関数
AmazonMiddleware::setDeliveryDataWithCheckoutSession( bool $clearExisting = false )
Populate Welcart $_POST['delivery']
with Amazon checkout session data
パラメータ パラメータ
- $clearExisting
(bool) (任意)
true
if$_SESSION['usces_entry']['delivery']
should be cleared,false
otherwise. Default:false
ファイル: src/Routing/AmazonMiddleware.php
public function setDeliveryDataWithCheckoutSession($clearExisting = false) { return function () use ($clearExisting) { if ($clearExisting === true) { unset($_SESSION['usces_entry']['delivery']); } $response = $_SESSION['amazonCheckoutSession']; $_POST['delivery'] = $this->getDeliveryAddressFromCheckoutSession($response); }; }