Files
constructdemo/ConstructorApp.EntityLayer/Entities/ContactUs.cs
2025-05-01 15:18:30 +03:00

28 lines
1.0 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 ConstructorApp.EntityLayer.Entities
{
public class ContactUs
{
[Key]
public int ContactusID { get; set; }
public DateTime Date { get; set; } = DateTime.Now;
[Required(ErrorMessage = "Ad Soyad alanı zorunludur.")]
[StringLength(50, ErrorMessage = "Ad Soyad en fazla 50 karakter olabilir.")]
public string? NameSurname { get; set; }
[Required(ErrorMessage = "Mail adresi zorunludur.")]
[EmailAddress(ErrorMessage = "Geçerli bir e-posta adresi giriniz.")]
public string? Mail { get; set; }
[Required(ErrorMessage = "Telefon numarası zorunludur.")]
[Phone(ErrorMessage = "Geçerli bir telefon numarası giriniz.")]
public string? Phone { get; set; }
[Required(ErrorMessage = "Mesaj içeriği boş bırakılamaz.")]
[StringLength(500, ErrorMessage = "Mesaj en fazla 500 karakter olabilir.")]
public string? MessageContent { get; set; }
public bool Status { get; set; }
}
}