Explorar el Código

Merge remote-tracking branch 'origin/dev_jzg_lipf_v20260518' into dev_jzg_lipf_v20260518

# Conflicts:
#	tenant/insurance/quotation-summary/src/main/resources/mapper/InsFeeAuditMapper.xml
jiakai hace 4 meses
padre
commit
f59c1acdc8
Se han modificado 16 ficheros con 97 adiciones y 21 borrados
  1. 4 0
      commons/src/main/java/com/jzg/commons/entity/agreement/po/PtlAgreementAttribution.java
  2. 3 0
      commons/src/main/java/com/jzg/commons/entity/orders/po/InsFeeAudit.java
  3. 5 0
      commons/src/main/java/com/jzg/commons/entity/orders/vo/FeeAuditVo.java
  4. 8 1
      platform/src/main/java/com/jzg/controller/AgreementAttributionController.java
  5. 8 2
      platform/src/main/java/com/jzg/service/PtlAgreementAttributionService.java
  6. 1 1
      platform/src/main/java/com/jzg/service/impl/PtlAgreementAttributionImpl.java
  7. 1 0
      platform/src/main/java/com/jzg/service/impl/PtlInsAttributionTemplateServiceImpl.java
  8. 6 5
      tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/controller/InsFeeAuditController.java
  9. 4 2
      tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/service/InsFeeAuditService.java
  10. 3 2
      tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/service/impl/InsFeeAuditServiceImpl.java
  11. 2 0
      tenant/insurance/quotation-summary/src/main/resources/mapper/InsFeeAuditMapper.xml
  12. 25 0
      tenant/organization/src/main/java/com/jzg/organization/client/PlatformClient.java
  13. 1 1
      tenant/organization/src/main/java/com/jzg/organization/controller/PtlAgreementCostController.java
  14. 7 1
      tenant/organization/src/main/java/com/jzg/organization/service/PtlAgreementCostService.java
  15. 12 3
      tenant/organization/src/main/java/com/jzg/organization/service/impl/PtlAgreementCostServiceImpl.java
  16. 7 3
      tenant/organization/src/main/java/com/jzg/organization/service/impl/PtlAgreementDispatchServiceImpl.java

+ 4 - 0
commons/src/main/java/com/jzg/commons/entity/agreement/po/PtlAgreementAttribution.java

@@ -14,6 +14,8 @@ import lombok.Data;
 import lombok.EqualsAndHashCode;
 import lombok.NoArgsConstructor;
 
+import java.io.Serial;
+
 /**
  * @author quchen
  * @date 2025/2/18 11:09
@@ -25,6 +27,8 @@ import lombok.NoArgsConstructor;
 @AllArgsConstructor
 @TableName(value = "ptl_agreement_attribution", autoResultMap = true)
 public class PtlAgreementAttribution extends BaseModel {
+    @Serial
+    private static final long serialVersionUID = 772426849982494479L;
     @Schema(description = "id")
     @TableId(value = "id")
     private String id;

+ 3 - 0
commons/src/main/java/com/jzg/commons/entity/orders/po/InsFeeAudit.java

@@ -44,6 +44,9 @@ public class InsFeeAudit extends BaseModel {
     @Schema(description = "是否是疑问订单 0.否 1.是")
     private Integer isProblem;
 
+    @Schema(description = "设为疑问单的原因")
+    private String problemReason;
+
     @Schema(description = "驳回原因")
     private String refuse;
 

+ 5 - 0
commons/src/main/java/com/jzg/commons/entity/orders/vo/FeeAuditVo.java

@@ -137,4 +137,9 @@ public class FeeAuditVo extends BaseModel {
     @Schema(description = "权益金额")
     private BigDecimal equityAmount;
 
+    @Schema(description = "是否是疑问单")
+    private int problem;
+
+    @Schema(description = "设置为疑问单的原因")
+    private String problemReason;
 }

+ 8 - 1
platform/src/main/java/com/jzg/controller/AgreementAttributionController.java

@@ -5,6 +5,7 @@ import com.jzg.commons.aop.OperatorTrajectory;
 import com.jzg.commons.constants.OperationTypeEnum;
 import com.jzg.commons.core.base.BaseController;
 import com.jzg.commons.core.page.HttpResult;
+import com.jzg.commons.entity.agreement.po.PtlAgreementAttribution;
 import com.jzg.commons.entity.agreement.vo.PtlAgreementAttributionDeptVo;
 import com.jzg.commons.entity.agreement.vo.PtlAgreementAttributionQueryVo;
 import com.jzg.commons.entity.agreement.vo.PtlAgreementAttributionSaveVo;
@@ -45,7 +46,13 @@ public class AgreementAttributionController extends BaseController {
 
     @Operation(summary = "保险公司账号详情接口", description = "保险公司账号接口")
     @PostMapping(value = "/getAgreementAttribution")
-    public HttpResult<Object> getAgreementAttribution(@RequestSingleParam(value = "id") String id) {
+    public HttpResult<PtlAgreementAttribution> getAgreementAttribution(@RequestSingleParam(value = "id") String id) {
+        return agreementAttributionService.getAgreementAttribution(id);
+    }
+
+    @Operation(summary = "保险公司账号详情接口", description = "保险公司账号接口")
+    @PostMapping(value = "/getAgreementAttribution2")
+    public HttpResult<PtlAgreementAttribution> getAgreementAttribution2(@RequestParam(value = "id") String id) {
         return agreementAttributionService.getAgreementAttribution(id);
     }
 

+ 8 - 2
platform/src/main/java/com/jzg/service/PtlAgreementAttributionService.java

@@ -14,8 +14,14 @@ public interface PtlAgreementAttributionService extends IService<PtlAgreementAtt
 
     boolean addAgreementAttribution(PtlAgreementAttributionSaveVo ptlAgreementAttributionSaveVo);
 
-    HttpResult<Object> getAgreementAttribution(String id);
-
+    HttpResult<PtlAgreementAttribution> getAgreementAttribution(String id);
+
+    /**
+     * 查询保险公司账号列表接口
+     *
+     * @author lipf
+     * @date 2026/5/22 14:17
+     */
     Page<PtlAgreementAttribution> getAgreementAttributionList(Page page, PtlAgreementAttributionQueryVo ptlAgreementAttributionQueryVo);
 
     boolean updateAgreementAttribution(PtlAgreementAttributionSaveVo ptlAgreementAttributionSaveVo);

+ 1 - 1
platform/src/main/java/com/jzg/service/impl/PtlAgreementAttributionImpl.java

@@ -65,7 +65,7 @@ public class PtlAgreementAttributionImpl extends ServiceImpl<PtlAgreementAttribu
     }
 
     @Override
-    public HttpResult<Object> getAgreementAttribution(String id) {
+    public HttpResult<PtlAgreementAttribution> getAgreementAttribution(String id) {
         PtlAgreementAttribution ptlAgreementAttribution = baseMapper.getAgreementAttribution(id);
         if (Objects.isNull(ptlAgreementAttribution)) {
             throw new RuntimeException("该保险公司账号不存在");

+ 1 - 0
platform/src/main/java/com/jzg/service/impl/PtlInsAttributionTemplateServiceImpl.java

@@ -143,6 +143,7 @@ public class PtlInsAttributionTemplateServiceImpl extends ServiceImpl<PtlInsAttr
 
     @Override
     public HttpResult<PtlAgreementAttribution> getAgreementAttribution(String agreementId) {
+        log.info("获取协议属性信息:agreementId=[{}]",agreementId);
         PtlAgreement ptlAgreement = ptlAgreementService.getById(agreementId);
         AssertionUtils.isEmpty(ptlAgreement, "协议不存在");
 

+ 6 - 5
tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/controller/InsFeeAuditController.java

@@ -137,12 +137,13 @@ public class InsFeeAuditController {
 
     /**
      * 设置为疑问订单
-     * @return
+     *
+     * @return HttpResult<String> 设为疑问单的处理结果
      */
     @PostMapping("/updateToQuestionOrder")
     @Operation(summary = "设置为疑问订单")
-    public HttpResult updateToQuestionOrder(@RequestParam("orderNo") String orderNo){
-        insFeeAuditService.updateToQuestionOrder(orderNo,"1");
+    public HttpResult<String> updateToQuestionOrder(@RequestParam("orderNo") String orderNo,@RequestParam(value = "problemReason",required = false) String problemReason){
+        insFeeAuditService.updateToQuestionOrder(orderNo,"1", problemReason);
         return HttpResult.ok("已设为疑问订单,可前往疑问订单列表查看");
     }
 
@@ -152,8 +153,8 @@ public class InsFeeAuditController {
      */
     @PostMapping("/updateToUnQuestionOrder")
     @Operation(summary = "设置为疑问订单")
-    public HttpResult updateToUnQuestionOrder(@RequestParam("orderNo") String orderNo){
-        insFeeAuditService.updateToQuestionOrder(orderNo,"0");
+    public HttpResult<String> updateToUnQuestionOrder(@RequestParam("orderNo") String orderNo){
+        insFeeAuditService.updateToQuestionOrder(orderNo,"0", "");
         return HttpResult.ok("已取消疑问订单,可前往待审核订单列表查看");
     }
 

+ 4 - 2
tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/service/InsFeeAuditService.java

@@ -76,9 +76,11 @@ public interface InsFeeAuditService extends IService<InsFeeAudit> {
 
     /**
      * 设置为疑问订单
-     * @param orderNo
+     *
+     * @param orderNo 订单编号
+     * @param problemReason 设置为疑问单的原因
      */
-    void updateToQuestionOrder(String orderNo,String status);
+    void updateToQuestionOrder(String orderNo, String status, String problemReason);
 
     /**
      * 订单审核费用详情

+ 3 - 2
tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/service/impl/InsFeeAuditServiceImpl.java

@@ -659,7 +659,8 @@ public class InsFeeAuditServiceImpl extends ServiceImpl<InsFeeAuditMapper, InsFe
     }
 
     @Override
-    public void updateToQuestionOrder(String orderNo,String status) {
+    public void updateToQuestionOrder(String orderNo, String status, String problemReason) {
+        log.info("更新订单的疑问状态。 orderNo=[{}],status=[{}], problemReason=[{}]",orderNo,status,problemReason);
         InsFeeAudit audit = this.getById(orderNo);
         if(audit.getAuditStatus() > 0){
             AssertionUtils.isFail(true, "订单已审核刷新订单详情页!");
@@ -672,7 +673,7 @@ public class InsFeeAuditServiceImpl extends ServiceImpl<InsFeeAuditMapper, InsFe
         if (!userName.equals(audit.getReceiveUser())) {
             AssertionUtils.isFail(true, "订单已被"+audit.getReceiveUser()+"领取返回待审核订单列表!");
         }
-
+        audit.setProblemReason(Objects.toString(problemReason,""));
         audit.setIsProblem(Integer.parseInt(status));
         this.updateById(audit);
     }

+ 2 - 0
tenant/insurance/quotation-summary/src/main/resources/mapper/InsFeeAuditMapper.xml

@@ -57,6 +57,8 @@
                ioc.jq_premium as jqPremium, ioc.sy_premium as syPremium, ioc.jy_premium as jyPremium,
                ioc.sum_premium as sumPremium,sd.name as deptName,ifa.create_time as createTime,
                ifa.create_by as createBy,io.pay_time as payTime, ifa.audit_time as auditTime,
+               ifa.audit_user as auditUser, ifa.refuse,
+               ifa.is_problem, ifa.problem_reason,
                ifa.audit_user as auditUser, ifa.refuse,
                 CASE ifa.is_problem
                 WHEN 0 THEN '否'

+ 25 - 0
tenant/organization/src/main/java/com/jzg/organization/client/PlatformClient.java

@@ -0,0 +1,25 @@
+package com.jzg.organization.client;
+
+
+import com.jzg.commons.core.page.HttpResult;
+import com.jzg.commons.entity.agreement.po.PtlAgreementAttribution;
+import io.swagger.v3.oas.annotations.Operation;
+import org.springframework.cloud.openfeign.FeignClient;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestParam;
+
+
+@FeignClient(name = "jzg-platform")
+public interface PlatformClient {
+
+    /**
+     * 根据协议属性id查询协议属性信息
+     *
+     * @author lipf
+     * @date 2026/5/22 15:00
+     */
+    @Operation(summary = "保险公司账号详情接口", description = "保险公司账号接口")
+    @PostMapping(value = "/manager/attribution/getAgreementAttribution2")
+    public HttpResult<PtlAgreementAttribution> getAgreementAttribution2(@RequestParam(value = "id") String id);
+
+}

+ 1 - 1
tenant/organization/src/main/java/com/jzg/organization/controller/PtlAgreementCostController.java

@@ -45,7 +45,7 @@ public class PtlAgreementCostController {
     @OperatorTrajectory(moduleName = "报价配置/费用管理/修改费用",OperationDict = OperationTypeEnum.EDITED_AGREEMENT, type = "U", mapperClass = PtlAgreementCostMapper.class,entityClass = PtlAgreementCostEnd.class)
     @Operation(summary = "协议费用管理修改")
     @PostMapping("update")
-    public HttpResult update(@RequestBody @Valid PtlAgreementCostEnd costEndList){
+    public HttpResult<String> update(@RequestBody @Valid PtlAgreementCostEnd costEndList){
         return ptlAgreementCostService.update(costEndList);
     }
 

+ 7 - 1
tenant/organization/src/main/java/com/jzg/organization/service/PtlAgreementCostService.java

@@ -21,7 +21,13 @@ public interface PtlAgreementCostService extends IService<PtlAgreementCost> {
     HttpResult save(PtlAgreemenCostAdd ptlAgreemenCostAdd);
 
 
-    HttpResult update(PtlAgreementCostEnd costEndList);
+    /**
+     * 协议费用管理修改
+     *
+     * @author lipf
+     * @date 2026/5/22 11:26
+     */
+    HttpResult<String> update(PtlAgreementCostEnd costEndList);
 
 
     HttpResult queryById(@NotNull(message = "id不能为空") Long id);

+ 12 - 3
tenant/organization/src/main/java/com/jzg/organization/service/impl/PtlAgreementCostServiceImpl.java

@@ -128,9 +128,16 @@ public class PtlAgreementCostServiceImpl extends ServiceImpl<PtlAgreementCostMap
         return HttpResult.ok(ReturnInformation.SUCCESS_MESSAGE);
     }
 
+    /**
+     * 协议费用管理修改
+     *
+     * @author lipf
+     * @date 2026/5/22 11:26
+     */
     @Override
     @Transactional(rollbackFor = Exception.class)
-    public HttpResult update(PtlAgreementCostEnd ptlAgreementCostEnd) {
+    public HttpResult<String> update(PtlAgreementCostEnd ptlAgreementCostEnd) {
+        log.info("协议费用修改。ptlAgreementCostEnd=[{}]", JSONUtil.toJsonStr(ptlAgreementCostEnd));
         if (ListUtils.hasDuplicates(ptlAgreementCostEnd.getRuleConditions())){
             return HttpResult.error("已存在相同且有效的费用规则,请检查");
         }
@@ -145,6 +152,8 @@ public class PtlAgreementCostServiceImpl extends ServiceImpl<PtlAgreementCostMap
             }
         }
         PtlAgreementCost ptlAgreementCost = BeanUtil.copyProperties(ptlAgreementCostEnd, PtlAgreementCost.class);
+        // modify by lipf, 2026年5月22日11:28:34 设置为待审核状态
+        ptlAgreementCost.setApproved(0);
         ptlAgreementCost.setCostRules(buildDescString(ptlAgreementCostEnd.getRuleConditions()));
         if (baseMapper.updateById(ptlAgreementCost) <= 0) {
             throw new RuntimeException(ReturnInformation.UPDATE_FAILED);
@@ -347,10 +356,10 @@ public class PtlAgreementCostServiceImpl extends ServiceImpl<PtlAgreementCostMap
         log.info("查询协议费用信息:costParam=[{}]", JSONUtil.toJsonStr(costParam));
         Page<CostManagementVo> costManagementVoPage = baseMapper.pageList(costParam.getPage(), costParam);
         costManagementVoPage.getRecords().forEach(item->{
-            if(item.getCostRules() != null && !item.getCostRules().equals("")){
+            if(item.getCostRules() != null && !item.getCostRules().isEmpty()){
                 item.setCostRules(item.getCostRules().substring(0,item.getCostRules().length()-1));
             }
-            if(item.getRuleDescription() != null && !item.getRuleDescription().equals("")){
+            if(item.getRuleDescription() != null && !item.getRuleDescription().isEmpty()){
                 item.setRuleDescription(item.getRuleDescription().substring(0,item.getRuleDescription().length()-1));
             }
             // 刷新有效状态

+ 7 - 3
tenant/organization/src/main/java/com/jzg/organization/service/impl/PtlAgreementDispatchServiceImpl.java

@@ -16,6 +16,7 @@ import com.jzg.commons.entity.po.*;
 import com.jzg.commons.util.StringUtils;
 import com.jzg.commons.util.idgen.IdGenerate;
 import com.jzg.organization.client.EsmInsCompanyClient;
+import com.jzg.organization.client.PlatformClient;
 import com.jzg.organization.mapper.PtlAgreementDispatchActionMapper;
 import com.jzg.organization.mapper.PtlAgreementDispatchAfterActionMapper;
 import com.jzg.organization.mapper.PtlAgreementDispatchMapper;
@@ -52,6 +53,8 @@ public class PtlAgreementDispatchServiceImpl extends ServiceImpl<PtlAgreementDis
     @Autowired
     SysDictService sysDictService;
     @Autowired
+    PlatformClient platformClient;
+    @Autowired
     PtlAgreementService ptlAgreementService;
     @Autowired
     EsmInsCompanyClient esmInsCompanyClient;
@@ -199,8 +202,10 @@ public class PtlAgreementDispatchServiceImpl extends ServiceImpl<PtlAgreementDis
                                 }
                             }
                         }else if("change_bs_account".equals(action.getActionCode())){
-                            if(Objects.nonNull(action.getActionJson().get("accountId"))) {
-                                HttpResult<PtlAgreementAttribution> agreementAttribution = esmInsCompanyClient.getAgreementAttribution(action.getActionJson().get("accountId").toString());
+                            String accountId = action.getActionJson().get("accountId").toString();
+                            if(Objects.nonNull(accountId)){
+                                HttpResult<PtlAgreementAttribution> agreementAttribution = platformClient.getAgreementAttribution2(accountId);
+                                //HttpResult<PtlAgreementAttribution> agreementAttribution = esmInsCompanyClient.getAgreementAttribution(accountId);
                                 if (agreementAttribution.getCode() == 200) {
                                     PtlAgreementAttribution data = agreementAttribution.getData();
                                     action.getActionJson().put("userName", data.getUsername());
@@ -282,7 +287,6 @@ public class PtlAgreementDispatchServiceImpl extends ServiceImpl<PtlAgreementDis
         return false;
     }
 
-
 }