package cn.estsh.i3plus.ext.mes.pcn.pojo.context;

import io.swagger.annotations.ApiParam;
import lombok.Data;

import java.io.Serializable;

/**
 * 生产过程上下文对象-开模记录信息
 */
@Data
public class MesScanMonitorContext implements Serializable {

    private static final long serialVersionUID = 8234923032970057500L;

    @ApiParam("组织代码")
    private String organizeCode;

    @ApiParam("开模记录ID")
    private Long mouldRecordId;

    @ApiParam(value ="工序开始时间")
    private String startDateTime;

    @ApiParam("区域代码")
    private String areaCode;

    @ApiParam("生产线")
    private String workCenterCode;

    @ApiParam("工位")
    private String workCellCode;

    @ApiParam("设备ID")
    private Integer equipId;

    @ApiParam("设备代码")
    private String equipmentCode;

    @ApiParam("设备名称")
    private String equipmentName;

    @ApiParam("工序代码")
    private String processCode;

    @ApiParam("工序名称")
    private String processName;

    @ApiParam("工艺代码")
    private String craftCode;

    @ApiParam("工艺名称")
    private String craftName;

    public MesScanMonitorContext() {}

    public MesScanMonitorContext(String organizeCode, String processCode, String processName, String craftCode, String craftName) {
        this.organizeCode = organizeCode;
        this.processCode = processCode;
        this.processName = processName;
        this.craftCode = craftCode;
        this.craftName = craftName;
    }

    public MesScanMonitorContext mouldRecordId(Long mouldRecordId) {
        this.mouldRecordId = mouldRecordId;
        return this;
    }

    public MesScanMonitorContext startDateTime(String startDateTime) {
        this.startDateTime = startDateTime;
        return this;
    }

    public MesScanMonitorContext equipment(Integer equipId, String equipmentCode, String equipmentName) {
        this.equipId = equipId;
        this.equipmentCode = equipmentCode;
        this.equipmentName = equipmentName;
        return this;
    }

}
