This commit is contained in:
Juan Pablo Vial
2024-07-26 23:15:48 -04:00
parent 43bb7a83c8
commit 84861b5e57
24 changed files with 457 additions and 18 deletions

View File

@ -0,0 +1,10 @@
<?php
$app->group('/admin', function($app) {
$files = new FilesystemIterator(implode(DIRECTORY_SEPARATOR, [__DIR__, 'admin']));
foreach ($files as $file) {
if ($file->isDir()) {
continue;
}
include_once $file->getRealPath();
}
});

View File

@ -0,0 +1,6 @@
<?php
use Incoviba\Controller\Admin\Users;
$app->group('/users', function($app) {
$app->get('[/]', Users::class);
});

View File

@ -0,0 +1,13 @@
<?php
$app->group('/admin', function($app) {
$folder = implode(DIRECTORY_SEPARATOR, [__DIR__, 'admin']);
if (file_exists($folder)) {
$files = new FilesystemIterator($folder);
foreach ($files as $file) {
if ($file->isDir()) {
continue;
}
include_once $file->getRealPath();
}
}
});

View File

@ -0,0 +1,6 @@
<?php
use Incoviba\Controller\API\Admin\Users;
$app->group('/users', function($app) {
$app->post('/add[/]', Users::class . ':add');
});

View File

@ -0,0 +1,4 @@
<?php
use Incoviba\Controller\API\Login;
$app->post('/login[/]', Login::class);

View File

@ -4,6 +4,10 @@ use Incoviba\Controller\API\Money;
$app->group('/money', function($app) {
$app->post('/ipc[/]', [Money::class, 'ipc']);
$app->post('/uf[/]', [Money::class, 'uf']);
$app->group('/ufs', function($app) {
$app->post('[/]', [Money::class, 'updateUfs']);
$app->get('[/]', [Money::class, 'ufs']);
});
$app->post('/many[/]', [Money::class, 'getMany']);
$app->post('[/]', [Money::class, 'get']);
});