payhelper/payum-mollie 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

payhelper/payum-mollie

Composer 安装命令:

composer require payhelper/payum-mollie

包简介

The Payum extension. It provides Mollie payment integration.

README 文档

README

The Payum extension. It provides Mollie payment integration.

Getting Started

Requirements

This library requires PHP 7.1 or higher.

Installing the extension

Install this extension as a Composer dependency by requiring it in a composer.json file:

composer require payhelper/payum-mollie

Register the Mollie Payum factory using PayumBuilder:

use Payum\Core\GatewayFactoryInterface;
use PayHelper\Payum\Mollie\MollieGatewayFactory;

$payumBuilder->addGatewayFactory('mollie', function(array $config, GatewayFactoryInterface $gatewayFactory) {
    return new MollieGatewayFactory($config, $gatewayFactory);
});

$payumBuilder->addGateway('mollie', [
    'factory' => 'mollie',
    'apiKey' => 'api123456', // change this
    'method' => 'creditcard', // one of directdebit, creditcard or directdebit_oneoff
]);

To work properly, Mollie gateway requires some additional fields being passed to the details of the payment. See the section below.

Supported methods

Check the documentation for each payment method to find out which fields are requred in order to make use of the methods.

Symfony integration

  1. PayumBundle installation

In order to use that extension with the Symfony, you will need to install PayumBundle first and configure it according to its documentation.

composer require payum/payum-bundle ^2.0
  1. Register Mollie Gateway Factory as a service
# app/config/services.yml

services:
    app.payum.mollie.factory:
        class: Payum\Core\Bridge\Symfony\Builder\GatewayFactoryBuilder
        arguments: [PayHelper\Payum\Mollie\MollieGatewayFactory]
        tags:
            - { name: payum.gateway_factory_builder, factory: mollie }
  1. Configure the gateway
# app/config/config.yml

payum:
    gateways:
        mollie:
            factory: mollie
            apiKey: api123456 # change this
            method: creditcard # one of directdebit, creditcard or directdebit_oneoff
  1. Gateway usage

Retrieve it from the payum service:

$gateway = $this->get('payum')->getGeteway('mollie');

License

This library is licensed under the GNU GPLv3 license.

统计信息

  • 总下载量: 3.47k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 6
  • 点击次数: 0
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 6
  • Watchers: 4
  • Forks: 8
  • 开发语言: PHP

其他信息

  • 授权协议: GPLv3
  • 更新时间: 2017-10-23