ldc-gen-game-web/app/Http/Controllers/FAQController.php
Jérémy Munsch 1af96897f3
- Squash migration
- Normalize Model names and sql tables
- PHPCS clean up
- Change analytics form + field
2022-01-11 12:46:10 +01:00

19 lines
447 B
PHP

<?php
namespace App\Http\Controllers;
use App\Models\FaqQuestion;
use App\Models\FaqTheme;
class FAQController extends Controller
{
public function index()
{
$questions = FaqQuestion::all();
$themes = FaqTheme::all();
if (count($questions) === 0 && count($themes) === 0) {
return redirect()->route('home');
}
return view('front.basic.faq', compact('questions', 'themes'));
}
}