From e5ca62a8fb0bf2fef9d305cde0a6edc2cf30e506 Mon Sep 17 00:00:00 2001 From: 刘小明 <liuxm_a@163.com> Date: 星期三, 07 八月 2024 16:05:38 +0800 Subject: [PATCH] 初始化代码优化,登录时有密码长度校验,帮初始密码改为6位 --- pms-parent/pms-web-station/src/main/java/com/dy/pmsStation/assemblyStep/AssemblyStepSv.java | 20 ++++++++++++-------- 1 files changed, 12 insertions(+), 8 deletions(-) diff --git a/pms-parent/pms-web-station/src/main/java/com/dy/pmsStation/assemblyStep/AssemblyStepSv.java b/pms-parent/pms-web-station/src/main/java/com/dy/pmsStation/assemblyStep/AssemblyStepSv.java index b0b5e5c..438f790 100644 --- a/pms-parent/pms-web-station/src/main/java/com/dy/pmsStation/assemblyStep/AssemblyStepSv.java +++ b/pms-parent/pms-web-station/src/main/java/com/dy/pmsStation/assemblyStep/AssemblyStepSv.java @@ -173,7 +173,7 @@ StaDeviceLast deviceLast = buildDeviceLast(params, workLast, deviceList.get(0)); int count = deviceLast.id == null ? deviceLastDao.insertSelective(deviceLast) : - deviceLastDao.updateByPrimaryKeySelective(deviceLast); + deviceLastDao.updateByPrimaryKey(deviceLast); saveDeviceProductionLog(deviceLast); @@ -349,16 +349,18 @@ repairInfo.repairTime = new Date(); repairInfo.repairBy = workLast.userId; repairInfo.repairReason = vo.errorMsg; - repairInfo.fromNode = preDeviceRecord.currNode; + if (preDeviceRecord != null) { + repairInfo.fromNode = preDeviceRecord.currNode; + } repairInfoDao.insertSelective(repairInfo); StaDeviceLast deviceLast = buildDeviceLast(vo, workLast, vo.deviceNo[0]); - + deviceLast.setRepairId(repairInfo.getId()); int count = deviceLast.id == null ? deviceLastDao.insertSelective(deviceLast) : - deviceLastDao.updateByPrimaryKeySelective(deviceLast); + deviceLastDao.updateByPrimaryKey(deviceLast); saveDeviceProductionLog(deviceLast); - boolean isEndNode = nodeDao.isEndNode(preDeviceRecord.currNode); - if (isEndNode) { + //鍙缁忓巻杩囩粨鏉熻妭鐐�,灏变竴鐩磋褰昫evice life + if (preDeviceRecord != null && preDeviceRecord.getOutLineTime() != null) { saveDeviceLife(deviceLast); } return count; @@ -391,10 +393,10 @@ } StaDeviceLast deviceLast = buildDeviceLast(vo, workLast, vo.deviceNo[0]); int count = deviceLast.id == null ? deviceLastDao.insertSelective(deviceLast) : - deviceLastDao.updateByPrimaryKeySelective(deviceLast); + deviceLastDao.updateByPrimaryKey(deviceLast); saveDeviceProductionLog(deviceLast); PrProductionNode node = nodeDao.selectByPrimaryKey(workLast.nodeId); - if (node.isRecord) { + if (node != null && node.isRecord) { saveDeviceLife(deviceLast); } return count; @@ -473,6 +475,7 @@ public List<PltProductQualityInspectionItems> getQualityItems(String proId) { Map<String, Object> params = new HashMap<>(); params.put("proId", proId);//item start count + params.put("disabled", "0"); //鏌ヨ绗﹀悎鏉′欢鐨勮褰� return qualityItemsDao.selectSome(params); } @@ -480,6 +483,7 @@ public List<PltProductTestInspectionItems> getTestItems(String proId) { Map<String, Object> params = new HashMap<>(); params.put("proId", proId); + params.put("disabled", "0"); return testItemsDao.selectSome(params); } -- Gitblit v1.8.0