Feat: Creating PaymentMethods, Setting Fees, Availabilities
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
<?php
|
||||
|
||||
use Modules\Core\Payment\Drivers\CashOnDeliveryPaymentDriver;
|
||||
use Modules\Core\Payment\Pipelines\Cart\ApplyCashOnDeliveryFee;
|
||||
|
||||
return [
|
||||
@@ -12,10 +13,18 @@ return [
|
||||
| boboko-core gets cash-on-delivery out of the box, without publishing
|
||||
| Lunar's own config.
|
||||
|
|
||||
| 'payment_driver' is boboko-owned, alongside Lunar's own 'driver' key —
|
||||
| it's the Modules\Core\Checkout\Contracts\PaymentDriver class
|
||||
| CheckoutService::confirmPayment() resolves via the container and calls
|
||||
| confirm() on. Kept on the same row as 'driver' rather than a second,
|
||||
| separately-keyed map, so a type's full definition — Lunar's driver,
|
||||
| its config, and its PaymentDriver — lives in one place.
|
||||
|
|
||||
*/
|
||||
'types' => [
|
||||
'cash-on-delivery' => [
|
||||
'driver' => 'offline',
|
||||
'payment_driver' => CashOnDeliveryPaymentDriver::class,
|
||||
'authorized' => 'awaiting-payment',
|
||||
'fee' => 0,
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user