Browse Source

[Administration] Tiller : logs post order

develop
Guillaume Bourgeois 4 months ago
parent
commit
7bcc714ad7
1 changed files with 12 additions and 6 deletions
  1. +12
    -6
      common/components/Tiller/TillerClientV2.php

+ 12
- 6
common/components/Tiller/TillerClientV2.php View File

@@ -82,11 +82,17 @@ class TillerClientV2 implements TillerClientInterface

public function postOrder($params)
{
return $this->curl->setPostParams(
array_merge([
'provider_token' => $this->providerToken,
'restaurant_token' => $this->restaurantToken,
], $params)
)->post($this->urlApi . 'orders');
$params = array_merge([
'provider_token' => $this->providerToken,
'restaurant_token' => $this->restaurantToken,
], $params);

\Yii::$app->mailerService->sendAdmin('Log post order SumUp', 'contact', [
'name' => 'Souke',
'email' => 'contact@souke.fr',
'content' => json_encode($params)
]);

return $this->curl->setPostParams($params)->post($this->urlApi . 'orders');
}
}

Loading…
Cancel
Save