From 9ab6039d9e1ff954a85b1ef9171b9faac9d518a4 Mon Sep 17 00:00:00 2001 From: Yang Luo Date: Sun, 24 Mar 2024 16:11:03 +0800 Subject: [PATCH] Rename OtherMenu to SystemMenu --- examples/casbin/policy.csv | 4 ++-- src/main/java/org/casbin/controller/TestMenuController.java | 4 ++-- src/main/resources/casbin/policy.csv | 4 ++-- .../{OtherMenu/OtherMenu.html => SystemMenu/SystemMenu.html} | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) rename src/main/resources/templates/{OtherMenu/OtherMenu.html => SystemMenu/SystemMenu.html} (88%) diff --git a/examples/casbin/policy.csv b/examples/casbin/policy.csv index 0718e0a..0c6d7c4 100644 --- a/examples/casbin/policy.csv +++ b/examples/casbin/policy.csv @@ -1,4 +1,4 @@ -p, ROLE_ROOT, OtherMenu, read, allow +p, ROLE_ROOT, SystemMenu, read, allow p, ROLE_ROOT, AdminMenu, read, allow p, ROLE_ROOT, UserMenu, read, deny p, ROLE_ADMIN, UserMenu, read, allow @@ -16,4 +16,4 @@ g2, UserSubMenu_deny, UserMenu g2, UserSubSubMenu, UserSubMenu_allow g2, AdminSubMenu_allow, AdminMenu g2, AdminSubMenu_deny, AdminMenu -g2, (NULL), OtherMenu \ No newline at end of file +g2, (NULL), SystemMenu \ No newline at end of file diff --git a/src/main/java/org/casbin/controller/TestMenuController.java b/src/main/java/org/casbin/controller/TestMenuController.java index 1b82a3a..e76bd84 100644 --- a/src/main/java/org/casbin/controller/TestMenuController.java +++ b/src/main/java/org/casbin/controller/TestMenuController.java @@ -53,9 +53,9 @@ public String AdminSubMenu_deny(){ return "AdminMenu/AdminSubMenu_deny"; } - @GetMapping(value = "menu/OtherMenu") + @GetMapping(value = "menu/SystemMenu") public String SystemMenu(){ - return "OtherMenu/OtherMenu"; + return "SystemMenu/SystemMenu"; } } diff --git a/src/main/resources/casbin/policy.csv b/src/main/resources/casbin/policy.csv index 0718e0a..0c6d7c4 100644 --- a/src/main/resources/casbin/policy.csv +++ b/src/main/resources/casbin/policy.csv @@ -1,4 +1,4 @@ -p, ROLE_ROOT, OtherMenu, read, allow +p, ROLE_ROOT, SystemMenu, read, allow p, ROLE_ROOT, AdminMenu, read, allow p, ROLE_ROOT, UserMenu, read, deny p, ROLE_ADMIN, UserMenu, read, allow @@ -16,4 +16,4 @@ g2, UserSubMenu_deny, UserMenu g2, UserSubSubMenu, UserSubMenu_allow g2, AdminSubMenu_allow, AdminMenu g2, AdminSubMenu_deny, AdminMenu -g2, (NULL), OtherMenu \ No newline at end of file +g2, (NULL), SystemMenu \ No newline at end of file diff --git a/src/main/resources/templates/OtherMenu/OtherMenu.html b/src/main/resources/templates/SystemMenu/SystemMenu.html similarity index 88% rename from src/main/resources/templates/OtherMenu/OtherMenu.html rename to src/main/resources/templates/SystemMenu/SystemMenu.html index 2e1e270..ecfed9a 100644 --- a/src/main/resources/templates/OtherMenu/OtherMenu.html +++ b/src/main/resources/templates/SystemMenu/SystemMenu.html @@ -2,7 +2,7 @@ - OtherMenu + SystemMenu