public UserModel GetEditModel(long id)
{
var user = this.Manager.Load(id);
var model = new UserModel
{
UserId = user.Id,
Name = user.Name,
Email = user.Email,
Login = user.UserPasswordCredential != null ? user.UserPasswordCredential.Login : string.Empty,
PartnerId = user.Partner != null ? user.Partner.Id : (long?)null,
RoleId = user.Role.Id
};
this.FillUserModel(model);
return model;
}