Add support for target location in tasks (#10179)

* Add support for target location in tasks

* bump sqltoolsservice to get addition of targetLocation to TaskNode
This commit is contained in:
Kim Santiago
2020-04-28 15:35:40 -07:00
committed by GitHub
parent 4ec281313f
commit 11f6790630
5 changed files with 23 additions and 6 deletions

View File

@@ -103,11 +103,18 @@ export class TaskHistoryRenderer implements IRenderer {
templateData.label.textContent = element.taskName + ' ' + taskStatus;
templateData.label.title = templateData.label.textContent;
let description: string;
// Determine the target name and set hover text equal to that
let description = element.serverName;
if (element.databaseName) {
description += ' | ' + element.databaseName;
// show target location if there is one, otherwise show server and database name
if (element.targetLocation) {
description = element.targetLocation;
} else {
description = element.serverName;
if (element.databaseName) {
description += ' | ' + element.databaseName;
}
}
templateData.description.textContent = description;
templateData.description.title = templateData.description.textContent;