package cn.estsh.i3plus.ext.mes.pojo.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.ColumnDefault;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

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

/**
 * @Description:
 * @Author: xiangming.liao
 * @Date: 2021/01/18 15:44
 * @Modify:
 */
@Data
@Entity
@DynamicInsert
@DynamicUpdate
@EqualsAndHashCode(callSuper = true)
@Table(name = "MES_PROCESS_TORQUE_MANAGE", indexes = {
        @Index(columnList = "PART_NO"),
        @Index(columnList = "PROCESS_CODE"),
        @Index(columnList = "PART_NO, PROCESS_CODE")

})
@Api("MES_工序扭矩管理")
public class MesProcessTorqueManage extends BaseBean implements Serializable {

    private static final long serialVersionUID = -5545553227344055268L;

    @Column(name="PART_NO")
    @ApiParam("零件编号")
    private String partNo;

    @Column(name="PART_NAME")
    @ApiParam("零件名称")
    private String partName;

    @Column(name = "PROCESS_CODE")
    @ApiParam(value = "工序编号")
    public String processCode;

    @Column(name="PROCESS_NAME")
    @ApiParam(value ="工序名称")
    private String processName;

    @Column(name = "FASTENING_POSITION")
    @ApiParam("紧固部位")
    private String fasteningPosition;

    @Column(name = "SPECIFICATION")
    @ApiParam("规格")
    private String specification;

    @Column(name = "UP_LIMIT")
    @ApiParam("上限值")
    private String upLimit;

    @Column(name = "DOWN_LIMIT")
    @ApiParam("下限值")
    private String downLimit;

    @Column(name = "SYSTEM_SYNC_STATUS")
    @ColumnDefault("2")
    @ApiParam(value = "系统同步标志")
    public Integer systemSyncStatus = 2;

}
