Skip to content

Commit

Permalink
OXDEV-8216: Add new right to de-/activate modules
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcelOxid committed Aug 12, 2024
1 parent d2f3018 commit 8ef4d5c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/Module/Controller/ModuleActivationController.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public function __construct(
*/
#[Mutation]
#[Logged]
#[Right('CHANGE_CONFIGURATION')]
#[Right('ACTIVATE_MODULE')]
public function activateModule(string $moduleId): bool
{
return $this->moduleActivationService->activateModule(moduleId: $moduleId);
Expand All @@ -41,7 +41,7 @@ public function activateModule(string $moduleId): bool
*/
#[Mutation]
#[Logged]
#[Right('CHANGE_CONFIGURATION')]
#[Right('ACTIVATE_MODULE')]
public function deactivateModule(string $moduleId): bool
{
return $this->moduleActivationService->deactivateModule(moduleId: $moduleId);
Expand Down
3 changes: 2 additions & 1 deletion src/Shared/Service/PermissionProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ public function getPermissions(): array
{
return [
'oxidadmin' => [
'CHANGE_CONFIGURATION'
'CHANGE_CONFIGURATION',
'ACTIVATE_MODULE'
],
];
}
Expand Down

0 comments on commit 8ef4d5c

Please sign in to comment.