...
|
...
|
@@ -210,8 +210,7 @@ class UsersController extends HomeBaseController{ |
|
|
$price=new OrderController();
|
|
|
$order['price']=$price->getPrice($users_id,$order['start_time'],$order['end_time']);
|
|
|
$time_info=$this->getTimeInfo($order['start_time'],$order['end_time']);
|
|
|
dump($time_info);
|
|
|
array_merge($order,$time_info);
|
|
|
$order=array_merge($order,$time_info);
|
|
|
$this->apiResponse(200,'success',$order);
|
|
|
}
|
|
|
|
...
|
...
|
@@ -243,7 +242,7 @@ class UsersController extends HomeBaseController{ |
|
|
$this->apiResponse(200,'没有未支付订单');
|
|
|
}
|
|
|
$time_info=$this->getTimeInfo($order['start_time'],$order['end_time']);
|
|
|
array_merge($order,$time_info);
|
|
|
$order=array_merge($order,$time_info);
|
|
|
$this->apiResponse(200,'success',$order);
|
|
|
}
|
|
|
|
...
|
...
|
@@ -377,6 +376,9 @@ class UsersController extends HomeBaseController{ |
|
|
|
|
|
|
|
|
public function getTimeInfo($start,$end){
|
|
|
if(empty($end)){
|
|
|
$end=time();
|
|
|
}
|
|
|
$time=$end-$start;
|
|
|
$return['hour']=floor($time/3600);
|
|
|
$return['min']=floor(($time-$return['hour']*3600)/60);
|
...
|
...
|
|