ui: dc/NodeView: eslint fixes and code cleanup/refactoring

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
Thomas Lamprecht 2021-05-18 12:19:24 +02:00
parent 8295f55e56
commit ffc947807c

View File

@ -79,17 +79,15 @@ Ext.define('PVE.dc.NodeView', {
{
type: 'up',
handler: function() {
var me = this.up('grid');
var height = Math.max(me.getHeight()-50, 250);
me.setHeight(height);
let view = this.up('grid');
view.setHeight(Math.max(view.getHeight() - 50, 250));
},
},
{
type: 'down',
handler: function() {
var me = this.up('grid');
var height = me.getHeight()+50;
me.setHeight(height);
let view = this.up('grid');
view.setHeight(view.getHeight() + 50);
},
},
],
@ -111,7 +109,8 @@ Ext.define('PVE.widget.ProgressBar', {
],
setValue: function(value) {
var me = this;
let me = this;
me.callParent([value]);
me.removeCls(['warning', 'critical']);