master
wanghaomei 9 months ago
parent d2834ce700
commit de0f14767c

@ -13,12 +13,12 @@ namespace Myshipping.Web.Core;
public class JwtHandler : AppAuthorizeHandler
{
//private ISysMenuService _sysMenuService;
private ISysMenuService _sysMenuService;
//public JwtHandler(ISysMenuService sysMenuService)
//{
// _sysMenuService = sysMenuService;
//}
public JwtHandler(ISysMenuService sysMenuService)
{
_sysMenuService = sysMenuService;
}
/// <summary>
@ -71,7 +71,7 @@ public class JwtHandler : AppAuthorizeHandler
if (routeName == "sysUser:updatePwd") return true;
Stopwatch sw = Stopwatch.StartNew();
var _sysMenuService = App.GetService<ISysMenuService>();
//var _sysMenuService = App.GetService<ISysMenuService>();
var allPermission = await _sysMenuService.GetAllPermission();
httpContext.Response.Headers["CheckTimeCheckAuthorzie1"] = sw.ElapsedMilliseconds.ToString();
if (!allPermission.Contains(routeName))

Loading…
Cancel
Save