diff --git a/aucma-api/src/main/java/com/aucma/api/service/impl/PdaServiceImpl.java b/aucma-api/src/main/java/com/aucma/api/service/impl/PdaServiceImpl.java index 047baca..a587782 100644 --- a/aucma-api/src/main/java/com/aucma/api/service/impl/PdaServiceImpl.java +++ b/aucma-api/src/main/java/com/aucma/api/service/impl/PdaServiceImpl.java @@ -143,9 +143,9 @@ public class PdaServiceImpl implements IPdaBindingService { */ @Override public String messageNotifications(String userName) { - List> barcodeList = mapper.messageNotifications(userName); String resultMessage = null; StringBuilder boxCode = null; + List> barcodeList = mapper.messageNotifications(userName); for (HashMap map : barcodeList) { String userNames = map.get("INSPECTION_USER_CODE"); if (userNames.equals("NULL")){ @@ -161,12 +161,15 @@ public class PdaServiceImpl implements IPdaBindingService { recordExceptionProcess.setInspectionUserCode(userNames); recordExceptionProcessService.updateRecordExceptionProcess(recordExceptionProcess); if (boxCode == null){ - boxCode = new StringBuilder(map.get("BOX_BARCODE")); + boxCode = new StringBuilder(map.get("BOX_BARCODE")).append("(位置:").append(map.get("TEAM_NAME")).append(")"); } else { - boxCode.append(",").append(map.get("BOX_BARCODE")); + boxCode.append(",").append(map.get("BOX_BARCODE")).append("(位置:").append(map.get("TEAM_NAME")).append(")"); } + } + if (boxCode != null){ resultMessage = boxCode + "已审批完成,请进行降级处理!"; } + System.out.println("PDA降级消息通知:" + resultMessage); return resultMessage; } diff --git a/aucma-api/src/main/resources/mapper/PdaBindingMapper.xml b/aucma-api/src/main/resources/mapper/PdaBindingMapper.xml index 0c8ded9..07e7599 100644 --- a/aucma-api/src/main/resources/mapper/PdaBindingMapper.xml +++ b/aucma-api/src/main/resources/mapper/PdaBindingMapper.xml @@ -97,11 +97,15 @@ diff --git a/aucma-report/src/main/java/com/aucma/report/domain/RecordExceptionProcess.java b/aucma-report/src/main/java/com/aucma/report/domain/RecordExceptionProcess.java index 0fda1c5..eb1811e 100644 --- a/aucma-report/src/main/java/com/aucma/report/domain/RecordExceptionProcess.java +++ b/aucma-report/src/main/java/com/aucma/report/domain/RecordExceptionProcess.java @@ -62,6 +62,12 @@ public class RecordExceptionProcess extends BaseEntity { @Excel(name = "班组") private String teamCode; + /** + * 班组名称 + */ + @Excel(name = "班组名称") + private String teamName; + /** * 申请原因 */ @@ -170,7 +176,13 @@ public class RecordExceptionProcess extends BaseEntity { @Excel(name = "修改时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss") private Date updatedTime; + public String getTeamName() { + return teamName; + } + public void setTeamName(String teamName) { + this.teamName = teamName; + } public String getProductLineCode() { return productLineCode; diff --git a/aucma-report/src/main/resources/mapper/report/GeneralReportMapper.xml b/aucma-report/src/main/resources/mapper/report/GeneralReportMapper.xml index 2716834..60e32bf 100644 --- a/aucma-report/src/main/resources/mapper/report/GeneralReportMapper.xml +++ b/aucma-report/src/main/resources/mapper/report/GeneralReportMapper.xml @@ -217,7 +217,9 @@ ZSD.QUALITY_DEFECT_CODE, ZSD.QUALITY_DEFECT_NAME, COUNT(*) Q_SUM, - TO_CHAR(ROUND(COUNT(*) / OS.OFFLINE_NUM * 100, 2), 'FM99990.00') || '%' OFFLINE_NUM + CASE + WHEN OS.OFFLINE_NUM = 0 THEN '0.00' + ELSE TO_CHAR(ROUND(COUNT(*) / OS.OFFLINE_NUM * 100, 2), 'FM99990.00') END || '%' OFFLINE_NUM FROM ( SELECT BF.FACTORY_NAME, PL2.PRODUCT_LINE_CODE, diff --git a/aucma-report/src/main/resources/mapper/report/RecordExceptionProcessMapper.xml b/aucma-report/src/main/resources/mapper/report/RecordExceptionProcessMapper.xml index a921c6c..741bb4a 100644 --- a/aucma-report/src/main/resources/mapper/report/RecordExceptionProcessMapper.xml +++ b/aucma-report/src/main/resources/mapper/report/RecordExceptionProcessMapper.xml @@ -9,6 +9,7 @@ + @@ -35,13 +36,14 @@ select rep.obj_id, - PB.ORDER_CODE orderCode, + PB.ORDER_CODE orderCode, BP.PRODUCT_LINE_CODE productLineCode, BP.PRODUCT_LINE_NAME productLineName, rep.box_barcode, ML.MATERIAL_SPECIFICATIONS materialModel, rep.production_user_flag, rep.team_code, + bt.TEAM_NAME, rep.apply_reason, rep.apply_time, rep.quality_user_flag, @@ -65,6 +67,7 @@ left join BASE_ORDERINFO bo on bo.ORDER_CODE = pb.ORDER_CODE left join BASE_PRODUCTLINE BP ON BP.WORK_CENTER_CODE = BO.WORK_CENTER_CODE LEFT JOIN BASE_MATERIALINFO ML ON ML.MATERIAL_CODE = PB.MATERIAL_CODE + left join BASE_TEAMMEMBERS bt on bt.TEAM_CODE = rep.TEAM_CODE