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

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

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

payum/payum-bundle

最新稳定版本:2.6.2

Composer 安装命令:

composer require payum/payum-bundle

包简介

One million downloads of Payum already! Payum offers everything you need to work with payments. Check more visiting site.

README 文档

README

Payum is an MIT-licensed open source project with its ongoing development made possible entirely by the support of community and our customers. If you'd like to join them, please consider:

PayumBundle

Gitter Build Status Total Downloads Latest Stable Version

The bundle integrate payum into symfony framework. It already supports +35 gateways. Provide nice configuration layer, secured capture controller, storages integration and lots of more features.

Sylius, an open source headless eCommerce platform, base its payment solutions on top of the bundle.

Resources

Examples

Configure:

payum:
    storages:
        Payum\Core\Model\Payment:
            filesystem:
                storage_dir: '%kernel.root_dir%/Resources/payments'
                id_property: number

    security:
        token_storage:
            Payum\Core\Model\Token:
                filesystem:
                    storage_dir: '%kernel.root_dir%/Resources/gateways'
                    id_property: hash
                
    gateways:
        offline:
            factory: offline

note if you're using Symfony 4+ then create config/packages/payum.yaml file with contents described above.

Purchase

<?php
use Payum\Core\Model\Payment;
use Payum\Core\Reply\HttpRedirect;
use Payum\Core\Reply\HttpResponse;
use Payum\Core\Request\Capture;

$payment = new Payment;
$payment->setNumber(uniqid());
$payment->setCurrencyCode('EUR');
$payment->setTotalAmount(123); // 1.23 EUR
$payment->setDescription('A description');
$payment->setClientId('anId');
$payment->setClientEmail('foo@example.com');

$gateway = $this->get('payum')->getGateway('offline');
$gateway->execute(new Capture($payment));

Get status

<?php
use Payum\Core\Request\GetHumanStatus;

$gateway->execute($status = new GetHumanStatus($payment));

echo $status->getValue();

Other operations.

<?php
use Payum\Core\Request\Authorize;
use Payum\Core\Request\Cancel;
use Payum\Core\Request\Refund;

$gateway->execute(new Authorize($payment));

$gateway->execute(new Refund($payment));

$gateway->execute(new Cancel($payment));

Contributing

PayumBundle is an open source, community-driven project. Pull requests are very welcome.

Like it? Spread the word!

Star PayumBundle on GitHub or packagist.

License

The bundle is released under the MIT License.

统计信息

  • 总下载量: 9.83M
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 594
  • 点击次数: 3
  • 依赖项目数: 45
  • 推荐数: 1

GitHub 信息

  • Stars: 580
  • Watchers: 18
  • Forks: 146
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-01-04

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固