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
0614c32d
Commit
0614c32d
authored
Jul 29, 2022
by
zhaji
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
"feature-zhaJi:新增项目列表接口"
parent
472245d2
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
73 additions
and
17 deletions
+73
-17
Dept.java
...a/com/yifu/cloud/plus/v1/yifu/insurances/entity/Dept.java
+29
-0
DeptChangeCheckParam.java
...loud/plus/v1/yifu/insurances/vo/DeptChangeCheckParam.java
+2
-2
TInsuranceDetailController.java
...ifu/insurances/controller/TInsuranceDetailController.java
+14
-2
TInsuranceDetailService.java
...s/v1/yifu/insurances/service/TInsuranceDetailService.java
+9
-0
TInsuranceDetailServiceImpl.java
.../insurances/service/impl/TInsuranceDetailServiceImpl.java
+19
-13
No files found.
yifu-insurances/yifu-insurances-api/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/entity/Dept.java
0 → 100644
View file @
0614c32d
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
insurances
.
entity
;
import
io.swagger.v3.oas.annotations.media.Schema
;
import
io.swagger.v3.oas.annotations.tags.Tag
;
import
lombok.Data
;
import
java.io.Serializable
;
/**
* @author zhaji
* @description 项目
* @date 2022-07-29 09:35:31
*/
@Data
@Tag
(
name
=
"项目类"
)
public
class
Dept
implements
Serializable
{
/**
* 项目编码
*/
@Schema
(
description
=
"项目编码"
)
private
String
deptNo
;
/**
* 项目名称
*/
@Schema
(
description
=
"项目名称"
)
private
String
projectName
;
}
yifu-insurances/yifu-insurances-api/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/vo/DeptChangeCheckParam.java
View file @
0614c32d
...
...
@@ -82,13 +82,13 @@ public class DeptChangeCheckParam implements Serializable {
/**
* 新项目结算方式
*/
@Schema
(
description
=
"结算方式"
)
@Schema
(
description
=
"
新项目
结算方式"
)
private
Integer
newSettleType
;
/**
* 旧项目结算方式
*/
@Schema
(
description
=
"结算方式"
)
@Schema
(
description
=
"
旧项目
结算方式"
)
private
Integer
oldSettleType
;
/**
...
...
yifu-insurances/yifu-insurances-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/controller/TInsuranceDetailController.java
View file @
0614c32d
...
...
@@ -3,6 +3,7 @@ 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.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
;
...
...
@@ -373,9 +374,20 @@ public class TInsuranceDetailController {
@Operation
(
summary
=
"更新减员退费"
,
description
=
"更新减员退费"
)
@PostMapping
(
"/updateRefundMoney"
)
public
R
updateRefundMoney
(
@RequestBody
@Valid
@Size
(
min
=
1
,
message
=
"更新减员退费不能为空"
)
List
<
RefundMoneyParam
>
paramList
)
{
return
tInsuranceDetailService
.
updateRefundMoney
(
paramList
);
return
R
.
failed
(
"该功能暂未开放"
);
//return tInsuranceDetailService.updateRefundMoney(paramList);
}
/**
* 查询项目列表
*
* @author zhaji
* @return {@link R<List<Dept>>}
*/
@Operation
(
summary
=
"查询项目列表"
,
description
=
"查询项目列表"
)
@GetMapping
(
"/deptList"
)
public
R
getDeptList
()
{
return
tInsuranceDetailService
.
getDeptList
();
}
}
yifu-insurances/yifu-insurances-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/service/TInsuranceDetailService.java
View file @
0614c32d
...
...
@@ -257,4 +257,13 @@ public interface TInsuranceDetailService extends IService<TInsuranceDetail> {
*/
R
updateRefundMoney
(
List
<
RefundMoneyParam
>
paramList
);
/**
* 查询项目列表
*
* @author zhaji
* @param
* @return {@link R}
*/
R
getDeptList
();
}
yifu-insurances/yifu-insurances-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/insurances/service/impl/TInsuranceDetailServiceImpl.java
View file @
0614c32d
...
...
@@ -9,6 +9,8 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import
com.google.common.collect.Sets
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.ProjectSetInfoVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.SetInfoVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainListVo
;
import
com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainSelectVo
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CacheConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.Common
;
...
...
@@ -2428,7 +2430,6 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
.
set
(
TInsuranceDetail
::
getUpdateTime
,
LocalDateTime
.
now
());
update
(
updateWrapper
);
}
updateDept2EKP
(
successList
);
}
List
<
DeptChangeCheckParam
>
errorList
=
stringListMap
.
get
(
"errorList"
);
return
R
.
ok
(
errorList
,
"导入成功"
);
...
...
@@ -3176,9 +3177,6 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
// 预估保费 = 费率 * 购买标准
BigDecimal
estimatePremium
=
new
BigDecimal
(
insuranceDetail
.
getBuyStandard
()).
multiply
(
new
BigDecimal
(
typeRate
.
getRate
())).
setScale
(
2
,
BigDecimal
.
ROUND_HALF_UP
);
insuranceDetail
.
setEstimatePremium
(
estimatePremium
);
if
(
insuranceDetail
.
getBuyType
()
==
CommonConstants
.
THREE_INT
){
insuranceDetail
.
setPolicyEffect
(
LocalDate
.
now
().
plusDays
(
CommonConstants
.
ONE_INT
));
}
}
}
else
{
//按天
...
...
@@ -3187,15 +3185,6 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
//预估保费 = (购买标准 / 365) * 天数
BigDecimal
estimatePremium
=
new
BigDecimal
(
insuranceDetail
.
getBuyStandard
()).
divide
(
new
BigDecimal
(
"365"
)).
multiply
(
new
BigDecimal
(
day
)).
setScale
(
2
,
BigDecimal
.
ROUND_HALF_UP
);
insuranceDetail
.
setEstimatePremium
(
estimatePremium
);
if
(
insuranceDetail
.
getBuyType
()
==
CommonConstants
.
THREE_INT
){
insuranceDetail
.
setPolicyEffect
(
LocalDate
.
now
().
plusDays
(
CommonConstants
.
ONE_INT
));
}
//保费存储
TInsuranceSettle
settle
=
new
TInsuranceSettle
();
settle
.
setInsDetailId
(
insuranceDetail
.
getId
());
settle
.
setSettleType
(
insuranceDetail
.
getSettleType
());
settle
.
setSettleHandleStatus
(
CommonConstants
.
ONE_STRING
);
settle
.
setEstimatePremium
(
estimatePremium
);
}
}
}
...
...
@@ -3209,4 +3198,21 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
return
map
;
}
@Override
public
R
getDeptList
(){
R
<
TSettleDomainListVo
>
tSettleDomainListVoR
=
archivesDaprUtil
.
selectAllSettleDomainSelectVos
();
TSettleDomainListVo
data
=
tSettleDomainListVoR
.
getData
();
List
<
TSettleDomainSelectVo
>
listSelectVO
=
data
.
getListSelectVO
();
List
<
Dept
>
deptList
=
new
ArrayList
<>();
if
(
CollectionUtils
.
isNotEmpty
(
listSelectVO
)){
for
(
TSettleDomainSelectVo
tSettleDomainSelectVo
:
listSelectVO
)
{
Dept
dept
=
new
Dept
();
dept
.
setDeptNo
(
tSettleDomainSelectVo
.
getDepartNo
());
dept
.
setProjectName
(
tSettleDomainSelectVo
.
getDepartName
());
deptList
.
add
(
dept
);
}
}
return
R
.
ok
(
deptList
);
};
}
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