Pārlūkot izejas kodu

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

lipf 4 mēneši atpakaļ
vecāks
revīzija
f432139f82

+ 23 - 15
commons/src/main/java/com/jzg/commons/entity/finance/vo/InvoiceReceivableExportExcelVo.java

@@ -41,64 +41,68 @@ public class InvoiceReceivableExportExcelVo extends BaseModel  {
     @ExcelProperty(value = "协议代码", index = 1)
     private String agreementCode;
 
+    @Schema(description = "协议类型")
+    @ExcelProperty(value = "协议类型", index = 2)
+    private String agreementType;
+
     @Schema(description = "车牌号")
-    @ExcelProperty(value = "车牌号", index = 2)
+    @ExcelProperty(value = "车牌号", index = 3)
     private String licenseNo;
 
     @Schema(description = "险种编号")
-    @ExcelProperty(value = "险种编号", index = 3)
+    @ExcelProperty(value = "险种编号", index = 4)
     private String productId;
 
     @Schema(description = "险种名称")
-    @ExcelProperty(value = "险种名称", index = 4)
+    @ExcelProperty(value = "险种名称", index = 5)
     private String productName;
 
     @Schema(description = "被保险人姓名")
-    @ExcelProperty(value = "被保险人姓名", index = 5)
+    @ExcelProperty(value = "被保险人姓名", index = 6)
     private String insuredPerson;
 
     @Schema(description = "订单号")
-    @ExcelProperty(value = "订单号", index = 6)
+    @ExcelProperty(value = "订单号", index = 7)
     private String orderNo;
 
     @Schema(description = "交强险保单号")
-    @ExcelProperty(value = "交强险保单号", index = 7)
+    @ExcelProperty(value = "交强险保单号", index = 8)
     private String jqPolicyNo;
 
     @Schema(description = "交强险手续费比例")
-    @ExcelProperty(value = "交强险手续费比例(%)", index = 8)
+    @ExcelProperty(value = "交强险手续费比例(%)", index = 9)
     private String jqSuperviseCostsProportion;
 
     @Schema(description = "交强险跟单费比例")
-    @ExcelProperty(value = "交强险跟单费比例(%)", index = 9)
+    @ExcelProperty(value = "交强险跟单费比例(%)", index = 10)
     private String jqOtherCostsProportion;
 
     @Schema(description = "商业险保单号")
-    @ExcelProperty(value = "商业险保单号", index = 10)
+    @ExcelProperty(value = "商业险保单号", index = 11)
     private String syPolicyNo;
 
     @Schema(description = "商业险手续费比例")
-    @ExcelProperty(value = "商业险手续费比例(%)", index = 11)
+    @ExcelProperty(value = "商业险手续费比例(%)", index = 12)
     private String sySuperviseCostsProportion;
 
     @Schema(description = "商业险跟单费比例")
-    @ExcelProperty(value = "商业险跟单费比例(%)", index = 12)
+    @ExcelProperty(value = "商业险跟单费比例(%)", index = 13)
     private String syOtherCostsProportion;
 
     @Schema(description = "非车险保单号")
-    @ExcelProperty(value = "非车险保单号", index = 13)
+    @ExcelProperty(value = "非车险保单号", index = 14)
     private String jyPolicyNo;
 
     @Schema(description = "非车险手续费比例")
-    @ExcelProperty(value = "非车险手续费比例(%)", index = 14)
+    @ExcelProperty(value = "非车险手续费比例(%)", index = 15)
     private String jySuperviseCostsProportion;
 
     @Schema(description = "非车险跟单费比例")
-    @ExcelProperty(value = "非车险跟单费比例(%)", index = 15)
+    @ExcelProperty(value = "非车险跟单费比例(%)", index = 16)
     private String jyOtherCostsProportion;
 
     @Schema(description = "公司编码")
-    @ExcelProperty(value = "公司编码", index = 16)
+    @ExcelProperty(value = "公司编码", index = 17)
     private String companyId;
 
     @Schema(description = "错误信息")
@@ -141,6 +145,10 @@ public class InvoiceReceivableExportExcelVo extends BaseModel  {
             resultVo.setMessage("公司编码不能为空");
             return resultVo;
         }
+        if (StrUtil.isBlank(this.getAgreementType())) {
+            resultVo.setMessage("协议类型不能为空");
+            return resultVo;
+        }
 
         // 交强险:有保单号 → 手续费、跟单费必填
         if (StrUtil.isNotBlank(this.getJqPolicyNo())

+ 2 - 1
tenant/organization/src/main/java/com/jzg/organization/service/impl/ReceivableServiceImpl.java

@@ -1189,7 +1189,8 @@ public class ReceivableServiceImpl extends ServiceImpl<ReceivableMapper, InsPlyI
 
             // 查询数据库中是否已存在该协议
             PtlAgreement ptlAgreement = ptlAgreementMapper.selectOne(new LambdaQueryWrapper<PtlAgreement>()
-                    .eq(PtlAgreement::getAgreementCode, vo.getAgreementCode()));
+                    .eq(PtlAgreement::getAgreementCode, vo.getAgreementCode())
+                    .eq(PtlAgreement::getAgreementType, vo.getAgreementType()));
 
             // 数据库不存在 → 直接失败
             if (Objects.isNull(ptlAgreement)) {