diff --git a/src/Core/ViewConfig.php b/src/Core/ViewConfig.php index 422e7f9c..73a7d79a 100644 --- a/src/Core/ViewConfig.php +++ b/src/Core/ViewConfig.php @@ -283,7 +283,15 @@ public function getPayload(): string "phoneNumber", "billingAddress" ]); - $payload->setPaymentIntent('AuthorizeWithCapture'); + + $paymentIntent = 'Authorize'; + $canHandlePendingAuth = true; + if (OxidServiceProvider::getAmazonClient()->getModuleConfig()->isOneStepCapture()) { + $paymentIntent = 'AuthorizeWithCapture'; + $canHandlePendingAuth = false; + } + $payload->setPaymentIntent($paymentIntent); + $payload->setCanHandlePendingAuthorization($canHandlePendingAuth); $delAddress = OxidServiceProvider::getDeliveryAddressService(); $address = $delAddress->getTempDeliveryAddressAddress();