From bdf79eb61a578e2c419069af1dd2f4cd4f8b2719 Mon Sep 17 00:00:00 2001 From: Argo Zhang Date: Wed, 19 Jun 2019 18:04:48 +0800 Subject: [PATCH] =?UTF-8?q?fix(#IY4NN):=20=E6=BC=94=E7=A4=BA=E6=A8=A1?= =?UTF-8?q?=E5=BC=8F=E4=B8=8B=E4=B8=8D=E5=85=81=E8=AE=B8=E6=96=B0=E5=BB=BA?= =?UTF-8?q?=E4=B8=8E=E4=BF=9D=E5=AD=98=E8=8F=9C=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit #Comment comment #IY4NN #Issue close https://gitee.com/LongbowEnterprise/dashboard/issues?id=IY4NN --- Bootstrap.DataAccess/Helper/MenuHelper.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Bootstrap.DataAccess/Helper/MenuHelper.cs b/Bootstrap.DataAccess/Helper/MenuHelper.cs index 58af4640..0bcd0ce1 100644 --- a/Bootstrap.DataAccess/Helper/MenuHelper.cs +++ b/Bootstrap.DataAccess/Helper/MenuHelper.cs @@ -31,7 +31,8 @@ namespace Bootstrap.DataAccess /// public static bool Save(BootstrapMenu p) { - if (DictHelper.RetrieveSystemModel() && !string.IsNullOrEmpty(p.Id) && RetrieveAllMenus("Admin").Where(m => m.Category == "0" || m.Application == "2").Any(m => m.Id == p.Id)) return true; + // 不允许保存系统菜单与前台演示系统的默认菜单 + if (DictHelper.RetrieveSystemModel() && (p.Category == "0" || p.Application == "2")) return true; if (p.Id == string.Empty) p.Id = null; var ret = DbContextManager.Create().Save(p);