jquery-tablesorter 1.2.0 → 1.3.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -4,7 +4,7 @@
4
4
 
5
5
  Simple integration of jquery-tablesorter into the asset pipeline.
6
6
 
7
- Current tablesorter version: 2.5.2 (11/27/2012), [documentation]
7
+ Current tablesorter version: 2.6.2 (12/20/2012), [documentation]
8
8
 
9
9
  Any issue associate with the js/css files, please report to [Mottie's fork].
10
10
 
@@ -86,6 +86,14 @@ pager theme:
86
86
  4. Push to the branch (`git push origin my-new-feature`)
87
87
  5. Create new Pull Request
88
88
 
89
+ ### Update js and css files
90
+
91
+ 1. Update `tablesorter` submodule
92
+ 2. Run `rake jquery_tablesorter:update`
93
+ 3. Run `rake jquery_tablesorter:sanitize_image_paths`
94
+ 4. Update `README.md` and `CHANGELOG.md`
95
+
96
+
89
97
  [Mottie's fork]: https://github.com/Mottie/tablesorter
90
98
  [documentation]: http://mottie.github.com/tablesorter/docs/index.html
91
99
 
@@ -1,3 +1,3 @@
1
1
  module JqueryTablesorter
2
- VERSION = "1.2.0"
2
+ VERSION = "1.3.0"
3
3
  end
@@ -1,20 +1,23 @@
1
1
  /*!
2
2
  * tablesorter pager plugin
3
- * updated 11/27/2012
3
+ * updated 12/20/2012
4
4
  */
5
5
  /*jshint browser:true, jquery:true, unused:false */
6
6
  ;(function($) {
7
7
  "use strict";
8
- $.extend({tablesorterPager: new function() {
8
+ /*jshint supernew:true */
9
+ $.extend({ tablesorterPager: new function() {
9
10
 
10
11
  this.defaults = {
11
12
  // target the pager markup
12
13
  container: null,
13
14
 
14
- // use this format: "http://mydatabase.com?page={page}&size={size}&{sortList:col}"
15
- // where {page} is replaced by the page number and {size} is replaced by the number of records to show
16
- // {sortList:col} adds the sortList to the url into a "col" array.
15
+ // use this format: "http://mydatabase.com?page={page}&size={size}&{sortList:col}&{filterList:fcol}"
16
+ // where {page} is replaced by the page number, {size} is replaced by the number of records to show,
17
+ // {sortList:col} adds the sortList to the url into a "col" array, and {filterList:fcol} adds
18
+ // the filterList to the url into an "fcol" array.
17
19
  // So a sortList = [[2,0],[3,0]] becomes "&col[2]=0&col[3]=0" in the url
20
+ // and a filterList = [[2,Blue],[3,13]] becomes "&fcol[2]=Blue&fcol[3]=13" in the url
18
21
  ajaxUrl: null,
19
22
 
20
23
  // process ajax so that the following information is returned:
@@ -61,6 +64,7 @@
61
64
  cssGoto: '.gotoPage', // go to page selector - select dropdown that sets the current page
62
65
  cssPageDisplay: '.pagedisplay', // location of where the "output" is displayed
63
66
  cssPageSize: '.pagesize', // page size selector - select dropdown that sets the "size" option
67
+ cssErrorRow: 'tablesorter-errorRow', // error information row
64
68
 
65
69
  // class added to arrows when at the extremes (i.e. prev/first arrows are "disabled" when on the first page)
66
70
  cssDisabled: 'disabled', // Note there is no period "." in front of this class name
@@ -81,7 +85,6 @@
81
85
  r = 'removeClass',
82
86
  d = c.cssDisabled,
83
87
  dis = !!disable,
84
- // tr = Math.min( c.totalRows, c.filteredRows ),
85
88
  tp = Math.min( c.totalPages, c.filteredPages );
86
89
  if ( c.updateArrows ) {
87
90
  $(c.cssFirst + ',' + c.cssPrev, c.container)[ ( dis || c.page === 0 ) ? a : r ](d);
@@ -90,7 +93,7 @@
90
93
  },
91
94
 
92
95
  updatePageDisplay = function(table, c) {
93
- var i, p, s, t, out, f = $(table).hasClass('hasFilters');
96
+ var i, p, s, t, out, f = $(table).hasClass('hasFilters') && !c.ajaxUrl;
94
97
  c.filteredRows = (f) ? $(table).find('tbody tr:not(.filtered)').length : c.totalRows;
95
98
  c.filteredPages = (f) ? Math.ceil( c.filteredRows / c.size ) : c.totalPages;
96
99
  if ( Math.min( c.totalPages, c.filteredPages ) > 0 ) {
@@ -134,7 +137,7 @@
134
137
  h = $.data(table, 'pagerSavedHeight');
135
138
  if (h) {
136
139
  d = h - $b.height();
137
- if ( d > 5 && $.data(table, 'pagerLastSize') === c.size && $b.find('tr:visible').length < c.size ) {
140
+ if ( d > 5 && $.data(table, 'pagerLastSize') === c.size && $b.children('tr:visible').length < c.size ) {
138
141
  $b.append('<tr class="pagerSavedHeightSpacer remove-me" style="height:' + d + 'px;"></tr>');
139
142
  }
140
143
  }
@@ -152,7 +155,7 @@
152
155
  hideRows = function(table, c){
153
156
  if (!c.ajaxUrl) {
154
157
  var i,
155
- rows = $('tr:not(.' + table.config.cssChildRow + ')', table.tBodies),
158
+ rows = $(table.tBodies).children('tr:not(.' + table.config.cssChildRow + ')'),
156
159
  l = rows.length,
157
160
  s = ( c.page * c.size ),
158
161
  e = s + c.size,
@@ -187,7 +190,7 @@
187
190
  tc = table.config,
188
191
  $b = $(table.tBodies).filter(':not(.' + tc.cssInfoBlock + ')'),
189
192
  hl = $t.find('thead th').length, tds = '',
190
- err = '<tr class="' + tc.selectorRemove + '"><td style="text-align: center;" colspan="' + hl + '">' +
193
+ err = '<tr class="' + c.cssErrorRow + ' ' + tc.selectorRemove + '"><td style="text-align: center;" colspan="' + hl + '">' +
191
194
  (exception ? exception.message + ' (' + exception.name + ')' : 'No rows found') + '</td></tr>',
192
195
  result = c.ajaxProcessing(data) || [ 0, [] ],
193
196
  d = result[1] || [],
@@ -225,13 +228,17 @@
225
228
  $f.eq(j).html( th[j] );
226
229
  });
227
230
  }
231
+
232
+ $t.find('thead tr.' + c.cssErrorRow).remove(); // Clean up any previous error.
228
233
  if ( exception ) {
229
234
  // add error row to thead instead of tbody, or clicking on the header will result in a parser error
230
235
  $t.find('thead').append(err);
231
236
  } else {
232
237
  $b.html( tds ); // add tbody
233
238
  }
234
- $.tablesorter.isProcessing(table); // remove loading icon
239
+ if (tc.showProcessing) {
240
+ $.tablesorter.isProcessing(table); // remove loading icon
241
+ }
235
242
  $t.trigger('update');
236
243
  c.totalRows = result[0] || 0;
237
244
  c.totalPages = Math.ceil( c.totalRows / c.size );
@@ -246,28 +253,52 @@
246
253
  },
247
254
 
248
255
  getAjax = function(table, c){
256
+ var url = getAjaxUrl(table, c),
257
+ tc = table.config;
258
+ if ( url !== '' ) {
259
+ if (tc.showProcessing) {
260
+ $.tablesorter.isProcessing(table, true); // show loading icon
261
+ }
262
+ $(document).bind('ajaxError.pager', function(e, xhr, settings, exception) {
263
+ if (settings.url === url) {
264
+ renderAjax(null, table, c, exception);
265
+ $(document).unbind('ajaxError.pager');
266
+ }
267
+ });
268
+ $.getJSON(url, function(data) {
269
+ renderAjax(data, table, c);
270
+ $(document).unbind('ajaxError.pager');
271
+ });
272
+ }
273
+ },
274
+
275
+ getAjaxUrl = function(table, c) {
249
276
  var url = (c.ajaxUrl) ? c.ajaxUrl.replace(/\{page\}/g, c.page).replace(/\{size\}/g, c.size) : '',
250
- arry = [],
251
277
  sl = table.config.sortList,
252
- col = url.match(/\{sortList[\s+]?:[\s+]?(.*)\}/);
253
- if (col) {
254
- col = col[1];
278
+ fl = c.currentFilters || [],
279
+ sortCol = url.match(/\{sortList[\s+]?:[\s+]?([^}]*)\}/),
280
+ filterCol = url.match(/\{filterList[\s+]?:[\s+]?([^}]*)\}/),
281
+ arry = [];
282
+ if (sortCol) {
283
+ sortCol = sortCol[1];
255
284
  $.each(sl, function(i,v){
256
- arry.push(col + '[' + v[0] + ']=' + v[1]);
285
+ arry.push(sortCol + '[' + v[0] + ']=' + v[1]);
257
286
  });
258
287
  // if the arry is empty, just add the col parameter... "&{sortList:col}" becomes "&col"
259
- url = url.replace(/\{sortList[\s+]?:[\s+]?(.*)\}/g, arry.length ? arry.join('&') : col );
288
+ url = url.replace(/\{sortList[\s+]?:[\s+]?([^\}]*)\}/g, arry.length ? arry.join('&') : sortCol );
260
289
  }
261
- if ( url !== '' ) {
262
- // loading icon
263
- $.tablesorter.isProcessing(table, true);
264
- $(document).ajaxError(function(e, xhr, settings, exception) {
265
- renderAjax(null, table, c, exception);
266
- });
267
- $.getJSON(url, function(data) {
268
- renderAjax(data, table, c);
290
+ if (filterCol) {
291
+ filterCol = filterCol[1];
292
+ $.each(fl, function(i,v){
293
+ if (v) {
294
+ arry.push(filterCol + '[' + i + ']=' + encodeURIComponent(v));
295
+ }
269
296
  });
297
+ // if the arry is empty, just add the fcol parameter... "&{filterList:fcol}" becomes "&fcol"
298
+ url = url.replace(/\{filterList[\s+]?:[\s+]?([^\}]*)\}/g, arry.length ? arry.join('&') : filterCol );
270
299
  }
300
+
301
+ return url;
271
302
  },
272
303
 
273
304
  renderTable = function(table, rows, c) {
@@ -329,13 +360,13 @@
329
360
  if ( c.page < 0 || c.page > ( p - 1 ) ) {
330
361
  c.page = 0;
331
362
  }
332
- // change if page changed - fixes #182
333
- if (c.ajax && $.data(table, 'pagerLastPage') !== c.page) {
363
+ if (c.ajax) {
334
364
  getAjax(table, c);
335
365
  } else if (!c.ajax) {
336
366
  renderTable(table, table.config.rowsCopy, c);
337
367
  }
338
368
  $.data(table, 'pagerLastPage', c.page);
369
+ $.data(table, 'pagerUpdateTriggered', true);
339
370
  if (c.initialized) { $(table).trigger('pageMoved', c); }
340
371
  },
341
372
 
@@ -411,19 +442,101 @@
411
442
  return this.each(function() {
412
443
  // check if tablesorter has initialized
413
444
  if (!(this.config && this.hasInitialized)) { return; }
414
- var config = this.config,
445
+ var t, ctrls, fxn,
446
+ config = this.config,
415
447
  c = config.pager = $.extend( {}, $.tablesorterPager.defaults, settings ),
416
448
  table = this,
449
+ tc = table.config,
417
450
  $t = $(table),
418
451
  pager = $(c.container).addClass('tablesorter-pager').show(); // added in case the pager is reinitialized after being destroyed.
419
452
  config.appender = $this.appender;
453
+
454
+ $t
455
+ .unbind('filterStart.pager filterEnd.pager sortEnd.pager disable.pager enable.pager destroy.pager update.pager')
456
+ .bind('filterStart.pager', function(e, filters) {
457
+ c.currentFilters = filters;
458
+ })
459
+ // update pager after filter widget completes
460
+ .bind('filterEnd.pager sortEnd.pager', function() {
461
+ //Prevent infinite event loops from occuring by setting this in all moveToPage calls and catching it here.
462
+ if ($.data(table, 'pagerUpdateTriggered')) {
463
+ $.data(table, 'pagerUpdateTriggered', false);
464
+ return;
465
+ }
466
+ c.page = 0;
467
+ updatePageDisplay(table, c);
468
+ moveToPage(table, c);
469
+ changeHeight(table, c);
470
+ })
471
+ .bind('disable.pager', function(){
472
+ showAllRows(table, c);
473
+ })
474
+ .bind('enable.pager', function(){
475
+ enablePager(table, c, true);
476
+ })
477
+ .bind('destroy.pager', function(){
478
+ destroyPager(table, c);
479
+ })
480
+ .bind('update.pager', function(){
481
+ hideRows(table, c);
482
+ });
483
+
484
+ // clicked controls
485
+ ctrls = [c.cssFirst, c.cssPrev, c.cssNext, c.cssLast];
486
+ fxn = [ moveToFirstPage, moveToPrevPage, moveToNextPage, moveToLastPage ];
487
+ pager.find(ctrls.join(','))
488
+ .unbind('click.pager')
489
+ .bind('click.pager', function(e){
490
+ var i, $this = $(this), l = ctrls.length;
491
+ if ( !$this.hasClass(c.cssDisabled) ) {
492
+ for (i = 0; i < l; i++) {
493
+ if ($this.is(ctrls[i])) {
494
+ fxn[i](table, c);
495
+ break;
496
+ }
497
+ }
498
+ }
499
+ return false;
500
+ });
501
+
502
+ // goto selector
503
+ if ( pager.find(c.cssGoto).length ) {
504
+ pager.find(c.cssGoto)
505
+ .unbind('change')
506
+ .bind('change', function(){
507
+ c.page = $(this).val() - 1;
508
+ moveToPage(table, c);
509
+ });
510
+ updatePageDisplay(table, c);
511
+ }
512
+
513
+ // page size selector
514
+ t = pager.find(c.cssPageSize);
515
+ if ( t.length ) {
516
+ t.unbind('change.pager').bind('change.pager', function() {
517
+ t.val( $(this).val() ); // in case there are more than one pagers
518
+ if ( !$(this).hasClass(c.cssDisabled) ) {
519
+ setPageSize(table, parseInt( $(this).val(), 10 ), c);
520
+ changeHeight(table, c);
521
+ }
522
+ return false;
523
+ });
524
+ }
525
+
420
526
  // clear initialized flag
421
527
  c.initialized = false;
528
+ // before initialization event
529
+ $t.trigger('pagerBeforeInitialized', c);
530
+
422
531
  enablePager(table, c, false);
532
+
423
533
  if ( typeof(c.ajaxUrl) === 'string' ) {
424
534
  // ajax pager; interact with database
425
535
  c.ajax = true;
426
- getAjax(table, c);
536
+ //When filtering with ajax, allow only custom filtering function, disable default filtering since it will be done server side.
537
+ tc.widgetOptions.filter_serversideFiltering = true;
538
+ tc.serverSideSorting = true;
539
+ moveToPage(table, c);
427
540
  } else {
428
541
  c.ajax = false;
429
542
  // Regular pager; all rows stored in memory
@@ -431,65 +544,6 @@
431
544
  hideRowsSetup(table, c);
432
545
  }
433
546
 
434
- // update pager after filter widget completes
435
- $(table)
436
- .unbind('filterEnd.pager updateComplete.pager ')
437
- .bind('filterEnd.pager updateComplete.pager', function() {
438
- if ($(this).hasClass('hasFilters')) {
439
- c.page = 0;
440
- updatePageDisplay(table, c);
441
- moveToPage(table, c);
442
- changeHeight(table, c);
443
- }
444
- });
445
-
446
- if ( $(c.cssGoto, pager).length ) {
447
- $(c.cssGoto, pager).bind('change', function(){
448
- c.page = $(this).val() - 1;
449
- moveToPage(table, c);
450
- });
451
- updatePageDisplay(table, c);
452
- }
453
- $(c.cssFirst,pager).unbind('click.pager').bind('click.pager', function() {
454
- if ( !$(this).hasClass(c.cssDisabled) ) { moveToFirstPage(table, c); }
455
- return false;
456
- });
457
- $(c.cssNext,pager).unbind('click.pager').bind('click.pager', function() {
458
- if ( !$(this).hasClass(c.cssDisabled) ) { moveToNextPage(table, c); }
459
- return false;
460
- });
461
- $(c.cssPrev,pager).unbind('click.pager').bind('click.pager', function() {
462
- if ( !$(this).hasClass(c.cssDisabled) ) { moveToPrevPage(table, c); }
463
- return false;
464
- });
465
- $(c.cssLast,pager).unbind('click.pager').bind('click.pager', function() {
466
- if ( !$(this).hasClass(c.cssDisabled) ) { moveToLastPage(table, c); }
467
- return false;
468
- });
469
- $(c.cssPageSize,pager).unbind('change.pager').bind('change.pager', function() {
470
- $(c.cssPageSize,pager).val( $(this).val() ); // in case there are more than one pagers
471
- if ( !$(this).hasClass(c.cssDisabled) ) {
472
- setPageSize(table, parseInt( $(this).val(), 10 ), c);
473
- changeHeight(table, c);
474
- }
475
- return false;
476
- });
477
-
478
- $t
479
- .unbind('disable.pager enable.pager destroy.pager update.pager')
480
- .bind('disable.pager', function(){
481
- showAllRows(table, c);
482
- })
483
- .bind('enable.pager', function(){
484
- enablePager(table, c, true);
485
- })
486
- .bind('destroy.pager', function(){
487
- destroyPager(table, c);
488
- })
489
- .bind('update.pager', function(){
490
- hideRows(table, c);
491
- });
492
-
493
547
  // pager initialized
494
548
  if (!c.ajax) {
495
549
  c.initialized = true;
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * TableSorter 2.5.2 - Client-side table sorting with ease!
2
+ * TableSorter 2.6.2 - Client-side table sorting with ease!
3
3
  * @requires jQuery v1.2.6+
4
4
  *
5
5
  * Copyright (c) 2007 Christian Bach
@@ -14,16 +14,17 @@
14
14
  * @author Christian Bach/christian.bach@polyester.se
15
15
  * @contributor Rob Garrison/https://github.com/Mottie/tablesorter
16
16
  */
17
- /*jshint browser:true, jquery:true, unused:false */
17
+ /*jshint browser:true, jquery:true, unused:false, expr: true */
18
18
  /*global console:false, alert:false */
19
19
  !(function($) {
20
20
  "use strict";
21
21
  $.extend({
22
+ /*jshint supernew:true */
22
23
  tablesorter: new function() {
23
24
 
24
25
  var ts = this;
25
26
 
26
- ts.version = "2.5.2";
27
+ ts.version = "2.6.2";
27
28
 
28
29
  ts.parsers = [];
29
30
  ts.widgets = [];
@@ -38,8 +39,10 @@
38
39
  cancelSelection : true, // prevent text selection in the header
39
40
  dateFormat : 'mmddyyyy', // other options: "ddmmyyy" or "yyyymmdd"
40
41
  sortMultiSortKey : 'shiftKey', // key used to select additional columns
42
+ sortResetKey : 'ctrlKey', // key used to remove sorting on a column
41
43
  usNumberFormat : true, // false for German "1.234.567,89" or French "1 234 567,89"
42
44
  delayInit : false, // if false, the parsed table contents will not update until the first sort
45
+ serverSideSorting: false, // if true, server-side sorting should be performed because client-side sorting will be disabled, but the ui and events will still be used.
43
46
 
44
47
  // sort options
45
48
  headers : {}, // set sorter, string, empty, locked order, sortInitialOrder, filter, etc.
@@ -166,7 +169,9 @@
166
169
  var c = table.config,
167
170
  tb = $(table.tBodies).filter(':not(.' + c.cssInfoBlock + ')'),
168
171
  rows, list, l, i, h, ch, p, parsersDebug = "";
169
- if ( tb.length === 0) { return; } // In the case of empty tables
172
+ if ( tb.length === 0) {
173
+ return c.debug ? log('*Empty table!* Not building a parser cache') : '';
174
+ }
170
175
  rows = tb[0].rows;
171
176
  if (rows[0]) {
172
177
  list = [];
@@ -208,6 +213,10 @@
208
213
  parsers = tc.parsers,
209
214
  t, v, i, j, k, c, cols, cacheTime, colMax = [];
210
215
  tc.cache = {};
216
+ // if no parsers found, return - it's an empty table.
217
+ if (!parsers) {
218
+ return tc.debug ? log('*Empty table!* Not building a cache') : '';
219
+ }
211
220
  if (tc.debug) {
212
221
  cacheTime = new Date();
213
222
  }
@@ -309,7 +318,7 @@
309
318
  function computeThIndexes(t) {
310
319
  var matrix = [],
311
320
  lookup = {},
312
- trs = $(t).find('thead:eq(0) tr, tfoot tr'),
321
+ trs = $(t).find('thead:eq(0), tfoot').children('tr'), // children tr in tfoot - see issue #196
313
322
  i, j, k, l, c, cells, rowIndex, cellId, rowSpan, colSpan, firstAvailCol, matrixrow;
314
323
  for (i = 0; i < trs.length; i++) {
315
324
  cells = trs[i].cells;
@@ -454,11 +463,13 @@
454
463
  }
455
464
 
456
465
  // sort multiple columns
457
- /* */
458
466
  function multisort(table) { /*jshint loopfunc:true */
459
467
  var dynamicExp, sortWrapper, col, mx = 0, dir = 0, tc = table.config,
460
468
  sortList = tc.sortList, l = sortList.length, bl = table.tBodies.length,
461
469
  sortTime, i, j, k, c, colMax, cache, lc, s, e, order, orgOrderCol;
470
+ if (tc.serverSideSorting) {
471
+ return;
472
+ }
462
473
  if (tc.debug) { sortTime = new Date(); }
463
474
  for (k = 0; k < bl; k++) {
464
475
  colMax = tc.cache[k].colMax;
@@ -511,7 +522,9 @@
511
522
  ts.construct = function(settings) {
512
523
  return this.each(function() {
513
524
  // if no thead or tbody, or tablesorter is already present, quit
514
- if (!this.tHead || this.tBodies.length === 0 || this.hasInitialized === true) { return; }
525
+ if (!this.tHead || this.tBodies.length === 0 || this.hasInitialized === true) {
526
+ return (this.config.debug) ? log('stopping initialization! No thead, tbody or tablesorter has already been initialized') : '';
527
+ }
515
528
  // declare
516
529
  var $cell, $this = $(this),
517
530
  c, i, j, k = '', a, s, o, downTime,
@@ -568,7 +581,7 @@
568
581
  // $cell = $(this);
569
582
  k = !e[c.sortMultiSortKey];
570
583
  // get current column sort order
571
- cell.count = (cell.count + 1) % (c.sortReset ? 3 : 2);
584
+ cell.count = e[c.sortResetKey] ? 2 : (cell.count + 1) % (c.sortReset ? 3 : 2);
572
585
  // reset all sorts on non-current column - issue #30
573
586
  if (c.sortRestart) {
574
587
  i = cell;
@@ -693,6 +706,7 @@
693
706
  // no closest in jQuery v1.2.6 - tbdy = $tb.index( $(cell).closest('tbody') ),$row = $(cell).closest('tr');
694
707
  tbdy = $tb.index( $(cell).parents('tbody').filter(':last') ),
695
708
  $row = $(cell).parents('tr').filter(':last');
709
+ cell = $(cell)[0]; // in case cell is a jQuery object
696
710
  // tbody may not exist if update is initialized while tbody is removed for processing
697
711
  if ($tb.length && tbdy >= 0) {
698
712
  row = $tb.eq(tbdy).find('tr').index( $row );
@@ -960,19 +974,20 @@
960
974
 
961
975
  // used when replacing accented characters during sorting
962
976
  ts.characterEquivalents = {
963
- "a" : "\u00e1\u00e0\u00e2\u00e3\u00e4", // áàâãä
964
- "A" : "\u00c1\u00c0\u00c2\u00c3\u00c4", // ÁÀÂÃÄ
965
- "c" : "\u00e7", // ç
966
- "C" : "\u00c7", // Ç
967
- "e" : "\u00e9\u00e8\u00ea\u00eb", // éèêë
968
- "E" : "\u00c9\u00c8\u00ca\u00cb", // ÉÈÊË
969
- "i" : "\u00ed\u00ec\u0130\u00ee\u00ef", // íìİîï
977
+ "a" : "\u00e1\u00e0\u00e2\u00e3\u00e4\u0105\u00e5", // áàâãäąå
978
+ "A" : "\u00c1\u00c0\u00c2\u00c3\u00c4\u0104\u00c5", // ÁÀÂÃÄĄÅ
979
+ "c" : "\u00e7\u0107\u010d", // çćč
980
+ "C" : "\u00c7\u0106\u010c", // ÇĆČ
981
+ "e" : "\u00e9\u00e8\u00ea\u00eb\u011b\u0119", // éèêëěę
982
+ "E" : "\u00c9\u00c8\u00ca\u00cb\u011a\u0118", // ÉÈÊËĚĘ
983
+ "i" : "\u00ed\u00ec\u0130\u00ee\u00ef\u0131", // íìİîïı
970
984
  "I" : "\u00cd\u00cc\u0130\u00ce\u00cf", // ÍÌİÎÏ
971
985
  "o" : "\u00f3\u00f2\u00f4\u00f5\u00f6", // óòôõö
972
986
  "O" : "\u00d3\u00d2\u00d4\u00d5\u00d6", // ÓÒÔÕÖ
973
- "S" : "\u00df", // ß
974
- "u" : "\u00fa\u00f9\u00fb\u00fc", // úùûü
975
- "U" : "\u00da\u00d9\u00db\u00dc" // ÚÙÛÜ
987
+ "ss": "\u00df", // ß (s sharp)
988
+ "SS": "\u1e9e", // ẞ (Capital sharp s)
989
+ "u" : "\u00fa\u00f9\u00fb\u00fc\u016f", // úùûüů
990
+ "U" : "\u00da\u00d9\u00db\u00dc\u016e" // ÚÙÛÜŮ
976
991
  };
977
992
  ts.replaceAccents = function(s) {
978
993
  var a, acc = '[', eq = ts.characterEquivalents;
@@ -1080,7 +1095,7 @@
1080
1095
  // remove previous widgets
1081
1096
  for (i = 0; i < l; i++){
1082
1097
  if ( w[i] && w[i].id && (doAll || $.inArray( w[i].id, cw ) < 0) ) {
1083
- if (c.debug) { log( 'removing ' + w[i].id ); }
1098
+ if (c.debug) { log( 'Refeshing widgets: Removing ' + w[i].id ); }
1084
1099
  if (w[i].hasOwnProperty('remove')) { w[i].remove(table, c, c.widgetOptions); }
1085
1100
  }
1086
1101
  }
@@ -1114,7 +1129,11 @@
1114
1129
 
1115
1130
  ts.formatFloat = function(s, table) {
1116
1131
  if (typeof(s) !== 'string' || s === '') { return s; }
1117
- if (table.config.usNumberFormat !== false) {
1132
+ // allow using formatFloat without a table; defaults to US number format
1133
+ var i,
1134
+ t = table && table.config ? table.config.usNumberFormat !== false :
1135
+ typeof table !== "undefined" ? table : true;
1136
+ if (t) {
1118
1137
  // US Format - 1,234,567.89 -> 1234567.89
1119
1138
  s = s.replace(/,/g,'');
1120
1139
  } else {
@@ -1126,14 +1145,14 @@
1126
1145
  // make (#) into a negative number -> (10) = -10
1127
1146
  s = s.replace(/^\s*\(/,'-').replace(/\)/,'');
1128
1147
  }
1129
- var i = parseFloat(s);
1148
+ i = parseFloat(s);
1130
1149
  // return the text instead of zero
1131
1150
  return isNaN(i) ? $.trim(s) : i;
1132
1151
  };
1133
1152
 
1134
1153
  ts.isDigit = function(s) {
1135
1154
  // replace all unwanted chars and match
1136
- return isNaN(s) ? (/^[\-+(]?\d+[)]?$/).test(s.toString().replace(/[,.'\s]/g, '')) : true;
1155
+ return isNaN(s) ? (/^[\-+(]?\d+[)]?$/).test(s.toString().replace(/[,.'"\s]/g, '')) : true;
1137
1156
  };
1138
1157
 
1139
1158
  }()
@@ -1164,7 +1183,7 @@
1164
1183
  ts.addParser({
1165
1184
  id: "currency",
1166
1185
  is: function(s) {
1167
- return (/^\(?[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]\d+/).test(s); // £$€¤¥¢
1186
+ return (/^\(?\d+[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]|[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]\d+\)?$/).test(s); // £$€¤¥¢
1168
1187
  },
1169
1188
  format: function(s, table) {
1170
1189
  return ts.formatFloat(s.replace(/[^\w,. \-()]/g, ""), table);
@@ -1214,7 +1233,7 @@
1214
1233
  ts.addParser({
1215
1234
  id: "percent",
1216
1235
  is: function(s) {
1217
- return (/\d%\)?$/).test(s);
1236
+ return (/(\d\s?%|%\s?\d)/).test(s);
1218
1237
  },
1219
1238
  format: function(s, table) {
1220
1239
  return ts.formatFloat(s.replace(/%/g, ""), table);
@@ -1225,7 +1244,8 @@
1225
1244
  ts.addParser({
1226
1245
  id: "usLongDate",
1227
1246
  is: function(s) {
1228
- return (/^[A-Z]{3,10}\.?\s+\d{1,2},?\s+(\d{4}|'?\d{2})\s+(([0-2]?\d:[0-5]\d)|([0-1]?\d:[0-5]\d\s?([AP]M)))$/i).test(s);
1247
+ // two digit years are not allowed cross-browser
1248
+ return (/^[A-Z]{3,10}\.?\s+\d{1,2},?\s+(\d{4})(\s+\d{1,2}:\d{2}(:\d{2})?(\s+[AP]M)?)?$/i).test(s);
1229
1249
  },
1230
1250
  format: function(s, table) {
1231
1251
  return ts.formatFloat( (new Date(s.replace(/(\S)([AP]M)$/i, "$1 $2")).getTime() || ''), table);
@@ -1236,8 +1256,8 @@
1236
1256
  ts.addParser({
1237
1257
  id: "shortDate", // "mmddyyyy", "ddmmyyyy" or "yyyymmdd"
1238
1258
  is: function(s) {
1239
- // testing for ####-##-#### - so it's not perfect
1240
- return (/^(\d{2}|\d{4})[\/\-\,\.\s+]\d{2}[\/\-\.\,\s+](\d{2}|\d{4})$/).test(s);
1259
+ // testing for ####-##-####, so it's not perfect
1260
+ return (/^(\d{1,2}|\d{4})[\/\-\,\.\s+]\d{1,2}[\/\-\.\,\s+](\d{1,2}|\d{4})$/).test(s);
1241
1261
  },
1242
1262
  format: function(s, table, cell, cellIndex) {
1243
1263
  var c = table.config, ci = c.headerList[cellIndex],
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * TableSorter 2.5.2 min - Client-side table sorting with ease!
2
+ * TableSorter 2.6.2 min - Client-side table sorting with ease!
3
3
  * Copyright (c) 2007 Christian Bach
4
4
  */
5
- !function(f){f.extend({tablesorter:new function(){function d(c){"undefined"!==typeof console&&"undefined"!==typeof console.log?console.log(c):alert(c)}function u(c,b){d(c+" ("+((new Date).getTime()-b.getTime())+"ms)")}function n(c,b,a){if(!b)return"";var g=c.config,h=g.textExtraction,e="",e="simple"===h?g.supportsTextContent?b.textContent:f(b).text():"function"===typeof h?h(b,c,a):"object"===typeof h&&h.hasOwnProperty(a)?h[a](b,c,a):g.supportsTextContent?b.textContent:f(b).text();return f.trim(e)} function i(c){var b=c.config,a=f(c.tBodies).filter(":not(."+b.cssInfoBlock+")"),g,h,s,j,l,k,m="";if(0!==a.length){a=a[0].rows;if(a[0]){g=[];h=a[0].cells.length;for(s=0;s<h;s++){j=b.$headers.filter(":not([colspan])");j=j.add(b.$headers.filter('[colspan="1"]')).filter('[data-column="'+s+'"]:last');l=b.headers[s];k=e.getParserById(e.getData(j,l,"sorter"));b.empties[s]=e.getData(j,l,"empty")||b.emptyTo||(b.emptyToBottom?"bottom":"top");b.strings[s]=e.getData(j,l,"string")||b.stringTo||"max";if(!k)a:{j= c;l=a;k=-1;for(var u=s,q=void 0,r=e.parsers.length,x=!1,p="",q=!0;""===p&&q;)k++,l[k]?(x=l[k].cells[u],p=n(j,x,u),j.config.debug&&d("Checking if value was empty on row "+k+", column: "+u+": "+p)):q=!1;for(q=1;q<r;q++)if(e.parsers[q].is(p,j,x)){k=e.parsers[q];break a}k=e.parsers[0]}b.debug&&(m+="column:"+s+"; parser:"+k.id+"; string:"+b.strings[s]+"; empty: "+b.empties[s]+"\n");g.push(k)}}b.debug&&d(m);return g}}function p(c){var b=c.tBodies,a=c.config,g,h,d=a.parsers,j,l,k,m,i,q,p,x=[];a.cache={}; a.debug&&(p=new Date);a.showProcessing&&e.isProcessing(c,!0);for(m=0;m<b.length;m++)if(a.cache[m]={row:[],normalized:[]},!f(b[m]).hasClass(a.cssInfoBlock)){g=b[m]&&b[m].rows.length||0;h=b[m].rows[0]&&b[m].rows[0].cells.length||0;for(l=0;l<g;++l)if(i=f(b[m].rows[l]),q=[],i.hasClass(a.cssChildRow))a.cache[m].row[a.cache[m].row.length-1]=a.cache[m].row[a.cache[m].row.length-1].add(i);else{a.cache[m].row.push(i);for(k=0;k<h;++k)if(j=n(c,i[0].cells[k],k),j=d[k].format(j,c,i[0].cells[k],k),q.push(j),"numeric"=== (d[k].type||"").toLowerCase())x[k]=Math.max(Math.abs(j),x[k]||0);q.push(a.cache[m].normalized.length);a.cache[m].normalized.push(q)}a.cache[m].colMax=x}a.showProcessing&&e.isProcessing(c);a.debug&&u("Building cache for "+g+" rows",p)}function r(c,b){var a=c.config,g=c.tBodies,h=[],d=a.cache,j,l,k,m,i,q,n,p,r,t,v;a.debug&&(v=new Date);for(p=0;p<g.length;p++)if(j=f(g[p]),!j.hasClass(a.cssInfoBlock)){i=e.processTbody(c,j,!0);j=d[p].row;l=d[p].normalized;m=(k=l.length)?l[0].length-1:0;for(q=0;q<k;q++)if(t= l[q][m],h.push(j[t]),!a.appender||!a.removeRows){r=j[t].length;for(n=0;n<r;n++)i.append(j[t][n])}e.processTbody(c,i,!1)}a.appender&&a.appender(c,h);a.debug&&u("Rebuilt table",v);b||e.applyWidget(c);f(c).trigger("sortEnd",c)}function B(c){var b,a,g,h=c.config,e=h.sortList,d=[h.cssAsc,h.cssDesc],l=f(c).find("tfoot tr").children().removeClass(d.join(" "));h.$headers.removeClass(d.join(" "));g=e.length;for(b=0;b<g;b++)if(2!==e[b][1]&&(c=h.$headers.not(".sorter-false").filter('[data-column="'+e[b][0]+ '"]'+(1===g?":last":"")),c.length))for(a=0;a<c.length;a++)c[a].sortDisabled||(c.eq(a).addClass(d[e[b][1]]),l.length&&l.filter('[data-column="'+e[b][0]+'"]').eq(a).addClass(d[e[b][1]]))}function D(c){var b=0,a=c.config,g=a.sortList,h=g.length,e=c.tBodies.length,d,l,k,m,i,q,n,p,r;a.debug&&(d=new Date);for(k=0;k<e;k++)i=a.cache[k].colMax,r=(q=a.cache[k].normalized)&&q[0]?q[0].length-1:0,q.sort(function(e,d){for(l=0;l<h;l++){m=g[l][0];p=g[l][1];n=/n/i.test(a.parsers&&a.parsers[m]?a.parsers[m].type||"": "")?"Numeric":"Text";n+=0===p?"":"Desc";/Numeric/.test(n)&&a.strings[m]&&(b="boolean"===typeof a.string[a.strings[m]]?(0===p?1:-1)*(a.string[a.strings[m]]?-1:1):a.strings[m]?a.string[a.strings[m]]||0:0);var j=f.tablesorter["sort"+n](c,e[m],d[m],m,i[m],b);if(j)return j}return e[r]-d[r]});a.debug&&u("Sorting on "+g.toString()+" and dir "+p+" time",d)}function C(c,b){c.trigger("updateComplete");"function"===typeof b&&b(c[0])}function E(c,b,a){!1!==b?c.trigger("sorton",[c[0].config.sortList,function(){C(c, a)}]):C(c,a)}var e=this;e.version="2.5.2";e.parsers=[];e.widgets=[];e.defaults={theme:"default",widthFixed:!1,showProcessing:!1,cancelSelection:!0,dateFormat:"mmddyyyy",sortMultiSortKey:"shiftKey",usNumberFormat:!0,delayInit:!1,headers:{},ignoreCase:!0,sortForce:null,sortList:[],sortAppend:null,sortInitialOrder:"asc",sortLocaleCompare:!1,sortReset:!1,sortRestart:!1,emptyTo:"bottom",stringTo:"max",textExtraction:"simple",textSorter:null,widgets:[],widgetOptions:{zebra:["even","odd"]},initWidgets:!0, initialized:null,onRenderHeader:null,tableClass:"tablesorter",cssAsc:"tablesorter-headerAsc",cssChildRow:"tablesorter-childRow",cssDesc:"tablesorter-headerDesc",cssHeader:"tablesorter-header",cssHeaderRow:"tablesorter-headerRow",cssIcon:"tablesorter-icon",cssInfoBlock:"tablesorter-infoOnly",cssProcessing:"tablesorter-processing",selectorHeaders:"> thead th, > thead td",selectorSort:"th, td",selectorRemove:".remove-me",debug:!1,headerList:[],empties:{},strings:{},parsers:[]};e.benchmark=u;e.construct= function(c){return this.each(function(){if(this.tHead&&!(0===this.tBodies.length||!0===this.hasInitialized)){var b=f(this),a,g,h,s="",j,l,k,m,C=f.metadata;this.hasInitialized=!1;this.config={};a=f.extend(!0,this.config,e.defaults,c);f.data(this,"tablesorter",a);a.debug&&f.data(this,"startoveralltimer",new Date);a.supportsTextContent="x"===f("<span>x</span>")[0].textContent;a.supportsDataObject=1.4<=parseFloat(f.fn.jquery);a.string={max:1,min:-1,"max+":1,"max-":-1,zero:0,none:0,"null":0,top:!0,bottom:!1}; /tablesorter\-/.test(b.attr("class"))||(s=""!==a.theme?" tablesorter-"+a.theme:"");b.addClass(a.tableClass+s);var q=[],M={},x=f(this).find("thead:eq(0) tr, tfoot tr"),H,I,v,y,L,A,J,N,O,F;for(H=0;H<x.length;H++){L=x[H].cells;for(I=0;I<L.length;I++){y=L[I];A=y.parentNode.rowIndex;J=A+"-"+y.cellIndex;N=y.rowSpan||1;O=y.colSpan||1;"undefined"===typeof q[A]&&(q[A]=[]);for(v=0;v<q[A].length+1;v++)if("undefined"===typeof q[A][v]){F=v;break}M[J]=F;f(y).attr({"data-column":F});for(v=A;v<A+N;v++){"undefined"=== typeof q[v]&&(q[v]=[]);J=q[v];for(y=F;y<F+O;y++)J[y]="x"}}}var K,z,P,G,Q,w=this.config;w.headerList=[];w.debug&&(Q=new Date);q=f(this).find(w.selectorHeaders).each(function(a){z=f(this);K=w.headers[a];P=w.cssIcon?'<i class="'+w.cssIcon+'"></i>':"";this.innerHTML='<div class="tablesorter-header-inner">'+this.innerHTML+P+"</div>";w.onRenderHeader&&w.onRenderHeader.apply(z,[a]);this.column=M[this.parentNode.rowIndex+"-"+this.cellIndex];var b=e.getData(z,K,"sortInitialOrder")||w.sortInitialOrder;this.order= /^d/i.test(b)||1===b?[1,0,2]:[0,1,2];this.count=-1;"false"===e.getData(z,K,"sorter")?(this.sortDisabled=!0,z.addClass("sorter-false")):z.removeClass("sorter-false");this.lockedOrder=!1;G=e.getData(z,K,"lockedOrder")||!1;"undefined"!==typeof G&&!1!==G&&(this.order=this.lockedOrder=/^d/i.test(G)||1===G?[1,1,1]:[0,0,0]);z.addClass((this.sortDisabled?"sorter-false ":" ")+w.cssHeader);w.headerList[a]=this;z.parent().addClass(w.cssHeaderRow)});this.config.debug&&(u("Built headers:",Q),d(q));a.$headers= q;a.parsers=i(this);a.delayInit||p(this);a.$headers.find("*").andSelf().filter(a.selectorSort).unbind("mousedown.tablesorter mouseup.tablesorter").bind("mousedown.tablesorter mouseup.tablesorter",function(c,d){var i=(this.tagName.match("TH|TD")?f(this):f(this).parents("th, td").filter(":last"))[0];if(1!==(c.which||c.button))return!1;if("mousedown"===c.type)return m=(new Date).getTime(),"INPUT"===c.target.tagName?"":!a.cancelSelection;if(!0!==d&&250<(new Date).getTime()-m)return!1;a.delayInit&&!a.cache&& p(b[0]);if(!i.sortDisabled){b.trigger("sortStart",b[0]);s=!c[a.sortMultiSortKey];i.count=(i.count+1)%(a.sortReset?3:2);a.sortRestart&&(g=i,a.$headers.each(function(){if(this!==g&&(s||!f(this).is("."+a.cssDesc+",."+a.cssAsc)))this.count=-1}));g=i.column;if(s){a.sortList=[];if(null!==a.sortForce){j=a.sortForce;for(h=0;h<j.length;h++)j[h][0]!==g&&a.sortList.push(j[h])}k=i.order[i.count];if(2>k&&(a.sortList.push([g,k]),1<i.colSpan))for(h=1;h<i.colSpan;h++)a.sortList.push([g+h,k])}else if(a.sortAppend&& 1<a.sortList.length&&e.isValueInArray(a.sortAppend[0][0],a.sortList)&&a.sortList.pop(),e.isValueInArray(g,a.sortList))for(h=0;h<a.sortList.length;h++)l=a.sortList[h],k=a.headerList[l[0]],l[0]===g&&(l[1]=k.order[k.count],2===l[1]&&(a.sortList.splice(h,1),k.count=-1));else if(k=i.order[i.count],2>k&&(a.sortList.push([g,k]),1<i.colSpan))for(h=1;h<i.colSpan;h++)a.sortList.push([g+h,k]);if(null!==a.sortAppend){j=a.sortAppend;for(h=0;h<j.length;h++)j[h][0]!==g&&a.sortList.push(j[h])}b.trigger("sortBegin", b[0]);setTimeout(function(){B(b[0]);D(b[0]);r(b[0])},1)}});a.cancelSelection&&a.$headers.each(function(){this.onselectstart=function(){return!1}});b.unbind("sortReset update updateCell addRows sorton appendCache applyWidgetId applyWidgets refreshWidgets destroy mouseup mouseleave").bind("sortReset",function(){a.sortList=[];B(this);D(this);r(this)}).bind("update",function(c,g,h){f(a.selectorRemove,this).remove();a.parsers=i(this);p(this);E(b,g,h)}).bind("updateCell",function(c,g,h,e){var d,j,i;d=f(this).find("tbody"); var c=d.index(f(g).parents("tbody").filter(":last")),s=f(g).parents("tr").filter(":last");d.length&&0<=c&&(j=d.eq(c).find("tr").index(s),i=g.cellIndex,d=this.config.cache[c].normalized[j].length-1,this.config.cache[c].row[this.config.cache[c].normalized[j][d]]=s,this.config.cache[c].normalized[j][i]=a.parsers[i].format(n(this,g,i),this,g,i),E(b,h,e))}).bind("addRows",function(c,g,e,d){var j=g.filter("tr").length,s=[],k=g[0].cells.length,l=f(this).find("tbody").index(g.closest("tbody"));a.parsers|| (a.parsers=i(this));for(c=0;c<j;c++){for(h=0;h<k;h++)s[h]=a.parsers[h].format(n(this,g[c].cells[h],h),this,g[c].cells[h],h);s.push(a.cache[l].row.length);a.cache[l].row.push([g[c]]);a.cache[l].normalized.push(s);s=[]}E(b,e,d)}).bind("sorton",function(a,b,c,g){f(this).trigger("sortStart",this);var h,e,d=this.config,a=b||d.sortList;d.sortList=[];f.each(a,function(a,b){h=[parseInt(b[0],10),parseInt(b[1],10)];if(e=d.headerList[h[0]])d.sortList.push(h),e.count=h[1]%(d.sortReset?3:2)});B(this);D(this); r(this,g);"function"===typeof c&&c(this)}).bind("appendCache",function(a,b,c){r(this,c);"function"===typeof b&&b(this)}).bind("applyWidgetId",function(b,c){e.getWidgetById(c).format(this,a,a.widgetOptions)}).bind("applyWidgets",function(a,b){e.applyWidget(this,b)}).bind("refreshWidgets",function(a,b,c){e.refreshWidgets(this,b,c)}).bind("destroy",function(a,b,c){e.destroy(this,b,c)});a.supportsDataObject&&"undefined"!==typeof b.data().sortlist?a.sortList=b.data().sortlist:C&&(b.metadata()&&b.metadata().sortlist)&& (a.sortList=b.metadata().sortlist);e.applyWidget(this,!0);0<a.sortList.length?b.trigger("sorton",[a.sortList,{},!a.initWidgets]):a.initWidgets&&e.applyWidget(this);if(this.config.widthFixed&&0===f(this).find("colgroup").length){var R=f("<colgroup>"),S=f(this).width();f("tr:first td",this.tBodies[0]).each(function(){R.append(f("<col>").css("width",parseInt(1E3*(f(this).width()/S),10)/10+"%"))});f(this).prepend(R)}a.showProcessing&&b.unbind("sortBegin sortEnd").bind("sortBegin sortEnd",function(a){e.isProcessing(b[0], "sortBegin"===a.type)});this.hasInitialized=!0;a.debug&&e.benchmark("Overall initialization time",f.data(this,"startoveralltimer"));b.trigger("tablesorter-initialized",this);"function"===typeof a.initialized&&a.initialized(this)}})};e.isProcessing=function(c,b,a){var g=c.config,c=a||f(c).find("."+g.cssHeader);b?(0<g.sortList.length&&(c=c.filter(function(){return this.sortDisabled?!1:e.isValueInArray(parseFloat(f(this).attr("data-column")),g.sortList)})),c.addClass(g.cssProcessing)):c.removeClass(g.cssProcessing)}; e.processTbody=function(c,b,a){if(a)return b.before('<span class="tablesorter-savemyplace"/>'),c=f.fn.detach?b.detach():b.remove();c=f(c).find("span.tablesorter-savemyplace");b.insertAfter(c);c.remove()};e.clearTableBody=function(c){f(c.tBodies).filter(":not(."+c.config.cssInfoBlock+")").empty()};e.destroy=function(c,b,a){var g=f(c),h=c.config,d=g.find("thead:first");c.hasInitialized=!1;d.find("tr:not(."+h.cssHeaderRow+")").remove();d.find(".tablesorter-resizer").remove();e.refreshWidgets(c,!0,!0); g.removeData("tablesorter").unbind("sortReset update updateCell addRows sorton appendCache applyWidgetId applyWidgets refreshWidgets destroy mouseup mouseleave").find("."+h.cssHeader).unbind("click mousedown mousemove mouseup").removeClass(h.cssHeader+" "+h.cssAsc+" "+h.cssDesc).find(".tablesorter-header-inner").each(function(){""!==h.cssIcon&&f(this).find("."+h.cssIcon).remove();f(this).replaceWith(f(this).contents())});!1!==b&&g.removeClass(h.tableClass);"function"===typeof a&&a(c)};e.regex=[/(^-?[0-9]+(\.?[0-9]*)[df]?e?[0-9]?$|^0x[0-9a-f]+$|[0-9]+)/gi, /(^([\w ]+,?[\w ]+)?[\w ]+,?[\w ]+\d+:\d+(:\d+)?[\w ]?|^\d{1,4}[\/\-]\d{1,4}[\/\-]\d{1,4}|^\w+, \w+ \d+, \d{4})/,/^0x[0-9a-f]+$/i];e.sortText=function(c,b,a,g){if(b===a)return 0;var h=c.config,d=h.string[h.empties[g]||h.emptyTo],j=e.regex;if(""===b&&0!==d)return"boolean"===typeof d?d?-1:1:-d||-1;if(""===a&&0!==d)return"boolean"===typeof d?d?1:-1:d||1;if("function"===typeof h.textSorter)return h.textSorter(b,a,c,g);c=b.replace(j[0],"\\0$1\\0").replace(/\\0$/,"").replace(/^\\0/,"").split("\\0");g=a.replace(j[0], "\\0$1\\0").replace(/\\0$/,"").replace(/^\\0/,"").split("\\0");b=parseInt(b.match(j[2]),16)||1!==c.length&&b.match(j[1])&&Date.parse(b);if(a=parseInt(a.match(j[2]),16)||b&&a.match(j[1])&&Date.parse(a)||null){if(b<a)return-1;if(b>a)return 1}h=Math.max(c.length,g.length);for(b=0;b<h;b++){a=isNaN(c[b])?c[b]||0:parseFloat(c[b])||0;j=isNaN(g[b])?g[b]||0:parseFloat(g[b])||0;if(isNaN(a)!==isNaN(j))return isNaN(a)?1:-1;typeof a!==typeof j&&(a+="",j+="");if(a<j)return-1;if(a>j)return 1}return 0};e.sortTextDesc= function(c,b,a,g){if(b===a)return 0;var d=c.config,f=d.string[d.empties[g]||d.emptyTo];return""===b&&0!==f?"boolean"===typeof f?f?-1:1:f||1:""===a&&0!==f?"boolean"===typeof f?f?1:-1:-f||-1:"function"===typeof d.textSorter?d.textSorter(a,b,c,g):e.sortText(c,a,b)};e.getTextValue=function(c,b,a){if(b){for(var g=c.length,d=b+a,b=0;b<g;b++)d+=c.charCodeAt(b);return a*d}return 0};e.sortNumeric=function(c,b,a,g,d,f){if(b===a)return 0;c=c.config;g=c.string[c.empties[g]||c.emptyTo];if(""===b&&0!==g)return"boolean"=== typeof g?g?-1:1:-g||-1;if(""===a&&0!==g)return"boolean"===typeof g?g?1:-1:g||1;isNaN(b)&&(b=e.getTextValue(b,d,f));isNaN(a)&&(a=e.getTextValue(a,d,f));return b-a};e.sortNumericDesc=function(c,b,a,d,h,f){if(b===a)return 0;c=c.config;d=c.string[c.empties[d]||c.emptyTo];if(""===b&&0!==d)return"boolean"===typeof d?d?-1:1:d||1;if(""===a&&0!==d)return"boolean"===typeof d?d?1:-1:-d||-1;isNaN(b)&&(b=e.getTextValue(b,h,f));isNaN(a)&&(a=e.getTextValue(a,h,f));return a-b};e.characterEquivalents={a:"\u00e1\u00e0\u00e2\u00e3\u00e4", A:"\u00c1\u00c0\u00c2\u00c3\u00c4",c:"\u00e7",C:"\u00c7",e:"\u00e9\u00e8\u00ea\u00eb",E:"\u00c9\u00c8\u00ca\u00cb",i:"\u00ed\u00ec\u0130\u00ee\u00ef",I:"\u00cd\u00cc\u0130\u00ce\u00cf",o:"\u00f3\u00f2\u00f4\u00f5\u00f6",O:"\u00d3\u00d2\u00d4\u00d5\u00d6",S:"\u00df",u:"\u00fa\u00f9\u00fb\u00fc",U:"\u00da\u00d9\u00db\u00dc"};e.replaceAccents=function(c){var b,a="[",d=e.characterEquivalents;if(!e.characterRegex){e.characterRegexArray={};for(b in d)"string"===typeof b&&(a+=d[b],e.characterRegexArray[b]= RegExp("["+d[b]+"]","g"));e.characterRegex=RegExp(a+"]")}if(e.characterRegex.test(c))for(b in d)"string"===typeof b&&(c=c.replace(e.characterRegexArray[b],b));return c};e.isValueInArray=function(c,b){var a,d=b.length;for(a=0;a<d;a++)if(b[a][0]===c)return!0;return!1};e.addParser=function(c){var b,a=e.parsers.length,d=!0;for(b=0;b<a;b++)e.parsers[b].id.toLowerCase()===c.id.toLowerCase()&&(d=!1);d&&e.parsers.push(c)};e.getParserById=function(c){var b,a=e.parsers.length;for(b=0;b<a;b++)if(e.parsers[b].id.toLowerCase()=== c.toString().toLowerCase())return e.parsers[b];return!1};e.addWidget=function(c){e.widgets.push(c)};e.getWidgetById=function(c){var b,a,d=e.widgets.length;for(b=0;b<d;b++)if((a=e.widgets[b])&&a.hasOwnProperty("id")&&a.id.toLowerCase()===c.toLowerCase())return a};e.applyWidget=function(c,b){var a=c.config,d=a.widgetOptions,h=a.widgets.sort().reverse(),i,j,l,k=h.length;j=f.inArray("zebra",a.widgets);0<=j&&(a.widgets.splice(j,1),a.widgets.push("zebra"));a.debug&&(i=new Date);for(j=0;j<k;j++)(l=e.getWidgetById(h[j]))&& (!0===b&&l.hasOwnProperty("init")?l.init(c,l,a,d):!b&&l.hasOwnProperty("format")&&l.format(c,a,d));a.debug&&u("Completed "+(!0===b?"initializing":"applying")+" widgets",i)};e.refreshWidgets=function(c,b,a){var g,h=c.config,i=h.widgets,j=e.widgets,l=j.length;for(g=0;g<l;g++)if(j[g]&&j[g].id&&(b||0>f.inArray(j[g].id,i)))h.debug&&d("removing "+j[g].id),j[g].hasOwnProperty("remove")&&j[g].remove(c,h,h.widgetOptions);!0!==a&&e.applyWidget(c,b)};e.getData=function(c,b,a){var d="",c=f(c),e,i;if(!c.length)return""; e=f.metadata?c.metadata():!1;i=" "+(c.attr("class")||"");"undefined"!==typeof c.data(a)||"undefined"!==typeof c.data(a.toLowerCase())?d+=c.data(a)||c.data(a.toLowerCase()):e&&"undefined"!==typeof e[a]?d+=e[a]:b&&"undefined"!==typeof b[a]?d+=b[a]:" "!==i&&i.match(" "+a+"-")&&(d=i.match(RegExp(" "+a+"-(\\w+)"))[1]||"");return f.trim(d)};e.formatFloat=function(c,b){if("string"!==typeof c||""===c)return c;c=!1!==b.config.usNumberFormat?c.replace(/,/g,""):c.replace(/[\s|\.]/g,"").replace(/,/g,".");/^\s*\([.\d]+\)/.test(c)&& (c=c.replace(/^\s*\(/,"-").replace(/\)/,""));var a=parseFloat(c);return isNaN(a)?f.trim(c):a};e.isDigit=function(c){return isNaN(c)?/^[\-+(]?\d+[)]?$/.test(c.toString().replace(/[,.'\s]/g,"")):!0}}});var i=f.tablesorter;f.fn.extend({tablesorter:i.construct});i.addParser({id:"text",is:function(){return!0},format:function(d,u){var n=u.config,d=f.trim(n.ignoreCase?d.toLocaleLowerCase():d);return n.sortLocaleCompare?i.replaceAccents(d):d},type:"text"});i.addParser({id:"currency",is:function(d){return/^\(?[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]\d+/.test(d)}, format:function(d,f){return i.formatFloat(d.replace(/[^\w,. \-()]/g,""),f)},type:"numeric"});i.addParser({id:"ipAddress",is:function(d){return/^\d{1,3}[\.]\d{1,3}[\.]\d{1,3}[\.]\d{1,3}$/.test(d)},format:function(d,f){var n,t=d.split("."),p="",r=t.length;for(n=0;n<r;n++)p+=("00"+t[n]).slice(-3);return i.formatFloat(p,f)},type:"numeric"});i.addParser({id:"url",is:function(d){return/^(https?|ftp|file):\/\//.test(d)},format:function(d){return f.trim(d.replace(/(https?|ftp|file):\/\//,""))},type:"text"}); i.addParser({id:"isoDate",is:function(d){return/^\d{4}[\/\-]\d{1,2}[\/\-]\d{1,2}$/.test(d)},format:function(d,f){return i.formatFloat(""!==d?(new Date(d.replace(/-/g,"/"))).getTime()||"":"",f)},type:"numeric"});i.addParser({id:"percent",is:function(d){return/\d%\)?$/.test(d)},format:function(d,f){return i.formatFloat(d.replace(/%/g,""),f)},type:"numeric"});i.addParser({id:"usLongDate",is:function(d){return/^[A-Z]{3,10}\.?\s+\d{1,2},?\s+(\d{4}|'?\d{2})\s+(([0-2]?\d:[0-5]\d)|([0-1]?\d:[0-5]\d\s?([AP]M)))$/i.test(d)}, format:function(d,f){return i.formatFloat((new Date(d.replace(/(\S)([AP]M)$/i,"$1 $2"))).getTime()||"",f)},type:"numeric"});i.addParser({id:"shortDate",is:function(d){return/^(\d{2}|\d{4})[\/\-\,\.\s+]\d{2}[\/\-\.\,\s+](\d{2}|\d{4})$/.test(d)},format:function(d,f,n,t){var n=f.config,p=n.headerList[t],r=p.shortDateFormat;"undefined"===typeof r&&(r=p.shortDateFormat=i.getData(p,n.headers[t],"dateFormat")||n.dateFormat);d=d.replace(/\s+/g," ").replace(/[\-|\.|\,]/g,"/");"mmddyyyy"===r?d=d.replace(/(\d{1,2})[\/\s](\d{1,2})[\/\s](\d{4})/, "$3/$1/$2"):"ddmmyyyy"===r?d=d.replace(/(\d{1,2})[\/\s](\d{1,2})[\/\s](\d{4})/,"$3/$2/$1"):"yyyymmdd"===r&&(d=d.replace(/(\d{4})[\/\s](\d{1,2})[\/\s](\d{1,2})/,"$1/$2/$3"));return i.formatFloat((new Date(d)).getTime()||"",f)},type:"numeric"});i.addParser({id:"time",is:function(d){return/^(([0-2]?\d:[0-5]\d)|([0-1]?\d:[0-5]\d\s?([AP]M)))$/i.test(d)},format:function(d,f){return i.formatFloat((new Date("2000/01/01 "+d.replace(/(\S)([AP]M)$/i,"$1 $2"))).getTime()||"",f)},type:"numeric"});i.addParser({id:"digit", is:function(d){return i.isDigit(d)},format:function(d,f){return i.formatFloat(d.replace(/[^\w,. \-()]/g,""),f)},type:"numeric"});i.addParser({id:"metadata",is:function(){return!1},format:function(d,i,n){d=i.config;d=!d.parserMetadataName?"sortValue":d.parserMetadataName;return f(n).metadata()[d]},type:"numeric"});i.addWidget({id:"zebra",format:function(d,u,n){var t,p,r,B,D,C,E=RegExp(u.cssChildRow,"i"),e=f(d).children("tbody:not(."+u.cssInfoBlock+")");u.debug&&(D=new Date);for(d=0;d<e.length;d++)t= f(e[d]),C=t.children("tr").length,1<C&&(r=0,t=t.children("tr:visible"),t.each(function(){p=f(this);E.test(this.className)||r++;B=0===r%2;p.removeClass(n.zebra[B?1:0]).addClass(n.zebra[B?0:1])}));u.debug&&i.benchmark("Applying Zebra widget",D)},remove:function(d,i){var n,t,p=f(d).children("tbody:not(."+i.cssInfoBlock+")"),r=(i.widgetOptions.zebra||["even","odd"]).join(" ");for(n=0;n<p.length;n++)t=f.tablesorter.processTbody(d,f(p[n]),!0),t.children().removeClass(r),f.tablesorter.processTbody(d,t,!1)}})}(jQuery);
5
+ !function(g){g.extend({tablesorter:new function(){function d(c){"undefined"!==typeof console&&"undefined"!==typeof console.log?console.log(c):alert(c)}function v(c,b){d(c+" ("+((new Date).getTime()-b.getTime())+"ms)")}function p(c,b,a){if(!b)return"";var f=c.config,h=f.textExtraction,e="",e="simple"===h?f.supportsTextContent?b.textContent:g(b).text():"function"===typeof h?h(b,c,a):"object"===typeof h&&h.hasOwnProperty(a)?h[a](b,c,a):f.supportsTextContent?b.textContent:g(b).text();return g.trim(e)} function j(c){var b=c.config,a=g(c.tBodies).filter(":not(."+b.cssInfoBlock+")"),f,h,s,k,m,l,n="";if(0===a.length)return b.debug?d("*Empty table!* Not building a parser cache"):"";a=a[0].rows;if(a[0]){f=[];h=a[0].cells.length;for(s=0;s<h;s++){k=b.$headers.filter(":not([colspan])");k=k.add(b.$headers.filter('[colspan="1"]')).filter('[data-column="'+s+'"]:last');m=b.headers[s];l=e.getParserById(e.getData(k,m,"sorter"));b.empties[s]=e.getData(k,m,"empty")||b.emptyTo||(b.emptyToBottom?"bottom":"top"); b.strings[s]=e.getData(k,m,"string")||b.stringTo||"max";if(!l)a:{k=c;m=a;l=-1;for(var v=s,r=void 0,t=e.parsers.length,y=!1,q="",r=!0;""===q&&r;)l++,m[l]?(y=m[l].cells[v],q=p(k,y,v),k.config.debug&&d("Checking if value was empty on row "+l+", column: "+v+": "+q)):r=!1;for(r=1;r<t;r++)if(e.parsers[r].is(q,k,y)){l=e.parsers[r];break a}l=e.parsers[0]}b.debug&&(n+="column:"+s+"; parser:"+l.id+"; string:"+b.strings[s]+"; empty: "+b.empties[s]+"\n");f.push(l)}}b.debug&&d(n);return f}function q(c){var b= c.tBodies,a=c.config,f,h,s=a.parsers,k,m,l,n,j,r,q,y=[];a.cache={};if(!s)return a.debug?d("*Empty table!* Not building a cache"):"";a.debug&&(q=new Date);a.showProcessing&&e.isProcessing(c,!0);for(n=0;n<b.length;n++)if(a.cache[n]={row:[],normalized:[]},!g(b[n]).hasClass(a.cssInfoBlock)){f=b[n]&&b[n].rows.length||0;h=b[n].rows[0]&&b[n].rows[0].cells.length||0;for(m=0;m<f;++m)if(j=g(b[n].rows[m]),r=[],j.hasClass(a.cssChildRow))a.cache[n].row[a.cache[n].row.length-1]=a.cache[n].row[a.cache[n].row.length- 1].add(j);else{a.cache[n].row.push(j);for(l=0;l<h;++l)if(k=p(c,j[0].cells[l],l),k=s[l].format(k,c,j[0].cells[l],l),r.push(k),"numeric"===(s[l].type||"").toLowerCase())y[l]=Math.max(Math.abs(k),y[l]||0);r.push(a.cache[n].normalized.length);a.cache[n].normalized.push(r)}a.cache[n].colMax=y}a.showProcessing&&e.isProcessing(c);a.debug&&v("Building cache for "+f+" rows",q)}function t(c,b){var a=c.config,f=c.tBodies,h=[],d=a.cache,k,m,l,n,j,r,p,q,t,u,w;a.debug&&(w=new Date);for(q=0;q<f.length;q++)if(k= g(f[q]),!k.hasClass(a.cssInfoBlock)){j=e.processTbody(c,k,!0);k=d[q].row;m=d[q].normalized;n=(l=m.length)?m[0].length-1:0;for(r=0;r<l;r++)if(u=m[r][n],h.push(k[u]),!a.appender||!a.removeRows){t=k[u].length;for(p=0;p<t;p++)j.append(k[u][p])}e.processTbody(c,j,!1)}a.appender&&a.appender(c,h);a.debug&&v("Rebuilt table",w);b||e.applyWidget(c);g(c).trigger("sortEnd",c)}function C(c){var b,a,f,h=c.config,e=h.sortList,d=[h.cssAsc,h.cssDesc],m=g(c).find("tfoot tr").children().removeClass(d.join(" "));h.$headers.removeClass(d.join(" ")); f=e.length;for(b=0;b<f;b++)if(2!==e[b][1]&&(c=h.$headers.not(".sorter-false").filter('[data-column="'+e[b][0]+'"]'+(1===f?":last":"")),c.length))for(a=0;a<c.length;a++)c[a].sortDisabled||(c.eq(a).addClass(d[e[b][1]]),m.length&&m.filter('[data-column="'+e[b][0]+'"]').eq(a).addClass(d[e[b][1]]))}function E(c){var b=0,a=c.config,f=a.sortList,h=f.length,e=c.tBodies.length,d,m,l,n,j,r,p,q,t;if(!a.serverSideSorting){a.debug&&(d=new Date);for(l=0;l<e;l++)j=a.cache[l].colMax,t=(r=a.cache[l].normalized)&& r[0]?r[0].length-1:0,r.sort(function(e,d){for(m=0;m<h;m++){n=f[m][0];q=f[m][1];p=/n/i.test(a.parsers&&a.parsers[n]?a.parsers[n].type||"":"")?"Numeric":"Text";p+=0===q?"":"Desc";/Numeric/.test(p)&&a.strings[n]&&(b="boolean"===typeof a.string[a.strings[n]]?(0===q?1:-1)*(a.string[a.strings[n]]?-1:1):a.strings[n]?a.string[a.strings[n]]||0:0);var k=g.tablesorter["sort"+p](c,e[n],d[n],n,j[n],b);if(k)return k}return e[t]-d[t]});a.debug&&v("Sorting on "+f.toString()+" and dir "+q+" time",d)}}function D(c, b){c.trigger("updateComplete");"function"===typeof b&&b(c[0])}function F(c,b,a){!1!==b?c.trigger("sorton",[c[0].config.sortList,function(){D(c,a)}]):D(c,a)}var e=this;e.version="2.6.2";e.parsers=[];e.widgets=[];e.defaults={theme:"default",widthFixed:!1,showProcessing:!1,cancelSelection:!0,dateFormat:"mmddyyyy",sortMultiSortKey:"shiftKey",sortResetKey:"ctrlKey",usNumberFormat:!0,delayInit:!1,serverSideSorting:!1,headers:{},ignoreCase:!0,sortForce:null,sortList:[],sortAppend:null,sortInitialOrder:"asc", sortLocaleCompare:!1,sortReset:!1,sortRestart:!1,emptyTo:"bottom",stringTo:"max",textExtraction:"simple",textSorter:null,widgets:[],widgetOptions:{zebra:["even","odd"]},initWidgets:!0,initialized:null,onRenderHeader:null,tableClass:"tablesorter",cssAsc:"tablesorter-headerAsc",cssChildRow:"tablesorter-childRow",cssDesc:"tablesorter-headerDesc",cssHeader:"tablesorter-header",cssHeaderRow:"tablesorter-headerRow",cssIcon:"tablesorter-icon",cssInfoBlock:"tablesorter-infoOnly",cssProcessing:"tablesorter-processing", selectorHeaders:"> thead th, > thead td",selectorSort:"th, td",selectorRemove:".remove-me",debug:!1,headerList:[],empties:{},strings:{},parsers:[]};e.benchmark=v;e.construct=function(c){return this.each(function(){if(!this.tHead||0===this.tBodies.length||!0===this.hasInitialized)return this.config.debug?d("stopping initialization! No thead, tbody or tablesorter has already been initialized"):"";var b=g(this),a,f,h,s="",k,m,l,n,D=g.metadata;this.hasInitialized=!1;this.config={};a=g.extend(!0,this.config, e.defaults,c);g.data(this,"tablesorter",a);a.debug&&g.data(this,"startoveralltimer",new Date);a.supportsTextContent="x"===g("<span>x</span>")[0].textContent;a.supportsDataObject=1.4<=parseFloat(g.fn.jquery);a.string={max:1,min:-1,"max+":1,"max-":-1,zero:0,none:0,"null":0,top:!0,bottom:!1};/tablesorter\-/.test(b.attr("class"))||(s=""!==a.theme?" tablesorter-"+a.theme:"");b.addClass(a.tableClass+s);var r=[],N={},y=g(this).find("thead:eq(0), tfoot").children("tr"),I,J,w,z,M,B,K,O,P,G;for(I=0;I<y.length;I++){M= y[I].cells;for(J=0;J<M.length;J++){z=M[J];B=z.parentNode.rowIndex;K=B+"-"+z.cellIndex;O=z.rowSpan||1;P=z.colSpan||1;"undefined"===typeof r[B]&&(r[B]=[]);for(w=0;w<r[B].length+1;w++)if("undefined"===typeof r[B][w]){G=w;break}N[K]=G;g(z).attr({"data-column":G});for(w=B;w<B+O;w++){"undefined"===typeof r[w]&&(r[w]=[]);K=r[w];for(z=G;z<G+P;z++)K[z]="x"}}}var L,A,Q,H,R,x=this.config;x.headerList=[];x.debug&&(R=new Date);r=g(this).find(x.selectorHeaders).each(function(a){A=g(this);L=x.headers[a];Q=x.cssIcon? '<i class="'+x.cssIcon+'"></i>':"";this.innerHTML='<div class="tablesorter-header-inner">'+this.innerHTML+Q+"</div>";x.onRenderHeader&&x.onRenderHeader.apply(A,[a]);this.column=N[this.parentNode.rowIndex+"-"+this.cellIndex];var b=e.getData(A,L,"sortInitialOrder")||x.sortInitialOrder;this.order=/^d/i.test(b)||1===b?[1,0,2]:[0,1,2];this.count=-1;"false"===e.getData(A,L,"sorter")?(this.sortDisabled=!0,A.addClass("sorter-false")):A.removeClass("sorter-false");this.lockedOrder=!1;H=e.getData(A,L,"lockedOrder")|| !1;"undefined"!==typeof H&&!1!==H&&(this.order=this.lockedOrder=/^d/i.test(H)||1===H?[1,1,1]:[0,0,0]);A.addClass((this.sortDisabled?"sorter-false ":" ")+x.cssHeader);x.headerList[a]=this;A.parent().addClass(x.cssHeaderRow)});this.config.debug&&(v("Built headers:",R),d(r));a.$headers=r;a.parsers=j(this);a.delayInit||q(this);a.$headers.find("*").andSelf().filter(a.selectorSort).unbind("mousedown.tablesorter mouseup.tablesorter").bind("mousedown.tablesorter mouseup.tablesorter",function(c,d){var j=(this.tagName.match("TH|TD")? g(this):g(this).parents("th, td").filter(":last"))[0];if(1!==(c.which||c.button))return!1;if("mousedown"===c.type)return n=(new Date).getTime(),"INPUT"===c.target.tagName?"":!a.cancelSelection;if(!0!==d&&250<(new Date).getTime()-n)return!1;a.delayInit&&!a.cache&&q(b[0]);if(!j.sortDisabled){b.trigger("sortStart",b[0]);s=!c[a.sortMultiSortKey];j.count=c[a.sortResetKey]?2:(j.count+1)%(a.sortReset?3:2);a.sortRestart&&(f=j,a.$headers.each(function(){if(this!==f&&(s||!g(this).is("."+a.cssDesc+",."+a.cssAsc)))this.count= -1}));f=j.column;if(s){a.sortList=[];if(null!==a.sortForce){k=a.sortForce;for(h=0;h<k.length;h++)k[h][0]!==f&&a.sortList.push(k[h])}l=j.order[j.count];if(2>l&&(a.sortList.push([f,l]),1<j.colSpan))for(h=1;h<j.colSpan;h++)a.sortList.push([f+h,l])}else if(a.sortAppend&&1<a.sortList.length&&e.isValueInArray(a.sortAppend[0][0],a.sortList)&&a.sortList.pop(),e.isValueInArray(f,a.sortList))for(h=0;h<a.sortList.length;h++)m=a.sortList[h],l=a.headerList[m[0]],m[0]===f&&(m[1]=l.order[l.count],2===m[1]&&(a.sortList.splice(h, 1),l.count=-1));else if(l=j.order[j.count],2>l&&(a.sortList.push([f,l]),1<j.colSpan))for(h=1;h<j.colSpan;h++)a.sortList.push([f+h,l]);if(null!==a.sortAppend){k=a.sortAppend;for(h=0;h<k.length;h++)k[h][0]!==f&&a.sortList.push(k[h])}b.trigger("sortBegin",b[0]);setTimeout(function(){C(b[0]);E(b[0]);t(b[0])},1)}});a.cancelSelection&&a.$headers.each(function(){this.onselectstart=function(){return!1}});b.unbind("sortReset update updateCell addRows sorton appendCache applyWidgetId applyWidgets refreshWidgets destroy mouseup mouseleave").bind("sortReset", function(){a.sortList=[];C(this);E(this);t(this)}).bind("update",function(c,f,h){g(a.selectorRemove,this).remove();a.parsers=j(this);q(this);F(b,f,h)}).bind("updateCell",function(c,f,h,e){var d,k,s;d=g(this).find("tbody");c=d.index(g(f).parents("tbody").filter(":last"));var j=g(f).parents("tr").filter(":last");f=g(f)[0];d.length&&0<=c&&(k=d.eq(c).find("tr").index(j),s=f.cellIndex,d=this.config.cache[c].normalized[k].length-1,this.config.cache[c].row[this.config.cache[c].normalized[k][d]]=j,this.config.cache[c].normalized[k][s]= a.parsers[s].format(p(this,f,s),this,f,s),F(b,h,e))}).bind("addRows",function(c,f,e,d){var k=f.filter("tr").length,s=[],l=f[0].cells.length,m=g(this).find("tbody").index(f.closest("tbody"));a.parsers||(a.parsers=j(this));for(c=0;c<k;c++){for(h=0;h<l;h++)s[h]=a.parsers[h].format(p(this,f[c].cells[h],h),this,f[c].cells[h],h);s.push(a.cache[m].row.length);a.cache[m].row.push([f[c]]);a.cache[m].normalized.push(s);s=[]}F(b,e,d)}).bind("sorton",function(a,b,c,f){g(this).trigger("sortStart",this);var h, e,d=this.config;a=b||d.sortList;d.sortList=[];g.each(a,function(a,b){h=[parseInt(b[0],10),parseInt(b[1],10)];if(e=d.headerList[h[0]])d.sortList.push(h),e.count=h[1]%(d.sortReset?3:2)});C(this);E(this);t(this,f);"function"===typeof c&&c(this)}).bind("appendCache",function(a,b,c){t(this,c);"function"===typeof b&&b(this)}).bind("applyWidgetId",function(b,c){e.getWidgetById(c).format(this,a,a.widgetOptions)}).bind("applyWidgets",function(a,b){e.applyWidget(this,b)}).bind("refreshWidgets",function(a,b, c){e.refreshWidgets(this,b,c)}).bind("destroy",function(a,b,c){e.destroy(this,b,c)});a.supportsDataObject&&"undefined"!==typeof b.data().sortlist?a.sortList=b.data().sortlist:D&&(b.metadata()&&b.metadata().sortlist)&&(a.sortList=b.metadata().sortlist);e.applyWidget(this,!0);0<a.sortList.length?b.trigger("sorton",[a.sortList,{},!a.initWidgets]):a.initWidgets&&e.applyWidget(this);if(this.config.widthFixed&&0===g(this).find("colgroup").length){var S=g("<colgroup>"),T=g(this).width();g("tr:first td", this.tBodies[0]).each(function(){S.append(g("<col>").css("width",parseInt(1E3*(g(this).width()/T),10)/10+"%"))});g(this).prepend(S)}a.showProcessing&&b.unbind("sortBegin sortEnd").bind("sortBegin sortEnd",function(a){e.isProcessing(b[0],"sortBegin"===a.type)});this.hasInitialized=!0;a.debug&&e.benchmark("Overall initialization time",g.data(this,"startoveralltimer"));b.trigger("tablesorter-initialized",this);"function"===typeof a.initialized&&a.initialized(this)})};e.isProcessing=function(c,b,a){var f= c.config;c=a||g(c).find("."+f.cssHeader);b?(0<f.sortList.length&&(c=c.filter(function(){return this.sortDisabled?!1:e.isValueInArray(parseFloat(g(this).attr("data-column")),f.sortList)})),c.addClass(f.cssProcessing)):c.removeClass(f.cssProcessing)};e.processTbody=function(c,b,a){if(a)return b.before('<span class="tablesorter-savemyplace"/>'),c=g.fn.detach?b.detach():b.remove();c=g(c).find("span.tablesorter-savemyplace");b.insertAfter(c);c.remove()};e.clearTableBody=function(c){g(c.tBodies).filter(":not(."+ c.config.cssInfoBlock+")").empty()};e.destroy=function(c,b,a){var f=g(c),h=c.config,d=f.find("thead:first");c.hasInitialized=!1;d.find("tr:not(."+h.cssHeaderRow+")").remove();d.find(".tablesorter-resizer").remove();e.refreshWidgets(c,!0,!0);f.removeData("tablesorter").unbind("sortReset update updateCell addRows sorton appendCache applyWidgetId applyWidgets refreshWidgets destroy mouseup mouseleave").find("."+h.cssHeader).unbind("click mousedown mousemove mouseup").removeClass(h.cssHeader+" "+h.cssAsc+ " "+h.cssDesc).find(".tablesorter-header-inner").each(function(){""!==h.cssIcon&&g(this).find("."+h.cssIcon).remove();g(this).replaceWith(g(this).contents())});!1!==b&&f.removeClass(h.tableClass);"function"===typeof a&&a(c)};e.regex=[/(^-?[0-9]+(\.?[0-9]*)[df]?e?[0-9]?$|^0x[0-9a-f]+$|[0-9]+)/gi,/(^([\w ]+,?[\w ]+)?[\w ]+,?[\w ]+\d+:\d+(:\d+)?[\w ]?|^\d{1,4}[\/\-]\d{1,4}[\/\-]\d{1,4}|^\w+, \w+ \d+, \d{4})/,/^0x[0-9a-f]+$/i];e.sortText=function(c,b,a,f){if(b===a)return 0;var h=c.config,d=h.string[h.empties[f]|| h.emptyTo],k=e.regex;if(""===b&&0!==d)return"boolean"===typeof d?d?-1:1:-d||-1;if(""===a&&0!==d)return"boolean"===typeof d?d?1:-1:d||1;if("function"===typeof h.textSorter)return h.textSorter(b,a,c,f);c=b.replace(k[0],"\\0$1\\0").replace(/\\0$/,"").replace(/^\\0/,"").split("\\0");f=a.replace(k[0],"\\0$1\\0").replace(/\\0$/,"").replace(/^\\0/,"").split("\\0");b=parseInt(b.match(k[2]),16)||1!==c.length&&b.match(k[1])&&Date.parse(b);if(a=parseInt(a.match(k[2]),16)||b&&a.match(k[1])&&Date.parse(a)||null){if(b< a)return-1;if(b>a)return 1}h=Math.max(c.length,f.length);for(b=0;b<h;b++){a=isNaN(c[b])?c[b]||0:parseFloat(c[b])||0;k=isNaN(f[b])?f[b]||0:parseFloat(f[b])||0;if(isNaN(a)!==isNaN(k))return isNaN(a)?1:-1;typeof a!==typeof k&&(a+="",k+="");if(a<k)return-1;if(a>k)return 1}return 0};e.sortTextDesc=function(c,b,a,f){if(b===a)return 0;var d=c.config,g=d.string[d.empties[f]||d.emptyTo];return""===b&&0!==g?"boolean"===typeof g?g?-1:1:g||1:""===a&&0!==g?"boolean"===typeof g?g?1:-1:-g||-1:"function"===typeof d.textSorter? d.textSorter(a,b,c,f):e.sortText(c,a,b)};e.getTextValue=function(c,b,a){if(b){var f=c.length,d=b+a;for(b=0;b<f;b++)d+=c.charCodeAt(b);return a*d}return 0};e.sortNumeric=function(c,b,a,f,d,g){if(b===a)return 0;c=c.config;f=c.string[c.empties[f]||c.emptyTo];if(""===b&&0!==f)return"boolean"===typeof f?f?-1:1:-f||-1;if(""===a&&0!==f)return"boolean"===typeof f?f?1:-1:f||1;isNaN(b)&&(b=e.getTextValue(b,d,g));isNaN(a)&&(a=e.getTextValue(a,d,g));return b-a};e.sortNumericDesc=function(c,b,a,f,d,g){if(b=== a)return 0;c=c.config;f=c.string[c.empties[f]||c.emptyTo];if(""===b&&0!==f)return"boolean"===typeof f?f?-1:1:f||1;if(""===a&&0!==f)return"boolean"===typeof f?f?1:-1:-f||-1;isNaN(b)&&(b=e.getTextValue(b,d,g));isNaN(a)&&(a=e.getTextValue(a,d,g));return a-b};e.characterEquivalents={a:"\u00e1\u00e0\u00e2\u00e3\u00e4\u0105\u00e5",A:"\u00c1\u00c0\u00c2\u00c3\u00c4\u0104\u00c5",c:"\u00e7\u0107\u010d",C:"\u00c7\u0106\u010c",e:"\u00e9\u00e8\u00ea\u00eb\u011b\u0119",E:"\u00c9\u00c8\u00ca\u00cb\u011a\u0118", i:"\u00ed\u00ec\u0130\u00ee\u00ef\u0131",I:"\u00cd\u00cc\u0130\u00ce\u00cf",o:"\u00f3\u00f2\u00f4\u00f5\u00f6",O:"\u00d3\u00d2\u00d4\u00d5\u00d6",ss:"\u00df",SS:"\u1e9e",u:"\u00fa\u00f9\u00fb\u00fc\u016f",U:"\u00da\u00d9\u00db\u00dc\u016e"};e.replaceAccents=function(c){var b,a="[",d=e.characterEquivalents;if(!e.characterRegex){e.characterRegexArray={};for(b in d)"string"===typeof b&&(a+=d[b],e.characterRegexArray[b]=RegExp("["+d[b]+"]","g"));e.characterRegex=RegExp(a+"]")}if(e.characterRegex.test(c))for(b in d)"string"=== typeof b&&(c=c.replace(e.characterRegexArray[b],b));return c};e.isValueInArray=function(c,b){var a,d=b.length;for(a=0;a<d;a++)if(b[a][0]===c)return!0;return!1};e.addParser=function(c){var b,a=e.parsers.length,d=!0;for(b=0;b<a;b++)e.parsers[b].id.toLowerCase()===c.id.toLowerCase()&&(d=!1);d&&e.parsers.push(c)};e.getParserById=function(c){var b,a=e.parsers.length;for(b=0;b<a;b++)if(e.parsers[b].id.toLowerCase()===c.toString().toLowerCase())return e.parsers[b];return!1};e.addWidget=function(c){e.widgets.push(c)}; e.getWidgetById=function(c){var b,a,d=e.widgets.length;for(b=0;b<d;b++)if((a=e.widgets[b])&&a.hasOwnProperty("id")&&a.id.toLowerCase()===c.toLowerCase())return a};e.applyWidget=function(c,b){var a=c.config,d=a.widgetOptions,h=a.widgets.sort().reverse(),j,k,m,l=h.length;k=g.inArray("zebra",a.widgets);0<=k&&(a.widgets.splice(k,1),a.widgets.push("zebra"));a.debug&&(j=new Date);for(k=0;k<l;k++)(m=e.getWidgetById(h[k]))&&(!0===b&&m.hasOwnProperty("init")?m.init(c,m,a,d):!b&&m.hasOwnProperty("format")&& m.format(c,a,d));a.debug&&v("Completed "+(!0===b?"initializing":"applying")+" widgets",j)};e.refreshWidgets=function(c,b,a){var f,h=c.config,j=h.widgets,k=e.widgets,m=k.length;for(f=0;f<m;f++)if(k[f]&&k[f].id&&(b||0>g.inArray(k[f].id,j)))h.debug&&d("Refeshing widgets: Removing "+k[f].id),k[f].hasOwnProperty("remove")&&k[f].remove(c,h,h.widgetOptions);!0!==a&&e.applyWidget(c,b)};e.getData=function(c,b,a){var d="";c=g(c);var e,j;if(!c.length)return"";e=g.metadata?c.metadata():!1;j=" "+(c.attr("class")|| "");"undefined"!==typeof c.data(a)||"undefined"!==typeof c.data(a.toLowerCase())?d+=c.data(a)||c.data(a.toLowerCase()):e&&"undefined"!==typeof e[a]?d+=e[a]:b&&"undefined"!==typeof b[a]?d+=b[a]:" "!==j&&j.match(" "+a+"-")&&(d=j.match(RegExp(" "+a+"-(\\w+)"))[1]||"");return g.trim(d)};e.formatFloat=function(c,b){if("string"!==typeof c||""===c)return c;var a;c=(b&&b.config?!1!==b.config.usNumberFormat:"undefined"!==typeof b?b:1)?c.replace(/,/g,""):c.replace(/[\s|\.]/g,"").replace(/,/g,".");/^\s*\([.\d]+\)/.test(c)&& (c=c.replace(/^\s*\(/,"-").replace(/\)/,""));a=parseFloat(c);return isNaN(a)?g.trim(c):a};e.isDigit=function(c){return isNaN(c)?/^[\-+(]?\d+[)]?$/.test(c.toString().replace(/[,.'"\s]/g,"")):!0}}});var j=g.tablesorter;g.fn.extend({tablesorter:j.construct});j.addParser({id:"text",is:function(){return!0},format:function(d,v){var p=v.config;d=g.trim(p.ignoreCase?d.toLocaleLowerCase():d);return p.sortLocaleCompare?j.replaceAccents(d):d},type:"text"});j.addParser({id:"currency",is:function(d){return/^\(?\d+[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]|[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]\d+\)?$/.test(d)}, format:function(d,g){return j.formatFloat(d.replace(/[^\w,. \-()]/g,""),g)},type:"numeric"});j.addParser({id:"ipAddress",is:function(d){return/^\d{1,3}[\.]\d{1,3}[\.]\d{1,3}[\.]\d{1,3}$/.test(d)},format:function(d,g){var p,u=d.split("."),q="",t=u.length;for(p=0;p<t;p++)q+=("00"+u[p]).slice(-3);return j.formatFloat(q,g)},type:"numeric"});j.addParser({id:"url",is:function(d){return/^(https?|ftp|file):\/\//.test(d)},format:function(d){return g.trim(d.replace(/(https?|ftp|file):\/\//,""))},type:"text"}); j.addParser({id:"isoDate",is:function(d){return/^\d{4}[\/\-]\d{1,2}[\/\-]\d{1,2}$/.test(d)},format:function(d,g){return j.formatFloat(""!==d?(new Date(d.replace(/-/g,"/"))).getTime()||"":"",g)},type:"numeric"});j.addParser({id:"percent",is:function(d){return/(\d\s?%|%\s?\d)/.test(d)},format:function(d,g){return j.formatFloat(d.replace(/%/g,""),g)},type:"numeric"});j.addParser({id:"usLongDate",is:function(d){return/^[A-Z]{3,10}\.?\s+\d{1,2},?\s+(\d{4})(\s+\d{1,2}:\d{2}(:\d{2})?(\s+[AP]M)?)?$/i.test(d)}, format:function(d,g){return j.formatFloat((new Date(d.replace(/(\S)([AP]M)$/i,"$1 $2"))).getTime()||"",g)},type:"numeric"});j.addParser({id:"shortDate",is:function(d){return/^(\d{1,2}|\d{4})[\/\-\,\.\s+]\d{1,2}[\/\-\.\,\s+](\d{1,2}|\d{4})$/.test(d)},format:function(d,g,p,u){p=g.config;var q=p.headerList[u],t=q.shortDateFormat;"undefined"===typeof t&&(t=q.shortDateFormat=j.getData(q,p.headers[u],"dateFormat")||p.dateFormat);d=d.replace(/\s+/g," ").replace(/[\-|\.|\,]/g,"/");"mmddyyyy"===t?d=d.replace(/(\d{1,2})[\/\s](\d{1,2})[\/\s](\d{4})/, "$3/$1/$2"):"ddmmyyyy"===t?d=d.replace(/(\d{1,2})[\/\s](\d{1,2})[\/\s](\d{4})/,"$3/$2/$1"):"yyyymmdd"===t&&(d=d.replace(/(\d{4})[\/\s](\d{1,2})[\/\s](\d{1,2})/,"$1/$2/$3"));return j.formatFloat((new Date(d)).getTime()||"",g)},type:"numeric"});j.addParser({id:"time",is:function(d){return/^(([0-2]?\d:[0-5]\d)|([0-1]?\d:[0-5]\d\s?([AP]M)))$/i.test(d)},format:function(d,g){return j.formatFloat((new Date("2000/01/01 "+d.replace(/(\S)([AP]M)$/i,"$1 $2"))).getTime()||"",g)},type:"numeric"});j.addParser({id:"digit", is:function(d){return j.isDigit(d)},format:function(d,g){return j.formatFloat(d.replace(/[^\w,. \-()]/g,""),g)},type:"numeric"});j.addParser({id:"metadata",is:function(){return!1},format:function(d,j,p){d=j.config;d=!d.parserMetadataName?"sortValue":d.parserMetadataName;return g(p).metadata()[d]},type:"numeric"});j.addWidget({id:"zebra",format:function(d,v,p){var u,q,t,C,E,D,F=RegExp(v.cssChildRow,"i"),e=g(d).children("tbody:not(."+v.cssInfoBlock+")");v.debug&&(E=new Date);for(d=0;d<e.length;d++)u= g(e[d]),D=u.children("tr").length,1<D&&(t=0,u=u.children("tr:visible"),u.each(function(){q=g(this);F.test(this.className)||t++;C=0===t%2;q.removeClass(p.zebra[C?1:0]).addClass(p.zebra[C?0:1])}));v.debug&&j.benchmark("Applying Zebra widget",E)},remove:function(d,j){var p,u,q=g(d).children("tbody:not(."+j.cssInfoBlock+")"),t=(j.widgetOptions.zebra||["even","odd"]).join(" ");for(p=0;p<q.length;p++)u=g.tablesorter.processTbody(d,g(q[p]),!0),u.children().removeClass(t),g.tablesorter.processTbody(d,u,!1)}})}(jQuery);
@@ -1,4 +1,4 @@
1
- /*! tableSorter 2.4+ widgets - updated 11/22/2012
1
+ /*! tableSorter 2.4+ widgets - updated 12/18/2012
2
2
  *
3
3
  * Column Styles
4
4
  * Column Filters
@@ -16,30 +16,34 @@ $.tablesorter = $.tablesorter || {};
16
16
 
17
17
  $.tablesorter.themes = {
18
18
  "bootstrap" : {
19
- table : 'table table-bordered table-striped',
20
- header : 'bootstrap-header', // give the header a gradient background
21
- icons : '', // add "icon-white" to make them white; this icon class is added to the <i> in the header
22
- sortNone : 'bootstrap-icon-unsorted',
23
- sortAsc : 'icon-chevron-up',
24
- sortDesc : 'icon-chevron-down',
25
- active : '', // applied when column is sorted
26
- hover : '', // use custom css here - bootstrap class may not override it
27
- filterRow: '', // filter row class
28
- even : '', // even row zebra striping
29
- odd : '' // odd row zebra striping
19
+ table : 'table table-bordered table-striped',
20
+ header : 'bootstrap-header', // give the header a gradient background
21
+ footerRow : '',
22
+ footerCells: '',
23
+ icons : '', // add "icon-white" to make them white; this icon class is added to the <i> in the header
24
+ sortNone : 'bootstrap-icon-unsorted',
25
+ sortAsc : 'icon-chevron-up',
26
+ sortDesc : 'icon-chevron-down',
27
+ active : '', // applied when column is sorted
28
+ hover : '', // use custom css here - bootstrap class may not override it
29
+ filterRow : '', // filter row class
30
+ even : '', // even row zebra striping
31
+ odd : '' // odd row zebra striping
30
32
  },
31
33
  "jui" : {
32
- table : 'ui-widget ui-widget-content ui-corner-all', // table classes
33
- header : 'ui-widget-header ui-corner-all ui-state-default', // header classes
34
- icons : 'ui-icon', // icon class added to the <i> in the header
35
- sortNone : 'ui-icon-carat-2-n-s',
36
- sortAsc : 'ui-icon-carat-1-n',
37
- sortDesc : 'ui-icon-carat-1-s',
38
- active : 'ui-state-active', // applied when column is sorted
39
- hover : 'ui-state-hover', // hover class
40
- filterRow: '',
41
- even : 'ui-widget-content', // even row zebra striping
42
- odd : 'ui-state-default' // odd row zebra striping
34
+ table : 'ui-widget ui-widget-content ui-corner-all', // table classes
35
+ header : 'ui-widget-header ui-corner-all ui-state-default', // header classes
36
+ footerRow : '',
37
+ footerCells: '',
38
+ icons : 'ui-icon', // icon class added to the <i> in the header
39
+ sortNone : 'ui-icon-carat-2-n-s',
40
+ sortAsc : 'ui-icon-carat-1-n',
41
+ sortDesc : 'ui-icon-carat-1-s',
42
+ active : 'ui-state-active', // applied when column is sorted
43
+ hover : 'ui-state-hover', // hover class
44
+ filterRow : '',
45
+ even : 'ui-widget-content', // even row zebra striping
46
+ odd : 'ui-state-default' // odd row zebra striping
43
47
  }
44
48
  };
45
49
 
@@ -124,10 +128,16 @@ $.tablesorter.addWidget({
124
128
  if (o.even !== '') { wo.zebra[0] += ' ' + o.even; }
125
129
  if (o.odd !== '') { wo.zebra[1] += ' ' + o.odd; }
126
130
  // add table/footer class names
127
- $t
131
+ t = $t
128
132
  // remove other selected themes; use widgetOptions.theme_remove
129
133
  .removeClass( c.theme === '' ? '' : 'tablesorter-' + c.theme )
130
- .addClass('tablesorter-' + theme + ' ' + o.table); // add theme widget class name
134
+ .addClass('tablesorter-' + theme + ' ' + o.table) // add theme widget class name
135
+ .find('tfoot');
136
+ if (t.length) {
137
+ t
138
+ .find('tr').addClass(o.footerRow)
139
+ .children('th, td').addClass(o.footerCells);
140
+ }
131
141
  c.theme = ''; // clear out theme option so it doesn't interfere
132
142
  // update header classes
133
143
  $h
@@ -282,6 +292,7 @@ $.tablesorter.addWidget({
282
292
  filter_searchDelay : 300 // typing delay in milliseconds before starting a search
283
293
  filter_startsWith : false // if true, filter start from the beginning of the cell contents
284
294
  filter_useParsedData : false // filter all data using parsed content
295
+ filter_serversideFiltering : false // if true, server-side filtering should be performed because client-side filtering will be disabled, but the ui and events will still be used.
285
296
  **************************/
286
297
  $.tablesorter.addWidget({
287
298
  id: "filter",
@@ -353,7 +364,7 @@ $.tablesorter.addWidget({
353
364
  $tb = $.tablesorter.processTbody(table, $(b[k]), true);
354
365
  $tr = $tb.children('tr');
355
366
  l = $tr.length;
356
- if (cv === ''){
367
+ if (cv === '' || wo.filter_serversideFiltering){
357
368
  $tr.show().removeClass('filtered');
358
369
  } else {
359
370
  // loop through the rows
@@ -1,12 +1,12 @@
1
- /*! tableSorter 2.4+ widgets - updated 11/22/2012 */
2
- ;(function(a){
3
- a.tablesorter=a.tablesorter||{};
4
- a.tablesorter.themes={bootstrap:{table:"table table-bordered table-striped",header:"bootstrap-header",icons:"",sortNone:"bootstrap-icon-unsorted",sortAsc:"icon-chevron-up",sortDesc:"icon-chevron-down",active:"",hover:"",filterRow:"",even:"",odd:""},jui:{table:"ui-widget ui-widget-content ui-corner-all",header:"ui-widget-header ui-corner-all ui-state-default",icons:"ui-icon",sortNone:"ui-icon-carat-2-n-s",sortAsc:"ui-icon-carat-1-n",sortDesc:"ui-icon-carat-1-s", active:"ui-state-active",hover:"ui-state-hover",filterRow:"",even:"ui-widget-content",odd:"ui-state-default"}};
5
- a.tablesorter.storage=function(e,c,d){var b,i=!1;b={};var f=e.id||a(".tablesorter").index(a(e)),g=window.location.pathname;try{i=!!localStorage.getItem}catch(n){}a.parseJSON&&(i?b=a.parseJSON(localStorage[c])||{}:(b=document.cookie.split(/[;\s|=]/),e=a.inArray(c,b)+1,b=0!==e?a.parseJSON(b[e])||{}:{}));if(d&&JSON&&JSON.hasOwnProperty("stringify")){if(!b[g]||!b[g][f])b[g]||(b[g]={});b[g][f]= d;i?localStorage[c]=JSON.stringify(b):(e=new Date,e.setTime(e.getTime()+31536E6),document.cookie=c+"="+JSON.stringify(b).replace(/\"/g,'"')+"; expires="+e.toGMTString()+"; path=/")}else return b&&b.hasOwnProperty(g)&&b[g].hasOwnProperty(f)?b[g][f]:{}};
6
- a.tablesorter.addWidget({id:"uitheme",format:function(e){var c,d,b,i,f=a(e),g=e.config,n=g.widgetOptions,m="object"===typeof n.uitheme?"jui":n.uitheme||"jui",h="object"===typeof n.uitheme&&!Object.prototype.toString.call(n.uitheme).test("Array")?n.uitheme: a.tablesorter.themes[a.tablesorter.themes.hasOwnProperty(m)?m:"jui"],l=a(g.headerList),q="tr."+(n.stickyHeaders||"tablesorter-stickyHeader"),p=h.sortNone+" "+h.sortDesc+" "+h.sortAsc;g.debug&&(c=new Date);if(!f.hasClass("tablesorter-"+m)||g.theme===m||!e.hasInitialized)""!==h.even&&(n.zebra[0]+=" "+h.even),""!==h.odd&&(n.zebra[1]+=" "+h.odd),f.removeClass(""===g.theme?"":"tablesorter-"+g.theme).addClass("tablesorter-"+m+" "+h.table),g.theme="",l.addClass(h.header).filter(":not(.sorter-false)").hover(function(){a(this).addClass(h.hover)}, function(){a(this).removeClass(h.hover)}),l.find(".tablesorter-wrapper").length||l.wrapInner('<div class="tablesorter-wrapper" style="position:relative;height:100%;width:100%"></div>'),g.cssIcon&&l.find("."+g.cssIcon).addClass(h.icons),f.hasClass("hasFilters")&&l.find(".tablesorter-filter-row").addClass(h.filterRow);a.each(l,function(c){b=a(this);i=g.cssIcon?b.find("."+g.cssIcon):b;this.sortDisabled?(b.removeClass(p),i.removeClass(p+" tablesorter-icon "+h.icons)):(f.hasClass("hasStickyHeaders")&& f.find(q).find("th").eq(c).add(b),d=b.hasClass(g.cssAsc)?h.sortAsc:b.hasClass(g.cssDesc)?h.sortDesc:b.hasClass(g.cssHeader)?h.sortNone:"",b[d===h.sortNone?"removeClass":"addClass"](h.active),i.removeClass(p).addClass(d))});g.debug&&a.tablesorter.benchmark("Applying "+m+" theme",c)},remove:function(e,c,d){var e=a(e),b="object"===typeof d.uitheme?"jui":d.uitheme||"jui",d="object"===typeof d.uitheme?d.uitheme:a.tablesorter.themes[a.tablesorter.themes.hasOwnProperty(b)?b:"jui"],i=e.children("thead").children(), f=d.sortNone+" "+d.sortDesc+" "+d.sortAsc;e.removeClass("tablesorter-"+b+" "+d.table).find(c.cssHeader).removeClass(d.header);i.unbind("mouseenter mouseleave").removeClass(d.hover+" "+f+" "+d.active).find(".tablesorter-filter-row").removeClass(d.filterRow);i.find(".tablesorter-icon").removeClass(d.icons)}});
7
- a.tablesorter.addWidget({id:"columns",format:function(e){var c,d,b,i,f,g,n,m,h,l=a(e),q=e.config,p=q.widgetOptions,s=l.children("tbody:not(."+q.cssInfoBlock+")"),u=q.sortList,v=u.length,k=["primary", "secondary","tertiary"],k=q.widgetColumns&&q.widgetColumns.hasOwnProperty("css")?q.widgetColumns.css||k:p&&p.hasOwnProperty("columns")?p.columns||k:k;g=k.length-1;n=k.join(" ");q.debug&&(f=new Date);for(h=0;h<s.length;h++)c=a.tablesorter.processTbody(e,a(s[h]),!0),d=c.children("tr"),d.each(function(){i=a(this);if("none"!==this.style.display&&(b=i.children().removeClass(n),u&&u[0]&&(b.eq(u[0][0]).addClass(k[0]),1<v)))for(m=1;m<v;m++)b.eq(u[m][0]).addClass(k[m]||k[g])}),a.tablesorter.processTbody(e, c,!1);d=!1!==p.columns_thead?"thead tr":"";!1!==p.columns_tfoot&&(d+=(""===d?"":",")+"tfoot tr");if(d.length&&(i=l.find(d).children().removeClass(n),u&&u[0]&&(i.filter('[data-column="'+u[0][0]+'"]').addClass(k[0]),1<v)))for(m=1;m<v;m++)i.filter('[data-column="'+u[m][0]+'"]').addClass(k[m]||k[g]);q.debug&&a.tablesorter.benchmark("Applying Columns widget",f)},remove:function(e,c){var d,b,i=a(e).children("tbody:not(."+c.cssInfoBlock+")"),f=(c.widgetOptions.columns||["primary","secondary","tertiary"]).join(" "); for(d=0;d<i.length;d++)b=a.tablesorter.processTbody(e,a(i[d]),!0),b.children("tr").each(function(){a(this).children().removeClass(f)}),a.tablesorter.processTbody(e,b,!1)}});
8
- a.tablesorter.addWidget({id:"filter",format:function(e){if(e.config.parsers&&!a(e).hasClass("hasFilters")){var c,d,b,i,f,g,n,m,h,l,q,p,s,u,v,k,x,F="",z=a.tablesorter,r=e.config,A=a(r.headerList),j=r.widgetOptions,y=j.filter_cssFilter||"tablesorter-filter",t=a(e).addClass("hasFilters"),D=t.children("tbody:not(."+r.cssInfoBlock+ ")"),E=r.parsers.length,B=[/^\/((?:\\\/|[^\/])+)\/([mig]{0,3})?$/,RegExp(r.cssChildRow),/undefined|number/,/(^[\"|\'|=])|([\"|\'|=]$)/,/[\"\'=]/g,/[^\w,. \-()]/g,/[<>=]/g],L=A.map(function(b){return z.getData?"parsed"===z.getData(A.filter('[data-column="'+b+'"]:last'),r.headers[b],"filter"):a(this).hasClass("filter-parsed")}).get(),G,H,C=function(b){var c=a.isArray(b),e=t.find("thead").eq(0).children("tr").find("select."+y+", input."+y),d=c?b:e.map(function(){return a(this).val()||""}).get(),f=(d|| []).join("");c&&e.each(function(c,d){a(d).val(b[c]||"")});!0===j.filter_hideFilters&&t.find(".tablesorter-filter-row").trigger(""===f?"mouseleave":"mouseenter");if(!(F===f&&!1!==b))if(t.trigger("filterStart",[d]),r.showProcessing)setTimeout(function(){I(b,d,f);return!1},30);else return I(b,d,f),!1},I=function(g,i,h){var l,q,s,p,x,w,y;r.debug&&(y=new Date);for(b=0;b<D.length;b++){g=a.tablesorter.processTbody(e,a(D[b]),!0);l=g.children("tr");x=l.length;if(""===h)l.show().removeClass("filtered");else for(d= 0;d<x;d++)if(!B[1].test(l[d].className)){p=!0;s=l.eq(d).nextUntil("tr:not(."+r.cssChildRow+")");k=s.length&&(j&&j.hasOwnProperty("filter_childRows")&&"undefined"!==typeof j.filter_childRows?j.filter_childRows:1)?s.text():"";k=j.filter_ignoreCase?k.toLocaleLowerCase():k;q=l.eq(d).children("td");for(c=0;c<E;c++)if(i[c]){n=j.filter_useParsedData||L[c]?r.cache[b].normalized[d][c]:a.trim(q.eq(c).text());m=!B[2].test(typeof n)&&j.filter_ignoreCase?n.toLocaleLowerCase():n;w=p;f=j.filter_ignoreCase?i[c].toLocaleLowerCase(): i[c];if(j.filter_functions&&j.filter_functions[c])!0===j.filter_functions[c]?w=A.filter('[data-column="'+c+'"]:last').hasClass("filter-match")?0<=m.search(f):i[c]===n:"function"===typeof j.filter_functions[c]?w=j.filter_functions[c](n,r.cache[b].normalized[d][c],i[c],c):"function"===typeof j.filter_functions[c][i[c]]&&(w=j.filter_functions[c][i[c]](n,r.cache[b].normalized[d][c],i[c],c));else if(B[0].test(f)){u=B[0].exec(f);try{w=RegExp(u[1],u[2]).test(m)}catch(C){w=!1}}else B[3].test(f)&&m===f.replace(B[4], "")?w=!0:/^\!/.test(f)?(f=f.replace("!",""),v=m.search(a.trim(f)),w=""===f?!0:!(j.filter_startsWith?0===v:0<=v)):/^[<>]=?/.test(f)?(u=isNaN(m)?a.tablesorter.formatFloat(m.replace(B[5],""),e):a.tablesorter.formatFloat(m,e),v=a.tablesorter.formatFloat(f.replace(B[5],"").replace(B[6],""),e),/>/.test(f)&&(w=/>=/.test(f)?u>=v:u>v),/</.test(f)&&(w=/<=/.test(f)?u<=v:u<v)):/[\?|\*]/.test(f)?w=RegExp(f.replace(/\?/g,"\\S{1}").replace(/\*/g,"\\S*")).test(m):(n=(m+k).indexOf(f),w=!j.filter_startsWith&&0<=n|| j.filter_startsWith&&0===n);p=w?p?!0:!1:!1}l[d].style.display=p?"":"none";l.eq(d)[p?"removeClass":"addClass"]("filtered");if(s.length)s[p?"show":"hide"]()}a.tablesorter.processTbody(e,g,!1)}F=h;r.debug&&z.benchmark("Completed filter widget search",y);t.trigger("applyWidgets");t.trigger("filterEnd")},J=function(c,f){var g,h=[],c=parseInt(c,10);g='<option value="">'+(A.filter('[data-column="'+c+'"]:last').attr("data-placeholder")||"")+"</option>";for(b=0;b<D.length;b++){i=r.cache[b].row.length;for(d= 0;d<i;d++)j.filter_useParsedData?h.push(""+r.cache[b].normalized[d][c]):(k=r.cache[b].row[d][0].cells[c])&&h.push(a.trim(r.supportsTextContent?k.textContent:a(k).text()))}h=a.grep(h,function(c,b){return a.inArray(c,h)===b});h=z.sortText?h.sort(function(a,b){return z.sortText(e,a,b,c)}):h.sort(!0);for(b=0;b<h.length;b++)g+='<option value="'+h[b]+'">'+h[b]+"</option>";t.find("thead").find("select."+y+'[data-column="'+c+'"]')[f?"html":"append"](g)},K=function(a){for(c=0;c<E;c++)k=A.filter('[data-column="'+ c+'"]:last'),k.hasClass("filter-select")&&(!k.hasClass("filter-false")&&!(j.filter_functions&&!0===j.filter_functions[c]))&&(j.filter_functions||(j.filter_functions={}),j.filter_functions[c]=!0,J(c,a))};r.debug&&(G=new Date);j.filter_ignoreCase=!1!==j.filter_ignoreCase;j.filter_useParsedData=!0===j.filter_useParsedData;if(!1!==j.filter_columnFilters&&A.filter(".filter-false").length!==A.length){k='<tr class="tablesorter-filter-row">';for(c=0;c<E;c++)s=!1,s=A.filter('[data-column="'+c+'"]:last'),g= j.filter_functions&&j.filter_functions[c]&&"function"!==typeof j.filter_functions[c]||s.hasClass("filter-select"),k+="<td>",k=g?k+('<select data-column="'+c+'" class="'+y):k+('<input type="search" placeholder="'+(s.attr("data-placeholder")||"")+'" data-column="'+c+'" class="'+y),s=z.getData?"false"===z.getData(s[0],r.headers[c],"filter"):r.headers[c]&&r.headers[c].hasOwnProperty("filter")&&!1===r.headers[c].filter||s.hasClass("filter-false"),k+=s?' disabled" disabled':'"',k+=(g?"></select>":">")+ "</td>";t.find("thead").eq(0).append(k+="</tr>")}t.bind(["addRows","updateCell","update","appendCache","search"].join(".tsfilter "),function(a,b){"search"!==a.type&&K(!0);C("search"===a.type?b:"");return!1}).find("input."+y).bind("keyup search",function(a,b){if(!(32>a.which&&8!==a.which||37<=a.which&&40>=a.which)){if("undefined"!==typeof b)return C(b),!1;clearTimeout(H);H=setTimeout(function(){C()},j.filter_searchDelay||300)}});j.filter_reset&&a(j.filter_reset).length&&a(j.filter_reset).bind("click", function(){t.find("."+y).val("");C();return!1});if(j.filter_functions)for(x in j.filter_functions)if(j.filter_functions.hasOwnProperty(x)&&"string"===typeof x)if(k=A.filter('[data-column="'+x+'"]:last'),g="",!0===j.filter_functions[x]&&!k.hasClass("filter-false"))J(x);else if("string"===typeof x&&!k.hasClass("filter-false")){for(l in j.filter_functions[x])"string"===typeof l&&(g+=""===g?'<option value="">'+(k.attr("data-placeholder")||"")+"</option>":"",g+='<option value="'+l+'">'+l+"</option>"); t.find("thead").find("select."+y+'[data-column="'+x+'"]').append(g)}K();t.find("select."+y).bind("change search",function(){C()});!0===j.filter_hideFilters&&t.find(".tablesorter-filter-row").addClass("hideme").bind("mouseenter mouseleave",function(b){var c;q=a(this);clearTimeout(h);h=setTimeout(function(){/enter|over/.test(b.type)?q.removeClass("hideme"):a(document.activeElement).closest("tr")[0]!==q[0]&&(c=t.find("."+(j.filter_cssFilter||"tablesorter-filter")).map(function(){return a(this).val()|| ""}).get().join(""),""===c&&q.addClass("hideme"))},200)}).find("input, select").bind("focus blur",function(b){p=a(this).closest("tr");clearTimeout(h);h=setTimeout(function(){if(""===t.find("."+(j.filter_cssFilter||"tablesorter-filter")).map(function(){return a(this).val()||""}).get().join(""))p["focus"===b.type?"removeClass":"addClass"]("hideme")},200)});r.showProcessing&&t.bind("filterStart filterEnd",function(b,c){var d=c?t.find("."+r.cssHeader).filter("[data-column]").filter(function(){return""!== c[a(this).data("column")]}):"";z.isProcessing(t[0],"filterStart"===b.type,c?d:"")});r.debug&&z.benchmark("Applying Filter widget",G);t.trigger("filterInit")}},remove:function(e,c,d){var b,i;b=a(e);c=b.children("tbody:not(."+c.cssInfoBlock+")");b.removeClass("hasFilters").unbind(["addRows","updateCell","update","appendCache","search"].join(".tsfilter")).find(".tablesorter-filter-row").remove();for(b=0;b<c.length;b++)i=a.tablesorter.processTbody(e,a(c[b]),!0),i.children().removeClass("filtered").show(), a.tablesorter.processTbody(e,i,!1);d.filterreset&&a(d.filter_reset).unbind("click")}});
9
- a.tablesorter.addWidget({id:"stickyHeaders",format:function(e){if(!a(e).hasClass("hasStickyHeaders")){var c=a(e).addClass("hasStickyHeaders"),d=e.config,b=d.widgetOptions,i=a(window),f=a(e).children("thead:first"),g=f.children("tr:not(.sticky-false)").children(),e=b.stickyHeaders||"tablesorter-stickyHeader",n=g.eq(0).parent(),m=c.find("tfoot"),b=c.clone(),h=b.children("thead:first").addClass(e).css({width:f.outerWidth(!0), position:"fixed",margin:0,top:0,visibility:"hidden",zIndex:1}),l=h.children("tr:not(.sticky-false)").children(),q="",p=0,s=function(){var b=navigator.userAgent;p=0;"collapse"!==c.css("border-collapse")&&!/(webkit|msie)/i.test(b)&&(p=2*parseInt(g.eq(0).css("border-left-width"),10));h.css({left:f.offset().left-i.scrollLeft()-p,width:f.outerWidth()});l.each(function(b){b=g.eq(b);a(this).css({width:b.width()-p,height:b.height()})}).find(".tablesorter-header-inner").each(function(b){b=g.eq(b).find(".tablesorter-header-inner").width(); a(this).width(b)})};b.find("thead:gt(0),tr.sticky-false,tbody,tfoot,caption").remove();b.css({height:0,width:0,padding:0,margin:0,border:0});h.find("tr.sticky-false").remove();l.find(".tablesorter-resizer").remove();c.bind("sortEnd.tsSticky",function(){g.each(function(b){b=l.eq(b);b.attr("class",a(this).attr("class"));d.cssIcon&&b.find("."+d.cssIcon).attr("class",a(this).find("."+d.cssIcon).attr("class"))})}).bind("pagerComplete.tsSticky",function(){s()});g.find("*").andSelf().filter(d.selectorSort).each(function(b){var c= a(this);l.eq(b).bind("mouseup",function(a){c.trigger(a,!0)}).bind("mousedown",function(){this.onselectstart=function(){return!1};return!1})});c.after(b);i.bind("scroll.tsSticky",function(){var a=n.offset(),b=i.scrollTop(),d=c.height()-(h.height()+(m.height()||0)),a=b>a.top&&b<a.top+d?"visible":"hidden";h.css({left:f.offset().left-i.scrollLeft()-p,visibility:a});a!==q&&(s(),q=a)}).bind("resize.tsSticky",function(){s()})}},remove:function(e,c,d){e=a(e);d=d.stickyHeaders||"tablesorter-stickyHeader"; e.removeClass("hasStickyHeaders").unbind("sortEnd.tsSticky pagerComplete.tsSticky").find("."+d).remove();a(window).unbind("scroll.tsSticky resize.tsSticky")}});
10
- a.tablesorter.addWidget({id:"resizable",format:function(e){if(!a(e).hasClass("hasResizable")){a(e).addClass("hasResizable");var c,d,b,i,f,g=a(e),n=e.config,m=n.widgetOptions,h=0,l=null,q=null,p=function(){h=0;l=q=null;a(window).trigger("resize")};if(b=a.tablesorter.storage&&!1!==m.resizable?a.tablesorter.storage(e,"tablesorter-resizable"): {})for(d in b)!isNaN(d)&&d<n.headerList.length&&a(n.headerList[d]).width(b[d]);g.children("thead:first").find("tr").each(function(){i=a(this).children();a(this).find(".tablesorter-wrapper").length||i.wrapInner('<div class="tablesorter-wrapper" style="position:relative;height:100%;width:100%"></div>');i=i.slice(0,-1);f=f?f.add(i):i});f.each(function(){c=a(this);d=parseInt(c.css("padding-right"),10)+8;c.find(".tablesorter-wrapper").append('<div class="tablesorter-resizer" style="cursor:w-resize;position:absolute;height:100%;width:16px;right:-'+ d+'px;top:0;z-index:1;"></div>')}).bind("mousemove.tsresize",function(a){if(0!==h&&l){var b=a.pageX-h;l.width(l.width()+b);q.width(q.width()-b);h=a.pageX}}).bind("mouseup.tsresize",function(){a.tablesorter.storage&&l&&(b[l.index()]=l.width(),b[q.index()]=q.width(),!1!==m.resizable&&a.tablesorter.storage(e,"tablesorter-resizable",b));p()}).find(".tablesorter-resizer").bind("mousedown",function(b){l=a(b.target).parents("th:last");q=l.next();h=b.pageX});g.find("thead:first").bind("mouseup.tsresize mouseleave.tsresize", function(){p()}).bind("contextmenu.tsresize",function(){a.tablesorter.resizableReset(e);var c=a.isEmptyObject?a.isEmptyObject(b):b==={};b={};return c})}},remove:function(e){a(e).removeClass("hasResizable").find("thead").unbind("mouseup.tsresize mouseleave.tsresize contextmenu.tsresize").find("tr").children().unbind("mousemove.tsresize mouseup.tsresize").find(".tablesorter-wrapper").each(function(){a(this).find(".tablesorter-resizer").remove();a(this).replaceWith(a(this).contents())});a.tablesorter.resizableReset(e)}}); a.tablesorter.resizableReset=function(e){a(e.config.headerList).width("auto");a.tablesorter.storage(e,"tablesorter-resizable",{})};
11
- a.tablesorter.addWidget({id:"saveSort",init:function(a,c){c.format(a,!0)},format:function(e,c){var d,b,i=e.config;d=!1!==i.widgetOptions.saveSort;var f={sortList:i.sortList};i.debug&&(b=new Date);a(e).hasClass("hasSaveSort")?d&&(e.hasInitialized&&a.tablesorter.storage)&&(a.tablesorter.storage(e,"tablesorter-savesort",f),i.debug&&a.tablesorter.benchmark("saveSort widget: Saving last sort: "+ i.sortList,b)):(a(e).addClass("hasSaveSort"),f="",a.tablesorter.storage&&(f=(d=a.tablesorter.storage(e,"tablesorter-savesort"))&&d.hasOwnProperty("sortList")&&a.isArray(d.sortList)?d.sortList:"",i.debug&&a.tablesorter.benchmark('saveSort: Last sort loaded: "'+f+'"',b)),c&&f&&0<f.length?i.sortList=f:e.hasInitialized&&(f&&0<f.length)&&a(e).trigger("sorton",[f]))},remove:function(e){a.tablesorter.storage(e,"tablesorter-savesort","")}})
1
+ /*! tableSorter 2.4+ widgets - updated 12/19/2012 */
2
+ ;(function(b){
3
+ b.tablesorter=b.tablesorter||{};
4
+ b.tablesorter.themes={bootstrap:{table:"table table-bordered table-striped",header:"bootstrap-header",footerRow:"",footerCells:"",icons:"",sortNone:"bootstrap-icon-unsorted",sortAsc:"icon-chevron-up",sortDesc:"icon-chevron-down",active:"",hover:"",filterRow:"",even:"",odd:""},jui:{table:"ui-widget ui-widget-content ui-corner-all",header:"ui-widget-header ui-corner-all ui-state-default",footerRow:"",footerCells:"",icons:"ui-icon",sortNone:"ui-icon-carat-2-n-s", sortAsc:"ui-icon-carat-1-n",sortDesc:"ui-icon-carat-1-s",active:"ui-state-active",hover:"ui-state-hover",filterRow:"",even:"ui-widget-content",odd:"ui-state-default"}};
5
+ b.tablesorter.storage=function(e,c,d){var a,j=!1;a={};var f=e.id||b(".tablesorter").index(b(e)),h=window.location.pathname;try{j=!!localStorage.getItem}catch(n){}b.parseJSON&&(j?a=b.parseJSON(localStorage[c])||{}:(a=document.cookie.split(/[;\s|=]/),e=b.inArray(c,a)+1,a=0!==e?b.parseJSON(a[e])||{}:{}));if(d&&JSON&&JSON.hasOwnProperty("stringify")){if(!a[h]|| !a[h][f])a[h]||(a[h]={});a[h][f]=d;j?localStorage[c]=JSON.stringify(a):(e=new Date,e.setTime(e.getTime()+31536E6),document.cookie=c+"="+JSON.stringify(a).replace(/\"/g,'"')+"; expires="+e.toGMTString()+"; path=/")}else return a&&a.hasOwnProperty(h)&&a[h].hasOwnProperty(f)?a[h][f]:{}};
6
+ b.tablesorter.addWidget({id:"uitheme",format:function(e){var c,d,a,j,f,h=b(e),n=e.config,p=n.widgetOptions,q="object"===typeof p.uitheme?"jui":p.uitheme||"jui",g="object"===typeof p.uitheme&&!Object.prototype.toString.call(p.uitheme).test("Array")? p.uitheme:b.tablesorter.themes[b.tablesorter.themes.hasOwnProperty(q)?q:"jui"],m=b(n.headerList),r="tr."+(p.stickyHeaders||"tablesorter-stickyHeader"),s=g.sortNone+" "+g.sortDesc+" "+g.sortAsc;n.debug&&(c=new Date);if(!h.hasClass("tablesorter-"+q)||n.theme===q||!e.hasInitialized)""!==g.even&&(p.zebra[0]+=" "+g.even),""!==g.odd&&(p.zebra[1]+=" "+g.odd),f=h.removeClass(""===n.theme?"":"tablesorter-"+n.theme).addClass("tablesorter-"+q+" "+g.table).find("tfoot"),f.length&&f.find("tr").addClass(g.footerRow).children("th, td").addClass(g.footerCells), n.theme="",m.addClass(g.header).filter(":not(.sorter-false)").hover(function(){b(this).addClass(g.hover)},function(){b(this).removeClass(g.hover)}),m.find(".tablesorter-wrapper").length||m.wrapInner('<div class="tablesorter-wrapper" style="position:relative;height:100%;width:100%"></div>'),n.cssIcon&&m.find("."+n.cssIcon).addClass(g.icons),h.hasClass("hasFilters")&&m.find(".tablesorter-filter-row").addClass(g.filterRow);b.each(m,function(c){a=b(this);j=n.cssIcon?a.find("."+n.cssIcon):a;this.sortDisabled? (a.removeClass(s),j.removeClass(s+" tablesorter-icon "+g.icons)):(f=h.hasClass("hasStickyHeaders")?h.find(r).find("th").eq(c).add(a):a,d=a.hasClass(n.cssAsc)?g.sortAsc:a.hasClass(n.cssDesc)?g.sortDesc:a.hasClass(n.cssHeader)?g.sortNone:"",a[d===g.sortNone?"removeClass":"addClass"](g.active),j.removeClass(s).addClass(d))});n.debug&&b.tablesorter.benchmark("Applying "+q+" theme",c)},remove:function(e,c,d){e=b(e);var a="object"===typeof d.uitheme?"jui":d.uitheme||"jui";d="object"===typeof d.uitheme? d.uitheme:b.tablesorter.themes[b.tablesorter.themes.hasOwnProperty(a)?a:"jui"];var j=e.children("thead").children(),f=d.sortNone+" "+d.sortDesc+" "+d.sortAsc;e.removeClass("tablesorter-"+a+" "+d.table).find(c.cssHeader).removeClass(d.header);j.unbind("mouseenter mouseleave").removeClass(d.hover+" "+f+" "+d.active).find(".tablesorter-filter-row").removeClass(d.filterRow);j.find(".tablesorter-icon").removeClass(d.icons)}});
7
+ b.tablesorter.addWidget({id:"columns",format:function(e){var c,d,a,j,f,h,n,p, q,g=b(e),m=e.config,r=m.widgetOptions,s=g.children("tbody:not(."+m.cssInfoBlock+")"),v=m.sortList,w=v.length,l=["primary","secondary","tertiary"],l=m.widgetColumns&&m.widgetColumns.hasOwnProperty("css")?m.widgetColumns.css||l:r&&r.hasOwnProperty("columns")?r.columns||l:l;h=l.length-1;n=l.join(" ");m.debug&&(f=new Date);for(q=0;q<s.length;q++)c=b.tablesorter.processTbody(e,b(s[q]),!0),d=c.children("tr"),d.each(function(){j=b(this);if("none"!==this.style.display&&(a=j.children().removeClass(n),v&&v[0]&& (a.eq(v[0][0]).addClass(l[0]),1<w)))for(p=1;p<w;p++)a.eq(v[p][0]).addClass(l[p]||l[h])}),b.tablesorter.processTbody(e,c,!1);d=!1!==r.columns_thead?"thead tr":"";!1!==r.columns_tfoot&&(d+=(""===d?"":",")+"tfoot tr");if(d.length&&(j=g.find(d).children().removeClass(n),v&&v[0]&&(j.filter('[data-column="'+v[0][0]+'"]').addClass(l[0]),1<w)))for(p=1;p<w;p++)j.filter('[data-column="'+v[p][0]+'"]').addClass(l[p]||l[h]);m.debug&&b.tablesorter.benchmark("Applying Columns widget",f)},remove:function(e,c){var d, a,j=b(e).children("tbody:not(."+c.cssInfoBlock+")"),f=(c.widgetOptions.columns||["primary","secondary","tertiary"]).join(" ");for(d=0;d<j.length;d++)a=b.tablesorter.processTbody(e,b(j[d]),!0),a.children("tr").each(function(){b(this).children().removeClass(f)}),b.tablesorter.processTbody(e,a,!1)}});
8
+ b.tablesorter.addWidget({id:"filter",format:function(e){if(e.config.parsers&&!b(e).hasClass("hasFilters")){var c,d,a,j,f,h,n,p,q,g,m,r,s,v,w,l,y,G="",A=b.tablesorter,t=e.config,B=b(t.headerList),k=t.widgetOptions, z=k.filter_cssFilter||"tablesorter-filter",u=b(e).addClass("hasFilters"),E=u.children("tbody:not(."+t.cssInfoBlock+")"),F=t.parsers.length,C=[/^\/((?:\\\/|[^\/])+)\/([mig]{0,3})?$/,RegExp(t.cssChildRow),/undefined|number/,/(^[\"|\'|=])|([\"|\'|=]$)/,/[\"\'=]/g,/[^\w,. \-()]/g,/[<>=]/g],M=B.map(function(a){return A.getData?"parsed"===A.getData(B.filter('[data-column="'+a+'"]:last'),t.headers[a],"filter"):b(this).hasClass("filter-parsed")}).get(),H,I,D=function(a){var c=b.isArray(a),e=u.find("thead").eq(0).children("tr").find("select."+ z+", input."+z),d=c?a:e.map(function(){return b(this).val()||""}).get(),f=(d||[]).join("");c&&e.each(function(c,d){b(d).val(a[c]||"")});!0===k.filter_hideFilters&&u.find(".tablesorter-filter-row").trigger(""===f?"mouseleave":"mouseenter");if(!(G===f&&!1!==a))if(u.trigger("filterStart",[d]),t.showProcessing)setTimeout(function(){J(a,d,f);return!1},30);else return J(a,d,f),!1},J=function(j,g,h){var m,q,s,r,y,x,z;t.debug&&(z=new Date);for(a=0;a<E.length;a++){j=b.tablesorter.processTbody(e,b(E[a]),!0); m=j.children("tr");y=m.length;if(""===h||k.filter_serversideFiltering)m.show().removeClass("filtered");else for(d=0;d<y;d++)if(!C[1].test(m[d].className)){r=!0;s=m.eq(d).nextUntil("tr:not(."+t.cssChildRow+")");l=s.length&&(k&&k.hasOwnProperty("filter_childRows")&&"undefined"!==typeof k.filter_childRows?k.filter_childRows:1)?s.text():"";l=k.filter_ignoreCase?l.toLocaleLowerCase():l;q=m.eq(d).children("td");for(c=0;c<F;c++)if(g[c]){n=k.filter_useParsedData||M[c]?t.cache[a].normalized[d][c]:b.trim(q.eq(c).text()); p=!C[2].test(typeof n)&&k.filter_ignoreCase?n.toLocaleLowerCase():n;x=r;f=k.filter_ignoreCase?g[c].toLocaleLowerCase():g[c];if(k.filter_functions&&k.filter_functions[c])!0===k.filter_functions[c]?x=B.filter('[data-column="'+c+'"]:last').hasClass("filter-match")?0<=p.search(f):g[c]===n:"function"===typeof k.filter_functions[c]?x=k.filter_functions[c](n,t.cache[a].normalized[d][c],g[c],c):"function"===typeof k.filter_functions[c][g[c]]&&(x=k.filter_functions[c][g[c]](n,t.cache[a].normalized[d][c],g[c], c));else if(C[0].test(f)){v=C[0].exec(f);try{x=RegExp(v[1],v[2]).test(p)}catch(D){x=!1}}else C[3].test(f)&&p===f.replace(C[4],"")?x=!0:/^\!/.test(f)?(f=f.replace("!",""),w=p.search(b.trim(f)),x=""===f?!0:!(k.filter_startsWith?0===w:0<=w)):/^[<>]=?/.test(f)?(v=isNaN(p)?b.tablesorter.formatFloat(p.replace(C[5],""),e):b.tablesorter.formatFloat(p,e),w=b.tablesorter.formatFloat(f.replace(C[5],"").replace(C[6],""),e),/>/.test(f)&&(x=/>=/.test(f)?v>=w:v>w),/</.test(f)&&(x=/<=/.test(f)?v<=w:v<w)):/[\?|\*]/.test(f)? x=RegExp(f.replace(/\?/g,"\\S{1}").replace(/\*/g,"\\S*")).test(p):(n=(p+l).indexOf(f),x=!k.filter_startsWith&&0<=n||k.filter_startsWith&&0===n);r=x?r?!0:!1:!1}m[d].style.display=r?"":"none";m.eq(d)[r?"removeClass":"addClass"]("filtered");if(s.length)s[r?"show":"hide"]()}b.tablesorter.processTbody(e,j,!1)}G=h;t.debug&&A.benchmark("Completed filter widget search",z);u.trigger("applyWidgets");u.trigger("filterEnd")},K=function(c,f){var g,h=[];c=parseInt(c,10);g='<option value="">'+(B.filter('[data-column="'+ c+'"]:last').attr("data-placeholder")||"")+"</option>";for(a=0;a<E.length;a++){j=t.cache[a].row.length;for(d=0;d<j;d++)k.filter_useParsedData?h.push(""+t.cache[a].normalized[d][c]):(l=t.cache[a].row[d][0].cells[c])&&h.push(b.trim(t.supportsTextContent?l.textContent:b(l).text()))}h=b.grep(h,function(a,c){return b.inArray(a,h)===c});h=A.sortText?h.sort(function(b,a){return A.sortText(e,b,a,c)}):h.sort(!0);for(a=0;a<h.length;a++)g+='<option value="'+h[a]+'">'+h[a]+"</option>";u.find("thead").find("select."+ z+'[data-column="'+c+'"]')[f?"html":"append"](g)},L=function(b){for(c=0;c<F;c++)l=B.filter('[data-column="'+c+'"]:last'),l.hasClass("filter-select")&&(!l.hasClass("filter-false")&&!(k.filter_functions&&!0===k.filter_functions[c]))&&(k.filter_functions||(k.filter_functions={}),k.filter_functions[c]=!0,K(c,b))};t.debug&&(H=new Date);k.filter_ignoreCase=!1!==k.filter_ignoreCase;k.filter_useParsedData=!0===k.filter_useParsedData;if(!1!==k.filter_columnFilters&&B.filter(".filter-false").length!==B.length){l= '<tr class="tablesorter-filter-row">';for(c=0;c<F;c++)s=!1,s=B.filter('[data-column="'+c+'"]:last'),h=k.filter_functions&&k.filter_functions[c]&&"function"!==typeof k.filter_functions[c]||s.hasClass("filter-select"),l+="<td>",l=h?l+('<select data-column="'+c+'" class="'+z):l+('<input type="search" placeholder="'+(s.attr("data-placeholder")||"")+'" data-column="'+c+'" class="'+z),s=A.getData?"false"===A.getData(s[0],t.headers[c],"filter"):t.headers[c]&&t.headers[c].hasOwnProperty("filter")&&!1===t.headers[c].filter|| s.hasClass("filter-false"),l+=s?' disabled" disabled':'"',l+=(h?"></select>":">")+"</td>";u.find("thead").eq(0).append(l+="</tr>")}u.bind(["addRows","updateCell","update","appendCache","search"].join(".tsfilter "),function(b,a){"search"!==b.type&&L(!0);D("search"===b.type?a:"");return!1}).find("input."+z).bind("keyup search",function(b,a){if(!(32>b.which&&8!==b.which||37<=b.which&&40>=b.which)){if("undefined"!==typeof a)return D(a),!1;clearTimeout(I);I=setTimeout(function(){D()},k.filter_searchDelay|| 300)}});k.filter_reset&&b(k.filter_reset).length&&b(k.filter_reset).bind("click",function(){u.find("."+z).val("");D();return!1});if(k.filter_functions)for(y in k.filter_functions)if(k.filter_functions.hasOwnProperty(y)&&"string"===typeof y)if(l=B.filter('[data-column="'+y+'"]:last'),h="",!0===k.filter_functions[y]&&!l.hasClass("filter-false"))K(y);else if("string"===typeof y&&!l.hasClass("filter-false")){for(g in k.filter_functions[y])"string"===typeof g&&(h+=""===h?'<option value="">'+(l.attr("data-placeholder")|| "")+"</option>":"",h+='<option value="'+g+'">'+g+"</option>");u.find("thead").find("select."+z+'[data-column="'+y+'"]').append(h)}L();u.find("select."+z).bind("change search",function(){D()});!0===k.filter_hideFilters&&u.find(".tablesorter-filter-row").addClass("hideme").bind("mouseenter mouseleave",function(a){var c;m=b(this);clearTimeout(q);q=setTimeout(function(){/enter|over/.test(a.type)?m.removeClass("hideme"):b(document.activeElement).closest("tr")[0]!==m[0]&&(c=u.find("."+(k.filter_cssFilter|| "tablesorter-filter")).map(function(){return b(this).val()||""}).get().join(""),""===c&&m.addClass("hideme"))},200)}).find("input, select").bind("focus blur",function(a){r=b(this).closest("tr");clearTimeout(q);q=setTimeout(function(){if(""===u.find("."+(k.filter_cssFilter||"tablesorter-filter")).map(function(){return b(this).val()||""}).get().join(""))r["focus"===a.type?"removeClass":"addClass"]("hideme")},200)});t.showProcessing&&u.bind("filterStart filterEnd",function(a,c){var d=c?u.find("."+t.cssHeader).filter("[data-column]").filter(function(){return""!== c[b(this).data("column")]}):"";A.isProcessing(u[0],"filterStart"===a.type,c?d:"")});t.debug&&A.benchmark("Applying Filter widget",H);u.trigger("filterInit")}},remove:function(e,c,d){var a,j;a=b(e);c=a.children("tbody:not(."+c.cssInfoBlock+")");a.removeClass("hasFilters").unbind(["addRows","updateCell","update","appendCache","search"].join(".tsfilter")).find(".tablesorter-filter-row").remove();for(a=0;a<c.length;a++)j=b.tablesorter.processTbody(e,b(c[a]),!0),j.children().removeClass("filtered").show(), b.tablesorter.processTbody(e,j,!1);d.filterreset&&b(d.filter_reset).unbind("click")}});
9
+ b.tablesorter.addWidget({id:"stickyHeaders",format:function(e){if(!b(e).hasClass("hasStickyHeaders")){var c=b(e).addClass("hasStickyHeaders"),d=e.config,a=d.widgetOptions,j=b(window),f=b(e).children("thead:first"),h=f.children("tr:not(.sticky-false)").children();e=a.stickyHeaders||"tablesorter-stickyHeader";var n=h.eq(0).parent(),p=c.find("tfoot"),a=c.clone(),q=a.children("thead:first").addClass(e).css({width:f.outerWidth(!0), position:"fixed",margin:0,top:0,visibility:"hidden",zIndex:1}),g=q.children("tr:not(.sticky-false)").children(),m="",r=0,s=function(){var a=navigator.userAgent;r=0;"collapse"!==c.css("border-collapse")&&!/(webkit|msie)/i.test(a)&&(r=2*parseInt(h.eq(0).css("border-left-width"),10));q.css({left:f.offset().left-j.scrollLeft()-r,width:f.outerWidth()});g.each(function(a){a=h.eq(a);b(this).css({width:a.width()-r,height:a.height()})}).find(".tablesorter-header-inner").each(function(a){a=h.eq(a).find(".tablesorter-header-inner").width(); b(this).width(a)})};a.find("thead:gt(0),tr.sticky-false,tbody,tfoot,caption").remove();a.css({height:0,width:0,padding:0,margin:0,border:0});q.find("tr.sticky-false").remove();g.find(".tablesorter-resizer").remove();c.bind("sortEnd.tsSticky",function(){h.each(function(a){a=g.eq(a);a.attr("class",b(this).attr("class"));d.cssIcon&&a.find("."+d.cssIcon).attr("class",b(this).find("."+d.cssIcon).attr("class"))})}).bind("pagerComplete.tsSticky",function(){s()});h.find("*").andSelf().filter(d.selectorSort).each(function(a){var c= b(this);g.eq(a).bind("mouseup",function(a){c.trigger(a,!0)}).bind("mousedown",function(){this.onselectstart=function(){return!1};return!1})});c.after(a);j.bind("scroll.tsSticky",function(){var a=n.offset(),b=j.scrollTop(),d=c.height()-(q.height()+(p.height()||0)),a=b>a.top&&b<a.top+d?"visible":"hidden";q.css({left:f.offset().left-j.scrollLeft()-r,visibility:a});a!==m&&(s(),m=a)}).bind("resize.tsSticky",function(){s()})}},remove:function(e,c,d){e=b(e);d=d.stickyHeaders||"tablesorter-stickyHeader"; e.removeClass("hasStickyHeaders").unbind("sortEnd.tsSticky pagerComplete.tsSticky").find("."+d).remove();b(window).unbind("scroll.tsSticky resize.tsSticky")}});
10
+ b.tablesorter.addWidget({id:"resizable",format:function(e){if(!b(e).hasClass("hasResizable")){b(e).addClass("hasResizable");var c,d,a,j,f,h=b(e),n=e.config,p=n.widgetOptions,q=0,g=null,m=null,r=function(){q=0;g=m=null;b(window).trigger("resize")};if(a=b.tablesorter.storage&&!1!==p.resizable?b.tablesorter.storage(e,"tablesorter-resizable"): {})for(d in a)!isNaN(d)&&d<n.headerList.length&&b(n.headerList[d]).width(a[d]);h.children("thead:first").find("tr").each(function(){j=b(this).children();b(this).find(".tablesorter-wrapper").length||j.wrapInner('<div class="tablesorter-wrapper" style="position:relative;height:100%;width:100%"></div>');j=j.slice(0,-1);f=f?f.add(j):j});f.each(function(){c=b(this);d=parseInt(c.css("padding-right"),10)+8;c.find(".tablesorter-wrapper").append('<div class="tablesorter-resizer" style="cursor:w-resize;position:absolute;height:100%;width:16px;right:-'+ d+'px;top:0;z-index:1;"></div>')}).bind("mousemove.tsresize",function(a){if(0!==q&&g){var b=a.pageX-q;g.width(g.width()+b);m.width(m.width()-b);q=a.pageX}}).bind("mouseup.tsresize",function(){b.tablesorter.storage&&g&&(a[g.index()]=g.width(),a[m.index()]=m.width(),!1!==p.resizable&&b.tablesorter.storage(e,"tablesorter-resizable",a));r()}).find(".tablesorter-resizer").bind("mousedown",function(a){g=b(a.target).parents("th:last");m=g.next();q=a.pageX});h.find("thead:first").bind("mouseup.tsresize mouseleave.tsresize", function(){r()}).bind("contextmenu.tsresize",function(){b.tablesorter.resizableReset(e);var c=b.isEmptyObject?b.isEmptyObject(a):a==={};a={};return c})}},remove:function(e){b(e).removeClass("hasResizable").find("thead").unbind("mouseup.tsresize mouseleave.tsresize contextmenu.tsresize").find("tr").children().unbind("mousemove.tsresize mouseup.tsresize").find(".tablesorter-wrapper").each(function(){b(this).find(".tablesorter-resizer").remove();b(this).replaceWith(b(this).contents())});b.tablesorter.resizableReset(e)}}); b.tablesorter.resizableReset=function(e){b(e.config.headerList).width("auto");b.tablesorter.storage(e,"tablesorter-resizable",{})};
11
+ b.tablesorter.addWidget({id:"saveSort",init:function(b,c){c.format(b,!0)},format:function(e,c){var d,a,j=e.config;d=!1!==j.widgetOptions.saveSort;var f={sortList:j.sortList};j.debug&&(a=new Date);b(e).hasClass("hasSaveSort")?d&&(e.hasInitialized&&b.tablesorter.storage)&&(b.tablesorter.storage(e,"tablesorter-savesort",f),j.debug&&b.tablesorter.benchmark("saveSort widget: Saving last sort: "+ j.sortList,a)):(b(e).addClass("hasSaveSort"),f="",b.tablesorter.storage&&(f=(d=b.tablesorter.storage(e,"tablesorter-savesort"))&&d.hasOwnProperty("sortList")&&b.isArray(d.sortList)?d.sortList:"",j.debug&&b.tablesorter.benchmark('saveSort: Last sort loaded: "'+f+'"',a)),c&&f&&0<f.length?j.sortList=f:e.hasInitialized&&(f&&0<f.length)&&b(e).trigger("sorton",[f]))},remove:function(e){b.tablesorter.storage(e,"tablesorter-savesort","")}})
12
12
  })(jQuery);
@@ -44,6 +44,10 @@
44
44
  color: #fff;
45
45
  background-image: url(data:image/gif;base64,R0lGODlhFQAEAIAAAP///////yH5BAEAAAEALAAAAAAVAAQAAAINjB+gC+jP2ptn0WskLQA7);
46
46
  }
47
+ .tablesorter-blackice thead .sorter-false {
48
+ background-image: url();
49
+ padding: 4px;
50
+ }
47
51
 
48
52
  /* tfoot */
49
53
  .tablesorter-blackice tfoot .tablesorter-headerSortUp,
@@ -40,7 +40,7 @@
40
40
  /* white (unsorted) double arrow */
41
41
  /* background-image: url(data:image/gif;base64,R0lGODlhFQAJAIAAAP///////yH5BAEAAAEALAAAAAAVAAkAAAIXjI+AywnaYnhUMoqt3gZXPmVg94yJVQAAOw==); */
42
42
  /* image */
43
- /* background-image: url(images/black-unsorted.gif); */
43
+ /* background-image: url(/assets/jquery-tablesorter/black-unsorted.gif); */
44
44
  background-repeat: no-repeat;
45
45
  background-position: center right;
46
46
  padding: 4px 18px 4px 4px;
@@ -56,7 +56,7 @@
56
56
  /* white asc arrow */
57
57
  /* background-image: url(data:image/gif;base64,R0lGODlhFQAEAIAAAP///////yH5BAEAAAEALAAAAAAVAAQAAAINjI8Bya2wnINUMopZAQA7); */
58
58
  /* image */
59
- /* background-image: url(images/black-asc.gif); */
59
+ /* background-image: url(/assets/jquery-tablesorter/black-asc.gif); */
60
60
  }
61
61
  .tablesorter-blue .headerSortDown,
62
62
  .tablesorter-blue .tablesorter-headerSortDown,
@@ -67,7 +67,11 @@
67
67
  /* white desc arrow */
68
68
  /* background-image: url(data:image/gif;base64,R0lGODlhFQAEAIAAAP///////yH5BAEAAAEALAAAAAAVAAQAAAINjB+gC+jP2ptn0WskLQA7); */
69
69
  /* image */
70
- /* background-image: url(images/black-desc.gif); */
70
+ /* background-image: url(/assets/jquery-tablesorter/black-desc.gif); */
71
+ }
72
+ .tablesorter-blue thead .sorter-false {
73
+ background-image: url();
74
+ padding: 4px;
71
75
  }
72
76
 
73
77
  /* tfoot */
@@ -43,6 +43,10 @@
43
43
  background-image: url(data:image/gif;base64,R0lGODlhFQAEAIAAAP///////yH5BAEAAAEALAAAAAAVAAQAAAINjB+gC+jP2ptn0WskLQA7);
44
44
  border-bottom: #888 1px solid;
45
45
  }
46
+ .tablesorter-dark thead .sorter-false {
47
+ background-image: url();
48
+ padding: 4px;
49
+ }
46
50
 
47
51
  /* tfoot */
48
52
  .tablesorter-dark tfoot .tablesorter-headerSortUp,
@@ -46,6 +46,10 @@ Default Theme
46
46
  background-image: url(data:image/gif;base64,R0lGODlhFQAEAIAAACMtMP///yH5BAEAAAEALAAAAAAVAAQAAAINjB+gC+jP2ptn0WskLQA7);
47
47
  border-bottom: #000 2px solid;
48
48
  }
49
+ .tablesorter-default thead .sorter-false {
50
+ background-image: url();
51
+ padding: 4px;
52
+ }
49
53
 
50
54
  /* tfoot */
51
55
  .tablesorter-default tfoot .tablesorter-headerSortUp,
@@ -57,22 +57,27 @@
57
57
  .tablesorter-dropbox .tablesorter-headerSortUp i,
58
58
  .tablesorter-dropbox .tablesorter-headerAsc i {
59
59
  background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAkAAAAJCAYAAADgkQYQAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAALhJREFUeNpi/P//PwMhwILMiexYx8bIxNTy/9+/muUVQb9g4kzIitg4edI4+YRLQTSyOCPMupjerUI8whK3OXgEhH58+fDuy9sXqkuKvd+hmMTOxdvCxS8sxMUvxACiQXwU6+Im7DDg5BNKY+fiY2BmYWMA0SA+SByuiJ2bbzIHrwAzMxsb0AGMDCAaxAeJg+SZ7wtaqfAISfQAdTIwMUM8ywhUyMTEzPD/71+5FXvPLWUkJpwAAgwAZqYvvHStbD4AAAAASUVORK5CYII=');
60
- /* background-image: url(images/dropbox-asc.png); */
60
+ /* background-image: url(/assets/jquery-tablesorter/dropbox-asc.png); */
61
61
  }
62
62
  .tablesorter-dropbox .tablesorter-headerSortUp:hover i,
63
63
  .tablesorter-dropbox .tablesorter-headerAsc:hover i {
64
64
  background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAkAAAAJCAYAAADgkQYQAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAALVJREFUeNpi/P//PwMhwILMCc+qZGNkYmr5/+9fzcpp7b9g4kzIitjYOdM4uXlLQTSyOCPMuqi8OiEefsHbHFzcQj++fX335eN71WWTmt6hmMTOwdXCycMnBDSJAUSD+CjWxRQ0GHBw86Sxc3AyMDOzMIBoEB8kDlfEzsk1mYOLByjPCnQAIwOIBvFB4iB55rsfmVS4+QV7QNYwMTNDHApUyMTExPDv/z+5Feu3L2UkJpwAAgwA244u+I9CleAAAAAASUVORK5CYII=');
65
- /* background-image: url(images/dropbox-asc-hovered.png); */
65
+ /* background-image: url(/assets/jquery-tablesorter/dropbox-asc-hovered.png); */
66
66
  }
67
67
  .tablesorter-dropbox .tablesorter-headerSortDown i,
68
68
  .tablesorter-dropbox .tablesorter-headerDesc i {
69
69
  background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAkAAAAJCAYAAADgkQYQAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAALdJREFUeNpi/P//PwMhwBLdtVGFhZ3zNhMzC4bkv79/GP78/K7KCDIpZ9mVw+xcfDaMTExwBf///WP4+e3TkSlROrZg7UxMLLns3HxnmFnZmGGK/v7+9ff3j2+5YHkQMSlC48Kv719m/f//D2IKkAbxQeJwRSDw4/OHmr+/fr0DqmAA0SA+TA6uaEq0zjugG+r//vkFcks9iA/3HbJvvn18O+vf379yP758mMXAoAAXZyQmnAACDADX316BiTFbMQAAAABJRU5ErkJggg==');
70
- /* background-image: url(images/dropbox-desc.png); */
70
+ /* background-image: url(/assets/jquery-tablesorter/dropbox-desc.png); */
71
71
  }
72
72
  .tablesorter-dropbox .tablesorter-headerSortDown:hover i,
73
73
  .tablesorter-dropbox .tablesorter-headerDesc:hover i {
74
74
  background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAkAAAAJCAYAAADgkQYQAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAALNJREFUeNpi/P//PwMhwBJf3uP879e3PUzMzBiS//7+ZWBi43JhBJmU2z7nIzMzEx8jIyNcAUj8799/nyZXpvCzgARYuXjTWBkZVjCzIEz7++cvw+//DGkgNiPMTWVT1l5hZvynDTINbMp/pqtdOcE6IDkmmM5fv3/5//v37z9QBQOIBvFhcnBFEwoj7/5jZFnz9+8fBhAN4sN9h+ybH9++JrGxscr/+vE1CVmckZhwAggwANvlUyq5Dd1wAAAAAElFTkSuQmCC');
75
- /* background-image: url(images/dropbox-desc-hovered.png); */
75
+ /* background-image: url(/assets/jquery-tablesorter/dropbox-desc-hovered.png); */
76
+ }
77
+ .tablesorter-dropbox thead .sorter-false i,
78
+ .tablesorter-dropbox thead .sorter-false:hover i {
79
+ background-image: url();
80
+ padding: 4px;
76
81
  }
77
82
 
78
83
  /* tbody */
@@ -22,7 +22,7 @@
22
22
  .tablesorter-green tfoot tr {
23
23
  background: center center repeat-x;
24
24
  background-image: url(data:image/gif;base64,R0lGODlhAQBkAOYAAN/e39XU1fX19tTU1eXm5uTl5ePk5OLj4+Hi4vX29fT19PP08/Lz8vHy8fDx8O/w7+7v7uzt7Orr6ufo5/T08/Pz8ufn5uLi4eDg39/f3t3d3Nzc29HR0NDQz8/Pzuvq6urp6eno6Ojn5+fm5tfW1tbV1dTT09PS0tLR0dHQ0NDPz/f39/b29vX19fT09PPz8/Ly8vHx8e/v7+7u7u3t7ezs7Ovr6+rq6unp6ejo6Ofn5+bm5uXl5eTk5OPj4+Li4uHh4eDg4N/f397e3t3d3dzc3Nvb29ra2tnZ2djY2NfX19XV1dPT09LS0tHR0dDQ0M/Pz8rKysXFxf///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAFMALAAAAAABAGQAAAdegCsrLC0tLi+ILi6FCSwsCS0KkhQVDA0OMjM0NTYfICEiIzw9P0AYGUQaG0ZHSEoDTU9Qs08pTk1MSyRJR0VDQT8+PTw7Ojg3NTMyMTAvi4WOhC0vMTI1OT9GTlFSgQA7);
25
- /* background-image: url(images/green-header.gif); */
25
+ /* background-image: url(/assets/jquery-tablesorter/green-header.gif); */
26
26
  }
27
27
  .tablesorter-green th,
28
28
  .tablesorter-green thead td {
@@ -35,7 +35,7 @@
35
35
  .tablesorter-green .tablesorter-header {
36
36
  background: no-repeat 5px center;
37
37
  background-image: url(data:image/gif;base64,R0lGODlhEAAQAOYAAA5NDBBYDlWWUzRUM5DVjp7inJ/fnQ1ECiCsGhyYFxqKFRFdDhBXDQxCCiO8HSK2HCCqGh2aGByUFxuPFhqNFhmHFRZ2EhVvERRpEBBVDSS8HiGyHB+mGh6fGRuTFxiAFBd5Eww/Cgs5CRp7Fiu+JRx8GCy/JjHAKyynKCuhJzXCMDbCMDnDMyNuHz3EODy9N0LFPSl7JkvIRjycOFDKS1LKTVPLT1XLUFTCT17OWTBkLmbQYnDTbHXVcXnWdoXago/djGmUZ112XCJEIEdjRf///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAEUALAAAAAAQABAAAAdlgEWCg4SFhoIvh4cVLECKhCMeJjwFj0UlEwgaMD4Gii0WFAkRHQ47BIY6IQAZDAwBCyAPOJa1toRBGBAwNTY3OT0/AoZCDQoOKi4yNDOKRCIfGycrKZYDBxIkKLZDFxy3RTHgloEAOw==);
38
- /* background-image: url(images/green-unsorted.gif); */
38
+ /* background-image: url(/assets/jquery-tablesorter/green-unsorted.gif); */
39
39
  border-collapse: collapse;
40
40
  white-space: normal;
41
41
  cursor: pointer;
@@ -44,18 +44,22 @@
44
44
  .tablesorter-green thead .tablesorter-headerSortUp,
45
45
  .tablesorter-green thead .tablesorter-headerAsc {
46
46
  background-image: url(data:image/gif;base64,R0lGODlhEAAQANUAAA5NDBBYDpDVjp7inJ/fnSCsGhyYFxFdDhBXDSO8HSK2HB2aGBuPFhqNFhmHFRZ2EhBVDSS8Hh6fGRuTFxd5Eww/Chp7Fhx8GCy/JjnDMyNuHzy9N0LFPVTCTzBkLmbQYnDTbHnWdo/djP///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAACMALAAAAAAQABAAAAY4wJFwSCwaj8ikcslMbpojR0bEtEwwoIHywihEOCECUvNoGBaSxEdg9FQAEAQicKAoOtC8fs8fBgEAOw==)
47
- /* background-image: url(images/green-asc.gif); */
47
+ /* background-image: url(/assets/jquery-tablesorter/green-asc.gif); */
48
48
  }
49
49
  .tablesorter-green thead .headerSortDown,
50
50
  .tablesorter-green thead .tablesorter-headerSortDown,
51
51
  .tablesorter-green thead .tablesorter-headerDesc {
52
52
  background-image: url(data:image/gif;base64,R0lGODlhEAAQANUAAFWWUzRUMw1EChqKFQxCCiO8HSCqGhyUFxVvERRpECGyHB+mGhiAFAs5CSu+JTHAKyynKCuhJzXCMDbCMD3EOELFPSl7JkvIRjycOFDKS1LKTVPLT1XLUF7OWXXVcYXagmmUZ112XCJEIEdjRf///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAACQALAAAAAAQABAAAAY4QJJwSCwaj8ikcskkghKGimbD6Xg+AGOIMChIKJcMBjlqMBSPSUQZEBwcEKYIsWiSLPa8fs9HBgEAOw==)
53
- /* background-image: url(images/green-desc.gif); */
53
+ /* background-image: url(/assets/jquery-tablesorter/green-desc.gif); */
54
54
  }
55
55
  .tablesorter-green th.tablesorter-header .tablesorter-header-inner,
56
56
  .tablesorter-green td.tablesorter-header .tablesorter-header-inner {
57
57
  padding-left: 23px;
58
58
  }
59
+ .tablesorter-green thead .tablesorter-header.sorter-false {
60
+ background-image: url();
61
+ padding: 4px;
62
+ }
59
63
 
60
64
  /* tfoot */
61
65
  .tablesorter-green tbody td,
@@ -78,6 +78,10 @@
78
78
  /* white desc arrow */
79
79
  background-image: url(data:image/gif;base64,R0lGODlhFQAEAIAAAP///////yH5BAEAAAEALAAAAAAVAAQAAAINjB+gC+jP2ptn0WskLQA7);
80
80
  }
81
+ .tablesorter-grey thead .sorter-false i {
82
+ background-image: url();
83
+ padding: 4px;
84
+ }
81
85
 
82
86
  /* tfoot */
83
87
  .tablesorter-grey tbody td,
@@ -37,7 +37,7 @@
37
37
  .tablesorter-ice .tablesorter-header {
38
38
  background: #f6f8f9 no-repeat center right;
39
39
  background-image: url(data:image/gif;base64,R0lGODlhDAAMAMQAAAJEjAJCiwJBigJAiANFjgNGjgNEjQRIkQRHkANIkAVMlAVQmAZWnQZUnAdYoAhdpAhZoAlhqQlepQliqQppsApmrQxutgtutQtutAxwtwxwtg1yug1zugxtsw1yuP8A/yH5BAEAAB8ALAAAAAAMAAwAAAUx4Cd+3GiOW4ado2d9VMVm1xg9ptadTsP+QNZEcjoQTBDGCAFgLRSfQgCYMAiCn8EvBAA7);
40
- /* background-image: url(images/ice-unsorted.gif) */
40
+ /* background-image: url(/assets/jquery-tablesorter/ice-unsorted.gif) */
41
41
  padding: 4px 20px 4px 4px;
42
42
  white-space: normal;
43
43
  cursor: pointer;
@@ -48,7 +48,7 @@
48
48
  color: #333;
49
49
  background: #ebedee no-repeat center right;
50
50
  background-image: url(data:image/gif;base64,R0lGODlhDAAMANUAAAJCiwNHkANFjgNEjQRIkQNJkQRMlARKkwRKkgVPlwZSmgdaogdYnwhfpghcowlhqgliqglgqAlgpwljqwporwpmrQplrAtsswtqsgtrsgtqsQxttAtvtQtttAxyuQxwtwxxtwxvtg10uw1zuQ1xuP8A/wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAACUALAAAAAAMAAwAAAY6wJKwJBoahyNQ6Dj0fDoZCpPEuWgqk4jxs8FQLI+Gg8Esm5kQydFQMC7IwkOAqUiUCAIzIjA4lwBlQQA7);
51
- /* background-image: url(images/ice-desc.gif) */
51
+ /* background-image: url(/assets/jquery-tablesorter/ice-desc.gif) */
52
52
  }
53
53
  .tablesorter-ice .headerSortDown,
54
54
  .tablesorter-ice .tablesorter-headerSortDown,
@@ -56,7 +56,11 @@
56
56
  color: #333;
57
57
  background: #ebedee no-repeat center right;
58
58
  background-image: url(data:image/gif;base64,R0lGODlhDAAMANUAAAE/iAJBigNFjgNEjQNFjQNDiwRHkQRHjwNHjwROlgRMlQRMlARJkgRKkgZQmAVPlgZWnQZSmgZRmAdXoAdXnwdUnAdbogdZoQhbowlhqAlepglkrAliqQtstAtqsQxyugxyuQxwuAxxuAxxtwxwtgxvtQ10vA12vA10u/8A/wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAACkALAAAAAAMAAwAAAY6wJQwdRoah6bP6DhEiVIdDxNEGm4yxlDpiJkwv2AmR2OhVCSJBsJ4gUQeCwOB6VAwBAXwYRAIpwBfQQA7);
59
- /* background-image: url(images/ice-asc.gif); */
59
+ /* background-image: url(/assets/jquery-tablesorter/ice-asc.gif); */
60
+ }
61
+ .tablesorter-ice thead .sorter-false {
62
+ background-image: url();
63
+ padding: 4px;
60
64
  }
61
65
 
62
66
  /* tfoot */
metadata CHANGED
@@ -2,31 +2,31 @@
2
2
  name: jquery-tablesorter
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 1.2.0
5
+ version: 1.3.0
6
6
  platform: ruby
7
7
  authors:
8
8
  - Jun Lin
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-12-16 00:00:00.000000000 Z
12
+ date: 2012-12-24 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
+ type: :runtime
15
16
  version_requirements: !ruby/object:Gem::Requirement
17
+ none: false
16
18
  requirements:
17
19
  - - ~>
18
20
  - !ruby/object:Gem::Version
19
21
  version: '3.1'
20
- none: false
21
22
  name: railties
22
- type: :runtime
23
23
  prerelease: false
24
24
  requirement: !ruby/object:Gem::Requirement
25
+ none: false
25
26
  requirements:
26
27
  - - ~>
27
28
  - !ruby/object:Gem::Version
28
29
  version: '3.1'
29
- none: false
30
30
  description: Simple integration of jquery-tablesorter into the asset pipeline.
31
31
  email:
32
32
  - linjunpop@gmail.com
@@ -95,17 +95,23 @@ rdoc_options: []
95
95
  require_paths:
96
96
  - lib
97
97
  required_ruby_version: !ruby/object:Gem::Requirement
98
+ none: false
98
99
  requirements:
99
100
  - - ! '>='
100
101
  - !ruby/object:Gem::Version
102
+ segments:
103
+ - 0
104
+ hash: 1361323073996744612
101
105
  version: '0'
102
- none: false
103
106
  required_rubygems_version: !ruby/object:Gem::Requirement
107
+ none: false
104
108
  requirements:
105
109
  - - ! '>='
106
110
  - !ruby/object:Gem::Version
111
+ segments:
112
+ - 0
113
+ hash: 1361323073996744612
107
114
  version: '0'
108
- none: false
109
115
  requirements: []
110
116
  rubyforge_project:
111
117
  rubygems_version: 1.8.23