From 75b207b2b53a89286dfb1515d47da25c3415fc9b Mon Sep 17 00:00:00 2001
From: Junjie <fallin.jie@qq.com>
Date: 星期二, 23 五月 2023 15:38:31 +0800
Subject: [PATCH] 指令创建和状态更新

---
 src/main/java/com/zy/asrs/entity/WmsWrk.java |   61 +++++++++++-------------------
 1 files changed, 22 insertions(+), 39 deletions(-)

diff --git a/src/main/java/com/zy/asrs/entity/WmsWrk.java b/src/main/java/com/zy/asrs/entity/WmsWrk.java
index ac4efbb..08ca061 100644
--- a/src/main/java/com/zy/asrs/entity/WmsWrk.java
+++ b/src/main/java/com/zy/asrs/entity/WmsWrk.java
@@ -10,37 +10,16 @@
 import org.springframework.format.annotation.DateTimeFormat;
 import com.core.common.SpringUtils;
 import com.zy.asrs.service.BasWrkIotypeService;
-import com.zy.asrs.entity.BasWrkIotype;
-import com.core.common.SpringUtils;
-import com.zy.asrs.service.BasCrnpService;
-import com.zy.asrs.entity.BasCrnp;
-import com.core.common.SpringUtils;
 import com.zy.asrs.service.LocMastService;
-import com.zy.asrs.entity.LocMast;
-import com.core.common.SpringUtils;
 import com.zy.asrs.service.BasDevpService;
-import com.zy.asrs.entity.BasDevp;
-import com.core.common.SpringUtils;
-import com.zy.asrs.service.BasDevpService;
-import com.zy.asrs.entity.BasDevp;
-import com.core.common.SpringUtils;
-import com.zy.asrs.service.LocMastService;
-import com.zy.asrs.entity.LocMast;
-import com.core.common.SpringUtils;
 import com.zy.system.service.UserService;
 import com.zy.system.entity.User;
-import java.text.SimpleDateFormat;
-import java.util.Date;
-import com.core.common.SpringUtils;
-import com.zy.system.service.UserService;
-import com.zy.system.entity.User;
-import java.text.SimpleDateFormat;
-import java.util.Date;
 
 import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
 import com.baomidou.mybatisplus.annotations.TableName;
 import java.io.Serializable;
+import java.util.List;
 
 @Data
 @TableName("wcs_wms_wrk")
@@ -121,17 +100,11 @@
     private String sourceLocNo;
 
     /**
-     * 搴撲綅鐘舵��
+     * 鏉$爜
      */
-    @ApiModelProperty(value= "搴撲綅鐘舵��")
-    @TableField("loc_sts")
-    private String locSts;
-
-    /**
-     * 鎷f枡(checkBox)
-     */
-    @ApiModelProperty(value= "鎷f枡(checkBox)")
-    private String picking;
+    @ApiModelProperty(value= "鏉$爜")
+    @TableField("barcode")
+    private String barcode;
 
     /**
      * 淇敼浜哄憳
@@ -170,15 +143,16 @@
     private String memo;
 
     /**
-     * 鏉$爜
+     * 缁撴潫鏃堕棿
      */
-    @ApiModelProperty(value= "鏉$爜")
-    @TableField("barcode")
-    private String barcode;
+    @ApiModelProperty(value= "缁撴潫鏃堕棿")
+    @TableField("end_time")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    private Date endTime;
 
     public WmsWrk() {}
 
-    public WmsWrk(Integer wmsWrkNo, Integer wmsStatus, Integer wrkNo, Date createTime, Integer ioType, Double ioPri, String locNo, Integer staNo, Integer sourceStaNo, String sourceLocNo, String locSts, String picking, Long modiUser, Date modiTime, Long appeUser, Date appeTime, String memo, String barcode) {
+    public WmsWrk(Integer wmsWrkNo, Integer wmsStatus, Integer wrkNo, Date createTime, Integer ioType, Double ioPri, String locNo, Integer staNo, Integer sourceStaNo, String sourceLocNo, Long modiUser, Date modiTime, Long appeUser, Date appeTime, String memo, String barcode, Date endTime) {
         this.wmsWrkNo = wmsWrkNo;
         this.wmsStatus = wmsStatus;
         this.wrkNo = wrkNo;
@@ -189,14 +163,13 @@
         this.staNo = staNo;
         this.sourceStaNo = sourceStaNo;
         this.sourceLocNo = sourceLocNo;
-        this.locSts = locSts;
-        this.picking = picking;
         this.modiUser = modiUser;
         this.modiTime = modiTime;
         this.appeUser = appeUser;
         this.appeTime = appeTime;
         this.memo = memo;
         this.barcode = barcode;
+        this.endTime = endTime;
     }
 
 //    WmsWrk wmsWrk = new WmsWrk(
@@ -309,6 +282,13 @@
         return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.appeTime);
     }
 
+    public String getEndTime$(){
+        if (Cools.isEmpty(this.endTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.endTime);
+    }
+
     /**
      * 鑾峰彇鎸佺画鏃堕棿
      */
@@ -318,6 +298,9 @@
         }
 
         Date endDate = new Date();
+        if (!Cools.isEmpty(this.endTime)) {
+            endDate = this.endTime;
+        }
 
         //鐢ㄦ潵鑾峰彇涓や釜鏃堕棿鐩稿樊鐨勬绉掓暟
         long l = this.createTime.getTime() - endDate.getTime();

--
Gitblit v1.9.1