This commit is contained in:
@@ -665,7 +665,7 @@ namespace AyaNova.Api.Controllers
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
var u = await ct.User.FirstOrDefaultAsync(z => z.Id == UserId);
|
var u = await ct.User.FirstOrDefaultAsync(z => z.Id == id);
|
||||||
if (u == null)//should never happen but ?
|
if (u == null)//should never happen but ?
|
||||||
return StatusCode(403, new ApiNotAuthorizedResponse());
|
return StatusCode(403, new ApiNotAuthorizedResponse());
|
||||||
|
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ namespace AyaNova.Models
|
|||||||
public string Wiki { get; set; }
|
public string Wiki { get; set; }
|
||||||
public string CustomFields { get; set; }
|
public string CustomFields { get; set; }
|
||||||
public List<string> Tags { get; set; }
|
public List<string> Tags { get; set; }
|
||||||
|
public bool TwoFactorEnabled { get; set; }
|
||||||
public DateTime? LastLogin { get; set; }
|
public DateTime? LastLogin { get; set; }
|
||||||
|
|
||||||
[NotMapped, JsonIgnore]
|
[NotMapped, JsonIgnore]
|
||||||
@@ -59,7 +59,7 @@ namespace AyaNova.Models
|
|||||||
public DateTime? LastLogin { get; set; }
|
public DateTime? LastLogin { get; set; }
|
||||||
public string Login { get; set; }
|
public string Login { get; set; }
|
||||||
public string Password { get; set; }
|
public string Password { get; set; }
|
||||||
public bool TwoFactorEnabled {get;set;}
|
public bool TwoFactorEnabled { get; set; }
|
||||||
[Required]
|
[Required]
|
||||||
public AuthorizationRoles Roles { get; set; }
|
public AuthorizationRoles Roles { get; set; }
|
||||||
[Required]
|
[Required]
|
||||||
@@ -98,7 +98,7 @@ namespace AyaNova.Models
|
|||||||
public DateTime? PasswordResetCodeExpire { get; set; }//---
|
public DateTime? PasswordResetCodeExpire { get; set; }//---
|
||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
public string TotpSecret { get; set; }//---
|
public string TotpSecret { get; set; }//---
|
||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
public string TempToken { get; set; }//--- Used for TFA verification step 2
|
public string TempToken { get; set; }//--- Used for TFA verification step 2
|
||||||
//==========================
|
//==========================
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user