/** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function index() { $pupils = Pupil::with('school')->orderBy('surname')->orderBy('firstname')->orderBy('schoolenrolment')->get(); return view('/pupil.index', ['pupils' => $pupils]); }