NOTE: temp commit, started rolling back changes to auth system
Signed-off-by: limited_dev <loginakkisativ@gmail.com>
This commit is contained in:
parent
e2ce6cbf37
commit
ce201207d4
13 changed files with 97 additions and 63 deletions
|
@ -9,11 +9,11 @@
|
|||
<div class="login">
|
||||
<form>
|
||||
<RadzenFormField Text="New Password" Variant="Variant.Outlined">
|
||||
<RadzenPassword @bind-Value="@Password" />
|
||||
<RadzenPassword @bind-Value="@Password"/>
|
||||
</RadzenFormField>
|
||||
<br/>
|
||||
<br/>
|
||||
<RadzenButton Click=@reset Text="reset" ButtonStyle="ButtonStyle.Secondary" />
|
||||
<RadzenButton Click=@reset Text="reset" ButtonStyle="ButtonStyle.Secondary" ButtonType="ButtonType.Submit"/>
|
||||
<br/>
|
||||
</form>
|
||||
@if (msg != null)
|
||||
|
@ -25,13 +25,13 @@
|
|||
|
||||
@code {
|
||||
private string Password { get; set; }
|
||||
|
||||
|
||||
private string msg { get; set; }
|
||||
|
||||
|
||||
[Parameter]
|
||||
[Required]
|
||||
public string userid { get; set; }
|
||||
|
||||
|
||||
[Parameter]
|
||||
[Required]
|
||||
public string hash { get; set; }
|
||||
|
@ -55,7 +55,7 @@
|
|||
msg = "The token does not match the account.";
|
||||
return;
|
||||
}
|
||||
if (user.ResetPasswordExpiresAt == -1 || user.ResetPasswordToken == "-1")
|
||||
if (user.ResetPasswordExpiresAt < 0 || user.ResetPasswordToken == "-1")
|
||||
{
|
||||
msg = "There is currently no valid link to reset this accounts password.";
|
||||
return;
|
||||
|
@ -73,6 +73,6 @@
|
|||
await UsersRepository.updateUserAsync(user);
|
||||
|
||||
msg = "Your Password has been updated.";
|
||||
|
||||
}
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue