diff --git a/app/Http/Resources/WalletTransactionResource.php b/app/Http/Resources/WalletTransactionResource.php index 2550a061..141da749 100644 --- a/app/Http/Resources/WalletTransactionResource.php +++ b/app/Http/Resources/WalletTransactionResource.php @@ -33,12 +33,14 @@ class WalletTransactionResource extends JsonResource case TransactionType::PAYMENT: $invoice = Transaction::where('payment_reference', $this->bill_no)->first(); if(!$invoice) { + Log::channel('paymentUnknownOrderLog')->info('ID: ' . $this->id); $description = 'Payment for unknown invoice, please contact tech support.'; break; } $order = $invoice->owner->owner->owner; if(!$order) { + Log::channel('paymentUnknownOrderLog')->info('ID: ' . $this->id); $description = 'Payment for unknown order, please contact tech support.'; break; } diff --git a/config/logging.php b/config/logging.php index 1aa06aa3..5868ffb5 100644 --- a/config/logging.php +++ b/config/logging.php @@ -100,6 +100,12 @@ return [ 'emergency' => [ 'path' => storage_path('logs/laravel.log'), ], + + 'paymentUnknownOrderLog' => [ + 'driver' => 'single', + 'path' => storage_path('logs/paymentUnknownOrderLog.log'), + 'level' => 'info', + ], ], ];