/*
   Copyright 2008-2014 SpryMedia Ltd.

 This source file is free software, available under the following license:
   MIT license - http://datatables.net/license

 This source file is distributed in the hope that it will be useful, but
 WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
 or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.

 For details please refer to: http://www.datatables.net
*/
(function(a){function C(c,b){var h=document.createElementNS("http://www.w3.org/2000/svg",c||"svg");b&&a.each(b,function(c,a){h.setAttributeNS(null,c,a)});return a(h)}a.fn.activity=function(e){this.each(function(){var b=a(this),h=b.data("activity");h&&(clearInterval(h.data("interval")),h.remove(),b.removeData("activity"));if(!1!==e){e=a.extend({color:b.css("color")},a.fn.activity.defaults,e);var h=k(b,e).css({position:"absolute",zIndex:e.zIndex}).prependTo(e.outside?"body":b),m=b.outerHeight()-h.height(),
q=b.outerWidth()-h.width(),m="top"==e.valign?e.padding:"bottom"==e.valign?m-e.padding:Math.floor(m/2),q="left"==e.align?e.padding:"right"==e.align?q-e.padding:Math.floor(q/2),l=b.offset();e.outside?h.css({top:l.top+"px",left:l.left+"px"}):(m-=h.offset().top-l.top,q-=h.offset().left-l.left);h.css({marginTop:m+"px",marginLeft:q+"px"});c(h,e.segments,Math.round(10/e.speed)/10);b.data("activity",h)}});return this};a.fn.activity.defaults={segments:12,space:3,length:7,width:4,speed:1.2,align:"center",valign:"center",
padding:4,zIndex:1};a.fn.activity.getOpacity=function(c,a){var b=c.steps||c.segments-1,h=void 0!==c.opacity?c.opacity:1/b;return 1-Math.min(a,b)*(1-h)/b};var k=function(){return a("<div>").addClass("busy")},c=function(){};if(document.createElementNS&&document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect)if(k=function(c,b){for(var h=2*b.width+b.space,m=h+b.length+Math.ceil(b.width/2)+1,q=C().width(2*m).height(2*m),l=C("g",{"stroke-width":b.width,"stroke-linecap":"round",stroke:b.color}).appendTo(C("g",
{transform:"translate("+m+","+m+")"}).appendTo(q)),k=0;k<b.segments;k++)l.append(C("line",{x1:0,y1:h,x2:0,y2:h+b.length,transform:"rotate("+360/b.segments*k+", 0, 0)",opacity:a.fn.activity.getOpacity(b,k)}));return a("<div>").append(q).width(2*m).height(2*m)},void 0!==document.createElement("div").style.WebkitAnimationName)var b={},c=function(c,a,h){if(!b[a]){var m=document.createElement("style");m.type="text/css";for(var q="spin"+a,l="@-webkit-keyframes "+q+" {",k=0;k<a;k++)var u=Math.round(1E5/
a*k)/1E3,y=Math.round(1E5/a*(k+1)-1)/1E3,z="% { -webkit-transform:rotate("+Math.round(360/a*k)+"deg); }\n",l=l+(u+z+y+z);m.appendChild(document.createTextNode(l+"100% { -webkit-transform:rotate(100deg); }\n}"));document.getElementsByTagName("head")[0].appendChild(m);b[a]=q}c.css("-webkit-animation",b[a]+" "+h+"s linear infinite")};else c=function(c,a,b){var h=0,m=c.find("g g").get(0);c.data("interval",setInterval(function(){m.setAttributeNS(null,"transform","rotate("+ ++h%a*(360/a)+")")},1E3*b/a))};
else{var h=a("<shape>").css("behavior","url(#default#VML)");a("body").append(h);if(h.get(0).adj){var m=document.createStyleSheet();a.each(["group","shape","stroke"],function(){m.addRule(this,"behavior:url(#default#VML);")});k=function(c,b){for(var h=2*b.width+b.space,m=2*(h+b.length+Math.ceil(b.width/2)+1),q=-Math.ceil(m/2),q=a("<group>",{coordsize:m+" "+m,coordorigin:q+" "+q}).css({top:q,left:q,width:m,height:m}),l=0;l<b.segments;l++)q.append(a("<shape>",{path:"m "+h+",0  l "+(h+b.length)+",0"}).css({width:m,
height:m,rotation:360/b.segments*l+"deg"}).append(a("<stroke>",{color:b.color,weight:b.width+"px",endcap:"round",opacity:a.fn.activity.getOpacity(b,l)})));return a("<group>",{coordsize:m+" "+m}).css({width:m,height:m,overflow:"hidden"}).append(q)};c=function(c,a,b){var h=0,m=c.get(0);c.data("interval",setInterval(function(){m.style.rotation=++h%a*(360/a)},1E3*b/a))}}a(h).remove()}})(jQuery);
(function(a,C,k,c){var b=[];a(k).ready(function(){if("Microsoft Internet Explorer"==navigator.appName){obj=k.getElementsByTagName("TEXTAREA");for(var c,a=0,a=0;a<obj.length;a++)c=obj[a],b[a]=c.value.length,c.onmouseup=function(){c=k.activeElement;for(var a=0;a<obj.length&&obj[a]!=c;a++);c.focus();var m=k.selection.createRange(),n=c.createTextRange(),g=n.duplicate();n.moveToBookmark(m.getBookmark());g.setEndPoint("EndToStart",n);b[a]=g.text.length},c.onkeyup=function(){c=k.activeElement;for(var a=
0;a<obj.length&&obj[a]!=c;a++);c.focus();var m=k.selection.createRange(),n=c.createTextRange(),g=n.duplicate();n.moveToBookmark(m.getBookmark());g.setEndPoint("EndToStart",n);b[a]=g.text.length}}});jQuery.fn.extend({getSelection:function(){var c=this.jquery?this[0]:this,a,e,f,n=0;c.onmousedown=function(){k.selection&&"number"!=typeof c.selectionStart?k.selection.empty():C.getSelection().removeAllRanges()};if(k.selection){var g=k.selection.createRange(),q=0,l=0,t=0;a=k.getElementsByTagName("TEXTAREA");
for(e=0;e<a.length&&a[e]!=c;e++);null!=c.value.match(/\n/g)&&(n=c.value.match(/\n/g).length);if(g.text){f=g.text;if("number"==typeof c.selectionStart){if(a=c.selectionStart,e=c.selectionEnd,a==e)return{start:a,end:e,text:g.text,length:e-a}}else{a=c.createTextRange();f=a.duplicate();firstRe=a.text;a.moveToBookmark(g.getBookmark());secondRe=a.text;f.setEndPoint("EndToStart",a);if(firstRe==secondRe&&firstRe!=g.text||f.text.length>firstRe.length)return{start:b[e],end:b[e],text:"",length:0};a=f.text.length;
e=f.text.length+g.text.length}if(0<n)for(f=0;f<=n;f++){var u=c.value.indexOf("\n",l);-1!=u&&u<a?(l=u+1,q++,t=q):-1!=u&&u>=a&&u<=e?u==a+1?(q--,t--,l=u+1):(l=u+1,t++):f=n}1==g.text.indexOf("\n",0)&&(t+=2);a-=q;e-=t;return{start:a,end:e,text:g.text,length:e-a}}c.focus();"number"==typeof c.selectionStart?a=c.selectionStart:(g=k.selection.createRange(),a=c.createTextRange(),f=a.duplicate(),a.moveToBookmark(g.getBookmark()),f.setEndPoint("EndToStart",a),a=f.text.length);if(0<n)for(f=0;f<=n;f++)u=c.value.indexOf("\n",
l),-1!=u&&u<a?(l=u+1,q++):f=n;a-=q;0==a&&"number"!=typeof c.selectionStart&&(a=b[e],e=b[e]);return{start:a,end:a,text:g.text,length:0}}return"number"==typeof c.selectionStart?(a=c.selectionStart,e=c.selectionEnd,f=c.value.substring(c.selectionStart,c.selectionEnd),{start:a,end:e,text:f,length:e-a}):{start:void 0,end:void 0,text:void 0,length:void 0}},replaceSelection:function(c){var a=this.jquery?this[0]:this,e,f;f=0;var n,g,q=0,l=0,t=void 0==a.scrollTop?0:a.scrollTop;e=k.getElementsByTagName("TEXTAREA");
for(var u=0;u<e.length&&e[u]!=a;u++);if(k.selection&&"number"!=typeof a.selectionStart){t=k.selection.createRange();if("number"!=typeof a.selectionStart){var y;g=a.createTextRange();n=g.duplicate();e=g.text;g.moveToBookmark(t.getBookmark());y=g.text;try{n.setEndPoint("EndToStart",g)}catch(z){return this}if(e==y&&e!=t.text||n.text.length>e.length)return this}if(t.text){part=t.text;null!=a.value.match(/\n/g)&&(q=a.value.match(/\n/g).length);e=n.text.length;if(0<q)for(y=0;y<=q;y++){var v=a.value.indexOf("\n",
f);-1!=v&&v<e?(f=v+1,l++):y=q}t.text=c;b[u]=n.text.length+c.length;g.move("character",b[u]);k.selection.empty();a.blur()}}else"number"==typeof a.selectionStart&&a.selectionStart!=a.selectionEnd&&(e=a.selectionStart,f=a.selectionEnd,a.value=a.value.substr(0,e)+c+a.value.substr(f),f=e+c.length,a.setSelectionRange(f,f),a.scrollTop=t);return this},setSelection:function(c,a){c=parseInt(c);a=parseInt(a);var b=this.jquery?this[0]:this;b.focus();"number"!=typeof b.selectionStart&&(re=b.createTextRange(),
re.text.length<a&&(a=re.text.length+1));if(a<c)return this;if(k.selection){var f=0,n=0,g=0,q=0;if("number"!=typeof b.selectionStart)re.collapse(!0),re.moveEnd("character",a),re.moveStart("character",c),re.select();else{if("number"==typeof b.selectionStart){null!=b.value.match(/\n/g)&&(f=b.value.match(/\n/g).length);if(0<f)for(var l=0;l<=f;l++){var t=b.value.indexOf("\n",g);-1!=t&&t<c?(g=t+1,n++,q=n):-1!=t&&t>=c&&t<=a?t==c+1?(n--,q--,g=t+1):(g=t+1,q++):l=f}b.selectionStart=c+n;b.selectionEnd=a+q}b.focus()}return this}if(b.selectionStart||
0==b.selectionStart)return b.focus(),C.getSelection().removeAllRanges(),b.selectionStart=c,b.selectionEnd=a,b.focus(),this},insertAtCaretPos:function(c){var a=this.jquery?this[0]:this,e,f,n,g,q,l,t;e=f=0;var u=void 0==a.scrollTop?0:a.scrollTop;t=k.getElementsByTagName("TEXTAREA");for(var y=0;y<t.length&&t[y]!=a;y++);a.focus();if(k.selection&&"number"!=typeof a.selectionStart&&(null!=a.value.match(/\n/g)&&(e=a.value.match(/\n/g).length),t=parseInt(b[y]),0<e))for(var z=0;z<=e;z++){var v=a.value.indexOf("\n",
n);-1!=v&&v<=t&&(n=v+1,--t,f++)}b[y]=parseInt(b[y]);a.onkeyup=function(){k.selection&&"number"!=typeof a.selectionStart&&(a.focus(),g=k.selection.createRange(),q=a.createTextRange(),l=q.duplicate(),q.moveToBookmark(g.getBookmark()),l.setEndPoint("EndToStart",q),b[y]=l.text.length)};a.onmouseup=function(){k.selection&&"number"!=typeof a.selectionStart&&(a.focus(),g=k.selection.createRange(),q=a.createTextRange(),l=q.duplicate(),q.moveToBookmark(g.getBookmark()),l.setEndPoint("EndToStart",q),b[y]=l.text.length)};
if(k.selection&&"number"!=typeof a.selectionStart){g=k.selection.createRange();if(0!=g.text.length)return this;q=a.createTextRange();textLength=q.text.length;l=q.duplicate();q.moveToBookmark(g.getBookmark());l.setEndPoint("EndToStart",q);e=l.text.length;0<b[y]&&0==e?(f=b[y]-f,q.move("character",f),q.select(),g=k.selection.createRange(),b[y]+=c.length):0<=b[y]||0!=textLength?0<=b[y]||0!=e?!(0<=b[y])&&0<e?(q.move("character",0),k.selection.empty(),q.select(),g=k.selection.createRange(),b[y]=e+c.length):
0<=b[y]&&b[y]==textLength?(0!=textLength?(q.move("character",textLength),q.select()):q.move("character",0),g=k.selection.createRange(),b[y]=c.length+textLength):(0<=b[y]&&0!=e&&b[y]>=e?(f=b[y]-e,q.move("character",f)):0<=b[y]&&0!=e&&b[y]<e&&q.move("character",0),k.selection.empty(),q.select(),g=k.selection.createRange(),b[y]+=c.length):(q.move("character",textLength),q.select(),g=k.selection.createRange(),b[y]=c.length+textLength):(g=k.selection.createRange(),b[y]=c.length+textLength);g.text=c;a.focus()}else"number"==
typeof a.selectionStart&&a.selectionStart==a.selectionEnd&&(n=a.selectionStart+c.length,e=a.selectionStart,f=a.selectionEnd,a.value=a.value.substr(0,e)+c+a.value.substr(f),a.setSelectionRange(n,n),a.scrollTop=u);return this},setCaretPos:function(a){var c=this.jquery?this[0]:this,e,f=0,n=0,g;g=k.getElementsByTagName("TEXTAREA");for(var q=0;q<g.length&&g[q]!=c;q++);c.focus();if(0==parseInt(a))return this;if(0<parseInt(a)){if(a=parseInt(a)-1,k.selection&&"number"==typeof c.selectionStart&&c.selectionStart==
c.selectionEnd&&(null!=c.value.match(/\n/g)&&(f=c.value.match(/\n/g).length),0<f))for(var l=0;l<=f;l++)g=c.value.indexOf("\n",e),-1!=g&&g<=a&&(e=g+1,a=parseInt(a)+1)}else if(0>parseInt(a))if(a=parseInt(a)+1,k.selection&&"number"!=typeof c.selectionStart){if(a=c.value.length+parseInt(a),null!=c.value.match(/\n/g)&&(f=c.value.match(/\n/g).length),0<f){for(l=0;l<=f;l++)g=c.value.indexOf("\n",e),-1!=g&&g<=a&&(e=g+1,a=parseInt(a)-1,n+=1);a=a+n-f}}else if(k.selection&&"number"==typeof c.selectionStart){if(a=
c.value.length+parseInt(a),null!=c.value.match(/\n/g)&&(f=c.value.match(/\n/g).length),0<f)for(a=parseInt(a)-f,l=0;l<=f;l++)g=c.value.indexOf("\n",e),-1!=g&&g<=a&&(e=g+1,a=parseInt(a)+1,n+=1)}else a=c.value.length+parseInt(a);else return this;if(k.selection&&"number"!=typeof c.selectionStart){e=k.selection.createRange();if(0!=e.text)return this;c=c.createTextRange();c.collapse(!0);c.moveEnd("character",a);c.moveStart("character",a);c.select();b[q]=a}else"number"==typeof c.selectionStart&&c.selectionStart==
c.selectionEnd&&c.setSelectionRange(a,a);return this},countCharacters:function(a){a=this.jquery?this[0]:this;return null!=a.value.match(/\r/g)?a.value.length-a.value.match(/\r/g).length:a.value.length},setMaxLength:function(a,c){this.each(function(){var b=this.jquery?this[0]:this,f=b.type,n,g;0>parseInt(a)&&(a=1E8);"text"==f&&(b.maxLength=a);if("textarea"==f||"text"==f)b.onkeypress=function(f){var l=b.value.match(/\r/g);g=a;null!=l&&(g=parseInt(g)+l.length);f=f||event;l=f.keyCode;n=k.selection?0<
k.selection.createRange().text.length:b.selectionStart!=b.selectionEnd;if(b.value.length>=g&&(47<l||32==l||0==l||13==l)&&!f.ctrlKey&&!f.altKey&&!n)return b.value=b.value.substring(0,g),"function"==typeof c&&c(),!1},b.onkeyup=function(){var f=b.value.match(/\r/g),l=0,n=0;g=a;if(null!=f){for(var k=0;k<=f.length;k++)b.value.indexOf("\n",n)<=parseInt(a)&&(l++,n=b.value.indexOf("\n",n)+1);g=parseInt(a)+l}if(b.value.length>g)return b.value=b.value.substring(0,g),"function"==typeof c&&c(),this};else return this});
return this}})})(jQuery,this,this.document);
(function(a){var C={className:"autosizejs",id:"autosizejs",append:"\n",callback:!1,resizeDelay:10,placeholder:!0},k="fontFamily fontSize fontWeight fontStyle letterSpacing textTransform wordSpacing textIndent whiteSpace".split(" "),c,b=a('<textarea tabindex="-1" style="position:absolute; top:-999px; left:0; right:auto; bottom:auto; border:0; padding: 0; -moz-box-sizing:content-box; -webkit-box-sizing:content-box; box-sizing:content-box; word-wrap:break-word; height:0 !important; min-height:0 !important; overflow:hidden; transition:none; -webkit-transition:none; -moz-transition:none;"/>').data("autosize",!0)[0];
b.style.lineHeight="99px";"99px"===a(b).css("lineHeight")&&k.push("lineHeight");b.style.lineHeight="";a.fn.autosize=function(h){if(!this.length)return this;h=a.extend({},C,h||{});b.parentNode!==document.body&&a(document.body).append(b);return this.each(function(){function m(){var c,e=window.getComputedStyle?window.getComputedStyle(g,null):!1;if(e){c=g.getBoundingClientRect().width;if(0===c||"number"!==typeof c)c=parseFloat(e.width);a.each(["paddingLeft","paddingRight","borderLeftWidth","borderRightWidth"],
function(a,b){c-=parseFloat(e[b])})}else c=q.width();b.style.width=Math.max(c,0)+"px"}function e(){var e={};c=g;b.className=h.className;b.id=h.id;l=parseFloat(q.css("maxHeight"));a.each(k,function(a,c){e[c]=q.css(c)});a(b).css(e).attr("wrap",q.attr("wrap"));m();if(window.chrome){var f=g.style.width;g.style.width="0px";g.style.width=f}}function f(){var a,f;c!==g?e():m();b.value=!g.value&&h.placeholder?q.attr("placeholder")||"":g.value;b.value+=h.append||"";b.style.overflowY=g.style.overflowY;f=parseFloat(g.style.height);
b.scrollTop=0;b.scrollTop=9E4;a=b.scrollTop;l&&a>l?(g.style.overflowY="scroll",a=l):(g.style.overflowY="hidden",a<t&&(a=t));a+=u;f!==a&&(g.style.height=a+"px",b.className=b.className,y&&h.callback.call(g,g),q.trigger("autosize.resized"))}function n(){clearTimeout(v);v=setTimeout(function(){var a=q.width();a!==I&&(I=a,f())},parseInt(h.resizeDelay,10))}var g=this,q=a(g),l,t,u=0,y=a.isFunction(h.callback),z={height:g.style.height,overflow:g.style.overflow,overflowY:g.style.overflowY,wordWrap:g.style.wordWrap,
resize:g.style.resize},v,I=q.width(),K=q.css("resize");if(!q.data("autosize")){q.data("autosize",!0);if("border-box"===q.css("box-sizing")||"border-box"===q.css("-moz-box-sizing")||"border-box"===q.css("-webkit-box-sizing"))u=q.outerHeight()-q.height();t=Math.max(parseFloat(q.css("minHeight"))-u||0,q.height());q.css({overflow:"hidden",overflowY:"hidden",wordWrap:"break-word"});"vertical"===K?q.css("resize","none"):"both"===K&&q.css("resize","horizontal");if("onpropertychange"in g)if("oninput"in g)q.on("input.autosize keyup.autosize",
f);else q.on("propertychange.autosize",function(){"value"===event.propertyName&&f()});else q.on("input.autosize",f);if(!1!==h.resizeDelay)a(window).on("resize.autosize",n);q.on("autosize.resize",f);q.on("autosize.resizeIncludeStyle",function(){c=null;f()});q.on("autosize.destroy",function(){c=null;clearTimeout(v);a(window).off("resize",n);q.off("autosize").off(".autosize").css(z).removeData("autosize")});f()}})}})(jQuery||$);
(function(a){"function"===typeof define&&define.amd?define(["jquery"],a):"object"===typeof exports?a(require("jquery")):a(jQuery)})(function(a){function C(a){a=b.json?JSON.stringify(a):String(a);return b.raw?a:encodeURIComponent(a)}function k(h,m){var e;if(b.raw)e=h;else a:{var f=h;0===f.indexOf('"')&&(f=f.slice(1,-1).replace(/\\"/g,'"').replace(/\\\\/g,"\\"));try{f=decodeURIComponent(f.replace(c," "));e=b.json?JSON.parse(f):f;break a}catch(n){}e=void 0}return a.isFunction(m)?m(e):e}var c=/\+/g,b=
a.cookie=function(c,m,e){if(1<arguments.length&&!a.isFunction(m)){e=a.extend({},b.defaults,e);if("number"===typeof e.expires){var f=e.expires,n=e.expires=new Date;n.setTime(+n+864E5*f)}return document.cookie=[b.raw?c:encodeURIComponent(c),"=",C(m),e.expires?"; expires="+e.expires.toUTCString():"",e.path?"; path="+e.path:"",e.domain?"; domain="+e.domain:"",e.secure?"; secure":""].join("")}for(var f=c?void 0:{},n=document.cookie?document.cookie.split("; "):[],g=0,q=n.length;g<q;g++){var l=n[g].split("="),
t;t=l.shift();t=b.raw?t:decodeURIComponent(t);l=l.join("=");if(c&&c===t){f=k(l,m);break}c||void 0===(l=k(l))||(f[t]=l)}return f};b.defaults={};a.removeCookie=function(c,b){if(void 0===a.cookie(c))return!1;a.cookie(c,"",a.extend({},b,{expires:-1}));return!a.cookie(c)}});
(function(a,C,k){(function(a){"function"===typeof define&&define.amd?define("datatables",["jquery"],a):"object"===typeof exports?a(require("jquery")):jQuery&&!jQuery.fn.dataTable&&a(jQuery)})(function(c){function b(d){var x,a,G={};c.each(d,function(c,p){(x=c.match(/^([^A-Z]+?)([A-Z])/))&&-1!=="a aa ai ao as b fn i m o s ".indexOf(x[1]+" ")&&(a=c.replace(x[0],x[2].toLowerCase()),G[a]=c,"o"===x[1]&&b(d[c]))});d._hungarianMap=G}function h(d,x,a){d._hungarianMap||b(d);var G;c.each(x,function(b,p){G=d._hungarianMap[b];
G===k||!a&&x[G]!==k||("o"===G.charAt(0)?(x[G]||(x[G]={}),c.extend(!0,x[G],x[b]),h(d[G],x[G],a)):x[G]=x[b])})}function m(d){var x=B.defaults.oLanguage,a=d.sZeroRecords;!d.sEmptyTable&&a&&"No data available in table"===x.sEmptyTable&&ba(d,d,"sZeroRecords","sEmptyTable");!d.sLoadingRecords&&a&&"Loading..."===x.sLoadingRecords&&ba(d,d,"sZeroRecords","sLoadingRecords");d.sInfoThousands&&(d.sThousands=d.sInfoThousands);(d=d.sDecimal)&&hb(d)}function e(d){V(d,"ordering","bSort");V(d,"orderMulti","bSortMulti");
V(d,"orderClasses","bSortClasses");V(d,"orderCellsTop","bSortCellsTop");V(d,"order","aaSorting");V(d,"orderFixed","aaSortingFixed");V(d,"paging","bPaginate");V(d,"pagingType","sPaginationType");V(d,"pageLength","iDisplayLength");V(d,"searching","bFilter");if(d=d.aoSearchCols)for(var x=0,a=d.length;x<a;x++)d[x]&&h(B.models.oSearch,d[x])}function f(d){V(d,"orderable","bSortable");V(d,"orderData","aDataSort");V(d,"orderSequence","asSorting");V(d,"orderDataType","sortDataType")}function n(d){d=d.oBrowser;
var x=c("<div/>").css({position:"absolute",top:0,left:0,height:1,width:1,overflow:"hidden"}).append(c("<div/>").css({position:"absolute",top:1,left:1,width:100,overflow:"scroll"}).append(c('<div class="test"/>').css({width:"100%",height:10}))).appendTo("body"),a=x.find(".test");d.bScrollOversize=100===a[0].offsetWidth;d.bScrollbarLeft=1!==a.offset().left;x.remove()}function g(d,x,a,c,b,p){var r,e=!1;a!==k&&(r=a,e=!0);for(;c!==b;)d.hasOwnProperty(c)&&(r=e?x(r,d[c],c,d):d[c],e=!0,c+=p);return r}function q(d,
x){var a=B.defaults.column,G=d.aoColumns.length,a=c.extend({},B.models.oColumn,a,{nTh:x?x:C.createElement("th"),sTitle:a.sTitle?a.sTitle:x?x.innerHTML:"",aDataSort:a.aDataSort?a.aDataSort:[G],mData:a.mData?a.mData:G,idx:G});d.aoColumns.push(a);a=d.aoPreSearchCols;a[G]=c.extend({},B.models.oSearch,a[G]);l(d,G,null)}function l(d,x,a){x=d.aoColumns[x];var G=d.oClasses,b=c(x.nTh);if(!x.sWidthOrig){x.sWidthOrig=b.attr("width")||null;var p=(b.attr("style")||"").match(/width:\s*(\d+[pxem%]+)/);p&&(x.sWidthOrig=
p[1])}a!==k&&null!==a&&(f(a),h(B.defaults.column,a),a.mDataProp===k||a.mData||(a.mData=a.mDataProp),a.sType&&(x._sManualType=a.sType),a.className&&!a.sClass&&(a.sClass=a.className),c.extend(x,a),ba(x,a,"sWidth","sWidthOrig"),"number"===typeof a.iDataSort&&(x.aDataSort=[a.iDataSort]),ba(x,a,"aDataSort"));var r=x.mData,e=W(r),ib=x.mRender?W(x.mRender):null;a=function(d){return"string"===typeof d&&-1!==d.indexOf("@")};x._bAttrSrc=c.isPlainObject(r)&&(a(r.sort)||a(r.type)||a(r.filter));x.fnGetData=function(d,
a,x){var c=e(d,a,k,x);return ib&&a?ib(c,a,d,x):c};x.fnSetData=function(d,a,x){return La(r)(d,a,x)};d.oFeatures.bSort||(x.bSortable=!1,b.addClass(G.sSortableNone));d=-1!==c.inArray("asc",x.asSorting);a=-1!==c.inArray("desc",x.asSorting);x.bSortable&&(d||a)?d&&!a?(x.sSortingClass=G.sSortableAsc,x.sSortingClassJUI=G.sSortJUIAscAllowed):!d&&a?(x.sSortingClass=G.sSortableDesc,x.sSortingClassJUI=G.sSortJUIDescAllowed):(x.sSortingClass=G.sSortable,x.sSortingClassJUI=G.sSortJUI):(x.sSortingClass=G.sSortableNone,
x.sSortingClassJUI="")}function t(d){if(!1!==d.oFeatures.bAutoWidth){var a=d.aoColumns;Ma(d);for(var c=0,G=a.length;c<G;c++)a[c].nTh.style.width=a[c].sWidth}a=d.oScroll;""===a.sY&&""===a.sX||ra(d);O(d,null,"column-sizing",[d])}function u(d,a){var c=v(d,"bVisible");return"number"===typeof c[a]?c[a]:null}function y(d,a){var D=v(d,"bVisible"),D=c.inArray(a,D);return-1!==D?D:null}function z(d){return v(d,"bVisible").length}function v(d,a){var D=[];c.map(d.aoColumns,function(d,c){d[a]&&D.push(c)});return D}
function I(d){var a=d.aoColumns,c=d.aoData,G=B.ext.type.detect,b,p,r,e,f,h,g,l,n;b=0;for(p=a.length;b<p;b++)if(g=a[b],n=[],!g.sType&&g._sManualType)g.sType=g._sManualType;else if(!g.sType){r=0;for(e=G.length;r<e;r++){f=0;for(h=c.length;f<h&&(n[f]===k&&(n[f]=M(d,f,b,"type")),l=G[r](n[f],d),l&&"html"!==l);f++);if(l){g.sType=l;break}}g.sType||(g.sType="string")}}function K(d,a,D,G){var b,p,r,e,f,h,g=d.aoColumns;if(a)for(b=a.length-1;0<=b;b--){h=a[b];var l=h.targets!==k?h.targets:h.aTargets;c.isArray(l)||
(l=[l]);p=0;for(r=l.length;p<r;p++)if("number"===typeof l[p]&&0<=l[p]){for(;g.length<=l[p];)q(d);G(l[p],h)}else if("number"===typeof l[p]&&0>l[p])G(g.length+l[p],h);else if("string"===typeof l[p])for(e=0,f=g.length;e<f;e++)("_all"==l[p]||c(g[e].nTh).hasClass(l[p]))&&G(e,h)}if(D)for(b=0,d=D.length;b<d;b++)G(b,D[b])}function H(d,a,D,G){var b=d.aoData.length,p=c.extend(!0,{},B.models.oRow,{src:D?"dom":"data"});p._aData=a;d.aoData.push(p);a=d.aoColumns;for(var p=0,r=a.length;p<r;p++)D&&E(d,b,p,M(d,b,
p)),a[p].sType=null;d.aiDisplayMaster.push(b);!D&&d.oFeatures.bDeferRender||ka(d,b,D,G);return b}function A(d,a){var D;a instanceof c||(a=c(a));return a.map(function(a,x){D=wa(d,x);return H(d,D.data,x,D.cells)})}function M(d,a,c,G){var b=d.iDraw,p=d.aoColumns[c],r=d.aoData[a]._aData,e=p.sDefaultContent;c=p.fnGetData(r,G,{settings:d,row:a,col:c});if(c===k)return d.iDrawError!=b&&null===e&&(la(d,0,"Requested unknown parameter "+("function"==typeof p.mData?"{function}":"'"+p.mData+"'")+" for row "+a,
4),d.iDrawError=b),e;if((c===r||null===c)&&null!==e)c=e;else if("function"===typeof c)return c.call(r);return null===c&&"display"==G?"":c}function E(d,a,c,G){d.aoColumns[c].fnSetData(d.aoData[a]._aData,G,{settings:d,row:a,col:c})}function ea(d){return c.map(d.match(/(\\.|[^\.])+/g),function(d){return d.replace(/\\./g,".")})}function W(d){if(c.isPlainObject(d)){var a={};c.each(d,function(d,c){c&&(a[d]=W(c))});return function(d,c,D,b){var e=a[c]||a._;return e!==k?e(d,c,D,b):d}}if(null===d)return function(d){return d};
if("function"===typeof d)return function(a,c,x,D){return d(a,c,x,D)};if("string"!==typeof d||-1===d.indexOf(".")&&-1===d.indexOf("[")&&-1===d.indexOf("("))return function(a,c){return a[d]};var D=function(d,a,c){var x,b;if(""!==c){b=ea(c);for(var e=0,f=b.length;e<f;e++){c=b[e].match(sa);x=b[e].match(ma);if(c){b[e]=b[e].replace(sa,"");""!==b[e]&&(d=d[b[e]]);x=[];b.splice(0,e+1);b=b.join(".");e=0;for(f=d.length;e<f;e++)x.push(D(d[e],a,b));d=c[0].substring(1,c[0].length-1);d=""===d?x:x.join(d);break}else if(x){b[e]=
b[e].replace(ma,"");d=d[b[e]]();continue}if(null===d||d[b[e]]===k)return k;d=d[b[e]]}}return d};return function(a,c){return D(a,c,d)}}function La(d){if(c.isPlainObject(d))return La(d._);if(null===d)return function(){};if("function"===typeof d)return function(a,c,x){d(a,"set",c,x)};if("string"!==typeof d||-1===d.indexOf(".")&&-1===d.indexOf("[")&&-1===d.indexOf("("))return function(a,c){a[d]=c};var a=function(d,c,b){b=ea(b);var p;p=b[b.length-1];for(var r,e,f=0,h=b.length-1;f<h;f++){r=b[f].match(sa);
e=b[f].match(ma);if(r){b[f]=b[f].replace(sa,"");d[b[f]]=[];p=b.slice();p.splice(0,f+1);r=p.join(".");e=0;for(h=c.length;e<h;e++)p={},a(p,c[e],r),d[b[f]].push(p);return}e&&(b[f]=b[f].replace(ma,""),d=d[b[f]](c));if(null===d[b[f]]||d[b[f]]===k)d[b[f]]={};d=d[b[f]]}if(p.match(ma))d[p.replace(ma,"")](c);else d[p.replace(sa,"")]=c};return function(c,b){return a(c,b,d)}}function S(d){return aa(d.aoData,"_aData")}function xa(d){d.aoData.length=0;d.aiDisplayMaster.length=0;d.aiDisplay.length=0}function Q(d,
a,c){for(var b=-1,e=0,p=d.length;e<p;e++)d[e]==a?b=e:d[e]>a&&d[e]--; -1!=b&&c===k&&d.splice(b,1)}function ya(d,a,c,b){var e=d.aoData[a],p;if("dom"!==c&&(c&&"auto"!==c||"dom"!==e.src)){var r=e.anCells,f;if(r)for(c=0,p=r.length;c<p;c++){for(f=r[c];f.childNodes.length;)f.removeChild(f.firstChild);r[c].innerHTML=M(d,a,c,"display")}}else e._aData=wa(d,e).data;e._aSortData=null;e._aFilterData=null;d=d.aoColumns;if(b!==k)d[b].sType=null;else for(c=0,p=d.length;c<p;c++)d[c].sType=null;Na(e)}function wa(d,
a){var D=[],b=[],e=a.firstChild,p,r,f,h=0,g,l=d.aoColumns,n=function(d,a,c){"string"===typeof d&&(a=d.indexOf("@"),-1!==a&&(d=d.substring(a+1),f["@"+d]=c.getAttribute(d)))},m=function(d){r=l[h];g=c.trim(d.innerHTML);r&&r._bAttrSrc?(f={display:g},n(r.mData.sort,f,d),n(r.mData.type,f,d),n(r.mData.filter,f,d),D.push(f)):D.push(g);h++};if(e)for(;e;){p=e.nodeName.toUpperCase();if("TD"==p||"TH"==p)m(e),b.push(e);e=e.nextSibling}else for(b=a.anCells,e=0,p=b.length;e<p;e++)m(b[e]);return{data:D,cells:b}}
function ka(d,a,c,b){var e=d.aoData[a],p=e._aData,r=[],f,h,g,l,n;if(null===e.nTr){f=c||C.createElement("tr");e.nTr=f;e.anCells=r;f._DT_RowIndex=a;Na(e);l=0;for(n=d.aoColumns.length;l<n;l++){g=d.aoColumns[l];h=c?b[l]:C.createElement(g.sCellType);r.push(h);if(!c||g.mRender||g.mData!==l)h.innerHTML=M(d,a,l,"display");g.sClass&&(h.className+=" "+g.sClass);g.bVisible&&!c?f.appendChild(h):!g.bVisible&&c&&h.parentNode.removeChild(h);g.fnCreatedCell&&g.fnCreatedCell.call(d.oInstance,h,M(d,a,l),p,a,l)}O(d,
"aoRowCreatedCallback",null,[f,p,a])}e.nTr.setAttribute("role","row")}function Na(d){var a=d.nTr,D=d._aData;if(a){D.DT_RowId&&(a.id=D.DT_RowId);if(D.DT_RowClass){var b=D.DT_RowClass.split(" ");d.__rowc=d.__rowc?Oa(d.__rowc.concat(b)):b;c(a).removeClass(d.__rowc.join(" ")).addClass(D.DT_RowClass)}D.DT_RowData&&c(a).data(D.DT_RowData)}}function na(d){var a,D,b,e,p,r=d.nTHead,f=d.nTFoot,h=0===c("th, td",r).length,g=d.oClasses,l=d.aoColumns;h&&(e=c("<tr/>").appendTo(r));a=0;for(D=l.length;a<D;a++)p=l[a],
b=c(p.nTh).addClass(p.sClass),h&&b.appendTo(e),d.oFeatures.bSort&&(b.addClass(p.sSortingClass),!1!==p.bSortable&&(b.attr("tabindex",d.iTabIndex).attr("aria-controls",d.sTableId),Pa(d,p.nTh,a))),p.sTitle!=b.html()&&b.html(p.sTitle),Qa(d,"header")(d,b,p,g);h&&N(d.aoHeader,r);c(r).find(">tr").attr("role","row");c(r).find(">tr>th, >tr>td").addClass(g.sHeaderTH);c(f).find(">tr>th, >tr>td").addClass(g.sFooterTH);if(null!==f)for(d=d.aoFooter[0],a=0,D=d.length;a<D;a++)p=l[a],p.nTf=d[a].cell,p.sClass&&c(p.nTf).addClass(p.sClass)}
function ta(d,a,D){var b,e,p,r=[],f=[],h=d.aoColumns.length,g;if(a){D===k&&(D=!1);b=0;for(e=a.length;b<e;b++){r[b]=a[b].slice();r[b].nTr=a[b].nTr;for(p=h-1;0<=p;p--)d.aoColumns[p].bVisible||D||r[b].splice(p,1);f.push([])}b=0;for(e=r.length;b<e;b++){if(d=r[b].nTr)for(;p=d.firstChild;)d.removeChild(p);p=0;for(a=r[b].length;p<a;p++)if(g=h=1,f[b][p]===k){d.appendChild(r[b][p].cell);for(f[b][p]=1;r[b+h]!==k&&r[b][p].cell==r[b+h][p].cell;)f[b+h][p]=1,h++;for(;r[b][p+g]!==k&&r[b][p].cell==r[b][p+g].cell;){for(D=
0;D<h;D++)f[b+D][p+g]=1;g++}c(r[b][p].cell).attr("rowspan",h).attr("colspan",g)}}}}function fa(d){var a=O(d,"aoPreDrawCallback","preDraw",[d]);if(-1!==c.inArray(!1,a))Y(d,!1);else{var a=[],D=0,b=d.asStripeClasses,e=b.length,p=d.oLanguage,r=d.iInitDisplayStart,f="ssp"==X(d),h=d.aiDisplay;d.bDrawing=!0;r!==k&&-1!==r&&(d._iDisplayStart=f?r:r>=d.fnRecordsDisplay()?0:r,d.iInitDisplayStart=-1);var r=d._iDisplayStart,g=d.fnDisplayEnd();if(d.bDeferLoading)d.bDeferLoading=!1,d.iDraw++,Y(d,!1);else if(!f)d.iDraw++;
else if(!d.bDestroying&&!za(d))return;if(0!==h.length)for(p=f?d.aoData.length:g,f=f?0:r;f<p;f++){var l=h[f],n=d.aoData[l];null===n.nTr&&ka(d,l);l=n.nTr;if(0!==e){var m=b[D%e];n._sRowStripe!=m&&(c(l).removeClass(n._sRowStripe).addClass(m),n._sRowStripe=m)}O(d,"aoRowCallback",null,[l,n._aData,D,f]);a.push(l);D++}else D=p.sZeroRecords,1==d.iDraw&&"ajax"==X(d)?D=p.sLoadingRecords:p.sEmptyTable&&0===d.fnRecordsTotal()&&(D=p.sEmptyTable),a[0]=c("<tr/>",{"class":e?b[0]:""}).append(c("<td />",{valign:"top",
colSpan:z(d),"class":d.oClasses.sRowEmpty}).html(D))[0];O(d,"aoHeaderCallback","header",[c(d.nTHead).children("tr")[0],S(d),r,g,h]);O(d,"aoFooterCallback","footer",[c(d.nTFoot).children("tr")[0],S(d),r,g,h]);b=c(d.nTBody);b.children().detach();b.append(c(a));O(d,"aoDrawCallback","draw",[d]);d.bSorted=!1;d.bFiltered=!1;d.bDrawing=!1}}function ha(d,a){var c=d.oFeatures,b=c.bFilter;c.bSort&&jb(d);b?ua(d,d.oPreviousSearch):d.aiDisplay=d.aiDisplayMaster.slice();!0!==a&&(d._iDisplayStart=0);d._drawHold=
a;fa(d);d._drawHold=!1}function va(d){var a=d.oClasses,b=c(d.nTable),b=c("<div/>").insertBefore(b),e=d.oFeatures,f=c("<div/>",{id:d.sTableId+"_wrapper","class":a.sWrapper+(d.nTFoot?"":" "+a.sNoFooter)});d.nHolding=b[0];d.nTableWrapper=f[0];d.nTableReinsertBefore=d.nTable.nextSibling;for(var p=d.sDom.split(""),r,h,g,l,n,m,k=0;k<p.length;k++){r=null;h=p[k];if("<"==h){g=c("<div/>")[0];l=p[k+1];if("'"==l||'"'==l){n="";for(m=2;p[k+m]!=l;)n+=p[k+m],m++;"H"==n?n=a.sJUIHeader:"F"==n&&(n=a.sJUIFooter);-1!=
n.indexOf(".")?(l=n.split("."),g.id=l[0].substr(1,l[0].length-1),g.className=l[1]):"#"==n.charAt(0)?g.id=n.substr(1,n.length-1):g.className=n;k+=m}f.append(g);f=c(g)}else if(">"==h)f=f.parent();else if("l"==h&&e.bPaginate&&e.bLengthChange)r=kb(d);else if("f"==h&&e.bFilter)r=lb(d);else if("r"==h&&e.bProcessing)r=mb(d);else if("t"==h)r=nb(d);else if("i"==h&&e.bInfo)r=ob(d);else if("p"==h&&e.bPaginate)r=pb(d);else if(0!==B.ext.feature.length)for(g=B.ext.feature,m=0,l=g.length;m<l;m++)if(h==g[m].cFeature){r=
g[m].fnInit(d);break}r&&(g=d.aanFeatures,g[h]||(g[h]=[]),g[h].push(r),f.append(r))}b.replaceWith(f)}function N(d,a){var b=c(a).children("tr"),e,f,p,r,h,g,l,n,m,k;d.splice(0,d.length);p=0;for(g=b.length;p<g;p++)d.push([]);p=0;for(g=b.length;p<g;p++)for(e=b[p],f=e.firstChild;f;){if("TD"==f.nodeName.toUpperCase()||"TH"==f.nodeName.toUpperCase()){n=1*f.getAttribute("colspan");m=1*f.getAttribute("rowspan");n=n&&0!==n&&1!==n?n:1;m=m&&0!==m&&1!==m?m:1;r=0;for(h=d[p];h[r];)r++;l=r;k=1===n?!0:!1;for(h=0;h<
n;h++)for(r=0;r<m;r++)d[p+r][l+h]={cell:f,unique:k},d[p+r].nTr=e}f=f.nextSibling}}function oa(d,a,c){var b=[];c||(c=d.aoHeader,a&&(c=[],N(c,a)));a=0;for(var e=c.length;a<e;a++)for(var p=0,r=c[a].length;p<r;p++)!c[a][p].unique||b[p]&&d.bSortCellsTop||(b[p]=c[a][p].cell);return b}function ia(d,a,b){O(d,"aoServerParams","serverParams",[a]);if(a&&c.isArray(a)){var e={},f=/(.*?)\[\]$/;c.each(a,function(d,a){var c=a.name.match(f);c?(c=c[0],e[c]||(e[c]=[]),e[c].push(a.value)):e[a.name]=a.value});a=e}var p,
r=d.ajax,h=d.oInstance;if(c.isPlainObject(r)&&r.data){p=r.data;var g=c.isFunction(p)?p(a):p;a=c.isFunction(p)&&g?g:c.extend(!0,a,g);delete r.data}g={data:a,success:function(a){var c=a.error||a.sError;c&&d.oApi._fnLog(d,0,c);d.json=a;O(d,null,"xhr",[d,a]);b(a)},dataType:"json",cache:!1,type:d.sServerMethod,error:function(a,c,x){x=d.oApi._fnLog;"parsererror"==c?x(d,0,"Invalid JSON response",1):4===a.readyState&&x(d,0,"Ajax error",7);Y(d,!1)}};d.oAjaxData=a;O(d,null,"preXhr",[d,a]);d.fnServerData?d.fnServerData.call(h,
d.sAjaxSource,c.map(a,function(d,a){return{name:a,value:d}}),b,d):d.sAjaxSource||"string"===typeof r?d.jqXHR=c.ajax(c.extend(g,{url:r||d.sAjaxSource})):c.isFunction(r)?d.jqXHR=r.call(h,a,b,d):(d.jqXHR=c.ajax(c.extend(g,r)),r.data=p)}function za(d){return d.bAjaxDataGet?(d.iDraw++,Y(d,!0),ia(d,Aa(d),function(a){Ba(d,a)}),!1):!0}function Aa(d){var a=d.aoColumns,b=a.length,e=d.oFeatures,f=d.oPreviousSearch,p=d.aoPreSearchCols,r,h=[],g,l,n,m=pa(d);r=d._iDisplayStart;g=!1!==e.bPaginate?d._iDisplayLength:
-1;var k=function(d,a){h.push({name:d,value:a})};k("sEcho",d.iDraw);k("iColumns",b);k("sColumns",aa(a,"sName").join(","));k("iDisplayStart",r);k("iDisplayLength",g);var q={draw:d.iDraw,columns:[],order:[],start:r,length:g,search:{value:f.sSearch,regex:f.bRegex}};for(r=0;r<b;r++)l=a[r],n=p[r],g="function"==typeof l.mData?"function":l.mData,q.columns.push({data:g,name:l.sName,searchable:l.bSearchable,orderable:l.bSortable,search:{value:n.sSearch,regex:n.bRegex}}),k("mDataProp_"+r,g),e.bFilter&&(k("sSearch_"+
r,n.sSearch),k("bRegex_"+r,n.bRegex),k("bSearchable_"+r,l.bSearchable)),e.bSort&&k("bSortable_"+r,l.bSortable);e.bFilter&&(k("sSearch",f.sSearch),k("bRegex",f.bRegex));e.bSort&&(c.each(m,function(d,a){q.order.push({column:a.col,dir:a.dir});k("iSortCol_"+d,a.col);k("sSortDir_"+d,a.dir)}),k("iSortingCols",m.length));a=B.ext.legacy.ajax;return null===a?d.sAjaxSource?h:q:a?h:q}function Ba(d,a){var c=function(d,c){return a[d]!==k?a[d]:a[c]},b=c("sEcho","draw"),e=c("iTotalRecords","recordsTotal"),c=c("iTotalDisplayRecords",
"recordsFiltered");if(b){if(1*b<d.iDraw)return;d.iDraw=1*b}xa(d);d._iRecordsTotal=parseInt(e,10);d._iRecordsDisplay=parseInt(c,10);b=ja(d,a);e=0;for(c=b.length;e<c;e++)H(d,b[e]);d.aiDisplay=d.aiDisplayMaster.slice();d.bAjaxDataGet=!1;fa(d);d._bInitComplete||Ca(d,a);d.bAjaxDataGet=!0;Y(d,!1)}function ja(d,a){var b=c.isPlainObject(d.ajax)&&d.ajax.dataSrc!==k?d.ajax.dataSrc:d.sAjaxDataProp;return"data"===b?a.aaData||a[b]:""!==b?W(b)(a):a}function lb(d){var a=d.oClasses,b=d.sTableId,e=d.oLanguage,f=d.oPreviousSearch,
p=d.aanFeatures,r='<input type="search" class="'+a.sFilterInput+'"/>',h=e.sSearch,h=h.match(/_INPUT_/)?h.replace("_INPUT_",r):h+r,a=c("<div/>",{id:p.f?null:b+"_filter","class":a.sFilter}).append(c("<label/>").append(h)),p=function(){var a=this.value?this.value:"";a!=f.sSearch&&(ua(d,{sSearch:a,bRegex:f.bRegex,bSmart:f.bSmart,bCaseInsensitive:f.bCaseInsensitive}),d._iDisplayStart=0,fa(d))},g=c("input",a).val(f.sSearch).attr("placeholder",e.sSearchPlaceholder).bind("keyup.DT search.DT input.DT paste.DT cut.DT",
"ssp"===X(d)?Ra(p,400):p).bind("keypress.DT",function(d){if(13==d.keyCode)return!1}).attr("aria-controls",b);c(d.nTable).on("search.dt.DT",function(a,c){if(d===c)try{g[0]!==C.activeElement&&g.val(f.sSearch)}catch(x){}});return a[0]}function ua(d,a,c){var b=d.oPreviousSearch,e=d.aoPreSearchCols,p=function(d){b.sSearch=d.sSearch;b.bRegex=d.bRegex;b.bSmart=d.bSmart;b.bCaseInsensitive=d.bCaseInsensitive},f=function(d){return d.bEscapeRegex!==k?!d.bEscapeRegex:d.bRegex};I(d);if("ssp"!=X(d)){qb(d,a.sSearch,
c,f(a),a.bSmart,a.bCaseInsensitive);p(a);for(a=0;a<e.length;a++)rb(d,e[a].sSearch,a,f(e[a]),e[a].bSmart,e[a].bCaseInsensitive);sb(d)}else p(a);d.bFiltered=!0;O(d,null,"search",[d])}function sb(d){for(var a=B.ext.search,c=d.aiDisplay,b,e,p=0,f=a.length;p<f;p++){for(var h=[],g=0,l=c.length;g<l;g++)e=c[g],b=d.aoData[e],a[p](d,b._aFilterData,e,b._aData,g)&&h.push(e);c.length=0;c.push.apply(c,h)}}function rb(d,a,c,b,e,p){if(""!==a){var f=d.aiDisplay;b=Sa(a,b,e,p);for(e=f.length-1;0<=e;e--)a=d.aoData[f[e]]._aFilterData[c],
b.test(a)||f.splice(e,1)}}function qb(d,a,c,b,e,p){b=Sa(a,b,e,p);e=d.oPreviousSearch.sSearch;p=d.aiDisplayMaster;var f;0!==B.ext.search.length&&(c=!0);f=tb(d);if(0>=a.length)d.aiDisplay=p.slice();else{if(f||c||e.length>a.length||0!==a.indexOf(e)||d.bSorted)d.aiDisplay=p.slice();a=d.aiDisplay;for(c=a.length-1;0<=c;c--)b.test(d.aoData[a[c]]._sFilterRow)||a.splice(c,1)}}function Sa(d,a,b,e){d=a?d:Ta(d);b&&(d="^(?=.*?"+c.map(d.match(/"[^"]+"|[^ ]+/g)||"",function(d){return'"'===d.charAt(0)?d.match(/^"(.*)"$/)[1]:
d}).join(")(?=.*?")+").*$");return new RegExp(d,e?"i":"")}function Ta(d){return d.replace(Qb,"\\$1")}function tb(d){var a=d.aoColumns,c,b,e,p,f,h,g,l,n=B.ext.type.search;c=!1;b=0;for(p=d.aoData.length;b<p;b++)if(l=d.aoData[b],!l._aFilterData){h=[];e=0;for(f=a.length;e<f;e++)c=a[e],c.bSearchable?(g=M(d,b,e,"filter"),n[c.sType]&&(g=n[c.sType](g)),null===g&&(g=""),"string"!==typeof g&&g.toString&&(g=g.toString())):g="",g.indexOf&&-1!==g.indexOf("&")&&(Da.innerHTML=g,g=Rb?Da.textContent:Da.innerText),
g.replace&&(g=g.replace(/[\r\n]/g,"")),h.push(g);l._aFilterData=h;l._sFilterRow=h.join("  ");c=!0}return c}function ub(d){return{search:d.sSearch,smart:d.bSmart,regex:d.bRegex,caseInsensitive:d.bCaseInsensitive}}function vb(d){return{sSearch:d.search,bSmart:d.smart,bRegex:d.regex,bCaseInsensitive:d.caseInsensitive}}function ob(d){var a=d.sTableId,b=d.aanFeatures.i,e=c("<div/>",{"class":d.oClasses.sInfo,id:b?null:a+"_info"});b||(d.aoDrawCallback.push({fn:wb,sName:"information"}),e.attr("role","status").attr("aria-live",
"polite"),c(d.nTable).attr("aria-describedby",a+"_info"));return e[0]}function wb(d){var a=d.aanFeatures.i;if(0!==a.length){var b=d.oLanguage,e=d._iDisplayStart+1,f=d.fnDisplayEnd(),p=d.fnRecordsTotal(),r=d.fnRecordsDisplay(),g=r?b.sInfo:b.sInfoEmpty;r!==p&&(g+=" "+b.sInfoFiltered);g+=b.sInfoPostFix;g=xb(d,g);b=b.fnInfoCallback;null!==b&&(g=b.call(d.oInstance,d,e,f,p,r,g));c(a).html(g)}}function xb(d,a){var c=d.fnFormatNumber,b=d._iDisplayStart+1,e=d._iDisplayLength,p=d.fnRecordsDisplay(),f=-1===
e;return a.replace(/_START_/g,c.call(d,b)).replace(/_END_/g,c.call(d,d.fnDisplayEnd())).replace(/_MAX_/g,c.call(d,d.fnRecordsTotal())).replace(/_TOTAL_/g,c.call(d,p)).replace(/_PAGE_/g,c.call(d,f?1:Math.ceil(b/e))).replace(/_PAGES_/g,c.call(d,f?1:Math.ceil(p/e)))}function Ea(d){var a,c,b=d.iInitDisplayStart,e=d.aoColumns,p;c=d.oFeatures;if(d.bInitialised){va(d);na(d);ta(d,d.aoHeader);ta(d,d.aoFooter);Y(d,!0);c.bAutoWidth&&Ma(d);a=0;for(c=e.length;a<c;a++)p=e[a],p.sWidth&&(p.nTh.style.width=J(p.sWidth));
ha(d);e=X(d);"ssp"!=e&&("ajax"==e?ia(d,[],function(c){var e=ja(d,c);for(a=0;a<e.length;a++)H(d,e[a]);d.iInitDisplayStart=b;ha(d);Y(d,!1);Ca(d,c)},d):(Y(d,!1),Ca(d)))}else setTimeout(function(){Ea(d)},200)}function Ca(d,a){d._bInitComplete=!0;a&&t(d);O(d,"aoInitComplete","init",[d,a])}function Ua(d,a){var c=parseInt(a,10);d._iDisplayLength=c;Va(d);O(d,null,"length",[d,c])}function kb(d){for(var a=d.oClasses,b=d.sTableId,e=d.aLengthMenu,f=c.isArray(e[0]),p=f?e[0]:e,e=f?e[1]:e,f=c("<select/>",{name:b+
"_length","aria-controls":b,"class":a.sLengthSelect}),r=0,g=p.length;r<g;r++)f[0][r]=new Option(e[r],p[r]);var h=c("<div><label/></div>").addClass(a.sLength);d.aanFeatures.l||(h[0].id=b+"_length");h.children().append(d.oLanguage.sLengthMenu.replace("_MENU_",f[0].outerHTML));c("select",h).val(d._iDisplayLength).bind("change.DT",function(a){Ua(d,c(this).val());fa(d)});c(d.nTable).bind("length.dt.DT",function(a,b,x){d===b&&c("select",h).val(x)});return h[0]}function pb(d){var a=d.sPaginationType,b=B.ext.pager[a],
e="function"===typeof b,f=function(d){fa(d)},a=c("<div/>").addClass(d.oClasses.sPaging+a)[0],p=d.aanFeatures;e||b.fnInit(d,a,f);p.p||(a.id=d.sTableId+"_paginate",d.aoDrawCallback.push({fn:function(d){if(e){var a=d._iDisplayStart,c=d._iDisplayLength,x=d.fnRecordsDisplay(),g=-1===c,a=g?0:Math.ceil(a/c),c=g?1:Math.ceil(x/c),x=b(a,c),h,g=0;for(h=p.p.length;g<h;g++)Qa(d,"pageButton")(d,p.p[g],g,x,a,c)}else b.fnUpdate(d,f)},sName:"pagination"}));return a}function Wa(d,a,c){var b=d._iDisplayStart,e=d._iDisplayLength,
p=d.fnRecordsDisplay();0===p||-1===e?b=0:"number"===typeof a?(b=a*e,b>p&&(b=0)):"first"==a?b=0:"previous"==a?(b=0<=e?b-e:0,0>b&&(b=0)):"next"==a?b+e<p&&(b+=e):"last"==a?b=Math.floor((p-1)/e)*e:la(d,0,"Unknown paging action: "+a,5);a=d._iDisplayStart!==b;d._iDisplayStart=b;a&&(O(d,null,"page",[d]),c&&fa(d));return a}function mb(d){return c("<div/>",{id:d.aanFeatures.r?null:d.sTableId+"_processing","class":d.oClasses.sProcessing}).html(d.oLanguage.sProcessing).insertBefore(d.nTable)[0]}function Y(d,
a){d.oFeatures.bProcessing&&c(d.aanFeatures.r).css("display",a?"block":"none");O(d,null,"processing",[d,a])}function nb(d){var a=c(d.nTable);a.attr("role","grid");var b=d.oScroll;if(""===b.sX&&""===b.sY)return d.nTable;var e=b.sX,f=b.sY,p=d.oClasses,g=a.children("caption"),h=g.length?g[0]._captionSide:null,l=c(a[0].cloneNode(!1)),n=c(a[0].cloneNode(!1)),m=a.children("tfoot");b.sX&&"100%"===a.attr("width")&&a.removeAttr("width");m.length||(m=null);b=c("<div/>",{"class":p.sScrollWrapper}).append(c("<div/>",
{"class":p.sScrollHead}).css({overflow:"hidden",position:"relative",border:0,width:e?e?J(e):null:"100%"}).append(c("<div/>",{"class":p.sScrollHeadInner}).css({"box-sizing":"content-box",width:b.sXInner||"100%"}).append(l.removeAttr("id").css("margin-left",0).append(a.children("thead")))).append("top"===h?g:null)).append(c("<div/>",{"class":p.sScrollBody}).css({overflow:"auto",height:f?J(f):null,width:e?J(e):null}).append(a));m&&b.append(c("<div/>",{"class":p.sScrollFoot}).css({overflow:"hidden",border:0,
width:e?e?J(e):null:"100%"}).append(c("<div/>",{"class":p.sScrollFootInner}).append(n.removeAttr("id").css("margin-left",0).append(a.children("tfoot")))).append("bottom"===h?g:null));var a=b.children(),k=a[0],p=a[1],q=m?a[2]:null;e&&c(p).scroll(function(d){d=this.scrollLeft;k.scrollLeft=d;m&&(q.scrollLeft=d)});d.nScrollHead=k;d.nScrollBody=p;d.nScrollFoot=q;d.aoDrawCallback.push({fn:ra,sName:"scrolling"});return b[0]}function ra(d){var a=d.oScroll,b=a.sX,e=a.sXInner,f=a.sY,p=a.iBarWidth,g=c(d.nScrollHead),
h=g[0].style,l=g.children("div"),n=l[0].style,m=l.children("table"),l=d.nScrollBody,k=c(l),q=l.style,t=c(d.nScrollFoot).children("div"),v=t.children("table"),I=c(d.nTHead),E=c(d.nTable),H=E[0],S=H.style,Q=d.nTFoot?c(d.nTFoot):null,K=d.oBrowser,y=K.bScrollOversize,M,A,z,W,ea,B=[],na=[],C=[],ja,ka=function(d){d=d.style;d.paddingTop="0";d.paddingBottom="0";d.borderTopWidth="0";d.borderBottomWidth="0";d.height=0};E.children("thead, tfoot").remove();ea=I.clone().prependTo(E);M=I.find("tr");z=ea.find("tr");
ea.find("th, td").removeAttr("tabindex");Q&&(W=Q.clone().prependTo(E),A=Q.find("tr"),W=W.find("tr"));b||(q.width="100%",g[0].style.width="100%");c.each(oa(d,ea),function(a,c){ja=u(d,a);c.style.width=d.aoColumns[ja].sWidth});Q&&ca(function(d){d.style.width=""},W);a.bCollapse&&""!==f&&(q.height=k[0].offsetHeight+I[0].offsetHeight+"px");g=E.outerWidth();""===b?(S.width="100%",y&&(E.find("tbody").height()>l.offsetHeight||"scroll"==k.css("overflow-y"))&&(S.width=J(E.outerWidth()-p))):""!==e?S.width=J(e):
g==k.width()&&k.height()<E.height()?(S.width=J(g-p),E.outerWidth()>g-p&&(S.width=J(g))):S.width=J(g);g=E.outerWidth();ca(ka,z);ca(function(d){C.push(d.innerHTML);B.push(J(c(d).css("width")))},z);ca(function(d,a){d.style.width=B[a]},M);c(z).height(0);Q&&(ca(ka,W),ca(function(d){na.push(J(c(d).css("width")))},W),ca(function(d,a){d.style.width=na[a]},A),c(W).height(0));ca(function(d,a){d.innerHTML='<div class="dataTables_sizing" style="height:0;overflow:hidden;">'+C[a]+"</div>";d.style.width=B[a]},z);
Q&&ca(function(d,a){d.innerHTML="";d.style.width=na[a]},W);E.outerWidth()<g?(A=l.scrollHeight>l.offsetHeight||"scroll"==k.css("overflow-y")?g+p:g,y&&(l.scrollHeight>l.offsetHeight||"scroll"==k.css("overflow-y"))&&(S.width=J(A-p)),""!==b&&""===e||la(d,1,"Possible column misalignment",6)):A="100%";q.width=J(A);h.width=J(A);Q&&(d.nScrollFoot.style.width=J(A));!f&&y&&(q.height=J(H.offsetHeight+p));f&&a.bCollapse&&(q.height=J(f),a=b&&H.offsetWidth>l.offsetWidth?p:0,H.offsetHeight<l.offsetHeight&&(q.height=
J(H.offsetHeight+a)));a=E.outerWidth();m[0].style.width=J(a);n.width=J(a);m=E.height()>l.clientHeight||"scroll"==k.css("overflow-y");K="padding"+(K.bScrollbarLeft?"Left":"Right");n[K]=m?p+"px":"0px";Q&&(v[0].style.width=J(a),t[0].style.width=J(a),t[0].style[K]=m?p+"px":"0px");k.scroll();!d.bSorted&&!d.bFiltered||d._drawHold||(l.scrollTop=0)}function ca(d,a,c){for(var b=0,e=0,p=a.length,f,g;e<p;){f=a[e].firstChild;for(g=c?c[e].firstChild:null;f;)1===f.nodeType&&(c?d(f,g,b):d(f,b),b++),f=f.nextSibling,
g=c?g.nextSibling:null;e++}}function Ma(d){var b=d.nTable,e=d.aoColumns,f=d.oScroll,g=f.sY,p=f.sX,h=f.sXInner,l=e.length,f=v(d,"bVisible"),n=c("th",d.nTHead),m=b.getAttribute("width"),k=b.parentNode,q=!1,w,u;for(w=0;w<f.length;w++)u=e[f[w]],null!==u.sWidth&&(u.sWidth=yb(u.sWidthOrig,k),q=!0);if(q||p||g||l!=z(d)||l!=n.length){l=c(b).clone().empty().css("visibility","hidden").removeAttr("id").append(c(d.nTHead).clone(!1)).append(c(d.nTFoot).clone(!1)).append(c("<tbody><tr/></tbody>"));l.find("tfoot th, tfoot td").css("width",
"");var E=l.find("tbody tr"),n=oa(d,l.find("thead")[0]);for(w=0;w<f.length;w++)u=e[f[w]],n[w].style.width=null!==u.sWidthOrig&&""!==u.sWidthOrig?J(u.sWidthOrig):"";if(d.aoData.length)for(w=0;w<f.length;w++)q=f[w],u=e[q],c(zb(d,q)).clone(!1).append(u.sContentPadding).appendTo(E);l.appendTo(k);p&&h?l.width(h):p?(l.css("width","auto"),l.width()<k.offsetWidth&&l.width(k.offsetWidth)):g?l.width(k.offsetWidth):m&&l.width(m);Ab(d,l[0]);if(p){for(w=h=0;w<f.length;w++)u=e[f[w]],g=c(n[w]).outerWidth(),h+=null===
u.sWidthOrig?g:parseInt(u.sWidth,10)+g-c(n[w]).width();l.width(J(h));b.style.width=J(h)}for(w=0;w<f.length;w++)if(u=e[f[w]],g=c(n[w]).width())u.sWidth=J(g);b.style.width=J(l.css("width"));l.remove()}else for(w=0;w<l;w++)e[w].sWidth=J(n.eq(w).width());m&&(b.style.width=J(m));!m&&!p||d._reszEvt||(c(a).bind("resize.DT-"+d.sInstance,Ra(function(){t(d)})),d._reszEvt=!0)}function Ra(d,a){var c=a||200,b,e;return function(){var a=this,x=+new Date,f=arguments;b&&x<b+c?(clearTimeout(e),e=setTimeout(function(){b=
k;d.apply(a,f)},c)):b?(b=x,d.apply(a,f)):b=x}}function yb(d,a){if(!d)return 0;var b=c("<div/>").css("width",J(d)).appendTo(a||C.body),e=b[0].offsetWidth;b.remove();return e}function Ab(d,a){var b=d.oScroll;if(b.sX||b.sY)b=b.sX?0:b.iBarWidth,a.style.width=J(c(a).outerWidth()-b)}function zb(d,a){var b=Bb(d,a);if(0>b)return null;var e=d.aoData[b];return e.nTr?e.anCells[a]:c("<td/>").html(M(d,b,a,"display"))[0]}function Bb(d,a){for(var c,b=-1,e=-1,p=0,f=d.aoData.length;p<f;p++)c=M(d,p,a,"display")+"",
c=c.replace(Sb,""),c.length>b&&(b=c.length,e=p);return e}function J(d){return null===d?"0px":"number"==typeof d?0>d?"0px":d+"px":d.match(/\d$/)?d+"px":d}function Cb(){if(!B.__scrollbarWidth){var d=c("<p/>").css({width:"100%",height:200,padding:0})[0],a=c("<div/>").css({position:"absolute",top:0,left:0,width:200,height:150,padding:0,overflow:"hidden",visibility:"hidden"}).append(d).appendTo("body"),b=d.offsetWidth;a.css("overflow","scroll");d=d.offsetWidth;b===d&&(d=a[0].clientWidth);a.remove();B.__scrollbarWidth=
b-d}return B.__scrollbarWidth}function pa(d){var a,b,e=[],f=d.aoColumns,p,g,h,l;a=d.aaSortingFixed;b=c.isPlainObject(a);var n=[];p=function(d){d.length&&!c.isArray(d[0])?n.push(d):n.push.apply(n,d)};c.isArray(a)&&p(a);b&&a.pre&&p(a.pre);p(d.aaSorting);b&&a.post&&p(a.post);for(d=0;d<n.length;d++)for(l=n[d][0],p=f[l].aDataSort,a=0,b=p.length;a<b;a++)g=p[a],h=f[g].sType||"string",e.push({src:l,col:g,dir:n[d][1],index:n[d][2],type:h,formatter:B.ext.type.order[h+"-pre"]});return e}function jb(d){var a,
c,b=[],e=B.ext.type.order,p=d.aoData,f=0,g,h=d.aiDisplayMaster,l;I(d);l=pa(d);a=0;for(c=l.length;a<c;a++)g=l[a],g.formatter&&f++,Db(d,g.col);if("ssp"!=X(d)&&0!==l.length){a=0;for(c=h.length;a<c;a++)b[h[a]]=a;f===l.length?h.sort(function(d,a){var c,e,x,f,D=l.length,g=p[d]._aSortData,h=p[a]._aSortData;for(x=0;x<D;x++)if(f=l[x],c=g[f.col],e=h[f.col],c=c<e?-1:c>e?1:0,0!==c)return"asc"===f.dir?c:-c;c=b[d];e=b[a];return c<e?-1:c>e?1:0}):h.sort(function(d,a){var c,x,f,D,g=l.length,h=p[d]._aSortData,r=p[a]._aSortData;
for(f=0;f<g;f++)if(D=l[f],c=h[D.col],x=r[D.col],D=e[D.type+"-"+D.dir]||e["string-"+D.dir],c=D(c,x),0!==c)return c;c=b[d];x=b[a];return c<x?-1:c>x?1:0})}d.bSorted=!0}function Eb(d){var a,c,b=d.aoColumns,e=pa(d);d=d.oLanguage.oAria;for(var f=0,g=b.length;f<g;f++){c=b[f];var h=c.asSorting;a=c.sTitle.replace(/<.*?>/g,"");var l=c.nTh;l.removeAttribute("aria-sort");c.bSortable&&(0<e.length&&e[0].col==f?(l.setAttribute("aria-sort","asc"==e[0].dir?"ascending":"descending"),c=h[e[0].index+1]||h[0]):c=h[0],
a+="asc"===c?d.sSortAscending:d.sSortDescending);l.setAttribute("aria-label",a)}}function Xa(d,a,b,e){var f=d.aaSorting,p=d.aoColumns[a].asSorting,g=function(d){var a=d._idx;a===k&&(a=c.inArray(d[1],p));return a+1>=p.length?0:a+1};"number"===typeof f[0]&&(f=d.aaSorting=[f]);b&&d.oFeatures.bSortMulti?(b=c.inArray(a,aa(f,"0")),-1!==b?(a=g(f[b]),f[b][1]=p[a],f[b]._idx=a):(f.push([a,p[0],0]),f[f.length-1]._idx=0)):f.length&&f[0][0]==a?(a=g(f[0]),f.length=1,f[0][1]=p[a],f[0]._idx=a):(f.length=0,f.push([a,
p[0]]),f[0]._idx=0);ha(d);"function"==typeof e&&e(d)}function Pa(d,a,c,b){var e=d.aoColumns[c];Ya(a,{},function(a){!1!==e.bSortable&&(d.oFeatures.bProcessing?(Y(d,!0),setTimeout(function(){Xa(d,c,a.shiftKey,b);"ssp"!==X(d)&&Y(d,!1)},0)):Xa(d,c,a.shiftKey,b))})}function Fa(d){var a=d.aLastSort,b=d.oClasses.sSortColumn,e=pa(d),f=d.oFeatures,p,g;if(f.bSort&&f.bSortClasses){f=0;for(p=a.length;f<p;f++)g=a[f].src,c(aa(d.aoData,"anCells",g)).removeClass(b+(2>f?f+1:3));f=0;for(p=e.length;f<p;f++)g=e[f].src,
c(aa(d.aoData,"anCells",g)).addClass(b+(2>f?f+1:3))}d.aLastSort=e}function Db(d,a){var c=d.aoColumns[a],b=B.ext.order[c.sSortDataType],e;b&&(e=b.call(d.oInstance,d,a,y(d,a)));for(var f,g=B.ext.type.order[c.sType+"-pre"],h=0,l=d.aoData.length;h<l;h++)if(c=d.aoData[h],c._aSortData||(c._aSortData=[]),!c._aSortData[a]||b)f=b?e[h]:M(d,h,a,"sort"),c._aSortData[a]=g?g(f):f}function Ga(d){if(d.oFeatures.bStateSave&&!d.bDestroying){var a={time:+new Date,start:d._iDisplayStart,length:d._iDisplayLength,order:c.extend(!0,
[],d.aaSorting),search:ub(d.oPreviousSearch),columns:c.map(d.aoColumns,function(a,c){return{visible:a.bVisible,search:ub(d.aoPreSearchCols[c])}})};O(d,"aoStateSaveParams","stateSaveParams",[d,a]);d.oSavedState=a;d.fnStateSaveCallback.call(d.oInstance,d,a)}}function Fb(d,a){var b,e,f=d.aoColumns;if(d.oFeatures.bStateSave){var p=d.fnStateLoadCallback.call(d.oInstance,d);if(p&&p.time&&(b=O(d,"aoStateLoadParams","stateLoadParams",[d,p]),-1===c.inArray(!1,b)&&(b=d.iStateDuration,!(0<b&&p.time<+new Date-
1E3*b)&&f.length===p.columns.length))){d.oLoadedState=c.extend(!0,{},p);d._iDisplayStart=p.start;d.iInitDisplayStart=p.start;d._iDisplayLength=p.length;d.aaSorting=[];c.each(p.order,function(a,c){d.aaSorting.push(c[0]>=f.length?[0,c[1]]:c)});c.extend(d.oPreviousSearch,vb(p.search));b=0;for(e=p.columns.length;b<e;b++){var g=p.columns[b];f[b].bVisible=g.visible;c.extend(d.aoPreSearchCols[b],vb(g.search))}O(d,"aoStateLoaded","stateLoaded",[d,p])}}}function Ha(d){var a=B.settings;d=c.inArray(d,aa(a,"nTable"));
return-1!==d?a[d]:null}function la(d,c,b,e){b="DataTables warning: "+(null!==d?"table id="+d.sTableId+" - ":"")+b;e&&(b+=". For more information about this error, please see http://datatables.net/tn/"+e);c?a.console&&console.log&&console.log(b):console.error(b)}function ba(d,a,b,e){c.isArray(b)?c.each(b,function(b,e){c.isArray(e)?ba(d,a,e[0],e[1]):ba(d,a,e)}):(e===k&&(e=b),a[b]!==k&&(d[e]=a[b]))}function Gb(d,a,b){var e,f;for(f in a)a.hasOwnProperty(f)&&(e=a[f],c.isPlainObject(e)?(c.isPlainObject(d[f])||
(d[f]={}),c.extend(!0,d[f],e)):b&&"data"!==f&&"aaData"!==f&&c.isArray(e)?d[f]=e.slice():d[f]=e);return d}function Ya(d,a,b){c(d).bind("click.DT",a,function(a){d.blur();b(a)}).bind("keypress.DT",a,function(d){13===d.which&&(d.preventDefault(),b(d))}).bind("selectstart.DT",function(){return!1})}function U(d,a,c,b){c&&d[a].push({fn:c,sName:b})}function O(d,a,b,e){var f=[];a&&(f=c.map(d[a].slice().reverse(),function(a,c){return a.fn.apply(d.oInstance,e)}));null!==b&&c(d.nTable).trigger(b+".dt",e);return f}
function Va(d){var a=d._iDisplayStart,c=d.fnDisplayEnd(),b=d._iDisplayLength;c===d.fnRecordsDisplay()&&(a=c-b);if(-1===b||0>a)a=0;d._iDisplayStart=a}function Qa(d,a){var b=d.renderer,e=B.ext.renderer[a];return c.isPlainObject(b)&&b[a]?e[b[a]]||e._:"string"===typeof b?e[b]||e._:e._}function X(d){return d.oFeatures.bServerSide?"ssp":d.ajax||d.sAjaxSource?"ajax":"dom"}function Za(d,a){var c=[],c=Hb.numbers_length,b=Math.floor(c/2);a<=c?c=qa(0,a):d<=b?(c=qa(0,c-2),c.push("ellipsis"),c.push(a-1)):(d>=
a-1-b?c=qa(a-(c-2),a):(c=qa(d-1,d+2),c.push("ellipsis"),c.push(a-1)),c.splice(0,0,"ellipsis"),c.splice(0,0,0));c.DT_el="span";return c}function hb(d){c.each({num:function(a){return Ia(a,d)},"num-fmt":function(a){return Ia(a,d,$a)},"html-num":function(a){return Ia(a,d,Ja)},"html-num-fmt":function(a){return Ia(a,d,Ja,$a)}},function(a,c){T.type.order[a+d+"-pre"]=c})}function Ib(d){return function(){var a=[Ha(this[B.ext.iApiIndex])].concat(Array.prototype.slice.call(arguments));return B.ext.internal[d].apply(this,
a)}}var B,T,L,F,P,ab={},Jb=/[\r\n]/g,Ja=/<.*?>/g,Tb=/^[\w\+\-]/,Ub=/[\w\+\-]$/,Qb=RegExp("(\\/|\\.|\\*|\\+|\\?|\\||\\(|\\)|\\[|\\]|\\{|\\}|\\\\|\\$|\\^|\\-)","g"),$a=/[',$\u00a3\u20ac\u00a5%\u2009\u202F]/g,da=function(d){return d&&!0!==d&&"-"!==d?!1:!0},Kb=function(d){var a=parseInt(d,10);return!isNaN(a)&&isFinite(d)?a:null},Lb=function(d,a){ab[a]||(ab[a]=new RegExp(Ta(a),"g"));return"string"===typeof d?d.replace(/\./g,"").replace(ab[a],"."):d},bb=function(d,a,c){var b="string"===typeof d;a&&b&&(d=
Lb(d,a));c&&b&&(d=d.replace($a,""));return da(d)||!isNaN(parseFloat(d))&&isFinite(d)},Mb=function(d,a,c){return da(d)?!0:da(d)||"string"===typeof d?bb(d.replace(Ja,""),a,c)?!0:null:null},aa=function(d,a,c){var b=[],e=0,f=d.length;if(c!==k)for(;e<f;e++)d[e]&&d[e][a]&&b.push(d[e][a][c]);else for(;e<f;e++)d[e]&&b.push(d[e][a]);return b},Ka=function(d,a,c,b){var e=[],f=0,g=a.length;if(b!==k)for(;f<g;f++)e.push(d[a[f]][c][b]);else for(;f<g;f++)e.push(d[a[f]][c]);return e},qa=function(d,a){var c=[],b;a===
k?(a=0,b=d):(b=a,a=d);for(var e=a;e<b;e++)c.push(e);return c},Oa=function(d){var a=[],c,b,e=d.length,f,g=0;b=0;a:for(;b<e;b++){c=d[b];for(f=0;f<g;f++)if(a[f]===c)continue a;a.push(c);g++}return a},V=function(d,a,c){d[a]!==k&&(d[c]=d[a])},sa=/\[.*?\]$/,ma=/\(\)$/,Da=c("<div>")[0],Rb=Da.textContent!==k,Sb=/<.*?>/g;B=function(d){this.$=function(d,a){return this.api(!0).$(d,a)};this._=function(d,a){return this.api(!0).rows(d,a).data()};this.api=function(d){return d?new L(Ha(this[T.iApiIndex])):new L(this)};
this.fnAddData=function(d,a){var b=this.api(!0),e=c.isArray(d)&&(c.isArray(d[0])||c.isPlainObject(d[0]))?b.rows.add(d):b.row.add(d);(a===k||a)&&b.draw();return e.flatten().toArray()};this.fnAdjustColumnSizing=function(d){var a=this.api(!0).columns.adjust(),c=a.settings()[0],b=c.oScroll;d===k||d?a.draw(!1):""===b.sX&&""===b.sY||ra(c)};this.fnClearTable=function(d){var a=this.api(!0).clear();(d===k||d)&&a.draw()};this.fnClose=function(d){this.api(!0).row(d).child.hide()};this.fnDeleteRow=function(d,
a,c){var b=this.api(!0);d=b.rows(d);var e=d.settings()[0],f=e.aoData[d[0][0]];d.remove();a&&a.call(this,e,f);(c===k||c)&&b.draw();return f};this.fnDestroy=function(d){this.api(!0).destroy(d)};this.fnDraw=function(d){this.api(!0).draw(!d)};this.fnFilter=function(d,a,c,b,e,f){e=this.api(!0);null===a||a===k?e.search(d,c,b,f):e.column(a).search(d,c,b,f);e.draw()};this.fnGetData=function(d,a){var c=this.api(!0);if(d!==k){var b=d.nodeName?d.nodeName.toLowerCase():"";return a!==k||"td"==b||"th"==b?c.cell(d,
a).data():c.row(d).data()||null}return c.data().toArray()};this.fnGetNodes=function(d){var a=this.api(!0);return d!==k?a.row(d).node():a.rows().nodes().flatten().toArray()};this.fnGetPosition=function(d){var a=this.api(!0),c=d.nodeName.toUpperCase();return"TR"==c?a.row(d).index():"TD"==c||"TH"==c?(d=a.cell(d).index(),[d.row,d.columnVisible,d.column]):null};this.fnIsOpen=function(d){return this.api(!0).row(d).child.isShown()};this.fnOpen=function(d,a,c){return this.api(!0).row(d).child(a,c).show().child()[0]};
this.fnPageChange=function(d,a){var c=this.api(!0).page(d);(a===k||a)&&c.draw(!1)};this.fnSetColumnVis=function(d,a,c){d=this.api(!0).column(d).visible(a);(c===k||c)&&d.columns.adjust().draw()};this.fnSettings=function(){return Ha(this[T.iApiIndex])};this.fnSort=function(d){this.api(!0).order(d).draw()};this.fnSortListener=function(d,a,c){this.api(!0).order.listener(d,a,c)};this.fnUpdate=function(d,a,c,b,e){var f=this.api(!0);c===k||null===c?f.row(a).data(d):f.cell(a,c).data(d);(e===k||e)&&f.columns.adjust();
(b===k||b)&&f.draw();return 0};this.fnVersionCheck=T.fnVersionCheck;var a=this,b=d===k,g=this.length;b&&(d={});this.oApi=this.internal=T.internal;for(var t in B.ext.internal)t&&(this[t]=Ib(t));this.each(function(){var p={},r=1<g?Gb(p,d,!0):d,t=0,v,Z=this.getAttribute("id"),p=!1,u=B.defaults;if("table"!=this.nodeName.toLowerCase())la(null,0,"Non-table node initialisation ("+this.nodeName+")",2);else{e(u);f(u.column);h(u,u,!0);h(u.column,u.column,!0);h(u,r);var E=B.settings,t=0;for(v=E.length;t<v;t++){if(E[t].nTable==
this){v=r.bRetrieve!==k?r.bRetrieve:u.bRetrieve;if(b||v)return E[t].oInstance;if(r.bDestroy!==k?r.bDestroy:u.bDestroy){E[t].oInstance.fnDestroy();break}else{la(E[t],0,"Cannot reinitialise DataTable",3);return}}if(E[t].sTableId==this.id){E.splice(t,1);break}}if(null===Z||""===Z)this.id=Z="DataTables_Table_"+B.ext._unique++;var w=c.extend(!0,{},B.models.oSettings,{nTable:this,oApi:a.internal,oInit:r,sDestroyWidth:c(this)[0].style.width,sInstance:Z,sTableId:Z});E.push(w);w.oInstance=1===a.length?a:c(this).dataTable();
e(r);r.oLanguage&&m(r.oLanguage);r.aLengthMenu&&!r.iDisplayLength&&(r.iDisplayLength=c.isArray(r.aLengthMenu[0])?r.aLengthMenu[0][0]:r.aLengthMenu[0]);r=Gb(c.extend(!0,{},u),r);ba(w.oFeatures,r,"bPaginate bLengthChange bFilter bSort bSortMulti bInfo bProcessing bAutoWidth bSortClasses bServerSide bDeferRender".split(" "));ba(w,r,["asStripeClasses","ajax","fnServerData","fnFormatNumber","sServerMethod","aaSorting","aaSortingFixed","aLengthMenu","sPaginationType","sAjaxSource","sAjaxDataProp","iStateDuration",
"sDom","bSortCellsTop","iTabIndex","fnStateLoadCallback","fnStateSaveCallback","renderer",["iCookieDuration","iStateDuration"],["oSearch","oPreviousSearch"],["aoSearchCols","aoPreSearchCols"],["iDisplayLength","_iDisplayLength"],["bJQueryUI","bJUI"]]);ba(w.oScroll,r,[["sScrollX","sX"],["sScrollXInner","sXInner"],["sScrollY","sY"],["bScrollCollapse","bCollapse"]]);ba(w.oLanguage,r,"fnInfoCallback");U(w,"aoDrawCallback",r.fnDrawCallback,"user");U(w,"aoServerParams",r.fnServerParams,"user");U(w,"aoStateSaveParams",
r.fnStateSaveParams,"user");U(w,"aoStateLoadParams",r.fnStateLoadParams,"user");U(w,"aoStateLoaded",r.fnStateLoaded,"user");U(w,"aoRowCallback",r.fnRowCallback,"user");U(w,"aoRowCreatedCallback",r.fnCreatedRow,"user");U(w,"aoHeaderCallback",r.fnHeaderCallback,"user");U(w,"aoFooterCallback",r.fnFooterCallback,"user");U(w,"aoInitComplete",r.fnInitComplete,"user");U(w,"aoPreDrawCallback",r.fnPreDrawCallback,"user");Z=w.oClasses;r.bJQueryUI?(c.extend(Z,B.ext.oJUIClasses,r.oClasses),r.sDom===u.sDom&&"lfrtip"===
u.sDom&&(w.sDom='<"H"lfr>t<"F"ip>'),w.renderer)?c.isPlainObject(w.renderer)&&!w.renderer.header&&(w.renderer.header="jqueryui"):w.renderer="jqueryui":c.extend(Z,B.ext.classes,r.oClasses);c(this).addClass(Z.sTable);if(""!==w.oScroll.sX||""!==w.oScroll.sY)w.oScroll.iBarWidth=Cb();!0===w.oScroll.sX&&(w.oScroll.sX="100%");w.iInitDisplayStart===k&&(w.iInitDisplayStart=r.iDisplayStart,w._iDisplayStart=r.iDisplayStart);null!==r.iDeferLoading&&(w.bDeferLoading=!0,t=c.isArray(r.iDeferLoading),w._iRecordsDisplay=
t?r.iDeferLoading[0]:r.iDeferLoading,w._iRecordsTotal=t?r.iDeferLoading[1]:r.iDeferLoading);""!==r.oLanguage.sUrl?(w.oLanguage.sUrl=r.oLanguage.sUrl,c.getJSON(w.oLanguage.sUrl,null,function(d){m(d);h(u.oLanguage,d);c.extend(!0,w.oLanguage,r.oLanguage,d);Ea(w)}),p=!0):c.extend(!0,w.oLanguage,r.oLanguage);null===r.asStripeClasses&&(w.asStripeClasses=[Z.sStripeOdd,Z.sStripeEven]);var t=w.asStripeClasses,I=c("tbody tr:eq(0)",this);-1!==c.inArray(!0,c.map(t,function(d,a){return I.hasClass(d)}))&&(c("tbody tr",
this).removeClass(t.join(" ")),w.asDestroyStripes=t.slice());var E=[],S,t=this.getElementsByTagName("thead");0!==t.length&&(N(w.aoHeader,t[0]),E=oa(w));if(null===r.aoColumns)for(S=[],t=0,v=E.length;t<v;t++)S.push(null);else S=r.aoColumns;t=0;for(v=S.length;t<v;t++)q(w,E?E[t]:null);K(w,r.aoColumnDefs,S,function(d,a){l(w,d,a)});if(I.length){var Q=function(d,a){return d.getAttribute("data-"+a)?a:null};c.each(wa(w,I[0]).cells,function(d,a){var c=w.aoColumns[d];try{if(c.mData===d){var b=Q(a,"sort")||Q(a,
"order"),e=Q(a,"filter")||Q(a,"search");if(null!==b||null!==e)c.mData={_:d+".display",sort:null!==b?d+".@data-"+b:k,type:null!==b?d+".@data-"+b:k,filter:null!==e?d+".@data-"+e:k},l(w,d)}}catch(f){console.error(f)}})}var y=w.oFeatures;r.bStateSave&&(y.bStateSave=!0,Fb(w,r),U(w,"aoDrawCallback",Ga,"state_save"));if(r.aaSorting===k)for(E=w.aaSorting,t=0,v=E.length;t<v;t++)E[t][1]=w.aoColumns[t].asSorting[0];Fa(w);y.bSort&&U(w,"aoDrawCallback",function(){if(w.bSorted){var d=pa(w),a={};c.each(d,function(d,
c){a[c.src]=c.dir});O(w,null,"order",[w,d,a]);Eb(w)}});U(w,"aoDrawCallback",function(){(w.bSorted||"ssp"===X(w)||y.bDeferRender)&&Fa(w)},"sc");n(w);t=c(this).children("caption").each(function(){this._captionSide=c(this).css("caption-side")});v=c(this).children("thead");0===v.length&&(v=c("<thead/>").appendTo(this));w.nTHead=v[0];v=c(this).children("tbody");0===v.length&&(v=c("<tbody/>").appendTo(this));w.nTBody=v[0];v=c(this).children("tfoot");0===v.length&&0<t.length&&(""!==w.oScroll.sX||""!==w.oScroll.sY)&&
(v=c("<tfoot/>").appendTo(this));0===v.length||0===v.children().length?c(this).addClass(Z.sNoFooter):0<v.length&&(w.nTFoot=v[0],N(w.aoFooter,w.nTFoot));if(r.aaData)for(t=0;t<r.aaData.length;t++)H(w,r.aaData[t]);else(w.bDeferLoading||"dom"==X(w))&&A(w,c(w.nTBody).children("tr"));w.aiDisplay=w.aiDisplayMaster.slice();w.bInitialised=!0;!1===p&&Ea(w)}});a=null;return this};var Nb=[],R=Array.prototype,Vb=function(d){var a,b,e=B.settings,f=c.map(e,function(d,a){return d.nTable});if(d){if(d.nTable&&d.oApi)return[d];
if(d.nodeName&&"table"===d.nodeName.toLowerCase())return a=c.inArray(d,f),-1!==a?[e[a]]:null;if(d&&"function"===typeof d.settings)return d.settings().toArray();"string"===typeof d?b=c(d):d instanceof c&&(b=d)}else return[];if(b)return b.map(function(d){a=c.inArray(this,f);return-1!==a?e[a]:null}).toArray()};L=function(d,a){if(!this instanceof L)throw"DT API must be constructed as a new object";var b=[],e=function(d){(d=Vb(d))&&b.push.apply(b,d)};if(c.isArray(d))for(var f=0,g=d.length;f<g;f++)e(d[f]);
else e(d);this.context=Oa(b);a&&this.push.apply(this,a.toArray?a.toArray():a);this.selector={rows:null,cols:null,opts:null};L.extend(this,this,Nb)};B.Api=L;L.prototype={concat:R.concat,context:[],each:function(d){for(var a=0,c=this.length;a<c;a++)d.call(this,this[a],a,this);return this},eq:function(d){var a=this.context;return a.length>d?new L(a[d],this[d]):null},filter:function(d){var a=[];if(R.filter)a=R.filter.call(this,d,this);else for(var c=0,b=this.length;c<b;c++)d.call(this,this[c],c,this)&&
a.push(this[c]);return new L(this.context,a)},flatten:function(){var d=[];return new L(this.context,d.concat.apply(d,this.toArray()))},join:R.join,indexOf:R.indexOf||function(d,a){for(var c=a||0,b=this.length;c<b;c++)if(this[c]===d)return c;return-1},iterator:function(d,a,c){var b=[],e,f,g,h,l,n=this.context,m,q,t=this.selector;"string"===typeof d&&(c=a,a=d,d=!1);f=0;for(g=n.length;f<g;f++)if("table"===a)e=c(n[f],f),e!==k&&b.push(e);else if("columns"===a||"rows"===a)e=c(n[f],this[f],f),e!==k&&b.push(e);
else if("column"===a||"column-rows"===a||"row"===a||"cell"===a)for(q=this[f],"column-rows"===a&&(m=cb(n[f],t.opts)),h=0,l=q.length;h<l;h++)e=q[h],e="cell"===a?c(n[f],e.row,e.column,f,h):c(n[f],e,f,h,m),e!==k&&b.push(e);return b.length?(d=new L(n,d?b.concat.apply([],b):b),a=d.selector,a.rows=t.rows,a.cols=t.cols,a.opts=t.opts,d):this},lastIndexOf:R.lastIndexOf||function(d,a){return this.indexOf.apply(this.toArray.reverse(),arguments)},length:0,map:function(d){var a=[];if(R.map)a=R.map.call(this,d,
this);else for(var c=0,b=this.length;c<b;c++)a.push(d.call(this,this[c],c));return new L(this.context,a)},pluck:function(d){return this.map(function(a){return a[d]})},pop:R.pop,push:R.push,reduce:R.reduce||function(d,a){return g(this,d,a,0,this.length,1)},reduceRight:R.reduceRight||function(d,a){return g(this,d,a,this.length-1,-1,-1)},reverse:R.reverse,selector:null,shift:R.shift,sort:R.sort,splice:R.splice,toArray:function(){return R.slice.call(this)},to$:function(){return c(this)},toJQuery:function(){return c(this)},
unique:function(){return new L(this.context,Oa(this))},unshift:R.unshift};L.extend=function(d,a,b){if(a&&(a instanceof L||a.__dt_wrapper)){var e,f,g,h=function(d,a,c){return function(){var b=a.apply(d,arguments);L.extend(b,b,c.methodExt);return b}};e=0;for(f=b.length;e<f;e++)g=b[e],a[g.name]="function"===typeof g.val?h(d,g.val,g):c.isPlainObject(g.val)?{}:g.val,a[g.name].__dt_wrapper=!0,L.extend(d,a[g.name],g.propExt)}};L.register=F=function(d,a){if(c.isArray(d))for(var b=0,e=d.length;b<e;b++)L.register(d[b],
a);else for(var f=d.split("."),g=Nb,h,l,b=0,e=f.length;b<e;b++){h=(l=-1!==f[b].indexOf("()"))?f[b].replace("()",""):f[b];var n;a:{n=0;for(var m=g.length;n<m;n++)if(g[n].name===h){n=g[n];break a}n=null}n||(n={name:h,val:{},methodExt:[],propExt:[]},g.push(n));b===e-1?n.val=a:g=l?n.methodExt:n.propExt}};L.registerPlural=P=function(d,a,b){L.register(d,b);L.register(a,function(){var d=b.apply(this,arguments);return d===this?this:d instanceof L?d.length?c.isArray(d[0])?new L(d.context,d[0]):d[0]:k:d})};
var Wb=function(d,a){if("number"===typeof d)return[a[d]];var b=c.map(a,function(d,a){return d.nTable});return c(b).filter(d).map(function(d){d=c.inArray(this,b);return a[d]}).toArray()};F("tables()",function(d){return d?new L(Wb(d,this.context)):this});F("table()",function(d){d=this.tables(d);var a=d.context;return a.length?new L(a[0]):d});P("tables().nodes()","table().node()",function(){return this.iterator("table",function(d){return d.nTable})});P("tables().body()","table().body()",function(){return this.iterator("table",
function(d){return d.nTBody})});P("tables().header()","table().header()",function(){return this.iterator("table",function(d){return d.nTHead})});P("tables().footer()","table().footer()",function(){return this.iterator("table",function(d){return d.nTFoot})});P("tables().containers()","table().container()",function(){return this.iterator("table",function(d){return d.nTableWrapper})});F("draw()",function(d){return this.iterator("table",function(a){ha(a,!1===d)})});F("page()",function(d){return d===k?
this.page.info().page:this.iterator("table",function(a){Wa(a,d)})});F("page.info()",function(d){if(0===this.context.length)return k;d=this.context[0];var a=d._iDisplayStart,c=d._iDisplayLength,b=d.fnRecordsDisplay(),e=-1===c;return{page:e?0:Math.floor(a/c),pages:e?1:Math.ceil(b/c),start:a,end:d.fnDisplayEnd(),length:c,recordsTotal:d.fnRecordsTotal(),recordsDisplay:b}});F("page.len()",function(d){return d===k?0!==this.context.length?this.context[0]._iDisplayLength:k:this.iterator("table",function(a){Ua(a,
d)})});var Ob=function(d,a,c){"ssp"==X(d)?ha(d,a):(Y(d,!0),ia(d,[],function(c){xa(d);c=ja(d,c);for(var b=0,e=c.length;b<e;b++)H(d,c[b]);ha(d,a);Y(d,!1)}));if(c){var b=new L(d);b.one("draw",function(){c(b.ajax.json())})}};F("ajax.json()",function(){var d=this.context;if(0<d.length)return d[0].json});F("ajax.params()",function(){var d=this.context;if(0<d.length)return d[0].oAjaxData});F("ajax.reload()",function(d,a){return this.iterator("table",function(c){Ob(c,!1===a,d)})});F("ajax.url()",function(d){var a=
this.context;if(d===k){if(0===a.length)return k;a=a[0];return a.ajax?c.isPlainObject(a.ajax)?a.ajax.url:a.ajax:a.sAjaxSource}return this.iterator("table",function(a){c.isPlainObject(a.ajax)?a.ajax.url=d:a.ajax=d})});F("ajax.url().load()",function(a,c){return this.iterator("table",function(b){Ob(b,!1===c,a)})});var db=function(a,b){var e=[],f,g,h,l,n,m;a&&"string"!==typeof a&&a.length!==k||(a=[a]);h=0;for(l=a.length;h<l;h++)for(g=a[h]&&a[h].split?a[h].split(","):[a[h]],n=0,m=g.length;n<m;n++)(f=b("string"===
typeof g[n]?c.trim(g[n]):g[n]))&&f.length&&e.push.apply(e,f);return e},eb=function(a){a||(a={});a.filter&&!a.search&&(a.search=a.filter);return{search:a.search||"none",order:a.order||"current",page:a.page||"all"}},fb=function(a){for(var c=0,b=a.length;c<b;c++)if(0<a[c].length)return a[0]=a[c],a.length=1,a.context=[a.context[c]],a;a.length=0;return a},cb=function(a,b){var e,f,g,h=[],l=a.aiDisplay;e=a.aiDisplayMaster;var n=b.search;f=b.order;g=b.page;if("ssp"==X(a))return"removed"===n?[]:qa(0,e.length);
if("current"==g)for(e=a._iDisplayStart,f=a.fnDisplayEnd();e<f;e++)h.push(l[e]);else if("current"==f||"applied"==f)h="none"==n?e.slice():"applied"==n?l.slice():c.map(e,function(a,d){return-1===c.inArray(a,l)?a:null});else if("index"==f||"original"==f)for(e=0,f=a.aoData.length;e<f;e++)"none"==n?h.push(e):(g=c.inArray(e,l),(-1===g&&"removed"==n||0<=g&&"applied"==n)&&h.push(e));return h},Xb=function(a,b,e){return db(b,function(b){var f=Kb(b);if(null!==f&&!e)return[f];var g=cb(a,e);if(null!==f&&-1!==c.inArray(f,
g))return[f];if(!b)return g;for(var f=[],h=0,l=g.length;h<l;h++)f.push(a.aoData[g[h]].nTr);return b.nodeName&&-1!==c.inArray(b,f)?[b._DT_RowIndex]:c(f).filter(b).map(function(){return this._DT_RowIndex}).toArray()})};F("rows()",function(a,b){a===k?a="":c.isPlainObject(a)&&(b=a,a="");b=eb(b);var e=this.iterator("table",function(c){return Xb(c,a,b)});e.selector.rows=a;e.selector.opts=b;return e});F("rows().nodes()",function(){return this.iterator("row",function(a,c){return a.aoData[c].nTr||k})});F("rows().data()",
function(){return this.iterator(!0,"rows",function(a,c){return Ka(a.aoData,c,"_aData")})});P("rows().cache()","row().cache()",function(a){return this.iterator("row",function(c,b){var e=c.aoData[b];return"search"===a?e._aFilterData:e._aSortData})});P("rows().invalidate()","row().invalidate()",function(a){return this.iterator("row",function(c,b){ya(c,b,a)})});P("rows().indexes()","row().index()",function(){return this.iterator("row",function(a,c){return c})});P("rows().remove()","row().remove()",function(){var a=
this;return this.iterator("row",function(b,e,f){var g=b.aoData;g.splice(e,1);for(var h=0,l=g.length;h<l;h++)null!==g[h].nTr&&(g[h].nTr._DT_RowIndex=h);c.inArray(e,b.aiDisplay);Q(b.aiDisplayMaster,e);Q(b.aiDisplay,e);Q(a[f],e,!1);Va(b)})});F("rows.add()",function(a){var c=this.iterator("table",function(c){var b,e,f,g=[];e=0;for(f=a.length;e<f;e++)b=a[e],b.nodeName&&"TR"===b.nodeName.toUpperCase()?g.push(A(c,b)[0]):g.push(H(c,b));return g}),b=this.rows(-1);b.pop();b.push.apply(b,c.toArray());return b});
F("row()",function(a,c){return fb(this.rows(a,c))});F("row().data()",function(a){var c=this.context;if(a===k)return c.length&&this.length?c[0].aoData[this[0]]._aData:k;c[0].aoData[this[0]]._aData=a;ya(c[0],this[0],"data");return this});F("row().node()",function(){var a=this.context;return a.length&&this.length?a[0].aoData[this[0]].nTr||null:null});F("row.add()",function(a){a instanceof c&&a.length&&(a=a[0]);var b=this.iterator("table",function(c){return a.nodeName&&"TR"===a.nodeName.toUpperCase()?
A(c,a)[0]:H(c,a)});return this.row(b[0])});var Yb=function(a,b,e,f){var g=[],h=function(b,e){if(b.nodeName&&"tr"===b.nodeName.toLowerCase())g.push(b);else{var f=c("<tr><td/></tr>").addClass(e);c("td",f).addClass(e).html(b)[0].colSpan=z(a);g.push(f[0])}};if(c.isArray(e)||e instanceof c)for(var l=0,n=e.length;l<n;l++)h(e[l],f);else h(e,f);b._details&&b._details.remove();b._details=c(g);b._detailsShow&&b._details.insertAfter(b.nTr)},gb=function(a){var c=a.context;c.length&&a.length&&(a=c[0].aoData[a[0]],
a._details&&(a._details.remove(),a._detailsShow=k,a._details=k))},Pb=function(a,c){var b=a.context;if(b.length&&a.length){var e=b[0].aoData[a[0]];e._details&&((e._detailsShow=c)?e._details.insertAfter(e.nTr):e._details.detach(),Zb(b[0]))}},Zb=function(a){var c=new L(a),b=a.aoData;c.off("draw.dt.DT_details column-visibility.dt.DT_details destroy.dt.DT_details");0<aa(b,"_details").length&&(c.on("draw.dt.DT_details",function(e,f){a===f&&c.rows({page:"current"}).eq(0).each(function(a){a=b[a];a._detailsShow&&
a._details.insertAfter(a.nTr)})}),c.on("column-visibility.dt.DT_details",function(c,e,f,g){if(a===e)for(e=z(e),f=0,g=b.length;f<g;f++)c=b[f],c._details&&c._details.children("td[colspan]").attr("colspan",e)}),c.on("destroy.dt.DT_details",function(c,e){if(a===e)for(var f=0,g=b.length;f<g;f++)b[f]._details&&gb(b[f])}))};F("row().child()",function(a,c){var b=this.context;if(a===k)return b.length&&this.length?b[0].aoData[this[0]]._details:k;!0===a?this.child.show():!1===a?gb(this):b.length&&this.length&&
Yb(b[0],b[0].aoData[this[0]],a,c);return this});F(["row().child.show()","row().child().show()"],function(a){Pb(this,!0);return this});F(["row().child.hide()","row().child().hide()"],function(){Pb(this,!1);return this});F(["row().child.remove()","row().child().remove()"],function(){gb(this);return this});F("row().child.isShown()",function(){var a=this.context;return a.length&&this.length?a[0].aoData[this[0]]._detailsShow||!1:!1});var $b=/^(.+):(name|visIdx|visible)$/,ac=function(a,b,e){var f=a.aoColumns,
g=aa(f,"sName"),h=aa(f,"nTh");return db(b,function(b){var e=Kb(b);if(""===b)return qa(f.length);if(null!==e)return[0<=e?e:f.length+e];var l="string"===typeof b?b.match($b):"";if(l)switch(l[2]){case "visIdx":case "visible":return b=parseInt(l[1],10),0>b?(e=c.map(f,function(a,d){return a.bVisible?d:null}),[e[e.length+b]]):[u(a,b)];case "name":return c.map(g,function(a,d){return a===l[1]?d:null})}else return c(h).filter(b).map(function(){return c.inArray(this,h)}).toArray()})};F("columns()",function(a,
b){a===k?a="":c.isPlainObject(a)&&(b=a,a="");b=eb(b);var e=this.iterator("table",function(c){return ac(c,a,b)});e.selector.cols=a;e.selector.opts=b;return e});P("columns().header()","column().header()",function(a,c){return this.iterator("column",function(a,d){return a.aoColumns[d].nTh})});P("columns().footer()","column().footer()",function(a,c){return this.iterator("column",function(a,d){return a.aoColumns[d].nTf})});P("columns().data()","column().data()",function(){return this.iterator("column-rows",
function(a,c,b,e,f){b=[];e=0;for(var g=f.length;e<g;e++)b.push(M(a,f[e],c,""));return b})});P("columns().cache()","column().cache()",function(a){return this.iterator("column-rows",function(c,b,e,f,g){return Ka(c.aoData,g,"search"===a?"_aFilterData":"_aSortData",b)})});P("columns().nodes()","column().nodes()",function(){return this.iterator("column-rows",function(a,c,b,e,f){return Ka(a.aoData,f,"anCells",c)})});P("columns().visible()","column().visible()",function(a,b){return this.iterator("column",
function(e,f){var g;if(a===k)g=e.aoColumns[f].bVisible;else{var h=e.aoColumns;g=h[f];var l=e.aoData,n,m,q;if(a===k)g=g.bVisible;else{if(g.bVisible!==a){if(a){var v=c.inArray(!0,aa(h,"bVisible"),f+1);n=0;for(m=l.length;n<m;n++)q=l[n].nTr,h=l[n].anCells,q&&q.insertBefore(h[f],h[v]||null)}else c(aa(e.aoData,"anCells",f)).detach();g.bVisible=a;ta(e,e.aoHeader);ta(e,e.aoFooter);if(b===k||b)t(e),(e.oScroll.sX||e.oScroll.sY)&&ra(e);O(e,null,"column-visibility",[e,f,a]);Ga(e)}g=void 0}}return g})});P("columns().indexes()",
"column().index()",function(a){return this.iterator("column",function(c,b){return"visible"===a?y(c,b):b})});F("columns.adjust()",function(){return this.iterator("table",function(a){t(a)})});F("column.index()",function(a,c){if(0!==this.context.length){var b=this.context[0];if("fromVisible"===a||"toData"===a)return u(b,c);if("fromData"===a||"toVisible"===a)return y(b,c)}});F("column()",function(a,c){return fb(this.columns(a,c))});var bc=function(a,b,e){var f=a.aoData,g=cb(a,e);e=Ka(f,g,"anCells");var h=
c([].concat.apply([],e)),l,n=a.aoColumns.length,m,q,t,v;return db(b,function(a){if(null===a||a===k){m=[];q=0;for(t=g.length;q<t;q++)for(l=g[q],v=0;v<n;v++)m.push({row:l,column:v});return m}return c.isPlainObject(a)?[a]:h.filter(a).map(function(a,d){l=d.parentNode._DT_RowIndex;return{row:l,column:c.inArray(d,f[l].anCells)}}).toArray()})};F("cells()",function(a,b,e){c.isPlainObject(a)&&(typeof a.row!==k?(e=b,b=null):(e=a,a=null));c.isPlainObject(b)&&(e=b,b=null);if(null===b||b===k)return this.iterator("table",
function(c){return bc(c,a,eb(e))});var f=this.columns(b,e),g=this.rows(a,e),h,l,n,m,q,t=this.iterator("table",function(a,d){h=[];l=0;for(n=g[d].length;l<n;l++)for(m=0,q=f[d].length;m<q;m++)h.push({row:g[d][l],column:f[d][m]});return h});c.extend(t.selector,{cols:b,rows:a,opts:e});return t});P("cells().nodes()","cell().node()",function(){return this.iterator("cell",function(a,c,b){return a.aoData[c].anCells[b]})});F("cells().data()",function(){return this.iterator("cell",function(a,c,b){return M(a,
c,b)})});P("cells().cache()","cell().cache()",function(a){a="search"===a?"_aFilterData":"_aSortData";return this.iterator("cell",function(c,b,e){return c.aoData[b][a][e]})});P("cells().indexes()","cell().index()",function(){return this.iterator("cell",function(a,c,b){return{row:c,column:b,columnVisible:y(a,b)}})});F(["cells().invalidate()","cell().invalidate()"],function(a){var c=this.selector;this.rows(c.rows,c.opts).invalidate(a);return this});F("cell()",function(a,c,b){return fb(this.cells(a,c,
b))});F("cell().data()",function(a){var c=this.context,b=this[0];if(a===k)return c.length&&b.length?M(c[0],b[0].row,b[0].column):k;E(c[0],b[0].row,b[0].column,a);ya(c[0],b[0].row,"data",b[0].column);return this});F("order()",function(a,b){var e=this.context;if(a===k)return 0!==e.length?e[0].aaSorting:k;"number"===typeof a?a=[[a,b]]:c.isArray(a[0])||(a=Array.prototype.slice.call(arguments));return this.iterator("table",function(c){c.aaSorting=a.slice()})});F("order.listener()",function(a,c,b){return this.iterator("table",
function(e){Pa(e,a,c,b)})});F(["columns().order()","column().order()"],function(a){var b=this;return this.iterator("table",function(e,f){var g=[];c.each(b[f],function(c,b){g.push([b,a])});e.aaSorting=g})});F("search()",function(a,b,e,f){var g=this.context;return a===k?0!==g.length?g[0].oPreviousSearch.sSearch:k:this.iterator("table",function(g){g.oFeatures.bFilter&&ua(g,c.extend({},g.oPreviousSearch,{sSearch:a+"",bRegex:null===b?!1:b,bSmart:null===e?!0:e,bCaseInsensitive:null===f?!0:f}),1)})});P("columns().search()",
"column().search()",function(a,b,e,f){return this.iterator("column",function(g,h){var l=g.aoPreSearchCols;if(a===k)return l[h].sSearch;g.oFeatures.bFilter&&(c.extend(l[h],{sSearch:a+"",bRegex:null===b?!1:b,bSmart:null===e?!0:e,bCaseInsensitive:null===f?!0:f}),ua(g,g.oPreviousSearch,1))})});F("state()",function(){return this.context.length?this.context[0].oSavedState:null});F("state.clear()",function(){return this.iterator("table",function(a){a.fnStateSaveCallback.call(a.oInstance,a,{})})});F("state.loaded()",
function(){return this.context.length?this.context[0].oLoadedState:null});F("state.save()",function(){return this.iterator("table",function(a){Ga(a)})});B.versionCheck=B.fnVersionCheck=function(a){var c=B.version.split(".");a=a.split(".");for(var b,e,f=0,g=a.length;f<g;f++)if(b=parseInt(c[f],10)||0,e=parseInt(a[f],10)||0,b!==e)return b>e;return!0};B.isDataTable=B.fnIsDataTable=function(a){var b=c(a).get(0),e=!1;c.each(B.settings,function(a,d){if(d.nTable===b||d.nScrollHead===b||d.nScrollFoot===b)e=
!0});return e};B.tables=B.fnTables=function(a){return jQuery.map(B.settings,function(b){if(!a||a&&c(b.nTable).is(":visible"))return b.nTable})};B.camelToHungarian=h;F("$()",function(a,b){var e=this.rows(b).nodes(),e=c(e);return c([].concat(e.filter(a).toArray(),e.find(a).toArray()))});c.each(["on","one","off"],function(a,b){F(b+"()",function(){var a=Array.prototype.slice.call(arguments);a[0].match(/\.dt\b/)||(a[0]+=".dt");var d=c(this.tables().nodes());d[b].apply(d,a);return this})});F("clear()",
function(){return this.iterator("table",function(a){xa(a)})});F("settings()",function(){return new L(this.context,this.context)});F("data()",function(){return this.iterator("table",function(a){return aa(a.aoData,"_aData")}).flatten()});F("destroy()",function(d){d=d||!1;return this.iterator("table",function(b){var e=b.nTableWrapper.parentNode,f=b.oClasses,g=b.nTable,h=b.nTBody,l=b.nTHead,n=b.nTFoot,m=c(g),h=c(h),k=c(b.nTableWrapper),q=c.map(b.aoData,function(a){return a.nTr}),t;b.bDestroying=!0;O(b,
"aoDestroyCallback","destroy",[b]);d||(new L(b)).columns().visible(!0);k.unbind(".DT").find(":not(tbody *)").unbind(".DT");c(a).unbind(".DT-"+b.sInstance);g!=l.parentNode&&(m.children("thead").detach(),m.append(l));n&&g!=n.parentNode&&(m.children("tfoot").detach(),m.append(n));m.detach();k.detach();b.aaSorting=[];b.aaSortingFixed=[];Fa(b);c(q).removeClass(b.asStripeClasses.join(" "));c("th, td",l).removeClass(f.sSortable+" "+f.sSortableAsc+" "+f.sSortableDesc+" "+f.sSortableNone);b.bJUI&&(c("th span."+
f.sSortIcon+", td span."+f.sSortIcon,l).detach(),c("th, td",l).each(function(){var a=c("div."+f.sSortJUIWrapper,this);c(this).append(a.contents());a.detach()}));!d&&e&&e.insertBefore(g,b.nTableReinsertBefore);h.children().detach();h.append(q);m.css("width",b.sDestroyWidth).removeClass(f.sTable);(t=b.asDestroyStripes.length)&&h.children().each(function(a){c(this).addClass(b.asDestroyStripes[a%t])});e=c.inArray(b,B.settings);-1!==e&&B.settings.splice(e,1)})});B.version="1.10.2";B.settings=[];B.models=
{};B.models.oSearch={bCaseInsensitive:!0,sSearch:"",bRegex:!1,bSmart:!0};B.models.oRow={nTr:null,anCells:null,_aData:[],_aSortData:null,_aFilterData:null,_sFilterRow:null,_sRowStripe:"",src:null};B.models.oColumn={idx:null,aDataSort:null,asSorting:null,bSearchable:null,bSortable:null,bVisible:null,_sManualType:null,_bAttrSrc:!1,fnCreatedCell:null,fnGetData:null,fnSetData:null,mData:null,mRender:null,nTh:null,nTf:null,sClass:null,sContentPadding:null,sDefaultContent:null,sName:null,sSortDataType:"std",
sSortingClass:null,sSortingClassJUI:null,sTitle:null,sType:null,sWidth:null,sWidthOrig:null};B.defaults={aaData:null,aaSorting:[[0,"asc"]],aaSortingFixed:[],ajax:null,aLengthMenu:[10,25,50,100],aoColumns:null,aoColumnDefs:null,aoSearchCols:[],asStripeClasses:null,bAutoWidth:!0,bDeferRender:!1,bDestroy:!1,bFilter:!0,bInfo:!0,bJQueryUI:!1,bLengthChange:!0,bPaginate:!0,bProcessing:!1,bRetrieve:!1,bScrollCollapse:!1,bServerSide:!1,bSort:!0,bSortMulti:!0,bSortCellsTop:!1,bSortClasses:!0,bStateSave:!1,
fnCreatedRow:null,fnDrawCallback:null,fnFooterCallback:null,fnFormatNumber:function(a){return a.toString().replace(/\B(?=(\d{3})+(?!\d))/g,this.oLanguage.sThousands)},fnHeaderCallback:null,fnInfoCallback:null,fnInitComplete:null,fnPreDrawCallback:null,fnRowCallback:null,fnServerData:null,fnServerParams:null,fnStateLoadCallback:function(a){try{return JSON.parse((-1===a.iStateDuration?sessionStorage:localStorage).getItem("DataTables_"+a.sInstance+"_"+location.pathname))}catch(c){}},fnStateLoadParams:null,
fnStateLoaded:null,fnStateSaveCallback:function(a,c){try{(-1===a.iStateDuration?sessionStorage:localStorage).setItem("DataTables_"+a.sInstance+"_"+location.pathname,JSON.stringify(c))}catch(b){}},fnStateSaveParams:null,iStateDuration:7200,iDeferLoading:null,iDisplayLength:10,iDisplayStart:0,iTabIndex:0,oClasses:{},oLanguage:{oAria:{sSortAscending:": activate to sort column ascending",sSortDescending:": activate to sort column descending"},oPaginate:{sFirst:"First",sLast:"Last",sNext:"Next",sPrevious:"Previous"},
sEmptyTable:"No data available in table",sInfo:"Showing _START_ to _END_ of _TOTAL_ entries",sInfoEmpty:"Showing 0 to 0 of 0 entries",sInfoFiltered:"(filtered from _MAX_ total entries)",sInfoPostFix:"",sDecimal:"",sThousands:",",sLengthMenu:"Show _MENU_ entries",sLoadingRecords:"Loading...",sProcessing:"Processing...",sSearch:"Search:",sSearchPlaceholder:"",sUrl:"",sZeroRecords:"No matching records found"},oSearch:c.extend({},B.models.oSearch),sAjaxDataProp:"data",sAjaxSource:null,sDom:"lfrtip",sPaginationType:"simple_numbers",
sScrollX:"",sScrollXInner:"",sScrollY:"",sServerMethod:"GET",renderer:null};b(B.defaults);B.defaults.column={aDataSort:null,iDataSort:-1,asSorting:["asc","desc"],bSearchable:!0,bSortable:!0,bVisible:!0,fnCreatedCell:null,mData:null,mRender:null,sCellType:"td",sClass:"",sContentPadding:"",sDefaultContent:null,sName:"",sSortDataType:"std",sTitle:null,sType:null,sWidth:null};b(B.defaults.column);B.models.oSettings={oFeatures:{bAutoWidth:null,bDeferRender:null,bFilter:null,bInfo:null,bLengthChange:null,
bPaginate:null,bProcessing:null,bServerSide:null,bSort:null,bSortMulti:null,bSortClasses:null,bStateSave:null},oScroll:{bCollapse:null,iBarWidth:0,sX:null,sXInner:null,sY:null},oLanguage:{fnInfoCallback:null},oBrowser:{bScrollOversize:!1,bScrollbarLeft:!1},ajax:null,aanFeatures:[],aoData:[],aiDisplay:[],aiDisplayMaster:[],aoColumns:[],aoHeader:[],aoFooter:[],oPreviousSearch:{},aoPreSearchCols:[],aaSorting:null,aaSortingFixed:[],asStripeClasses:null,asDestroyStripes:[],sDestroyWidth:0,aoRowCallback:[],
aoHeaderCallback:[],aoFooterCallback:[],aoDrawCallback:[],aoRowCreatedCallback:[],aoPreDrawCallback:[],aoInitComplete:[],aoStateSaveParams:[],aoStateLoadParams:[],aoStateLoaded:[],sTableId:"",nTable:null,nTHead:null,nTFoot:null,nTBody:null,nTableWrapper:null,bDeferLoading:!1,bInitialised:!1,aoOpenRows:[],sDom:null,sPaginationType:"two_button",iStateDuration:0,aoStateSave:[],aoStateLoad:[],oSavedState:null,oLoadedState:null,sAjaxSource:null,sAjaxDataProp:null,bAjaxDataGet:!0,jqXHR:null,json:k,oAjaxData:k,
fnServerData:null,aoServerParams:[],sServerMethod:null,fnFormatNumber:null,aLengthMenu:null,iDraw:0,bDrawing:!1,iDrawError:-1,_iDisplayLength:10,_iDisplayStart:0,_iRecordsTotal:0,_iRecordsDisplay:0,bJUI:null,oClasses:{},bFiltered:!1,bSorted:!1,bSortCellsTop:null,oInit:null,aoDestroyCallback:[],fnRecordsTotal:function(){return"ssp"==X(this)?1*this._iRecordsTotal:this.aiDisplayMaster.length},fnRecordsDisplay:function(){return"ssp"==X(this)?1*this._iRecordsDisplay:this.aiDisplay.length},fnDisplayEnd:function(){var a=
this._iDisplayLength,c=this._iDisplayStart,b=c+a,e=this.aiDisplay.length,f=this.oFeatures,g=f.bPaginate;return f.bServerSide?!1===g||-1===a?c+e:Math.min(c+a,this._iRecordsDisplay):!g||b>e||-1===a?e:b},oInstance:null,sInstance:null,iTabIndex:0,nScrollHead:null,nScrollFoot:null,aLastSort:[],oPlugins:{}};B.ext=T={classes:{},errMode:"alert",feature:[],search:[],internal:{},legacy:{ajax:null},pager:{},renderer:{pageButton:{},header:{}},order:{},type:{detect:[],search:{},order:{}},_unique:0,fnVersionCheck:B.fnVersionCheck,
iApiIndex:0,oJUIClasses:{},sVersion:B.version};c.extend(T,{afnFiltering:T.search,aTypes:T.type.detect,ofnSearch:T.type.search,oSort:T.type.order,afnSortData:T.order,aoFeatures:T.feature,oApi:T.internal,oStdClasses:T.classes,oPagination:T.pager});c.extend(B.ext.classes,{sTable:"dataTable",sNoFooter:"no-footer",sPageButton:"paginate_button",sPageButtonActive:"current",sPageButtonDisabled:"disabled",sStripeOdd:"odd",sStripeEven:"even",sRowEmpty:"dataTables_empty",sWrapper:"dataTables_wrapper",sFilter:"dataTables_filter",
sInfo:"dataTables_info",sPaging:"dataTables_paginate paging_",sLength:"dataTables_length",sProcessing:"dataTables_processing",sSortAsc:"sorting_asc",sSortDesc:"sorting_desc",sSortable:"sorting",sSortableAsc:"sorting_asc_disabled",sSortableDesc:"sorting_desc_disabled",sSortableNone:"sorting_disabled",sSortColumn:"sorting_",sFilterInput:"",sLengthSelect:"",sScrollWrapper:"dataTables_scroll",sScrollHead:"dataTables_scrollHead",sScrollHeadInner:"dataTables_scrollHeadInner",sScrollBody:"dataTables_scrollBody",
sScrollFoot:"dataTables_scrollFoot",sScrollFootInner:"dataTables_scrollFootInner",sHeaderTH:"",sFooterTH:"",sSortJUIAsc:"",sSortJUIDesc:"",sSortJUI:"",sSortJUIAscAllowed:"",sSortJUIDescAllowed:"",sSortJUIWrapper:"",sSortIcon:"",sJUIHeader:"",sJUIFooter:""});(function(){var a="",a="",b=a+"ui-state-default",e=a+"css_right ui-icon ui-icon-",a=a+"fg-toolbar ui-toolbar ui-widget-header ui-helper-clearfix";c.extend(B.ext.oJUIClasses,B.ext.classes,{sPageButton:"fg-button ui-button "+b,sPageButtonActive:"ui-state-disabled",
sPageButtonDisabled:"ui-state-disabled",sPaging:"dataTables_paginate fg-buttonset ui-buttonset fg-buttonset-multi ui-buttonset-multi paging_",sSortAsc:b+" sorting_asc",sSortDesc:b+" sorting_desc",sSortable:b+" sorting",sSortableAsc:b+" sorting_asc_disabled",sSortableDesc:b+" sorting_desc_disabled",sSortableNone:b+" sorting_disabled",sSortJUIAsc:e+"triangle-1-n",sSortJUIDesc:e+"triangle-1-s",sSortJUI:e+"carat-2-n-s",sSortJUIAscAllowed:e+"carat-1-n",sSortJUIDescAllowed:e+"carat-1-s",sSortJUIWrapper:"DataTables_sort_wrapper",
sSortIcon:"DataTables_sort_icon",sScrollHead:"dataTables_scrollHead "+b,sScrollFoot:"dataTables_scrollFoot "+b,sHeaderTH:b,sFooterTH:b,sJUIHeader:a+" ui-corner-tl ui-corner-tr",sJUIFooter:a+" ui-corner-bl ui-corner-br"})})();var Hb=B.ext.pager;c.extend(Hb,{simple:function(a,c){return["previous","next"]},full:function(a,c){return["first","previous","next","last"]},simple_numbers:function(a,c){return["previous",Za(a,c),"next"]},full_numbers:function(a,c){return["first","previous",Za(a,c),"next","last"]},
_numbers:Za,numbers_length:7});c.extend(!0,B.ext.renderer,{pageButton:{_:function(a,b,e,f,g,h){var l=a.oClasses,n=a.oLanguage.oPaginate,m,k,q=0,t=function(b,f){var v,u,x,E,I=function(c){Wa(a,c.data.action,!0)};v=0;for(u=f.length;v<u;v++)if(E=f[v],c.isArray(E))x=c("<"+(E.DT_el||"div")+"/>").appendTo(b),t(x,E);else{k=m="";switch(E){case "ellipsis":b.append("<span>&hellip;</span>");break;case "first":m=n.sFirst;k=E+(0<g?"":" "+l.sPageButtonDisabled);break;case "previous":m=n.sPrevious;k=E+(0<g?"":" "+
l.sPageButtonDisabled);break;case "next":m=n.sNext;k=E+(g<h-1?"":" "+l.sPageButtonDisabled);break;case "last":m=n.sLast;k=E+(g<h-1?"":" "+l.sPageButtonDisabled);break;default:m=E+1,k=g===E?l.sPageButtonActive:""}m&&(x=c("<a>",{"class":l.sPageButton+" "+k,"aria-controls":a.sTableId,"data-dt-idx":q,tabindex:a.iTabIndex,id:0===e&&"string"===typeof E?a.sTableId+"_"+E:null}).html(m).appendTo(b),Ya(x,{action:E},I),q++)}};try{var v=c(C.activeElement).data("dt-idx");t(c(b).empty(),f);null!==v&&c(b).find("[data-dt-idx="+
v+"]").focus()}catch(u){}}}});var Ia=function(a,c,b,e){if(!a||"-"===a)return-Infinity;c&&(a=Lb(a,c));a.replace&&(b&&(a=a.replace(b,"")),e&&(a=a.replace(e,"")));return 1*a};c.extend(T.type.order,{"date-pre":function(a){return Date.parse(a)||0},"html-pre":function(a){return da(a)?"":a.replace?a.replace(/<.*?>/g,"").toLowerCase():a+""},"string-pre":function(a){return da(a)?"":"string"===typeof a?a.toLowerCase():a.toString?a.toString():""},"string-asc":function(a,c){return a<c?-1:a>c?1:0},"string-desc":function(a,
c){return a<c?1:a>c?-1:0}});hb("");c.extend(B.ext.type.detect,[function(a,c){var b=c.oLanguage.sDecimal;return bb(a,b)?"num"+b:null},function(a,c){if(a&&(!Tb.test(a)||!Ub.test(a)))return null;var b=Date.parse(a);return null!==b&&!isNaN(b)||da(a)?"date":null},function(a,c){var b=c.oLanguage.sDecimal;return bb(a,b,!0)?"num-fmt"+b:null},function(a,c){var b=c.oLanguage.sDecimal;return Mb(a,b)?"html-num"+b:null},function(a,c){var b=c.oLanguage.sDecimal;return Mb(a,b,!0)?"html-num-fmt"+b:null},function(a,
c){return da(a)||"string"===typeof a&&-1!==a.indexOf("<")?"html":null}]);c.extend(B.ext.type.search,{html:function(a){return da(a)?a:"string"===typeof a?a.replace(Jb," ").replace(Ja,""):""},string:function(a){return da(a)?a:"string"===typeof a?a.replace(Jb," "):a}});c.extend(!0,B.ext.renderer,{header:{_:function(a,b,e,f){c(a.nTable).on("order.dt.DT",function(c,g,h,l){a===g&&(c=e.idx,b.removeClass(e.sSortingClass+" "+f.sSortAsc+" "+f.sSortDesc).addClass("asc"==l[c]?f.sSortAsc:"desc"==l[c]?f.sSortDesc:
e.sSortingClass))})},jqueryui:function(a,b,e,f){var g=e.idx;c("<div/>").addClass(f.sSortJUIWrapper).append(b.contents()).append(c("<span/>").addClass(f.sSortIcon+" "+e.sSortingClassJUI)).appendTo(b);c(a.nTable).on("order.dt.DT",function(c,h,l,n){a===h&&(b.removeClass(f.sSortAsc+" "+f.sSortDesc).addClass("asc"==n[g]?f.sSortAsc:"desc"==n[g]?f.sSortDesc:e.sSortingClass),b.find("span."+f.sSortIcon).removeClass(f.sSortJUIAsc+" "+f.sSortJUIDesc+" "+f.sSortJUI+" "+f.sSortJUIAscAllowed+" "+f.sSortJUIDescAllowed).addClass("asc"==
n[g]?f.sSortJUIAsc:"desc"==n[g]?f.sSortJUIDesc:e.sSortingClassJUI))})}}});B.render={number:function(a,c,b,e){return{display:function(f){var g=0>f?"-":"";f=Math.abs(parseFloat(f));var h=parseInt(f,10);f=b?c+(f-h).toFixed(b).substring(2):"";return g+(e||"")+h.toString().replace(/\B(?=(\d{3})+(?!\d))/g,a)+f}}}};c.extend(B.ext.internal,{_fnExternApiFunc:Ib,_fnBuildAjax:ia,_fnAjaxUpdate:za,_fnAjaxParameters:Aa,_fnAjaxUpdateDraw:Ba,_fnAjaxDataSrc:ja,_fnAddColumn:q,_fnColumnOptions:l,_fnAdjustColumnSizing:t,
_fnVisibleToColumnIndex:u,_fnColumnIndexToVisible:y,_fnVisbleColumns:z,_fnGetColumns:v,_fnColumnTypes:I,_fnApplyColumnDefs:K,_fnHungarianMap:b,_fnCamelToHungarian:h,_fnLanguageCompat:m,_fnBrowserDetect:n,_fnAddData:H,_fnAddTr:A,_fnNodeToDataIndex:function(a,c){return c._DT_RowIndex!==k?c._DT_RowIndex:null},_fnNodeToColumnIndex:function(a,b,e){return c.inArray(e,a.aoData[b].anCells)},_fnGetCellData:M,_fnSetCellData:E,_fnSplitObjNotation:ea,_fnGetObjectDataFn:W,_fnSetObjectDataFn:La,_fnGetDataMaster:S,
_fnClearTable:xa,_fnDeleteIndex:Q,_fnInvalidateRow:ya,_fnGetRowElements:wa,_fnCreateTr:ka,_fnBuildHead:na,_fnDrawHead:ta,_fnDraw:fa,_fnReDraw:ha,_fnAddOptionsHtml:va,_fnDetectHeader:N,_fnGetUniqueThs:oa,_fnFeatureHtmlFilter:lb,_fnFilterComplete:ua,_fnFilterCustom:sb,_fnFilterColumn:rb,_fnFilter:qb,_fnFilterCreateSearch:Sa,_fnEscapeRegex:Ta,_fnFilterData:tb,_fnFeatureHtmlInfo:ob,_fnUpdateInfo:wb,_fnInfoMacros:xb,_fnInitialise:Ea,_fnInitComplete:Ca,_fnLengthChange:Ua,_fnFeatureHtmlLength:kb,_fnFeatureHtmlPaginate:pb,
_fnPageChange:Wa,_fnFeatureHtmlProcessing:mb,_fnProcessingDisplay:Y,_fnFeatureHtmlTable:nb,_fnScrollDraw:ra,_fnApplyToChildren:ca,_fnCalculateColumnWidths:Ma,_fnThrottle:Ra,_fnConvertToWidth:yb,_fnScrollingWidthAdjust:Ab,_fnGetWidestNode:zb,_fnGetMaxLenString:Bb,_fnStringToCss:J,_fnScrollBarWidth:Cb,_fnSortFlatten:pa,_fnSort:jb,_fnSortAria:Eb,_fnSortListener:Xa,_fnSortAttachListener:Pa,_fnSortingClasses:Fa,_fnSortData:Db,_fnSaveState:Ga,_fnLoadState:Fb,_fnSettingsFromNode:Ha,_fnLog:la,_fnMap:ba,_fnBindAction:Ya,
_fnCallbackReg:U,_fnCallbackFire:O,_fnLengthOverflow:Va,_fnRenderer:Qa,_fnDataSource:X,_fnRowAttributes:Na,_fnCalculateEnd:function(){}});c.fn.dataTable=B;c.fn.dataTableSettings=B.settings;c.fn.dataTableExt=B.ext;c.fn.DataTable=function(a){return c(this).dataTable(a).api()};c.each(B,function(a,b){c.fn.DataTable[a]=b});return c.fn.dataTable})})(window,document);
function naturalSort(a,C){var k=/(^-?[0-9]+(\.?[0-9]*)[df]?e?[0-9]?$|^0x[0-9a-f]+$|[0-9]+)/gi,c=/(^[ ]*|[ ]*$)/g,b=/(^([\w ]+,?[\w ]+)?[\w ]+,?[\w ]+\d+:\d+(:\d+)?[\w ]?|^\d{1,4}[\/\-]\d{1,4}[\/\-]\d{1,4}|^\w+, \w+ \d+, \d{4})/,h=/^0x[0-9a-f]+$/i,m=/^0/,e=function(a){return naturalSort.insensitive&&(""+a).toLowerCase()||""+a},f=e(a).replace(c,"")||"",e=e(C).replace(c,"")||"",c=f.replace(k,"\x00$1\x00").replace(/\0$/,"").replace(/^\0/,"").split("\x00"),k=e.replace(k,"\x00$1\x00").replace(/\0$/,"").replace(/^\0/,
"").split("\x00"),f=parseInt(f.match(h))||1!=c.length&&f.match(b)&&Date.parse(f);if(b=parseInt(e.match(h))||f&&e.match(b)&&Date.parse(e)||null){if(f<b)return-1;if(f>b)return 1}f=0;for(e=Math.max(c.length,k.length);f<e;f++){b=!(c[f]||"").match(m)&&parseFloat(c[f])||c[f]||0;h=!(k[f]||"").match(m)&&parseFloat(k[f])||k[f]||0;if(isNaN(b)!==isNaN(h))return isNaN(b)?1:-1;typeof b!==typeof h&&(b+="",h+="");if(b<h)return-1;if(b>h)return 1}return 0}
jQuery.fn.dataTableExt.oSort["string-asc"]=function(a,C){return naturalSort(a,C)};jQuery.fn.dataTableExt.oSort["string-desc"]=function(a,C){return-1*naturalSort(a,C)};
(function(a){"function"===typeof define&&define.amd?define(["jquery"],a):a("undefined"!=typeof jQuery?jQuery:window.Zepto)})(function(a){function C(c){var b=c.data;c.isDefaultPrevented()||(c.preventDefault(),a(c.target).ajaxSubmit(b))}function k(c){var b=c.target,h=a(b);if(!h.is("[type=submit],[type=image]")){b=h.closest("[type=submit]");if(0===b.length)return;b=b[0]}var g=this;g.clk=b;"image"==b.type&&(void 0!==c.offsetX?(g.clk_x=c.offsetX,g.clk_y=c.offsetY):"function"==typeof a.fn.offset?(h=h.offset(),
g.clk_x=c.pageX-h.left,g.clk_y=c.pageY-h.top):(g.clk_x=c.pageX-b.offsetLeft,g.clk_y=c.pageY-b.offsetTop));setTimeout(function(){g.clk=g.clk_x=g.clk_y=null},100)}function c(){if(a.fn.ajaxSubmit.debug){var c="[jquery.form] "+Array.prototype.join.call(arguments,"");window.console&&window.console.log?window.console.log(c):window.opera&&window.opera.postError&&window.opera.postError(c)}}var b,h;b=void 0!==a("<input type='file'/>").get(0).files;h=void 0!==window.FormData;var m=!!a.fn.prop;a.fn.attr2=function(){if(!m)return this.attr.apply(this,
arguments);var a=this.prop.apply(this,arguments);return a&&a.jquery||"string"===typeof a?a:this.attr.apply(this,arguments)};a.fn.ajaxSubmit=function(e){function f(c){c=a.param(c,e.traditional).split("&");var b=c.length,f=[],g,h;for(g=0;g<b;g++)c[g]=c[g].replace(/\+/g," "),h=c[g].split("="),f.push([decodeURIComponent(h[0]),decodeURIComponent(h[1])]);return f}function n(c){for(var b=new FormData,g=0;g<c.length;g++)b.append(c[g].name,c[g].value);if(e.extraData)for(c=f(e.extraData),g=0;g<c.length;g++)c[g]&&
b.append(c[g][0],c[g][1]);e.data=null;g=a.extend(!0,{},a.ajaxSettings,e,{contentType:!1,processData:!1,cache:!1,type:k||"POST"});e.uploadProgress&&(g.xhr=function(){var c=a.ajaxSettings.xhr();c.upload&&c.upload.addEventListener("progress",function(a){var c=0,b=a.loaded||a.position,f=a.total;a.lengthComputable&&(c=Math.ceil(b/f*100));e.uploadProgress(a,b,f,c)},!1);return c});g.data=null;var h=g.beforeSend;g.beforeSend=function(a,c){c.data=e.formData?e.formData:b;h&&h.call(this,a,c)};return a.ajax(g)}
function g(b){function f(a){var b=null;try{a.contentWindow&&(b=a.contentWindow.document)}catch(e){c("cannot get iframe.contentWindow document: "+e)}if(b)return b;try{b=a.contentDocument?a.contentDocument:a.document}catch(g){c("cannot get iframe.contentDocument: "+g),b=a.document}return b}function g(){function b(){try{var a=f(K).readyState;c("state = "+a);a&&"uninitialized"==a.toLowerCase()&&setTimeout(b,50)}catch(e){c("Server abort: ",e," (",e.name,")"),h(2),M&&clearTimeout(M),M=void 0}}var e=t.attr2("target"),
n=t.attr2("action"),m=t.attr("enctype")||t.attr("encoding")||"multipart/form-data";l.setAttribute("target",I);k&&!/post/i.test(k)||l.setAttribute("method","POST");n!=v.url&&l.setAttribute("action",v.url);v.skipEncodingOverride||k&&!/post/i.test(k)||t.attr({encoding:"multipart/form-data",enctype:"multipart/form-data"});v.timeout&&(M=setTimeout(function(){z=!0;h(1)},v.timeout));var u=[];try{if(v.extraData)for(var A in v.extraData)v.extraData.hasOwnProperty(A)&&(a.isPlainObject(v.extraData[A])&&v.extraData[A].hasOwnProperty("name")&&
v.extraData[A].hasOwnProperty("value")?u.push(a('<input type="hidden" name="'+v.extraData[A].name+'">').val(v.extraData[A].value).appendTo(l)[0]):u.push(a('<input type="hidden" name="'+A+'">').val(v.extraData[A]).appendTo(l)[0]));v.iframeTarget||H.appendTo("body");K.attachEvent?K.attachEvent("onload",h):K.addEventListener("load",h,!1);setTimeout(b,15);try{l.submit()}catch(E){document.createElement("form").submit.apply(l)}}finally{l.setAttribute("action",n),l.setAttribute("enctype",m),e?l.setAttribute("target",
e):t.removeAttr("target"),a(u).remove()}}function h(b){if(!A.aborted&&!ia)if(N=f(K),N||(c("cannot access response document"),b=2),1===b&&A)A.abort("timeout"),C.reject(A,"timeout");else if(2==b&&A)A.abort("server abort"),C.reject(A,"error","server abort");else if(N&&N.location.href!=v.iframeSrc||z){K.detachEvent?K.detachEvent("onload",h):K.removeEventListener("load",h,!1);b="success";var e;try{if(z)throw"timeout";var g="xml"==v.dataType||N.XMLDocument||a.isXMLDoc(N);c("isXml="+g);if(!g&&window.opera&&
(null===N.body||!N.body.innerHTML)&&--oa){c("requeing onLoad callback, DOM not available");setTimeout(h,250);return}var l=N.body?N.body:N.documentElement;A.responseText=l?l.innerHTML:null;A.responseXML=N.XMLDocument?N.XMLDocument:N;g&&(v.dataType="xml");A.getResponseHeader=function(a){return{"content-type":v.dataType}[a.toLowerCase()]};l&&(A.status=Number(l.getAttribute("status"))||A.status,A.statusText=l.getAttribute("statusText")||A.statusText);var n=(v.dataType||"").toLowerCase(),m=/(json|script|text)/.test(n);
if(m||v.textarea){var k=N.getElementsByTagName("textarea")[0];if(k)A.responseText=k.value,A.status=Number(k.getAttribute("status"))||A.status,A.statusText=k.getAttribute("statusText")||A.statusText;else if(m){var q=N.getElementsByTagName("pre")[0],t=N.getElementsByTagName("body")[0];q?A.responseText=q.textContent?q.textContent:q.innerText:t&&(A.responseText=t.textContent?t.textContent:t.innerText)}}else"xml"==n&&!A.responseXML&&A.responseText&&(A.responseXML=za(A.responseText));try{va=Ba(A,n,v)}catch(I){b=
"parsererror",A.error=e=I||b}}catch(E){c("error caught: ",E),b="error",A.error=e=E||b}A.aborted&&(c("upload aborted"),b=null);A.status&&(b=200<=A.status&&300>A.status||304===A.status?"success":"error");"success"===b?(v.success&&v.success.call(v.context,va,"success",A),C.resolve(A.responseText,"success",A),u&&a.event.trigger("ajaxSuccess",[A,v])):b&&(void 0===e&&(e=A.statusText),v.error&&v.error.call(v.context,A,b,e),C.reject(A,"error",e),u&&a.event.trigger("ajaxError",[A,v,e]));u&&a.event.trigger("ajaxComplete",
[A,v]);u&&!--a.active&&a.event.trigger("ajaxStop");v.complete&&v.complete.call(v.context,A,b);ia=!0;v.timeout&&clearTimeout(M);setTimeout(function(){v.iframeTarget?H.attr("src",v.iframeSrc):H.remove();A.responseXML=null},100)}}var l=t[0],n,v,u,I,H,K,A,z,M,C=a.Deferred();C.abort=function(a){A.abort(a)};if(b)for(n=0;n<y.length;n++)b=a(y[n]),m?b.prop("disabled",!1):b.removeAttr("disabled");v=a.extend(!0,{},a.ajaxSettings,e);v.context=v.context||v;I="jqFormIO"+(new Date).getTime();v.iframeTarget?(H=a(v.iframeTarget),
(n=H.attr2("name"))?I=n:H.attr2("name",I)):(H=a('<iframe name="'+I+'" src="'+v.iframeSrc+'" />'),H.css({position:"absolute",top:"-1000px",left:"-1000px"}));K=H[0];A={aborted:0,responseText:null,responseXML:null,status:0,statusText:"n/a",getAllResponseHeaders:function(){},getResponseHeader:function(){},setRequestHeader:function(){},abort:function(b){var e="timeout"===b?"timeout":"aborted";c("aborting upload... "+e);this.aborted=1;try{K.contentWindow.document.execCommand&&K.contentWindow.document.execCommand("Stop")}catch(f){}H.attr("src",
v.iframeSrc);A.error=e;v.error&&v.error.call(v.context,A,e,b);u&&a.event.trigger("ajaxError",[A,v,e]);v.complete&&v.complete.call(v.context,A,e)}};(u=v.global)&&0===a.active++&&a.event.trigger("ajaxStart");u&&a.event.trigger("ajaxSend",[A,v]);if(v.beforeSend&&!1===v.beforeSend.call(v.context,A,v))return v.global&&a.active--,C.reject(),C;if(A.aborted)return C.reject(),C;(b=l.clk)&&(n=b.name)&&!b.disabled&&(v.extraData=v.extraData||{},v.extraData[n]=b.value,"image"==b.type&&(v.extraData[n+".x"]=l.clk_x,
v.extraData[n+".y"]=l.clk_y));b=a("meta[name=csrf-token]").attr("content");(n=a("meta[name=csrf-param]").attr("content"))&&b&&(v.extraData=v.extraData||{},v.extraData[n]=b);v.forceSync?g():setTimeout(g,10);var va,N,oa=50,ia,za=a.parseXML||function(a,c){window.ActiveXObject?(c=new ActiveXObject("Microsoft.XMLDOM"),c.async="false",c.loadXML(a)):c=(new DOMParser).parseFromString(a,"text/xml");return c&&c.documentElement&&"parsererror"!=c.documentElement.nodeName?c:null},Aa=a.parseJSON||function(a){return window.eval("("+
a+")")},Ba=function(c,b,e){var f=c.getResponseHeader("content-type")||"",g="xml"===b||!b&&0<=f.indexOf("xml");c=g?c.responseXML:c.responseText;g&&"parsererror"===c.documentElement.nodeName&&a.error&&a.error("parsererror");e&&e.dataFilter&&(c=e.dataFilter(c,b));"string"===typeof c&&("json"===b||!b&&0<=f.indexOf("json")?c=Aa(c):("script"===b||!b&&0<=f.indexOf("javascript"))&&a.globalEval(c));return c};return C}if(!this.length)return c("ajaxSubmit: skipping submit process - no element selected"),this;
var k,l,t=this;"function"==typeof e?e={success:e}:void 0===e&&(e={});k=e.type||this.attr2("method");l=e.url||this.attr2("action");(l=(l="string"===typeof l?a.trim(l):"")||window.location.href||"")&&(l=(l.match(/^([^#]+)/)||[])[1]);e=a.extend(!0,{url:l,success:a.ajaxSettings.success,type:k||a.ajaxSettings.type,iframeSrc:/^https/i.test(window.location.href||"")?"javascript:false":"about:blank"},e);l={};this.trigger("form-pre-serialize",[this,e,l]);if(l.veto)return c("ajaxSubmit: submit vetoed via form-pre-serialize trigger"),
this;if(e.beforeSerialize&&!1===e.beforeSerialize(this,e))return c("ajaxSubmit: submit aborted via beforeSerialize callback"),this;var u=e.traditional;void 0===u&&(u=a.ajaxSettings.traditional);var y=[],z,v=this.formToArray(e.semantic,y);e.data&&(e.extraData=e.data,z=a.param(e.data,u));if(e.beforeSubmit&&!1===e.beforeSubmit(v,this,e))return c("ajaxSubmit: submit aborted via beforeSubmit callback"),this;this.trigger("form-submit-validate",[v,this,e,l]);if(l.veto)return c("ajaxSubmit: submit vetoed via form-submit-validate trigger"),
this;l=a.param(v,u);z&&(l=l?l+"&"+z:z);"GET"==e.type.toUpperCase()?(e.url+=(0<=e.url.indexOf("?")?"&":"?")+l,e.data=null):e.data=l;var I=[];e.resetForm&&I.push(function(){t.resetForm()});e.clearForm&&I.push(function(){t.clearForm(e.includeHidden)});if(!e.dataType&&e.target){var K=e.success||function(){};I.push(function(c){var b=e.replaceTarget?"replaceWith":"html";a(e.target)[b](c).each(K,arguments)})}else e.success&&I.push(e.success);e.success=function(a,c,b){for(var f=e.context||this,g=0,h=I.length;g<
h;g++)I[g].apply(f,[a,c,b||t,t])};if(e.error){var H=e.error;e.error=function(a,c,b){H.apply(e.context||this,[a,c,b,t])}}if(e.complete){var A=e.complete;e.complete=function(a,c){A.apply(e.context||this,[a,c,t])}}z=0<a("input[type=file]:enabled",this).filter(function(){return""!==a(this).val()}).length;l="multipart/form-data"==t.attr("enctype")||"multipart/form-data"==t.attr("encoding");u=b&&h;c("fileAPI :"+u);var M;!1!==e.iframe&&(e.iframe||(z||l)&&!u)?e.closeKeepAlive?a.get(e.closeKeepAlive,function(){M=
g(v)}):M=g(v):M=(z||l)&&u?n(v):a.ajax(e);t.removeData("jqxhr").data("jqxhr",M);for(z=0;z<y.length;z++)y[z]=null;this.trigger("form-submit-notify",[this,e]);return this};a.fn.ajaxForm=function(b){b=b||{};b.delegation=b.delegation&&a.isFunction(a.fn.on);if(!b.delegation&&0===this.length){var f=this.selector,h=this.context;if(!a.isReady&&f)return c("DOM not ready, queuing ajaxForm"),a(function(){a(f,h).ajaxForm(b)}),this;c("terminating; zero elements found by selector"+(a.isReady?"":" (DOM not ready)"));
return this}return b.delegation?(a(document).off("submit.form-plugin",this.selector,C).off("click.form-plugin",this.selector,k).on("submit.form-plugin",this.selector,b,C).on("click.form-plugin",this.selector,b,k),this):this.ajaxFormUnbind().bind("submit.form-plugin",b,C).bind("click.form-plugin",b,k)};a.fn.ajaxFormUnbind=function(){return this.unbind("submit.form-plugin click.form-plugin")};a.fn.formToArray=function(c,f){var h=[];if(0===this.length)return h;var g=this[0],m=this.attr("id"),l=c?g.getElementsByTagName("*"):
g.elements;l&&!/MSIE [678]/.test(navigator.userAgent)&&(l=a(l).get());m&&(m=a(':input[form="'+m+'"]').get(),m.length&&(l=(l||[]).concat(m)));if(!l||!l.length)return h;var k,u,y,z,v;k=0;for(v=l.length;k<v;k++)if(z=l[k],(m=z.name)&&!z.disabled)if(c&&g.clk&&"image"==z.type)g.clk==z&&(h.push({name:m,value:a(z).val(),type:z.type}),h.push({name:m+".x",value:g.clk_x},{name:m+".y",value:g.clk_y}));else if((y=a.fieldValue(z,!0))&&y.constructor==Array)for(f&&f.push(z),u=0,z=y.length;u<z;u++)h.push({name:m,
value:y[u]});else if(b&&"file"==z.type)if(f&&f.push(z),y=z.files,y.length)for(u=0;u<y.length;u++)h.push({name:m,value:y[u],type:z.type});else h.push({name:m,value:"",type:z.type});else null!==y&&"undefined"!=typeof y&&(f&&f.push(z),h.push({name:m,value:y,type:z.type,required:z.required}));!c&&g.clk&&(l=a(g.clk),k=l[0],(m=k.name)&&!k.disabled&&"image"==k.type&&(h.push({name:m,value:l.val()}),h.push({name:m+".x",value:g.clk_x},{name:m+".y",value:g.clk_y})));return h};a.fn.formSerialize=function(c){return a.param(this.formToArray(c))};
a.fn.fieldSerialize=function(c){var b=[];this.each(function(){var h=this.name;if(h){var g=a.fieldValue(this,c);if(g&&g.constructor==Array)for(var m=0,l=g.length;m<l;m++)b.push({name:h,value:g[m]});else null!==g&&"undefined"!=typeof g&&b.push({name:this.name,value:g})}});return a.param(b)};a.fn.fieldValue=function(c){for(var b=[],h=0,g=this.length;h<g;h++){var m=a.fieldValue(this[h],c);null===m||"undefined"==typeof m||m.constructor==Array&&!m.length||(m.constructor==Array?a.merge(b,m):b.push(m))}return b};
a.fieldValue=function(c,b){var h=c.name,g=c.type,m=c.tagName.toLowerCase();void 0===b&&(b=!0);if(b&&(!h||c.disabled||"reset"==g||"button"==g||("checkbox"==g||"radio"==g)&&!c.checked||("submit"==g||"image"==g)&&c.form&&c.form.clk!=c||"select"==m&&-1==c.selectedIndex))return null;if("select"==m){var l=c.selectedIndex;if(0>l)return null;for(var h=[],m=c.options,k=(g="select-one"==g)?l+1:m.length,l=g?l:0;l<k;l++){var u=m[l];if(u.selected){var y=u.value;y||(y=u.attributes&&u.attributes.value&&!u.attributes.value.specified?
u.text:u.value);if(g)return y;h.push(y)}}return h}return a(c).val()};a.fn.clearForm=function(c){return this.each(function(){a("input,select,textarea",this).clearFields(c)})};a.fn.clearFields=a.fn.clearInputs=function(c){var b=/^(?:color|date|datetime|email|month|number|password|range|search|tel|text|time|url|week)$/i;return this.each(function(){var h=this.type,g=this.tagName.toLowerCase();b.test(h)||"textarea"==g?this.value="":"checkbox"==h||"radio"==h?this.checked=!1:"select"==g?this.selectedIndex=
-1:"file"==h?/MSIE/.test(navigator.userAgent)?a(this).replaceWith(a(this).clone(!0)):a(this).val(""):c&&(!0===c&&/hidden/.test(h)||"string"==typeof c&&a(this).is(c))&&(this.value="")})};a.fn.resetForm=function(){return this.each(function(){("function"==typeof this.reset||"object"==typeof this.reset&&!this.reset.nodeType)&&this.reset()})};a.fn.enable=function(a){void 0===a&&(a=!0);return this.each(function(){this.disabled=!a})};a.fn.selected=function(c){void 0===c&&(c=!0);return this.each(function(){var b=
this.type;"checkbox"==b||"radio"==b?this.checked=c:"option"==this.tagName.toLowerCase()&&(b=a(this).parent("select"),c&&b[0]&&"select-one"==b[0].type&&b.find("option").selected(!1),this.selected=c)})};a.fn.ajaxSubmit.debug=!1});
(function(a){a._i18n={trans:{},"default":"en",language:"en"};a.i18n=function(){if(2>arguments.length)return a._i18n.language=arguments[0],a._i18n.language;if("string"==typeof arguments[1]){var C;C=arguments[0];var k=arguments[1],c=!1;a._i18n.trans[a._i18n.language]&&a._i18n.trans[a._i18n.language][C]&&a._i18n.trans[a._i18n.language][C][k]?c=a._i18n.trans[a._i18n.language][C][k]:a._i18n.trans[a._i18n["default"]]&&a._i18n.trans[a._i18n["default"]][C]&&a._i18n.trans[a._i18n["default"]][C][k]&&(c=a._i18n.trans[a._i18n["default"]][C][k]);
C=c||k;return arguments[2]&&"object"==typeof arguments[2]?a.format(C,arguments[2]):C}k=arguments[0].split(".");C=k[0];k=k[1]||"jQuery";a._i18n.trans[C]||(a._i18n.trans[C]={});a._i18n.trans[C][k]?a.extend(a._i18n.trans[C][k],arguments[1]):a._i18n.trans[C][k]=arguments[1]}})(jQuery);
new function(a){var C=a.separator||"&",k=!1===a.spaces?!1:!0,c=!1!==a.prefix?!0===a.hash?"#":"?":"",b=!1===a.numbers?!1:!0;jQuery.query=new function(){var a=function(a,c){return void 0!=a&&null!==a&&(c?a.constructor==c:!0)},m=function(a){for(var c=/\[([^[]*)\]/g,b=/^([^[]+)(\[.*\])?$/.exec(a),e=b[1],f=[];a=c.exec(b[2]);)f.push(a[1]);return[e,f]},e=function(c,b,f){var l=b.shift();"object"!=typeof c&&(c=null);if(""===l)if(c||(c=[]),a(c,Array))c.push(0==b.length?f:e(null,b.slice(0),f));else if(a(c,Object)){for(l=
0;null!=c[l++];);c[--l]=0==b.length?f:e(c[l],b.slice(0),f)}else c=[],c.push(0==b.length?f:e(null,b.slice(0),f));else if(l&&l.match(/^\s*[0-9]+\s*$/)){var m=parseInt(l,10);c||(c=[]);c[m]=0==b.length?f:e(c[m],b.slice(0),f)}else if(l){m=l.replace(/^\s*|\s*$/g,"");c||(c={});if(a(c,Array)){for(var k={},l=0;l<c.length;++l)k[l]=c[l];c=k}c[m]=0==b.length?f:e(c[m],b.slice(0),f)}else return f;return c},f=function(a){var c=this;c.keys={};a.queryObject?jQuery.each(a.get(),function(a,b){c.SET(a,b)}):jQuery.each(arguments,
function(){var a;a=(""+this).replace(/^[?#]/,"");a=a.replace(/[;&]$/,"");k&&(a=a.replace(/[+]/g," "));jQuery.each(a.split(/[&;]/),function(){var a=decodeURIComponent(this.split("=")[0]||""),e=decodeURIComponent(this.split("=")[1]||"");a&&(b&&(/^[+-]?[0-9]+\.[0-9]*$/.test(e)?e=parseFloat(e):/^[+-]?[0-9]+$/.test(e)&&(e=parseInt(e,10))),c.SET(a,e||0===e?e:!0))})});return c};f.prototype={queryObject:!0,has:function(c,b){var e=this.get(c);return a(e,b)},GET:function(c){if(!a(c))return this.keys;var b=
m(c);c=b[1];for(b=this.keys[b[0]];null!=b&&0!=c.length;)b=b[c.shift()];return"number"==typeof b?b:b||""},get:function(c){c=this.GET(c);return a(c,Object)?jQuery.extend(!0,{},c):a(c,Array)?c.slice(0):c},SET:function(c,b){if($.isPlainObject(c)){var f=this;$.each(c,function(a,c){"undefined"!==typeof c?f.SET(a,c):f.REMOVE(a)});return this}var l=a(b)?b:null,k=m(c),u=k[0];this.keys[u]=e(this.keys[u],k[1].slice(0),l);return this},set:function(a,c){return this.copy().SET(a,c)},REMOVE:function(a){return this.SET(a,
null).COMPACT()},remove:function(a){return this.copy().REMOVE(a)},EMPTY:function(){var a=this;jQuery.each(a.keys,function(c,b){delete a.keys[c]});return a},load:function(a){var c=a.replace(/^.*?[#](.+?)(?:\?.+)?$/,"$1"),b=a.replace(/^.*?[?](.+?)(?:#.+)?$/,"$1");return new f(a.length==b.length?"":b,a.length==c.length?"":c)},empty:function(){return this.copy().EMPTY()},copy:function(){return new f(this)},COMPACT:function(){function c(b){var e="object"==typeof b?a(b,Array)?[]:{}:b;"object"==typeof b&&
jQuery.each(b,function(b,f){if(!a(f))return!0;var g=c(f);a(e,Array)?e.push(g):e[b]=g});return e}this.keys=c(this.keys);return this},compact:function(){return this.copy().COMPACT()},toString:function(){var b=[],e=[],f=function(a){a+="";k&&(a=a.replace(/%20/g,"+"));return encodeURIComponent(a)},l=function(c,b){var m=function(a){return b&&""!=b?[b,"[",a,"]"].join(""):""+a};jQuery.each(c,function(c,b){if("object"==typeof b)l(b,m(c));else{var k=m(c);a(b)&&!1!==b&&(k=[f(k)],!0!==b&&(k.push("="),k.push(f(b))),
e.push(k.join("")))}})};l(this.keys);0<e.length&&b.push(c);b.push(e.join(C));return b.join("")}};return new f(location.search,location.hash)}}(jQuery.query||{});
(function(a){var C=function(){var k=function(){var c=/iPhone|iPad|iPod/i.test(navigator.userAgent);c&&a(window).load(function(){a("body").children().on("click",a.noop)});return c}(),c=function(){var a=document.documentElement.style;return"behavior"in a&&"fill"in a&&/iemobile/i.test(navigator.userAgent)}(),b=function(a,c){var b="sf-js-enabled";c.cssArrows&&(b+=" sf-arrows");a.toggleClass(b)},h=function(c,b){return c.find("li."+b.pathClass).slice(0,b.pathLevels).addClass(b.hoverClass+" sf-breadcrumb").filter(function(){return a(this).children(b.popUpSelector).hide().show().length}).removeClass(b.pathClass)},
m=function(a){var c=a.css("ms-touch-action");a.css("ms-touch-action","pan-y"===c?"auto":"pan-y")},e=function(c){var b=a(this),e=b.siblings(c.data.popUpSelector);0<e.length&&e.is(":hidden")&&(b.one("click.superfish",!1),"MSPointerDown"===c.type?b.trigger("focus"):a.proxy(f,b.parent("li"))())},f=function(){var c=a(this),b=q(c);clearTimeout(b.sfTimer);c.siblings().superfish("hide").end().superfish("show")},n=function(){var c=a(this),b=q(c);k?a.proxy(g,c,b)():(clearTimeout(b.sfTimer),b.sfTimer=setTimeout(a.proxy(g,
c,b),b.delay))},g=function(c){c.retainPath=-1<a.inArray(this[0],c.$path);this.superfish("hide");this.parents("."+c.hoverClass).length||(c.onIdle.call(this.closest(".sf-js-enabled")),c.$path.length&&a.proxy(f,c.$path)())},q=function(a){return a.closest(".sf-js-enabled").data("sf-options")};return{hide:function(c){if(this.length){var b=q(this);if(!b)return this;var e=!0===b.retainPath?b.$path:"",e=this.find("li."+b.hoverClass).add(this).not(e).removeClass(b.hoverClass).children(b.popUpSelector),f=b.speedOut;
c&&(e.show(),f=0);b.retainPath=!1;b.onBeforeHide.call(e);e.stop(!0,!0).animate(b.animationOut,f,function(){var c=a(this);b.onHide.call(c)})}return this},show:function(){var a=q(this);if(!a)return this;var c=this.addClass(a.hoverClass).children(a.popUpSelector);a.onBeforeShow.call(c);c.stop(!0,!0).animate(a.animation,a.speed,function(){a.onShow.call(c)});return this},destroy:function(){return this.each(function(){var c=a(this),e=c.data("sf-options"),f;if(!e)return!1;f=c.find(e.popUpSelector).parent("li");
clearTimeout(e.sfTimer);b(c,e);f.children("a").toggleClass("sf-with-ul");m(c);c.off(".superfish").off(".hoverIntent");f.children(e.popUpSelector).attr("style",function(a,c){return c.replace(/display[^;]+;?/g,"")});e.$path.removeClass(e.hoverClass+" sf-breadcrumb").addClass(e.pathClass);c.find("."+e.hoverClass).removeClass(e.hoverClass);e.onDestroy.call(c);c.removeData("sf-options")})},init:function(g){return this.each(function(){var q=a(this);if(q.data("sf-options"))return!1;var u=a.extend({},a.fn.superfish.defaults,
g),y=q.find(u.popUpSelector).parent("li");u.$path=h(q,u);q.data("sf-options",u);b(q,u);y.children("a").toggleClass("sf-with-ul");m(q);var z="li:has("+u.popUpSelector+")";if(a.fn.hoverIntent&&!u.disableHI)q.hoverIntent(f,n,z);else q.on("mouseenter.superfish",z,f).on("mouseleave.superfish",z,n);z="MSPointerDown.superfish";k||(z+=" touchend.superfish");c&&(z+=" mousedown.superfish");q.on("focusin.superfish","li",f).on("focusout.superfish","li",n).on(z,"a",u,e);y.not(".sf-breadcrumb").superfish("hide",
!0);u.onInit.call(this)})}}}();a.fn.superfish=function(k,c){return C[k]?C[k].apply(this,Array.prototype.slice.call(arguments,1)):"object"!==typeof k&&k?a.error("Method "+k+" does not exist on jQuery.fn.superfish"):C.init.apply(this,arguments)};a.fn.superfish.defaults={popUpSelector:"ul,.sf-mega",hoverClass:"sfHover",pathClass:"overrideThisToUse",pathLevels:1,delay:800,animation:{opacity:"show"},animationOut:{opacity:"hide"},speed:"normal",speedOut:"fast",cssArrows:!0,disableHI:!1,onInit:a.noop,onBeforeShow:a.noop,
onShow:a.noop,onBeforeHide:a.noop,onHide:a.noop,onIdle:a.noop,onDestroy:a.noop};a.fn.extend({hideSuperfishUl:C.hide,showSuperfishUl:C.show})})(jQuery);
(function(a,C,k){function c(c,h,m){var e=c.scrollTop;if(c.setSelectionRange){var f=c.selectionStart,n=c.selectionEnd;if(f==n)h?f-m.tabString==c.value.substring(f-m.tabString.length,f)?(c.value=c.value.substring(0,f-m.tabString.length)+c.value.substring(f),c.focus(),c.setSelectionRange(f-m.tabString.length,f-m.tabString.length)):f-m.tabString==c.value.substring(f,f+m.tabString.length)&&(c.value=c.value.substring(0,f)+c.value.substring(f+m.tabString.length),c.focus(),c.setSelectionRange(f,f)):(c.value=
c.value.substring(0,f)+m.tabString+c.value.substring(f),c.focus(),c.setSelectionRange(f+m.tabString.length,f+m.tabString.length));else{for(;f<c.value.length&&c.value.charAt(f).match(/[ \t]/);)f++;var g=c.value.split("\n"),q=[],l=0,t=0,u;for(u in g)t=l+g[u].length,q.push({start:l,end:t,selected:l<=f&&t>f||t>=n&&l<n||l>f&&t<n}),l=t+1;g=0;for(u in q)q[u].selected&&(l=q[u].start+g,h&&m.tabString==c.value.substring(l,l+m.tabString.length)?(c.value=c.value.substring(0,l)+c.value.substring(l+m.tabString.length),
g-=m.tabString.length):h||(c.value=c.value.substring(0,l)+m.tabString+c.value.substring(l),g+=m.tabString.length));c.focus();c.setSelectionRange(f+(0<g?m.tabString.length:0>g?-m.tabString.length:0),n+g)}}else if(k.selection&&(f=k.selection.createRange(),c==f.parentElement()))if(""==f.text)h?(h=f.getBookmark(),f.moveStart("character",-m.tabString.length),m.tabString==f.text?f.text="":(f.moveToBookmark(h),f.moveEnd("character",m.tabString.length),m.tabString==f.text&&(f.text="")),f.collapse(!0)):(f.text=
m.tabString,f.collapse(!1)),f.select();else{q=f.text;n=q.length;u=q.split("\r\n");q=k.body.createTextRange();q.moveToElementText(c);q.setEndPoint("EndToStart",f);l=q.text;g=l.split("\r\n");l=l.length;t=k.body.createTextRange();t.moveToElementText(c);t.setEndPoint("StartToEnd",f);var t=t.text,y=k.body.createTextRange();y.moveToElementText(c);y.setEndPoint("StartToEnd",q);var z=y.text,y=a(c).html();a("#r3").text(l+" + "+n+" + "+t.length+" = "+y.length);l+z.length<y.length?(g.push(""),l+=2,h&&m.tabString==
u[0].substring(0,m.tabString.length)?u[0]=u[0].substring(m.tabString.length):h||(u[0]=m.tabString+u[0])):h&&m.tabString==g[g.length-1].substring(0,m.tabString.length)?g[g.length-1]=g[g.length-1].substring(m.tabString.length):h||(g[g.length-1]=m.tabString+g[g.length-1]);for(z=1;z<u.length;z++)h&&m.tabString==u[z].substring(0,m.tabString.length)?u[z]=u[z].substring(m.tabString.length):h||(u[z]=m.tabString+u[z]);1==g.length&&0==l&&(h&&m.tabString==u[0].substring(0,m.tabString.length)?u[0]=u[0].substring(m.tabString.length):
h||(u[0]=m.tabString+u[0]));l+n+t.length<y.length&&u.push("");q.text=g.join("\r\n");f.text=u.join("\r\n");m=k.body.createTextRange();m.moveToElementText(c);0<l?m.setEndPoint("StartToEnd",q):m.setEndPoint("StartToStart",q);m.setEndPoint("EndToEnd",f);m.select()}c.scrollTop=e}a.fn.tabby=function(b){var h=a.extend({},a.fn.tabby.defaults,b),m=a.fn.tabby.pressed;return this.each(function(){$this=a(this);var b=a.meta?a.extend({},h,$this.data()):h;$this.bind("keydown",function(f){var h=a.fn.tabby.catch_kc(f);
16==h&&(m.shft=!0);17==h&&(m.ctrl=!0,setTimeout(function(){a.fn.tabby.pressed.ctrl=!1},1E3));18==h&&(m.alt=!0,setTimeout(function(){a.fn.tabby.pressed.alt=!1},1E3));if(9==h&&!m.ctrl&&!m.alt)return f.preventDefault,m.last=h,setTimeout(function(){a.fn.tabby.pressed.last=null},0),c(a(f.target).get(0),m.shft,b),!1}).bind("keyup",function(c){16==a.fn.tabby.catch_kc(c)&&(m.shft=!1)}).bind("blur",function(c){9==m.last&&a(c.target).one("focus",function(a){m.last=null}).get(0).focus()})})};a.fn.tabby.catch_kc=
function(a){return a.keyCode?a.keyCode:a.charCode?a.charCode:a.which};a.fn.tabby.pressed={shft:!1,ctrl:!1,alt:!1,last:null};a.fn.tabby.defaults={tabString:String.fromCharCode(9)}})(jQuery,this,this.document);
(function(a,C,k){a.widget("ui.rlightbox",{options:{animationSpeed:"fast",setPrefix:"lb",showMap:!0,counterDelimiter:" / ",videoWidth:640,videoHeight:385,errorMessage:"Oh dear! Something went wrong! If the problem still appears let the page\u2019s admin know. Would you like to try again or reject the content?",againButtonLabel:"Try again",rejectButtonLabel:"Reject this content",overwriteTitle:!1,keys:{next:[78,39],previous:[80,37],close:[67,27],panorama:[90,null]},loop:!1},_create:function(){var c,
b=a.ui.rlightbox.global,h=this;b.getLightbox();c=b.extractAnchor(this);c.type!==k&&(b.addToSet(c),this.element.click(function(a){b.open(h);a.preventDefault()}))},_setOption:function(a,b){}});a.extend(a.ui.rlightbox,{global:{addToSet:function(c){var b=this.getSetName(c.self),h=a.ui.rlightbox.global.sets,m=a("."+c.self.options.setPrefix+"_"+b).index(c.element);h[b]?h[b].splice(m,0,c):(h[b]=[],h[b].push(c))},checkButtonsState:function(){var a=this.data,b=this.$lightbox,h=a.totalElementsNumber,m=a.currentElementNumber,
e=a.currentSetElement.self.options.loop;"single"===a.currentSet||1===h?this.setButtonState("disabled"):1===m&&!1===e?(this.setButtonState("disabled",b.prev),this.setButtonState("default",b.next)):m===h&&!1===e?(this.setButtonState("disabled",b.next),this.setButtonState("default",b.prev)):this.setButtonState("default")},checkMinimalSize:function(a,b){var h=this.data.minimalLightboxSize,m=h.width,h=h.height;if("width"===a)return b<m?m:b;if("height"===a)return b<h?h:b},closeLightbox:function(){var c=
this.data,b=this.$lightbox;c.ready&&(b.overlay.add(b.root).add(b.header).hide(),a("body").css("overflow","visible"),b.content.empty().width(20).height(20),this.hideArrow(),this.setButtonState("default"),this.panoramaHideIcon(),c.currentElementNumber=null,c.totalElementsNumber=null,b.title.empty(),this.panoramaHideMap(),c.ready=!1)},createStructure:function(){var c=this.data;a(c.htmlLightbox).appendTo("body").after(c.htmlMap).after(c.htmlOverlay)},destroy:function(){this.data.currentSetElement.element.unbind(".rlightbox").unbind("click").removeData("rlightbox")},
extractAnchor:function(c){var b={type:k},h=a(c.element),m=h.attr("href");a.each({youtube:{urls:[/(http:\/\/www\.youtube\.com\/watch\?v=([\w-_]+))&?/],type:"youtube"},image:{urls:[/.jpg$|.png$|.gif$/i],type:"image"},vimeo:{urls:[/(http:\/\/vimeo\.com\/groups\/\w+\/videos\/(\w+))&?/,/(http:\/\/vimeo\.com\/(\w+))&?/],type:"vimeo"},flash:{urls:[/.swf/i],type:"flash"}},function(e,f){var k=!1;a.each(f.urls,function(a,e){var l=e.exec(m);if(null!==l){b={url:l[1],id:l[2],type:f.type,element:h,self:c};if("image"===
f.type||"flash"===f.type||c.options.overwriteTitle)b.title=h.attr("title"),b.url=m;k=!0;return!1}});if(k)return!1});return b},getAvailableScreenSize:function(){var a=this.data,b=a.lightboxPadding;return{width:this.getWindowSize("width")-b,height:this.getWindowSize("height")-a.headerHeight-b}},getCurrentElementNumber:function(c){var b;a.each(this.sets[this.data.currentSet],function(h,m){if(a(c).get(0)===m.element.get(0))return b=h+1,!1});return b},getImageStatus:function(a,b){var h=this.data,m=this.getWindowSize("width"),
e=this.getWindowSize("height"),f=h.minimalLightboxSize.width,k=h.minimalLightboxSize.height,g=h.lightboxPadding,h=h.headerHeight;return{statusWidth:a<=f?-1:a>f&&a+g<=m?1:2,statusHeight:b<=k?-1:b>k&&e>=b+g+h?1:2}},getLightbox:function(){var c=this.data,b=this.$lightbox,h=this;b.root||(this.createStructure(),this.setReferences(),b.close.add(b.overlay).click(a.proxy(this.closeLightbox,this)),b.next.click(a.proxy(this.next,this)),b.prev.click(a.proxy(this.prev,this)),b.next.add(b.prev).add(b.next).add(b.close).hover(function(){a(this).is(":not(.ui-state-disabled)")&&
h.setButtonState("highlight",a(this))},function(){a(this).is(":not(.ui-state-disabled)")&&h.setButtonState("default",a(this))}),b.contentContainer.mousemove(a.proxy(this.showArrow,this)).mousemove(a.proxy(this.checkSide,this)).mousemove(a.proxy(this.setCursor,this)).click(function(){"left"===c.side?h.prev.apply(h):"right"===c.side&&h.next.apply(h)}).mousedown(a.proxy(this.panoramaStart,this)).mouseup(a.proxy(this.panoramaStop,this)).mouseleave(function(){h.hideArrow.apply(h);c.side=""}),b.panoramaIcon.click(a.proxy(this.panoramaToggle,
this)).hover(a.proxy(this.panoramaHighlight,this)),a(C).bind("resize.rlightbox",a.proxy(this.liveResize,this)),a(document).keyup(a.proxy(this.handleKeyboard,this)))},getOptimalSize:function(a,b){var h=this.data.minimalLightboxSize,m=h.width,h=h.height,e=this.getAvailableScreenSize(),f=e.width,e=e.height;if("width"===a)return b<m?m:b>f?f:b;if("height"===a)return b<h?h:b>e?e:b},getParam:function(a,b){var h;h=(new RegExp("[\\?&]"+a+"=(\\w+)")).exec(b);return null!==h?h[1]:null},getSetName:function(c){var b=
a(c.element).attr("class");return(c=(new RegExp(c.options.setPrefix+"_([\\w-_]+)")).exec(b))?c[1]:"single"},checkSide:function(a){var b=this.data,h=this.$lightbox.contentContainer,m=a.pageX-h.offset().left,h=Math.round(h.width()/2);m<=h?b.side="left":m>h&&(b.side="right");a.preventDefault()},getSizes:function(){function a(t,E){b=u.getImageStatus(t,E);h=b.statusWidth;m=b.statusHeight;if(!(1!==h&&-1!==h||2===m||1!==m&&-1!==m||2===h))1===h?k=t:-1===h&&(k=I),e=t,1===m?g=E:-1===m&&(g=K),f=E;else if(2===
h||2===m)1===h||-1===h?(f=g=v-A-H,q=g/E,-1===h?(k=I,e=Math.ceil(t*q)):(e=k=Math.ceil(t*q)-H,e<=I&&a(e,f))):1===m||-1===m?(e=k=z-H,l=k/t,-1===m?(g=K,f=Math.ceil(E*l)):(f=g=Math.ceil(E*l)-A-H,f<=K&&a(e,f))):t>E?(e=k=z-H,l=k/t,f=g=Math.ceil(E*l)-H-A,(f<=K||g+H+A>v)&&a(e,f)):(f=g=v-A-H,q=g/E,e=k=Math.ceil(t*q)-H,(e<=I||k>z)&&a(e,f))}var b,h,m,e,f,k,g,q,l,t=this.data,u=this,y=t.currentSetElement,z=this.getWindowSize("width"),v=this.getWindowSize("height"),I=t.minimalLightboxSize.width,K=t.minimalLightboxSize.height,
H=t.lightboxPadding,A=t.headerHeight;a(y.width,y.height);return{imageTargetWidth:e,imageTargetHeight:f,lightboxTargetWidth:k,lightboxTargetHeight:g,statusWidth:h,statusHeight:m}},getWindowSize:function(c){var b=this.data,h=a(C).width(),m=a(C).height(),e=b.minimalLightboxSize,f=b.lightboxPadding,k=e.width+f,b=e.height+f+b.headerHeight;return"width"===c?h<k?k:h:m<b?b:m},handleKeyboard:function(a){var b=this.data,h=b.currentSetElement;if("undefined"!==typeof h.self){var m=(typeof h.self.options?[]:h.self.options).keys,
e=a.which;!1!==b.ready&&(e===m.next[0]||e===m.next[1]?this.next():e===m.previous[0]||e===m.previous[1]?this.prev():e===m.close[0]||e===m.close[1]?this.closeLightbox():e!==m.panorama[0]&&e!==m.panorama[1]||"image"!==h.type||this.panoramaToggle(a))}},hideArrow:function(){this.$lightbox.arrow.hide()},liveResize:function(){var a=this.data,b=a.currentSetElement.type;a.ready&&!1===a.panoramaOn&&"image"===b?(this.queueResizeLightbox(),this.updateTitleWidth(),this.queueCenterContent(),this.panoramaCheckAvailability()):
a.ready&&a.panoramaOn&&"image"===b?(this.queueCenterLightbox(),this.panoramaShrink(),this.panoramaCheckAvailability()):a.ready&&"image"!==b&&this.queueCenterLightbox()},loadContentFlash:function(c){var b,h,m,e=this.data,f=this,k=this.$lightbox.content,g=a.Deferred(),q=e.htmlFlash,l=e.currentSetElement,t=l.self.options;k.addClass("ui-lightbox-loader");setTimeout(function(){b=f.getParam("width",c);h=f.getParam("height",c);if(null===b||isNaN(b))b=t.videoWidth;if(null===h||isNaN(h))h=t.videoHeight;l.width=
b;l.height=h;q=f.replaceHtmlPatterns(q,{width:b,height:h,url:c});m=a("<div></div>");m.css({display:"none",width:b,height:h});k.removeClass("ui-lightbox-loader").empty().append(q).children().wrap(m);g.resolve()},1E3);return g.promise()},loadContentImage:function(c){var b=this.$lightbox,h=this,m=this.data.currentSetElement,e=a.Deferred(),f=a("<img />");b.content.addClass("ui-lightbox-loader");f.attr("src",c).bind("load",function(){a(this).unbind("load");m.width=this.width;m.height=this.height;b.content.removeClass("ui-lightbox-loader").empty().append(this).children().hide();
e.resolve()}).error(function(){b.content.removeClass("ui-lightbox-loader");h.showErrorMessage();e.resolve()}).each(function(){if(this.complete||this.complete===k){var a=this.src;this.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw==";this.src=a}});return e.promise()},loadContentVimeo:function(c){var b=this.data,h=this.$lightbox,m=this,e=a.Deferred(),f=b.providers.vimeo,k=b.currentSetElement,g=k.self.options;h.content.addClass("ui-lightbox-loader");a.ajax({url:f,data:{url:c,
maxwidth:g.videoWidth,maxheight:g.videoHeight},dataType:"jsonp",timeout:5E3}).success(function(a){h.content.removeClass("ui-lightbox-loader").empty().append(a.html).children().wrap("<div style='display: none'></div>").end().find("div:first").width(a.width).height(a.height);!1===g.overwriteTitle&&(k.title=a.title);k.width=a.width;k.height=a.height;e.resolve()}).error(function(){h.content.removeClass("ui-lightbox-loader");m.showErrorMessage();e.resolve()});return e.promise()},loadContentYoutube:function(c){function b(){m.content.removeClass("ui-lightbox-loader");
f.showErrorMessage();k.resolve()}var h;c=this.data;var m=this.$lightbox,e=m.content,f=this,k=a.Deferred(),g=c.providers.youtube,q=c.currentSetElement,l=q.self.options,t=l.videoWidth,u=l.videoHeight,y=c.htmlYoutube;m.content.addClass("ui-lightbox-loader");a.ajax({url:g+q.id+"?callback=?",data:{v:2,alt:"jsonc",prettyprint:!0},dataType:"jsonp",timeout:5E3}).success(function(c){c.error?b():(y=f.replaceHtmlPatterns(y,{width:t,height:u,url:q.id}),h=a("<div></div>"),h.css({display:"none",width:t,height:u}),
e.removeClass("ui-lightbox-loader").empty().append(y).children().wrap(h),!1===l.overwriteTitle&&(q.title=c.data.title),q.width=t,q.height=u,k.resolve())}).error(function(){b()});return k.promise()},navigationGoToElement:function(a){var b=this.data,h=this.sets,m=this.$lightbox,e=b.currentSet;b.currentElementNumber=a;b.currentSetElement=h[e][a-1];this.setNextQueue();m.queueContainer.next.dequeue("lightboxNext")},next:function(){var a=this.data,b=this.sets,h=this.$lightbox,m=a.panoramaOn,e=a.currentSet,
f=a.currentElementNumber,k=a.totalElementsNumber,g=a.currentSetElement.self.options.loop,q=!0;a.ready&&"single"!==e&&!1===m&&(f+1<=k?a.currentElementNumber=f+=1:f+1>k&&g?a.currentElementNumber=f=1:q=!1,q&&(a.currentSetElement=b[e][f-1],this.setNextQueue(),h.queueContainer.next.dequeue("lightboxNext")))},open:function(c){var b=this.data,h=this.sets,m=this.$lightbox,e=c.element;c=this.getSetName(c);a(e).attr("href");b.currentSet=c;b.totalElementsNumber=h[c].length;b.currentElementNumber=this.getCurrentElementNumber(e);
b.currentSetElement=h[c][b.currentElementNumber-1];this.setOpenQueue();this.setNextQueue();this.checkButtonsState();m.queueContainer.open.dequeue("lightboxOpen")},panoramaCenterContent:function(){var a,b,h=this.$lightbox,m=this.data.currentSetElement;b=this.getAvailableScreenSize();a=b.width;b=b.height;var e=m.width,m=m.height,f=h.content,h=f.find("img");a=a<e?0:f.width()/2-h.width()/2;b=b<m?0:f.height()/2-h.height()/2;h.css({top:b,left:a})},panoramaCheckAvailability:function(){var a=this.data,b=
a.currentSetElement,h=b.height,m=b.currentHeight;b.currentWidth<b.width||m<h?(this.panoramaShowIcon("expand"),a.enablePanorama=!0):(a.enablePanorama=!1,this.panoramaHideIcon())},panoramaExpand:function(a){var b=this.data,h=this.$lightbox,m=b.currentSetElement,e=m.self.options;b.panoramaOn=!0;"click"===a.type?this.panoramaShowIcon("shrink","-hover"):this.panoramaShowIcon("shrink");h.content.css("overflow","hidden");h.content.find("img").width(m.width).height(m.height);this.panoramaSetContentSize();
this.panoramaCenterContent();this.queueCenterLightbox();this.updateTitleWidth();e.showMap&&this.panoramaShowMap();this.hideArrow();this.setCursor()},panoramaHideIcon:function(){var a=this.data;this.$lightbox.panoramaIcon.hide().removeClass("ui-lightbox-panorama-icon-expand ui-lightbox-panorama-icon-shrink");a.panoramaOn=!1},panoramaHideMap:function(){var a=this.$lightbox;a.map.hide();a.viewport.css({left:-1,top:-1})},panoramaHighlight:function(){var a;this.$lightbox.panoramaIcon.attr("class",function(b,
h){a=h.indexOf("-hover");return-1!==a?h.slice(0,a):h+"-hover"})},panoramaSetContentSize:function(){var a,b=this.data,h=this.$lightbox;a=b.currentSetElement;var m=b.minimalLightboxSize,b=m.width,e=m.height,f=this.getAvailableScreenSize(),m=f.width,k=f.height,f=a.width;a=a.height;a=a>k?k:a<=e?e:a;h.content.width(f>m?m:f<=b?b:f).height(a)},panoramaShowIcon:function(a,b){var h="ui-lightbox-panorama-icon-"+a+(b||"");this.$lightbox.panoramaIcon.show().removeClass().addClass(h)},panoramaShowMap:function(){var a,
b,h,m,e,f=this.data;a=f.minimalLightboxSize;var k=this.$lightbox;b=k.content;h=b.find("img");e=h.width();var g=h.height();m=f.currentSetElement;var q=f.mapSize;h=q.width/m.width;m=q.height/m.height;e=e<a.width?e:b.width();b=g<a.height?g:b.height();a=Math.ceil(e*h);b=Math.ceil(b*m);k.viewport.width(a).height(b);k.map.show();f.viewportRatio={width:h,height:m}},panoramaShrink:function(a){var b=this.$lightbox;this.data.panoramaOn=!1;a&&"click"===a.type?this.panoramaShowIcon("expand","-hover"):this.panoramaShowIcon("expand");
this.queueResizeLightbox();this.queueCenterContent();b.content.css("overflow","visible");this.updateTitleWidth();this.panoramaHideMap();this.setCursor()},panoramaStart:function(a){this.data.panoramaPosition={xStart:a.pageX,yStart:a.pageY};a.preventDefault()},panoramaStop:function(a){var b=this.data,h=this.$lightbox,k=-1*(a.pageX-b.panoramaPosition.xStart),e=-1*(a.pageY-b.panoramaPosition.yStart),f=h.content,n=b.viewportRatio;b.panoramaOn&&(f.scrollLeft(f.scrollLeft()+k).scrollTop(f.scrollTop()+e),
h.viewport.css({left:f.scrollLeft()*n.width-1,top:f.scrollTop()*n.height-1}));a.stopPropagation()},panoramaToggle:function(a){var b=this.data,h=b.panoramaOn;(b=b.enablePanorama)&&!1===h?this.panoramaExpand(a):b&&h&&this.panoramaShrink(a)},prev:function(){var a=this.data,b=this.sets,h=this.$lightbox,k=a.panoramaOn,e=a.currentSet,f=a.currentElementNumber,n=a.totalElementsNumber,g=a.currentSetElement.self.options.loop,q=!0;a.ready&&"single"!==e&&!1===k&&(1<=f-1?a.currentElementNumber=--f:1>f-1&&g?a.currentElementNumber=
f=n:q=!1,q&&(a.currentSetElement=b[e][f-1],this.setNextQueue(),h.queueContainer.next.dequeue("lightboxNext")))},removeSetElement:function(a){var b=this.data,h=this.sets,k=b.currentSet,e=b.totalElementsNumber;h[k].splice(a-1,1);1===e||"single"===k?(this.closeLightbox(),this.destroy()):(this.destroy(),b.totalElementsNumber=h[k].length,a===e?this.navigationGoToElement(a-1):this.navigationGoToElement(a))},replaceHtmlPatterns:function(c,b){a.each(b,function(a,b){c=c.replace(new RegExp("{"+a+"}","g"),b)});
return c},setButtonState:function(a,b){var h=this.$lightbox,h=b||h.controlButtons;switch(a){case "default":h.removeClass("ui-state-highlight ui-state-disabled");break;case "highlight":h.addClass("ui-state-highlight");break;case "disabled":h.addClass("ui-state-disabled")}},setCursor:function(a){var b=this.data,h=this.$lightbox.contentContainer,k=b.currentSet,e=b.currentSetElement.type,f=b.totalElementsNumber,n=b.currentElementNumber,g=b.side,q=b.panoramaOn,l=b.showErrorMessage,t=b.currentSetElement.self.options.loop;
b.ready?("single"===k||1===f||1===n&&"left"===g||n===f&&"right"===g)&&!1===q&&("image"===e||"image"!==e&&l)?!1===t?h.css("cursor","default"):h.css("cursor","pointer"):q?h.css("cursor","move"):"image"===e||"image"!==e&&l?h.css("cursor","pointer"):h.css("cursor","auto"):h.css("cursor","default");a&&a.preventDefault()},setNextQueue:function(){var c=this.$lightbox,b=[a.proxy(this.queueSlideUpHeader,this),a.proxy(this.queueHideContent,this),a.proxy(this.queueLoadContent,this),a.proxy(this.queueResizeLightbox,
this),a.proxy(this.queueCenterContent,this),a.proxy(this.queueShowContent,this),a.proxy(this.queueSlideDownHeader,this)];c.queueContainer.next.queue("lightboxNext",b)},setOpenQueue:function(){var c=this.$lightbox,b=[a.proxy(this.queueShowOverlay,this),a.proxy(this.queueCenterLightbox,this),a.proxy(this.queueLoadContent,this),a.proxy(this.queueResizeLightbox,this),a.proxy(this.queueCenterContent,this),a.proxy(this.queueShowContent,this),a.proxy(this.queueSlideDownHeader,this)];c.queueContainer.open.queue("lightboxOpen",
b)},setReferences:function(){var c=this.$lightbox;c.root=a("#ui-lightbox");c.panoramaIcon=c.root.find("#ui-lightbox-panorama-icon");c.contentContainer=c.root.find("#ui-lightbox-content-container");c.content=c.contentContainer.find("#ui-lightbox-content");c.arrow=c.contentContainer.find("#ui-lightbox-arrow");c.header=c.root.find("#ui-lightbox-bottombar");c.headerWrapper=c.header.find("#ui-lightbox-title-wrapper");c.overlay=a("#ui-lightbox-overlay");c.next=c.root.find("#ui-lightbox-button-next");c.prev=
c.root.find("#ui-lightbox-button-prev");c.controlButtons=c.next.add(c.prev);c.close=c.root.find("#ui-lightbox-button-close");c.counter=c.root.find("#ui-lightbox-counter");c.title=c.root.find("#ui-lightbox-title");c.map=a("#ui-lightbox-map");c.viewport=c.map.children().eq(0);c.queueContainer={open:a({}),next:a({})}},showArrow:function(a){var b=this.data,h=this.$lightbox.arrow,k=b.showErrorMessage,e=b.side,f=b.currentElementNumber,n=b.totalElementsNumber,g=b.currentSetElement.self.options.loop;b.ready&&
"single"!==b.currentSet&&("image"===b.currentSetElement.type||k)&&!1===b.panoramaOn&&("left"===e&&(1<f||g)?h.show().removeClass("ui-lightbox-arrow-next ui-corner-left").addClass("ui-lightbox-arrow-prev ui-corner-right").find("span").removeClass("ui-icon-carat-1-e").addClass("ui-icon-carat-1-w"):"right"===e&&(f<n||g)?h.show().removeClass("ui-lightbox-arrow-prev ui-corner-right").addClass("ui-lightbox-arrow-next ui-corner-left").find("span").removeClass("ui-icon-carat-1-w").addClass("ui-icon-carat-1-e"):
this.hideArrow());a&&a.preventDefault()},showErrorMessage:function(){var c,b,h,k=this.data,e=this.$lightbox,f=this;c=k.currentSetElement.self.options;var n=k.currentElementNumber;b=k.htmlErrorScreen;var g=k.errorScreenSize,q=g.width,g=g.height;b=f.replaceHtmlPatterns(b,{message:c.errorMessage,labelAgain:c.againButtonLabel,labelReject:c.rejectButtonLabel});h=a(b);c=h.find("#ui-lightbox-error-footer-again");b=h.find("#ui-lightbox-error-footer-reject");c.click(function(){f.navigationGoToElement(n)}).hover(function(){a(this).toggleClass("ui-state-hover")});
b.click(function(){f.removeSetElement(n)}).hover(function(){a(this).toggleClass("ui-state-hover")});e.content.empty().append(h).find("#ui-lightbox-error").width(q).height(g).end().children().hide();k.showErrorMessage=!0},updateCounter:function(){var a,b;b=this.data;var h=this.$lightbox,k=b.currentSetElement.self.options;"single"!==b.currentSet?(a=b.currentElementNumber,b=b.totalElementsNumber):b=a=1;h.counter.text(a+k.counterDelimiter+b)},updateTitle:function(){var a=this.$lightbox,b=this.data.currentSetElement;
""!==b.title?a.title.empty().append(b.title):a.title.append("&nbsp;")},updateTitleWidth:function(){var a=this.$lightbox;a.header.width(a.content.width()-12)},queueHideContent:function(c){var b=this.data,h=this.$lightbox,k=b.currentSetElement.self.options;h.content.children().fadeOut(k.animationSpeed,function(){a(this).remove();c()});h.panoramaIcon.hide().removeClass("ui-lightbox-panorama-icon-expand ui-lightbox-panorama-icon-shrink");b.panoramaOn=!1;this.panoramaHideMap()},queueShowOverlay:function(a){var b=
this.data,h=this.$lightbox,k=b.currentSetElement.self;b.ready=!1;this.setCursor();h.overlay.fadeIn(k.options.animationSpeed,a)},queueCenterLightbox:function(a){var b=this.$lightbox.root,h=this.getWindowSize("width"),k=this.getWindowSize("height"),e=b.outerWidth(),f=b.outerHeight();b.css({left:Math.round((h-e)/2)+"px",top:Math.round((k-f)/2)+"px"}).show(0,a)},queueLoadContent:function(c){var b,h=this.data,k=h.currentSetElement;h.showErrorMessage=!1;switch(k.type){case "image":b="loadContentImage";
break;case "youtube":b="loadContentYoutube";break;case "vimeo":b="loadContentVimeo";break;case "flash":b="loadContentFlash"}a.when(this[b](k.url)).then(function(){c()})},queueResizeLightbox:function(c){var b,h,k,e,f;e=this.data;var n=this.$lightbox,g=e.lightboxPadding,q=e.headerHeight,l=e.currentSetElement,t=l.self.options;k=e.showErrorMessage;b=e.errorScreenSize;e=b.width;var u=b.height;b=t.animationSpeed;"image"===l.type&&!1===k?(h=this.getSizes(),k=h.imageTargetWidth,e=h.imageTargetHeight,f=h.lightboxTargetWidth,
h=h.lightboxTargetHeight,b=n.content.find("img"),l.currentWidth=k,l.currentHeight=e,b.width(k).height(e),b=a.isFunction(c)?t.animationSpeed:0):"youtube"!==l.type&&"vimeo"!==l.type||!1!==k?"flash"===l.type&&!1===k?(f=this.getOptimalSize("width",l.width),h=this.getOptimalSize("height",l.height)):k&&(b=0,f=e,h=u):(f=this.checkMinimalSize("width",l.width),h=this.checkMinimalSize("height",l.height));n.root.find("#ui-lightbox-content").animate({width:f},b).animate({height:h},b).end().animate({left:(this.getWindowSize("width")-
f-g)/2},b).animate({top:(this.getWindowSize("height")-h-g-q)/2},b,c)},queueCenterContent:function(a){var b=this.$lightbox.content,h=b.children();b.children().css({top:b.height()/2-h.outerHeight()/2,left:b.width()/2-h.outerWidth()/2});a&&a()},queueShowContent:function(a){var b=this.data,h=this,k=b.currentSetElement,e=k.self.options,f=b.showErrorMessage;this.$lightbox.content.children().fadeIn(e.animationSpeed,function(){"image"===k.type&&!1===f&&h.panoramaCheckAvailability();a()})},queueSlideDownHeader:function(a){var b=
this.data;this.$lightbox.header.slideDown(b.currentSetElement.self.options.animationSpeed,a);this.updateCounter();this.updateTitleWidth();this.updateTitle();this.checkButtonsState();b.ready=!0;this.setCursor();this.showArrow()},queueSlideUpHeader:function(a){var b=this.data,h=this.$lightbox,k=b.currentSetElement.self.options;b.ready=!1;this.hideArrow();this.setCursor();h.header.slideUp(k.animationSpeed,a)},$lightbox:{},sets:{},data:{minimalLightboxSize:{width:300,height:300},lightboxPadding:12,headerHeight:57,
ready:!1,panoramaOn:!1,mapSize:{width:150,height:100},providers:{vimeo:"//www.vimeo.com/api/oembed.json?callback=?",youtube:"//gdata.youtube.com/feeds/api/videos/"},showErrorMessage:!1,currentSetElement:{},enablePanorama:!1,errorScreenSize:{width:500,height:500},htmlFlash:"<object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' width='{width}' height='{height}'><param name='movie' value='{url}' />\x3c!--[if !IE]>--\x3e<object type='application/x-shockwave-flash' data='{url}' width='{width}' height='{height}'>\x3c!--<![endif]--\x3e\x3c!--[if !IE]>--\x3e</object>\x3c!--<![endif]--\x3e</object>",
htmlErrorScreen:"<div id='ui-lightbox-error'><div id='ui-lightbox-error-message' class='ui-lightbox-error-icon-sign'>{message}</div><div id='ui-lightbox-error-footer'><button aria-disabled='false' role='button' id='ui-lightbox-error-footer-again' class='ui-button ui-widget ui-state-default ui-corner-all ui-button-text-icon-primary'><span class='ui-button-icon-primary ui-icon ui-icon-refresh'></span><span class='ui-button-text'>{labelAgain}</span></button><button aria-disabled='false' role='button' id='ui-lightbox-error-footer-reject' class='ui-button ui-widget ui-state-default ui-corner-all ui-button-text-icon-primary'><span class='ui-button-icon-primary ui-icon ui-icon-trash'></span><span class='ui-button-text'>{labelReject}</span></button></div></div>",
htmlYoutube:"<iframe class='youtube-player' type='text/html' width='{width}' height='{height}' src='//www.youtube.com/embed/{url}' frameborder='0'></iframe>",htmlLightbox:"<div id='ui-lightbox' class='ui-widget ui-widget-content ui-corner-all' style='display: none'><div id='ui-lightbox-panorama-icon' style='display: none'></div><div id='ui-lightbox-content-container'><div id='ui-lightbox-content' class='ui-widget-content'></div><a id='ui-lightbox-arrow' class='ui-widget-header' style='display: none'><span class='ui-icon'>go</span></a></div><div id='ui-lightbox-bottombar' class='ui-widget-header ui-corner-all' style='display: none'><p id='ui-lightbox-title-wrapper'><span id='ui-lightbox-title'></span></p><p id='ui-lightbox-bottombar-bottom'><a id='ui-lightbox-button-prev' class='ui-lightbox-button'><span class='ui-icon ui-icon-circle-arrow-w'>prev</span></a><span id='ui-lightbox-counter'></span><a id='ui-lightbox-button-next' class='ui-lightbox-button'><span class='ui-icon ui-icon-circle-arrow-e'>next</span></a></p><a id='ui-lightbox-button-close' class='ui-lightbox-button'><span class='ui-icon ui-icon-closethick'>close</span></a></div></div>",
htmlMap:"<div id='ui-lightbox-map' style='display: none'><div id='ui-lightbox-map-viewport'></div></div>",htmlOverlay:"<div id='ui-lightbox-overlay' class='ui-widget-overlay' style='display: none'></div>"}}})})(jQuery,window);var pukiwiki={},bootstrapTooltip=$.fn.tooltip.noConflict();$.fn.bstooltip=bootstrapTooltip;var bootstrapButton=$.fn.button.noConflict();$.fn.bsbutton=bootstrapButton;
(function(a,C,k,c){for(var b,h=function(){},m="assert clear count debug dir dirxml error exception group groupCollapsed groupEnd info log markTimeline profile profileEnd table time timeEnd timeStamp trace warn".split(" "),e=m.length,f=k.console=k.console||{};e--;)b=m[e],f[b]||(f[b]=h);if(DEBUG){k.console.debugMode=!0;var n=new Date}var g=function(){for(var a=3,b=c.createElement("div"),e=b.getElementsByTagName("i");b.innerHTML="\x3c!--[if gt IE "+ ++a+"]><i></i><![endif]--\x3e",e[0];);return 4<a?a:
void 0}();navigator.userAgent.match(/iphone|ipod|ipad|android/i);var q=[],l=[],t=[],u=[],y=[];if(!a)throw"pukiwiki: jQuery does not included.";if(!a.ui)throw"pukiwiki: jQueryUI does not included.";var z=a(c.body);pukiwiki={meta:{"@prefix":"<http://purl.org/net/ns/doas#>","@about":"<skin.js>",a:":JavaScript",title:"Pukiwiki skin script for jQuery",created:"2008-11-25",release:{revision:"2.5.0",created:"2013-01-22"},author:{name:"Logue",homepage:"<http://logue.be/>"},license:"<http://www.gnu.org/licenses/gpl-2.0.html>"},
custom:{},isPage:"undefined"===typeof PAGE||a.query.get("cmd")||PAGE.match(/^:|FormatRules|RecentChanges|RecentDeleted|InterWikiName|AutoAliasName|MenuBar|SideBar|Navigation|Glossary/i)?!1:!0,href:a("link[rel=canonical]")[0].href,init:function(){var b=a("meta[name=generator]")[0].content;b.match(/[PukiPlus|Advance]/)?this.image_dir=IMAGE_URI+"ajax/":b.match(/plus/)?this.image_dir=SKIN_DIR+"theme/"+THEME_NAME+"/":this.image_dir=SKIN_DIR+this.name+"/image/";DEBUG&&a("#pkwk-info ul").append('<li>JavaScript framework:<a href="//modernizr.com/">Modernizr</a>: <var>'+
C._version+'</var> / <a href="//jquery.com/">jQuery</a>: <var>'+a.fn.jquery+'</var> / <a href="//jqueryui.com">jQuery UI</a>: <var>'+a.ui.version+"</var>.</li>");this.body=this.custom.body?this.custom.body:'*[role="main"]';var b=a("link[rel=canonical]")[0].href,c=a("html").attr("lang");a.i18n(LANG);a.extend(!0,a.fn.superfish.defaults,{autoArrows:!1,dropShadows:!1},this.custom.suckerfish);a.extend(!0,a.fn.dataTable.defaults,{bJQueryUI:!0,bAutoWidth:!1,sDom:'<"H"pi>tr<"F"lf>',sPaginationType:"full_numbers",
oLanguage:{sEmptyTable:a.i18n("dataTable","sEmptyTable"),sInfo:a.i18n("dataTable","sInfo"),sInfoEmpty:a.i18n("dataTable","sInfoEmpty"),sInfoFiltered:a.i18n("dataTable","sInfoFiltered"),sInfoThousands:a.i18n("dataTable","sInfoThousands"),sLengthMenu:a.i18n("dataTable","sLengthMenu"),sLoadingRecords:a.i18n("dialog","loading"),sProcessing:a.i18n("dataTable","sProcessing"),sSearch:a.i18n("dataTable","sSearch"),sUrl:"",sZeroRecords:a.i18n("dataTable","sZeroRecords"),oPaginate:{sFirst:a.i18n("dialog","first"),
sPrevious:a.i18n("dialog","prev"),sNext:a.i18n("dialog","next"),sLast:a.i18n("dialog","last")},oAria:{sSortAscending:a.i18n("dataTable","sSortAscending"),sSortDescending:a.i18n("dataTable","sSortDescending")}}});b=a.extend(!0,{hatena:{use:!0,dom:'<a href="//b.hatena.ne.jp/entry/" data-hatena-bookmark-layout="standard-balloon"><img src="//b.st-hatena.com/images/entry-button/button-only@2x.png" alt="\u3053\u306e\u30a8\u30f3\u30c8\u30ea\u30fc\u3092\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u306b\u8ffd\u52a0" width="20" height="20" style="border: none;" /></a>',
script:"//b.st-hatena.com/js/bookmark_button.js"},mixi:{use:!1,dom:'<a href="//mixi.jp/share.pl" class="mixi-check-button" data-url="'+b+'" data-button="button-6">Mixi</a>',script:"//static.mixi.jp/js/share.js"},"google+1":{use:!0,dom:'<div class="g-plusone" data-size="medium">Google+1</div>',script:"https://apis.google.com/js/plusone.js"},twitter:{use:!0,dom:'<a href="//twitter.com/share" class="twitter-share-button" data-dnt="true" data-lang="'+c+'">Tweet</a>',script:"//platform.twitter.com/widgets.js"},
tumblr:{use:!1,dom:'<a href="//www.tumblr.com/share" title="Share on Tumblr" style="display:inline-block; text-indent:-9999px; overflow:hidden; width:81px; height:20px; background:url(\'//platform.tumblr.com/v1/share_1.png\') top left no-repeat transparent;"></a>',script:"//platform.tumblr.com/v1/share.js"}},this.custom.social);this.assistant_setting={emoji:"sun cloud rain snow thunder typhoon mist sprinkle aries taurus gemini cancer leo virgo libra scorpius sagittarius capricornus aquarius pisces sports baseball golf tennis soccer ski basketball motorsports pocketbell train subway bullettrain car rvcar bus ship airplane house building postoffice hospital bank atm hotel cvs gasstation parking signaler toilet restaurant cafe bar beer fastfood boutique hairsalon karaoke movie upwardright carouselpony music art drama event ticket smoking nosmoking camera bag book ribbon present birthday telephone mobilephone memo tv game cd heart spade diamond club eye ear rock scissors paper downwardright upwardleft foot shoe eyeglass wheelchair newmoon moon1 moon2 moon3 fullmoon dog cat yacht xmas downwardleft phoneto mailto faxto info01 info02 mail by-d d-point yen free id key enter clear search new flag freedial sharp mobaq one two three four five six seven eight nine zero ok heart01 heart02 heart03 heart04 happy01 angry despair sad wobbly up note spa cute kissmark shine flair annoy punch bomb notes down sleepy sign01 sign02 sign03 impact sweat01 sweat02 dash sign04 sign05 slate pouch pen shadow chair night soon on end clock appli01 appli02 t-shirt moneybag rouge denim snowboard bell door dollar pc loveletter wrench pencil crown ring sandclock bicycle japanesetea watch think confident coldsweats01 coldsweats02 pout gawk lovely good bleah wink happy02 bearing catface crying weep ng clip copyright tm run secret recycle r-mark danger ban empty pass full leftright updown school wave fuji clover cherry tulip banana apple bud maple cherryblossom riceball cake bottle noodle bread snail chick penguin fish delicious smile horse pig wine shock".split(" "),
color:"#000 #030 #060 #090 #0C0 #0F0 #300 #330 #360 #390 #3C0 #3F0 #600 #630 #660 #690 #6C0 #6F0 #003 #033 #063 #093 #0C3 #0F3 #303 #333 #363 #393 #3C3 #3F3 #603 #633 #663 #693 #6C3 #6F3 #006 #036 #066 #096 #0C6 #0F6 #306 #336 #366 #396 #3C6 #3F6 #606 #636 #666 #696 #6C6 #6F6 #009 #039 #069 #099 #0C9 #0F9 #309 #339 #369 #399 #3C9 #3F9 #609 #639 #669 #699 #6C9 #6F9 #00C #03C #06C #09C #0CC #0FC #30C #33C #36C #39C #3CC #3FC #60C #63C #66C #69C #6CC #6FC #00F #03F #06F #09F #0CF #0FF #30F #33F #36F #39F #3CF #3FF #60F #63F #66F #69F #6CF #6FF #900 #930 #960 #990 #9C0 #9F0 #C00 #C30 #C60 #C90 #CC0 #CF0 #F00 #F30 #F60 #F90 #FC0 #FF0 #903 #933 #963 #993 #9C3 #9F3 #C03 #C33 #C63 #C93 #CC3 #CF3 #F03 #F33 #F63 #F93 #FC3 #FF3 #906 #936 #966 #996 #9C6 #9F6 #C06 #C36 #C66 #C96 #CC6 #CF6 #F06 #F36 #F66 #F96 #FC6 #FF6 #909 #939 #969 #999 #9C9 #9F9 #C09 #C39 #C69 #C99 #CC9 #CF9 #F09 #F39 #F69 #F99 #FC9 #FF9 #90C #93C #96C #99C #9CC #9FC #C0C #C3C #C6C #C9C #CCC #CFC #F0C #F3C #F6C #F9C #FCC #FFC #90F #93F #96F #99F #9CF #9FF #C0F #C3F #C6F #C9F #CCF #CFF #F0F #F3F #F6F #F9F #FCF #FFF #111 #222 #333 #444 #555 #666 #777 #888 #999 #A5A5A5 #AAA #BBB #C3C3C3 #CCC #D2D2D2 #DDD #EEE #FFF".split(" ")};
this.sh_config=a.extend(!0,{theme:"default",options:{lineNumbers:!0,showMenu:!0}},this.custom.sh);a(".sf-menu").superfish();this.preptoc();0!==a(".form-edit").length&&"guiedit"!==a.query.get("cmd")&&this.set_editform();0!==a('*[name="msg"]').length&&(a(".plugin-comment-form, .plugin-pcomment-form").after('<div class="assistant ui-corner-all ui-widget-header ui-helper-clearfix"></div>'),this.assistant(!1));this.init_dom();a("#banner_box img").fadeTo(200,.3);a("#banner_box img").hover(function(){a(this).fadeTo(200,
1)},function(){a(this).fadeTo(200,.3)});this.social(b);this.blockUI();0!==a(".mathjax-eq").length&&a.getScript("//cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS_HTML",function(){MathJax.Hub.Config({displayAlign:"inherit",TeX:{Macros:{bm:["\\\\boldsymbol{#1}",1],argmax:["\\\\mathop{\\\\rm arg\\\\,max}\\\\limits"],argmin:["\\\\mathop{\\\\rm arg\\\\,min}\\\\limits"]},extensions:["autobold.js","color.js"],equationNumbers:{}},tex2jax:{ignoreClass:".*",processClass:"mathjax-eq"}})})},unload:function(b){a(":input").attr("disabled",
"disabled");return!1},register:{init:function(a){q.push(a)},before_init:function(a){l.push(a)},unload:function(a){t.push(a)},before_unload:function(a){u.push(a)},ajax_load:function(a){y.push(a)}},init_dom:function(b,c){var e=this;void 0!==b&&"string"!==typeof b&&(b=b.selector);b=b?b+" ":"";a(":input").attr("disabled","disabled");a(b+"form.autosubmit").change(function(){this.submit()});a(b+"textarea").tabby();a(b+"textarea[rows=1]").autosize();a(b+"li[role=tab] a").each(function(){var b=a(this),c=
b.attr("href");b.on("click",function(){return!1});c.match("#")?b.data("disableScrolling",!0):c.match("ajax=raw")||b.attr("href",c+"&ajax=raw")});a(b+".tabs").tabs({beforeLoad:function(b,c){c.panel.html('<p id="ajax_error" class="alert alert-info"><span class="fa fa-spinner fa-spin"></span>'+a.i18n("dialog","loading")+"</p>");c.jqXHR.global=!1;c.jqXHR.error(function(){c.panel.html('<p id="ajax_error" class="alert alert-warning"><span class="fa fa-fa-exclamation-triangle"></span>'+a.i18n("dialog","error_page")+
"</p>")})},load:function(a,b){e.init_dom(b.panel.id)}}).removeClass("tabs");a(b+".accordion").accordion({ajaxOptions:{global:!1,ajaxOptions:{beforeSend:function(b,c){c.panel.html(a.i18n("dialog","loading"));c.jqXHR.error(function(){c.panel.html('<p id="ajax_error" class="alert alert-danger"><span class="fa fa-times-circle"></span>'+a.i18n("dialog","error_page")+"</p>")})}}},spinner:a.i18n("dialog","loading"),load:function(a,b){e.init_dom(b.panel.id)}}).removeClass("tabs");this.setUploaderProgress(b);
this.setAnchor(b);this.sh(b);this.suggest(b);this.bad_behavior(b);this.glossaly(b);this.dataTable(b);this.setRegion(b);a(":input").removeAttr("disabled");"function"===typeof c&&c()},setUploaderProgress:function(b){var c,e,g;e=a(b+'form[enctype="multipart/form-data"]');if(0!==e.children('input[type="file"]').length&&0!==e.length&&0!==e.find(".progress_session").length){g=a('<div class="help-block hide">\n<div class="progress progress-info progress-striped">\n<div class="bar"></div>\n</div>\n<p></p>\n</div>');
e.append(g);var h=function(){a.getJSON(SCRIPT,{cmd:"attach",pcmd:"progress"},function(b){b.status&&!b.status.done?k(Math.floor(b.status.current/b.status.total*100),a.i18n("uploader","uploading")):(k(100,"Complete!"),clearInterval(c))})},k=function(a,b){g.show();g.width(a+"%");g.children("p").html(b);100>a?g.children(".progress").addClass("progress-info active").removeClass("progress-success"):g.children(".progress").removeClass("progress-info active").addClass("progress-success")};e.find("button").off("click").on("click",
function(b){b.preventDefault();""!==e.children('input[type="file"]').val()&&(a(this).ajaxSubmit({beforeSubmit:function(a,b,c){a.push({ajax:!0})},success:function(a,b,e,f){clearInterval(c);k(100,"Complete!");g.hide();a.status||(a=f.children('input[type="file"]'),a.replaceWith(a.val("").clone(!0)))},error:function(a,b,c){f.log(a,b,c)}}),k(0,"Starting upload..."),c=setInterval(h,900))})}},setRegion:function(b){b=b?a(b).find(".plugin-region"):a(".plugin-region");var c=a('<button class="btn btn-default btn-xs pull-left region-btn"><small class="fa fa-plus"></small></button>');
b.find(".plugin-region-title").before(c);a(".plugin-region-body").hide();a(".region-btn").off("click").on("click",function(){var b=a(this),c=b.next().next();b.attr("disabled","disabled");c.toggle("blind",{},500,function(){if(null!==c.data("page")&&""===c.html()){var e={cmd:"read",ajax:"raw"},g="",h=c.data("page").split("#");e.page=h[0];h[1]&&(e.id=h[1]);b.html('<small class="fa fa-spinner fa-spin"></small>');a.ajax({global:!1,dataType:"text",url:SCRIPT,data:e,type:"GET",cache:!0}).done(function(a){g=
null!==a?a.replace(/<script[^>]*>[^<]+/ig,""):'<p class="alert alert-warning"><span class="fa fa-warning"></span>Data is Null!</p>'}).fail(function(b,c){401===b.status?c=a.i18n("dialog","error_auth"):"error"===c&&(c=a.i18n("dialog","error_page"));g='<p class="alert alert-warning" id="ajax-error"><span class="fa fa-warning"></span>'+c+"</p>";f.error(b)}).always(function(a){c.html(g)})}c.is(":hidden")?b.html('<small class="fa fa-plus"></small>'):b.html('<small class="fa fa-minus"></small>');b.removeAttr("disabled")})})},
setAnchor:function(b){var e=this,f=b?a(b).find("a"):a("a");a(".fa-external-link, .fa-external-link-square").each(function(){var b=a(this);b.off("click").on("click",function(){k.open(b.parent().attr("href"));return!1})});f.each(function(){var c=a(this),f=c.attr("href"),h=c.attr("rel"),l=f?f.match(/\.(\w+)$/i):null,m=h&&h.match(/noreferer|license|product|external/);if(f&&!1!==c.data("ajax"))if(f===a('link[rel="canonical"]').attr("href")&&"read"===a.query.get("cmd"))c.off("click").on("click",function(){a.ajax({dataType:"xml",
url:SCRIPT,data:{cmd:"read",page:PAGE,ajax:"xml"},type:"GET",cache:!1}).done(function(a){}).fail(function(a,b){}).always(function(b){var c=a('*[role="main"]');a(b).find("body").each(function(){c.html(a(this).text());e.init()})});return!1});else if(m)c.off("click").on("click",function(){if(h.match(/noreferer/))if(g){var a=k.open("","","location=yes, menubar=yes, toolbar=yes, status=yes, resizable=yes, scrollbars=yes,").document;a.open();a.write('<meta http-equiv="refresh" content="0;url='+f+'" />');
a.close()}else f.match(/data:text\/html;/)?k.open(f):(a="data:text/html;charset=utf-8,"+encodeURIComponent('<html><head><script type="text/javascript">\x3c!--\ndocument.write(\'<meta http-equiv="refresh" content="0;url='+f+"\" />');\n// --\x3e\x3c/script></head><body></body></html>"),h.match(/external/)?k.open(a):location.href=a);else if(l[1])switch(l[1]){case "jpg":case "jpeg":case "gif":case "png":c.rlightbox();break;default:k.open(f)}return!1});else if(f){for(var n={},m=f.slice(f.indexOf("?")+
1).split("&"),q=c.data("disableScrolling")||c.parent().attr("role")?!0:!1,t=0;t<m.length;t++){var u=m[t].split("=");try{n[u[0]]=decodeURIComponent(u[1]).replace(/\+/g," ").replace(/%2F/g,"/")}catch(A){}}if("false"===n.ajax)return!0;if(f.match("#")&&"#"!==f){if(!1===q)c.off("click").on("click",function(){var b;0===a(k).scrollTop()&&a(k).scrollTop(1);if(0<a("html").scrollTop())b=a("html");else if(0<a("body").scrollTop())b=a("body");else return;b.stop().animate({scrollTop:a(f).offset().top},{duration:800});
e._hideToc();return!1})}else{if("raw"===n.ajax)return!1;if(n.cmd)if("open"==n.pcmd||void 0!==n.openfile){if(n.file?(m=n.file,c.attr("href",SCRIPT+"?cmd="+n.cmd+"&pcmd="+n.pcmd+"&refer="+n.refer+"&age="+n.age+"&file="+m)):(m=n.openfile,c.attr("href",SCRIPT+"?cmd="+n.cmd+"&refer="+n.refer+"&openfile="+m)),l=m.match(/\.(\w+)$/i))switch(l[1].toLowerCase()){case "jpg":case "jpeg":case "gif":case "png":c.rlightbox()}}else if("qrcode"==n.cmd)c.attr("href",f+"&type=.gif"),c.rlightbox();else if(n.cmd.match(/search|newpage|template|rename/i)||
"true"===n.help||"attach"===n.cmd&&"list"!==n.pcmd||"tb"===n.cmd&&void 0!==n.tb_id||"table_edit2"===n.cmd||n.cmd.match(/attach|source|template|freeze|rename|diff|referer|logview|related/i)&&"undefined"!==typeof n.page)"true"==n.help&&(n={cmd:"read",page:"FormatRule"}),c.off("click").on("click",function(){n.ajax="json";e.ajax_dialog(n,b,function(){if("attach"==n.cmd&&n.pcmd.match(/upload|info/i)||n.cmd.match(/attachref|read|backup/i)&&""!==n.age)a(b).find(".window"),e.init_dom(b+" .window")});return!1})}}});
if(0===a("#back-top").length){var f=a(c.body),h=a(k),l;f.append('<div id="back-top"><a href="#" class="btn btn-primary btn-lg" title="Go to Top"><span class="glyphicon glyphicon-arrow-up"></span></a></div>');l=a("#back-top");l.hide();h.scroll(function(){a(this).scrollTop()>a(".masthead").height()?l.fadeIn():l.fadeOut()});a("#back-top a").off("click").on("click",function(){a("html,body").animate({scrollTop:0},1E3);return!1}).fadeTo("fast",.5).hover(function(){a(this).fadeTo("normal",1)},function(){a(this).fadeTo("normal",
.5)})}},ajax_dialog:function(b,e,f,g){e=e?a(e).find(".window"):a(".window");var h=this,l={modal:!0,resizable:!0,show:"fade",hide:"fade",width:"520px",open:function(){"function"===typeof f&&f();h.init_dom(e);return!1},close:function(){a(this).remove()}},m=a('<div class="window"></div>'),n="";"upload"===b.pcmd&&(l.width="90%");if(b.cmd.match(/logview|source|diff|edit|read|referer/i)||"true"===b.help)l.width="90%",l.height=.8*a(k).height()|0;a.ajax({dataType:"json",url:SCRIPT,data:b,type:"GET",cache:!0}).done(function(a){}).fail(function(b,
e){302===b.status&&c.location.reload();l.title=a.i18n("dialog","error")}).always(function(b){"function"===typeof g&&(b=g(b));"null"!==typeof b&&b.body?(n=b.body.replace(/<script[^>]*>[^<]+/g,""),l.title=b.title):401===b.status||403===b.status?n='<p class="alert alert-warning" id="ajax-error"><span class="fa fa-warning"></span>'+a.i18n("dialog","error_auth")+"</p>":"error"===status?n='<p class="alert alert-warning" id="ajax-error"><span class="fa fa-warning"></span>'+a.i18n("dialog","error_page")+
"</p>":(n='<p class="alert alert-warning"><span class="fa fa-warning"></span>Data is Null!</p>',l.title=a.i18n("dialog","error"));m.html(n).dialog(l);a('*[role="tooltip"]').remove()})},blockUI:function(){var b=a(c),e=a(k),f,g;0===a("#loading").length&&a('<div id="loading"><div class="ui-widget-overlay"></div><div id="loading-activity"></div></div>').off("click").on("click",function(){a(this).fadeOut();return!1}).appendTo("body");f=a("#loading-activity");g=a("#loading");f.activity({segments:12,width:24,
space:8,length:64,color:"black",speed:1,zIndex:9999}).off("click").on("click",function(){g.fadeOut()});b.ajaxSend(function(b,c,h){a(":input").attr("disabled","disabled");f.css({position:"absolute",left:e.width()/2+e.scrollLeft()-f.width()/2,top:e.height()/2+e.scrollTop()-f.height()/2});g.fadeIn()}).ajaxStop(function(){a(":input").removeAttr("disabled");g.fadeOut();for(var b;b=y.shift();)null!==b&&b()})},sh:function(b){var c=this,e=b?b+" .sh":".sh",c=this;0!==a(e).length&&("undefined"===typeof k.Sunlight?
a.getScript(JS_URI+"sunlight/sunlight-all-min.js",function(){a("head").prepend('<link rel="stylesheet" href="'+JS_URI+"sunlight/themes/sunlight."+c.sh_config.theme+'.css" />');a.fn.sunlight=function(a){var b=new k.Sunlight.Highlighter(a);this.each(function(){b.highlightNode(this)});return this};a(e).sunlight(c.sh_config.config)}):a(e).sunlight(this.sh_config.config))},dataTable:function(b){(b?a(b).find(".table"):a(".table")).each(function(){var b=a(this),c="undefined"===typeof b.data("sortable")||
!0===b.data("sortable")?!0:!1;0!==b.find("thead").length&&c&&(c="undefined"===typeof b.data("pagenate")||!1===b.data("pagenate")?!1:!0,b.dataTable({bPaginate:c,sDom:c?'<"H"pi>tr<"F"lf>':"tr",aaSorting:b.data("filter")?b.data("filter"):[],aoColumnsDefs:[{sType:"natural"},{sType:"natural"},{sType:"natural"},null]}))});a(".fg-toolbar input, .fg-toolbar select").addClass("form-control").css("display","inline-block")},suggest:function(b){b=a(b?b+" .suggest":".suggest");var c={},e;0!==b.length&&b.autocomplete({minLength:3,
source:function(b,f){var g=b.term;g in c?f(c[g]):e=a.ajax({url:SCRIPT,data:{cmd:"list",term:g,type:"json"},method:"get",dataType:"json",global:!1}).done(function(a,b,h){c[g]=a;h===e&&f(a)})}})},glossaly:function(b){var e={};a(c.body).tooltip({items:".glossary, .search-summary, [title]",track:!0,show:function(){1<a('*[role="tooltip"]').length&&a('*[role="tooltip"]').remove()},content:function(b){var c=a(this);if(c.is(".glossary, .search-summary")){c.removeAttr("title");var f=c.text();if(""===f||e[f])return e[f];
c=c.is(".search-summary")?{cmd:"preview",page:f,word:a.query.get("word"),cache:!0}:{cmd:"tooltip",q:f,cache:!0};a.ajax({url:SCRIPT,type:"GET",cache:!0,timeout:2E3,dataType:"xml",global:!1,data:c}).done(function(a){a.documentElement.textContent&&(e[f]=a.documentElement.textContent,b(a.documentElement.textContent))}).always(function(a){a.responseText&&(e[f]=a.responseText,b(a.responseText))})}else if(c.is("[title]"))return c.attr("title")}})},assistant:function(b){var c,e,f,g=a('*[name="msg"]'),h;a(".assistant").html(['<div class="btn-toolbar" role="toolbar">\n<div class="btn-group">',
'<button class="btn btn-default btn-sm replace" title="'+a.i18n("editor","bold")+'" name="b"><span class="fa fa-bold"></span></button>','<button class="btn btn-default btn-sm replace" title="'+a.i18n("editor","italic")+'" name="i"><span class="fa fa-italic"></span></button>','<button class="btn btn-default btn-sm replace" title="'+a.i18n("editor","strike")+'" name="s"><span class="fa fa-strikethrough"></span></button>','<button class="btn btn-default btn-sm replace" title="'+a.i18n("editor","underline")+
'" name="u"><span class="fa fa-underline"></span></button>','<button class="btn btn-default btn-sm replace" title="'+a.i18n("editor","code")+'" name="code"><span class="fa fa-code"></span></button>','<button class="btn btn-default btn-sm replace" title="'+a.i18n("editor","quote")+'" name="q"><span class="fa fa-quote-left"></span></button>','</div>\n<div class="btn-group">','<button class="btn btn-default btn-sm replace" title="'+a.i18n("editor","link")+'" name="url"><span class="fa fa-link" role="button"></span></button>',
'<button class="btn btn-default btn-sm replace" title="'+a.i18n("editor","size")+'" name="size"><span class="fa fa-text-height" role="button"></span></button>','<button class="btn btn-default btn-sm insert" title="'+a.i18n("editor","color")+'" name="color">color</button>','</div>\n<div class="btn-group">','<button class="btn btn-default btn-sm insert" title="'+a.i18n("editor","emoji")+'" name="emoji"><span class="fa fa-smile-o"></span></button>','<button class="btn btn-default btn-sm insert" title="'+
a.i18n("editor","breakline")+'" name="br">\u23ce</button>',"</div>",'<button class="btn btn-default btn-sm replace" title="'+a.i18n("editor","ncr")+'" name="ncr">&amp;#</button>','<button class="btn btn-default btn-sm insert" title="'+a.i18n("editor","hint")+'" name="help"><span class="fa fa-question-circle"></span></button>',!b&&C.localstorage?'<button class="btn btn-default btn-sm insert" title="'+a.i18n("editor","flush")+'" name="flush"><span class="fa fa-trash-o"></span></button>':null,b?null:
'<button class="btn btn-default btn-sm disabled pull-right hidden" id="indicator"><span class="fa fa-refresh fa-spin"></span></button>',"</div>"].join("\n"));if(0===a("#emoji").length){z.append('<div id="emoji"></div>');f='<ul class="ui-widget pkwk_widget ui-helper-clearfix">';b=0;for(e=this.assistant_setting.emoji.length;b<e;b++){var k=this.assistant_setting.emoji[b];f+='<li class="btn btn-default btn-xs" title="'+k+'" name="'+k+'"><span class="emoji emoji-'+k+'"></span></li>'}f+="</ul>";a("#emoji").dialog({title:a.i18n("editor",
"emoji"),autoOpen:!1,bgiframe:!0,minWidth:410,height:410,minHeight:410,show:"scale",hide:"scale"}).html(f);a("#emoji").children("ul").children("li").off("click").on("click",function(){var b=g.getSelection().text,c="&("+a(this).attr("name")+");";g.focus();""===b?g.insertAtCaretPos(c):g.replaceSelection(c);h.dialog("close")})}h=a("#emoji");if(0===a("#color_palette").length){z.append('<div id="color_palette"></div>');f='<ul class="ui-widget pkwk_widget ui-helper-clearfix" id="colors">';b=0;for(e=this.assistant_setting.color.length;b<
e;b++)k=this.assistant_setting.color[b],f+='<li class="btn btn-default btn-xs" title="'+k+'" name="'+k+'"><span class="emoji" style="background-color:'+k+';"></span></li>',c++;f+="</ul>";a("#color_palette").dialog({title:a.i18n("editor","color"),autoOpen:!1,bgiframe:!0,width:470,height:400,show:"scale",hide:"scale"}).html(f);a("#color_palette").children("ul").children("li").off("click").on("click",function(){var b=g.getSelection().text,c=a(this).attr("name");""===b?alert(a.i18n("pukiwiki","select")):
(g.focus().replaceSelection(b.match(/^&color\([^\)]*\)\{.*\};$/)?b.replace(/^(&color\([^\)]*)(\)\{.*\};)$/,"$1,"+c+"$2"):"&color("+c+"){"+b+"};"),(void 0).dialog("close"))})}0===a("#hint").length&&(z.append('<div id="hint"></div>'),a("#hint").dialog({title:a.i18n("editor","hint"),autoOpen:!1,bgiframe:!0,width:470,show:"scale",hide:"scale"}).html(a.i18n("pukiwiki","hint_text1")));a(".insert").off("click").on("click",function(){var b="",c=a(this).attr("name");switch(c){case "help":a("#hint").dialog("open");
break;case "br":b="&br;\n";break;case "emoji":a("#emoji").dialog("open");break;case "color":a("#color_palette").dialog("open");break;case "flush":C.localstorage&&!0===confirm(a.i18n("pukiwiki","flush_restore"))&&localStorage.removeItem(PAGE);break;default:b="&("+c+");"}""!==b&&(g.focus(),""===g.getSelection().text?g.insertAtCaretPos(b):g.replaceSelection(b));a('*[role="tooltip]').hide();return!1});a(".replace").off("click").on("click",function(){var b="",c=g.getSelection().text,e=a(this).attr("name");
if(""===c)return alert(a.i18n("pukiwiki","select")),!1;switch(e){case "size":b=prompt(a.i18n("pukiwiki","fontsize"),"100%");if(!b||!b.match(/\d+/))return;b="&size("+b+"){"+c+"};";break;case "ncr":var f,e=0;for(f=c.length;e<f;e++)b+="&#"+c.charCodeAt(e)+";";break;case "b":b="''"+c+"''";break;case "i":b="'''"+c+"'''";break;case "u":b="__"+c+"__";break;case "s":b="%%"+c+"%%";break;case "code":b="@@"+c+"@@";break;case "q":b="@@@"+c+"@@@";break;case "url":e=prompt(a.i18n("pukiwiki","url"),"http://"),null!==
e&&(b="[["+c+">"+e+"]]")}g.focus().replaceSelection(b);return!1})},set_editform:function(b){b=a(".form-edit");var e=b.find('textarea[name="msg"]'),g=b.find('textarea[name="original"]'),h=this,l=!1,m=function(a){"string"===typeof a&&(a=a.replace(/&/g,"&amp;"),a=a.replace(/\"/g,"&quot;"),a=a.replace(/\'/g,"&#039;"),a=a.replace(/</g,"&lt;"),a=a.replace(/>/g,"&gt;"));return a},n=function(){var b=e.val(),c=a("#realview"),f=a("#indicator"),g;c.is(":visible")?(f.css("display:block;"),1===++h.ajax_count&&
(g=b.lastIndexOf("\n",e.getSelection().start),a.ajax({url:SCRIPT,type:"post",global:!1,data:{cmd:"edit",realview:1,page:decodeURIComponent(PAGE),msg:b.substring(0,g)+"\n\n&editmark;\n\n"+b.substring(g),type:"json"},cache:!1,dataType:"json",beforeSend:function(){e.attr("disabled","disabled");f.removeClass("hidden");f.html('<span class="fa fa-spinner fa-spin"></span>')}}).done(function(b,e,g){f.html('<span class="fa fa-clock-o"></span>'+b.taketime);b=b.data.replace(/<script[^>]*>[^<]+/ig,"<div>[SCRIPT]</div>");
b=b.replace(/<form(.*?)>(.*?)<\/form>/ig,"<div>[FORM]</div>");a("#realview").html(b);b=a("#editmark");0!==b.length&&c.scrollTop(b.offset().top-c.height()-100);1===h.ajax_count?h.ajax_count=0:(h.ajax_count=0,n())}).fail(function(b,e,f){DEBUG&&c.html(['<div class="alert alert-warning">','<p><span class="fa fa-warning-sign"></span>'+a.i18n("pukiwiki","error")+e+"</p>","<ul>","<li>readyState:"+b.readyState+"</li>","<li>responseText:"+b.responseText+"</li>","<li>status:"+b.status+"</li>","<li>statusText:"+
b.statusText+"</li>","</ul>\n</div>"].join("\n"))}).always(function(){e.removeAttr("disabled")}))):f.css("display:hidden;")},q=function(a,b,c){var e=a.length,f=b.length;if(!c&&e>f)return q(b,a,!0);var g,h,k=e+1,l=f-e,m=[],n=[],v=function(g){var h,l,q,v;h=m[g-1+k];l=m[g+1+k];h>=l?(l=h+1,h=l-g,q=n[g-1+k],v={edit:c?"-":"+",arr:b,line:l-1}):(h=l-g,q=n[g+1+k],v={edit:c?"+":"-",arr:a,line:h-1});0<=v.line&&(n[g+k]=q.concat(v));v=e-h>f-l?e-h:f-l;for(q=0;q<v&&a[h+q]===b[l+q];++q)n[g+k].push({edit:"=",arr:a,
line:h+q});m[g+k]=l+q;return!0};for(h=0;h<e+f+3;++h)m[h]=-1,n[h]=[];for(h=0;m[l+k]!==f;h++){for(g=-h;g<l;++g)v(g);for(g=l+h;g>=l;--g)v(g)}return n[l+k]};this.ajax_count=0;if(C.localstorage){var t=k.localStorage.getItem(PAGE);if(t=k.JSON.parse(t)){var u=MODIFIED>t.modified&&t.msg!==e.val()?a.i18n("pukiwiki","info_restore1"):a.i18n("pukiwiki","info_restore2");confirm(u)&&e.val(t.msg)}l=!0}b.find('button[name="write"]').after('<button type="submit" name="diff" class="btn btn-default" accesskey="d"><span class="fa fa-eye-slash"></span>'+
a.i18n("editor","diff")+"</button>");z.append('<div id="diff"><pre>'+m(g.val())+"</pre></div>");a("#diff").dialog({title:a.i18n("editor","diff"),autoOpen:!1,bgiframe:!0,width:"90%",height:.8*a(k).height()|0,show:"scale",hide:"scale"});e.unbind("blur").bind("blur",function(){n()}).unbind("mouseup").bind("mouseup",function(){a(this).val()!==g.val()&&n()}).unbind("keypress").bind("keypress",function(){if(l){var b=new Date;k.localStorage.setItem(PAGE,JSON.stringify({msg:a(this).val(),modified:b.getTime()}))}}).unbind("change").bind("change",
function(){for(var b=q(g.val().replace(/^\n+|\n+$/g,"").split("\n"),a(this).val().replace(/^\n+|\n+$/g,"").split("\n")),c=[],e=[],f=0;c=b[f];++f){var h=m(c.arr[c.line]);switch(c.edit){case "+":e[f]='<ins class="diff-added">'+h+"</ins>";break;case "-":e[f]='<del class="diff-removed">'+h+"</del>";break;default:e[f]=h}}a("#diff").html("<pre>"+e.join("\n")+"</pre>")});b.submit(function(){return!1});b.find("button").off("click").on("click",function(b){b.preventDefault();b=a(this);var h=b.parents("form"),
k=h.serializeObject(),m=h.find(":input");m.attr("disabled","disabled");switch(b.attr("name")){case "cancel":l&&localStorage.removeItem(PAGE);location.href=SCRIPT+"?"+PAGE;break;case "preview":var q=e.height();0===a("#realview").length&&e.before('<div id="realview" class="form-control" style="display:none;"></div>');a("#realview").is(":visible")?a("#realview").animate({height:0},function(){e.animate({height:2*q});a("#realview").hide();a("#indicator").addClass("hide");m.removeAttr("disabled","disabled")}):
e.animate({height:q/2},function(){a("#realview").css("display","block").animate({height:q/2},function(){n();m.removeAttr("disabled")})});break;case "diff":a("#diff").dialog("open");m.removeAttr("disabled");break;case "write":k.write=!0;k.ajax="json";if(g.val()==e.val()){alert("Void updating");m.removeAttr("disabled");break}if(0!==h.find('input[name="pass"]').length&&k.notimestamp&&""===k.pass){alert("Password is missing");m.removeAttr("disabled");break}a.ajax({type:"POST",url:SCRIPT,data:k,cache:!1,
dataType:"json"}).done(function(b){a("title").text(b.title);a('[role="main"]').html(b.body);if(!0===b.posted)return l&&localStorage.removeItem(PAGE),location.href=SCRIPT+"?"+PAGE,!1}).fail(function(b,e){f.log(b);DEBUG&&(f.error(b,e),0===a("#debug-window").length&&a(c.body).append('<div id="debug-window"></div>'),a("#debug-window").dialog({modal:!0,content:b.statusText}));alert(a.i18n("pukiwiki","error"))}).always(function(a,b){m.removeAttr("disabled")})}return!1});e.before('<div class="assistant ui-corner-top ui-widget-header ui-helper-clearfix"></div>');
this.assistant()},preptoc:function(){var a=this.prepHdngs();this.genTocDiv(a)},prepHdngs:function(){var b=a('*[role="main"]'),c=b.find("h2"),e=b.find(".contents"),f=[],b="";c.each(function(b){var c=a(this),g=c.attr("id");c.html(c.html()+'<span class="pkwk-icon icon-toc" title="Table of Contents of this page" style="cursor:pointer;"></span>');0===e.length&&(g||(g="_genid_"+b,c.attr("id",g)),f[b]='<li><a href="#'+g+'">'+c.text()+"</a></li>")});0!==e.length?b=e.html():0!==c.length?b="<ol>"+f.join("\n")+
"</ol>":-1!==a.query.get("cmd").match(/list|backup/)&&(b='<ul class="list-inline">'+a(".page_initial").children().html()+"</ul>");return b},genTocDiv:function(b){var e=this;this.toc=c.createElement("div");this.toc.id="poptoc";a(this.toc).addClass("panel panel-default noprint").css("top",0).css("left",0).css("position","absolute").css("z-index",100).css("display","none").html(['<h1><a href="#">'+a("#title").text()+'</a><abbr title="Table of Contents">[TOC]</abbr></h1>',b.replace(/href/g,'tabindex="1" href')].join("")).off("click").on("click",
function(){e._hideToc()});a("body").append(this.toc);b=c.createElement("div");b.id="toc_bg";a(b).addClass("ui-widget-overlay").css("display","none").off("click").on("click",function(){e._hideToc()});a("body").append(b);this.calcObj(this.toc,300);a(".icon-toc").off("click").on("click",function(b){a("#"+e.toc.id).hide()?e._dispToc(b,this,!1):e._hideToc(b)}).css("display","inline-block");a("#"+this.toc.id+" *").off("click").on("click",function(){e._hideToc()});a(k).keydown(function(b){if(!b.target.nodeName.match(/(input|textarea)/i)&&
111===b.keyCode)return a("#"+e.toc.id).hide()?e._dispToc():e._hideToc(),!1})},calcObj:function(a,b){var c=self.pageXOffset,e=self.pageYOffset;a.style.visibility="hidden";a.style.display="block";a.width=a.offsetWidth;a.width>b&&(a.width=b);a.height=a.offsetHeight;a.style.display="none";a.style.visibility="visible";e&&scroll(c,e)},_dispToc:function(b,c){var e,f,g,h,l=this.toc.height,m=this.toc.width;b&&c?(a(k).scrollLeft(),a(k).scrollTop(),e=b.pageX,f=b.pageY,g=a(k).width(),h=a(k).height(),h<l&&a(this.toc).css("height",
h+"px").css("overflow","auto"),a(this.toc).css("top",f+"px").css("left",(e<g-m?e:e-m)+"px")):a(this.toc).css("top",a(k).scrollTop()+"px").css("left","0px");a(this.toc).show("slow");a("#toc_bg").fadeIn("fast")},_hideToc:function(b){a(this.toc).hide("slow");a("#toc_bg").fadeOut("fast")},bad_behavior:function(b){"undefined"!==typeof BH_NAME&&"undefined"!==typeof BH_VALUE&&a((b?b+" ":"")+"form").append('<input type="hidden" name="'+BH_NAME+'" value="'+BH_VALUE+'" />')},social:function(b){if(pukiwiki.isPage){var c=
a('[role="main"]'),e=[],f=[];k.___gcfg={lang:a("html").attr("lang")};e.push('<hr class="noprint" /><ul class="social noprint clearfix list-inline">');for(var g in b)b[g].use&&(e.push("<li>"+b[g].dom+"</li>"),b[g].script&&f.push(b[g].script));"undefined"!==typeof FACEBOOK_APPID&&(a("html").attr("xmlns:fb","http://www.facebook.com/2008/fbml#"),a("body").append('<div id="fb-root"></div>'),e.push('<li><div class="fb-like" data-href="'+href+'" data-layout="button_count" data-send="true" data-width="450" data-show-faces="true"></div></li>'));
e.push("</ul>");c.append(e.join("\n"));for(b=0;b<f.length;b++)a.getScript(f[b]);"undefined"!==typeof FACEBOOK_APPID&&(a.getScript("//connect.facebook.net/"+LANG+"/all.js",function(){FB.init({appId:FACEBOOK_APPID,status:!0,cookie:!0,xfbml:!0,oauth:!0});FB.Event.subscribe("auth.login",function(){k.location.reload()})}),c.append('<hr class="noprint" /><div class="fb-comments" href="'+href+'" publish_feed="true" numposts="10" migrated="1"></div>'))}}};a.fn.serializeObject=function(){var b={},c=this.serializeArray();
a.each(c,function(){b[this.name]?(b[this.name].push||(b[this.name]=[b[this.name]]),b[this.name].push(this.value||"")):b[this.name]=this.value||""});return b};a(c).ready(function(){for(var a;a=l.shift();)null!==a&&a();pukiwiki.init();for(tzCalculation_LocalTimeZone(location.host,!1);a=q.shift();)null!==a&&a();DEBUG&&f.info("Finish. (Process Time :",new Date-n,"ms)")});a(k).unload(function(){pukiwiki.unload()});"undefined"!==typeof GOOGLE_ANALYTICS&&!1!==GOOGLE_ANALYTICS&&(function(a,b,c,e,f){a.GoogleAnalyticsObject=
c;a[c]||(a[c]=function(){(a[c].q=a[c].q||[]).push(arguments)});a[c].l=+new Date;e=b.createElement("script");f=b.scripts[0];e.src="//www.google-analytics.com/analytics.js";f.parentNode.insertBefore(e,f)}(this,c,"ga"),ga("create",GOOGLE_ANALYTICS,"auto"),ga("send","pageview",{}))})(jQuery,Modernizr,this,this.document);
var tzCalculation_LocalTimeZone=function(a,C){var k,c,b;k=new Date;c=Date.UTC(k.getUTCFullYear(),k.getUTCMonth(),k.getUTCDate(),k.getUTCHours(),k.getUTCMinutes(),k.getUTCSeconds());b=(Date.UTC(k.getFullYear(),k.getMonth(),k.getDate(),k.getHours(),k.getMinutes(),k.getSeconds())-c)/1E3/60;k=0>b?"-":"+";c=b%60;0!=c&&(b-=c,0>c&&(c=Math.abs(c)));0>b&&(b=Math.abs(b));b/=60;10>b&&(k+="0");k+=b;10>c&&(k+="0");k+=c;C&&document.writeln(k);document.cookie="timezone="+k+"; domain="+a;return k};
