gui: ceph: prepare statusdetail for metadata

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
Dominik Csapak 2019-05-27 14:14:00 +02:00 committed by Thomas Lamprecht
parent 11b3410fa6
commit e8324041e4
2 changed files with 8 additions and 7 deletions

View File

@ -222,6 +222,7 @@ Ext.define('PVE.node.CephStatus', {
var me = this;
var rec = records[0];
me.status = rec.data;
// add health panel
me.down('#overallhealth').updateHealth(PVE.Utils.render_ceph_health(rec.data.health || {}));
@ -229,12 +230,7 @@ Ext.define('PVE.node.CephStatus', {
me.down('#warnings').getStore().loadRawData(me.generateCheckData(rec.data.health || {}), false);
// update detailstatus panel
me.getComponent('statusdetail').updateAll(
rec.data.health || {},
rec.data.monmap || {},
rec.data.pgmap || {},
rec.data.osdmap || {},
rec.data.quorum_names || []);
me.getComponent('statusdetail').updateAll(me.metadata || {}, rec.data);
// add performance data
var used = rec.data.pgmap.bytes_used;

View File

@ -74,10 +74,15 @@ Ext.define('PVE.ceph.StatusDetail', {
]
}],
updateAll: function(health, monmap, pgmap, osdmap, quorum_names) {
updateAll: function(metadata, status) {
var me = this;
me.suspendLayout = true;
var pgmap = status.pgmap || {};
var health = status.health || {};
var osdmap = status.osdmap || { osdmap: {} };
// update pgs sorted
var pgs_by_state = pgmap.pgs_by_state || [];
pgs_by_state.sort(function(a,b){