From 27db18ae80478b8ab00e27ea89fb2ff5e54355c2 Mon Sep 17 00:00:00 2001 From: James Ward Date: Wed, 15 Apr 2026 02:00:00 -0400 Subject: [PATCH] fix(ui): enable all OIDC permissions when admin is granted (#517) * fix(ui): enable all OIDC permissions when admin is granted * fix(ui): only turn on all permissions when admin is on --- .../authentication-settings.component.html | 12 ++++++++++-- .../authentication-settings.component.ts | 9 +++++++++ 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/frontend/src/app/core/security/oauth2-management/authentication-settings.component.html b/frontend/src/app/core/security/oauth2-management/authentication-settings.component.html index 5c3ea7aa0..e00265134 100644 --- a/frontend/src/app/core/security/oauth2-management/authentication-settings.component.html +++ b/frontend/src/app/core/security/oauth2-management/authentication-settings.component.html @@ -583,7 +583,10 @@
{{ t('groupMapping.adminLabel') }}
- +
@@ -596,7 +599,12 @@ @for (perm of editingGroupMappingPerms; track perm) {
- +
} diff --git a/frontend/src/app/core/security/oauth2-management/authentication-settings.component.ts b/frontend/src/app/core/security/oauth2-management/authentication-settings.component.ts index 55cdcdaae..0ebdf49c0 100644 --- a/frontend/src/app/core/security/oauth2-management/authentication-settings.component.ts +++ b/frontend/src/app/core/security/oauth2-management/authentication-settings.component.ts @@ -437,6 +437,15 @@ export class AuthenticationSettingsComponent { }); } + onAdminCheckboxChange(): void { + if (this.editingGroupMapping.isAdmin) { + this.editingGroupMappingPerms = this.availablePermissions.map(p => ({ + ...p, + selected: true, + })); + } + } + private emptyGroupMapping(): OidcGroupMapping { return {oidcGroupClaim: '', isAdmin: false, permissions: [], libraryIds: [], description: ''}; }