|
@@ -618,7 +618,7 @@ public class PaperServiceImpl implements PaperService{
|
|
subQues.setQuesParams(params);
|
|
subQues.setQuesParams(params);
|
|
quesService.formatQuesUnit(subQues);
|
|
quesService.formatQuesUnit(subQues);
|
|
}
|
|
}
|
|
- String quesBodyHtml = relaceQuestionIdx(question.getQuesBody(),0);
|
|
|
|
|
|
+ String quesBodyHtml = CommonUtils.relaceQuestionIdx(question.getQuesBody(),0);
|
|
question.setQuesBody(quesBodyHtml);
|
|
question.setQuesBody(quesBodyHtml);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -627,8 +627,6 @@ public class PaperServiceImpl implements PaperService{
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
-
|
|
|
|
-
|
|
|
|
/**
|
|
/**
|
|
* 格式化查询条件
|
|
* 格式化查询条件
|
|
*
|
|
*
|
|
@@ -939,25 +937,6 @@ public class PaperServiceImpl implements PaperService{
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
- private String relaceQuestionIdx(String str, int baseIdx) {
|
|
|
|
- StringBuffer sb = new StringBuffer("");
|
|
|
|
- Pattern pattern = Pattern.compile("##(\\d+)##");
|
|
|
|
-
|
|
|
|
- Matcher matcher = pattern.matcher(str);
|
|
|
|
-
|
|
|
|
- while (matcher.find()) {
|
|
|
|
- String idx = matcher.group(1);
|
|
|
|
- matcher.appendReplacement(sb, "___" + String.valueOf(Integer.parseInt(idx) + baseIdx) + "___");
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- if (StringUtils.isEmpty(sb.toString())) {
|
|
|
|
- return str;
|
|
|
|
- } else {
|
|
|
|
- matcher.appendTail(sb);
|
|
|
|
- return sb.toString();
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
public Page<Paper> getPapersNotInIds(PaperSearchInfo paperSearchInfo, String[] ids, int curPage,int pageSize,PaperType paperType) {
|
|
public Page<Paper> getPapersNotInIds(PaperSearchInfo paperSearchInfo, String[] ids, int curPage,int pageSize,PaperType paperType) {
|
|
Set<String> selectedIds = new HashSet<>();
|
|
Set<String> selectedIds = new HashSet<>();
|
|
for (String id : ids) {
|
|
for (String id : ids) {
|