mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 18:46:40 -05:00
use STS to process the requests (#17358)
This commit is contained in:
@@ -11,7 +11,7 @@ import * as path from 'path';
|
||||
import { getCommonLaunchArgsAndCleanupOldLogFiles, getOrDownloadServer } from './utils';
|
||||
import { Telemetry, LanguageClientErrorHandler } from './telemetry';
|
||||
import { SqlOpsDataClient, ClientOptions } from 'dataprotocol-client';
|
||||
import { TelemetryFeature, AgentServicesFeature, SerializationFeature, AccountFeature, SqlAssessmentServicesFeature, ProfilerFeature } from './features';
|
||||
import { TelemetryFeature, AgentServicesFeature, SerializationFeature, AccountFeature, SqlAssessmentServicesFeature, ProfilerFeature, TableDesignerFeature } from './features';
|
||||
import { CredentialStore } from './credentialstore/credentialstore';
|
||||
import { AzureResourceProvider } from './resourceProvider/resourceProvider';
|
||||
import { SchemaCompareService } from './schemaCompare/schemaCompareService';
|
||||
@@ -163,6 +163,7 @@ function getClientOptions(context: AppContext): ClientOptions {
|
||||
NotebookConvertService.asFeature(context),
|
||||
ProfilerFeature,
|
||||
SqlMigrationService.asFeature(context),
|
||||
TableDesignerFeature
|
||||
],
|
||||
outputChannel: new CustomOutputChannel()
|
||||
};
|
||||
|
||||
@@ -10,10 +10,12 @@ import { sqlProviderName } from '../constants';
|
||||
|
||||
export function registerTableDesignerCommands(appContext: AppContext) {
|
||||
appContext.extensionContext.subscriptions.push(vscode.commands.registerCommand('mssql.newTable', async (context: azdata.ObjectExplorerContext) => {
|
||||
const connectionUri = await azdata.connection.getUriForConnection(context.connectionProfile.id);
|
||||
await azdata.designers.openTableDesigner(sqlProviderName, {
|
||||
server: context.connectionProfile.serverName,
|
||||
database: context.connectionProfile.databaseName,
|
||||
isNewTable: true
|
||||
isNewTable: true,
|
||||
connectionUri: connectionUri
|
||||
});
|
||||
}));
|
||||
|
||||
@@ -22,13 +24,15 @@ export function registerTableDesignerCommands(appContext: AppContext) {
|
||||
const database = context.connectionProfile.databaseName;
|
||||
const schema = context.nodeInfo.metadata.schema;
|
||||
const name = context.nodeInfo.metadata.name;
|
||||
const connectionUri = await azdata.connection.getUriForConnection(context.connectionProfile.id);
|
||||
await azdata.designers.openTableDesigner(sqlProviderName, {
|
||||
server: server,
|
||||
database: database,
|
||||
isNewTable: false,
|
||||
name: name,
|
||||
schema: schema,
|
||||
id: `${server}|${database}|${schema}|${name}`
|
||||
id: `${server}|${database}|${schema}|${name}`,
|
||||
connectionUri: connectionUri
|
||||
});
|
||||
}));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user