Exemplo n.º 1
0
 public override void OnActionExecuting(ActionExecutingContext actionContext)
 {
     //var dd =await _blogArticleServices.Query();
     if (actionContext.Filters.Any(item => item is MustLogin))
     {
         string ClaimType          = "jti";
         var    getUserInfoByToken = _user.GetUserInfoFromToken(ClaimType);
         if (!_user.IsAuthenticated())
         {
             actionContext.Result = MyResponse.MustLogin <string>().GetResult();
             base.OnActionExecuting(actionContext);
             return;
         }
     }
     base.OnActionExecuting(actionContext);
 }