From d28f6b45fc57fb4a6e26990d6172d0151e706f63 Mon Sep 17 00:00:00 2001 From: Jottyfan Date: Tue, 30 Jul 2024 11:22:50 +0200 Subject: [PATCH] using Kinderstunde klein for date privileges --- build.gradle | 2 +- .../java/de/jottyfan/bico/modules/CommonController.java | 6 +++--- src/main/resources/templates/next.html | 2 +- src/main/resources/templates/template.html | 6 +++--- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/build.gradle b/build.gradle index 376c824..4ebd82a 100644 --- a/build.gradle +++ b/build.gradle @@ -8,7 +8,7 @@ plugins { } group = 'de.jottyfan.bico' -version = '0.1.1' +version = '0.1.2' description = """BibleClassOrganizer""" diff --git a/src/main/java/de/jottyfan/bico/modules/CommonController.java b/src/main/java/de/jottyfan/bico/modules/CommonController.java index e95e7cd..32ac948 100644 --- a/src/main/java/de/jottyfan/bico/modules/CommonController.java +++ b/src/main/java/de/jottyfan/bico/modules/CommonController.java @@ -43,14 +43,14 @@ public abstract class CommonController { } } - @ModelAttribute("hasDiakoneRole") - public Boolean hasDiakoneRole(Principal principal) { + @ModelAttribute("hasDateRole") + public Boolean hasDateRole(Principal principal) { OAuth2AuthenticationToken token = (OAuth2AuthenticationToken) principal; if (token != null) { OAuth2User user = token.getPrincipal(); @SuppressWarnings("unchecked") List roles = (List) user.getAttributes().get("roles"); - return roles.contains("Diakone"); + return roles.contains("Kinderstunde klein"); } else { LOGGER.warn("token is null, no roles can be detected"); return false; diff --git a/src/main/resources/templates/next.html b/src/main/resources/templates/next.html index fa01dc0..5cfacf9 100644 --- a/src/main/resources/templates/next.html +++ b/src/main/resources/templates/next.html @@ -3,7 +3,7 @@
-
+
diff --git a/src/main/resources/templates/template.html b/src/main/resources/templates/template.html index 2f09064..1aa4385 100644 --- a/src/main/resources/templates/template.html +++ b/src/main/resources/templates/template.html @@ -21,7 +21,7 @@ -
content
-
+
content
+
Leider fehlen Ihnen die Berechtigungen, um diese Anwendung nutzen zu können.