自动化立体仓库 - WMS系统
#
ytfl
3 天以前 52d8ce519ff385881000b31004d0252561232fa2
src/main/java/com/zy/common/model/DetlDto.java
@@ -21,6 +21,7 @@
    private String remark;
    private String batch = "";
    private String brand = "";
    private String standby1 = "";
@@ -34,6 +35,14 @@
    private String boxType3 = "";
    private Double anfme;
    private Double weight;
    //退库组托
    private String tkFlag;
    //库存状态
    private String cstateid;
    public DetlDto() {
    }
@@ -197,6 +206,29 @@
    }
    public static boolean has(List<DetlDto> detlDtos, DetlDto detlDto) {
        if (detlDto.getOrderNo() != null) {
            return hasByOrderNo(detlDtos, detlDto);
        }else {
            return hasNormal(detlDtos, detlDto);
        }
    }
    public static boolean hasByOrderNo(List<DetlDto> detlDtos, DetlDto detlDto) {
        for (DetlDto dto : detlDtos) {
            if (dto.getMatnr().equals(detlDto.getMatnr()) && Cools.eq(dto.getBatch(), detlDto.getBatch())
                    && Cools.eq(dto.getBrand(), detlDto.getBrand()) && Cools.eq(dto.getStandby1(), detlDto.getStandby1())
                    && Cools.eq(dto.getStandby2(), detlDto.getStandby2()) && Cools.eq(dto.getStandby3(), detlDto.getStandby3())
                    && Cools.eq(dto.getBoxType1(), detlDto.getBoxType1()) && Cools.eq(dto.getBoxType2(), detlDto.getBoxType2())
                    && Cools.eq(dto.getBoxType3(), detlDto.getBoxType3())) {
                if (dto.getOrderNo().equals(detlDto.getOrderNo())){
                    return true;
                }
            }
        }
        return false;
    }
    public static boolean hasNormal(List<DetlDto> detlDtos, DetlDto detlDto) {
        for (DetlDto dto : detlDtos) {
            if (dto.getMatnr().equals(detlDto.getMatnr()) && Cools.eq(dto.getBatch(), detlDto.getBatch())
                    && Cools.eq(dto.getBrand(), detlDto.getBrand()) && Cools.eq(dto.getStandby1(), detlDto.getStandby1())
@@ -262,7 +294,8 @@
        }
        for (DetlDto detlDto : detlDtos) {
            if (detlDtoB.getMatnr().equals(detlDto.getMatnr()) && Cools.eq(detlDtoB.getBatch(), detlDto.getBatch())
                    && detlDtoB.getBrand().equals(detlDto.getBrand()) && detlDtoB.getStandby1().equals(detlDto.getStandby1())
//                    && detlDtoB.getBrand().equals(detlDto.getBrand())
                    && detlDtoB.getStandby1().equals(detlDto.getStandby1())
                    && detlDtoB.getStandby2().equals(detlDto.getStandby2()) && detlDtoB.getStandby3().equals(detlDto.getStandby3())
                    && detlDtoB.getBoxType1().equals(detlDto.getBoxType1()) && detlDtoB.getBoxType2().equals(detlDto.getBoxType2())
                    && detlDtoB.getBoxType3().equals(detlDto.getBoxType3())) {