|
@@ -53,20 +53,21 @@ public class ExamCardController {
|
|
|
|
|
|
/**
|
|
|
* 题卡管理(通卡管理)
|
|
|
- * @param type 题卡类型(通卡或专卡)
|
|
|
- * @param title 题卡名称模糊查询
|
|
|
- * @param createMethod 题卡创建方式(上传、自定义)
|
|
|
- * @param enable 1正常/0禁用
|
|
|
+ *
|
|
|
+ * @param type 题卡类型(通卡或专卡)
|
|
|
+ * @param title 题卡名称模糊查询
|
|
|
+ * @param createMethod 题卡创建方式(上传、自定义)
|
|
|
+ * @param enable 1正常/0禁用
|
|
|
* @param createStartTime 创建时间(开始)
|
|
|
- * @param createEndTime 创建时间(结束)
|
|
|
- * @param pageNumber 分页参数
|
|
|
- * @param pageSize 分页参数
|
|
|
+ * @param createEndTime 创建时间(结束)
|
|
|
+ * @param pageNumber 分页参数
|
|
|
+ * @param pageSize 分页参数
|
|
|
* @return Result
|
|
|
*/
|
|
|
@ApiOperation(value = "分页查询")
|
|
|
@RequestMapping(value = "/page", method = RequestMethod.POST)
|
|
|
@OperationLogDetail(customizedOperationType = CustomizedOperationTypeEnum.SEARCH)
|
|
|
- public Result page(@RequestParam(value = "type", defaultValue = "GENERIC") String type,
|
|
|
+ public Result page(@RequestParam(value = "type", required = false) String type,
|
|
|
@RequestParam(value = "title", required = false) String title,
|
|
|
@RequestParam(value = "createMethod", required = false) String createMethod,
|
|
|
@RequestParam(value = "enable", required = false) Boolean enable,
|
|
@@ -80,6 +81,7 @@ public class ExamCardController {
|
|
|
|
|
|
/**
|
|
|
* 题卡管理(通卡管理)-新增/修改
|
|
|
+ *
|
|
|
* @param params 保存传值参数
|
|
|
* @return Result
|
|
|
*/
|
|
@@ -88,11 +90,12 @@ public class ExamCardController {
|
|
|
@OperationLogDetail(customizedOperationType = CustomizedOperationTypeEnum.EDIT)
|
|
|
public Result save(@RequestBody GenericExamCardParams params) throws Exception {
|
|
|
Long id = examCardService.saveGeneric(params);
|
|
|
- return ResultUtil.ok(String.valueOf(id),"");
|
|
|
+ return ResultUtil.ok(String.valueOf(id), "");
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 题卡管理(通卡管理)-删除
|
|
|
+ *
|
|
|
* @param id 题卡ID
|
|
|
* @return Result
|
|
|
*/
|
|
@@ -106,10 +109,9 @@ public class ExamCardController {
|
|
|
//====================================通卡接口↑(end)===================================
|
|
|
|
|
|
/**
|
|
|
- * 新建
|
|
|
+ * 新建专卡
|
|
|
*
|
|
|
* @param examCardParams
|
|
|
- * @return
|
|
|
*/
|
|
|
@ApiOperation(value = "新建")
|
|
|
@RequestMapping(value = "/save", method = RequestMethod.POST)
|
|
@@ -177,14 +179,15 @@ public class ExamCardController {
|
|
|
|
|
|
/**
|
|
|
* 选择已有题卡列表
|
|
|
- * @param examId 考试id
|
|
|
+ *
|
|
|
+ * @param examId 考试id
|
|
|
* @param courseCode 课程编号
|
|
|
* @return 结果
|
|
|
*/
|
|
|
@ApiOperation(value = "选择已有题卡列表")
|
|
|
@RequestMapping(value = "/select_card_list", method = RequestMethod.POST)
|
|
|
- public Result selectCardList(@RequestParam String examId,@RequestParam String courseCode, @RequestParam(required = false) String paperNumber) {
|
|
|
- BasicPrintConfig basicPrintConfig = basicPrintConfigService.getByExamIdAndCourseCode(SystemConstant.convertIdToLong(examId),courseCode);
|
|
|
+ public Result selectCardList(@RequestParam String examId, @RequestParam String courseCode, @RequestParam(required = false) String paperNumber) {
|
|
|
+ BasicPrintConfig basicPrintConfig = basicPrintConfigService.getByExamIdAndCourseCode(SystemConstant.convertIdToLong(examId), courseCode);
|
|
|
List<ExamCard> list = examCardService.listSelectCard(courseCode, basicPrintConfig.getCardRuleId(), paperNumber);
|
|
|
return ResultUtil.ok(list);
|
|
|
}
|
|
@@ -210,7 +213,19 @@ public class ExamCardController {
|
|
|
@RequestMapping(value = "/copy", method = RequestMethod.POST)
|
|
|
public Result copyCard(@RequestParam(value = "id") String id,
|
|
|
@RequestParam(value = "courseCode") String courseCode) {
|
|
|
- Long copyCardId = examCardService.copyCard(SystemConstant.convertIdToLong(id),courseCode);
|
|
|
+ Long copyCardId = examCardService.copyCard(SystemConstant.convertIdToLong(id), courseCode);
|
|
|
return ResultUtil.ok(String.valueOf(copyCardId), "");
|
|
|
}
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 题卡转图片
|
|
|
+ *
|
|
|
+ * @param id 题卡id
|
|
|
+ */
|
|
|
+ @ApiOperation(value = "题卡转图片")
|
|
|
+ @RequestMapping(value = "/convert_image", method = RequestMethod.POST)
|
|
|
+ public Result convertImage(@RequestParam(value = "id") String id) {
|
|
|
+ examCardService.convertImage(SystemConstant.convertIdToLong(id));
|
|
|
+ return ResultUtil.ok(true, "");
|
|
|
+ }
|
|
|
}
|