From 9987b0cd5c549618738898fc990038335beeba4e Mon Sep 17 00:00:00 2001 From: zwl <1051256694@qq.com> Date: 星期四, 17 七月 2025 10:18:37 +0800 Subject: [PATCH] # --- src/main/java/com/zy/asrs/task/handler/WorkMastHandler.java | 23 +++++++++++++++++++++++ 1 files changed, 23 insertions(+), 0 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 bca1468..0e4e5b4 100644 --- a/src/main/java/com/zy/asrs/task/handler/WorkMastHandler.java +++ b/src/main/java/com/zy/asrs/task/handler/WorkMastHandler.java @@ -263,6 +263,23 @@ TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); return FAIL.setMsg("鐩樼偣鍏ュ簱 ===>> 宸ヤ綔鏄庣粏妗d负绌�; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getLocNo() + "]"); } + for (WrkDetl wrkDetl:wrkDetls57){ + LocDetl locDetl = new LocDetl(); + locDetl.sync(wrkDetl); + locDetl.setAnfme(wrkDetl.getAnfme());//鏁伴噺 + locDetl.setLocNo(wrkMast.getLocNo()); // 搴撲綅鍙� + locDetl.setZpallet(wrkDetl.getZpallet()); // 鎵樼洏鏉$爜 + locDetl.setModiTime(now); + locDetl.setAppeTime(now); + locDetl.setPrice(0.0); + if (null != locDetl) { + if (!locDetlService.insert(locDetl)) { +// exceptionHandle("鎷f枡鍏ュ簱 ===>> 淇敼搴撳瓨鏄庣粏鏁伴噺澶辫触锛沎workNo={0}],[locNo={1}]", wrkMast.getWrkNo(), wrkMast.getLocNo()); + TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); + return FAIL.setMsg("鎷f枡鍏ュ簱 ===>> 淇敼搴撳瓨鏄庣粏鏁伴噺澶辫触; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getLocNo() + "]"); + } + } + } // 淇敼搴撲綅鐘舵�� S ====>> F if (locMast.getLocSts().equals("S")) { locMast.setLocSts(wrkMast.getFullPlt().equals("Y")?"F":"D"); @@ -438,6 +455,12 @@ exceptionHandle("淇濆瓨宸ヤ綔鏄庣粏鍘嗗彶妗workNo={0}]澶辫触", wrkMast.getWrkNo()); } } + // 鍒犻櫎宸ヤ綔妗f簮搴撲綅鐨勫簱瀛樻槑缁� + if (!locDetlService.delete(new EntityWrapper<LocDetl>().eq("loc_no", wrkMast.getSourceLocNo()))) { +// exceptionHandle("鍏ㄦ澘鍑哄簱 ===>> 鍒犻櫎搴撳瓨鏄庣粏澶辫触锛沎workNo={0}],[sourceLocNo={1}]", wrkMast.getWrkNo(), wrkMast.getSourceLocNo()); + TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); + return FAIL.setMsg("鎷f枡鐩樼偣鍑哄簱 ===>> 鍒犻櫎搴撳瓨鏄庣粏澶辫触; [workNo=" + wrkMast.getWrkNo() + "],[locNo=" + wrkMast.getSourceLocNo() + "]"); + } } break; default: -- Gitblit v1.9.1