2021-07-14 21:31:29 +10:00
|
|
|
|
using System.ComponentModel.DataAnnotations;
|
|
|
|
|
|
|
|
|
|
namespace PartyInvites.Models
|
2021-07-14 00:01:12 +10:00
|
|
|
|
{
|
|
|
|
|
public class GuestResponse
|
|
|
|
|
{
|
2021-07-14 21:31:29 +10:00
|
|
|
|
[Required(ErrorMessage = "Please enter your name")]
|
2021-07-14 00:01:12 +10:00
|
|
|
|
public string Name { get; set; }
|
2021-07-14 21:31:29 +10:00
|
|
|
|
|
|
|
|
|
[Required(ErrorMessage = "Please enter your email address")]
|
|
|
|
|
[RegularExpression(".+\\@.+\\..+",
|
|
|
|
|
ErrorMessage = "Please enter a valid email address")]
|
2021-07-14 00:01:12 +10:00
|
|
|
|
public string Email { get; set; }
|
2021-07-14 21:31:29 +10:00
|
|
|
|
|
|
|
|
|
[Required(ErrorMessage = "Please enter your name")]
|
2021-07-14 00:01:12 +10:00
|
|
|
|
public string Phone { get; set; }
|
2021-07-14 21:31:29 +10:00
|
|
|
|
|
|
|
|
|
[Required(ErrorMessage = "Please specify whether you'll attend")]
|
2021-07-14 00:01:12 +10:00
|
|
|
|
public bool? WillAttend { get; set; }
|
2021-07-14 21:31:29 +10:00
|
|
|
|
|
2021-07-14 00:01:12 +10:00
|
|
|
|
}
|
|
|
|
|
}
|