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