RQYDTQuestionModule.h 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134
  1. //
  2. // RQYDTQuestionModule.h
  3. // jiaPei
  4. //
  5. // Created by 张嵘 on 2022/3/28.
  6. // Copyright © 2022 JCZ. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. typedef NS_ENUM(NSUInteger, RQQuestionUpdateViewType) {
  10. /// 默认
  11. RQQuestionUpdateViewType_Default,
  12. /// 下载中
  13. RQQuestionUpdateViewType_Request,
  14. /// 下载结束
  15. RQQuestionUpdateViewType_Complete,
  16. /// 题库下载
  17. RQQuestionUpdateViewType_LibDownload,
  18. /// 解释下载
  19. RQQuestionUpdateViewType_ExplainDownload,
  20. /// 解释下载中
  21. RQQuestionUpdateViewType_ExplainDownloading,
  22. /// 解释下载中
  23. RQQuestionUpdateViewType_ExplainDownloaded,
  24. };
  25. #pragma mark - Model
  26. #import "RQYDTExamRuleModel.h"
  27. #import "RQYDTQuestionModel.h"
  28. #import "RQYDTPointModel.h"
  29. #import "RQHTTPService+RQGetChapterList.h"
  30. #import "RQHTTPService+RQGetUpdateQuestion.h"
  31. #pragma mark - ViewModel
  32. #pragma mark - View
  33. #import "RQUpdateView.h"
  34. #pragma mark - Module
  35. #import "RQExerciseModule.h"
  36. #import "RQYDTUserQuestionModule.h"
  37. #import "RQYDTJSQuestionModule.h"
  38. #import "YNYDTJQQuestionModule.h"
  39. /// RQCarTypeChangeNotification
  40. FOUNDATION_EXTERN NSString * const RQCarTypeChangeNotification;
  41. #define RQ_YDTQuestion_Module [RQYDTQuestionModule sharedInstance]
  42. NS_ASSUME_NONNULL_BEGIN
  43. @interface RQYDTQuestionModule : NSObject
  44. @property (nonatomic, readwrite, assign) RQHomePageCarType carType;
  45. @property (nonatomic, readwrite, copy) NSString *carTypeStr;
  46. @property (nonatomic, readwrite, copy) NSString *carTypeStrNew;
  47. @property (nonatomic, readwrite, assign) RQHomePageSubjectType subject;
  48. @property (nonatomic, readwrite, copy) NSString *subjectStr;
  49. /**用户题库类型。数据库要用的。
  50. */
  51. @property (nonatomic, readwrite, copy) NSString *car_type;
  52. /**是否资格证
  53. */
  54. @property (nonatomic, readwrite, copy) NSString *isZhiGeZheng;
  55. /**科目一的顺序练习题号
  56. */
  57. @property (nonatomic, readwrite, copy) NSString *userSubj1Index;
  58. /**科目四的顺序练习题号
  59. */
  60. @property (nonatomic, readwrite, copy) NSString *userSubj4Index;
  61. /**科目一的背题题号
  62. */
  63. @property (nonatomic, readwrite, copy) NSString *user1Index;
  64. /**科目四的背题题号
  65. */
  66. @property (nonatomic, readwrite, copy) NSString *user4Index;
  67. /**
  68. * 下面全是对题号的记录 客车 货车 摩托车 教练 货运 客运 危险品 出租车
  69. */
  70. @property (nonatomic, readwrite, copy) NSString *A2Subj1Index;
  71. @property (nonatomic, readwrite, copy) NSString *A2Subj4Index;
  72. @property (nonatomic, readwrite, copy) NSString *A1Subj1Index;
  73. @property (nonatomic, readwrite, copy) NSString *A1Subj4Index;
  74. @property (nonatomic, readwrite, copy) NSString *DSubj1Index;
  75. @property (nonatomic, readwrite, copy) NSString *DSubj4Index;
  76. @property (nonatomic, readwrite, copy) NSString *coachIndex;
  77. @property (nonatomic, readwrite, copy) NSString *A1Index;
  78. @property (nonatomic, readwrite, copy) NSString *A2Index;
  79. @property (nonatomic, readwrite, copy) NSString *dangerIndex;
  80. @property (nonatomic, readwrite, copy) NSString *texiIndex;
  81. @property (nonatomic, readwrite, copy) NSString *wycIndex;
  82. /// 科目一顺序练习
  83. @property (nonatomic, readonly, copy) NSArray *subjectOneArr;
  84. /// 科目四顺序练习
  85. @property (nonatomic, readonly, copy) NSArray *subjectFourArr;
  86. /// 单例
  87. + (instancetype) sharedInstance;
  88. /// 更新题库
  89. - (void)rq_updateQuestion;
  90. - (NSInteger)getQuestionVersion;
  91. - (void)saveQuestionsWithSubjectOneArr:(NSArray *)subjectOneArr;
  92. - (void)saveQuestionsWithSubjectFourArr:(NSArray *)subjectFourArr;
  93. - (RQHomePageSubjectType)getSubjectWithSubjectName:(NSString *)subjectName;
  94. - (NSString *)getSubjectNameWithSubject:(RQHomePageSubjectType)subject;
  95. - (NSString *)getCarTypeCNNameWithCarType:(RQHomePageCarType)carType;
  96. - (NSString *)getCar_TypeNameWithCarType:(RQHomePageCarType)carType;
  97. - (NSString *)getCarTypeExamNameWithCarType:(RQHomePageCarType)carType;
  98. - (NSString *)getCarTypeCNTiKuUpdateNameWithCarType:(RQHomePageCarType)carType;
  99. - (RQHomePageCarType)getCarTypeWithCarTypeName:(NSString *)carTypeName;
  100. - (NSArray *)getQuestionWithExerciseType:(RQExerciseType)exerciseType;
  101. - (NSArray *)getQuestionWithExerciseType:(RQExerciseType)exerciseType questionIds:(NSString*)questionIds;
  102. - (NSArray *)getQuestionWithExerciseType:(RQExerciseType)exerciseType code:(NSInteger)code;
  103. - (NSArray *)getQuestionWithSubject:(RQHomePageSubjectType)subject exerciseType:(RQExerciseType)exerciseType;
  104. - (NSArray *)getQuestionWithSubject:(RQHomePageSubjectType)subject exerciseType:(RQExerciseType)exerciseType isNeedMediaData:(BOOL)isNeedMediaData;
  105. - (NSInteger)getQuestionNumWithWithSubject:(RQHomePageSubjectType)subject exerciseType:(RQExerciseType)exerciseType;
  106. /// 章节练习
  107. - (NSArray *)getChapterArr;
  108. - (NSArray *)getChapterQuestionWithChapterName:(NSString *)chapterName;
  109. - (NSArray *)getChapterQuestionWithChapterName:(NSString *)chapterName exerciseType:(RQExerciseType)exerciseType;
  110. /// 强化练习(考点)
  111. - (NSArray *)getPoint;
  112. - (NSArray *)getPointQuestionWithPointID:(NSInteger)pointId;
  113. - (NSArray *)getPointQuestionWithPointID:(NSInteger)pointId exerciseType:(RQExerciseType)exerciseType;
  114. - (BOOL)isNewRuleQuestionWithQuestionId:(NSInteger)questionId;
  115. - (NSData *)getMediaDataWithMediaName:(NSString *)mediaName;
  116. /// 做到哪一题
  117. - (NSInteger)getHistoryQuestionNum;
  118. - (void)saveHistoryQuestionNumWithQuestionId:(NSInteger)questionId;
  119. @end
  120. NS_ASSUME_NONNULL_END