package com.sw.mes.plan.dto;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.sw.mes.enumvalue.EnumValuesFbServer;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.math.BigDecimal;
import java.util.Date;

/**
 * @Author
 * @Description：
 * @Date: Create in
 * @Modified By:
 */
@Data
@ApiModel(value = "方棒工单排程Dto")
public class ProductionScheduleDto {

    private Integer id;
    @ApiModelProperty(value = "炉次id")
    Integer sectionId;
    @ApiModelProperty(value = "炉次号")
    String sectionNo;
    @ApiModelProperty(value = "工单编号")
    String code;
    @ApiModelProperty(value = "设备id")
    Integer deviceId;
    @ApiModelProperty(value = "设备编号")
    String deviceNo;
    @ApiModelProperty(value = "任务状态(0：未开始,1：进行中,2：已完成,3：已取消)", required = true)
    Integer status;
    @ApiModelProperty(value = "状态信息")
    String statusInfo;
    @ApiModelProperty(value = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    Date createTime;
    @ApiModelProperty(value = "数量")
    Integer count;
    @ApiModelProperty(value = "创建人id")
    Integer createUserId;
    @ApiModelProperty(value = "创建人姓名")
    String createUserName;
    @ApiModelProperty(value = "设备类别")
    Integer category;
    @ApiModelProperty(value = "加工能力编码")
    Integer capacityId;

    /**
     * 任务状态名称
     */
    @ApiModelProperty(value = "状态信息")
    String statusName;

    public String getStatusName() {
        return EnumValuesFbServer.ProductionScheduleStatus.getText(this.status);
    }

    @ApiModelProperty(value = "订单编号")
    String productionOrderAufnr;

    @ApiModelProperty(value = "订单类型")
    String productionOrderAuart;

    @ApiModelProperty(value = "计划开始时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    Date productionOrderGstrp;

    @ApiModelProperty(value = "计划结束时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    Date productionOrderGltrp;

    @ApiModelProperty(value = "客户")
    String productionOrderCustom;

    @ApiModelProperty(value = "研发唯一标识")
    String productionOrderRdonlylogo;

    @ApiModelProperty(value = "订单定向标识")
    String productionOrderZorientationind;

    @ApiModelProperty(value = "物料号")
    String fbProductModelCode;

    @ApiModelProperty(value = "物料名称")
    String fbProductModelName;

    @ApiModelProperty(value = "产品简称")
    String fbProductModelProductName;

    @ApiModelProperty(value = "型号")
    String productionOrderResistanceType;

    @ApiModelProperty(value = "规格")
    String fbProductModelSpecification;

    @ApiModelProperty(value = "掺杂剂")
    String fbProductModelDopant;

    @ApiModelProperty(value = "定向标识")
    String fbProductModelDirectionalSign;

    @ApiModelProperty(value = "边长")
    String sideLength;

    @ApiModelProperty(value = "长度范围")
    String lengthRange;

    @ApiModelProperty(value = "拼数")
    String sticksCount;


}