Ejemplo n.º 1
0
 /**
  * Display a listing of the resource.
  *
  * @return Response
  */
 public function index()
 {
     // $lists = Todolist::all();
     $lists = Todolist::orderBy('created_at', 'desc')->with('comments')->paginate(10);
     return view('lists.index')->with(compact('lists'));
 }
Ejemplo n.º 2
0
 /**
  * Display a listing of the resource.
  *
  * @return \Illuminate\Http\Response
  */
 public function index()
 {
     $lists = Todolist::orderBy('name', 'DESC')->paginate(10);
     return view('lists.index', compact('lists'));
 }
 /**
  * Display a listing of the resource.
  *
  * @return Response
  */
 public function index()
 {
     $lists = Todolist::orderBy('name')->paginate(10);
     return view('lists.index')->with('lists', $lists);
 }