fixes merge issues
This commit is contained in:
@@ -68,14 +68,14 @@ namespace Umbraco.Web.Editors
|
||||
var startId = 100 + ((pageNumber -1) * pageSize);
|
||||
var numUsers = pageSize;
|
||||
var users = new List<UserDisplay>();
|
||||
var userTypes = Services.UserService.GetAllUserTypes().ToDictionary(x => x.Alias, x => x.Name);
|
||||
var userTypes = Services.UserService.GetAllUserGroups().ToDictionary(x => x.Alias, x => x.Name);
|
||||
var cultures = Services.TextService.GetSupportedCultures().ToDictionary(x => x.Name, x => x.DisplayName);
|
||||
for (int i = 0; i < numUsers; i++)
|
||||
{
|
||||
var display = new UserDisplay
|
||||
{
|
||||
Id = startId,
|
||||
UserType = "writer",
|
||||
//UserType = "writer",
|
||||
AllowedSections = new[] {"content", "media"},
|
||||
AvailableUserTypes = userTypes,
|
||||
Email = "test" + startId + "@test.com",
|
||||
|
||||
@@ -21,8 +21,9 @@ namespace Umbraco.Web.Models.ContentEditing
|
||||
[DataMember(Name = "email", IsRequired = true)]
|
||||
public string Email { get; set; }
|
||||
|
||||
[DataMember(Name = "userType")]
|
||||
public string UserType { get; set; }
|
||||
//TODO: Should be user groups!
|
||||
//[DataMember(Name = "userType")]
|
||||
//public string UserType { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets the available user types (i.e. to populate a drop down)
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace Umbraco.Web.Models.Mapping
|
||||
{
|
||||
config.CreateMap<IUser, UserDisplay>()
|
||||
.ForMember(detail => detail.Id, opt => opt.MapFrom(user => user.Id))
|
||||
.ForMember(detail => detail.UserType, opt => opt.MapFrom(user => user.UserType.Alias))
|
||||
//.ForMember(detail => detail.UserType, opt => opt.MapFrom(user => user.UserType.Alias))
|
||||
.ForMember(detail => detail.StartContentId, opt => opt.MapFrom(user => user.StartContentId))
|
||||
.ForMember(detail => detail.StartMediaId, opt => opt.MapFrom(user => user.StartMediaId))
|
||||
.ForMember(detail => detail.Culture, opt => opt.MapFrom(user => user.GetUserCulture(applicationContext.Services.TextService)))
|
||||
|
||||
Reference in New Issue
Block a user