[pve-devel] [PATCH manager] remove unnecessary sort function in HardwareView.js
David Limbeck
d.limbeck at proxmox.com
Tue Nov 6 12:14:44 CET 2018
we're adding everything in the right order already so there's no need to
sort them based on groups
Signed-off-by: David Limbeck <d.limbeck at proxmox.com>
---
this is in preparation for increased unused disks as unused disk 10-19
would appear before disk 2
www/manager6/qemu/HardwareView.js | 11 -----------
1 file changed, 11 deletions(-)
diff --git a/www/manager6/qemu/HardwareView.js b/www/manager6/qemu/HardwareView.js
index f2a3e244..2a86e461 100644
--- a/www/manager6/qemu/HardwareView.js
+++ b/www/manager6/qemu/HardwareView.js
@@ -233,16 +233,6 @@ Ext.define('PVE.qemu.HardwareView', {
};
}
- var sorterFn = function(rec1, rec2) {
- var v1 = rec1.data.key;
- var v2 = rec2.data.key;
- var g1 = rows[v1].group || 0;
- var g2 = rows[v2].group || 0;
-
- return (g1 !== g2) ?
- (g1 > g2 ? 1 : -1) : (v1 > v2 ? 1 : (v1 < v2 ? -1 : 0));
- };
-
var reload = function() {
me.rstore.load();
};
@@ -627,7 +617,6 @@ Ext.define('PVE.qemu.HardwareView', {
revert_btn
],
rows: rows,
- sorterFn: sorterFn,
listeners: {
itemdblclick: run_editor,
selectionchange: set_button_status
--
2.11.0
More information about the pve-devel
mailing list