| | |
| | | Thread.sleep(200); |
| | | return R.ok().add(orderDetlService.selectByOrderId(orderId).stream().map(OrderDetl::getId).distinct().collect(Collectors.toList())); |
| | | } |
| | | |
| | | @PostMapping("/getMesOrder/auth") |
| | | @ManagerAuth |
| | | public R getMesOrder() { |
| | | List<String> orderNoList = orderService.getOrderNosByDocType(25L); |
| | | return R.ok().add(orderNoList); |
| | | } |
| | | |
| | | @PostMapping("/out/pakout/preview/auth") |
| | | @ManagerAuth |
| | | public R pakoutPreview(@RequestBody List<Long> ids) { |
| | |
| | | // 获取出库口 |
| | | List<Integer> staNos = new ArrayList<>(); |
| | | if (order.getDocType() == 21) { |
| | | staNos.add(3077); staNos.add(3106); |
| | | staNos.add(3077); |
| | | staNos.add(3106); |
| | | } else if (order.getDocType() == 22) { |
| | | staNos.add(2041); |
| | | } else if (order.getDocType() == 23) { |
| | | staNos.add(3092); staNos.add(3102); staNos.add(3095); |
| | | staNos.add(3092); |
| | | staNos.add(3102); |
| | | staNos.add(3095); |
| | | } |
| | | |
| | | // 去重 key,避免相同 loc+unit+model 重复显示 |
| | |
| | | // 判断是否为盘点单(docType == 23),如果不是则校验合格性 |
| | | Order order = orderService.selectByNo(stockOutParam.getOrderNo()); |
| | | if ( order.getDocType() != 23) { |
| | | if (order.getDocType() == 26 || order.getDocType() == 27) { |
| | | if ("合格".equals(one.getThreeCode())) { |
| | | throw new CoolException(one.getModel() + "卷是合格: " + one.getThreeCode()); |
| | | } |
| | | } else { |
| | | if (!"合格".equals(one.getThreeCode())) { |
| | | throw new CoolException(one.getModel() + "卷不合格: " + one.getThreeCode()); |
| | | } |
| | | } |
| | | } |
| | | |
| | |
| | | .eq("loc_no", locDetlDtos.get(0).getLocDetl().getLocNo())); |
| | | if ("F".equals(locMast.getLocSts()) || "D".equals(locMast.getLocSts())) { |
| | | Order order = orderService.selectByNo(stockOutParam.getOrderNo()); |
| | | IoWorkType ioWorkType = (order.getDocType() != null && order.getDocType() == 23) |
| | | ? IoWorkType.CHECK_OUT : null; |
| | | if (order.getDocType() != null) { |
| | | if (order.getDocType() == 26 || order.getDocType() == 27) { |
| | | ioWorkType = IoWorkType.ALL_OUT; |
| | | } |
| | | } |
| | | workService.stockOut(staNo, locDetlDtos, |
| | | order.getDocType() != null && order.getDocType() == 23 |
| | | ? IoWorkType.CHECK_OUT : null, |
| | | ioWorkType, |
| | | getUserId(),optionValue); |
| | | } else { |
| | | throw new CoolException("所选库位状态不为F/D,库位号:" + |
| | |
| | | |
| | | return R.ok(); |
| | | } |
| | | |
| | | |
| | | |
| | | @PostMapping("/out/refund/loc/auth") |