repository = $131414; parent::__construct(); } /** * Show 131414's list. * * @param string $slug * * @return response */ protected function index() { $131414s = $this->repository ->pushCriteria(app('Litepie\Repository\Criteria\RequestCriteria')) ->scopeQuery(function($query){ return $query->orderBy('id','DESC'); })->paginate(); return $this->response->title(trans('$tm::$131414.names')) ->view('$tm::public.131414.index') ->data(compact('$131414s')) ->output(); } /** * Show 131414's list based on a type. * * @param string $slug * * @return response */ protected function list($type = null) { $131414s = $this->repository ->pushCriteria(app('Litepie\Repository\Criteria\RequestCriteria')) ->scopeQuery(function($query){ return $query->orderBy('id','DESC'); })->paginate(); return $this->response->title(trans('$tm::$131414.names')) ->view('$tm::public.131414.index') ->data(compact('$131414s')) ->output(); } /** * Show 131414. * * @param string $slug * * @return response */ protected function show($slug) { $131414 = $this->repository->scopeQuery(function($query) use ($slug) { return $query->orderBy('id','DESC') ->where('slug', $slug); })->first(['*']); return $this->response->title($$131414->name . trans('$tm::$131414.name')) ->view('$tm::public.131414.show') ->data(compact('$131414')) ->output(); } }