1
0
xiatian 1 жил өмнө
parent
commit
654b64a906

+ 7 - 2
stmms-web/src/main/java/cn/com/qmth/stmms/admin/exam/InspectedController.java

@@ -628,9 +628,14 @@ public class InspectedController extends BaseExamController {
         long total = studentService.countByQuery(sQuery);
         long total = studentService.countByQuery(sQuery);
         model.addAttribute("unMarkedCount", total - markedCount);
         model.addAttribute("unMarkedCount", total - markedCount);
         model.addAttribute("markedCount", markedCount);
         model.addAttribute("markedCount", markedCount);
-        long subjectCount = subjectService.count(examId);
+//        long subjectCount = subjectService.count(examId);
+        Set<String> hasTask = studentService.findSubjectHasTaskByExamId(examId);
+        long hasTaskCount=0;
+        if(hasTask!=null) {
+        	hasTaskCount=hasTask.size();
+        }
         model.addAttribute("unFinishCount", unFinishSet.size());
         model.addAttribute("unFinishCount", unFinishSet.size());
-        model.addAttribute("finishCount", subjectCount - unFinishSet.size());
+        model.addAttribute("finishCount", hasTaskCount - unFinishSet.size());
         model.addAttribute("resultList", list);
         model.addAttribute("resultList", list);
         model.addAttribute("query", query);
         model.addAttribute("query", query);
         model.addAttribute("subjectList", getExamSubject(examId, wu));
         model.addAttribute("subjectList", getExamSubject(examId, wu));