Commit 1ba63982 authored by huyuchen's avatar huyuchen

商险优化

parent 1ec1f9d0
......@@ -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;
......
......@@ -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)
......
......@@ -130,22 +130,19 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
if (!Common.isEmpty(employeeProject)) {
//身份证实名认证
if (!Common.isEmpty(tEmployeeInfo)) {
if (!tEmployeeProject.getEmpName().equals(tEmployeeInfo.getEmpName())) {
return R.failed("姓名和身份证不一致,请确认后再次新增");
}
if (!Common.isEmpty(tEmployeeInfo) && !tEmployeeProject.getEmpName().equals(tEmployeeInfo.getEmpName())) {
return R.failed("姓名和身份证不一致,请确认后再次新增");
}
//项目状态为已减项
if (CommonConstants.dingleDigitIntArray[1] == employeeProject.getProjectStatus()) {
if (!Common.isEmpty(tEmployeeInfo)) {
map.put("empProId", employeeProject.getId());
if (CommonConstants.dingleDigitIntArray[0] == tEmployeeInfo.getFileStatus()) {
return new R<>(CommonConstants.dingleDigitIntArray[4], "该人员已减项,是否“复项”", map);
} else {
map.put("employeeId", tEmployeeInfo.getId());
return new R<>(CommonConstants.dingleDigitIntArray[2], "该人员已减档减项,是否“复档复项”", map);
}
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);
} else {
map.put("employeeId", tEmployeeInfo.getId());
return new R<>(CommonConstants.dingleDigitIntArray[2], "该人员已减档减项,是否“复档复项”", map);
}
}
//状态为草稿、已审核
......@@ -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,10 +759,8 @@ 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())) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), "工时制不能为空!"));
}
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 {
......@@ -1181,10 +1178,7 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
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;
......@@ -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);
......
......@@ -1670,98 +1670,97 @@ 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) {
//获取项目信息
TSettleDomain settleDomain = new TSettleDomain();
List<TSettleDomainSelectVo> settleDomainR = null;
R<TSettleDomainListVo> listVo = null;
listVo = archivesDaprUtil.selectSettleDomainSelectVoByNo(detail.getDeptNo());
if (Common.isNotNull(listVo)) {
TSettleDomainListVo tSettleDomainListVo = listVo.getData();
if (Common.isNotNull(tSettleDomainListVo) && Common.isNotEmpty(tSettleDomainListVo.getListSelectVO())) {
settleDomainR = tSettleDomainListVo.getListSelectVO();
for (TSettleDomainSelectVo vo :settleDomainR) {
BeanUtils.copyProperties(vo,settleDomain);
}
CommonConstants.ONE_INT == detail.getSettleType() &&
new BigDecimal(success.getActualPremium()).compareTo(actualMoney) != 0) {
//获取项目信息
TSettleDomain settleDomain = new TSettleDomain();
List<TSettleDomainSelectVo> settleDomainR = null;
R<TSettleDomainListVo> listVo = null;
listVo = archivesDaprUtil.selectSettleDomainSelectVoByNo(detail.getDeptNo());
if (Common.isNotNull(listVo)) {
TSettleDomainListVo tSettleDomainListVo = listVo.getData();
if (Common.isNotNull(tSettleDomainListVo) && Common.isNotEmpty(tSettleDomainListVo.getListSelectVO())) {
settleDomainR = tSettleDomainListVo.getListSelectVO();
for (TSettleDomainSelectVo vo : settleDomainR) {
BeanUtils.copyProperties(vo, settleDomain);
}
}
BigDecimal gMoney = BigDecimal.ZERO;
Boolean isBl = false;
if (Common.isNotNull(settleDomain)) {
// 含有商险,则计算收入
if (settleDomain.getMrSettleType().equals(CommonConstants.TWO_STRING)) {
if (Common.isNotNull(settleDomain.getManageServerItem()) && settleDomain.getManageServerItem()
.contains(CommonConstants.THREE_STRING) && CommonConstants.ZERO_STRING.equals(settleDomain.getManagementTag())) {
if (CommonConstants.ONE_STRING.equals(settleDomain.getManagementType())) {
gMoney = BigDecimalUtils.safeMultiply(actualMoney,
settleDomain.getManagementFee().divide(new BigDecimal("100"),
CommonConstants.FIVE_INT, BigDecimal.ROUND_HALF_UP));
isBl = true;
}
//判断是否存在当月的商险收入数据
TIncomeDetail incomeDetail = new TIncomeDetail();
incomeDetail.setSourceId(detail.getId());
if (isBl) {
incomeDetail.setMoney(gMoney);
}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) {
//生成红冲数据
for (TIncomeDetail detailInfo : detailInfoList.getData().getDetailList()) {
TIncomeDetail detail1 = new TIncomeDetail();
BeanCopyUtils.copyProperties(detailInfo, detail1);
detail1.setId(CommonConstants.NULL);
detail1.setRedData(CommonConstants.ONE_STRING);
detail1.setMoney(detailInfo.getMoney().negate());
socialDaprUtils.createTIncomeDetail(detail1);
break;
}
}
}
BigDecimal gMoney = BigDecimal.ZERO;
boolean isBl = false;
if (Common.isNotNull(settleDomain)) {
// 含有商险,则计算收入
if (settleDomain.getMrSettleType().equals(CommonConstants.TWO_STRING)) {
if (Common.isNotNull(settleDomain.getManageServerItem()) && settleDomain.getManageServerItem()
.contains(CommonConstants.THREE_STRING) && CommonConstants.ZERO_STRING.equals(settleDomain.getManagementTag())) {
if (CommonConstants.ONE_STRING.equals(settleDomain.getManagementType())) {
gMoney = BigDecimalUtils.safeMultiply(actualMoney,
settleDomain.getManagementFee().divide(new BigDecimal("100"),
CommonConstants.FIVE_INT, BigDecimal.ROUND_HALF_UP));
isBl = true;
}
if (Common.isNotNull(settleDomain.getRiskServerItem()) && settleDomain.getRiskServerItem()
.contains(CommonConstants.THREE_STRING) && CommonConstants.ZERO_STRING.equals(settleDomain.getRiskFundTag())) {
if (CommonConstants.ONE_STRING.equals(settleDomain.getRiskFundType())) {
gMoney = BigDecimalUtils.safeMultiply(actualMoney,
settleDomain.getRiskFundFee().divide(new BigDecimal("100"),
CommonConstants.FIVE_INT, BigDecimal.ROUND_HALF_UP));
isBl = true;
}
//判断是否存在当月的商险收入数据
TIncomeDetail incomeDetail = new TIncomeDetail();
incomeDetail.setSourceId(detail.getId());
incomeDetail.setFeeType(CommonConstants.TWO_STRING);
if (isBl) {
incomeDetail.setMoney(gMoney);
}else {
incomeDetail.setMoney(actualMoney);
//判断是否存在当月的商险收入数据
TIncomeDetail incomeDetail = new TIncomeDetail();
incomeDetail.setSourceId(detail.getId());
if (isBl) {
incomeDetail.setMoney(gMoney);
} 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().isEmpty()) {
//生成红冲数据
for (TIncomeDetail detailInfo : detailInfoList.getData().getDetailList()) {
TIncomeDetail detail1 = new TIncomeDetail();
BeanCopyUtils.copyProperties(detailInfo, detail1);
detail1.setId(CommonConstants.NULL);
detail1.setRedData(CommonConstants.ONE_STRING);
detail1.setMoney(detailInfo.getMoney().negate());
socialDaprUtils.createTIncomeDetail(detail1);
break;
}
//判断是否存在当月的商险收入数据
R<TIncomeDetailReturnVo> detailInfoList = socialDaprUtils.getTIncomeDetailList(incomeDetail);
if (Common.isNotNull(detailInfoList) && detailInfoList.getCode() == CommonConstants.SUCCESS
&& detailInfoList.getData().getDetailList().size() > 0) {
//生成红冲数据
for (TIncomeDetail detailInfo : detailInfoList.getData().getDetailList()) {
TIncomeDetail detail1 = new TIncomeDetail();
BeanCopyUtils.copyProperties(detailInfo, detail1);
detail1.setId(CommonConstants.NULL);
detail1.setRedData(CommonConstants.ONE_STRING);
detail1.setMoney(detailInfo.getMoney().negate());
socialDaprUtils.createTIncomeDetail(detail1);
break;
}
}
}
if (Common.isNotNull(settleDomain.getRiskServerItem()) && settleDomain.getRiskServerItem()
.contains(CommonConstants.THREE_STRING) && CommonConstants.ZERO_STRING.equals(settleDomain.getRiskFundTag())) {
if (CommonConstants.ONE_STRING.equals(settleDomain.getRiskFundType())) {
gMoney = BigDecimalUtils.safeMultiply(actualMoney,
settleDomain.getRiskFundFee().divide(new BigDecimal("100"),
CommonConstants.FIVE_INT, BigDecimal.ROUND_HALF_UP));
isBl = true;
}
//判断是否存在当月的商险收入数据
TIncomeDetail incomeDetail = new TIncomeDetail();
incomeDetail.setSourceId(detail.getId());
incomeDetail.setFeeType(CommonConstants.TWO_STRING);
if (isBl) {
incomeDetail.setMoney(gMoney);
} else {
incomeDetail.setMoney(actualMoney);
}
//判断是否存在当月的商险收入数据
R<TIncomeDetailReturnVo> detailInfoList = socialDaprUtils.getTIncomeDetailList(incomeDetail);
if (Common.isNotNull(detailInfoList) && detailInfoList.getCode() == CommonConstants.SUCCESS
&& !detailInfoList.getData().getDetailList().isEmpty()) {
//生成红冲数据
for (TIncomeDetail detailInfo : detailInfoList.getData().getDetailList()) {
TIncomeDetail detail1 = new TIncomeDetail();
BeanCopyUtils.copyProperties(detailInfo, detail1);
detail1.setId(CommonConstants.NULL);
detail1.setRedData(CommonConstants.ONE_STRING);
detail1.setMoney(detailInfo.getMoney().negate());
socialDaprUtils.createTIncomeDetail(detail1);
break;
}
}
}
}
//生成收入数据
createInsuranceInfo(detail);
}
//生成收入数据
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