package com.huiju.estateagents.center.taUser.entity;

import com.baomidou.mybatisplus.annotation.FieldStrategy;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.huiju.estateagents.entity.*;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.List;

/**
 * <p>
 * 用户表 
 * </p>
 *
 * @author jobob
 * @since 2019-09-11
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class TaUser implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 用户ID
     */
    @TableId(value = "user_id", type = IdType.AUTO)
    private Integer userId;

    /**
     * 公司id
     */
    private Integer orgId;

    /**
     * 用户名称
     */
    private String userName;

    /**
     * 登录账户
     */
    private String loginName;

    /**
     * 手机号
     */
    private String phone;

    /**
     * 登录密码
     */
    private String loginPassword;

    /**
     * 用户头像
     */
    private String avatar;

    /**
     * 用户状态
     */
    private Integer status;

    /**
     * 创建时间
     */
    private LocalDateTime createDate;

    /**
     * 账户过期时间
     */
    private LocalDateTime expDate;

    /**
     * 是否管理员
     */
    private Boolean isAdmin;

    /**
     * 公司名称
     */
    private String orgName;

    /**
     * 部门
     */
    private String department;

    /**
     * 职位
     */
    private String position;

    /**
     * 邮箱
     */
    private String email;

    /**
     * 身份证号
     */
    private String idNo;
    
    private String address;
    private String photo;
    private String description;

    /**
     * 权重
     */
    @TableField(strategy= FieldStrategy.IGNORED)
    private String weight;

    /**
     * 是否置业顾问
     */
    private Boolean isConsultant;

    /**
     * 公司水印
     */
    @TableField(exist = false)
    private String waterMark;

    /**
     * 关联小程序
     */
    @TableField(exist = false)
    private TaMiniapp miniapp;

    /**
     * 授权角色列表
     */
    @TableField(exist = false)
    private List<TaRole> roles;

    /**
     * 授权菜单列表
     */
    @TableField(exist = false)
    private List<SysMenu> menus;

    /**
     * 授权按钮列表
     */
    @TableField(exist = false)
    private List<SysButtonInMenu> buttons;
    
    @TableField(exist = false)
    private List<TaTags> taTagsList = new ArrayList<TaTags>();
    
    @TableField(exist = false)
    private List<Integer> taTags = new ArrayList<Integer>();
    
    @TableField(exist = false)
    private List<Integer> roleIds = new ArrayList<Integer>();
    
    @TableField(exist = false)
    private String buildingId;

    @TableField(exist = false)
    private List<String> projects;

    /**
     * ta_org/orgNum楼盘最大数
     */
  @TableField(exist = false)
    private int orgNum;

    // 所有省份城市
    @TableField(exist = false)
    List<TdCity> tdCityList;

    /**
     * 前台传值城市
     */
    @TableField(exist = false)
    private ArrayList<String> selectCityTree;

    /**
     * 城市ID
     */
    @TableField(exist = false)
    private Integer cityId;

    /**
     * 默认城市
     */
    @TableField(exist = false)
    private Integer defaultCityId;

    /**
     * 小程序绑定状态
     *
     * 0 未绑定 1 绑定
     */
    @TableField(exist = false)
    private Integer miniStatus;

    @TableField(exist = false)
    private List<String> buildingIds = new ArrayList<String>();

    /**
     * 新密码
     */
    @TableField(exist = false)
    private String newPassword;

    /**
     * 确认新密码
     */
    @TableField(exist = false)
    private String confirmPassword;

    /**
     * 置业顾问的personid
     */
    @TableField(exist = false)
    private String consultantPersonId;

    /**
     * personId集合
     */
    @TableField(exist = false)
    private List<TaPerson> personIds;

    /**
     * customerId集合
     */
    @TableField(exist = false)
    private List<TaRecommendCustomer> customerIds;

    @TableField(exist = false)
    private String miniAppName;

    private Boolean notShow;

    /**
     * 公司封面
     */
    @TableField(exist = false)
    private String orgThumb;

    /**
     * 公司描述
     */
    @TableField(exist = false)
    private String orgDesc;

    /**
     * 公司Logo
     */
    @TableField(exist = false)
    private String orgLogo;

    /**
     * BOSS 开屏图
     */
    @TableField(exist = false)
    private String bossDisplay;
}
