(function(a){function A(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=A().width(2*m).height(2*m),l=A("g",{"stroke-width":b.width,"stroke-linecap":"round",stroke:b.color}).appendTo(A("g",
{transform:"translate("+m+","+m+")"}).appendTo(q)),k=0;k<b.segments;k++)l.append(A("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 v=Math.round(1E5/
a*k)/1E3,x=Math.round(1E5/a*(k+1)-1)/1E3,r="% { -webkit-transform:rotate("+Math.round(360/a*k)+"deg); }\n",l=l+(v+r+x+r);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,A,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():A.getSelection().removeAllRanges()};if(k.selection){var g=k.selection.createRange(),q=0,l=0,u=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 v=c.value.indexOf("\n",l);-1!=v&&v<a?(l=v+1,q++,u=q):-1!=v&&v>=a&&v<=e?v==a+1?(q--,u--,l=v+1):(l=v+1,u++):f=n}1==g.text.indexOf("\n",0)&&(u+=2);a-=q;e-=u;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++)v=c.value.indexOf("\n",
l),-1!=v&&v<a?(l=v+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,u=void 0==a.scrollTop?0:a.scrollTop;e=k.getElementsByTagName("TEXTAREA");
for(var v=0;v<e.length&&e[v]!=a;v++);if(k.selection&&"number"!=typeof a.selectionStart){u=k.selection.createRange();if("number"!=typeof a.selectionStart){var x;g=a.createTextRange();n=g.duplicate();e=g.text;g.moveToBookmark(u.getBookmark());x=g.text;try{n.setEndPoint("EndToStart",g)}catch(r){return this}if(e==x&&e!=u.text||n.text.length>e.length)return this}if(u.text){part=u.text;null!=a.value.match(/\n/g)&&(q=a.value.match(/\n/g).length);e=n.text.length;if(0<q)for(x=0;x<=q;x++){var D=a.value.indexOf("\n",
f);-1!=D&&D<e?(f=D+1,l++):x=q}u.text=c;b[v]=n.text.length+c.length;g.move("character",b[v]);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=u);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 u=b.value.indexOf("\n",g);-1!=u&&u<c?(g=u+1,n++,q=n):-1!=u&&u>=c&&u<=a?u==c+1?(n--,q--,g=u+1):(g=u+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(),A.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,u;e=f=0;var v=void 0==a.scrollTop?0:a.scrollTop;u=k.getElementsByTagName("TEXTAREA");for(var x=0;x<u.length&&u[x]!=a;x++);a.focus();if(k.selection&&"number"!=typeof a.selectionStart&&(null!=a.value.match(/\n/g)&&(e=a.value.match(/\n/g).length),u=parseInt(b[x]),0<e))for(var r=0;r<=e;r++){var D=a.value.indexOf("\n",
n);-1!=D&&D<=u&&(n=D+1,--u,f++)}b[x]=parseInt(b[x]);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[x]=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[x]=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[x]&&0==e?(f=b[x]-f,q.move("character",f),q.select(),g=k.selection.createRange(),b[x]+=c.length):0<=b[x]||0!=textLength?0<=b[x]||0!=e?!(0<=b[x])&&0<e?(q.move("character",0),k.selection.empty(),q.select(),g=k.selection.createRange(),b[x]=e+c.length):
0<=b[x]&&b[x]==textLength?(0!=textLength?(q.move("character",textLength),q.select()):q.move("character",0),g=k.selection.createRange(),b[x]=c.length+textLength):(0<=b[x]&&0!=e&&b[x]>=e?(f=b[x]-e,q.move("character",f)):0<=b[x]&&0!=e&&b[x]<e&&q.move("character",0),k.selection.empty(),q.select(),g=k.selection.createRange(),b[x]+=c.length):(q.move("character",textLength),q.select(),g=k.selection.createRange(),b[x]=c.length+textLength):(g=k.selection.createRange(),b[x]=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=v);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 A={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({},A,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<u&&(a=u));a+=v;f!==a&&(g.style.height=a+"px",b.className=b.className,x&&h.callback.call(g,g),q.trigger("autosize.resized"))}function n(){clearTimeout(D);D=setTimeout(function(){var a=q.width();a!==H&&(H=a,f())},parseInt(h.resizeDelay,10))}var g=this,q=a(g),l,u,v=0,x=a.isFunction(h.callback),r={height:g.style.height,overflow:g.style.overflow,overflowY:g.style.overflowY,wordWrap:g.style.wordWrap,
resize:g.style.resize},D,H=q.width(),B=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"))v=q.outerHeight()-q.height();u=Math.max(parseFloat(q.css("minHeight"))-v||0,q.height());q.css({overflow:"hidden",overflowY:"hidden",wordWrap:"break-word"});"vertical"===B?q.css("resize","none"):"both"===B&&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(D);a(window).off("resize",n);q.off("autosize").off(".autosize").css(r).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 A(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),"=",A(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("="),
u;u=l.shift();u=b.raw?u:decodeURIComponent(u);l=l.join("=");if(c&&c===u){f=k(l,m);break}c||void 0===(l=k(l))||(f[u]=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,A,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 w,a,F={};c.each(d,function(c,p){(w=c.match(/^([^A-Z]+?)([A-Z])/))&&-1!=="a aa ai ao as b fn i m o s ".indexOf(w[1]+" ")&&(a=c.replace(w[0],w[2].toLowerCase()),F[a]=c,"o"===w[1]&&b(d[c]))});d._hungarianMap=F}function h(d,w,a){d._hungarianMap||b(d);var F;c.each(w,function(b,p){F=d._hungarianMap[b];
F===k||!a&&w[F]!==k||("o"===F.charAt(0)?(w[F]||(w[F]={}),c.extend(!0,w[F],w[b]),h(d[F],w[F],a)):w[F]=w[b])})}function m(d){var w=z.defaults.oLanguage,a=d.sZeroRecords;!d.sEmptyTable&&a&&"No data available in table"===w.sEmptyTable&&Z(d,d,"sZeroRecords","sEmptyTable");!d.sLoadingRecords&&a&&"Loading..."===w.sLoadingRecords&&Z(d,d,"sZeroRecords","sLoadingRecords");d.sInfoThousands&&(d.sThousands=d.sInfoThousands);(d=d.sDecimal)&&hb(d)}function e(d){U(d,"ordering","bSort");U(d,"orderMulti","bSortMulti");
U(d,"orderClasses","bSortClasses");U(d,"orderCellsTop","bSortCellsTop");U(d,"order","aaSorting");U(d,"orderFixed","aaSortingFixed");U(d,"paging","bPaginate");U(d,"pagingType","sPaginationType");U(d,"pageLength","iDisplayLength");U(d,"searching","bFilter");if(d=d.aoSearchCols)for(var w=0,a=d.length;w<a;w++)d[w]&&h(z.models.oSearch,d[w])}function f(d){U(d,"orderable","bSortable");U(d,"orderData","aDataSort");U(d,"orderSequence","asSorting");U(d,"orderDataType","sortDataType")}function n(d){d=d.oBrowser;
var w=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=w.find(".test");d.bScrollOversize=100===a[0].offsetWidth;d.bScrollbarLeft=1!==a.offset().left;w.remove()}function g(d,w,a,c,b,p){var t,e=!1;a!==k&&(t=a,e=!0);for(;c!==b;)d.hasOwnProperty(c)&&(t=e?w(t,d[c],c,d):d[c],e=!0,c+=p);return t}function q(d,
w){var a=z.defaults.column,F=d.aoColumns.length,a=c.extend({},z.models.oColumn,a,{nTh:w?w:A.createElement("th"),sTitle:a.sTitle?a.sTitle:w?w.innerHTML:"",aDataSort:a.aDataSort?a.aDataSort:[F],mData:a.mData?a.mData:F,idx:F});d.aoColumns.push(a);a=d.aoPreSearchCols;a[F]=c.extend({},z.models.oSearch,a[F]);l(d,F,null)}function l(d,w,a){w=d.aoColumns[w];var F=d.oClasses,b=c(w.nTh);if(!w.sWidthOrig){w.sWidthOrig=b.attr("width")||null;var p=(b.attr("style")||"").match(/width:\s*(\d+[pxem%]+)/);p&&(w.sWidthOrig=
p[1])}a!==k&&null!==a&&(f(a),h(z.defaults.column,a),a.mDataProp===k||a.mData||(a.mData=a.mDataProp),a.sType&&(w._sManualType=a.sType),a.className&&!a.sClass&&(a.sClass=a.className),c.extend(w,a),Z(w,a,"sWidth","sWidthOrig"),"number"===typeof a.iDataSort&&(w.aDataSort=[a.iDataSort]),Z(w,a,"aDataSort"));var t=w.mData,e=ca(t),ib=w.mRender?ca(w.mRender):null;a=function(d){return"string"===typeof d&&-1!==d.indexOf("@")};w._bAttrSrc=c.isPlainObject(t)&&(a(t.sort)||a(t.type)||a(t.filter));w.fnGetData=function(d,
a,w){var c=e(d,a,k,w);return ib&&a?ib(c,a,d,w):c};w.fnSetData=function(d,a,w){return ja(t)(d,a,w)};d.oFeatures.bSort||(w.bSortable=!1,b.addClass(F.sSortableNone));d=-1!==c.inArray("asc",w.asSorting);a=-1!==c.inArray("desc",w.asSorting);w.bSortable&&(d||a)?d&&!a?(w.sSortingClass=F.sSortableAsc,w.sSortingClassJUI=F.sSortJUIAscAllowed):!d&&a?(w.sSortingClass=F.sSortableDesc,w.sSortingClassJUI=F.sSortJUIDescAllowed):(w.sSortingClass=F.sSortable,w.sSortingClassJUI=F.sSortJUI):(w.sSortingClass=F.sSortableNone,
w.sSortingClassJUI="")}function u(d){if(!1!==d.oFeatures.bAutoWidth){var a=d.aoColumns;La(d);for(var c=0,F=a.length;c<F;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 v(d,a){var c=D(d,"bVisible");return"number"===typeof c[a]?c[a]:null}function x(d,a){var C=D(d,"bVisible"),C=c.inArray(a,C);return-1!==C?C:null}function r(d){return D(d,"bVisible").length}function D(d,a){var C=[];c.map(d.aoColumns,function(d,c){d[a]&&C.push(c)});return C}
function H(d){var a=d.aoColumns,c=d.aoData,F=z.ext.type.detect,b,p,t,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){t=0;for(e=F.length;t<e;t++){f=0;for(h=c.length;f<h&&(n[f]===k&&(n[f]=J(d,f,b,"type")),l=F[t](n[f],d),l&&"html"!==l);f++);if(l){g.sType=l;break}}g.sType||(g.sType="string")}}function B(d,a,C,F){var b,p,t,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(t=l.length;p<t;p++)if("number"===typeof l[p]&&0<=l[p]){for(;g.length<=l[p];)q(d);F(l[p],h)}else if("number"===typeof l[p]&&0>l[p])F(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]))&&F(e,h)}if(C)for(b=0,d=C.length;b<d;b++)F(b,C[b])}function G(d,a,C,F){var b=d.aoData.length,p=c.extend(!0,{},z.models.oRow,{src:C?"dom":"data"});p._aData=a;d.aoData.push(p);a=d.aoColumns;for(var p=0,t=a.length;p<t;p++)C&&L(d,b,p,J(d,b,
p)),a[p].sType=null;d.aiDisplayMaster.push(b);!C&&d.oFeatures.bDeferRender||Ma(d,b,C,F);return b}function M(d,a){var C;a instanceof c||(a=c(a));return a.map(function(a,w){C=wa(d,w);return G(d,C.data,w,C.cells)})}function J(d,a,c,F){var b=d.iDraw,p=d.aoColumns[c],t=d.aoData[a]._aData,e=p.sDefaultContent;c=p.fnGetData(t,F,{settings:d,row:a,col:c});if(c===k)return d.iDrawError!=b&&null===e&&(ka(d,0,"Requested unknown parameter "+("function"==typeof p.mData?"{function}":"'"+p.mData+"'")+" for row "+a,
4),d.iDrawError=b),e;if((c===t||null===c)&&null!==e)c=e;else if("function"===typeof c)return c.call(t);return null===c&&"display"==F?"":c}function L(d,a,c,F){d.aoColumns[c].fnSetData(d.aoData[a]._aData,F,{settings:d,row:a,col:c})}function da(d){return c.map(d.match(/(\\.|[^\.])+/g),function(d){return d.replace(/\\./g,".")})}function ca(d){if(c.isPlainObject(d)){var a={};c.each(d,function(d,c){c&&(a[d]=ca(c))});return function(d,c,C,b){var e=a[c]||a._;return e!==k?e(d,c,C,b):d}}if(null===d)return function(d){return d};
if("function"===typeof d)return function(a,c,w,C){return d(a,c,w,C)};if("string"!==typeof d||-1===d.indexOf(".")&&-1===d.indexOf("[")&&-1===d.indexOf("("))return function(a,c){return a[d]};var C=function(d,a,c){var w,b;if(""!==c){b=da(c);for(var e=0,f=b.length;e<f;e++){c=b[e].match(sa);w=b[e].match(la);if(c){b[e]=b[e].replace(sa,"");""!==b[e]&&(d=d[b[e]]);w=[];b.splice(0,e+1);b=b.join(".");e=0;for(f=d.length;e<f;e++)w.push(C(d[e],a,b));d=c[0].substring(1,c[0].length-1);d=""===d?w:w.join(d);break}else if(w){b[e]=
b[e].replace(la,"");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 C(a,c,d)}}function ja(d){if(c.isPlainObject(d))return ja(d._);if(null===d)return function(){};if("function"===typeof d)return function(a,c,w){d(a,"set",c,w)};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=da(b);var p;p=b[b.length-1];for(var t,e,f=0,h=b.length-1;f<h;f++){t=b[f].match(sa);
e=b[f].match(la);if(t){b[f]=b[f].replace(sa,"");d[b[f]]=[];p=b.slice();p.splice(0,f+1);t=p.join(".");e=0;for(h=c.length;e<h;e++)p={},a(p,c[e],t),d[b[f]].push(p);return}e&&(b[f]=b[f].replace(la,""),d=d[b[f]](c));if(null===d[b[f]]||d[b[f]]===k)d[b[f]]={};d=d[b[f]]}if(p.match(la))d[p.replace(la,"")](c);else d[p.replace(sa,"")]=c};return function(c,b){return a(c,b,d)}}function ma(d){return Y(d.aoData,"_aData")}function ea(d){d.aoData.length=0;d.aiDisplayMaster.length=0;d.aiDisplay.length=0}function R(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 xa(d,a,c,b){var e=d.aoData[a],p;if("dom"!==c&&(c&&"auto"!==c||"dom"!==e.src)){var t=e.anCells,f;if(t)for(c=0,p=t.length;c<p;c++){for(f=t[c];f.childNodes.length;)f.removeChild(f.firstChild);t[c].innerHTML=J(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 C=[],b=[],e=a.firstChild,p,t,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){t=l[h];g=c.trim(d.innerHTML);t&&t._bAttrSrc?(f={display:g},n(t.mData.sort,f,d),n(t.mData.type,f,d),n(t.mData.filter,f,d),C.push(f)):C.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:C,cells:b}}
function Ma(d,a,c,b){var e=d.aoData[a],p=e._aData,t=[],f,h,g,l,n;if(null===e.nTr){f=c||A.createElement("tr");e.nTr=f;e.anCells=t;f._DT_RowIndex=a;Na(e);l=0;for(n=d.aoColumns.length;l<n;l++){g=d.aoColumns[l];h=c?b[l]:A.createElement(g.sCellType);t.push(h);if(!c||g.mRender||g.mData!==l)h.innerHTML=J(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,J(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,C=d._aData;if(a){C.DT_RowId&&(a.id=C.DT_RowId);if(C.DT_RowClass){var b=C.DT_RowClass.split(" ");d.__rowc=d.__rowc?Oa(d.__rowc.concat(b)):b;c(a).removeClass(d.__rowc.join(" ")).addClass(C.DT_RowClass)}C.DT_RowData&&c(a).data(C.DT_RowData)}}function na(d){var a,C,b,e,p,t=d.nTHead,f=d.nTFoot,h=0===c("th, td",t).length,g=d.oClasses,l=d.aoColumns;h&&(e=c("<tr/>").appendTo(t));a=0;for(C=l.length;a<C;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,t);c(t).find(">tr").attr("role","row");c(t).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,C=d.length;a<C;a++)p=l[a],p.nTf=d[a].cell,p.sClass&&c(p.nTf).addClass(p.sClass)}
function ta(d,a,C){var b,e,p,t=[],f=[],h=d.aoColumns.length,g;if(a){C===k&&(C=!1);b=0;for(e=a.length;b<e;b++){t[b]=a[b].slice();t[b].nTr=a[b].nTr;for(p=h-1;0<=p;p--)d.aoColumns[p].bVisible||C||t[b].splice(p,1);f.push([])}b=0;for(e=t.length;b<e;b++){if(d=t[b].nTr)for(;p=d.firstChild;)d.removeChild(p);p=0;for(a=t[b].length;p<a;p++)if(g=h=1,f[b][p]===k){d.appendChild(t[b][p].cell);for(f[b][p]=1;t[b+h]!==k&&t[b][p].cell==t[b+h][p].cell;)f[b+h][p]=1,h++;for(;t[b][p+g]!==k&&t[b][p].cell==t[b][p+g].cell;){for(C=
0;C<h;C++)f[b+C][p+g]=1;g++}c(t[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))W(d,!1);else{var a=[],C=0,b=d.asStripeClasses,e=b.length,p=d.oLanguage,t=d.iInitDisplayStart,f="ssp"==V(d),h=d.aiDisplay;d.bDrawing=!0;t!==k&&-1!==t&&(d._iDisplayStart=f?t:t>=d.fnRecordsDisplay()?0:t,d.iInitDisplayStart=-1);var t=d._iDisplayStart,g=d.fnDisplayEnd();if(d.bDeferLoading)d.bDeferLoading=!1,d.iDraw++,W(d,!1);else if(!f)d.iDraw++;
else if(!d.bDestroying&&!ya(d))return;if(0!==h.length)for(p=f?d.aoData.length:g,f=f?0:t;f<p;f++){var l=h[f],n=d.aoData[l];null===n.nTr&&Ma(d,l);l=n.nTr;if(0!==e){var m=b[C%e];n._sRowStripe!=m&&(c(l).removeClass(n._sRowStripe).addClass(m),n._sRowStripe=m)}O(d,"aoRowCallback",null,[l,n._aData,C,f]);a.push(l);C++}else C=p.sZeroRecords,1==d.iDraw&&"ajax"==V(d)?C=p.sLoadingRecords:p.sEmptyTable&&0===d.fnRecordsTotal()&&(C=p.sEmptyTable),a[0]=c("<tr/>",{"class":e?b[0]:""}).append(c("<td />",{valign:"top",
colSpan:r(d),"class":d.oClasses.sRowEmpty}).html(C))[0];O(d,"aoHeaderCallback","header",[c(d.nTHead).children("tr")[0],ma(d),t,g,h]);O(d,"aoFooterCallback","footer",[c(d.nTFoot).children("tr")[0],ma(d),t,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(""),t,h,g,l,n,m,k=0;k<p.length;k++){t=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)t=kb(d);else if("f"==h&&e.bFilter)t=lb(d);else if("r"==h&&e.bProcessing)t=mb(d);else if("t"==h)t=nb(d);else if("i"==h&&e.bInfo)t=ob(d);else if("p"==h&&e.bPaginate)t=pb(d);else if(0!==z.ext.feature.length)for(g=z.ext.feature,m=0,l=g.length;m<l;m++)if(h==g[m].cFeature){t=
g[m].fnInit(d);break}t&&(g=d.aanFeatures,g[h]||(g[h]=[]),g[h].push(t),f.append(t))}b.replaceWith(f)}function N(d,a){var b=c(a).children("tr"),e,f,p,t,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;t=0;for(h=d[p];h[t];)t++;l=t;k=1===n?!0:!1;for(h=0;h<
n;h++)for(t=0;t<m;t++)d[p+t][l+h]={cell:f,unique:k},d[p+t].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,t=c[a].length;p<t;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,
t=d.ajax,h=d.oInstance;if(c.isPlainObject(t)&&t.data){p=t.data;var g=c.isFunction(p)?p(a):p;a=c.isFunction(p)&&g?g:c.extend(!0,a,g);delete t.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,w){w=d.oApi._fnLog;"parsererror"==c?w(d,0,"Invalid JSON response",1):4===a.readyState&&w(d,0,"Ajax error",7);W(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 t?d.jqXHR=c.ajax(c.extend(g,{url:t||d.sAjaxSource})):c.isFunction(t)?d.jqXHR=t.call(h,a,b,d):(d.jqXHR=c.ajax(c.extend(g,t)),t.data=p)}function ya(d){return d.bAjaxDataGet?(d.iDraw++,W(d,!0),ia(d,za(d),function(a){Aa(d,a)}),!1):!0}function za(d){var a=d.aoColumns,b=a.length,e=d.oFeatures,f=d.oPreviousSearch,p=d.aoPreSearchCols,t,h=[],g,l,n,m=pa(d);t=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",Y(a,"sName").join(","));k("iDisplayStart",t);k("iDisplayLength",g);var q={draw:d.iDraw,columns:[],order:[],start:t,length:g,search:{value:f.sSearch,regex:f.bRegex}};for(t=0;t<b;t++)l=a[t],n=p[t],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_"+t,g),e.bFilter&&(k("sSearch_"+
t,n.sSearch),k("bRegex_"+t,n.bRegex),k("bSearchable_"+t,l.bSearchable)),e.bSort&&k("bSortable_"+t,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=z.ext.legacy.ajax;return null===a?d.sAjaxSource?h:q:a?h:q}function Aa(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}ea(d);d._iRecordsTotal=parseInt(e,10);d._iRecordsDisplay=parseInt(c,10);b=Ba(d,a);e=0;for(c=b.length;e<c;e++)G(d,b[e]);d.aiDisplay=d.aiDisplayMaster.slice();d.bAjaxDataGet=!1;fa(d);d._bInitComplete||Ca(d,a);d.bAjaxDataGet=!0;W(d,!1)}function Ba(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?ca(b)(a):a}function lb(d){var a=d.oClasses,b=d.sTableId,e=d.oLanguage,f=
d.oPreviousSearch,p=d.aanFeatures,t='<input type="search" class="'+a.sFilterInput+'"/>',h=e.sSearch,h=h.match(/_INPUT_/)?h.replace("_INPUT_",t):h+t,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"===V(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]!==A.activeElement&&g.val(f.sSearch)}catch(w){}});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};H(d);if("ssp"!=V(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=z.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!==z.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=z.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=J(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(),t=d.fnRecordsDisplay(),g=t?b.sInfo:b.sInfoEmpty;t!==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,t,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);W(d,!0);c.bAutoWidth&&La(d);a=0;for(c=e.length;a<c;a++)p=e[a],p.sWidth&&(p.nTh.style.width=I(p.sWidth));
ha(d);e=V(d);"ssp"!=e&&("ajax"==e?ia(d,[],function(c){var e=Ba(d,c);for(a=0;a<e.length;a++)G(d,e[a]);d.iInitDisplayStart=b;ha(d);W(d,!1);Ca(d,c)},d):(W(d,!1),Ca(d)))}else setTimeout(function(){Ea(d)},200)}function Ca(d,a){d._bInitComplete=!0;a&&u(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}),t=0,g=p.length;t<g;t++)f[0][t]=new Option(e[t],p[t]);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,w){d===b&&c("select",h).val(w)});return h[0]}function pb(d){var a=d.sPaginationType,b=z.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,w=d.fnRecordsDisplay(),g=-1===c,a=g?0:Math.ceil(a/c),c=g?1:Math.ceil(w/c),w=b(a,c),h,g=0;for(h=p.p.length;g<h;g++)Qa(d,"pageButton")(d,p.p[g],g,w,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:ka(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 W(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?I(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?I(f):null,width:e?I(e):null}).append(a));m&&b.append(c("<div/>",{"class":p.sScrollFoot}).css({overflow:"hidden",border:0,
width:e?e?I(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,r=c(d.nScrollFoot).children("div"),u=r.children("table"),D=c(d.nTHead),L=c(d.nTable),H=L[0],R=H.style,G=d.nTFoot?c(d.nTFoot):null,x=d.oBrowser,B=x.bScrollOversize,ja,J,M,z,da,A=[],na=[],ca=[],ea,ma=function(d){d=d.style;d.paddingTop="0";d.paddingBottom="0";d.borderTopWidth="0";d.borderBottomWidth="0";d.height=0};L.children("thead, tfoot").remove();da=D.clone().prependTo(L);ja=D.find("tr");M=da.find("tr");
da.find("th, td").removeAttr("tabindex");G&&(z=G.clone().prependTo(L),J=G.find("tr"),z=z.find("tr"));b||(q.width="100%",g[0].style.width="100%");c.each(oa(d,da),function(a,c){ea=v(d,a);c.style.width=d.aoColumns[ea].sWidth});G&&aa(function(d){d.style.width=""},z);a.bCollapse&&""!==f&&(q.height=k[0].offsetHeight+D[0].offsetHeight+"px");g=L.outerWidth();""===b?(R.width="100%",B&&(L.find("tbody").height()>l.offsetHeight||"scroll"==k.css("overflow-y"))&&(R.width=I(L.outerWidth()-p))):""!==e?R.width=I(e):
g==k.width()&&k.height()<L.height()?(R.width=I(g-p),L.outerWidth()>g-p&&(R.width=I(g))):R.width=I(g);g=L.outerWidth();aa(ma,M);aa(function(d){ca.push(d.innerHTML);A.push(I(c(d).css("width")))},M);aa(function(d,a){d.style.width=A[a]},ja);c(M).height(0);G&&(aa(ma,z),aa(function(d){na.push(I(c(d).css("width")))},z),aa(function(d,a){d.style.width=na[a]},J),c(z).height(0));aa(function(d,a){d.innerHTML='<div class="dataTables_sizing" style="height:0;overflow:hidden;">'+ca[a]+"</div>";d.style.width=A[a]},
M);G&&aa(function(d,a){d.innerHTML="";d.style.width=na[a]},z);L.outerWidth()<g?(J=l.scrollHeight>l.offsetHeight||"scroll"==k.css("overflow-y")?g+p:g,B&&(l.scrollHeight>l.offsetHeight||"scroll"==k.css("overflow-y"))&&(R.width=I(J-p)),""!==b&&""===e||ka(d,1,"Possible column misalignment",6)):J="100%";q.width=I(J);h.width=I(J);G&&(d.nScrollFoot.style.width=I(J));!f&&B&&(q.height=I(H.offsetHeight+p));f&&a.bCollapse&&(q.height=I(f),a=b&&H.offsetWidth>l.offsetWidth?p:0,H.offsetHeight<l.offsetHeight&&(q.height=
I(H.offsetHeight+a)));a=L.outerWidth();m[0].style.width=I(a);n.width=I(a);m=L.height()>l.clientHeight||"scroll"==k.css("overflow-y");x="padding"+(x.bScrollbarLeft?"Left":"Right");n[x]=m?p+"px":"0px";G&&(u[0].style.width=I(a),r[0].style.width=I(a),r[0].style[x]=m?p+"px":"0px");k.scroll();!d.bSorted&&!d.bFiltered||d._drawHold||(l.scrollTop=0)}function aa(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 La(d){var b=d.nTable,e=d.aoColumns,f=d.oScroll,g=f.sY,p=f.sX,h=f.sXInner,l=e.length,f=D(d,"bVisible"),n=c("th",d.nTHead),m=b.getAttribute("width"),k=b.parentNode,q=!1,y,v;for(y=0;y<f.length;y++)v=e[f[y]],null!==v.sWidth&&(v.sWidth=yb(v.sWidthOrig,k),q=!0);if(q||p||g||l!=r(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 L=l.find("tbody tr"),n=oa(d,l.find("thead")[0]);for(y=0;y<f.length;y++)v=e[f[y]],n[y].style.width=null!==v.sWidthOrig&&""!==v.sWidthOrig?I(v.sWidthOrig):"";if(d.aoData.length)for(y=0;y<f.length;y++)q=f[y],v=e[q],c(zb(d,q)).clone(!1).append(v.sContentPadding).appendTo(L);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(y=h=0;y<f.length;y++)v=e[f[y]],g=c(n[y]).outerWidth(),h+=null===
v.sWidthOrig?g:parseInt(v.sWidth,10)+g-c(n[y]).width();l.width(I(h));b.style.width=I(h)}for(y=0;y<f.length;y++)if(v=e[f[y]],g=c(n[y]).width())v.sWidth=I(g);b.style.width=I(l.css("width"));l.remove()}else for(y=0;y<l;y++)e[y].sWidth=I(n.eq(y).width());m&&(b.style.width=I(m));!m&&!p||d._reszEvt||(c(a).bind("resize.DT-"+d.sInstance,Ra(function(){u(d)})),d._reszEvt=!0)}function Ra(d,a){var c=a||200,b,e;return function(){var a=this,w=+new Date,f=arguments;b&&w<b+c?(clearTimeout(e),e=setTimeout(function(){b=
k;d.apply(a,f)},c)):b?(b=w,d.apply(a,f)):b=w}}function yb(d,a){if(!d)return 0;var b=c("<div/>").css("width",I(d)).appendTo(a||A.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=I(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(J(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=J(d,p,a,"display")+"",
c=c.replace(Sb,""),c.length>b&&(b=c.length,e=p);return e}function I(d){return null===d?"0px":"number"==typeof d?0>d?"0px":d+"px":d.match(/\d$/)?d+"px":d}function Cb(){if(!z.__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();z.__scrollbarWidth=
b-d}return z.__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:z.ext.type.order[h+"-pre"]});return e}function jb(d){var a,
c,b=[],e=z.ext.type.order,p=d.aoData,f=0,g,h=d.aiDisplayMaster,l;H(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"!=V(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,w,f,C=l.length,g=p[d]._aSortData,h=p[a]._aSortData;for(w=0;w<C;w++)if(f=l[w],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,w,f,C,g=l.length,h=p[d]._aSortData,t=p[a]._aSortData;
for(f=0;f<g;f++)if(C=l[f],c=h[C.col],w=t[C.col],C=e[C.type+"-"+C.dir]||e["string-"+C.dir],c=C(c,w),0!==c)return c;c=b[d];w=b[a];return c<w?-1:c>w?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,Y(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?(W(d,!0),setTimeout(function(){Xa(d,c,a.shiftKey,b);"ssp"!==V(d)&&W(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(Y(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(Y(d.aoData,"anCells",g)).addClass(b+(2>f?f+1:3))}d.aLastSort=e}function Db(d,a){var c=d.aoColumns[a],b=z.ext.order[c.sSortDataType],e;b&&(e=b.call(d.oInstance,d,a,x(d,a)));for(var f,g=z.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]:J(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=z.settings;d=c.inArray(d,Y(a,"nTable"));
return-1!==d?a[d]:null}function ka(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 Z(d,a,b,e){c.isArray(b)?c.each(b,function(b,e){c.isArray(e)?Z(d,a,e[0],e[1]):Z(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 T(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=z.ext.renderer[a];return c.isPlainObject(b)&&b[a]?e[b[a]]||e._:"string"===typeof b?e[b]||e._:e._}function V(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){S.type.order[a+d+"-pre"]=c})}function Ib(d){return function(){var a=[Ha(this[z.ext.iApiIndex])].concat(Array.prototype.slice.call(arguments));return z.ext.internal[d].apply(this,
a)}}var z,S,K,E,P,ab={},Jb=/[\r\n]/g,Ja=/<.*?>/g,Tb=/^[\w\+\-]/,Ub=/[\w\+\-]$/,Qb=RegExp("(\\/|\\.|\\*|\\+|\\?|\\||\\(|\\)|\\[|\\]|\\{|\\}|\\\\|\\$|\\^|\\-)","g"),$a=/[',$\u00a3\u20ac\u00a5%\u2009\u202F]/g,ba=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 ba(d)||!isNaN(parseFloat(d))&&isFinite(d)},Mb=function(d,a,c){return ba(d)?!0:ba(d)||"string"===typeof d?bb(d.replace(Ja,""),a,c)?!0:null:null},Y=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},U=function(d,a,c){d[a]!==k&&(d[c]=d[a])},sa=/\[.*?\]$/,la=/\(\)$/,Da=c("<div>")[0],Rb=Da.textContent!==k,Sb=/<.*?>/g;z=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 K(Ha(this[S.iApiIndex])):new K(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[S.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=S.fnVersionCheck;var a=this,b=d===k,g=this.length;b&&(d={});this.oApi=this.internal=S.internal;for(var r in z.ext.internal)r&&(this[r]=Ib(r));this.each(function(){var p={},t=1<g?Gb(p,d,!0):d,r=0,u,X=this.getAttribute("id"),p=!1,v=z.defaults;if("table"!=this.nodeName.toLowerCase())ka(null,0,"Non-table node initialisation ("+this.nodeName+")",2);else{e(v);f(v.column);h(v,v,!0);h(v.column,v.column,!0);h(v,t);var D=z.settings,r=0;for(u=D.length;r<u;r++){if(D[r].nTable==
this){u=t.bRetrieve!==k?t.bRetrieve:v.bRetrieve;if(b||u)return D[r].oInstance;if(t.bDestroy!==k?t.bDestroy:v.bDestroy){D[r].oInstance.fnDestroy();break}else{ka(D[r],0,"Cannot reinitialise DataTable",3);return}}if(D[r].sTableId==this.id){D.splice(r,1);break}}if(null===X||""===X)this.id=X="DataTables_Table_"+z.ext._unique++;var y=c.extend(!0,{},z.models.oSettings,{nTable:this,oApi:a.internal,oInit:t,sDestroyWidth:c(this)[0].style.width,sInstance:X,sTableId:X});D.push(y);y.oInstance=1===a.length?a:c(this).dataTable();
e(t);t.oLanguage&&m(t.oLanguage);t.aLengthMenu&&!t.iDisplayLength&&(t.iDisplayLength=c.isArray(t.aLengthMenu[0])?t.aLengthMenu[0][0]:t.aLengthMenu[0]);t=Gb(c.extend(!0,{},v),t);Z(y.oFeatures,t,"bPaginate bLengthChange bFilter bSort bSortMulti bInfo bProcessing bAutoWidth bSortClasses bServerSide bDeferRender".split(" "));Z(y,t,["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"]]);Z(y.oScroll,t,[["sScrollX","sX"],["sScrollXInner","sXInner"],["sScrollY","sY"],["bScrollCollapse","bCollapse"]]);Z(y.oLanguage,t,"fnInfoCallback");T(y,"aoDrawCallback",t.fnDrawCallback,"user");T(y,"aoServerParams",t.fnServerParams,"user");T(y,"aoStateSaveParams",
t.fnStateSaveParams,"user");T(y,"aoStateLoadParams",t.fnStateLoadParams,"user");T(y,"aoStateLoaded",t.fnStateLoaded,"user");T(y,"aoRowCallback",t.fnRowCallback,"user");T(y,"aoRowCreatedCallback",t.fnCreatedRow,"user");T(y,"aoHeaderCallback",t.fnHeaderCallback,"user");T(y,"aoFooterCallback",t.fnFooterCallback,"user");T(y,"aoInitComplete",t.fnInitComplete,"user");T(y,"aoPreDrawCallback",t.fnPreDrawCallback,"user");X=y.oClasses;t.bJQueryUI?(c.extend(X,z.ext.oJUIClasses,t.oClasses),t.sDom===v.sDom&&"lfrtip"===
v.sDom&&(y.sDom='<"H"lfr>t<"F"ip>'),y.renderer)?c.isPlainObject(y.renderer)&&!y.renderer.header&&(y.renderer.header="jqueryui"):y.renderer="jqueryui":c.extend(X,z.ext.classes,t.oClasses);c(this).addClass(X.sTable);if(""!==y.oScroll.sX||""!==y.oScroll.sY)y.oScroll.iBarWidth=Cb();!0===y.oScroll.sX&&(y.oScroll.sX="100%");y.iInitDisplayStart===k&&(y.iInitDisplayStart=t.iDisplayStart,y._iDisplayStart=t.iDisplayStart);null!==t.iDeferLoading&&(y.bDeferLoading=!0,r=c.isArray(t.iDeferLoading),y._iRecordsDisplay=
r?t.iDeferLoading[0]:t.iDeferLoading,y._iRecordsTotal=r?t.iDeferLoading[1]:t.iDeferLoading);""!==t.oLanguage.sUrl?(y.oLanguage.sUrl=t.oLanguage.sUrl,c.getJSON(y.oLanguage.sUrl,null,function(d){m(d);h(v.oLanguage,d);c.extend(!0,y.oLanguage,t.oLanguage,d);Ea(y)}),p=!0):c.extend(!0,y.oLanguage,t.oLanguage);null===t.asStripeClasses&&(y.asStripeClasses=[X.sStripeOdd,X.sStripeEven]);var r=y.asStripeClasses,L=c("tbody tr:eq(0)",this);-1!==c.inArray(!0,c.map(r,function(d,a){return L.hasClass(d)}))&&(c("tbody tr",
this).removeClass(r.join(" ")),y.asDestroyStripes=r.slice());var D=[],H,r=this.getElementsByTagName("thead");0!==r.length&&(N(y.aoHeader,r[0]),D=oa(y));if(null===t.aoColumns)for(H=[],r=0,u=D.length;r<u;r++)H.push(null);else H=t.aoColumns;r=0;for(u=H.length;r<u;r++)q(y,D?D[r]:null);B(y,t.aoColumnDefs,H,function(d,a){l(y,d,a)});if(L.length){var R=function(d,a){return d.getAttribute("data-"+a)?a:null};c.each(wa(y,L[0]).cells,function(d,a){var c=y.aoColumns[d];try{if(c.mData===d){var b=R(a,"sort")||R(a,
"order"),e=R(a,"filter")||R(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(y,d)}}catch(f){console.error(f)}})}var x=y.oFeatures;t.bStateSave&&(x.bStateSave=!0,Fb(y,t),T(y,"aoDrawCallback",Ga,"state_save"));if(t.aaSorting===k)for(D=y.aaSorting,r=0,u=D.length;r<u;r++)D[r][1]=y.aoColumns[r].asSorting[0];Fa(y);x.bSort&&T(y,"aoDrawCallback",function(){if(y.bSorted){var d=pa(y),a={};c.each(d,function(d,
c){a[c.src]=c.dir});O(y,null,"order",[y,d,a]);Eb(y)}});T(y,"aoDrawCallback",function(){(y.bSorted||"ssp"===V(y)||x.bDeferRender)&&Fa(y)},"sc");n(y);r=c(this).children("caption").each(function(){this._captionSide=c(this).css("caption-side")});u=c(this).children("thead");0===u.length&&(u=c("<thead/>").appendTo(this));y.nTHead=u[0];u=c(this).children("tbody");0===u.length&&(u=c("<tbody/>").appendTo(this));y.nTBody=u[0];u=c(this).children("tfoot");0===u.length&&0<r.length&&(""!==y.oScroll.sX||""!==y.oScroll.sY)&&
(u=c("<tfoot/>").appendTo(this));0===u.length||0===u.children().length?c(this).addClass(X.sNoFooter):0<u.length&&(y.nTFoot=u[0],N(y.aoFooter,y.nTFoot));if(t.aaData)for(r=0;r<t.aaData.length;r++)G(y,t.aaData[r]);else(y.bDeferLoading||"dom"==V(y))&&M(y,c(y.nTBody).children("tr"));y.aiDisplay=y.aiDisplayMaster.slice();y.bInitialised=!0;!1===p&&Ea(y)}});a=null;return this};var Nb=[],Q=Array.prototype,Vb=function(d){var a,b,e=z.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()};K=function(d,a){if(!this instanceof K)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};K.extend(this,this,Nb)};z.Api=K;K.prototype={concat:Q.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 K(a[d],this[d]):null},filter:function(d){var a=[];if(Q.filter)a=Q.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 K(this.context,a)},flatten:function(){var d=[];return new K(this.context,d.concat.apply(d,this.toArray()))},join:Q.join,indexOf:Q.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,r,q=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(r=this[f],"column-rows"===a&&(m=cb(n[f],q.opts)),h=0,l=r.length;h<l;h++)e=r[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 K(n,d?b.concat.apply([],b):b),a=d.selector,a.rows=q.rows,a.cols=q.cols,a.opts=q.opts,d):this},lastIndexOf:Q.lastIndexOf||function(d,a){return this.indexOf.apply(this.toArray.reverse(),arguments)},length:0,map:function(d){var a=[];if(Q.map)a=Q.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 K(this.context,a)},pluck:function(d){return this.map(function(a){return a[d]})},pop:Q.pop,push:Q.push,reduce:Q.reduce||function(d,a){return g(this,d,a,0,this.length,1)},reduceRight:Q.reduceRight||function(d,a){return g(this,d,a,this.length-1,-1,-1)},reverse:Q.reverse,selector:null,shift:Q.shift,sort:Q.sort,splice:Q.splice,toArray:function(){return Q.slice.call(this)},to$:function(){return c(this)},toJQuery:function(){return c(this)},
unique:function(){return new K(this.context,Oa(this))},unshift:Q.unshift};K.extend=function(d,a,b){if(a&&(a instanceof K||a.__dt_wrapper)){var e,f,g,h=function(d,a,c){return function(){var b=a.apply(d,arguments);K.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,K.extend(d,a[g.name],g.propExt)}};K.register=E=function(d,a){if(c.isArray(d))for(var b=0,e=d.length;b<e;b++)K.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}};K.registerPlural=P=function(d,a,b){K.register(d,b);K.register(a,function(){var d=b.apply(this,arguments);return d===this?this:d instanceof K?d.length?c.isArray(d[0])?new K(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()};E("tables()",function(d){return d?new K(Wb(d,this.context)):this});E("table()",function(d){d=this.tables(d);var a=d.context;return a.length?new K(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})});E("draw()",function(d){return this.iterator("table",function(a){ha(a,!1===d)})});E("page()",function(d){return d===k?
this.page.info().page:this.iterator("table",function(a){Wa(a,d)})});E("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}});E("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"==V(d)?ha(d,a):(W(d,!0),ia(d,[],function(c){ea(d);c=Ba(d,c);for(var b=0,e=c.length;b<e;b++)G(d,c[b]);ha(d,a);W(d,!1)}));if(c){var b=new K(d);b.one("draw",function(){c(b.ajax.json())})}};E("ajax.json()",function(){var d=this.context;if(0<d.length)return d[0].json});E("ajax.params()",function(){var d=this.context;if(0<d.length)return d[0].oAjaxData});E("ajax.reload()",function(d,a){return this.iterator("table",function(c){Ob(c,!1===a,d)})});E("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})});E("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"==V(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()})};E("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});E("rows().nodes()",function(){return this.iterator("row",function(a,c){return a.aoData[c].nTr||k})});E("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){xa(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);R(b.aiDisplayMaster,e);R(b.aiDisplay,e);R(a[f],e,!1);Va(b)})});E("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(M(c,b)[0]):g.push(G(c,b));return g}),b=this.rows(-1);b.pop();b.push.apply(b,c.toArray());return b});
E("row()",function(a,c){return fb(this.rows(a,c))});E("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;xa(c[0],this[0],"data");return this});E("row().node()",function(){var a=this.context;return a.length&&this.length?a[0].aoData[this[0]].nTr||null:null});E("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()?
M(c,a)[0]:G(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=r(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 K(a),b=a.aoData;c.off("draw.dt.DT_details column-visibility.dt.DT_details destroy.dt.DT_details");0<Y(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=r(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])}))};E("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});E(["row().child.show()","row().child().show()"],function(a){Pb(this,!0);return this});E(["row().child.hide()","row().child().hide()"],function(){Pb(this,!1);return this});E(["row().child.remove()","row().child().remove()"],function(){gb(this);return this});E("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=Y(f,"sName"),h=Y(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]]):[v(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()})};E("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(J(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,r;if(a===k)g=g.bVisible;else{if(g.bVisible!==a){if(a){var q=c.inArray(!0,Y(h,"bVisible"),f+1);n=0;for(m=l.length;n<m;n++)r=l[n].nTr,h=l[n].anCells,r&&r.insertBefore(h[f],h[q]||null)}else c(Y(e.aoData,"anCells",f)).detach();g.bVisible=a;ta(e,e.aoHeader);ta(e,e.aoFooter);if(b===k||b)u(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?x(c,b):b})});E("columns.adjust()",function(){return this.iterator("table",function(a){u(a)})});E("column.index()",function(a,c){if(0!==this.context.length){var b=this.context[0];if("fromVisible"===a||"toData"===a)return v(b,c);if("fromData"===a||"toVisible"===a)return x(b,c)}});E("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,r,q,u;return db(b,function(a){if(null===a||a===k){m=[];r=0;for(q=g.length;r<q;r++)for(l=g[r],u=0;u<n;u++)m.push({row:l,column:u});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()})};E("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,r,q=this.iterator("table",function(a,d){h=[];l=0;for(n=g[d].length;l<n;l++)for(m=0,r=f[d].length;m<r;m++)h.push({row:g[d][l],column:f[d][m]});return h});c.extend(q.selector,{cols:b,rows:a,opts:e});return q});P("cells().nodes()","cell().node()",function(){return this.iterator("cell",function(a,c,b){return a.aoData[c].anCells[b]})});E("cells().data()",function(){return this.iterator("cell",function(a,c,b){return J(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:x(a,b)}})});E(["cells().invalidate()","cell().invalidate()"],function(a){var c=this.selector;this.rows(c.rows,c.opts).invalidate(a);return this});E("cell()",function(a,c,b){return fb(this.cells(a,c,
b))});E("cell().data()",function(a){var c=this.context,b=this[0];if(a===k)return c.length&&b.length?J(c[0],b[0].row,b[0].column):k;L(c[0],b[0].row,b[0].column,a);xa(c[0],b[0].row,"data",b[0].column);return this});E("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()})});E("order.listener()",function(a,c,b){return this.iterator("table",
function(e){Pa(e,a,c,b)})});E(["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})});E("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))})});E("state()",function(){return this.context.length?this.context[0].oSavedState:null});E("state.clear()",function(){return this.iterator("table",function(a){a.fnStateSaveCallback.call(a.oInstance,a,{})})});E("state.loaded()",
function(){return this.context.length?this.context[0].oLoadedState:null});E("state.save()",function(){return this.iterator("table",function(a){Ga(a)})});z.versionCheck=z.fnVersionCheck=function(a){var c=z.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};z.isDataTable=z.fnIsDataTable=function(a){var b=c(a).get(0),e=!1;c.each(z.settings,function(a,d){if(d.nTable===b||d.nScrollHead===b||d.nScrollFoot===b)e=
!0});return e};z.tables=z.fnTables=function(a){return jQuery.map(z.settings,function(b){if(!a||a&&c(b.nTable).is(":visible"))return b.nTable})};z.camelToHungarian=h;E("$()",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){E(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})});E("clear()",
function(){return this.iterator("table",function(a){ea(a)})});E("settings()",function(){return new K(this.context,this.context)});E("data()",function(){return this.iterator("table",function(a){return Y(a.aoData,"_aData")}).flatten()});E("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),r=c(b.nTableWrapper),k=c.map(b.aoData,function(a){return a.nTr}),q;b.bDestroying=!0;O(b,
"aoDestroyCallback","destroy",[b]);d||(new K(b)).columns().visible(!0);r.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();r.detach();b.aaSorting=[];b.aaSortingFixed=[];Fa(b);c(k).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(k);m.css("width",b.sDestroyWidth).removeClass(f.sTable);(q=b.asDestroyStripes.length)&&h.children().each(function(a){c(this).addClass(b.asDestroyStripes[a%q])});e=c.inArray(b,z.settings);-1!==e&&z.settings.splice(e,1)})});z.version="1.10.2";z.settings=[];z.models=
{};z.models.oSearch={bCaseInsensitive:!0,sSearch:"",bRegex:!1,bSmart:!0};z.models.oRow={nTr:null,anCells:null,_aData:[],_aSortData:null,_aFilterData:null,_sFilterRow:null,_sRowStripe:"",src:null};z.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};z.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({},z.models.oSearch),sAjaxDataProp:"data",sAjaxSource:null,sDom:"lfrtip",sPaginationType:"simple_numbers",
sScrollX:"",sScrollXInner:"",sScrollY:"",sServerMethod:"GET",renderer:null};b(z.defaults);z.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(z.defaults.column);z.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"==V(this)?1*this._iRecordsTotal:this.aiDisplayMaster.length},fnRecordsDisplay:function(){return"ssp"==V(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:{}};z.ext=S={classes:{},errMode:"alert",feature:[],search:[],internal:{},legacy:{ajax:null},pager:{},renderer:{pageButton:{},header:{}},order:{},type:{detect:[],search:{},order:{}},_unique:0,fnVersionCheck:z.fnVersionCheck,
iApiIndex:0,oJUIClasses:{},sVersion:z.version};c.extend(S,{afnFiltering:S.search,aTypes:S.type.detect,ofnSearch:S.type.search,oSort:S.type.order,afnSortData:S.order,aoFeatures:S.feature,oApi:S.internal,oStdClasses:S.classes,oPagination:S.pager});c.extend(z.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(z.ext.oJUIClasses,z.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=z.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,z.ext.renderer,{pageButton:{_:function(a,b,e,f,g,h){var l=a.oClasses,n=a.oLanguage.oPaginate,m,r,k=0,q=function(b,f){var u,v,D,w,L=function(c){Wa(a,c.data.action,!0)};u=0;for(v=f.length;u<v;u++)if(w=f[u],c.isArray(w))D=c("<"+(w.DT_el||"div")+"/>").appendTo(b),q(D,w);else{r=m="";switch(w){case "ellipsis":b.append("<span>&hellip;</span>");break;case "first":m=n.sFirst;r=w+(0<g?"":" "+l.sPageButtonDisabled);break;case "previous":m=n.sPrevious;r=w+(0<g?"":" "+
l.sPageButtonDisabled);break;case "next":m=n.sNext;r=w+(g<h-1?"":" "+l.sPageButtonDisabled);break;case "last":m=n.sLast;r=w+(g<h-1?"":" "+l.sPageButtonDisabled);break;default:m=w+1,r=g===w?l.sPageButtonActive:""}m&&(D=c("<a>",{"class":l.sPageButton+" "+r,"aria-controls":a.sTableId,"data-dt-idx":k,tabindex:a.iTabIndex,id:0===e&&"string"===typeof w?a.sTableId+"_"+w:null}).html(m).appendTo(b),Ya(D,{action:w},L),k++)}};try{var u=c(A.activeElement).data("dt-idx");q(c(b).empty(),f);null!==u&&c(b).find("[data-dt-idx="+
u+"]").focus()}catch(v){}}}});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(S.type.order,{"date-pre":function(a){return Date.parse(a)||0},"html-pre":function(a){return ba(a)?"":a.replace?a.replace(/<.*?>/g,"").toLowerCase():a+""},"string-pre":function(a){return ba(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(z.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)||ba(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 ba(a)||"string"===typeof a&&-1!==a.indexOf("<")?"html":null}]);c.extend(z.ext.type.search,{html:function(a){return ba(a)?a:"string"===typeof a?a.replace(Jb," ").replace(Ja,""):""},string:function(a){return ba(a)?a:"string"===typeof a?a.replace(Jb," "):a}});c.extend(!0,z.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))})}}});z.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(z.ext.internal,{_fnExternApiFunc:Ib,_fnBuildAjax:ia,_fnAjaxUpdate:ya,_fnAjaxParameters:za,_fnAjaxUpdateDraw:Aa,_fnAjaxDataSrc:Ba,_fnAddColumn:q,_fnColumnOptions:l,_fnAdjustColumnSizing:u,
_fnVisibleToColumnIndex:v,_fnColumnIndexToVisible:x,_fnVisbleColumns:r,_fnGetColumns:D,_fnColumnTypes:H,_fnApplyColumnDefs:B,_fnHungarianMap:b,_fnCamelToHungarian:h,_fnLanguageCompat:m,_fnBrowserDetect:n,_fnAddData:G,_fnAddTr:M,_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:J,_fnSetCellData:L,_fnSplitObjNotation:da,_fnGetObjectDataFn:ca,_fnSetObjectDataFn:ja,_fnGetDataMaster:ma,
_fnClearTable:ea,_fnDeleteIndex:R,_fnInvalidateRow:xa,_fnGetRowElements:wa,_fnCreateTr:Ma,_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:W,_fnFeatureHtmlTable:nb,_fnScrollDraw:ra,_fnApplyToChildren:aa,_fnCalculateColumnWidths:La,_fnThrottle:Ra,_fnConvertToWidth:yb,_fnScrollingWidthAdjust:Ab,_fnGetWidestNode:zb,_fnGetMaxLenString:Bb,_fnStringToCss:I,_fnScrollBarWidth:Cb,_fnSortFlatten:pa,_fnSort:jb,_fnSortAria:Eb,_fnSortListener:Xa,_fnSortAttachListener:Pa,_fnSortingClasses:Fa,_fnSortData:Db,_fnSaveState:Ga,_fnLoadState:Fb,_fnSettingsFromNode:Ha,_fnLog:ka,_fnMap:Z,_fnBindAction:Ya,
_fnCallbackReg:T,_fnCallbackFire:O,_fnLengthOverflow:Va,_fnRenderer:Qa,_fnDataSource:V,_fnRowAttributes:Na,_fnCalculateEnd:function(){}});c.fn.dataTable=z;c.fn.dataTableSettings=z.settings;c.fn.dataTableExt=z.ext;c.fn.DataTable=function(a){return c(this).dataTable(a).api()};c.each(z,function(a,b){c.fn.DataTable[a]=b});return c.fn.dataTable})})(window,document);
function naturalSort(a,A){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(A).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,A){return naturalSort(a,A)};jQuery.fn.dataTableExt.oSort["string-desc"]=function(a,A){return-1*naturalSort(a,A)};
(function(a){"function"===typeof define&&define.amd?define(["jquery"],a):a("undefined"!=typeof jQuery?jQuery:window.Zepto)})(function(a){function A(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(G).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=u.attr2("target"),
n=u.attr2("action"),m=u.attr("enctype")||u.attr("encoding")||"multipart/form-data";l.setAttribute("target",D);k&&!/post/i.test(k)||l.setAttribute("method","POST");n!=r.url&&l.setAttribute("action",r.url);r.skipEncodingOverride||k&&!/post/i.test(k)||u.attr({encoding:"multipart/form-data",enctype:"multipart/form-data"});r.timeout&&(M=setTimeout(function(){J=!0;h(1)},r.timeout));var v=[];try{if(r.extraData)for(var B in r.extraData)r.extraData.hasOwnProperty(B)&&(a.isPlainObject(r.extraData[B])&&r.extraData[B].hasOwnProperty("name")&&
r.extraData[B].hasOwnProperty("value")?v.push(a('<input type="hidden" name="'+r.extraData[B].name+'">').val(r.extraData[B].value).appendTo(l)[0]):v.push(a('<input type="hidden" name="'+B+'">').val(r.extraData[B]).appendTo(l)[0]));r.iframeTarget||H.appendTo("body");G.attachEvent?G.attachEvent("onload",h):G.addEventListener("load",h,!1);setTimeout(b,15);try{l.submit()}catch(x){document.createElement("form").submit.apply(l)}}finally{l.setAttribute("action",n),l.setAttribute("enctype",m),e?l.setAttribute("target",
e):u.removeAttr("target"),a(v).remove()}}function h(b){if(!B.aborted&&!ia)if(N=f(G),N||(c("cannot access response document"),b=2),1===b&&B)B.abort("timeout"),A.reject(B,"timeout");else if(2==b&&B)B.abort("server abort"),A.reject(B,"error","server abort");else if(N&&N.location.href!=r.iframeSrc||J){G.detachEvent?G.detachEvent("onload",h):G.removeEventListener("load",h,!1);b="success";var e;try{if(J)throw"timeout";var g="xml"==r.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;B.responseText=l?l.innerHTML:null;B.responseXML=N.XMLDocument?N.XMLDocument:N;g&&(r.dataType="xml");B.getResponseHeader=function(a){return{"content-type":r.dataType}[a.toLowerCase()]};l&&(B.status=Number(l.getAttribute("status"))||B.status,B.statusText=l.getAttribute("statusText")||B.statusText);var n=(r.dataType||"").toLowerCase(),m=/(json|script|text)/.test(n);
if(m||r.textarea){var k=N.getElementsByTagName("textarea")[0];if(k)B.responseText=k.value,B.status=Number(k.getAttribute("status"))||B.status,B.statusText=k.getAttribute("statusText")||B.statusText;else if(m){var q=N.getElementsByTagName("pre")[0],u=N.getElementsByTagName("body")[0];q?B.responseText=q.textContent?q.textContent:q.innerText:u&&(B.responseText=u.textContent?u.textContent:u.innerText)}}else"xml"==n&&!B.responseXML&&B.responseText&&(B.responseXML=ya(B.responseText));try{va=Aa(B,n,r)}catch(D){b=
"parsererror",B.error=e=D||b}}catch(x){c("error caught: ",x),b="error",B.error=e=x||b}B.aborted&&(c("upload aborted"),b=null);B.status&&(b=200<=B.status&&300>B.status||304===B.status?"success":"error");"success"===b?(r.success&&r.success.call(r.context,va,"success",B),A.resolve(B.responseText,"success",B),v&&a.event.trigger("ajaxSuccess",[B,r])):b&&(void 0===e&&(e=B.statusText),r.error&&r.error.call(r.context,B,b,e),A.reject(B,"error",e),v&&a.event.trigger("ajaxError",[B,r,e]));v&&a.event.trigger("ajaxComplete",
[B,r]);v&&!--a.active&&a.event.trigger("ajaxStop");r.complete&&r.complete.call(r.context,B,b);ia=!0;r.timeout&&clearTimeout(M);setTimeout(function(){r.iframeTarget?H.attr("src",r.iframeSrc):H.remove();B.responseXML=null},100)}}var l=u[0],n,r,v,D,H,G,B,J,M,A=a.Deferred();A.abort=function(a){B.abort(a)};if(b)for(n=0;n<x.length;n++)b=a(x[n]),m?b.prop("disabled",!1):b.removeAttr("disabled");r=a.extend(!0,{},a.ajaxSettings,e);r.context=r.context||r;D="jqFormIO"+(new Date).getTime();r.iframeTarget?(H=a(r.iframeTarget),
(n=H.attr2("name"))?D=n:H.attr2("name",D)):(H=a('<iframe name="'+D+'" src="'+r.iframeSrc+'" />'),H.css({position:"absolute",top:"-1000px",left:"-1000px"}));G=H[0];B={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{G.contentWindow.document.execCommand&&G.contentWindow.document.execCommand("Stop")}catch(f){}H.attr("src",
r.iframeSrc);B.error=e;r.error&&r.error.call(r.context,B,e,b);v&&a.event.trigger("ajaxError",[B,r,e]);r.complete&&r.complete.call(r.context,B,e)}};(v=r.global)&&0===a.active++&&a.event.trigger("ajaxStart");v&&a.event.trigger("ajaxSend",[B,r]);if(r.beforeSend&&!1===r.beforeSend.call(r.context,B,r))return r.global&&a.active--,A.reject(),A;if(B.aborted)return A.reject(),A;(b=l.clk)&&(n=b.name)&&!b.disabled&&(r.extraData=r.extraData||{},r.extraData[n]=b.value,"image"==b.type&&(r.extraData[n+".x"]=l.clk_x,
r.extraData[n+".y"]=l.clk_y));b=a("meta[name=csrf-token]").attr("content");(n=a("meta[name=csrf-param]").attr("content"))&&b&&(r.extraData=r.extraData||{},r.extraData[n]=b);r.forceSync?g():setTimeout(g,10);var va,N,oa=50,ia,ya=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},za=a.parseJSON||function(a){return window.eval("("+
a+")")},Aa=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=za(c):("script"===b||!b&&0<=f.indexOf("javascript"))&&a.globalEval(c));return c};return A}if(!this.length)return c("ajaxSubmit: skipping submit process - no element selected"),this;
var k,l,u=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 v=e.traditional;void 0===v&&(v=a.ajaxSettings.traditional);var x=[],r,D=this.formToArray(e.semantic,x);e.data&&(e.extraData=e.data,r=a.param(e.data,v));if(e.beforeSubmit&&!1===e.beforeSubmit(D,this,e))return c("ajaxSubmit: submit aborted via beforeSubmit callback"),this;this.trigger("form-submit-validate",[D,this,e,l]);if(l.veto)return c("ajaxSubmit: submit vetoed via form-submit-validate trigger"),
this;l=a.param(D,v);r&&(l=l?l+"&"+r:r);"GET"==e.type.toUpperCase()?(e.url+=(0<=e.url.indexOf("?")?"&":"?")+l,e.data=null):e.data=l;var H=[];e.resetForm&&H.push(function(){u.resetForm()});e.clearForm&&H.push(function(){u.clearForm(e.includeHidden)});if(!e.dataType&&e.target){var B=e.success||function(){};H.push(function(c){var b=e.replaceTarget?"replaceWith":"html";a(e.target)[b](c).each(B,arguments)})}else e.success&&H.push(e.success);e.success=function(a,c,b){for(var f=e.context||this,g=0,h=H.length;g<
h;g++)H[g].apply(f,[a,c,b||u,u])};if(e.error){var G=e.error;e.error=function(a,c,b){G.apply(e.context||this,[a,c,b,u])}}if(e.complete){var M=e.complete;e.complete=function(a,c){M.apply(e.context||this,[a,c,u])}}r=0<a("input[type=file]:enabled",this).filter(function(){return""!==a(this).val()}).length;l="multipart/form-data"==u.attr("enctype")||"multipart/form-data"==u.attr("encoding");v=b&&h;c("fileAPI :"+v);var J;!1!==e.iframe&&(e.iframe||(r||l)&&!v)?e.closeKeepAlive?a.get(e.closeKeepAlive,function(){J=
g(D)}):J=g(D):J=(r||l)&&v?n(D):a.ajax(e);u.removeData("jqxhr").data("jqxhr",J);for(r=0;r<x.length;r++)x[r]=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,A).off("click.form-plugin",this.selector,k).on("submit.form-plugin",this.selector,b,A).on("click.form-plugin",this.selector,b,k),this):this.ajaxFormUnbind().bind("submit.form-plugin",b,A).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,v,x,r,D;k=0;for(D=l.length;k<D;k++)if(r=l[k],(m=r.name)&&!r.disabled)if(c&&g.clk&&"image"==r.type)g.clk==r&&(h.push({name:m,value:a(r).val(),type:r.type}),h.push({name:m+".x",value:g.clk_x},{name:m+".y",value:g.clk_y}));else if((x=a.fieldValue(r,!0))&&x.constructor==Array)for(f&&f.push(r),v=0,r=x.length;v<r;v++)h.push({name:m,
value:x[v]});else if(b&&"file"==r.type)if(f&&f.push(r),x=r.files,x.length)for(v=0;v<x.length;v++)h.push({name:m,value:x[v],type:r.type});else h.push({name:m,value:"",type:r.type});else null!==x&&"undefined"!=typeof x&&(f&&f.push(r),h.push({name:m,value:x,type:r.type,required:r.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 v=m[l];if(v.selected){var x=v.value;x||(x=v.attributes&&v.attributes.value&&!v.attributes.value.specified?
v.text:v.value);if(g)return x;h.push(x)}}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 A;A=arguments[0];var k=arguments[1],c=!1;a._i18n.trans[a._i18n.language]&&a._i18n.trans[a._i18n.language][A]&&a._i18n.trans[a._i18n.language][A][k]?c=a._i18n.trans[a._i18n.language][A][k]:a._i18n.trans[a._i18n["default"]]&&a._i18n.trans[a._i18n["default"]][A]&&a._i18n.trans[a._i18n["default"]][A][k]&&(c=a._i18n.trans[a._i18n["default"]][A][k]);
A=c||k;return arguments[2]&&"object"==typeof arguments[2]?a.format(A,arguments[2]):A}k=arguments[0].split(".");A=k[0];k=k[1]||"jQuery";a._i18n.trans[A]||(a._i18n.trans[A]={});a._i18n.trans[A][k]?a.extend(a._i18n.trans[A][k],arguments[1]):a._i18n.trans[A][k]=arguments[1]}})(jQuery);
new function(a){var A=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),v=k[0];this.keys[v]=e(this.keys[v],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(A));return b.join("")}};return new f(location.search,location.hash)}}(jQuery.query||{});
(function(a){var A=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 v=a.extend({},a.fn.superfish.defaults,
g),x=q.find(v.popUpSelector).parent("li");v.$path=h(q,v);q.data("sf-options",v);b(q,v);x.children("a").toggleClass("sf-with-ul");m(q);var r="li:has("+v.popUpSelector+")";if(a.fn.hoverIntent&&!v.disableHI)q.hoverIntent(f,n,r);else q.on("mouseenter.superfish",r,f).on("mouseleave.superfish",r,n);r="MSPointerDown.superfish";k||(r+=" touchend.superfish");c&&(r+=" mousedown.superfish");q.on("focusin.superfish","li",f).on("focusout.superfish","li",n).on(r,"a",v,e);x.not(".sf-breadcrumb").superfish("hide",
!0);v.onInit.call(this)})}}}();a.fn.superfish=function(k,c){return A[k]?A[k].apply(this,Array.prototype.slice.call(arguments,1)):"object"!==typeof k&&k?a.error("Method "+k+" does not exist on jQuery.fn.superfish"):A.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:A.hide,showSuperfishUl:A.show})})(jQuery);
(function(a,A,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,u=0,v;for(v in g)u=l+g[v].length,q.push({start:l,end:u,selected:l<=f&&u>f||u>=n&&l<n||l>f&&u<n}),l=u+1;g=0;for(v in q)q[v].selected&&(l=q[v].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;v=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;u=k.body.createTextRange();u.moveToElementText(c);u.setEndPoint("StartToEnd",f);var u=u.text,x=k.body.createTextRange();x.moveToElementText(c);x.setEndPoint("StartToEnd",q);var r=x.text,x=a(c).html();a("#r3").text(l+" + "+n+" + "+u.length+" = "+x.length);l+r.length<x.length?(g.push(""),l+=2,h&&m.tabString==
v[0].substring(0,m.tabString.length)?v[0]=v[0].substring(m.tabString.length):h||(v[0]=m.tabString+v[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(r=1;r<v.length;r++)h&&m.tabString==v[r].substring(0,m.tabString.length)?v[r]=v[r].substring(m.tabString.length):h||(v[r]=m.tabString+v[r]);1==g.length&&0==l&&(h&&m.tabString==v[0].substring(0,m.tabString.length)?v[0]=v[0].substring(m.tabString.length):
h||(v[0]=m.tabString+v[0]));l+n+u.length<x.length&&v.push("");q.text=g.join("\r\n");f.text=v.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,A,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(A).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(u,x){b=v.getImageStatus(u,x);h=b.statusWidth;m=b.statusHeight;if(!(1!==h&&-1!==h||2===m||1!==m&&-1!==m||2===h))1===h?k=u:-1===h&&(k=H),e=u,1===m?g=x:-1===m&&(g=B),f=x;else if(2===
h||2===m)1===h||-1===h?(f=g=D-M-G,q=g/x,-1===h?(k=H,e=Math.ceil(u*q)):(e=k=Math.ceil(u*q)-G,e<=H&&a(e,f))):1===m||-1===m?(e=k=r-G,l=k/u,-1===m?(g=B,f=Math.ceil(x*l)):(f=g=Math.ceil(x*l)-M-G,f<=B&&a(e,f))):u>x?(e=k=r-G,l=k/u,f=g=Math.ceil(x*l)-G-M,(f<=B||g+G+M>D)&&a(e,f)):(f=g=D-M-G,q=g/x,e=k=Math.ceil(u*q)-G,(e<=H||k>r)&&a(e,f))}var b,h,m,e,f,k,g,q,l,u=this.data,v=this,x=u.currentSetElement,r=this.getWindowSize("width"),D=this.getWindowSize("height"),H=u.minimalLightboxSize.width,B=u.minimalLightboxSize.height,
G=u.lightboxPadding,M=u.headerHeight;a(x.width,x.height);return{imageTargetWidth:e,imageTargetHeight:f,lightboxTargetWidth:k,lightboxTargetHeight:g,statusWidth:h,statusHeight:m}},getWindowSize:function(c){var b=this.data,h=a(A).width(),m=a(A).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,u=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=u.videoWidth;if(null===h||isNaN(h))h=u.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,u=l.videoWidth,v=l.videoHeight,x=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():(x=f.replaceHtmlPatterns(x,{width:u,height:v,url:q.id}),h=a("<div></div>"),h.css({display:"none",width:u,height:v}),
e.removeClass("ui-lightbox-loader").empty().append(x).children().wrap(h),!1===l.overwriteTitle&&(q.title=c.data.title),q.width=u,q.height=v,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,m=-1*(a.pageX-b.panoramaPosition.xStart),e=-1*(a.pageY-b.panoramaPosition.yStart),f=h.content,k=b.viewportRatio;b.panoramaOn&&(f.scrollLeft(f.scrollLeft()+m).scrollTop(f.scrollTop()+e),
h.viewport.css({left:f.scrollLeft()*k.width-1,top:f.scrollTop()*k.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,u=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===u?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,u=l.self.options;k=e.showErrorMessage;b=e.errorScreenSize;e=b.width;var v=b.height;b=u.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)?u.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=v):(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,A,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}navigator.userAgent.match(/ip[hone|od|ad]|android/i);var g=[],q=[],l=[],u=[],v=[];if(!a)throw"pukiwiki: jQuery does not included.";if(!a.ui)throw"pukiwiki: jQueryUI does not included.";
var x=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>'+A._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){g.push(a)},before_init:function(a){q.push(a)},unload:function(a){l.push(a)},before_unload:function(a){u.push(a)},ajax_load:function(a){v.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"),g=c.attr("rel"),h=f?f.match(/\.(\w+)$/i):null,l=g&&g.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(l)c.off("click").on("click",function(){if(g.match(/noreferer/))if(f.match(/data:text\/html;/))k.open(f);else{var 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>");g.match(/external/)?k.open(a):location.href=a}else if(h[1])switch(h[1]){case "jpg":case "jpeg":case "gif":case "png":c.rlightbox();break;default:k.open(f)}return!1});else if(f){for(var m={},l=f.slice(f.indexOf("?")+1).split("&"),n=c.data("disableScrolling")||c.parent().attr("role")?!0:!1,q=0;q<l.length;q++){var u=l[q].split("=");try{m[u[0]]=decodeURIComponent(u[1]).replace(/\+/g," ").replace(/%2F/g,"/")}catch(v){}}if("false"===m.ajax)return!0;
if(f.match("#")&&"#"!==f){if(!1===n)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"===m.ajax)return!1;if(m.cmd)if("open"==m.pcmd||void 0!==m.openfile){if(m.file?(l=m.file,c.attr("href",SCRIPT+"?cmd="+m.cmd+"&pcmd="+m.pcmd+"&refer="+m.refer+"&age="+m.age+"&file="+l)):(l=
m.openfile,c.attr("href",SCRIPT+"?cmd="+m.cmd+"&refer="+m.refer+"&openfile="+l)),h=l.match(/\.(\w+)$/i))switch(h[1].toLowerCase()){case "jpg":case "jpeg":case "gif":case "png":c.rlightbox()}}else if("qrcode"==m.cmd)c.attr("href",f+"&type=.gif"),c.rlightbox();else if(m.cmd.match(/search|newpage|template|rename/i)||"true"===m.help||"attach"===m.cmd&&"list"!==m.pcmd||"tb"===m.cmd&&void 0!==m.tb_id||"table_edit2"===m.cmd||m.cmd.match(/attach|source|template|freeze|rename|diff|referer|logview|related/i)&&
"undefined"!==typeof m.page)"true"==m.help&&(m={cmd:"read",page:"FormatRule"}),c.off("click").on("click",function(){m.ajax="json";e.ajax_dialog(m,b,function(){if("attach"==m.cmd&&m.pcmd.match(/upload|info/i)||m.cmd.match(/attachref|read|backup/i)&&""!==m.age)a(b).find(".window"),e.init_dom(b+" .window")});return!1})}}});if(0===a("#back-top").length){var f=a(c.body),g=a(k),h;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>');
h=a("#back-top");h.hide();g.scroll(function(){a(this).scrollTop()>a(".masthead").height()?h.fadeIn():h.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");n=b.responseText}).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=v.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 e[f]=c.attr("title"),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&&A.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){x.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){x.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&&(x.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":A.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=[],r=[],n=function(g){var h,l,n,q;h=m[g-1+k];l=m[g+1+k];h>=l?(l=h+1,h=l-g,n=r[g-1+k],q={edit:c?"-":"+",arr:b,line:l-1}):(h=l-g,n=r[g+1+k],q={edit:c?"+":"-",arr:a,line:h-1});0<=q.line&&(r[g+k]=n.concat(q));q=e-h>f-l?e-h:f-l;for(n=0;n<q&&a[h+n]===b[l+n];++n)r[g+k].push({edit:"=",arr:a,line:h+n});m[g+k]=l+n;return!0};for(h=0;h<e+f+3;++h)m[h]=-1,r[h]=[];for(h=0;m[l+k]!==f;h++){for(g=-h;g<l;++g)n(g);for(g=l+h;g>=l;--g)n(g)}return r[l+
k]};this.ajax_count=0;if(A.localstorage){var u=k.localStorage.getItem(PAGE);if(u=k.JSON.parse(u)){var v=MODIFIED>u.modified&&u.msg!==e.val()?a.i18n("pukiwiki","info_restore1"):a.i18n("pukiwiki","info_restore2");confirm(v)&&e.val(u.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>");x.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 r=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*r});a("#realview").hide();a("#indicator").addClass("hide");m.removeAttr("disabled","disabled")}):e.animate({height:r/2},function(){a("#realview").css("display","block").animate({height:r/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){a(".window").dialog("close");DEBUG?(f.error(b,e),0===a("#debug-window").length&&a(c.body).append('<div id="debug-window"></div>'),a("#debug-window").html(b.responseText).dialog({title:a.i18n("dialog","error"),modal:!0})):f.error(b.responseText);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=q.shift();)null!==a&&a();pukiwiki.init();for(tzCalculation_LocalTimeZone(location.host,!1);a=g.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,A){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;A&&document.writeln(k);document.cookie="timezone="+k+"; domain="+a;return k};
