Commit fd421666 authored by hongguangwu's avatar hongguangwu

Merge remote-tracking branch 'origin/MVP1.7.19' into MVP1.7.19

parents 235bbe20 9af2ba87
......@@ -472,6 +472,11 @@ public class InsurancesConstants {
* 商险待投保,无法登记保单保费
*/
public static final String BUY_HANDLE_ONE_NOT_REGISTERED = "商险待投保,无法登记保单保费";
/**
* 商险待投保,无法登记保单保费
*/
public static final String BUY_HANDLE_SIX_NOT_REGISTERED = "商险待缴费,无法登记保单保费";
/**
* 商险投保中,无法登记保单保费
*/
......
package com.yifu.cloud.plus.v1.yifu.insurances.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.*;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
......@@ -116,6 +114,7 @@ public class EkpInsurancesInfo {
private String fd_3af9197b31071c;
@Schema(description = "实际结算月份")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private Date fd_3af9d11088facc;
@Schema(description = "有无预估")
......
......@@ -51,7 +51,7 @@ public class InsuranceListVO implements Serializable {
* 购买月数
*/
@Schema(description = "购买月数")
private Long buyMonth;
private String buyMonth;
/**
* 项目名称
......
......@@ -295,7 +295,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
insuranceList = baseMapper.getInsuranceListPage(page,param);
// 购买月数
if (CollectionUtils.isNotEmpty(insuranceList.getRecords())){
insuranceList.getRecords().forEach(e -> e.setBuyMonth(LocalDateUtil.betweenMonth(e.getPolicyStart().toString(),e.getPolicyEnd().toString())));
insuranceList.getRecords().forEach(e -> e.setBuyMonth(null==e.getPurchaseCycle()?String.valueOf(LocalDateUtil.betweenMonth(e.getPolicyStart().toString(),e.getPolicyEnd().toString())):(e.getPurchaseCycle().indexOf("个月")==-1?e.getPurchaseCycle():e.getPurchaseCycle().indexOf("个月")==-1?e.getPurchaseCycle():e.getPurchaseCycle().substring(0,e.getPurchaseCycle().indexOf("个月")))));
}
return insuranceList;
}
......@@ -321,7 +321,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
List<InsuranceListVO> insuranceList = baseMapper.getInsuranceList(param);
// 购买月数
if (CollectionUtils.isNotEmpty(insuranceList)){
insuranceList.forEach(e -> e.setBuyMonth(LocalDateUtil.betweenMonth(e.getPolicyStart().toString(),e.getPolicyEnd().toString())));
insuranceList.forEach(e -> e.setBuyMonth(null==e.getPurchaseCycle()?String.valueOf(LocalDateUtil.betweenMonth(e.getPolicyStart().toString(),e.getPolicyEnd().toString())):(e.getPurchaseCycle().indexOf("个月")==-1?e.getPurchaseCycle():e.getPurchaseCycle().indexOf("个月")==-1?e.getPurchaseCycle():e.getPurchaseCycle().substring(0,e.getPurchaseCycle().indexOf("个月")))));
TInsuranceOperate tInsuranceOperate;
for (InsuranceListVO listVO : insuranceList) {
if (CommonConstants.FOUR_INT == listVO.getBuyHandleStatus()) {
......@@ -365,7 +365,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
IPage<InsuranceListVO> insuranceList = baseMapper.getInsuranceHandleListPage(page,param);
// 购买月数
if (CollectionUtils.isNotEmpty(insuranceList.getRecords())){
insuranceList.getRecords().forEach(e -> e.setBuyMonth(LocalDateUtil.betweenMonth(e.getPolicyStart().toString(),e.getPolicyEnd().toString())));
insuranceList.getRecords().forEach(e -> e.setBuyMonth(null==e.getPurchaseCycle()?String.valueOf(LocalDateUtil.betweenMonth(e.getPolicyStart().toString(),e.getPolicyEnd().toString())):(e.getPurchaseCycle().indexOf("个月")==-1?e.getPurchaseCycle():e.getPurchaseCycle().indexOf("个月")==-1?e.getPurchaseCycle():e.getPurchaseCycle().substring(0,e.getPurchaseCycle().indexOf("个月")))));
}
return insuranceList;
}
......@@ -424,6 +424,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
if (CollectionUtils.isNotEmpty(listSuccess)){
List<TInsuranceSettle> settleList = new ArrayList<>();
List<String> sourceIdCardList = new ArrayList<>();
List<TInsuranceDetail> pushList = new ArrayList<>();
for (InsuranceAddParam success : listSuccess) {
TInsuranceDetail detail = new TInsuranceDetail();
BeanCopyUtils.copyProperties(success,detail);
......@@ -450,14 +451,9 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
sourceIdCardList.add(detail.getEmpIdcardNo());
baseMapper.insert(detail);
if (CommonConstants.ZERO_STRING.equals(detail.getIsJfcd())){
//生成收入数据
createInsuranceInfo(detail,mapSelectVo.get(detail.getDeptNo()));
pushList.add(detail);
updateEmployeeInsurancePre(success.getInsurancePreId(),detail,CommonConstants.SEVEN_STRING);
updateEmployeeInsurancePreRenew(success.getInsurancePreRenewId(),detail,CommonConstants.SEVEN_STRING);
//异步任务推送
List<TInsuranceDetail> successList = new ArrayList<>();
successList.add(detail);
doJointInsuranceTask.pushEstime(successList);
}else {
updateEmployeeInsurancePre(success.getInsurancePreId(),detail,CommonConstants.THREE_STRING);
updateEmployeeInsurancePreRenew(success.getInsurancePreRenewId(),detail,CommonConstants.THREE_STRING);
......@@ -470,6 +466,14 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
,InsurancesConstants.ADD,null,CommonConstants.ONE_INT));
}
}
if (Common.isNotNull(pushList)){
for (TInsuranceDetail detail : pushList){
//生成收入数据
createInsuranceInfo(detail,mapSelectVo.get(detail.getDeptNo()));
}
//异步任务推送
doJointInsuranceTask.pushEstime(pushList);
}
List<String> replaceIdList = new ArrayList<>();
for (TInsuranceDetail d : detailList) {
replaceIdList.add(d.getId());
......@@ -4758,6 +4762,10 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
param.setErrorMessage(InsurancesConstants.BUY_HANDLE_ONE_NOT_REGISTERED);
continue;
}
if (detail.getBuyHandleStatus() == CommonConstants.SIX_INT){
param.setErrorMessage(InsurancesConstants.BUY_HANDLE_SIX_NOT_REGISTERED);
continue;
}
if (detail.getBuyHandleStatus() == CommonConstants.TWO_INT){
param.setErrorMessage(InsurancesConstants.BUY_HANDLE_TWO_NOT_REGISTERED);
continue;
......
......@@ -798,6 +798,11 @@ public class DoJointInsuranceTask {
if ("0".equals(param.getIsJfcd())){
//见费出单 实缴的应收为0
info.setFd_3adfe6e30f2a3c(0.00);
//特殊处理下是否见费出单 是否全部结算为是
//见费出单 是否全部结算 都是 是
info.setFd_3b13b2ecc164aa("是");
//实际结算月份置空
info.setFd_3af9d11088facc(null);
}
insurancesInfoMapper.updateById(info);
}
......
......@@ -335,7 +335,7 @@
a.SETTLE_TYPE as settleType,
a.SETTLE_MONTH as settleMonth,
a.DEPT_NAME as projectName,
a.IS_ADRESS as isAdress
a.IS_ADRESS as isAdress,a.PURCHASE_CYCLE as purchaseCycle
from t_insurance_detail a
where a.DELETE_FLAG = 0
<if test="param.deptNo != null and param.deptNo.trim() != ''">
......
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