/** * Display the edit page by the given category * * @param Category $category * @return \Illuminate\Contracts\View\Factory|\Illuminate\View\View */ public function editCategory(Category $category) { $categories = Category::superCategories()->get(); return view('manage.category.edit', compact('category', 'categories')); }