package com.bjtdba.userCenter.vo;

import com.bjtdba.utils.DateUtils;

import java.util.Date;

public class UserInfoVo {
    private Long uid;
    /**
     * 用户昵称
     */
    private String nickname;

    /**
     * 用户头像
     */
    private String avatar;
    /**
     * 手机号
     */
    private String phone;

    /**
     * 性别
     */
    private Integer sex;
    /**
     * 生日
     */
    private Date birthday;
    /**
     * 地址
     */
    private String addres;

    /**
     * 积分（20220712改版新增）
     */
    private Double score;
    /**
     * 佣金金额
     */
    private Double brokeragePrice;

    private Integer is_da_cang_vip;

    public Long getUid() {
        return uid;
    }

    public void setUid(Long uid) {
        this.uid = uid;
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public String getAvatar() {
        return avatar;
    }

    public void setAvatar(String avatar) {
        this.avatar = avatar;
    }

    public String getPhone() {
        return phone.replaceAll("(?<=[\\w]{3})\\w(?=[\\w]{4})", "*");
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public Integer getSex() {
        return sex;
    }

    public void setSex(Integer sex) {
        this.sex = sex;
    }

    public String getBirthday() {
        return  DateUtils.formatDate(birthday,"yyyy-MM-dd HH:mm:ss") ;
    }

    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }

    public String getAddres() {
        return addres;
    }

    public void setAddres(String addres) {
        this.addres = addres;
    }

    public Double getScore() {
        return score;
    }

    public void setScore(Double score) {
        this.score = score;
    }

    public Double getBrokeragePrice() {
        return brokeragePrice;
    }

    public void setBrokeragePrice(Double brokeragePrice) {
        this.brokeragePrice = brokeragePrice;
    }

    public Integer getIs_da_cang_vip() {
        return is_da_cang_vip;
    }

    public void setIs_da_cang_vip(Integer is_da_cang_vip) {
        this.is_da_cang_vip = is_da_cang_vip;
    }
}
