Guest User

Untitled

a guest
Jun 21st, 2018
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.54 KB | None | 0 0
  1. jQuery.fn.sort = function() { return this.pushStack( [].sort.apply( this, arguments ), []); };
  2. $('.djDebugSql').closest('tr').each(function(i) { this.setAttribute('rel',i); });
  3. function dtsql(o){
  4. switch (o) {
  5. case 'clean' : $('.djDebugSql').each(function(){ $(this).contents()[1].nodeValue = ' '; }); break;
  6. case 'time' : tbody = $('.djDebugSql:eq(0)').closest('tbody'); tbody.children('tr').sort(function(a,b){ return $(b).children('td:eq(0)').html() - $(a).children('td:eq(0)').html() }).appendTo(tbody);
  7. break;
  8. }
  9. }
  10. dtsql('time');
Add Comment
Please, Sign In to add comment