|
|
@ -17,6 +17,7 @@
|
|
|
|
<result property="printReason" column="print_reason"/>
|
|
|
|
<result property="printReason" column="print_reason"/>
|
|
|
|
<result property="recordTime" column="record_time"/>
|
|
|
|
<result property="recordTime" column="record_time"/>
|
|
|
|
<result property="createBy" column="create_by"/>
|
|
|
|
<result property="createBy" column="create_by"/>
|
|
|
|
|
|
|
|
<result property="productLineCode" column="PRODUCT_LINE_CODE"/>
|
|
|
|
</resultMap>
|
|
|
|
</resultMap>
|
|
|
|
|
|
|
|
|
|
|
|
<sql id="selectPrintSupplementBarCodeVo">
|
|
|
|
<sql id="selectPrintSupplementBarCodeVo">
|
|
|
@ -30,9 +31,11 @@
|
|
|
|
PS.print_reason,
|
|
|
|
PS.print_reason,
|
|
|
|
PS.record_time,
|
|
|
|
PS.record_time,
|
|
|
|
PS.create_by,
|
|
|
|
PS.create_by,
|
|
|
|
|
|
|
|
PB.PRODUCT_LINE_CODE,
|
|
|
|
CASE WHEN PS.IS_PRINT = '1' THEN '已打印' ELSE '未打印' END IS_PRINT
|
|
|
|
CASE WHEN PS.IS_PRINT = '1' THEN '已打印' ELSE '未打印' END IS_PRINT
|
|
|
|
FROM C##AUCMA_SCADA.PRINT_SUPPLEMENTBARCODE PS
|
|
|
|
FROM C##AUCMA_SCADA.PRINT_SUPPLEMENTBARCODE PS
|
|
|
|
LEFT JOIN C##AUCMA_MES.BASE_MATERIALINFO BM ON BM.MATERIAL_CODE = PS.MATERIAL_CODE
|
|
|
|
LEFT JOIN C##AUCMA_MES.BASE_MATERIALINFO BM ON BM.MATERIAL_CODE = PS.MATERIAL_CODE
|
|
|
|
|
|
|
|
LEFT JOIN C##AUCMA_SCADA.PRINT_BARCODE PB ON PB.MATERIAL_BARCODE = PS.MATERIAL_CODE
|
|
|
|
</sql>
|
|
|
|
</sql>
|
|
|
|
|
|
|
|
|
|
|
|
<select id="selectPrintSupplementBarCodeList" parameterType="PrintSupplementBarCode"
|
|
|
|
<select id="selectPrintSupplementBarCodeList" parameterType="PrintSupplementBarCode"
|
|
|
@ -56,6 +59,7 @@
|
|
|
|
'%')
|
|
|
|
'%')
|
|
|
|
</if>
|
|
|
|
</if>
|
|
|
|
<if test="isPrint != null and isPrint != ''">and PS.is_print = #{isPrint}</if>
|
|
|
|
<if test="isPrint != null and isPrint != ''">and PS.is_print = #{isPrint}</if>
|
|
|
|
|
|
|
|
<if test="productLineCode != null and productLineCode != ''">and PB.PRODUCT_LINE_CODE = #{productLineCode}</if>
|
|
|
|
</where>
|
|
|
|
</where>
|
|
|
|
ORDER BY PS.record_time DESC
|
|
|
|
ORDER BY PS.record_time DESC
|
|
|
|
</select>
|
|
|
|
</select>
|
|
|
@ -65,38 +69,6 @@
|
|
|
|
where PS.obj_id = #{objId}
|
|
|
|
where PS.obj_id = #{objId}
|
|
|
|
</select>
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|
<insert id="insertPrintSupplementBarCode" parameterType="PrintSupplementBarCode">
|
|
|
|
|
|
|
|
<selectKey keyProperty="objId" resultType="long" order="BEFORE">
|
|
|
|
|
|
|
|
SELECT seq_print_supplementbarcode.NEXTVAL as objId FROM DUAL
|
|
|
|
|
|
|
|
</selectKey>
|
|
|
|
|
|
|
|
insert into print_supplementbarcode
|
|
|
|
|
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
|
|
|
|
|
<if test="objId != null">obj_id,</if>
|
|
|
|
|
|
|
|
<if test="orderCode != null">order_code,</if>
|
|
|
|
|
|
|
|
<if test="materialCode != null">material_code,</if>
|
|
|
|
|
|
|
|
<if test="materialName != null">material_name,</if>
|
|
|
|
|
|
|
|
<if test="materialBarcode != null">material_barcode,</if>
|
|
|
|
|
|
|
|
<if test="printTime != null">print_time,</if>
|
|
|
|
|
|
|
|
<if test="printBartype != null">print_bartype,</if>
|
|
|
|
|
|
|
|
<if test="printName != null">print_name,</if>
|
|
|
|
|
|
|
|
<if test="isPrint != null">is_print,</if>
|
|
|
|
|
|
|
|
<if test="printReason != null">print_reason,</if>
|
|
|
|
|
|
|
|
<if test="createBy != null">create_by,</if>
|
|
|
|
|
|
|
|
</trim>
|
|
|
|
|
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
|
|
|
|
|
<if test="objId != null">#{objId},</if>
|
|
|
|
|
|
|
|
<if test="orderCode != null">#{orderCode},</if>
|
|
|
|
|
|
|
|
<if test="materialCode != null">#{materialCode},</if>
|
|
|
|
|
|
|
|
<if test="materialName != null">#{materialName},</if>
|
|
|
|
|
|
|
|
<if test="materialBarcode != null">#{materialBarcode},</if>
|
|
|
|
|
|
|
|
<if test="printTime != null">#{printTime},</if>
|
|
|
|
|
|
|
|
<if test="printBartype != null">#{printBartype},</if>
|
|
|
|
|
|
|
|
<if test="printName != null">#{printName},</if>
|
|
|
|
|
|
|
|
<if test="isPrint != null">#{isPrint},</if>
|
|
|
|
|
|
|
|
<if test="printReason != null">#{printReason},</if>
|
|
|
|
|
|
|
|
<if test="createBy != null">#{createBy},</if>
|
|
|
|
|
|
|
|
</trim>
|
|
|
|
|
|
|
|
</insert>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<update id="updatePrintSupplementBarCode" parameterType="PrintSupplementBarCode">
|
|
|
|
<update id="updatePrintSupplementBarCode" parameterType="PrintSupplementBarCode">
|
|
|
|
update print_supplementbarcode
|
|
|
|
update print_supplementbarcode
|
|
|
|