Download the PHP package pimcore/payment-provider-unzer without Composer
On this page you can find all versions of the php package pimcore/payment-provider-unzer. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download pimcore/payment-provider-unzer
More information about pimcore/payment-provider-unzer
Files in pimcore/payment-provider-unzer
Package payment-provider-unzer
Short Description Pimcore Payment Provider - Unzer (Heidelpay)
License GPL-3.0+
Informations about the package payment-provider-unzer
Pimcore E-Commerce Framework Payment Provider - Unzer (former: Heidelpay)
Unzer Web Integration
To integrate Unzer web integration see Unzer docs and follow following steps.
The basic flow goes as following:
- Unzer gets initialized via java script and depending on activated payment methods additional form fields are injected to view template.
- User selects payment method and enters additional information if necessary (e.g. credit card information).
- Information is submitted to unzer, payment transaction is started and payment id is returned.
- Payment id is submitted back to Pimcore and Pimcore payment transaction is started.
- If necessary user is redirected to payment provider (e.g. Paypal).
- If user comes back from external payment site, payment state is checked server-to-server between Pimcore and unzer and if successful order is committed and user is redirected to success page.
Installation
Install latest version with composer:
Enable bundle via console or extensions manager in Pimcore backend:
Configuration
Setup payment provider in e-commerce framework configuration. The access keys you find in Unzer documentation (or you will get them from Unzer for production integrations).
Payment Information: Order payment section "Payment Informations" stores information about every payment trial by Customer.
Add additional fields in "PaymentInfo" fieldcollection, so that Order Manager stores information in Order object:
Create View Template
Create view template for payment method selection. This view template
- needs to include a javascript and a css from Unzer.
- has a list of all provided payment methods and depending of the payment method additional form elements.
- includes a java script that handles data communication the data to Unzer.
- has an additional form that submits successful payment information (Unzer payment id) back to Pimcore.
Sample template with Creditcard, Paypal and Sofort
Sample Javascript (payment.js) with Creditcard, Paypal and Sofort
5) Create Controller Action for Payment Selection
The only special thing in this controller action is to get public access key out of payment provider and assign it to the template.
6) Create Controller Action for Starting Payment
To this action the paymentId of Unzer is submitted after payment transaction is started successfully on client side.
Additionally an error action is defined to extract the error messages from Unzer.
7) Create Controller Action for Commit Order Finally commit order and redirect user to order success page.
Important Configuration
Please make sure that serialize_precision
is set to a very high value, or even better to -1
in order to prevent rounding issues with the unzer sdk.
For details also see https://docs.unzer.com/integrate/php-sdk/installation/#php-configuration
All versions of payment-provider-unzer with dependencies
pimcore/pimcore Version ^11.0
pimcore/ecommerce-framework-bundle Version ^1.0