20 lines
416 B
PHP
20 lines
416 B
PHP
<?php
|
|
use ProVM\KI\Common\Controller\Web\Admin\Home;
|
|
|
|
$app->group('/admin', function($app) {
|
|
$folder = implode(DIRECTORY_SEPARATOR, [
|
|
__DIR__,
|
|
'admin'
|
|
]);
|
|
if (file_exists($folder)) {
|
|
$files = new DirectoryIterator($folder);
|
|
foreach ($files as $file) {
|
|
if ($file->isDir()) {
|
|
continue;
|
|
}
|
|
include_once $file->getRealPath();
|
|
}
|
|
}
|
|
$app->get('[/]', Home::class);
|
|
});
|