|  |  | 
 |  |  |             if (record.outLineTime != null) { | 
 |  |  |                 isEnd = true; | 
 |  |  |             } | 
 |  |  |             if(StringUtils.isNotBlank(params.getContent())){ | 
 |  |  |                 record.nodeContent = params.getContent(); | 
 |  |  |             } | 
 |  |  |         } else { | 
 |  |  |             PrProductionNode node = nodeDao.selectByPrimaryKey(workLast.nodeId); | 
 |  |  |             record.nodeContent = node.content; | 
 |  |  | 
 |  |  |      */ | 
 |  |  |     private Integer getStatus(String status, boolean isEnd, String workType) { | 
 |  |  |         //组装   2024/07/17 目前组装workType 1 只有MarkOk     //测试    //品检 | 
 |  |  |         if (WORK_TYPE_ASSEMBLY.equals(workType) || WORK_TYPE_TEST.equals(workType) || WORK_TYPE_INSPECTION.equals(workType) || WORK_TYPE_REPAIR.equals(workType)) { | 
 |  |  |         if (WORK_TYPE_ASSEMBLY.equals(workType) || WORK_TYPE_TEST.equals(workType) || WORK_TYPE_INSPECTION.equals(workType) || WORK_TYPE_REPAIR.equals(workType)|| WORK_TYPE_OTHER.equals(workType)) { | 
 |  |  |             return switch (status) { | 
 |  |  |                 case QrCodeConstant.MarkOk -> isEnd ? DeviceStatus.COMPLETED.getCode() : DeviceStatus.ASSEMBLING.getCode(); | 
 |  |  |                 case QrCodeConstant.MarkQualified -> isEnd ? DeviceStatus.COMPLETED.getCode() : DeviceStatus.ASSEMBLING.getCode(); | 
 |  |  | 
 |  |  |      * @return 结果 | 
 |  |  |      */ | 
 |  |  |     private Integer getResult(String status, String workType) { | 
 |  |  |         //组装 | 
 |  |  |         if (WORK_TYPE_ASSEMBLY.equals(workType)) { | 
 |  |  |         //组装  临时任务-其他 | 
 |  |  |         if (WORK_TYPE_ASSEMBLY.equals(workType) || WORK_TYPE_OTHER.equals(workType)) { | 
 |  |  |             return switch (status) { | 
 |  |  |                 case QrCodeConstant.MarkOk -> DeviceResult.PASS.getCode(); | 
 |  |  |                 default -> throw new RuntimeException("状态错误"); | 
 |  |  | 
 |  |  |         if (workLast == null) { | 
 |  |  |             throw new RuntimeException("系统中没有该条登录信息"); | 
 |  |  |         } | 
 |  |  |         //保存工作记录 | 
 |  |  |         int count = 0; | 
 |  |  |         //保存工作记录 //如果有设备码 | 
 |  |  |         if(vo.deviceNo != null && StringUtils.isNotBlank(vo.deviceNo[0])){ | 
 |  |  |             StaDeviceLast deviceLast = buildDeviceLast(vo, workLast, vo.deviceNo[0]); | 
 |  |  |             count = deviceLast.id == null ? deviceLastDao.insertSelective(deviceLast) : | 
 |  |  |                     deviceLastDao.updateByPrimaryKey(deviceLast); | 
 |  |  |             saveDeviceProductionLog(deviceLast); | 
 |  |  |         }else{ | 
 |  |  |         StaDeviceProductionLog log = new StaDeviceProductionLog(); | 
 |  |  |         log.setId(null); // 设备生产日志ID设为null,表示新增 | 
 |  |  |         log.setDeviceNo("");  //RepairId  planId  currNode deviceCycleContent  memo | 
 |  |  | 
 |  |  |         log.setOutTime(new Date()); | 
 |  |  |         log.setUpdatedBy(workLast.getUserId()); | 
 |  |  |         log.setNumber(vo.getNumber()); | 
 |  |  |         int count = deviceProductionLogDao.insertSelective(log); | 
 |  |  |             count = deviceProductionLogDao.insertSelective(log); | 
 |  |  |  | 
 |  |  |         } | 
 |  |  |         return count; | 
 |  |  |     } | 
 |  |  |  |