Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
8
8timerapiv200
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
8timerv2
8timerapiv200
Commits
32f70d13
Commit
32f70d13
authored
Apr 09, 2022
by
翁国栋
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
运营后台--
8小时后台保险列表
parent
669fd39d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
50 additions
and
35 deletions
+50
-35
src/main/java/cn/timer/api/controller/insure/InsureContorll.java
+1
-2
src/main/java/cn/timer/api/controller/insure/InsureUserController.java
+1
-1
src/main/resources/mapping/insure/InsureUserMapper.xml
+48
-32
No files found.
src/main/java/cn/timer/api/controller/insure/InsureContorll.java
View file @
32f70d13
...
...
@@ -413,8 +413,7 @@ public class InsureContorll {
if
(
insurePolicy
==
null
)
{
return
ResultUtil
.
error
(
"保单不存在"
);
}
Integer
price
=
getPrice
(
insureDto
.
getBenefitBasicPlan
(),
insureDto
.
getBenefitOccupationCategory
());
LocalDateTime
now
=
LocalDateTime
.
now
();
LocalDateTime
now
=
LocalDateTime
.
now
();
String
url
=
creaXSSFWorkbook1
(
insureDto
);
log
.
info
(
"保全增员文件地址"
,
url
);
DateTimeFormatter
dtf2
=
DateTimeFormatter
.
ofPattern
(
"yyyyMMddHHmmss"
);
...
...
src/main/java/cn/timer/api/controller/insure/InsureUserController.java
View file @
32f70d13
...
...
@@ -60,7 +60,7 @@ public class InsureUserController{
@PostMapping
(
value
=
"/userPolicyList"
)
@ApiOperation
(
value
=
"3.保单列表--8小时端"
,
httpMethod
=
"Post"
,
notes
=
"保单列表"
)
public
Result
<
Object
>
userPolicyList
(
@CurrentUser
UserBean
userBean
,
PolicyDto
policyDto
)
{
public
Result
<
Object
>
userPolicyList
(
@CurrentUser
UserBean
userBean
,
@RequestBody
PolicyDto
policyDto
)
{
Map
map
=
Maps
.
newHashMap
();
InsurePolicy
insurePolicy
=
InsurePolicy
.
builder
().
build
().
selectOne
(
new
QueryWrapper
<
InsurePolicy
>().
lambda
().
eq
(
InsurePolicy:
:
getOrgCode
,
userBean
.
getOrgCode
()).
eq
(
InsurePolicy:
:
getStatus
,
1
));
if
(
insurePolicy
==
null
){
...
...
src/main/resources/mapping/insure/InsureUserMapper.xml
View file @
32f70d13
...
...
@@ -277,22 +277,32 @@
</delete>
<select
id=
"selectPolicyList"
resultType=
"cn.timer.api.dto.insure.PolicyDto"
>
select iu.id,yme.`name`,yme.zj_type,yme.zj_num,iu.policy_no,iu.`status`,ip.scheme_name,iu.policy_date_start,iu.insure_status,
iu.policy_date_end,ip.create_time,iu.insured_name,iu.benefit_basic_plan AS benefitBasicPlan,iu.price AS price,
iu.user_id as userId,iu.batch_no as batchNo,iu.benefit_occupation_category as benefitOccupationCategory
select
iu.id,yme.`name`,yme.zj_type,yme.zj_num,iu.policy_no,iu.`status`,ip.scheme_name,iu.policy_date_start,iu.insure_status,
iu.policy_date_end,ip.create_time,iu.insured_name,iu.benefit_basic_plan AS benefitBasicPlan,iu.price AS price,
iu.user_id as userId,iu.batch_no as batchNo,iu.benefit_occupation_category as benefitOccupationCategory
from insure_user iu
LEFT JOIN yggl_main_emp yme on yme.id=iu.user_id
LEFT JOIN insure_policy ip on ip.id=iu.policy_id
LEFT JOIN yggl_main_emp yme on yme.id=iu.user_id
LEFT JOIN insure_policy ip on ip.id=iu.policy_id
<where>
ip.id=#{policyDto.id}
<if
test=
"policyDto.orgCode !=null and policyDto.orgCode !=''"
>
and ip.org_code=#{policyDto.orgCode}
</if>
<if
test=
"policyDto.id !=null and policyDto.id !=''"
>
and ip.id=#{policyDto.id}
</if>
<if
test=
"policyDto.planId !=null and policyDto.planId !=''"
>
and iu.benefit_basic_plan = #{policyDto.planId}
</if>
<if
test=
"policyDto.categoryId !=null and policyDto.categoryId !=''"
>
and iu.benefit_occupation_category = #{policyDto.categoryId}
<if
test=
"policyDto.name !=null and policyDto.name !=''"
>
and iu.insured_e_contact like CONCAT('%',#{policyDto.name},'%')
</if>
<if
test=
"policyDto.policyDateStart !=null and policyDto.policyDateStart !=''"
>
and iu.policy_date_start
<![CDATA[>=]]>
#{policyDto.policyDateStart}
</if>
</if>
<if
test=
"policyDto.name !=null and policyDto.name !=''"
>
and iu.insured_e_contact like CONCAT('%',#{policyDto.name},'%')
</if>
<if
test=
"policyDto.policyDateStart !=null and policyDto.policyDateStart !=''"
>
and iu.policy_date_start
<![CDATA[>=]]>
#{policyDto.policyDateStart}
</if>
<if
test=
"policyDto.status !=null and policyDto.status !=''"
>
and iu.insure_status = #{policyDto.status}
</if>
...
...
@@ -306,19 +316,26 @@
select count(iu.id) from insure_user iu
LEFT JOIN yggl_main_emp yme on yme.id=iu.user_id
LEFT JOIN insure_policy ip on ip.id=iu.policy_id
<where>
<if
test=
"policyDto.id !=null and policyDto.id !=''"
>
and ip.id=#{policyDto.id}
</if>
<if
test=
"policyDto.name !=null and policyDto.name !=''"
>
and iu.insured_e_contact like CONCAT('%',#{policyDto.name},'%')
</if>
<if
test=
"policyDto.policyDateStart !=null and policyDto.policyDateStart !=''"
>
and iu.policy_date_start
<![CDATA[>=]]>
#{policyDto.policyDateStart}
</if>
and iu.benefit_basic_plan = #{policyDto.planId}
and iu.benefit_occupation_category = #{policyDto.categoryId}
</where>
<where>
<if
test=
"policyDto.orgCode !=null and policyDto.orgCode !=''"
>
and ip.org_code=#{policyDto.orgCode}
</if>
<if
test=
"policyDto.id !=null and policyDto.id !=''"
>
and ip.id=#{policyDto.id}
</if>
<if
test=
"policyDto.planId !=null and policyDto.planId !=''"
>
and iu.benefit_basic_plan = #{policyDto.planId}
</if>
<if
test=
"policyDto.categoryId !=null and policyDto.categoryId !=''"
>
and iu.benefit_occupation_category = #{policyDto.categoryId}
</if>
<if
test=
"policyDto.name !=null and policyDto.name !=''"
>
and iu.insured_e_contact like CONCAT('%',#{policyDto.name},'%')
</if>
<if
test=
"policyDto.policyDateStart !=null and policyDto.policyDateStart !=''"
>
and iu.policy_date_start
<![CDATA[>=]]>
#{policyDto.policyDateStart}
</if>
</where>
</select>
<!--根据id数组查询员工-->
...
...
@@ -344,17 +361,16 @@
<foreach
item=
"id"
collection=
"array"
open=
"("
separator=
","
close=
")"
>
#{id}
</foreach>
group by benefit_basic_plan,benefit_occupation_category
group by benefit_basic_plan,benefit_occupation_category
</select>
<select
id=
"selectPlansListById"
resultType=
"cn.timer.api.dto.insure.InsureUserDto"
>
SELECT
policy_id as policyId,
benefit_basic_plan as benefitBasicPlan,
benefit_occupation_category as benefitOccupationCategory,
count(id) as totalUser
SELECT policy_id as policyId,
benefit_basic_plan as benefitBasicPlan,
benefit_occupation_category as benefitOccupationCategory,
count(id) as totalUser
FROM insure_user
WHERE policy_id = #{policyId}
group by benefit_basic_plan,benefit_occupation_category
group by benefit_basic_plan,
benefit_occupation_category
</select>
</mapper>
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