From f934f933155b4c65a17d18176f4a2fbf95e68535 Mon Sep 17 00:00:00 2001 From: zhang <zc857179121@qq.com> Date: 星期三, 28 五月 2025 08:33:01 +0800 Subject: [PATCH] 13 --- src/main/java/com/zy/asrs/task/handler/WorkMastHandler.java | 167 +++++++++++++++++++++++++++++++++---------------------- 1 files changed, 100 insertions(+), 67 deletions(-) diff --git a/src/main/java/com/zy/asrs/task/handler/WorkMastHandler.java b/src/main/java/com/zy/asrs/task/handler/WorkMastHandler.java index 2616ec9..918da4f 100644 --- a/src/main/java/com/zy/asrs/task/handler/WorkMastHandler.java +++ b/src/main/java/com/zy/asrs/task/handler/WorkMastHandler.java @@ -44,14 +44,14 @@ // 4.鍏ュ簱瀹屾垚 if (wrkMast.getWrkSts() == 4) { return doIn(wrkMast); - // 14.鍑哄簱瀹屾垚 - } else if (wrkMast.getWrkSts() == 14) { + // 14.鍑哄簱瀹屾垚 + } else if (wrkMast.getWrkSts() == 14) { return doOut(wrkMast); } return SUCCESS; } - private ReturnT<String> doIn(WrkMast wrkMast){ + private ReturnT<String> doIn(WrkMast wrkMast) { Date now = new Date(); LocMast locMast = locMastService.selectById(wrkMast.getLocNo()); try { @@ -96,11 +96,11 @@ // 閬嶅巻宸ヤ綔鏄庣粏锛屾洿鏂板簱瀛樻槑缁嗗拰鍏ュ簱閫氱煡妗� for (WrkDetl wrkDetl : wrkDetls) { - LocDetl locDetl = locDetlService.selectItem(locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand() - ,wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(),wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3()); + LocDetl locDetl = locDetlService.selectItem(locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand() + , wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3()); if (null != locDetl) { - if (!locDetlService.updateAnfme(wrkDetl.getAnfme(), wrkMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3() - ,wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3())) { + if (!locDetlService.updateAnfme(wrkDetl.getAnfme(), wrkMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3() + , wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3())) { // exceptionHandle("鍏ㄦ澘鍏ュ簱 ===>> 鏇存柊搴撳瓨鏄庣粏澶辫触锛沎workNo={0}],[locNo={1}]", wrkMast.getWrkNo(), wrkMast.getLocNo()); TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); return FAIL.setMsg("鍏ㄦ澘鍏ュ簱 ===>> 鏇存柊搴撳瓨鏄庣粏澶辫触; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getLocNo() + "]"); @@ -122,26 +122,30 @@ // 鏇存柊璁㈠崟瀹屾垚鏁伴噺 OrderDetlPakin orderDetlPakin = orderDetlPakinService.selectItem - (wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(), - wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3()); - if (orderDetlPakin==null){ + (wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), + wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3()); + if (orderDetlPakin == null) { orderDetlPakin = orderDetlPakinService.selectItem - (wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), - wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(), - wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3()); + (wrkDetl.getOrderNo(), wrkDetl.getMatnr(), null, + wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), + wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3()); } try { - if(!Cools.isEmpty(orderDetlPakin)){ - if(!orderDetlPakinService.increaseQtyByOrderNo(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), - orderDetlPakin.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(), - wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3(),wrkDetl.getAnfme())){ + if (!Cools.isEmpty(orderDetlPakin)) { +// if (!orderDetlPakinService.increaseQtyByOrderNo(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), +// orderDetlPakin.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), +// wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3(), wrkDetl.getAnfme())) { + if (!orderDetlPakoutService.increaseQtyByOrderNo(orderDetlPakin.getOrderNo(), orderDetlPakin.getMatnr(), + orderDetlPakin.getBatch(), orderDetlPakin.getBrand(), orderDetlPakin.getStandby1(), orderDetlPakin.getStandby2(), orderDetlPakin.getStandby3(), + orderDetlPakin.getBoxType1(), orderDetlPakin.getBoxType2(), orderDetlPakin.getBoxType3(), orderDetlPakin.getAnfme())) { // exceptionHandle("鍏ㄦ澘鍏ュ簱 ===>> 鏇存柊璁㈠崟瀹屾垚鏁伴噺澶辫触锛沎workNo={0}],[locNo={1}]", // wrkMast.getWrkNo(), wrkMast.getLocNo()); TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); return FAIL.setMsg("鍏ㄦ澘鍏ュ簱 ===>> 鏇存柊璁㈠崟瀹屾垚鏁伴噺澶辫触; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getLocNo() + "]"); } } - } catch (Exception ignore){} + } catch (Exception ignore) { + } } // 淇敼搴撲綅鐘舵�� S ====>> F @@ -212,11 +216,11 @@ } for (WrkDetl wrkDetl : wrkDetls53) { - LocDetl locDetl = locDetlService.selectItem(locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand() - ,wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(),wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3()); + LocDetl locDetl = locDetlService.selectItem(locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand() + , wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3()); if (null != locDetl) { - if (!locDetlService.updateAnfme(locDetl.getAnfme() - wrkDetl.getAnfme(), locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3() - ,wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3())) { + if (!locDetlService.updateAnfme(locDetl.getAnfme() - wrkDetl.getAnfme(), locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3() + , wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3())) { // exceptionHandle("鎷f枡鍏ュ簱 ===>> 淇敼搴撳瓨鏄庣粏鏁伴噺澶辫触锛沎workNo={0}],[locNo={1}]", wrkMast.getWrkNo(), wrkMast.getLocNo()); TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); return FAIL.setMsg("鎷f枡鍏ュ簱 ===>> 淇敼搴撳瓨鏄庣粏鏁伴噺澶辫触; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getLocNo() + "]"); @@ -225,26 +229,31 @@ // 鏇存柊璁㈠崟瀹屾垚鏁伴噺 OrderDetlPakin orderDetlPakin = orderDetlPakinService.selectItem - (wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand(), - wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(), - wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3()); - if (orderDetlPakin==null){ + (wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand(), + wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), + wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3()); + if (orderDetlPakin == null) { orderDetlPakin = orderDetlPakinService.selectItem - (wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(), - wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3()); + (wrkDetl.getOrderNo(), wrkDetl.getMatnr(), null, wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), + wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3()); } try { - if(!Cools.isEmpty(orderDetlPakin)){ - if(!orderDetlPakinService.increaseQtyByOrderNo(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), - orderDetlPakin.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(), - wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3(),wrkDetl.getAnfme())){ + if (!Cools.isEmpty(orderDetlPakin)) { +// if (!orderDetlPakinService.increaseQtyByOrderNo(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), +// orderDetlPakin.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), +// wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3(), wrkDetl.getAnfme())) { + + if (!orderDetlPakoutService.increaseQtyByOrderNo(orderDetlPakin.getOrderNo(), orderDetlPakin.getMatnr(), + orderDetlPakin.getBatch(), orderDetlPakin.getBrand(), orderDetlPakin.getStandby1(), orderDetlPakin.getStandby2(), orderDetlPakin.getStandby3(), + orderDetlPakin.getBoxType1(), orderDetlPakin.getBoxType2(), orderDetlPakin.getBoxType3(), orderDetlPakin.getAnfme())) { // exceptionHandle("鎷f枡鍏ュ簱 ===>> 鏇存柊璁㈠崟瀹屾垚鏁伴噺澶辫触锛沎workNo={0}],[locNo={1}]", // wrkMast.getWrkNo(), wrkMast.getLocNo()); TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); return FAIL.setMsg("鎷f枡鍏ュ簱 ===>> 鏇存柊璁㈠崟瀹屾垚鏁伴噺澶辫触; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getLocNo() + "]"); } } - } catch (Exception ignore){} + } catch (Exception ignore) { + } } // 淇敼搴撲綅鐘舵�� Q ====>> F @@ -270,13 +279,13 @@ return FAIL.setMsg("骞舵澘鍏ュ簱 ===>> 宸ヤ綔鏄庣粏妗d负绌�; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getLocNo() + "]"); } // 淇敼搴撳瓨鏄庣粏鏁伴噺锛屽鏃犲簱瀛橈紝鏇炬柊澧� - for (WrkDetl wrkDetl:wrkDetls54) { + for (WrkDetl wrkDetl : wrkDetls54) { - LocDetl locDetl = locDetlService.selectItem(locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand() - ,wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(),wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3()); + LocDetl locDetl = locDetlService.selectItem(locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand() + , wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3()); if (null != locDetl) { - if (!locDetlService.updateAnfme(wrkDetl.getAnfme(), locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3() - ,wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3())) { + if (!locDetlService.updateAnfme(wrkDetl.getAnfme(), locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3() + , wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3())) { // exceptionHandle("骞舵澘鍏ュ簱 ===>> 淇敼搴撳瓨鏄庣粏鏁伴噺澶辫触锛沎workNo={0}],[matnr={1}]", wrkMast.getWrkNo(), wrkDetl.getMatnr()); TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); return FAIL.setMsg("骞舵澘鍏ュ簱 ===>> 淇敼搴撳瓨鏄庣粏鏁伴噺澶辫触; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getLocNo() + "]"); @@ -296,17 +305,21 @@ } // 鏇存柊璁㈠崟瀹屾垚鏁伴噺 - OrderDetlPakin orderDetlPakin = orderDetlPakinService.selectItem(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand(), wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(), wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3()); + OrderDetlPakin orderDetlPakin = orderDetlPakinService.selectItem(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3()); try { - if(!Cools.isEmpty(orderDetlPakin)){ - if(!orderDetlPakinService.increaseQtyByOrderNo(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), - orderDetlPakin.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(), - wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3(),wrkDetl.getAnfme())){ + if (!Cools.isEmpty(orderDetlPakin)) { +// if (!orderDetlPakinService.increaseQtyByOrderNo(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), +// orderDetlPakin.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), +// wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3(), wrkDetl.getAnfme())) { + + if (!orderDetlPakoutService.increaseQtyByOrderNo(orderDetlPakin.getOrderNo(), orderDetlPakin.getMatnr(), + orderDetlPakin.getBatch(), orderDetlPakin.getBrand(), orderDetlPakin.getStandby1(), orderDetlPakin.getStandby2(), orderDetlPakin.getStandby3(), + orderDetlPakin.getBoxType1(), orderDetlPakin.getBoxType2(), orderDetlPakin.getBoxType3(), orderDetlPakin.getAnfme())) { TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); return FAIL.setMsg("骞舵澘鍏ュ簱 ===>> 鏇存柊璁㈠崟瀹屾垚鏁伴噺澶辫触; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getLocNo() + "]"); } } - } catch (Exception ignore){ + } catch (Exception ignore) { } @@ -333,9 +346,27 @@ TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); return FAIL.setMsg("鐩樼偣鍏ュ簱 ===>> 宸ヤ綔鏄庣粏妗d负绌�; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getLocNo() + "]"); } + for (WrkDetl wrkDetl : wrkDetls57) { + if (!Cools.isEmpty(wrkDetl.getOrderNo())) { + // 鏇存柊璁㈠崟瀹屾垚鏁伴噺 + OrderDetlPakout orderDetlPakout = orderDetlPakoutService.selectItem(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), + wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3()); + if (!Cools.isEmpty(orderDetlPakout)) { +// if (!orderDetlPakoutService.increaseQtyByOrderNo(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), +// orderDetlPakout.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), +// wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3(), wrkDetl.getAnfme())) { + if (!orderDetlPakoutService.increaseQtyByOrderNo(orderDetlPakout.getOrderNo(), orderDetlPakout.getMatnr(), + orderDetlPakout.getBatch(), orderDetlPakout.getBrand(), orderDetlPakout.getStandby1(), orderDetlPakout.getStandby2(), orderDetlPakout.getStandby3(), + orderDetlPakout.getBoxType1(), orderDetlPakout.getBoxType2(), orderDetlPakout.getBoxType3(), orderDetlPakout.getAnfme())) { + TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); + return FAIL.setMsg("鐩樼偣鍏ュ簱 ===>> 鏇存柊璁㈠崟瀹屾垚鏁伴噺澶辫触; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getSourceLocNo() + "]"); + } + } + } + } // 淇敼搴撲綅鐘舵�� Q ====>> F if (locMast.getLocSts().equals("Q")) { - locMast.setLocSts(wrkMast.getFullPlt().equals("Y")?"F":"D"); + locMast.setLocSts(wrkMast.getFullPlt().equals("Y") ? "F" : "D"); locMast.setBarcode(wrkMast.getBarcode()); locMast.setIoTime(now); locMast.setModiTime(now); @@ -404,7 +435,7 @@ return SUCCESS; } - private ReturnT<String> doOut(WrkMast wrkMast){ + private ReturnT<String> doOut(WrkMast wrkMast) { Date now = new Date(); LocMast locMast = locMastService.selectById(wrkMast.getSourceLocNo()); try { @@ -430,24 +461,25 @@ } for (WrkDetl wrkDetl : wrkDetls101) { // 鏇存柊璁㈠崟瀹屾垚鏁伴噺 - OrderDetlPakout orderDetlPakout = orderDetlPakoutService.selectItem(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(), - wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3()); - if (orderDetlPakout==null){ - orderDetlPakout = orderDetlPakoutService.selectItem(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(), - wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3()); + OrderDetlPakout orderDetlPakout = orderDetlPakoutService.selectItem(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), + wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3()); + if (orderDetlPakout == null) { + orderDetlPakout = orderDetlPakoutService.selectItem(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), null, wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), + wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3()); } try { - if(!Cools.isEmpty(orderDetlPakout)){ - if(!orderDetlPakoutService.increaseQtyByOrderNo(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), - orderDetlPakout.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(), - wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3(),wrkDetl.getAnfme())){ + if (!Cools.isEmpty(orderDetlPakout)) { + if (!orderDetlPakoutService.increaseQtyByOrderNo(orderDetlPakout.getOrderNo(), orderDetlPakout.getMatnr(), + orderDetlPakout.getBatch(), orderDetlPakout.getBrand(), orderDetlPakout.getStandby1(), orderDetlPakout.getStandby2(), orderDetlPakout.getStandby3(), + orderDetlPakout.getBoxType1(), orderDetlPakout.getBoxType2(), orderDetlPakout.getBoxType3(), orderDetlPakout.getAnfme())) { // exceptionHandle("鍏ㄦ澘鍑哄簱 ===>> 鏇存柊璁㈠崟瀹屾垚鏁伴噺澶辫触锛沎workNo={0}],[locNo={1}]", // wrkMast.getWrkNo(), wrkMast.getLocNo()); TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); return FAIL.setMsg("鍏ㄦ澘鍑哄簱 ===>> 鏇存柊璁㈠崟瀹屾垚鏁伴噺澶辫触; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getSourceLocNo() + "]"); } } - } catch (Exception ignore){} + } catch (Exception ignore) { + } } // 鍒犻櫎宸ヤ綔妗f簮搴撲綅鐨勫簱瀛樻槑缁� if (!locDetlService.delete(new EntityWrapper<LocDetl>().eq("loc_no", wrkMast.getSourceLocNo()))) { @@ -477,28 +509,29 @@ return FAIL.setMsg("骞舵澘閫斾腑鎹℃枡 ===>> 宸ヤ綔鏄庣粏妗d负绌�; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getSourceLocNo() + "]"); } for (WrkDetl wrkDetl : wrkDetls108) { - LocDetl locDetl = locDetlService.selectItem(locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand() - ,wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(),wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3()); + LocDetl locDetl = locDetlService.selectItem(locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand() + , wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3()); if (null != locDetl) { - if (!locDetlService.updateAnfme(locDetl.getAnfme() - wrkDetl.getAnfme(), locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3() - ,wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3())) { + if (!locDetlService.updateAnfme(locDetl.getAnfme() - wrkDetl.getAnfme(), locMast.getLocNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3() + , wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3())) { TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); return FAIL.setMsg("骞舵澘閫斾腑鎹℃枡 ===>> 淇敼搴撳瓨鏄庣粏鏁伴噺澶辫触; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getLocNo() + "]"); } } // 鏇存柊璁㈠崟瀹屾垚鏁伴噺 - OrderDetlPakout orderDetlPakout = orderDetlPakoutService.selectItem(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(), - wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3()); + OrderDetlPakout orderDetlPakout = orderDetlPakoutService.selectItem(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), wrkDetl.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), + wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3()); try { - if(!Cools.isEmpty(orderDetlPakout)){ - if(!orderDetlPakoutService.increaseQtyByOrderNo(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), - orderDetlPakout.getBatch(),wrkDetl.getBrand(),wrkDetl.getStandby1(),wrkDetl.getStandby2(),wrkDetl.getStandby3(), - wrkDetl.getBoxType1(),wrkDetl.getBoxType2(),wrkDetl.getBoxType3(),wrkDetl.getAnfme())){ + if (!Cools.isEmpty(orderDetlPakout)) { + if (!orderDetlPakoutService.increaseQtyByOrderNo(wrkDetl.getOrderNo(), wrkDetl.getMatnr(), + orderDetlPakout.getBatch(), wrkDetl.getBrand(), wrkDetl.getStandby1(), wrkDetl.getStandby2(), wrkDetl.getStandby3(), + wrkDetl.getBoxType1(), wrkDetl.getBoxType2(), wrkDetl.getBoxType3(), wrkDetl.getAnfme())) { TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); return FAIL.setMsg("骞舵澘閫斾腑鎹℃枡 ===>> 鏇存柊璁㈠崟瀹屾垚鏁伴噺澶辫触; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getSourceLocNo() + "]"); } } - } catch (Exception ignore){} + } catch (Exception ignore) { + } } break; // 绌烘澘鍑哄簱 -- Gitblit v1.9.1