|
|
@@ -3,6 +3,7 @@ package com.ydtech.modules.order.controller;
|
|
|
import com.alibaba.fastjson.JSONArray;
|
|
|
import com.alibaba.fastjson.JSONObject;
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
|
+import com.fasterxml.jackson.core.JsonProcessingException;
|
|
|
import com.ydtech.aop.request.RequestSingleParam;
|
|
|
import com.ydtech.core.page.HttpResult;
|
|
|
import com.ydtech.exception.SystemException;
|
|
|
@@ -340,4 +341,67 @@ public class QuoteController extends BaseController {
|
|
|
|
|
|
return httpResult;
|
|
|
}
|
|
|
+
|
|
|
+
|
|
|
+ @PostMapping(value = "batchOrderStatus")
|
|
|
+ public HttpResult batchOrderStatus(@RequestSingleParam("orderNos") List<String> orderNos) throws Exception {
|
|
|
+ List<InsAreaCompany> list = insAreaCompanyService.list(new LambdaQueryWrapper<InsAreaCompany>()
|
|
|
+ .in(InsAreaCompany::getId, orderNos));
|
|
|
+ list.forEach(item -> {
|
|
|
+ //如果是爬虫的 先调用爬虫的查询订单状态
|
|
|
+ if (Objects.isNull(item.getApiType()) || item.getApiType() == 2) {
|
|
|
+ try {
|
|
|
+ insCrawlerOrderService.verifyPayment(item.getId());
|
|
|
+ }catch (Exception e){
|
|
|
+
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if (item.getCompanyId().equals("AICS1000000") && item.getApiType() == 1) {
|
|
|
+ try {
|
|
|
+ yongchengOrderApiService.callbackAnOrder(item.getId());
|
|
|
+ }catch (Exception e){
|
|
|
+
|
|
|
+ }
|
|
|
+ } else if (item.getCompanyId().equals("ZMBX1000000") && item.getApiType() == 1) {
|
|
|
+ try {
|
|
|
+ zhongMeiOrderApiService.paymentEnquiry(item.getId());
|
|
|
+ }catch (Exception e){}
|
|
|
+ } else if (item.getCompanyId().equals("ZKIC1000000")) {
|
|
|
+ try {
|
|
|
+ zijinOrderApiService.auditStatusQuery(item.getId());
|
|
|
+ }catch (Exception e){}
|
|
|
+ } else if (item.getCompanyId().equals("XDCX1000000")) {
|
|
|
+ try {
|
|
|
+ guorenOrderApiService.pay(item.getId());
|
|
|
+ }catch (Exception e){}
|
|
|
+ } else if (item.getCompanyId().equals("YGBX1000000")) {
|
|
|
+ try {
|
|
|
+ yangGuangOrderApiService.paymentCallback(item.getId());
|
|
|
+ } catch (JsonProcessingException e) {
|
|
|
+ throw new RuntimeException(e);
|
|
|
+ }
|
|
|
+ } else if (item.getCompanyId().equals("HTIC1000000")) {
|
|
|
+ try {
|
|
|
+ huaTaiOrderApiService.paymentEnquiry(item.getId());
|
|
|
+ }catch (Exception e){}
|
|
|
+ } else if (item.getCompanyId().equals("DJPC1000000")) {
|
|
|
+ try {
|
|
|
+ daJiaOrderService.verifyPayment(item.getId());
|
|
|
+ }catch (Exception e){}
|
|
|
+ } else if (item.getCompanyId().equals("CHAC1000000")) {
|
|
|
+ try {
|
|
|
+ chengTaiOrderApiService.getPayUrl(item.getId());
|
|
|
+ } catch (Exception e) {
|
|
|
+ throw new RuntimeException(e);
|
|
|
+ }
|
|
|
+ } else if (item.getCompanyId().equals("BPIC1000000")) {
|
|
|
+ try {
|
|
|
+ boHaiOrderApiService.auditStatusQuery(item.getId());
|
|
|
+ } catch (Exception e) {
|
|
|
+ throw new RuntimeException(e);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ });
|
|
|
+ return HttpResult.ok("查询成功");
|
|
|
+ }
|
|
|
}
|