diff --git a/KwcShop/Kwc/Shop/Cart/Checkout/Payment/Wirecard/ConfirmLink/Component.php b/KwcShop/Kwc/Shop/Cart/Checkout/Payment/Wirecard/ConfirmLink/Component.php index 09be95d..8de3495 100644 --- a/KwcShop/Kwc/Shop/Cart/Checkout/Payment/Wirecard/ConfirmLink/Component.php +++ b/KwcShop/Kwc/Shop/Cart/Checkout/Payment/Wirecard/ConfirmLink/Component.php @@ -33,6 +33,11 @@ public static function buildWirecardButtonHtml($params, $payment, $order, $initU 'orderDescription' => $order->firstname . ' ' . $order->lastname . ' (' . $order->zip . '), '.$payment->trlKwf('Order: {0}', $order->number), 'firstname' => $order->firstname, 'lastname' => $order->lastname, + 'email' => $order->email, + 'city' => $order->city, + 'country' => $order->country, + 'street1' => $order->street, + 'postal-code' => $order->zip, 'displayText' => $payment->trlKwf('Thank you very much for your order.'), 'successRedirectUrl' => $payment->getChildComponent('_success')->getAbsoluteUrl(), 'failRedirectUrl' => $payment->getChildComponent('_failure')->getAbsoluteUrl(), diff --git a/KwcShop/Kwc/Shop/Cart/Checkout/Payment/Wirecard/ConfirmLink/Controller.php b/KwcShop/Kwc/Shop/Cart/Checkout/Payment/Wirecard/ConfirmLink/Controller.php index 5313722..39a0267 100644 --- a/KwcShop/Kwc/Shop/Cart/Checkout/Payment/Wirecard/ConfirmLink/Controller.php +++ b/KwcShop/Kwc/Shop/Cart/Checkout/Payment/Wirecard/ConfirmLink/Controller.php @@ -41,12 +41,22 @@ public function jsonInitiatePaymentAction() $client->setAuth($wirecardUsername, $wirecardPassword, \Zend_Http_Client::AUTH_BASIC); $postData = array( 'payment' => array_merge(array( + 'card' => array( + 'merchant-tokenization-flag' => true, + ), 'merchant-account-id' => array( 'value' => $wirecardMerchantId ), 'account-holder' => array( 'first-name' => $this->getParam('firstname'), 'last-name' => $this->getParam('lastname'), + 'email' => $this->getParam('email'), + 'address' => array( + 'street1' => $this->getParam('street1'), + 'postal-code' => $this->getParam('zip'), + 'city' => $this->getParam('city'), + 'country' => $this->getParam('country'), + ) ), 'locale' => $this->getParam('language'), 'request-id' => $this->getParam('orderId'), diff --git a/README.md b/README.md index 7630913..b575353 100644 --- a/README.md +++ b/README.md @@ -2,16 +2,9 @@ Shop Component for Koala Framework #### Wirecard credentials -Several types of payment methods can be configured. Each payment method has its own individual test credentials, which need to be set correctly for each payment method to work properly in a test environment. Some payment methods are shown below but other configurations can be found at: https://doc.wirecard.com/PPv2.html#PPv2_PaymentMethods +Several types of payment methods can be configured. Each payment method has its own individual test credentials, which need to be set correctly for each payment method to work properly in a test environment. Some payment methods are shown below but other configurations can be found at: https://doc.wirecard.com/CC_Main.html#PPv2_CC_3DSecure ``` [test] -;creditcard -wirecard.url = https://wpp-test.wirecard.com/api/payment/register -wirecard.merchant.id = 7a6dd74f-06ab-4f3f-a864-adc52687270a -wirecard.secret = a8c3fce6-8df7-4fd6-a1fd-62fa229c5e55 -wirecard.auth.username = "70000-APIDEMO-CARD" -wirecard.auth.password = "ohysS0-dvfMx" - ;creditcard with 3d-secure enabled wirecard.url = https://wpp-test.wirecard.com/api/payment/register wirecard.merchant.id = cad16b4a-abf2-450d-bcb8-1725a4cef443