ISSUE10685 - Edits schemaCompareDialog to show connectionName if provided (#15152)

* ISSUE10685 - Edits schemaCompareDialog to show connectionName if provided

* ISSUE10685 - Edits to not show user if connectionName

* ISSUE10685 - Shows connection name is schema compare launched from db

* ISSUE10685 - Shows connection name in schema compare window

* ISSUE10685 - Edits utils tests

* ISSUE10685 - Edits schemaCompare test

* ISSUE10685 - Adds/Edits specs

* ISSUE10685 - Changes let to const
This commit is contained in:
Vaggelis Sotiropoulos
2021-04-26 11:11:43 -07:00
committed by GitHub
parent 463ea0b46b
commit 3e4f687862
5 changed files with 44 additions and 28 deletions

View File

@@ -549,13 +549,19 @@ export class SchemaCompareDialog {
count++;
let usr = c.options.user;
let srv = c.options.server;
if (!usr) {
usr = loc.defaultText;
}
let srv = c.options.server;
let finalName = `${srv} (${usr})`;
if (c.options.connectionName) {
finalName = c.options.connectionName;
}
// use previously selected server or current connection if there is one
if (endpointInfo && !isNullOrUndefined(endpointInfo.serverName) && !isNullOrUndefined(endpointInfo.serverDisplayName)
&& c.options.server.toLowerCase() === endpointInfo.serverName.toLowerCase()