Skip to content

Instantly share code, notes, and snippets.

@MyFRA
Created October 25, 2022 17:11
Show Gist options
  • Save MyFRA/7a471d587c7fb34175a29f654a4f2300 to your computer and use it in GitHub Desktop.
Save MyFRA/7a471d587c7fb34175a29f654a4f2300 to your computer and use it in GitHub Desktop.
<?php
namespace App\Http\Controllers;
use App\Models\PendaftarLayananMandiri;
use App\Models\Penduduk;
use App\Models\PermohonanSurat;
use App\Models\WilayahAdministratif;
use App\Models\WilayahAdministratifRT;
use App\Models\WilayahAdministratifRW;
use Illuminate\Http\Request;
class HomeController extends Controller
{
/**
* Show the application dashboard.
*
* @return \Illuminate\Contracts\Support\Renderable
*/
public function index()
{
$data = [
'jmlWilayahAdministratif' => WilayahAdministratif::count(),
'jmlRW' => WilayahAdministratifRW::count(),
'jmlRT' => WilayahAdministratifRT::count(),
'jmlPenduduk' => Penduduk::count(),
'totalPermohonanSurat' => PermohonanSurat::count(),
'jmlPendaftarLayananMandiri' => PendaftarLayananMandiri::count(),
];
return view('home', $data);
}
}
@MyFRA
Copy link
Author

MyFRA commented Oct 25, 2022

path : app/Http/Controllers/HomeController.php

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment