package cn.estsh.i3plus.pojo.mes.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.*;
import java.io.Serializable;

/**
 * @Description :设备维修作业记录
 * @Reference :
 * @Author : wangjie
 * @CreateDate : 2019-10-11
 * @Modify:
 **/
@Data
@Entity
@DynamicInsert
@DynamicUpdate
@EqualsAndHashCode(callSuper = true)
@Table(name = "MES_EQU_TASK_REPAIR_RECORD", indexes = {
        @Index(columnList = "EQUIPMENT_CODE")
})
@Api("设备维修作业记录")
public class MesEquTaskRepairRecord extends BaseBean implements Serializable {

    private static final long serialVersionUID = 5431970816367411649L;
    @Column(name = "TASK_NO")
    @ApiParam("作业任务编号")
    private String taskNo;

    @Column(name = "TASK_TYPE")
    @ApiParam("作业类型")
    private Integer taskType;

    @Column(name = "EQUIPMENT_CODE")
    @ApiParam("设备代码")
    private String equipmentCode;

    @Column(name = "EQUIPMENT_NAME")
    @ApiParam("设备名称")
    private String equipmentName;

    @Column(name = "FP_CODE")
    @ApiParam("故障现象")
    private String fpCode;

    @Column(name = "FC_CODE")
    @ApiParam("故障原因")
    private String fcCode;

    @Column(name = "FM_CODE")
    @ApiParam("处理方法")
    private String fmCode;

    @Column(name = "FINAL_RESULT")
    @ApiParam("整体结果")
    private Integer finalResult;

    @Column(name = "MEMO")
    @ApiParam("备注")
    private String memo;

    @Transient
    @ApiParam("故障现象")
    private String fpName;

    @Transient
    @ApiParam("故障原因")
    private String fcName;

    @Transient
    @ApiParam("处理方法")
    private String fmName;

    @Transient
    @ApiParam("作业类型")
    private String taskTypeName;

    @Transient
    @ApiParam("整体结果")
    private String finalResultName;

}
