自动化立体仓库 - WMS系统
chen.lin
5 天以前 055743022694b6fc1bb1864137e0c81b6ea658c5
src/main/java/com/zy/common/service/CommonService.java
@@ -169,15 +169,17 @@
                }
            }
            //检测是否为呆滞料
            String matnr = findLocNoAttributeVo.getMatnr();
            Mat mat = matService.selectByMatnr(matnr);
            if (mat == null) {
                throw new CoolException(matnr + "物料信息不存在");
            }
            if (staDescId != 10) {
                //检测是否为呆滞料
                String matnr = findLocNoAttributeVo.getMatnr();
                Mat mat = matService.selectByMatnr(matnr);
                if (mat == null) {
                    throw new CoolException(matnr + "物料信息不存在");
                }
            if (mat.getTscp() != null && mat.getTscp() == 1) {
                crnList.add(0, 1);
                if (mat.getTscp() != null && mat.getTscp() == 1) {
                    crnList.add(0, 1);
                }
            }
        }else if (barcode.startsWith("16")) {
            crnList.add(6);
@@ -280,13 +282,6 @@
        if (searchLocMasts.size() <= emptyInKeepLimit) {
            log.error(crnNo + "号堆垛机到达空库位预留上限!!! 尺寸规格: {}", JSON.toJSONString(locTypeDto));
            throw new CoolException(crnNo + "号堆垛机到达空库位预留上限!尺寸规格:" + (locTypeDto.getLocType1() == 1 ? "高" : "低"));
        }
        if (crnNo == 1) {
            if (wrkMasts.size() >= 1) {
                log.error(crnNo + "号堆垛机已达到入库控制上限!!! 任务数量: {}, 控制数量:{}", wrkMasts.size(), 1);
                throw new CoolException(crnNo + "号堆垛机已达到入库控制上限!");
            }
        }
        LocMast locMast = null;
@@ -504,6 +499,18 @@
                    break;
                }
            }
            if(targetLocMast == null) {
                //深库位找完都没找到,直接找浅库位
                for (LocMast locMast : locMastsList) {
                    if (!VersionUtils.locMoveCheckLocTypeComplete(locMast, locTypeDto)) {
                        continue;
                    }
                    //空库位直接选择
                    targetLocMast = locMast;
                }
            }
        }
        return targetLocMast;