package cn.estsh.i3plus.pojo.mes.pcn.bean;

import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiParam;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.io.Serializable;

/**
 * @Description :产品流程配置操作参数表
 * @Reference :
 * @Author : jack.jia
 * @CreateDate : 2019-04-02
 * @Modify:
 **/
@Data
@Entity
@DynamicInsert
@DynamicUpdate
@EqualsAndHashCode(callSuper = true)
@Table(name = "MES_PROD_ROUTE_OPT_PARAM")
@Api("产品流程配置操作参数表")
public class MesProdRouteOptParam extends BaseBean implements Serializable {
    private static final long serialVersionUID = -932364659894292000L;
    @Column(name = "PROD_ROUTE_CFG_ID")
    @ApiParam("产品流程ID")
    private Long prodRouteCfgId;

    @Column(name = "ROUTE_CODE")
    @ApiParam("流程代码")
    private String routeCode;

    @Column(name = "PROCESS_CODE")
    @ApiParam("工序代码")
    private String processCode;

    @Column(name = "STEP_CODE")
    @ApiParam("工步代码")
    private String stepCode;

    @Column(name = "STEP_SEQ")
    @ApiParam("工步顺序")
    private Integer stepSeq;

    @Column(name = "PARAM_CODE")
    @ApiParam("工步参数代码")
    private String paramCode;

    @Column(name = "PARAM_VALUE")
    @ApiParam("工步参数值")
    private String paramValue;

    public long getProdRouteCfgIdVal() {
        return this.prodRouteCfgId == null ? 0l : this.prodRouteCfgId;
    }

    public int getStepSeq() {
        return this.stepSeq == null ? 0 : this.stepSeq;
    }

    public void setStepSeq(int stepSeq) {
        this.stepSeq = stepSeq;
    }
}
