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