Commit 351bbef7 authored by hongguangwu's avatar hongguangwu

Merge remote-tracking branch 'origin/develop' into develop

parents 172e00e3 cb638258
......@@ -405,10 +405,10 @@ public class TEmployeeContractInfo extends BaseEntity {
private String auditRemark;
/**
* 员工类型(字典值,0外包1派遣2代理)
* 员工类型(字典值,0外包1派遣2代理3内部员工
*/
@ExcelAttribute(name = "员工类型", isDataId = true, dataType = ExcelAttributeConstants.EMP_NATRUE)
@Schema(description = "员工类型(字典值,0外包1派遣2代理)")
@Schema(description = "员工类型(字典值,0外包1派遣2代理3内部员工)")
@Size(max = 1, message = "员工类型不可超过1位")
private String empNatrue;
......
......@@ -59,10 +59,10 @@ public class TEmployeeInfo extends BaseEntity {
private String empCode;
/**
* 员工类型(字典值,0外包1派遣2代理)
* 员工类型(字典值,0外包1派遣2代理3内部员工
*/
@ExcelAttribute(name = "员工类型", isDataId = true, dataType = ExcelAttributeConstants.EMP_NATRUE)
@Schema(description = "员工类型(字典值,0外包1派遣2代理)")
@Schema(description = "员工类型(字典值,0外包1派遣2代理3内部员工)")
@NotNull(message = "员工类型不可为空")
@Size(max = 1, message = "员工类型不可超过1位")
private String empNatrue;
......@@ -440,4 +440,8 @@ public class TEmployeeInfo extends BaseEntity {
@TableField(exist = false)
private String[] empNatureArray;
@Schema(description = "姓名或身份证")
@TableField(exist = false)
private String nameOrIdcard;
}
......@@ -66,9 +66,9 @@ public class TEmployeeProject extends BaseEntity {
private String empCode;
/**
* 员工类型(字典值,0外包1派遣2代理)
* 员工类型(字典值,0外包1派遣2代理3内部员工
*/
@Schema(description ="员工类型(字典值,0外包1派遣2代理)")
@Schema(description ="员工类型(字典值,0外包1派遣2代理3内部员工)")
@NotNull(message = "员工类型不能为空")
@Size(max = 1, message = "员工类型不可超过1位")
private String empNatrue;
......
......@@ -22,10 +22,10 @@ public class EmpAddDispatchVo extends TEmployeeInfo {
/**
* 员工类型(字典值,0外包1派遣2代理)
* 员工类型(字典值,0外包1派遣2代理3内部员工
*/
@ExcelAttribute(name = "员工类型", isDataId = true, dataType = ExcelAttributeConstants.EMP_NATRUE)
@Schema(description = "员工类型(字典值,0外包1派遣2代理)")
@Schema(description = "员工类型(字典值,0外包1派遣2代理3内部员工)")
private String empNatrue;
/**
......
......@@ -117,7 +117,7 @@ public class EmployeeContractExportVO implements Serializable {
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("员工类型")
@ExcelAttribute(name = "员工类型", isDataId = true, dataType = ExcelAttributeConstants.EMP_NATRUE)
@Schema(description = "员工类型(字典值,0外包1派遣2代理)")
@Schema(description = "员工类型(字典值,0外包1派遣2代理3内部员工)")
private String empNatrue;
@HeadFontStyle(fontHeightInPoints = 11)
......
/*
* 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.format.DateTimeFormat;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.alibaba.excel.annotation.write.style.HeadFontStyle;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttributeConstants;
import com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity;
import lombok.Data;
import javax.validation.constraints.Past;
import java.time.LocalDateTime;
import java.util.Date;
import java.util.List;
/**
* 项目档案表excel导出对应的实体
*
* @author huyc
* @date 2022-06-23 10:54:40
*/
@Data
@ColumnWidth(15)
public class EmployeeProjectExportParamVO extends BaseEntity {
private static final long serialVersionUID = 1L;
/**
* 档案员工类型(字典值,0外包1派遣2代理)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="档案员工类型")
@ExcelAttribute(name = "档案员工类型",isDataId = true,dataType = ExcelAttributeConstants.EMP_NATRUE)
private String proEmpNatrue;
/**
* 员工姓名
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="员工姓名")
private String empName;
/**
* 身份证号码
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="身份证号")
private String empIdcard;
/**
* 员工主码(系统自动生成:ZM+年月日+5位数字)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="员工主码")
private String empCode;
/**
* 身份证有效期起
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "身份证开始日期")
@DateTimeFormat("yyyy-MM-dd")
private Date validityStart;
/**
* 身份证有效期止
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "身份证截止日期")
@DateTimeFormat("yyyy-MM-dd")
private Date validityEnd;
/**
* 婚姻状况
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "婚姻状况")
@ExcelAttribute(name = "婚姻状况", isDataId = true,dataType = ExcelAttributeConstants.EMP_MARRIED)
private String empMarriStatus;
/**
* 民族
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "民族")
@ExcelAttribute(name = "民族", isDataId = true,dataType = ExcelAttributeConstants.EMP_NATIONAL)
private String empNational;
/**
* 政治面貌
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "政治面貌")
@ExcelAttribute(name = "政治面貌", isDataId = true,dataType = ExcelAttributeConstants.EMP_POLITICAL)
private String politicalStatus;
/**
* 手机号码
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "手机号码")
private String empPhone;
/**
* 邮箱
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "邮箱")
private String empEmail;
/**
* 身份证-省
*/
@ExcelAttribute(name = "户籍所在省", isArea = true)
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "户籍所在省")
private String idProvince;
/**
* 身份证-市
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "户籍所在市")
@ExcelAttribute(name = "户籍所在市", isArea = true, parentField = "idProvince")
private String idCity;
/**
* 身份证-县
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "户籍所在县")
@ExcelAttribute(name = "户籍所在县", isArea = true, parentField = "idCity")
private String idTown;
/**
* 户口性质
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "户口性质")
@ExcelAttribute(name = "户口性质", isDataId = true,dataType = ExcelAttributeConstants.EMP_REGISTYPE)
private String empRegisType;
/**
* 档案-省
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "档案所在省")
@ExcelAttribute(name = "档案所在省", isArea = true)
private String fileProvince;
/**
* 档案-市
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "档案所在市")
@ExcelAttribute(name = "档案所在市", isArea = true, parentField = "fileProvince")
private String fileCity;
/**
* 档案-县
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "档案所在县")
@ExcelAttribute(name = "档案所在县", isArea = true, parentField = "fileCity")
private String fileTown;
/**
* 是否大专及以上(0否1是)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "是否大专及以上")
@ExcelAttribute(name = "是否大专及以上", readConverterExp = "0=否,1=是")
private String isCollege;
/**
* 最高学历(字典值)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "最高学历")
@ExcelAttribute(name = "最高学历", isDataId = true,dataType = ExcelAttributeConstants.EDUCATION)
private String hignEducation;
/**
* 学校
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "学校")
private String school;
/**
* 专业
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "专业")
private String major;
/**
* 入学时间
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "入学时间")
@DateTimeFormat("yyyy-MM-dd")
private LocalDateTime admissionDate;
/**
* 毕业时间
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "毕业时间")
@DateTimeFormat("yyyy-MM-dd")
private LocalDateTime gradutionDate;
/**
* 备注
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "档案备注")
private String remark;
/**
* 人员档案来源(字典:4人员档案新建、5项目档案新建、1社保/公积金、3商险、2薪酬)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "人员档案来源")
@ExcelAttribute(name = "人员档案来源", readConverterExp = "1=社保公积金,2=薪酬,3=商险,4=人员档案新建")
private String fileSource;
/**
* 人员档案状态(0草稿、1已审核)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "人员档案状态")
@ExcelAttribute(name = "人员档案状态", readConverterExp = "0=草稿,1=已审核")
private String proStatus;
/**
* 创建者-姓名
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "人员档案创建人")
private String proCreateName;
/**
* 创建时间
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "人员档案创建时间")
@DateTimeFormat("yyyy-MM-dd")
private LocalDateTime proCreateTime;
/**
* 开户行
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="开户行")
private String bankName;
/**
* 支行
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="支行")
private String bankSubName;
/**
* 银行卡号
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="银行卡号")
private String bankNo;
/**
* 项目编码
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="项目编码")
private String deptNo;
/**
* 合同类型(字典值)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="合同类型")
@ExcelAttribute(name = "合同类型", isDataId = true,dataType = ExcelAttributeConstants.PERSONNEL_TYPE)
private String contractType;
/**
* 工时制
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="工时制")
@ExcelAttribute(name = "工时制", isDataId = true,dataType = ExcelAttributeConstants.WORKING_HOURS)
private String workingHours;
/**
* 就职岗位
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="就职岗位")
private String post;
/**
* 入职日期
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="入职日期")
@DateTimeFormat("yyyy-MM-dd")
@Past
private Date enjoinDate;
/**
* 试用期(单位月)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="试用期")
private String tryPeriod;
/**
* 项目员工类型
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="项目员工类型")
@ExcelAttribute(name = "项目员工类型", isDataId = true,dataType = ExcelAttributeConstants.EMP_NATRUE)
private String empNatrue;
/**
* 员工编码
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="员工编码")
private String empNo;
/**
* 客户名称
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="客户名称")
private String unitName;
/**
* 客户编码
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="客户编码")
private String unitNo;
/**
* 项目名称
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="项目名称")
private String deptName;
/**
* 员工合同状态(字典)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="合同状态")
@ExcelAttribute(name = "合同状态", isDataId = true,dataType = ExcelAttributeConstants.PERSONNEL_STATE)
private String contractStatus;
/**
* 业务类型一级分类
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="业务类型一级分类")
@ExcelAttribute(name = "业务类型一级分类", isDataId = true,dataType = ExcelAttributeConstants.CUSTOMER_BUSSINESS_PARENT)
private String businessPrimaryType;
/**
* 业务类型二级分类
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="业务类型二级分类")
@ExcelAttribute(name = "业务类型二级分类", isDataId = true,dataType = ExcelAttributeConstants.CUSTOMER_BUSSINESS_TYPE)
private String businessSecondType;
/**
* 业务类型三级分类
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="业务类型三级分类")
@ExcelAttribute(name = "业务类型三级分类", isDataId = true,dataType = ExcelAttributeConstants.CUSTOMER_BUSSINESS_SUB_TYPE)
private String businessThirdType;
/**
* 商险状态(字典)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="商险状态")
@ExcelAttribute(name = "商险状态", isDataId = true,dataType = ExcelAttributeConstants.COMMERCIAL_SATTE)
private String insuranceStatus;
/**
* 社保状态(字典)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="社保状态")
@ExcelAttribute(name = "社保状态", isDataId = true,dataType = ExcelAttributeConstants.SOCIAL_ECURITY_STATE)
private String socialStatus;
/**
* 公积金状态(字典)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="公积金状态")
@ExcelAttribute(name = "公积金状态", isDataId = true,dataType = ExcelAttributeConstants.FUND_STATUS)
private String fundStatus;
/**
* 近3个月发薪(0否;1是)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="近3个月发薪")
@ExcelAttribute(name = "近3个月发薪", readConverterExp = "0=无,1=是,2=否")
private String salaryStatus;
/**
* 项目档案来源(字典:4人员档案新建、5项目档案新建、1社保/公积金、3商险、2薪酬)
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="项目档案来源")
@ExcelAttribute(name = "项目档案来源", isDataId = true,dataType = ExcelAttributeConstants.PROJECT_EMP_SOURCE)
private String projectSource;
/**
* 项目档案状态(0草稿、1已审核)
*/
@ExcelAttribute(name ="项目档案状态", readConverterExp = "0=草稿,1=已审核")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="项目档案状态")
private String status;
/**
* 社保-省
*/
@ExcelAttribute(name ="社保所在省")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="社保所在省")
private String socialProvince;
/**
* 社保-市
*/
@ExcelAttribute(name ="社保所在市")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="社保所在市")
private String socialCity;
/**
* 社保-县
*/
@ExcelAttribute(name ="社保所在县")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="社保所在县")
private String socialTown;
private String[] socialStatusArray;
private String[] fundStatusArray;
private String[] insuranceStatusArray;
private String[] contractStatusArray;
private String[] empNatureArray;
private List<String> idList;
}
......@@ -22,7 +22,6 @@ import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.alibaba.excel.annotation.write.style.HeadFontStyle;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttributeConstants;
import com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity;
import lombok.Data;
import javax.validation.constraints.Past;
......@@ -38,7 +37,7 @@ import java.util.List;
*/
@Data
@ColumnWidth(15)
public class EmployeeProjectExportVO extends BaseEntity {
public class EmployeeProjectExportVO {
private static final long serialVersionUID = 1L;
......
......@@ -22,7 +22,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeProject;
import com.yifu.cloud.plus.v1.yifu.archives.service.TEmployeeProjectService;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmployeeProjectExportVO;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmployeeProjectExportParamVO;
import com.yifu.cloud.plus.v1.yifu.archives.vo.UpProjectSocialFundVo;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.util.Common;
......@@ -262,7 +262,7 @@ public class TEmployeeProjectController {
**/
@PostMapping("/export")
public void export(HttpServletResponse response, @RequestParam(name = "idstr", required = false)String idstr,
@RequestBody List<String> exportFields, EmployeeProjectExportVO projectDTO) {
@RequestBody List<String> exportFields, EmployeeProjectExportParamVO projectDTO) {
YifuUser user = SecurityUtils.getUser();
if (user != null && Common.isNotNull(user.getId())) {
menuUtil.setAuthSql(user, projectDTO);
......
......@@ -22,6 +22,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeInfo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeProject;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmployeeProjectExportParamVO;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmployeeProjectExportVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
......@@ -57,5 +58,5 @@ public interface TEmployeeProjectMapper extends BaseMapper<TEmployeeProject> {
* @param tEmployeeProject
* @return
*/
List<EmployeeProjectExportVO> getTEmployeeProjectExportPage(@Param("tEmployeeProject")EmployeeProjectExportVO tEmployeeProject);
List<EmployeeProjectExportVO> getTEmployeeProjectExportPage(@Param("tEmployeeProject") EmployeeProjectExportParamVO tEmployeeProject);
}
......@@ -23,7 +23,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeInfo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeProject;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmployeeProjectExportVO;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmployeeProjectExportParamVO;
import com.yifu.cloud.plus.v1.yifu.archives.vo.UpProjectSocialFundVo;
import com.yifu.cloud.plus.v1.yifu.common.core.util.ErrorMessage;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
......@@ -96,7 +96,7 @@ public interface TEmployeeProjectService extends IService<TEmployeeProject> {
R deleteEmpPro(TEmployeeProject tEmployeeProject);
/**
* @param list
* @param inputStream
* @Description: 批量减项
* @Author: huyc
* @Date: 2022/6/21 10:30
......@@ -163,7 +163,7 @@ public interface TEmployeeProjectService extends IService<TEmployeeProject> {
* @Date: 2022/6/23 10:30
* @return: R
**/
void listExportProject(HttpServletResponse response, EmployeeProjectExportVO projectDTO,
void listExportProject(HttpServletResponse response, EmployeeProjectExportParamVO projectDTO,
String idstr, List<String> exportFields);
/**
* @param employeeInfo
......
......@@ -130,15 +130,13 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
if (!Common.isEmpty(employeeProject)) {
//身份证实名认证
if (!Common.isEmpty(tEmployeeInfo)) {
if (!tEmployeeProject.getEmpName().equals(tEmployeeInfo.getEmpName())) {
if (!Common.isEmpty(tEmployeeInfo) && !tEmployeeProject.getEmpName().equals(tEmployeeInfo.getEmpName())) {
return R.failed("姓名和身份证不一致,请确认后再次新增");
}
}
//项目状态为已减项
if (CommonConstants.dingleDigitIntArray[1] == employeeProject.getProjectStatus()) {
if (!Common.isEmpty(tEmployeeInfo)) {
if (CommonConstants.dingleDigitIntArray[1] == employeeProject.getProjectStatus() &&
!Common.isEmpty(tEmployeeInfo)) {
map.put("empProId", employeeProject.getId());
if (CommonConstants.dingleDigitIntArray[0] == tEmployeeInfo.getFileStatus()) {
return new R<>(CommonConstants.dingleDigitIntArray[4], "该人员已减项,是否“复项”", map);
......@@ -147,7 +145,6 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
return new R<>(CommonConstants.dingleDigitIntArray[2], "该人员已减档减项,是否“复档复项”", map);
}
}
}
//状态为草稿、已审核
if (CommonConstants.dingleDigitIntArray[0] == employeeProject.getStatus() ||
CommonConstants.dingleDigitIntArray[1] == employeeProject.getStatus()) {
......@@ -194,7 +191,7 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
return R.failed(EmployeeConstants.CHECK_NO_RESPONSE);
} else if (!CommonConstants.SUCCESS.equals(vo.getRes().getCode())) {
return R.failed(vo.getRes().getMsg());
} else if (!Common.isEmpty(check) && !check.getResult().equals(CommonConstants.ZERO_ONE)) {
} else if (null != check && !check.getResult().equals(CommonConstants.ZERO_ONE)) {
return R.failed(check.getRemark());
}
} else {
......@@ -255,7 +252,7 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
return R.failed(EmployeeConstants.CHECK_NO_RESPONSE);
} else if (!CommonConstants.SUCCESS.equals(vo.getRes().getCode())) {
return R.failed(vo.getRes().getMsg());
} else if (!Common.isEmpty(check) && !check.getResult().equals(CommonConstants.ZERO_ONE)) {
} else if (null != check && !check.getResult().equals(CommonConstants.ZERO_ONE)) {
return R.failed(check.getRemark());
}
} else {
......@@ -374,7 +371,9 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
//从剩下的项目档案中查找员工类型并更新
if (Common.isNotNull(list)) {
Set<String> empNatrue = list.stream().map(TEmployeeProject::getEmpNatrue).collect(Collectors.toSet());
if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.ZERO_STRING))) {
if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.THREE_STRING))) {
tEmployeeInfo.setEmpNatrue(CommonConstants.THREE_STRING);
} else if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.ZERO_STRING))) {
tEmployeeInfo.setEmpNatrue(CommonConstants.ZERO_STRING);
} else if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.ONE_STRING))) {
tEmployeeInfo.setEmpNatrue(CommonConstants.ONE_STRING);
......@@ -411,7 +410,9 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
//从剩下的项目档案中查找员工类型并更新
if (Common.isNotNull(list)) {
Set<String> empNatrue = list.stream().map(TEmployeeProject::getEmpNatrue).collect(Collectors.toSet());
if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.ZERO_STRING))) {
if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.THREE_STRING))) {
tEmployeeInfo.setEmpNatrue(CommonConstants.THREE_STRING);
} else if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.ZERO_STRING))) {
tEmployeeInfo.setEmpNatrue(CommonConstants.ZERO_STRING);
} else if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.ONE_STRING))) {
tEmployeeInfo.setEmpNatrue(CommonConstants.ONE_STRING);
......@@ -472,7 +473,9 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
//从剩下的项目档案中查找员工类型并更新
if (Common.isNotNull(list)) {
Set<String> empNatrue = list.stream().map(TEmployeeProject::getEmpNatrue).collect(Collectors.toSet());
if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.ZERO_STRING))) {
if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.THREE_STRING))) {
tEmployeeInfo.setEmpNatrue(CommonConstants.THREE_STRING);
} else if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.ZERO_STRING))) {
tEmployeeInfo.setEmpNatrue(CommonConstants.ZERO_STRING);
} else if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.ONE_STRING))) {
tEmployeeInfo.setEmpNatrue(CommonConstants.ONE_STRING);
......@@ -740,9 +743,9 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
@Transactional
public void importListAdd(List<EmployeeProjectVO> excelVOList, List<ErrorMessage> errorMessageList, String idAdd) {
// 通用校验获取失败的数据
List<TEmployeeInfo> updateList = new ArrayList();
List<TEmployeeProject> proInsList = new ArrayList();
List<TEmployeeProject> proupdateList = new ArrayList();
List<TEmployeeInfo> updateList = new ArrayList<>();
List<TEmployeeProject> proInsList = new ArrayList<>();
List<TEmployeeProject> proupdateList = new ArrayList<>();
// 获取身份证、手机号列表,批量查询档案
Map<String, Integer> idCardMap = new HashMap<>();
......@@ -756,11 +759,9 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
idCard = excel.getEmpIdcard();
deptNo = excel.getDeptNo();
if (excel.getEmpNatrue().equals(CommonConstants.ZERO_STRING) || excel.getEmpNatrue().equals(CommonConstants.ONE_STRING)) {
if (excel.getContractType().equals(CommonConstants.ONE_STRING)) {
if (Common.isEmpty(excel.getWorkingHours())) {
if (excel.getContractType().equals(CommonConstants.ONE_STRING) && Common.isEmpty(excel.getWorkingHours())) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), "工时制不能为空!"));
}
}
if (Common.isEmpty(excel.getEnjoinDate())) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), "入职日期不能为空!"));
}
......@@ -815,7 +816,7 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), EmployeeConstants.CHECK_NO_RESPONSE));
} else if (!CommonConstants.SUCCESS.equals(vo.getRes().getCode())) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), vo.getRes().getMsg()));
} else if (!Common.isEmpty(check) && !check.getResult().equals(CommonConstants.ZERO_ONE)) {
} else if (null != check && !check.getResult().equals(CommonConstants.ZERO_ONE)) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), check.getRemark()));
}
} else {
......@@ -836,7 +837,6 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
//档案有(离职库),项目(已减档)
if (Common.isNotNull(tEmployeeInfo) && CommonConstants.dingleDigitIntArray[1] == tEmployeeInfo.getFileStatus()
&& Common.isNotNull(tEmployeeProject) && CommonConstants.dingleDigitIntArray[1] == tEmployeeProject.getProjectStatus()) {
updateExcelPost(updateList, tEmployeeInfo);
updateExcelPro(excel, proupdateList, tEmployeeProject);
//档案有(离职库),项目无;
} else if (Common.isNotNull(tEmployeeInfo) && CommonConstants.dingleDigitIntArray[1] == tEmployeeInfo.getFileStatus()
......@@ -855,21 +855,20 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), EmployeeConstants.CHECK_NO_RESPONSE));
} else if (!CommonConstants.SUCCESS.equals(vo.getRes().getCode())) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), vo.getRes().getMsg()));
} else if (!Common.isEmpty(check) && !check.getResult().equals(CommonConstants.ZERO_ONE)) {
} else if (null != check && !check.getResult().equals(CommonConstants.ZERO_ONE)) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), check.getRemark()));
}
} else {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), EmployeeConstants.CHECK_NO_RESPONSE));
}
}
updateExcelPost(updateList, tEmployeeInfo);
insertExcelPro(excel, proInsList, tEmployeeInfo);
//档案有(在档人员),项目(已减档)
} else if (Common.isNotNull(tEmployeeInfo) && CommonConstants.dingleDigitIntArray[0] == tEmployeeInfo.getFileStatus()
&& Common.isNotNull(tEmployeeProject) && CommonConstants.dingleDigitIntArray[1] == tEmployeeProject.getProjectStatus()) {
updateExcelPost(updateList, tEmployeeInfo);
updateExcelPro(excel, proupdateList, tEmployeeProject);
}
updateExcelPost(updateList, tEmployeeInfo);
//不允许复档复项
} else {
//档案有(离职库),项目(已减档)
......@@ -973,12 +972,10 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
// 项目档案更新List
List<TEmployeeProject> updateList = new ArrayList<>();
// 人员档案更新List
List<TEmployeeInfo> updTEmployeeList = new ArrayList();
List<TEmployeeInfo> updTEmployeeList = new ArrayList<>();
Map<String, Integer> checkCountMap = new HashMap<>();
// 新老档案List
List<EmployeeNewOldVO> updateInfoList = new ArrayList<>();
// 新老项目档案vo
EmployeeProjectNewOldVO newOldProject;
// 新老项目档案List
......@@ -1019,7 +1016,7 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), EmployeeConstants.CHECK_NO_RESPONSE));
} else if (!CommonConstants.SUCCESS.equals(vo.getRes().getCode())) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), vo.getRes().getMsg()));
} else if (!Common.isEmpty(check) && !check.getResult().equals(CommonConstants.ZERO_ONE)) {
} else if (null != check && !check.getResult().equals(CommonConstants.ZERO_ONE)) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), check.getRemark()));
}
} else {
......@@ -1177,14 +1174,11 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
* @Date 10:55 2022/6/23
**/
@Override
public void listExportProject(HttpServletResponse response, EmployeeProjectExportVO projectDTO, String idstr, List<String> exportFields) {
public void listExportProject(HttpServletResponse response, EmployeeProjectExportParamVO projectDTO, String idstr, List<String> exportFields) {
String fileName = "项目档案批量导出" + DateUtil.getThisTime() + CommonConstants.XLSX;
// 根据用户传入确定要导出的字段
Set<String> includeColumnFiledNames = new HashSet<>();
for (String exportField : exportFields) {
includeColumnFiledNames.add(exportField);
}
Set<String> includeColumnFiledNames = new HashSet<>(exportFields);
//获取要导出的列表
List<EmployeeProjectExportVO> list;
......@@ -1262,7 +1256,7 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
/**
* 获取导出的项目档案列表
*/
private List<EmployeeProjectExportVO> gettEmpProInfoExportVos(String idstr, EmployeeProjectExportVO projectDTO) {
private List<EmployeeProjectExportVO> gettEmpProInfoExportVos(String idstr, EmployeeProjectExportParamVO projectDTO) {
List<EmployeeProjectExportVO> list;
if (!Common.isEmpty(idstr)) {
projectDTO.setIdList(Common.initStrToList(idstr, CommonConstants.COMMA_STRING));
......@@ -1386,9 +1380,9 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
@Override
public String getEmpNo(String deptNo) {
String str = "";
String EmpNo = baseMapper.findEmployeeMaxOnlyNoByDepId(deptNo);
if (!Common.isEmpty(EmpNo)) {
str = NoUtil.productionNo(EmpNo, CommonConstants.EMPLOYEE_INIT_NO_START);
String empNo = baseMapper.findEmployeeMaxOnlyNoByDepId(deptNo);
if (!Common.isEmpty(empNo)) {
str = NoUtil.productionNo(empNo, CommonConstants.EMPLOYEE_INIT_NO_START);
} else {
str = deptNo + CommonConstants.EMPLOYEE_INIT_NO;
}
......
......@@ -57,7 +57,9 @@ public class DoJointTask {
.eq(TEmployeeProject::getProjectStatus, CommonConstants.ZERO_INT));
if (Common.isNotNull(list)) {
Set<String> empNatrue = list.stream().map(TEmployeeProject::getEmpNatrue).collect(Collectors.toSet());
if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.ZERO_STRING))) {
if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.THREE_STRING))) {
tEmployeeInfo.setEmpNatrue(CommonConstants.THREE_STRING);
} else if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.ZERO_STRING))) {
tEmployeeInfo.setEmpNatrue(CommonConstants.ZERO_STRING);
} else if (empNatrue.stream().anyMatch(e -> e.equals(CommonConstants.ONE_STRING))) {
tEmployeeInfo.setEmpNatrue(CommonConstants.ONE_STRING);
......
......@@ -297,6 +297,13 @@
<if test="tEmployeeInfo.empIdcard != null and tEmployeeInfo.empIdcard.trim() != ''">
AND a.EMP_IDCARD = #{tEmployeeInfo.empIdcard}
</if>
<if test="tEmployeeInfo.nameOrIdcard != null and tEmployeeInfo.nameOrIdcard.trim() != ''">
AND (
a.EMP_NAME like concat(#{tEmployeeInfo.nameOrIdcard},'%')
or
a.EMP_IDCARD like concat(#{tEmployeeInfo.nameOrIdcard},'%')
)
</if>
<if test="tEmployeeInfo.validityStart != null">
AND a.VALIDITY_START = #{tEmployeeInfo.validityStart}
</if>
......
......@@ -1670,8 +1670,8 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
detailList.add(detail);
try {
if (detail.getBuyType() != CommonConstants.FOUR_INT &&
CommonConstants.ONE_INT == detail.getSettleType()) {
if (new BigDecimal(success.getActualPremium()).compareTo(actualMoney) != 0) {
CommonConstants.ONE_INT == detail.getSettleType() &&
new BigDecimal(success.getActualPremium()).compareTo(actualMoney) != 0) {
//获取项目信息
TSettleDomain settleDomain = new TSettleDomain();
List<TSettleDomainSelectVo> settleDomainR = null;
......@@ -1681,13 +1681,13 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
TSettleDomainListVo tSettleDomainListVo = listVo.getData();
if (Common.isNotNull(tSettleDomainListVo) && Common.isNotEmpty(tSettleDomainListVo.getListSelectVO())) {
settleDomainR = tSettleDomainListVo.getListSelectVO();
for (TSettleDomainSelectVo vo :settleDomainR) {
BeanUtils.copyProperties(vo,settleDomain);
for (TSettleDomainSelectVo vo : settleDomainR) {
BeanUtils.copyProperties(vo, settleDomain);
}
}
}
BigDecimal gMoney = BigDecimal.ZERO;
Boolean isBl = false;
boolean isBl = false;
if (Common.isNotNull(settleDomain)) {
// 含有商险,则计算收入
if (settleDomain.getMrSettleType().equals(CommonConstants.TWO_STRING)) {
......@@ -1704,14 +1704,14 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
incomeDetail.setSourceId(detail.getId());
if (isBl) {
incomeDetail.setMoney(gMoney);
}else {
} else {
incomeDetail.setMoney(actualMoney);
}
incomeDetail.setFeeType(CommonConstants.ONE_STRING);
//判断是否存在当月的商险收入数据
R<TIncomeDetailReturnVo> detailInfoList = socialDaprUtils.getTIncomeDetailList(incomeDetail);
if (Common.isNotNull(detailInfoList) && detailInfoList.getCode() == CommonConstants.SUCCESS
&& detailInfoList.getData().getDetailList().size() > 0) {
&& !detailInfoList.getData().getDetailList().isEmpty()) {
//生成红冲数据
for (TIncomeDetail detailInfo : detailInfoList.getData().getDetailList()) {
TIncomeDetail detail1 = new TIncomeDetail();
......@@ -1738,13 +1738,13 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
incomeDetail.setFeeType(CommonConstants.TWO_STRING);
if (isBl) {
incomeDetail.setMoney(gMoney);
}else {
} else {
incomeDetail.setMoney(actualMoney);
}
//判断是否存在当月的商险收入数据
R<TIncomeDetailReturnVo> detailInfoList = socialDaprUtils.getTIncomeDetailList(incomeDetail);
if (Common.isNotNull(detailInfoList) && detailInfoList.getCode() == CommonConstants.SUCCESS
&& detailInfoList.getData().getDetailList().size() > 0) {
&& !detailInfoList.getData().getDetailList().isEmpty()) {
//生成红冲数据
for (TIncomeDetail detailInfo : detailInfoList.getData().getDetailList()) {
TIncomeDetail detail1 = new TIncomeDetail();
......@@ -1762,7 +1762,6 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
//生成收入数据
createInsuranceInfo(detail);
}
}
}catch (Exception e){
log.error("收入数据同步处理失败:"+e);
}
......
......@@ -515,10 +515,10 @@ public class TForecastLibrary extends BaseEntity {
/**
* 员工类型(字典值,0外包1派遣2代理)
*/
@ExcelAttribute(name = "员工类型(字典值,0外包1派遣2代理)", maxLength = 1)
@Length(max = 1, message = "员工类型(字典值,0外包1派遣2代理)不能超过1个字符")
@ExcelAttribute(name = "员工类型(字典值,0外包1派遣2代理3内部员工)", maxLength = 1)
@Length(max = 1, message = "员工类型(字典值,0外包1派遣2代理3内部员工)不能超过1个字符")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("员工类型(字典值,0外包1派遣2代理)")
@ExcelProperty("员工类型(字典值,0外包1派遣2代理3内部员工)")
private String empNatrue;
/**
* 单位补缴利息
......
......@@ -554,13 +554,13 @@ public class TForecastLibraryVo extends RowIndex implements Serializable {
@ExcelProperty("项目名称")
private String deptName;
/**
* 员工类型(字典值,0外包1派遣2代理)
* 员工类型(字典值,0外包1派遣2代理3内部员工
*/
@Length(max = 1, message = "员工类型(字典值,0外包1派遣2代理) 不能超过1 个字符")
@ExcelAttribute(name = "员工类型(字典值,0外包1派遣2代理)", maxLength = 1)
@Schema(description = "员工类型(字典值,0外包1派遣2代理)")
@Length(max = 1, message = "员工类型(字典值,0外包1派遣2代理3内部员工) 不能超过1 个字符")
@ExcelAttribute(name = "员工类型(字典值,0外包1派遣2代理3内部员工)", maxLength = 1)
@Schema(description = "员工类型(字典值,0外包1派遣2代理3内部员工)")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("员工类型(字典值,0外包1派遣2代理)")
@ExcelProperty("员工类型(字典值,0外包1派遣2代理3内部员工)")
private String empNatrue;
/**
* 单位补缴利息
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment