forked from ddrilling/AsbCloudServer
Поля "Email" и "Телефон" формы создания контактов - необязательны к заполнению
This commit is contained in:
parent
5459fbdd5c
commit
b2d6091476
@ -34,14 +34,12 @@ namespace AsbCloudApp.Data.User
|
||||
/// <summary>
|
||||
/// Email
|
||||
/// </summary>
|
||||
[Required]
|
||||
[RegularExpression(@"^([a-zA-Z0-9_\-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([a-zA-Z0-9\-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\]?)$", ErrorMessage = "Некорректный email")]
|
||||
public string Email { get; set; } = null!;
|
||||
|
||||
/// <summary>
|
||||
/// Phone
|
||||
/// </summary>
|
||||
[Required]
|
||||
[RegularExpression(@"^(?:\+7|8)\s?(?:\(\d{3}\)|\d{3})\s?\d{3}-?\d{2}-?\d{2}$", ErrorMessage = "Некорректный номер телефона")]
|
||||
public string Phone { get; set; } = null!;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user