package com.sw.mes.production.dto;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.sw.mes.production.entity.FormulaProductSchemeDetail;
import com.sw.mes.production.entity.FormulaProductSchemeWeightDetail;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.List;

/**
 * @Author
 * @Description：
 * @Date: Create in
 * @Modified By:
 */
@Data
@ApiModel(value = "产品方案Dto")
public class FormulaProductSchemeDto {

    private Long id;
    @NotBlank(message = "设备号不能为空")
    @ApiModelProperty(value = "设备号", required = true)
    String equipmentCode;
    @ApiModelProperty(value = "设备号集合")
    List<String> equipmentCodeList;
    @NotBlank(message = "产品料号不能为空")
    @ApiModelProperty(value = "产品料号", required = true)
    String productModeCode;
    @NotBlank(message = "产品名称不能为空")
    @ApiModelProperty(value = "产品名称", required = true)
    String productName;


    @ApiModelProperty(value = "拆桶方案id", required = true)
    Long decompositionSchemeId;
    @ApiModelProperty(value = "拆桶方案名称", required = true)
    String decompositionSchemeName;

    @ApiModelProperty(value = "初始配方id")
    Long initialFormulaId;
    @ApiModelProperty(value = "初始配方名称")
    String initialFormulaName;
    @ApiModelProperty(value = "初始复投方案id")
    Long initialReinvestmentId;
    @ApiModelProperty(value = "初始复投方案名称")
    String initialReinvestmentName;
    @ApiModelProperty(value = "取段复投方案id")
    Long reinvestmentId;
    @ApiModelProperty(value = "取段复投方案名称")
    String reinvestmentName;

    @NotNull(message = "状态不能为空")
    @ApiModelProperty(value = "状态(0：生效，1：下炉次生效)", required = true)
    Integer status;
    @ApiModelProperty(value = "下炉次生效信息")
    String nextFurnaceEffective;
    @ApiModelProperty(value = "创建人")
    String userCreate;
    @ApiModelProperty(value = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    Date gmtCreate;
    @ApiModelProperty(value = "修改人")
    String userUpdate;
    @ApiModelProperty(value = "修改时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    Date gmtUpdate;

    @ApiModelProperty(value = "重量及配方方案明细")
    List<FormulaProductSchemeWeightDetail> weightDetailList;
}