瀏覽代碼

判断题答案过滤html代码

chenken 8 年之前
父節點
當前提交
076f0eefc2
共有 1 個文件被更改,包括 2 次插入1 次删除
  1. 2 1
      cqb-paper/src/main/java/com/qmth/cqb/paper/service/ImportPaperService.java

+ 2 - 1
cqb-paper/src/main/java/com/qmth/cqb/paper/service/ImportPaperService.java

@@ -603,7 +603,8 @@ public class ImportPaperService {
         if (answerHTML.length() > 0) {
         	//选择题过滤html标签--chenken 2017.4.25
         	if (question.getQuestionType()==QuesStructType.SINGLE_ANSWER_QUESTION||
-        		question.getQuestionType()==QuesStructType.MULTIPLE_ANSWER_QUESTION){
+        		question.getQuestionType()==QuesStructType.MULTIPLE_ANSWER_QUESTION||
+        		question.getQuestionType()==QuesStructType.BOOL_ANSWER_QUESTION){
         		String regEx_html="<[^>]+>";
         		Pattern p_html=Pattern.compile(regEx_html,Pattern.CASE_INSENSITIVE);
                 Matcher m_html=p_html.matcher(answerHTML.toString()); //过滤html标签