质量问题修改3

master
zhaoxiaolin 1 year ago
parent 798e94cb5c
commit 8b7d6c238d

@ -363,6 +363,7 @@ public class IWCInterfaceServiceImpl implements IWCSInterfaceService {
* @return * @return
*/ */
private R reportHzToSap(MesReportWork workOrder){ private R reportHzToSap(MesReportWork workOrder){
Date nowTime = DateUtils.getNowDate();
SapRFW sapRFW = new SapRFW(); SapRFW sapRFW = new SapRFW();
sapRFW.setAufnr(workOrder.getWorkorderCodeSap());//虚拟工单号 sapRFW.setAufnr(workOrder.getWorkorderCodeSap());//虚拟工单号
sapRFW.setGamng(workOrder.getQuantityFeedback().toString());//报工数量 sapRFW.setGamng(workOrder.getQuantityFeedback().toString());//报工数量
@ -403,7 +404,7 @@ public class IWCInterfaceServiceImpl implements IWCSInterfaceService {
workOrder.setUploadStatus("2"); workOrder.setUploadStatus("2");
workOrder.setUploadMsg(r.getMsg()); workOrder.setUploadMsg(r.getMsg());
} }
workOrder.setUploadTime(DateUtils.getNowDate()); workOrder.setUploadTime(nowTime);
mesReportWorkMapper.updateSyncSapStatus(workOrder); mesReportWorkMapper.updateSyncSapStatus(workOrder);
return R.ok(); return R.ok();

@ -481,7 +481,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
mrw.workTime,mrw.useMan,mrw.uploadStatus,mrw.unit, mrw.workTime,mrw.useMan,mrw.uploadStatus,mrw.unit,
pow.order_code orderCode,pow.quantity_split quantity, pow.order_code orderCode,pow.quantity_split quantity,
pow.workorder_code_sap workorderCodeSap, pow.workorder_code_sap workorderCodeSap,
pow.product_date productDate pow.product_date productDate,
mrw.uploadTime,
mrw.uploadMsg
from ( from (
select workorder_code workorderCode, select workorder_code workorderCode,
product_code productCode, product_code productCode,
@ -493,7 +495,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
sum(work_time) workTime, sum(work_time) workTime,
sum(use_man) useMan, sum(use_man) useMan,
upload_status uploadStatus, upload_status uploadStatus,
<!--,upload_time uploadTime,--> upload_time uploadTime,
upload_msg uploadMsg,
unit unit
from mes_report_work from mes_report_work
where del_flag = '0' and parent_order = '0' where del_flag = '0' and parent_order = '0'
@ -505,7 +508,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="uploadStatus != null and uploadStatus != ''"> and upload_status = #{uploadStatus}</if> <if test="uploadStatus != null and uploadStatus != ''"> and upload_status = #{uploadStatus}</if>
group by workorder_code, product_code,product_name,machine_code,machine_name,shift_code group by workorder_code, product_code,product_name,machine_code,machine_name,shift_code
,upload_status,unit ,upload_status,unit
<!--,upload_time--> ,upload_time,upload_msg
) mrw ) mrw
left join pro_order_workorder pow on mrw.workorderCode = pow.workorder_code left join pro_order_workorder pow on mrw.workorderCode = pow.workorder_code
<where> <where>

@ -123,6 +123,11 @@ public class QcProCheckServiceImpl implements QcProCheckService {
public List<QcCheckTaskIncome> getCheckTaskList(QcCheckTaskIncome qcCheckTaskIncome) { public List<QcCheckTaskIncome> getCheckTaskList(QcCheckTaskIncome qcCheckTaskIncome) {
DynamicDataSourceContextHolder.push(qcCheckTaskIncome.getFactoryCode()); DynamicDataSourceContextHolder.push(qcCheckTaskIncome.getFactoryCode());
List<QcCheckTaskIncome> dtos = qcProCheckMapper.getCheckTaskList(qcCheckTaskIncome); List<QcCheckTaskIncome> dtos = qcProCheckMapper.getCheckTaskList(qcCheckTaskIncome);
for(QcCheckTaskIncome dto:dtos){
if(StringUtils.isEmpty(dto.getWorkorderCodeSap())){
dto.setWorkorderCodeSap(dto.getOrderNo());
}
}
return dtos; return dtos;
} }

@ -256,12 +256,19 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
qct.check_status, qct.check_man_code,qct.check_man_name, qct.check_time, qct.check_result, qct.check_status, qct.check_man_code,qct.check_man_name, qct.check_time, qct.check_result,
qct.status,qct.create_by,qct.create_time,qct.check_type, qct.status,qct.create_by,qct.create_time,qct.check_type,
qct.noOk_quality,qct.aNoOkquality,qct.bNoOkquality,qct.cNoOkquality,qct.sample_quality qct.noOk_quality,qct.aNoOkquality,qct.bNoOkquality,qct.cNoOkquality,qct.sample_quality
,pow.workorder_code_sap workorderCodeSap <if test='checkType=="checkTypeSCXJ" or checkType=="checkTypeSC"'>
,pow.workorder_code_sap workorderCodeSap
</if>
from qc_check_task qct from qc_check_task qct
left join qc_check_task_user qctu on qctu.belong_to = qct.record_id left join qc_check_task_user qctu on qctu.belong_to = qct.record_id
left join pro_order_workorder pow on pow.workorder_code = qct.order_no <if test='checkType=="checkTypeSCXJ" or checkType=="checkTypeSC"'>
left join pro_order_workorder pow on pow.workorder_code = qct.order_no
</if>
<where> <where>
and qct.del_flag = '0' and pow.del_flag = '0' and qct.del_flag = '0'
<if test='checkType=="checkTypeSCXJ" or checkType=="checkTypeSC"'>
and pow.del_flag = '0'
</if>
<if test="checkType != null and checkType != ''"> and qct.check_type = #{checkType}</if> <if test="checkType != null and checkType != ''"> and qct.check_type = #{checkType}</if>
<if test="checkManCode != null and checkManCode != ''"> and qctu.check_man_code = #{checkManCode}</if> <if test="checkManCode != null and checkManCode != ''"> and qctu.check_man_code = #{checkManCode}</if>
<if test="checkStatus != null and checkStatus != ''"> and qct.check_status in (${checkStatus})</if> <if test="checkStatus != null and checkStatus != ''"> and qct.check_status in (${checkStatus})</if>

Loading…
Cancel
Save