From: Aashish Sharma Date: Wed, 17 May 2023 12:07:41 +0000 (+0530) Subject: mgr/dashboard: Status column in Cluster > Hosts shows empty X-Git-Tag: v17.2.7~346^2~18 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=3374291b0e5a7b3e94d57f007640f1540236814c;p=ceph.git mgr/dashboard: Status column in Cluster > Hosts shows empty Fixes: https://tracker.ceph.com/issues/61215 Signed-off-by: Aashish Sharma (cherry picked from commit 930e48008403ce246105a0cc631efba2974494f4) --- diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/hosts/hosts.component.ts b/src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/hosts/hosts.component.ts index 6089965fc7487..b7cad7e3c3378 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/hosts/hosts.component.ts +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/hosts/hosts.component.ts @@ -217,7 +217,8 @@ export class HostsComponent extends ListWithDetails implements OnDestroy, OnInit cellTransformation: CellTemplate.badge, customTemplateConfig: { map: { - maintenance: { class: 'badge-warning' } + maintenance: { class: 'badge-warning' }, + available: { class: 'badge-success' } } } }, @@ -495,6 +496,11 @@ export class HostsComponent extends ListWithDetails implements OnDestroy, OnInit .subscribe( (hostList) => { this.hosts = hostList; + this.hosts.forEach((host: object) => { + if (host['status'] === '') { + host['status'] = 'available'; + } + }); this.transformHostsData(); this.isLoadingHosts = false; },