reload the pool grid correctly

whenever a window is closed (creation, deletion) we want to reload the
pool grid, for not having to wait on the next refresh

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
Dominik Csapak 2017-07-31 15:15:29 +02:00 committed by Fabian Grünbichler
parent c9508b5d4c
commit 0e9a34c660

View File

@ -165,6 +165,9 @@ Ext.define('PVE.node.CephPoolList', {
nodename: nodename nodename: nodename
}); });
win.show(); win.show();
win.on('destroy', function() {
rstore.load();
});
} }
}); });
@ -181,10 +184,13 @@ Ext.define('PVE.node.CephPoolList', {
var base_url = '/nodes/' + nodename + '/ceph/pools/' + var base_url = '/nodes/' + nodename + '/ceph/pools/' +
rec.data.pool_name; rec.data.pool_name;
Ext.create('PVE.window.SafeDestroy', { var win = Ext.create('PVE.window.SafeDestroy', {
url: base_url, url: base_url,
item: { type: 'CephPool', id: rec.data.pool_name } item: { type: 'CephPool', id: rec.data.pool_name }
}).show(); }).show();
win.on('destroy', function() {
rstore.load();
});
} }
}); });