This commit is contained in:
陈淳
2022-11-06 21:38:55 +08:00
parent dc58f9397f
commit 86e869ff16
4 changed files with 46 additions and 3 deletions

View File

@@ -2,6 +2,7 @@
using SqlSugar;
using System;
using System.Linq;
using Yi.Framework.Common.Const;
using Yi.Framework.Common.Enum;
using Yi.Framework.Common.Models;
using Yi.Framework.DTOModel;
@@ -28,7 +29,7 @@ namespace Yi.Framework.Core
}
//超级管理员直接放行
if (ServiceLocator.Admin.Equals(userName))
if (SystemConst.Admin.Equals(userName))
{
return;
}

View File

@@ -9,8 +9,7 @@ namespace Yi.Framework.WebCore
{
public static IServiceProvider? Instance { get; set; }
public static string Admin { get; set; } = "cc";
//需要兼容不存在http请求的情况
public static bool GetHttp(out HttpContext? httpContext)
{
httpContext = null;