diff --git a/routes/web.php b/routes/web.php index 53c34711..da9575b8 100644 --- a/routes/web.php +++ b/routes/web.php @@ -1253,3 +1253,46 @@ Route::get('fix-payment-status-updated-but-failed-update-invoice', function (Upd Route::get('/payment-and-billing-2', function () { return view('pages.paymentAndBilling2'); })->name('admin.payment-and-billing-2'); + +Route::get('/show-all-extra-payments', function () { + ini_set('memory_limit', '-1'); + + $invoices = Transaction::where('type', TransactionType::SHIPPING_INVOICE) + ->where('status', ApprovalStatus::COMPLETED) + ->whereHas('transactions', function ($query) { + $query->where('type', TransactionType::PAYMENT) + ->whereIn('status', [ApprovalStatus::APPROVED, ApprovalStatus::COMPLETED]); + }) + ->get(); + + echo '
| Transaction Type | +Total | +Paid | +Customer | +Order | +
|---|---|---|---|---|
| ' . $invoice->type . ' | '; + echo '' . $invoice->amount . ' | '; + echo '' . $paidAmount . ' | '; + echo ''.$marking.' | '; + echo '' . $order->reference . ' - ' . $order->created_at . ' | ';
+ echo '