package cn.estsh.i3plus.pojo.andon.bean;

import cn.estsh.i3plus.pojo.base.annotation.AnnoOutputColumn;
import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import cn.estsh.i3plus.pojo.base.enumutil.AndonEnumUtil;
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;

/**
 * @Description : ANDON_自处理配置
 * @Reference :
 * @Author : hansen.ke
 * @CreateDate : 2019-05-31 14:08
 * @Modify:
 **/
@Data
@Entity
@Table(name="ANDON_DISPOSAL_CFG")
@DynamicInsert
@DynamicUpdate
@EqualsAndHashCode(callSuper = true)
@Api("ANDON_自处理配置")
public class AndonDisposalCfg extends BaseBean {

    @Column(name = "WORK_CENTER_CODE")
    @ApiParam(value = "工作中心代码")
    private String workCenterCode;

    @Column(name = "WORK_CELL_CODE")
    @ApiParam(value = "工作单元代码")
    private String workCellCode;

    @AnnoOutputColumn(refClass = AndonEnumUtil.ALARM_TYPE.class,refForeignKey = "value",value = "description")
    @Column(name = "ALARM_CODE")
    @ApiParam(value = "安灯类型代码")
    private String alarmCode;

    @Column(name = "AC_CODE")
    @ApiParam(value = "呼叫原因代码")
    private String acCode;

    @Column(name = "AC_NAME_RDD")
    @ApiParam(value = "呼叫原因描述")
    private String acNameRdd;

    @AnnoOutputColumn(refClass = AndonEnumUtil.APPROVAL_STATUS.class,refForeignKey = "value",value = "description")
    @Column(name = "APPROVAL_STATUS")
    @ApiParam(value = "审批状态")
    private String approvalStatus;
}
