forked from TFMM/silent-auction
fix: disable internal TomSelect sorting to respect server-side order
This commit is contained in:
@@ -18,13 +18,7 @@
|
|||||||
copyClassesToDropdown: false,
|
copyClassesToDropdown: false,
|
||||||
dropdownParent: 'body',
|
dropdownParent: 'body',
|
||||||
controlInput: '<input>',
|
controlInput: '<input>',
|
||||||
sortField: {
|
sortField: false // Disable TomSelect's internal sorting
|
||||||
field: 'text',
|
|
||||||
direction: 'asc',
|
|
||||||
func: function(a, b) {
|
|
||||||
return a.text.localeCompare(b.text, undefined, {numeric: true, sensitivity: 'base'});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user