'),x=w.parent().addClass(c.css.stickyHide).css({position:l.length?"absolute":"fixed",padding:parseInt(w.parent().parent().css("padding-left"),10),top:t+v,left:0,visibility:"hidden",zIndex:f.stickyHeaders_zIndex||2}),y=w.children("thead:first"),z="",A=0,B=function(a,c){var d,e,f,g,h,i=a.filter(":visible"),j=i.length;for(d=0;j>d;d++)g=c.filter(":visible").eq(d),h=i.eq(d),"border-box"===h.css("box-sizing")?e=h.outerWidth():"collapse"===g.css("border-collapse")?b.getComputedStyle?e=parseFloat(b.getComputedStyle(h[0],null).width):(f=parseFloat(h.css("border-width")),e=h.outerWidth()-parseFloat(h.css("padding-left"))-parseFloat(h.css("padding-right"))-f):e=h.width(),g.css({width:e,"min-width":e,"max-width":e})},C=function(){t=s.length?s.height()||0:parseInt(f.stickyHeaders_offset,10)||0,A=0,x.css({left:l.length?parseInt(l.css("padding-left"),10)||0:k.offset().left-parseInt(k.css("margin-left"),10)-o.scrollLeft()-A,width:k.outerWidth()}),B(k,w),B(q,j)},D=function(b){if(k.is(":visible")){v=u.length?u.offset().top-n.scrollTop()+u.height():0;var d=k.offset(),e=a.isWindow(n[0]),f=a.isWindow(o[0]),g=(l.length?e?n.scrollTop():n.offset().top:n.scrollTop())+t+v,h=k.height()-(x.height()+(r.height()||0)),i=g>d.top&&g
g;g++)e.onRenderHeader.apply(i.eq(g),[g,e,w]);o.add(n).unbind("scroll resize ".split(" ").join(m).replace(/\s+/g," ")).bind("scroll resize ".split(" ").join(m),function(a){D("resize"===a.type)}),e.$table.unbind("stickyHeadersUpdate"+m).bind("stickyHeadersUpdate"+m,function(){D(!0)}),f.stickyHeaders_addResizeEvent&&c.addHeaderResizeEvent(d),k.hasClass("hasFilters")&&f.filter_columnFilters&&(k.bind("filterEnd"+m,function(){var d=a(document.activeElement).closest("td"),g=d.parent().children().index(d);x.hasClass(c.css.stickyVis)&&f.stickyHeaders_filteredToTop&&(b.scrollTo(0,k.position().top),g>=0&&e.$filters&&e.$filters.eq(g).find("a, select, input").filter(":visible").focus())}),c.filter.bindSearch(k,j.find("."+c.css.filter)),f.filter_hideFilters&&c.filter.hideFilters(w,e)),k.trigger("stickyHeadersInit")}},remove:function(d,e,f){var g=e.namespace+"stickyheaders ";e.$table.removeClass("hasStickyHeaders").unbind("pagerComplete filterEnd stickyHeadersUpdate ".split(" ").join(g).replace(/\s+/g," ")).next("."+c.css.stickyWrap).remove(),f.$sticky&&f.$sticky.length&&f.$sticky.remove(),a(b).add(f.stickyHeaders_xScroll).add(f.stickyHeaders_yScroll).add(f.stickyHeaders_attachTo).unbind("scroll resize ".split(" ").join(g).replace(/\s+/g," ")),c.addHeaderResizeEvent(d,!1)}})}(jQuery,window),function(a,b){"use strict";var c=a.tablesorter||{};a.extend(c.css,{resizableContainer:"tablesorter-resizable-container",resizableHandle:"tablesorter-resizable-handle",resizableNoSelect:"tablesorter-disableSelection",resizableStorage:"tablesorter-resizable"}),a(function(){var b="";a(b).appendTo("body")}),c.resizable={init:function(b,d){if(!b.$table.hasClass("hasResizable")){b.$table.addClass("hasResizable");var e,f,g,h,i,j=b.$table,k=j.parent(),l=parseInt(j.css("margin-top"),10),m=d.resizable_vars={useStorage:c.storage&&d.resizable!==!1,$wrap:k,mouseXPosition:0,$target:null,$next:null,overflow:"auto"===k.css("overflow")||"scroll"===k.css("overflow")||"auto"===k.css("overflow-x")||"scroll"===k.css("overflow-x"),storedSizes:[]};for(c.resizableReset(b.table,!0),m.tableWidth=j.width(),m.fullWidth=Math.abs(k.width()-m.tableWidth)<20,m.useStorage&&m.overflow&&(c.storage(b.table,"tablesorter-table-original-css-width",m.tableWidth),i=c.storage(b.table,"tablesorter-table-resized-width")||"auto",c.resizable.setWidth(j,i,!0)),d.resizable_vars.storedSizes=h=(m.useStorage?c.storage(b.table,c.css.resizableStorage):[])||[],c.resizable.setWidths(b,d,h),c.resizable.updateStoredSizes(b,d),d.$resizable_container=a('').css({top:l}).insertBefore(j),g=0;g
').appendTo(d.$resizable_container).attr({"data-column":g,unselectable:"on"}).data("header",f).bind("selectstart",!1);j.one("tablesorter-initialized",function(){c.resizable.setHandlePosition(b,d),c.resizable.bindings(this.config,this.config.widgetOptions)})}},updateStoredSizes:function(a,b){var c,d,e=a.columns,f=b.resizable_vars;for(f.storedSizes=[],c=0;e>c;c++)d=a.$headerIndexed[c],f.storedSizes[c]=d.is(":visible")?d.width():0},setWidth:function(a,b,c){a.css({width:b,"min-width":c?b:"","max-width":c?b:""})},setWidths:function(b,d,e){var f,g,h=d.resizable_vars,i=a(b.namespace+"_extra_headers"),j=b.$table.children("colgroup").children("col");if(e=e||h.storedSizes||[],e.length){for(f=0;ff||f===h&&d.resizable_addLastColumn)&&c.css({display:"inline-block",height:g,left:j.position().left-e+j.outerWidth()-i}):c.hide())})},toggleTextSelection:function(b,d){var e=b.namespace+"tsresize";b.widgetOptions.resizable_vars.disabled=d,a("body").toggleClass(c.css.resizableNoSelect,d),d?a("body").attr("unselectable","on").bind("selectstart"+e,!1):a("body").removeAttr("unselectable").unbind("selectstart"+e)},bindings:function(d,e){var f=d.namespace+"tsresize";e.$resizable_container.children().bind("mousedown",function(b){var f,g=e.resizable_vars,h=a(d.namespace+"_extra_headers"),i=a(b.target).data("header");f=parseInt(i.attr("data-column"),10),g.$target=i=i.add(h.filter('[data-column="'+f+'"]')),g.target=f,g.$next=b.shiftKey||e.resizable_targetLast?i.parent().children().not(".resizable-false").filter(":last"):i.nextAll(":not(.resizable-false)").eq(0),f=parseInt(g.$next.attr("data-column"),10),g.$next=g.$next.add(h.filter('[data-column="'+f+'"]')),g.next=f,g.mouseXPosition=b.pageX,c.resizable.updateStoredSizes(d,e),c.resizable.toggleTextSelection(d,!0)}),a(document).bind("mousemove"+f,function(a){var b=e.resizable_vars;b.disabled&&0!==b.mouseXPosition&&b.$target&&(e.resizable_throttle?(clearTimeout(b.timer),b.timer=setTimeout(function(){c.resizable.mouseMove(d,e,a)},isNaN(e.resizable_throttle)?5:e.resizable_throttle)):c.resizable.mouseMove(d,e,a))}).bind("mouseup"+f,function(){e.resizable_vars.disabled&&(c.resizable.toggleTextSelection(d,!1),c.resizable.stopResize(d,e),c.resizable.setHandlePosition(d,e))}),a(b).bind("resize"+f+" resizeEnd"+f,function(){c.resizable.setHandlePosition(d,e)}),d.$table.bind("columnUpdate"+f,function(){c.resizable.setHandlePosition(d,e)}).find("thead:first").add(a(d.namespace+"_extra_table").find("thead:first")).bind("contextmenu"+f,function(){var a=0===e.resizable_vars.storedSizes.length;return c.resizableReset(d.table),c.resizable.setHandlePosition(d,e),e.resizable_vars.storedSizes=[],a})},mouseMove:function(b,d,e){if(0!==d.resizable_vars.mouseXPosition&&d.resizable_vars.$target){var f,g=0,h=d.resizable_vars,i=h.$next,j=h.storedSizes[h.target],k=e.pageX-h.mouseXPosition;if(h.overflow){if(j+k>0){for(h.storedSizes[h.target]+=k,c.resizable.setWidth(h.$target,h.storedSizes[h.target],!0),f=0;f0?d.sortList=k:c.hasInitialized&&k&&k.length>0&&i.trigger("sorton",[k]))},remove:function(a,c){c.$table.removeClass("hasSaveSort"),b.storage&&b.storage(a,"tablesorter-savesort","")}})}(jQuery),a.tablesorter});
\ No newline at end of file
+/*! tablesorter (FORK) - updated 08-23-2015 (v2.23.2)*/
+!function(a){"function"==typeof define&&define.amd?define(["jquery"],a):"object"==typeof module&&"object"==typeof module.exports?module.exports=a(require("jquery")):a(jQuery)}(function(a){return function(a){"use strict";a.extend({tablesorter:new function(){function b(b,c,d,e){for(var f,g,h=q.parsers.length,i=!1,j="",k=!0;""===j&&k;)d++,c[d]?(i=c[d].cells[e],j=q.getElementText(b,i,e),g=a(i),b.debug&&console.log("Checking if value was empty on row "+d+", column: "+e+': "'+j+'"')):k=!1;for(;--h>=0;)if(f=q.parsers[h],f&&"text"!==f.id&&f.is&&f.is(j,b.table,i,g))return f;return q.getParserById("text")}function c(a,c){var d,e,f,g,h,i,j,k,l,m,n,o,p=a.table,r=0,s={};if(a.$tbodies=a.$table.children("tbody:not(."+a.cssInfoBlock+")"),n="undefined"==typeof c?a.$tbodies:c,o=n.length,0===o)return a.debug?console.warn("Warning: *Empty table!* Not building a parser cache"):"";for(a.debug&&(m=new Date,console[console.group?"group":"log"]("Detecting parsers for each column")),e={extractors:[],parsers:[]};o>r;){if(d=n[r].rows,d.length)for(f=a.columns,g=0;f>g;g++)h=a.$headerIndexed[g],i=q.getColumnData(p,a.headers,g),l=q.getParserById(q.getData(h,i,"extractor")),k=q.getParserById(q.getData(h,i,"sorter")),j="false"===q.getData(h,i,"parser"),a.empties[g]=(q.getData(h,i,"empty")||a.emptyTo||(a.emptyToBottom?"bottom":"top")).toLowerCase(),a.strings[g]=(q.getData(h,i,"string")||a.stringTo||"max").toLowerCase(),j&&(k=q.getParserById("no-parser")),l||(l=!1),k||(k=b(a,d,-1,g)),a.debug&&(s["("+g+") "+h.text()]={parser:k.id,extractor:l?l.id:"none",string:a.strings[g],empty:a.empties[g]}),e.parsers[g]=k,e.extractors[g]=l;r+=e.parsers.length?o:1}a.debug&&(q.isEmptyObject(s)?console.warn(" No parsers detected!"):console[console.table?"table":"log"](s),console.log("Completed detecting parsers"+q.benchmark(m)),console.groupEnd&&console.groupEnd()),a.parsers=e.parsers,a.extractors=e.extractors}function d(b,c,d){var e,f,g,h,i,j,k,l,m,n,o,p,r,s,t=b.config,u=t.parsers;if(t.$tbodies=t.$table.children("tbody:not(."+t.cssInfoBlock+")"),k="undefined"==typeof d?t.$tbodies:d,t.cache={},t.totalRows=0,!u)return t.debug?console.warn("Warning: *Empty table!* Not building a cache"):"";for(t.debug&&(n=new Date),t.showProcessing&&q.isProcessing(b,!0),j=0;jh;++h)if(p={child:[],raw:[]},l=a(k[j].rows[h]),m=[],l.hasClass(t.cssChildRow)&&0!==h)for(f=e.normalized.length-1,r=e.normalized[f][t.columns],r.$row=r.$row.add(l),l.prev().hasClass(t.cssChildRow)||l.prev().addClass(q.css.cssHasChild),g=l.children("th, td"),f=r.child.length,r.child[f]=[],i=0;i':"",b.$headers=a(a.map(b.$table.find(b.selectorHeaders),function(h,k){return d=a(h),d.parent().hasClass(b.cssIgnoreRow)?void 0:(c=q.getColumnData(b.table,b.headers,k,!0),b.headerContent[k]=d.html(),""===b.headerTemplate||d.find("."+q.css.headerIn).length||(i=b.headerTemplate.replace(q.regex.templateContent,d.html()).replace(q.regex.templateIcon,d.find("."+q.css.icon).length?"":g),b.onRenderTemplate&&(f=b.onRenderTemplate.apply(d,[k,i]),f&&"string"==typeof f&&(i=f)),d.html('")),b.onRenderHeader&&b.onRenderHeader.apply(d,[k,b,b.$table]),h.column=parseInt(d.attr("data-column"),10),h.order=e(q.getData(d,c,"sortInitialOrder")||b.sortInitialOrder)?[1,0,2]:[0,1,2],h.count=-1,h.lockedOrder=!1,j=q.getData(d,c,"lockedOrder")||!1,"undefined"!=typeof j&&j!==!1&&(h.order=h.lockedOrder=e(j)?[1,1,1]:[0,0,0]),d.addClass(q.css.header+" "+b.cssHeader),b.headerList[k]=h,d.parent().addClass(q.css.headerRow+" "+b.cssHeaderRow).attr("role","row"),b.tabIndex&&d.attr("tabindex",0),h)})),b.$headerIndexed=[],l=0;lb;b++)d=f.$headers.eq(b),e=q.getColumnData(a,f.headers,b,!0),c="false"===q.getData(d,e,"sorter")||"false"===q.getData(d,e,"parser"),d[0].sortDisabled=c,d[c?"addClass":"removeClass"]("sorter-false").attr("aria-disabled",""+c),a.id&&(c?d.removeAttr("aria-controls"):d.attr("aria-controls",a.id))}function i(b){var c,d,e,f,g,h,i,j,k=b.config,l=k.sortList,m=l.length,n=q.css.sortNone+" "+k.cssNone,o=[q.css.sortAsc+" "+k.cssAsc,q.css.sortDesc+" "+k.cssDesc],p=[k.cssIconAsc,k.cssIconDesc,k.cssIconNone],r=["ascending","descending"],s=a(b).find("tfoot tr").children().add(a(k.namespace+"_extra_headers")).removeClass(o.join(" "));for(k.$headers.removeClass(o.join(" ")).addClass(n).attr("aria-sort","none").find("."+q.css.icon).removeClass(p.join(" ")).addClass(p[2]),e=0;m>e;e++)if(2!==l[e][1]&&(c=k.$headers.not(".sorter-false").filter('[data-column="'+l[e][0]+'"]'+(1===m?":last":"")),c.length)){for(f=0;fe;e++)h=g.eq(e),h.length&&(d=g[e],i=d.order[(d.count+1)%(k.sortReset?3:2)],j=a.trim(h.text())+": "+q.language[h.hasClass(q.css.sortAsc)?"sortAsc":h.hasClass(q.css.sortDesc)?"sortDesc":"sortNone"]+q.language[0===i?"nextAsc":1===i?"nextDesc":"nextNone"],h.attr("aria-label",j))}function j(b,c){var d,e,f,g,h,i,j,k,l=b.config,m=c||l.sortList,n=m.length;for(l.sortList=[],h=0;n>h;h++)if(k=m[h],d=parseInt(k[0],10),d=0?e:f[1]%(l.sortReset?3:2)}}function k(a,b){return a&&a[b]?a[b].type||"":""}function l(b,c,d){if(b.isUpdating)return setTimeout(function(){l(b,c,d)},50);var e,f,g,h,j,k,n,o=b.config,p=!d[o.sortMultiSortKey],r=o.$table,s=o.$headers.length;if(r.trigger("sortStart",b),c.count=d[o.sortResetKey]?2:(c.count+1)%(o.sortReset?3:2),o.sortRestart)for(f=c,g=0;s>g;g++)n=o.$headers.eq(g),n[0]===f||!p&&n.is("."+q.css.sortDesc+",."+q.css.sortAsc)||(n[0].count=-1);if(f=parseInt(a(c).attr("data-column"),10),p){if(o.sortList=[],null!==o.sortForce)for(e=o.sortForce,h=0;hj&&(o.sortList.push([f,j]),c.colSpan>1))for(h=1;h1)for(h=0;h=0&&o.sortList.splice(k,1);if(q.isValueInArray(f,o.sortList)>=0)for(h=0;hj&&(o.sortList.push([f,j]),c.colSpan>1))for(h=1;hc;c++)g=o.cache[c].colMax,h=o.cache[c].normalized,h.sort(function(c,f){for(b=0;s>b;b++){if(e=r[b][0],i=r[b][1],n=0===i,o.sortStable&&c[e]===f[e]&&1===s)return c[o.columns].order-f[o.columns].order;if(d=/n/i.test(k(o.parsers,e)),d&&o.strings[e]?(d="boolean"==typeof o.string[o.strings[e]]?(n?1:-1)*(o.string[o.strings[e]]?-1:1):o.strings[e]?o.string[o.strings[e]]||0:0,j=o.numberSorter?o.numberSorter(c[e],f[e],n,g[e],a):q["sortNumeric"+(n?"Asc":"Desc")](c[e],f[e],d,g[e],e,a)):(l=n?c:f,m=n?f:c,j="function"==typeof p?p(l[e],m[e],n,e,a):"object"==typeof p&&p.hasOwnProperty(e)?p[e](l[e],m[e],n,e,a):q["sortNatural"+(n?"Asc":"Desc")](c[e],f[e],e,a,o)),j)return j}return c[o.columns].order-f[o.columns].order});o.debug&&console.log("Sorting on "+r.toString()+" and dir "+i+" time"+q.benchmark(f))}}function n(b,c){b.table.isUpdating&&b.$table.trigger("updateComplete",b.table),a.isFunction(c)&&c(b.table)}function o(b,c,d){var e=a.isArray(c)?c:b.sortList,f="undefined"==typeof c?b.resort:c;f===!1||b.serverSideSorting||b.table.isProcessing?(n(b,d),q.applyWidget(b.table,!1)):e.length?b.$table.trigger("sorton",[e,function(){n(b,d)},!0]):b.$table.trigger("sortReset",[function(){n(b,d),q.applyWidget(b.table,!1)}])}function p(b){var c=b.config,d=c.$table,e="sortReset update updateRows updateAll updateHeaders addRows updateCell updateComplete sorton appendCache updateCache applyWidgetId applyWidgets refreshWidgets destroy mouseup mouseleave ".split(" ").join(c.namespace+" ");d.unbind(e.replace(q.regex.spaces," ")).bind("sortReset"+c.namespace,function(a,b){a.stopPropagation(),q.sortReset(this.config,b)}).bind("updateAll"+c.namespace,function(a,b,c){a.stopPropagation(),q.updateAll(this.config,b,c)}).bind("update"+c.namespace+" updateRows"+c.namespace,function(a,b,c){a.stopPropagation(),q.update(this.config,b,c)}).bind("updateHeaders"+c.namespace,function(a,b){a.stopPropagation(),q.updateHeaders(this.config,b)}).bind("updateCell"+c.namespace,function(a,b,c,d){a.stopPropagation(),q.updateCell(this.config,b,c,d)}).bind("addRows"+c.namespace,function(a,b,c,d){a.stopPropagation(),q.addRows(this.config,b,c,d)}).bind("updateComplete"+c.namespace,function(){b.isUpdating=!1}).bind("sorton"+c.namespace,function(a,b,c,d){a.stopPropagation(),q.sortOn(this.config,b,c,d)}).bind("appendCache"+c.namespace,function(c,d,e){c.stopPropagation(),q.appendCache(this.config,e),a.isFunction(d)&&d(b)}).bind("updateCache"+c.namespace,function(a,b,c){a.stopPropagation(),q.updateCache(this.config,b,c)}).bind("applyWidgetId"+c.namespace,function(a,c){a.stopPropagation(),q.getWidgetById(c).format(b,this.config,this.config.widgetOptions)}).bind("applyWidgets"+c.namespace,function(a,c){a.stopPropagation(),q.applyWidget(b,c)}).bind("refreshWidgets"+c.namespace,function(a,c,d){a.stopPropagation(),q.refreshWidgets(b,c,d)}).bind("destroy"+c.namespace,function(a,c,d){a.stopPropagation(),q.destroy(b,c,d)}).bind("resetToLoadState"+c.namespace,function(d){d.stopPropagation(),q.removeWidget(b,!0,!1),c=a.extend(!0,q.defaults,c.originalSettings),b.hasInitialized=!1,q.setup(b,c)})}var q=this;q.version="2.23.2",q.parsers=[],q.widgets=[],q.defaults={theme:"default",widthFixed:!1,showProcessing:!1,headerTemplate:"{content}",onRenderTemplate:null,onRenderHeader:null,cancelSelection:!0,tabIndex:!0,dateFormat:"mmddyyyy",sortMultiSortKey:"shiftKey",sortResetKey:"ctrlKey",usNumberFormat:!0,delayInit:!1,serverSideSorting:!1,resort:!0,headers:{},ignoreCase:!0,sortForce:null,sortList:[],sortAppend:null,sortStable:!1,sortInitialOrder:"asc",sortLocaleCompare:!1,sortReset:!1,sortRestart:!1,emptyTo:"bottom",stringTo:"max",textExtraction:"basic",textAttribute:"data-text",textSorter:null,numberSorter:null,widgets:[],widgetOptions:{zebra:["even","odd"]},initWidgets:!0,widgetClass:"widget-{name}",initialized:null,tableClass:"",cssAsc:"",cssDesc:"",cssNone:"",cssHeader:"",cssHeaderRow:"",cssProcessing:"",cssChildRow:"tablesorter-childRow",cssIcon:"tablesorter-icon",cssIconNone:"",cssIconAsc:"",cssIconDesc:"",cssInfoBlock:"tablesorter-infoOnly",cssNoSort:"tablesorter-noSort",cssIgnoreRow:"tablesorter-ignoreRow",pointerClick:"click",pointerDown:"mousedown",pointerUp:"mouseup",selectorHeaders:"> thead th, > thead td",selectorSort:"th, td",selectorRemove:".remove-me",debug:!1,headerList:[],empties:{},strings:{},parsers:[]},q.css={table:"tablesorter",cssHasChild:"tablesorter-hasChildRow",childRow:"tablesorter-childRow",colgroup:"tablesorter-colgroup",header:"tablesorter-header",headerRow:"tablesorter-headerRow",headerIn:"tablesorter-header-inner",icon:"tablesorter-icon",processing:"tablesorter-processing",sortAsc:"tablesorter-headerAsc",sortDesc:"tablesorter-headerDesc",sortNone:"tablesorter-headerUnSorted"},q.language={sortAsc:"Ascending sort applied, ",sortDesc:"Descending sort applied, ",sortNone:"No sort applied, ",nextAsc:"activate to apply an ascending sort",nextDesc:"activate to apply a descending sort",nextNone:"activate to remove the sort"},q.regex={templateContent:/\{content\}/g,templateIcon:/\{icon\}/g,templateName:/\{name\}/i,spaces:/\s+/g,nonWord:/\W/g,formElements:/(input|select|button|textarea)/i},q.instanceMethods={},q.isEmptyObject=function(a){for(var b in a)return!1;return!0},q.getElementText=function(b,c,d){if(!c)return"";var e,f=b.textExtraction||"",g=c.jquery?c:a(c);return"string"==typeof f?"basic"===f&&"undefined"!=typeof(e=g.attr(b.textAttribute))?a.trim(e):a.trim(c.textContent||g.text()):"function"==typeof f?a.trim(f(g[0],b.table,d)):"function"==typeof(e=q.getColumnData(b.table,f,d))?a.trim(e(g[0],b.table,d)):a.trim(g[0].textContent||g.text())},q.getParsedText=function(a,b,c,d){"undefined"==typeof d&&(d=q.getElementText(a,b,c));var e=""+d,f=a.parsers[c],g=a.extractors[c];return f&&(g&&"function"==typeof g.format&&(d=g.format(d,a.table,b,c)),e="no-parser"===f.id?"":f.format(""+d,a.table,b,c),a.ignoreCase&&"string"==typeof e&&(e=e.toLowerCase())),e},q.construct=function(b){return this.each(function(){var c=this,d=a.extend(!0,{},q.defaults,b,q.instanceMethods);d.originalSettings=b,!c.hasInitialized&&q.buildTable&&"TABLE"!==this.nodeName?q.buildTable(c,d):q.setup(c,d)})},q.setup=function(b,e){if(!b||!b.tHead||0===b.tBodies.length||b.hasInitialized===!0)return void(e.debug&&(b.hasInitialized?console.warn("Stopping initialization. Tablesorter has already been initialized"):console.error("Stopping initialization! No table, thead or tbody")));var g="",h=a(b),j=a.metadata;b.hasInitialized=!1,b.isProcessing=!0,b.config=e,a.data(b,"tablesorter",e),e.debug&&(console[console.group?"group":"log"]("Initializing tablesorter"),a.data(b,"startoveralltimer",new Date)),e.supportsDataObject=function(a){return a[0]=parseInt(a[0],10),a[0]>1||1===a[0]&&parseInt(a[1],10)>=4}(a.fn.jquery.split(".")),e.string={max:1,min:-1,emptymin:1,emptymax:-1,zero:0,none:0,"null":0,top:!0,bottom:!1},e.emptyTo=e.emptyTo.toLowerCase(),e.stringTo=e.stringTo.toLowerCase(),/tablesorter\-/.test(h.attr("class"))||(g=""!==e.theme?" tablesorter-"+e.theme:""),e.table=b,e.$table=h.addClass(q.css.table+" "+e.tableClass+g).attr("role","grid"),e.$headers=h.find(e.selectorHeaders),e.namespace?e.namespace="."+e.namespace.replace(q.regex.nonWord,""):e.namespace=".tablesorter"+Math.random().toString(16).slice(2),e.$table.children().children("tr").attr("role","row"),e.$tbodies=h.children("tbody:not(."+e.cssInfoBlock+")").attr({"aria-live":"polite","aria-relevant":"all"}),e.$table.children("caption").length&&(g=e.$table.children("caption")[0],g.id||(g.id=e.namespace.slice(1)+"caption"),e.$table.attr("aria-labelledby",g.id)),e.widgetInit={},e.textExtraction=e.$table.attr("data-text-extraction")||e.textExtraction||"basic",f(e),q.fixColumnWidth(b),q.applyWidgetOptions(b,e),c(e),e.totalRows=0,e.delayInit||d(b),q.bindEvents(b,e.$headers,!0),p(b),e.supportsDataObject&&"undefined"!=typeof h.data().sortlist?e.sortList=h.data().sortlist:j&&h.metadata()&&h.metadata().sortlist&&(e.sortList=h.metadata().sortlist),q.applyWidget(b,!0),e.sortList.length>0?h.trigger("sorton",[e.sortList,{},!e.initWidgets,!0]):(i(b),e.initWidgets&&q.applyWidget(b,!1)),e.showProcessing&&h.unbind("sortBegin"+e.namespace+" sortEnd"+e.namespace).bind("sortBegin"+e.namespace+" sortEnd"+e.namespace,function(a){clearTimeout(e.processTimer),q.isProcessing(b),"sortBegin"===a.type&&(e.processTimer=setTimeout(function(){q.isProcessing(b,!0)},500))}),b.hasInitialized=!0,b.isProcessing=!1,e.debug&&(console.log("Overall initialization time: "+q.benchmark(a.data(b,"startoveralltimer"))),e.debug&&console.groupEnd&&console.groupEnd()),h.trigger("tablesorter-initialized",b),"function"==typeof e.initialized&&e.initialized(b)},q.fixColumnWidth=function(b){b=a(b)[0];var c,d,e,f,g,h=b.config,i=h.$table.children("colgroup");if(i.length&&i.hasClass(q.css.colgroup)&&i.remove(),h.widthFixed&&0===h.$table.children("colgroup").length){for(i=a(''),c=h.$table.width(),e=h.$tbodies.find("tr:first").children(":visible"),f=e.length,g=0;f>g;g++)d=parseInt(e.eq(g).width()/c*1e3,10)/10+"%",i.append(a("").css("width",d));h.$table.prepend(i)}},q.getColumnData=function(b,c,d,e,f){if("undefined"!=typeof c&&null!==c){b=a(b)[0];var g,h,i=b.config,j=f||i.$headers,k=i.$headerIndexed&&i.$headerIndexed[d]||j.filter('[data-column="'+d+'"]:last');if(c[d])return e?c[d]:c[j.index(k)];for(h in c)if("string"==typeof h&&(g=k.filter(h).add(k.find(h)),g.length))return c[h]}},q.computeColumnIndex=function(b){var c,d,e,f,g,h,i,j,k,l,m,n,o=[],p=[],q={};for(c=0;ce;e++)for("undefined"==typeof o[e]&&(o[e]=[]),p=o[e],f=n;n+m>f;f++)p[f]="x"}return p.length},q.isProcessing=function(b,c,d){b=a(b);var e=b[0].config,f=d||b.find("."+q.css.header);c?("undefined"!=typeof d&&e.sortList.length>0&&(f=f.filter(function(){return this.sortDisabled?!1:q.isValueInArray(parseFloat(a(this).attr("data-column")),e.sortList)>=0})),b.add(f).addClass(q.css.processing+" "+e.cssProcessing)):b.add(f).removeClass(q.css.processing+" "+e.cssProcessing)},q.processTbody=function(b,c,d){b=a(b)[0];var e;return d?(b.isProcessing=!0,c.before(''),e=a.fn.detach?c.detach():c.remove()):(e=a(b).find("colgroup.tablesorter-savemyplace"),c.insertAfter(e),e.remove(),void(b.isProcessing=!1))},q.clearTableBody=function(b){a(b)[0].config.$tbodies.children().detach()},q.bindEvents=function(b,c,e){b=a(b)[0];var f,g=null,h=b.config;e!==!0&&(c.addClass(h.namespace.slice(1)+"_extra_headers"),f=a.fn.closest?c.closest("table")[0]:c.parents("table")[0],f&&"TABLE"===f.nodeName&&f!==b&&a(f).addClass(h.namespace.slice(1)+"_extra_table")),f=(h.pointerDown+" "+h.pointerUp+" "+h.pointerClick+" sort keyup ").replace(q.regex.spaces," ").split(" ").join(h.namespace+" "),c.find(h.selectorSort).add(c.filter(h.selectorSort)).unbind(f).bind(f,function(c,e){var f,i,j,k=a(c.target),m=" "+c.type+" ";if(!(1!==(c.which||c.button)&&!m.match(" "+h.pointerClick+" | sort | keyup ")||" keyup "===m&&13!==c.which||m.match(" "+h.pointerClick+" ")&&"undefined"!=typeof c.which||m.match(" "+h.pointerUp+" ")&&g!==c.target&&e!==!0)){if(m.match(" "+h.pointerDown+" "))return g=c.target,j=k.jquery.split("."),void("1"===j[0]&&j[1]<4&&c.preventDefault());if(g=null,q.regex.formElements.test(c.target.nodeName)||k.hasClass(h.cssNoSort)||k.parents("."+h.cssNoSort).length>0||k.parents("button").length>0)return!h.cancelSelection;h.delayInit&&q.isEmptyObject(h.cache)&&d(b),f=a.fn.closest?a(this).closest("th, td"):/TH|TD/.test(this.nodeName)?a(this):a(this).parents("th, td"),i=h.$headers[f.prevAll().length],i&&!i.sortDisabled&&l(b,i,c)}}),h.cancelSelection&&c.attr("unselectable","on").bind("selectstart",!1).css({"user-select":"none",MozUserSelect:"none"})},q.sortReset=function(b,c){var d=b.table;b.sortList=[],i(d),m(d),q.appendCache(b),a.isFunction(c)&&c(d)},q.updateAll=function(a,b,c){var d=a.table;d.isUpdating=!0,q.refreshWidgets(d,!0,!0),f(a),q.bindEvents(d,a.$headers,!0),p(d),g(d,b,c)},q.update=function(a,b,c){var d=a.table;d.isUpdating=!0,h(d),g(d,b,c)},q.updateHeaders=function(a,b){a.table.isUpdating=!0,f(a),q.bindEvents(a.table,a.$headers,!0),n(a,b)},q.updateCell=function(b,c,d,e){b.table.isUpdating=!0,b.$table.find(b.selectorRemove).remove();var f,g,h,i,j=(b.table,b.$tbodies),k=a(c),l=j.index(a.fn.closest?k.closest("tbody"):k.parents("tbody").filter(":first")),m=b.cache[l],p=a.fn.closest?k.closest("tr"):k.parents("tr").filter(":first");c=k[0],j.length&&l>=0&&(g=j.eq(l).find("tr").index(p),i=m.normalized[g],h=k.index(),f=q.getParsedText(b,c,h),i[h]=f,i[b.columns].$row=p,"numeric"===(b.parsers[h].type||"").toLowerCase()&&(m.colMax[h]=Math.max(Math.abs(f)||0,m.colMax[h]||0)),f="undefined"!==d?d:b.resort,f!==!1?o(b,f,e):n(b,e))},q.addRows=function(b,d,e,f){var i,j,k,l,m,n,p,r="string"==typeof d&&1===b.$tbodies.length&&/i;i++){for(k=d[i].cells.length,m=[],l={child:[],$row:d.eq(i),order:b.cache[p].normalized.length},j=0;k>j;j++)m[j]=q.getParsedText(b,d[i].cells[j],j),"numeric"===(b.parsers[j].type||"").toLowerCase()&&(b.cache[p].colMax[j]=Math.max(Math.abs(m[j])||0,b.cache[p].colMax[j]||0));m.push(l),b.cache[p].normalized.push(m)}o(b,e,f)}},q.updateCache=function(a,b,e){a.parsers&&a.parsers.length||c(a,e),d(a.table,b,e)},q.appendCache=function(a,b){var c,d,e,f,g,h,i,j=a.table,k=a.widgetOptions,l=a.$tbodies,m=[],n=a.cache;if(q.isEmptyObject(n))return a.appender?a.appender(j,m):j.isUpdating?a.$table.trigger("updateComplete",j):"";for(a.debug&&(i=new Date),h=0;hg;g++)m.push(c[g][a.columns].$row),a.appender&&(!a.pager||a.pager.removeRows&&k.pager_removeRows||a.pager.ajax)||f.append(c[g][a.columns].$row);q.processTbody(j,f,!1)}a.appender&&a.appender(j,m),a.debug&&console.log("Rebuilt table"+q.benchmark(i)),b||a.appender||q.applyWidget(j),j.isUpdating&&a.$table.trigger("updateComplete",j)},q.sortOn=function(b,c,e,f){var g=b.table;b.$table.trigger("sortStart",g),j(g,c),i(g),b.delayInit&&q.isEmptyObject(b.cache)&&d(g),b.$table.trigger("sortBegin",g),m(g),q.appendCache(b,f),b.$table.trigger("sortEnd",g),q.applyWidget(g),a.isFunction(e)&&e(g)},q.restoreHeaders=function(b){var c,d,e=a(b)[0].config,f=e.$table.find(e.selectorHeaders),g=f.length;for(c=0;g>c;c++)d=f.eq(c),d.find("."+q.css.headerIn).length&&d.html(e.headerContent[c])},q.destroy=function(b,c,d){if(b=a(b)[0],b.hasInitialized){q.removeWidget(b,!0,!1);var e,f=a(b),g=b.config,h=g.debug,i=f.find("thead:first"),j=i.find("tr."+q.css.headerRow).removeClass(q.css.headerRow+" "+g.cssHeaderRow),k=f.find("tfoot:first > tr").children("th, td");c===!1&&a.inArray("uitheme",g.widgets)>=0&&(f.trigger("applyWidgetId",["uitheme"]),f.trigger("applyWidgetId",["zebra"])),i.find("tr").not(j).remove(),e="sortReset update updateRows updateAll updateHeaders updateCell addRows updateComplete sorton appendCache updateCache applyWidgetId applyWidgets refreshWidgets destroy mouseup mouseleave keypress "+"sortBegin sortEnd resetToLoadState ".split(" ").join(g.namespace+" "),f.removeData("tablesorter").unbind(e.replace(q.regex.spaces," ")),g.$headers.add(k).removeClass([q.css.header,g.cssHeader,g.cssAsc,g.cssDesc,q.css.sortAsc,q.css.sortDesc,q.css.sortNone].join(" ")).removeAttr("data-column").removeAttr("aria-label").attr("aria-disabled","true"),j.find(g.selectorSort).unbind("mousedown mouseup keypress ".split(" ").join(g.namespace+" ").replace(q.regex.spaces," ")),q.restoreHeaders(b),f.toggleClass(q.css.table+" "+g.tableClass+" tablesorter-"+g.theme,c===!1),b.hasInitialized=!1,delete b.config.cache,"function"==typeof d&&d(b),h&&console.log("tablesorter has been removed")}},q.regex.chunk=/(^([+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?)?$|^0x[0-9a-f]+$|\d+)/gi,q.regex.chunks=/(^\\0|\\0$)/,q.regex.hex=/^0x[0-9a-f]+$/i,q.sortNatural=function(a,b){if(a===b)return 0;var c,d,e,f,g,h,i,j,k=q.regex;if(k.hex.test(b)){if(d=parseInt(a.match(k.hex),16),f=parseInt(b.match(k.hex),16),f>d)return-1;if(d>f)return 1}for(c=a.replace(k.chunk,"\\0$1\\0").replace(k.chunks,"").split("\\0"),e=b.replace(k.chunk,"\\0$1\\0").replace(k.chunks,"").split("\\0"),j=Math.max(c.length,e.length),i=0;j>i;i++){if(g=isNaN(c[i])?c[i]||0:parseFloat(c[i])||0,h=isNaN(e[i])?e[i]||0:parseFloat(e[i])||0,isNaN(g)!==isNaN(h))return isNaN(g)?1:-1;if(typeof g!=typeof h&&(g+="",h+=""),h>g)return-1;if(g>h)return 1}return 0},q.sortNaturalAsc=function(a,b,c,d,e){if(a===b)return 0;var f=e.string[e.empties[c]||e.emptyTo];return""===a&&0!==f?"boolean"==typeof f?f?-1:1:-f||-1:""===b&&0!==f?"boolean"==typeof f?f?1:-1:f||1:q.sortNatural(a,b)},q.sortNaturalDesc=function(a,b,c,d,e){if(a===b)return 0;var f=e.string[e.empties[c]||e.emptyTo];return""===a&&0!==f?"boolean"==typeof f?f?-1:1:f||1:""===b&&0!==f?"boolean"==typeof f?f?1:-1:-f||-1:q.sortNatural(b,a)},q.sortText=function(a,b){return a>b?1:b>a?-1:0},q.getTextValue=function(a,b,c){if(c){var d,e=a?a.length:0,f=c+b;for(d=0;e>d;d++)f+=a.charCodeAt(d);return b*f}return 0},q.sortNumericAsc=function(a,b,c,d,e,f){if(a===b)return 0;var g=f.config,h=g.string[g.empties[e]||g.emptyTo];return""===a&&0!==h?"boolean"==typeof h?h?-1:1:-h||-1:""===b&&0!==h?"boolean"==typeof h?h?1:-1:h||1:(isNaN(a)&&(a=q.getTextValue(a,c,d)),isNaN(b)&&(b=q.getTextValue(b,c,d)),a-b)},q.sortNumericDesc=function(a,b,c,d,e,f){if(a===b)return 0;var g=f.config,h=g.string[g.empties[e]||g.emptyTo];return""===a&&0!==h?"boolean"==typeof h?h?-1:1:h||1:""===b&&0!==h?"boolean"==typeof h?h?1:-1:-h||-1:(isNaN(a)&&(a=q.getTextValue(a,c,d)),isNaN(b)&&(b=q.getTextValue(b,c,d)),b-a)},q.sortNumeric=function(a,b){return a-b},q.characterEquivalents={a:"áàâãäąå",A:"ÁÀÂÃÄĄÅ",c:"çćč",C:"ÇĆČ",e:"éèêëěę",E:"ÉÈÊËĚĘ",i:"íìİîïı",I:"ÍÌİÎÏ",o:"óòôõöō",O:"ÓÒÔÕÖŌ",ss:"ß",SS:"ẞ",u:"úùûüů",U:"ÚÙÛÜŮ"},q.replaceAccents=function(a){var b,c="[",d=q.characterEquivalents;if(!q.characterRegex){q.characterRegexArray={};for(b in d)"string"==typeof b&&(c+=d[b],q.characterRegexArray[b]=new RegExp("["+d[b]+"]","g"));q.characterRegex=new RegExp(c+"]")}if(q.characterRegex.test(a))for(b in d)"string"==typeof b&&(a=a.replace(q.characterRegexArray[b],b));return a},q.isValueInArray=function(a,b){var c,d=b&&b.length||0;for(c=0;d>c;c++)if(b[c][0]===a)return c;return-1},q.addParser=function(a){var b,c=q.parsers.length,d=!0;for(b=0;c>b;b++)q.parsers[b].id.toLowerCase()===a.id.toLowerCase()&&(d=!1);d&&q.parsers.push(a)},q.addInstanceMethods=function(b){a.extend(q.instanceMethods,b)},q.getParserById=function(a){if("false"==a)return!1;var b,c=q.parsers.length;for(b=0;c>b;b++)if(q.parsers[b].id.toLowerCase()===a.toString().toLowerCase())return q.parsers[b];return!1},q.addWidget=function(a){q.widgets.push(a)},q.hasWidget=function(b,c){return b=a(b),b.length&&b[0].config&&b[0].config.widgetInit[c]||!1},q.getWidgetById=function(a){var b,c,d=q.widgets.length;for(b=0;d>b;b++)if(c=q.widgets[b],c&&c.hasOwnProperty("id")&&c.id.toLowerCase()===a.toLowerCase())return c},q.applyWidgetOptions=function(b,c){var d,e,f=c.widgets.length,g=c.widgetOptions;if(f)for(d=0;f>d;d++)e=q.getWidgetById(c.widgets[d]),e&&"options"in e&&(g=b.config.widgetOptions=a.extend(!0,{},e.options,g))},q.applyWidget=function(b,c,d){b=a(b)[0];var e,f,g,h,i,j,k,l,m,n,o=b.config,p=o.widgetOptions,r=" "+o.table.className+" ",s=[];if(c===!1||!b.hasInitialized||!b.isApplyingWidgets&&!b.isUpdating){if(o.debug&&(k=new Date),n=new RegExp("\\s"+o.widgetClass.replace(q.regex.templateName,"([\\w-]+)")+"\\s","g"),r.match(n)&&(m=r.match(n)))for(f=m.length,e=0;f>e;e++)o.widgets.push(m[e].replace(n,"$1"));if(o.widgets.length){for(b.isApplyingWidgets=!0,o.widgets=a.grep(o.widgets,function(b,c){return a.inArray(b,o.widgets)===c}),g=o.widgets||[],f=g.length,e=0;f>e;e++)n=q.getWidgetById(g[e]),n&&n.id&&(n.priority||(n.priority=10),s[e]=n);for(s.sort(function(a,b){return a.prioritye;e++)h=s[e],h&&(i=h.id,j=!1,o.debug&&(l=new Date),(c||!o.widgetInit[i])&&(o.widgetInit[i]=!0,b.hasInitialized&&q.applyWidgetOptions(b,o),"init"in h&&(j=!0,o.debug&&console[console.group?"group":"log"]("Initializing "+i+" widget"),h.init(b,h,o,p))),!c&&"format"in h&&(j=!0,o.debug&&console[console.group?"group":"log"]("Updating "+i+" widget"),h.format(b,o,p,!1)),o.debug&&j&&(console.log("Completed "+(c?"initializing ":"applying ")+i+" widget"+q.benchmark(l)),console.groupEnd&&console.groupEnd()));o.debug&&console.groupEnd&&console.groupEnd(),c||"function"!=typeof d||d(b)}setTimeout(function(){b.isApplyingWidgets=!1,a.data(b,"lastWidgetApplication",new Date)},0),o.debug&&(m=o.widgets.length,console.log("Completed "+(c===!0?"initializing ":"applying ")+m+" widget"+(1!==m?"s":"")+q.benchmark(k)))}},q.removeWidget=function(b,c,d){b=a(b)[0];var e,f,g,h,i=b.config;if(c===!0)for(c=[],h=q.widgets.length,g=0;h>g;g++)f=q.widgets[g],f&&f.id&&c.push(f.id);else c=(a.isArray(c)?c.join(","):c||"").toLowerCase().split(/[\s,]+/);for(h=c.length,e=0;h>e;e++)f=q.getWidgetById(c[e]),g=a.inArray(c[e],i.widgets),f&&"remove"in f&&(i.debug&&g>=0&&console.log('Removing "'+c[e]+'" widget'),i.debug&&console.log((d?"Refreshing":"Removing")+' "'+c[e]+'" widget'),f.remove(b,i,i.widgetOptions,d),i.widgetInit[c[e]]=!1),g>=0&&d!==!0&&i.widgets.splice(g,1)},q.refreshWidgets=function(b,c,d){b=a(b)[0];var e,f=b.config,g=f.widgets,h=q.widgets,i=h.length,j=[],k=function(b){a(b).trigger("refreshComplete")};for(e=0;i>e;e++)h[e]&&h[e].id&&(c||a.inArray(h[e].id,g)<0)&&j.push(h[e].id);q.removeWidget(b,j.join(","),!0),d!==!0?(q.applyWidget(b,c||!1,k),c&&q.applyWidget(b,!1,k)):k(b)},q.getColumnText=function(b,c,d){b=a(b)[0];var e,f,g,h,i,j,k,l,m,n,o="function"==typeof d,p="all"===c,r={raw:[],parsed:[],$cell:[]},s=b.config;if(!q.isEmptyObject(s)){for(i=s.$tbodies.length,e=0;i>e;e++)for(g=s.cache[e].normalized,j=g.length,f=0;j>f;f++)n=!0,h=g[f],l=p?h.slice(0,s.columns):h[c],h=h[s.columns],k=p?h.raw:h.raw[c],m=p?h.$row.children():h.$row.children().eq(c),o&&(n=d({tbodyIndex:e,rowIndex:f,parsed:l,raw:k,$row:h.$row,$cell:m})),n!==!1&&(r.parsed.push(l),r.raw.push(k),r.$cell.push(m));return r}s.debug&&console.warn("No cache found - aborting getColumnText function!")},q.getData=function(b,c,d){var e,f,g="",h=a(b);return h.length?(e=a.metadata?h.metadata():!1,f=" "+(h.attr("class")||""),"undefined"!=typeof h.data(d)||"undefined"!=typeof h.data(d.toLowerCase())?g+=h.data(d)||h.data(d.toLowerCase()):e&&"undefined"!=typeof e[d]?g+=e[d]:c&&"undefined"!=typeof c[d]?g+=c[d]:" "!==f&&f.match(" "+d+"-")&&(g=f.match(new RegExp("\\s"+d+"-([\\w-]+)"))[1]||""),
+a.trim(g)):""},q.regex.comma=/,/g,q.regex.digitNonUS=/[\s|\.]/g,q.regex.digitNegativeTest=/^\s*\([.\d]+\)/,q.regex.digitNegativeReplace=/^\s*\(([.\d]+)\)/,q.formatFloat=function(b,c){if("string"!=typeof b||""===b)return b;var d,e=c&&c.config?c.config.usNumberFormat!==!1:"undefined"!=typeof c?c:!0;return b=e?b.replace(q.regex.comma,""):b.replace(q.regex.digitNonUS,"").replace(q.regex.comma,"."),q.regex.digitNegativeTest.test(b)&&(b=b.replace(q.regex.digitNegativeReplace,"-$1")),d=parseFloat(b),isNaN(d)?a.trim(b):d},q.regex.digitTest=/^[\-+(]?\d+[)]?$/,q.regex.digitReplace=/[,.'"\s]/g,q.isDigit=function(a){return isNaN(a)?q.regex.digitTest.test(a.toString().replace(q.regex.digitReplace,"")):""!==a}}});var b=a.tablesorter;a.fn.extend({tablesorter:b.construct}),console&&console.log||(b.logs=[],console={},console.log=console.warn=console.error=console.table=function(){b.logs.push([Date.now(),arguments])}),b.log=function(){console.log(arguments)},b.benchmark=function(a){return" ("+((new Date).getTime()-a.getTime())+"ms)"},b.addParser({id:"no-parser",is:function(){return!1},format:function(){return""},type:"text"}),b.addParser({id:"text",is:function(){return!0},format:function(c,d){var e=d.config;return c&&(c=a.trim(e.ignoreCase?c.toLocaleLowerCase():c),c=e.sortLocaleCompare?b.replaceAccents(c):c),c},type:"text"}),b.regex.nondigit=/[^\w,. \-()]/g,b.addParser({id:"digit",is:function(a){return b.isDigit(a)},format:function(c,d){var e=b.formatFloat((c||"").replace(b.regex.nondigit,""),d);return c&&"number"==typeof e?e:c?a.trim(c&&d.config.ignoreCase?c.toLocaleLowerCase():c):c},type:"numeric"}),b.regex.currencyReplace=/[+\-,. ]/g,b.regex.currencyTest=/^\(?\d+[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]|[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]\d+\)?$/,b.addParser({id:"currency",is:function(a){return a=(a||"").replace(b.regex.currencyReplace,""),b.regex.currencyTest.test(a)},format:function(c,d){var e=b.formatFloat((c||"").replace(b.regex.nondigit,""),d);return c&&"number"==typeof e?e:c?a.trim(c&&d.config.ignoreCase?c.toLocaleLowerCase():c):c},type:"numeric"}),b.regex.urlProtocolTest=/^(https?|ftp|file):\/\//,b.regex.urlProtocolReplace=/(https?|ftp|file):\/\//,b.addParser({id:"url",is:function(a){return b.regex.urlProtocolTest.test(a)},format:function(c){return c?a.trim(c.replace(b.regex.urlProtocolReplace,"")):c},parsed:!0,type:"text"}),b.regex.dash=/-/g,b.regex.isoDate=/^\d{4}[\/\-]\d{1,2}[\/\-]\d{1,2}/,b.addParser({id:"isoDate",is:function(a){return b.regex.isoDate.test(a)},format:function(a,c){var d=a?new Date(a.replace(b.regex.dash,"/")):a;return d instanceof Date&&isFinite(d)?d.getTime():a},type:"numeric"}),b.regex.percent=/%/g,b.regex.percentTest=/(\d\s*?%|%\s*?\d)/,b.addParser({id:"percent",is:function(a){return b.regex.percentTest.test(a)&&a.length<15},format:function(a,c){return a?b.formatFloat(a.replace(b.regex.percent,""),c):a},type:"numeric"}),b.addParser({id:"image",is:function(a,b,c,d){return d.find("img").length>0},format:function(b,c,d){return a(d).find("img").attr(c.config.imgAttr||"alt")||b},parsed:!0,type:"text"}),b.regex.dateReplace=/(\S)([AP]M)$/i,b.regex.usLongDateTest1=/^[A-Z]{3,10}\.?\s+\d{1,2},?\s+(\d{4})(\s+\d{1,2}:\d{2}(:\d{2})?(\s+[AP]M)?)?$/i,b.regex.usLongDateTest2=/^\d{1,2}\s+[A-Z]{3,10}\s+\d{4}/i,b.addParser({id:"usLongDate",is:function(a){return b.regex.usLongDateTest1.test(a)||b.regex.usLongDateTest2.test(a)},format:function(a,c){var d=a?new Date(a.replace(b.regex.dateReplace,"$1 $2")):a;return d instanceof Date&&isFinite(d)?d.getTime():a},type:"numeric"}),b.regex.shortDateTest=/(^\d{1,2}[\/\s]\d{1,2}[\/\s]\d{4})|(^\d{4}[\/\s]\d{1,2}[\/\s]\d{1,2})/,b.regex.shortDateReplace=/[\-.,]/g,b.regex.shortDateXXY=/(\d{1,2})[\/\s](\d{1,2})[\/\s](\d{4})/,b.regex.shortDateYMD=/(\d{4})[\/\s](\d{1,2})[\/\s](\d{1,2})/,b.addParser({id:"shortDate",is:function(a){return a=(a||"").replace(b.regex.spaces," ").replace(b.regex.shortDateReplace,"/"),b.regex.shortDateTest.test(a)},format:function(a,c,d,e){if(a){var f,g,h=c.config,i=h.$headerIndexed[e],j=i.length&&i[0].dateFormat||b.getData(i,b.getColumnData(c,h.headers,e),"dateFormat")||h.dateFormat;return g=a.replace(b.regex.spaces," ").replace(b.regex.shortDateReplace,"/"),"mmddyyyy"===j?g=g.replace(b.regex.shortDateXXY,"$3/$1/$2"):"ddmmyyyy"===j?g=g.replace(b.regex.shortDateXXY,"$3/$2/$1"):"yyyymmdd"===j&&(g=g.replace(b.regex.shortDateYMD,"$1/$2/$3")),f=new Date(g),f instanceof Date&&isFinite(f)?f.getTime():a}return a},type:"numeric"}),b.regex.timeTest=/^(([0-2]?\d:[0-5]\d)|([0-1]?\d:[0-5]\d\s?([AP]M)))$/i,b.addParser({id:"time",is:function(a){return b.regex.timeTest.test(a)},format:function(a,c){var d=a?new Date("2000/01/01 "+a.replace(b.regex.dateReplace,"$1 $2")):a;return d instanceof Date&&isFinite(d)?d.getTime():a},type:"numeric"}),b.addParser({id:"metadata",is:function(){return!1},format:function(b,c,d){var e=c.config,f=e.parserMetadataName?e.parserMetadataName:"sortValue";return a(d).metadata()[f]},type:"numeric"}),b.addWidget({id:"zebra",priority:90,format:function(b,c,d){var e,f,g,h,i,j,k,l,m=new RegExp(c.cssChildRow,"i"),n=c.$tbodies.add(a(c.namespace+"_extra_table").children("tbody:not(."+c.cssInfoBlock+")"));for(c.debug&&(i=new Date),j=0;jk;k++)f=e.eq(k),m.test(f[0].className)||g++,h=g%2===0,f.removeClass(d.zebra[h?1:0]).addClass(d.zebra[h?0:1])},remove:function(a,c,d,e){if(!e){var f,g,h=c.$tbodies,i=(d.zebra||["even","odd"]).join(" ");for(f=0;f')}),d.cssIcon&&t.find("."+b.css.icon).removeClass(q?[n.icons,p].join(" "):"").addClass(v.icons||""),s.hasClass("hasFilters")&&s.children("thead").children("."+b.css.filterRow).removeClass(q?n.filterRow||"":"").addClass(v.filterRow||"")),f=0;f1)))for(m=1;q>m;m++)k.eq(p[m][0]).addClass(r[m]||r[s])}),b.processTbody(c,f,!1);if(i=e.columns_thead!==!1?["thead tr"]:[],e.columns_tfoot!==!1&&i.push("tfoot tr"),i.length&&(h=n.find(i.join(",")).children().removeClass(l),q))for(m=0;q>m;m++)h.filter('[data-column="'+p[m][0]+'"]').addClass(r[m]||r[s])},remove:function(c,d,e){var f,g,h=d.$tbodies,i=(e.columns||["primary","secondary","tertiary"]).join(" ");for(d.$headers.removeClass(i),d.$table.children("tfoot").children("tr").children("th, td").removeClass(i),f=0;f=]/g,query:"(q|query)",wild01:/\?/g,wild0More:/\*/g,quote:/\"/g,isNeg1:/(>=?\s*-\d)/,isNeg2:/(<=?\s*\d)/},types:{or:function(c,d,e){if(b.regex.orTest.test(d.iFilter)||b.regex.orSplit.test(d.filter)){var f,g,h,i,j=a.extend({},d),k=d.index,l=d.parsed[k],m=d.filter.split(b.regex.orSplit),n=d.iFilter.split(b.regex.orSplit),o=m.length;for(f=0;o>f;f++){j.nestedFilters=!0,j.filter=""+(b.parseFilter(c,m[f],k,l)||""),j.iFilter=""+(b.parseFilter(c,n[f],k,l)||""),h="("+(b.parseFilter(c,j.filter,k,l)||"")+")";try{if(i=new RegExp(d.isMatch?h:"^"+h+"$",c.widgetOptions.filter_ignoreCase?"i":""),g=i.test(j.exact)||b.processTypes(c,j,e))return g}catch(p){return null}}return g||!1}return null},and:function(c,d,e){if(b.regex.andTest.test(d.filter)){var f,g,h,i,j,k=a.extend({},d),l=d.index,m=d.parsed[l],n=d.filter.split(b.regex.andSplit),o=d.iFilter.split(b.regex.andSplit),p=n.length;for(f=0;p>f;f++){k.nestedFilters=!0,k.filter=""+(b.parseFilter(c,n[f],l,m)||""),k.iFilter=""+(b.parseFilter(c,o[f],l,m)||""),i=("("+(b.parseFilter(c,k.filter,l,m)||"")+")").replace(b.regex.wild01,"\\S{1}").replace(b.regex.wild0More,"\\S*");try{j=new RegExp(d.isMatch?i:"^"+i+"$",c.widgetOptions.filter_ignoreCase?"i":""),h=j.test(k.exact)||b.processTypes(c,k,e),g=0===f?h:g&&h}catch(q){return null}}return g||!1}return null},regex:function(a,c){if(b.regex.regex.test(c.filter)){var d,e=c.filter_regexCache[c.index]||b.regex.regex.exec(c.filter),f=e instanceof RegExp;try{f||(c.filter_regexCache[c.index]=e=new RegExp(e[1],e[2])),d=e.test(c.exact)}catch(g){d=!1}return d}return null},operators:function(d,e){if(b.regex.operTest.test(e.iFilter)&&""!==e.iExact){var f,g,h,i=d.table,j=e.index,k=e.parsed[j],l=c.formatFloat(e.iFilter.replace(b.regex.operators,""),i),m=d.parsers[j],n=l;return(k||"numeric"===m.type)&&(h=a.trim(""+e.iFilter.replace(b.regex.operators,"")),g=b.parseFilter(d,h,j,!0),l="number"!=typeof g||""===g||isNaN(g)?l:g),!k&&"numeric"!==m.type||isNaN(l)||"undefined"==typeof e.cache?(h=isNaN(e.iExact)?e.iExact.replace(c.regex.nondigit,""):e.iExact,f=c.formatFloat(h,i)):f=e.cache,b.regex.gtTest.test(e.iFilter)?g=b.regex.gteTest.test(e.iFilter)?f>=l:f>l:b.regex.ltTest.test(e.iFilter)&&(g=b.regex.lteTest.test(e.iFilter)?l>=f:l>f),g||""!==n||(g=!0),g}return null},notMatch:function(c,d){if(b.regex.notTest.test(d.iFilter)){var e,f=d.iFilter.replace("!",""),g=b.parseFilter(c,f,d.index,d.parsed[d.index])||"";return b.regex.exact.test(g)?(g=g.replace(b.regex.exact,""),""===g?!0:a.trim(g)!==d.iExact):(e=d.iExact.search(a.trim(g)),""===g?!0:!(c.widgetOptions.filter_startsWith?0===e:e>=0))}return null},exact:function(c,d){if(b.regex.exact.test(d.iFilter)){var e=d.iFilter.replace(b.regex.exact,""),f=b.parseFilter(c,e,d.index,d.parsed[d.index])||"";return d.anyMatch?a.inArray(f,d.rowArray)>=0:f==d.iExact}return null},range:function(a,d){if(b.regex.toTest.test(d.iFilter)){var e,f,g,h,i=a.table,j=d.index,k=d.parsed[j],l=d.iFilter.split(b.regex.toSplit);return f=l[0].replace(c.regex.nondigit,"")||"",g=c.formatFloat(b.parseFilter(a,f,j,k),i),f=l[1].replace(c.regex.nondigit,"")||"",h=c.formatFloat(b.parseFilter(a,f,j,k),i),(k||"numeric"===a.parsers[j].type)&&(e=a.parsers[j].format(""+l[0],i,a.$headers.eq(j),j),g=""===e||isNaN(e)?g:e,e=a.parsers[j].format(""+l[1],i,a.$headers.eq(j),j),h=""===e||isNaN(e)?h:e),!k&&"numeric"!==a.parsers[j].type||isNaN(g)||isNaN(h)?(f=isNaN(d.iExact)?d.iExact.replace(c.regex.nondigit,""):d.iExact,e=c.formatFloat(f,i)):e=d.cache,g>h&&(f=g,g=h,h=f),e>=g&&h>=e||""===g||""===h}return null},wild:function(a,c){if(b.regex.wildOrTest.test(c.iFilter)){var d=c.index,e=c.parsed[d],f=""+(b.parseFilter(a,c.iFilter,d,e)||"");!b.regex.wildTest.test(f)&&c.nestedFilters&&(f=c.isMatch?f:"^("+f+")$");try{return new RegExp(f.replace(b.regex.wild01,"\\S{1}").replace(b.regex.wild0More,"\\S*"),a.widgetOptions.filter_ignoreCase?"i":"").test(c.exact)}catch(g){return null}}return null},fuzzy:function(a,c){if(b.regex.fuzzyTest.test(c.iFilter)){var d,e=0,f=c.iExact.length,g=c.iFilter.slice(1),h=b.parseFilter(a,g,c.index,c.parsed[c.index])||"";for(d=0;f>d;d++)c.iExact[d]===h[e]&&(e+=1);return e===h.length?!0:!1}return null}},init:function(e,f,g){c.language=a.extend(!0,{},{to:"to",or:"or",and:"and"},c.language);var h,i,j,k,l,m,n,o,p,q=b.regex;if(f.$table.addClass("hasFilters"),g.searchTimer=null,g.filter_initTimer=null,g.filter_formatterCount=0,g.filter_formatterInit=[],g.filter_anyColumnSelector='[data-column="all"],[data-column="any"]',g.filter_multipleColumnSelector='[data-column*="-"],[data-column*=","]',n="\\{"+b.regex.query+"\\}",a.extend(q,{child:new RegExp(f.cssChildRow),filtered:new RegExp(g.filter_filteredRow),alreadyFiltered:new RegExp("(\\s+("+c.language.or+"|-|"+c.language.to+")\\s+)","i"),toTest:new RegExp("\\s+(-|"+c.language.to+")\\s+","i"),toSplit:new RegExp("(?:\\s+(?:-|"+c.language.to+")\\s+)","gi"),andTest:new RegExp("\\s+("+c.language.and+"|&&)\\s+","i"),andSplit:new RegExp("(?:\\s+(?:"+c.language.and+"|&&)\\s+)","gi"),orTest:/\|/,orSplit:new RegExp("(?:\\s+(?:"+c.language.or+")\\s+|\\|)","gi"),iQuery:new RegExp(n,"i"),igQuery:new RegExp(n,"ig"),operTest:/^[<>]=?/,gtTest:/>/,gteTest:/>=/,ltTest:/,lteTest:/<=/,notTest:/^\!/,wildOrTest:/[\?\*\|]/,wildTest:/\?\*/,fuzzyTest:/^~/,exactTest:/[=\"\|!]/}),n=f.$headers.filter(".filter-false, .parser-false").length,g.filter_columnFilters!==!1&&n!==f.$headers.length&&b.buildRow(e,f,g),j="addRows updateCell update updateRows updateComplete appendCache filterReset filterEnd search ".split(" ").join(f.namespace+"filter "),f.$table.bind(j,function(c,h){return n=g.filter_hideEmpty&&a.isEmptyObject(f.cache)&&!(f.delayInit&&"appendCache"===c.type),f.$table.find("."+d.filterRow).toggleClass(g.filter_filteredRow,n),/(search|filter)/.test(c.type)||(c.stopPropagation(),b.buildDefault(e,!0)),"filterReset"===c.type?(f.$table.find("."+d.filter).add(g.filter_$externalFilters).val(""),b.searching(e,[])):"filterEnd"===c.type?b.buildDefault(e,!0):(h="search"===c.type?h:"updateComplete"===c.type?f.$table.data("lastSearch"):"",/(update|add)/.test(c.type)&&"updateComplete"!==c.type&&(f.lastCombinedFilter=null,f.lastSearch=[]),b.searching(e,h,!0)),!1}),g.filter_reset&&(g.filter_reset instanceof a?g.filter_reset.click(function(){f.$table.trigger("filterReset")}):a(g.filter_reset).length&&a(document).undelegate(g.filter_reset,"click.tsfilter").delegate(g.filter_reset,"click.tsfilter",function(){f.$table.trigger("filterReset")})),g.filter_functions)for(l=0;l'+(k.data("placeholder")||k.attr("data-placeholder")||g.filter_placeholder.select||"")+"":"",n=i,j=i,i.indexOf(g.filter_selectSourceSeparator)>=0&&(n=i.split(g.filter_selectSourceSeparator),j=n[1],n=n[0]),h+="");f.$table.find("thead").find("select."+d.filter+'[data-column="'+l+'"]').append(h),j=g.filter_selectSource,o=a.isFunction(j)?!0:c.getColumnData(e,j,l),o&&b.buildSelect(f.table,l,"",!0,k.hasClass(g.filter_onlyAvail))}b.buildDefault(e,!0),b.bindSearch(e,f.$table.find("."+d.filter),!0),g.filter_external&&b.bindSearch(e,g.filter_external),g.filter_hideFilters&&b.hideFilters(e,f),f.showProcessing&&(j="filterStart filterEnd ".split(" ").join(f.namespace+"filter "),f.$table.unbind(j.replace(c.regex.spaces," ")).bind(j,function(b,g){k=g?f.$table.find("."+d.header).filter("[data-column]").filter(function(){return""!==g[a(this).data("column")]}):"",c.isProcessing(e,"filterStart"===b.type,g?k:"")})),f.filteredRows=f.totalRows,j="tablesorter-initialized pagerBeforeInitialized ".split(" ").join(f.namespace+"filter "),f.$table.unbind(j.replace(c.regex.spaces," ")).bind(j,function(){var a=this.config.widgetOptions;m=b.setDefaults(e,f,a)||[],m.length&&(f.delayInit&&""===m.join("")||c.setFilters(e,m,!0)),f.$table.trigger("filterFomatterUpdate"),setTimeout(function(){a.filter_initialized||b.filterInitComplete(f)},100)}),f.pager&&f.pager.initialized&&!g.filter_initialized&&(f.$table.trigger("filterFomatterUpdate"),setTimeout(function(){b.filterInitComplete(f)},100))},formatterUpdated:function(a,b){var c=a.closest("table")[0].config.widgetOptions;c.filter_initialized||(c.filter_formatterInit[b]=1)},filterInitComplete:function(c){var d,e,f=c.widgetOptions,g=0,h=function(){f.filter_initialized=!0,c.$table.trigger("filterInit",c),b.findRows(c.table,c.$table.data("lastSearch")||[])};if(a.isEmptyObject(f.filter_formatter))h();else{for(e=f.filter_formatterInit.length,d=0;e>d;d++)1===f.filter_formatterInit[d]&&g++;clearTimeout(f.filter_initTimer),f.filter_initialized||g!==f.filter_formatterCount?f.filter_initialized||(f.filter_initTimer=setTimeout(function(){h()},500)):h()}},setDefaults:function(b,d,e){var f,g,h,i,j,k=c.getFilters(b)||[];if(e.filter_saveFilters&&c.storage&&(g=c.storage(b,"tablesorter-filters")||[],f=a.isArray(g),f&&""===g.join("")||!f||(k=g)),""===k.join(""))for(j=d.$headers.add(e.filter_$externalFilters).filter("["+e.filter_defaultAttrib+"]"),h=0;h<=d.columns;h++)i=h===d.columns?"all":h,k[h]=j.filter('[data-column="'+i+'"]').attr(e.filter_defaultAttrib)||k[h]||"";return d.$table.data("lastSearch",k),k},parseFilter:function(a,b,c,d){return d?a.parsers[c].format(b,a.table,[],c):b},buildRow:function(b,e,f){var g,h,i,j,k,l,m,n,o=f.filter_cellFilter,p=e.columns,q=a.isArray(o),r='';for(h=0;p>h;h++)r+=" | ";for(e.$filters=a(r+="
").appendTo(e.$table.children("thead").eq(0)).find("td"),h=0;p>h;h++)k=!1,i=e.$headerIndexed[h],m=c.getColumnData(b,f.filter_functions,h),j=f.filter_functions&&m&&"function"!=typeof m||i.hasClass("filter-select"),g=c.getColumnData(b,e.headers,h),k="false"===c.getData(i[0],g,"filter")||"false"===c.getData(i[0],g,"parser"),j?r=a("