/*
 *    Copyright (c) 2018-2025, lengleng All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 * Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * Neither the name of the yifu4cloud.com developer nor the names of its
 * contributors may be used to endorse or promote products derived from
 * this software without specific prior written permission.
 * Author: lengleng (wangiegie@gmail.com)
 */
package com.yifu.cloud.plus.v1.yifu.archives.vo;

import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.alibaba.excel.annotation.write.style.HeadFontStyle;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttributeConstants;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.List;
import java.util.Set;

/**
 * 员工合同
 *
 * @author hgw
 * @date 2022-06-29 20:45:22
 */
@Data
@ColumnWidth(10)
public class EmployeeContractExportAuditVO implements Serializable {

	private static final long serialVersionUID = 1L;

	@ExcelAttribute(name = "派单类型",readConverterExp = "0=派增,1=派减")
	@Schema(description = "派单类型")
	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("审核类型")
	private String type;

	@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss")
	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("创建时间")
	private String createTime;

	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("员工姓名")
	@ExcelAttribute(name = "员工姓名", maxLength = 32)
	@Schema(description = "员工姓名", name = "empName")
	private String empName;

	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("身份证号")
	@ExcelAttribute(name = "身份证号", maxLength = 32)
	@Schema(description = "身份证号", name = "empIdcard")
	private String empIdcard;

	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("客户名称")
	@ExcelAttribute(name = "客户名称", maxLength = 128)
	@Schema(description = "客户名称", name = "subjectDepart")
	private String subjectUnit;

	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("项目名称")
	@ExcelAttribute(name = "项目名称", maxLength = 128)
	@Schema(description = "项目名称", name = "subjectDepart")
	private String subjectDepart;

	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("合同类型")
	@NotBlank(message = "合同类型不能为空")
	@ExcelAttribute(name = "合同类型", isNotEmpty = true, errorInfo = "合同类型不能为空", maxLength = 32, needExport = true)
	@Schema(description = "合同类型", name = "contractName")
	private String contractName;

	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("业务细分")
	@ExcelAttribute(name = "业务细分", maxLength = 32, needExport = true)
	@Schema(description = "业务细分", name = "contractName")
	private String contractSubName;

	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("签订类型")
	@ExcelAttribute(name = "签订类型", isDataId = true, dataType = ExcelAttributeConstants.EMPLOYEE_SITUATION_TYPE)
	@Schema(description = "签订类型", name = "situation")
	private String situation;

	/**
	 * 原因说明-- 委托备注
	 */
	@ExcelAttribute(name = "原因说明", maxLength = 200, needExport = true)
	@Schema(description = "原因说明", name = "reason")
	@ExcelProperty("原因说明")
	private String reason;

	/**
	 * 创建者-姓名
	 */
	@Schema(description = "创建人")
	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("创建人")
	private String createName;

	@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd")
	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("合同起始日期")
	@ExcelAttribute(name = "合同起始日期", isNotEmpty = true, errorInfo = "合同起始日期不能为空")
	@Schema(description = "合同起始日期", name = "contractStart")
	private String contractStart;

	@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd")
	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("合同截止时间")
	@ExcelAttribute(name = "合同截止时间", needExport = true)
	@Schema(description = "合同截止时间", name = "contractEnd")
	private String contractEnd;

	/**
	 * 签订期限employee_contract_type
	 * 0	已完成一定工作任务为期限
	 * 1	固定期限
	 * 2	无固定期限
	 */
	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("签订期限")
	@ExcelAttribute(name = "签订期限", isNotEmpty = true,  isDataId = true, dataType = ExcelAttributeConstants.EMPLOYEE_CONTRACT_TYPE, needExport = true)
	@Schema(description = "签订期限", name = "contractType")
	private String contractType;

	/**
	 * 工时制（数据字典） 1标准工时 2 综合工时 3不定时工时制
	 */
	@ExcelAttribute(name = "工时制", maxLength = 32, isDataId = true, dataType = ExcelAttributeConstants.WORKING_HOURS)
	@Schema(description = "工时制（数据字典） 1标准工时 2 综合工时 3不定时工时制", name = "workingHours")
	@ExcelProperty("工时制")
	private String workingHours;

	/**
	 * 离职日期
	 */
	@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd")
	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelProperty("离职日期")
	@ExcelAttribute(name = "离职日期")
	@Schema(description = "离职日期", name = "contractEnd")
	private String leaveDate;
	/**
	 * 减少原因
	 */
	@HeadFontStyle(fontHeightInPoints = 11)
	@ExcelAttribute(name = "减少原因", maxLength = 32, isDataId = true,dataType = ExcelAttributeConstants.REDUCE_SOCIAL_REASON)
	@Schema(description = "减少原因", name = "workingHours")
	@ExcelProperty("减少原因")
	private String reduceReason;
}
