[pve-devel] [PATCH 3/3] don't display default value for pending options

Alexandre Derumier aderumier at odiso.com
Tue Dec 16 15:10:19 CET 2014


also remove "pending:" text

Signed-off-by: Alexandre Derumier <aderumier at odiso.com>
---
 www/manager/grid/ObjectGrid2.js |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/www/manager/grid/ObjectGrid2.js b/www/manager/grid/ObjectGrid2.js
index a2c38dc..5ea8b68 100644
--- a/www/manager/grid/ObjectGrid2.js
+++ b/www/manager/grid/ObjectGrid2.js
@@ -30,7 +30,9 @@ Ext.define('PVE.grid.ObjectGrid2', {
 
 	if (renderer) {
 	    current = renderer(value, metaData, record, rowIndex, colIndex, store);
-	    pending = renderer(record.data['pending'], metaData, record, rowIndex, colIndex, store);
+	    if(record.data['pending']){
+		pending = renderer(record.data['pending'], metaData, record, rowIndex, colIndex, store);
+	    }
 	}else{
 	    current = value;
 	    pending = record.data['pending'];
@@ -41,7 +43,7 @@ Ext.define('PVE.grid.ObjectGrid2', {
 
 	value = current;
 	if(pending || pendingdelete){
-	    value += '<div style="color:red"> pending:' + pending + pendingdelete + '</div>';
+	    value += '<div style="color:red">' + pending + pendingdelete + '</div>';
 	}
 	return value;
     },
-- 
1.7.10.4




More information about the pve-devel mailing list