From cb0f1ad62453de82efea35e132b272928c37e2ca Mon Sep 17 00:00:00 2001
From: lty <876263681@qq.com>
Date: 星期四, 26 三月 2026 10:40:44 +0800
Subject: [PATCH] #
---
src/main/java/com/zy/common/model/DetlDto.java | 46 ++++++++++++++++++++++++++++++++--------------
1 files changed, 32 insertions(+), 14 deletions(-)
diff --git a/src/main/java/com/zy/common/model/DetlDto.java b/src/main/java/com/zy/common/model/DetlDto.java
index daf439e..4e85f58 100644
--- a/src/main/java/com/zy/common/model/DetlDto.java
+++ b/src/main/java/com/zy/common/model/DetlDto.java
@@ -4,6 +4,7 @@
import com.zy.asrs.entity.OrderDetl;
import lombok.Data;
+import java.util.List;
import java.util.Set;
/**
@@ -20,6 +21,13 @@
private Double anfme;
+ private String spec;
+
+ private String model;
+ private String unit;
+ private String planNo;
+ private String qcStatus;
+
public DetlDto() {
}
@@ -28,10 +36,23 @@
this.anfme = anfme;
}
+ public DetlDto(String matnr, String batch) {
+ this.matnr = matnr;
+ this.batch = batch;
+ }
+
public DetlDto(String matnr, String batch, Double anfme) {
this.matnr = matnr;
this.batch = batch;
this.anfme = anfme;
+ }
+
+ public DetlDto(String matnr, String batch, Double anfme,String qcStatus,String planNo) {
+ this.matnr = matnr;
+ this.batch = batch;
+ this.anfme = anfme;
+ this.qcStatus = qcStatus;
+ this.planNo = planNo;
}
public DetlDto(String orderNo, String matnr, String batch, Double anfme) {
@@ -58,24 +79,21 @@
return false;
}
- public static DetlDto find(Set<DetlDto> detlDtos, String matnr, String batch) {
+ 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())) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ public static DetlDto find(List<DetlDto> detlDtos, String matnr, String batch) {
if (Cools.isEmpty(matnr)) {
return null;
}
for (DetlDto detlDto : detlDtos) {
- if (!matnr.equals(detlDto.getMatnr())) {
- continue;
- }
- if (Cools.isEmpty(batch) && Cools.isEmpty(detlDto.getBatch())) {
- return detlDto;
- }
- if (Cools.isEmpty(batch) && !Cools.isEmpty(detlDto.getBatch())) {
- continue;
- }
- if (Cools.isEmpty(detlDto.getBatch()) && !Cools.isEmpty(batch)) {
- continue;
- }
- if (batch.equals(detlDto.getBatch())) {
+ if (matnr.equals(detlDto.getMatnr()) && Cools.eq(batch, detlDto.getBatch())) {
return detlDto;
}
}
--
Gitblit v1.9.1