fixed login form
This commit is contained in:
parent
17a5634c42
commit
61136aee93
14
Moonlight/App/Models/Misc/LoginDataModel.cs
Normal file
14
Moonlight/App/Models/Misc/LoginDataModel.cs
Normal file
|
@ -0,0 +1,14 @@
|
|||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Moonlight.App.Models.Misc;
|
||||
|
||||
public class LoginDataModel
|
||||
{
|
||||
[Required(ErrorMessage = "You need to enter an email address")]
|
||||
[EmailAddress(ErrorMessage = "You need to enter a valid email address")]
|
||||
public string Email { get; set; }
|
||||
|
||||
[Required(ErrorMessage = "You need to enter a password")]
|
||||
[MinLength(8, ErrorMessage = "You need to enter a password with minimum 8 characters in lenght")]
|
||||
public string Password { get; set; }
|
||||
}
|
|
@ -10,6 +10,7 @@
|
|||
@using Moonlight.App.Exceptions
|
||||
@using Logging.Net
|
||||
@using Moonlight.App.Database.Entities
|
||||
@using Moonlight.App.Models.Misc
|
||||
@using Moonlight.App.Services.OAuth2
|
||||
@using Moonlight.App.Services.Sessions
|
||||
|
||||
|
@ -113,7 +114,7 @@
|
|||
|
||||
@code
|
||||
{
|
||||
private User User = new();
|
||||
private LoginDataModel User = new();
|
||||
|
||||
private bool TotpRequired = false;
|
||||
private string TotpCode = "";
|
||||
|
|
|
@ -421,3 +421,6 @@ If you have trouble using the QR Code, select manual input in the app and enter
|
|||
Finish activation;Finish activation
|
||||
New password;New password
|
||||
Enable;Enable
|
||||
Your account is secured with 2fa;Your account is secured with 2fa
|
||||
anyone write a fancy text here?;anyone write a fancy text here?
|
||||
Disable;Disable
|
||||
|
|
Loading…
Reference in a new issue