using Common.Enums;
using Hushian.Domain.Abstracts;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Hushian.Domain.Entites
{
   public class Conversation : BaseEntity
    {
        #region Key
        public int ID { get; set; }
        public int CompanyID { get; set; }
        public int UserID { get; set; }
        public int? GroupID { get; set; }
        #endregion

        #region Fild
        public ConversationStatus Status { get; set; } 
            = ConversationStatus.Recorded;
        public DateTime? FinishedDateTime { get; set; }
        public DateTime Cdatetime
        { get; set; } = DateTime.Now;
        #endregion 

        #region Navigation
        [ForeignKey("CompanyID")]
        public Company Company { get; set; }
        [ForeignKey("UserID")]
        public User User { get; set; }
        [ForeignKey("GroupID")]
        public Group? Group { get; set; }
        public ICollection<ConversationResponse> ConversationResponses { get; set; }
        = new List<ConversationResponse>();
        #endregion
    }
}
