自动化立体仓库 - WMS系统
#
LSH
2023-01-30 17dfda3a88e556fa9416f4597153495110aa2aa8
#
1个文件已修改
37 ■■■■■ 已修改文件
src/main/java/com/zy/common/service/CommonService.java 37 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/zy/common/service/CommonService.java
@@ -356,6 +356,19 @@
        // 2.无库位时,无视区域锁定,重新查找库位
        if (Cools.isEmpty(locMast)){
            List<LocMast> locMasts = locMastService.queryFreeLocMastEnd(curRow);
            int sign=curRow;
            while (true){
                if (locMasts.size()==0){
                    sign = getCurRow(sign);
                    if (sign != 0){
                        locMasts = locMastService.queryFreeLocMastEnd(sign);
                    }else {
                        break;
                    }
                }else {
                    break;
                }
            }
            for (LocMast locMast1 : locMasts){
                List<LocMast> locMasts1 = locMastService.queryFreeLocMastEnd0(locMast1.getBay1(), locMast1.getLev1(),locMast1.getRow1());
                Integer innermostRow = Utils.getInnermostRow(locMasts1.get(0).getLocNo());
@@ -417,4 +430,28 @@
        }
    }
    public int getCurRow(int curRow){
        switch (curRow){
            case 1:
            case 2:
            case 8:
            case 9:
            case 10:
            case 15:
            case 16:
            case 17:
                return curRow+1;
            case 5:
            case 6:
            case 7:
            case 13:
            case 14:
            case 20:
            case 21:
                return curRow-1;
            default:
                return 0;
        }
    }
}