app/Http/Controllers/PetugasController.php
/**
     * Display a listing of the resource.
     *
     * @return \Illuminate\Http\Response
     */
Display a listing of the resource.
@return \Illuminate\Http\Response
Display a listing of the resource . @return \ Illuminate \ Http \ Response
public function index()
    {
        $petuga = Petugas::orderBy('created_at','DESC')->get();
        return view('petugas.index',
            [
                "petugas" => $petuga
            ]);
    }
public function index ( ) { $ petuga = Petugas :: orderBy ( 'created_at' , 'DESC' ) -> get ( ) ; return view ( 'petugas.index' , [ " petugas " => $ petuga ] ) ; }
Display a listing of the resource.
Display a listing of the resource .