mirror of
https://github.com/sbrl/Nibriboard.git
synced 2018-01-10 21:33:49 +00:00
Attempt to fix deserialisation issue, but there's still some kind of problem
This commit is contained in:
parent
10192e88a4
commit
aacb6f26f9
1 changed files with 5 additions and 1 deletions
|
@ -28,21 +28,25 @@ namespace Nibriboard.Userspace
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Represents a single Nibriboard user.
|
/// Represents a single Nibriboard user.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[JsonObject(MemberSerialization.OptOut)]
|
[JsonObject(MemberSerialization.OptIn)]
|
||||||
public class User
|
public class User
|
||||||
{
|
{
|
||||||
private static ISimpleHash passwordHasher = new SimpleHash();
|
private static ISimpleHash passwordHasher = new SimpleHash();
|
||||||
|
|
||||||
private UserManager userManager;
|
private UserManager userManager;
|
||||||
|
|
||||||
|
[JsonProperty]
|
||||||
public DateTime CreationTime { get; set; }
|
public DateTime CreationTime { get; set; }
|
||||||
|
[JsonProperty]
|
||||||
public string Username { get; set; }
|
public string Username { get; set; }
|
||||||
|
[JsonProperty]
|
||||||
public string HashedPassword { get; set; }
|
public string HashedPassword { get; set; }
|
||||||
|
|
||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
public List<RbacRole> Roles { get; set; } = new List<RbacRole>();
|
public List<RbacRole> Roles { get; set; } = new List<RbacRole>();
|
||||||
|
|
||||||
private List<string> rolesText = null;
|
private List<string> rolesText = null;
|
||||||
|
[JsonProperty("RolesText")]
|
||||||
public List<string> RolesText {
|
public List<string> RolesText {
|
||||||
get {
|
get {
|
||||||
return new List<string>(Roles.Select((RbacRole role) => role.Name));
|
return new List<string>(Roles.Select((RbacRole role) => role.Name));
|
||||||
|
|
Loading…
Reference in a new issue