search; $pageLimit = $request->input('pageLimit', config('database.pagination.limit')); $page = Website::pushScope(new RequestScope()) ->pushScope(new WebsitePublicScope()) ->paginate($pageLimit) ->withQueryString(); $websites = new WebsitesCollection($page); $categories = []; $tags = []; $recent = []; return $this->response->setMetaTitle(trans('customer::website.names')) ->view('customer::public.website.index') ->data(compact('websites', 'categories', 'tags', 'recent')) ->output(); } /** * Show website. * * @param string $slug * * @return response */ protected function show(PublicRequest $request, $slug) { $model = Website::findBySlug($slug); $data = new WebsiteResource($model); $categories = []; $tags = []; $recent = []; return $this->response->setMetaTitle($data['title'] . trans('customer::website.name')) ->view('customer::public.website.show') ->data(compact('data', 'categories', 'tags', 'recent')) ->output(); } }