$cat = Category::with('translations.team')->where('slug', '=', $slug)->firstOrFail();
$translation = $cat->translations;
$translations = CollectionHelper::paginate($translation, $translation->count(), 15);
return view('translation.index', compact('cat'))->with([
'category' => $cat,
'translations' => $translations,
]);
$category = Category::whereSlug($slug)
->firstOrFail();
$translations = $category->translations()
->with('team')
->paginate(15);
return view('translation.index', compact('category', 'translations'));