mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-01 01:25:38 -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",
|
||||
"displayName": "%displayName%",
|
||||
"description": "%description%",
|
||||
"version": "0.4.0",
|
||||
"version": "0.5.0",
|
||||
"publisher": "Microsoft",
|
||||
"preview": true,
|
||||
"engines": {
|
||||
@@ -75,4 +75,4 @@
|
||||
"publisherDisplayName": "Microsoft",
|
||||
"publisherId": "Microsoft"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -448,6 +448,7 @@ export class SchemaCompareOptionsDialog {
|
||||
if (this.optionsChanged) {
|
||||
vscode.window.showWarningMessage(SchemaCompareOptionsDialog.OptionsChangedMessage, SchemaCompareOptionsDialog.YesButtonText, SchemaCompareOptionsDialog.NoButtonText).then((result) => {
|
||||
if (result === SchemaCompareOptionsDialog.YesButtonText) {
|
||||
this.schemaComparison.setDeploymentOptions(this.deploymentOptions);
|
||||
this.schemaComparison.startCompare();
|
||||
}
|
||||
});
|
||||
@@ -1807,4 +1808,4 @@ export class SchemaCompareOptionsDialog {
|
||||
return SchemaCompareOptionsDialog.descriptionIgnoreColumnOrder;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -266,6 +266,10 @@ export class SchemaCompareMainWindow {
|
||||
return this.deploymentOptions;
|
||||
}
|
||||
|
||||
public setDeploymentOptions(deploymentOptions: azdata.DeploymentOptions): void {
|
||||
this.deploymentOptions = deploymentOptions;
|
||||
}
|
||||
|
||||
public async execute(): Promise<void> {
|
||||
Telemetry.sendTelemetryEvent('SchemaComparisonStarted');
|
||||
const service = await SchemaCompareMainWindow.getService(msSqlProvider);
|
||||
@@ -649,7 +653,6 @@ export class SchemaCompareMainWindow {
|
||||
// create fresh every time
|
||||
this.schemaCompareOptionDialog = new SchemaCompareOptionsDialog(this.deploymentOptions, this);
|
||||
await this.schemaCompareOptionDialog.openDialog();
|
||||
this.deploymentOptions = this.schemaCompareOptionDialog.deploymentOptions;
|
||||
});
|
||||
}
|
||||
|
||||
@@ -915,7 +918,7 @@ export class SchemaCompareMainWindow {
|
||||
}
|
||||
|
||||
this.updateSourceAndTarget();
|
||||
this.deploymentOptions = result.deploymentOptions;
|
||||
this.setDeploymentOptions(result.deploymentOptions);
|
||||
this.scmpSourceExcludes = result.excludedSourceElements;
|
||||
this.scmpTargetExcludes = result.excludedTargetElements;
|
||||
this.sourceTargetSwitched = result.originalTargetName !== this.targetEndpointInfo.databaseName;
|
||||
@@ -1014,7 +1017,7 @@ export class SchemaCompareMainWindow {
|
||||
// Same as dacfx default options
|
||||
const service = await SchemaCompareMainWindow.getService(msSqlProvider);
|
||||
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];
|
||||
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 */
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user