xiatian 3 anni fa
parent
commit
a5bfaf434b

+ 3 - 1
examcloud-core-questions-service/src/main/java/cn/com/qmth/examcloud/core/questions/service/impl/PaperServiceImpl.java

@@ -1223,7 +1223,9 @@ public class PaperServiceImpl implements PaperService {
         query.addCriteria(Criteria.where("paperType").is(paperType));
         query.addCriteria(Criteria.where("course.code").is(paperSearchInfo.getCourseNo()));
         query.addCriteria(Criteria.where("id").nin(selectedIds));
-
+        if(PaperType.GENERATE.equals(paperType)) {
+        	query.addCriteria(Criteria.where("storage").ne(1));
+        }
         long total = this.mongoTemplate.count(query, Paper.class);
         if (total == 0) {
             return Page.empty();