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