From 6004efd6f95e26c718325675adcac6149c21b392 Mon Sep 17 00:00:00 2001
From: zwl <zwl123456>
Date: 星期四, 11 九月 2025 15:19:11 +0800
Subject: [PATCH] U8订单对接完成(需正式账套)
---
src/main/java/com/zy/common/model/DetlDto.java | 87 ++++++++++++++++++++++++++++++++++++-------
1 files changed, 72 insertions(+), 15 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..8890207 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;
/**
@@ -12,13 +13,60 @@
@Data
public class DetlDto {
- private String orderNo;
+ /**
+ * 1锛氭甯� 0锛氬叧闂�
+ */
+ private Integer sts;
+ /**
+ * 琛屽彿
+ */
+ private String model;
+
+ /**
+ * 鐗╂枡缂栫爜
+ */
private String matnr;
+ /**
+ * 鐗╂枡缂栫爜
+ */
+ private String maktx;
+
+ /**
+ * 鐗规畩璇存槑
+ */
private String batch;
+ /**
+ * 瀹屾垚鏁伴噺
+ */
private Double anfme;
+
+ /**
+ * 瑙勬牸
+ */
+ private String specs;
+
+ /**
+ * 绔嬪簱婧愯揣浣嶏紙榛樿1-1锛�
+ */
+ private String sourceStaNo = "1-1";
+
+ /**
+ * 鐩爣璐т綅
+ */
+ private String locNo = "2-2";
+
+ /**
+ * 琛屼富閿�
+ */
+ private String memo;
+
+ private String orderNo;
+
+
+ private Double units;
public DetlDto() {
}
@@ -28,10 +76,22 @@
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, Double units) {
+ this.matnr = matnr;
+ this.batch = batch;
+ this.anfme = anfme;
+ this.units = units;
}
public DetlDto(String orderNo, String matnr, String batch, Double anfme) {
@@ -58,24 +118,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