From b06233aa71b70f7a30ff382ae1ba19c29b134d7c Mon Sep 17 00:00:00 2001
From: zhou zhou <3272660260@qq.com>
Date: 星期五, 28 十一月 2025 15:41:51 +0800
Subject: [PATCH] #库存调整完成

---
 src/main/java/com/zy/asrs/entity/CheckOrderDetl.java |   40 +++++++++-------------------------------
 1 files changed, 9 insertions(+), 31 deletions(-)

diff --git a/src/main/java/com/zy/asrs/entity/CheckOrderDetl.java b/src/main/java/com/zy/asrs/entity/CheckOrderDetl.java
index c2f3e39..04afc24 100644
--- a/src/main/java/com/zy/asrs/entity/CheckOrderDetl.java
+++ b/src/main/java/com/zy/asrs/entity/CheckOrderDetl.java
@@ -3,6 +3,7 @@
 import com.core.common.Cools;import com.baomidou.mybatisplus.annotations.TableId;
 import com.baomidou.mybatisplus.enums.IdType;
 import com.core.common.SpringUtils;
+import com.zy.asrs.enums.CheckStatusEnum;
 import com.zy.asrs.service.OrderService;
 import com.zy.asrs.entity.Order;
 import com.baomidou.mybatisplus.annotations.TableField;
@@ -69,7 +70,8 @@
     private BigDecimal anfme;
 
     @ApiModelProperty(value= "")
-    private BigDecimal qty;
+    @TableField("diff_qty")
+    private BigDecimal diffQty;
 
     /**
      * 鍟嗗搧缂栫爜
@@ -257,7 +259,7 @@
     /**
      * 鐘舵�� 1: 鏈敓鎴�  0: 绂佺敤  2锛氬緟鐩�  3锛氬凡鐩�
      */
-    @ApiModelProperty(value= "鐘舵�� 1: 鏈敓鎴�  0: 绂佺敤  2锛氬緟鐩�  3锛氬凡鐩�")
+    @ApiModelProperty(value= "鐘舵�� 1: 鏈敓鎴�  0: 绂佺敤  2锛氬緟鐩�  3锛氬凡鐩�  4:鍏佽  5:绂佹 6锛氬凡淇敼")
     private Integer status;
 
     /**
@@ -389,11 +391,11 @@
 
     public CheckOrderDetl() {}
 
-    public CheckOrderDetl(Long orderId,String orderNo,BigDecimal anfme,BigDecimal qty,String matnr,String maktx,String batch,String specs,String model,String color,String brand,String unit,Double price,String sku,Double units,String barcode,String origin,String manu,String manuDate,String itemNum,Double safeQty,Double weight,Double manLength,Double volume,String threeCode,String supp,String suppCode,Integer beBatch,String deadTime,Integer deadWarn,Integer source,Integer inspect,Integer danger,Integer status,Long createBy,Date createTime,Long updateBy,Date updateTime,String memo,BigDecimal workQty,String qrCode,Date startDate,Date endDate,Integer pakinPakoutStatus,Long lineNumber,String locNo,Long version) {
+    public CheckOrderDetl(Long orderId,String orderNo,BigDecimal anfme,BigDecimal diffQty,String matnr,String maktx,String batch,String specs,String model,String color,String brand,String unit,Double price,String sku,Double units,String barcode,String origin,String manu,String manuDate,String itemNum,Double safeQty,Double weight,Double manLength,Double volume,String threeCode,String supp,String suppCode,Integer beBatch,String deadTime,Integer deadWarn,Integer source,Integer inspect,Integer danger,Integer status,Long createBy,Date createTime,Long updateBy,Date updateTime,String memo,BigDecimal workQty,String qrCode,Date startDate,Date endDate,Integer pakinPakoutStatus,Long lineNumber,String locNo,Long version) {
         this.orderId = orderId;
         this.orderNo = orderNo;
         this.anfme = anfme;
-        this.qty = qty;
+        this.diffQty = diffQty;
         this.matnr = matnr;
         this.maktx = maktx;
         this.batch = batch;
@@ -489,21 +491,6 @@
 //            null    // [闈炵┖]
 //    );
 
-    public BigDecimal getDiffQty() {
-        if (null == this.status || this.status == 1  ||  this.status == 0 ) {
-            return BigDecimal.ZERO;
-        }
-        if (null != this.anfme && this.workQty != null) {
-
-            BigDecimal subtract = new BigDecimal(this.workQty.toString()).subtract(new BigDecimal(this.anfme.toString()));
-
-            return subtract;
-        }
-//        if (null != this.anfme && this.qty != null) {
-//            return this.anfme - this.qty;
-//        }
-        return null;
-    }
 
     public String getOrderId$(){
         OrderService service = SpringUtils.getBean(OrderService.class);
@@ -566,18 +553,9 @@
 
     public String getStatus$(){
         if (null == this.status){ return null; }
-        switch (this.status){
-            case 1:
-                return "鏈敓鎴�";
-            case 0:
-                return "绂佺敤";
-            case 2:
-                return "寰呯洏";
-            case 3:
-                return "宸茬洏";
-            default:
-                return String.valueOf(this.status);
-        }
+        String descByType = CheckStatusEnum.getDescByType(this.status);
+        if (Cools.isEmpty(descByType)){ return "鏈畾涔�"; }
+        return descByType;
     }
 
     public String getCreateBy$(){

--
Gitblit v1.9.1