Skip to content

Commit

Permalink
Spotless Apply
Browse files Browse the repository at this point in the history
  • Loading branch information
Zzm0809 authored and github-actions[bot] committed Dec 22, 2023
1 parent fd88de5 commit d7a2038
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 8 deletions.
4 changes: 3 additions & 1 deletion dinky-web/src/pages/DataStudio/HeaderContainer/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,9 @@ const HeaderContainer = (props: connect) => {
const handlerDebug = async () => {
if (!currentData) return;
// @ts-ignore
const editor = currentTab.monacoInstance.editor.getEditors().find((x:any)=>x["id"]===currentData.id);
const editor = currentTab.monacoInstance.editor
.getEditors()
.find((x: any) => x['id'] === currentData.id);

let selectSql = '';
if (editor) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

import CodeEdit from '@/components/CustomEditor/CodeEdit';
import { useEditor } from '@/hooks/useEditor';
import { getCurrentTab } from '@/pages/DataStudio/function';
import { matchLanguage } from '@/pages/DataStudio/MiddleContainer/function';
import { TASK_VAR_FILTER } from '@/pages/DataStudio/MiddleContainer/StudioEditor/constants';
import DiffModal from '@/pages/DataStudio/MiddleContainer/StudioEditor/DiffModal';
Expand All @@ -39,7 +40,6 @@ import { Monaco } from '@monaco-editor/react';
import { Button, Spin } from 'antd';
import { editor } from 'monaco-editor';
import React, { memo, useEffect, useRef, useState } from 'react';
import {getCurrentData, getCurrentTab} from "@/pages/DataStudio/function";

export type EditorProps = {
tabsItem: DataStudioTabsItemType;
Expand Down Expand Up @@ -107,11 +107,10 @@ const StudioEditor: React.FC<EditorProps & connect> = (props) => {
editor.focus();
editorInstance.current = editor;
// @ts-ignore
editor['id']=getCurrentTab(tabs.panes,tabs.activeKey)?.params.taskId
editor['id'] = getCurrentTab(tabs.panes, tabs.activeKey)?.params.taskId;
tabsItem.monacoInstance = monaco;

editor.onDidChangeCursorPosition((e) => {

props.footContainer.codePosition = [e.position.lineNumber, e.position.column];
dispatch({
type: STUDIO_MODEL.saveFooterValue,
Expand Down
2 changes: 1 addition & 1 deletion dinky-web/src/pages/DataStudio/model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -882,7 +882,7 @@ const Model: ModelType = {
...state,
suggestions: payload
};
},
}
}
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,17 +63,17 @@ const JobOperator = (props: OperatorType) => {
} else if (key == operatorType.SAVEPOINT_CANCEL) {
getData(API_CONSTANTS.SAVEPOINT, {
taskId: jobDetail?.instance?.taskId,
savePointType: "cancel"
savePointType: 'cancel'
});
} else if (key == operatorType.SAVEPOINT_STOP) {
getData(API_CONSTANTS.SAVEPOINT, {
taskId: jobDetail?.instance?.taskId,
savePointType: "stop"
savePointType: 'stop'
});
} else if (key == operatorType.SAVEPOINT_TRIGGER) {
getData(API_CONSTANTS.SAVEPOINT, {
taskId: jobDetail?.instance?.taskId,
savePointType: "trigger"
savePointType: 'trigger'
});
} else {
cancelTask('', jobDetail?.instance?.taskId);
Expand Down

0 comments on commit d7a2038

Please sign in to comment.