Fix handling of connections in editors (#9682)

* fix handling of connections in editors

* initial tests

* remove test
This commit is contained in:
Anthony Dresser
2020-03-21 14:13:32 -07:00
committed by GitHub
parent a649461409
commit a7dbb68f7d
9 changed files with 52 additions and 41 deletions

View File

@@ -120,7 +120,7 @@ export function openNewQuery(accessor: ServicesAccessor, profile?: IConnectionPr
if (!profile) {
profile = getCurrentGlobalConnection(objectExplorerService, connectionManagementService, editorService);
}
return queryEditorService.newSqlEditor(initalContent).then((owner: IConnectableInput) => {
return queryEditorService.newSqlEditor({ initalContent }).then((owner: IConnectableInput) => {
// Connect our editor to the input connection
let options: IConnectionCompletionOptions = {
params: { connectionType: ConnectionType.editor, runQueryOnCompletion: onConnection, input: owner },