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