mirror of https://github.com/lidarr/Lidarr
76 lines
2.0 KiB
C#
76 lines
2.0 KiB
C#
|
using System;
|
|||
|
using System.Collections.Generic;
|
|||
|
using System.ComponentModel;
|
|||
|
using System.ComponentModel.DataAnnotations;
|
|||
|
using System.Globalization;
|
|||
|
using System.Linq;
|
|||
|
using System.Web;
|
|||
|
using System.Web.Mvc;
|
|||
|
using System.Web.Security;
|
|||
|
|
|||
|
namespace NzbDrone.Web.Models
|
|||
|
{
|
|||
|
|
|||
|
#region Models
|
|||
|
[PropertiesMustMatch("NewPassword", "ConfirmPassword", ErrorMessage = "The new password and confirmation password do not match.")]
|
|||
|
public class ChangePasswordModel1
|
|||
|
{
|
|||
|
[Required]
|
|||
|
[DataType(DataType.Password)]
|
|||
|
[DisplayName("Current password")]
|
|||
|
public string OldPassword { get; set; }
|
|||
|
|
|||
|
[Required]
|
|||
|
[ValidatePasswordLength]
|
|||
|
[DataType(DataType.Password)]
|
|||
|
[DisplayName("New password")]
|
|||
|
public string NewPassword { get; set; }
|
|||
|
|
|||
|
[Required]
|
|||
|
[DataType(DataType.Password)]
|
|||
|
[DisplayName("Confirm new password")]
|
|||
|
public string ConfirmPassword { get; set; }
|
|||
|
}
|
|||
|
|
|||
|
public class LogOnModel1
|
|||
|
{
|
|||
|
[Required]
|
|||
|
[DisplayName("User name")]
|
|||
|
public string UserName { get; set; }
|
|||
|
|
|||
|
[Required]
|
|||
|
[DataType(DataType.Password)]
|
|||
|
[DisplayName("Password")]
|
|||
|
public string Password { get; set; }
|
|||
|
|
|||
|
[DisplayName("Remember me?")]
|
|||
|
public bool RememberMe { get; set; }
|
|||
|
}
|
|||
|
|
|||
|
[PropertiesMustMatch("Password", "ConfirmPassword", ErrorMessage = "The password and confirmation password do not match.")]
|
|||
|
public class RegisterModel1
|
|||
|
{
|
|||
|
[Required]
|
|||
|
[DisplayName("User name")]
|
|||
|
public string UserName { get; set; }
|
|||
|
|
|||
|
[Required]
|
|||
|
[DataType(DataType.EmailAddress)]
|
|||
|
[DisplayName("Email address")]
|
|||
|
public string Email { get; set; }
|
|||
|
|
|||
|
[Required]
|
|||
|
[ValidatePasswordLength]
|
|||
|
[DataType(DataType.Password)]
|
|||
|
[DisplayName("Password")]
|
|||
|
public string Password { get; set; }
|
|||
|
|
|||
|
[Required]
|
|||
|
[DataType(DataType.Password)]
|
|||
|
[DisplayName("Confirm password")]
|
|||
|
public string ConfirmPassword { get; set; }
|
|||
|
}
|
|||
|
#endregion
|
|||
|
|
|||
|
}
|