public async Task <IActionResult> Edituser(EditUserViewModel euser)
        {
            var user = await _userManager.FindByIdAsync(euser.Id);

            user = euser.MakeApplicationUser(user);

            var roles = await _userManager.GetRolesAsync(user);

            var role = roles.FirstOrDefault();

            if (!role.Equals(euser.Role))
            {
                await _userManager.RemoveFromRoleAsync(user, role);

                await _userManager.AddToRoleAsync(user, euser.Role);
            }

            if (!string.IsNullOrEmpty(euser.NewPassword))
            {
                await _userManager.RemovePasswordAsync(user);

                await _userManager.AddPasswordAsync(user, euser.NewPassword);
            }



            await _userManager.UpdateAsync(user);

            await _userManager.UpdateSecurityStampAsync(user);



            return(RedirectToAction("Users"));
        }