Merge pull request #13951 from dataease/pr@dev-v2@perf_ds_excel_upload

perf(数据源): Excel 数据源上传失败
This commit is contained in:
dataeaseShu
2024-12-11 09:51:39 +08:00
committed by GitHub

View File

@@ -773,8 +773,10 @@ public class DatasourceServer implements DatasourceApi {
private static final Integer append = 1;
public ExcelFileData excelUpload(@RequestParam("file") MultipartFile file, @RequestParam("id") long datasourceId, @RequestParam("editType") Integer editType) throws DEException {
CoreDatasource coreDatasource = dataSourceManage.getCoreDatasource(datasourceId);
CoreDatasource coreDatasource = null;
if (ObjectUtils.isNotEmpty(datasourceId) && 0L != datasourceId) {
coreDatasource = dataSourceManage.getCoreDatasource(datasourceId);
}
ExcelUtils excelUtils = new ExcelUtils();
ExcelFileData excelFileData = excelUtils.excelSaveAndParse(file);