|
@@ -8,8 +8,6 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
import com.qmth.distributed.print.business.bean.dto.*;
|
|
|
import com.qmth.distributed.print.business.entity.*;
|
|
|
import com.qmth.distributed.print.business.enums.ExamDetailStatusEnum;
|
|
|
-import com.qmth.distributed.print.business.enums.ExamStatusEnum;
|
|
|
-import com.qmth.distributed.print.business.enums.PrintPlanStatusEnum;
|
|
|
import com.qmth.distributed.print.business.service.*;
|
|
|
import com.qmth.distributed.print.business.util.ExcelUtil;
|
|
|
import com.qmth.distributed.print.business.util.ServletUtil;
|
|
@@ -68,15 +66,15 @@ public class ClientServiceImpl implements ClientService {
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
- public Map<String, String> getUrl(Long examTaskId) {
|
|
|
+ public Map<String, String> getUrl(Long printPlanId, Long examTaskId) {
|
|
|
Long schoolId = Long.valueOf(ServletUtil.getRequestHeaderSchoolId().toString());
|
|
|
- return examTaskDetailService.getUrl(schoolId, examTaskId);
|
|
|
+ return examTaskDetailService.getUrl(schoolId, printPlanId, examTaskId);
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
- public Boolean tagPass(String courseCode, String courseName, String paperNumber, String machineCode, Boolean isPass, Long userId) {
|
|
|
+ public Boolean tagPass(Long printPlanId, String courseCode, String courseName, String paperNumber, String machineCode, Boolean isPass, Long userId) {
|
|
|
Long schoolId = Long.valueOf(ServletUtil.getRequestHeaderSchoolId().toString());
|
|
|
- return clientStatusService.tagPass(schoolId, courseCode, courseName, paperNumber, machineCode, isPass, userId);
|
|
|
+ return clientStatusService.tagPass(schoolId, printPlanId, courseCode, courseName, paperNumber, machineCode, isPass, userId);
|
|
|
}
|
|
|
|
|
|
@Override
|
|
@@ -302,9 +300,11 @@ public class ClientServiceImpl implements ClientService {
|
|
|
}
|
|
|
String examTaskId = examDetailCours.get("examTaskId").toString();
|
|
|
UpdateWrapper<ExamTaskDetail> examTaskDetailUpdateWrapper = new UpdateWrapper<>();
|
|
|
+ String exposedPaper = String.join(",", exposedPaperSet);
|
|
|
+ String unexposedPaper = String.join(",", unexposedPaperSet);
|
|
|
examTaskDetailUpdateWrapper.lambda()
|
|
|
- .set(ExamTaskDetail::getExposedPaperType, String.join(",", exposedPaperSet))
|
|
|
- .set(ExamTaskDetail::getUnexposedPaperType, String.join(",", unexposedPaperSet))
|
|
|
+ .set(ExamTaskDetail::getExposedPaperType, StringUtils.isBlank(exposedPaper) ? null : exposedPaper)
|
|
|
+ .set(ExamTaskDetail::getUnexposedPaperType, StringUtils.isBlank(unexposedPaper) ? null : unexposedPaper)
|
|
|
.eq(ExamTaskDetail::getExamTaskId, examTaskId);
|
|
|
examTaskDetailService.update(examTaskDetailUpdateWrapper);
|
|
|
}
|
|
@@ -456,10 +456,11 @@ public class ClientServiceImpl implements ClientService {
|
|
|
List<Map<String, String>> list = new ArrayList<>();
|
|
|
for (ClientExamTaskDto clientExamTaskDto : clientExamTaskDtos) {
|
|
|
Map<String, String> map = new HashMap<>();
|
|
|
+ map.put("printPlanId", clientExamTaskDto.getPrintPlanId());
|
|
|
map.put("courseCode", clientExamTaskDto.getCourseCode());
|
|
|
map.put("courseName", clientExamTaskDto.getCourseName());
|
|
|
map.put("paperNumber", clientExamTaskDto.getPaperNumber());
|
|
|
- Map<String, String> stringMap = examTaskDetailService.getUrl(schoolId, Long.valueOf(clientExamTaskDto.getExamTaskId()));
|
|
|
+ Map<String, String> stringMap = examTaskDetailService.getUrl(schoolId, printPlanId, Long.valueOf(clientExamTaskDto.getExamTaskId()));
|
|
|
map.putAll(stringMap);
|
|
|
list.add(map);
|
|
|
}
|
|
@@ -489,7 +490,7 @@ public class ClientServiceImpl implements ClientService {
|
|
|
String pEndTime = simpleDateFormat.format(new Date(m.getPrintEndTime()));
|
|
|
m.setPrintEndTimeStr(pEndTime);
|
|
|
}
|
|
|
- m.setStatusStr(ExamStatusEnum.valueOf(m.getStatus()).getDesc());
|
|
|
+ m.setStatusStr(ExamDetailStatusEnum.valueOf(m.getStatus()).getDesc());
|
|
|
m.setValidateStr(m.getValidate() ? "是" : "否");
|
|
|
m.setDownloadStr(m.getDownload() ? "是" : "否");
|
|
|
return m;
|