Feature: Moving Payment Methods to DB, adding fees, Transaction Updates, Refund Updates, General Updates to Payments
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Core\Order\Filament\Extensions;
|
||||
|
||||
use Filament\Infolists\Components\RepeatableEntry;
|
||||
use Lunar\Admin\Support\Extending\ViewPageExtension;
|
||||
use Modules\Core\Order\Filament\Infolists\TransactionEntry;
|
||||
|
||||
/**
|
||||
* Swaps Lunar\Admin\Support\Infolists\Components\Transaction for our own
|
||||
* TransactionEntry in the order page's transactions list — same component,
|
||||
* different Blade view, so a Transaction.meta['notes'] value (written by
|
||||
* a manual/attested driver like Payment\Drivers\BankTransferPaymentDriver)
|
||||
* actually renders somewhere, instead of only the notes column Lunar's own
|
||||
* view reads (see TransactionEntry's own docblock for why that column is
|
||||
* usually empty for a successful manual payment/refund).
|
||||
*
|
||||
* Uses the extendTransactionsRepeatableEntry hook ManageOrder's own
|
||||
* DisplaysTransactions trait already calls
|
||||
* (getTransactionsRepeatableEntry() → callStaticLunarHook(
|
||||
* 'extendTransactionsRepeatableEntry', ...)) — a class/component swap via
|
||||
* a Lunar-provided hook, the same category of extension already used
|
||||
* throughout CorePlugin, not a Blade view-path override.
|
||||
*/
|
||||
class OrderTransactionsExtension extends ViewPageExtension
|
||||
{
|
||||
public function extendTransactionsRepeatableEntry(RepeatableEntry $entry): RepeatableEntry
|
||||
{
|
||||
return $entry->schema([
|
||||
TransactionEntry::make('transaction_detail'),
|
||||
]);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user