自动化立体仓库 - WMS系统
#
zwl
2 天以前 7aba2103c4b3ea72e8e0fd79dc88be0e251c1c33
src/main/java/com/zy/asrs/task/handler/AutomaticallyIssueWCSTasksHandler.java
@@ -48,6 +48,12 @@
            for (WrkMast m : wrkMast) {
                if (m == null) { continue; }
                if (Objects.equals(m.getWrkSts(), 11L)) {
                    if ("Y".equalsIgnoreCase(m.getPauseMk())) {
                        continue;
                    }
                    if (requiresOutboundErpConfirm(m) && !"Y".equalsIgnoreCase(m.getPdcType())) {
                        continue;
                    }
                    if (m.getUpdMk() != null && "WCS_SENT".equalsIgnoreCase(m.getUpdMk())) {
                        continue;
                    }
@@ -85,8 +91,11 @@
                    if (m.getIoPri() != null) {
                        t.put("taskPri", m.getIoPri().intValue());
                    }
                    t.put("batchSeq", m.getPltType());
                    if (m.getUserNo() != null) {
                    // 7.11:seq=0 表示无序,WCS 下发不传 batch 和 batchSeq。
                    if (m.getPltType() != null && m.getPltType() > 0) {
                        t.put("batchSeq", m.getPltType());
                    }
                    if (m.getPltType() != null && m.getPltType() > 0 && m.getUserNo() != null) {
                        t.put("batch", m.getUserNo());
                    }
                    tasks.add(t);
@@ -136,4 +145,9 @@
        }
        return SUCCESS;
    }
    private boolean requiresOutboundErpConfirm(WrkMast wrkMast) {
        Integer ioType = wrkMast == null ? null : wrkMast.getIoType();
        return ioType != null && (ioType == 101 || ioType == 103 || ioType == 104 || ioType == 107 || ioType == 110);
    }
}