package com.zy.asrs.common.wms.entity; import java.text.SimpleDateFormat; import java.util.Date; import org.springframework.format.annotation.DateTimeFormat; import java.text.SimpleDateFormat; import java.util.Date; import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableLogic; import com.baomidou.mybatisplus.annotation.TableName; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Data; import com.zy.asrs.framework.common.Cools; import com.zy.asrs.framework.common.SpringUtils; import com.zy.asrs.common.sys.entity.User; import com.zy.asrs.common.sys.entity.Host; import com.zy.asrs.common.sys.service.UserService; import com.zy.asrs.common.sys.service.HostService; import java.io.Serializable; import java.util.Date; @Data @TableName("wms_loc_rule") public class LocRule implements Serializable { private static final long serialVersionUID = 1L; @ApiModelProperty(value= "") @TableId(value = "id", type = IdType.AUTO) private Long id; @ApiModelProperty(value= "") private String matnr; @ApiModelProperty(value= "") private String specs; @ApiModelProperty(value= "") private String model; @ApiModelProperty(value= "") private String cstmr; @ApiModelProperty(value= "") private String batch; @ApiModelProperty(value= "") private String other; @ApiModelProperty(value= "") private Integer rowBeg; @ApiModelProperty(value= "") private Integer rowEnd; @ApiModelProperty(value= "") private Integer bayBeg; @ApiModelProperty(value= "") private Integer bayEnd; @ApiModelProperty(value= "") private Integer levBeg; @ApiModelProperty(value= "") private Integer levEnd; @ApiModelProperty(value= "") private Integer limit; @ApiModelProperty(value= "") private Integer status; @ApiModelProperty(value= "") private Long createBy; @ApiModelProperty(value= "") @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") private Date createTime; @ApiModelProperty(value= "") private Long updateBy; @ApiModelProperty(value= "") @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") private Date updateTime; @ApiModelProperty(value= "") private String memo; /** * 是否支持混载 0: 不支持 1: 支持 */ @ApiModelProperty(value= "是否支持混载 0: 不支持 1: 支持 ") private Short mixed; /** * 支持混载情况下,没找到库位是否继续寻找 0: 否 1: 是 */ @ApiModelProperty(value= "支持混载情况下,没找到库位是否继续寻找 0: 否 1: 是 ") private Short keepGo; /** * 仓库ID */ @ApiModelProperty(value= "仓库ID") private Long hostId; public LocRule() {} public LocRule(String matnr,String specs,String model,String cstmr,String batch,String other,Integer rowBeg,Integer rowEnd,Integer bayBeg,Integer bayEnd,Integer levBeg,Integer levEnd,Integer limit,Integer status,Long createBy,Date createTime,Long updateBy,Date updateTime,String memo,Short mixed,Short keepGo) { this.matnr = matnr; this.specs = specs; this.model = model; this.cstmr = cstmr; this.batch = batch; this.other = other; this.rowBeg = rowBeg; this.rowEnd = rowEnd; this.bayBeg = bayBeg; this.bayEnd = bayEnd; this.levBeg = levBeg; this.levEnd = levEnd; this.limit = limit; this.status = status; this.createBy = createBy; this.createTime = createTime; this.updateBy = updateBy; this.updateTime = updateTime; this.memo = memo; this.mixed = mixed; this.keepGo = keepGo; } // LocRule locRule = new LocRule( // null, // // null, // // null, // // null, // // null, // // null, // // null, // // null, // // null, // // null, // // null, // // null, // // null, // // null, // // null, // // null, // // null, // // null, // // null, // // null, // 是否支持混载 // null // 支持混载情况下,没找到库位是否继续寻找 // ); public String getCreateTime$(){ if (Cools.isEmpty(this.createTime)){ return ""; } return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.createTime); } public String getUpdateTime$(){ if (Cools.isEmpty(this.updateTime)){ return ""; } return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.updateTime); } public String getMixed$(){ if (null == this.mixed){ return null; } switch (this.mixed){ case 0: return "不支持"; case 1: return "支持"; default: return String.valueOf(this.mixed); } } public String getKeepGo$(){ if (null == this.keepGo){ return null; } switch (this.keepGo){ case 0: return "否"; case 1: return "是"; default: return String.valueOf(this.keepGo); } } }