<?php

namespace App\Controllers\Admin;

use App\Models\Control\TransactionModel;

/**
 * Read-only ledger of platform-level payments (subscription charges FROM
 * hotels) — every row here comes from either
 * Admin\InvoiceController::markPaid() (manual settlement) or the
 * platform Hubtel webhook (PaymentWebhookController::platformHubtelCheckout()).
 * Nothing is ever written from this controller.
 */
class TransactionController extends BaseAdminController
{
    public function index()
    {
        return view('admin/transactions/index', [
            'pageTitle'    => 'Transactions',
            'activeNav'    => 'transactions',
            'transactions' => (new TransactionModel())->allWithTenant(),
        ]);
    }
}
