Skip to content

Commit

Permalink
revert: back to original state
Browse files Browse the repository at this point in the history
  • Loading branch information
Chrinsieboy committed Jan 24, 2024
1 parent 68fe893 commit ca726bd
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/app/Http/Controllers/AdminController.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,21 @@ class AdminController extends Controller
{
public function index()
{
$userData = auth()->user();

if (!$userData) {
$userData = User::find(1);
auth()->login($userData);
}

// Get the Statistics
$items = Item::count();
$customers = User::count();
$reservations = Reservation::count();
$invoices = Fine::count();

return Inertia::render('admin/index', [
'userData' => $userData,
'count' => [
'items' => $items,
'customers' => $customers,
Expand Down

0 comments on commit ca726bd

Please sign in to comment.