using IRaCIS.Core.Domain.Share;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace IRaCIS.Core.Application.Service.Reading.Dto
{

    public class GetReadingImgOutDto
    {
        public string Path { get; set; }

        public string FileName { get; set; }
    }

    public class GetReadingTaskDto
    {
        public Guid VisistTaskId { get; set; }
        public Guid VisistId { get; set; }

        public Guid SubjectId { get; set; }

        public ReadingCategory ReadingCategory { get; set; }

        public decimal VisitNum { get; set; }

    }

    public class GetReadingImgInDto
    {

        public Guid? SubjectId { get; set; }

        [NotDefault]
        public Guid TrialId { get; set; }

        public Guid? VisistTaskId { get; set; }
    }

    public class GetConfirmCriterionInDto
    {
        [NotDefault]
        public Guid TrialId { get; set; }
    }



    /// <summary>
    /// 返回对象
    /// </summary>
    public class GetTrialConfirmCriterionListOutDto
    {
        public Guid ReadingQuestionCriterionTrialId { get; set; }

        /// <summary>
        /// 标准
        /// </summary>
        public string ReadingQuestionCriterionTrialName { get; set; }
    }


    public class SetTrialCriterionJudgeQuestionAnswerGroupInDto
    {
        [NotDefault]
        public Guid ReadingQuestionTrialId { get; set; }


        [NotDefault]
        public List<string> AnswerGroup { get; set; }
    }

    public class GetTrialCriterionJudgeQuestionListOutDto
    {
        public Guid ReadingQuestionTrialId { get; set; }

        public string QuestionName { get; set; }

        public string TypeValue { get; set; }

        public List<string> AnswerGroup { get; set; }


    }

    public class GetTrialCriterionJudgeQuestionListInDto
    {
        [NotDefault]
        public Guid ReadingQuestionCriterionTrialId { get; set; }
    }

    public class GetTrialReadingQuestionInDto
    {
        [NotDefault]
        public Guid ReadingQuestionCriterionTrialId { get; set; }

        public Guid? VisitTaskId { get; set; }
    }

    /// <summary>
    /// 
    /// </summary>
    public class SubmitVisitTaskQuestionsInDto
    {
        [NotDefault]
        public Guid TrialId { get; set; }
        [NotDefault]
        public Guid VisitTaskId { get; set; }
        [NotDefault]
        public Guid ReadingQuestionCriterionTrialId { get; set; }

        public List<QuestionAnswer> AnswerList { get; set; } = new List<QuestionAnswer>();
    }

    public class SaveJudgeTaskDto
    {
        public List<Guid> VisitTaskIds { get; set; }
    }

    public class QuestionAnswer
    {
        public Guid ReadingQuestionTrialId { get; set; }

        public string Answer { get; set; }
    }


    //public class GetTrialReadingQuestionDto
    //{
    //    public Guid Id { get; set; }

    //    public string GroupName { get; set; }

    //    List<GetTrialReadingQuestionOutDto> Questions { get; set; }
    //}

    public class GroupTaskAnswerDto
    {
        public Guid QuestionId { get; set; }

        public string AnswerGroup { get; set; }

        public List<TaskAnswerDto> TaskAnswerList { get; set; }
    }

    public class AnswerGroup
    {
        public Guid GroupId { get; set; }

        public string GroupValue { get; set; }
    }


    public class TaskAnswerDto
    {
        public Guid VisitTaskId { get; set; }

        public Guid QuestionId { get; set; }

        public string Answer { get; set; }

        public string AnswerGroup { get; set; }
    }

    public class GetTrialReadingQuestionOutDto
    {
        public Guid ReadingQuestionTrialId { get; set; }

        /// <summary>
        /// 项目标准Id
        /// </summary>
        public Guid ReadingQuestionCriterionTrialId { get; set; }

        /// <summary>
        /// 项目Id
        /// </summary>
        public Guid TrialId { get; set; }

        /// <summary>
        /// 类型
        /// </summary>
        public string Type { get; set; }

        /// <summary>
        /// 父问题触发
        /// </summary>
        public string ParentTriggerValue { get; set; }

        public string GroupName { get; set; }

        /// <summary>
        /// 问题名称
        /// </summary>
        public string QuestionName { get; set; }

        /// <summary>
        /// 是否是必须
        /// </summary>
        public bool IsRequired { get; set; }

        /// <summary>
        /// 排序
        /// </summary>
        public int ShowOrder { get; set; }

        /// <summary>
        /// 父问题ID
        /// </summary>
        public Guid? ParentId { get; set; }


        /// <summary>
        /// 类型值
        /// </summary>
        public string TypeValue { get; set; }

        /// <summary>
        /// 答案
        /// </summary>
        public string Answer { get; set; }

        public List<GetTrialReadingQuestionOutDto> Childrens { get; set; }
    }


}