Browse Source

下单

master
Lemon 5 years ago
parent
commit
6661c9184a
  1. 2
      app/Controller/v3/OrderOnlineController.php
  2. 1
      app/Service/v3/Implementations/AppointmentTimeService.php

2
app/Controller/v3/OrderOnlineController.php

@ -96,7 +96,7 @@ class OrderOnlineController extends BaseController
'distribution_price' => 0 'distribution_price' => 0
]; ];
//返回预约送达时间 数组 //返回预约送达时间 数组
$res['appointment_time'] = $this->appointmentTimeService->get($shopcartIds);
$res['appointment_time'] = $this->appointmentTimeService->do($shopcartIds);
$res['store_list'] = $this->shopCartService->getGoodsByShopcartId($shopcartIds); $res['store_list'] = $this->shopCartService->getGoodsByShopcartId($shopcartIds);
//获取用户优惠券 //获取用户优惠券

1
app/Service/v3/Implementations/AppointmentTimeService.php

@ -77,6 +77,7 @@ class AppointmentTimeService implements AppointmentTimeServiceInterface
if($nowTime > $time1Max){ if($nowTime > $time1Max){
$time1Max = $nowTime; $time1Max = $nowTime;
} }
$res = [];
for($i = 1;$i<=10;$i++){ for($i = 1;$i<=10;$i++){
$time = time() + (30*60*$i); $time = time() + (30*60*$i);
if($time < $time2Min){ if($time < $time2Min){

Loading…
Cancel
Save