|
@@ -280,11 +280,35 @@ public class ProjectListService {
|
|
|
}
|
|
|
String currentToken = TokenProvider.getCurrentToken();
|
|
|
if (ObjectUtil.isNotEmpty(programArchiveDto)) {
|
|
|
- SpringUtil.getBean ( IWorkAttachmentApi.class ).saveOrUpdateFileListFlag(programArchiveDto.getReportFileList(),programArchive.getId(),"report",currentToken);
|
|
|
- SpringUtil.getBean ( IWorkAttachmentApi.class ).saveOrUpdateFileListFlag(programArchiveDto.getDetailFileList(),programArchive.getId(),"detail",currentToken);
|
|
|
- SpringUtil.getBean ( IWorkAttachmentApi.class ).saveOrUpdateFileListFlag(programArchiveDto.getExplainFileList(),programArchive.getId(),"explain",currentToken);
|
|
|
- SpringUtil.getBean ( IWorkAttachmentApi.class ).saveOrUpdateFileListFlag(programArchiveDto.getPapersFileList(),programArchive.getId(),"papers",currentToken);
|
|
|
- SpringUtil.getBean ( IWorkAttachmentApi.class ).saveOrUpdateFileListFlag(programArchiveDto.getOtherFileList(),programArchive.getId(),"other",currentToken);
|
|
|
+ Map<String,String> map = new HashMap<>();
|
|
|
+ String fileList = JSON.toJSONString((programArchiveDto.getReportFileList()));
|
|
|
+ String attachmentId = programArchive.getId();
|
|
|
+ String attachmentFlag = "report";
|
|
|
+ map.put("fileList",fileList);
|
|
|
+ map.put("attachmentId",attachmentId);
|
|
|
+ map.put("attachmentFlag",attachmentFlag);
|
|
|
+ map.put("currentToken", TokenProvider.getCurrentToken ( ));
|
|
|
+ SpringUtil.getBean ( IWorkAttachmentApi.class ).saveOrUpdateFileListFlag(map);
|
|
|
+ fileList = JSON.toJSONString((programArchiveDto.getDetailFileList()));
|
|
|
+ attachmentFlag = "detail";
|
|
|
+ map.put("fileList",fileList);
|
|
|
+ map.put("attachmentFlag",attachmentFlag);
|
|
|
+ SpringUtil.getBean ( IWorkAttachmentApi.class ).saveOrUpdateFileListFlag(map);
|
|
|
+ fileList = JSON.toJSONString((programArchiveDto.getExplainFileList()));
|
|
|
+ attachmentFlag = "explain";
|
|
|
+ map.put("fileList",fileList);
|
|
|
+ map.put("attachmentFlag",attachmentFlag);
|
|
|
+ SpringUtil.getBean ( IWorkAttachmentApi.class ).saveOrUpdateFileListFlag(map);
|
|
|
+ fileList = JSON.toJSONString((programArchiveDto.getPapersFileList()));
|
|
|
+ attachmentFlag = "papers";
|
|
|
+ map.put("fileList",fileList);
|
|
|
+ map.put("attachmentFlag",attachmentFlag);
|
|
|
+ SpringUtil.getBean ( IWorkAttachmentApi.class ).saveOrUpdateFileListFlag(map);
|
|
|
+ fileList = JSON.toJSONString((programArchiveDto.getOtherFileList()));
|
|
|
+ attachmentFlag = "other";
|
|
|
+ map.put("fileList",fileList);
|
|
|
+ map.put("attachmentFlag",attachmentFlag);
|
|
|
+ SpringUtil.getBean ( IWorkAttachmentApi.class ).saveOrUpdateFileListFlag(map);
|
|
|
}
|
|
|
return programArchive.getId();
|
|
|
}
|