using Edu.Common;
using Edu.Common.Plugin;
using System.Collections.Generic;

namespace Edu.Model.ViewModel.Question
{
    /// <summary>
    /// 题库视图实体类
    /// </summary>
    public class RB_Question_ViewModel : Model.Entity.Question.RB_Question
    {
        /// <summary>
        /// 创建人
        /// </summary>
        public string CreateByName { get; set; }

        /// <summary>
        /// 修改人
        /// </summary>
        public string UpdateByName { get; set; }

        /// <summary>
        /// 创建时间字符串
        /// </summary>
        public string CreateTimeStr { get { return this.CreateTime.FormatTime(); } }

        /// <summary>
        /// 更新时间字符串
        /// </summary>
        public string UpdateTimeStr { get { return this.UpdateTime.FormatTime(); } }

        /// <summary>
        /// 问题类型名称
        /// </summary>
        public string QuestionTypeName { get; set; }

        /// <summary>
        /// 知识点列表
        /// </summary>
        public List<RB_Question_Point_ViewModel> QuestionPointList { get; set; }

        /// <summary>
        /// 问题类型【查询使用，多选】
        /// </summary>
        public string QQuestionTypeStr { get; set; }


        /// <summary>
        /// 知识点【查询使用，多选】
        /// </summary>
        public string QPointStr { get; set; }

        /// <summary>
        /// 难易程度【查询使用,多选】
        /// </summary>
        public string QDifficultyType { get; set; }

        /// <summary>
        /// 题库编号【查询使用】
        /// </summary>
        public string QBankIds { get; set; }

        /// <summary>
        /// 题目类型
        /// </summary>
        public string Q_QuestionTypeIds { get; set; }

        /// <summary>
        /// 选项
        /// </summary>
        public object QuestionContentObj { get; set; }

        /// <summary>
        /// 知识点名称
        /// </summary>
        public string PointName { get; set; }

        /// <summary>
        /// 难易程度
        /// </summary>
        public string DifficultyTypeStr { get { return this.DifficultyType.ToName(); } }

        /// <summary>
        /// 大类名称
        /// </summary>
        public string CategoryName
        {
            get
            {
                return Common.Plugin.EnumHelper.ToName(this.Category);
            }
        }

        /// <summary>
        /// 分类编号
        /// </summary>
        public string QCategoryId { get; set; }

        /// <summary>
        /// 考级程度
        /// </summary>
        public string LevelTypeName
        {
            get
            {
                return Common.Plugin.EnumHelper.ToName(this.LevelType);
            }
        }

        /// <summary>
        /// 是否返回所有字段
        /// </summary>
        public int IsShowAllQuestion { get; set; }

        /// <summary>
        /// 问题数量
        /// </summary>
        public int QuestionCount { get; set; }


        /// <summary>
        /// 阅读理解、听力、完型，答案列表
        /// </summary>
        public List<object> QuestionAnswerList { get; set; }
    }
}