From 3bcfebe3912bdaf8abf2d29b6913b771bad3804c Mon Sep 17 00:00:00 2001
From: zhang <zc857179121@qq.com>
Date: 星期一, 20 十月 2025 08:44:46 +0800
Subject: [PATCH] 1
---
src/main/java/com/zy/asrs/service/impl/MobileServiceImpl.java | 40 ++++++++++++++++++++++++++++++++++------
1 files changed, 34 insertions(+), 6 deletions(-)
diff --git a/src/main/java/com/zy/asrs/service/impl/MobileServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/MobileServiceImpl.java
index d0f9011..4cd06b4 100644
--- a/src/main/java/com/zy/asrs/service/impl/MobileServiceImpl.java
+++ b/src/main/java/com/zy/asrs/service/impl/MobileServiceImpl.java
@@ -661,6 +661,17 @@
throw new CoolException("鍗曟嵁缂栧彿宸蹭綔涓氬畬鎴�");
}
+ List<WaitPakin> waitPakinList = waitPakinService.selectList(new EntityWrapper<WaitPakin>()
+ .eq("matnr", elem.getMatnr())
+ .eq("batch", elem.getBatch())
+ .eq("order_no", elem.getOrderNo())
+ .eq("anfme", elem.getAnfme())
+ .eq("standby1", elem.getStandby1())
+ );
+ if (!waitPakinList.isEmpty()) {
+ throw new CoolException("璇ヨ鍗曠墿鏂欏凡缁忕粍鎵橈紒");
+ }
+
// 璁㈠崟鏄庣粏鏁伴噺鏍¢獙
OrderDetl orderDetl = OrderInAndOutUtil.selectItem(Boolean.TRUE, order.getId(), elem.getMatnr(), elem.getBatch(), elem.getBrand(), elem.getStandby1(), elem.getStandby2(), elem.getStandby3(),
elem.getBoxType1(), elem.getBoxType2(), elem.getBoxType3());
@@ -1295,7 +1306,7 @@
.setJson(JSON.toJSONString(map))
.build()
.doPost();
- log.info("toOutSta:{}", response);
+ log.info("toOutSta:{},{}",map, response);
} catch (Exception e) {
log.error("fail", e);
}
@@ -1303,6 +1314,12 @@
@Override
public void toAllOut(PalletToAllOutParam param, Long userId) {
+ String barcodeSize = param.getBarcode().substring(0, 2);
+ String newBarcodeSize = param.getNewBarcode().substring(0, 2);
+ if (!barcodeSize.equals(newBarcodeSize)) {
+ throw new CoolException("鎵樼洏灏哄涓嶄竴鑷�");
+ }
+
WrkMast wrkMast = wrkMastService.selectByBarcode(param.getBarcode());
if (wrkMast == null) {
throw new CoolException("宸ヤ綔妗d笉瀛樺湪");
@@ -1316,15 +1333,26 @@
throw new CoolException("宸ヤ綔鐘舵�佹湭澶勪簬宸插嚭搴�");
}
+ LocMast locMast = locMastService.selectOne(new EntityWrapper<LocMast>().eq("loc_no", wrkMast.getSourceLocNo()));
+ if (locMast == null) {
+ throw new CoolException("搴撲綅涓嶅瓨鍦�");
+ }
+
+ if (!locMast.getLocSts().equals("P")) {
+ throw new CoolException("搴撲綅绫诲瀷涓嶆槸鎷f枡鍑哄簱");
+ }
+
wrkMast.setBarcode(param.getNewBarcode());
wrkMast.setModiTime(new Date());
wrkMast.setModiUser(userId);
wrkMastService.updateById(wrkMast);
- WrkDetl wrkDetl = new WrkDetl();
- wrkDetl.setZpallet(param.getNewBarcode());
- wrkDetl.setModiTime(new Date());
- wrkDetl.setModiUser(userId);
- wrkDetlService.update(wrkDetl, new EntityWrapper<WrkDetl>().eq("wrk_no", wrkMast.getWrkNo()));
+ wrkDetlService.updateBarcode(wrkMast.getWrkNo(), param.getNewBarcode());
+
+ locMast.setBarcode(param.getNewBarcode());
+ locMast.setModiTime(new Date());
+ locMastService.updateById(locMast);
+
+ locDetlService.updateBarcode(locMast.getLocNo(), param.getNewBarcode());
}
}
--
Gitblit v1.9.1