Selaa lähdekoodia

fix 题库导入

he2802 3 vuotta sitten
vanhempi
commit
0ac14ed671

+ 2 - 0
zhongzheng-system/src/main/java/com/zhongzheng/modules/bank/bo/ExamQueryBo.java

@@ -83,4 +83,6 @@ public class ExamQueryBo extends BaseEntity {
 	/** 项目ID */
 	@ApiModelProperty("项目ID")
 	private Long projectId;
+	@ApiModelProperty("关键词")
+	private String searchKey;
 }

+ 1 - 0
zhongzheng-system/src/main/java/com/zhongzheng/modules/bank/bo/QuestionChapterQueryBo.java

@@ -70,4 +70,5 @@ public class QuestionChapterQueryBo extends BaseEntity {
 	/** 项目ID */
 	@ApiModelProperty("项目ID")
 	private Long projectId;
+
 }

+ 2 - 0
zhongzheng-system/src/main/java/com/zhongzheng/modules/bank/bo/QuestionModuleQueryBo.java

@@ -64,4 +64,6 @@ public class QuestionModuleQueryBo extends BaseEntity {
 	/** 项目ID */
 	@ApiModelProperty("项目ID")
 	private Long projectId;
+	@ApiModelProperty("关键词")
+	private String searchKey;
 }

+ 3 - 0
zhongzheng-system/src/main/resources/mapper/modules/bank/QuestionModuleMapper.xml

@@ -98,6 +98,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <if test="prefixName != null and prefixName != ''">
             AND qm.prefix_name  like concat('%', #{prefixName}, '%')
         </if>
+        <if test="searchKey != null and searchKey != '' ">
+            and (qm.module_name like concat('%', #{searchKey}, '%') or qm.code like concat('%', #{searchKey}, '%') or qm.prefix_name like concat('%', #{searchKey}, '%'))
+        </if>
         ORDER BY qm.module_exam_id DESC
     </select>
 </mapper>