package com.platform.modules.live.vo;

import com.platform.modules.sys.entity.SysUserEntity;
import lombok.Data;
import lombok.NoArgsConstructor;


/**
 * Description:
 * Author:zj
 * Date:2019/2/20 10:46
 */
@Data
@NoArgsConstructor
public class ReporterVo {
    private Long userId;

    /**
     * 用户名
     */
    private String username;

    /**
     * 真实姓名
     */
    private String realName;

    /**
     * 性别
     */
    private String userGender;

    /**
     * 简介
     */
    private String userDesc;

    /**
     * 照片
     */
    private String photo;

    public ReporterVo(SysUserEntity sysUserEntity) {
        this.userId = sysUserEntity.getUserId();
        this.username = sysUserEntity.getUsername();
        this.realName = sysUserEntity.getRealname();
        this.userGender = sysUserEntity.getGender()==null ? "未知" : ((sysUserEntity.getGender()==1 || sysUserEntity.getGender().equals(1)) ? "男" : "女");
        this.userDesc = sysUserEntity.getIntro();
        this.photo = sysUserEntity.getUserImg();
    }
}
