package com.ruoyi.frequency.sale.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import com.ruoyi.vo.UserInfo;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.experimental.Accessors;

import java.math.BigDecimal;
import java.util.Date;

/**
 * 销售账号对象 t_sale
 * 
 * @author zj
 * @date 2023-09-22
 */
@Data
@Accessors(chain = true)
@TableName("t_sale")
public class Sale extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 租户号 */
//    @TableId("INPUT")
    private Long id;


    /** 删除标志;1 正常 2 删除 3 禁用 */
    private Integer delFlag;

    /** 头像 */
    @Excel(name = "头像")
    private String avatar;

    /** 手机 */
    @Excel(name = "手机")
    private String mobile;

    /** 微信id */
    @Excel(name = "微信id")
    private String wechatOpenid;

    /** 小程序id */
    @Excel(name = "小程序id")
    private String wechatAppletOpenid;

    /** 小程序unionId*/
    @Excel(name = "小程序unionId")
    private String unionId;

    /** 苹果id */
    @Excel(name = "苹果id")
    private String appleOpenid;

    private String nickname;

    private String name;
    /** 入行时间 */
    @Excel(name = "入行时间", width = 30, dateFormat = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy")
    private Date enterDate;

    /** 微信openID */
    @Excel(name = "微信openID")
    private String openId;

    /** 密码 */
    @Excel(name = "密码")
    private String loginPwd;

    /** 个人签名 */
    @Excel(name = "个人签名")
    private String signature;

    /** 余额 */
    @Excel(name = "余额")
    private BigDecimal balance;

    /** 总收益 */
    @Excel(name = "总收益")
    private BigDecimal income;

    /** 邀请码 */
    @Excel(name = "邀请码")
    private String inviteCode;

    /** 推广人数 */
    @Excel(name = "推广人数")
    private Integer inviteNum;

    @ApiModelProperty(value = "背景图")
    private String backgroundImage;

    /** 推送是否关闭;1不关闭2  关闭 */
    @Excel(name = "推送是否关闭;1不关闭2  关闭")
    private Integer closeMessage;

    @ApiModelProperty("开户行")
    @Excel(name = "开户行")
    private String bank;

    @ApiModelProperty("开户支行")
    @Excel(name = "开户支行")
    private String subbranch;

    @ApiModelProperty("银行卡")
    @Excel(name = "银行卡")
    private String bankCard;

    @ApiModelProperty("使用余额支付时 支付密码")
    private String payPwd;

    @ApiModelProperty(value = "用户信息")
    @TableField(exist = false)
    private UserInfo userInfo;


    @ApiModelProperty(value = "佣金排名")
    @TableField(exist = false)
    private Integer commissionRanking;

    @ApiModelProperty(value = "推广人数排名")
    @TableField(exist = false)
    private Integer saleRanking;

    @ApiModelProperty("排序 1降序 2升序")
    @TableField(exist = false)
    private Integer sortType;
}
