Commit a2c51ff9 authored by 查济's avatar 查济

Merge branch 'feature-zhaji' into 'develop'

Feature zhaji

See merge request fangxinjiang/yifu!137
parents f3ca4cb3 a7038b59
......@@ -77,5 +77,17 @@ public class InsuranceRefundHandlingParam implements Serializable {
@Schema(description = "是否过期 0未过期 1已过期")
private Integer isOverdue;
/**
* 办理地分流sql
*/
@Schema(description = "办理地分流sql")
private String regionSql;
/**
* 办理人
*/
@Schema(description = "办理人")
private String updateBy;
}
......@@ -52,4 +52,10 @@ public class RefundExportListParam implements Serializable {
@Schema(description = "商险id集合")
private List<String> idList;
/**
* 办理地分流sql
*/
@Schema(description = "办理地分流sql")
private String regionSql;
}
......@@ -134,15 +134,6 @@ public interface TInsuranceDetailMapper extends BaseMapper<TInsuranceDetail> {
*/
IPage<RefundExportListVo> getInsuranceRefundHandlingPageList(Page<InsuranceRefundHandlingParam> page, @Param("param") InsuranceRefundHandlingParam param);
/**
* 减员办理列表不分页查询
*
* @author zhaji
* @param param 查询参数
* @return {@link List< RefundExportListVo >}
*/
List<RefundExportListVo> getInsuranceRefundHandlingList(@Param("param")InsuranceRefundHandlingParam param);
/**
* 减员办理
*
......
......@@ -2656,7 +2656,14 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
*/
@Override
public IPage<RefundExportListVo> getInsuranceRefundHandlingPageList(Page<InsuranceRefundHandlingParam> page, InsuranceRefundHandlingParam param) {
YifuUser user = SecurityUtils.getUser();
String id = user.getId();
Integer reduceHandleStatus = param.getReduceHandleStatus();
if(null != reduceHandleStatus && reduceHandleStatus != CommonConstants.ONE_INT){
param.setUpdateBy(id);
}
String regionSQL = getRegionSQL(user);
param.setRegionSql(regionSQL);
IPage<RefundExportListVo> insuranceRefundHandlingPageList = this.baseMapper.getInsuranceRefundHandlingPageList(page, param);
if (CollectionUtils.isNotEmpty(insuranceRefundHandlingPageList.getRecords())){
//根据项目编码获取项目名称
......@@ -2692,7 +2699,8 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
YifuUser user = SecurityUtils.getUser();
List<RefundExportListVo> refundExportList;
//todo 根据登录人获取数据权限
String regionSQL = getRegionSQL(user);
param.setRegionSql(regionSQL);
//如勾选项不为空,则导出勾选记录;否则导出当前筛选条件下 && 「待减员」的结果集
if (CollectionUtils.isNotEmpty(param.getIdList())){
refundExportList = baseMapper.getRefundExportListBySelect(param.getIdList());
......@@ -2740,7 +2748,6 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
for (TInsuranceRefund refund : refundList) {
tInsuranceRefundService.updateByInsDetailId(refund);
}
}
//操作记录
addOperate(detailList,user,InsurancesConstants.INSURANCE_REFUND_EXPORT);
......@@ -4178,21 +4185,21 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
deptList.add("皖M02023");
deptList.add("皖M02002");
}else{
deptList.add("A0001");
deptList.add("皖M02002");
deptList.add("皖A12345678");
deptList.add("皖B29203");
deptList.add("皖AFA10M");
deptList.add("皖AFA11F");
deptList.add("皖M02023");
deptList.add("皖M02045");
R<TSettleDomainListVo> tSettleDomainListVoR = archivesDaprUtil.selectAllSettleDomainSelectVos();
if (null != tSettleDomainListVoR && tSettleDomainListVoR.getCode() == CommonConstants.SUCCESS && Common.isNotNull(tSettleDomainListVoR.getData())) {
TSettleDomainListVo data = tSettleDomainListVoR.getData();
List<TSettleDomainSelectVo> listSelectVO = data.getListSelectVO();
for (TSettleDomainSelectVo tSettleDomainSelectVo : listSelectVO) {
deptList.add(tSettleDomainSelectVo.getDepartNo());
}
}
}
return deptList;
}
public String getRegionSQL(YifuUser user){
return null;
String sql = "detail.INSURANCE_HANDLE_PROVINCE in (12) and detail.INSURANCE_HANDLE_CITY in (135)";
return sql;
}
......
......@@ -713,12 +713,6 @@
<if test="param.deptNo != null and param.deptNo.trim() != ''">
and detail.DEPT_NO = #{param.deptNo}
</if>
<if test="param.deptNo == null or param.deptNo.trim() == ''">
and detail.DEPT_NO in
<foreach collection="param.deptNoList" index="index" item="item" open="(" separator="," close=")">
#{item}
</foreach>
</if>
<if test="param.reduceHandleStatus != null">
and detail.REDUCE_HANDLE_STATUS = #{param.reduceHandleStatus}
</if>
......@@ -728,65 +722,13 @@
<if test="param.insuranceCompanyName != null and param.insuranceCompanyName.trim() != ''">
and detail.INSURANCE_COMPANY_NAME = #{param.insuranceCompanyName}
</if>
ORDER BY refund.CREATE_TIME DESC,detail.ID ASC
</select>
<!-- 减员办理列表不分页查询-->
<select id="getInsuranceRefundHandlingList" resultType="com.yifu.cloud.plus.v1.yifu.insurances.vo.RefundExportListVo">
select
DISTINCT
detail.id as id,
detail.DEPT_NO as deptNo,
detail.EMP_NAME as empName,
detail.EMP_IDCARD_NO as empIdcardNo,
detail.BUY_TYPE as buyType,
detail.POST as post,
detail.INSURANCE_PROVINCE_NAME as insuranceProvinceName,
detail.INSURANCE_CITY_NAME as insuranceCityName,
detail.INSURANCE_HANDLE_PROVINCE_NAME as insuranceHandleProvinceName,
detail.INSURANCE_HANDLE_CITY_NAME as insuranceHandleCityName,
detail.POLICY_START as policyStart,
detail.POLICY_END as policyEnd,
detail.INSURANCE_COMPANY_NAME as insuranceCompanyName,
detail.INSURANCE_TYPE_NAME as insuranceTypeName,
detail.BUY_STANDARD as buyStandard,
detail.MEDICAL_QUOTA as medicalQuota,
detail.DIE_DISABLE_QUOTA as dieDisableQuota,
detail.SETTLE_TYPE as settleType,
detail.SETTLE_MONTH as settleMonth,
refund.CREATE_NAME as createName,
detail.REMARK as remark,
detail.REDUCE_HANDLE_STATUS as reduceHandleStatus
from
t_insurance_detail detail,
t_insurance_refund refund
where
detail.DELETE_FLAG = 0
and
detail.ID = refund.INS_DETAIL_ID
and
detail.REDUCE_HANDLE_STATUS = 1
<if test="param.empName != null and param.empName.trim() != ''">
and detail.EMP_NAME like concat('%',replace(replace(#{param.empName},'_','\_'),'%','\%'),'%')
</if>
<if test="param.empIdcardNo != null and param.empIdcardNo.trim() != ''">
and detail.EMP_IDCARD_NO like concat('%',replace(replace(#{param.empIdcardNo},'_','\_'),'%','\%'),'%')
</if>
<if test="param.deptNo != null and param.deptNo.trim() != ''">
and detail.DEPT_NO = #{param.deptNo}
</if>
<if test="param.deptNo == null or param.deptNo.trim() == ''">
and detail.DEPT_NO in
<foreach collection="param.deptNoList" index="index" item="item" open="(" separator="," close=")">
#{item}
</foreach>
</if>
<if test="param.isOverdue != null ">
and detail.IS_OVERDUE = #{param.isOverdue}
<if test="param.regionSql != null and param.regionSql.trim() != ''">
and ${param.regionSql}
</if>
<if test="param.isUse != null">
and detail.IS_USE = #{param.isUse}
<if test="param.updateBy != null and param.updateBy.trim() != ''">
and refund.UPDATE_BY = #{param.updateBy}
</if>
ORDER BY detail.REFUND_CREATE_TIME DESC
ORDER BY refund.CREATE_TIME DESC,detail.ID ASC
</select>
<!-- 查询保单列表-->
<select id="selectDetailListByIds"
......@@ -907,6 +849,9 @@
<if test="param.insuranceCompanyName != null and param.insuranceCompanyName.trim() != ''">
and detail.INSURANCE_COMPANY_NAME = #{param.insuranceCompanyName}
</if>
<if test="param.regionSql != null and param.regionSql.trim() != ''">
and ${param.regionSql}
</if>
ORDER BY detail.CREATE_TIME DESC
</select>
<!-- 减员办理-->
......
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