package com.yuchen.saas.manage.system.api.entity;

import com.baomidou.mybatisplus.annotation.TableName;

import java.util.Date;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.nest.springwrap.core.tenant.mp.TenantEntity;

/**
 * <p>
 * 组织成员
 * </p>
 *
 * @author author
 * @since 2023-03-16
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("nest_org_user")
public class NestOrgUser extends TenantEntity {

    private static final long serialVersionUID = 1L;


    /**
     * 姓名:来自组织申请记录表
     */
    @ApiModelProperty(value = "姓名:")
    private String name;

    /**
     * 用户id
     */
    @ApiModelProperty(value = "用户id")
    private Long userId;

    /**
     * 组织id
     */
    @ApiModelProperty(value = "组织id")
    private Long deptId;
    /**
     * 职位
     */
    @ApiModelProperty(value = "职位")
    private String position;

    /**
     * 办公地点
     */
    @ApiModelProperty(value = "办公地点")
    private String officeLocation;

    /**
     * 直属主管的组织成员ID
     */
    @ApiModelProperty(value = "直属主管的组织成员ID")
    private Long leaderOrgUserId;

    /**
     * 入职时间
     */
    @ApiModelProperty(value = "入职时间")
    private Date entryTime;

    /**
     * 备注
     */
    @ApiModelProperty(value = "备注")
    private String remark;

    //改标记再userDept表的isShow,
    @ApiModelProperty(value = "是否在组织层级底下0否1是(组织绑定关系不能移除,只能在这里加个字段判断")
    @Deprecated
    private Integer isInOrg;

    @Deprecated
    @ApiModelProperty(value = "是否是外部组织0否1是(外部关联连组织进来的绑定关系)")
    private Integer isExternalOrg;

    @ApiModelProperty(value = "直接绑定的下级组织id(建立在isexternalOrg=1时)")
    private Long childOrgId;

    @ApiModelProperty(value = "原本所在组织id(建立在isexternalOrg=1时)")
    private Long originalOrgId;

    @ApiModelProperty(value = "原本所在组织成员id(建立在isexternalOrg=1时)")
    private Long originalOrgUserId;

    @ApiModelProperty(name = "email", value = "邮箱")
    private String email;

    @ApiModelProperty(name = "jobNo", value = "工号")
    private String jobNo;

    @ApiModelProperty(name = "type", value = "成员类型:0内部成员,1外部成员,2下级组织成员")
    private Integer type;

    @ApiModelProperty(value = "来源组织id(外部成员来源组织id可能也会为空)")
    private Long sourceDeptId;

    @ApiModelProperty(value = "来源组织名称")
    private String sourceDeptName;

    @ApiModelProperty(value = "来源组织成员id(外部成员来源组织成员id可能也会为空)")
    private Long sourceOrgUserId;

    @ApiModelProperty(name = "isShowName", value = "外部组织名称(可以直接输名称,不存在组织id)")
    private Integer isShowName;

    @ApiModelProperty(name = "isShowEmail", value = "是否展示邮箱(外部组织0不展示,1展示)")
    private Integer isShowEmail;

    @ApiModelProperty(name = "isShowPhone", value = "是否展示手机号(外部组织0不展示,1展示)")
    private Integer isShowPhone;

    @ApiModelProperty(name = "isShowDept", value = "是否展示部门(外部组织0不展示,1展示)")
    private Integer isShowDept;

    @ApiModelProperty(name = "isShowPosition", value = "是否展示职位(外部组织0不展示,1展示)")
    private Integer isShowPosition;

}
