using Marco.Pms.Model.Employees;
using Marco.Pms.Model.Master;
using Marco.Pms.Model.OrganizationModel;
using Marco.Pms.Model.Utilities;
using Microsoft.AspNetCore.Mvc.ModelBinding.Validation;
using System.ComponentModel.DataAnnotations.Schema;

namespace Marco.Pms.Model.ServiceProject
{
    public class ServiceProject : TenantRelation
    {
        public Guid Id { get; set; }
        public string Name { get; set; } = string.Empty;
        public string ShortName { get; set; } = string.Empty;
        public Guid ClientId { get; set; }

        [ValidateNever]
        [ForeignKey("ClientId")]
        public Organization? Client { get; set; }
        public string Address { get; set; } = string.Empty;
        public DateTime AssignedDate { get; set; }
        public Guid StatusId { get; set; }

        [ValidateNever]
        [ForeignKey("StatusId")]
        public StatusMaster? Status { get; set; }
        public string ContactName { get; set; } = string.Empty;
        public string ContactPhone { get; set; } = string.Empty;
        public string ContactEmail { get; set; } = string.Empty;
        public bool IsActive { get; set; }
        public DateTime CreatedAt { get; set; }
        public Guid CreatedById { get; set; }

        [ValidateNever]
        [ForeignKey("CreatedById")]
        public Employee? CreatedBy { get; set; }
        public DateTime? UpdatedAt { get; set; }
        public Guid? UpdatedById { get; set; }

        [ValidateNever]
        [ForeignKey("UpdatedById")]
        public Employee? UpdatedBy { get; set; }
    }
}
