fix(数据集): 任务管理中预览数据

This commit is contained in:
taojinlong 2022-08-25 15:21:16 +08:00
parent dc754054b4
commit 6b436eb6e6
2 changed files with 5 additions and 2 deletions

View File

@ -616,6 +616,9 @@ public class DataSetTableService {
// check doris table
if (!checkEngineTableIsExists(dataSetTableRequest.getId())) {
if (dataSetTableRequest.isPreviewForTask()) {
map.put("fields", fields);
map.put("data", new ArrayList<>());
map.put("page", new DataSetPreviewPage());
return map;
} else {
throw new RuntimeException(Translator.get("i18n_data_not_sync"));

View File

@ -138,7 +138,6 @@ export default {
table: [],
filterText: "",
fields: [],
tableName: "",
dataLoading: false,
treeLoading: false,
};
@ -184,6 +183,7 @@ export default {
initData(table) {
this.dataLoading = true;
table.row = 100;
table.previewForTask = true
post("/dataset/table/getPreviewData/1/100", table, false, 30000)
.then((response) => {
this.fields = response.data.fields;