magenxcommerce / module-instant-purchase
N/A
100.4.2
2021-10-20 06:14 UTC
Requires
- php: ~7.3.0||~7.4.0
- magenxcommerce/framework: 103.0.*
- magenxcommerce/module-catalog: 104.0.*
- magenxcommerce/module-customer: 103.0.*
- magenxcommerce/module-quote: 101.2.*
- magenxcommerce/module-sales: 103.0.*
- magenxcommerce/module-shipping: 100.4.*
- magenxcommerce/module-store: 101.1.*
- magenxcommerce/module-vault: 101.2.*
Replaces
- magento/module-instant-purchase: *
- dev-placeholder
- dev-default
- dev-2.4.3-release
- 100.4.2.x-dev
- 100.4.2
- 100.4.1.x-dev
- 100.4.1
- 100.4.0.x-dev
- 100.4.0
- 100.3.7.x-dev
- 100.3.7
- 100.3.6.x-dev
- 100.3.6
- 100.3.5.x-dev
- 100.3.5
- 100.3.4.x-dev
- 100.3.4
- 100.3.3.x-dev
- 100.3.3
- 100.3.2.x-dev
- 100.3.2
- 100.3.1.x-dev
- 100.3.1
- 100.3.0.x-dev
- 100.3.0
- 100.2.6.x-dev
- 100.2.6
- 100.2.5.x-dev
- 100.2.5
- 100.2.4.x-dev
- 100.2.4
- 2.4.3.x-dev
- 2.4.2.x-dev
- 2.4.1.x-dev
- 2.4.0.x-dev
- 2.3.7.x-dev
- 2.3.6.x-dev
- 2.3.5.x-dev
- 2.3.4.x-dev
- 2.3.3.x-dev
- 2.3.2.x-dev
- 2.3.1.x-dev
- 2.3.0.x-dev
- dev-2.3.6-p1
- dev-2.4.1-p1
- dev-2.4.2-p1
- dev-2.4.2-p2
- dev-2.4.3-p1
- dev-2.4.3-p2
- dev-2.4.3-p3
- dev-2.3.7-p1
- dev-2.3.7-p2
This package is auto-updated.
Last update: 2024-09-21 10:43:43 UTC
README
即时购买功能允许客户在几秒钟内下单,无需完成完整结账。一旦点击,系统就会使用默认的送货和账单地址以及存储的支付方式下单。订单完成后,客户会在通知区域收到确认消息。
显示即时购买按钮的先决条件
- 在
商店 / 配置 / 销售 / 销售 / 即时购买
为商店启用即时购买 - 客户已登录
- 客户已定义默认的送货和账单地址
- 客户有支持即时购买的有效的存储支付方式
结构
除了 典型的 Magento 2 模块文件结构 之外,PaymentMethodsIntegration
目录包含与即时购买集成的接口和基本实现。
可扩展性
即时购买定制
几乎可以定制即时购买的各个方面。请参阅带有 @api
标记的类和接口的注释。
为即时购买创建的所有支付都包含 'instant-purchase' => true
以及其他信息。仅在所有其他定制点都不合适时使用此选项。
支付方式集成
可以为任何具有 保险库支持 的支付方式实现即时购买支持。在大多数情况下,提供的 Magento\InstantPurchase\PaymentMethodIntegration
的基本实现应该足够。默认情况下,它没有启用,以避免生产站点上的问题,并且保险库支付方式的作者应手动验证即时购买的正确性。要启用基本实现,只需向 config.xml
中的支付方式配置添加单个选项即可。
<instant_purchase> <supported>1</supported> </instant_purchase>
基本实现是一个好的起点,但建议提供自己的实现以改进用户体验。如果即时购买集成有定制,则不需要 supported
选项。
<instant_purchase> <available>Implementation_Of_Magento\InstantPurchase\PaymentMethodIntegration\AvailabilityCheckerInterface</available> <tokenFormat>Implementation_Of_Magento\InstantPurchase\PaymentMethodIntegration\PaymentTokenFormatterInterface</tokenFormat> <additionalInformation>Implementation_Of_Magento\InstantPurchase\PaymentMethodIntegration\PaymentAdditionalInformationProviderInterface</additionalInformation> </instant_purchase>
Magento\InstantPurchase\PaymentMethodIntegration\AvailabilityCheckerInterface
- 允许程序定义是否支持即时购买(例如,如果某些支付方式选项被打开/关闭,则可能不支持)。基本实现始终返回true
。Magento\InstantPurchase\PaymentMethodIntegration\PaymentTokenFormatterInterface
- 创建描述存储的支付方式的字符串。基本实现返回支付方式名称。强烈建议实现自己的格式化程序。Magento\InstantPurchase\PaymentMethodIntegration\PaymentAdditionalInformationProviderInterface
- 允许向支付附加信息数组添加一些额外值。默认实现返回空数组。
附加信息
向后不兼容的更改
《Magento_InstantPurchase》模块没有引入向后不兼容的更改。
您可以在补丁版本中跟踪 向后不兼容的更改。
此模块最初由 Creatuity Corp. 和 Magento 社区工程团队 开发。