Commit 51316284 authored by hongguangwu's avatar hongguangwu

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

parents 7faf022e 09761585
......@@ -36,12 +36,12 @@ import java.util.List;
public interface TSettleDomainMapper extends BaseMapper<TSettleDomain> {
/**
* @param id
* @param departNo
* @Author: wangan
* @Date: 2019/10/18
* @Description: 通过id获取项目及单位部分信息
**/
TSettleDomainSelectVo selectSettleDomainSelectVosById(@Param("id") String id);
TSettleDomainSelectVo selectSettleDomainSelectVosById(@Param("departNo") String departNo);
/**
* 获取所有客户单位的项目信息
......
......@@ -95,7 +95,7 @@ public class TSettleDomainServiceImpl extends ServiceImpl<TSettleDomainMapper, T
**/
@Override
public TSettleDomainSelectVo selectSettleDomainSelectVosById(TSettleDomainSelectVo settleDomainSelectVo) {
return baseMapper.selectSettleDomainSelectVosById(settleDomainSelectVo.getId());
return baseMapper.selectSettleDomainSelectVosById(settleDomainSelectVo.getDepartNo());
}
@Override
......
......@@ -176,7 +176,7 @@
INDUSTRY_BELONG,
CUSTOMER_CODE from t_customer_info
) c ON a.CUSTOMER_ID = c.customerId
WHERE a.id=#{id} GROUP BY a.id
WHERE a.DEPART_NO=#{departNo} GROUP BY a.DEPART_NO
</select>
<select id="selectAllSettleDomainSelectVos" resultMap="tSettleDomainSelectVoMap">
......
......@@ -69,4 +69,6 @@ public class ValidityConstants {
/** 不超过两位小数的正数 */
public static final String POSITIVE_INTEGER_PATTERN_TWO_FLOAT = "^[+]?([0-9]+(.[0-9]{1,2})?)$";
/** 身份证规则(x只能大写) */
public static final String IDCARD_UPPERCASE_PATTERN = "(^[1-9]\\d{5}(18|19|20)\\d{2}((0[1-9])|(10|11|12))(([0-2][1-9])|10|20|30|31)\\d{3}[0-9X]$)|(^[1-9]\\d{5}\\d{2}((0[1-9])|(10|11|12))(([0-2][1-9])|10|20|30|31)\\d{3}$)" ;
}
......@@ -84,7 +84,7 @@ public class ArchivesDaprUtil {
**/
public R<TSettleDomainSelectVo> getSettleDomainSelectVoById(String departId){
TSettleDomainSelectVo settleDomainSelectVo = new TSettleDomainSelectVo();
settleDomainSelectVo.setId(departId);
settleDomainSelectVo.setDepartNo(departId);
R<TSettleDomainSelectVo> res = HttpDaprUtil.invokeMethodPost(daprArchivesProperties.getAppUrl(),daprArchivesProperties.getAppId(),"/tsettledomain/getSettleDomainSelectVoById",settleDomainSelectVo, TSettleDomainSelectVo.class, SecurityConstants.FROM_IN);
if (Common.isEmpty(res)){
return R.failed("获取派单校验需要的档案信息失败!");
......
......@@ -12,6 +12,6 @@ dapr.check.appId=yifu-check
dapr.archives.appUrl=http://yifu-archives.qas-mvp.svc.cluster.local:3500/v1.0/invoke/
dapr.archives.appId=yifu-archives
dapr.insurances.appUrl=http://yifu-insurances.qas-mvp.svc.cluster.local:3511/v1.0/invoke/
dapr.insurances.appUrl=http://yifu-auth.qas-mvp.svc.cluster.local:3500/v1.0/invoke/
dapr.insurances.appId=yifu-insurances
......@@ -146,9 +146,9 @@ public class InsurancesConstants {
*/
public static final String REDUCE_ROLLBACK_IS_NOT_ALLOW = "投保状态不是待投保、投保中、已投保,无法退回";
/**
* 减员中,无法退回
* 商险减员中,无法退回
*/
public static final String REDUCE_ROLLBACK_REDUCE_IS_NOT_ALLOW = "减员中,无法退回";
public static final String REDUCE_ROLLBACK_REDUCE_IS_NOT_ALLOW = "商险减员中,无法退回";
/**
* 员工姓名不能为空
*/
......@@ -190,9 +190,9 @@ public class InsurancesConstants {
*/
public static final String REPLACE_EMP_INFO_SAME = "替换信息和被替换信息一致,无法替换";
/**
* 替换员工身份证号格式
* 替换员工身份证号格式
*/
public static final String REPLACE_EMP_IDCARD_NO_NOT_LEGITIMATE = "替换员工身份证号格式误";
public static final String REPLACE_EMP_IDCARD_NO_NOT_LEGITIMATE = "替换员工身份证号格式误";
/**
* 项目编码不能为空
*/
......@@ -326,9 +326,9 @@ public class InsurancesConstants {
*/
public static final String ACTUAL_PREMIUM_EMPTY = "保费不能为空";
/**
* 保费金额格式错误
* 保费金额需要填写不大于9999999.99的正数,最多支持两位小数
*/
public static final String ACTUAL_PREMIUM_PARSE_ERROR= "保费金额格式错误";
public static final String ACTUAL_PREMIUM_PARSE_ERROR= "保费金额需要填写不大于9999999.99的正数,最多支持两位小数";
/**
* 替换类型无法登记保单保费
*/
......@@ -525,7 +525,7 @@ public class InsurancesConstants {
/**
* 商险已减员,无法变更项目
*/
public static final String DEPT_NO_CHANGE_REFUND_STATUS_ONE_ERROR = "商险减员中,无法变更项目";
public static final String DEPT_NO_CHANGE_REFUND_STATUS_ONE_ERROR = "减员流程中,无法变更项目";
/**
* 商险结算中,无法变更项目
......
......@@ -150,7 +150,7 @@ public class ValidityUtil {
if(Common.isEmpty(idCard)){
return Boolean.FALSE ;
}
return idCard.matches(ValidityConstants.IDCARD_PATTERN) ;
return idCard.matches(ValidityConstants.IDCARD_UPPERCASE_PATTERN) ;
}
/**
......
......@@ -38,6 +38,18 @@ public class DeptChangeCheckParam implements Serializable {
@Schema(description = "原项目编码")
private String oldDeptNo;
/**
* 新项目名称
*/
@Schema(description = "新项目名称")
private String newDeptName;
/**
* 原项目名称
*/
@Schema(description = "原项目名称")
private String oldDeptName;
/**
* 新项目编码
*/
......
......@@ -3,18 +3,14 @@ package com.yifu.cloud.plus.v1.yifu.insurances.controller;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
import com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceCompany;
import com.yifu.cloud.plus.v1.yifu.common.log.annotation.SysLog;
import com.yifu.cloud.plus.v1.yifu.common.security.annotation.Inner;
import com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceDetail;
import com.yifu.cloud.plus.v1.yifu.insurances.vo.Dept;
import com.yifu.cloud.plus.v1.yifu.insurances.service.TInsuranceDetailService;
import com.yifu.cloud.plus.v1.yifu.insurances.vo.*;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.security.SecurityRequirement;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor;
import org.springframework.http.HttpHeaders;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;
......@@ -33,7 +29,6 @@ import java.util.List;
@RequestMapping("/insuranceDetail")
@Tag(name = "商险相关")
@Validated
@SecurityRequirement(name = HttpHeaders.AUTHORIZATION)
public class TInsuranceDetailController {
@Resource
private TInsuranceDetailService tInsuranceDetailService;
......
......@@ -84,14 +84,6 @@ public class TInsuranceTypeStandardServiceImpl extends ServiceImpl<TInsuranceTyp
if (Common.isEmpty(byId) || CommonConstants.ONE_INT == byId.getDeleteFlag()){
return R.failed("购买标准信息不存在或已被删除");
}
LambdaQueryWrapper<TInsuranceDetail> queryWrapper = new LambdaQueryWrapper<>();
queryWrapper.eq(TInsuranceDetail::getInsuranceTypeId,byId.getInsuranceTypeId())
.eq(TInsuranceDetail::getBuyStandard,byId.getBuyStandard())
.eq(TInsuranceDetail::getDeleteFlag,CommonConstants.ZERO_INT);
List<TInsuranceDetail> list = tInsuranceDetailService.list(queryWrapper);
if (Common.isNotEmpty(list)){
return R.failed("当前险种的购买标准已存在对应的商险信息,不能删除");
}
LambdaUpdateWrapper<TInsuranceTypeStandard> updateWrapper = new LambdaUpdateWrapper<>();
updateWrapper.eq(TInsuranceTypeStandard::getId,id)
.set(TInsuranceTypeStandard::getDeleteFlag, CommonConstants.ONE_INT)
......
......@@ -88,6 +88,7 @@ public class TAgentConfigServiceImpl extends ServiceImpl<TAgentConfigMapper, TAg
if (Common.isNotNull(count)) {
return R.failed("同一城市,年度的政策不能重复新增");
}
baseMapper.insert(tAgentConfig);
return R.ok();
}
}
......@@ -2096,16 +2096,22 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
Map<String, TSocialFundInfo> socialFundMap = getSocialFundMap(idcards);
// 获取项目编码数据 以供校验
Map<String, ProjectSetInfoVo> projectVoMap = getProjectVoMap(codes);
DispatchEmpVo empVo = null;
DispatchEmpVo empVo;
TDispatchInfo dispatch;
TDispatchReduceVo excel;
TSocialFundInfo socialFund;
ProjectSetInfoVo setInfoVo = null;
ProjectSetInfoVo setInfoVo;
// 执行数据插入操作 组装
for (int i = 0; i < excelVOList.size(); i++) {
socialFund = null;
setInfoVo= null;
empVo= null;
dispatch= null;
excel = excelVOList.get(i);
setInfoVo = getSetInfoVo(projectVoMap,excel.getDepartNo());
if (Common.isNotNull(socialFundMap)){
socialFund = socialFundMap.get(excel.getEmpIdcard());
}
if (Common.isEmpty(setInfoVo)){
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_PROJECT_NOT_FOUND)));
continue;
......
......@@ -1825,6 +1825,33 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
}
}
/**
* map数据封装
*
* @param settleDomainList
* @param settleDomainNameMap
* @param customerNameMap
* @param settleIdAndCustomerIdMap
* @return
* @Author huyc
* @Date 2022-07-18
**/
private void initSettleDomainMaps(List<TSettleDomainSelectVo> settleDomainList,
Map<String, String> settleDomainNameMap,
Map<String, String> customerNameMap,
Map<String, String> settleIdAndCustomerIdMap) {
//map数据封装
if (Common.isNotNull(settleDomainList)) {
for (TSettleDomainSelectVo settleDomainSelectVo : settleDomainList) {
settleDomainNameMap.put(settleDomainSelectVo.getId(), settleDomainSelectVo.getDepartName());
settleIdAndCustomerIdMap.put(settleDomainSelectVo.getId(), settleDomainSelectVo.getCustomerId());
if (!customerNameMap.containsKey(settleDomainSelectVo.getCustomerName())) {
customerNameMap.put(settleDomainSelectVo.getCustomerId(), settleDomainSelectVo.getCustomerName());
}
}
}
}
/**
* 初始化社保公积金基数
*
......@@ -1858,33 +1885,6 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
initBaseSetMap(baseSocialTimeMap, baseFundTimeMap, baseSocialSetMap, baseFundSetMap);
}
/**
* map数据封装
*
* @param settleDomainList
* @param settleDomainNameMap
* @param customerNameMap
* @param settleIdAndCustomerIdMap
* @return
* @Author huyc
* @Date 2022-07-18
**/
private void initSettleDomainMaps(List<TSettleDomainSelectVo> settleDomainList,
Map<String, String> settleDomainNameMap,
Map<String, String> customerNameMap,
Map<String, String> settleIdAndCustomerIdMap) {
//map数据封装
if (Common.isNotNull(settleDomainList)) {
for (TSettleDomainSelectVo settleDomainSelectVo : settleDomainList) {
settleDomainNameMap.put(settleDomainSelectVo.getId(), settleDomainSelectVo.getDepartName());
settleIdAndCustomerIdMap.put(settleDomainSelectVo.getId(), settleDomainSelectVo.getCustomerId());
if (!customerNameMap.containsKey(settleDomainSelectVo.getCustomerName())) {
customerNameMap.put(settleDomainSelectVo.getCustomerId(), settleDomainSelectVo.getCustomerName());
}
}
}
}
/**
* 初始化派减的相关状态及数据
*
......
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