public IActionResult UpdateRole([FromBody] UpdateUserProfileRoleDto data)
        {
            var result = this.UnitOfWork.UserProfileRepository.UpdateRole(data);

            this.UnitOfWork.Commit();
            return(this.JsonResponse(result));
        }
Ejemplo n.º 2
0
        public UserProfileRoleEntity UpdateRole(UpdateUserProfileRoleDto data)
        {
            var entity = this.Get(data.UserProfileId);
            var role   = this.DbContext.UserProfileRoles.Single(x => x.Id == data.UserProfileRoleId);

            entity.Role = role;
            return(role);
        }