| | |
| | | bsFormulaChildInfo.setResults("NG"); |
| | | bsFormulaChildInfo.setCollectData(bsFormulaChildInfo.getTightenTheArray()); |
| | | |
| | | // Integer ngTimes = bsFormulaChildInfo.getNgTimes(); |
| | | // bsFormulaChildInfo.setNgTimes(ngTimes+1); |
| | | // bsFormulaChildInfoMapper.updateBsFormulaChildInfo(bsFormulaChildInfo); |
| | | // |
| | | // if(bsFormulaChildInfo.getNgTimes() > 3){ |
| | | // this.recordNgTighteningData(bsFormulaChildInfo.getLocationCode(), bsFormulaChildInfo.getProductCode(), bsFormulaChildInfo.getProductBarcode()); |
| | | // WebSocketUsers.sendMessageToUserByText(map.get(bsFormulaChildInfo.getLocationCode()), "NG"); |
| | | // return AjaxResult.error("超过三次拧紧 pack NG下线!"); |
| | | // } |
| | | Integer ngTimes = bsFormulaChildInfo.getNgTimes(); |
| | | bsFormulaChildInfo.setNgTimes(ngTimes+1); |
| | | bsFormulaChildInfoMapper.updateBsFormulaChildInfo(bsFormulaChildInfo); |
| | | |
| | | if(bsFormulaChildInfo.getNgTimes() > 3){ |
| | | this.recordNgTighteningData(bsFormulaChildInfo.getLocationCode(), bsFormulaChildInfo.getProductCode(), bsFormulaChildInfo.getProductBarcode()); |
| | | WebSocketUsers.sendMessageToUserByText(map.get(bsFormulaChildInfo.getLocationCode()), "NG"); |
| | | return AjaxResult.error("超过三次拧紧 pack NG下线!"); |
| | | } |
| | | return AjaxResult.error("拧紧结果NG,请重新拧紧!"); |
| | | }else { |
| | | //List<BsFormulaChildInfo> bsFormulaChildInfos = bsFormulaChildInfoMapper.selectBsFormulaChildInfoList(listQuery); |
| | |
| | | String originalString = bsFormulaChildInfo.getTightenTheArray(); |
| | | String modifiedString = originalString.replaceFirst("OK", "NG"); |
| | | bsFormulaChildInfo.setCollectData(modifiedString); |
| | | // bsFormulaChildInfoMapper.updateBsFormulaChildInfo(bsFormulaChildInfo); |
| | | |
| | | Integer ngTimes = bsFormulaChildInfo.getNgTimes(); |
| | | bsFormulaChildInfo.setNgTimes(ngTimes+1); |
| | | bsFormulaChildInfoMapper.updateBsFormulaChildInfo(bsFormulaChildInfo); |
| | | |
| | | if(bsFormulaChildInfo.getNgTimes() > 3){ |
| | | this.recordNgTighteningData(bsFormulaChildInfo.getLocationCode(), bsFormulaChildInfo.getProductCode(), bsFormulaChildInfo.getProductBarcode()); |
| | | WebSocketUsers.sendMessageToUserByText(map.get(bsFormulaChildInfo.getLocationCode()), "NG"); |
| | | return AjaxResult.error("超过三次拧紧 pack NG下线!"); |
| | | } |
| | | return AjaxResult.error("拧紧结果NG,请重新拧紧!"); |
| | | } |
| | | |
| | |
| | | childInfoTemp.setProcessesCode(childInfo.getProcessesCode()); |
| | | childInfoTemp.setProductCode(childInfo.getProductCode()); |
| | | childInfoTemp.setStepSort(childInfo.getStepSort()); |
| | | // childInfoTemp.setLineCode(childInfo.getId()); |
| | | childInfoTemp.setChildId(childInfo.getId()); |
| | | bsFormulaChildInfoTempService.save(childInfoTemp); |
| | | } |
| | | } |