package com.rf.psychological.institution.model;

import com.rf.psychological.base.model.BaseEntity;
import lombok.*;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Index;
import javax.persistence.Table;

@Entity
@Data
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper=false)
@Table(name = "t_institution_auth", indexes = {
        @Index(columnList = "id", unique = true),
        @Index(columnList = "b_id,institution_no")
})
@org.hibernate.annotations.Table(appliesTo = "t_institution_auth", comment = "机构数据权限表")
public class InstitutionAuthEntity extends BaseEntity {
    @Column(name = "institution_no", columnDefinition = "varchar(50) comment '所属机构编码'")
    private String institutionNo;

    @Column(name = "b_id", columnDefinition = "varchar(50) comment '数据id，数据类型为0时是量表id，1时为认知任务id'")
    private String bId;

    @Column(name = "type", columnDefinition = "varchar(50) comment '数据类型：0-量表、1-认知任务'")
    private String type;


}
