Exemple #1
0
        public ActionResult GetFullUserList()
        {
            int userId = ExractIdFromToken();

            if (userId == 0)
            {
                return(BadRequest());
            }

            //var token = Request.Headers.FirstOrDefault(x => x.Key == "Authorization").Value.FirstOrDefault();
            //int userId = 0;
            //if (JwtHandler.IsTokenValid(token , out userId) == false) {
            //    return BadRequest();
            //}

            SignalRChatContext Db = new SignalRChatContext();

            List <UserCls> userListRes = UserFunctions.GetFullUserList(Db, userId);

            return(new JsonResult(userListRes));
        }