自动化立体仓库 - WMS系统
zyx
2024-05-27 cd8ab30f720cd8ab32062024b00c7fe3294a56a4
src/main/java/com/zy/asrs/task/handler/AgvWrkMastHandler.java
@@ -71,11 +71,12 @@
        // 空板入库 设置库位状态为D.空桶/空栈板
        String locSts = agvWrkMast.getIoType() == 10 ? "D" : "F";
        if (agvWrkMast.getIoType() == 10 || agvWrkMast.getIoType() == 109) {
            if (agvWrkMast.getIoType() == 109 && agvWrkMast.getLocNo().substring(0,2).equals("DB")) {
                agvBasDevpService.updateLocStsAndBarcodeByDevNo(agvWrkMast.getLocNo(),"R",agvWrkMast.getBarcode(),agvWrkMast.getWhsType().shortValue());
            } else {
                agvLocMastService.updateLocStsByLocNo(agvWrkMast.getLocNo(),"D",agvWrkMast.getBarcode(),agvWrkMast.getWhsType().shortValue());
            }
            //if (agvWrkMast.getIoType() == 109 && agvWrkMast.getLocNo().substring(0,2).equals("DB")) {
            //    agvBasDevpService.updateLocStsAndBarcodeByDevNo(agvWrkMast.getLocNo(),"R",agvWrkMast.getBarcode(),agvWrkMast.getWhsType().shortValue());
            //} else {
            //    agvLocMastService.updateLocStsByLocNo(agvWrkMast.getLocNo(),"D",agvWrkMast.getBarcode(),agvWrkMast.getWhsType().shortValue());
            //}
            agvLocMastService.updateLocStsByLocNo(agvWrkMast.getLocNo(),"D",agvWrkMast.getBarcode(),agvWrkMast.getWhsType().shortValue());
        } else {
            agvLocMastService.updateLocStsByLocNo(agvWrkMast.getLocNo(),"F",agvWrkMast.getBarcode(),agvWrkMast.getWhsType().shortValue());
        }
@@ -112,11 +113,15 @@
        }
        if(agvWrkMast.getIoType() == 109){
            //修改源库位状态为O
            agvLocMastService.updateLocStsByLocNo(agvWrkMast.getSourceLocNo(),"O","",agvWrkMast.getWhsType().shortValue(),"",(short)0);
            // 新建工作档
            Date now = new Date();
            createWrkMast(109, 201L, agvWrkMast.getLocNo(), "", agvWrkMast.getBarcode(), now, 9527L, agvWrkMast.getWhsType(), 0);
            if (agvWrkMast.getSourceLocNo().substring(0,2).equals("DB")) {
                agvBasDevpService.updateLocStsAndBarcodeByDevNo(agvWrkMast.getSourceLocNo(),"O","",(short)0);
            } else {
                //修改源库位状态为O
                agvLocMastService.updateLocStsByLocNo(agvWrkMast.getSourceLocNo(),"O","",agvWrkMast.getWhsType().shortValue(),"",(short)0);
                // 新建工作档
                Date now = new Date();
                createWrkMast(109, 201L, agvWrkMast.getLocNo(), "", agvWrkMast.getBarcode(), now, 9527L, agvWrkMast.getWhsType(), 0);
            }
        }
        if (agvWrkMast.getIoType() == 58) {
            agvBasDevpService.updateLocStsAndBarcodeByDevNo(agvWrkMast.getSourceLocNo(),"O","",agvWrkMast.getWhsType().shortValue());
@@ -365,9 +370,9 @@
        wrkMast.setSourceLocNo(sourceLocNo);
        //目标站点
        wrkMast.setLocNo(locNo);
        //容器编码
        //货架编码
        wrkMast.setBarcode(barcode);
        //容器类型
        //货架类型
        wrkMast.setWhsType(containerType);
        // 目标楼层
        wrkMast.setCrnNo(floor);