model = $newsletter; parent::__construct(); } /** * Show newsletter's list. * * @param string $slug * * @return response */ protected function index() { $newsletters = $this->model->all(); return $this->theme->of('d_m_newsletter::public.newsletter.index', compact('newsletters'))->render(); } /** * Show newsletter. * * @param string $slug * * @return response */ protected function show($slug) { $newsletter = $this->model->findBySlug($slug); return $this->theme->of('d_m_newsletter::public.newsletter.show', compact('newsletter'))->render(); } }