示例#1
0
 public function index(Request $request)
 {
     $tag = $request->get('tag');
     $data = $this->dispatch(new BlogIndexData($tag));
     $layout = $tag ? Tag::layout($tag) : 'blog.layouts.index';
     return view($layout, $data);
 }
示例#2
0
 public function index(Request $request)
 {
     $tag = $request->get('tag');
     $data = $this->dispatch(new BlogIndexData($tag));
     // Click BLOG
     $layout = $tag ? Tag::layout($tag) : 'pages.layouts.blog';
     //SCROLL BLOG - Remove Pager Styles
     //		$layout = $tag ? Tag::layout($tag) : 'sandbox.scroll-blog';
     return view($layout, $data);
 }
示例#3
0
 public function index(request $request)
 {
     $tag = $request->get('tag');
     $data = $this->dispatch(new BlogIndexData($tag));
     $layout = $tag ? Tag::layout($tag) : 'blog.layouts.index';
     return view($layout, $data);
     //        $posts = Post::where('published_at', '<=', Carbon::now())
     //            ->orderBy('published_at', 'desc')
     //            ->paginate(config('blog.posts_per_page'));
     //        return view('blog.index', compact('posts'));
 }
示例#4
0
 public function index(Request $request)
 {
     /*		$posts = Post::where("published_at", "<=", Carbon::now())
     			->orderBy("published_at", "desc")
     			->paginate(config("blog.posts_per_page"));
     
     		return view("blog.index", compact("posts"));
      */
     $tag = $request->get("tag");
     $data = $this->dispatch(new BlogIndexData($tag));
     $layout = $tag ? Tag::layout($tag) : "blog.layouts.index";
     return view($layout, $data);
 }
示例#5
0
 public function showTag($tag, Request $request)
 {
     $data = $this->dispatch(new HomeIndexData($tag));
     $layout = $tag ? Tag::layout($tag) : 'home.layouts.index';
     return view($layout, $data);
 }