oms-Exchange/Admin/Routes/Web/Api.php
Dennis Eichhorn b6903b53b6
Some checks failed
Image optimization / general_image_workflow (push) Has been cancelled
CI / general_module_workflow_php (push) Has been cancelled
CI / general_module_workflow_js (push) Has been cancelled
fix permissions
2025-04-02 14:15:05 +00:00

48 lines
1.3 KiB
PHP

<?php
/**
* Jingga
*
* PHP Version 8.2
*
* @package Modules
* @copyright Dennis Eichhorn
* @license OMS License 2.2
* @version 1.0.0
* @link https://jingga.app
*/
declare(strict_types=1);
use Modules\Exchange\Controller\ApiController;
use Modules\Exchange\Models\PermissionCategory;
use phpOMS\Account\PermissionType;
use phpOMS\Router\RouteVerb;
return [
'^.*/admin/exchange/import/view(\?.*$|$)' => [
[
'dest' => '\Modules\Exchange\Controller\ApiController:apiExchangeImport',
'verb' => RouteVerb::SET,
'csrf' => true,
'active' => true,
'permission' => [
'module' => ApiController::NAME,
'type' => PermissionType::CREATE,
'state' => PermissionCategory::IMPORT,
],
],
],
'^.*/admin/exchange/export/view(\?.*$|$)' => [
[
'dest' => '\Modules\Exchange\Controller\ApiController:apiExchangeExport',
'verb' => RouteVerb::SET,
'csrf' => true,
'active' => true,
'permission' => [
'module' => ApiController::NAME,
'type' => PermissionType::CREATE,
'state' => PermissionCategory::EXPORT,
],
],
],
];