silvercommerce/checkout
Composer 安装命令:
composer require silvercommerce/checkout
包简介
Adds a 'checkout' to a SilverStripe site which links to an Estimate and adds the ability to setup and pay
README 文档
README
Adds a checkout process, to allow users to pay for an Estimate using configured omnipay payment gateways.
Also allows you to overwrite the process so you can add more custom payment integration.
Install
Install this module using composer:
composer require silvercommerce/checkout
Usage
By default, this module works with silvercommerce/shoppingcart out of the box. But it is fairly
simple to use it to create payment workflows for a custom estimate if required.
Paying for a custom estimate
If you want to create a payment flow for a custom estimate, you simply have to create the estimate, add some items, add it to the checkout and then redirect. This can be done with a simple bit of code.
The example below has a custom controller that creates an estimate from a pre-defined product and then redirects to the checkout:
use SilverStripe\Core\Injector\Injector;
use SilverCommerce\Checkout\Control\Checkout;
use SilverCommerce\OrdersAdmin\Factory\OrderFactory;
class ProductRedirectController extends PageController
{
public function init()
{
parent::init();
$product = $this->Product(); // Instance of SilverCommerce\CatalogueAdmin\CatalogueProduct
$factory = OrderFactory::create();
$factory->addItem($product);
$factory->write();
$checkout = Injector::inst()->get(Checkout::class);
$checkout->setEstimate($factory->getOrder());
$this->redirect($checkout->Link());
}
}
silvercommerce/checkout 适用场景与选型建议
silvercommerce/checkout 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 2.61k 次下载、GitHub Stars 达 0, 最近一次更新时间为 2018 年 02 月 20 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「ecommerce」 「checkout」 「payments」 「silverstripe」 「commerce」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 silvercommerce/checkout 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 silvercommerce/checkout 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 silvercommerce/checkout 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
Nevogate Payment Gateway SDK
Dealing with payments through the Egyptian payment gateway PayMob
Librería para la gestión sencilla de pagos mediante TPV Redsys y Paypal
Rich payment solutions for Laravel framework. Paypal, payex, authorize.net, be2bill, omnipay, recurring paymens, instant notifications and many more
A PHP (and Laravel) package to interface with the Snipcart api.
Add a simple webshop to your Laravel project
统计信息
- 总下载量: 2.61k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 8
- 依赖项目数: 6
- 推荐数: 0
其他信息
- 授权协议: BSD-3-Clause
- 更新时间: 2018-02-20