package com.muchinfo.mtp3pojos.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.util.Date;

/**
 * <p>
 * 角色表
 * </p>
 *
 * @author XKF
 * @since 2024-04-16
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("SYSTEMMANAGERROLE")
@ApiModel(value="Systemmanagerrole对象", description="角色表")
@AllArgsConstructor
@NoArgsConstructor
@Builder
@KeySequence(value = "SEQ_SYSTEMMANAGERROLE")
public class Systemmanagerrole extends Model<Systemmanagerrole> {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "角色ID(自增ID) -- D")
    @TableId(value = "AUTOID", type=IdType.INPUT)
    private Long autoid;

    @ApiModelProperty(value = "角色名称 -- A")
    @TableField("ROLENAME")
    private String rolename;

    @ApiModelProperty(value = "所属机构")
    @TableField("AREAUSERID")
    private Long areauserid;

    @ApiModelProperty(value = "角色状态 - 1:启用  2：停用")
    @TableField("ROLESTATUS")
    private Integer rolestatus;

    @ApiModelProperty(value = "角色类型 - 1- 管理端   2-  交易端")
    @TableField("ROLETYPE")
    private Integer roletype;

    @ApiModelProperty(value = "敏感字段权限(JSON字符串)：1-客户手机号，2-客户证件号码，3-客户邮箱 -- A,U")
    @TableField("SENSITIVEFIELDS")
    @Builder.Default
    private String sensitivefields = "";

    @ApiModelProperty(value = "修改时间")
    @TableField("MODIFYTIME")
    private Date modifytime;

    @ApiModelProperty(value = "修改人")
    @TableField("MODIFIERID")
    private Long modifierid;

    @ApiModelProperty(value = "系统类型 - 1:旧管理端 2:新管理端")
    @TableField("SYSTEMTYPE")
    private Integer systemtype;

    @Override
    public Serializable pkVal() {
        return this.autoid;
    }

}
