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

import com.jiayue.ipfcst.common.data.abst.AbstractBaseEntity;
import com.jiayue.ipfcst.common.data.constant.enums.FileTypeEnum;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.annotations.GenericGenerator;
import org.springframework.core.annotation.Order;

import javax.persistence.*;

/**
 * 上报路径
 *
 * @author tl
 * @version 3.0
 */
@EqualsAndHashCode(callSuper = true)
@Entity
@Data
public class UploadURL extends AbstractBaseEntity {

    @Id
    @Order(1)
    @GeneratedValue(strategy = GenerationType.AUTO, generator = "myid")
    @GenericGenerator(name = "myid", strategy = "com.jiayue.ipfcst.common.data.entity.id.CustomIDGenerator")
    private Integer id;

    //上报路径
    @Column
    private String uploadURL;

    //上报对象id
    @Column
    private Integer uploadObjectId;

    //上报通道id
    @Column
    private Integer uploadChannelId;

    //文件类型
    @Column
    @Enumerated(EnumType.STRING)
    private FileTypeEnum fileTypeEnum;

    /**
     * 场站编号（运维标识）
     */
    @Column
    private String stationCode;

}
