コード例 #1
0
ファイル: TeamController.php プロジェクト: bashmach/ggf
 public function search()
 {
     $collection = Team::with('tournamentTeams.tournament')->where('name', 'like', Input::get('term') . '%')->get();
     return $this->response->collection($collection, new TeamSearchTransformer(), 'teams');
 }
コード例 #2
0
ファイル: TeamsController.php プロジェクト: wyrover/aeroeco
 public function show($id)
 {
     //show single
     $record = Team::with($this->related)->findOrFail($id);
     return $record;
 }