package com.kingdee.eas.custom.synctask.entity;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;

import java.util.Map;

/**
 * @author qingwu
 * @date 2024/10/24
 * @apiNote
 */
@JsonInclude(JsonInclude.Include.NON_NULL)
public class PersonEntity {
    // 编号
    private String workcode;
    // 分部：2 种方式：1)分部全路径（副作用：未找到，会新增），2) 以 {"subcompanycode":"fw"} 为值的字符串，指定分部编码（不会新增）
    private String subcompany;
    // 部门：2 种方式：1)部门全路径（副作用：未找到，会新增），2)以 {"departmentcode":"fw"} 为值的字符串，指定部门编码（不会新增）
    private String department;
    //人员名称
    private String lastname;
    // 登录名称
    private String loginid;
    // 明文密码，会转密文
    private String password;
    // 安全级别
    private String seclevel;
    // 枚举值：默认男、女，此处为性别
    private String sex;
    // 岗位名称：2 种方式：1）名称（会新建），2）以 {"jobtitlecode":"fw"} 为值的字符串，指定岗位编码（不会新增）
    private String jobtitle = "";
    // 职务，岗位使用 JSON 格式不需要传递
    private String jobactivityid = "";
    // 职务类型，岗位使用 JSON 格式不需要传递
    private String jobgroupid = "";
    // 职称，数据关联表：HrmJobCall
    private String jobcall;
    // 职级，仅支持整数字
    private String joblevel;
    // 职责描述
    //private String jobactivitydesc;
    // 直接上级，仅支持编号
    private String managerid="";
    // 助理，仅支持编号
    private String assistantid;
    // 状态，包括试用、正式、临时、试用延期、解聘、离职、退休、无效
    private String status;
    // 办公地点
    private String locationid = "";
    // 办公室
    //private String workroom;
    // 办公室电话
    private String telephone;
    // 移动电话
    private String mobile;
    //// 其他电话
    //private String mobilecall;
    //// 传真
    //private String fax;
    // 邮箱
    private String email;
    //// 系统语言，包括简体中文、繁體中文、English
    //private String systemlanguage;
    //// 生日，格式：yyyy-MM-dd
    //private String birthday;
    //// 民族
    //private String folk;
    //// 籍贯
    //private String nativeplace;
    //// 户口
    //private String regresidentplace;
    //// 身份证号码，如果有值，必须唯一
    //private String certificatenum;
    //// 婚姻状况，包括已婚、离异、未婚
    //private String maritalstatus;
    //// 政治面貌
    //private String policy;
    //// 入团日期，格式：yyyy-MM-dd
    //private String bememberdate;
    //// 入党日期，格式：yyyy-MM-dd
    //private String bepartydate;
    //// 工会会员
    //private String islabouunion;
    //// 学历，数据关联表：HrmEducationLevel
    //private String educationlevel;
    //// 学位
    //private String degree;
    //// 健康状况，包括良好、一般、较差、优秀
    //private String healthinfo;
    //// 现居住地
    //private String residentplace;
    //// 家庭联系方式
    //private String homeaddress;
    // 入职日期
    private String companystartdate;
    // 参加工作日期
    private String workstartdate;
    // 基本信息自定义数据，字段确认请看【组织权限中心】-【自定义设置】-【人员卡片字段定义】-【基本信息】数据库字段名
    @JsonProperty("base_custom_data")
    private Map baseCustomData;
    // 个人信息自定义数据，字段确认请看【组织权限中心】-【自定义设置】-【人员卡片字段定义】-【个人信息】数据库字段名
    @JsonProperty("person_custom_data")
    private Map personCustomData;
    // 工作信息自定义数据，字段确认请看【组织权限中心】-【自定义设置】-【人员卡片字段定义】-【工作信息】数据库字段名  work_custom_data
    @JsonProperty("work_custom_data")
    private Map workCustomData;

    public String getWorkcode() {
        return workcode;
    }

    public void setWorkcode(String workcode) {
        this.workcode = workcode;
    }

    public String getSubcompany() {
        return subcompany;
    }

    public void setSubcompany(String subcompany) {
        this.subcompany = "{JSON}{\"subcompanycode\":\""+subcompany+"\"}" ;
    }

    public String getDepartment() {
        return department;
    }

    public void setDepartment(String department) {
        this.department = "{JSON}{\"departmentcode\":\""+department+"\"}" ;
    }

    public String getLastname() {
        return lastname;
    }

    public void setLastname(String lastname) {
        this.lastname = lastname;
    }

    public String getLoginid() {
        return loginid;
    }

    public void setLoginid(String loginid) {
        this.loginid = loginid;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getSeclevel() {
        return seclevel;
    }

    public void setSeclevel(String seclevel) {
        this.seclevel = seclevel;
    }

    public String getSex() {
        return sex;
    }

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

    public String getJobtitle() {
        return jobtitle;
    }

    public void setJobtitle(String jobtitle) {
        this.jobtitle = "{JSON}{\"jobtitlecode\":\""+jobtitle+"\"}";
    }

    public String getJobactivityid() {
        return jobactivityid;
    }

    public void setJobactivityid(String jobactivityid) {
        this.jobactivityid = jobactivityid;
    }

    public String getJobgroupid() {
        return jobgroupid;
    }

    public void setJobgroupid(String jobgroupid) {
        this.jobgroupid = jobgroupid;
    }

    public String getJobcall() {
        return jobcall;
    }

    public void setJobcall(String jobcall) {
        this.jobcall = jobcall;
    }

    public String getJoblevel() {
        return joblevel;
    }

    public void setJoblevel(String joblevel) {
        this.joblevel = joblevel;
    }

    public String getManagerid() {
        return managerid;
    }

    public void setManagerid(String managerid) {
        this.managerid = managerid;
    }

    public String getAssistantid() {
        return assistantid;
    }

    public void setAssistantid(String assistantid) {
        this.assistantid = assistantid;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getLocationid() {
        return locationid;
    }

    public void setLocationid(String locationid) {
        this.locationid = locationid;
    }

    public String getTelephone() {
        return telephone;
    }

    public void setTelephone(String telephone) {
        this.telephone = telephone;
    }

    public String getMobile() {
        return mobile;
    }

    public void setMobile(String mobile) {
        this.mobile = mobile;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getCompanystartdate() {
        return companystartdate;
    }

    public void setCompanystartdate(String companystartdate) {
        this.companystartdate = companystartdate;
    }

    public String getWorkstartdate() {
        return workstartdate;
    }

    public void setWorkstartdate(String workstartdate) {
        this.workstartdate = workstartdate;
    }

    public Map getBaseCustomData() {
        return baseCustomData;
    }

    public void setBaseCustomData(Map baseCustomData) {
        this.baseCustomData = baseCustomData;
    }

    public Map getPersonCustomData() {
        return personCustomData;
    }

    public void setPersonCustomData(Map personCustomData) {
        this.personCustomData = personCustomData;
    }

    public Map getWorkCustomData() {
        return workCustomData;
    }

    public void setWorkCustomData(Map workCustomData) {
        this.workCustomData = workCustomData;
    }

    @Override
    public String toString() {
        return "PersonEntity{" +
                "workcode='" + workcode + '\'' +
                ", subcompany='" + subcompany + '\'' +
                ", department='" + department + '\'' +
                ", lastname='" + lastname + '\'' +
                ", loginid='" + loginid + '\'' +
                ", password='" + password + '\'' +
                ", seclevel='" + seclevel + '\'' +
                ", sex='" + sex + '\'' +
                ", jobtitle='" + jobtitle + '\'' +
                ", jobactivityid='" + jobactivityid + '\'' +
                ", jobgroupid='" + jobgroupid + '\'' +
                ", jobcall='" + jobcall + '\'' +
                ", joblevel='" + joblevel + '\'' +
                ", managerid='" + managerid + '\'' +
                ", assistantid='" + assistantid + '\'' +
                ", status='" + status + '\'' +
                ", locationid='" + locationid + '\'' +
                ", telephone='" + telephone + '\'' +
                ", mobile='" + mobile + '\'' +
                ", email='" + email + '\'' +
                ", companystartdate='" + companystartdate + '\'' +
                ", workstartdate='" + workstartdate + '\'' +
                ", baseCustomData=" + baseCustomData +
                ", personCustomData=" + personCustomData +
                ", workCustomData=" + workCustomData +
                '}';
    }
}
