Giter Site home page Giter Site logo

k3ssen / paymentmolliebundle Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ruudk/paymentmolliebundle

0.0 3.0 0.0 48 KB

A Symfony2 Bundle that provides access to the Mollie API. Based on JMSPaymentCoreBundle.

License: MIT License

PHP 100.00%

paymentmolliebundle's Introduction

RuudkPaymentMollieBundle

A Symfony2 Bundle that provides access to the Mollie API. Based on JMSPaymentCoreBundle.

Installation

Step1: Require the package with Composer

php composer.phar require ruudk/payment-mollie-bundle

Step2: Enable the bundle

Enable the bundle in the kernel:

<?php
// app/AppKernel.php

public function registerBundles()
{
    $bundles = array(
        // ...

        new Ruudk\Payment\MollieBundle\RuudkPaymentMollieBundle(),
    );
}

Step3: Configure

Add the following to your routing.yml:

ruudk_payment_mollie_notifications:
    pattern:  /webhook/mollie
    defaults: { _controller: ruudk_payment_mollie.controller.notification:processNotification }
    methods:  [GET, POST]

Add the following to your config.yml:

ruudk_payment_mollie:
    api_key:  Your API key
    logger:   true/false   # Default true
    methods:
      - ideal
      - mistercash
      - creditcard
      - sofort
      - banktransfer
      - belfius
      - kbc
      - ...

See the Mollie API documentation for all available methods.

Make sure you set the return_url in the predefined_data for every payment method you enable:

$form = $this->getFormFactory()->create('jms_choose_payment_method', null, array(
    'amount'   => $order->getAmount(),
    'currency' => 'EUR',
    'predefined_data' => array(
        'mollie_ideal' => array(
            'return_url' => $this->generateUrl('order_complete', array(), true),
        ),
    ),
));

It's also possible to set a description for the transaction in the predefined_data.

See JMSPaymentCoreBundle documentation for more info.

paymentmolliebundle's People

Contributors

ruudk avatar msvrtan avatar bobvandevijver avatar kalinowski5 avatar

Watchers

James Cloos avatar Kevin Driessen avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.