|
|
@ -3,7 +3,7 @@
|
|
|
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
|
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
|
|
<mapper namespace="com.op.quality.mapper.QcCheckTaskDetailMapper">
|
|
|
|
<mapper namespace="com.op.quality.mapper.QcCheckTaskDetailMapper">
|
|
|
|
|
|
|
|
|
|
|
|
<resultMap type="QcCheckTaskDetail" id="QcCheckTaskDetailResult">
|
|
|
|
<resultMap type="QcCheckTaskDetail" id="QcCheckTaskDetailResult">
|
|
|
|
<result property="recordId" column="record_id" />
|
|
|
|
<result property="recordId" column="record_id" />
|
|
|
|
<result property="belongTo" column="belong_to" />
|
|
|
|
<result property="belongTo" column="belong_to" />
|
|
|
@ -35,7 +35,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
|
|
|
|
|
|
|
<select id="selectQcCheckTaskDetailList" parameterType="QcCheckTaskDetail" resultMap="QcCheckTaskDetailResult">
|
|
|
|
<select id="selectQcCheckTaskDetailList" parameterType="QcCheckTaskDetail" resultMap="QcCheckTaskDetailResult">
|
|
|
|
<include refid="selectQcCheckTaskDetailVo"/>
|
|
|
|
<include refid="selectQcCheckTaskDetailVo"/>
|
|
|
|
<where>
|
|
|
|
<where>
|
|
|
|
<if test="belongTo != null and belongTo != ''"> and belong_to = #{belongTo}</if>
|
|
|
|
<if test="belongTo != null and belongTo != ''"> and belong_to = #{belongTo}</if>
|
|
|
|
<if test="orderNum != null and orderNum != ''"> and order_num = #{orderNum}</if>
|
|
|
|
<if test="orderNum != null and orderNum != ''"> and order_num = #{orderNum}</if>
|
|
|
|
<if test="ruleName != null and ruleName != ''"> and rule_name like concat('%', #{ruleName}, '%')</if>
|
|
|
|
<if test="ruleName != null and ruleName != ''"> and rule_name like concat('%', #{ruleName}, '%')</if>
|
|
|
@ -53,12 +53,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
<if test="factoryCode != null and factoryCode != ''"> and factory_code = #{factoryCode}</if>
|
|
|
|
<if test="factoryCode != null and factoryCode != ''"> and factory_code = #{factoryCode}</if>
|
|
|
|
</where>
|
|
|
|
</where>
|
|
|
|
</select>
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|
<select id="selectQcCheckTaskDetailByRecordId" parameterType="String" resultMap="QcCheckTaskDetailResult">
|
|
|
|
<select id="selectQcCheckTaskDetailByRecordId" parameterType="String" resultMap="QcCheckTaskDetailResult">
|
|
|
|
<include refid="selectQcCheckTaskDetailVo"/>
|
|
|
|
<include refid="selectQcCheckTaskDetailVo"/>
|
|
|
|
where record_id = #{recordId}
|
|
|
|
where record_id = #{recordId}
|
|
|
|
</select>
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|
<insert id="insertQcCheckTaskDetail" parameterType="QcCheckTaskDetail">
|
|
|
|
<insert id="insertQcCheckTaskDetail" parameterType="QcCheckTaskDetail">
|
|
|
|
insert into qc_check_task_detail
|
|
|
|
insert into qc_check_task_detail
|
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
@ -110,8 +110,30 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
<if test="delFlag != null">#{delFlag},</if>
|
|
|
|
<if test="delFlag != null">#{delFlag},</if>
|
|
|
|
</trim>
|
|
|
|
</trim>
|
|
|
|
</insert>
|
|
|
|
</insert>
|
|
|
|
|
|
|
|
<insert id="addBatch">
|
|
|
|
|
|
|
|
insert into qc_check_task_detail(
|
|
|
|
|
|
|
|
record_id,belong_to,
|
|
|
|
|
|
|
|
project_id,rule_name,order_num,
|
|
|
|
|
|
|
|
property_code,check_mode,
|
|
|
|
|
|
|
|
check_tool,unit_code,
|
|
|
|
|
|
|
|
check_standard,actual_value,
|
|
|
|
|
|
|
|
status,create_by,create_time,
|
|
|
|
|
|
|
|
factory_code,del_flag
|
|
|
|
|
|
|
|
) values
|
|
|
|
|
|
|
|
<foreach item="item" index="index" collection="list" separator=",">
|
|
|
|
|
|
|
|
(
|
|
|
|
|
|
|
|
#{item.recordId},#{item.belongTo},
|
|
|
|
|
|
|
|
#{item.projectId},#{item.ruleName},#{item.sort},
|
|
|
|
|
|
|
|
#{item.propertyCode},#{item.checkMode},
|
|
|
|
|
|
|
|
#{item.checkTool},#{item.unitCode},
|
|
|
|
|
|
|
|
#{item.checkStandard},#{item.actualValue},
|
|
|
|
|
|
|
|
'0',#{item.createBy},#{item.createTime},
|
|
|
|
|
|
|
|
#{item.factoryCode},'0'
|
|
|
|
|
|
|
|
)
|
|
|
|
|
|
|
|
</foreach>
|
|
|
|
|
|
|
|
</insert>
|
|
|
|
|
|
|
|
|
|
|
|
<update id="updateQcCheckTaskDetail" parameterType="QcCheckTaskDetail">
|
|
|
|
<update id="updateQcCheckTaskDetail" parameterType="QcCheckTaskDetail">
|
|
|
|
update qc_check_task_detail
|
|
|
|
update qc_check_task_detail
|
|
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
|
|
<if test="belongTo != null">belong_to = #{belongTo},</if>
|
|
|
|
<if test="belongTo != null">belong_to = #{belongTo},</if>
|
|
|
@ -144,9 +166,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
</delete>
|
|
|
|
</delete>
|
|
|
|
|
|
|
|
|
|
|
|
<delete id="deleteQcCheckTaskDetailByRecordIds" parameterType="String">
|
|
|
|
<delete id="deleteQcCheckTaskDetailByRecordIds" parameterType="String">
|
|
|
|
delete from qc_check_task_detail where record_id in
|
|
|
|
delete from qc_check_task_detail where record_id in
|
|
|
|
<foreach item="recordId" collection="array" open="(" separator="," close=")">
|
|
|
|
<foreach item="recordId" collection="array" open="(" separator="," close=")">
|
|
|
|
#{recordId}
|
|
|
|
#{recordId}
|
|
|
|
</foreach>
|
|
|
|
</foreach>
|
|
|
|
</delete>
|
|
|
|
</delete>
|
|
|
|
</mapper>
|
|
|
|
</mapper>
|
|
|
|