package com.ruoyi.app.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 【请填写功能名称】对象 app_wcs_task
 *
 * @author ruoyi
 * @date 2025-01-15
 */
public class AppWcsTask extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** wcs任务号 */
    private String wcsTaskId;

    /** wcs任务状态 */
    @Excel(name = "wcs任务状态")
    private Integer wcsTaskStatus;

    /** 任务类型 */
    @Excel(name = "任务类型")
    private Integer wcsTaskType;

    /** 任务优先级 */
    @Excel(name = "任务优先级")
    private Integer taskPriority;

    /** 载具号 */
    @Excel(name = "载具号")
    private String vehicleId;

    /** 起点 */
    @Excel(name = "起点")
    private String origin;

    /** 终点 */
    @Excel(name = "终点")
    private String destination;

    /** 下发时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "下发时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date sendTime;

    /** 完成时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "完成时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date finishTime;

    public void setWcsTaskId(String wcsTaskId)
    {
        this.wcsTaskId = wcsTaskId;
    }

    public String getWcsTaskId()
    {
        return wcsTaskId;
    }
    public void setWcsTaskStatus(Integer wcsTaskStatus)
    {
        this.wcsTaskStatus = wcsTaskStatus;
    }

    public Integer getWcsTaskStatus()
    {
        return wcsTaskStatus;
    }
    public void setWcsTaskType(Integer wcsTaskType)
    {
        this.wcsTaskType = wcsTaskType;
    }

    public Integer getWcsTaskType()
    {
        return wcsTaskType;
    }
    public void setTaskPriority(Integer taskPriority)
    {
        this.taskPriority = taskPriority;
    }

    public Integer getTaskPriority()
    {
        return taskPriority;
    }
    public void setVehicleId(String vehicleId)
    {
        this.vehicleId = vehicleId;
    }

    public String getVehicleId()
    {
        return vehicleId;
    }
    public void setOrigin(String origin)
    {
        this.origin = origin;
    }

    public String getOrigin()
    {
        return origin;
    }
    public void setDestination(String destination)
    {
        this.destination = destination;
    }

    public String getDestination()
    {
        return destination;
    }
    public void setSendTime(Date sendTime)
    {
        this.sendTime = sendTime;
    }

    public Date getSendTime()
    {
        return sendTime;
    }
    public void setFinishTime(Date finishTime)
    {
        this.finishTime = finishTime;
    }

    public Date getFinishTime()
    {
        return finishTime;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
                .append("wcsTaskId", getWcsTaskId())
                .append("wcsTaskStatus", getWcsTaskStatus())
                .append("wcsTaskType", getWcsTaskType())
                .append("taskPriority", getTaskPriority())
                .append("vehicleId", getVehicleId())
                .append("origin", getOrigin())
                .append("destination", getDestination())
                .append("createTime", getCreateTime())
                .append("sendTime", getSendTime())
                .append("finishTime", getFinishTime())
                .append("remark", getRemark())
                .toString();
    }

    /**
     * wcs任务类转化为记录类
     * @return 记录
     */
    public AppWcsTaskBak toAppWcsTaskBak() {
        AppWcsTaskBak appWcsTaskBak = new AppWcsTaskBak();
        appWcsTaskBak.setWcsTaskId(getWcsTaskId());
        appWcsTaskBak.setWcsTaskStatus(getWcsTaskStatus());
        appWcsTaskBak.setWcsTaskType(getWcsTaskType());
        appWcsTaskBak.setTaskPriority(getTaskPriority());
        appWcsTaskBak.setVehicleId(getVehicleId());
        appWcsTaskBak.setOrigin(getOrigin());
        appWcsTaskBak.setDestination(getDestination());
        appWcsTaskBak.setSendTime(getSendTime());
        appWcsTaskBak.setFinishTime(getFinishTime());
        appWcsTaskBak.setRemark(getRemark());
        return appWcsTaskBak;
    }
}
