package com.ruoyi.bst.realName.domain;

import java.math.BigDecimal;

import javax.validation.constraints.NotBlank;

import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.annotation.Sensitive;
import com.ruoyi.common.core.domain.BaseEntity;
import com.ruoyi.common.core.interfaces.LogBizParam;
import com.ruoyi.common.core.validate.ValidGroup;
import com.ruoyi.common.enums.DesensitizedType;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * 实名认证信息对象 bst_real_name
 *
 * @author ruoyi
 * @date 2025-03-29
 */
@Data
public class RealName extends BaseEntity implements LogBizParam
{
    private static final long serialVersionUID = 1L;

    private Long id;

    @Excel(name = "用户id")
    @ApiModelProperty("用户id")
    private Long userId;

    @Excel(name = "用户姓名")
    @ApiModelProperty("用户姓名")
    @NotBlank(message = "用户姓名不允许为空", groups = {ValidGroup.Create.class})
    @Sensitive(desensitizedType = DesensitizedType.USERNAME)
    private String userName;

    @Excel(name = "身份证")
    @ApiModelProperty("身份证")
    @NotBlank(message = "身份证不允许为空", groups = {ValidGroup.Create.class})
    @Sensitive(desensitizedType = DesensitizedType.ID_CARD)
    private String idCard;

    @Excel(name = "人脸图像")
    @ApiModelProperty("人脸图像")
    private String picture;

    @Excel(name = "对比分数")
    @ApiModelProperty("对比分数")
    private BigDecimal score;

    @Excel(name = "手机号")
    @ApiModelProperty("手机号")
    @NotBlank(message = "手机号不允许为空", groups = {ValidGroup.Create.class})
    @Sensitive(desensitizedType = DesensitizedType.PHONE)
    private String mobile;

    @Excel(name = "实名认证状态")
    @ApiModelProperty("实名认证状态")
    private String status;

    @Excel(name = "认证类型")
    @ApiModelProperty("认证类型")
    private String type;

    @Excel(name = "认证结果")
    @ApiModelProperty("认证结果")
    private String result;

    @Override
    public Object logBizId() {
        return id;
    }

}
