From a967e90d4cd745fe704bd8227c649d9235bcb1a3 Mon Sep 17 00:00:00 2001 From: Cheena Malhotra <13396919+cheenamalhotra@users.noreply.github.com> Date: Tue, 1 Nov 2022 10:57:11 -0700 Subject: [PATCH] Add dashboard navigation to database when connected to a database (#21056) --- .../workbench/contrib/dashboard/browser/dashboard.component.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/sql/workbench/contrib/dashboard/browser/dashboard.component.ts b/src/sql/workbench/contrib/dashboard/browser/dashboard.component.ts index becd0b7f52..41f9fe63c3 100644 --- a/src/sql/workbench/contrib/dashboard/browser/dashboard.component.ts +++ b/src/sql/workbench/contrib/dashboard/browser/dashboard.component.ts @@ -45,6 +45,9 @@ export class DashboardComponent extends AngularDisposable implements OnInit { // Route to the server page as this is the default database this._router.navigate(['server-dashboard'], { relativeTo: this._activeRoute, skipLocationChange: true }).catch(onUnexpectedError); } + else { + this._router.navigate(['database-dashboard'], { relativeTo: this._activeRoute, skipLocationChange: true }).catch(onUnexpectedError); + } } private updateTheme(theme: IColorTheme): void {