|
@@ -3,7 +3,7 @@
|
|
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
|
<mapper namespace="com.cpms.project.process.mapper.TValveCsocscMapper">
|
|
|
-
|
|
|
+
|
|
|
<resultMap type="TValveCsocsc" id="TValveCsocscResult">
|
|
|
<result property="id" column="id" />
|
|
|
<result property="unit" column="unit" />
|
|
@@ -28,15 +28,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<result property="updaterCode" column="updater_code" />
|
|
|
<result property="updatedate" column="updatedate" />
|
|
|
<result property="deptId" column="dept_id" />
|
|
|
+ <result property="checkBeforeSu" column="check_before_su" />
|
|
|
+ <result property="sheReview" column="she_review" />
|
|
|
</resultMap>
|
|
|
|
|
|
<sql id="selectTValveCsocscVo">
|
|
|
- select id, unit, vt_no, pid_no, location_des, medium, valve_type, valve_size, identifier, valve_position, firmly_secured, responsibility, checked_by, pid_status, risk_level, check_date, remarks, del_flag, creater_code, createdate, updater_code, updatedate, dept_id from t_valve_csocsc
|
|
|
+ select id, unit, vt_no, pid_no, location_des, medium, valve_type, valve_size, identifier, valve_position, firmly_secured, responsibility, checked_by, check_before_su, she_review, pid_status, risk_level, check_date, remarks, del_flag, creater_code, createdate, updater_code, updatedate, dept_id from t_valve_csocsc
|
|
|
</sql>
|
|
|
|
|
|
<select id="selectTValveCsocscList" parameterType="TValveCsocsc" resultMap="TValveCsocscResult">
|
|
|
<include refid="selectTValveCsocscVo"/>
|
|
|
- <where>
|
|
|
+ <where>
|
|
|
<if test="unit != null and unit != ''"> and unit = #{unit}</if>
|
|
|
<if test="vtNo != null and vtNo != ''"> and vt_no = #{vtNo}</if>
|
|
|
<if test="pidNo != null and pidNo != ''"> and pid_no = #{pidNo}</if>
|
|
@@ -62,12 +64,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
</where>
|
|
|
order by createdate desc
|
|
|
</select>
|
|
|
-
|
|
|
+
|
|
|
<select id="selectTValveCsocscById" parameterType="Long" resultMap="TValveCsocscResult">
|
|
|
<include refid="selectTValveCsocscVo"/>
|
|
|
where id = #{id}
|
|
|
</select>
|
|
|
-
|
|
|
+
|
|
|
<insert id="insertTValveCsocsc" parameterType="TValveCsocsc" useGeneratedKeys="true" keyProperty="id">
|
|
|
insert into t_valve_csocsc
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
@@ -93,7 +95,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="updaterCode != null">updater_code,</if>
|
|
|
<if test="updatedate != null">updatedate,</if>
|
|
|
<if test="deptId != null">dept_id,</if>
|
|
|
- </trim>
|
|
|
+ <if test="checkBeforeSu != null">check_before_su,</if>
|
|
|
+ <if test="sheReview != null">she_review,</if>
|
|
|
+
|
|
|
+ </trim>
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
<if test="unit != null">#{unit},</if>
|
|
|
<if test="vtNo != null">#{vtNo},</if>
|
|
@@ -117,7 +122,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="updaterCode != null">#{updaterCode},</if>
|
|
|
<if test="updatedate != null">#{updatedate},</if>
|
|
|
<if test="deptId != null">#{deptId},</if>
|
|
|
- </trim>
|
|
|
+ <if test="checkBeforeSu != null">#{checkBeforeSu},</if>
|
|
|
+ <if test="sheReview != null">#{sheReview},</if>
|
|
|
+
|
|
|
+ </trim>
|
|
|
</insert>
|
|
|
|
|
|
<update id="updateTValveCsocsc" parameterType="TValveCsocsc">
|
|
@@ -145,6 +153,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="updaterCode != null">updater_code = #{updaterCode},</if>
|
|
|
<if test="updatedate != null">updatedate = #{updatedate},</if>
|
|
|
<if test="deptId != null">dept_id = #{deptId},</if>
|
|
|
+ <if test="checkBeforeSu != null">check_before_su = #{checkBeforeSu},</if>
|
|
|
+ <if test="sheReview != null">she_review = #{sheReview},</if>
|
|
|
+
|
|
|
</trim>
|
|
|
where id = #{id}
|
|
|
</update>
|
|
@@ -154,9 +165,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
</delete>
|
|
|
|
|
|
<delete id="deleteTValveCsocscByIds" parameterType="String">
|
|
|
- delete from t_valve_csocsc where id in
|
|
|
+ delete from t_valve_csocsc where id in
|
|
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
|
|
#{id}
|
|
|
</foreach>
|
|
|
</delete>
|
|
|
-</mapper>
|
|
|
+</mapper>
|