Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
yifu-mvp
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
fangxinjiang
yifu-mvp
Commits
6a095335
Commit
6a095335
authored
Dec 13, 2022
by
zhaji
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
"feature-zhaJi:优化商险登记保单退费的保单开始时间结束时间校验"
parent
40a2611b
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
46 additions
and
10 deletions
+46
-10
InsurancesConstants.java
...lus/v1/yifu/insurances/constants/InsurancesConstants.java
+7
-0
RefundMoneyUpdateParam.java
...ud/plus/v1/yifu/insurances/vo/RefundMoneyUpdateParam.java
+6
-0
TInsuranceDetailMapper.java
.../insurances/mapper/insurances/TInsuranceDetailMapper.java
+2
-1
TInsuranceDetailServiceImpl.java
...s/service/insurance/impl/TInsuranceDetailServiceImpl.java
+28
-7
TInsuranceDetailMapper.xml
...in/resources/mapper/insurances/TInsuranceDetailMapper.xml
+3
-2
No files found.
yifu-insurances/yifu-insurances-api/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/constants/InsurancesConstants.java
View file @
6a095335
...
...
@@ -1201,6 +1201,13 @@ public class InsurancesConstants {
*/
public
static
final
String
SETTLE_ID_ATYPISM
=
"结算id不一致"
;
/**
* 登记退保费用
*/
public
static
final
String
REGISTERED_SURRENDER_EXPENSE
=
"登记退保费用"
;
/**
* 获取项目信息失败
*/
...
...
yifu-insurances/yifu-insurances-api/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/vo/RefundMoneyUpdateParam.java
View file @
6a095335
...
...
@@ -21,6 +21,12 @@ public class RefundMoneyUpdateParam implements Serializable {
@JsonIgnore
private
String
id
;
/**
* 商险id
*/
@JsonIgnore
private
String
insDetailId
;
/**
* 员工姓名
*/
...
...
yifu-insurances/yifu-insurances-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/mapper/insurances/TInsuranceDetailMapper.java
View file @
6a095335
...
...
@@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainSelectVo
;
import
com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceDetail
;
import
com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceRefund
;
import
com.yifu.cloud.plus.v1.yifu.insurances.vo.*
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Param
;
...
...
@@ -198,7 +199,7 @@ public interface TInsuranceDetailMapper extends BaseMapper<TInsuranceDetail> {
* @param param 查询参数
* @return {@link String}
*/
String
selectRefundDetailId
(
@Param
(
"param"
)
RefundMoneyUpdateParam
param
);
TInsuranceRefund
selectRefundDetailId
(
@Param
(
"param"
)
RefundMoneyUpdateParam
param
);
/**
* 根据ID导出减员办理列表
...
...
yifu-insurances/yifu-insurances-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/service/insurance/impl/TInsuranceDetailServiceImpl.java
View file @
6a095335
...
...
@@ -5422,6 +5422,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
Map
<
String
,
List
<
RefundMoneyUpdateParam
>>
map
=
refundMoneyCheck
(
paramList
);
List
<
RefundMoneyUpdateParam
>
successList
=
map
.
get
(
InsurancesConstants
.
SUCCESS_LIST
);
List
<
TInsuranceOperate
>
insuranceOperateList
=
new
ArrayList
<>();
if
(
CollectionUtils
.
isNotEmpty
(
successList
)){
for
(
RefundMoneyUpdateParam
param
:
successList
)
{
TInsuranceRefund
insuranceRefund
=
new
TInsuranceRefund
();
...
...
@@ -5431,8 +5432,18 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
insuranceRefund
.
setUpdateBy
(
user
.
getId
());
insuranceRefund
.
setUpdateTime
(
LocalDateTime
.
now
());
tInsuranceRefundService
.
updateRefundMoney
(
insuranceRefund
);
//新增操作记录
TInsuranceOperate
insuranceOperate
=
new
TInsuranceOperate
();
insuranceOperate
.
setInsuranceDetailId
(
param
.
getInsDetailId
());
insuranceOperate
.
setCreateBy
(
user
.
getId
());
insuranceOperate
.
setCreateName
(
user
.
getNickname
());
insuranceOperate
.
setCreateTime
(
LocalDateTime
.
now
());
insuranceOperate
.
setDisplayFlag
(
CommonConstants
.
ZERO_INT
);
insuranceOperate
.
setOperateDesc
(
InsurancesConstants
.
REGISTERED_SURRENDER_EXPENSE
);
insuranceOperateList
.
add
(
insuranceOperate
);
}
}
tInsuranceOperateService
.
saveBatch
(
insuranceOperateList
);
return
R
.
ok
(
map
.
get
(
InsurancesConstants
.
ERROR_LIST
));
}
...
...
@@ -5674,15 +5685,23 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
errorList
.
add
(
param
);
continue
;
}
if
(!
LocalDateUtil
.
isDate
(
param
.
getPolicyStart
(),
LocalDateUtil
.
NORM_DATE_PATTERN
)){
param
.
setErrorMessage
(
InsurancesConstants
.
POLICY_START_PARSE_ERROR
);
errorList
.
add
(
param
);
continue
;
}
//保单结束时间
if
(
StringUtils
.
isBlank
(
param
.
getPolicyEnd
())){
param
.
setErrorMessage
(
InsurancesConstants
.
REFUND_INSURANCE_END_DATE_NOT_EMPTY
);
errorList
.
add
(
param
);
continue
;
}
//保单借宿时间
if
(!
LocalDateUtil
.
isDate
(
param
.
getPolicyEnd
(),
LocalDateUtil
.
NORM_DATE_PATTERN
)){
param
.
setErrorMessage
(
InsurancesConstants
.
POLICY_END_PARSE_ERROR
);
errorList
.
add
(
param
);
continue
;
}
//购买标准
if
(
StringUtils
.
isBlank
(
param
.
getBuyStandard
())){
param
.
setErrorMessage
(
InsurancesConstants
.
REFUND_BUY_STANDARD_NOT_EMPTY
);
errorList
.
add
(
param
);
...
...
@@ -5696,7 +5715,6 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
continue
;
}
if
(!
ValidityUtil
.
validateMoney
(
param
.
getRefundMoney
())){
param
.
setErrorMessage
(
InsurancesConstants
.
REFUND_MONEY_PARSE_ERROR
);
errorList
.
add
(
param
);
...
...
@@ -5704,13 +5722,14 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
}
//必填格式校通过后查询对应的保单信息
String
tInsuranceRefundDetailI
d
=
this
.
baseMapper
.
selectRefundDetailId
(
param
);
if
(
Common
.
isEmpty
(
tInsuranceRefundDetailI
d
)){
TInsuranceRefund
insuranceRefun
d
=
this
.
baseMapper
.
selectRefundDetailId
(
param
);
if
(
Common
.
isEmpty
(
insuranceRefun
d
)){
param
.
setErrorMessage
(
InsurancesConstants
.
REFUND_IS_NULL
);
errorList
.
add
(
param
);
continue
;
}
param
.
setId
(
tInsuranceRefundDetailId
);
param
.
setId
(
insuranceRefund
.
getId
());
param
.
setInsDetailId
(
insuranceRefund
.
getInsDetailId
());
successList
.
add
(
param
);
}
map
.
put
(
InsurancesConstants
.
ERROR_LIST
,
errorList
);
...
...
@@ -6212,6 +6231,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
//保单开始日期
String
policyStart
=
param
.
getPolicyStart
();
if
(
StringUtils
.
isBlank
(
policyStart
)){
errorList
.
add
(
param
);
param
.
setErrorMessage
(
InsurancesConstants
.
POLICY_START_NOT_EMPTY
);
continue
;
}
...
...
@@ -6238,6 +6258,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
// 保单开始日期格式校验
if
(!
LocalDateUtil
.
isDate
(
policyStart
,
LocalDateUtil
.
NORM_DATE_PATTERN
)){
param
.
setErrorMessage
(
InsurancesConstants
.
POLICY_START_PARSE_ERROR
);
errorList
.
add
(
param
);
continue
;
}
// 保单结束日期格式校验
...
...
yifu-insurances/yifu-insurances-biz/src/main/resources/mapper/insurances/TInsuranceDetailMapper.xml
View file @
6a095335
...
...
@@ -933,9 +933,10 @@
</select>
<!-- 查询保单减员退费信息-->
<select
id=
"selectRefundDetailId"
resultType=
"
String
"
>
<select
id=
"selectRefundDetailId"
resultType=
"
com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceRefund
"
>
select
refund.ID as refundId
refund.ID as id,
refund.INS_DETAIL_ID as insDetailId
from
t_insurance_detail a,
t_insurance_refund refund
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment