Files
Backend-Api/CompanyManagment.App.Contracts/Representative/CreateLegalRepresentative.cs

46 lines
1.3 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
using System.ComponentModel.DataAnnotations;
namespace CompanyManagment.App.Contracts.Representative;
public class CreateLegalRepresentative
{
/// <summary>
/// نام حقوقی
/// </summary>
[Required(ErrorMessage = "این مقدار نمی تواند خالی باشد")]
public string LegalName { get; set; }
/// <summary>
/// شناسه ثبت
/// </summary>
[RegularExpression("^[0-9]*$", ErrorMessage = "لطفا فقط عدد وارد کنید")]
public string RegisterId { get; set; }
/// <summary>
/// شناسه ملی
/// </summary>
[RegularExpression("[0-9]{11}", ErrorMessage = "لطفا فقط عدد 11 رقمی وارد کنید")]
public string NationalId { get; set; }
/// <summary>
/// شماره تلفن
/// </summary>
[DataType(DataType.PhoneNumber)]
[RegularExpression(@"^\(?([0-9]{4})\)?[-. ]?([0-9]{3})[-. ]?([0-9]{4})$", ErrorMessage = "لطفا شماره تلفن معتبر وارد کنید")]
public string Phone { get; set; }
/// <summary>
/// شماره تلفن نماینده
/// </summary>
[RegularExpression("^[0-9]*$", ErrorMessage = "لطفا فقط عدد وارد کنید")]
public string AgentPhone { get; set; }
/// <summary>
/// آدرس
/// </summary>
public string Address { get; set; }
}