src/Controller/DocumentationController.php line 29
<?php
namespace App\Controller;
use App\Globals\Roles;
use App\Globals\Triggers;
use App\Utility\EmailUtility;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface;
use Symfony\Contracts\Translation\TranslatorInterface;
use Symfony\Component\Security\Http\Authentication\AuthenticationUtils;
use Symfony\Component\HttpFoundation\Request;
class DocumentationController extends AbstractController
{
/**
* @var \Symfony\Component\Translation\Translator
*/
protected $translator;
public function __construct(TranslatorInterface $translator) {
$this->translator = $translator;
}
/**
* @Route("/documentation/{service}", name="app_documentation_index", defaults={"service"=null})
*/
public function index(Request $request, $service) {
if(is_null($service)) {
return $this->render('documentation/index.twig');
}
else {
return $this->render('documentation/'.$service.'.twig', array(
'service' => $service
));
}
}
}