1
4 天以前 9a3f96bae11e9d4303474996e7097e079649f376
rsf-server/src/main/java/com/vincent/rsf/server/api/service/impl/AgvServiceImpl.java
@@ -269,6 +269,8 @@
            if (!matches) {
                throw new CoolException("条码与站点不匹配");
            }
        } else {
            throw new CoolException("数据异常:验证基础信息");
        }
        return basStation;
@@ -319,8 +321,8 @@
            for (BasContainer container : containers) {
                String codeType = container.getCodeType();  // 获取正则表达式
                if (barcode.matches(codeType)) {  // 判断条码是否符合这个正则
                    List<String> areaList2 = JSONObject.parseArray(container.getAreas(), String.class);
                    if (!areaList2.contains(area)) {
                    List<Integer> areaList2 = container.getAreas();
                    if (!areaList2.contains(Integer.valueOf(area))) {
                        matches2 = false;
                        continue;
                    }
@@ -331,12 +333,14 @@
//            boolean matches = containers.stream()
//                    .map(BasContainer::getCodeType)
//                    .anyMatch(codeType -> barcode.matches(codeType));
            if (!matches) {
                throw new CoolException("条码与站点不匹配");
            }
            if (!matches2) {
                throw new CoolException("查询到的容器不支持目标库区");
            }
            if (!matches) {
                throw new CoolException("容器与站点不匹配");
            }
        } else {
            throw new CoolException("数据异常:验证基础信息");
        }
        return basStation;