|
@@ -114,7 +114,7 @@ class DouYinService
|
|
|
];
|
|
];
|
|
|
$order = DouyinOrder::create($create_data);
|
|
$order = DouyinOrder::create($create_data);
|
|
|
Db::commit();
|
|
Db::commit();
|
|
|
- return $order['id'];
|
|
|
|
|
|
|
+ return $create_data['order_number'];
|
|
|
} catch (\Exception $e) {
|
|
} catch (\Exception $e) {
|
|
|
Db::rollback();
|
|
Db::rollback();
|
|
|
throw new \Exception($e->getMessage());
|
|
throw new \Exception($e->getMessage());
|
|
@@ -189,9 +189,9 @@ class DouYinService
|
|
|
}
|
|
}
|
|
|
public static function reservation($params)
|
|
public static function reservation($params)
|
|
|
{
|
|
{
|
|
|
- $lon_lat = get_address_lat_lng($params['user_address']);
|
|
|
|
|
|
|
+ /*$lon_lat = get_address_lat_lng($params['user_address']);
|
|
|
$params['lon'] = $lon_lat['lon'];
|
|
$params['lon'] = $lon_lat['lon'];
|
|
|
- $params['lat'] = $lon_lat['lat'];
|
|
|
|
|
|
|
+ $params['lat'] = $lon_lat['lat'];*/
|
|
|
|
|
|
|
|
// $params['order_number']
|
|
// $params['order_number']
|
|
|
Db::startTrans();
|
|
Db::startTrans();
|
|
@@ -199,6 +199,7 @@ class DouYinService
|
|
|
$order = DouyinOrder::where('order_number', $params['order_number'])->findOrEmpty();
|
|
$order = DouyinOrder::where('order_number', $params['order_number'])->findOrEmpty();
|
|
|
if(!$order->isEmpty()){
|
|
if(!$order->isEmpty()){
|
|
|
$consultation = ExternalConsultation::where('id', $order->consultation_id)->findOrEmpty()->toArray();
|
|
$consultation = ExternalConsultation::where('id', $order->consultation_id)->findOrEmpty()->toArray();
|
|
|
|
|
+ $consultation['mobile'] = $params['mobile']??$consultation['mobile'];
|
|
|
$consultation['user_address'] = $params['user_address'];
|
|
$consultation['user_address'] = $params['user_address'];
|
|
|
$consultation['lon'] = $params['lon'];
|
|
$consultation['lon'] = $params['lon'];
|
|
|
$consultation['lat'] = $params['lat'];
|
|
$consultation['lat'] = $params['lat'];
|