自动化立体仓库 - WCS系统
Junjie
2023-05-22 ed2ea2b286ec963970e710a578cdb064cc8650d8
src/main/java/com/zy/asrs/entity/WrkMast.java
@@ -13,6 +13,7 @@
import com.zy.system.service.UserService;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.text.SimpleDateFormat;
@@ -315,6 +316,14 @@
    @TableField("wms_wrk_no")
    private Integer wmsWrkNo;
    /**
     * 结束时间
     */
    @ApiModelProperty(value= "结束时间")
    @TableField("end_time")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    private Date endTime;
    public String getWrkSts$(){
        BasWrkStatusMapper mapper = SpringUtils.getBean(BasWrkStatusMapper.class);
        BasWrkStatus entity = mapper.selectById(this.wrkSts);
@@ -491,6 +500,13 @@
        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.logErrTime);
    }
    public String getEndTime$(){
        if (Cools.isEmpty(this.endTime)){
            return "";
        }
        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.endTime);
    }
    /**
     * 获取持续时间
     */
@@ -500,6 +516,9 @@
        }
        Date endDate = new Date();
        if (!Cools.isEmpty(this.endTime)) {
            endDate = this.endTime;
        }
        //用来获取两个时间相差的毫秒数
        long l = this.ioTime.getTime() - endDate.getTime();