Example #1
0
 public function show($teamID, $year)
 {
     $team = Team::leftJoin('league', 'lgID', '=', 'league.id')->leftJoin('division', 'divID', '=', 'division.id')->where('teamID', '=', $teamID)->where('yearID', '=', $year)->first();
     \Debugbar::info($team);
     $battingGrids = BattingController::team($teamID, $year);
     $pitchingGrids = PitchingController::team($teamID, $year);
     $fieldingGrids = FieldingController::team($teamID, $year);
     return view('teams.show')->with(['team' => $team, 'year' => $year, 'battingGrids' => $battingGrids, 'pitchingGrids' => $pitchingGrids, 'fieldingGrids' => $fieldingGrids]);
 }