From 45d602719964509214d06ec5173f23e5307d5dfe Mon Sep 17 00:00:00 2001
From: zyx <zyx123456>
Date: 星期二, 16 四月 2024 12:24:10 +0800
Subject: [PATCH] 无空库位时,不做空板入库操作

---
 src/main/java/com/zy/asrs/entity/WrkDetl.java |   58 ++++++++++++++++++++--------------------------------------
 1 files changed, 20 insertions(+), 38 deletions(-)

diff --git a/src/main/java/com/zy/asrs/entity/WrkDetl.java b/src/main/java/com/zy/asrs/entity/WrkDetl.java
index bd1f873..ae755c0 100644
--- a/src/main/java/com/zy/asrs/entity/WrkDetl.java
+++ b/src/main/java/com/zy/asrs/entity/WrkDetl.java
@@ -4,15 +4,12 @@
 import com.baomidou.mybatisplus.annotations.TableName;
 import com.core.common.Cools;
 import com.core.common.SpringUtils;
-import com.core.exception.CoolException;
+import com.zy.common.utils.Synchro;
 import com.zy.system.entity.User;
 import com.zy.system.service.UserService;
 import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
 
-import java.beans.BeanInfo;
-import java.beans.Introspector;
-import java.beans.PropertyDescriptor;
 import java.io.Serializable;
 import java.text.SimpleDateFormat;
 import java.util.Date;
@@ -52,19 +49,19 @@
     /**
      * 鐗╂枡
      */
-    @ApiModelProperty(value= "鍟嗗搧缂栧彿")
+    @ApiModelProperty(value= "鐗╂枡鍙�")
     private String matnr;
 
     /**
      * 鐗╂枡鎻忚堪
      */
-    @ApiModelProperty(value= "鍟嗗搧鍚嶇О")
+    @ApiModelProperty(value= "鐗╂枡鍙�")
     private String maktx;
 
     /**
-     * 鎵瑰彿
+     * 搴忓垪鐮�
      */
-    @ApiModelProperty(value= "鎵瑰彿")
+    @ApiModelProperty(value= "搴忓垪鐮�")
     private String batch;
 
     /**
@@ -81,9 +78,9 @@
     private String specs;
 
     /**
-     * 鍨嬪彿
+     * 鎵规
      */
-    @ApiModelProperty(value= "鍨嬪彿")
+    @ApiModelProperty(value= "鎵规")
     private String model;
 
     /**
@@ -117,9 +114,9 @@
     private String sku;
 
     /**
-     * 鍗曚綅閲�
+     * 鍖呮暟
      */
-    @ApiModelProperty(value= "鍗曚綅閲�")
+    @ApiModelProperty(value= "鍖呮暟")
     private Double units;
 
     /**
@@ -129,9 +126,9 @@
     private String barcode;
 
     /**
-     * 浜у湴
+     * 鐗╂枡鐘舵��
      */
-    @ApiModelProperty(value= "浜у湴")
+    @ApiModelProperty(value= "鐗╂枡鐘舵��")
     private String origin;
 
     /**
@@ -141,9 +138,9 @@
     private String manu;
 
     /**
-     * 鐢熶骇鏃ユ湡
+     * 鍗曟嵁鏃堕棿
      */
-    @ApiModelProperty(value= "鐢熶骇鏃ユ湡")
+    @ApiModelProperty(value= "鍗曟嵁鏃堕棿")
     @TableField("manu_date")
     private String manuDate;
 
@@ -230,7 +227,7 @@
      * 瑕佹眰妫�楠� 1: 鏄�  0: 鍚�
      */
     @ApiModelProperty(value= "瑕佹眰妫�楠� 1: 鏄�  0: 鍚�  ")
-    private Integer check;
+    private Integer inspect;
 
     /**
      * 鍗遍櫓鍝� 1: 鏄�  0: 鍚�
@@ -305,15 +302,15 @@
         }
     }
 
-    public String getCheck$(){
-        if (null == this.check){ return null; }
-        switch (this.check){
+    public String getInspect$(){
+        if (null == this.inspect){ return null; }
+        switch (this.inspect){
             case 1:
                 return "鏄�";
             case 0:
                 return "鍚�";
             default:
-                return String.valueOf(this.check);
+                return String.valueOf(this.inspect);
         }
     }
 
@@ -361,23 +358,8 @@
         return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.appeTime);
     }
 
-    public void sync(Object dest) {
-        try {
-            BeanInfo sourceBean = Introspector.getBeanInfo(this.getClass(),Object.class);
-            PropertyDescriptor[] sourceProperty = sourceBean.getPropertyDescriptors();
-            BeanInfo destBean = Introspector.getBeanInfo(dest.getClass(),Object.class);
-            PropertyDescriptor[] destProperty = destBean.getPropertyDescriptors();
-            for (PropertyDescriptor propertyDescriptor : sourceProperty) {
-                for (PropertyDescriptor descriptor : destProperty) {
-                    if (propertyDescriptor.getName().equals(descriptor.getName()) && propertyDescriptor.getPropertyType() == descriptor.getPropertyType()) {
-                        descriptor.getWriteMethod().invoke(dest, propertyDescriptor.getReadMethod().invoke(this));
-                        break;
-                    }
-                }
-            }
-        } catch (Exception e) {
-            throw new CoolException("灞炴�у鍒跺け璐�:" + e.getMessage());
-        }
+    public void sync(Object source) {
+        Synchro.Copy(source, this);
     }
 
 }

--
Gitblit v1.9.1