/**
  * Display a listing of the resource.
  *
  * @return Response
  */
 public function index(Request $request)
 {
     //
     $data = ['s_title' => $request->input('s_title'), 's_slug' => $request->input('s_slug')];
     $fragments = $this->content->index($data, 'fragment', Cache::get('page_size', '10'));
     return view('back.fragment.index', compact('fragments'));
 }
 /**
  * Display a listing of the resource.
  *
  * @return Response
  */
 public function index(Request $request)
 {
     $data = ['s_title' => $request->input('s_title')];
     //使用仓库方法获取文章列表
     $articles = $this->content->index($data, 'article', Cache::get('page_size', '10'));
     //注意:因为已经使用 Bootstrap 后台模版,故无须再传入自定义的分页样式
     //传入自定义的分页Presenter
     //$links = page_links($articles, $data);
     return view('back.article.index', compact('articles'));
 }
Beispiel #3
0
 /**
  * Display a listing of the resource.
  *
  * @return Response
  */
 public function index(Request $request)
 {
     $data = ['s_title' => $request->input('s_title')];
     $pages = $this->content->index($data, 'page', Cache::get('page_size', '10'));
     return view('back.page.index', compact('pages'));
 }