/** * Show the forums index * * @param TopicRepoInterface $topic * @param PostRepoInterface $post * @param ForumRepoInterface $forum * @return \Illuminate\View\View */ public function getIndex(TopicRepoInterface $topic, PostRepoInterface $post, ForumRepoInterface $forum) { $forums = $forum->getForums(); // Get sidebar info $recentPosts = $post->getRecent(); $recentTopics = $topic->getRecent(); return \View::make('lforums/forums', compact('forums', 'recentTopics', 'recentPosts')); }
/** * Show post * * @return \Illuminate\Http\RedirectResponse */ public function getShow() { $page = $this->postRepo->getPostPage($this->post); return $this->redirectToTopic($page); }