예제 #1
0
 public function openedCourses()
 {
     $today = Carbon::today();
     return Course::where('start_date', '>=', $today->toDateString())->with('professor')->with('venue')->with('subject')->get();
 }
예제 #2
0
 public function show($id)
 {
     return Response::json(Course::findOrFail($id));
 }