quguofeng 2 years ago
parent
commit
84dd756466
2 changed files with 8 additions and 0 deletions
  1. 6 0
      app/controller/api/Common.php
  2. 2 0
      route/api.php

+ 6 - 0
app/controller/api/Common.php

@@ -15,6 +15,7 @@ namespace app\controller\api;
 
 
 use app\common\repositories\delivery\DeliveryOrderRepository;
+use app\common\repositories\store\order\StoreOrderRepository;
 use app\common\repositories\store\product\ProductAssistSetRepository;
 use app\common\repositories\store\product\ProductGroupBuyingRepository;
 use app\common\repositories\store\product\ProductGroupRepository;
@@ -468,4 +469,9 @@ class Common extends BaseController
         }
         return app('json')->success(['subscribe' => false, 'qrcode' => systemConfig('wechat_qrcode')]);
     }
+    public function order_time()
+    {
+        $storeOrderRepository = app()->make(StoreOrderRepository::class);
+        $storeOrderRepository->expireOrder();
+    }
 }

+ 2 - 0
route/api.php

@@ -546,6 +546,8 @@ Route::group('api/', function () {
     Route::get('common/menus', 'api.Common/menus');
     //首页数据
     Route::get('common/home', 'api.Common/home');
+    //超时
+    Route::get('common/order_time', 'api.Common/order_time');
     //经纬度转位置信息
     Route::get('lbs/geocoder', 'api.Common/lbs_geocoder');
     //获取支付宝支付链接