package top.sunriseydy.syhthems.db.model;

import lombok.Data;

import javax.persistence.*;

/**
 * @author SunriseYDY
 * Generated by MBG
 */
@Data
@Table(name = "`sys_role`")
public class Role extends BaseModel {
    @Id
    @Column(name = "`role_id`")
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long roleId;

    /**
     * 角色编码，必须符合SpringSecurity的标准，即类似于ROLE_USER
     */
    @Column(name = "`role_code`")
    private String roleCode;

    /**
     * 角色名称
     */
    @Column(name = "`role_name`")
    private String roleName;

    /**
     * 角色描述
     */
    @Column(name = "`role_description`")
    private String roleDescription;

    /**
     * 启用标记,Y-启用,N-禁用
     */
    @Column(name = "`enable_flag`")
    private String enableFlag;

    public static final String ROLE_ID = "roleId";

    public static final String DB_ROLE_ID = "role_id";

    public static final String ROLE_CODE = "roleCode";

    public static final String DB_ROLE_CODE = "role_code";

    public static final String ROLE_NAME = "roleName";

    public static final String DB_ROLE_NAME = "role_name";

    public static final String ROLE_DESCRIPTION = "roleDescription";

    public static final String DB_ROLE_DESCRIPTION = "role_description";

    public static final String ENABLE_FLAG = "enableFlag";

    public static final String DB_ENABLE_FLAG = "enable_flag";

    public static final String CREATE_TIME = "createTime";

    public static final String DB_CREATE_TIME = "create_time";

    public static final String LAST_UPDATE_TIME = "lastUpdateTime";

    public static final String DB_LAST_UPDATE_TIME = "last_update_time";

    public static final String LAST_UPDATE_BY = "lastUpdateBy";

    public static final String DB_LAST_UPDATE_BY = "last_update_by";
}