-
Notifications
You must be signed in to change notification settings - Fork 0
/
routing.php
23 lines (20 loc) · 1.01 KB
/
routing.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
<?php
use core\App;
use core\Utils;
App::getRouter()->setDefaultRoute('indexShow');
// App::getRouter()->setLoginRoute('login'); // akcja/ścieżka na potrzeby logowania (przekierowanie, gdy nie ma dostępu)
Utils::addRoute('indexShow', 'IndexCtrl');
Utils::addRoute('delete', 'IndexCtrl', ["Admin", "User"]);
Utils::addRoute('ready', 'IndexCtrl', ["Admin", "User"]);
Utils::addRoute('registerShow', 'RegisterCtrl');
Utils::addRoute('register', 'RegisterCtrl');
Utils::addRoute('loginShow', 'LoginCtrl');
Utils::addRoute('login', 'LoginCtrl');
Utils::addRoute('logout', 'LoginCtrl');
Utils::addRoute('addTaskShow', 'AddTaskCtrl', ["Admin", "User"]);
Utils::addRoute('addTask', 'AddTaskCtrl', ["Admin", "User"]);
Utils::addRoute('admin', 'AdminCtrl', ["Admin"]);
Utils::addRoute('adminDelete', 'AdminEditCtrl');
Utils::addRoute('adminEdit', 'AdminEditCtrl');
Utils::addRoute('edit', 'AdminEditCtrl');
//Utils::addRoute('downolandUs', 'AdminEditCtrl');