Эх сурвалжийг харах

just format code styles, nothing change...

deason 2 жил өмнө
parent
commit
c77bdd8e9e
97 өөрчлөгдсөн 3656 нэмэгдсэн , 3544 устгасан
  1. 77 77
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/AdminOperateType.java
  2. 1 1
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/BasicDataType.java
  3. 28 28
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/BooleanSelect.java
  4. 20 20
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/CURD.java
  5. 37 37
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/CourseLevel.java
  6. 16 16
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/ExamSpecialSettingsType.java
  7. 8 8
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/ExamStageStartExamStatus.java
  8. 1 1
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/ExamType.java
  9. 1 1
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/Gender.java
  10. 16 16
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/NoticeReceiverRuleType.java
  11. 20 20
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/NoticeStatus.java
  12. 16 16
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/PrivilegeGroupType.java
  13. 8 8
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/SubmitType.java
  14. 2 3
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/BaseRequest.java
  15. 13 14
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/BaseResponse.java
  16. 12 12
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/EnterpriseRequest.java
  17. 12 12
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/EnterpriseResponse.java
  18. 2 3
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/ExchangeBean.java
  19. 43 43
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/FormFilePart.java
  20. 11 11
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/FormRequest.java
  21. 1 2
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/JsonSerializable.java
  22. 121 121
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/PageInfo.java
  23. 36 36
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/security/bean/AccessApp.java
  24. 50 51
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/security/bean/Role.java
  25. 46 46
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/security/bean/UserType.java
  26. 66 66
      examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/security/bean/WebSocketSession.java
  27. 56 44
      examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/bean/AdminOperateReport.java
  28. 56 50
      examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/bean/BaseReport.java
  29. 53 48
      examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/bean/OnlineExamStudentReport.java
  30. 32 29
      examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/bean/OnlineStudentReport.java
  31. 32 29
      examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/bean/OnlineUserReport.java
  32. 63 56
      examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/bean/OperateReport.java
  33. 27 27
      examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/enums/MqType.java
  34. 30 31
      examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/enums/OperateContent.java
  35. 70 69
      examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/enums/Tag.java
  36. 34 34
      examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/enums/Topic.java
  37. 112 119
      examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/util/ReportsUtil.java
  38. 61 61
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/AppCacheBean.java
  39. 1 0
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/BasePaperCacheBean.java
  40. 46 43
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/CourseCacheBean.java
  41. 8 8
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamOrgPropertyCacheBean.java
  42. 1 1
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamOrgSettingsCacheBean.java
  43. 22 22
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamPropertyCacheBean.java
  44. 23 20
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamRecordPropertyCacheBean.java
  45. 190 190
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamSettingsCacheBean.java
  46. 138 141
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamStageCacheBean.java
  47. 20 18
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamStagesCacheBean.java
  48. 145 144
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamStudentCacheBean.java
  49. 8 8
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamStudentPropertyCacheBean.java
  50. 1 1
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamStudentSettingsCacheBean.java
  51. 118 117
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExtractConfigCacheBean.java
  52. 1 0
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExtractConfigDetailCacheBean.java
  53. 1 0
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExtractConfigPaperCacheBean.java
  54. 50 52
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/OrgCacheBean.java
  55. 22 22
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/OrgPropertyCacheBean.java
  56. 24 24
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/PrivilegeRolesCacheBean.java
  57. 1 0
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/QuestionAnswerCacheBean.java
  58. 1 0
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/QuestionCacheBean.java
  59. 50 52
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/RootOrgCacheBean.java
  60. 24 24
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/RootOrgPrivilegesCacheBean.java
  61. 192 191
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/SmsAssemblyCacheBean.java
  62. 103 103
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/StudentCacheBean.java
  63. 15 15
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/SysPropertyCacheBean.java
  64. 53 53
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ThirdPartyAccessCacheBean.java
  65. 6 2
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/enums/ExamProcess.java
  66. 1 1
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/enums/ExamRecordStatus.java
  67. 38 38
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/enums/IsSuccess.java
  68. 30 30
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamBoss.java
  69. 94 86
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamFileAnswer.java
  70. 187 153
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamQuestion.java
  71. 26 27
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamRecordPaperStruct.java
  72. 3 2
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamRecordQuestions.java
  73. 41 40
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamingActivityTime.java
  74. 44 43
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamingHeartbeat.java
  75. 8 8
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamingStatus.java
  76. 7 3
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ColumnSetting.java
  77. 22 21
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelCell.java
  78. 40 39
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelError.java
  79. 83 88
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelErrorType.java
  80. 14 10
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelProperty.java
  81. 2 2
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelReaderHandle.java
  82. 25 22
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelRow.java
  83. 32 30
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelSheet.java
  84. 25 25
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/filestorage/FileStorageUtil.java
  85. 3 1
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/AudioTextHandler.java
  86. 10 9
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/ComplexTextHandler.java
  87. 15 14
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/HtmlTextHandler.java
  88. 15 15
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/ImageTextHandler.java
  89. 2 0
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/RichTextHandler.java
  90. 9 6
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/RichTextHandlerFactory.java
  91. 3 0
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/bean/BlockBean.java
  92. 1 2
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/bean/SectionBean.java
  93. 2 1
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/helper/IdentityNumberHelper.java
  94. 73 52
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/privilege/PrivilegeDefine.java
  95. 44 44
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/privilege/PrivilegeManager.java
  96. 4 7
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/redis/RedisKeyDefine.java
  97. 199 208
      examcloud-support/src/main/java/cn/com/qmth/examcloud/support/util/FileDisposeUtil.java

+ 77 - 77
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/AdminOperateType.java

@@ -1,85 +1,85 @@
 package cn.com.qmth.examcloud.api.commons.enums;
 
 public enum AdminOperateType {
-	TYPE1("考生端配置-保存考生端配置"),
-	TYPE2("考生端配置-上传学校logo"),
-	TYPE3("考生端配置-上传考生端登录界面图片"),
-	TYPE4("考生端配置-上传学校答题纸模板"),
-	TYPE5("考生端配置-上传菜单logo"),
-	
-	TYPE6("普通用户管理-新增用户"),
-	TYPE7("普通用户管理-修改用户"),
-	TYPE8("普通用户管理-重置用户密码"),
-	TYPE9("普通用户管理-批量重置用户密码"),
-	TYPE10("普通用户管理-启用用户"),
-	TYPE11("普通用户管理-禁用用户"),
-	TYPE12("普通用户管理-权限复制"),
-	
-	TYPE13("监考已审-导出"),
-	
-	TYPE14("监考待审-审核"),
-	TYPE15("监考待审-批量审核"),
-	
-	TYPE16("考试明细-重审"),
-	TYPE17("考试明细-导出"),
-	
-	TYPE18("成绩统计-导出"),
-	
-	TYPE19("考试进度详情-导出"),
-	
-	TYPE20("设置重考-设置重考"),
-	
-	TYPE21("考试进度详情-上传作答"),
-	
-	TYPE22("调卷规则-保存音频播放次数"),
-	TYPE23("调卷规则-新增调卷规则"),
-	TYPE24("调卷规则-修改调卷规则"),
-	
-	TYPE25("考试试卷管理-简易组卷"),
-	TYPE26("考试试卷管理-精细组卷"),
-	TYPE27("考试试卷管理-蓝图组卷"),
-	TYPE28("考试试卷管理-手动组卷"),
-	TYPE31("考试试卷管理-试卷审核"),
-	TYPE33("考试试卷管理-编辑试卷"),
-	TYPE36("考试试卷管理-下载"),
-	TYPE37("考试试卷管理-批量下载"),
-	TYPE39("考试试卷管理-修改大题名称"),
-	TYPE41("考试试卷管理-删除大题"),
-	TYPE42("考试试卷管理-移动大题"),
-	TYPE44("考试试卷管理-编辑小题"),
-	TYPE45("考试试卷管理-删除小题"),
-	TYPE47("考试试卷管理-删除试卷"),
-	TYPE49("考试试卷管理-选题"),
-	
-	TYPE29("导入试卷管理-导入试卷"),
-	TYPE30("导入试卷管理-复制试卷"),
-	TYPE32("导入试卷管理-编辑试卷"),
-	TYPE34("导入试卷管理-使用原卷"),
-	TYPE35("导入试卷管理-试卷答案导入"),
-	TYPE38("导入试卷管理-修改大题名称"),
-	TYPE40("导入试卷管理-删除大题"),
-	TYPE43("导入试卷管理-编辑小题"),
-	TYPE46("导入试卷管理-删除原卷"),
-	TYPE48("导入试卷管理-删除小题"),
-	
-	TYPE50("试卷检查-打回"),
-	TYPE51("试卷检查-批量打回"),
-	
-	TYPE52("创建评卷工作-设置任务数"),
-	TYPE53("创建评卷工作-设置给分间隔"),
-	TYPE54("创建评卷工作-导出评卷员"),
-	TYPE55("创建评卷工作-修改"),
-	TYPE56("创建评卷工作-删除评卷工作"),
-	TYPE57("创建评卷工作-结束评卷工作"),
-	TYPE58("创建评卷工作-开启评卷工作"),
-	TYPE59("创建评卷工作-成绩发布"),
-	TYPE60("创建评卷工作-设置评卷员"),
-	TYPE61("创建评卷工作-导入评卷员"),
-	TYPE62("创建评卷工作-新增"),
-	TYPE63("创建评卷工作-重试"),
+    TYPE1("考生端配置-保存考生端配置"),
+    TYPE2("考生端配置-上传学校logo"),
+    TYPE3("考生端配置-上传考生端登录界面图片"),
+    TYPE4("考生端配置-上传学校答题纸模板"),
+    TYPE5("考生端配置-上传菜单logo"),
+
+    TYPE6("普通用户管理-新增用户"),
+    TYPE7("普通用户管理-修改用户"),
+    TYPE8("普通用户管理-重置用户密码"),
+    TYPE9("普通用户管理-批量重置用户密码"),
+    TYPE10("普通用户管理-启用用户"),
+    TYPE11("普通用户管理-禁用用户"),
+    TYPE12("普通用户管理-权限复制"),
+
+    TYPE13("监考已审-导出"),
+
+    TYPE14("监考待审-审核"),
+    TYPE15("监考待审-批量审核"),
+
+    TYPE16("考试明细-重审"),
+    TYPE17("考试明细-导出"),
+
+    TYPE18("成绩统计-导出"),
+
+    TYPE19("考试进度详情-导出"),
+
+    TYPE20("设置重考-设置重考"),
+
+    TYPE21("考试进度详情-上传作答"),
+
+    TYPE22("调卷规则-保存音频播放次数"),
+    TYPE23("调卷规则-新增调卷规则"),
+    TYPE24("调卷规则-修改调卷规则"),
+
+    TYPE25("考试试卷管理-简易组卷"),
+    TYPE26("考试试卷管理-精细组卷"),
+    TYPE27("考试试卷管理-蓝图组卷"),
+    TYPE28("考试试卷管理-手动组卷"),
+    TYPE31("考试试卷管理-试卷审核"),
+    TYPE33("考试试卷管理-编辑试卷"),
+    TYPE36("考试试卷管理-下载"),
+    TYPE37("考试试卷管理-批量下载"),
+    TYPE39("考试试卷管理-修改大题名称"),
+    TYPE41("考试试卷管理-删除大题"),
+    TYPE42("考试试卷管理-移动大题"),
+    TYPE44("考试试卷管理-编辑小题"),
+    TYPE45("考试试卷管理-删除小题"),
+    TYPE47("考试试卷管理-删除试卷"),
+    TYPE49("考试试卷管理-选题"),
+
+    TYPE29("导入试卷管理-导入试卷"),
+    TYPE30("导入试卷管理-复制试卷"),
+    TYPE32("导入试卷管理-编辑试卷"),
+    TYPE34("导入试卷管理-使用原卷"),
+    TYPE35("导入试卷管理-试卷答案导入"),
+    TYPE38("导入试卷管理-修改大题名称"),
+    TYPE40("导入试卷管理-删除大题"),
+    TYPE43("导入试卷管理-编辑小题"),
+    TYPE46("导入试卷管理-删除原卷"),
+    TYPE48("导入试卷管理-删除小题"),
+
+    TYPE50("试卷检查-打回"),
+    TYPE51("试卷检查-批量打回"),
+
+    TYPE52("创建评卷工作-设置任务数"),
+    TYPE53("创建评卷工作-设置给分间隔"),
+    TYPE54("创建评卷工作-导出评卷员"),
+    TYPE55("创建评卷工作-修改"),
+    TYPE56("创建评卷工作-删除评卷工作"),
+    TYPE57("创建评卷工作-结束评卷工作"),
+    TYPE58("创建评卷工作-开启评卷工作"),
+    TYPE59("创建评卷工作-成绩发布"),
+    TYPE60("创建评卷工作-设置评卷员"),
+    TYPE61("创建评卷工作-导入评卷员"),
+    TYPE62("创建评卷工作-新增"),
+    TYPE63("创建评卷工作-重试"),
     ;
 
-	AdminOperateType(String desc) {
+    AdminOperateType(String desc) {
         this.desc = desc;
     }
 

+ 1 - 1
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/BasicDataType.java

@@ -9,6 +9,6 @@ package cn.com.qmth.examcloud.api.commons.enums;
  */
 public enum BasicDataType {
 
-	STRING, INTEGER, BOOLEAN, LONG, DATE;
+    STRING, INTEGER, BOOLEAN, LONG, DATE;
 
 }

+ 28 - 28
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/BooleanSelect.java

@@ -9,36 +9,36 @@ package cn.com.qmth.examcloud.api.commons.enums;
  */
 public enum BooleanSelect {
 
-	/**
-	 * 未指定
-	 */
-	UNDEFINED,
+    /**
+     * 未指定
+     */
+    UNDEFINED,
 
-	/**
-	 * true
-	 */
-	TRUE,
+    /**
+     * true
+     */
+    TRUE,
 
-	/**
-	 * false
-	 */
-	FALSE;
+    /**
+     * false
+     */
+    FALSE;
 
-	/**
-	 * 获取boolean
-	 *
-	 * @author WANGWEI
-	 * @param value
-	 * @return
-	 */
-	public Boolean getBoolean() {
-		if (UNDEFINED.equals(this)) {
-			return null;
-		} else if (TRUE.equals(this)) {
-			return true;
-		} else {
-			return false;
-		}
-	}
+    /**
+     * 获取boolean
+     *
+     * @param value
+     * @return
+     * @author WANGWEI
+     */
+    public Boolean getBoolean() {
+        if (UNDEFINED.equals(this)) {
+            return null;
+        } else if (TRUE.equals(this)) {
+            return true;
+        } else {
+            return false;
+        }
+    }
 
 }

+ 20 - 20
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/CURD.java

@@ -9,29 +9,29 @@ package cn.com.qmth.examcloud.api.commons.enums;
  */
 public enum CURD {
 
-	/**
-	 * 创建
-	 */
-	CREATION,
+    /**
+     * 创建
+     */
+    CREATION,
 
-	/**
-	 * 更新
-	 */
-	UPDATE,
+    /**
+     * 更新
+     */
+    UPDATE,
 
-	/**
-	 * 创建或更新
-	 */
-	CREATION_OR_UPDATE,
+    /**
+     * 创建或更新
+     */
+    CREATION_OR_UPDATE,
 
-	/**
-	 * 获取
-	 */
-	RETRIEVE,
+    /**
+     * 获取
+     */
+    RETRIEVE,
 
-	/**
-	 * 删除
-	 */
-	DELETE
+    /**
+     * 删除
+     */
+    DELETE
 
 }

+ 37 - 37
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/CourseLevel.java

@@ -9,42 +9,42 @@ package cn.com.qmth.examcloud.api.commons.enums;
  */
 public enum CourseLevel {
 
-	ZSB("专升本"),
-
-	GQZ("高起专"),
-
-	GQB("高起本"),
-
-	ALL("不限");
-
-	private String name;
-
-	private CourseLevel(String name) {
-		this.name = name;
-	}
-
-	public String getName() {
-		return this.name;
-	}
-
-	/**
-	 * 混合查询
-	 *
-	 * @author WANGWEI
-	 * @param name
-	 * @return
-	 */
-	public static CourseLevel getCourseLevel(String name) {
-		for (CourseLevel cur : CourseLevel.values()) {
-			if (name.equals(cur.getName())) {
-				return cur;
-			}
-			if (name.equals(cur.name())) {
-				return cur;
-			}
-		}
-
-		throw new RuntimeException("level name is wong");
-	}
+    ZSB("专升本"),
+
+    GQZ("高起专"),
+
+    GQB("高起本"),
+
+    ALL("不限");
+
+    private String name;
+
+    private CourseLevel(String name) {
+        this.name = name;
+    }
+
+    public String getName() {
+        return this.name;
+    }
+
+    /**
+     * 混合查询
+     *
+     * @param name
+     * @return
+     * @author WANGWEI
+     */
+    public static CourseLevel getCourseLevel(String name) {
+        for (CourseLevel cur : CourseLevel.values()) {
+            if (name.equals(cur.getName())) {
+                return cur;
+            }
+            if (name.equals(cur.name())) {
+                return cur;
+            }
+        }
+
+        throw new RuntimeException("level name is wong");
+    }
 
 }

+ 16 - 16
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/ExamSpecialSettingsType.java

@@ -9,24 +9,24 @@ package cn.com.qmth.examcloud.api.commons.enums;
  */
 public enum ExamSpecialSettingsType {
 
-	/**
-	 * 机构维度
-	 */
-	ORG_BASED,
+    /**
+     * 机构维度
+     */
+    ORG_BASED,
 
-	/**
-	 * 学生维度
-	 */
-	STUDENT_BASED,
+    /**
+     * 学生维度
+     */
+    STUDENT_BASED,
 
-	/**
-	 * 课程维度
-	 */
-	COURSE_BASED,
+    /**
+     * 课程维度
+     */
+    COURSE_BASED,
 
-	/**
-	 * 场次维度
-	 */
-	STAGE_BASED
+    /**
+     * 场次维度
+     */
+    STAGE_BASED
 
 }

+ 8 - 8
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/ExamStageStartExamStatus.java

@@ -7,13 +7,13 @@ package cn.com.qmth.examcloud.api.commons.enums;
  * @Version 1.0
  */
 public enum ExamStageStartExamStatus {
-	/**
-	 * 未开考
-	 */
-	NOT_START,
+    /**
+     * 未开考
+     */
+    NOT_START,
 
-	/**
-	 * 已开考
-	 */
-	STARTED
+    /**
+     * 已开考
+     */
+    STARTED
 }

+ 1 - 1
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/ExamType.java

@@ -29,7 +29,7 @@ public enum ExamType {
      * 分布式印刷考试
      */
     PRINT_EXAM("分布式印刷考试"),
-    
+
     /**
      * 在线作业
      */

+ 1 - 1
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/Gender.java

@@ -4,5 +4,5 @@ package cn.com.qmth.examcloud.api.commons.enums;
  * Created by songyue on 17/2/22.
  */
 public enum Gender {
-    MAN,WOMAN
+    MAN, WOMAN
 }

+ 16 - 16
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/NoticeReceiverRuleType.java

@@ -9,24 +9,24 @@ package cn.com.qmth.examcloud.api.commons.enums;
  */
 public enum NoticeReceiverRuleType {
 
-	/**
-	 * 归属考试的考生
-	 */
-	STUDENTS_OF_EXAM,
+    /**
+     * 归属考试的考生
+     */
+    STUDENTS_OF_EXAM,
 
-	/**
-	 * 顶级机构下所有学生
-	 */
-	ALL_STUDENTS_OF_ROOT_ORG,
+    /**
+     * 顶级机构下所有学生
+     */
+    ALL_STUDENTS_OF_ROOT_ORG,
 
-	/**
-	 * 拥有角色的用户
-	 */
-	COMMON_USERS_OF_ROLE,
+    /**
+     * 拥有角色的用户
+     */
+    COMMON_USERS_OF_ROLE,
 
-	/**
-	 * 阅卷工作的老师
-	 */
-	TEACHER_OF_MARK_WORK
+    /**
+     * 阅卷工作的老师
+     */
+    TEACHER_OF_MARK_WORK
 
 }

+ 20 - 20
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/NoticeStatus.java

@@ -9,26 +9,26 @@ package cn.com.qmth.examcloud.api.commons.enums;
  */
 public enum NoticeStatus {
 
-	/**
-	 * 草稿
-	 */
-	DRAFT,
+    /**
+     * 草稿
+     */
+    DRAFT,
 
-	/**
-	 * 待发布
-	 */
-	TO_BE_PUBLISHED,
-	/**
-	 * 发布中
-	 */
-	PUBLISHING,
-	/**
-	 * 已发布
-	 */
-	PUBLISHED,
-	/**
-	 * 已撤回
-	 */
-	RECALLED
+    /**
+     * 待发布
+     */
+    TO_BE_PUBLISHED,
+    /**
+     * 发布中
+     */
+    PUBLISHING,
+    /**
+     * 已发布
+     */
+    PUBLISHED,
+    /**
+     * 已撤回
+     */
+    RECALLED
 
 }

+ 16 - 16
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/PrivilegeGroupType.java

@@ -9,24 +9,24 @@ package cn.com.qmth.examcloud.api.commons.enums;
  */
 public enum PrivilegeGroupType {
 
-	/**
-	 * 菜单
-	 */
-	ADMIN_MENU,
+    /**
+     * 菜单
+     */
+    ADMIN_MENU,
 
-	/**
-	 * 功能
-	 */
-	FUNCTION,
+    /**
+     * 功能
+     */
+    FUNCTION,
 
-	/**
-	 * 数据权限
-	 */
-	DATA_ACCESS,
+    /**
+     * 数据权限
+     */
+    DATA_ACCESS,
 
-	/**
-	 * 学生端菜单
-	 */
-	STUDENT_CLIENT_MENU
+    /**
+     * 学生端菜单
+     */
+    STUDENT_CLIENT_MENU
 
 }

+ 8 - 8
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/enums/SubmitType.java

@@ -7,13 +7,13 @@ package cn.com.qmth.examcloud.api.commons.enums;
  * @Version 1.0
  */
 public enum SubmitType {
-	/**
-	 * 定点收卷
-	 */
-	TIMING_END,
+    /**
+     * 定点收卷
+     */
+    TIMING_END,
 
-	/**
-	 * 正常收卷
-	 */
-	NORMAL
+    /**
+     * 正常收卷
+     */
+    NORMAL
 }

+ 2 - 3
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/BaseRequest.java

@@ -2,12 +2,11 @@ package cn.com.qmth.examcloud.api.commons.exchange;
 
 /**
  * 请求体基类
- * 
- * @author WANGWEI
  *
+ * @author WANGWEI
  */
 public abstract class BaseRequest extends ExchangeBean {
 
-	private static final long serialVersionUID = 6465330136225230063L;
+    private static final long serialVersionUID = 6465330136225230063L;
 
 }

+ 13 - 14
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/BaseResponse.java

@@ -4,26 +4,25 @@ import io.swagger.annotations.ApiModelProperty;
 
 /**
  * 响应体基类
- * 
- * @author WANGWEI
  *
+ * @author WANGWEI
  */
 public abstract class BaseResponse extends ExchangeBean {
 
-	private static final long serialVersionUID = 1755304211766414171L;
+    private static final long serialVersionUID = 1755304211766414171L;
 
-	/**
-	 * 耗时(毫秒)
-	 */
-	@ApiModelProperty(value = "耗时(毫秒)", example = "500", required = true)
-	private Long cost;
+    /**
+     * 耗时(毫秒)
+     */
+    @ApiModelProperty(value = "耗时(毫秒)", example = "500", required = true)
+    private Long cost;
 
-	public Long getCost() {
-		return cost;
-	}
+    public Long getCost() {
+        return cost;
+    }
 
-	public void setCost(Long cost) {
-		this.cost = cost;
-	}
+    public void setCost(Long cost) {
+        this.cost = cost;
+    }
 
 }

+ 12 - 12
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/EnterpriseRequest.java

@@ -4,20 +4,20 @@ import io.swagger.annotations.ApiModelProperty;
 
 public class EnterpriseRequest extends BaseRequest {
 
-	private static final long serialVersionUID = -7805477355173448066L;
+    private static final long serialVersionUID = -7805477355173448066L;
 
-	@Deprecated
-	@ApiModelProperty(value = "废弃字段", example = "", required = false)
-	private String des;
+    @Deprecated
+    @ApiModelProperty(value = "废弃字段", example = "", required = false)
+    private String des;
 
-	@Deprecated
-	public String getDes() {
-		return des;
-	}
+    @Deprecated
+    public String getDes() {
+        return des;
+    }
 
-	@Deprecated
-	public void setDes(String des) {
-		this.des = des;
-	}
+    @Deprecated
+    public void setDes(String des) {
+        this.des = des;
+    }
 
 }

+ 12 - 12
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/EnterpriseResponse.java

@@ -4,20 +4,20 @@ import io.swagger.annotations.ApiModelProperty;
 
 public class EnterpriseResponse extends BaseResponse {
 
-	private static final long serialVersionUID = 1317937489317321732L;
+    private static final long serialVersionUID = 1317937489317321732L;
 
-	@Deprecated
-	@ApiModelProperty(value = "废弃字段", example = "", required = false)
-	private String des;
+    @Deprecated
+    @ApiModelProperty(value = "废弃字段", example = "", required = false)
+    private String des;
 
-	@Deprecated
-	public String getDes() {
-		return des;
-	}
+    @Deprecated
+    public String getDes() {
+        return des;
+    }
 
-	@Deprecated
-	public void setDes(String des) {
-		this.des = des;
-	}
+    @Deprecated
+    public void setDes(String des) {
+        this.des = des;
+    }
 
 }

+ 2 - 3
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/ExchangeBean.java

@@ -2,12 +2,11 @@ package cn.com.qmth.examcloud.api.commons.exchange;
 
 /**
  * bean 基类
- * 
- * @author WANGWEI
  *
+ * @author WANGWEI
  */
 public abstract class ExchangeBean implements JsonSerializable {
 
-	private static final long serialVersionUID = 3913250969569367810L;
+    private static final long serialVersionUID = 3913250969569367810L;
 
 }

+ 43 - 43
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/FormFilePart.java

@@ -11,48 +11,48 @@ import java.io.File;
  */
 public class FormFilePart {
 
-	private String paramName;
-
-	private String filename;
-
-	private File file;
-
-	/**
-	 * 构造函数
-	 *
-	 * @param paramName
-	 * @param filename
-	 * @param file
-	 */
-	public FormFilePart(String paramName, String filename, File file) {
-		super();
-		this.paramName = paramName;
-		this.filename = filename;
-		this.file = file;
-	}
-
-	public String getParamName() {
-		return paramName;
-	}
-
-	public void setParamName(String paramName) {
-		this.paramName = paramName;
-	}
-
-	public String getFilename() {
-		return filename;
-	}
-
-	public void setFilename(String filename) {
-		this.filename = filename;
-	}
-
-	public File getFile() {
-		return file;
-	}
-
-	public void setFile(File file) {
-		this.file = file;
-	}
+    private String paramName;
+
+    private String filename;
+
+    private File file;
+
+    /**
+     * 构造函数
+     *
+     * @param paramName
+     * @param filename
+     * @param file
+     */
+    public FormFilePart(String paramName, String filename, File file) {
+        super();
+        this.paramName = paramName;
+        this.filename = filename;
+        this.file = file;
+    }
+
+    public String getParamName() {
+        return paramName;
+    }
+
+    public void setParamName(String paramName) {
+        this.paramName = paramName;
+    }
+
+    public String getFilename() {
+        return filename;
+    }
+
+    public void setFilename(String filename) {
+        this.filename = filename;
+    }
+
+    public File getFile() {
+        return file;
+    }
+
+    public void setFile(File file) {
+        this.file = file;
+    }
 
 }

+ 11 - 11
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/FormRequest.java

@@ -1,9 +1,9 @@
 package cn.com.qmth.examcloud.api.commons.exchange;
 
-import java.util.List;
-
 import io.swagger.annotations.ApiModelProperty;
 
+import java.util.List;
+
 /**
  * 表单请求
  *
@@ -13,17 +13,17 @@ import io.swagger.annotations.ApiModelProperty;
  */
 public class FormRequest extends BaseRequest {
 
-	private static final long serialVersionUID = 1201394717322230917L;
+    private static final long serialVersionUID = 1201394717322230917L;
 
-	@ApiModelProperty(value = "文件参数集合", required = false)
-	private transient List<FormFilePart> formFilePartList;
+    @ApiModelProperty(value = "文件参数集合", required = false)
+    private transient List<FormFilePart> formFilePartList;
 
-	public List<FormFilePart> getFormFilePartList() {
-		return formFilePartList;
-	}
+    public List<FormFilePart> getFormFilePartList() {
+        return formFilePartList;
+    }
 
-	public void setFormFilePartList(List<FormFilePart> formFilePartList) {
-		this.formFilePartList = formFilePartList;
-	}
+    public void setFormFilePartList(List<FormFilePart> formFilePartList) {
+        this.formFilePartList = formFilePartList;
+    }
 
 }

+ 1 - 2
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/JsonSerializable.java

@@ -7,9 +7,8 @@ import java.io.Serializable;
  * <p>
  * 严重警告: 此接口为标识接口,禁止添加属性和方法. by wangwei
  * </p>
- * 
- * @author WANGWEI
  *
+ * @author WANGWEI
  */
 public interface JsonSerializable extends Serializable {
 

+ 121 - 121
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/exchange/PageInfo.java

@@ -1,136 +1,136 @@
 package cn.com.qmth.examcloud.api.commons.exchange;
 
+import org.springframework.data.domain.Page;
+
 import java.io.Serializable;
 import java.util.List;
 
-import org.springframework.data.domain.Page;
-
 /**
  * 分页
  *
+ * @param <T>
  * @author WANGWEI
  * @date 2018年6月25日
  * @Copyright (c) 2018-? http://qmth.com.cn All Rights Reserved.
- * @param <T>
  */
 public class PageInfo<T> implements Serializable {
-	private static final long serialVersionUID = 1L;
-
-	/**
-	 * 当前页码
-	 */
-	private long index = 1;
-
-	/**
-	 * 每页的数量限制
-	 */
-	private long limit = 10;
-
-	/**
-	 * 当前页的数量
-	 */
-	private long size;
-
-	/**
-	 * 总记录数
-	 */
-	private long total;
-
-	/**
-	 * 总页数
-	 */
-	private long pages;
-
-	/**
-	 * 结果集
-	 */
-	private List<T> list;
-
-	/**
-	 * 构造函数
-	 *
-	 */
-	public PageInfo() {
-
-	}
-
-	/**
-	 * 构造函数
-	 *
-	 * @param page
-	 */
-	public PageInfo(Page<T> page) {
-		this.total = page.getTotalElements();
-		this.pages = page.getTotalPages();
-		this.index = page.getNumber();
-		this.size = page.getNumberOfElements();
-		this.limit = page.getSize();
-
-		this.list = page.getContent();
-	}
-
-	/**
-	 * 构造函数
-	 *
-	 * @param page
-	 * @param list
-	 */
-	public PageInfo(Page<?> page, List<T> list) {
-		this.total = page.getTotalElements();
-		this.pages = page.getTotalPages();
-		this.index = page.getNumber();
-		this.size = page.getNumberOfElements();
-		this.limit = page.getSize();
-
-		this.list = list;
-	}
-
-	public long getIndex() {
-		return index;
-	}
-
-	public void setIndex(long index) {
-		this.index = index;
-	}
-
-	public long getLimit() {
-		return limit;
-	}
-
-	public void setLimit(long limit) {
-		this.limit = limit;
-	}
-
-	public long getSize() {
-		return size;
-	}
-
-	public void setSize(long size) {
-		this.size = size;
-	}
-
-	public long getTotal() {
-		return total;
-	}
-
-	public void setTotal(long total) {
-		this.total = total;
-	}
-
-	public long getPages() {
-		return pages;
-	}
-
-	public void setPages(long pages) {
-		this.pages = pages;
-	}
-
-	public List<T> getList() {
-		return list;
-	}
-
-	public void setList(List<T> list) {
-		this.list = list;
-	}
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 当前页码
+     */
+    private long index = 1;
+
+    /**
+     * 每页的数量限制
+     */
+    private long limit = 10;
+
+    /**
+     * 当前页的数量
+     */
+    private long size;
+
+    /**
+     * 总记录数
+     */
+    private long total;
+
+    /**
+     * 总页数
+     */
+    private long pages;
+
+    /**
+     * 结果集
+     */
+    private List<T> list;
+
+    /**
+     * 构造函数
+     */
+    public PageInfo() {
+
+    }
+
+    /**
+     * 构造函数
+     *
+     * @param page
+     */
+    public PageInfo(Page<T> page) {
+        this.total = page.getTotalElements();
+        this.pages = page.getTotalPages();
+        this.index = page.getNumber();
+        this.size = page.getNumberOfElements();
+        this.limit = page.getSize();
+
+        this.list = page.getContent();
+    }
+
+    /**
+     * 构造函数
+     *
+     * @param page
+     * @param list
+     */
+    public PageInfo(Page<?> page, List<T> list) {
+        this.total = page.getTotalElements();
+        this.pages = page.getTotalPages();
+        this.index = page.getNumber();
+        this.size = page.getNumberOfElements();
+        this.limit = page.getSize();
+
+        this.list = list;
+    }
+
+    public long getIndex() {
+        return index;
+    }
+
+    public void setIndex(long index) {
+        this.index = index;
+    }
+
+    public long getLimit() {
+        return limit;
+    }
+
+    public void setLimit(long limit) {
+        this.limit = limit;
+    }
+
+    public long getSize() {
+        return size;
+    }
+
+    public void setSize(long size) {
+        this.size = size;
+    }
+
+    public long getTotal() {
+        return total;
+    }
+
+    public void setTotal(long total) {
+        this.total = total;
+    }
+
+    public long getPages() {
+        return pages;
+    }
+
+    public void setPages(long pages) {
+        this.pages = pages;
+    }
+
+    public List<T> getList() {
+        return list;
+    }
+
+    public void setList(List<T> list) {
+        this.list = list;
+    }
 
 }

+ 36 - 36
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/security/bean/AccessApp.java

@@ -11,56 +11,56 @@ import cn.com.qmth.examcloud.api.commons.exchange.JsonSerializable;
  */
 public class AccessApp implements JsonSerializable {
 
-	private static final long serialVersionUID = 9193428318438074444L;
+    private static final long serialVersionUID = 9193428318438074444L;
 
-	private Long appId;
+    private Long appId;
 
-	private String appName;
+    private String appName;
 
-	private String appCode;
+    private String appCode;
 
-	private String secretKey;
+    private String secretKey;
 
-	private Long timeRange;
+    private Long timeRange;
 
-	public Long getAppId() {
-		return appId;
-	}
+    public Long getAppId() {
+        return appId;
+    }
 
-	public void setAppId(Long appId) {
-		this.appId = appId;
-	}
+    public void setAppId(Long appId) {
+        this.appId = appId;
+    }
 
-	public String getAppName() {
-		return appName;
-	}
+    public String getAppName() {
+        return appName;
+    }
 
-	public void setAppName(String appName) {
-		this.appName = appName;
-	}
+    public void setAppName(String appName) {
+        this.appName = appName;
+    }
 
-	public String getAppCode() {
-		return appCode;
-	}
+    public String getAppCode() {
+        return appCode;
+    }
 
-	public void setAppCode(String appCode) {
-		this.appCode = appCode;
-	}
+    public void setAppCode(String appCode) {
+        this.appCode = appCode;
+    }
 
-	public String getSecretKey() {
-		return secretKey;
-	}
+    public String getSecretKey() {
+        return secretKey;
+    }
 
-	public void setSecretKey(String secretKey) {
-		this.secretKey = secretKey;
-	}
+    public void setSecretKey(String secretKey) {
+        this.secretKey = secretKey;
+    }
 
-	public Long getTimeRange() {
-		return timeRange;
-	}
+    public Long getTimeRange() {
+        return timeRange;
+    }
 
-	public void setTimeRange(Long timeRange) {
-		this.timeRange = timeRange;
-	}
+    public void setTimeRange(Long timeRange) {
+        this.timeRange = timeRange;
+    }
 
 }

+ 50 - 51
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/security/bean/Role.java

@@ -9,56 +9,55 @@ package cn.com.qmth.examcloud.api.commons.security.bean;
  */
 public class Role {
 
-	private Long roleId;
-
-	private String roleCode;
-
-	private String roleName;
-
-	/**
-	 * 构造函数
-	 *
-	 */
-	public Role() {
-		super();
-	}
-
-	/**
-	 * 构造函数
-	 *
-	 * @param roleId
-	 * @param roleCode
-	 * @param roleName
-	 */
-	public Role(Long roleId, String roleCode, String roleName) {
-		super();
-		this.roleId = roleId;
-		this.roleCode = roleCode;
-		this.roleName = roleName;
-	}
-
-	public Long getRoleId() {
-		return roleId;
-	}
-
-	public void setRoleId(Long roleId) {
-		this.roleId = roleId;
-	}
-
-	public String getRoleCode() {
-		return roleCode;
-	}
-
-	public void setRoleCode(String roleCode) {
-		this.roleCode = roleCode;
-	}
-
-	public String getRoleName() {
-		return roleName;
-	}
-
-	public void setRoleName(String roleName) {
-		this.roleName = roleName;
-	}
+    private Long roleId;
+
+    private String roleCode;
+
+    private String roleName;
+
+    /**
+     * 构造函数
+     */
+    public Role() {
+        super();
+    }
+
+    /**
+     * 构造函数
+     *
+     * @param roleId
+     * @param roleCode
+     * @param roleName
+     */
+    public Role(Long roleId, String roleCode, String roleName) {
+        super();
+        this.roleId = roleId;
+        this.roleCode = roleCode;
+        this.roleName = roleName;
+    }
+
+    public Long getRoleId() {
+        return roleId;
+    }
+
+    public void setRoleId(Long roleId) {
+        this.roleId = roleId;
+    }
+
+    public String getRoleCode() {
+        return roleCode;
+    }
+
+    public void setRoleCode(String roleCode) {
+        this.roleCode = roleCode;
+    }
+
+    public String getRoleName() {
+        return roleName;
+    }
+
+    public void setRoleName(String roleName) {
+        this.roleName = roleName;
+    }
 
 }

+ 46 - 46
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/security/bean/UserType.java

@@ -9,51 +9,51 @@ package cn.com.qmth.examcloud.api.commons.security.bean;
  */
 public enum UserType {
 
-	/**
-	 * 学生
-	 */
-	STUDENT("S", "学生"),
-
-	/**
-	 * 常规用户
-	 */
-	COMMON("C", "常规用户");
-
-	// ===========================================================================
-
-	/**
-	 * 码
-	 */
-	private String code;
-
-	/**
-	 * 描述
-	 */
-	private String desc;
-
-	/**
-	 * 构造函数
-	 *
-	 * @param code
-	 * @param desc
-	 */
-	private UserType(String code, String desc) {
-		this.code = code;
-		this.desc = desc;
-	}
-
-	/**
-	 * @return the code
-	 */
-	public String getCode() {
-		return code;
-	}
-
-	/**
-	 * @return the desc
-	 */
-	public String getDesc() {
-		return desc;
-	}
+    /**
+     * 学生
+     */
+    STUDENT("S", "学生"),
+
+    /**
+     * 常规用户
+     */
+    COMMON("C", "常规用户");
+
+    // ===========================================================================
+
+    /**
+     * 码
+     */
+    private String code;
+
+    /**
+     * 描述
+     */
+    private String desc;
+
+    /**
+     * 构造函数
+     *
+     * @param code
+     * @param desc
+     */
+    private UserType(String code, String desc) {
+        this.code = code;
+        this.desc = desc;
+    }
+
+    /**
+     * @return the code
+     */
+    public String getCode() {
+        return code;
+    }
+
+    /**
+     * @return the desc
+     */
+    public String getDesc() {
+        return desc;
+    }
 
 }

+ 66 - 66
examcloud-api-commons/src/main/java/cn/com/qmth/examcloud/api/commons/security/bean/WebSocketSession.java

@@ -11,71 +11,71 @@ import cn.com.qmth.examcloud.api.commons.exchange.JsonSerializable;
  */
 public class WebSocketSession implements JsonSerializable {
 
-	private static final long serialVersionUID = 6657113738382557514L;
-
-	/**
-	 * session ID
-	 */
-	private String sessionId;
-
-	/**
-	 * 全局唯一用户标识符
-	 */
-	private String key;
-
-	/**
-	 * 鉴权token
-	 */
-	private String token;
-
-	/**
-	 * 应用名称
-	 */
-	private String appName;
-
-	/**
-	 * 会话失效时长
-	 */
-	private Integer sessionTimeout;
-
-	public String getSessionId() {
-		return sessionId;
-	}
-
-	public void setSessionId(String sessionId) {
-		this.sessionId = sessionId;
-	}
-
-	public String getKey() {
-		return key;
-	}
-
-	public void setKey(String key) {
-		this.key = key;
-	}
-
-	public String getToken() {
-		return token;
-	}
-
-	public void setToken(String token) {
-		this.token = token;
-	}
-
-	public String getAppName() {
-		return appName;
-	}
-
-	public void setAppName(String appName) {
-		this.appName = appName;
-	}
-
-	public Integer getSessionTimeout() {
-		return sessionTimeout;
-	}
-
-	public void setSessionTimeout(Integer sessionTimeout) {
-		this.sessionTimeout = sessionTimeout;
-	}
+    private static final long serialVersionUID = 6657113738382557514L;
+
+    /**
+     * session ID
+     */
+    private String sessionId;
+
+    /**
+     * 全局唯一用户标识符
+     */
+    private String key;
+
+    /**
+     * 鉴权token
+     */
+    private String token;
+
+    /**
+     * 应用名称
+     */
+    private String appName;
+
+    /**
+     * 会话失效时长
+     */
+    private Integer sessionTimeout;
+
+    public String getSessionId() {
+        return sessionId;
+    }
+
+    public void setSessionId(String sessionId) {
+        this.sessionId = sessionId;
+    }
+
+    public String getKey() {
+        return key;
+    }
+
+    public void setKey(String key) {
+        this.key = key;
+    }
+
+    public String getToken() {
+        return token;
+    }
+
+    public void setToken(String token) {
+        this.token = token;
+    }
+
+    public String getAppName() {
+        return appName;
+    }
+
+    public void setAppName(String appName) {
+        this.appName = appName;
+    }
+
+    public Integer getSessionTimeout() {
+        return sessionTimeout;
+    }
+
+    public void setSessionTimeout(Integer sessionTimeout) {
+        this.sessionTimeout = sessionTimeout;
+    }
 
 }

+ 56 - 44
examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/bean/AdminOperateReport.java

@@ -4,49 +4,61 @@ import cn.com.qmth.examcloud.reports.commons.enums.Tag;
 import cn.com.qmth.examcloud.reports.commons.enums.Topic;
 
 public class AdminOperateReport extends BaseReport {
-	private Long operateUserId;
-	private String operate;
-	private String operateInfo;
-	private Long rootOrgId;
-
-
-	public AdminOperateReport(Long rootOrgId,Long operateUserId,String operate,String operateInfo) {
-		super();
-		this.rootOrgId = rootOrgId;
-		this.operateUserId = operateUserId;
-		this.operate = operate;
-		this.operateInfo=operateInfo;
-		this.topic = Topic.REPORT_TOPIC.getCode();
-		this.tag = Tag.ADMIN_OPERATE_INFO.getCode();
-	}
-	public AdminOperateReport() {
-		super();
-	}
-	public Long getOperateUserId() {
-		return operateUserId;
-	}
-	public void setOperateUserId(Long operateUserId) {
-		this.operateUserId = operateUserId;
-	}
-	public String getOperate() {
-		return operate;
-	}
-	public void setOperate(String operate) {
-		this.operate = operate;
-	}
-	public Long getRootOrgId() {
-		return rootOrgId;
-	}
-	public void setRootOrgId(Long rootOrgId) {
-		this.rootOrgId = rootOrgId;
-	}
-	public String getOperateInfo() {
-		return operateInfo;
-	}
-	public void setOperateInfo(String operateInfo) {
-		this.operateInfo = operateInfo;
-	}
-
-	
+
+    private Long operateUserId;
+
+    private String operate;
+
+    private String operateInfo;
+
+    private Long rootOrgId;
+
+
+    public AdminOperateReport(Long rootOrgId, Long operateUserId, String operate, String operateInfo) {
+        super();
+        this.rootOrgId = rootOrgId;
+        this.operateUserId = operateUserId;
+        this.operate = operate;
+        this.operateInfo = operateInfo;
+        this.topic = Topic.REPORT_TOPIC.getCode();
+        this.tag = Tag.ADMIN_OPERATE_INFO.getCode();
+    }
+
+    public AdminOperateReport() {
+        super();
+    }
+
+    public Long getOperateUserId() {
+        return operateUserId;
+    }
+
+    public void setOperateUserId(Long operateUserId) {
+        this.operateUserId = operateUserId;
+    }
+
+    public String getOperate() {
+        return operate;
+    }
+
+    public void setOperate(String operate) {
+        this.operate = operate;
+    }
+
+    public Long getRootOrgId() {
+        return rootOrgId;
+    }
+
+    public void setRootOrgId(Long rootOrgId) {
+        this.rootOrgId = rootOrgId;
+    }
+
+    public String getOperateInfo() {
+        return operateInfo;
+    }
+
+    public void setOperateInfo(String operateInfo) {
+        this.operateInfo = operateInfo;
+    }
+
 
 }

+ 56 - 50
examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/bean/BaseReport.java

@@ -3,55 +3,61 @@ package cn.com.qmth.examcloud.reports.commons.bean;
 import java.util.Date;
 
 public class BaseReport {
-	protected String topic;
-	protected String tag;
-	private Boolean reportOnException = false;
-	private Date reportTime;
-	private String reportHost;
-	private String remoteHost;
-
-	public Date getReportTime() {
-		return reportTime;
-	}
-
-	public void setReportTime(Date reportTime) {
-		this.reportTime = reportTime;
-	}
-
-	public String getReportHost() {
-		return reportHost;
-	}
-
-	public void setReportHost(String reportHost) {
-		this.reportHost = reportHost;
-	}
-
-	public Boolean getReportOnException() {
-		return reportOnException;
-	}
-
-	public void setReportOnException(Boolean reportOnException) {
-		this.reportOnException = reportOnException;
-	}
-
-	public String getTopic() {
-		return topic;
-	}
-
-	public String getTag() {
-		return tag;
-	}
-
-	public String getRemoteHost() {
-		return remoteHost;
-	}
-
-	public void setRemoteHost(String remoteHost) {
-		this.remoteHost = remoteHost;
-	}
-
-	public BaseReport() {
-		super();
-	}
+
+    protected String topic;
+
+    protected String tag;
+
+    private Boolean reportOnException = false;
+
+    private Date reportTime;
+
+    private String reportHost;
+
+    private String remoteHost;
+
+    public Date getReportTime() {
+        return reportTime;
+    }
+
+    public void setReportTime(Date reportTime) {
+        this.reportTime = reportTime;
+    }
+
+    public String getReportHost() {
+        return reportHost;
+    }
+
+    public void setReportHost(String reportHost) {
+        this.reportHost = reportHost;
+    }
+
+    public Boolean getReportOnException() {
+        return reportOnException;
+    }
+
+    public void setReportOnException(Boolean reportOnException) {
+        this.reportOnException = reportOnException;
+    }
+
+    public String getTopic() {
+        return topic;
+    }
+
+    public String getTag() {
+        return tag;
+    }
+
+    public String getRemoteHost() {
+        return remoteHost;
+    }
+
+    public void setRemoteHost(String remoteHost) {
+        this.remoteHost = remoteHost;
+    }
+
+    public BaseReport() {
+        super();
+    }
 
 }

+ 53 - 48
examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/bean/OnlineExamStudentReport.java

@@ -5,53 +5,58 @@ import cn.com.qmth.examcloud.reports.commons.enums.Topic;
 
 public class OnlineExamStudentReport extends BaseReport {
 
-	private Long rootOrgId;
-	private Long studentId;
-	private Long examId;
-	private Long examStudentId;
-
-	public Long getRootOrgId() {
-		return rootOrgId;
-	}
-
-	public void setRootOrgId(Long rootOrgId) {
-		this.rootOrgId = rootOrgId;
-	}
-
-	public Long getStudentId() {
-		return studentId;
-	}
-
-	public void setStudentId(Long studentId) {
-		this.studentId = studentId;
-	}
-
-	public Long getExamId() {
-		return examId;
-	}
-
-	public void setExamId(Long examId) {
-		this.examId = examId;
-	}
-
-	public Long getExamStudentId() {
-		return examStudentId;
-	}
-
-	public void setExamStudentId(Long examStudentId) {
-		this.examStudentId = examStudentId;
-	}
-	public OnlineExamStudentReport() {
-		super();
-	}
-	public OnlineExamStudentReport(Long rootOrgId, Long studentId, Long examId, Long examStudentId) {
-		super();
-		this.rootOrgId = rootOrgId;
-		this.studentId = studentId;
-		this.examId = examId;
-		this.examStudentId = examStudentId;
-		this.topic = Topic.REPORT_TOPIC.getCode();
-		this.tag = Tag.ONLINE_EXAM_STUDENT.getCode();
-	}
+    private Long rootOrgId;
+
+    private Long studentId;
+
+    private Long examId;
+
+    private Long examStudentId;
+
+    public Long getRootOrgId() {
+        return rootOrgId;
+    }
+
+    public void setRootOrgId(Long rootOrgId) {
+        this.rootOrgId = rootOrgId;
+    }
+
+    public Long getStudentId() {
+        return studentId;
+    }
+
+    public void setStudentId(Long studentId) {
+        this.studentId = studentId;
+    }
+
+    public Long getExamId() {
+        return examId;
+    }
+
+    public void setExamId(Long examId) {
+        this.examId = examId;
+    }
+
+    public Long getExamStudentId() {
+        return examStudentId;
+    }
+
+    public void setExamStudentId(Long examStudentId) {
+        this.examStudentId = examStudentId;
+    }
+
+    public OnlineExamStudentReport() {
+        super();
+    }
+
+    public OnlineExamStudentReport(Long rootOrgId, Long studentId, Long examId, Long examStudentId) {
+        super();
+        this.rootOrgId = rootOrgId;
+        this.studentId = studentId;
+        this.examId = examId;
+        this.examStudentId = examStudentId;
+        this.topic = Topic.REPORT_TOPIC.getCode();
+        this.tag = Tag.ONLINE_EXAM_STUDENT.getCode();
+    }
 
 }

+ 32 - 29
examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/bean/OnlineStudentReport.java

@@ -4,34 +4,37 @@ import cn.com.qmth.examcloud.reports.commons.enums.Tag;
 import cn.com.qmth.examcloud.reports.commons.enums.Topic;
 
 public class OnlineStudentReport extends BaseReport {
-	private Long rootOrgId;
-	private Long studentId;
-
-	public Long getRootOrgId() {
-		return rootOrgId;
-	}
-
-	public void setRootOrgId(Long rootOrgId) {
-		this.rootOrgId = rootOrgId;
-	}
-
-	public Long getStudentId() {
-		return studentId;
-	}
-
-	public void setStudentId(Long studentId) {
-		this.studentId = studentId;
-	}
-
-	public OnlineStudentReport() {
-		super();
-	}
-	public OnlineStudentReport(Long rootOrgId, Long studentId) {
-		super();
-		this.rootOrgId = rootOrgId;
-		this.studentId = studentId;
-		this.topic = Topic.REPORT_TOPIC.getCode();
-		this.tag = Tag.ONLINE_STUDENT.getCode();
-	}
+
+    private Long rootOrgId;
+
+    private Long studentId;
+
+    public Long getRootOrgId() {
+        return rootOrgId;
+    }
+
+    public void setRootOrgId(Long rootOrgId) {
+        this.rootOrgId = rootOrgId;
+    }
+
+    public Long getStudentId() {
+        return studentId;
+    }
+
+    public void setStudentId(Long studentId) {
+        this.studentId = studentId;
+    }
+
+    public OnlineStudentReport() {
+        super();
+    }
+
+    public OnlineStudentReport(Long rootOrgId, Long studentId) {
+        super();
+        this.rootOrgId = rootOrgId;
+        this.studentId = studentId;
+        this.topic = Topic.REPORT_TOPIC.getCode();
+        this.tag = Tag.ONLINE_STUDENT.getCode();
+    }
 
 }

+ 32 - 29
examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/bean/OnlineUserReport.java

@@ -4,34 +4,37 @@ import cn.com.qmth.examcloud.reports.commons.enums.Tag;
 import cn.com.qmth.examcloud.reports.commons.enums.Topic;
 
 public class OnlineUserReport extends BaseReport {
-	private Long rootOrgId;
-	private Long userId;
-
-	public OnlineUserReport() {
-		super();
-	}
-	public Long getRootOrgId() {
-		return rootOrgId;
-	}
-
-	public void setRootOrgId(Long rootOrgId) {
-		this.rootOrgId = rootOrgId;
-	}
-
-	public Long getUserId() {
-		return userId;
-	}
-
-	public void setUserId(Long userId) {
-		this.userId = userId;
-	}
-
-	public OnlineUserReport(Long rootOrgId, Long userId) {
-		super();
-		this.rootOrgId = rootOrgId;
-		this.userId = userId;
-		this.topic = Topic.REPORT_TOPIC.getCode();
-		this.tag = Tag.ONLINE_USER.getCode();
-	}
+
+    private Long rootOrgId;
+
+    private Long userId;
+
+    public OnlineUserReport() {
+        super();
+    }
+
+    public Long getRootOrgId() {
+        return rootOrgId;
+    }
+
+    public void setRootOrgId(Long rootOrgId) {
+        this.rootOrgId = rootOrgId;
+    }
+
+    public Long getUserId() {
+        return userId;
+    }
+
+    public void setUserId(Long userId) {
+        this.userId = userId;
+    }
+
+    public OnlineUserReport(Long rootOrgId, Long userId) {
+        super();
+        this.rootOrgId = rootOrgId;
+        this.userId = userId;
+        this.topic = Topic.REPORT_TOPIC.getCode();
+        this.tag = Tag.ONLINE_USER.getCode();
+    }
 
 }

+ 63 - 56
examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/bean/OperateReport.java

@@ -5,87 +5,94 @@ import cn.com.qmth.examcloud.reports.commons.enums.Tag;
 import cn.com.qmth.examcloud.reports.commons.enums.Topic;
 
 public class OperateReport extends BaseReport {
-	private Long operateUserId;
-	private Long examStudentId;
-	private Long studentId;
-	private UserType operateUserType;
-	private String operate;
-	private Long rootOrgId;
 
+    private Long operateUserId;
 
-	public OperateReport(Long rootOrgId,Long operateUserId,Long studentId,Long examStudentId, UserType operateClient,String operate) {
-		super();
-		this.rootOrgId = rootOrgId;
-		this.operateUserId = operateUserId;
-		this.studentId = studentId;
-		this.examStudentId=examStudentId;
-		this.operateUserType = operateClient;
-		this.operate = operate;
-		this.topic = Topic.REPORT_TOPIC.getCode();
-		this.tag = Tag.OPERATE_INFO.getCode();
-	}
-	public OperateReport() {
-		super();
-	}
-	public Long getOperateUserId() {
-		return operateUserId;
-	}
+    private Long examStudentId;
 
+    private Long studentId;
 
-	public void setOperateUserId(Long operateUserId) {
-		this.operateUserId = operateUserId;
-	}
+    private UserType operateUserType;
 
+    private String operate;
 
-	public Long getStudentId() {
-		return studentId;
-	}
+    private Long rootOrgId;
 
 
-	public void setStudentId(Long studentId) {
-		this.studentId = studentId;
-	}
+    public OperateReport(Long rootOrgId, Long operateUserId, Long studentId, Long examStudentId, UserType operateClient, String operate) {
+        super();
+        this.rootOrgId = rootOrgId;
+        this.operateUserId = operateUserId;
+        this.studentId = studentId;
+        this.examStudentId = examStudentId;
+        this.operateUserType = operateClient;
+        this.operate = operate;
+        this.topic = Topic.REPORT_TOPIC.getCode();
+        this.tag = Tag.OPERATE_INFO.getCode();
+    }
 
+    public OperateReport() {
+        super();
+    }
 
+    public Long getOperateUserId() {
+        return operateUserId;
+    }
 
-	public UserType getOperateUserType() {
-		return operateUserType;
-	}
 
+    public void setOperateUserId(Long operateUserId) {
+        this.operateUserId = operateUserId;
+    }
 
-	public void setOperateUserType(UserType operateUserType) {
-		this.operateUserType = operateUserType;
-	}
 
+    public Long getStudentId() {
+        return studentId;
+    }
 
-	public String getOperate() {
-		return operate;
-	}
 
+    public void setStudentId(Long studentId) {
+        this.studentId = studentId;
+    }
 
-	public void setOperate(String operate) {
-		this.operate = operate;
-	}
 
+    public UserType getOperateUserType() {
+        return operateUserType;
+    }
 
-	public Long getRootOrgId() {
-		return rootOrgId;
-	}
 
+    public void setOperateUserType(UserType operateUserType) {
+        this.operateUserType = operateUserType;
+    }
 
-	public void setRootOrgId(Long rootOrgId) {
-		this.rootOrgId = rootOrgId;
-	}
 
+    public String getOperate() {
+        return operate;
+    }
 
-	public Long getExamStudentId() {
-		return examStudentId;
-	}
 
+    public void setOperate(String operate) {
+        this.operate = operate;
+    }
 
-	public void setExamStudentId(Long examStudentId) {
-		this.examStudentId = examStudentId;
-	}
+
+    public Long getRootOrgId() {
+        return rootOrgId;
+    }
+
+
+    public void setRootOrgId(Long rootOrgId) {
+        this.rootOrgId = rootOrgId;
+    }
+
+
+    public Long getExamStudentId() {
+        return examStudentId;
+    }
+
+
+    public void setExamStudentId(Long examStudentId) {
+        this.examStudentId = examStudentId;
+    }
 
 
 }

+ 27 - 27
examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/enums/MqType.java

@@ -1,37 +1,37 @@
 package cn.com.qmth.examcloud.reports.commons.enums;
 
 public enum MqType {
-	KAFKA("kafka", "kafka"),
-	ROCKETMQ("rocketmq", "rocketmq"),
-	;
+    KAFKA("kafka", "kafka"),
+    ROCKETMQ("rocketmq", "rocketmq"),
+    ;
 
-	// ===========================================================================
+    // ===========================================================================
 
-	/**
-	 * 码
-	 */
-	private String code;
+    /**
+     * 码
+     */
+    private String code;
 
-	/**
-	 * 描述
-	 */
-	private String desc;
+    /**
+     * 描述
+     */
+    private String desc;
 
-	/**
-	 * 构造函数
-	 *
-	 * @param desc
-	 */
-	private MqType(String code, String desc) {
-		this.code = code;
-		this.desc = desc;
-	}
+    /**
+     * 构造函数
+     *
+     * @param desc
+     */
+    private MqType(String code, String desc) {
+        this.code = code;
+        this.desc = desc;
+    }
 
-	public String getDesc() {
-		return desc;
-	}
+    public String getDesc() {
+        return desc;
+    }
 
-	public String getCode() {
-		return code;
-	}
+    public String getCode() {
+        return code;
+    }
 }

+ 30 - 31
examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/enums/OperateContent.java

@@ -2,42 +2,41 @@ package cn.com.qmth.examcloud.reports.commons.enums;
 
 /**
  * 操作内容
- * 
- * @author chenken
  *
+ * @author chenken
  */
 public enum OperateContent {
 
-	EXAM_STUDENT_ADD("考生新增"), 
-	EXAM_STUDENT_COPY("考生复制"), 
-	EXAM_STUDENT_UPDATE("考生更新"), 
-	EXAM_STUDENT_DISABLE("考生禁用"),
-	STUDENT_DISABLE("学生禁用"), 
-	EXAM_STUDENT_ENABLE("考生启用"), 
-	STUDENT_ENABLE("学生启用"), 
-	STUDENT_LOGIN("学生登录"),
-	STUDENT_PHOTO_IMPORT("学生照片导入"), 
-	STUDENT_PASSWORD_RESET("学生密码重置"), 
-	EXAM_STUDENT_IMPORT("考生导入"),
-	STUDENT_UNBIND_PHONE("解绑安全手机"), 
-	STUDENT_UNBIND_STUDENTCODE("解绑学号"), 
-	STUDENT_PASSWORD_UPDATE("学生修改密码");
+    EXAM_STUDENT_ADD("考生新增"),
+    EXAM_STUDENT_COPY("考生复制"),
+    EXAM_STUDENT_UPDATE("考生更新"),
+    EXAM_STUDENT_DISABLE("考生禁用"),
+    STUDENT_DISABLE("学生禁用"),
+    EXAM_STUDENT_ENABLE("考生启用"),
+    STUDENT_ENABLE("学生启用"),
+    STUDENT_LOGIN("学生登录"),
+    STUDENT_PHOTO_IMPORT("学生照片导入"),
+    STUDENT_PASSWORD_RESET("学生密码重置"),
+    EXAM_STUDENT_IMPORT("考生导入"),
+    STUDENT_UNBIND_PHONE("解绑安全手机"),
+    STUDENT_UNBIND_STUDENTCODE("解绑学号"),
+    STUDENT_PASSWORD_UPDATE("学生修改密码");
 
-	/**
-	 * 描述
-	 */
-	private String desc;
+    /**
+     * 描述
+     */
+    private String desc;
 
-	/**
-	 * 构造函数
-	 *
-	 * @param desc
-	 */
-	private OperateContent(String desc) {
-		this.desc = desc;
-	}
+    /**
+     * 构造函数
+     *
+     * @param desc
+     */
+    private OperateContent(String desc) {
+        this.desc = desc;
+    }
 
-	public String getDesc() {
-		return desc;
-	}
+    public String getDesc() {
+        return desc;
+    }
 }

+ 70 - 69
examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/enums/Tag.java

@@ -2,74 +2,75 @@ package cn.com.qmth.examcloud.reports.commons.enums;
 
 public enum Tag {
 
-	/**
-	 * 学生
-	 */
-	ONLINE_STUDENT("ONLINE_STUDENT","ONLINE_STUDENT_GROUP", "学生"),
-
-	/**
-	 * 考生
-	 */
-	ONLINE_EXAM_STUDENT("ONLINE_EXAM_STUDENT","ONLINE_EXAM_STUDENT_GROUP", "考生"),
-
-	/**
-	 * 后台用户
-	 */
-	ONLINE_USER("ONLINE_USER","ONLINE_USER_GROUP", "后台用户"),
-
-	/**
-	 * 操作日志
-	 */
-	OPERATE_INFO("OPERATE_INFO","OPERATE_INFO_GROUP","操作日志"),
-
-	/**
-	 * 考试过程记录
-	 */
-	EXAM_PROCESS_RECORD("EXAM_PROCESS_RECORD","EXAM_PROCESS_RECORD_GROUP","考试过程记录"),
-	
-	/**
-	 * 后台用户操作日志
-	 */
-	ADMIN_OPERATE_INFO("ADMIN_OPERATE_INFO","ADMIN_OPERATE_INFO_GROUP","后台用户操作日志"),
-	;
-
-	// ===========================================================================
-
-	/**
-	 * 码
-	 */
-	private String code;
-
-	/**
-	 * 描述
-	 */
-	private String group;
-	/**
-	 * 描述
-	 */
-	private String desc;
-
-	/**
-	 * 构造函数
-	 *
-	 * @param desc
-	 */
-	private Tag(String code, String group,String desc) {
-		this.code = code;
-		this.group=group;
-		this.desc = desc;
-	}
-
-	public String getDesc() {
-		return desc;
-	}
-
-	public String getCode() {
-		return code;
-	}
-
-	public String getGroup() {
-		return group;
-	}
+    /**
+     * 学生
+     */
+    ONLINE_STUDENT("ONLINE_STUDENT", "ONLINE_STUDENT_GROUP", "学生"),
+
+    /**
+     * 考生
+     */
+    ONLINE_EXAM_STUDENT("ONLINE_EXAM_STUDENT", "ONLINE_EXAM_STUDENT_GROUP", "考生"),
+
+    /**
+     * 后台用户
+     */
+    ONLINE_USER("ONLINE_USER", "ONLINE_USER_GROUP", "后台用户"),
+
+    /**
+     * 操作日志
+     */
+    OPERATE_INFO("OPERATE_INFO", "OPERATE_INFO_GROUP", "操作日志"),
+
+    /**
+     * 考试过程记录
+     */
+    EXAM_PROCESS_RECORD("EXAM_PROCESS_RECORD", "EXAM_PROCESS_RECORD_GROUP", "考试过程记录"),
+
+    /**
+     * 后台用户操作日志
+     */
+    ADMIN_OPERATE_INFO("ADMIN_OPERATE_INFO", "ADMIN_OPERATE_INFO_GROUP", "后台用户操作日志"),
+    ;
+
+    // ===========================================================================
+
+    /**
+     * 码
+     */
+    private String code;
+
+    /**
+     * 描述
+     */
+    private String group;
+
+    /**
+     * 描述
+     */
+    private String desc;
+
+    /**
+     * 构造函数
+     *
+     * @param desc
+     */
+    private Tag(String code, String group, String desc) {
+        this.code = code;
+        this.group = group;
+        this.desc = desc;
+    }
+
+    public String getDesc() {
+        return desc;
+    }
+
+    public String getCode() {
+        return code;
+    }
+
+    public String getGroup() {
+        return group;
+    }
 
 }

+ 34 - 34
examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/enums/Topic.java

@@ -2,38 +2,38 @@ package cn.com.qmth.examcloud.reports.commons.enums;
 
 public enum Topic {
 
-	/**
-	 * 打点通用
-	 */
-	REPORT_TOPIC("REPORT_TOPIC", "打点通用");
-
-	// ===========================================================================
-
-	/**
-	 * 码
-	 */
-	private String code;
-
-	/**
-	 * 描述
-	 */
-	private String desc;
-
-	/**
-	 * 构造函数
-	 *
-	 * @param desc
-	 */
-	private Topic(String code, String desc) {
-		this.code = code;
-		this.desc = desc;
-	}
-
-	public String getDesc() {
-		return desc;
-	}
-
-	public String getCode() {
-		return code;
-	}
+    /**
+     * 打点通用
+     */
+    REPORT_TOPIC("REPORT_TOPIC", "打点通用");
+
+    // ===========================================================================
+
+    /**
+     * 码
+     */
+    private String code;
+
+    /**
+     * 描述
+     */
+    private String desc;
+
+    /**
+     * 构造函数
+     *
+     * @param desc
+     */
+    private Topic(String code, String desc) {
+        this.code = code;
+        this.desc = desc;
+    }
+
+    public String getDesc() {
+        return desc;
+    }
+
+    public String getCode() {
+        return code;
+    }
 }

+ 112 - 119
examcloud-support/src/main/java/cn/com/qmth/examcloud/reports/commons/util/ReportsUtil.java

@@ -1,5 +1,17 @@
 package cn.com.qmth.examcloud.reports.commons.util;
 
+import cn.com.qmth.examcloud.commons.util.ThreadLocalUtil;
+import cn.com.qmth.examcloud.reports.commons.bean.BaseReport;
+import cn.com.qmth.examcloud.reports.commons.enums.MqType;
+import cn.com.qmth.examcloud.web.bootstrap.PropertyHolder;
+import cn.com.qmth.examcloud.web.support.IpUtil;
+import cn.com.qmth.examcloud.web.support.ServletUtil;
+import com.alibaba.fastjson.JSON;
+import com.aliyun.openservices.ons.api.*;
+import org.apache.commons.collections.CollectionUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
 import java.net.Inet4Address;
 import java.net.InetAddress;
 import java.util.ArrayList;
@@ -7,125 +19,106 @@ import java.util.Date;
 import java.util.List;
 import java.util.Properties;
 
-import cn.com.qmth.examcloud.web.support.IpUtil;
-import org.apache.commons.collections.CollectionUtils;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-import com.alibaba.fastjson.JSON;
-import com.aliyun.openservices.ons.api.Message;
-import com.aliyun.openservices.ons.api.ONSFactory;
-import com.aliyun.openservices.ons.api.OnExceptionContext;
-import com.aliyun.openservices.ons.api.Producer;
-import com.aliyun.openservices.ons.api.PropertyKeyConst;
-import com.aliyun.openservices.ons.api.SendCallback;
-import com.aliyun.openservices.ons.api.SendResult;
-
-import cn.com.qmth.examcloud.commons.util.ThreadLocalUtil;
-import cn.com.qmth.examcloud.reports.commons.bean.BaseReport;
-import cn.com.qmth.examcloud.reports.commons.enums.MqType;
-import cn.com.qmth.examcloud.web.bootstrap.PropertyHolder;
-import cn.com.qmth.examcloud.web.support.ServletUtil;
-
 public class ReportsUtil {
 
-	private static final Logger LOG = LoggerFactory.getLogger(ReportsUtil.class);
-
-	private static final String KEY = "mq-report-data";
-
-	private static Producer producer;
-
-	private static String mqType = PropertyHolder.getString("$report.mq-type", "rocketmq");
-
-	private static Boolean reportEnable = PropertyHolder.getBoolean("$report.enable", false);
-
-	static {
-		if (reportEnable) {
-			if (MqType.ROCKETMQ.getCode().equals(mqType)) {
-				Properties properties = new Properties();
-				// AccessKeyId 阿里云身份验证,在阿里云服务器管理控制台创建。
-				properties.put(PropertyKeyConst.AccessKey, PropertyHolder.getString("$rocketmq-accesskey"));
-				// AccessKeySecret 阿里云身份验证,在阿里云服务器管理控制台创建。
-				properties.put(PropertyKeyConst.SecretKey, PropertyHolder.getString("$rocketmq-secretkey"));
-				// 设置发送超时时间,单位毫秒。
-				properties.setProperty(PropertyKeyConst.SendMsgTimeoutMillis, "3000");
-				// 设置 TCP 接入域名,进入控制台的实例详情页面的 TCP 协议客户端接入点区域查看。
-				properties.put(PropertyKeyConst.NAMESRV_ADDR, PropertyHolder.getString("$rocketmq-namesrv-addr"));
-
-				producer = ONSFactory.createProducer(properties);
-				// 在发送消息前,必须调用 start 方法来启动 Producer,只需调用一次即可。
-				producer.start();
-			} else {
-				LOG.error("value of property[$report.mq-type] is wrong!");
-			}
-		}
-	}
-
-
-	private static void sendReportRocket(Boolean onException) {
-		@SuppressWarnings("unchecked")
-		List<BaseReport> list = (List<BaseReport>) ThreadLocalUtil.get(KEY);
-		if (CollectionUtils.isNotEmpty(list)) {
-			for (BaseReport b : list) {
-				if (!onException || (onException && b.getReportOnException())) {
-					try {
-						String messageStr = JSON.toJSONString(b);
-						Message msg = new Message(b.getTopic(), b.getTag(), messageStr.getBytes("utf-8"));
-						producer.sendAsync(msg, new SendCallback() {
-							@Override
-							public void onSuccess(final SendResult sendResult) {
-								// 消息发送成功。
-							}
-
-							@Override
-							public void onException(OnExceptionContext context) {
-								// 消息发送失败,需要进行重试处理,可重新发送这条消息或持久化这条数据进行补偿处理。
-								LOG.error("SendReport failed msgId:"+msg+" " + messageStr, context.getException());
-							}
-						});
-					} catch (Exception e) {
-						LOG.error("SendReport Error:" + JSON.toJSONString(b), e);
-					}
-				}
-			}
-			ThreadLocalUtil.set(KEY, null);
-		}
-	}
-
-	public static void report(BaseReport report) {
-		try {
-			if (!reportEnable) {
-				return;
-			}
-			setReportCommonData(report);
-			@SuppressWarnings("unchecked")
-			List<BaseReport> list = (List<BaseReport>) ThreadLocalUtil.get(KEY);
-			if (list == null) {
-				list = new ArrayList<BaseReport>();
-				ThreadLocalUtil.set(KEY, list);
-			}
-			list.add(report);
-		} catch (Exception e) {
-			LOG.error(JSON.toJSONString(report), e);
-		}
-	}
-
-	public static void sendReport(Boolean onException) {
-		if (MqType.ROCKETMQ.getCode().equals(mqType)) {
-			sendReportRocket(onException);
-		}
-	}
-
-	private static void setReportCommonData(BaseReport report) {
-		String ip = "";
-		try {
-			InetAddress localHost = Inet4Address.getLocalHost();
-			ip = localHost.getHostAddress();
-		} catch (Exception e) {
-			LOG.debug("获取本机IP出错", e);
-		}
-		report.setReportHost(ip);
-		report.setRemoteHost(IpUtil.getRemoteIp(ServletUtil.getRequest()));
-		report.setReportTime(new Date());
-	}
+    private static final Logger LOG = LoggerFactory.getLogger(ReportsUtil.class);
+
+    private static final String KEY = "mq-report-data";
+
+    private static Producer producer;
+
+    private static String mqType = PropertyHolder.getString("$report.mq-type", "rocketmq");
+
+    private static Boolean reportEnable = PropertyHolder.getBoolean("$report.enable", false);
+
+    static {
+        if (reportEnable) {
+            if (MqType.ROCKETMQ.getCode().equals(mqType)) {
+                Properties properties = new Properties();
+                // AccessKeyId 阿里云身份验证,在阿里云服务器管理控制台创建。
+                properties.put(PropertyKeyConst.AccessKey, PropertyHolder.getString("$rocketmq-accesskey"));
+                // AccessKeySecret 阿里云身份验证,在阿里云服务器管理控制台创建。
+                properties.put(PropertyKeyConst.SecretKey, PropertyHolder.getString("$rocketmq-secretkey"));
+                // 设置发送超时时间,单位毫秒。
+                properties.setProperty(PropertyKeyConst.SendMsgTimeoutMillis, "3000");
+                // 设置 TCP 接入域名,进入控制台的实例详情页面的 TCP 协议客户端接入点区域查看。
+                properties.put(PropertyKeyConst.NAMESRV_ADDR, PropertyHolder.getString("$rocketmq-namesrv-addr"));
+
+                producer = ONSFactory.createProducer(properties);
+                // 在发送消息前,必须调用 start 方法来启动 Producer,只需调用一次即可。
+                producer.start();
+            } else {
+                LOG.error("value of property[$report.mq-type] is wrong!");
+            }
+        }
+    }
+
+
+    private static void sendReportRocket(Boolean onException) {
+        @SuppressWarnings("unchecked")
+        List<BaseReport> list = (List<BaseReport>) ThreadLocalUtil.get(KEY);
+        if (CollectionUtils.isNotEmpty(list)) {
+            for (BaseReport b : list) {
+                if (!onException || (onException && b.getReportOnException())) {
+                    try {
+                        String messageStr = JSON.toJSONString(b);
+                        Message msg = new Message(b.getTopic(), b.getTag(), messageStr.getBytes("utf-8"));
+                        producer.sendAsync(msg, new SendCallback() {
+                            @Override
+                            public void onSuccess(final SendResult sendResult) {
+                                // 消息发送成功。
+                            }
+
+                            @Override
+                            public void onException(OnExceptionContext context) {
+                                // 消息发送失败,需要进行重试处理,可重新发送这条消息或持久化这条数据进行补偿处理。
+                                LOG.error("SendReport failed msgId:" + msg + " " + messageStr, context.getException());
+                            }
+                        });
+                    } catch (Exception e) {
+                        LOG.error("SendReport Error:" + JSON.toJSONString(b), e);
+                    }
+                }
+            }
+            ThreadLocalUtil.set(KEY, null);
+        }
+    }
+
+    public static void report(BaseReport report) {
+        try {
+            if (!reportEnable) {
+                return;
+            }
+            setReportCommonData(report);
+            @SuppressWarnings("unchecked")
+            List<BaseReport> list = (List<BaseReport>) ThreadLocalUtil.get(KEY);
+            if (list == null) {
+                list = new ArrayList<BaseReport>();
+                ThreadLocalUtil.set(KEY, list);
+            }
+            list.add(report);
+        } catch (Exception e) {
+            LOG.error(JSON.toJSONString(report), e);
+        }
+    }
+
+    public static void sendReport(Boolean onException) {
+        if (MqType.ROCKETMQ.getCode().equals(mqType)) {
+            sendReportRocket(onException);
+        }
+    }
+
+    private static void setReportCommonData(BaseReport report) {
+        String ip = "";
+        try {
+            InetAddress localHost = Inet4Address.getLocalHost();
+            ip = localHost.getHostAddress();
+        } catch (Exception e) {
+            LOG.debug("获取本机IP出错", e);
+        }
+        report.setReportHost(ip);
+        report.setRemoteHost(IpUtil.getRemoteIp(ServletUtil.getRequest()));
+        report.setReportTime(new Date());
+    }
+
 }

+ 61 - 61
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/AppCacheBean.java

@@ -2,66 +2,66 @@ package cn.com.qmth.examcloud.support.cache.bean;
 
 public class AppCacheBean {
 
-	private Long id;
-
-	/**
-	 * APP服务名(大写字母加"-"组成)
-	 */
-	private String name;
-
-	/**
-	 * APP编码(通常为1到3位大写字母和数字组合)
-	 */
-	private String code;
-
-	/**
-	 * 密钥
-	 */
-	private String secretKey;
-
-	/**
-	 * 接口鉴权时差范围
-	 */
-	private Long timeRange;
-
-	public Long getId() {
-		return id;
-	}
-
-	public void setId(Long id) {
-		this.id = id;
-	}
-
-	public String getName() {
-		return name;
-	}
-
-	public void setName(String name) {
-		this.name = name;
-	}
-
-	public String getCode() {
-		return code;
-	}
-
-	public void setCode(String code) {
-		this.code = code;
-	}
-
-	public String getSecretKey() {
-		return secretKey;
-	}
-
-	public void setSecretKey(String secretKey) {
-		this.secretKey = secretKey;
-	}
-
-	public Long getTimeRange() {
-		return timeRange;
-	}
-
-	public void setTimeRange(Long timeRange) {
-		this.timeRange = timeRange;
-	}
+    private Long id;
+
+    /**
+     * APP服务名(大写字母加"-"组成)
+     */
+    private String name;
+
+    /**
+     * APP编码(通常为1到3位大写字母和数字组合)
+     */
+    private String code;
+
+    /**
+     * 密钥
+     */
+    private String secretKey;
+
+    /**
+     * 接口鉴权时差范围
+     */
+    private Long timeRange;
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getCode() {
+        return code;
+    }
+
+    public void setCode(String code) {
+        this.code = code;
+    }
+
+    public String getSecretKey() {
+        return secretKey;
+    }
+
+    public void setSecretKey(String secretKey) {
+        this.secretKey = secretKey;
+    }
+
+    public Long getTimeRange() {
+        return timeRange;
+    }
+
+    public void setTimeRange(Long timeRange) {
+        this.timeRange = timeRange;
+    }
 
 }

+ 1 - 0
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/BasePaperCacheBean.java

@@ -9,6 +9,7 @@ import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
  * @Date 2019/7/30 14:36
  */
 public class BasePaperCacheBean extends RandomCacheBean {
+
     private static final long serialVersionUID = 6309635978462557320L;
 
     /**

+ 46 - 43
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/CourseCacheBean.java

@@ -4,70 +4,73 @@ import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
 
 /**
  * 课程缓存实体
+ *
  * @author lideyin
  * @date 2019年5月21日 下午4:26:19
  * @description 可根据需求扩展属性
  */
 public class CourseCacheBean extends RandomCacheBean {
 
-	private static final long serialVersionUID = 3910143938927203635L;
-	private Long id;
+    private static final long serialVersionUID = 3910143938927203635L;
 
-	private Long rootOrgId;
+    private Long id;
 
-	private String code;
+    private Long rootOrgId;
 
-	private String name;
+    private String code;
 
-	private String level;
+    private String name;
 
-	private Boolean enable;
+    private String level;
 
-	public Long getId() {
-		return id;
-	}
+    private Boolean enable;
 
-	public void setId(Long id) {
-		this.id = id;
-	}
+    public Long getId() {
+        return id;
+    }
 
-	public Long getRootOrgId() {
-		return rootOrgId;
-	}
+    public void setId(Long id) {
+        this.id = id;
+    }
 
-	public void setRootOrgId(Long rootOrgId) {
-		this.rootOrgId = rootOrgId;
-	}
+    public Long getRootOrgId() {
+        return rootOrgId;
+    }
 
-	public String getCode() {
-		return code;
-	}
+    public void setRootOrgId(Long rootOrgId) {
+        this.rootOrgId = rootOrgId;
+    }
 
-	public void setCode(String code) {
-		this.code = code;
-	}
+    public String getCode() {
+        return code;
+    }
 
-	public String getName() {
-		return name;
-	}
+    public void setCode(String code) {
+        this.code = code;
+    }
 
-	public void setName(String name) {
-		this.name = name;
-	}
+    public String getName() {
+        return name;
+    }
 
-	public String getLevel() {
-		return level;
-	}
+    public void setName(String name) {
+        this.name = name;
+    }
 
-	public void setLevel(String level) {
-		this.level = level;
-	}
+    public String getLevel() {
+        return level;
+    }
 
-	public Boolean getEnable() {
-		return enable;
-	}
+    public void setLevel(String level) {
+        this.level = level;
+    }
+
+    public Boolean getEnable() {
+        return enable;
+    }
+
+    public void setEnable(Boolean enable) {
+        this.enable = enable;
+    }
 
-	public void setEnable(Boolean enable) {
-		this.enable = enable;
-	}
 }

+ 8 - 8
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamOrgPropertyCacheBean.java

@@ -9,16 +9,16 @@ package cn.com.qmth.examcloud.support.cache.bean;
  */
 public class ExamOrgPropertyCacheBean extends ExamPropertyCacheBean {
 
-	private static final long serialVersionUID = -8521363493722068369L;
+    private static final long serialVersionUID = -8521363493722068369L;
 
-	private Long orgId;
+    private Long orgId;
 
-	public Long getOrgId() {
-		return orgId;
-	}
+    public Long getOrgId() {
+        return orgId;
+    }
 
-	public void setOrgId(Long orgId) {
-		this.orgId = orgId;
-	}
+    public void setOrgId(Long orgId) {
+        this.orgId = orgId;
+    }
 
 }

+ 1 - 1
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamOrgSettingsCacheBean.java

@@ -9,6 +9,6 @@ package cn.com.qmth.examcloud.support.cache.bean;
  */
 public class ExamOrgSettingsCacheBean extends ExamSettingsCacheBean {
 
-	private static final long serialVersionUID = -8007446755455123835L;
+    private static final long serialVersionUID = -8007446755455123835L;
 
 }

+ 22 - 22
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamPropertyCacheBean.java

@@ -11,36 +11,36 @@ import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
  */
 public class ExamPropertyCacheBean extends RandomCacheBean {
 
-	private static final long serialVersionUID = -8521363493722068369L;
+    private static final long serialVersionUID = -8521363493722068369L;
 
-	private Long examId;
+    private Long examId;
 
-	private String key;
+    private String key;
 
-	private String value;
+    private String value;
 
-	public Long getExamId() {
-		return examId;
-	}
+    public Long getExamId() {
+        return examId;
+    }
 
-	public void setExamId(Long examId) {
-		this.examId = examId;
-	}
+    public void setExamId(Long examId) {
+        this.examId = examId;
+    }
 
-	public String getKey() {
-		return key;
-	}
+    public String getKey() {
+        return key;
+    }
 
-	public void setKey(String key) {
-		this.key = key;
-	}
+    public void setKey(String key) {
+        this.key = key;
+    }
 
-	public String getValue() {
-		return value;
-	}
+    public String getValue() {
+        return value;
+    }
 
-	public void setValue(String value) {
-		this.value = value;
-	}
+    public void setValue(String value) {
+        this.value = value;
+    }
 
 }

+ 23 - 20
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamRecordPropertyCacheBean.java

@@ -5,35 +5,38 @@ import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
 /**
  * 考试记录相关常用属性缓存
  * 注意:此缓存中只能添加不会发生改变的属性,否则需要埋点同步刷新缓存
+ *
  * @author lideyin
  * @date 2019年5月21日 下午4:26:19
  * @description 可根据需求扩展属性
  */
 public class ExamRecordPropertyCacheBean extends RandomCacheBean {
 
-	/**
-	 * 
-	 */
-	private static final long serialVersionUID = 4325869001570331457L;
+    /**
+     *
+     */
+    private static final long serialVersionUID = 4325869001570331457L;
 
-	//考试id
-	private Long examId;
-	//组织机构id
-	private Long orgId;
+    //考试id
+    private Long examId;
 
-	public Long getExamId() {
-		return examId;
-	}
+    //组织机构id
+    private Long orgId;
 
-	public void setExamId(Long examId) {
-		this.examId = examId;
-	}
+    public Long getExamId() {
+        return examId;
+    }
 
-	public Long getOrgId() {
-		return orgId;
-	}
+    public void setExamId(Long examId) {
+        this.examId = examId;
+    }
+
+    public Long getOrgId() {
+        return orgId;
+    }
+
+    public void setOrgId(Long orgId) {
+        this.orgId = orgId;
+    }
 
-	public void setOrgId(Long orgId) {
-		this.orgId = orgId;
-	}
 }

+ 190 - 190
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamSettingsCacheBean.java

@@ -1,10 +1,10 @@
 package cn.com.qmth.examcloud.support.cache.bean;
 
-import java.util.Date;
-
 import cn.com.qmth.examcloud.api.commons.enums.ExamSpecialSettingsType;
 import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
 
+import java.util.Date;
+
 /**
  * 机构考试配置
  *
@@ -14,198 +14,198 @@ import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
  */
 public class ExamSettingsCacheBean extends RandomCacheBean {
 
-	private static final long serialVersionUID = -8007446755455123835L;
-
-	private Long id;
-
-	/**
-	 * 考试编码
-	 */
-	private String code;
-
-	/**
-	 * 顶级机构Id
-	 */
-	private Long rootOrgId;
-
-	/**
-	 * 考试批次开始时间
-	 */
-	private Date beginTime;
-
-	/**
-	 * 考试批次结束时间
-	 */
-	private Date endTime;
-
-	/**
-	 * 考试名称
-	 */
-	private String name;
-
-	/**
-	 * 考试类型
-	 */
-	private String examType;
-	
-	/**
-	 * 抽题模式
-	 */
-	private String callType;
-
-	/**
-	 * 考试时长
-	 */
-	private Integer duration;
-
-	/**
-	 * 是否可用
-	 */
-	private Boolean enable;
-
-	/**
-	 * 考试备注
-	 */
-	private String remark;
-
-	/**
-	 * 考试次数
-	 */
-	private Long examTimes;
-
-	/**
-	 * 是否禁止考试
-	 */
-	private Boolean examLimit;
-
-	/**
-	 * 开启特殊设置
-	 */
-	private Boolean specialSettingsEnabled;
-
-	/**
-	 * 特殊设置类型
-	 */
-	private ExamSpecialSettingsType specialSettingsType;
-
-	public Long getId() {
-		return id;
-	}
-
-	public void setId(Long id) {
-		this.id = id;
-	}
-
-	public String getCode() {
-		return code;
-	}
-
-	public void setCode(String code) {
-		this.code = code;
-	}
-
-	public Long getRootOrgId() {
-		return rootOrgId;
-	}
-
-	public void setRootOrgId(Long rootOrgId) {
-		this.rootOrgId = rootOrgId;
-	}
-
-	public Date getBeginTime() {
-		return beginTime;
-	}
-
-	public void setBeginTime(Date beginTime) {
-		this.beginTime = beginTime;
-	}
-
-	public Date getEndTime() {
-		return endTime;
-	}
-
-	public void setEndTime(Date endTime) {
-		this.endTime = endTime;
-	}
-
-	public String getName() {
-		return name;
-	}
-
-	public void setName(String name) {
-		this.name = name;
-	}
-
-	public String getExamType() {
-		return examType;
-	}
-
-	public void setExamType(String examType) {
-		this.examType = examType;
-	}
-
-	public Integer getDuration() {
-		return duration;
-	}
-
-	public void setDuration(Integer duration) {
-		this.duration = duration;
-	}
-
-	public Boolean getEnable() {
-		return enable;
-	}
-
-	public void setEnable(Boolean enable) {
-		this.enable = enable;
-	}
-
-	public String getRemark() {
-		return remark;
-	}
-
-	public void setRemark(String remark) {
-		this.remark = remark;
-	}
-
-	public Long getExamTimes() {
-		return examTimes;
-	}
-
-	public void setExamTimes(Long examTimes) {
-		this.examTimes = examTimes;
-	}
-
-	public Boolean getExamLimit() {
-		return examLimit;
-	}
-
-	public void setExamLimit(Boolean examLimit) {
-		this.examLimit = examLimit;
-	}
-
-	public Boolean getSpecialSettingsEnabled() {
-		return specialSettingsEnabled;
-	}
+    private static final long serialVersionUID = -8007446755455123835L;
+
+    private Long id;
+
+    /**
+     * 考试编码
+     */
+    private String code;
+
+    /**
+     * 顶级机构Id
+     */
+    private Long rootOrgId;
+
+    /**
+     * 考试批次开始时间
+     */
+    private Date beginTime;
+
+    /**
+     * 考试批次结束时间
+     */
+    private Date endTime;
+
+    /**
+     * 考试名称
+     */
+    private String name;
+
+    /**
+     * 考试类型
+     */
+    private String examType;
+
+    /**
+     * 抽题模式
+     */
+    private String callType;
+
+    /**
+     * 考试时长
+     */
+    private Integer duration;
+
+    /**
+     * 是否可用
+     */
+    private Boolean enable;
+
+    /**
+     * 考试备注
+     */
+    private String remark;
+
+    /**
+     * 考试次数
+     */
+    private Long examTimes;
+
+    /**
+     * 是否禁止考试
+     */
+    private Boolean examLimit;
+
+    /**
+     * 开启特殊设置
+     */
+    private Boolean specialSettingsEnabled;
+
+    /**
+     * 特殊设置类型
+     */
+    private ExamSpecialSettingsType specialSettingsType;
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+
+    public String getCode() {
+        return code;
+    }
+
+    public void setCode(String code) {
+        this.code = code;
+    }
+
+    public Long getRootOrgId() {
+        return rootOrgId;
+    }
+
+    public void setRootOrgId(Long rootOrgId) {
+        this.rootOrgId = rootOrgId;
+    }
+
+    public Date getBeginTime() {
+        return beginTime;
+    }
+
+    public void setBeginTime(Date beginTime) {
+        this.beginTime = beginTime;
+    }
+
+    public Date getEndTime() {
+        return endTime;
+    }
+
+    public void setEndTime(Date endTime) {
+        this.endTime = endTime;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getExamType() {
+        return examType;
+    }
+
+    public void setExamType(String examType) {
+        this.examType = examType;
+    }
+
+    public Integer getDuration() {
+        return duration;
+    }
+
+    public void setDuration(Integer duration) {
+        this.duration = duration;
+    }
+
+    public Boolean getEnable() {
+        return enable;
+    }
+
+    public void setEnable(Boolean enable) {
+        this.enable = enable;
+    }
+
+    public String getRemark() {
+        return remark;
+    }
+
+    public void setRemark(String remark) {
+        this.remark = remark;
+    }
+
+    public Long getExamTimes() {
+        return examTimes;
+    }
+
+    public void setExamTimes(Long examTimes) {
+        this.examTimes = examTimes;
+    }
+
+    public Boolean getExamLimit() {
+        return examLimit;
+    }
+
+    public void setExamLimit(Boolean examLimit) {
+        this.examLimit = examLimit;
+    }
+
+    public Boolean getSpecialSettingsEnabled() {
+        return specialSettingsEnabled;
+    }
 
-	public void setSpecialSettingsEnabled(Boolean specialSettingsEnabled) {
-		this.specialSettingsEnabled = specialSettingsEnabled;
-	}
+    public void setSpecialSettingsEnabled(Boolean specialSettingsEnabled) {
+        this.specialSettingsEnabled = specialSettingsEnabled;
+    }
 
-	public ExamSpecialSettingsType getSpecialSettingsType() {
-		return specialSettingsType;
-	}
+    public ExamSpecialSettingsType getSpecialSettingsType() {
+        return specialSettingsType;
+    }
 
-	public void setSpecialSettingsType(ExamSpecialSettingsType specialSettingsType) {
-		this.specialSettingsType = specialSettingsType;
-	}
+    public void setSpecialSettingsType(ExamSpecialSettingsType specialSettingsType) {
+        this.specialSettingsType = specialSettingsType;
+    }
 
-	public String getCallType() {
-		return callType;
-	}
+    public String getCallType() {
+        return callType;
+    }
 
-	public void setCallType(String callType) {
-		this.callType = callType;
-	}
+    public void setCallType(String callType) {
+        this.callType = callType;
+    }
 
 }

+ 138 - 141
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamStageCacheBean.java

@@ -1,13 +1,7 @@
 package cn.com.qmth.examcloud.support.cache.bean;
 
-import cn.com.qmth.examcloud.api.commons.enums.ExamStageStartExamStatus;
-import cn.com.qmth.examcloud.api.commons.enums.SubmitType;
 import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
-import org.springframework.format.annotation.DateTimeFormat;
 
-import javax.persistence.Column;
-import javax.persistence.EnumType;
-import javax.persistence.Enumerated;
 import java.util.Date;
 
 /**
@@ -17,142 +11,145 @@ import java.util.Date;
  * @Version 1.0
  */
 public class ExamStageCacheBean extends RandomCacheBean {
-	private static final long serialVersionUID = 7837714620786777681L;
-
 
-	private Long id;
-	/**
-	 * 顶级机构Id
-	 */
-	private Long rootOrgId;
-
-	/**
-	 * 考试id
-	 */
-	private Long examId;
-
-	/**
-	 * 场次号
-	 */
-	private Integer stageOrder;
+    private static final long serialVersionUID = 7837714620786777681L;
 
-	/**
-	 * 开始进入考试时间
-	 */
-	private Date startTime;
-
-	/**
-	 * 考试批次结束时间
-	 */
-	private Date endTime;
-
-	private Boolean enable;
 
-	/**
-	 * 是否特殊设置
-	 */
-	private Boolean specialSetting;
-
-	/**
-	 * 回收试卷类型
-	 */
-	private String submitType;
-
-	/**
-	 * 统一收卷考试时长(分钟)
-	 */
-	private Integer submitDuration;
-
-	/**
-	 * 场次开考状态
-	 */
-	private String startExamStatus;
-
-	public Long getId() {
-		return id;
-	}
-
-	public void setId(Long id) {
-		this.id = id;
-	}
-
-	public Long getRootOrgId() {
-		return rootOrgId;
-	}
-
-	public void setRootOrgId(Long rootOrgId) {
-		this.rootOrgId = rootOrgId;
-	}
-
-	public Long getExamId() {
-		return examId;
-	}
-
-	public void setExamId(Long examId) {
-		this.examId = examId;
-	}
-
-	public Integer getStageOrder() {
-		return stageOrder;
-	}
-
-	public void setStageOrder(Integer stageOrder) {
-		this.stageOrder = stageOrder;
-	}
-
-	public Date getStartTime() {
-		return startTime;
-	}
-
-	public void setStartTime(Date startTime) {
-		this.startTime = startTime;
-	}
-
-	public Date getEndTime() {
-		return endTime;
-	}
-
-	public void setEndTime(Date endTime) {
-		this.endTime = endTime;
-	}
-
-	public Boolean getEnable() {
-		return enable;
-	}
-
-	public void setEnable(Boolean enable) {
-		this.enable = enable;
-	}
-
-	public Boolean getSpecialSetting() {
-		return specialSetting;
-	}
-
-	public void setSpecialSetting(Boolean specialSetting) {
-		this.specialSetting = specialSetting;
-	}
-
-	public String getSubmitType() {
-		return submitType;
-	}
-
-	public void setSubmitType(String submitType) {
-		this.submitType = submitType;
-	}
-
-	public Integer getSubmitDuration() {
-		return submitDuration;
-	}
-
-	public void setSubmitDuration(Integer submitDuration) {
-		this.submitDuration = submitDuration;
-	}
-
-	public String getStartExamStatus() {
-		return startExamStatus;
-	}
-
-	public void setStartExamStatus(String startExamStatus) {
-		this.startExamStatus = startExamStatus;
-	}
+    private Long id;
+
+    /**
+     * 顶级机构Id
+     */
+    private Long rootOrgId;
+
+    /**
+     * 考试id
+     */
+    private Long examId;
+
+    /**
+     * 场次号
+     */
+    private Integer stageOrder;
+
+    /**
+     * 开始进入考试时间
+     */
+    private Date startTime;
+
+    /**
+     * 考试批次结束时间
+     */
+    private Date endTime;
+
+    private Boolean enable;
+
+    /**
+     * 是否特殊设置
+     */
+    private Boolean specialSetting;
+
+    /**
+     * 回收试卷类型
+     */
+    private String submitType;
+
+    /**
+     * 统一收卷考试时长(分钟)
+     */
+    private Integer submitDuration;
+
+    /**
+     * 场次开考状态
+     */
+    private String startExamStatus;
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+
+    public Long getRootOrgId() {
+        return rootOrgId;
+    }
+
+    public void setRootOrgId(Long rootOrgId) {
+        this.rootOrgId = rootOrgId;
+    }
+
+    public Long getExamId() {
+        return examId;
+    }
+
+    public void setExamId(Long examId) {
+        this.examId = examId;
+    }
+
+    public Integer getStageOrder() {
+        return stageOrder;
+    }
+
+    public void setStageOrder(Integer stageOrder) {
+        this.stageOrder = stageOrder;
+    }
+
+    public Date getStartTime() {
+        return startTime;
+    }
+
+    public void setStartTime(Date startTime) {
+        this.startTime = startTime;
+    }
+
+    public Date getEndTime() {
+        return endTime;
+    }
+
+    public void setEndTime(Date endTime) {
+        this.endTime = endTime;
+    }
+
+    public Boolean getEnable() {
+        return enable;
+    }
+
+    public void setEnable(Boolean enable) {
+        this.enable = enable;
+    }
+
+    public Boolean getSpecialSetting() {
+        return specialSetting;
+    }
+
+    public void setSpecialSetting(Boolean specialSetting) {
+        this.specialSetting = specialSetting;
+    }
+
+    public String getSubmitType() {
+        return submitType;
+    }
+
+    public void setSubmitType(String submitType) {
+        this.submitType = submitType;
+    }
+
+    public Integer getSubmitDuration() {
+        return submitDuration;
+    }
+
+    public void setSubmitDuration(Integer submitDuration) {
+        this.submitDuration = submitDuration;
+    }
+
+    public String getStartExamStatus() {
+        return startExamStatus;
+    }
+
+    public void setStartExamStatus(String startExamStatus) {
+        this.startExamStatus = startExamStatus;
+    }
+
 }

+ 20 - 18
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamStagesCacheBean.java

@@ -11,28 +11,30 @@ import java.util.List;
  * @Version 1.0
  */
 public class ExamStagesCacheBean extends RandomCacheBean {
-	private static final long serialVersionUID = 7837714620786777681L;
 
-	/**
-	 * 考试id
-	 */
-	private Long examId;
+    private static final long serialVersionUID = 7837714620786777681L;
 
-	private List<ExamStageCacheBean> examStages;
+    /**
+     * 考试id
+     */
+    private Long examId;
 
-	public Long getExamId() {
-		return examId;
-	}
+    private List<ExamStageCacheBean> examStages;
 
-	public void setExamId(Long examId) {
-		this.examId = examId;
-	}
+    public Long getExamId() {
+        return examId;
+    }
 
-	public List<ExamStageCacheBean> getExamStages() {
-		return examStages;
-	}
+    public void setExamId(Long examId) {
+        this.examId = examId;
+    }
+
+    public List<ExamStageCacheBean> getExamStages() {
+        return examStages;
+    }
+
+    public void setExamStages(List<ExamStageCacheBean> examStages) {
+        this.examStages = examStages;
+    }
 
-	public void setExamStages(List<ExamStageCacheBean> examStages) {
-		this.examStages = examStages;
-	}
 }

+ 145 - 144
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamStudentCacheBean.java

@@ -11,148 +11,149 @@ import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
  */
 public class ExamStudentCacheBean extends RandomCacheBean {
 
-	private static final long serialVersionUID = -645838123919802377L;
-
-	/**
-	 * 考生ID
-	 */
-	private Long examStudentId;
-
-	/**
-	 * 考试ID
-	 */
-	private Long examId;
-
-	/**
-	 * 学生ID
-	 */
-	private Long studentId;
-
-	/**
-	 * 课程ID
-	 */
-	private Long courseId;
-
-	/**
-	 * 已经考试的次数
-	 */
-	private Integer usedNum;
-
-	/**
-	 * 补加的考试次数
-	 */
-	private Integer extraNum;
-
-	/**
-	 * 是否可用
-	 */
-	private Boolean enable;
-
-	/**
-	 * 试卷类型
-	 */
-	private String paperType;
-
-	/**
-	 * 年级
-	 */
-	private String grade;
-
-	/**
-	 * 场次id
-	 */
-	private Long examStageId;
-
-	/**
-	 * 场次号
-	 */
-	private Integer examStageOrder;
-
-	public Long getExamStudentId() {
-		return examStudentId;
-	}
-
-	public void setExamStudentId(Long examStudentId) {
-		this.examStudentId = examStudentId;
-	}
-
-	public Long getExamId() {
-		return examId;
-	}
-
-	public void setExamId(Long examId) {
-		this.examId = examId;
-	}
-
-	public Long getStudentId() {
-		return studentId;
-	}
-
-	public void setStudentId(Long studentId) {
-		this.studentId = studentId;
-	}
-
-	public Long getCourseId() {
-		return courseId;
-	}
-
-	public void setCourseId(Long courseId) {
-		this.courseId = courseId;
-	}
-
-	public Integer getUsedNum() {
-		return usedNum;
-	}
-
-	public void setUsedNum(Integer usedNum) {
-		this.usedNum = usedNum;
-	}
-
-	public Integer getExtraNum() {
-		return extraNum;
-	}
-
-	public void setExtraNum(Integer extraNum) {
-		this.extraNum = extraNum;
-	}
-
-	public Boolean getEnable() {
-		return enable;
-	}
-
-	public void setEnable(Boolean enable) {
-		this.enable = enable;
-	}
-
-	public String getPaperType() {
-		return paperType;
-	}
-
-	public void setPaperType(String paperType) {
-		this.paperType = paperType;
-	}
-
-	public String getGrade() {
-		return grade;
-	}
-
-	public void setGrade(String grade) {
-		this.grade = grade;
-	}
-
-	public Long getExamStageId() {
-		return examStageId;
-	}
-
-	public void setExamStageId(Long examStageId) {
-		this.examStageId = examStageId;
-	}
-
-	public Integer getExamStageOrder() {
-		return examStageOrder;
-	}
-
-	public void setExamStageOrder(Integer examStageOrder) {
-		this.examStageOrder = examStageOrder;
-	}
+    private static final long serialVersionUID = -645838123919802377L;
+
+    /**
+     * 考生ID
+     */
+    private Long examStudentId;
+
+    /**
+     * 考试ID
+     */
+    private Long examId;
+
+    /**
+     * 学生ID
+     */
+    private Long studentId;
+
+    /**
+     * 课程ID
+     */
+    private Long courseId;
+
+    /**
+     * 已经考试的次数
+     */
+    private Integer usedNum;
+
+    /**
+     * 补加的考试次数
+     */
+    private Integer extraNum;
+
+    /**
+     * 是否可用
+     */
+    private Boolean enable;
+
+    /**
+     * 试卷类型
+     */
+    private String paperType;
+
+    /**
+     * 年级
+     */
+    private String grade;
+
+    /**
+     * 场次id
+     */
+    private Long examStageId;
+
+    /**
+     * 场次号
+     */
+    private Integer examStageOrder;
+
+    public Long getExamStudentId() {
+        return examStudentId;
+    }
+
+    public void setExamStudentId(Long examStudentId) {
+        this.examStudentId = examStudentId;
+    }
+
+    public Long getExamId() {
+        return examId;
+    }
+
+    public void setExamId(Long examId) {
+        this.examId = examId;
+    }
+
+    public Long getStudentId() {
+        return studentId;
+    }
+
+    public void setStudentId(Long studentId) {
+        this.studentId = studentId;
+    }
+
+    public Long getCourseId() {
+        return courseId;
+    }
+
+    public void setCourseId(Long courseId) {
+        this.courseId = courseId;
+    }
+
+    public Integer getUsedNum() {
+        return usedNum;
+    }
+
+    public void setUsedNum(Integer usedNum) {
+        this.usedNum = usedNum;
+    }
+
+    public Integer getExtraNum() {
+        return extraNum;
+    }
+
+    public void setExtraNum(Integer extraNum) {
+        this.extraNum = extraNum;
+    }
+
+    public Boolean getEnable() {
+        return enable;
+    }
+
+    public void setEnable(Boolean enable) {
+        this.enable = enable;
+    }
+
+    public String getPaperType() {
+        return paperType;
+    }
+
+    public void setPaperType(String paperType) {
+        this.paperType = paperType;
+    }
+
+    public String getGrade() {
+        return grade;
+    }
+
+    public void setGrade(String grade) {
+        this.grade = grade;
+    }
+
+    public Long getExamStageId() {
+        return examStageId;
+    }
+
+    public void setExamStageId(Long examStageId) {
+        this.examStageId = examStageId;
+    }
+
+    public Integer getExamStageOrder() {
+        return examStageOrder;
+    }
+
+    public void setExamStageOrder(Integer examStageOrder) {
+        this.examStageOrder = examStageOrder;
+    }
+
 }

+ 8 - 8
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamStudentPropertyCacheBean.java

@@ -9,16 +9,16 @@ package cn.com.qmth.examcloud.support.cache.bean;
  */
 public class ExamStudentPropertyCacheBean extends ExamPropertyCacheBean {
 
-	private static final long serialVersionUID = -8521363493722068369L;
+    private static final long serialVersionUID = -8521363493722068369L;
 
-	private Long studentId;
+    private Long studentId;
 
-	public Long getStudentId() {
-		return studentId;
-	}
+    public Long getStudentId() {
+        return studentId;
+    }
 
-	public void setStudentId(Long studentId) {
-		this.studentId = studentId;
-	}
+    public void setStudentId(Long studentId) {
+        this.studentId = studentId;
+    }
 
 }

+ 1 - 1
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExamStudentSettingsCacheBean.java

@@ -9,6 +9,6 @@ package cn.com.qmth.examcloud.support.cache.bean;
  */
 public class ExamStudentSettingsCacheBean extends ExamSettingsCacheBean {
 
-	private static final long serialVersionUID = -8007446755455123835L;
+    private static final long serialVersionUID = -8007446755455123835L;
 
 }

+ 118 - 117
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExtractConfigCacheBean.java

@@ -1,130 +1,131 @@
 package cn.com.qmth.examcloud.support.cache.bean;
 
-import java.util.List;
-
 import cn.com.qmth.examcloud.api.commons.enums.CallType;
 import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
 
+import java.util.List;
+
 /**
  * @Description 调卷规则信息
  * @Author lideyin
  * @Date 2019/7/30 14:36
  */
 public class ExtractConfigCacheBean extends RandomCacheBean {
-	private static final long serialVersionUID = 6309635978462557320L;
-
-	/**
-	 * ID
-	 */
-	protected String id;
-
-	private CallType callType;
-
-	/**
-	 * 考试ID
-	 */
-	private Long examId;
-
-	/**
-	 * 课程代码
-	 */
-	private String courseCode;
-
-	/**
-	 * 抽取试卷对象集合
-	 */
-	private List<ExtractConfigDetailCacheBean> details;
-
-	/**
-	 * 是否小题乱序
-	 */
-	Boolean sortQuestionOrder;
-
-	/**
-	 * 是否选项乱序
-	 */
-	Boolean sortOptionOrder;
-
-	/**
-	 * 抽卷模板id
-	 */
-	private String randomPaperId;
-
-	/**
-	 * 播放次数限制
-	 */
-	private Integer playTime;
-
-	public String getId() {
-		return id;
-	}
-
-	public void setId(String id) {
-		this.id = id;
-	}
-
-	public Long getExamId() {
-		return examId;
-	}
-
-	public void setExamId(Long examId) {
-		this.examId = examId;
-	}
-
-	public String getCourseCode() {
-		return courseCode;
-	}
-
-	public void setCourseCode(String courseCode) {
-		this.courseCode = courseCode;
-	}
-
-	public List<ExtractConfigDetailCacheBean> getDetails() {
-		return details;
-	}
-
-	public void setDetails(List<ExtractConfigDetailCacheBean> details) {
-		this.details = details;
-	}
-
-	public Boolean getSortQuestionOrder() {
-		return sortQuestionOrder;
-	}
-
-	public void setSortQuestionOrder(Boolean sortQuestionOrder) {
-		this.sortQuestionOrder = sortQuestionOrder;
-	}
-
-	public Boolean getSortOptionOrder() {
-		return sortOptionOrder;
-	}
-
-	public void setSortOptionOrder(Boolean sortOptionOrder) {
-		this.sortOptionOrder = sortOptionOrder;
-	}
-
-	public String getRandomPaperId() {
-		return randomPaperId;
-	}
-
-	public void setRandomPaperId(String randomPaperId) {
-		this.randomPaperId = randomPaperId;
-	}
-
-	public Integer getPlayTime() {
-		return playTime;
-	}
-
-	public void setPlayTime(Integer playTime) {
-		this.playTime = playTime;
-	}
-
-	public CallType getCallType() {
-		return callType;
-	}
-
-	public void setCallType(CallType callType) {
-		this.callType = callType;
-	}
+
+    private static final long serialVersionUID = 6309635978462557320L;
+
+    /**
+     * ID
+     */
+    protected String id;
+
+    private CallType callType;
+
+    /**
+     * 考试ID
+     */
+    private Long examId;
+
+    /**
+     * 课程代码
+     */
+    private String courseCode;
+
+    /**
+     * 抽取试卷对象集合
+     */
+    private List<ExtractConfigDetailCacheBean> details;
+
+    /**
+     * 是否小题乱序
+     */
+    Boolean sortQuestionOrder;
+
+    /**
+     * 是否选项乱序
+     */
+    Boolean sortOptionOrder;
+
+    /**
+     * 抽卷模板id
+     */
+    private String randomPaperId;
+
+    /**
+     * 播放次数限制
+     */
+    private Integer playTime;
+
+    public String getId() {
+        return id;
+    }
+
+    public void setId(String id) {
+        this.id = id;
+    }
+
+    public Long getExamId() {
+        return examId;
+    }
+
+    public void setExamId(Long examId) {
+        this.examId = examId;
+    }
+
+    public String getCourseCode() {
+        return courseCode;
+    }
+
+    public void setCourseCode(String courseCode) {
+        this.courseCode = courseCode;
+    }
+
+    public List<ExtractConfigDetailCacheBean> getDetails() {
+        return details;
+    }
+
+    public void setDetails(List<ExtractConfigDetailCacheBean> details) {
+        this.details = details;
+    }
+
+    public Boolean getSortQuestionOrder() {
+        return sortQuestionOrder;
+    }
+
+    public void setSortQuestionOrder(Boolean sortQuestionOrder) {
+        this.sortQuestionOrder = sortQuestionOrder;
+    }
+
+    public Boolean getSortOptionOrder() {
+        return sortOptionOrder;
+    }
+
+    public void setSortOptionOrder(Boolean sortOptionOrder) {
+        this.sortOptionOrder = sortOptionOrder;
+    }
+
+    public String getRandomPaperId() {
+        return randomPaperId;
+    }
+
+    public void setRandomPaperId(String randomPaperId) {
+        this.randomPaperId = randomPaperId;
+    }
+
+    public Integer getPlayTime() {
+        return playTime;
+    }
+
+    public void setPlayTime(Integer playTime) {
+        this.playTime = playTime;
+    }
+
+    public CallType getCallType() {
+        return callType;
+    }
+
+    public void setCallType(CallType callType) {
+        this.callType = callType;
+    }
 
 }

+ 1 - 0
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExtractConfigDetailCacheBean.java

@@ -8,6 +8,7 @@ import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
  * @Date 2019/7/30 14:36
  */
 public class ExtractConfigDetailCacheBean extends RandomCacheBean {
+
     private static final long serialVersionUID = 6309635978462557320L;
 
     /**

+ 1 - 0
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ExtractConfigPaperCacheBean.java

@@ -9,6 +9,7 @@ import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
  * @Date 2019/7/30 14:36
  */
 public class ExtractConfigPaperCacheBean extends RandomCacheBean {
+
     private static final long serialVersionUID = 6309635978462557320L;
 
     /**

+ 50 - 52
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/OrgCacheBean.java

@@ -3,82 +3,80 @@ package cn.com.qmth.examcloud.support.cache.bean;
 import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
 
 /**
- * 
  * @author WANG
- *
  */
 public class OrgCacheBean extends RandomCacheBean {
 
-	private static final long serialVersionUID = -4045967342902486442L;
+    private static final long serialVersionUID = -4045967342902486442L;
 
-	private Long id;
+    private Long id;
 
-	private Long rootId;
+    private Long rootId;
 
-	private Long parentId;
+    private Long parentId;
 
-	private String name;
+    private String name;
 
-	private Boolean enable;
+    private Boolean enable;
 
-	private String code;
+    private String code;
 
-	private String domainName;
+    private String domainName;
 
-	public Long getId() {
-		return id;
-	}
+    public Long getId() {
+        return id;
+    }
 
-	public void setId(Long id) {
-		this.id = id;
-	}
+    public void setId(Long id) {
+        this.id = id;
+    }
 
-	public Long getRootId() {
-		return rootId;
-	}
+    public Long getRootId() {
+        return rootId;
+    }
 
-	public void setRootId(Long rootId) {
-		this.rootId = rootId;
-	}
+    public void setRootId(Long rootId) {
+        this.rootId = rootId;
+    }
 
-	public Long getParentId() {
-		return parentId;
-	}
+    public Long getParentId() {
+        return parentId;
+    }
 
-	public void setParentId(Long parentId) {
-		this.parentId = parentId;
-	}
+    public void setParentId(Long parentId) {
+        this.parentId = parentId;
+    }
 
-	public String getName() {
-		return name;
-	}
+    public String getName() {
+        return name;
+    }
 
-	public void setName(String name) {
-		this.name = name;
-	}
+    public void setName(String name) {
+        this.name = name;
+    }
 
-	public Boolean getEnable() {
-		return enable;
-	}
+    public Boolean getEnable() {
+        return enable;
+    }
 
-	public void setEnable(Boolean enable) {
-		this.enable = enable;
-	}
+    public void setEnable(Boolean enable) {
+        this.enable = enable;
+    }
 
-	public String getCode() {
-		return code;
-	}
+    public String getCode() {
+        return code;
+    }
 
-	public void setCode(String code) {
-		this.code = code;
-	}
+    public void setCode(String code) {
+        this.code = code;
+    }
 
-	public String getDomainName() {
-		return domainName;
-	}
+    public String getDomainName() {
+        return domainName;
+    }
 
-	public void setDomainName(String domainName) {
-		this.domainName = domainName;
-	}
+    public void setDomainName(String domainName) {
+        this.domainName = domainName;
+    }
 
 }

+ 22 - 22
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/OrgPropertyCacheBean.java

@@ -4,36 +4,36 @@ import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
 
 public class OrgPropertyCacheBean extends RandomCacheBean {
 
-	private static final long serialVersionUID = -8320620858676945769L;
+    private static final long serialVersionUID = -8320620858676945769L;
 
-	private Long orgId;
+    private Long orgId;
 
-	private String key;
+    private String key;
 
-	private String value;
+    private String value;
 
-	public Long getOrgId() {
-		return orgId;
-	}
+    public Long getOrgId() {
+        return orgId;
+    }
 
-	public void setOrgId(Long orgId) {
-		this.orgId = orgId;
-	}
+    public void setOrgId(Long orgId) {
+        this.orgId = orgId;
+    }
 
-	public String getKey() {
-		return key;
-	}
+    public String getKey() {
+        return key;
+    }
 
-	public void setKey(String key) {
-		this.key = key;
-	}
+    public void setKey(String key) {
+        this.key = key;
+    }
 
-	public String getValue() {
-		return value;
-	}
+    public String getValue() {
+        return value;
+    }
 
-	public void setValue(String value) {
-		this.value = value;
-	}
+    public void setValue(String value) {
+        this.value = value;
+    }
 
 }

+ 24 - 24
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/PrivilegeRolesCacheBean.java

@@ -1,41 +1,41 @@
 package cn.com.qmth.examcloud.support.cache.bean;
 
-import java.util.Set;
-
 import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
 
+import java.util.Set;
+
 public class PrivilegeRolesCacheBean extends RandomCacheBean {
 
-	private static final long serialVersionUID = 7517123394296666833L;
+    private static final long serialVersionUID = 7517123394296666833L;
 
-	private Long rootOrgId;
+    private Long rootOrgId;
 
-	private Set<Long> roleIdList;
+    private Set<Long> roleIdList;
 
-	private Set<String> roleCodeList;
+    private Set<String> roleCodeList;
 
-	public Long getRootOrgId() {
-		return rootOrgId;
-	}
+    public Long getRootOrgId() {
+        return rootOrgId;
+    }
 
-	public void setRootOrgId(Long rootOrgId) {
-		this.rootOrgId = rootOrgId;
-	}
+    public void setRootOrgId(Long rootOrgId) {
+        this.rootOrgId = rootOrgId;
+    }
 
-	public Set<Long> getRoleIdList() {
-		return roleIdList;
-	}
+    public Set<Long> getRoleIdList() {
+        return roleIdList;
+    }
 
-	public void setRoleIdList(Set<Long> roleIdList) {
-		this.roleIdList = roleIdList;
-	}
+    public void setRoleIdList(Set<Long> roleIdList) {
+        this.roleIdList = roleIdList;
+    }
 
-	public Set<String> getRoleCodeList() {
-		return roleCodeList;
-	}
+    public Set<String> getRoleCodeList() {
+        return roleCodeList;
+    }
 
-	public void setRoleCodeList(Set<String> roleCodeList) {
-		this.roleCodeList = roleCodeList;
-	}
+    public void setRoleCodeList(Set<String> roleCodeList) {
+        this.roleCodeList = roleCodeList;
+    }
 
 }

+ 1 - 0
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/QuestionAnswerCacheBean.java

@@ -10,6 +10,7 @@ import java.util.List;
  * @Date 2019/7/30 14:36
  */
 public class QuestionAnswerCacheBean extends RandomCacheBean {
+
     private static final long serialVersionUID = 6309635978462557320L;
 
     /**

+ 1 - 0
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/QuestionCacheBean.java

@@ -9,6 +9,7 @@ import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
  * @Date 2019/7/30 14:36
  */
 public class QuestionCacheBean extends RandomCacheBean {
+
     private static final long serialVersionUID = 6309635978462557320L;
 
     /**

+ 50 - 52
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/RootOrgCacheBean.java

@@ -3,82 +3,80 @@ package cn.com.qmth.examcloud.support.cache.bean;
 import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
 
 /**
- * 
  * @author WANG
- *
  */
 public class RootOrgCacheBean extends RandomCacheBean {
 
-	private static final long serialVersionUID = -4045967342902486442L;
+    private static final long serialVersionUID = -4045967342902486442L;
 
-	private Long id;
+    private Long id;
 
-	private Long rootId;
+    private Long rootId;
 
-	private Long parentId;
+    private Long parentId;
 
-	private String name;
+    private String name;
 
-	private Boolean enable;
+    private Boolean enable;
 
-	private String code;
+    private String code;
 
-	private String domainName;
+    private String domainName;
 
-	public Long getId() {
-		return id;
-	}
+    public Long getId() {
+        return id;
+    }
 
-	public void setId(Long id) {
-		this.id = id;
-	}
+    public void setId(Long id) {
+        this.id = id;
+    }
 
-	public Long getRootId() {
-		return rootId;
-	}
+    public Long getRootId() {
+        return rootId;
+    }
 
-	public void setRootId(Long rootId) {
-		this.rootId = rootId;
-	}
+    public void setRootId(Long rootId) {
+        this.rootId = rootId;
+    }
 
-	public Long getParentId() {
-		return parentId;
-	}
+    public Long getParentId() {
+        return parentId;
+    }
 
-	public void setParentId(Long parentId) {
-		this.parentId = parentId;
-	}
+    public void setParentId(Long parentId) {
+        this.parentId = parentId;
+    }
 
-	public String getName() {
-		return name;
-	}
+    public String getName() {
+        return name;
+    }
 
-	public void setName(String name) {
-		this.name = name;
-	}
+    public void setName(String name) {
+        this.name = name;
+    }
 
-	public Boolean getEnable() {
-		return enable;
-	}
+    public Boolean getEnable() {
+        return enable;
+    }
 
-	public void setEnable(Boolean enable) {
-		this.enable = enable;
-	}
+    public void setEnable(Boolean enable) {
+        this.enable = enable;
+    }
 
-	public String getCode() {
-		return code;
-	}
+    public String getCode() {
+        return code;
+    }
 
-	public void setCode(String code) {
-		this.code = code;
-	}
+    public void setCode(String code) {
+        this.code = code;
+    }
 
-	public String getDomainName() {
-		return domainName;
-	}
+    public String getDomainName() {
+        return domainName;
+    }
 
-	public void setDomainName(String domainName) {
-		this.domainName = domainName;
-	}
+    public void setDomainName(String domainName) {
+        this.domainName = domainName;
+    }
 
 }

+ 24 - 24
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/RootOrgPrivilegesCacheBean.java

@@ -1,41 +1,41 @@
 package cn.com.qmth.examcloud.support.cache.bean;
 
-import java.util.Set;
-
 import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
 
+import java.util.Set;
+
 public class RootOrgPrivilegesCacheBean extends RandomCacheBean {
 
-	private static final long serialVersionUID = 7517123394296666833L;
+    private static final long serialVersionUID = 7517123394296666833L;
 
-	private Long rootOrgId;
+    private Long rootOrgId;
 
-	private Set<Long> privilegeIdList;
+    private Set<Long> privilegeIdList;
 
-	private Set<String> privilegeCodeList;
+    private Set<String> privilegeCodeList;
 
-	public Long getRootOrgId() {
-		return rootOrgId;
-	}
+    public Long getRootOrgId() {
+        return rootOrgId;
+    }
 
-	public void setRootOrgId(Long rootOrgId) {
-		this.rootOrgId = rootOrgId;
-	}
+    public void setRootOrgId(Long rootOrgId) {
+        this.rootOrgId = rootOrgId;
+    }
 
-	public Set<Long> getPrivilegeIdList() {
-		return privilegeIdList;
-	}
+    public Set<Long> getPrivilegeIdList() {
+        return privilegeIdList;
+    }
 
-	public void setPrivilegeIdList(Set<Long> privilegeIdList) {
-		this.privilegeIdList = privilegeIdList;
-	}
+    public void setPrivilegeIdList(Set<Long> privilegeIdList) {
+        this.privilegeIdList = privilegeIdList;
+    }
 
-	public Set<String> getPrivilegeCodeList() {
-		return privilegeCodeList;
-	}
+    public Set<String> getPrivilegeCodeList() {
+        return privilegeCodeList;
+    }
 
-	public void setPrivilegeCodeList(Set<String> privilegeCodeList) {
-		this.privilegeCodeList = privilegeCodeList;
-	}
+    public void setPrivilegeCodeList(Set<String> privilegeCodeList) {
+        this.privilegeCodeList = privilegeCodeList;
+    }
 
 }

+ 192 - 191
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/SmsAssemblyCacheBean.java

@@ -7,200 +7,201 @@ import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
  */
 public class SmsAssemblyCacheBean extends RandomCacheBean {
 
-	private static final long serialVersionUID = 6227721820083892418L;
-
-	/**
-	 * 短信装配ID
-	 */
-	private Long id;
-
-	/**
-	 * 短信装配编码
-	 */
-	private String code;
-
-	/**
-	 * 短信装配名称
-	 */
-	private String name;
-
-	/**
-	 * 短信样例
-	 */
-	private String example;
-
-	/**
-	 * 短信模板
-	 */
-	private String template;
-
-	/**
-	 * 扩展属性1
-	 */
-	private String ext1;
-
-	/**
-	 * 扩展属性2
-	 */
-	private String ext2;
-
-	/**
-	 * 扩展属性3
-	 */
-	private String ext3;
-
-	/**
-	 * 扩展属性4
-	 */
-	private String ext4;
-
-	/**
-	 * 扩展属性5
-	 */
-	private String ext5;
-
-	/**
-	 * 扩展属性6
-	 */
-	private String ext6;
-
-	/**
-	 * 扩展属性7
-	 */
-	private String ext7;
-
-	/**
-	 * 扩展属性8
-	 */
-	private String ext8;
-
-	/**
-	 * 扩展属性9
-	 */
-	private String ext9;
-
-	/**
-	 * 扩展属性10
-	 */
-	private String ext10;
-
-	public Long getId() {
-		return id;
-	}
-
-	public void setId(Long id) {
-		this.id = id;
-	}
-
-	public String getCode() {
-		return code;
-	}
-
-	public void setCode(String code) {
-		this.code = code;
-	}
-
-	public String getName() {
-		return name;
-	}
-
-	public void setName(String name) {
-		this.name = name;
-	}
-
-	public String getExample() {
-		return example;
-	}
-
-	public void setExample(String example) {
-		this.example = example;
-	}
-
-	public String getTemplate() {
-		return template;
-	}
-
-	public void setTemplate(String template) {
-		this.template = template;
-	}
-
-	public String getExt1() {
-		return ext1;
-	}
-
-	public void setExt1(String ext1) {
-		this.ext1 = ext1;
-	}
-
-	public String getExt2() {
-		return ext2;
-	}
-
-	public void setExt2(String ext2) {
-		this.ext2 = ext2;
-	}
-
-	public String getExt3() {
-		return ext3;
-	}
-
-	public void setExt3(String ext3) {
-		this.ext3 = ext3;
-	}
-
-	public String getExt4() {
-		return ext4;
-	}
-
-	public void setExt4(String ext4) {
-		this.ext4 = ext4;
-	}
-
-	public String getExt5() {
-		return ext5;
-	}
-
-	public void setExt5(String ext5) {
-		this.ext5 = ext5;
-	}
-
-	public String getExt6() {
-		return ext6;
-	}
-
-	public void setExt6(String ext6) {
-		this.ext6 = ext6;
-	}
-
-	public String getExt7() {
-		return ext7;
-	}
-
-	public void setExt7(String ext7) {
-		this.ext7 = ext7;
-	}
-
-	public String getExt8() {
-		return ext8;
-	}
+    private static final long serialVersionUID = 6227721820083892418L;
+
+    /**
+     * 短信装配ID
+     */
+    private Long id;
+
+    /**
+     * 短信装配编码
+     */
+    private String code;
+
+    /**
+     * 短信装配名称
+     */
+    private String name;
+
+    /**
+     * 短信样例
+     */
+    private String example;
+
+    /**
+     * 短信模板
+     */
+    private String template;
+
+    /**
+     * 扩展属性1
+     */
+    private String ext1;
+
+    /**
+     * 扩展属性2
+     */
+    private String ext2;
+
+    /**
+     * 扩展属性3
+     */
+    private String ext3;
+
+    /**
+     * 扩展属性4
+     */
+    private String ext4;
+
+    /**
+     * 扩展属性5
+     */
+    private String ext5;
+
+    /**
+     * 扩展属性6
+     */
+    private String ext6;
+
+    /**
+     * 扩展属性7
+     */
+    private String ext7;
+
+    /**
+     * 扩展属性8
+     */
+    private String ext8;
+
+    /**
+     * 扩展属性9
+     */
+    private String ext9;
+
+    /**
+     * 扩展属性10
+     */
+    private String ext10;
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+
+    public String getCode() {
+        return code;
+    }
+
+    public void setCode(String code) {
+        this.code = code;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getExample() {
+        return example;
+    }
+
+    public void setExample(String example) {
+        this.example = example;
+    }
+
+    public String getTemplate() {
+        return template;
+    }
+
+    public void setTemplate(String template) {
+        this.template = template;
+    }
+
+    public String getExt1() {
+        return ext1;
+    }
+
+    public void setExt1(String ext1) {
+        this.ext1 = ext1;
+    }
+
+    public String getExt2() {
+        return ext2;
+    }
+
+    public void setExt2(String ext2) {
+        this.ext2 = ext2;
+    }
+
+    public String getExt3() {
+        return ext3;
+    }
+
+    public void setExt3(String ext3) {
+        this.ext3 = ext3;
+    }
+
+    public String getExt4() {
+        return ext4;
+    }
+
+    public void setExt4(String ext4) {
+        this.ext4 = ext4;
+    }
+
+    public String getExt5() {
+        return ext5;
+    }
+
+    public void setExt5(String ext5) {
+        this.ext5 = ext5;
+    }
 
-	public void setExt8(String ext8) {
-		this.ext8 = ext8;
-	}
+    public String getExt6() {
+        return ext6;
+    }
 
-	public String getExt9() {
-		return ext9;
-	}
+    public void setExt6(String ext6) {
+        this.ext6 = ext6;
+    }
 
-	public void setExt9(String ext9) {
-		this.ext9 = ext9;
-	}
+    public String getExt7() {
+        return ext7;
+    }
 
-	public String getExt10() {
-		return ext10;
-	}
+    public void setExt7(String ext7) {
+        this.ext7 = ext7;
+    }
+
+    public String getExt8() {
+        return ext8;
+    }
+
+    public void setExt8(String ext8) {
+        this.ext8 = ext8;
+    }
+
+    public String getExt9() {
+        return ext9;
+    }
+
+    public void setExt9(String ext9) {
+        this.ext9 = ext9;
+    }
+
+    public String getExt10() {
+        return ext10;
+    }
+
+    public void setExt10(String ext10) {
+        this.ext10 = ext10;
+    }
 
-	public void setExt10(String ext10) {
-		this.ext10 = ext10;
-	}
 }

+ 103 - 103
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/StudentCacheBean.java

@@ -1,143 +1,143 @@
 package cn.com.qmth.examcloud.support.cache.bean;
 
-import java.util.List;
-
 import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
 
+import java.util.List;
+
 public class StudentCacheBean extends RandomCacheBean {
 
-	private static final long serialVersionUID = 2870680150437521145L;
+    private static final long serialVersionUID = 2870680150437521145L;
 
-	private Long id;
+    private Long id;
 
-	private String name;
+    private String name;
 
-	private String identityNumber;
+    private String identityNumber;
 
-	private String photoPath;
+    private String photoPath;
 
-	private String remark;
+    private String remark;
 
-	private Boolean enable;
+    private Boolean enable;
 
-	private Long orgId;
+    private Long orgId;
 
-	private Long rootOrgId;
+    private Long rootOrgId;
 
-	/**
-	 * 手机号码
-	 */
-	private String phoneNumber;
+    /**
+     * 手机号码
+     */
+    private String phoneNumber;
 
-	/**
-	 * 安全手机号码(用于登录)
-	 */
-	private String securityPhone;
+    /**
+     * 安全手机号码(用于登录)
+     */
+    private String securityPhone;
 
-	/**
-	 * 学号集合
-	 */
-	private List<String> studentCodeList;
+    /**
+     * 学号集合
+     */
+    private List<String> studentCodeList;
 
-	/**
-	 * face++参数
-	 */
-	private String faceToken;
+    /**
+     * face++参数
+     */
+    private String faceToken;
 
-	public Long getId() {
-		return id;
-	}
+    public Long getId() {
+        return id;
+    }
 
-	public void setId(Long id) {
-		this.id = id;
-	}
+    public void setId(Long id) {
+        this.id = id;
+    }
 
-	public String getName() {
-		return name;
-	}
+    public String getName() {
+        return name;
+    }
 
-	public void setName(String name) {
-		this.name = name;
-	}
+    public void setName(String name) {
+        this.name = name;
+    }
 
-	public String getIdentityNumber() {
-		return identityNumber;
-	}
+    public String getIdentityNumber() {
+        return identityNumber;
+    }
 
-	public void setIdentityNumber(String identityNumber) {
-		this.identityNumber = identityNumber;
-	}
+    public void setIdentityNumber(String identityNumber) {
+        this.identityNumber = identityNumber;
+    }
 
-	public String getPhotoPath() {
-		return photoPath;
-	}
+    public String getPhotoPath() {
+        return photoPath;
+    }
 
-	public void setPhotoPath(String photoPath) {
-		this.photoPath = photoPath;
-	}
+    public void setPhotoPath(String photoPath) {
+        this.photoPath = photoPath;
+    }
 
-	public String getRemark() {
-		return remark;
-	}
+    public String getRemark() {
+        return remark;
+    }
 
-	public void setRemark(String remark) {
-		this.remark = remark;
-	}
+    public void setRemark(String remark) {
+        this.remark = remark;
+    }
 
-	public Boolean getEnable() {
-		return enable;
-	}
+    public Boolean getEnable() {
+        return enable;
+    }
 
-	public void setEnable(Boolean enable) {
-		this.enable = enable;
-	}
+    public void setEnable(Boolean enable) {
+        this.enable = enable;
+    }
 
-	public Long getOrgId() {
-		return orgId;
-	}
+    public Long getOrgId() {
+        return orgId;
+    }
 
-	public void setOrgId(Long orgId) {
-		this.orgId = orgId;
-	}
+    public void setOrgId(Long orgId) {
+        this.orgId = orgId;
+    }
 
-	public Long getRootOrgId() {
-		return rootOrgId;
-	}
+    public Long getRootOrgId() {
+        return rootOrgId;
+    }
 
-	public void setRootOrgId(Long rootOrgId) {
-		this.rootOrgId = rootOrgId;
-	}
+    public void setRootOrgId(Long rootOrgId) {
+        this.rootOrgId = rootOrgId;
+    }
 
-	public String getPhoneNumber() {
-		return phoneNumber;
-	}
+    public String getPhoneNumber() {
+        return phoneNumber;
+    }
 
-	public void setPhoneNumber(String phoneNumber) {
-		this.phoneNumber = phoneNumber;
-	}
+    public void setPhoneNumber(String phoneNumber) {
+        this.phoneNumber = phoneNumber;
+    }
 
-	public String getSecurityPhone() {
-		return securityPhone;
-	}
+    public String getSecurityPhone() {
+        return securityPhone;
+    }
 
-	public void setSecurityPhone(String securityPhone) {
-		this.securityPhone = securityPhone;
-	}
-
-	public List<String> getStudentCodeList() {
-		return studentCodeList;
-	}
-
-	public void setStudentCodeList(List<String> studentCodeList) {
-		this.studentCodeList = studentCodeList;
-	}
-
-	public String getFaceToken() {
-		return faceToken;
-	}
-
-	public void setFaceToken(String faceToken) {
-		this.faceToken = faceToken;
-	}
+    public void setSecurityPhone(String securityPhone) {
+        this.securityPhone = securityPhone;
+    }
+
+    public List<String> getStudentCodeList() {
+        return studentCodeList;
+    }
+
+    public void setStudentCodeList(List<String> studentCodeList) {
+        this.studentCodeList = studentCodeList;
+    }
+
+    public String getFaceToken() {
+        return faceToken;
+    }
+
+    public void setFaceToken(String faceToken) {
+        this.faceToken = faceToken;
+    }
 
 }

+ 15 - 15
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/SysPropertyCacheBean.java

@@ -5,26 +5,26 @@ import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
 
 public class SysPropertyCacheBean extends RandomCacheBean {
 
-	private static final long serialVersionUID = -8320620858676945769L;
+    private static final long serialVersionUID = -8320620858676945769L;
 
-	private BasicDataType valueType;
+    private BasicDataType valueType;
 
-	private Object value;
+    private Object value;
 
-	public BasicDataType getValueType() {
-		return valueType;
-	}
+    public BasicDataType getValueType() {
+        return valueType;
+    }
 
-	public void setValueType(BasicDataType valueType) {
-		this.valueType = valueType;
-	}
+    public void setValueType(BasicDataType valueType) {
+        this.valueType = valueType;
+    }
 
-	public Object getValue() {
-		return value;
-	}
+    public Object getValue() {
+        return value;
+    }
 
-	public void setValue(Object value) {
-		this.value = value;
-	}
+    public void setValue(Object value) {
+        this.value = value;
+    }
 
 }

+ 53 - 53
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/cache/bean/ThirdPartyAccessCacheBean.java

@@ -11,58 +11,58 @@ import cn.com.qmth.examcloud.web.cache.RandomCacheBean;
  */
 public class ThirdPartyAccessCacheBean extends RandomCacheBean {
 
-	private static final long serialVersionUID = 9212710623859419481L;
-
-	/**
-	 * 顶级机构ID
-	 */
-	private Long rootOrgId;
-
-	/**
-	 * 应用ID
-	 */
-	private String appId;
-
-	/**
-	 * 密钥
-	 */
-	private String secretKey;
-
-	/**
-	 * 时间差范围
-	 */
-	private Long timeRange;
-
-	public Long getRootOrgId() {
-		return rootOrgId;
-	}
-
-	public void setRootOrgId(Long rootOrgId) {
-		this.rootOrgId = rootOrgId;
-	}
-
-	public String getAppId() {
-		return appId;
-	}
-
-	public void setAppId(String appId) {
-		this.appId = appId;
-	}
-
-	public String getSecretKey() {
-		return secretKey;
-	}
-
-	public void setSecretKey(String secretKey) {
-		this.secretKey = secretKey;
-	}
-
-	public Long getTimeRange() {
-		return timeRange;
-	}
-
-	public void setTimeRange(Long timeRange) {
-		this.timeRange = timeRange;
-	}
+    private static final long serialVersionUID = 9212710623859419481L;
+
+    /**
+     * 顶级机构ID
+     */
+    private Long rootOrgId;
+
+    /**
+     * 应用ID
+     */
+    private String appId;
+
+    /**
+     * 密钥
+     */
+    private String secretKey;
+
+    /**
+     * 时间差范围
+     */
+    private Long timeRange;
+
+    public Long getRootOrgId() {
+        return rootOrgId;
+    }
+
+    public void setRootOrgId(Long rootOrgId) {
+        this.rootOrgId = rootOrgId;
+    }
+
+    public String getAppId() {
+        return appId;
+    }
+
+    public void setAppId(String appId) {
+        this.appId = appId;
+    }
+
+    public String getSecretKey() {
+        return secretKey;
+    }
+
+    public void setSecretKey(String secretKey) {
+        this.secretKey = secretKey;
+    }
+
+    public Long getTimeRange() {
+        return timeRange;
+    }
+
+    public void setTimeRange(Long timeRange) {
+        this.timeRange = timeRange;
+    }
 
 }

+ 6 - 2
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/enums/ExamProcess.java

@@ -13,7 +13,9 @@ public enum ExamProcess {
     CONTINUE("CONTINUE", "断点续考"),
     AUTO_HAND_IN("AUTO_HAND_IN", "服务端交卷"),
     MANUAL_HAND_IN("MANUAL_HAND_IN", "考生端交卷");
+
     private String code;
+
     private String desc;
 
     ExamProcess(String code, String desc) {
@@ -23,17 +25,19 @@ public enum ExamProcess {
 
     /**
      * 考试过程代码
+     *
      * @return
      */
-    public String getCode(){
+    public String getCode() {
         return this.code;
     }
 
     /**
      * 考试过程描述
+     *
      * @return
      */
-    public String getDesc(){
+    public String getDesc() {
         return this.desc;
     }
 }

+ 1 - 1
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/enums/ExamRecordStatus.java

@@ -33,7 +33,7 @@ public enum ExamRecordStatus {
      * 考试无效/作废
      */
     EXAM_INVALID,
-    
+
     /**
      * 考试异常数据
      */

+ 38 - 38
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/enums/IsSuccess.java

@@ -3,46 +3,46 @@ package cn.com.qmth.examcloud.support.enums;
 import org.apache.commons.lang3.StringUtils;
 
 /**
- * @author  	chenken
- * @date    	2018年2月26日 下午3:13:05
- * @company 	QMTH
+ * @author chenken
+ * @date 2018年2月26日 下午3:13:05
+ * @company QMTH
  * @description 成功或失败
  */
 public enum IsSuccess {
-	/**
-	 * 成功
-	 */
-	SUCCESS("成功"),
-	/**
-	 * 失败
-	 */
-	FAILED("失败");
-	
-	private String desc;
-	
-	public static IsSuccess strToEnum(String name){
-		if(StringUtils.isBlank(name)){
-			return null;
-		}
-		for(IsSuccess isSuccess:IsSuccess.values()){
-			if(name.equals(isSuccess.name())){
-				return isSuccess;
-			}
-		}
-		
-		return null;
-	}
-	
-	private IsSuccess(String desc){
-		this.desc = desc;
-	}
-	
-	public String getDesc() {
-		return desc;
-	}
-
-	public void setDesc(String desc) {
-		this.desc = desc;
-	}
+    /**
+     * 成功
+     */
+    SUCCESS("成功"),
+    /**
+     * 失败
+     */
+    FAILED("失败");
+
+    private String desc;
+
+    public static IsSuccess strToEnum(String name) {
+        if (StringUtils.isBlank(name)) {
+            return null;
+        }
+        for (IsSuccess isSuccess : IsSuccess.values()) {
+            if (name.equals(isSuccess.name())) {
+                return isSuccess;
+            }
+        }
+
+        return null;
+    }
+
+    private IsSuccess(String desc) {
+        this.desc = desc;
+    }
+
+    public String getDesc() {
+        return desc;
+    }
+
+    public void setDesc(String desc) {
+        this.desc = desc;
+    }
 }
 

+ 30 - 30
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamBoss.java

@@ -1,9 +1,9 @@
 package cn.com.qmth.examcloud.support.examing;
 
-import java.util.List;
-
 import cn.com.qmth.examcloud.api.commons.exchange.JsonSerializable;
 
+import java.util.List;
+
 /**
  * 考试控制属性<br>
  * ExamBoss存储于redis,无过期时间<br>
@@ -17,45 +17,45 @@ import cn.com.qmth.examcloud.api.commons.exchange.JsonSerializable;
  */
 public class ExamBoss implements JsonSerializable {
 
-	private static final long serialVersionUID = -3499412275759440367L;
+    private static final long serialVersionUID = -3499412275759440367L;
 
-	/**
-	 * 开考次数
-	 */
-	private int startCount;
+    /**
+     * 开考次数
+     */
+    private int startCount;
 
-	/**
-	 * 完结次数
-	 */
-	private int endCount;
-	
-	/**
-	 * 未同步的考试记录id
-	 */
-	private List<Long> examRecordDataIds;
+    /**
+     * 完结次数
+     */
+    private int endCount;
 
-	public int getStartCount() {
-		return startCount;
-	}
+    /**
+     * 未同步的考试记录id
+     */
+    private List<Long> examRecordDataIds;
 
-	public void setStartCount(int startCount) {
-		this.startCount = startCount;
-	}
+    public int getStartCount() {
+        return startCount;
+    }
 
-	public int getEndCount() {
-		return endCount;
-	}
+    public void setStartCount(int startCount) {
+        this.startCount = startCount;
+    }
+
+    public int getEndCount() {
+        return endCount;
+    }
+
+    public void setEndCount(int endCount) {
+        this.endCount = endCount;
+    }
 
-	public void setEndCount(int endCount) {
-		this.endCount = endCount;
-	}
 
-    
     public List<Long> getExamRecordDataIds() {
         return examRecordDataIds;
     }
 
-    
+
     public void setExamRecordDataIds(List<Long> examRecordDataIds) {
         this.examRecordDataIds = examRecordDataIds;
     }

+ 94 - 86
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamFileAnswer.java

@@ -11,90 +11,98 @@ import cn.com.qmth.examcloud.support.enums.FileAnswerAcknowledgeStatus;
  */
 public class ExamFileAnswer implements JsonSerializable {
 
-	private static final long serialVersionUID = -7441792839367736076L;
-	/**
-	 * 主键id
-	 */
-	private Long id;
-	/**
-	 * 考试记录id
-	 */
-	private Long examRecordDataId;
-	/**
-	 * 考生id
-	 */
-	private Long examStudentId;
-	/**
-	 * 小题序号
-	 */
-	private Integer questionOrder;
-	/**
-	 * 文件路径
-	 */
-	private String filePath;
-	/**
-	 * 文件作答的响应状态
-	 */
-	private FileAnswerAcknowledgeStatus status;
-	/**
-	 * 传输文件的类型(PIC | AUDIO)
-	 */
-	private String transferFileType;
-
-	public Long getId() {
-		return id;
-	}
-
-	public void setId(Long id) {
-		this.id = id;
-	}
-
-	public Long getExamRecordDataId() {
-		return examRecordDataId;
-	}
-
-	public void setExamRecordDataId(Long examRecordDataId) {
-		this.examRecordDataId = examRecordDataId;
-	}
-
-	public Long getExamStudentId() {
-		return examStudentId;
-	}
-
-	public void setExamStudentId(Long examStudentId) {
-		this.examStudentId = examStudentId;
-	}
-
-
-	public Integer getQuestionOrder() {
-		return questionOrder;
-	}
-
-	public void setQuestionOrder(Integer questionOrder) {
-		this.questionOrder = questionOrder;
-	}
-
-	public String getFilePath() {
-		return filePath;
-	}
-
-	public void setFilePath(String filePath) {
-		this.filePath = filePath;
-	}
-
-	public FileAnswerAcknowledgeStatus getStatus() {
-		return status;
-	}
-
-	public void setStatus(FileAnswerAcknowledgeStatus status) {
-		this.status = status;
-	}
-
-	public String getTransferFileType() {
-		return transferFileType;
-	}
-
-	public void setTransferFileType(String transferFileType) {
-		this.transferFileType = transferFileType;
-	}
+    private static final long serialVersionUID = -7441792839367736076L;
+
+    /**
+     * 主键id
+     */
+    private Long id;
+
+    /**
+     * 考试记录id
+     */
+    private Long examRecordDataId;
+
+    /**
+     * 考生id
+     */
+    private Long examStudentId;
+
+    /**
+     * 小题序号
+     */
+    private Integer questionOrder;
+
+    /**
+     * 文件路径
+     */
+    private String filePath;
+
+    /**
+     * 文件作答的响应状态
+     */
+    private FileAnswerAcknowledgeStatus status;
+
+    /**
+     * 传输文件的类型(PIC | AUDIO)
+     */
+    private String transferFileType;
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+
+    public Long getExamRecordDataId() {
+        return examRecordDataId;
+    }
+
+    public void setExamRecordDataId(Long examRecordDataId) {
+        this.examRecordDataId = examRecordDataId;
+    }
+
+    public Long getExamStudentId() {
+        return examStudentId;
+    }
+
+    public void setExamStudentId(Long examStudentId) {
+        this.examStudentId = examStudentId;
+    }
+
+
+    public Integer getQuestionOrder() {
+        return questionOrder;
+    }
+
+    public void setQuestionOrder(Integer questionOrder) {
+        this.questionOrder = questionOrder;
+    }
+
+    public String getFilePath() {
+        return filePath;
+    }
+
+    public void setFilePath(String filePath) {
+        this.filePath = filePath;
+    }
+
+    public FileAnswerAcknowledgeStatus getStatus() {
+        return status;
+    }
+
+    public void setStatus(FileAnswerAcknowledgeStatus status) {
+        this.status = status;
+    }
+
+    public String getTransferFileType() {
+        return transferFileType;
+    }
+
+    public void setTransferFileType(String transferFileType) {
+        this.transferFileType = transferFileType;
+    }
+
 }

+ 187 - 153
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamQuestion.java

@@ -1,12 +1,11 @@
 package cn.com.qmth.examcloud.support.examing;
 
-import java.io.Serializable;
+import cn.com.qmth.examcloud.question.commons.core.question.AnswerType;
+import cn.com.qmth.examcloud.question.commons.core.question.QuestionType;
 
 import javax.persistence.EnumType;
 import javax.persistence.Enumerated;
-
-import cn.com.qmth.examcloud.question.commons.core.question.AnswerType;
-import cn.com.qmth.examcloud.question.commons.core.question.QuestionType;
+import java.io.Serializable;
 
 /**
  * @author chenken
@@ -14,216 +13,251 @@ import cn.com.qmth.examcloud.question.commons.core.question.QuestionType;
  * @company QMTH
  * @description 考生单题作答记录
  */
-public class ExamQuestion implements Serializable{
+public class ExamQuestion implements Serializable {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -6141069483774400912L;
 
     /**
-	 * 
-	 */
-	private static final long serialVersionUID = -6141069483774400912L;
-	
-	/**
      * 作答记录是否在mongo
      */
     private Boolean isInMongo;
-    
+
     /**
      * 作答记录在mongo中的id
      */
     private String examQuestionTempId;
-	
-	/**
-	 * 考试记录Data Id
-	 */
+
+    /**
+     * 考试记录Data Id
+     */
     private Long examRecordDataId;
+
     /**
      * 大题号
      */
     private Integer mainNumber;
+
     /**
      * 原题ID
      */
     private String questionId;
+
     /**
      * 顺序
      */
     private Integer order;
+
     /**
      * 小题分数
      */
     private Double questionScore;
+
     /**
      * 小题类型
      */
     private QuestionType questionType;
+
     /**
      * 标准答案
      */
     private String correctAnswer;
+
     /**
      * 考生作答
      */
     private String studentAnswer;
+
     /**
      * 学生小题得分
      */
     private Double studentScore;
+
     /**
      * 是否作答
      */
     private Boolean isAnswer;
+
     /**
      * 是否标记
      */
     private Boolean isSign;
-    
-    /**
-	 * 选项排序值
-	 */
-	private Integer[] optionPermutation;
-	
-	/**
-	 * 音频播放次数
-	 */
-	private String audioPlayTimes;
-	/**
-	 * 题目作答类型
-	 */
-	@Enumerated(EnumType.STRING)
-	private AnswerType answerType;	
-	
-	public Long getExamRecordDataId() {
-		return examRecordDataId;
-	}
-	public void setExamRecordDataId(Long examRecordDataId) {
-		this.examRecordDataId = examRecordDataId;
-	}
-	public Integer getMainNumber() {
-		return mainNumber;
-	}
-	/**
-	 * 设置 大题号
-	 * @param mainNumber
-	 */
-	public void setMainNumber(Integer mainNumber) {
-		this.mainNumber = mainNumber;
-	}
-	public String getQuestionId() {
-		return questionId;
-	}
-	/**
-	 * 设置题库试题ID
-	 * @param questionId
-	 */
-	public void setQuestionId(String questionId) {
-		this.questionId = questionId;
-	}
-	public Integer getOrder() {
-		return order;
-	}
-	/**
-	 * 设置小题号
-	 * @param order
-	 */
-	public void setOrder(Integer order) {
-		this.order = order;
-	}
-	public String getStudentAnswer() {
-		return studentAnswer;
-	}
-	public void setStudentAnswer(String studentAnswer) {
-		this.studentAnswer = studentAnswer;
-	}
-	public Double getStudentScore() {
-		return studentScore;
-	}
-	/**
-	 * 设置考生得分
-	 * @param studentScore
-	 */
-	public void setStudentScore(Double studentScore) {
-		this.studentScore = studentScore;
-	}
-	public Double getQuestionScore() {
-		return questionScore;
-	}
-	/**
-	 * 设置试题分数
-	 * @param questionScore
-	 */
-	public void setQuestionScore(Double questionScore) {
-		this.questionScore = questionScore;
-	}
-	public QuestionType getQuestionType() {
-		return questionType;
-	}
-	/**
-	 * 设置题型
-	 * @param questionType
-	 */
-	public void setQuestionType(QuestionType questionType) {
-		this.questionType = questionType;
-	}
-	public Boolean getIsAnswer() {
-		return isAnswer;
-	}
-	public void setIsAnswer(Boolean isAnswer) {
-		this.isAnswer = isAnswer;
-	}
-	public Boolean getIsSign() {
-		return isSign;
-	}
-	public void setIsSign(Boolean isSign) {
-		this.isSign = isSign;
-	}
-
-	public String getCorrectAnswer() {
-		return correctAnswer;
-	}
-
-	public void setCorrectAnswer(String correctAnswer) {
-		this.correctAnswer = correctAnswer;
-	}
-
-	public Integer[] getOptionPermutation() {
-		return optionPermutation;
-	}
-
-	public void setOptionPermutation(Integer[] optionPermutation) {
-		this.optionPermutation = optionPermutation;
-	}
-
-	public String getAudioPlayTimes() {
-		return audioPlayTimes;
-	}
-
-	public void setAudioPlayTimes(String audioPlayTimes) {
-		this.audioPlayTimes = audioPlayTimes;
-	}
-
-	public AnswerType getAnswerType() {
-		return answerType;
-	}
-
-	public void setAnswerType(AnswerType answerType) {
-		this.answerType = answerType;
-	}
-    
+
+    /**
+     * 选项排序值
+     */
+    private Integer[] optionPermutation;
+
+    /**
+     * 音频播放次数
+     */
+    private String audioPlayTimes;
+
+    /**
+     * 题目作答类型
+     */
+    @Enumerated(EnumType.STRING)
+    private AnswerType answerType;
+
+    public Long getExamRecordDataId() {
+        return examRecordDataId;
+    }
+
+    public void setExamRecordDataId(Long examRecordDataId) {
+        this.examRecordDataId = examRecordDataId;
+    }
+
+    public Integer getMainNumber() {
+        return mainNumber;
+    }
+
+    /**
+     * 设置 大题号
+     *
+     * @param mainNumber
+     */
+    public void setMainNumber(Integer mainNumber) {
+        this.mainNumber = mainNumber;
+    }
+
+    public String getQuestionId() {
+        return questionId;
+    }
+
+    /**
+     * 设置题库试题ID
+     *
+     * @param questionId
+     */
+    public void setQuestionId(String questionId) {
+        this.questionId = questionId;
+    }
+
+    public Integer getOrder() {
+        return order;
+    }
+
+    /**
+     * 设置小题号
+     *
+     * @param order
+     */
+    public void setOrder(Integer order) {
+        this.order = order;
+    }
+
+    public String getStudentAnswer() {
+        return studentAnswer;
+    }
+
+    public void setStudentAnswer(String studentAnswer) {
+        this.studentAnswer = studentAnswer;
+    }
+
+    public Double getStudentScore() {
+        return studentScore;
+    }
+
+    /**
+     * 设置考生得分
+     *
+     * @param studentScore
+     */
+    public void setStudentScore(Double studentScore) {
+        this.studentScore = studentScore;
+    }
+
+    public Double getQuestionScore() {
+        return questionScore;
+    }
+
+    /**
+     * 设置试题分数
+     *
+     * @param questionScore
+     */
+    public void setQuestionScore(Double questionScore) {
+        this.questionScore = questionScore;
+    }
+
+    public QuestionType getQuestionType() {
+        return questionType;
+    }
+
+    /**
+     * 设置题型
+     *
+     * @param questionType
+     */
+    public void setQuestionType(QuestionType questionType) {
+        this.questionType = questionType;
+    }
+
+    public Boolean getIsAnswer() {
+        return isAnswer;
+    }
+
+    public void setIsAnswer(Boolean isAnswer) {
+        this.isAnswer = isAnswer;
+    }
+
+    public Boolean getIsSign() {
+        return isSign;
+    }
+
+    public void setIsSign(Boolean isSign) {
+        this.isSign = isSign;
+    }
+
+    public String getCorrectAnswer() {
+        return correctAnswer;
+    }
+
+    public void setCorrectAnswer(String correctAnswer) {
+        this.correctAnswer = correctAnswer;
+    }
+
+    public Integer[] getOptionPermutation() {
+        return optionPermutation;
+    }
+
+    public void setOptionPermutation(Integer[] optionPermutation) {
+        this.optionPermutation = optionPermutation;
+    }
+
+    public String getAudioPlayTimes() {
+        return audioPlayTimes;
+    }
+
+    public void setAudioPlayTimes(String audioPlayTimes) {
+        this.audioPlayTimes = audioPlayTimes;
+    }
+
+    public AnswerType getAnswerType() {
+        return answerType;
+    }
+
+    public void setAnswerType(AnswerType answerType) {
+        this.answerType = answerType;
+    }
+
     public String getExamQuestionTempId() {
         return examQuestionTempId;
     }
-    
+
     public void setExamQuestionTempId(String examQuestionTempId) {
         this.examQuestionTempId = examQuestionTempId;
     }
-    
+
     public Boolean getIsInMongo() {
         return isInMongo;
     }
-    
+
     public void setIsInMongo(Boolean isInMongo) {
         this.isInMongo = isInMongo;
     }
 
-	
-	
+
 }

+ 26 - 27
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamRecordPaperStruct.java

@@ -1,41 +1,40 @@
 package cn.com.qmth.examcloud.support.examing;
 
-import java.io.Serializable;
-
 import cn.com.qmth.examcloud.question.commons.core.paper.DefaultPaper;
 
+import java.io.Serializable;
+
 /**
- * 
- * @author  	chenken
- * @date    	2018年8月27日 下午3:26:27
- * @company 	QMTH
+ * @author chenken
+ * @date 2018年8月27日 下午3:26:27
+ * @company QMTH
  * @description ExamRecordPaper.java
  */
-public class ExamRecordPaperStruct implements Serializable{
+public class ExamRecordPaperStruct implements Serializable {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -4672132535133881321L;
+
+    private String id;
 
-	/**
-	 * 
-	 */
-	private static final long serialVersionUID = -4672132535133881321L;
+    private DefaultPaper defaultPaper;
 
-	private String id;
-	
-	private DefaultPaper defaultPaper;
+    public String getId() {
+        return id;
+    }
 
-	public String getId() {
-		return id;
-	}
+    public void setId(String id) {
+        this.id = id;
+    }
 
-	public void setId(String id) {
-		this.id = id;
-	}
+    public DefaultPaper getDefaultPaper() {
+        return defaultPaper;
+    }
 
-	public DefaultPaper getDefaultPaper() {
-		return defaultPaper;
-	}
+    public void setDefaultPaper(DefaultPaper defaultPaper) {
+        this.defaultPaper = defaultPaper;
+    }
 
-	public void setDefaultPaper(DefaultPaper defaultPaper) {
-		this.defaultPaper = defaultPaper;
-	}
-	
 }

+ 3 - 2
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamRecordQuestions.java

@@ -11,6 +11,7 @@ import java.util.List;
  * @description 考试作答试题集合
  */
 public class ExamRecordQuestions implements Serializable {
+
     private static final long serialVersionUID = -1688201571728312142L;
 
     private Long examRecordDataId;
@@ -35,12 +36,12 @@ public class ExamRecordQuestions implements Serializable {
         this.examRecordDataId = examRecordDataId;
     }
 
-    
+
     public List<ExamQuestion> getExamQuestions() {
         return examQuestions;
     }
 
-    
+
     public void setExamQuestions(List<ExamQuestion> examQuestions) {
         this.examQuestions = examQuestions;
     }

+ 41 - 40
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamingActivityTime.java

@@ -11,44 +11,45 @@ import cn.com.qmth.examcloud.api.commons.exchange.JsonSerializable;
  */
 public class ExamingActivityTime implements JsonSerializable {
 
-	private static final long serialVersionUID = 380814978042469776L;
-
-	/**
-	 * 考试记录ID
-	 */
-	private Long examRecordDataId;
-
-	/**
-	 * 学生最后活动时间
-	 */
-	private Long activeTime;
-
-	/**
-	 *  真实ip
-	 */
-	private String realIp;
-
-	public Long getExamRecordDataId() {
-		return examRecordDataId;
-	}
-
-	public void setExamRecordDataId(Long examRecordDataId) {
-		this.examRecordDataId = examRecordDataId;
-	}
-
-	public Long getActiveTime() {
-		return activeTime;
-	}
-
-	public void setActiveTime(Long activeTime) {
-		this.activeTime = activeTime;
-	}
-
-	public String getRealIp() {
-		return realIp;
-	}
-
-	public void setRealIp(String realIp) {
-		this.realIp = realIp;
-	}
+    private static final long serialVersionUID = 380814978042469776L;
+
+    /**
+     * 考试记录ID
+     */
+    private Long examRecordDataId;
+
+    /**
+     * 学生最后活动时间
+     */
+    private Long activeTime;
+
+    /**
+     * 真实ip
+     */
+    private String realIp;
+
+    public Long getExamRecordDataId() {
+        return examRecordDataId;
+    }
+
+    public void setExamRecordDataId(Long examRecordDataId) {
+        this.examRecordDataId = examRecordDataId;
+    }
+
+    public Long getActiveTime() {
+        return activeTime;
+    }
+
+    public void setActiveTime(Long activeTime) {
+        this.activeTime = activeTime;
+    }
+
+    public String getRealIp() {
+        return realIp;
+    }
+
+    public void setRealIp(String realIp) {
+        this.realIp = realIp;
+    }
+
 }

+ 44 - 43
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamingHeartbeat.java

@@ -10,48 +10,49 @@ import cn.com.qmth.examcloud.api.commons.exchange.JsonSerializable;
  * @Copyright (c) 2018-? http://qmth.com.cn All Rights Reserved.
  */
 public class ExamingHeartbeat implements JsonSerializable {
-	private static final long serialVersionUID = 2981954395650966836L;
-
-	/**
-	 * 考试记录ID
-	 */
-	private Long examRecordDataId;
-
-	/**
-	 * 心跳次数
-	 */
-	@Deprecated
-	private Long times;
-
-	/**
-	 * 耗时(单位:秒)
-	 */
-	private Long cost;
-
-	public Long getExamRecordDataId() {
-		return examRecordDataId;
-	}
-
-	public void setExamRecordDataId(Long examRecordDataId) {
-		this.examRecordDataId = examRecordDataId;
-	}
-
-	@Deprecated
-	public Long getTimes() {
-		return times;
-	}
-
-	@Deprecated
-	public void setTimes(Long times) {
-		this.times = times;
-	}
-
-	public Long getCost() {
-		return cost;
-	}
-
-	public void setCost(Long cost) {
-		this.cost = cost;
-	}
+
+    private static final long serialVersionUID = 2981954395650966836L;
+
+    /**
+     * 考试记录ID
+     */
+    private Long examRecordDataId;
+
+    /**
+     * 心跳次数
+     */
+    @Deprecated
+    private Long times;
+
+    /**
+     * 耗时(单位:秒)
+     */
+    private Long cost;
+
+    public Long getExamRecordDataId() {
+        return examRecordDataId;
+    }
+
+    public void setExamRecordDataId(Long examRecordDataId) {
+        this.examRecordDataId = examRecordDataId;
+    }
+
+    @Deprecated
+    public Long getTimes() {
+        return times;
+    }
+
+    @Deprecated
+    public void setTimes(Long times) {
+        this.times = times;
+    }
+
+    public Long getCost() {
+        return cost;
+    }
+
+    public void setCost(Long cost) {
+        this.cost = cost;
+    }
 
 }

+ 8 - 8
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/examing/ExamingStatus.java

@@ -9,14 +9,14 @@ package cn.com.qmth.examcloud.support.examing;
  */
 public enum ExamingStatus {
 
-	/**
-	 * 非正式状态
-	 */
-	INFORMAL,
+    /**
+     * 非正式状态
+     */
+    INFORMAL,
 
-	/**
-	 * 正式状态
-	 */
-	FORMAL
+    /**
+     * 正式状态
+     */
+    FORMAL
 
 }

+ 7 - 3
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ColumnSetting.java

@@ -6,8 +6,11 @@ package cn.com.qmth.examcloud.support.excel;
 public class ColumnSetting implements Comparable<ColumnSetting> {
 
     private String header;
+
     private String getMethodName;
+
     private int width;
+
     private int index;
 
     public ColumnSetting(String header, String getMethodName, int width, int index) {
@@ -53,9 +56,10 @@ public class ColumnSetting implements Comparable<ColumnSetting> {
     @Override
     public int compareTo(ColumnSetting columnSetting) {
         if (index < columnSetting.getIndex())
-            return - 1 ;
+            return -1;
         if (index > columnSetting.getIndex())
-            return 1 ;
-        return 0 ;
+            return 1;
+        return 0;
     }
+
 }

+ 22 - 21
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelCell.java

@@ -2,34 +2,35 @@ package cn.com.qmth.examcloud.support.excel;
 
 public class ExcelCell {
 
-	private String r;
+    private String r;
 
-	private String s;
-	private String v;
+    private String s;
 
-	public String getR() {
-		return r;
-	}
+    private String v;
 
-	public void setR(String r) {
-		this.r = r;
-	}
+    public String getR() {
+        return r;
+    }
 
-	public String getS() {
-		return s;
-	}
+    public void setR(String r) {
+        this.r = r;
+    }
 
-	public void setS(String s) {
-		this.s = s;
-	}
+    public String getS() {
+        return s;
+    }
 
+    public void setS(String s) {
+        this.s = s;
+    }
 
-	public String getV() {
-		return v;
-	}
 
-	public void setV(String v) {
-		this.v = v;
-	}
+    public String getV() {
+        return v;
+    }
+
+    public void setV(String v) {
+        this.v = v;
+    }
 
 }

+ 40 - 39
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelError.java

@@ -1,48 +1,49 @@
 package cn.com.qmth.examcloud.support.excel;
+
 /**
- * 
- * @Description: excel导入错误
  * @author ting.yin
+ * @Description: excel导入错误
  * @date 2016年8月19日
  */
 public class ExcelError {
 
-	/**
-	 * 错误行数
-	 */
-	private int row;
-
-	/**
-	 * 错误类型
-	 */
-	private String excelErrorType;
-
-	public ExcelError() {
-
-	}
-
-	public ExcelError(int row, String excelErrorType) {
-		this.row = row;
-		this.excelErrorType = excelErrorType;
-	}
-	
-	public ExcelError(String excelErrorType) {
-		this.excelErrorType = excelErrorType;
-	}
-	public int getRow() {
-		return row;
-	}
-
-	public void setRow(int row) {
-		this.row = row;
-	}
-
-	public String getExcelErrorType() {
-		return excelErrorType;
-	}
-
-	public void setExcelErrorType(String excelErrorType) {
-		this.excelErrorType = excelErrorType;
-	}
+    /**
+     * 错误行数
+     */
+    private int row;
+
+    /**
+     * 错误类型
+     */
+    private String excelErrorType;
+
+    public ExcelError() {
+
+    }
+
+    public ExcelError(int row, String excelErrorType) {
+        this.row = row;
+        this.excelErrorType = excelErrorType;
+    }
+
+    public ExcelError(String excelErrorType) {
+        this.excelErrorType = excelErrorType;
+    }
+
+    public int getRow() {
+        return row;
+    }
+
+    public void setRow(int row) {
+        this.row = row;
+    }
+
+    public String getExcelErrorType() {
+        return excelErrorType;
+    }
+
+    public void setExcelErrorType(String excelErrorType) {
+        this.excelErrorType = excelErrorType;
+    }
 
 }

+ 83 - 88
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelErrorType.java

@@ -1,98 +1,93 @@
 package cn.com.qmth.examcloud.support.excel;
 
 /**
- * 
- * @Description: excel导入错误类型
  * @author ting.yin
+ * @Description: excel导入错误类型
  * @date 2016年8月19日
  */
 public enum ExcelErrorType {
 
-	NOT_CAMPUS("学习中心不存在"),
-
-	NOT_EXAM_SITE("学习中心下的考点不存在"),
-	
-	EXAM_SITE_CODE("考点代码为空或格式错误,只能包含数字,英文字母"),
-	
-	EXAM_SITE_CODE_LENGTH("考点代码必须在1-15个字符"),
-	
-	EXAM_SITE_NAME_LENGTH("考点名称必须在1-50个字符"),
-	
-	CAMPUS_CODE("学习中心代码为空或格式错误,只能包含数字,英文字母"),
-	
-	CAMPUS_CODE_LENGTH("学习中心代码必须在1-15个字符"),
-	
-	CAMPUS_NAME_LENGTH("学习中心名必须在1-50个字符"),
-
-	COURSE_CODE("课程代码格式错误,只能包含数字,英文字母"),
-
-	SPECIALTY_CODE("专业代码格式错误,只能包含数字,英文字母"),
-	
-	ONLY_EXAM_NUMBER("准考证号重复"),
-	
-	STUDENT_NAME_NULL("考生姓名不能为空"),
-	
-	STUDENT_NAME_LENGTH("考生姓名必须在1-50个字符"),
-	
-	STUDENT_SEX_NULL("考生性别不能为空"),
-	
-	STUDENT_CODE_NULL("考生学号不能为空"),
-	
-	STUDENT_CODE_LENGTH("考生学号必须在6-15个字符"),
-	
-	CAMPUS_NAME_NULL("学习中心名称不能为空"),
-	
-	COURSE_NAME_NULL("课程名称不能为空"),
-	
-	COURSE_CODE_NULL("课程代码不能为空"),
-	
-	SPECIALTY_NAME_NULL("专业名称不能为空"),
-	
-	SPECIALTY_CODE_NULL("专业代码不能为空"),
-	
-	EXCEL_FORMAT_ERROR("Excel文件格式错误"),
-	
-	EXAM_SITE_NAME_NULL("考点名称不能为空"),
-	
-	GRADE_NULL("年级不能为空"),
-	
-	GRADE_FORMAT("年级必须是数字格式"),
-	
-	STUDENT_EXIST("已有相同考生学号,课程代码,批次的考生存在"),
-	
-	EXCEL_HYPERLINK_FORMAT_ERROR("Excel文件包含有超链接格式的文本"),
-	
-	STUDENT_NAME_CHECK("考生名称不能为空且长度在1-50个字符"),
-	
-	STUDENT_CODE_CHECK("考生学号不能为空且长度在6-15个字符"),
-	
-	STUDENT_GRADE_CHECK("年级不能为空且只能是数字格式"),
-	
-	CAMPUS_NAME_CHECK("学习中心名称不能为空且长度在1-50个字符"),
-	
-	CAMPUS_CODE_CHECK("学习中心代码不能为空且长度在1-15个字符且只能包含数字和英文字母"),
-	
-	COURSE_NAME_CHECK("课程名称不能为空且长度在1-50个字符"),
-	
-	COURSE_CODE_CHECK("课程代码不能为空且长度在1-15个字符且只能包含数字和英文字母"),
-	
-	SPECIALTY_NAME_CHECK("专业名称不能为空且长度在1-50个字符"),
-	
-	SPECIALTY_CODE_CHECK("专业代码不能为空且长度在1-15个字符且只能包含数字和英文字母")
-	
-	;
-	
-	
-	
-	
-	private String name;
-
-	public String getName() {
-		return name;
-	}
-
-	private ExcelErrorType(String name) {
-		this.name = name;
-	}
+    NOT_CAMPUS("学习中心不存在"),
+
+    NOT_EXAM_SITE("学习中心下的考点不存在"),
+
+    EXAM_SITE_CODE("考点代码为空或格式错误,只能包含数字,英文字母"),
+
+    EXAM_SITE_CODE_LENGTH("考点代码必须在1-15个字符"),
+
+    EXAM_SITE_NAME_LENGTH("考点名称必须在1-50个字符"),
+
+    CAMPUS_CODE("学习中心代码为空或格式错误,只能包含数字,英文字母"),
+
+    CAMPUS_CODE_LENGTH("学习中心代码必须在1-15个字符"),
+
+    CAMPUS_NAME_LENGTH("学习中心名必须在1-50个字符"),
+
+    COURSE_CODE("课程代码格式错误,只能包含数字,英文字母"),
+
+    SPECIALTY_CODE("专业代码格式错误,只能包含数字,英文字母"),
+
+    ONLY_EXAM_NUMBER("准考证号重复"),
+
+    STUDENT_NAME_NULL("考生姓名不能为空"),
+
+    STUDENT_NAME_LENGTH("考生姓名必须在1-50个字符"),
+
+    STUDENT_SEX_NULL("考生性别不能为空"),
+
+    STUDENT_CODE_NULL("考生学号不能为空"),
+
+    STUDENT_CODE_LENGTH("考生学号必须在6-15个字符"),
+
+    CAMPUS_NAME_NULL("学习中心名称不能为空"),
+
+    COURSE_NAME_NULL("课程名称不能为空"),
+
+    COURSE_CODE_NULL("课程代码不能为空"),
+
+    SPECIALTY_NAME_NULL("专业名称不能为空"),
+
+    SPECIALTY_CODE_NULL("专业代码不能为空"),
+
+    EXCEL_FORMAT_ERROR("Excel文件格式错误"),
+
+    EXAM_SITE_NAME_NULL("考点名称不能为空"),
+
+    GRADE_NULL("年级不能为空"),
+
+    GRADE_FORMAT("年级必须是数字格式"),
+
+    STUDENT_EXIST("已有相同考生学号,课程代码,批次的考生存在"),
+
+    EXCEL_HYPERLINK_FORMAT_ERROR("Excel文件包含有超链接格式的文本"),
+
+    STUDENT_NAME_CHECK("考生名称不能为空且长度在1-50个字符"),
+
+    STUDENT_CODE_CHECK("考生学号不能为空且长度在6-15个字符"),
+
+    STUDENT_GRADE_CHECK("年级不能为空且只能是数字格式"),
+
+    CAMPUS_NAME_CHECK("学习中心名称不能为空且长度在1-50个字符"),
+
+    CAMPUS_CODE_CHECK("学习中心代码不能为空且长度在1-15个字符且只能包含数字和英文字母"),
+
+    COURSE_NAME_CHECK("课程名称不能为空且长度在1-50个字符"),
+
+    COURSE_CODE_CHECK("课程代码不能为空且长度在1-15个字符且只能包含数字和英文字母"),
+
+    SPECIALTY_NAME_CHECK("专业名称不能为空且长度在1-50个字符"),
+
+    SPECIALTY_CODE_CHECK("专业代码不能为空且长度在1-15个字符且只能包含数字和英文字母");
+
+
+    private String name;
+
+    public String getName() {
+        return name;
+    }
+
+    private ExcelErrorType(String name) {
+        this.name = name;
+    }
 
 }

+ 14 - 10
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelProperty.java

@@ -11,19 +11,22 @@ import java.lang.annotation.Target;
 @Target(ElementType.FIELD)
 @Retention(RetentionPolicy.RUNTIME)
 public @interface ExcelProperty {
-	/**
-	 * 导出时列名
-	 */
+
+    /**
+     * 导出时列名
+     */
     String name() default "";
-    
-	/**
-	 * 导出时列宽
-	 */
+
+    /**
+     * 导出时列宽
+     */
     int width() default 0;
-	/**
-	 * 排序
-	 */
+
+    /**
+     * 排序
+     */
     int index();
+
     /**
      * 类型
      * 0:导入(读excel)
@@ -31,4 +34,5 @@ public @interface ExcelProperty {
      * 2:导入&导出
      */
     int type() default 2;
+
 }

+ 2 - 2
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelReaderHandle.java

@@ -1,7 +1,7 @@
 package cn.com.qmth.examcloud.support.excel;
 
 public interface ExcelReaderHandle {
-	
-	ExcelError handle(Object dto);
+
+    ExcelError handle(Object dto);
 
 }

+ 25 - 22
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelRow.java

@@ -4,26 +4,29 @@ import java.util.ArrayList;
 import java.util.List;
 
 public class ExcelRow {
-	private String r;
-	private List<ExcelCell> cells=new ArrayList<ExcelCell>();
-
-	public List<ExcelCell> getCells() {
-		return cells;
-	}
-
-	public void setCells(List<ExcelCell> cells) {
-		this.cells = cells;
-	}
-
-	public String getR() {
-		return r;
-	}
-
-	public void setR(String r) {
-		this.r = r;
-	}
-	
-	public void addCell(ExcelCell cell) {
-		cells.add(cell);
-	}
+
+    private String r;
+
+    private List<ExcelCell> cells = new ArrayList<ExcelCell>();
+
+    public List<ExcelCell> getCells() {
+        return cells;
+    }
+
+    public void setCells(List<ExcelCell> cells) {
+        this.cells = cells;
+    }
+
+    public String getR() {
+        return r;
+    }
+
+    public void setR(String r) {
+        this.r = r;
+    }
+
+    public void addCell(ExcelCell cell) {
+        cells.add(cell);
+    }
+
 }

+ 32 - 30
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/excel/ExcelSheet.java

@@ -4,35 +4,37 @@ import java.util.ArrayList;
 import java.util.List;
 
 public class ExcelSheet {
-	private String dimension;
-	private List<ExcelRow> rows=new ArrayList<ExcelRow>();
-
-	public String getDimension() {
-		return dimension;
-	}
-
-	public void setDimension(String dimension) {
-		this.dimension = dimension;
-	}
-
-	public List<ExcelRow> getRows() {
-		return rows;
-	}
-
-	public void setRows(List<ExcelRow> rows) {
-		this.rows = rows;
-	}
-	
-	public void addRow(ExcelRow row) {
-		rows.add(row);
-	}
-	
-	public void clearRows() {
-		rows=new ArrayList<ExcelRow>();
-	}
-	
-	public int getRowCount() {
-		return rows.size();
-	}
+
+    private String dimension;
+
+    private List<ExcelRow> rows = new ArrayList<ExcelRow>();
+
+    public String getDimension() {
+        return dimension;
+    }
+
+    public void setDimension(String dimension) {
+        this.dimension = dimension;
+    }
+
+    public List<ExcelRow> getRows() {
+        return rows;
+    }
+
+    public void setRows(List<ExcelRow> rows) {
+        this.rows = rows;
+    }
+
+    public void addRow(ExcelRow row) {
+        rows.add(row);
+    }
+
+    public void clearRows() {
+        rows = new ArrayList<ExcelRow>();
+    }
+
+    public int getRowCount() {
+        return rows.size();
+    }
 
 }

+ 25 - 25
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/filestorage/FileStorageUtil.java

@@ -69,17 +69,17 @@ public class FileStorageUtil {
     public static YunPathInfo saveFile(String siteId, FileStoragePathEnvInfo env, File file, String md5) {
         return saveFile(siteId, env, file, md5, false);
     }
-    
-    public static YunPathInfo saveFile(String siteId, FileStoragePathEnvInfo env, File file, String md5,Long cacheAge) {
+
+    public static YunPathInfo saveFile(String siteId, FileStoragePathEnvInfo env, File file, String md5, Long cacheAge) {
         FileStorageType fsType = getFileStorageType();
-        return saveFile(siteId, env, file, fsType, md5, false,cacheAge);
+        return saveFile(siteId, env, file, fsType, md5, false, cacheAge);
     }
 
     public static YunPathInfo saveFile(String siteId, FileStoragePathEnvInfo env, File file, String md5, boolean refreshCDN) {
         FileStorageType fsType = getFileStorageType();
         return saveFile(siteId, env, file, fsType, md5, refreshCDN);
     }
-    
+
     /**
      * 保存文件
      *
@@ -160,22 +160,22 @@ public class FileStorageUtil {
         FileStorage fs = SpringContextHolder.getBean(fsType.name().toLowerCase() + beanSuff, FileStorage.class);
         return fs.saveFile(siteId, env, file, md5, refreshCDN);
     }
-    
+
     private static YunPathInfo saveFile(String siteId, FileStoragePathEnvInfo env, File file, FileStorageType fsType,
-            String md5, boolean refreshCDN,Long cacheAge) {
-		if (siteId == null) {
-		throw new StatusException("2000", "siteId是空");
-		}
-		if (file == null) {
-		throw new StatusException("2001", "文件是空");
-		}
-		if (env == null) {
-		throw new StatusException("2002", "文件上传路径信息是空");
-		}
-		env.setTimeMillis(String.valueOf(System.currentTimeMillis()));
-		FileStorage fs = SpringContextHolder.getBean(fsType.name().toLowerCase() + beanSuff, FileStorage.class);
-		return fs.saveFile(siteId, env, file, md5, refreshCDN,cacheAge);
-	}
+                                        String md5, boolean refreshCDN, Long cacheAge) {
+        if (siteId == null) {
+            throw new StatusException("2000", "siteId是空");
+        }
+        if (file == null) {
+            throw new StatusException("2001", "文件是空");
+        }
+        if (env == null) {
+            throw new StatusException("2002", "文件上传路径信息是空");
+        }
+        env.setTimeMillis(String.valueOf(System.currentTimeMillis()));
+        FileStorage fs = SpringContextHolder.getBean(fsType.name().toLowerCase() + beanSuff, FileStorage.class);
+        return fs.saveFile(siteId, env, file, md5, refreshCDN, cacheAge);
+    }
 
     /**
      * 获取文件访问路径
@@ -323,12 +323,12 @@ public class FileStorageUtil {
      * @throws IOException
      */
     public static void saveUrlAs(String fileUrl, File localFile) {
-    	if (StringUtils.isBlank(fileUrl)) {
-    		throw new StatusException("500","文件链接为空");
-    	}
-    	if (!fileUrl.toLowerCase().startsWith("http") && !fileUrl.toLowerCase().startsWith("https")) {
-    		throw new StatusException("500","文件链接不是URL");
-    	}
+        if (StringUtils.isBlank(fileUrl)) {
+            throw new StatusException("500", "文件链接为空");
+        }
+        if (!fileUrl.toLowerCase().startsWith("http") && !fileUrl.toLowerCase().startsWith("https")) {
+            throw new StatusException("500", "文件链接不是URL");
+        }
         try {
             saveUrlAs(fileUrl, localFile.getAbsolutePath());
         } catch (IOException e) {

+ 3 - 1
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/AudioTextHandler.java

@@ -18,7 +18,8 @@ import java.util.List;
  * @Version 1.0
  */
 @Deprecated
-public class AudioTextHandler implements RichTextHandler{
+public class AudioTextHandler implements RichTextHandler {
+
     private static final Logger LOG = LoggerFactory.getLogger(AudioTextHandler.class);
 
     @Override
@@ -63,4 +64,5 @@ public class AudioTextHandler implements RichTextHandler{
         String regExp = "^(ftp|https?)\\:\\/\\/([\\w\\_\\-]+)\\.([\\w\\-]+[\\.]?)*[\\w]+\\.[a-zA-Z]{2,10}(.*)\\.(mp3)";
         return studentAnswer.matches(regExp);
     }
+
 }

+ 10 - 9
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/ComplexTextHandler.java

@@ -26,6 +26,7 @@ import java.util.Map;
  */
 @Deprecated
 public class ComplexTextHandler implements RichTextHandler {
+
     private static final Logger LOG = LoggerFactory.getLogger(HtmlTextHandler.class);
 
     private static final Map<String, String> TEXT_PARAM_MAP = new HashMap<>();
@@ -62,7 +63,7 @@ public class ComplexTextHandler implements RichTextHandler {
         }
 
         SectionCollectionBean result = new SectionCollectionBean();
-//        List<SectionBean> sections = new ArrayList<>();
+        //        List<SectionBean> sections = new ArrayList<>();
 
         Element body = Jsoup.parseBodyFragment(org.apache.commons.lang.StringUtils.trimToEmpty(richText)).body();
         switchSection();
@@ -159,7 +160,7 @@ public class ComplexTextHandler implements RichTextHandler {
             case "img":// TODO
             case "audio":// TODO
             case "a":// TODO
-//                finishSection();
+                //                finishSection();
                 break;
             default:
                 String style = TEXT_PARAM_MAP.get(name);
@@ -188,11 +189,11 @@ public class ComplexTextHandler implements RichTextHandler {
         currentTextParam.clear();
     }
 
-//    public static void main(String[] args) {
-//        String test = "<p><strong><em>杆件变形</em></strong>的基本形式有哪几种?何谓构件的强度,刚度和稳定性?</p>";
-//        test="<p><strong><em>杆件变形</em></strong><a id='a' name='1' url='http://1.mp3'></a>的基本形式有哪几种?<img src='http://www.baidu.com'/>何谓构件的强度,刚度和稳定性?</p>";
-//
-//        ComplexTextHandler handler = new ComplexTextHandler();
-//        System.out.println(JsonUtil.toJson(handler.handle(test)));
-//    }
+    //    public static void main(String[] args) {
+    //        String test = "<p><strong><em>杆件变形</em></strong>的基本形式有哪几种?何谓构件的强度,刚度和稳定性?</p>";
+    //        test="<p><strong><em>杆件变形</em></strong><a id='a' name='1' url='http://1.mp3'></a>的基本形式有哪几种?<img src='http://www.baidu.com'/>何谓构件的强度,刚度和稳定性?</p>";
+    //
+    //        ComplexTextHandler handler = new ComplexTextHandler();
+    //        System.out.println(JsonUtil.toJson(handler.handle(test)));
+    //    }
 }

+ 15 - 14
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/HtmlTextHandler.java

@@ -30,6 +30,7 @@ public class HtmlTextHandler implements RichTextHandler {
     private static final Logger LOG = LoggerFactory.getLogger(HtmlTextHandler.class);
 
     private static Map<String, String> tagMap;
+
     private static String DEFAULT_RETAIN_TAG = "b,u,i,sup,sub";
 
     static {
@@ -55,8 +56,8 @@ public class HtmlTextHandler implements RichTextHandler {
         /*过滤不需要的html标签*/
         String retainTags = PropertyHolder.getString("cloudMarking.interface.retainTags", DEFAULT_RETAIN_TAG);
 
-//        String[] specialRetainTagArr = (retainTags + ",br").split(",");
-//        richText = Jsoup.clean(richText, new Whitelist().addTags(specialRetainTagArr));
+        //        String[] specialRetainTagArr = (retainTags + ",br").split(",");
+        //        richText = Jsoup.clean(richText, new Whitelist().addTags(specialRetainTagArr));
 
         richText = richText.replace("<div>", "\n")
                 .replace("</div>", "")
@@ -179,17 +180,17 @@ public class HtmlTextHandler implements RichTextHandler {
         return null;
     }
 
-//    public static void main(String[] args) {
-////        String testStr = "1111111<div>222&lt;div&gt;&lt;/div&gt;21000<sup>2</sup></div><div>3333399<sub>3</sub>5555555</div><div><br></div><div>444444</div>";
-////        String testStr="{\"mainNumber\":2,\"order\":23,\"questionId\":\"5ebdf1cbcad4db1aee85e907\",\"studentAnswer\":\"发发呆<div>ななぅぅぉてふっふてふ</div><div class='photo-answers-block'><a href='https://ecs-test-static.qmth.com.cn/oe-answer-file/21083/19288/23/21083_19288_23_15895106360336244.jpeg' target='_blank' ><img class='photo-answer' src='https://ecs-test-static.qmth.com.cn/oe-answer-file/21083/19288/23/21083_19288_23_15895106360336244.jpeg?x-oss-process=image/resize,m_lfit,h_200,w_200' /></a></div>\",\"answerType\":null,\"answer\":\"<p><span> えいが</span></p>\",\"body\":\"<p>映画</p>\",\"parentBody\":null,\"questionType\":\"ESSAY\"}";
-//            String testStr="{\"mainNumber\":5,\"order\":19,\"questionId\":\"5e942585cad4db278def3df5\",\"studentAnswer\":\"范德萨范德萨飞<sup>电风扇的</sup><div>范德萨范德萨</div><div>范德萨范德萨范<sub>德萨发的</sub></div><div class='photo-answers-block'><a href='https://ecs-test-static.qmth.com.cn/oe-answer-file/20820/19336/19/20820_19336_19_15899464519267961.jpeg' target='_blank' ><img class='photo-answer' src='https://ecs-test-static.qmth.com.cn/oe-answer-file/20820/19336/19/20820_19336_19_15899464519267961.jpeg?x-oss-process=image/resize,m_lfit,h_200,w_200' /></a><a href='https://ecs-test-static.qmth.com.cn/oe-answer-file/20820/19336/19/20820_19336_19_15899464518985666.jpeg' target='_blank' ><img class='photo-answer' src='https://ecs-test-static.qmth.com.cn/oe-answer-file/20820/19336/19/20820_19336_19_15899464518985666.jpeg?x-oss-process=image/resize,m_lfit,h_200,w_200' /></a><a href='https://ecs-test-static.qmth.com.cn/oe-answer-file/20820/19336/19/20820_19336_19_15899464519221951.jpeg' target='_blank' ><img class='photo-answer' src='https://ecs-test-static.qmth.com.cn/oe-answer-file/20820/19336/19/20820_19336_19_15899464519221951.jpeg?x-oss-process=image/resize,m_lfit,h_200,w_200' /></a></div>\",\"answerType\":\"DIVERSIFIED_TEXT\",\"answer\":\"<p>1).杆件变形的基本形式有轴向拉伸和压缩,剪切,扭转和弯曲。</p>\\n\\n<p>2).强度&mdash;&mdash;构建抵抗破坏的能力。刚度&mdash;&mdash;构件抵抗变形的能力。</p>\\n\\n<p>3).稳定性&mdash;&mdash;构件保持原型状的能力。</p>\",\"body\":\"<p>杆件变形的<em><strong><u>基本形式</u></strong></em>有哪几种?何谓构件的强度,刚度和稳定性?</p><p><a id=\\\"5eba5fadcad4db05908c8d13\\\" name=\\\"19_1_2.mp3\\\" question-audio url=\\\"https://ecs-test-static.qmth.com.cn/comm-ques-bank/prod/audio/5e942585cad4db278def3df5_514_19_1_2.mp3\\\"></a></p>\",\"parentBody\":null,\"questionType\":\"ESSAY\"}";
-//
-//        HtmlTextHandler o = new HtmlTextHandler();
-//
-//
-//        SectionCollectionBean sfds = o.handle(testStr);
-//
-//        System.out.println(JsonUtil.toJson(sfds));
-//    }
+    //    public static void main(String[] args) {
+    ////        String testStr = "1111111<div>222&lt;div&gt;&lt;/div&gt;21000<sup>2</sup></div><div>3333399<sub>3</sub>5555555</div><div><br></div><div>444444</div>";
+    ////        String testStr="{\"mainNumber\":2,\"order\":23,\"questionId\":\"5ebdf1cbcad4db1aee85e907\",\"studentAnswer\":\"发发呆<div>ななぅぅぉてふっふてふ</div><div class='photo-answers-block'><a href='https://ecs-test-static.qmth.com.cn/oe-answer-file/21083/19288/23/21083_19288_23_15895106360336244.jpeg' target='_blank' ><img class='photo-answer' src='https://ecs-test-static.qmth.com.cn/oe-answer-file/21083/19288/23/21083_19288_23_15895106360336244.jpeg?x-oss-process=image/resize,m_lfit,h_200,w_200' /></a></div>\",\"answerType\":null,\"answer\":\"<p><span> えいが</span></p>\",\"body\":\"<p>映画</p>\",\"parentBody\":null,\"questionType\":\"ESSAY\"}";
+    //            String testStr="{\"mainNumber\":5,\"order\":19,\"questionId\":\"5e942585cad4db278def3df5\",\"studentAnswer\":\"范德萨范德萨飞<sup>电风扇的</sup><div>范德萨范德萨</div><div>范德萨范德萨范<sub>德萨发的</sub></div><div class='photo-answers-block'><a href='https://ecs-test-static.qmth.com.cn/oe-answer-file/20820/19336/19/20820_19336_19_15899464519267961.jpeg' target='_blank' ><img class='photo-answer' src='https://ecs-test-static.qmth.com.cn/oe-answer-file/20820/19336/19/20820_19336_19_15899464519267961.jpeg?x-oss-process=image/resize,m_lfit,h_200,w_200' /></a><a href='https://ecs-test-static.qmth.com.cn/oe-answer-file/20820/19336/19/20820_19336_19_15899464518985666.jpeg' target='_blank' ><img class='photo-answer' src='https://ecs-test-static.qmth.com.cn/oe-answer-file/20820/19336/19/20820_19336_19_15899464518985666.jpeg?x-oss-process=image/resize,m_lfit,h_200,w_200' /></a><a href='https://ecs-test-static.qmth.com.cn/oe-answer-file/20820/19336/19/20820_19336_19_15899464519221951.jpeg' target='_blank' ><img class='photo-answer' src='https://ecs-test-static.qmth.com.cn/oe-answer-file/20820/19336/19/20820_19336_19_15899464519221951.jpeg?x-oss-process=image/resize,m_lfit,h_200,w_200' /></a></div>\",\"answerType\":\"DIVERSIFIED_TEXT\",\"answer\":\"<p>1).杆件变形的基本形式有轴向拉伸和压缩,剪切,扭转和弯曲。</p>\\n\\n<p>2).强度&mdash;&mdash;构建抵抗破坏的能力。刚度&mdash;&mdash;构件抵抗变形的能力。</p>\\n\\n<p>3).稳定性&mdash;&mdash;构件保持原型状的能力。</p>\",\"body\":\"<p>杆件变形的<em><strong><u>基本形式</u></strong></em>有哪几种?何谓构件的强度,刚度和稳定性?</p><p><a id=\\\"5eba5fadcad4db05908c8d13\\\" name=\\\"19_1_2.mp3\\\" question-audio url=\\\"https://ecs-test-static.qmth.com.cn/comm-ques-bank/prod/audio/5e942585cad4db278def3df5_514_19_1_2.mp3\\\"></a></p>\",\"parentBody\":null,\"questionType\":\"ESSAY\"}";
+    //
+    //        HtmlTextHandler o = new HtmlTextHandler();
+    //
+    //
+    //        SectionCollectionBean sfds = o.handle(testStr);
+    //
+    //        System.out.println(JsonUtil.toJson(sfds));
+    //    }
 
 }

+ 15 - 15
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/ImageTextHandler.java

@@ -64,12 +64,12 @@ public class ImageTextHandler implements RichTextHandler {
                 blockBean.setValue(getPureUrl(imgAnswers[i]));
 
                 //又拍云图片的宽*高
-                String width=RegExpUtil.find(imgAnswers[i], "w_(\\d+)");
-                String height=RegExpUtil.find(imgAnswers[i], "h_(\\d+)");
+                String width = RegExpUtil.find(imgAnswers[i], "w_(\\d+)");
+                String height = RegExpUtil.find(imgAnswers[i], "h_(\\d+)");
                 Map<String, Object> paramMap = new HashMap<>();
                 if (!StringUtils.isNullOrEmpty(width) && !StringUtils.isNullOrEmpty(height)) {
-                    paramMap.put("width", Integer.valueOf(width.replaceAll("w_","")));
-                    paramMap.put("height", Integer.valueOf(height.replaceAll("h_","")));
+                    paramMap.put("width", Integer.valueOf(width.replaceAll("w_", "")));
+                    paramMap.put("height", Integer.valueOf(height.replaceAll("h_", "")));
                     blockBean.setParam(paramMap);
                 }
 
@@ -159,15 +159,15 @@ public class ImageTextHandler implements RichTextHandler {
         return RegExpUtil.find(imgUrl, regExp);
     }
 
-//    public static void main(String[] args) {
-////        String testStr = "1111111<div>222&lt;div&gt;&lt;/div&gt;21000<sup>2</sup></div><div>3333399<sub>3</sub>5555555</div><div><br></div><div>444444</div>";
-//        String testStr = "{\"mainNumber\":2,\"order\":23,\"questionId\":\"5ebdf1cbcad4db1aee85e907\",\"studentAnswer\":\"发发呆<div>ななぅぅぉてふっふてふ</div><div class='photo-answers-block'><a href='https://ecs-test-static.qmth.com.cn/oe-answer-file/21083/19288/23/21083_19288_23_15895106360336244.jpeg' target='_blank' ><img class='photo-answer' src='https://ecs-test-static.qmth.com.cn/oe-answer-file/21083/19288/23/21083_19288_23_15895106360336244.jpeg?x-oss-process=image/resize,m_lfit,h_200,w_200' /></a></div>\",\"answerType\":null,\"answer\":\"<p><span> えいが</span></p>\",\"body\":\"<p>映画</p>\",\"parentBody\":null,\"questionType\":\"ESSAY\"}";
-//
-//        ImageTextHandler o = new ImageTextHandler();
-//
-//
-//        SectionCollectionBean sfds = o.handle(testStr);
-//
-//        System.out.println(JsonUtil.toJson(sfds));
-//    }
+    //    public static void main(String[] args) {
+    ////        String testStr = "1111111<div>222&lt;div&gt;&lt;/div&gt;21000<sup>2</sup></div><div>3333399<sub>3</sub>5555555</div><div><br></div><div>444444</div>";
+    //        String testStr = "{\"mainNumber\":2,\"order\":23,\"questionId\":\"5ebdf1cbcad4db1aee85e907\",\"studentAnswer\":\"发发呆<div>ななぅぅぉてふっふてふ</div><div class='photo-answers-block'><a href='https://ecs-test-static.qmth.com.cn/oe-answer-file/21083/19288/23/21083_19288_23_15895106360336244.jpeg' target='_blank' ><img class='photo-answer' src='https://ecs-test-static.qmth.com.cn/oe-answer-file/21083/19288/23/21083_19288_23_15895106360336244.jpeg?x-oss-process=image/resize,m_lfit,h_200,w_200' /></a></div>\",\"answerType\":null,\"answer\":\"<p><span> えいが</span></p>\",\"body\":\"<p>映画</p>\",\"parentBody\":null,\"questionType\":\"ESSAY\"}";
+    //
+    //        ImageTextHandler o = new ImageTextHandler();
+    //
+    //
+    //        SectionCollectionBean sfds = o.handle(testStr);
+    //
+    //        System.out.println(JsonUtil.toJson(sfds));
+    //    }
 }

+ 2 - 0
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/RichTextHandler.java

@@ -10,5 +10,7 @@ import cn.com.qmth.examcloud.support.handler.richText.bean.SectionCollectionBean
  */
 @Deprecated
 public interface RichTextHandler {
+
     SectionCollectionBean handle(String richText);
+
 }

+ 9 - 6
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/RichTextHandlerFactory.java

@@ -14,22 +14,24 @@ import java.util.Map;
  */
 @Deprecated
 public class RichTextHandlerFactory {
-    private static final Map<String,RichTextHandler> handlerMap=new HashMap<>();
+
+    private static final Map<String, RichTextHandler> handlerMap = new HashMap<>();
 
     static {
-        handlerMap.put("text",new HtmlTextHandler());
-        handlerMap.put("image",new ImageTextHandler());
-        handlerMap.put("audio",new AudioTextHandler());
+        handlerMap.put("text", new HtmlTextHandler());
+        handlerMap.put("image", new ImageTextHandler());
+        handlerMap.put("audio", new AudioTextHandler());
     }
 
     /**
      * 根据类型获取实例
+     *
      * @param type 文本类型
      * @return
      */
     public static RichTextHandler getHandler(String type) {
         if (StringUtils.isNullOrEmpty(type)) {
-            throw new StatusException("900101","参数type不允许为空");
+            throw new StatusException("900101", "参数type不允许为空");
         }
 
         //由于复合文处理类中有公共字段,所以必须是多例
@@ -38,9 +40,10 @@ public class RichTextHandlerFactory {
         }
 
         if (!handlerMap.containsKey(type)) {
-            throw new StatusException("900102","不支持的文本类型");
+            throw new StatusException("900102", "不支持的文本类型");
         }
 
         return handlerMap.get(type);
     }
+
 }

+ 3 - 0
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/bean/BlockBean.java

@@ -11,6 +11,7 @@ import java.util.Map;
  */
 @Deprecated
 public class BlockBean {
+
     public BlockBean(String type) {
         this.type = type;
         this.param = new HashMap<>();
@@ -24,10 +25,12 @@ public class BlockBean {
      * video:视频
      */
     private String type;
+
     /**
      * 资源相对路径
      */
     private String value;
+
     /**
      * 播放次数
      */

+ 1 - 2
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/handler/richText/bean/SectionBean.java

@@ -13,7 +13,7 @@ import java.util.List;
 public class SectionBean {
 
     public SectionBean() {
-        this.blocks=new ArrayList<>();
+        this.blocks = new ArrayList<>();
     }
 
     private List<BlockBean> blocks;
@@ -27,6 +27,5 @@ public class SectionBean {
     }
 
 
-
 }
 

+ 2 - 1
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/helper/IdentityNumberHelper.java

@@ -33,7 +33,7 @@ public class IdentityNumberHelper {
 
         return replaceStrToSymbol(identityNumber, startIndex, identityNumber.length() - 2, "*");
     }
-    
+
     public static String conceal(String identityNumber) {
         if (StringUtils.isBlank(identityNumber)) {
             return identityNumber;
@@ -90,4 +90,5 @@ public class IdentityNumberHelper {
             return false;
         }
     }
+
 }

+ 73 - 52
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/privilege/PrivilegeDefine.java

@@ -13,74 +13,95 @@ package cn.com.qmth.examcloud.support.privilege;
  */
 public interface PrivilegeDefine {
 
-	// 数据访问权限组
-	public interface DataAccess {
+    // 数据访问权限组
+    public interface DataAccess {
 
-		String CODE = "DATA_ACCESS";
+        String CODE = "DATA_ACCESS";
 
-		// 网考数据访问权限
-		public interface OnlineExamData {
+        // 网考数据访问权限
+        public interface OnlineExamData {
 
-			String CODE = "ONLINE_EXAM_DATA";
+            String CODE = "ONLINE_EXAM_DATA";
 
-			// 违纪名单数据权限
-			public interface DataViolatingDiscipline {
-				String CODE = "DATA_VIOLATING_DISCIPLINE";
+            // 违纪名单数据权限
+            public interface DataViolatingDiscipline {
 
-				// 未通过审核的学生照片权限
-				public interface UnapprovedStudentPhoto {
-					String CODE = "UNAPPROVED_STUDENT_PHOTO";
-				}
+                String CODE = "DATA_VIOLATING_DISCIPLINE";
 
-				// 所有学生照片权限
-				public interface AllStudentPhoto {
-					String CODE = "ALL_STUDENT_PHOTO";
-				}
-			}
-		}
+                // 未通过审核的学生照片权限
+                public interface UnapprovedStudentPhoto {
 
-		// 考务数据访问权限
-		public interface ExamWorkData {
+                    String CODE = "UNAPPROVED_STUDENT_PHOTO";
 
-			String CODE = "EXAM_WORK_DATA";
+                }
 
-			// 学生数据
-			public interface StudentInfoData {
-				String CODE = "STUDENT_INFO_DATA";
+                // 所有学生照片权限
+                public interface AllStudentPhoto {
 
-				// 学习中心学生数据
-				public interface OrgStudentData {
-					String CODE = "ORG_STUDENT_DATA";
-				}
+                    String CODE = "ALL_STUDENT_PHOTO";
 
-				// 所有学生数据
-				public interface AllStudentData {
-					String CODE = "ALL_STUDENT_DATA";
-				}
-			}
-		}
+                }
 
-	}
+            }
 
-	// 顶级机构功能权限组
-	public interface RootOrgFunctions {
-		String CODE = "ROOT_ORG_FUNCTIONS";
+        }
 
-		// 网考功能
-		public interface OnlineExamFunctions {
-			String CODE = "ONLINE_EXAM_FUNCTIONS";
+        // 考务数据访问权限
+        public interface ExamWorkData {
 
-			// 人脸识别
-			public interface FaceCheck {
-				String CODE = "FACE_CHECK";
-			}
+            String CODE = "EXAM_WORK_DATA";
 
-			// 活体检测
-			public interface IdentificationOfLivingBody {
-				String CODE = "IDENTIFICATION_OF_LIVING_BODY";
-			}
-		}
+            // 学生数据
+            public interface StudentInfoData {
 
-	}
+                String CODE = "STUDENT_INFO_DATA";
+
+                // 学习中心学生数据
+                public interface OrgStudentData {
+
+                    String CODE = "ORG_STUDENT_DATA";
+
+                }
+
+                // 所有学生数据
+                public interface AllStudentData {
+
+                    String CODE = "ALL_STUDENT_DATA";
+
+                }
+
+            }
+
+        }
+
+    }
+
+    // 顶级机构功能权限组
+    public interface RootOrgFunctions {
+
+        String CODE = "ROOT_ORG_FUNCTIONS";
+
+        // 网考功能
+        public interface OnlineExamFunctions {
+
+            String CODE = "ONLINE_EXAM_FUNCTIONS";
+
+            // 人脸识别
+            public interface FaceCheck {
+
+                String CODE = "FACE_CHECK";
+
+            }
+
+            // 活体检测
+            public interface IdentificationOfLivingBody {
+
+                String CODE = "IDENTIFICATION_OF_LIVING_BODY";
+
+            }
+
+        }
+
+    }
 
 }

+ 44 - 44
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/privilege/PrivilegeManager.java

@@ -1,13 +1,13 @@
 package cn.com.qmth.examcloud.support.privilege;
 
-import java.util.List;
-import java.util.Set;
-
 import cn.com.qmth.examcloud.api.commons.security.bean.Role;
 import cn.com.qmth.examcloud.support.cache.CacheHelper;
 import cn.com.qmth.examcloud.support.cache.bean.PrivilegeRolesCacheBean;
 import cn.com.qmth.examcloud.support.cache.bean.RootOrgPrivilegesCacheBean;
 
+import java.util.List;
+import java.util.Set;
+
 /**
  * 权限管理器
  *
@@ -17,53 +17,53 @@ import cn.com.qmth.examcloud.support.cache.bean.RootOrgPrivilegesCacheBean;
  */
 public class PrivilegeManager {
 
-	/**
-	 * 判断角色是否有权限
-	 *
-	 * @author WANGWEI
-	 * @param rootOrgId
-	 * @param roleList
-	 * @param privilegeCode
-	 * @return
-	 */
-	public static Boolean judge(Long rootOrgId, List<Role> roleList, String privilegeCode) {
+    /**
+     * 判断角色是否有权限
+     *
+     * @param rootOrgId
+     * @param roleList
+     * @param privilegeCode
+     * @return
+     * @author WANGWEI
+     */
+    public static Boolean judge(Long rootOrgId, List<Role> roleList, String privilegeCode) {
 
-		PrivilegeRolesCacheBean cacheBean = CacheHelper.getPrivilegeRoles(rootOrgId, privilegeCode);
-		Set<Long> roleIdList = cacheBean.getRoleIdList();
-		Set<String> roleCodeList = cacheBean.getRoleCodeList();
+        PrivilegeRolesCacheBean cacheBean = CacheHelper.getPrivilegeRoles(rootOrgId, privilegeCode);
+        Set<Long> roleIdList = cacheBean.getRoleIdList();
+        Set<String> roleCodeList = cacheBean.getRoleCodeList();
 
-		for (Role cur : roleList) {
-			Long roleId = cur.getRoleId();
-			String roleCode = cur.getRoleCode();
+        for (Role cur : roleList) {
+            Long roleId = cur.getRoleId();
+            String roleCode = cur.getRoleCode();
 
-			if (null != roleId && roleIdList.contains(roleId)) {
-				return true;
-			}
-			if (null != roleCode && roleCodeList.contains(roleCode)) {
-				return true;
-			}
-		}
-		return false;
-	}
+            if (null != roleId && roleIdList.contains(roleId)) {
+                return true;
+            }
+            if (null != roleCode && roleCodeList.contains(roleCode)) {
+                return true;
+            }
+        }
+        return false;
+    }
 
-	/**
-	 * 判断顶级机构是否有权限
-	 *
-	 * @author WANGWEI
-	 * @param rootOrgId
-	 * @param privilegeCode
-	 * @return
-	 */
-	public static Boolean judge(Long rootOrgId, String privilegeCode) {
+    /**
+     * 判断顶级机构是否有权限
+     *
+     * @param rootOrgId
+     * @param privilegeCode
+     * @return
+     * @author WANGWEI
+     */
+    public static Boolean judge(Long rootOrgId, String privilegeCode) {
 
-		RootOrgPrivilegesCacheBean cacheBean = CacheHelper.getRootOrgPrivileges(rootOrgId);
+        RootOrgPrivilegesCacheBean cacheBean = CacheHelper.getRootOrgPrivileges(rootOrgId);
 
-		Set<String> privilegeCodeList = cacheBean.getPrivilegeCodeList();
-		if (privilegeCodeList.contains(privilegeCode)) {
-			return true;
-		}
+        Set<String> privilegeCodeList = cacheBean.getPrivilegeCodeList();
+        if (privilegeCodeList.contains(privilegeCode)) {
+            return true;
+        }
 
-		return false;
-	}
+        return false;
+    }
 
 }

+ 4 - 7
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/redis/RedisKeyDefine.java

@@ -1,10 +1,6 @@
 package cn.com.qmth.examcloud.support.redis;
 
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
+import java.lang.annotation.*;
 
 /**
  * redis key定义
@@ -18,7 +14,8 @@ import java.lang.annotation.Target;
 @Documented
 public @interface RedisKeyDefine {
 
-	String value();
+    String value();
+
+    String Prefix();
 
-	String Prefix();
 }

+ 199 - 208
examcloud-support/src/main/java/cn/com/qmth/examcloud/support/util/FileDisposeUtil.java

@@ -1,17 +1,10 @@
 package cn.com.qmth.examcloud.support.util;
 
-import java.io.BufferedInputStream;
-import java.io.BufferedOutputStream;
-import java.io.ByteArrayOutputStream;
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
+import org.apache.commons.io.FileUtils;
+import org.apache.commons.io.IOUtils;
+
+import javax.servlet.http.HttpServletResponse;
+import java.io.*;
 import java.net.HttpURLConnection;
 import java.net.URL;
 import java.net.URLEncoder;
@@ -26,11 +19,6 @@ import java.util.zip.ZipEntry;
 import java.util.zip.ZipFile;
 import java.util.zip.ZipOutputStream;
 
-import javax.servlet.http.HttpServletResponse;
-
-import org.apache.commons.io.FileUtils;
-import org.apache.commons.io.IOUtils;
-
 
 /**
  * @author chenken
@@ -39,192 +27,194 @@ import org.apache.commons.io.IOUtils;
  * @description FileUtil.java
  */
 public class FileDisposeUtil {
-	
-	/**
-	 * 将网络文件保存到本地
-	 * @param fileUrl		   网络文件URL
-	 * @param localFilePath  例如D:/123.txt
-	 * @return
-	 */
-	public static boolean saveUrlAs(String fileUrl,String localFilePath) {
-		HttpURLConnection connection = null;
-		FileOutputStream fileOutputStream = null;
-		DataOutputStream dataOutputStream = null;
-		DataInputStream dataInputStream = null;
-		try {
-			URL url = new URL(fileUrl);
-			connection = (HttpURLConnection) url.openConnection();
-			dataInputStream = new DataInputStream(connection.getInputStream());
-			fileOutputStream = new FileOutputStream(localFilePath);
-			dataOutputStream = new DataOutputStream(fileOutputStream);
-			byte[] buffer = new byte[4096];
-			int count = 0;
-			while ((count = dataInputStream.read(buffer)) > 0) {
-				dataOutputStream.write(buffer, 0, count);
-			}
-			return true;
-		} catch (Exception e) {
-			return false;
-		}finally {
-			try {
-				if(fileOutputStream!=null){
-					fileOutputStream.flush();
-					fileOutputStream.close();
-					fileOutputStream = null;
-				}
-				if (dataOutputStream != null) {
-					dataOutputStream.flush();
-					dataOutputStream.close();
-					dataOutputStream = null;
-				}
-				if (dataInputStream != null) {
-					dataInputStream.close();
-					dataInputStream = null;
-				}
-			} catch (IOException e) {
-				e.printStackTrace();
-			}
-			if (connection != null) {
-				connection.disconnect();
-				connection = null;
-			}
-		}
-	}
-	
-	/**
-	 * 下载服务器上的文件
-	 * @param filename		文件名称
-	 * @param fullFilePath	文件全路径
-	 * @param response
-	 */
-	public static void downloadFile(String filename,String fullFilePath,HttpServletResponse response){
-		FileInputStream input = null;
-		OutputStream output = null;
-		try {
-	        //设置文件MIME类型  
-			response.setContentType(getContentType(filename));
-	        response.setHeader("Content-Disposition", "attachment;filename="+URLEncoder.encode(filename,"UTF-8"));
-	        //读取目标文件,通过response将目标文件写到客户端  
-	        input =  new FileInputStream(fullFilePath);
-			output =  response.getOutputStream();  
-	        //写文件  
-			byte[] b = new byte[2048];
+
+    /**
+     * 将网络文件保存到本地
+     *
+     * @param fileUrl       网络文件URL
+     * @param localFilePath 例如D:/123.txt
+     * @return
+     */
+    public static boolean saveUrlAs(String fileUrl, String localFilePath) {
+        HttpURLConnection connection = null;
+        FileOutputStream fileOutputStream = null;
+        DataOutputStream dataOutputStream = null;
+        DataInputStream dataInputStream = null;
+        try {
+            URL url = new URL(fileUrl);
+            connection = (HttpURLConnection) url.openConnection();
+            dataInputStream = new DataInputStream(connection.getInputStream());
+            fileOutputStream = new FileOutputStream(localFilePath);
+            dataOutputStream = new DataOutputStream(fileOutputStream);
+            byte[] buffer = new byte[4096];
+            int count = 0;
+            while ((count = dataInputStream.read(buffer)) > 0) {
+                dataOutputStream.write(buffer, 0, count);
+            }
+            return true;
+        } catch (Exception e) {
+            return false;
+        } finally {
+            try {
+                if (fileOutputStream != null) {
+                    fileOutputStream.flush();
+                    fileOutputStream.close();
+                    fileOutputStream = null;
+                }
+                if (dataOutputStream != null) {
+                    dataOutputStream.flush();
+                    dataOutputStream.close();
+                    dataOutputStream = null;
+                }
+                if (dataInputStream != null) {
+                    dataInputStream.close();
+                    dataInputStream = null;
+                }
+            } catch (IOException e) {
+                e.printStackTrace();
+            }
+            if (connection != null) {
+                connection.disconnect();
+                connection = null;
+            }
+        }
+    }
+
+    /**
+     * 下载服务器上的文件
+     *
+     * @param filename     文件名称
+     * @param fullFilePath 文件全路径
+     * @param response
+     */
+    public static void downloadFile(String filename, String fullFilePath, HttpServletResponse response) {
+        FileInputStream input = null;
+        OutputStream output = null;
+        try {
+            //设置文件MIME类型
+            response.setContentType(getContentType(filename));
+            response.setHeader("Content-Disposition", "attachment;filename=" + URLEncoder.encode(filename, "UTF-8"));
+            //读取目标文件,通过response将目标文件写到客户端
+            input = new FileInputStream(fullFilePath);
+            output = response.getOutputStream();
+            //写文件
+            byte[] b = new byte[2048];
             int len;
             while ((len = input.read(b)) != -1) {
-            	output.write(b, 0, len);
-            } 
+                output.write(b, 0, len);
+            }
             response.setHeader("Content-Length", String.valueOf(input.getChannel().size()));
-	        input.close();  
-		} catch (FileNotFoundException e) {
-			e.printStackTrace();
-		} catch (IOException e) {
-			e.printStackTrace();
-		}
-	}
-	/**
-	 * 获得文件MIME类型
-	 * @param filename
-	 * @return
-	 */
-	public static String getContentType(String filename){
-		String type = null;
-		Path path = Paths.get(filename);
-		try {
-			type = Files.probeContentType(path);
-		} catch (IOException e) {
-			e.printStackTrace();
-		}
-		return type;
-	}
+            input.close();
+        } catch (FileNotFoundException e) {
+            e.printStackTrace();
+        } catch (IOException e) {
+            e.printStackTrace();
+        }
+    }
+
+    /**
+     * 获得文件MIME类型
+     *
+     * @param filename
+     * @return
+     */
+    public static String getContentType(String filename) {
+        String type = null;
+        Path path = Paths.get(filename);
+        try {
+            type = Files.probeContentType(path);
+        } catch (IOException e) {
+            e.printStackTrace();
+        }
+        return type;
+    }
 
-	/**
-	 * 将存放在sourceFilePath目录下的源文件,打包成fileName名称的zip文件,并存放到zipFilePath路径下
-	 * 
-	 * @param sourceFilePath
-	 *            :待压缩的文件夹路径
-	 * @param zipFilePath
-	 *            :压缩后zip文件的存放路径
-	 * @param fileName
-	 *            :zip文件的名称
-	 * @return
-	 */
-	public static boolean fileToZip(String sourceFilePath, String zipFilePath,String fileName) {
-		boolean flag = false;
-		File sourceFile = new File(sourceFilePath);
-		FileInputStream fis = null;
-		BufferedInputStream bis = null;
-		FileOutputStream fos = null;
-		ZipOutputStream zos = null;
-		if (sourceFile.exists() == false) {
-			throw new RuntimeException("待压缩的文件目录:" + sourceFilePath + "不存在.");
-		} else {
-			try {
-				File zipFile = new File(zipFilePath+File.separator+fileName+".zip");
-				if (zipFile.exists()) {
-					throw new RuntimeException(zipFilePath + "目录下存在名字为:"+fileName+".zip"+"打包文件.");
-				} else {
-					File[] sourceFiles = sourceFile.listFiles();
-					if (null == sourceFiles || sourceFiles.length < 1) {
-						throw new RuntimeException("待压缩的文件目录:" + sourceFilePath+ "里面不存在文件,无需压缩.");
-					} else {
-						fos = new FileOutputStream(zipFile);
-						zos = new ZipOutputStream(new BufferedOutputStream(fos));
-						byte[] bufs = new byte[1024 * 10];
-						for (int i = 0; i < sourceFiles.length; i++) {
-							try{
-								//创建ZIP实体,并添加进压缩包
-								String fileEncode = System.getProperty("file.encoding");
-								String name = new String(sourceFiles[i].getName().getBytes(fileEncode),"UTF-8");
-								ZipEntry zipEntry = new ZipEntry(name);
-								zos.putNextEntry(zipEntry);
-								//读取待压缩的文件并写进压缩包里
-								fis = new FileInputStream(sourceFiles[i]);
-								bis = new BufferedInputStream(fis, 1024 * 10);
-								int read = 0;
-								while ((read = bis.read(bufs, 0, 1024 * 10)) != -1) {
-									zos.write(bufs, 0, read);
-								}
-								zos.flush();
-							}catch(Exception e){
-								e.printStackTrace();
-							}finally{
-								IOUtils.closeQuietly(bis);
-								IOUtils.closeQuietly(fis);
-							}
-						}
-						flag = true;
-					}
-				}
-			} catch (Exception e) {
-				e.printStackTrace();
-			} finally {
-				IOUtils.closeQuietly(bis);
-				IOUtils.closeQuietly(fis);
-				IOUtils.closeQuietly(zos);
-				IOUtils.closeQuietly(fos);
-			}
-		}
-		return flag;
-	}
-	
-	public static void createDirectory(String downloadDirectory) {
-		File directory = new File(downloadDirectory);
-		if(!directory.exists()){
-			directory.mkdirs();
-		}else{
-			FileUtils.deleteQuietly(directory);
-			directory.mkdirs();
-		}
-	}
-	
-	/**
-	 * 获得文件的byte数组
-	 * @param filePath
-	 * @return
-	 * @throws IOException
-	 */
-	public static byte[] getBytes(String filePath) throws IOException{  
-    	File file = new File(filePath);
+    /**
+     * 将存放在sourceFilePath目录下的源文件,打包成fileName名称的zip文件,并存放到zipFilePath路径下
+     *
+     * @param sourceFilePath :待压缩的文件夹路径
+     * @param zipFilePath    :压缩后zip文件的存放路径
+     * @param fileName       :zip文件的名称
+     * @return
+     */
+    public static boolean fileToZip(String sourceFilePath, String zipFilePath, String fileName) {
+        boolean flag = false;
+        File sourceFile = new File(sourceFilePath);
+        FileInputStream fis = null;
+        BufferedInputStream bis = null;
+        FileOutputStream fos = null;
+        ZipOutputStream zos = null;
+        if (sourceFile.exists() == false) {
+            throw new RuntimeException("待压缩的文件目录:" + sourceFilePath + "不存在.");
+        } else {
+            try {
+                File zipFile = new File(zipFilePath + File.separator + fileName + ".zip");
+                if (zipFile.exists()) {
+                    throw new RuntimeException(zipFilePath + "目录下存在名字为:" + fileName + ".zip" + "打包文件.");
+                } else {
+                    File[] sourceFiles = sourceFile.listFiles();
+                    if (null == sourceFiles || sourceFiles.length < 1) {
+                        throw new RuntimeException("待压缩的文件目录:" + sourceFilePath + "里面不存在文件,无需压缩.");
+                    } else {
+                        fos = new FileOutputStream(zipFile);
+                        zos = new ZipOutputStream(new BufferedOutputStream(fos));
+                        byte[] bufs = new byte[1024 * 10];
+                        for (int i = 0; i < sourceFiles.length; i++) {
+                            try {
+                                //创建ZIP实体,并添加进压缩包
+                                String fileEncode = System.getProperty("file.encoding");
+                                String name = new String(sourceFiles[i].getName().getBytes(fileEncode), "UTF-8");
+                                ZipEntry zipEntry = new ZipEntry(name);
+                                zos.putNextEntry(zipEntry);
+                                //读取待压缩的文件并写进压缩包里
+                                fis = new FileInputStream(sourceFiles[i]);
+                                bis = new BufferedInputStream(fis, 1024 * 10);
+                                int read = 0;
+                                while ((read = bis.read(bufs, 0, 1024 * 10)) != -1) {
+                                    zos.write(bufs, 0, read);
+                                }
+                                zos.flush();
+                            } catch (Exception e) {
+                                e.printStackTrace();
+                            } finally {
+                                IOUtils.closeQuietly(bis);
+                                IOUtils.closeQuietly(fis);
+                            }
+                        }
+                        flag = true;
+                    }
+                }
+            } catch (Exception e) {
+                e.printStackTrace();
+            } finally {
+                IOUtils.closeQuietly(bis);
+                IOUtils.closeQuietly(fis);
+                IOUtils.closeQuietly(zos);
+                IOUtils.closeQuietly(fos);
+            }
+        }
+        return flag;
+    }
+
+    public static void createDirectory(String downloadDirectory) {
+        File directory = new File(downloadDirectory);
+        if (!directory.exists()) {
+            directory.mkdirs();
+        } else {
+            FileUtils.deleteQuietly(directory);
+            directory.mkdirs();
+        }
+    }
+
+    /**
+     * 获得文件的byte数组
+     *
+     * @param filePath
+     * @return
+     * @throws IOException
+     */
+    public static byte[] getBytes(String filePath) throws IOException {
+        File file = new File(filePath);
         if (!file.exists()) {
             throw new FileNotFoundException(filePath);
         }
@@ -251,7 +241,7 @@ public class FileDisposeUtil {
             bos.close();
         }
     }
-	
+
     public static File createZip(String sourceFilePath, String targetFilePath) throws IOException {
         OutputStream fos = null;
         ZipOutputStream zos = null;
@@ -272,7 +262,7 @@ public class FileDisposeUtil {
             }
         }
     }
-    
+
     private static void writeZip(File file, String parentPath, ZipOutputStream zos) throws IOException {
         if (file.exists()) {
             ZipEntry ze = null;
@@ -327,7 +317,7 @@ public class FileDisposeUtil {
             }
         }
     }
-    
+
     /**
      * 解压文件
      *
@@ -336,20 +326,20 @@ public class FileDisposeUtil {
      */
     public static List<File> unZip(File targetDir, File zipFile) {
         if (targetDir == null) {
-        	throw new RuntimeException("解压目录不能为空!");
+            throw new RuntimeException("解压目录不能为空!");
         }
 
         if (zipFile == null) {
-        	throw new RuntimeException("待解压的文件不能为空!");
+            throw new RuntimeException("待解压的文件不能为空!");
         }
 
         if (!zipFile.exists()) {
-        	throw new RuntimeException("待解压的文件不存在!" + zipFile.getAbsolutePath());
+            throw new RuntimeException("待解压的文件不存在!" + zipFile.getAbsolutePath());
         }
 
         String zipName = zipFile.getName().toLowerCase();
         if (zipFile.isDirectory() || zipName.indexOf(".zip") < 0) {
-        	throw new RuntimeException("待解压的文件格式错误!");
+            throw new RuntimeException("待解压的文件格式错误!");
         }
 
         if (!targetDir.exists()) {
@@ -382,16 +372,17 @@ public class FileDisposeUtil {
                         IOUtils.copy(is, os);
                         os.flush();
                     } catch (IOException e) {
-                    	throw new RuntimeException(e.getMessage(), e);
+                        throw new RuntimeException(e.getMessage(), e);
                     }
                     result.add(target);
                 }
             }
 
         } catch (IOException e) {
-        	throw new RuntimeException(e.getMessage(), e);
+            throw new RuntimeException(e.getMessage(), e);
         }
 
         return result;
     }
+
 }