he2802 3 år sedan
förälder
incheckning
fda176cba2

+ 8 - 2
zhongzheng-system/src/main/java/com/zhongzheng/modules/bank/service/impl/QuestionServiceImpl.java

@@ -547,6 +547,7 @@ public class QuestionServiceImpl extends ServiceImpl<QuestionMapper, Question> i
                                 j++;
                             }
                             analysisContent+=q_content;
+                            i = j;
                         }
                         //考查考点
                         else if(content.startsWith("考查考点:")){
@@ -562,7 +563,7 @@ public class QuestionServiceImpl extends ServiceImpl<QuestionMapper, Question> i
                                 j++;
                             }
                             analysisContent = analysisContent + "\r\n" +q_content;
-
+                            i = j;
                         }
                         //老师解答
                         else if(content.startsWith("老师解答:")){
@@ -578,6 +579,7 @@ public class QuestionServiceImpl extends ServiceImpl<QuestionMapper, Question> i
                                 j++;
                             }
                             analysisContent = analysisContent + "\r\n" +q_content;
+                           
                         }
                         //问答题问题
                         else if(content.startsWith("【问题】")){
@@ -596,6 +598,8 @@ public class QuestionServiceImpl extends ServiceImpl<QuestionMapper, Question> i
                             q_content = q_content.replace("【问题】", "");
                             QuestionChildAddBo bo1 = optionsList.get(0);
                             bo1.setContent(q_content);
+                            i = j;
+                            continue;
                         }
                         //题目正文
                         else{
@@ -608,10 +612,12 @@ public class QuestionServiceImpl extends ServiceImpl<QuestionMapper, Question> i
                                     break;
                                 }
                                 q_content+=tempTxt;
+                                System.out.println("正文"+q_content);
                                 j++;
                             }
-                            q_content = q_content.replace("考查考点:", "");
                             qContent = q_content;
+                            i = j;
+                            continue;
                         }
                     }else{
                        System.out.println("换行");