From e3c9aa6bbf449ec27cd5f037045418d355d0580e Mon Sep 17 00:00:00 2001 From: LSH Date: 星期一, 28 八月 2023 14:35:21 +0800 Subject: [PATCH] #bug修复 --- src/main/java/com/zy/asrs/service/impl/WorkServiceImpl.java | 34 ++++++++++++++++++++-------------- 1 files changed, 20 insertions(+), 14 deletions(-) diff --git a/src/main/java/com/zy/asrs/service/impl/WorkServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/WorkServiceImpl.java index 3da394d..208791b 100644 --- a/src/main/java/com/zy/asrs/service/impl/WorkServiceImpl.java +++ b/src/main/java/com/zy/asrs/service/impl/WorkServiceImpl.java @@ -167,27 +167,33 @@ for(StockOutParam.LocDetl one : param.getLocDetls()){ locs.add(one.getLocNo()); } + boolean sign = true; for (StockOutParam.LocDetl locDetl : param.getLocDetls()) { + LocMast locMast = locMastService.selectOne(new EntityWrapper<LocMast>().eq("loc_no", locDetl.getLocNo())); //鑾峰彇鍚屼竴搴撲綅缁勭殑澶栦晶搴撲綅鍙� List<String> groupOuterSingleLoc = Utils.getGroupOuterSingleLoc(locDetl.getLocNo()); - if (Utils.getBay(locDetl.getLocNo())>=21){ + if (locMast.getLocType2().equals((short)3)){ groupOuterSingleLoc = Utils.getGroupOuterSingleLocLowFrequency(locDetl.getLocNo()); } - for (String locNo : groupOuterSingleLoc) { - //姣忎釜搴撲綅鐨勫簱浣嶆槑缁� - if(locs.contains(locNo)) continue; - for (LocDetl detl : locDetlService.selectByLocNo(locNo)) { - if (!detl.getMatnr().equals(locDetl.getMatnr())) { - //涓嶆槸鐩稿悓鐗╂枡 - if (Utils.getBay(locDetl.getLocNo())>=21){ - locDetls.add(new StockOutParam.LocDetl(detl.getLocNo(), detl.getMatnr(), detl.getBatch(), detl.getAnfme())); - } - continue; - } - locDetls.add(new StockOutParam.LocDetl(detl.getLocNo(), detl.getMatnr(), detl.getBatch(), detl.getAnfme())); + if (sign){ + if (locMast.getLocType2().equals((short)3)) { + sign = false; } - + for (String locNo : groupOuterSingleLoc) { + //姣忎釜搴撲綅鐨勫簱浣嶆槑缁� + if(locs.contains(locNo)) continue; + for (LocDetl detl : locDetlService.selectByLocNo(locNo)) { + if (!detl.getMatnr().equals(locDetl.getMatnr())) { + //涓嶆槸鐩稿悓鐗╂枡 + if (!sign){ + locDetls.add(new StockOutParam.LocDetl(detl.getLocNo(), detl.getMatnr(), detl.getBatch(), detl.getAnfme())); + } + continue; + } + locDetls.add(new StockOutParam.LocDetl(detl.getLocNo(), detl.getMatnr(), detl.getBatch(), detl.getAnfme())); + } + } } locDetls.add(locDetl); } -- Gitblit v1.9.1