2017-09-27 14:18:09 +09:00
|
|
|
using System.ComponentModel.DataAnnotations;
|
2020-06-28 17:55:27 +09:00
|
|
|
using BTCPayServer.Services.Mails;
|
2022-06-23 13:41:52 +09:00
|
|
|
using BTCPayServer.Validation;
|
2017-09-27 14:18:09 +09:00
|
|
|
|
|
|
|
namespace BTCPayServer.Models.ServerViewModels
|
|
|
|
{
|
|
|
|
public class EmailsViewModel
|
|
|
|
{
|
2020-10-05 15:42:19 +09:00
|
|
|
public EmailsViewModel()
|
|
|
|
{
|
|
|
|
|
|
|
|
}
|
|
|
|
public EmailsViewModel(EmailSettings settings)
|
|
|
|
{
|
|
|
|
Settings = settings;
|
|
|
|
PasswordSet = !string.IsNullOrEmpty(settings?.Password);
|
|
|
|
}
|
2017-10-27 17:53:04 +09:00
|
|
|
public EmailSettings Settings
|
|
|
|
{
|
|
|
|
get; set;
|
|
|
|
}
|
2020-10-05 15:42:19 +09:00
|
|
|
public bool PasswordSet { get; set; }
|
2022-06-23 13:41:52 +09:00
|
|
|
[MailboxAddressAttribute]
|
2019-03-03 16:27:03 -06:00
|
|
|
[Display(Name = "Test Email")]
|
2017-10-27 17:53:04 +09:00
|
|
|
public string TestEmail
|
|
|
|
{
|
|
|
|
get; set;
|
|
|
|
}
|
|
|
|
}
|
2017-09-27 14:18:09 +09:00
|
|
|
}
|