| | |
| | | // 检索库位 |
| | | List<String> matnrs = waitPakins.stream().map(WaitPakin::getMatnr).distinct().collect(Collectors.toList()); |
| | | List<String> batchs = waitPakins.stream().map(WaitPakin::getBatch).distinct().collect(Collectors.toList()); |
| | | StartupDto dto = commonService.getLocNo(1, 1, devpNo, matnrs.get(0), batchs.get(0), null, locTypeDto); |
| | | // StartupDto dto = commonService.getLocNo(1, 1, devpNo, matnrs.get(0), batchs.get(0), null, locTypeDto); |
| | | StartupDto dto = commonService.getLocNo(1, 1, devpNo, matnrs.get(0), batchs.get(0), null, locTypeDto,barcode); |
| | | int workNo = dto.getWorkNo(); |
| | | Date now = new Date(); |
| | | // 生成工作档 |
| | |
| | | wrkMast.setIoPri(13D); // 优先级 |
| | | wrkMast.setCrnNo(dto.getCrnNo()); |
| | | wrkMast.setSourceStaNo(dto.getSourceStaNo()); |
| | | wrkMast.setStaNo(dto.getStaNo()); |
| | | wrkMast.setLocNo(dto.getLocNo()); |
| | | wrkMast.setStaNo(dto.getStaNo());// 目标站 |
| | | wrkMast.setLocNo(dto.getLocNo());// 目标库位 |
| | | wrkMast.setBarcode(barcode); // 托盘码 |
| | | wrkMast.setFullPlt("Y"); // 满板:Y |
| | | wrkMast.setPicking("N"); // 拣料 |
| | |
| | | if (locMast.getLocSts().equals("O")) { |
| | | locMast.setLocSts("S"); // S.入库预约 |
| | | locMast.setModiTime(now); |
| | | if (locMast.getBarcode()==null){ |
| | | locMast.setBarcode(barcode);//托盘与库位绑定 |
| | | } |
| | | if (!locMastService.updateById(locMast)) { |
| | | throw new CoolException("改变库位状态失败"); |
| | | } |
| | |
| | | // 源站点状态检测 |
| | | BasDevp sourceStaNo = basDevpService.checkSiteStatus(devpNo, true); |
| | | // 检索库位 |
| | | StartupDto dto = commonService.getLocNo(1, 10, devpNo, null, null, null, locTypeDto); |
| | | StartupDto dto = commonService.getLocNo(1, 10, devpNo, null, null, null, locTypeDto,barcode); |
| | | int workNo = dto.getWorkNo(); |
| | | // 生成工作档 |
| | | WrkMast wrkMast = new WrkMast(); |
| | |
| | | if (locMast.getLocSts().equals("O")) { |
| | | locMast.setLocSts("S"); // S.入库预约 |
| | | locMast.setModiTime(new Date()); |
| | | if (locMast.getBarcode()==null){ |
| | | locMast.setBarcode(barcode);//托盘与库位绑定 |
| | | } |
| | | if (!locMastService.updateById(locMast)) { |
| | | throw new CoolException("改变库位状态失败"); |
| | | } |