public ActionResult UserRoles(SelectUserRolesViewModel model)
        {

            ApplicationUser user = _accountService.GetUserById(model.Id);
            _accountService.ClearUserRoles(user.Id);
            model.Roles
                .Where(x => x.Selected)
                .ForEach(item => _accountService.AddUserToRole(user.Id, item.RoleName));
            return RedirectToAction("index");

            // return View(model);
        }
 public ActionResult UserRoles(string id)
 {
     ApplicationUser user = _accountService.GetUserById(id);
     var model = new SelectUserRolesViewModel(user);
     return View(model);
 }