[pve-devel] [PATCH manager v2 2/3] ui: ObjectPendingGrid: slightly refactor renderValue

Thomas Lamprecht t.lamprecht at proxmox.com
Thu Aug 31 14:26:00 CEST 2017


---

new in v2

 www/manager6/grid/PendingObjectGrid.js | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/www/manager6/grid/PendingObjectGrid.js b/www/manager6/grid/PendingObjectGrid.js
index d5702f2e..43889456 100644
--- a/www/manager6/grid/PendingObjectGrid.js
+++ b/www/manager6/grid/PendingObjectGrid.js
@@ -52,7 +52,7 @@ Ext.define('PVE.grid.PendingObjectGrid', {
 		pending = renderer(record.data.pending, metaData, record, rowIndex, colIndex, store, true);
 	    }
 	    if (pending == current) {
-		pending = undefined;
+		pending = '';
 	    }
 	} else {
 	    current = value || '';
@@ -64,10 +64,9 @@ Ext.define('PVE.grid.PendingObjectGrid', {
 	}
 
 	if (pending || pendingdelete) {
-	    return current + '<div style="color:red">' + (pending || '') + pendingdelete + '</div>';
-	} else {
-	    return current;
+	    current += '<div style="color:red">' + pending + pendingdelete + '</div>';
 	}
+	return current;
     },
 
     initComponent : function() {
-- 
2.11.0




More information about the pve-devel mailing list