예제 #1
0
        public ActionResult getInstitutions()
        {
            string          authHeader = this.HttpContext.Request.Headers["Authorization"];
            TokenModel      tokenModel = new TokenModel();
            ClaimsPrincipal auth       = tokenModel.GetPrincipal(authHeader);

            if (auth.Identity.IsAuthenticated)
            {
                new ClickTracker("getInstitutions", true, false, "", auth.Identity.Name);
                Institution institution = new Institution();
                return(Ok(institution.GetInstitutions()));
            }
            return(Ok(""));
        }