From 03af32fb651a4a8046a6380dad84d20d731a9ffe Mon Sep 17 00:00:00 2001
From: dbs <email0099@163.com>
Date: 星期一, 23 十二月 2024 14:21:18 +0800
Subject: [PATCH] 修改组成MES的格式
---
src/main/java/com/itstyle/mdm/utils/MdmApiUtils.java | 35 ++++++++++++++---------------------
1 files changed, 14 insertions(+), 21 deletions(-)
diff --git a/src/main/java/com/itstyle/mdm/utils/MdmApiUtils.java b/src/main/java/com/itstyle/mdm/utils/MdmApiUtils.java
index db3840e..13f452b 100644
--- a/src/main/java/com/itstyle/mdm/utils/MdmApiUtils.java
+++ b/src/main/java/com/itstyle/mdm/utils/MdmApiUtils.java
@@ -165,28 +165,21 @@
JSONObject rowObject = jsonArray.getJSONObject(i);
JSONObject tmp1=new JSONObject();
tmp1.put("Tgcoriginalcode",rowObject.getString("tgctwoclasscode"));
- JSONObject tmp2=new JSONObject();
- tmp2.put("Code",rowObject.getString("code"));
- JSONObject tmp3=new JSONObject();
- tmp3.put("Name",rowObject.getString("name"));
- JSONObject tmp4=new JSONObject();
- tmp4.put("Specification",rowObject.getString("specification"));
- JSONObject tmp5=new JSONObject();
- tmp5.put("UnitName",rowObject.getString("unitName"));
- JSONObject tmp6=new JSONObject();
- tmp6.put("TypeCode",rowObject.getString("typeCode"));
- JSONObject tmp7=new JSONObject();
- tmp7.put("SpecificationDisplayName",rowObject.getString("specificationDisplayName"));
- JSONObject tmp8=new JSONObject();
- tmp8.put("SupplierName",rowObject.getString("supplierName"));
+
+ tmp1.put("Code",rowObject.getString("code"));
+
+ tmp1.put("Name",rowObject.getString("name"));
+
+ tmp1.put("Specification",rowObject.getString("specification"));
+
+ tmp1.put("UnitName",rowObject.getString("unitName"));
+
+ tmp1.put("TypeCode",rowObject.getString("typeCode"));
+
+ tmp1.put("SpecificationDisplayName",rowObject.getString("specificationDisplayName"));
+
+ tmp1.put("SupplierName",rowObject.getString("supplierName"));
mesResDetail.add(tmp1);
- mesResDetail.add(tmp2);
- mesResDetail.add(tmp3);
- mesResDetail.add(tmp4);
- mesResDetail.add(tmp5);
- mesResDetail.add(tmp6);
- mesResDetail.add(tmp7);
- mesResDetail.add(tmp8);
}
mesResJson.put("Records",mesResDetail);
return mesResJson.toJSONString();
--
Gitblit v1.8.0