Commit 32f70d13 by 翁国栋

运营后台--

8小时后台保险列表
parent 669fd39d
...@@ -413,8 +413,7 @@ public class InsureContorll { ...@@ -413,8 +413,7 @@ public class InsureContorll {
if (insurePolicy == null) { if (insurePolicy == null) {
return ResultUtil.error("保单不存在"); return ResultUtil.error("保单不存在");
} }
Integer price = getPrice(insureDto.getBenefitBasicPlan(),insureDto.getBenefitOccupationCategory()); LocalDateTime now = LocalDateTime.now();
LocalDateTime now = LocalDateTime.now();
String url = creaXSSFWorkbook1(insureDto); String url = creaXSSFWorkbook1(insureDto);
log.info("保全增员文件地址", url); log.info("保全增员文件地址", url);
DateTimeFormatter dtf2 = DateTimeFormatter.ofPattern("yyyyMMddHHmmss"); DateTimeFormatter dtf2 = DateTimeFormatter.ofPattern("yyyyMMddHHmmss");
......
...@@ -60,7 +60,7 @@ public class InsureUserController{ ...@@ -60,7 +60,7 @@ public class InsureUserController{
@PostMapping(value = "/userPolicyList") @PostMapping(value = "/userPolicyList")
@ApiOperation(value = "3.保单列表--8小时端", httpMethod = "Post", notes = "保单列表") @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(); Map map = Maps.newHashMap();
InsurePolicy insurePolicy = InsurePolicy.builder().build().selectOne(new QueryWrapper<InsurePolicy>().lambda().eq(InsurePolicy::getOrgCode,userBean.getOrgCode()).eq(InsurePolicy::getStatus,1)); InsurePolicy insurePolicy = InsurePolicy.builder().build().selectOne(new QueryWrapper<InsurePolicy>().lambda().eq(InsurePolicy::getOrgCode,userBean.getOrgCode()).eq(InsurePolicy::getStatus,1));
if(insurePolicy==null){ if(insurePolicy==null){
......
...@@ -277,22 +277,32 @@ ...@@ -277,22 +277,32 @@
</delete> </delete>
<select id="selectPolicyList" resultType="cn.timer.api.dto.insure.PolicyDto"> <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, select
iu.policy_date_end,ip.create_time,iu.insured_name,iu.benefit_basic_plan AS benefitBasicPlan,iu.price AS price, 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.user_id as userId,iu.batch_no as batchNo,iu.benefit_occupation_category as benefitOccupationCategory 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 from insure_user iu
LEFT JOIN yggl_main_emp yme on yme.id=iu.user_id 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 insure_policy ip on ip.id=iu.policy_id
<where> <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} and iu.benefit_basic_plan = #{policyDto.planId}
</if>
<if test="policyDto.categoryId !=null and policyDto.categoryId !=''">
and iu.benefit_occupation_category = #{policyDto.categoryId} and iu.benefit_occupation_category = #{policyDto.categoryId}
<if test="policyDto.name !=null and policyDto.name !=''"> </if>
and iu.insured_e_contact like CONCAT('%',#{policyDto.name},'%') <if test="policyDto.name !=null and policyDto.name !=''">
</if> and iu.insured_e_contact like CONCAT('%',#{policyDto.name},'%')
<if test="policyDto.policyDateStart !=null and policyDto.policyDateStart !=''"> </if>
and iu.policy_date_start <![CDATA[>=]]> #{policyDto.policyDateStart} <if test="policyDto.policyDateStart !=null and policyDto.policyDateStart !=''">
</if> and iu.policy_date_start <![CDATA[>=]]> #{policyDto.policyDateStart}
</if>
<if test="policyDto.status !=null and policyDto.status !=''"> <if test="policyDto.status !=null and policyDto.status !=''">
and iu.insure_status = #{policyDto.status} and iu.insure_status = #{policyDto.status}
</if> </if>
...@@ -306,19 +316,26 @@ ...@@ -306,19 +316,26 @@
select count(iu.id) from insure_user iu select count(iu.id) from insure_user iu
LEFT JOIN yggl_main_emp yme on yme.id=iu.user_id 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 insure_policy ip on ip.id=iu.policy_id
<where> <where>
<if test="policyDto.id !=null and policyDto.id !=''"> <if test="policyDto.orgCode !=null and policyDto.orgCode !=''">
and ip.id=#{policyDto.id} and ip.org_code=#{policyDto.orgCode}
</if> </if>
<if test="policyDto.name !=null and policyDto.name !=''"> <if test="policyDto.id !=null and policyDto.id !=''">
and iu.insured_e_contact like CONCAT('%',#{policyDto.name},'%') and ip.id=#{policyDto.id}
</if> </if>
<if test="policyDto.policyDateStart !=null and policyDto.policyDateStart !=''"> <if test="policyDto.planId !=null and policyDto.planId !=''">
and iu.policy_date_start <![CDATA[>=]]> #{policyDto.policyDateStart} and iu.benefit_basic_plan = #{policyDto.planId}
</if> </if>
and iu.benefit_basic_plan = #{policyDto.planId} <if test="policyDto.categoryId !=null and policyDto.categoryId !=''">
and iu.benefit_occupation_category = #{policyDto.categoryId} and iu.benefit_occupation_category = #{policyDto.categoryId}
</where> </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> </select>
<!--根据id数组查询员工--> <!--根据id数组查询员工-->
...@@ -344,17 +361,16 @@ ...@@ -344,17 +361,16 @@
<foreach item="id" collection="array" open="(" separator="," close=")"> <foreach item="id" collection="array" open="(" separator="," close=")">
#{id} #{id}
</foreach> </foreach>
group by benefit_basic_plan,benefit_occupation_category group by benefit_basic_plan,benefit_occupation_category
</select> </select>
<select id="selectPlansListById" resultType="cn.timer.api.dto.insure.InsureUserDto"> <select id="selectPlansListById" resultType="cn.timer.api.dto.insure.InsureUserDto">
SELECT SELECT policy_id as policyId,
policy_id as policyId, benefit_basic_plan as benefitBasicPlan,
benefit_basic_plan as benefitBasicPlan, benefit_occupation_category as benefitOccupationCategory,
benefit_occupation_category as benefitOccupationCategory, count(id) as totalUser
count(id) as totalUser
FROM insure_user FROM insure_user
WHERE policy_id = #{policyId} WHERE policy_id = #{policyId}
group by benefit_basic_plan,benefit_occupation_category group by benefit_basic_plan, benefit_occupation_category
</select> </select>
</mapper> </mapper>
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