repository = $fbuids; parent::__construct(); } /** * Show fbuids's list. * * @param string $slug * * @return response */ protected function index() { $fbuids = $this->repository->scopeQuery(function($query){ return $query->orderBy('id','DESC'); })->paginate(); return $this->theme->of('fbuid::public.fbuids.index', compact('fbuids'))->render(); } /** * Show fbuids. * * @param string $slug * * @return response */ protected function show($slug) { $fbuids = $this->repository->scopeQuery(function($query) use ($slug) { return $query->orderBy('id','DESC') ->where('slug', $slug); })->first(['*']); return $this->theme->of('fbuid::public.fbuids.show', compact('fbuids'))->render(); } }