diff --git a/brain/controller/DashControl.inc.php b/brain/controller/DashControl.inc.php index db89ec5..0315dba 100644 --- a/brain/controller/DashControl.inc.php +++ b/brain/controller/DashControl.inc.php @@ -1,18 +1,36 @@ getContents(); + $book = new Book("content/pages"); + $pageOptions = [ + "title" => "Fipamo Dashboard", + "status" => $auth->sessionStatus(), + "pages" => $book->getContents(), + ]; break; } + + return $view->render($response, "dash/start.twig", $pageOptions); } } diff --git a/brain/controller/IndexControl.inc.php b/brain/controller/IndexControl.inc.php index 1bd56c2..039f72a 100644 --- a/brain/controller/IndexControl.inc.php +++ b/brain/controller/IndexControl.inc.php @@ -1,12 +1,23 @@ secret; - } - -} \ No newline at end of file + public static function start( + ServerRequestInterface $request, + ResponseInterface $response, + array $args + ): ResponseInterface { + $view = Twig::fromRequest($request); + + return $view->render($response, "front/start.twig", [ + "title" => "Fipamo Dash", + "status" => false, + "pages" => [], + "totalPages" => 0, + ]); + } +} diff --git a/brain/controller/RouteControl.inc.php b/brain/controller/RouteControl.inc.php new file mode 100644 index 0000000..93550b8 --- /dev/null +++ b/brain/controller/RouteControl.inc.php @@ -0,0 +1,31 @@ + + +
+ +