|
@@ -1,9 +1,9 @@
|
|
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<!DOCTYPE mapper
|
|
<!DOCTYPE mapper
|
|
-PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
-"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
|
|
|
|
+ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
+ "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
<mapper namespace="com.phm.manage.mapper.SortieMapper">
|
|
<mapper namespace="com.phm.manage.mapper.SortieMapper">
|
|
-
|
|
|
|
|
|
+
|
|
<resultMap type="Sortie" id="SortieResult">
|
|
<resultMap type="Sortie" id="SortieResult">
|
|
<result property="id" column="id" />
|
|
<result property="id" column="id" />
|
|
<result property="aircraftNumber" column="aircraft_number" />
|
|
<result property="aircraftNumber" column="aircraft_number" />
|
|
@@ -24,25 +24,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
|
<select id="selectSortieList" parameterType="Sortie" resultMap="SortieResult">
|
|
<select id="selectSortieList" parameterType="Sortie" resultMap="SortieResult">
|
|
<include refid="selectSortieVo"/>
|
|
<include refid="selectSortieVo"/>
|
|
- <where>
|
|
|
|
|
|
+ <where>
|
|
<if test="aircraftNumber != null and aircraftNumber != ''"> and aircraft_number = #{aircraftNumber}</if>
|
|
<if test="aircraftNumber != null and aircraftNumber != ''"> and aircraft_number = #{aircraftNumber}</if>
|
|
<if test="sortieNumber != null and sortieNumber != ''"> and sortie_number = #{sortieNumber}</if>
|
|
<if test="sortieNumber != null and sortieNumber != ''"> and sortie_number = #{sortieNumber}</if>
|
|
<if test="startTime != null and startTime != ''"> and start_time = #{startTime}</if>
|
|
<if test="startTime != null and startTime != ''"> and start_time = #{startTime}</if>
|
|
<if test="endTime != null and endTime != ''"> and end_time = #{endTime}</if>
|
|
<if test="endTime != null and endTime != ''"> and end_time = #{endTime}</if>
|
|
<if test="duration != null and duration != ''"> and duration = #{duration}</if>
|
|
<if test="duration != null and duration != ''"> and duration = #{duration}</if>
|
|
- <if test="isDelete != null "> and is_delete = #{isDelete}</if>
|
|
|
|
- <if test="createBy != null and createBy != ''"> and create_by = #{createBy}</if>
|
|
|
|
- <if test="createTime != null "> and create_time = #{createTime}</if>
|
|
|
|
- <if test="updateBy != null and updateBy != ''"> and update_by = #{updateBy}</if>
|
|
|
|
- <if test="updateTime != null "> and update_time = #{updateTime}</if>
|
|
|
|
</where>
|
|
</where>
|
|
</select>
|
|
</select>
|
|
-
|
|
|
|
|
|
+
|
|
<select id="selectSortieById" parameterType="Long" resultMap="SortieResult">
|
|
<select id="selectSortieById" parameterType="Long" resultMap="SortieResult">
|
|
<include refid="selectSortieVo"/>
|
|
<include refid="selectSortieVo"/>
|
|
where id = #{id}
|
|
where id = #{id}
|
|
</select>
|
|
</select>
|
|
-
|
|
|
|
|
|
+
|
|
<insert id="insertSortie" parameterType="Sortie" useGeneratedKeys="true" keyProperty="id">
|
|
<insert id="insertSortie" parameterType="Sortie" useGeneratedKeys="true" keyProperty="id">
|
|
insert into phm_sortie
|
|
insert into phm_sortie
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
@@ -56,7 +51,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="createTime != null">create_time,</if>
|
|
<if test="createTime != null">create_time,</if>
|
|
<if test="updateBy != null">update_by,</if>
|
|
<if test="updateBy != null">update_by,</if>
|
|
<if test="updateTime != null">update_time,</if>
|
|
<if test="updateTime != null">update_time,</if>
|
|
- </trim>
|
|
|
|
|
|
+ </trim>
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<if test="aircraftNumber != null">#{aircraftNumber},</if>
|
|
<if test="aircraftNumber != null">#{aircraftNumber},</if>
|
|
<if test="sortieNumber != null">#{sortieNumber},</if>
|
|
<if test="sortieNumber != null">#{sortieNumber},</if>
|
|
@@ -68,7 +63,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="createTime != null">#{createTime},</if>
|
|
<if test="createTime != null">#{createTime},</if>
|
|
<if test="updateBy != null">#{updateBy},</if>
|
|
<if test="updateBy != null">#{updateBy},</if>
|
|
<if test="updateTime != null">#{updateTime},</if>
|
|
<if test="updateTime != null">#{updateTime},</if>
|
|
- </trim>
|
|
|
|
|
|
+ </trim>
|
|
</insert>
|
|
</insert>
|
|
|
|
|
|
<update id="updateSortie" parameterType="Sortie">
|
|
<update id="updateSortie" parameterType="Sortie">
|
|
@@ -93,7 +88,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</delete>
|
|
</delete>
|
|
|
|
|
|
<delete id="deleteSortieByIds" parameterType="String">
|
|
<delete id="deleteSortieByIds" parameterType="String">
|
|
- delete from phm_sortie where id in
|
|
|
|
|
|
+ delete from phm_sortie where id in
|
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
|
#{id}
|
|
#{id}
|
|
</foreach>
|
|
</foreach>
|