package com.jiayue.ipfcst.common.data.entity;

import com.jiayue.ipfcst.common.data.abst.AbstractBaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.annotations.GenericGenerator;

import javax.persistence.*;
import javax.validation.constraints.Digits;
import java.math.BigDecimal;

/**
 * 检修计划
 *
 * @author zzy
 * @version 1.0
 * @since 2019/7/22 11:24
 */
@EqualsAndHashCode(callSuper = true)
@Data
@Entity
public class OverhaulPlan extends AbstractBaseEntity {


    /**
     * 编号
     */
    @Id
    @GeneratedValue(strategy = GenerationType.AUTO, generator = "myid")
    @GenericGenerator(name = "myid", strategy = "com.jiayue.ipfcst.common.data.entity.id.CustomIDGenerator")
    @Column
    private Integer id;


    /**
     * 名称
     */
    @Column
    private String name;

    /**
     * 描述
     */
    @Column
    private String describe;

    /**
     * 开始时间
     */
    @Column
    private Long startTime;

    /**
     * 结束时间
     */
    @Column
    private Long endTime;

    /**
     * 检修容量，单位MW
     */
    @Column
    @Digits(integer = 10, fraction = 2)
    private BigDecimal overhaulCapactity;

    /**
     * 状态：改为执行中和关闭中
     */
    @Column
    private Integer status;

    /**
     * 生效时间
     */
    @Column
    private Long finalEntryTime;

    /**
     * 手动完成时间
     * Manual completion time
     */
    private Long mcTime;

    @Column
    private String stationCode;

    /*
    backUpA 捆绑id
     */

}
