Ver Fonte

查询报价单 返回null 改为 空对象

785834757 há 2 anos atrás
pai
commit
27b7593781

+ 4 - 0
src/main/java/com/ydtech/modules/order/service/impl/InsOrdersServiceImpl.java

@@ -644,6 +644,8 @@ public class InsOrdersServiceImpl extends ServiceImpl<InsOrdersMapper, InsOrders
             }
             JSONArray accidentInfo = JSON.parseArray(JSON.toJSONString(insDrivingIntentionInsuranceSon));
             orderAndAreaCompany.setAccidentInfo(accidentInfo);
+        }else{
+            orderAndAreaCompany.setAccidentInfo(new JSONArray());
         }
 
         //获取交强险种信息
@@ -651,6 +653,8 @@ public class InsOrdersServiceImpl extends ServiceImpl<InsOrdersMapper, InsOrders
                 orderAndAreaCompany.getProductid().equals(ProductsType.PT_0330034001.getCode()) ||
                         orderAndAreaCompany.getProductid().equals(ProductsType.PT_0330034002.getCode())) {
             orderAndAreaCompany.setJqInsuranceType(JqInsuranceType.toJsonArray());
+        }else{
+            orderAndAreaCompany.setJqInsuranceType(new JSONArray());
         }
         return HttpResult.ok("success", orderAndAreaCompany);
     }