diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/monitor/monitor.component.ts b/src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/monitor/monitor.component.ts index de18f792486..d66e7ff6e7b 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/monitor/monitor.component.ts +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/monitor/monitor.component.ts @@ -50,11 +50,13 @@ export class MonitorComponent { data.in_quorum.map((row) => { row.cdOpenSessions = row.stats.num_sessions.map(i => i[1]); row.cdLink = '/perf_counters/mon/' + row.name; + row.cdParams = {fromLink: '/monitor'}; return row; }); data.out_quorum.map((row) => { row.cdLink = '/perf_counters/mon/' + row.name; + row.cdParams = {fromLink: '/monitor'}; return row; }); diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/performance-counter/performance-counter/performance-counter.component.html b/src/pybind/mgr/dashboard/frontend/src/app/ceph/performance-counter/performance-counter/performance-counter.component.html index ebb9ba93d62..615228b7e68 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/performance-counter/performance-counter/performance-counter.component.html +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/performance-counter/performance-counter/performance-counter.component.html @@ -1,6 +1,19 @@ + +
- Performance Counters -

{{ serviceType }}.{{ serviceId }}

+ {{ serviceType }}.{{ serviceId }} diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/performance-counter/performance-counter/performance-counter.component.ts b/src/pybind/mgr/dashboard/frontend/src/app/ceph/performance-counter/performance-counter/performance-counter.component.ts index 06f5a9270ac..40287758b71 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/performance-counter/performance-counter/performance-counter.component.ts +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/performance-counter/performance-counter/performance-counter.component.ts @@ -7,10 +7,19 @@ import { ActivatedRoute } from '@angular/router'; styleUrls: ['./performance-counter.component.scss'] }) export class PerformanceCounterComponent { + + static defaultFromLink = '/hosts'; + serviceId: string; serviceType: string; + fromLink: string; constructor(private route: ActivatedRoute) { + this.route.queryParams.subscribe( + (params: { fromLink: string }) => { + this.fromLink = params.fromLink || PerformanceCounterComponent.defaultFromLink; + } + ); this.route.params.subscribe( (params: { type: string; id: string }) => { this.serviceId = params.id; diff --git a/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable/table/table.component.html b/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable/table/table.component.html index d9ecb65439a..0f7f8ab1743 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable/table/table.component.html +++ b/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable/table/table.component.html @@ -111,7 +111,8 @@ - {{ value }} + {{ value }}