自动化立体仓库 - WMS系统
lty
3 天以前 d907a822a940c7ec0fb7de0ca845472bda52229b
src/main/java/com/zy/common/model/DetlDto.java
@@ -20,6 +20,9 @@
    private String batch;
    private Double anfme;
    private Integer areaId;
    private String cartonLabel;
    public DetlDto() {
    }
@@ -38,6 +41,13 @@
        this.matnr = matnr;
        this.batch = batch;
        this.anfme = anfme;
    }
    public DetlDto(String matnr, String batch, Double anfme,String cartonLabel) {
        this.matnr = matnr;
        this.batch = batch;
        this.anfme = anfme;
        this.cartonLabel = cartonLabel;
    }
    public DetlDto(String orderNo, String matnr, String batch, Double anfme) {
@@ -66,7 +76,7 @@
    public static boolean has(List<DetlDto> detlDtos, DetlDto detlDto) {
        for (DetlDto dto : detlDtos) {
            if (dto.getMatnr().equals(detlDto.getMatnr()) && Cools.eq(dto.getBatch(), detlDto.getBatch())) {
            if (dto.getMatnr().equals(detlDto.getMatnr()) && Cools.eq(dto.getBatch(), detlDto.getBatch()) && Cools.eq(dto.getCartonLabel(), detlDto.getCartonLabel()) ) {
                return true;
            }
        }
@@ -85,4 +95,16 @@
        return null;
    }
    public static DetlDto find(List<DetlDto> detlDtos, String matnr, String batch,String cartonLabel) {
        if (Cools.isEmpty(matnr)) {
            return null;
        }
        for (DetlDto detlDto : detlDtos) {
            if (matnr.equals(detlDto.getMatnr()) && Cools.eq(batch, detlDto.getBatch()) && Cools.eq(cartonLabel, detlDto.getCartonLabel())) {
                return detlDto;
            }
        }
        return null;
    }
}