mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 18:46:40 -05:00
Fix Schema compare recompare after options reset not using correct options (#6539)
* Fix incorrect options being used after reset * bump version
This commit is contained in:
@@ -2,7 +2,7 @@
|
|||||||
"name": "schema-compare",
|
"name": "schema-compare",
|
||||||
"displayName": "%displayName%",
|
"displayName": "%displayName%",
|
||||||
"description": "%description%",
|
"description": "%description%",
|
||||||
"version": "0.4.0",
|
"version": "0.5.0",
|
||||||
"publisher": "Microsoft",
|
"publisher": "Microsoft",
|
||||||
"preview": true,
|
"preview": true,
|
||||||
"engines": {
|
"engines": {
|
||||||
@@ -75,4 +75,4 @@
|
|||||||
"publisherDisplayName": "Microsoft",
|
"publisherDisplayName": "Microsoft",
|
||||||
"publisherId": "Microsoft"
|
"publisherId": "Microsoft"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -448,6 +448,7 @@ export class SchemaCompareOptionsDialog {
|
|||||||
if (this.optionsChanged) {
|
if (this.optionsChanged) {
|
||||||
vscode.window.showWarningMessage(SchemaCompareOptionsDialog.OptionsChangedMessage, SchemaCompareOptionsDialog.YesButtonText, SchemaCompareOptionsDialog.NoButtonText).then((result) => {
|
vscode.window.showWarningMessage(SchemaCompareOptionsDialog.OptionsChangedMessage, SchemaCompareOptionsDialog.YesButtonText, SchemaCompareOptionsDialog.NoButtonText).then((result) => {
|
||||||
if (result === SchemaCompareOptionsDialog.YesButtonText) {
|
if (result === SchemaCompareOptionsDialog.YesButtonText) {
|
||||||
|
this.schemaComparison.setDeploymentOptions(this.deploymentOptions);
|
||||||
this.schemaComparison.startCompare();
|
this.schemaComparison.startCompare();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@@ -1807,4 +1808,4 @@ export class SchemaCompareOptionsDialog {
|
|||||||
return SchemaCompareOptionsDialog.descriptionIgnoreColumnOrder;
|
return SchemaCompareOptionsDialog.descriptionIgnoreColumnOrder;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -266,6 +266,10 @@ export class SchemaCompareMainWindow {
|
|||||||
return this.deploymentOptions;
|
return this.deploymentOptions;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public setDeploymentOptions(deploymentOptions: azdata.DeploymentOptions): void {
|
||||||
|
this.deploymentOptions = deploymentOptions;
|
||||||
|
}
|
||||||
|
|
||||||
public async execute(): Promise<void> {
|
public async execute(): Promise<void> {
|
||||||
Telemetry.sendTelemetryEvent('SchemaComparisonStarted');
|
Telemetry.sendTelemetryEvent('SchemaComparisonStarted');
|
||||||
const service = await SchemaCompareMainWindow.getService(msSqlProvider);
|
const service = await SchemaCompareMainWindow.getService(msSqlProvider);
|
||||||
@@ -649,7 +653,6 @@ export class SchemaCompareMainWindow {
|
|||||||
// create fresh every time
|
// create fresh every time
|
||||||
this.schemaCompareOptionDialog = new SchemaCompareOptionsDialog(this.deploymentOptions, this);
|
this.schemaCompareOptionDialog = new SchemaCompareOptionsDialog(this.deploymentOptions, this);
|
||||||
await this.schemaCompareOptionDialog.openDialog();
|
await this.schemaCompareOptionDialog.openDialog();
|
||||||
this.deploymentOptions = this.schemaCompareOptionDialog.deploymentOptions;
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -915,7 +918,7 @@ export class SchemaCompareMainWindow {
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.updateSourceAndTarget();
|
this.updateSourceAndTarget();
|
||||||
this.deploymentOptions = result.deploymentOptions;
|
this.setDeploymentOptions(result.deploymentOptions);
|
||||||
this.scmpSourceExcludes = result.excludedSourceElements;
|
this.scmpSourceExcludes = result.excludedSourceElements;
|
||||||
this.scmpTargetExcludes = result.excludedTargetElements;
|
this.scmpTargetExcludes = result.excludedTargetElements;
|
||||||
this.sourceTargetSwitched = result.originalTargetName !== this.targetEndpointInfo.databaseName;
|
this.sourceTargetSwitched = result.originalTargetName !== this.targetEndpointInfo.databaseName;
|
||||||
@@ -1014,7 +1017,7 @@ export class SchemaCompareMainWindow {
|
|||||||
// Same as dacfx default options
|
// Same as dacfx default options
|
||||||
const service = await SchemaCompareMainWindow.getService(msSqlProvider);
|
const service = await SchemaCompareMainWindow.getService(msSqlProvider);
|
||||||
let result = await service.schemaCompareGetDefaultOptions();
|
let result = await service.schemaCompareGetDefaultOptions();
|
||||||
this.deploymentOptions = result.defaultDeploymentOptions;
|
this.setDeploymentOptions(result.defaultDeploymentOptions);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1042,4 +1045,4 @@ export function generateGuid(): string {
|
|||||||
let clockSequenceHi: string = hexValues[8 + (Math.random() * 4) | 0];
|
let clockSequenceHi: string = hexValues[8 + (Math.random() * 4) | 0];
|
||||||
return oct.substr(0, 8) + '-' + oct.substr(9, 4) + '-4' + oct.substr(13, 3) + '-' + clockSequenceHi + oct.substr(16, 3) + '-' + oct.substr(19, 12);
|
return oct.substr(0, 8) + '-' + oct.substr(9, 4) + '-4' + oct.substr(13, 3) + '-' + clockSequenceHi + oct.substr(16, 3) + '-' + oct.substr(19, 12);
|
||||||
/* tslint:enable:no-bitwise */
|
/* tslint:enable:no-bitwise */
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user