예제 #1
0
 public function index($cat_id)
 {
     $faqs = QuestionsAnswers::where('cat_id', $cat_id)->paginate(20);
     $category_name = Category::findOrFail($cat_id);
     $category_name = $category_name->name;
     return view('faq::faqs.index', compact('faqs', 'cat_id', 'category_name'));
 }
예제 #2
0
 public function edit($id)
 {
     $categories = Category::findOrFail($id);
     return view('faq::categories.edit', compact('categories'));
 }