mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-19 17:46:00 +00:00
Execute Current, Execute Current Line Not Current Query #1209
This commit is contained in:
@@ -130,6 +130,7 @@
|
||||
currentEditorTheme,
|
||||
currentThemeDefinition,
|
||||
currentEditorKeybindigMode,
|
||||
getCurrentSettings
|
||||
} from '../stores';
|
||||
import _ from 'lodash';
|
||||
import { handleCommandKeyDown } from '../commands/CommandListener.svelte';
|
||||
@@ -212,11 +213,18 @@
|
||||
line: editor.getSelectionRange().start.row,
|
||||
};
|
||||
}
|
||||
const line = editor.getSelectionRange().start.row;
|
||||
if (!getCurrentSettings()['sqlEditor.disableExecuteCurrentLine']){
|
||||
const line = editor.getSelectionRange().start.row;
|
||||
return {
|
||||
text: editor.session.getLine(line),
|
||||
line,
|
||||
};
|
||||
}
|
||||
|
||||
return {
|
||||
text: editor.session.getLine(line),
|
||||
line,
|
||||
text: editor.getValue(),
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
export function getCodeCompletionCommandText() {
|
||||
|
||||
@@ -258,6 +258,12 @@ ORDER BY
|
||||
label="Disable split by empty line"
|
||||
defaultValue={false}
|
||||
/>
|
||||
|
||||
<FormCheckboxField
|
||||
name="sqlEditor.disableExecuteCurrentLine"
|
||||
label="Disable current line execution (Execute current)"
|
||||
defaultValue={false}
|
||||
/>
|
||||
</svelte:fragment>
|
||||
<svelte:fragment slot="2">
|
||||
<div class="heading">Connection</div>
|
||||
|
||||
Reference in New Issue
Block a user