fix: remove all /main prefix from perm_config.py paths

This commit is contained in:
yumoqing 2026-05-05 13:46:29 +08:00
parent 1ed4ce0935
commit 6255feaf5b
2 changed files with 10 additions and 12 deletions

View File

@ -55,8 +55,7 @@ ROLES = {
# /api/*_list.dspy, *.ui -> 读操作
# /api/*_list.dspy, *.ui -> read operations
#
# The init script expands '**' to concrete file paths, then registers
# both canonical (/module/path.ui) and /main-prefixed (/main/module/path.ui) variants.
# 初始化脚本通过遍历 wwwroot 文件系统展开具体路径,然后注册到 permission 表。
PERMISSION_MATRIX = {
# ========================================================
@ -67,8 +66,8 @@ PERMISSION_MATRIX = {
},
"rbac_public": {
"/main/login.ui": ["any"],
"/main/login.dspy": ["any"],
"/login.ui": ["any"],
"/login.dspy": ["any"],
},
# ========================================================
@ -392,8 +391,8 @@ PERMISSION_MATRIX = {
# Main app pages (login redirect, base layout)
# ========================================================
"main_app": {
"/main/base.ui": ["logined"], # All logged-in users
"/main/index.ui": ["logined"],
"/base.ui": ["logined"], # All logged-in users
"/index.ui": ["logined"],
},
}

View File

@ -55,8 +55,7 @@ ROLES = {
# /api/*_list.dspy, *.ui -> 读操作
# /api/*_list.dspy, *.ui -> read operations
#
# The init script expands '**' to concrete file paths, then registers
# both canonical (/module/path.ui) and /main-prefixed (/main/module/path.ui) variants.
# 初始化脚本通过遍历 wwwroot 文件系统展开具体路径,然后注册到 permission 表。
PERMISSION_MATRIX = {
# ========================================================
@ -67,8 +66,8 @@ PERMISSION_MATRIX = {
},
"rbac_public": {
"/main/login.ui": ["any"],
"/main/login.dspy": ["any"],
"/login.ui": ["any"],
"/login.dspy": ["any"],
},
# ========================================================
@ -392,8 +391,8 @@ PERMISSION_MATRIX = {
# Main app pages (login redirect, base layout)
# ========================================================
"main_app": {
"/main/base.ui": ["logined"], # All logged-in users
"/main/index.ui": ["logined"],
"/base.ui": ["logined"], # All logged-in users
"/index.ui": ["logined"],
},
}