Example #1
0
        public async Task <ActionResult <IEnumerable <SectionDto> > > GetRoles()
        {
            if (!this.HttpContext.Session.HasSystemActionRights() || !this.HttpContext.Session.HasSystemActionRight(ActionRights.SecurityManagement))
            {
                return(RedirectToAction("Index", "Home"));
            }

            var roleDtos = await SecurityGuiHelper.GetAllRoleDtosAsync();

            return(Ok(roleDtos));
        }