[pve-devel] [PATCH manager 09/15] gui: ceph: prepare statusdetail for metadata

Dominik Csapak d.csapak at proxmox.com
Mon May 27 14:14:00 CEST 2019


Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
---
 www/manager6/ceph/Status.js       | 8 ++------
 www/manager6/ceph/StatusDetail.js | 7 ++++++-
 2 files changed, 8 insertions(+), 7 deletions(-)

diff --git a/www/manager6/ceph/Status.js b/www/manager6/ceph/Status.js
index ffb407d7..78b6c925 100644
--- a/www/manager6/ceph/Status.js
+++ b/www/manager6/ceph/Status.js
@@ -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;
diff --git a/www/manager6/ceph/StatusDetail.js b/www/manager6/ceph/StatusDetail.js
index 97fa426e..e354b1be 100644
--- a/www/manager6/ceph/StatusDetail.js
+++ b/www/manager6/ceph/StatusDetail.js
@@ -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){
-- 
2.11.0





More information about the pve-devel mailing list