package jnpf.model.personnels.vo.transfer;

import jnpf.model.personnels.po.FtbPersonnelsTransferManage;
import lombok.Data;

import java.math.BigDecimal;
import java.util.Date;

@Data
public class FtbHandleTransferDetailsVO {
    /**
     * 调动主键Id
     */
    private String mobilizeId;
    /**
     * 调动类型0调岗1晋升2降职3调店
     */
    private Integer state;

    /**
     * 调动人用户id
     */
    private String userId;
    /**
     * 调动人用户姓名
     */
    private String userName;
    /**
     * 员工id（页面展示）
     */
    private String systemWorkerId;

    /**
     * 调动前组织id
     */
    private String beforeOrgId;
    /**
     * 调动前组织id
     */
    private String beforeOrgName;

    /**
     * 调动前岗位id
     */
    private String beforePostId;

    private String beforePostName;

    /**
     * 调动前职级id
     */
    private String beforeRankId;

    private String beforeRankName;

    /**
     * 调动后组织id
     */
    private String afterOrgId;

    private String afterOrgName;

    /**
     * 调动后岗位id
     */
    private String afterPostId;
    private String afterPostName;

    /**
     * 调动后职级id
     */
    private String afterRankId;

    private String afterRankName;

    /**
     * 生效时间
     */
    private Date effectiveDate;

    /**
     * 审核状态(0,待审批,1审批中,2,审核通过,3,审核不通过,4,撤销,5未办理, 6手动)
     */
    private Integer processingStatus;

    /**
     * 调动前班组id
     */
    private String beforeTeamId;

    /**
     * 调动后班组id
     */
    private String afterTeamId;

    /**
     * 审批id
     */
    private String taskInfoId;

    /**
     * 薪资结构(0,不使用,1使用)
     */
    private Integer salaryStructure;

    /**
     * 薪资详情
     */
    private String salaryStructureList;

    /**
     * 调动备注
     */
    private String remarks;

    /**
     * 附件
     */
    private String files;
    /**
     * 工作、交接交接
     */
    private String workHandover;

    private String beforeTeamName;

    private String afterTeamName;

    /**
     * 薪资序列
     * 1职级标准 2自定义标准
     */
    private Integer payrollSequence;

    /**
     * 薪资序列 id
     */
    private String payrollSequenceId;

    /**
     * 调薪方式 1.加薪 2.降薪
     */
    private Integer salaryType;

    /**
     * 薪资项合计
     */
    private BigDecimal salaryTotal;
    /**
     * 办理人主键id
     */
    private String handlePersonId;
    /**
     * 办理人姓名
     */
    private String handlePersonName;
    /**
     * 办理时间
     */
    private Date handleTime;

    /**
     * 薪资序列名称
     */
    private String payrollSequenceName;

    /**
     * 调动前直属主管id
     */
    private String beforeDirectSupervisorId;
    /**
     * 调动前直属主管名称
     */
    private String beforeDirectSupervisorName;

    /**
     * 调动后直属主管id
     */
    private String afterDirectSupervisorId;
    /**
     * 调动后直属主管名称
     */
    private String afterDirectSupervisorName;
    /**
     * 来源0非员工申请1员工申请
     */
    private Integer source;

    public static FtbHandleTransferDetailsVO convert(FtbPersonnelsTransferManage ftbPersonnelsTransferManage) {
        if (ftbPersonnelsTransferManage == null) {
            return null;
        }
        FtbHandleTransferDetailsVO ftbHandleTransferDetailsVO = new FtbHandleTransferDetailsVO();
        ftbHandleTransferDetailsVO.setState(ftbPersonnelsTransferManage.getState());
        ftbHandleTransferDetailsVO.setUserId(ftbPersonnelsTransferManage.getUserId());
        ftbHandleTransferDetailsVO.setBeforeOrgId(ftbPersonnelsTransferManage.getBeforeOrgId());
        ftbHandleTransferDetailsVO.setBeforeOrgName(ftbPersonnelsTransferManage.getBeforeOrgName());
        ftbHandleTransferDetailsVO.setBeforePostId(ftbPersonnelsTransferManage.getBeforePostId());
        ftbHandleTransferDetailsVO.setBeforePostName(ftbPersonnelsTransferManage.getBeforePostName());
        ftbHandleTransferDetailsVO.setBeforeRankId(ftbPersonnelsTransferManage.getBeforeRankId());
        ftbHandleTransferDetailsVO.setBeforeRankName(ftbPersonnelsTransferManage.getBeforeRankName());
        ftbHandleTransferDetailsVO.setAfterOrgId(ftbPersonnelsTransferManage.getAfterOrgId());
        ftbHandleTransferDetailsVO.setAfterOrgName(ftbPersonnelsTransferManage.getAfterOrgName());
        ftbHandleTransferDetailsVO.setAfterPostId(ftbPersonnelsTransferManage.getAfterPostId());
        ftbHandleTransferDetailsVO.setAfterPostName(ftbPersonnelsTransferManage.getAfterPostName());
        ftbHandleTransferDetailsVO.setAfterRankId(ftbPersonnelsTransferManage.getAfterRankId());
        ftbHandleTransferDetailsVO.setAfterRankName(ftbPersonnelsTransferManage.getAfterRankName());
        ftbHandleTransferDetailsVO.setEffectiveDate(ftbPersonnelsTransferManage.getEffectiveDate());
        ftbHandleTransferDetailsVO.setProcessingStatus(ftbPersonnelsTransferManage.getProcessingStatus());
        ftbHandleTransferDetailsVO.setBeforeTeamId(ftbPersonnelsTransferManage.getBeforeTeamId());
        ftbHandleTransferDetailsVO.setAfterTeamId(ftbPersonnelsTransferManage.getAfterTeamId());
        ftbHandleTransferDetailsVO.setTaskInfoId(ftbPersonnelsTransferManage.getTaskInfoId());
        ftbHandleTransferDetailsVO.setSalaryStructure(ftbPersonnelsTransferManage.getSalaryStructure());
        ftbHandleTransferDetailsVO.setSalaryStructureList(ftbPersonnelsTransferManage.getSalaryStructureList());
        ftbHandleTransferDetailsVO.setRemarks(ftbPersonnelsTransferManage.getRemarks());
        ftbHandleTransferDetailsVO.setFiles(ftbPersonnelsTransferManage.getFiles());
        ftbHandleTransferDetailsVO.setWorkHandover(ftbPersonnelsTransferManage.getWorkHandover());
        ftbHandleTransferDetailsVO.setBeforeTeamName(ftbPersonnelsTransferManage.getBeforeTeamName());
        ftbHandleTransferDetailsVO.setAfterTeamName(ftbPersonnelsTransferManage.getAfterTeamName());
        ftbHandleTransferDetailsVO.setPayrollSequence(ftbPersonnelsTransferManage.getPayrollSequence());
        ftbHandleTransferDetailsVO.setPayrollSequenceId(ftbPersonnelsTransferManage.getPayrollSequenceId());
        ftbHandleTransferDetailsVO.setSalaryType(ftbPersonnelsTransferManage.getSalaryType());
        ftbHandleTransferDetailsVO.setMobilizeId(ftbPersonnelsTransferManage.getId());
        ftbHandleTransferDetailsVO.setSalaryTotal(ftbPersonnelsTransferManage.getSalaryTotal());
        ftbHandleTransferDetailsVO.setHandleTime(ftbPersonnelsTransferManage.getCreatorTime());
        ftbHandleTransferDetailsVO.setHandlePersonId(ftbPersonnelsTransferManage.getCreatorUserId());
        ftbHandleTransferDetailsVO.setPayrollSequenceName(ftbPersonnelsTransferManage.getPayrollSequenceName());
        ftbHandleTransferDetailsVO.setBeforeDirectSupervisorId(ftbPersonnelsTransferManage.getBeforeDirectSupervisorId());
        ftbHandleTransferDetailsVO.setBeforeDirectSupervisorName(ftbPersonnelsTransferManage.getBeforeDirectSupervisorName());
        ftbHandleTransferDetailsVO.setAfterDirectSupervisorId(ftbPersonnelsTransferManage.getAfterDirectSupervisorId());
        ftbHandleTransferDetailsVO.setAfterDirectSupervisorName(ftbPersonnelsTransferManage.getAfterDirectSupervisorName());
        ftbHandleTransferDetailsVO.setSource(ftbPersonnelsTransferManage.getSource());
        return ftbHandleTransferDetailsVO;
    }
}
