|
|
@ -3370,7 +3370,11 @@ |
|
|
a.ScheduledDate, |
|
|
a.ScheduledDate, |
|
|
a.CreatedBy as createBy, |
|
|
a.CreatedBy as createBy, |
|
|
isnull(a.roll_qty, 0) as rollQty, |
|
|
isnull(a.roll_qty, 0) as rollQty, |
|
|
u.UserName as OperatorName |
|
|
|
|
|
|
|
|
u.UserName as OperatorName, |
|
|
|
|
|
type_flag1, |
|
|
|
|
|
type_flag2, |
|
|
|
|
|
type_flag3, |
|
|
|
|
|
type_flag4 |
|
|
FROM SOScheduledRouting AS a |
|
|
FROM SOScheduledRouting AS a |
|
|
inner join ShopOrder as t ON t.Site = a.Site AND t.OrderNo = a.SOOrderNo |
|
|
inner join ShopOrder as t ON t.Site = a.Site AND t.OrderNo = a.SOOrderNo |
|
|
inner join WorkCenterResource as w ON w.Site = a.Site AND w.WorkCenterNo = a.S_WorkCenterNo and w.ResourceID = a.S_ResourceID |
|
|
inner join WorkCenterResource as w ON w.Site = a.Site AND w.WorkCenterNo = a.S_WorkCenterNo and w.ResourceID = a.S_ResourceID |
|
|
@ -3413,6 +3417,18 @@ |
|
|
<if test="query.endDate != null"> |
|
|
<if test="query.endDate != null"> |
|
|
AND #{query.endDate} >= a.ScheduledDate |
|
|
AND #{query.endDate} >= a.ScheduledDate |
|
|
</if> |
|
|
</if> |
|
|
|
|
|
<if test="query.inspectionTypeNo != null and query.inspectionTypeNo != '' and query.inspectionTypeNo == '首件检'"> |
|
|
|
|
|
AND a.type_flag1 = 'Y' |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="query.inspectionTypeNo != null and query.inspectionTypeNo != '' and query.inspectionTypeNo == '自检'"> |
|
|
|
|
|
AND a.type_flag2 = 'Y' |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="query.inspectionTypeNo != null and query.inspectionTypeNo != '' and query.inspectionTypeNo == '巡检'"> |
|
|
|
|
|
AND a.type_flag3 = 'Y' |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="query.inspectionTypeNo != null and query.inspectionTypeNo != '' and query.inspectionTypeNo == '末件检'"> |
|
|
|
|
|
AND a.type_flag4 = 'Y' |
|
|
|
|
|
</if> |
|
|
</select> |
|
|
</select> |
|
|
|
|
|
|
|
|
<select id="searchPartInfo" parameterType="com.xujie.sys.modules.pms.data.QcFAIRecordData" resultType="com.xujie.sys.modules.pms.data.QcFAIRecordData"> |
|
|
<select id="searchPartInfo" parameterType="com.xujie.sys.modules.pms.data.QcFAIRecordData" resultType="com.xujie.sys.modules.pms.data.QcFAIRecordData"> |
|
|
@ -4392,6 +4408,54 @@ |
|
|
WHERE site = #{site} and BarcodeID = #{seqNo} |
|
|
WHERE site = #{site} and BarcodeID = #{seqNo} |
|
|
</update> |
|
|
</update> |
|
|
|
|
|
|
|
|
|
|
|
<update id="updateSOScheduledRoutingTypeFlag"> |
|
|
|
|
|
UPDATE SOScheduledRouting |
|
|
|
|
|
<set> |
|
|
|
|
|
<if test="inspectionTypeNo == '首件检'"> |
|
|
|
|
|
type_flag1 = 'Y', |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="inspectionTypeNo == '自检'"> |
|
|
|
|
|
type_flag2 = 'Y', |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="inspectionTypeNo == '巡检'"> |
|
|
|
|
|
type_flag3 = 'Y', |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="inspectionTypeNo == '末件检'"> |
|
|
|
|
|
type_flag4 = 'Y' |
|
|
|
|
|
</if> |
|
|
|
|
|
</set> |
|
|
|
|
|
WHERE site = #{site} and BarcodeID = #{seqNo} |
|
|
|
|
|
</update> |
|
|
|
|
|
|
|
|
|
|
|
<!-- 修改IQC明细记录信息 --> |
|
|
|
|
|
<update id="updateSOScheduledRoutingTypeFlag2"> |
|
|
|
|
|
UPDATE SOScheduledRouting |
|
|
|
|
|
<set> |
|
|
|
|
|
<if test="inspectionTypeNo == '首件检'"> |
|
|
|
|
|
type_flag1 = '', |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="inspectionTypeNo == '自检'"> |
|
|
|
|
|
type_flag2 = '', |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="inspectionTypeNo == '巡检'"> |
|
|
|
|
|
type_flag3 = '', |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="inspectionTypeNo == '末件检'"> |
|
|
|
|
|
type_flag4 = '' |
|
|
|
|
|
</if> |
|
|
|
|
|
</set> |
|
|
|
|
|
WHERE site = #{site} and BarcodeID = #{seqNo} |
|
|
|
|
|
</update> |
|
|
|
|
|
|
|
|
|
|
|
<select id="selectIPQCRecordByType" parameterType="QcFAIRecordData" resultType="QcRecordData"> |
|
|
|
|
|
SELECT |
|
|
|
|
|
site, |
|
|
|
|
|
bu_no, |
|
|
|
|
|
inspection_no |
|
|
|
|
|
FROM qc_ipqc_record |
|
|
|
|
|
WHERE site = #{site} and bu_no = #{buNo} and seq_no = #{seqNo} and inspection_type_no = #{inspectionTypeNo} |
|
|
|
|
|
</select> |
|
|
|
|
|
|
|
|
<select id="getShiftList" parameterType="ShiftData" resultType="ShiftData"> |
|
|
<select id="getShiftList" parameterType="ShiftData" resultType="ShiftData"> |
|
|
SELECT distinct |
|
|
SELECT distinct |
|
|
shiftdesc |
|
|
shiftdesc |
|
|
|