|
@@ -1742,8 +1742,18 @@ public class TaskLogicServiceImpl implements TaskLogicService {
|
|
|
|
|
|
|
|
|
byte[] bytes = htmlContent.getBytes();
|
|
|
- String cardLocalHtmlPath = filePath + "题卡-" + examCardService.getById(examCardId).getTitle() + SystemConstant.HTML_PREFIX;
|
|
|
- String cardLocalPdfPath = filePath + "题卡-" + examCardService.getById(examCardId).getTitle() + SystemConstant.PDF_PREFIX;
|
|
|
+ String cardName = "题卡-";
|
|
|
+ if (namedByCourseInfo){
|
|
|
+ cardName = cardName + course;
|
|
|
+ }
|
|
|
+ if (namedByPaperNumber){
|
|
|
+ cardName = cardName + paperNumber;
|
|
|
+ }
|
|
|
+ if (namedByOriginalFile){
|
|
|
+ cardName = cardName + examCardService.getById(examCardId).getTitle();
|
|
|
+ }
|
|
|
+ String cardLocalHtmlPath = filePath + cardName + SystemConstant.HTML_PREFIX;
|
|
|
+ String cardLocalPdfPath = filePath + cardName + SystemConstant.PDF_PREFIX;
|
|
|
|
|
|
switch (paperFileDownloadContent) {
|
|
|
case ONLY_CARD:
|
|
@@ -1771,6 +1781,7 @@ public class TaskLogicServiceImpl implements TaskLogicService {
|
|
|
if (namedByOriginalFile){
|
|
|
paperName = paperName + examTaskPaperFileDto.getPaperName();
|
|
|
}
|
|
|
+ paperName = paperName + "-" + examTaskPaperFileDto.getPaperType();
|
|
|
String paperLocalPath = filePath + paperName + examTaskPaperFileDto.getPaperSuffix();
|
|
|
String paperPath = examTaskPaperFileDto.getPaperPath();
|
|
|
fileStoreUtil.ossDownload(paperPath, paperLocalPath, fileStoreUtil.getUploadEnumByPath(paperPath).getFssType());
|
|
@@ -1801,6 +1812,7 @@ public class TaskLogicServiceImpl implements TaskLogicService {
|
|
|
if (namedByOriginalFile){
|
|
|
paperName = paperName + examTaskPaperFileDto.getPaperName();
|
|
|
}
|
|
|
+ paperName = paperName + "-" + examTaskPaperFileDto.getPaperType();
|
|
|
String paperLocalPath = filePath + paperName + examTaskPaperFileDto.getPaperSuffix();
|
|
|
String paperPath = examTaskPaperFileDto.getPaperPath();
|
|
|
fileStoreUtil.ossDownload(paperPath, paperLocalPath, fileStoreUtil.getUploadEnumByPath(paperPath).getFssType());
|