From e204b180a8bef7aeb55d94dea7275ccd0138b1f9 Mon Sep 17 00:00:00 2001 From: Soulter <37870767+Soulter@users.noreply.github.com> Date: Fri, 22 Aug 2025 19:31:55 +0800 Subject: [PATCH] =?UTF-8?q?Improve:=20=E6=89=A9=E5=A4=A7=E9=85=8D=E7=BD=AE?= =?UTF-8?q?=E6=96=87=E4=BB=B6=E7=94=9F=E6=95=88=E8=8C=83=E5=9B=B4=E7=9A=84?= =?UTF-8?q?=E8=87=AA=E5=AE=9A=E4=B9=89=E7=A8=8B=E5=BA=A6=E5=88=B0=E4=BC=9A?= =?UTF-8?q?=E8=AF=9D=E7=B2=92=E5=BA=A6=20(#2532)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * feat: 扩大配置文件生效范围的自定义程度 * perf: 冲突检测 * refactor: simplify config form validation and improve conflict message clarity --- astrbot/core/astrbot_config_mgr.py | 2 +- dashboard/src/views/ConfigPage.vue | 569 ++++++++++++++++++++++++++--- 2 files changed, 525 insertions(+), 46 deletions(-) diff --git a/astrbot/core/astrbot_config_mgr.py b/astrbot/core/astrbot_config_mgr.py index ef40981d..51ea8fcd 100644 --- a/astrbot/core/astrbot_config_mgr.py +++ b/astrbot/core/astrbot_config_mgr.py @@ -63,7 +63,7 @@ class AstrBotConfigManager: if len(p1_ls) != 3 or len(p2_ls) != 3: return False # 非法格式 - return all(p == "" or p == t for p, t in zip(p1_ls, p2_ls)) + return all(p == "" or p == "*" or p == t for p, t in zip(p1_ls, p2_ls)) def _load_conf_mapping(self, umo: str | MessageSession) -> ConfInfo: """获取指定 umo 的配置文件 uuid, 如果不存在则返回默认配置(返回 "default") diff --git a/dashboard/src/views/ConfigPage.vue b/dashboard/src/views/ConfigPage.vue index 314980d5..94bb8b57 100644 --- a/dashboard/src/views/ConfigPage.vue +++ b/dashboard/src/views/ConfigPage.vue @@ -7,10 +7,10 @@
-
- +
+