自动化立体仓库 - WMS系统
pang.jiabao
2 天以前 a1dd6ff24f7cae0b529ad313ba07351c07965605
src/main/java/com/zy/system/entity/SaasLog.java
@@ -5,6 +5,8 @@
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
import com.core.common.Cools;
import com.core.common.SpringUtils;
import com.zy.system.service.UserService;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
@@ -27,7 +29,7 @@
    private Long id;
    /**
     * {0:入库,1:出库}
     * {0:入库,1:出库,2.调拨入,3.调拨出,4.领料出}
     */
    @ApiModelProperty(value= "{0:入库,1:出库}")
    private Integer type;
@@ -81,19 +83,33 @@
        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.ioTime);
    }
    public String getType$(){
        if (this.type ==0) {
            return "入库";
           } else if (this.type == 1) {
            return "出库";
        } else if (this.type == 2) {
            return "库位移转";
        } else if (this.type == 3) {
            return "库存调整";
        }else {
            return "";
    /**
     * {0:入库,1:出库,2.调拨入,3.调拨出,4.领料出}
     */
    public String getType$() {
        switch (this.type) {
            case 0:
                return "入库";
            case 1:
                return "出库";
            case 2:
                return "调拨入";
            case 3:
                return "调拨出";
            case 4:
                return "领料出";
            default:
                return "";
        }
    }
    public String getCreateBy$(){
        UserService service = SpringUtils.getBean(UserService.class);
        User user = service.selectById(this.createBy);
        if (!Cools.isEmpty(user)){
            return String.valueOf(user.getUsername());
        }
        return null;
    }