From: Patrick Seidensal Date: Fri, 11 Sep 2020 09:47:34 +0000 (+0200) Subject: mgr/dashboard: Enable per RBD graphs in details of RBD X-Git-Tag: v15.2.9~129^2~4^2~2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=dc5a87d3c1e490f5e42a6aa85c5d2a08d0391f87;p=ceph.git mgr/dashboard: Enable per RBD graphs in details of RBD Fixes: https://tracker.ceph.com/issues/47433 Signed-off-by: Patrick Seidensal (cherry picked from commit 3d3230b99bf075020256bdc7cf082fd54fc61992) Conflicts: src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-details/rbd-details.component.html src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-details/rbd-details.component.ts Fixed conflicts because https://github.com/ceph/ceph/pull/35290, https://github.com/ceph/ceph/pull/35311 and https://github.com/ceph/ceph/pull/35574 have not been backported to octopus. --- diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-details/rbd-details.component.html b/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-details/rbd-details.component.html index 314bde9ece56..88a52b6c7be7 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-details/rbd-details.component.html +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-details/rbd-details.component.html @@ -129,6 +129,13 @@ heading="Configuration"> + + + + Global - diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-details/rbd-details.component.ts b/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-details/rbd-details.component.ts index 0916391e0663..3e1803cd7608 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-details/rbd-details.component.ts +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/block/rbd-details/rbd-details.component.ts @@ -1,4 +1,4 @@ -import { Component, Input, TemplateRef, ViewChild } from '@angular/core'; +import { Component, Input, OnChanges, TemplateRef, ViewChild } from '@angular/core'; import { RbdFormModel } from '../rbd-form/rbd-form.model'; @@ -7,7 +7,7 @@ import { RbdFormModel } from '../rbd-form/rbd-form.model'; templateUrl: './rbd-details.component.html', styleUrls: ['./rbd-details.component.scss'] }) -export class RbdDetailsComponent { +export class RbdDetailsComponent implements OnChanges { @Input() selection: RbdFormModel; @Input() @@ -16,4 +16,12 @@ export class RbdDetailsComponent { poolConfigurationSourceTpl: TemplateRef; constructor() {} + + rbdDashboardUrl: string; + + ngOnChanges() { + if (this.selection) { + this.rbdDashboardUrl = `rbd-details?var-Pool=${this.selection['pool_name']}&var-Image=${this.selection['name']}`; + } + } }