PHPackages                             payplug/sylius-payplug-plugin - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. payplug/sylius-payplug-plugin

ActiveSylius-plugin

payplug/sylius-payplug-plugin
=============================

PayPlug payment plugin for Sylius applications.

1.11.1(10mo ago)873.4k—4.7%19[6 issues](https://github.com/payplug/SyliusPayPlugPlugin/issues)[3 PRs](https://github.com/payplug/SyliusPayPlugPlugin/pulls)MITPHPPHP ^8.0CI failing

Since May 15Pushed 6mo ago9 watchersCompare

[ Source](https://github.com/payplug/SyliusPayPlugPlugin)[ Packagist](https://packagist.org/packages/payplug/sylius-payplug-plugin)[ RSS](/packages/payplug-sylius-payplug-plugin/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (41)Versions (63)Used By (0)

[![License](https://camo.githubusercontent.com/de2d9b48e03e69d901b69bada3e8eccc2387f3246e9490505f1bc2bd2f8f7775/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f706179706c75672f706179706c75672d73796c6975732e737667)](https://github.com/payplug/SyliusPayPlugPlugin/blob/master/LICENSE)[![CI](https://github.com/payplug/SyliusPayPlugPlugin/workflows/CI/badge.svg?branch=master)](https://github.com/payplug/SyliusPayPlugPlugin/workflows/CI/badge.svg?branch=master)[![Version](https://camo.githubusercontent.com/532099e1c5bb6f032b7b63700a95b90eee5ab8b21913baa485540a5cf759f6d4/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f706179706c75672f706179706c75672d73796c6975732e737667)](https://packagist.org/packages/payplug/payplug-sylius)[![Total Downloads](https://camo.githubusercontent.com/ca439d102ff806ac978f8f0df727fbebfe7ca733457841e743b7d1ce2ba13cd5/68747470733a2f2f706f7365722e707567782e6f72672f706179706c75672f706179706c75672d73796c6975732f646f776e6c6f616473)](https://packagist.org/packages/payplug/payplug-sylius)

 [ ![](https://camo.githubusercontent.com/1567208cc7c8ec53cf6e2af4f54449a9bb3ab0dee7916998de4e3ce9b7f79015/68747470733a2f2f64656d6f2e73796c6975732e636f6d2f6173736574732f73686f702f696d672f6c6f676f2e706e67) ](https://sylius.com)

Payplug payment plugin for Sylius
=================================

[](#payplug-payment-plugin-for-sylius)

This plugin allows you to integrate Payplug payment with Sylius platform app including payment features and refunding orders.

Requirements
------------

[](#requirements)

In the channel settings, the base currency must be set to **EUR** because the payment gateway only works in this currency.

In local environment, the plugin will not work properly because you will not be notified of the status of payments from the payment gateway.

> #### ⚠️ Refunds requirements
>
> [](#️-refunds-requirements)
>
> You need to make some adjustments in order to make our plugin worked normally due to a dependency to [refund-plugin](https://github.com/Sylius/RefundPlugin). Please follow those requirements:
>
> To generate "Credit memos" when refunding, your server need to have the [**WKHTMLTOPDF**](https://wkhtmltopdf.org/) binary as explain in [refund-pluging documentation # Pre-requirements](https://github.com/Sylius/RefundPlugin/tree/master#pre---requirements)

Compatibility
-------------

[](#compatibility)

VersionPHP7.4, 8.0, 8.1Sylius1.9, 1.10, 1.11, 1.12Installation
------------

[](#installation)

1. Require the **payplug/sylius-payplug-plugin** :

    ```
    composer config extra.symfony.allow-contrib true
    composer require payplug/sylius-payplug-plugin
    ```
2. Apply migrations to your database:

    ```
    bin/console doctrine:migrations:migrate
    ```
3. Copy templates that are overridden by Sylius into `templates/bundles/SyliusAdminBundle`

    ```
    mkdir -p templates/bundles/SyliusAdminBundle/
    cp -R vendor/payplug/sylius-payplug-plugin/src/Resources/views/SyliusAdminBundle/* templates/bundles/SyliusAdminBundle/
    ```
4. Add Payplug to refundable payment method for Sylius Refund Plugin in `config/services.yaml`

    ```
    parameters:
        locale: fr_FR
        sylius_refund.supported_gateways:
            - payplug
            - payplug_oney
            - payplug_bancontact
            - payplug_apple_pay
            - payplug_american_express
    ```
5. Add Payplug routes in `config/routes.yaml`

    ```
    sylius_payplug:
       resource: "@PayPlugSyliusPayPlugPlugin/Resources/config/routing.yaml"
    ```
6. Add Traits for Customer and PaymentMethod entities

- App\\Entity\\Customer\\Customer

    ```
