|
@@ -11,6 +11,7 @@ import com.qmth.distributed.print.business.service.ExamTaskDetailService;
|
|
|
import com.qmth.distributed.print.business.service.ExamTaskService;
|
|
|
import com.qmth.teachcloud.common.entity.BasicAttachment;
|
|
|
import com.qmth.teachcloud.common.service.BasicAttachmentService;
|
|
|
+import com.qmth.teachcloud.common.util.DateDisposeUtils;
|
|
|
import com.qmth.teachcloud.common.util.OssUtil;
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
import org.apache.poi.ss.usermodel.*;
|
|
@@ -25,6 +26,7 @@ import java.io.File;
|
|
|
import java.io.FileOutputStream;
|
|
|
import java.io.IOException;
|
|
|
import java.util.ArrayList;
|
|
|
+import java.util.Date;
|
|
|
import java.util.List;
|
|
|
|
|
|
/**
|
|
@@ -57,6 +59,7 @@ public class ExamTaskPaperExportTest {
|
|
|
for (ExamTask examTask : examTaskList) {
|
|
|
String paperNumberRoot = examRoot + File.separator + String.format("%s(%s)", examTask.getCourseName(), examTask.getCourseCode()) + File.separator + examTask.getPaperNumber();
|
|
|
ExamTaskDetail examTaskDetail = examTaskDetailService.getByExamTaskId(examTask.getId());
|
|
|
+ String applyDate = DateDisposeUtils.dateTime(new Date(examTask.getCreateTime()));
|
|
|
if (examTaskDetail != null && StringUtils.isNotBlank(examTaskDetail.getPaperAttachmentIds())) {
|
|
|
List<JSONObject> objectList = JSON.parseArray(examTaskDetail.getPaperAttachmentIds(), JSONObject.class);
|
|
|
boolean success = false;
|
|
@@ -88,7 +91,7 @@ public class ExamTaskPaperExportTest {
|
|
|
}
|
|
|
}
|
|
|
if (success) {
|
|
|
- examTaskExportVoList.add(new ExamTaskExportVo(examTask.getCourseCode(), examTask.getCourseName(), examTask.getPaperNumber(), examTaskDetail.getPaperType(), examTaskDetail.getExposedPaperType(), examTaskDetail.getUnexposedPaperType()));
|
|
|
+ examTaskExportVoList.add(new ExamTaskExportVo(examTask.getCourseCode(), examTask.getCourseName(), examTask.getPaperNumber(), examTaskDetail.getPaperType(), examTaskDetail.getExposedPaperType(), examTaskDetail.getUnexposedPaperType(), applyDate));
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -170,7 +173,7 @@ public class ExamTaskPaperExportTest {
|
|
|
|
|
|
XSSFRow headRow = sheet.createRow(0);
|
|
|
// 表头
|
|
|
- String[] fieldsNameList = {"课程代码", "课程名称", "试着编号", "上传所有卷型", "已曝光卷型", "未曝光卷型"};
|
|
|
+ String[] fieldsNameList = {"课程代码", "课程名称", "试着编号", "上传所有卷型", "已曝光卷型", "未曝光卷型", "命题时间"};
|
|
|
for (int i = 0; i < fieldsNameList.length; i++) {
|
|
|
XSSFCell cell = headRow.createCell(i);
|
|
|
cell.setCellValue(fieldsNameList[i]);
|
|
@@ -210,6 +213,11 @@ public class ExamTaskPaperExportTest {
|
|
|
// cell5.setCellStyle(lockStyle);
|
|
|
cell5.setCellStyle(dataStyle);
|
|
|
cell5.setCellValue(examTaskExportVo.getUnExposePaperType());
|
|
|
+
|
|
|
+ XSSFCell cell6 = row.createCell(6);
|
|
|
+// cell5.setCellStyle(lockStyle);
|
|
|
+ cell6.setCellStyle(dataStyle);
|
|
|
+ cell6.setCellValue(examTaskExportVo.getApplyDate());
|
|
|
}
|
|
|
|
|
|
for (int i = 0; i < fieldsNameList.length; i++) {
|