Sort order of Custom Portal Tasks?
// show task 1
As these add up, the order in which it displays is inconsistent - Is there a way in the custom.js to specify which order these should appear in?
I think I saw somewhere else where the default options are coming from the controller.js - which is okay. I'm just looking for sorting the additional tasks I am adding.
thanks in advance!
Best Answers
-
Ryan_Lane Cireson Support Advanced IT Monkey ✭✭✭Hello!
I have this function you can use in custom.js to sort custom tasks alphabetically using the jquery sort function:function sortTaskList() { var taskList = $('.taskmenu'), listitems = taskList.children('li').get(); listitems.sort(function (a, b) { return $(a).text().toUpperCase().localeCompare($(b).text().toUpperCase()); }); $.each(listitems, function (idx, itm) { taskList.append(itm); }); }
3
Answers
I have this function you can use in custom.js to sort custom tasks alphabetically using the jquery sort function: