QuestionOptionsDto.cs 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. using Exam.Infrastructure.Data.Entity;
  2. using Exam.Infrastructure.Data.Interface;
  3. using Exam.Infrastructure.Enums;
  4. using Hotline.Share.Exams.Interface;
  5. using System.ComponentModel;
  6. namespace Hotline.Share.Dtos.Questions
  7. {
  8. /// <summary>
  9. /// 试题选项
  10. /// </summary>
  11. [Description("试题选项")]
  12. public class QuestionOptionsDto:UpdateQuestionOptionsDto
  13. {
  14. public string CompleteContent
  15. {
  16. get
  17. {
  18. return string.Concat(Label, ".", Content);
  19. }
  20. }
  21. }
  22. /// <summary>
  23. /// 查看试题选项
  24. /// </summary>
  25. [Description("查看试题选项")]
  26. public class ViewQuestionOptionDto : QuestionOptionsDto
  27. {
  28. public bool IsSelected { get; set; }
  29. }
  30. /// <summary>
  31. /// 试题选项
  32. /// </summary>
  33. [Description("试题选项")]
  34. public class AddQuestionOptionsDto : IAddRequest,IOperationStatus
  35. {
  36. /// <summary>
  37. /// 选项内容
  38. /// </summary>
  39. [Description("选项内容")]
  40. public string Content { get; set; }
  41. /// <summary>
  42. /// 是否答案
  43. /// </summary>
  44. [Description("是否答案")]
  45. public bool IsAnswer { get; set; }
  46. /// <summary>
  47. /// 试题
  48. /// </summary>
  49. [Description("试题")]
  50. public string QuestionId { get; set; }
  51. /// <summary>
  52. /// 操作状态
  53. /// </summary>
  54. [Description("操作状态")]
  55. public EEOperationStatus OperationStatus { get; set; }
  56. /// <summary>
  57. /// 选项题标
  58. /// </summary>
  59. [Description("选项题标")]
  60. public string Label { get; set; }
  61. }
  62. /// <summary>
  63. /// 试题选项
  64. /// </summary>
  65. [Description("试题选项")]
  66. public class UpdateQuestionOptionsDto : AddQuestionOptionsDto,IActionRequest
  67. {
  68. /// <summary>
  69. /// 主键
  70. /// </summary>
  71. [Description("主键")]
  72. public string Id { get; set; }
  73. }
  74. }