From 32b4dab4cd00a4bd77defdc612eb5b147beb2a8e Mon Sep 17 00:00:00 2001 From: Dennis Eichhorn Date: Fri, 11 Oct 2024 19:17:40 +0000 Subject: [PATCH] bug fixes --- Admin/Routes/Web/Api.php | 161 ++++++++++++++++++++++ Theme/Backend/kanban-board-create.tpl.php | 5 +- 2 files changed, 165 insertions(+), 1 deletion(-) create mode 100644 Admin/Routes/Web/Api.php diff --git a/Admin/Routes/Web/Api.php b/Admin/Routes/Web/Api.php new file mode 100644 index 0000000..dca7ebf --- /dev/null +++ b/Admin/Routes/Web/Api.php @@ -0,0 +1,161 @@ + [ + [ + 'dest' => '\Modules\Kanban\Controller\ApiController:apiKanbanBoardCreate', + 'verb' => RouteVerb::PUT, + 'csrf' => true, + 'active' => true, + 'permission' => [ + 'module' => ApiController::NAME, + 'type' => PermissionType::CREATE, + 'state' => PermissionCategory::BOARD, + ], + ], + [ + 'dest' => '\Modules\Kanban\Controller\ApiController:apiKanbanBoardUpdate', + 'verb' => RouteVerb::SET, + 'csrf' => true, + 'active' => true, + 'permission' => [ + 'module' => ApiController::NAME, + 'type' => PermissionType::MODIFY, + 'state' => PermissionCategory::BOARD, + ], + ], + [ + 'dest' => '\Modules\Kanban\Controller\ApiController:apiKanbanBoardDelete', + 'verb' => RouteVerb::DELETE, + 'csrf' => true, + 'active' => true, + 'permission' => [ + 'module' => ApiController::NAME, + 'type' => PermissionType::DELETE, + 'state' => PermissionCategory::BOARD, + ], + ], + ], + '^.*/kanban/column(\?.*|$)' => [ + [ + 'dest' => '\Modules\Kanban\Controller\ApiController:apiKanbanColumnCreate', + 'verb' => RouteVerb::PUT, + 'csrf' => true, + 'active' => true, + 'permission' => [ + 'module' => ApiController::NAME, + 'type' => PermissionType::CREATE, + 'state' => PermissionCategory::BOARD, + ], + ], + [ + 'dest' => '\Modules\Kanban\Controller\ApiController:apiKanbanColumnUpdate', + 'verb' => RouteVerb::SET, + 'csrf' => true, + 'active' => true, + 'permission' => [ + 'module' => ApiController::NAME, + 'type' => PermissionType::MODIFY, + 'state' => PermissionCategory::BOARD, + ], + ], + [ + 'dest' => '\Modules\Kanban\Controller\ApiController:apiKanbanColumnDelete', + 'verb' => RouteVerb::DELETE, + 'csrf' => true, + 'active' => true, + 'permission' => [ + 'module' => ApiController::NAME, + 'type' => PermissionType::DELETE, + 'state' => PermissionCategory::BOARD, + ], + ], + ], + '^.*/kanban/card(\?.*|$)' => [ + [ + 'dest' => '\Modules\Kanban\Controller\ApiController:apiKanbanCardCreate', + 'verb' => RouteVerb::PUT, + 'csrf' => true, + 'active' => true, + 'permission' => [ + 'module' => ApiController::NAME, + 'type' => PermissionType::CREATE, + 'state' => PermissionCategory::BOARD, + ], + ], + [ + 'dest' => '\Modules\Kanban\Controller\ApiController:apiKanbanCardUpdate', + 'verb' => RouteVerb::SET, + 'csrf' => true, + 'active' => true, + 'permission' => [ + 'module' => ApiController::NAME, + 'type' => PermissionType::MODIFY, + 'state' => PermissionCategory::BOARD, + ], + ], + [ + 'dest' => '\Modules\Kanban\Controller\ApiController:apiKanbanCardDelete', + 'verb' => RouteVerb::DELETE, + 'csrf' => true, + 'active' => true, + 'permission' => [ + 'module' => ApiController::NAME, + 'type' => PermissionType::DELETE, + 'state' => PermissionCategory::BOARD, + ], + ], + ], + '^.*/kanban/comment(\?.*|$)' => [ + [ + 'dest' => '\Modules\Kanban\Controller\ApiController:apiKanbanCommentCreate', + 'verb' => RouteVerb::PUT, + 'csrf' => true, + 'active' => true, + 'permission' => [ + 'module' => ApiController::NAME, + 'type' => PermissionType::CREATE, + 'state' => PermissionCategory::BOARD, + ], + ], + [ + 'dest' => '\Modules\Kanban\Controller\ApiController:apiKanbanCommentUpdate', + 'verb' => RouteVerb::SET, + 'csrf' => true, + 'active' => true, + 'permission' => [ + 'module' => ApiController::NAME, + 'type' => PermissionType::MODIFY, + 'state' => PermissionCategory::BOARD, + ], + ], + [ + 'dest' => '\Modules\Kanban\Controller\ApiController:apiKanbanCommentDelete', + 'verb' => RouteVerb::DELETE, + 'csrf' => true, + 'active' => true, + 'permission' => [ + 'module' => ApiController::NAME, + 'type' => PermissionType::DELETE, + 'state' => PermissionCategory::BOARD, + ], + ], + ] +]; diff --git a/Theme/Backend/kanban-board-create.tpl.php b/Theme/Backend/kanban-board-create.tpl.php index 4cd185f..0e35470 100755 --- a/Theme/Backend/kanban-board-create.tpl.php +++ b/Theme/Backend/kanban-board-create.tpl.php @@ -23,7 +23,10 @@ echo $this->data['nav']->render();
-
+ >
getHtml('Board'); ?>