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
f2cf2ebc
Commit
f2cf2ebc
authored
Aug 22, 2022
by
zhaji
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
"feature-zhaJi:新增操作时的备注字段"
parent
df73b011
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
241 additions
and
243 deletions
+241
-243
InsuranceRefundHandlingParam.java
...s/v1/yifu/insurances/vo/InsuranceRefundHandlingParam.java
+18
-0
TInsuranceDetailServiceImpl.java
.../insurances/service/impl/TInsuranceDetailServiceImpl.java
+214
-243
TInsuranceDetailMapper.xml
...-biz/src/main/resources/mapper/TInsuranceDetailMapper.xml
+9
-0
No files found.
yifu-insurances/yifu-insurances-api/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/vo/InsuranceRefundHandlingParam.java
View file @
f2cf2ebc
...
@@ -89,5 +89,23 @@ public class InsuranceRefundHandlingParam implements Serializable {
...
@@ -89,5 +89,23 @@ public class InsuranceRefundHandlingParam implements Serializable {
@Schema
(
description
=
"办理人"
)
@Schema
(
description
=
"办理人"
)
private
String
updateBy
;
private
String
updateBy
;
/**
* 派单人
*/
@Schema
(
description
=
"派单人"
)
private
String
createName
;
/**
* 派单开始时间
*/
@Schema
(
description
=
"派单开始时间"
)
private
String
createStartTime
;
/**
* 派单结束时间
*/
@Schema
(
description
=
"派单结束时间"
)
private
String
createEndTime
;
}
}
yifu-insurances/yifu-insurances-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/service/impl/TInsuranceDetailServiceImpl.java
View file @
f2cf2ebc
...
@@ -323,7 +323,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -323,7 +323,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
this
.
saveBatch
(
detailList
);
this
.
saveBatch
(
detailList
);
}
}
//操作记录
//操作记录
addOperate
(
detailList
,
user
,
InsurancesConstants
.
ADD
);
addOperate
(
detailList
,
user
,
InsurancesConstants
.
ADD
,
null
);
return
R
.
ok
(
listResult
,
InsurancesConstants
.
ADD_SUCCESS
);
return
R
.
ok
(
listResult
,
InsurancesConstants
.
ADD_SUCCESS
);
}
}
...
@@ -368,7 +368,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -368,7 +368,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
this
.
saveBatch
(
detailList
);
this
.
saveBatch
(
detailList
);
}
}
//操作记录
//操作记录
addOperate
(
detailList
,
user
,
InsurancesConstants
.
BATCH
);
addOperate
(
detailList
,
user
,
InsurancesConstants
.
BATCH
,
null
);
return
R
.
ok
(
listResult
,
InsurancesConstants
.
BATCH_SUCCESS
);
return
R
.
ok
(
listResult
,
InsurancesConstants
.
BATCH_SUCCESS
);
}
}
...
@@ -468,7 +468,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -468,7 +468,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
}
}
}
}
//操作记录
//操作记录
addOperate
(
detailList
,
user
,
InsurancesConstants
.
REPLACE
);
addOperate
(
detailList
,
user
,
InsurancesConstants
.
REPLACE
,
null
);
return
R
.
ok
(
listResult
,
InsurancesConstants
.
REPLACE_SUCCESS
);
return
R
.
ok
(
listResult
,
InsurancesConstants
.
REPLACE_SUCCESS
);
}
}
...
@@ -500,7 +500,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -500,7 +500,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
byId
.
setDeleteFlag
(
CommonConstants
.
ONE_INT
);
byId
.
setDeleteFlag
(
CommonConstants
.
ONE_INT
);
this
.
updateById
(
byId
);
this
.
updateById
(
byId
);
//操作记录
//操作记录
addOperate
(
Arrays
.
asList
(
byId
),
user
,
InsurancesConstants
.
DELETE
);
addOperate
(
Arrays
.
asList
(
byId
),
user
,
InsurancesConstants
.
DELETE
,
null
);
return
R
.
ok
(
InsurancesConstants
.
OPERATE_SUCCESS
);
return
R
.
ok
(
InsurancesConstants
.
OPERATE_SUCCESS
);
}
}
...
@@ -756,7 +756,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -756,7 +756,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
return
R
.
failed
(
InsurancesConstants
.
EDIT_NOT_ALLOW
);
return
R
.
failed
(
InsurancesConstants
.
EDIT_NOT_ALLOW
);
}
}
//操作记录
//操作记录
addOperate
(
Arrays
.
asList
(
byId
),
user
,
InsurancesConstants
.
EDIT
);
addOperate
(
Arrays
.
asList
(
byId
),
user
,
InsurancesConstants
.
EDIT
,
null
);
return
R
.
ok
(
InsurancesConstants
.
OPERATE_SUCCESS
);
return
R
.
ok
(
InsurancesConstants
.
OPERATE_SUCCESS
);
}
}
...
@@ -850,7 +850,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -850,7 +850,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
this
.
saveOrUpdateBatch
(
detailList
);
this
.
saveOrUpdateBatch
(
detailList
);
}
}
//操作记录
//操作记录
addOperate
(
detailList
,
user
,
InsurancesConstants
.
EXPORT
);
addOperate
(
detailList
,
user
,
InsurancesConstants
.
EXPORT
,
null
);
//针对是替换类型的做处理,每一条替换数据对应一条被替换数据
//针对是替换类型的做处理,每一条替换数据对应一条被替换数据
List
<
InsuranceExportListVO
>
listVOS
=
insuranceExportList
.
stream
().
filter
(
e
->
e
.
getBuyType
()
==
CommonConstants
.
FOUR_INT
).
collect
(
Collectors
.
toList
());
List
<
InsuranceExportListVO
>
listVOS
=
insuranceExportList
.
stream
().
filter
(
e
->
e
.
getBuyType
()
==
CommonConstants
.
FOUR_INT
).
collect
(
Collectors
.
toList
());
...
@@ -1008,7 +1008,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -1008,7 +1008,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
//根据项目编码获取项目名称
//根据项目编码获取项目名称
setProjectNameByDeptNo
(
errorList
);
setProjectNameByDeptNo
(
errorList
);
//操作记录
//操作记录
addOperate
(
successList
,
user
,
InsurancesConstants
.
ROLLBACK
);
addOperate
(
successList
,
user
,
InsurancesConstants
.
ROLLBACK
,
null
);
return
R
.
ok
(
errorList
,
InsurancesConstants
.
OPERATE_SUCCESS
);
return
R
.
ok
(
errorList
,
InsurancesConstants
.
OPERATE_SUCCESS
);
}
}
...
@@ -1168,7 +1168,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -1168,7 +1168,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
//根据项目编码获取项目名称
//根据项目编码获取项目名称
setProjectNameByDeptNo
(
errorList
);
setProjectNameByDeptNo
(
errorList
);
//操作记录
//操作记录
addOperate
(
successList
,
user
,
InsurancesConstants
.
SUCCESSFUL
);
addOperate
(
successList
,
user
,
InsurancesConstants
.
SUCCESSFUL
,
null
);
return
R
.
ok
(
errorList
,
InsurancesConstants
.
OPERATE_SUCCESS
);
return
R
.
ok
(
errorList
,
InsurancesConstants
.
OPERATE_SUCCESS
);
}
}
...
@@ -1271,7 +1271,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -1271,7 +1271,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
}
}
}
}
//操作记录
//操作记录
addOperate
(
detailList
,
user
,
InsurancesConstants
.
REGISTERED
);
addOperate
(
detailList
,
user
,
InsurancesConstants
.
REGISTERED
,
null
);
return
R
.
ok
(
listResult
,
InsurancesConstants
.
OPERATE_SUCCESS
);
return
R
.
ok
(
listResult
,
InsurancesConstants
.
OPERATE_SUCCESS
);
}
}
...
@@ -2601,7 +2601,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -2601,7 +2601,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
* @param operateDesc 操作描述
* @param operateDesc 操作描述
* @return void
* @return void
*/
*/
private
void
addOperate
(
List
<
TInsuranceDetail
>
detailList
,
YifuUser
user
,
String
operateDesc
){
private
void
addOperate
(
List
<
TInsuranceDetail
>
detailList
,
YifuUser
user
,
String
operateDesc
,
String
remark
){
if
(
CollectionUtils
.
isNotEmpty
(
detailList
)){
if
(
CollectionUtils
.
isNotEmpty
(
detailList
)){
try
{
try
{
List
<
TInsuranceOperate
>
operateList
=
new
ArrayList
<>();
List
<
TInsuranceOperate
>
operateList
=
new
ArrayList
<>();
...
@@ -2962,7 +2962,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -2962,7 +2962,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
}
}
}
}
//操作记录
//操作记录
addOperate
(
detailList
,
user
,
InsurancesConstants
.
INSURANCE_REFUND_EXPORT
);
addOperate
(
detailList
,
user
,
InsurancesConstants
.
INSURANCE_REFUND_EXPORT
,
null
);
}
}
return
R
.
ok
(
refundExportList
);
return
R
.
ok
(
refundExportList
);
}
}
...
@@ -3034,9 +3034,9 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -3034,9 +3034,9 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
updateBatchById
(
successList
);
updateBatchById
(
successList
);
//操作记录
//操作记录
if
(
CommonConstants
.
FOUR_INT
==
refundType
){
if
(
CommonConstants
.
FOUR_INT
==
refundType
){
addOperate
(
successList
,
user
,
InsurancesConstants
.
INSURANCE_REFUND_SUCCESS
);
addOperate
(
successList
,
user
,
InsurancesConstants
.
INSURANCE_REFUND_SUCCESS
,
null
);
}
else
{
}
else
{
addOperate
(
successList
,
user
,
InsurancesConstants
.
INSURANCE_REFUND_FAILED
);
addOperate
(
successList
,
user
,
InsurancesConstants
.
INSURANCE_REFUND_FAILED
,
null
);
}
}
return
R
.
ok
(
errorList
,
"操作成功"
);
return
R
.
ok
(
errorList
,
"操作成功"
);
}
}
...
@@ -3135,205 +3135,210 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -3135,205 +3135,210 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
if
(
CollectionUtils
.
isNotEmpty
(
successList
)){
if
(
CollectionUtils
.
isNotEmpty
(
successList
)){
threadPool
.
execute
(()
->
{
threadPool
.
execute
(()
->
{
for
(
DeptChangeCheckParam
success
:
successList
)
{
for
(
DeptChangeCheckParam
success
:
successList
)
{
EKPInteractiveParam
interactiveParam
=
new
EKPInteractiveParam
();
//新的结算信息
TInsuranceDetail
one
=
getOne
(
lambdaQuery
().
getWrapper
().
eq
(
TInsuranceDetail:
:
getId
,
success
.
getId
()));
TInsuranceSettle
newInsuranceSettle
=
new
TInsuranceSettle
();
BeanCopyUtils
.
copyProperties
(
one
,
interactiveParam
);
//实际保费
//更新新的客户,项目信息
BigDecimal
actualPremium
=
success
.
getActualPremium
();
LambdaUpdateWrapper
<
TInsuranceDetail
>
updateWrapper
=
new
LambdaUpdateWrapper
<>();
//预估保费
Integer
oldSettleType
=
success
.
getOldSettleType
();
BigDecimal
estimatePremium
=
success
.
getEstimatePremium
();
Integer
newSettleType
=
success
.
getNewSettleType
();
//EKP推送类
updateWrapper
.
eq
(
TInsuranceDetail
::
getId
,
success
.
getId
())
EKPInteractiveParam
interactiveParam
=
new
EKPInteractiveParam
();
TInsuranceDetail
one
=
getOne
(
lambdaQuery
().
getWrapper
().
eq
(
TInsuranceDetail:
:
getId
,
success
.
getId
()));
BeanCopyUtils
.
copyProperties
(
one
,
interactiveParam
);
LambdaUpdateWrapper
<
TInsuranceDetail
>
updateWrapper
=
new
LambdaUpdateWrapper
<>();
Integer
oldSettleType
=
success
.
getOldSettleType
();
Integer
newSettleType
=
success
.
getNewSettleType
();
//更新新的项目编码,结算方式,预估保费,实际保费
updateWrapper
.
eq
(
TInsuranceDetail
::
getId
,
success
.
getId
())
.
set
(
TInsuranceDetail
::
getDeptNo
,
success
.
getNewDeptNo
())
.
set
(
TInsuranceDetail
::
getDeptNo
,
success
.
getNewDeptNo
())
.
set
(
TInsuranceDetail
::
getSettleType
,
success
.
getNewSettleType
())
.
set
(
TInsuranceDetail
::
getSettleType
,
newSettleType
)
.
set
(
TInsuranceDetail
::
getActualPremium
,
actualPremium
)
.
set
(
TInsuranceDetail
::
getEstimatePremium
,
estimatePremium
)
.
set
(
TInsuranceDetail
::
getUpdateBy
,
user
.
getId
())
.
set
(
TInsuranceDetail
::
getUpdateBy
,
user
.
getId
())
.
set
(
TInsuranceDetail
::
getUpdateTime
,
LocalDateTime
.
now
());
.
set
(
TInsuranceDetail
::
getUpdateTime
,
LocalDateTime
.
now
());
String
insuranceDetailId
=
success
.
getId
();
//更新项目编码
//结算信息id
update
(
updateWrapper
);
String
defaultSettleId
=
success
.
getDefaultSettleId
();
//商险id
//实际保费
String
insuranceDetailId
=
success
.
getId
();
BigDecimal
actualPremium
=
success
.
getActualPremium
();
//旧结算信息id
//如果变更前为单独结算
String
oldDefaultSettleId
=
success
.
getDefaultSettleId
();
if
(
CommonConstants
.
ONE_INT
==
oldSettleType
){
//如果变更前为单独结算
//登记了保单保费
if
(
CommonConstants
.
ONE_INT
==
oldSettleType
){
if
(!
BigDecimalUtils
.
isNullOrZero
(
actualPremium
))
{
//登记了保单保费
//根据旧的结算id获取旧的结算信息
if
(!
BigDecimalUtils
.
isNullOrZero
(
actualPremium
))
{
TInsuranceSettle
byId
=
tInsuranceSettleService
.
getById
(
defaultSettleId
);
newInsuranceSettle
.
setInsDetailId
(
insuranceDetailId
);
//作废旧的数据,生成作废结算信息记录
newInsuranceSettle
.
setSettleType
(
newSettleType
);
TInsuranceSettleCancel
cancel
=
new
TInsuranceSettleCancel
();
newInsuranceSettle
.
setIsEstimatePush
(
CommonConstants
.
ZERO_INT
);
cancel
.
setDeptNo
(
success
.
getOldDeptNo
());
newInsuranceSettle
.
setIsActualPush
(
CommonConstants
.
ZERO_INT
);
cancel
.
setInsDetailId
(
success
.
getId
());
newInsuranceSettle
.
setSettleHandleStatus
(
CommonConstants
.
ONE_STRING
);
cancel
.
setSettleId
(
defaultSettleId
);
newInsuranceSettle
.
setCreateTime
(
LocalDateTime
.
now
());
cancel
.
setCreateUesr
(
user
.
getId
());
newInsuranceSettle
.
setActualPremium
(
actualPremium
);
cancel
.
setCreateTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setEstimatePremium
(
estimatePremium
);
cancel
.
setDeptName
(
success
.
getOldDeptName
());
//存储新的结算信息
cancel
.
setIsCancelPush
(
CommonConstants
.
ZERO_INT
);
tInsuranceSettleService
.
save
(
newInsuranceSettle
);
tInsuranceSettleCancelService
.
save
(
cancel
);
updateWrapper
.
set
(
TInsuranceDetail:
:
getDefaultSettleId
,
newInsuranceSettle
.
getId
());
//如果已经推送过实际保费,则先作废,再推送新的实际保费
//更新新的结算信息
if
(
byId
.
getIsActualPush
()
==
CommonConstants
.
ONE_INT
)
{
update
(
updateWrapper
);
//TODO: 2022/8/2
//根据旧的结算id获取旧的结算信息
//推送至EKP执行作废操作
TInsuranceSettle
byId
=
tInsuranceSettleService
.
getById
(
oldDefaultSettleId
);
interactiveParam
.
setActualPremium
(
one
.
getActualPremium
());
//作废旧的数据,生成作废结算信息记录
interactiveParam
.
setCustomerCode
(
success
.
getOldCustomerCode
());
TInsuranceSettleCancel
cancel
=
new
TInsuranceSettleCancel
();
interactiveParam
.
setCustomerName
(
success
.
getOldCustomerName
());
cancel
.
setDeptNo
(
success
.
getOldDeptNo
());
interactiveParam
.
setDeptNo
(
success
.
getOldDeptNo
());
cancel
.
setInsDetailId
(
insuranceDetailId
);
interactiveParam
.
setDeptName
(
success
.
getOldDeptName
());
cancel
.
setSettleId
(
oldDefaultSettleId
);
interactiveParam
.
setInteractiveType
(
CommonConstants
.
THREE_INT
);
cancel
.
setCreateUesr
(
user
.
getId
());
String
deleteBody
=
EKPUtil
.
sendToEKP
(
interactiveParam
);
cancel
.
setCreateTime
(
LocalDateTime
.
now
());
if
(
StringUtils
.
isNotBlank
(
deleteBody
))
{
cancel
.
setDeptName
(
success
.
getOldDeptName
());
//推送成功更新作废推送状态
cancel
.
setIsCancelPush
(
CommonConstants
.
ZERO_INT
);
cancel
.
setIsCancelPush
(
CommonConstants
.
ONE_INT
);
tInsuranceSettleCancelService
.
save
(
cancel
);
tInsuranceSettleCancelService
.
updateById
(
cancel
);
//如果已经推送过实际保费,则先作废,再推送新的实际保费
//变更后为单独结算
if
(
byId
.
getIsActualPush
()
==
CommonConstants
.
ONE_INT
)
{
if
(
CommonConstants
.
ONE_INT
==
newSettleType
)
{
//TODO: 2022/8/2
//生成新的结算信息
//推送至EKP执行作废操作
TInsuranceSettle
newInsuranceSettle
=
new
TInsuranceSettle
();
interactiveParam
.
setActualPremium
(
one
.
getActualPremium
());
newInsuranceSettle
.
setInsDetailId
(
insuranceDetailId
);
interactiveParam
.
setCustomerCode
(
success
.
getOldCustomerCode
());
newInsuranceSettle
.
setSettleType
(
newSettleType
);
interactiveParam
.
setCustomerName
(
success
.
getOldCustomerName
());
newInsuranceSettle
.
setIsEstimatePush
(
CommonConstants
.
ZERO_INT
);
interactiveParam
.
setDeptNo
(
success
.
getOldDeptNo
());
newInsuranceSettle
.
setIsActualPush
(
CommonConstants
.
ZERO_INT
);
interactiveParam
.
setDeptName
(
success
.
getOldDeptName
());
newInsuranceSettle
.
setSettleHandleStatus
(
CommonConstants
.
ONE_STRING
);
interactiveParam
.
setInteractiveType
(
CommonConstants
.
THREE_INT
);
newInsuranceSettle
.
setCreateTime
(
LocalDateTime
.
now
());
String
deleteBody
=
EKPUtil
.
sendToEKP
(
interactiveParam
);
newInsuranceSettle
.
setActualPremium
(
success
.
getActualPremium
());
if
(
StringUtils
.
isNotBlank
(
deleteBody
))
{
tInsuranceSettleService
.
save
(
newInsuranceSettle
);
//推送成功更新作废推送状态
//赋值新的结算信息id
cancel
.
setIsCancelPush
(
CommonConstants
.
ONE_INT
);
updateWrapper
.
set
(
TInsuranceDetail:
:
getDefaultSettleId
,
newInsuranceSettle
.
getId
());
tInsuranceSettleCancelService
.
updateById
(
cancel
);
update
(
updateWrapper
);
//变更后为单独结算
// TODO: 2022/8/2
if
(
CommonConstants
.
ONE_INT
==
newSettleType
)
{
//推送新的结算信息至EKP
//推送新的结算信息至EKP
interactiveParam
.
setSettleType
(
CommonConstants
.
ONE_INT
);
interactiveParam
.
setInteractiveType
(
CommonConstants
.
ONE_INT
);
interactiveParam
.
setCustomerCode
(
success
.
getNewCustomerCode
());
interactiveParam
.
setCustomerName
(
success
.
getNewCustomerName
());
interactiveParam
.
setDeptNo
(
success
.
getNewDeptNo
());
interactiveParam
.
setDeptName
(
success
.
getNewDeptName
());
interactiveParam
.
setActualPremium
(
success
.
getActualPremium
());
String
addBody
=
EKPUtil
.
sendToEKP
(
interactiveParam
);
if
(
StringUtils
.
isNotBlank
(
addBody
)){
newInsuranceSettle
.
setActualPushTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setIsActualPush
(
CommonConstants
.
ONE_INT
);
newInsuranceSettle
.
setUpdateTime
(
LocalDateTime
.
now
());
tInsuranceSettleService
.
updateById
(
newInsuranceSettle
);
}
else
{
//异常处理 // TODO: 2022/8/9
}
}
//变更后为合并结算
if
(
CommonConstants
.
ZERO_INT
==
newSettleType
)
{
// TODO: 2022/8/2
//先推送预估,再推送实际
interactiveParam
.
setCustomerCode
(
success
.
getNewCustomerCode
());
interactiveParam
.
setCustomerName
(
success
.
getNewCustomerName
());
interactiveParam
.
setDeptNo
(
success
.
getNewDeptNo
());
interactiveParam
.
setDeptName
(
success
.
getNewDeptName
());
interactiveParam
.
setInteractiveType
(
CommonConstants
.
ONE_INT
);
//推送预估单
interactiveParam
.
setEstimatePremium
(
success
.
getEstimatePremium
());
interactiveParam
.
setActualPremium
(
null
);
interactiveParam
.
setSettleType
(
CommonConstants
.
ZERO_INT
);
String
estimateBody
=
EKPUtil
.
sendToEKP
(
interactiveParam
);
if
(
StringUtils
.
isNotBlank
(
estimateBody
))
{
newInsuranceSettle
.
setEstimatePushTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setIsEstimatePush
(
CommonConstants
.
ONE_INT
);
newInsuranceSettle
.
setUpdateTime
(
LocalDateTime
.
now
());
tInsuranceSettleService
.
updateById
(
newInsuranceSettle
);
//推送实缴单
interactiveParam
.
setSettleType
(
CommonConstants
.
ONE_INT
);
interactiveParam
.
setSettleType
(
CommonConstants
.
ONE_INT
);
interactiveParam
.
setInteractiveType
(
CommonConstants
.
ONE_INT
);
interactiveParam
.
setEstimatePremium
(
null
);
interactiveParam
.
setCustomerCode
(
success
.
getNewCustomerCode
());
interactiveParam
.
setCustomerName
(
success
.
getNewCustomerName
());
interactiveParam
.
setDeptNo
(
success
.
getNewDeptNo
());
interactiveParam
.
setDeptName
(
success
.
getNewDeptName
());
interactiveParam
.
setActualPremium
(
success
.
getActualPremium
());
interactiveParam
.
setActualPremium
(
success
.
getActualPremium
());
String
addBody
=
EKPUtil
.
sendToEKP
(
interactiveParam
);
String
actualBody
=
EKPUtil
.
sendToEKP
(
interactiveParam
);
if
(
StringUtils
.
isNotBlank
(
addBody
)){
if
(
StringUtils
.
isNotBlank
(
actualBody
))
{
//推送成功后更新本地推送状态
newInsuranceSettle
.
setActualPushTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setActualPushTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setIsActualPush
(
CommonConstants
.
ONE_INT
);
newInsuranceSettle
.
setIsActualPush
(
CommonConstants
.
ONE_INT
);
newInsuranceSettle
.
setUpdateTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setUpdateTime
(
LocalDateTime
.
now
());
tInsuranceSettleService
.
updateById
(
newInsuranceSettle
);
tInsuranceSettleService
.
updateById
(
newInsuranceSettle
);
}
else
{
}
else
{
//异常处理 // TODO: 2022/8/9
}
}
//变更后为合并结算
if
(
CommonConstants
.
ZERO_INT
==
newSettleType
)
{
//新增新的结算信息
TInsuranceSettle
newInsuranceSettle
=
new
TInsuranceSettle
();
newInsuranceSettle
.
setInsDetailId
(
insuranceDetailId
);
newInsuranceSettle
.
setSettleType
(
newSettleType
);
newInsuranceSettle
.
setIsEstimatePush
(
CommonConstants
.
ZERO_INT
);
newInsuranceSettle
.
setIsActualPush
(
CommonConstants
.
ZERO_INT
);
newInsuranceSettle
.
setSettleHandleStatus
(
CommonConstants
.
ONE_STRING
);
newInsuranceSettle
.
setCreateTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setActualPremium
(
success
.
getActualPremium
());
newInsuranceSettle
.
setEstimatePremium
(
success
.
getEstimatePremium
());
//生成新的结算信息
tInsuranceSettleService
.
save
(
newInsuranceSettle
);
//赋值新的预估费用和新的结算信息
updateWrapper
.
set
(
TInsuranceDetail:
:
getEstimatePremium
,
success
.
getEstimatePremium
());
updateWrapper
.
set
(
TInsuranceDetail:
:
getDefaultSettleId
,
newInsuranceSettle
.
getId
());
update
(
updateWrapper
);
//推送EKP
// TODO: 2022/8/2
//先推送预估,再推送实际
interactiveParam
.
setCustomerCode
(
success
.
getNewCustomerCode
());
interactiveParam
.
setCustomerName
(
success
.
getNewCustomerName
());
interactiveParam
.
setDeptNo
(
success
.
getNewDeptNo
());
interactiveParam
.
setDeptName
(
success
.
getNewDeptName
());
interactiveParam
.
setInteractiveType
(
CommonConstants
.
ONE_INT
);
//推送预估单
interactiveParam
.
setEstimatePremium
(
success
.
getEstimatePremium
());
interactiveParam
.
setActualPremium
(
null
);
interactiveParam
.
setSettleType
(
CommonConstants
.
ZERO_INT
);
String
estimateBody
=
EKPUtil
.
sendToEKP
(
interactiveParam
);
if
(
StringUtils
.
isNotBlank
(
estimateBody
))
{
newInsuranceSettle
.
setEstimatePushTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setIsEstimatePush
(
CommonConstants
.
ONE_INT
);
newInsuranceSettle
.
setUpdateTime
(
LocalDateTime
.
now
());
tInsuranceSettleService
.
updateById
(
newInsuranceSettle
);
//推送实缴单
interactiveParam
.
setSettleType
(
CommonConstants
.
ONE_INT
);
interactiveParam
.
setEstimatePremium
(
null
);
interactiveParam
.
setActualPremium
(
success
.
getActualPremium
());
String
actualBody
=
EKPUtil
.
sendToEKP
(
interactiveParam
);
if
(
StringUtils
.
isNotBlank
(
actualBody
))
{
//推送成功后更新本地推送状态
newInsuranceSettle
.
setActualPushTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setIsActualPush
(
CommonConstants
.
ONE_INT
);
newInsuranceSettle
.
setUpdateTime
(
LocalDateTime
.
now
());
tInsuranceSettleService
.
updateById
(
newInsuranceSettle
);
}
else
{
//异常处理 // TODO: 2022/8/9
//异常处理 // TODO: 2022/8/9
}
}
}
}
}
}
}
}
else
{
//异常处理 // TODO: 2022/8/9
}
}
}
else
{
// TODO: 2022/8/9 已有实缴但是未推送属于异常,暂时不推
}
}
//未登记保单保费
}
if
(
BigDecimalUtils
.
isNullOrZero
(
actualPremium
)){
//未登记保单保费
//变更后为单独结算
if
(
BigDecimalUtils
.
isNullOrZero
(
actualPremium
)){
if
(
CommonConstants
.
ONE_INT
==
newSettleType
){
//变更后为单独结算
//变更项目且不做处理
if
(
CommonConstants
.
ONE_INT
==
newSettleType
){
update
(
updateWrapper
);
//变更项目且不做处理
}
//update(updateWrapper);
//变更后为合并结算
}
if
(
CommonConstants
.
ZERO_INT
==
newSettleType
){
//变更后为合并结算
//生成预估结算信息
if
(
CommonConstants
.
ZERO_INT
==
newSettleType
){
TInsuranceSettle
tInsuranceSettle
=
new
TInsuranceSettle
();
//生成预估结算信息
tInsuranceSettle
.
setInsDetailId
(
success
.
getId
()
);
TInsuranceSettle
tInsuranceSettle
=
new
TInsuranceSettle
(
);
tInsuranceSettle
.
setSettleType
(
success
.
getNewSettleType
());
tInsuranceSettle
.
setInsDetailId
(
success
.
getId
());
tInsuranceSettle
.
setSettleHandleStatus
(
CommonConstants
.
ONE_STRING
);
tInsuranceSettle
.
setSettleType
(
success
.
getNewSettleType
()
);
tInsuranceSettle
.
setEstimatePremium
(
success
.
getEstimatePremium
()
);
tInsuranceSettle
.
setSettleHandleStatus
(
CommonConstants
.
ONE_STRING
);
tInsuranceSettle
.
setIsActualPush
(
CommonConstants
.
ZERO_INT
);
tInsuranceSettle
.
setEstimatePremium
(
estimatePremium
);
tInsuranceSettle
.
setIsEstimate
Push
(
CommonConstants
.
ZERO_INT
);
tInsuranceSettle
.
setIsActual
Push
(
CommonConstants
.
ZERO_INT
);
tInsuranceSettle
.
setCreateTime
(
LocalDateTime
.
now
()
);
tInsuranceSettle
.
setIsEstimatePush
(
CommonConstants
.
ZERO_INT
);
tInsuranceSettleService
.
save
(
tInsuranceSettle
);
tInsuranceSettle
.
setCreateTime
(
LocalDateTime
.
now
()
);
//将结算id赋值给保单信息,并新增预估费用
tInsuranceSettleService
.
save
(
tInsuranceSettle
);
updateWrapper
.
set
(
TInsuranceDetail
::
getEstimatePremium
,
success
.
getEstimatePremium
())
//将结算id赋值给保单信息,并新增预估费用
.
set
(
TInsuranceDetail
::
getDefaultSettleId
,
tInsuranceSettle
.
getId
());
updateWrapper
.
set
(
TInsuranceDetail
::
getDefaultSettleId
,
tInsuranceSettle
.
getId
());
update
(
updateWrapper
);
update
(
updateWrapper
);
//推送结算信息至EKP
//推送结算信息至EKP
// TODO: 2022/8/2
// TODO: 2022/8/2
interactiveParam
.
setCustomerCode
(
success
.
getNewCustomerCode
());
interactiveParam
.
setCustomerCode
(
success
.
getNewCustomerCode
());
interactiveParam
.
setCustomerName
(
success
.
getNewCustomerName
());
interactiveParam
.
setCustomerName
(
success
.
getNewCustomerName
());
interactiveParam
.
setDeptNo
(
success
.
getNewDeptNo
());
interactiveParam
.
setDeptNo
(
success
.
getNewDeptNo
());
interactiveParam
.
setDeptName
(
success
.
getNewDeptName
());
interactiveParam
.
setDeptName
(
success
.
getNewDeptName
());
interactiveParam
.
setInteractiveType
(
CommonConstants
.
ONE_INT
);
interactiveParam
.
setInteractiveType
(
CommonConstants
.
ONE_INT
);
interactiveParam
.
setEstimatePremium
(
success
.
getEstimatePremium
());
interactiveParam
.
setEstimatePremium
(
success
.
getEstimatePremium
());
interactiveParam
.
setActualPremium
(
null
);
interactiveParam
.
setActualPremium
(
null
);
interactiveParam
.
setSettleType
(
CommonConstants
.
ZERO_INT
);
interactiveParam
.
setSettleType
(
CommonConstants
.
ZERO_INT
);
String
estimateBody
=
EKPUtil
.
sendToEKP
(
interactiveParam
);
String
estimateBody
=
EKPUtil
.
sendToEKP
(
interactiveParam
);
if
(
StringUtils
.
isNotBlank
(
estimateBody
)){
if
(
StringUtils
.
isNotBlank
(
estimateBody
)){
//推送成功后更新本地推送状态
//推送成功后更新本地推送状态
tInsuranceSettle
.
setIsEstimatePush
(
CommonConstants
.
ONE_INT
);
tInsuranceSettle
.
setIsEstimatePush
(
CommonConstants
.
ONE_INT
);
tInsuranceSettle
.
setEstimatePushTime
(
LocalDateTime
.
now
());
tInsuranceSettle
.
setEstimatePushTime
(
LocalDateTime
.
now
());
tInsuranceSettle
.
setUpdateTime
(
LocalDateTime
.
now
());
tInsuranceSettle
.
setUpdateTime
(
LocalDateTime
.
now
());
tInsuranceSettleService
.
updateById
(
tInsuranceSettle
);
tInsuranceSettleService
.
updateById
(
tInsuranceSettle
);
}
else
{
}
else
{
//异常处理 // TODO: 2022/8/9
//异常处理 // TODO: 2022/8/9
}
}
}
}
}
}
}
//变更前为合并结算
}
if
(
CommonConstants
.
ZERO_INT
==
oldSettleType
){
//变更前为合并结算
//如果已经登记保费
if
(
CommonConstants
.
ZERO_INT
==
oldSettleType
){
if
(!
BigDecimalUtils
.
isNullOrZero
(
actualPremium
)){
//作废旧的结算信息
//作废旧的结算信息
TInsuranceSettleCancel
cancel
=
new
TInsuranceSettleCancel
();
TInsuranceSettleCancel
cancel
=
new
TInsuranceSettleCancel
();
cancel
.
setDeptNo
(
success
.
getOldDeptNo
());
cancel
.
setDeptNo
(
success
.
getOldDeptNo
());
cancel
.
setInsDetailId
(
success
.
getId
());
cancel
.
setInsDetailId
(
success
.
getId
());
cancel
.
setSettleId
(
oldDefaultSettleId
);
cancel
.
setSettleId
(
defaultSettleId
);
cancel
.
setCreateUesr
(
user
.
getId
());
cancel
.
setCreateUesr
(
user
.
getId
());
cancel
.
setCreateTime
(
LocalDateTime
.
now
());
cancel
.
setCreateTime
(
LocalDateTime
.
now
());
cancel
.
setDeptName
(
success
.
getOldDeptName
());
cancel
.
setDeptName
(
success
.
getOldDeptName
());
cancel
.
setIsCancelPush
(
CommonConstants
.
ZERO_INT
);
cancel
.
setIsCancelPush
(
CommonConstants
.
ZERO_INT
);
tInsuranceSettleCancelService
.
save
(
cancel
);
tInsuranceSettleCancelService
.
save
(
cancel
);
TInsuranceSettle
byId
=
tInsuranceSettleService
.
getById
(
oldDefaultSettleId
);
//如果已经登记保费
if
(!
BigDecimalUtils
.
isNullOrZero
(
actualPremium
)){
//新增新的结算信息
newInsuranceSettle
.
setInsDetailId
(
insuranceDetailId
);
newInsuranceSettle
.
setSettleType
(
newSettleType
);
newInsuranceSettle
.
setIsEstimatePush
(
CommonConstants
.
ZERO_INT
);
newInsuranceSettle
.
setIsActualPush
(
CommonConstants
.
ZERO_INT
);
newInsuranceSettle
.
setSettleHandleStatus
(
CommonConstants
.
ONE_STRING
);
newInsuranceSettle
.
setCreateTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setActualPremium
(
success
.
getActualPremium
());
newInsuranceSettle
.
setEstimatePremium
(
success
.
getEstimatePremium
());
tInsuranceSettleService
.
save
(
newInsuranceSettle
);
updateWrapper
.
set
(
TInsuranceDetail
::
getDefaultSettleId
,
newInsuranceSettle
.
getId
());
update
(
updateWrapper
);
if
(
byId
.
getIsActualPush
()
==
CommonConstants
.
ONE_INT
&&
byId
.
getIsEstimatePush
()
==
CommonConstants
.
ONE_INT
){
//推送作废结算信息至EKP
//推送作废结算信息至EKP
// TODO: 2022/8/2
// TODO: 2022/8/2
interactiveParam
.
setCustomerCode
(
success
.
getOldCustomerCode
());
interactiveParam
.
setCustomerCode
(
success
.
getOldCustomerCode
());
...
@@ -3343,7 +3348,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -3343,7 +3348,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
interactiveParam
.
setInteractiveType
(
CommonConstants
.
THREE_INT
);
interactiveParam
.
setInteractiveType
(
CommonConstants
.
THREE_INT
);
interactiveParam
.
setEstimatePremium
(
one
.
getEstimatePremium
());
interactiveParam
.
setEstimatePremium
(
one
.
getEstimatePremium
());
interactiveParam
.
setActualPremium
(
one
.
getActualPremium
());
interactiveParam
.
setActualPremium
(
one
.
getActualPremium
());
interactiveParam
.
setSettleType
(
CommonConstants
.
ZERO
_INT
);
interactiveParam
.
setSettleType
(
CommonConstants
.
ONE
_INT
);
String
deleteBody
=
EKPUtil
.
sendToEKP
(
interactiveParam
);
String
deleteBody
=
EKPUtil
.
sendToEKP
(
interactiveParam
);
if
(
StringUtils
.
isNotBlank
(
deleteBody
)){
if
(
StringUtils
.
isNotBlank
(
deleteBody
)){
//推送成功更新作废推送状态
//推送成功更新作废推送状态
...
@@ -3351,21 +3356,10 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -3351,21 +3356,10 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
tInsuranceSettleCancelService
.
updateById
(
cancel
);
tInsuranceSettleCancelService
.
updateById
(
cancel
);
//变更为单独结算
//变更为单独结算
if
(
CommonConstants
.
ONE_INT
==
newSettleType
){
if
(
CommonConstants
.
ONE_INT
==
newSettleType
){
//新增新的结算信息
TInsuranceSettle
newInsuranceSettle
=
new
TInsuranceSettle
();
newInsuranceSettle
.
setInsDetailId
(
insuranceDetailId
);
newInsuranceSettle
.
setSettleType
(
newSettleType
);
newInsuranceSettle
.
setIsEstimatePush
(
CommonConstants
.
ZERO_INT
);
newInsuranceSettle
.
setIsActualPush
(
CommonConstants
.
ZERO_INT
);
newInsuranceSettle
.
setSettleHandleStatus
(
CommonConstants
.
ONE_STRING
);
newInsuranceSettle
.
setCreateTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setActualPremium
(
success
.
getActualPremium
());
tInsuranceSettleService
.
save
(
newInsuranceSettle
);
//更新预估费用为0.00
//更新预估费用为0.00
updateWrapper
.
set
(
TInsuranceDetail
::
getEstimatePremium
,
new
BigDecimal
(
"0.00"
));
updateWrapper
.
set
(
TInsuranceDetail
::
getEstimatePremium
,
new
BigDecimal
(
"0.00"
));
updateWrapper
.
set
(
TInsuranceDetail
::
getDefaultSettleId
,
newInsuranceSettle
.
getId
());
update
(
updateWrapper
);
update
(
updateWrapper
);
//推送新的结算信息至EKP,
先推预估单,再
推实际保费
//推送新的结算信息至EKP,推实际保费
// TODO: 2022/8/2
// TODO: 2022/8/2
interactiveParam
.
setCustomerCode
(
success
.
getNewCustomerCode
());
interactiveParam
.
setCustomerCode
(
success
.
getNewCustomerCode
());
interactiveParam
.
setCustomerName
(
success
.
getNewCustomerName
());
interactiveParam
.
setCustomerName
(
success
.
getNewCustomerName
());
...
@@ -3388,23 +3382,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -3388,23 +3382,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
}
}
//变更为合并结算
//变更为合并结算
if
(
CommonConstants
.
ZERO_INT
==
newSettleType
){
if
(
CommonConstants
.
ZERO_INT
==
newSettleType
){
//新增新的结算信息
// 推送新的结算信息 TODO: 2022/8/2
TInsuranceSettle
newInsuranceSettle
=
new
TInsuranceSettle
();
newInsuranceSettle
.
setInsDetailId
(
insuranceDetailId
);
newInsuranceSettle
.
setSettleType
(
newSettleType
);
newInsuranceSettle
.
setIsEstimatePush
(
CommonConstants
.
ZERO_INT
);
newInsuranceSettle
.
setIsActualPush
(
CommonConstants
.
ZERO_INT
);
newInsuranceSettle
.
setSettleHandleStatus
(
CommonConstants
.
ONE_STRING
);
newInsuranceSettle
.
setCreateTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setActualPremium
(
success
.
getActualPremium
());
newInsuranceSettle
.
setEstimatePremium
(
success
.
getEstimatePremium
());
tInsuranceSettleService
.
save
(
newInsuranceSettle
);
//更新预估费用为新的预估费用
updateWrapper
.
set
(
TInsuranceDetail
::
getEstimatePremium
,
success
.
getEstimatePremium
());
updateWrapper
.
set
(
TInsuranceDetail
::
getDefaultSettleId
,
newInsuranceSettle
.
getId
());
update
(
updateWrapper
);
//推送新的结算信息
// TODO: 2022/8/2
interactiveParam
.
setCustomerCode
(
success
.
getNewCustomerCode
());
interactiveParam
.
setCustomerCode
(
success
.
getNewCustomerCode
());
interactiveParam
.
setCustomerName
(
success
.
getNewCustomerName
());
interactiveParam
.
setCustomerName
(
success
.
getNewCustomerName
());
interactiveParam
.
setDeptNo
(
success
.
getNewDeptNo
());
interactiveParam
.
setDeptNo
(
success
.
getNewDeptNo
());
...
@@ -3423,27 +3401,20 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -3423,27 +3401,20 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
newInsuranceSettle
.
setUpdateTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setUpdateTime
(
LocalDateTime
.
now
());
tInsuranceSettleService
.
updateById
(
newInsuranceSettle
);
tInsuranceSettleService
.
updateById
(
newInsuranceSettle
);
}
else
{
}
else
{
//
异常处理 // TODO: 2022/8/9
//
todo 异常情况,需进行处理
}
}
}
}
}
else
{
}
else
{
//
异常处理 // TODO: 2022/8/9
//
todo 异常情况,需进行处理
}
}
}
else
{
//todo 异常情况,需进行处理
}
}
//如果没有登记保费
}
if
(
BigDecimalUtils
.
isNullOrZero
(
actualPremium
)){
//如果没有登记保费
//作废旧的结算信息
if
(
BigDecimalUtils
.
isNullOrZero
(
actualPremium
)){
TInsuranceSettleCancel
cancel
=
new
TInsuranceSettleCancel
();
if
(
byId
.
getIsEstimatePush
()
==
CommonConstants
.
ONE_INT
){
cancel
.
setDeptNo
(
success
.
getOldDeptNo
());
//推送至EKP TODO: 2022/8/2
cancel
.
setInsDetailId
(
success
.
getId
());
cancel
.
setSettleId
(
defaultSettleId
);
cancel
.
setCreateUesr
(
user
.
getId
());
cancel
.
setCreateTime
(
LocalDateTime
.
now
());
cancel
.
setDeptName
(
success
.
getOldDeptName
());
cancel
.
setIsCancelPush
(
CommonConstants
.
ZERO_INT
);
tInsuranceSettleCancelService
.
save
(
cancel
);
//推送至EKP
// TODO: 2022/8/2
interactiveParam
.
setCustomerCode
(
success
.
getOldCustomerCode
());
interactiveParam
.
setCustomerCode
(
success
.
getOldCustomerCode
());
interactiveParam
.
setCustomerName
(
success
.
getOldCustomerName
());
interactiveParam
.
setCustomerName
(
success
.
getOldCustomerName
());
interactiveParam
.
setDeptNo
(
success
.
getOldDeptNo
());
interactiveParam
.
setDeptNo
(
success
.
getOldDeptNo
());
...
@@ -3466,7 +3437,6 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -3466,7 +3437,6 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
//变更为合并结算
//变更为合并结算
if
(
CommonConstants
.
ZERO_INT
==
newSettleType
){
if
(
CommonConstants
.
ZERO_INT
==
newSettleType
){
//新增新的结算信息
//新增新的结算信息
TInsuranceSettle
newInsuranceSettle
=
new
TInsuranceSettle
();
newInsuranceSettle
.
setInsDetailId
(
insuranceDetailId
);
newInsuranceSettle
.
setInsDetailId
(
insuranceDetailId
);
newInsuranceSettle
.
setSettleType
(
newSettleType
);
newInsuranceSettle
.
setSettleType
(
newSettleType
);
newInsuranceSettle
.
setIsEstimatePush
(
CommonConstants
.
ZERO_INT
);
newInsuranceSettle
.
setIsEstimatePush
(
CommonConstants
.
ZERO_INT
);
...
@@ -3475,8 +3445,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -3475,8 +3445,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
newInsuranceSettle
.
setCreateTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setCreateTime
(
LocalDateTime
.
now
());
newInsuranceSettle
.
setEstimatePremium
(
success
.
getEstimatePremium
());
newInsuranceSettle
.
setEstimatePremium
(
success
.
getEstimatePremium
());
tInsuranceSettleService
.
save
(
newInsuranceSettle
);
tInsuranceSettleService
.
save
(
newInsuranceSettle
);
//更新预估费用
//更新结算信息
updateWrapper
.
set
(
TInsuranceDetail
::
getEstimatePremium
,
success
.
getEstimatePremium
());
updateWrapper
.
set
(
TInsuranceDetail
::
getDefaultSettleId
,
newInsuranceSettle
.
getId
());
updateWrapper
.
set
(
TInsuranceDetail
::
getDefaultSettleId
,
newInsuranceSettle
.
getId
());
update
(
updateWrapper
);
update
(
updateWrapper
);
//推送新的结算信息至EKP
//推送新的结算信息至EKP
...
@@ -3503,9 +3472,11 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
...
@@ -3503,9 +3472,11 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
}
else
{
}
else
{
//异常处理 // TODO: 2022/8/9
//异常处理 // TODO: 2022/8/9
}
}
}
else
{
//todo 异常情况,需进行处理
}
}
}
}
}
//新增操作信息
//新增操作信息
TInsuranceOperate
insuranceOperate
=
new
TInsuranceOperate
();
TInsuranceOperate
insuranceOperate
=
new
TInsuranceOperate
();
insuranceOperate
.
setInsuranceDetailId
(
success
.
getId
());
insuranceOperate
.
setInsuranceDetailId
(
success
.
getId
());
...
...
yifu-insurances/yifu-insurances-biz/src/main/resources/mapper/TInsuranceDetailMapper.xml
View file @
f2cf2ebc
...
@@ -739,6 +739,15 @@
...
@@ -739,6 +739,15 @@
<if
test=
"param.updateBy != null and param.updateBy.trim() != ''"
>
<if
test=
"param.updateBy != null and param.updateBy.trim() != ''"
>
and refund.UPDATE_BY = #{param.updateBy}
and refund.UPDATE_BY = #{param.updateBy}
</if>
</if>
<if
test=
"param.createName != null and param.createName.trim() != ''"
>
and refund.CREATE_NAME like concat('%',replace(replace(#{param.createName},'_','\_'),'%','\%'),'%')
</if>
<if
test=
"param.createStartTime != null and param.createStartTime.trim() != ''"
>
AND refund.CREATE_TIME
<![CDATA[ >= ]]>
concat(#{param.createStartTime}, ' 00:00:00')
</if>
<if
test=
"param.createEndTime != null and param.createEndTime.trim() != ''"
>
AND refund.CREATE_TIME
<![CDATA[ <= ]]>
concat(#{param.createEndTime}, ' 23:59:59')
</if>
ORDER BY refund.CREATE_TIME DESC,detail.ID ASC
ORDER BY refund.CREATE_TIME DESC,detail.ID ASC
</select>
</select>
<!-- 查询保单列表-->
<!-- 查询保单列表-->
...
...
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