Commit b7c0fb36 authored by hongguangwu's avatar hongguangwu

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

parents 4604e081 f7435bd3
......@@ -122,6 +122,20 @@ public class TEmployeeInfo extends BaseEntity {
@Max(value = 200, message = "年龄不可超过200")
private Integer empAge;
/**
* 年龄查询开始
*/
@Schema(description = "年龄查询开始")
@TableField(exist = false)
private int empAgeStart;
/**
* 年龄查询结束
*/
@Schema(description = "年龄查询结束")
@TableField(exist = false)
private int empAgeEnd;
/**
* 婚姻状态
*/
......
......@@ -71,6 +71,11 @@ public class EmployeeExportVO extends BaseEntity {
@DateTimeFormat("yyyy-MM-dd")
private LocalDateTime validityEnd;
@ExcelProperty(value = "年龄")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelAttribute(name = "年龄")
private Integer empAge;
@ExcelAttribute(name = "婚姻状况", isDataId = true,dataType = ExcelAttributeConstants.EMP_MARRIED)
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "婚姻状况")
......
......@@ -82,6 +82,7 @@
<result property="empNatrue" column="EMP_NATRUE"/>
<result property="empName" column="EMP_NAME"/>
<result property="empIdcard" column="EMP_IDCARD"/>
<result property="empAge" column="EMP_AGE"/>
<result property="validityStart" column="VALIDITY_START"/>
<result property="validityEnd" column="VALIDITY_END"/>
<result property="empMarriStatus" column="EMP_MARRI_STATUS"/>
......@@ -329,8 +330,11 @@
<if test="tEmployeeInfo.empBirthday != null">
AND a.EMP_BIRTHDAY = #{tEmployeeInfo.empBirthday}
</if>
<if test="tEmployeeInfo.empAge != null">
AND a.EMP_AGE = #{tEmployeeInfo.empAge}
<if test="tEmployeeInfo.empAgeStart >0">
AND a.EMP_AGE >= #{tEmployeeInfo.empAgeStart}
</if>
<if test="tEmployeeInfo.empAgeEnd >0">
AND a.EMP_AGE <![CDATA[ <= ]]> #{tEmployeeInfo.empAgeEnd}
</if>
<if test="tEmployeeInfo.empMarriStatus != null and tEmployeeInfo.empMarriStatus.trim() != ''">
AND a.EMP_MARRI_STATUS = #{tEmployeeInfo.empMarriStatus}
......@@ -952,6 +956,7 @@
a.EMP_NATRUE,
a.EMP_NAME,
a.EMP_IDCARD,
a.EMP_AGE,
a.VALIDITY_START,
a.VALIDITY_END,
a.EMP_MARRI_STATUS,
......
......@@ -514,6 +514,10 @@ public interface ErrorCodes {
*/
String EMP_DISPATCH_SOCIAL_PAYMENT_TYPE_NOT_SAME = "emp.dispatch.social.payment.type.same";
String SOCIAL_HOLD_IS_EMPTY = "social.hold.is.empty";
String FUND_HOLD_IS_EMPTY = "fund.hold.is.empty";
String ARCHIVES_IMPORT_EMP_TRUE = "archives.import.emp.true";
/**
......
......@@ -205,6 +205,10 @@ emp.dispatch.emp.contract.sub.name.not.empty=\u6D3E\u589E\u5F02\u5E38\uFF1A \u54
emp.dispatch.social.record.base.not.exist=\u6D3E\u589E\u5F02\u5E38\uFF1A\u5907\u6848\u57FA\u6570\u4E0D\u53EF\u4E3A\u7A7A
social.hold.is.empty=\u793E\u4FDD\u6237\u4E0D\u80FD\u4E3A\u7A7A
fund.hold.is.empty=\u516C\u79EF\u91D1\u6237\u4E0D\u80FD\u4E3A\u7A7A
......
......@@ -51,7 +51,7 @@ public class TPreDispatchInfo extends BaseEntity {
*/
@TableId(type = IdType.ASSIGN_ID)
@Schema(description ="id")
private String id;
private String id;
/**
* 0 派增 1 派减
......
......@@ -17,6 +17,7 @@ import java.time.LocalDateTime;
public class TPreDispatchExportVo implements Serializable {
@ExcelAttribute(name = "主键", needExport = true)
@ExcelProperty("主键")
private String id;
/**
......
......@@ -33,7 +33,6 @@ import com.yifu.cloud.plus.v1.yifu.admin.api.vo.AllUserNaVo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeContractInfo;
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.entity.TSettleDomain;
import com.yifu.cloud.plus.v1.yifu.archives.vo.*;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CacheConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
......@@ -60,12 +59,10 @@ import lombok.RequiredArgsConstructor;
import lombok.extern.log4j.Log4j2;
import org.apache.shardingsphere.transaction.annotation.ShardingTransactionType;
import org.apache.shardingsphere.transaction.core.TransactionType;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cache.Cache;
import org.springframework.cache.CacheManager;
import org.springframework.cache.support.SimpleValueWrapper;
import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
......@@ -510,6 +507,17 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
excelVOTemp.put(excel.getRowIndex().toString(),excel.getEmpIdcard());
continue;
}
} else {
if (Common.isNotNull(excel.getRecordBase()) || Common.isNotNull(excel.getPensionStart()) ||
Common.isNotNull(excel.getMedicalStart()) || Common.isNotNull(excel.getBirthStart()) ||
Common.isNotNull(excel.getBigailmentStart()) || Common.isNotNull(excel.getUnemployStart()) ||
Common.isNotNull(excel.getWorkInjuryStart()) || Common.isNotNull(excel.getPaymentType()) ||
Common.isNotNull(excel.getPensionCardinal()) || Common.isNotNull(excel.getBirthCardinal()) ||
Common.isNotNull(excel.getBigailmentCardinal()) || Common.isNotNull(excel.getMedicalCardinal())
|| Common.isNotNull(excel.getUnemploymentCardinal()) || Common.isNotNull(excel.getWorkInjuryCardinal())) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.SOCIAL_HOLD_IS_EMPTY)));
excelVOTemp.put(excel.getRowIndex().toString(),excel.getEmpIdcard());
}
}
if (Common.isNotNull(excel.getProvidentHousehold())){
if (Common.isEmpty(fundSet)){
......@@ -517,6 +525,12 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
excelVOTemp.put(excel.getRowIndex().toString(),excel.getEmpIdcard());
continue;
}
} else {
if (Common.isNotNull(excel.getProvidentStart()) || Common.isNotNull(excel.getProvidentCardinal()) ||
Common.isNotNull(excel.getProvidentPer())) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.FUND_HOLD_IS_EMPTY)));
excelVOTemp.put(excel.getRowIndex().toString(),excel.getEmpIdcard());
}
}
if (Common.isNotNull(dispatchMap) && Common.isNotNull(dispatchMap.get(excel.getEmpIdcard()))){
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_EXIST)));
......@@ -681,7 +695,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
if (Common.isNotNull(socialFund) && Common.isNotNull(dispatch)){
socialFund.setDispatchId(dispatch.getId());
}
initSocialFundAndInsert(emp, social, fund, socialFund,project,dispatchPart,injury);
initSocialFundAndInsert(emp, social, fund, socialFund,project,dispatchPart,injury);
}
// 生成预付数据
if (Common.isNotNull(socialFund) && Common.isNotNull(socialFund.getId())){
......@@ -1460,7 +1474,26 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
social.setHandleStatus(CommonConstants.ZERO_STRING);
social.setDeleteFlag(CommonConstants.ZERO_STRING);
social.setTrustRemark(excel.getTrustRemark());
social.setSocialStartDate(excel.getPensionStart());
List<Date> lstDate = new ArrayList<>();
if (Common.isNotNull(excel.getPensionStart())) {
lstDate.add(excel.getPensionStart());
}
if (Common.isNotNull(excel.getUnemployStart())) {
lstDate.add(excel.getUnemployStart());
}
if (Common.isNotNull(excel.getBigailmentStart())) {
lstDate.add(excel.getBigailmentStart());
}
if (Common.isNotNull(excel.getWorkInjuryStart())) {
lstDate.add(excel.getWorkInjuryStart());
}
if (Common.isNotNull(excel.getMedicalStart())) {
lstDate.add(excel.getMedicalStart());
}
if (Common.isNotNull(excel.getBirthStart())) {
lstDate.add(excel.getBirthStart());
}
social.setSocialStartDate(Collections.min(lstDate));
// 封装单位信息 结算信息
social.setBelongUnit(excel.getCustomerId());
social.setSettleDomain(excel.getSettleDomainId());
......
......@@ -2347,7 +2347,7 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
importVo.setPost(preInfo.getPositionAdd());
importVo.setWorkingHours(preInfo.getWorkingHoursAdd());
importVo.setEmpNational(CommonConstants.ONE_STRING);
importVo.setEducationName(CommonConstants.FIVE_STRING);
importVo.setEducationName("大专");
importVo.setTrustRemark("预派单");
if (null != preInfo.getPensionBase()){
importVo.setRecordBase(preInfo.getPensionBase());
......@@ -2406,7 +2406,7 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
**/
private void initDispatchContractVo(TPreDispatchInfo preInfo, TDispatchImportVo importVo) {
if (Common.isNotNull(preInfo.getContractNameAdd())){
importVo.setContractName(preInfo.getContractTypeAdd());
importVo.setContractName("其他");
if (Common.isNotNull(preInfo.getContractStartAdd())){
importVo.setContractStart(DateUtil.stringToDate(ServiceUtil.
replaceSeparator(preInfo.getContractStartAdd(),CommonConstants.CENTER_SPLIT_LINE_STRING,
......
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