namespace IRaCIS.Application.Contracts
{
    #region TP
    public class WorkloadTPDTO
    {
        public Guid Id { get; set; }
        public Guid TrialSiteId { get; set; }
        public string SiteName { get; set; } = String.Empty;
        public Guid SubjectId { get; set; }
        public string SubjectCode { get; set; } = String.Empty;
        public Guid SubjectVisitId { get; set; }
        public string VisitName { get; set; } = String.Empty;
        public decimal VisitNum { get; set; }
        public Guid StudyId { get; set; }
        public string StudyCode { get; set; } = String.Empty;
        public string TimepointCode { get; set; } = String.Empty;
        public Guid ReviewerId { get; set; }
        public string ReviewerCode { get; set; } = String.Empty;
        public string ReviewerFirstName { get; set; } = String.Empty;
        public string ReviewerLastName { get; set; } = String.Empty;
        public string ReviewerChineseName { get; set; } = String.Empty;
        public int Status { get; set; }
        public DateTime UpdateTime { get; set; }
    }
    #endregion

    #region Global
    public class WorkloadGlobalDTO
    {
        public Guid Id { get; set; }
        public Guid TrialSiteId { get; set; }
        public string SiteName { get; set; } = String.Empty;
        public Guid VisitId { get; set; }
        public string VisitName { get; set; } = String.Empty;

        public Guid TrialId { get; set; }
        public Guid SubjectId { get; set; }
        public string SubjectCode { get; set; } = String.Empty;
        public decimal VisitNum { get; set; }

        public string GlobalCode { get; set; } = String.Empty;
        public Guid ReviewerId { get; set; }
        public string ReviewerCode { get; set; } = String.Empty;
        public string ReviewerFirstName { get; set; } = String.Empty;
        public string ReviewerLastName { get; set; } = String.Empty;
        public string ReviewerChineseName { get; set; } = String.Empty;
        public int Status { get; set; }
        public DateTime UpdateTime { get; set; }
    }
    #endregion

    #region AD
    public class WorkloadADDTO
    {
        public Guid Id { get; set; }
        public Guid TrialId { get; set; }
        public Guid TrialSiteId { get; set; }
        public string SiteName { get; set; } = String.Empty;
        public Guid SubjectId { get; set; }
        public string SubjectCode { get; set; } = String.Empty;
        public string ADCode { get; set; } = String.Empty;
        public Guid ReviewerId { get; set; }
        public string ReviewerCode { get; set; } = String.Empty;
        public string ReviewerFirstName { get; set; } = String.Empty;
        public string ReviewerLastName { get; set; } = String.Empty;
        public string ReviewerChineseName { get; set; } = String.Empty;
        public int Status { get; set; }
        public DateTime UpdateTime { get; set; }
        public Guid Global1Id { get; set; }
        public Guid Global2Id { get; set; }
    }
    #endregion

    public class WorkloadDistributionQueryParam : PageInput
    {
        public Guid TrialId { get; set; } = Guid.Empty;
        public Guid? TrialSiteId { get; set; } = Guid.Empty;
        public string SubjectCode { get; set; } = string.Empty;
        public string WorkloadCode { get; set; } = string.Empty;
        public string Reviewer { get; set; } = string.Empty;
        public int? Status { get; set; }
        public int? GroupId { get; set; } = 0;
    }

    public class WorkloadTPInfo
    {
        public Guid Id { get; set; }
        public Guid StudyId { get; set; }
    }
    public class WorkloadTPCommand
    {
        public List<WorkloadTPInfo> TpList { get; set; } = new List<WorkloadTPInfo>();
        public Guid ReviewerId { get; set; }
        public string ReviewerName { get; set; } = String.Empty;
    }

    public class WorkloadGlobalInfo
    {
        public Guid Id { get; set; }
        public Guid SubjectId { get; set; }
        public decimal VisitNum { get; set; }
    }
    public class WorkloadGlobalCommand
    {
        public List<WorkloadGlobalInfo> GlobalList { get; set; } = new List<WorkloadGlobalInfo>();
        public Guid ReviewerId { get; set; }
        public string ReviewerName { get; set; } = String.Empty;
    }
    public class WorkloadAdCommand
    {
        public List<Guid> IdList { get; set; } = new List<Guid>();
        public Guid ReviewerId { get; set; }
        public string ReviewerName { get; set; } = String.Empty;
    }

    //public class WorkloadDistributionUpdateCommand
    //{
    //    public Guid Id { get; set; }
    //    public Guid? ReviewerId { get; set; }
    //}

    public class WorkloadDetailDTO
    {
        public Guid Id { get; set; }
        public Guid WorkloadId { get; set; }
        public string OptUserName { get; set; } = String.Empty;
        public DateTime OptTime { get; set; }
        public string ReviewerFirstName { get; set; } = String.Empty;
        public string ReviewerLastName { get; set; } = String.Empty;
        public string ReviewerChineseName { get; set; } = String.Empty;
        public int Status { get; set; }
    }

    //public class WorkloadDetailQueryParam
    //{
    //    public int WorkloadType { get; set; } //1-tp,2-global,3-ad
    //    public Guid WorkloadId { get; set; }

    //}

}
