/// <summary> /// Adds the User specified by userID to the Role Specified by name /// <para>Returns ApplicationRoleDTOModel</para> /// </summary> /// <param name="userID">string</param> /// <param name="roleName">string</param> /// <returns>ApplicationRoleDTOModel</returns> public ApplicationRoleDTOModel AddToRole(string userID, string roleName) { try { return(new ApplicationRoleDTOModel { Item = _repository.AddToRole(userID, roleName), }); } catch (Exception e) { return(new ApplicationRoleDTOModel { ErrorMessage = e.Message, }); } }