Unverified Commit 442ce3b0 authored by Zzm0809's avatar Zzm0809 Committed by GitHub

[Optimization-2885][web] Automatically switch console and result tags (#2886)

* Spotless Apply * Spotless Apply * auto-check-tags * Spotless Apply --------- Co-authored-by: 's avatarZzm0809 <Zzm0809@users.noreply.github.com>
parent 0edde40a
......@@ -92,8 +92,7 @@ export default class LineageDagExt extends LineageDag {
edges: result.edges
};
setTimeout(
() => {
setTimeout(() => {
let tmpEdges = result.edges;
result.edges = [];
// this.canvas.wrapper.style.visibility = 'hidden';
......@@ -141,8 +140,6 @@ export default class LineageDagExt extends LineageDag {
this.canvas.on('system.canvas.click', () => {
this.canvas.unfocus();
});
},
_.get(this.props, 'config.delayDraw', 0)
);
}, _.get(this.props, 'config.delayDraw', 0));
}
}
......@@ -20,6 +20,7 @@
import { LoadingBtn } from '@/components/CallBackButton/LoadingBtn';
import { PushpinIcon } from '@/components/Icons/CustomIcons';
import { FlexCenterDiv } from '@/components/StyledComponents';
import { LeftBottomKey } from '@/pages/DataStudio/data.d';
import { getCurrentData, getCurrentTab, mapDispatchToProps } from '@/pages/DataStudio/function';
import Explain from '@/pages/DataStudio/HeaderContainer/Explain';
import FlinkGraph from '@/pages/DataStudio/HeaderContainer/FlinkGraph';
......@@ -100,6 +101,7 @@ const HeaderContainer = (props: connect) => {
tabs: { panes, activeKey },
saveTabs,
updateJobRunningMsg,
updateSelectBottomKey,
queryDsConfig,
queryTaskData,
enabledDs
......@@ -189,6 +191,7 @@ const HeaderContainer = (props: connect) => {
};
const handlerDebug = async () => {
updateSelectBottomKey(LeftBottomKey.CONSOLE_KEY);
if (!currentData) return;
// @ts-ignore
const editor = currentTab.monacoInstance.editor
......@@ -208,7 +211,12 @@ const HeaderContainer = (props: connect) => {
{ ...currentData, statement: selectSql }
);
if (!res) return;
if (!res) {
return;
} else {
updateSelectBottomKey(LeftBottomKey.RESULT_KEY);
}
updateJobRunningMsg({
taskId: currentData.id,
jobName: currentData.name,
......@@ -232,6 +240,8 @@ const HeaderContainer = (props: connect) => {
};
const handlerSubmit = async () => {
updateSelectBottomKey(LeftBottomKey.CONSOLE_KEY);
if (!currentData) return;
const saved = currentData.step == JOB_LIFE_CYCLE.PUBLISH ? true : await handleSave();
if (!saved) return;
......
......@@ -17,6 +17,7 @@
*
*/
import { LeftBottomKey, LeftMenuKey } from '@/pages/DataStudio/data.d';
import { getFooterValue, isDataStudioTabsItemType } from '@/pages/DataStudio/function';
import { getDataSourceList } from '@/pages/DataStudio/LeftContainer/DataSource/service';
import { getTaskData } from '@/pages/DataStudio/LeftContainer/Project/service';
......@@ -356,7 +357,7 @@ const Model: ModelType = {
toolContentHeight: 0,
centerContentHeight: 0,
leftContainer: {
selectKey: 'menu.datastudio.project',
selectKey: LeftMenuKey.PROJECT_KEY,
selectSubKey: {},
height: '100%',
width: 260
......@@ -368,7 +369,7 @@ const Model: ModelType = {
width: 260
},
bottomContainer: {
selectKey: 'menu.datastudio.console',
selectKey: LeftBottomKey.CONSOLE_KEY,
selectSubKey: {},
height: 180,
width: '100%'
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment