#
vincentlu
2025-12-19 19ff3f5b3bdfa903898a900be1ef387445f540fb
zy-acs-manager/src/main/java/com/zy/acs/manager/core/scheduler/AutoRunScheduler.java
@@ -322,21 +322,17 @@
        // STOCK
        List<Loc> stockLocList = locService.selectRandByLocSts(LocStsType.STOCK.val(), maxCapacity);
//        LambdaQueryWrapper<Loc> stockWrapper = new LambdaQueryWrapper<Loc>().eq(Loc::getLocSts, LocStsType.STOCK.val());
//        List<Loc> stockList = locService.list(stockWrapper);
//        if (Cools.isEmpty(stockList) || stockList.size() < agvModel.getBackpack()) {
//            return;
//        }
//        Collections.shuffle(stockList);
        if (Cools.isEmpty(stockLocList)) {
            return;
        }
        Collections.shuffle(stockLocList);
        // IDLE
        List<Loc> idleLocList = locService.selectRandByLocSts(LocStsType.IDLE.val(), maxCapacity);
//        LambdaQueryWrapper<Loc> idleWrapper = new LambdaQueryWrapper<Loc>().eq(Loc::getLocSts, LocStsType.IDLE.val());
//        List<Loc> idleList = locService.list(idleWrapper);
//        if (Cools.isEmpty(idleList)) {
//            return;
//        }
//        Collections.shuffle(idleList);
        if (Cools.isEmpty(idleLocList)) {
            return;
        }
        Collections.shuffle(idleLocList);
        OpenBusSubmitParam param = new OpenBusSubmitParam();
        param.setBatch(String.valueOf(snowflakeIdWorker.nextId()).substring(13, 19));
@@ -351,6 +347,7 @@
            param.getTaskList().add(taskDto);
        }
        if (Cools.isEmpty(param.getTaskList())) { return; }
        mainService.generateBusAndTask(param, memo);
    }