|
|
@ -92,13 +92,15 @@ class sapToMesCcscTaskResult {
|
|
|
|
if (resultWorkMap.size() > 0) {
|
|
|
|
if (resultWorkMap.size() > 0) {
|
|
|
|
String work_center_code = resultWorkMap.get(0).get("work_center_code")
|
|
|
|
String work_center_code = resultWorkMap.get(0).get("work_center_code")
|
|
|
|
String work_cell_code = resultWorkMap.get(0).get("work_cell_code")
|
|
|
|
String work_cell_code = resultWorkMap.get(0).get("work_cell_code")
|
|
|
|
|
|
|
|
long workOrderId = Long.valueOf(resultWorkMap.get(0).get("id")+"")
|
|
|
|
|
|
|
|
|
|
|
|
LOGGER.info("-------- filterData Start QMS同步MES_CCSC任务检测结果 70{}",work_center_code)
|
|
|
|
LOGGER.info("-------- filterData Start QMS同步MES_CCSC任务检测结果 70{}",work_center_code)
|
|
|
|
String logUpdateSql="update mes_comunication_log set is_deleted = 1 " +
|
|
|
|
String logUpdateSql="update mes_comunication_log set is_deleted = 1 " +
|
|
|
|
" where organize_code= '"+organizeCode+"' and work_center_code= '"+work_center_code+"' " +
|
|
|
|
" where organize_code= '"+organizeCode+"' and work_center_code= '"+work_center_code+"' " +
|
|
|
|
" and work_cell_code= '"+work_cell_code+"' and parameter_name= '"+part_no+"'; "
|
|
|
|
" and work_cell_code= '"+work_cell_code+"' and parameter_name= '"+part_no+"'; "
|
|
|
|
insertSqlList.add(logUpdateSql);
|
|
|
|
insertSqlList.add(logUpdateSql);
|
|
|
|
|
|
|
|
//更新工单CCSC状态
|
|
|
|
|
|
|
|
String workOrderUpdate = "";
|
|
|
|
if (taskResult.equals("2")) { //1:合格 2:不合格
|
|
|
|
if (taskResult.equals("2")) { //1:合格 2:不合格
|
|
|
|
String insertSql = String.format(" INSERT INTO mes_comunication_log " +
|
|
|
|
String insertSql = String.format(" INSERT INTO mes_comunication_log " +
|
|
|
|
"(`parameter_name`,`parameter_desc`,`value`,`status`,`work_cell_code`,`work_center_code`, " +
|
|
|
|
"(`parameter_name`,`parameter_desc`,`value`,`status`,`work_cell_code`,`work_center_code`, " +
|
|
|
@ -118,8 +120,11 @@ class sapToMesCcscTaskResult {
|
|
|
|
mesInputDefectRecordService.savePartInspection(mesProduceSn, "JOB",mesDefect,"A01")
|
|
|
|
mesInputDefectRecordService.savePartInspection(mesProduceSn, "JOB",mesDefect,"A01")
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
workOrderUpdate = "update mes_work_order set ccsc_status = 20,work_order_status=40 where id= "+workOrderId+"; "
|
|
|
|
|
|
|
|
}else{
|
|
|
|
|
|
|
|
workOrderUpdate = "update mes_work_order set ccsc_status = 10 where id= "+workOrderId+"; "
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
insertSqlList.add(workOrderUpdate);
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|