/** 
 * Kendo UI v2017.2.621 (http://www.telerik.com/kendo-ui)                                                                                                                                               
 * Copyright 2017 Telerik AD. All rights reserved.                                                                                                                                                      
 *                                                                                                                                                                                                      
 * Kendo UI commercial licenses may be obtained at                                                                                                                                                      
 * http://www.telerik.com/purchase/license-agreement/kendo-ui-complete                                                                                                                                  
 * If you do not own a commercial license, this file shall be governed by the trial license terms.                                                                                                      
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       

*/
!function(e,define){define("kendo.core.min",["jquery"],e)}(function(){return function(e,t,n){function i(){}function o(e,t){if(t)return"'"+e.split("'").join("\\'").split('\\"').join('\\\\\\"').replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\t/g,"\\t")+"'";var n=e.charAt(0),i=e.substring(1);return"="===n?"+("+i+")+":":"===n?"+$kendoHtmlEncode("+i+")+":";"+e+";$kendoOutput+="}function r(e,t,n){return e+="",t=t||2,n=t-e.length,n?U[t].substring(0,n)+e:e}function s(e){var t=e.css(ve.support.transitions.css+"box-shadow")||e.css("box-shadow"),n=t?t.match(Ae)||[0,0,0,0,0]:[0,0,0,0,0],i=xe.max(+n[3],+(n[4]||0));return{left:-n[1]+i,right:+n[1]+i,bottom:+n[2]+i}}function a(t,n){var i,o,r,s,a,l,c,d=Se.browser,u=ve._outerWidth,h=ve._outerHeight;return t.parent().hasClass("k-animation-container")?(l=t.parent(".k-animation-container"),c=l[0].style,l.is(":hidden")&&l.show(),i=Te.test(c.width)||Te.test(c.height),i||l.css({width:n?u(t)+1:u(t),height:h(t),boxSizing:"content-box",mozBoxSizing:"content-box",webkitBoxSizing:"content-box"})):(o=t[0].style.width,r=t[0].style.height,s=Te.test(o),a=Te.test(r),i=s||a,!s&&(!n||n&&o)&&(o=n?u(t)+1:u(t)),!a&&(!n||n&&r)&&(r=h(t)),t.wrap(e("<div/>").addClass("k-animation-container").css({width:o,height:r})),i&&t.css({width:"100%",height:"100%",boxSizing:"border-box",mozBoxSizing:"border-box",webkitBoxSizing:"border-box"})),d.msie&&xe.floor(d.version)<=7&&(t.css({zoom:1}),t.children(".k-menu").width(t.width())),t.parent()}function l(e){var t=1,n=arguments.length;for(t=1;t<n;t++)c(e,arguments[t]);return e}function c(e,t){var n,i,o,r,s,a=ve.data.ObservableArray,l=ve.data.LazyObservableArray,d=ve.data.DataSource,u=ve.data.HierarchicalDataSource;for(n in t)i=t[n],o=typeof i,r=o===Fe&&null!==i?i.constructor:null,r&&r!==Array&&r!==a&&r!==l&&r!==d&&r!==u&&r!==RegExp?i instanceof Date?e[n]=new Date(i.getTime()):R(i.clone)?e[n]=i.clone():(s=e[n],e[n]=typeof s===Fe?s||{}:{},c(e[n],i)):o!==Be&&(e[n]=i);return e}function d(e,t,i){for(var o in t)if(t.hasOwnProperty(o)&&t[o].test(e))return o;return i!==n?i:e}function u(e){return e.replace(/([a-z][A-Z])/g,function(e){return e.charAt(0)+"-"+e.charAt(1).toLowerCase()})}function h(e){return e.replace(/\-(\w)/g,function(e,t){return t.toUpperCase()})}function f(t,n){var i,o={};return document.defaultView&&document.defaultView.getComputedStyle?(i=document.defaultView.getComputedStyle(t,""),n&&e.each(n,function(e,t){o[t]=i.getPropertyValue(t)})):(i=t.currentStyle,n&&e.each(n,function(e,t){o[t]=i[h(t)]})),ve.size(o)||(o=i),o}function p(e){if(e&&e.className&&"string"==typeof e.className&&e.className.indexOf("k-auto-scrollable")>-1)return!0;var t=f(e,["overflow"]).overflow;return"auto"==t||"scroll"==t}function m(t,i){var o,r=Se.browser.webkit,s=Se.browser.mozilla,a=t instanceof e?t[0]:t;if(t)return o=Se.isRtl(t),i===n?o&&r?a.scrollWidth-a.clientWidth-a.scrollLeft:Math.abs(a.scrollLeft):(a.scrollLeft=o&&r?a.scrollWidth-a.clientWidth-i:o&&s?-i:i,n)}function g(e){var t,n=0;for(t in e)e.hasOwnProperty(t)&&"toJSON"!=t&&n++;return n}function v(e,n,i){var o,r,s;return n||(n="offset"),o=e[n](),r={top:o.top,right:o.right,bottom:o.bottom,left:o.left},Se.browser.msie&&(Se.pointers||Se.msPointers)&&!i&&(s=Se.isRtl(e)?1:-1,r.top-=t.pageYOffset-document.documentElement.scrollTop,r.left-=t.pageXOffset+s*document.documentElement.scrollLeft),r}function _(e){var t={};return be("string"==typeof e?e.split(" "):e,function(e){t[e]=this}),t}function b(e){return new ve.effects.Element(e)}function w(e,t,n,i){return typeof e===Ie&&(R(t)&&(i=t,t=400,n=!1),R(n)&&(i=n,n=!1),typeof t===Pe&&(n=t,t=400),e={effects:e,duration:t,reverse:n,complete:i}),_e({effects:{},duration:400,reverse:!1,init:ke,teardown:ke,hide:!1},e,{completeCallback:e.complete,complete:ke})}function y(t,n,i,o,r){for(var s,a=0,l=t.length;a<l;a++)s=e(t[a]),s.queue(function(){q.promise(s,w(n,i,o,r))});return t}function k(e,t,n,i){return t&&(t=t.split(" "),be(t,function(t,n){e.toggleClass(n,i)})),e}function x(e){return(""+e).replace(j,"&amp;").replace(G,"&lt;").replace(K,"&gt;").replace($,"&quot;").replace(Y,"&#39;")}function C(e,t){var i;return 0===t.indexOf("data")&&(t=t.substring(4),t=t.charAt(0).toLowerCase()+t.substring(1)),t=t.replace(oe,"-$1"),i=e.getAttribute("data-"+ve.ns+t),null===i?i=n:"null"===i?i=null:"true"===i?i=!0:"false"===i?i=!1:Ee.test(i)?i=parseFloat(i):ne.test(i)&&!ie.test(i)&&(i=Function("return ("+i+")")()),i}function S(t,i){var o,r,s={};for(o in i)r=C(t,o),r!==n&&(te.test(o)&&(r="string"==typeof r?ve.template(e("#"+r).html()):t.getAttribute(o)),s[o]=r);return s}function T(t,n){return e.contains(t,n)?-1:1}function D(){var t=e(this);return e.inArray(t.attr("data-"+ve.ns+"role"),["slider","rangeslider"])>-1||t.is(":visible")}function A(e,t){var n=e.nodeName.toLowerCase();return(/input|select|textarea|button|object/.test(n)?!e.disabled:"a"===n?e.href||t:t)&&E(e)}function E(t){return e.expr.filters.visible(t)&&!e(t).parents().addBack().filter(function(){return"hidden"===e.css(this,"visibility")}).length}function M(e,t){return new M.fn.init(e,t)}var I,R,F,z,P,B,L,H,N,O,V,U,W,q,j,G,$,Y,K,Q,X,Z,J,ee,te,ne,ie,oe,re,se,ae,le,ce,de,ue,he,fe,pe,me,ge,ve=t.kendo=t.kendo||{cultures:{}},_e=e.extend,be=e.each,we=e.isArray,ye=e.proxy,ke=e.noop,xe=Math,Ce=t.JSON||{},Se={},Te=/%/,De=/\{(\d+)(:[^\}]+)?\}/g,Ae=/(\d+(?:\.?)\d*)px\s*(\d+(?:\.?)\d*)px\s*(\d+(?:\.?)\d*)px\s*(\d+)?/i,Ee=/^(\+|-?)\d+(\.?)\d*$/,Me="function",Ie="string",Re="number",Fe="object",ze="null",Pe="boolean",Be="undefined",Le={},He={},Ne=[].slice;ve.version="2017.2.621".replace(/^\s+|\s+$/g,""),i.extend=function(e){var t,n,i=function(){},o=this,r=e&&e.init?e.init:function(){o.apply(this,arguments)};i.prototype=o.prototype,n=r.fn=r.prototype=new i;for(t in e)n[t]=null!=e[t]&&e[t].constructor===Object?_e(!0,{},i.prototype[t],e[t]):e[t];return n.constructor=r,r.extend=o.extend,r},i.prototype._initOptions=function(e){this.options=l({},this.options,e)},R=ve.isFunction=function(e){return"function"==typeof e},F=function(){this._defaultPrevented=!0},z=function(){return this._defaultPrevented===!0},P=i.extend({init:function(){this._events={}},bind:function(e,t,i){var o,r,s,a,l,c=this,d=typeof e===Ie?[e]:e,u=typeof t===Me;if(t===n){for(o in e)c.bind(o,e[o]);return c}for(o=0,r=d.length;o<r;o++)e=d[o],a=u?t:t[e],a&&(i&&(s=a,a=function(){c.unbind(e,a),s.apply(c,arguments)},a.original=s),l=c._events[e]=c._events[e]||[],l.push(a));return c},one:function(e,t){return this.bind(e,t,!0)},first:function(e,t){var n,i,o,r,s=this,a=typeof e===Ie?[e]:e,l=typeof t===Me;for(n=0,i=a.length;n<i;n++)e=a[n],o=l?t:t[e],o&&(r=s._events[e]=s._events[e]||[],r.unshift(o));return s},trigger:function(e,t){var n,i,o=this,r=o._events[e];if(r){for(t=t||{},t.sender=o,t._defaultPrevented=!1,t.preventDefault=F,t.isDefaultPrevented=z,r=r.slice(),n=0,i=r.length;n<i;n++)r[n].call(o,t);return t._defaultPrevented===!0}return!1},unbind:function(e,t){var i,o=this,r=o._events[e];if(e===n)o._events={};else if(r)if(t)for(i=r.length-1;i>=0;i--)r[i]!==t&&r[i].original!==t||r.splice(i,1);else o._events[e]=[];return o}}),B=/^\w+/,L=/\$\{([^}]*)\}/g,H=/\\\}/g,N=/__CURLY__/g,O=/\\#/g,V=/__SHARP__/g,U=["","0","00","000","0000"],I={paramName:"data",useWithBlock:!0,render:function(e,t){var n,i,o="";for(n=0,i=t.length;n<i;n++)o+=e(t[n]);return o},compile:function(e,t){var n,i,r,s=_e({},this,t),a=s.paramName,l=a.match(B)[0],c=s.useWithBlock,d="var $kendoOutput, $kendoHtmlEncode = kendo.htmlEncode;";if(R(e))return e;for(d+=c?"with("+a+"){":"",d+="$kendoOutput=",i=e.replace(H,"__CURLY__").replace(L,"#=$kendoHtmlEncode($1)#").replace(N,"}").replace(O,"__SHARP__").split("#"),r=0;r<i.length;r++)d+=o(i[r],r%2===0);d+=c?";}":";",d+="return $kendoOutput;",d=d.replace(V,"#");try{return n=Function(l,d),n._slotCount=Math.floor(i.length/2),n}catch(u){throw Error(ve.format("Invalid template:'{0}' Generated code:'{1}'",e,d))}}},function(){function e(e){return s.lastIndex=0,s.test(e)?'"'+e.replace(s,function(e){var t=a[e];return typeof t===Ie?t:"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+e+'"'}function t(r,s){var a,c,d,u,h,f,p=n,m=s[r];if(m&&typeof m===Fe&&typeof m.toJSON===Me&&(m=m.toJSON(r)),typeof o===Me&&(m=o.call(s,r,m)),f=typeof m,f===Ie)return e(m);if(f===Re)return isFinite(m)?m+"":ze;if(f===Pe||f===ze)return m+"";if(f===Fe){if(!m)return ze;if(n+=i,h=[],"[object Array]"===l.apply(m)){for(u=m.length,a=0;a<u;a++)h[a]=t(a,m)||ze;return d=0===h.length?"[]":n?"[\n"+n+h.join(",\n"+n)+"\n"+p+"]":"["+h.join(",")+"]",n=p,d}if(o&&typeof o===Fe)for(u=o.length,a=0;a<u;a++)typeof o[a]===Ie&&(c=o[a],d=t(c,m),d&&h.push(e(c)+(n?": ":":")+d));else for(c in m)Object.hasOwnProperty.call(m,c)&&(d=t(c,m),d&&h.push(e(c)+(n?": ":":")+d));return d=0===h.length?"{}":n?"{\n"+n+h.join(",\n"+n)+"\n"+p+"}":"{"+h.join(",")+"}",n=p,d}}var n,i,o,s=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,a={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},l={}.toString;typeof Date.prototype.toJSON!==Me&&(Date.prototype.toJSON=function(){var e=this;return isFinite(e.valueOf())?r(e.getUTCFullYear(),4)+"-"+r(e.getUTCMonth()+1)+"-"+r(e.getUTCDate())+"T"+r(e.getUTCHours())+":"+r(e.getUTCMinutes())+":"+r(e.getUTCSeconds())+"Z":null},String.prototype.toJSON=Number.prototype.toJSON=Boolean.prototype.toJSON=function(){return this.valueOf()}),typeof Ce.stringify!==Me&&(Ce.stringify=function(e,r,s){var a;if(n="",i="",typeof s===Re)for(a=0;a<s;a+=1)i+=" ";else typeof s===Ie&&(i=s);if(o=r,r&&typeof r!==Me&&(typeof r!==Fe||typeof r.length!==Re))throw Error("JSON.stringify");return t("",{"":e})})}(),function(){function t(e){if(e){if(e.numberFormat)return e;if(typeof e===Ie){var t=ve.cultures;return t[e]||t[e.split("-")[0]]||null}return null}return null}function i(e){return e&&(e=t(e)),e||ve.cultures.current}function o(e,t,o){o=i(o);var s=o.calendars.standard,a=s.days,l=s.months;return t=s.patterns[t]||t,t.replace(d,function(t){var i,o,c;return"d"===t?o=e.getDate():"dd"===t?o=r(e.getDate()):"ddd"===t?o=a.namesAbbr[e.getDay()]:"dddd"===t?o=a.names[e.getDay()]:"M"===t?o=e.getMonth()+1:"MM"===t?o=r(e.getMonth()+1):"MMM"===t?o=l.namesAbbr[e.getMonth()]:"MMMM"===t?o=l.names[e.getMonth()]:"yy"===t?o=r(e.getFullYear()%100):"yyyy"===t?o=r(e.getFullYear(),4):"h"===t?o=e.getHours()%12||12:"hh"===t?o=r(e.getHours()%12||12):"H"===t?o=e.getHours():"HH"===t?o=r(e.getHours()):"m"===t?o=e.getMinutes():"mm"===t?o=r(e.getMinutes()):"s"===t?o=e.getSeconds():"ss"===t?o=r(e.getSeconds()):"f"===t?o=xe.floor(e.getMilliseconds()/100):"ff"===t?(o=e.getMilliseconds(),o>99&&(o=xe.floor(o/10)),o=r(o)):"fff"===t?o=r(e.getMilliseconds(),3):"tt"===t?o=e.getHours()<12?s.AM[0]:s.PM[0]:"zzz"===t?(i=e.getTimezoneOffset(),c=i<0,o=(""+xe.abs(i/60)).split(".")[0],i=xe.abs(i)-60*o,o=(c?"+":"-")+r(o),o+=":"+r(i)):"zz"!==t&&"z"!==t||(o=e.getTimezoneOffset()/60,c=o<0,o=(""+xe.abs(o)).split(".")[0],o=(c?"+":"-")+("zz"===t?r(o):o)),o!==n?o:t.slice(1,t.length-1)})}function s(e,t,o){o=i(o);var r,s,c,d,w,y,k,x,C,S,T,D,A,E,M,I,R,F,z,P,B,L,H,N=o.numberFormat,O=N[m],V=N.decimals,U=N.pattern[0],W=[],q=e<0,j=p,G=p,$=-1;if(e===n)return p;if(!isFinite(e))return e;if(!t)return o.name.length?e.toLocaleString():""+e;if(w=u.exec(t)){if(t=w[1].toLowerCase(),s="c"===t,c="p"===t,(s||c)&&(N=s?N.currency:N.percent,O=N[m],V=N.decimals,r=N.symbol,U=N.pattern[q?0:1]),d=w[2],d&&(V=+d),"e"===t)return d?e.toExponential(V):e.toExponential();if(c&&(e*=100),e=l(e,V),q=e<0,e=e.split(m),y=e[0],k=e[1],q&&(y=y.substring(1)),G=a(y,0,y.length,N),k&&(G+=O+k),"n"===t&&!q)return G;for(e=p,S=0,T=U.length;S<T;S++)D=U.charAt(S),e+="n"===D?G:"$"===D||"%"===D?r:D;return e}if(q&&(e=-e),(t.indexOf("'")>-1||t.indexOf('"')>-1||t.indexOf("\\")>-1)&&(t=t.replace(h,function(e){var t=e.charAt(0).replace("\\",""),n=e.slice(1).replace(t,"");return W.push(n),b})),t=t.split(";"),q&&t[1])t=t[1],E=!0;else if(0===e){if(t=t[2]||t[0],t.indexOf(v)==-1&&t.indexOf(_)==-1)return t}else t=t[0];if(P=t.indexOf("%"),B=t.indexOf("$"),c=P!=-1,s=B!=-1,c&&(e*=100),s&&"\\"===t[B-1]&&(t=t.split("\\").join(""),s=!1),(s||c)&&(N=s?N.currency:N.percent,O=N[m],V=N.decimals,r=N.symbol),A=t.indexOf(g)>-1,A&&(t=t.replace(f,p)),M=t.indexOf(m),T=t.length,M!=-1?(k=(""+e).split("e"),k=k[1]?l(e,Math.abs(k[1])):k[0],k=k.split(m)[1]||p,R=t.lastIndexOf(_)-M,I=t.lastIndexOf(v)-M,F=R>-1,z=I>-1,S=k.length,F||z||(t=t.substring(0,M)+t.substring(M+1),T=t.length,M=-1,S=0),F&&R>I?S=R:I>R&&(z&&S>I?S=I:F&&S<R&&(S=R)),S>-1&&(e=l(e,S))):e=l(e),I=t.indexOf(v),L=R=t.indexOf(_),$=I==-1&&R!=-1?R:I!=-1&&R==-1?I:I>R?R:I,I=t.lastIndexOf(v),R=t.lastIndexOf(_),H=I==-1&&R!=-1?R:I!=-1&&R==-1?I:I>R?I:R,$==T&&(H=$),$!=-1){for(G=(""+e).split(m),y=G[0],k=G[1]||p,x=y.length,C=k.length,q&&e*-1>=0&&(q=!1),e=t.substring(0,$),q&&!E&&(e+="-"),S=$;S<T;S++){if(D=t.charAt(S),M==-1){if(H-S<x){e+=y;break}}else if(R!=-1&&R<S&&(j=p),M-S<=x&&M-S>-1&&(e+=y,S=M),M===S){e+=(k?O:p)+k,S+=H-M+1;continue}D===_?(e+=D,j=D):D===v&&(e+=j)}if(A&&(e=a(e,$+(q&&!E?1:0),Math.max(H,x+$),N)),H>=$&&(e+=t.substring(H+1)),s||c){for(G=p,S=0,T=e.length;S<T;S++)D=e.charAt(S),G+="$"===D||"%"===D?r:D;e=G}if(T=W.length)for(S=0;S<T;S++)e=e.replace(b,W[S])}return e}var a,l,c,d=/dddd|ddd|dd|d|MMMM|MMM|MM|M|yyyy|yy|HH|H|hh|h|mm|m|fff|ff|f|tt|ss|s|zzz|zz|z|"[^"]*"|'[^']*'/g,u=/^(n|c|p|e)(\d*)$/i,h=/(\\.)|(['][^']*[']?)|(["][^"]*["]?)/g,f=/\,/g,p="",m=".",g=",",v="#",_="0",b="??",w="en-US",y={}.toString;ve.cultures["en-US"]={name:w,numberFormat:{pattern:["-n"],decimals:2,",":",",".":".",groupSize:[3],percent:{pattern:["-n %","n %"],decimals:2,",":",",".":".",groupSize:[3],symbol:"%"},currency:{name:"US Dollar",abbr:"USD",pattern:["($n)","$n"],decimals:2,",":",",".":".",groupSize:[3],symbol:"$"}},calendars:{standard:{days:{names:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],namesAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],namesShort:["Su","Mo","Tu","We","Th","Fr","Sa"]},months:{names:["January","February","March","April","May","June","July","August","September","October","November","December"],namesAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]},AM:["AM","am","AM"],PM:["PM","pm","PM"],patterns:{d:"M/d/yyyy",D:"dddd, MMMM dd, yyyy",F:"dddd, MMMM dd, yyyy h:mm:ss tt",g:"M/d/yyyy h:mm tt",G:"M/d/yyyy h:mm:ss tt",m:"MMMM dd",M:"MMMM dd",s:"yyyy'-'MM'-'ddTHH':'mm':'ss",t:"h:mm tt",T:"h:mm:ss tt",u:"yyyy'-'MM'-'dd HH':'mm':'ss'Z'",y:"MMMM, yyyy",Y:"MMMM, yyyy"},"/":"/",":":":",firstDay:0,twoDigitYearMax:2029}}},ve.culture=function(e){var i,o=ve.cultures;return e===n?o.current:(i=t(e)||o[w],i.calendar=i.calendars.standard,o.current=i,n)},ve.findCulture=t,ve.getCulture=i,ve.culture(w),a=function(e,t,i,o){var r,s,a,l,c,d,u=e.indexOf(o[m]),h=o.groupSize.slice(),f=h.shift();if(i=u!==-1?u:i+1,r=e.substring(t,i),s=r.length,s>=f){for(a=s,l=[];a>-1;)if(c=r.substring(a-f,a),c&&l.push(c),a-=f,d=h.shift(),f=d!==n?d:f,0===f){l.push(r.substring(0,a));break}r=l.reverse().join(o[g]),e=e.substring(0,t)+r+e.substring(i)}return e},l=function(e,t){return t=t||0,e=(""+e).split("e"),e=Math.round(+(e[0]+"e"+(e[1]?+e[1]+t:t))),e=(""+e).split("e"),e=+(e[0]+"e"+(e[1]?+e[1]-t:-t)),e.toFixed(Math.min(t,20))},c=function(e,t,i){if(t){if("[object Date]"===y.call(e))return o(e,t,i);if(typeof e===Re)return s(e,t,i)}return e!==n?e:""},ve.format=function(e){var t=arguments;return e.replace(De,function(e,n,i){var o=t[parseInt(n,10)+1];return c(o,i?i.substring(1):"")})},ve._extractFormat=function(e){return"{0:"===e.slice(0,3)&&(e=e.slice(3,e.length-1)),e},ve._activeElement=function(){try{return document.activeElement}catch(e){return document.documentElement.activeElement}},ve._round=l,ve._outerWidth=function(t,n){return e(t).outerWidth(n||!1)||0},ve._outerHeight=function(t,n){return e(t).outerHeight(n||!1)||0},ve.toString=c}(),function(){function t(e,t,n){return!(e>=t&&e<=n)}function i(e){return e.charAt(0)}function o(t){return e.map(t,i)}function r(e,t){t||23!==e.getHours()||e.setHours(e.getHours()+2)}function s(e){for(var t=0,n=e.length,i=[];t<n;t++)i[t]=(e[t]+"").toLowerCase();return i}function a(e){var t,n={};for(t in e)n[t]=s(e[t]);return n}function l(e,i,s){if(!e)return null;var l,c,d,u,h,m,g,v,_,w,y,k,x,C=function(e){for(var t=0;i[B]===e;)t++,B++;return t>0&&(B-=1),t},S=function(t){var n=b[t]||RegExp("^\\d{1,"+t+"}"),i=e.substr(L,t).match(n);return i?(i=i[0],L+=i.length,parseInt(i,10)):null},T=function(t,n){for(var i,o,r,s=0,a=t.length,l=0,c=0;s<a;s++)i=t[s],o=i.length,r=e.substr(L,o),n&&(r=r.toLowerCase()),r==i&&o>l&&(l=o,c=s);return l?(L+=l,c+1):null},D=function(){var t=!1;return e.charAt(L)===i[B]&&(L++,t=!0),t},A=s.calendars.standard,E=null,M=null,I=null,R=null,F=null,z=null,P=null,B=0,L=0,H=!1,N=new Date,O=A.twoDigitYearMax||2029,V=N.getFullYear();for(i||(i="d"),u=A.patterns[i],u&&(i=u),i=i.split(""),d=i.length;B<d;B++)if(l=i[B],H)"'"===l?H=!1:D();else if("d"===l){if(c=C("d"),A._lowerDays||(A._lowerDays=a(A.days)),null!==I&&c>2)continue;if(I=c<3?S(2):T(A._lowerDays[3==c?"namesAbbr":"names"],!0),null===I||t(I,1,31))return null}else if("M"===l){if(c=C("M"),A._lowerMonths||(A._lowerMonths=a(A.months)),M=c<3?S(2):T(A._lowerMonths[3==c?"namesAbbr":"names"],!0),null===M||t(M,1,12))return null;M-=1}else if("y"===l){if(c=C("y"),E=S(c),null===E)return null;2==c&&("string"==typeof O&&(O=V+parseInt(O,10)),E=V-V%100+E,E>O&&(E-=100))}else if("h"===l){if(C("h"),R=S(2),12==R&&(R=0),null===R||t(R,0,11))return null}else if("H"===l){if(C("H"),R=S(2),null===R||t(R,0,23))return null}else if("m"===l){if(C("m"),F=S(2),null===F||t(F,0,59))return null}else if("s"===l){if(C("s"),z=S(2),null===z||t(z,0,59))return null}else if("f"===l){if(c=C("f"),x=e.substr(L,c).match(b[3]),P=S(c),null!==P&&(P=parseFloat("0."+x[0],10),P=ve._round(P,3),P*=1e3),null===P||t(P,0,999))return null}else if("t"===l){if(c=C("t"),v=A.AM,_=A.PM,1===c&&(v=o(v),_=o(_)),h=T(_),!h&&!T(v))return null}else if("z"===l){if(m=!0,c=C("z"),"Z"===e.substr(L,1)){D();continue}if(g=e.substr(L,6).match(c>2?p:f),!g)return null;if(g=g[0].split(":"),w=g[0],y=g[1],!y&&w.length>3&&(L=w.length-2,y=w.substring(L),w=w.substring(0,L)),w=parseInt(w,10),t(w,-12,13))return null;if(c>2&&(y=parseInt(y,10),isNaN(y)||t(y,0,59)))return null}else if("'"===l)H=!0,D();else if(!D())return null;return k=null!==R||null!==F||z||null,null===E&&null===M&&null===I&&k?(E=V,M=N.getMonth(),I=N.getDate()):(null===E&&(E=V),null===I&&(I=1)),h&&R<12&&(R+=12),m?(w&&(R+=-w),y&&(F+=-y),e=new Date(Date.UTC(E,M,I,R,F,z,P))):(e=new Date(E,M,I,R,F,z,P),r(e,R)),E<100&&e.setFullYear(E),e.getDate()!==I&&m===n?null:e}function c(e){var t="-"===e.substr(0,1)?-1:1;return e=e.substring(1),e=60*parseInt(e.substr(0,2),10)+parseInt(e.substring(2),10),t*e}function d(e){var t,n,i,o=xe.max(v.length,_.length),r=e.calendar.patterns,s=[];for(i=0;i<o;i++){for(t=v[i],n=0;n<t.length;n++)s.push(r[t[n]]);s=s.concat(_[i])}return s}var u=/\u00A0/g,h=/[eE][\-+]?[0-9]+/,f=/[+|\-]\d{1,2}/,p=/[+|\-]\d{1,2}:?\d{2}/,m=/^\/Date\((.*?)\)\/$/,g=/[+-]\d*/,v=[[],["G","g","F"],["D","d","y","m","T","t"]],_=[["yyyy-MM-ddTHH:mm:ss.fffffffzzz","yyyy-MM-ddTHH:mm:ss.fffffff","yyyy-MM-ddTHH:mm:ss.fffzzz","yyyy-MM-ddTHH:mm:ss.fff","ddd MMM dd yyyy HH:mm:ss","yyyy-MM-ddTHH:mm:sszzz","yyyy-MM-ddTHH:mmzzz","yyyy-MM-ddTHH:mmzz","yyyy-MM-ddTHH:mm:ss","yyyy-MM-dd HH:mm:ss","yyyy/MM/dd HH:mm:ss"],["yyyy-MM-ddTHH:mm","yyyy-MM-dd HH:mm","yyyy/MM/dd HH:mm"],["yyyy/MM/dd","yyyy-MM-dd","HH:mm:ss","HH:mm"]],b={2:/^\d{1,2}/,3:/^\d{1,3}/,4:/^\d{4}/},w={}.toString;ve.parseDate=function(e,t,n){var i,o,r,s;if("[object Date]"===w.call(e))return e;if(i=0,o=null,e&&0===e.indexOf("/D")&&(o=m.exec(e)))return o=o[1],s=g.exec(o.substring(1)),o=new Date(parseInt(o,10)),s&&(s=c(s[0]),o=ve.timezone.apply(o,0),o=ve.timezone.convert(o,0,-1*s)),o;for(n=ve.getCulture(n),t||(t=d(n)),t=we(t)?t:[t],r=t.length;i<r;i++)if(o=l(e,t[i],n))return o;return o},ve.parseInt=function(e,t){var n=ve.parseFloat(e,t);return n&&(n=0|n),n},ve.parseFloat=function(e,t,n){if(!e&&0!==e)return null;if(typeof e===Re)return e;e=""+e,t=ve.getCulture(t);var i,o,r=t.numberFormat,s=r.percent,a=r.currency,l=a.symbol,c=s.symbol,d=e.indexOf("-");return h.test(e)?(e=parseFloat(e.replace(r["."],".")),isNaN(e)&&(e=null),e):d>0?null:(d=d>-1,e.indexOf(l)>-1||n&&n.toLowerCase().indexOf("c")>-1?(r=a,i=r.pattern[0].replace("$",l).split("n"),e.indexOf(i[0])>-1&&e.indexOf(i[1])>-1&&(e=e.replace(i[0],"").replace(i[1],""),d=!0)):e.indexOf(c)>-1&&(o=!0,r=s,l=c),e=e.replace("-","").replace(l,"").replace(u," ").split(r[","].replace(u," ")).join("").replace(r["."],"."),e=parseFloat(e),isNaN(e)?e=null:d&&(e*=-1),e&&o&&(e/=100),e)}}(),function(){var i,o,r,s,a,l,c,u,h;Se._scrollbar=n,Se.scrollbar=function(e){if(isNaN(Se._scrollbar)||e){var t,n=document.createElement("div");return n.style.cssText="overflow:scroll;overflow-x:hidden;zoom:1;clear:both;display:block",n.innerHTML="&nbsp;",document.body.appendChild(n),Se._scrollbar=t=n.offsetWidth-n.scrollWidth,document.body.removeChild(n),t}return Se._scrollbar},Se.isRtl=function(t){return e(t).closest(".k-rtl").length>0},i=document.createElement("table");try{i.innerHTML="<tr><td></td></tr>",Se.tbodyInnerHtml=!0}catch(f){Se.tbodyInnerHtml=!1}Se.touch="ontouchstart"in t,o=document.documentElement.style,r=Se.transitions=!1,s=Se.transforms=!1,a="HTMLElement"in t?HTMLElement.prototype:[],Se.hasHW3D="WebKitCSSMatrix"in t&&"m11"in new t.WebKitCSSMatrix||"MozPerspective"in o||"msPerspective"in o,Se.cssFlexbox="flexWrap"in o||"WebkitFlexWrap"in o||"msFlexWrap"in o,be(["Moz","webkit","O","ms"],function(){var e,t=""+this,n=typeof i.style[t+"Transition"]===Ie;if(n||typeof i.style[t+"Transform"]===Ie)return e=t.toLowerCase(),s={css:"ms"!=e?"-"+e+"-":"",prefix:t,event:"o"===e||"webkit"===e?e:""},n&&(r=s,r.event=r.event?r.event+"TransitionEnd":"transitionend"),!1}),i=null,Se.transforms=s,Se.transitions=r,Se.devicePixelRatio=t.devicePixelRatio===n?1:t.devicePixelRatio;try{Se.screenWidth=t.outerWidth||t.screen?t.screen.availWidth:t.innerWidth,Se.screenHeight=t.outerHeight||t.screen?t.screen.availHeight:t.innerHeight}catch(f){Se.screenWidth=t.screen.availWidth,Se.screenHeight=t.screen.availHeight}Se.detectOS=function(e){var n,i,o=!1,r=[],s=!/mobile safari/i.test(e),a={wp:/(Windows Phone(?: OS)?)\s(\d+)\.(\d+(\.\d+)?)/,fire:/(Silk)\/(\d+)\.(\d+(\.\d+)?)/,android:/(Android|Android.*(?:Opera|Firefox).*?\/)\s*(\d+)\.(\d+(\.\d+)?)/,iphone:/(iPhone|iPod).*OS\s+(\d+)[\._]([\d\._]+)/,ipad:/(iPad).*OS\s+(\d+)[\._]([\d_]+)/,meego:/(MeeGo).+NokiaBrowser\/(\d+)\.([\d\._]+)/,webos:/(webOS)\/(\d+)\.(\d+(\.\d+)?)/,blackberry:/(BlackBerry|BB10).*?Version\/(\d+)\.(\d+(\.\d+)?)/,playbook:/(PlayBook).*?Tablet\s*OS\s*(\d+)\.(\d+(\.\d+)?)/,windows:/(MSIE)\s+(\d+)\.(\d+(\.\d+)?)/,tizen:/(tizen).*?Version\/(\d+)\.(\d+(\.\d+)?)/i,sailfish:/(sailfish).*rv:(\d+)\.(\d+(\.\d+)?).*firefox/i,ffos:/(Mobile).*rv:(\d+)\.(\d+(\.\d+)?).*Firefox/},l={ios:/^i(phone|pad|pod)$/i,android:/^android|fire$/i,blackberry:/^blackberry|playbook/i,windows:/windows/,wp:/wp/,flat:/sailfish|ffos|tizen/i,meego:/meego/},c={tablet:/playbook|ipad|fire/i},u={omini:/Opera\sMini/i,omobile:/Opera\sMobi/i,firefox:/Firefox|Fennec/i,mobilesafari:/version\/.*safari/i,ie:/MSIE|Windows\sPhone/i,chrome:/chrome|crios/i,webkit:/webkit/i};for(i in a)if(a.hasOwnProperty(i)&&(r=e.match(a[i]))){if("windows"==i&&"plugins"in navigator)return!1;o={},o.device=i,o.tablet=d(i,c,!1),o.browser=d(e,u,"default"),o.name=d(i,l),o[o.name]=!0,o.majorVersion=r[2],o.minorVersion=r[3].replace("_","."),n=o.minorVersion.replace(".","").substr(0,2),o.flatVersion=o.majorVersion+n+Array(3-(n.length<3?n.length:2)).join("0"),o.cordova=typeof t.PhoneGap!==Be||typeof t.cordova!==Be,o.appMode=t.navigator.standalone||/file|local|wmapp/.test(t.location.protocol)||o.cordova,o.android&&(Se.devicePixelRatio<1.5&&o.flatVersion<400||s)&&(Se.screenWidth>800||Se.screenHeight>800)&&(o.tablet=i);break}return o},l=Se.mobileOS=Se.detectOS(navigator.userAgent),Se.wpDevicePixelRatio=l.wp?screen.width/320:0,Se.hasNativeScrolling=!1,(l.ios||l.android&&l.majorVersion>2||l.wp)&&(Se.hasNativeScrolling=l),Se.delayedClick=function(){if(Se.touch){if(l.ios)return!0;if(l.android)return!Se.browser.chrome||!(Se.browser.version<32)&&!(e("meta[name=viewport]").attr("content")||"").match(/user-scalable=no/i)}return!1},Se.mouseAndTouchPresent=Se.touch&&!(Se.mobileOS.ios||Se.mobileOS.android),Se.detectBrowser=function(e){var t,n=!1,i=[],o={edge:/(edge)[ \/]([\w.]+)/i,webkit:/(chrome)[ \/]([\w.]+)/i,safari:/(webkit)[ \/]([\w.]+)/i,opera:/(opera)(?:.*version|)[ \/]([\w.]+)/i,msie:/(msie\s|trident.*? rv:)([\w.]+)/i,mozilla:/(mozilla)(?:.*? rv:([\w.]+)|)/i};for(t in o)if(o.hasOwnProperty(t)&&(i=e.match(o[t]))){n={},n[t]=!0,n[i[1].toLowerCase().split(" ")[0].split("/")[0]]=!0,n.version=parseInt(document.documentMode||i[2],10);break}return n},Se.browser=Se.detectBrowser(navigator.userAgent),Se.detectClipboardAccess=function(){var e={copy:!!document.queryCommandSupported&&document.queryCommandSupported("copy"),cut:!!document.queryCommandSupported&&document.queryCommandSupported("cut"),paste:!!document.queryCommandSupported&&document.queryCommandSupported("paste")};return Se.browser.chrome&&(e.paste=!1,Se.browser.version>=43&&(e.copy=!0,e.cut=!0)),e},Se.clipboard=Se.detectClipboardAccess(),Se.zoomLevel=function(){var e,n,i;try{return e=Se.browser,n=0,i=document.documentElement,e.msie&&11==e.version&&i.scrollHeight>i.clientHeight&&!Se.touch&&(n=Se.scrollbar()),Se.touch?i.clientWidth/t.innerWidth:e.msie&&e.version>=10?((top||t).document.documentElement.offsetWidth+n)/(top||t).innerWidth:1}catch(o){return 1}},Se.cssBorderSpacing=n!==o.borderSpacing&&!(Se.browser.msie&&Se.browser.version<8),function(t){var n="",i=e(document.documentElement),o=parseInt(t.version,10);t.msie?n="ie":t.mozilla?n="ff":t.safari?n="safari":t.webkit?n="webkit":t.opera?n="opera":t.edge&&(n="edge"),n&&(n="k-"+n+" k-"+n+o),Se.mobileOS&&(n+=" k-mobile"),Se.cssFlexbox||(n+=" k-no-flexbox"),i.addClass(n)}(Se.browser),Se.eventCapture=document.documentElement.addEventListener,c=document.createElement("input"),Se.placeholder="placeholder"in c,Se.propertyChangeEvent="onpropertychange"in c,Se.input=function(){for(var e,t=["number","date","time","month","week","datetime","datetime-local"],n=t.length,i="test",o={},r=0;r<n;r++)e=t[r],c.setAttribute("type",e),c.value=i,o[e.replace("-","")]="text"!==c.type&&c.value!==i;return o}(),c.style.cssText="float:left;",Se.cssFloat=!!c.style.cssFloat,c=null,Se.stableSort=function(){var e,t=513,n=[{index:0,field:"b"}];for(e=1;e<t;e++)n.push({index:e,field:"a"});return n.sort(function(e,t){return e.field>t.field?1:e.field<t.field?-1:0}),1===n[0].index}(),Se.matchesSelector=a.webkitMatchesSelector||a.mozMatchesSelector||a.msMatchesSelector||a.oMatchesSelector||a.matchesSelector||a.matches||function(t){for(var n=document.querySelectorAll?(this.parentNode||document).querySelectorAll(t)||[]:e(t),i=n.length;i--;)if(n[i]==this)return!0;return!1},Se.pushState=t.history&&t.history.pushState,u=document.documentMode,Se.hashChange="onhashchange"in t&&!(Se.browser.msie&&(!u||u<=8)),Se.customElements="registerElement"in t.document,h=Se.browser.chrome,Se.msPointers=!h&&t.MSPointerEvent,Se.pointers=!h&&t.PointerEvent,Se.kineticScrollNeeded=l&&(Se.touch||Se.msPointers||Se.pointers)}(),W={left:{reverse:"right"},right:{reverse:"left"},down:{reverse:"up"},up:{reverse:"down"},top:{reverse:"bottom"},bottom:{reverse:"top"},"in":{reverse:"out"},out:{reverse:"in"}},q={},e.extend(q,{enabled:!0,Element:function(t){this.element=e(t)},promise:function(e,t){e.is(":visible")||e.css({display:e.data("olddisplay")||"block"}).css("display"),t.hide&&e.data("olddisplay",e.css("display")).hide(),t.init&&t.init(),t.completeCallback&&t.completeCallback(e),e.dequeue()},disable:function(){this.enabled=!1,this.promise=this.promiseShim},enable:function(){this.enabled=!0,this.promise=this.animatedPromise}}),q.promiseShim=q.promise,"kendoAnimate"in e.fn||_e(e.fn,{kendoStop:function(e,t){return this.stop(e,t)},kendoAnimate:function(e,t,n,i){return y(this,e,t,n,i)},kendoAddClass:function(e,t){return ve.toggleClass(this,e,t,!0)},kendoRemoveClass:function(e,t){return ve.toggleClass(this,e,t,!1)},kendoToggleClass:function(e,t,n){return ve.toggleClass(this,e,t,n)}}),j=/&/g,G=/</g,$=/"/g,Y=/'/g,K=/>/g,Q=function(e){return e.target},Se.touch&&(Q=function(e){var t="originalEvent"in e?e.originalEvent.changedTouches:"changedTouches"in e?e.changedTouches:null;return t?document.elementFromPoint(t[0].clientX,t[0].clientY):e.target},be(["swipe","swipeLeft","swipeRight","swipeUp","swipeDown","doubleTap","tap"],function(t,n){e.fn[n]=function(e){return this.bind(n,e)}})),Se.touch?Se.mobileOS?(Se.mousedown="touchstart",Se.mouseup="touchend",Se.mousemove="touchmove",Se.mousecancel="touchcancel",Se.click="touchend",Se.resize="orientationchange"):(Se.mousedown="mousedown touchstart",Se.mouseup="mouseup touchend",Se.mousemove="mousemove touchmove",Se.mousecancel="mouseleave touchcancel",Se.click="click",Se.resize="resize"):Se.pointers?(Se.mousemove="pointermove",Se.mousedown="pointerdown",Se.mouseup="pointerup",Se.mousecancel="pointercancel",Se.click="pointerup",Se.resize="orientationchange resize"):Se.msPointers?(Se.mousemove="MSPointerMove",Se.mousedown="MSPointerDown",Se.mouseup="MSPointerUp",Se.mousecancel="MSPointerCancel",Se.click="MSPointerUp",Se.resize="orientationchange resize"):(Se.mousemove="mousemove",Se.mousedown="mousedown",Se.mouseup="mouseup",Se.mousecancel="mouseleave",Se.click="click",Se.resize="resize"),X=function(e,t){var n,i,o,r,s=t||"d",a=1;for(i=0,o=e.length;i<o;i++)r=e[i],""!==r&&(n=r.indexOf("["),0!==n&&(n==-1?r="."+r:(a++,r="."+r.substring(0,n)+" || {})"+r.substring(n))),a++,s+=r+(i<o-1?" || {})":")"));return Array(a).join("(")+s},Z=/^([a-z]+:)?\/\//i,_e(ve,{widgets:[],_widgetRegisteredCallbacks:[],ui:ve.ui||{},fx:ve.fx||b,effects:ve.effects||q,mobile:ve.mobile||{},data:ve.data||{},dataviz:ve.dataviz||{},drawing:ve.drawing||{},spreadsheet:{messages:{}},keys:{INSERT:45,DELETE:46,BACKSPACE:8,TAB:9,ENTER:13,ESC:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,END:35,HOME:36,SPACEBAR:32,PAGEUP:33,PAGEDOWN:34,F2:113,F10:121,F12:123,NUMPAD_PLUS:107,NUMPAD_MINUS:109,NUMPAD_DOT:110},support:ve.support||Se,animate:ve.animate||y,ns:"",attr:function(e){return"data-"+ve.ns+e},getShadows:s,wrap:a,deepExtend:l,getComputedStyles:f,webComponents:ve.webComponents||[],isScrollable:p,scrollLeft:m,size:g,toCamelCase:h,toHyphens:u,getOffset:ve.getOffset||v,parseEffects:ve.parseEffects||_,toggleClass:ve.toggleClass||k,directions:ve.directions||W,Observable:P,Class:i,Template:I,template:ye(I.compile,I),render:ye(I.render,I),stringify:ye(Ce.stringify,Ce),eventTarget:Q,htmlEncode:x,isLocalUrl:function(e){return e&&!Z.test(e)},expr:function(e,t,n){return e=e||"",typeof t==Ie&&(n=t,t=!1),n=n||"d",e&&"["!==e.charAt(0)&&(e="."+e),t?(e=e.replace(/"([^.]*)\.([^"]*)"/g,'"$1_$DOT$_$2"'),e=e.replace(/'([^.]*)\.([^']*)'/g,"'$1_$DOT$_$2'"),e=X(e.split("."),n),e=e.replace(/_\$DOT\$_/g,".")):e=n+e,e},getter:function(e,t){var n=e+t;return Le[n]=Le[n]||Function("d","return "+ve.expr(e,t))},setter:function(e){return He[e]=He[e]||Function("d,value",ve.expr(e)+"=value")},accessor:function(e){return{get:ve.getter(e),set:ve.setter(e)}},guid:function(){var e,t,n="";for(e=0;e<32;e++)t=16*xe.random()|0,8!=e&&12!=e&&16!=e&&20!=e||(n+="-"),n+=(12==e?4:16==e?3&t|8:t).toString(16);return n},roleSelector:function(e){return e.replace(/(\S+)/g,"["+ve.attr("role")+"=$1],").slice(0,-1)},directiveSelector:function(e){var t,n=e.split(" ");if(n)for(t=0;t<n.length;t++)"view"!=n[t]&&(n[t]=n[t].replace(/(\w*)(view|bar|strip|over)$/,"$1-$2"));return n.join(" ").replace(/(\S+)/g,"kendo-mobile-$1,").slice(0,-1)},triggeredByInput:function(e){return/^(label|input|textarea|select)$/i.test(e.target.tagName)},onWidgetRegistered:function(e){for(var t=0,n=ve.widgets.length;t<n;t++)e(ve.widgets[t]);ve._widgetRegisteredCallbacks.push(e)},logToConsole:function(e,i){var o=t.console;!ve.suppressLog&&n!==o&&o.log&&o[i||"log"](e)}}),J=P.extend({init:function(e,t){var n,i=this;i.element=ve.jQuery(e).handler(i),
i.angular("init",t),P.fn.init.call(i),n=t?t.dataSource:null,n&&(t=_e({},t,{dataSource:{}})),t=i.options=_e(!0,{},i.options,t),n&&(t.dataSource=n),i.element.attr(ve.attr("role"))||i.element.attr(ve.attr("role"),(t.name||"").toLowerCase()),i.element.data("kendo"+t.prefix+t.name,i),i.bind(i.events,t)},events:[],options:{prefix:""},_hasBindingTarget:function(){return!!this.element[0].kendoBindingTarget},_tabindex:function(e){e=e||this.wrapper;var t=this.element,n="tabindex",i=e.attr(n)||t.attr(n);t.removeAttr(n),e.attr(n,isNaN(i)?0:i)},setOptions:function(t){this._setEvents(t),e.extend(this.options,t)},_setEvents:function(e){for(var t,n=this,i=0,o=n.events.length;i<o;i++)t=n.events[i],n.options[t]&&e[t]&&n.unbind(t,n.options[t]);n.bind(n.events,e)},resize:function(e){var t=this.getSize(),n=this._size;(e||(t.width>0||t.height>0)&&(!n||t.width!==n.width||t.height!==n.height))&&(this._size=t,this._resize(t,e),this.trigger("resize",t))},getSize:function(){return ve.dimensions(this.element)},size:function(e){return e?(this.setSize(e),n):this.getSize()},setSize:e.noop,_resize:e.noop,destroy:function(){var e=this;e.element.removeData("kendo"+e.options.prefix+e.options.name),e.element.removeData("handler"),e.unbind()},_destroy:function(){this.destroy()},angular:function(){},_muteAngularRebind:function(e){this._muteRebind=!0,e.call(this),this._muteRebind=!1}}),ee=J.extend({dataItems:function(){return this.dataSource.flatView()},_angularItems:function(t){var n=this;n.angular(t,function(){return{elements:n.items(),data:e.map(n.dataItems(),function(e){return{dataItem:e}})}})}}),ve.dimensions=function(e,t){var n=e[0];return t&&e.css(t),{width:n.offsetWidth,height:n.offsetHeight}},ve.notify=ke,te=/template$/i,ne=/^\s*(?:\{(?:.|\r\n|\n)*\}|\[(?:.|\r\n|\n)*\])\s*$/,ie=/^\{(\d+)(:[^\}]+)?\}|^\[[A-Za-z_]+\]$/,oe=/([A-Z])/g,ve.initWidget=function(i,o,r){var s,a,l,c,d,u,h,f,p,m,g,v,_;if(r?r.roles&&(r=r.roles):r=ve.ui.roles,i=i.nodeType?i:i[0],u=i.getAttribute("data-"+ve.ns+"role")){p=u.indexOf(".")===-1,l=p?r[u]:ve.getter(u)(t),g=e(i).data(),v=l?"kendo"+l.fn.options.prefix+l.fn.options.name:"",m=p?RegExp("^kendo.*"+u+"$","i"):RegExp("^"+v+"$","i");for(_ in g)if(_.match(m)){if(_!==v)return g[_];s=g[_]}if(l){for(f=C(i,"dataSource"),o=e.extend({},S(i,l.fn.options),o),f&&(o.dataSource=typeof f===Ie?ve.getter(f)(t):f),c=0,d=l.fn.events.length;c<d;c++)a=l.fn.events[c],h=C(i,a),h!==n&&(o[a]=ve.getter(h)(t));return s?e.isEmptyObject(o)||s.setOptions(o):s=new l(i,o),s}}},ve.rolesFromNamespaces=function(e){var t,n,i=[];for(e[0]||(e=[ve.ui,ve.dataviz.ui]),t=0,n=e.length;t<n;t++)i[t]=e[t].roles;return _e.apply(null,[{}].concat(i.reverse()))},ve.init=function(t){var n=ve.rolesFromNamespaces(Ne.call(arguments,1));e(t).find("[data-"+ve.ns+"role]").addBack().each(function(){ve.initWidget(this,{},n)})},ve.destroy=function(t){e(t).find("[data-"+ve.ns+"role]").addBack().each(function(){var t,n=e(this).data();for(t in n)0===t.indexOf("kendo")&&typeof n[t].destroy===Me&&n[t].destroy()})},ve.resize=function(t,n){var i,o=e(t).find("[data-"+ve.ns+"role]").addBack().filter(D);o.length&&(i=e.makeArray(o),i.sort(T),e.each(i,function(){var t=ve.widgetInstance(e(this));t&&t.resize(n)}))},ve.parseOptions=S,_e(ve.ui,{Widget:J,DataBoundWidget:ee,roles:{},progress:function(t,n){var i,o,r,s,a=t.find(".k-loading-mask"),l=ve.support,c=l.browser;n?a.length||(i=l.isRtl(t),o=i?"right":"left",s=t.scrollLeft(),r=c.webkit&&i?t[0].scrollWidth-t.width()-2*s:0,a=e("<div class='k-loading-mask'><span class='k-loading-text'>"+ve.ui.progress.messages.loading+"</span><div class='k-loading-image'/><div class='k-loading-color'/></div>").width("100%").height("100%").css("top",t.scrollTop()).css(o,Math.abs(s)+r).prependTo(t)):a&&a.remove()},plugin:function(t,i,o){var r,s,a,l,c=t.fn.options.name;for(i=i||ve.ui,o=o||"",i[c]=t,i.roles[c.toLowerCase()]=t,r="getKendo"+o+c,c="kendo"+o+c,s={name:c,widget:t,prefix:o||""},ve.widgets.push(s),a=0,l=ve._widgetRegisteredCallbacks.length;a<l;a++)ve._widgetRegisteredCallbacks[a](s);e.fn[c]=function(i){var o,r=this;return typeof i===Ie?(o=Ne.call(arguments,1),this.each(function(){var t,s,a=e.data(this,c);if(!a)throw Error(ve.format("Cannot call method '{0}' of {1} before it is initialized",i,c));if(t=a[i],typeof t!==Me)throw Error(ve.format("Cannot find method '{0}' of {1}",i,c));if(s=t.apply(a,o),s!==n)return r=s,!1})):this.each(function(){return new t(this,i)}),r},e.fn[c].widget=t,e.fn[r]=function(){return this.data(c)}}}),ve.ui.progress.messages={loading:"Loading..."},re={bind:function(){return this},nullObject:!0,options:{}},se=J.extend({init:function(e,t){J.fn.init.call(this,e,t),this.element.autoApplyNS(),this.wrapper=this.element,this.element.addClass("km-widget")},destroy:function(){J.fn.destroy.call(this),this.element.kendoDestroy()},options:{prefix:"Mobile"},events:[],view:function(){var e=this.element.closest(ve.roleSelector("view splitview modalview drawer"));return ve.widgetInstance(e,ve.mobile.ui)||re},viewHasNativeScrolling:function(){var e=this.view();return e&&e.options.useNativeScrolling},container:function(){var e=this.element.closest(ve.roleSelector("view layout modalview drawer splitview"));return ve.widgetInstance(e.eq(0),ve.mobile.ui)||re}}),_e(ve.mobile,{init:function(e){ve.init(e,ve.mobile.ui,ve.ui,ve.dataviz.ui)},appLevelNativeScrolling:function(){return ve.mobile.application&&ve.mobile.application.options&&ve.mobile.application.options.useNativeScrolling},roles:{},ui:{Widget:se,DataBoundWidget:ee.extend(se.prototype),roles:{},plugin:function(e){ve.ui.plugin(e,ve.mobile.ui,"Mobile")}}}),l(ve.dataviz,{init:function(e){ve.init(e,ve.dataviz.ui)},ui:{roles:{},themes:{},views:[],plugin:function(e){ve.ui.plugin(e,ve.dataviz.ui)}},roles:{}}),ve.touchScroller=function(t,n){return n||(n={}),n.useNative=!0,e(t).map(function(t,i){return i=e(i),!(!Se.kineticScrollNeeded||!ve.mobile.ui.Scroller||i.data("kendoMobileScroller"))&&(i.kendoMobileScroller(n),i.data("kendoMobileScroller"))})[0]},ve.preventDefault=function(e){e.preventDefault()},ve.widgetInstance=function(e,n){var i,o,r,s,a=e.data(ve.ns+"role"),l=[];if(a){if("content"===a&&(a="scroller"),n)if(n[0])for(i=0,o=n.length;i<o;i++)l.push(n[i].roles[a]);else l.push(n.roles[a]);else l=[ve.ui.roles[a],ve.dataviz.ui.roles[a],ve.mobile.ui.roles[a]];for(a.indexOf(".")>=0&&(l=[ve.getter(a)(t)]),i=0,o=l.length;i<o;i++)if(r=l[i],r&&(s=e.data("kendo"+r.fn.options.prefix+r.fn.options.name)))return s}},ve.onResize=function(n){var i=n;return Se.mobileOS.android&&(i=function(){setTimeout(n,600)}),e(t).on(Se.resize,i),i},ve.unbindResize=function(n){e(t).off(Se.resize,n)},ve.attrValue=function(e,t){return e.data(ve.ns+t)},ve.days={Sunday:0,Monday:1,Tuesday:2,Wednesday:3,Thursday:4,Friday:5,Saturday:6},e.extend(e.expr[":"],{kendoFocusable:function(t){var n=e.attr(t,"tabindex");return A(t,!isNaN(n)&&n>-1)}}),ae=["mousedown","mousemove","mouseenter","mouseleave","mouseover","mouseout","mouseup","click"],le="label, input, [data-rel=external]",ce={setupMouseMute:function(){var t,n=0,i=ae.length,o=document.documentElement;if(!ce.mouseTrap&&Se.eventCapture)for(ce.mouseTrap=!0,ce.bustClick=!1,ce.captureMouse=!1,t=function(t){ce.captureMouse&&("click"===t.type?ce.bustClick&&!e(t.target).is(le)&&(t.preventDefault(),t.stopPropagation()):t.stopPropagation())};n<i;n++)o.addEventListener(ae[n],t,!0)},muteMouse:function(e){ce.captureMouse=!0,e.data.bustClick&&(ce.bustClick=!0),clearTimeout(ce.mouseTrapTimeoutID)},unMuteMouse:function(){clearTimeout(ce.mouseTrapTimeoutID),ce.mouseTrapTimeoutID=setTimeout(function(){ce.captureMouse=!1,ce.bustClick=!1},400)}},de={down:"touchstart mousedown",move:"mousemove touchmove",up:"mouseup touchend touchcancel",cancel:"mouseleave touchcancel"},Se.touch&&(Se.mobileOS.ios||Se.mobileOS.android)?de={down:"touchstart",move:"touchmove",up:"touchend touchcancel",cancel:"touchcancel"}:Se.pointers?de={down:"pointerdown",move:"pointermove",up:"pointerup",cancel:"pointercancel pointerleave"}:Se.msPointers&&(de={down:"MSPointerDown",move:"MSPointerMove",up:"MSPointerUp",cancel:"MSPointerCancel MSPointerLeave"}),!Se.msPointers||"onmspointerenter"in t||e.each({MSPointerEnter:"MSPointerOver",MSPointerLeave:"MSPointerOut"},function(t,n){e.event.special[t]={delegateType:n,bindType:n,handle:function(t){var i,o=this,r=t.relatedTarget,s=t.handleObj;return r&&(r===o||e.contains(o,r))||(t.type=s.origType,i=s.handler.apply(this,arguments),t.type=n),i}}}),ue=function(e){return de[e]||e},he=/([^ ]+)/g,ve.applyEventMap=function(e,t){return e=e.replace(he,ue),t&&(e=e.replace(he,"$1."+t)),e},fe=e.fn.on,_e(!0,M,e),M.fn=M.prototype=new e,M.fn.constructor=M,M.fn.init=function(t,n){return n&&n instanceof e&&!(n instanceof M)&&(n=M(n)),e.fn.init.call(this,t,n,pe)},M.fn.init.prototype=M.fn,pe=M(document),_e(M.fn,{handler:function(e){return this.data("handler",e),this},autoApplyNS:function(e){return this.data("kendoNS",e||ve.guid()),this},on:function(){var e,t,n,i,o,r,s=this,a=s.data("kendoNS");return 1===arguments.length?fe.call(s,arguments[0]):(e=s,t=Ne.call(arguments),typeof t[t.length-1]===Be&&t.pop(),n=t[t.length-1],i=ve.applyEventMap(t[0],a),Se.mouseAndTouchPresent&&i.search(/mouse|click/)>-1&&this[0]!==document.documentElement&&(ce.setupMouseMute(),o=2===t.length?null:t[1],r=i.indexOf("click")>-1&&i.indexOf("touchend")>-1,fe.call(this,{touchstart:ce.muteMouse,touchend:ce.unMuteMouse},o,{bustClick:r})),typeof n===Ie&&(e=s.data("handler"),n=e[n],t[t.length-1]=function(t){n.call(e,t)}),t[0]=i,fe.apply(s,t),s)},kendoDestroy:function(e){return e=e||this.data("kendoNS"),e&&this.off("."+e),this}}),ve.jQuery=M,ve.eventMap=de,ve.timezone=function(){function e(e,t){var n,i,o,r=t[3],s=t[4],a=t[5],l=t[8];return l||(t[8]=l={}),l[e]?l[e]:(isNaN(s)?0===s.indexOf("last")?(n=new Date(Date.UTC(e,d[r]+1,1,a[0]-24,a[1],a[2],0)),i=u[s.substr(4,3)],o=n.getUTCDay(),n.setUTCDate(n.getUTCDate()+i-o-(i>o?7:0))):s.indexOf(">=")>=0&&(n=new Date(Date.UTC(e,d[r],s.substr(5),a[0],a[1],a[2],0)),i=u[s.substr(0,3)],o=n.getUTCDay(),n.setUTCDate(n.getUTCDate()+i-o+(i<o?7:0))):n=new Date(Date.UTC(e,d[r],s,a[0],a[1],a[2],0)),l[e]=n)}function t(t,n,i){var o,r,s,a;return(n=n[i])?(s=new Date(t).getUTCFullYear(),n=jQuery.grep(n,function(e){var t=e[0],n=e[1];return t<=s&&(n>=s||t==s&&"only"==n||"max"==n)}),n.push(t),n.sort(function(t,n){return"number"!=typeof t&&(t=+e(s,t)),"number"!=typeof n&&(n=+e(s,n)),t-n}),a=n[jQuery.inArray(t,n)-1]||n[n.length-1],isNaN(a)?a:null):(o=i.split(":"),r=0,o.length>1&&(r=60*o[0]+ +o[1]),[-1e6,"max","-","Jan",1,[0,0,0],r,"-"])}function n(e,t,n){var i,o,r,s=t[n];if("string"==typeof s&&(s=t[s]),!s)throw Error('Timezone "'+n+'" is either incorrect, or kendo.timezones.min.js is not included.');for(i=s.length-1;i>=0&&(o=s[i][3],!(o&&e>o));i--);if(r=s[i+1],!r)throw Error('Timezone "'+n+'" not found on '+e+".");return r}function i(e,i,o,r){typeof e!=Re&&(e=Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));var s=n(e,i,r);return{zone:s,rule:t(e,o,s[1])}}function o(e,t){var n,o,r;return"Etc/UTC"==t||"Etc/GMT"==t?0:(n=i(e,this.zones,this.rules,t),o=n.zone,r=n.rule,ve.parseFloat(r?o[0]-r[6]:o[0]))}function r(e,t){var n=i(e,this.zones,this.rules,t),o=n.zone,r=n.rule,s=o[2];return s.indexOf("/")>=0?s.split("/")[r&&+r[6]?1:0]:s.indexOf("%s")>=0?s.replace("%s",r&&"-"!=r[7]?r[7]:""):s}function s(e,t,n){var i,o;return typeof t==Ie&&(t=this.offset(e,t)),typeof n==Ie&&(n=this.offset(e,n)),i=e.getTimezoneOffset(),e=new Date(e.getTime()+6e4*(t-n)),o=e.getTimezoneOffset(),new Date(e.getTime()+6e4*(o-i))}function a(e,t){return this.convert(e,e.getTimezoneOffset(),t)}function l(e,t){return this.convert(e,t,e.getTimezoneOffset())}function c(e){return this.apply(new Date(e),"Etc/UTC")}var d={Jan:0,Feb:1,Mar:2,Apr:3,May:4,Jun:5,Jul:6,Aug:7,Sep:8,Oct:9,Nov:10,Dec:11},u={Sun:0,Mon:1,Tue:2,Wed:3,Thu:4,Fri:5,Sat:6};return{zones:{},rules:{},offset:o,convert:s,apply:a,remove:l,abbr:r,toLocalDate:c}}(),ve.date=function(){function e(e,t){return 0===t&&23===e.getHours()&&(e.setHours(e.getHours()+2),!0)}function t(t,n,i){var o=t.getHours();i=i||1,n=(n-t.getDay()+7*i)%7,t.setDate(t.getDate()+n),e(t,o)}function n(e,n,i){return e=new Date(e),t(e,n,i),e}function i(e){return new Date(e.getFullYear(),e.getMonth(),1)}function o(e){var t=new Date(e.getFullYear(),e.getMonth()+1,0),n=i(e),o=Math.abs(t.getTimezoneOffset()-n.getTimezoneOffset());return o&&t.setHours(n.getHours()+o/60),t}function r(e,t){return 1!==t?f(n(e,t,-1),4):f(e,4-(e.getDay()||7))}function s(e,t){var n=new Date(e.getFullYear(),0,1,(-6)),i=r(e,t),o=i.getTime()-n.getTime(),s=Math.floor(o/w);return 1+Math.floor(s/7)}function a(e,t){var n=f(e,-7),i=f(e,7),o=s(e,t);return 0===o?s(n,t)+1:53===o&&s(i,t)>1?1:o}function l(t){return t=new Date(t.getFullYear(),t.getMonth(),t.getDate(),0,0,0),e(t,0),t}function c(e){return Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())}function d(e){return e.getTime()-l(e)}function u(e,t,n){var i,o=d(t),r=d(n);return!e||o==r||(t>=n&&(n+=w),i=d(e),o>i&&(i+=w),r<o&&(r+=w),i>=o&&i<=r)}function h(e,t,n){var i,o=t.getTime(),r=n.getTime();return o>=r&&(r+=w),i=e.getTime(),i>=o&&i<=r}function f(t,n){var i=t.getHours();return t=new Date(t),p(t,n*w),e(t,i),t}function p(e,t,n){var i,o=e.getTimezoneOffset();e.setTime(e.getTime()+t),n||(i=e.getTimezoneOffset()-o,e.setTime(e.getTime()+i*b))}function m(t,n){return t=new Date(ve.date.getDate(t).getTime()+ve.date.getMilliseconds(n)),e(t,n.getHours()),t}function g(){return l(new Date)}function v(e){return l(e).getTime()==g().getTime()}function _(e){var t=new Date(1980,1,1,0,0,0);return e&&t.setHours(e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()),t}var b=6e4,w=864e5;return{adjustDST:e,dayOfWeek:n,setDayOfWeek:t,getDate:l,isInDateRange:h,isInTimeRange:u,isToday:v,nextDay:function(e){return f(e,1)},previousDay:function(e){return f(e,-1)},toUtcTime:c,MS_PER_DAY:w,MS_PER_HOUR:60*b,MS_PER_MINUTE:b,setTime:p,setHours:m,addDays:f,today:g,toInvariantTime:_,firstDayOfMonth:i,lastDayOfMonth:o,weekInYear:a,getMilliseconds:d}}(),ve.stripWhitespace=function(e){var t,n,i;if(document.createNodeIterator)for(t=document.createNodeIterator(e,NodeFilter.SHOW_TEXT,function(t){return t.parentNode==e?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_REJECT},!1);t.nextNode();)t.referenceNode&&!t.referenceNode.textContent.trim()&&t.referenceNode.parentNode.removeChild(t.referenceNode);else for(n=0;n<e.childNodes.length;n++)i=e.childNodes[n],3!=i.nodeType||/\S/.test(i.nodeValue)||(e.removeChild(i),n--),1==i.nodeType&&ve.stripWhitespace(i)},me=t.requestAnimationFrame||t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.oRequestAnimationFrame||t.msRequestAnimationFrame||function(e){setTimeout(e,1e3/60)},ve.animationFrame=function(e){me.call(t,e)},ge=[],ve.queueAnimation=function(e){ge[ge.length]=e,1===ge.length&&ve.runNextAnimation()},ve.runNextAnimation=function(){ve.animationFrame(function(){ge[0]&&(ge.shift()(),ge[0]&&ve.runNextAnimation())})},ve.parseQueryStringParams=function(e){for(var t=e.split("?")[1]||"",n={},i=t.split(/&|=/),o=i.length,r=0;r<o;r+=2)""!==i[r]&&(n[decodeURIComponent(i[r])]=decodeURIComponent(i[r+1]));return n},ve.elementUnderCursor=function(e){if(n!==e.x.client)return document.elementFromPoint(e.x.client,e.y.client)},ve.wheelDeltaY=function(e){var t,i=e.originalEvent,o=i.wheelDeltaY;return i.wheelDelta?(o===n||o)&&(t=i.wheelDelta):i.detail&&i.axis===i.VERTICAL_AXIS&&(t=10*-i.detail),t},ve.throttle=function(e,t){var i,o,r=0;return!t||t<=0?e:(o=function(){function o(){e.apply(s,l),r=+new Date}var s=this,a=+new Date-r,l=arguments;return r?(i&&clearTimeout(i),a>t?o():i=setTimeout(o,t-a),n):o()},o.cancel=function(){clearTimeout(i)},o)},ve.caret=function(t,i,o){var r,s,a,l,c,d=i!==n;if(o===n&&(o=i),t[0]&&(t=t[0]),!d||!t.disabled){try{t.selectionStart!==n?d?(t.focus(),s=Se.mobileOS,s.wp||s.android?setTimeout(function(){t.setSelectionRange(i,o)},0):t.setSelectionRange(i,o)):i=[t.selectionStart,t.selectionEnd]:document.selection&&(e(t).is(":visible")&&t.focus(),r=t.createTextRange(),d?(r.collapse(!0),r.moveStart("character",i),r.moveEnd("character",o-i),r.select()):(a=r.duplicate(),r.moveToBookmark(document.selection.createRange().getBookmark()),a.setEndPoint("EndToStart",r),l=a.text.length,c=l+r.text.length,i=[l,c]))}catch(u){i=[]}return i}},ve.compileMobileDirective=function(e,n){var i=t.angular;return e.attr("data-"+ve.ns+"role",e[0].tagName.toLowerCase().replace("kendo-mobile-","").replace("-","")),i.element(e).injector().invoke(["$compile",function(t){t(e)(n),/^\$(digest|apply)$/.test(n.$$phase)||n.$digest()}]),ve.widgetInstance(e,ve.mobile.ui)},ve.antiForgeryTokens=function(){var t={},i=e("meta[name=csrf-token],meta[name=_csrf]").attr("content"),o=e("meta[name=csrf-param],meta[name=_csrf_header]").attr("content");return e("input[name^='__RequestVerificationToken']").each(function(){t[this.name]=this.value}),o!==n&&i!==n&&(t[o]=i),t},ve.cycleForm=function(e){function t(e){var t=ve.widgetInstance(e);t&&t.focus?t.focus():e.focus()}var n=e.find("input, .k-widget").first(),i=e.find("button, .k-button").last();i.on("keydown",function(e){e.keyCode!=ve.keys.TAB||e.shiftKey||(e.preventDefault(),t(n))}),n.on("keydown",function(e){e.keyCode==ve.keys.TAB&&e.shiftKey&&(e.preventDefault(),t(i))})},function(){function n(t,n,i,o){var r,s,a=e("<form>").attr({action:i,method:"POST",target:o}),l=ve.antiForgeryTokens();l.fileName=n,r=t.split(";base64,"),l.contentType=r[0].replace("data:",""),l.base64=r[1];for(s in l)l.hasOwnProperty(s)&&e("<input>").attr({value:l[s],name:s,type:"hidden"}).appendTo(a);a.appendTo("body").submit().remove()}function i(e,t){var n,i,o,r,s,a=e;if("string"==typeof e){for(n=e.split(";base64,"),i=n[0],o=atob(n[1]),r=new Uint8Array(o.length),s=0;s<o.length;s++)r[s]=o.charCodeAt(s);a=new Blob([r.buffer],{type:i})}navigator.msSaveBlob(a,t)}function o(e,n){t.Blob&&e instanceof Blob&&(e=URL.createObjectURL(e)),r.download=n,r.href=e;var i=document.createEvent("MouseEvents");i.initMouseEvent("click",!0,!1,t,0,0,0,0,0,!1,!1,!1,!1,0,null),r.dispatchEvent(i),setTimeout(function(){URL.revokeObjectURL(e)})}var r=document.createElement("a"),s="download"in r&&!ve.support.browser.edge;ve.saveAs=function(e){var t=n;e.forceProxy||(s?t=o:navigator.msSaveBlob&&(t=i)),t(e.dataURI,e.fileName,e.proxyURL,e.proxyTarget)}}(),ve.proxyModelSetters=function(e){var t={};return Object.keys(e||{}).forEach(function(n){Object.defineProperty(t,n,{get:function(){return e[n]},set:function(t){e[n]=t,e.dirty=!0}})}),t}}(jQuery,window),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.router.min",["kendo.core.min"],e)}(function(){return function(e,t){function n(e,t){if(!t)return e;e+"/"===t&&(e=t);var n=RegExp("^"+t,"i");return n.test(e)||(e=t+"/"+e),f.protocol+"//"+(f.host+"/"+e).replace(/\/\/+/g,"/")}function i(e){return e?"#!":"#"}function o(e){var t=f.href;return"#!"===e&&t.indexOf("#")>-1&&t.indexOf("#!")<0?null:t.split(e)[1]||""}function r(e,t){return 0===t.indexOf(e)?t.substr(e.length).replace(/\/\//g,"/"):t}function s(e){return e.replace(/^(#)?/,"#")}function a(e){return e.replace(/^(#(!)?)?/,"#!")}var l=window.kendo,c="change",d="back",u="same",h=l.support,f=window.location,p=window.history,m=50,g=l.support.browser.msie,v=/^#*/,_=window.document,b=l.Class.extend({back:function(){g?setTimeout(function(){p.back()}):p.back()},forward:function(){g?setTimeout(function(){p.forward()}):p.forward()},length:function(){return p.length},replaceLocation:function(e){f.replace(e)}}),w=b.extend({init:function(e){this.root=e},navigate:function(e){p.pushState({},_.title,n(e,this.root))},replace:function(e){p.replaceState({},_.title,n(e,this.root))},normalize:function(e){return r(this.root,e)},current:function(){var e=f.pathname;return f.search&&(e+=f.search),r(this.root,e)},change:function(t){e(window).bind("popstate.kendo",t)},stop:function(){e(window).unbind("popstate.kendo")},normalizeCurrent:function(e){var t,r=e.root,s=f.pathname,a=o(i(e.hashBang));r===s+"/"&&(t=r),r===s&&a&&(t=n(a.replace(v,""),r)),t&&p.pushState({},_.title,t)}}),y=b.extend({init:function(e){this._id=l.guid(),this.prefix=i(e),this.fix=e?a:s},navigate:function(e){f.hash=this.fix(e)},replace:function(e){this.replaceLocation(this.fix(e))},normalize:function(e){return e.indexOf(this.prefix)<0?e:e.split(this.prefix)[1]},change:function(t){h.hashChange?e(window).on("hashchange."+this._id,t):this._interval=setInterval(t,m)},stop:function(){e(window).off("hashchange."+this._id),clearInterval(this._interval)},current:function(){return o(this.prefix)},normalizeCurrent:function(e){var t=f.pathname,n=e.root;return!(!e.pushState||n===t)&&(this.replaceLocation(n+this.prefix+r(n,t)),!0)}}),k=l.Observable.extend({start:function(t){if(t=t||{},this.bind([c,d,u],t),!this._started){this._started=!0,t.root=t.root||"/";var n,i=this.createAdapter(t);i.normalizeCurrent(t)||(n=i.current(),e.extend(this,{adapter:i,root:t.root,historyLength:i.length(),current:n,locations:[n]}),i.change(e.proxy(this,"_checkUrl")))}},createAdapter:function(e){return h.pushState&&e.pushState?new w(e.root):new y(e.hashBang)},stop:function(){this._started&&(this.adapter.stop(),this.unbind(c),this._started=!1)},change:function(e){this.bind(c,e)},replace:function(e,t){this._navigate(e,t,function(t){t.replace(e),this.locations[this.locations.length-1]=this.current})},navigate:function(e,n){return"#:back"===e?(this.backCalled=!0,this.adapter.back(),t):(this._navigate(e,n,function(t){t.navigate(e),this.locations.push(this.current)}),t)},_navigate:function(e,n,i){var o=this.adapter;return e=o.normalize(e),this.current===e||this.current===decodeURIComponent(e)?(this.trigger(u),t):(!n&&this.trigger(c,{url:e,decode:!1})||(this.current=e,i.call(this,o),this.historyLength=o.length()),t)},_checkUrl:function(){var e=this.adapter,n=e.current(),i=e.length(),o=this.historyLength===i,r=n===this.locations[this.locations.length-2]&&o,s=this.backCalled,a=this.current;return null===n||this.current===n||this.current===decodeURIComponent(n)||(this.historyLength=i,this.backCalled=!1,this.current=n,r&&this.trigger("back",{url:a,to:n})?(e.forward(),this.current=a,t):this.trigger(c,{url:n,backButtonPressed:!s})?(r?e.forward():(e.back(),this.historyLength--),this.current=a,t):(r?this.locations.pop():this.locations.push(n),t))}});l.History=k,l.History.HistoryAdapter=b,l.History.HashAdapter=y,l.History.PushStateAdapter=w,l.absoluteURL=n,l.history=new k}(window.kendo.jQuery),function(){function e(e,t){return t?e:"([^/]+)"}function t(t,n){return RegExp("^"+t.replace(p,"\\$&").replace(u,"(?:$1)?").replace(h,e).replace(f,"(.*?)")+"$",n?"i":"")}function n(e){return e.replace(/(\?.*)|(#.*)/g,"")}var i=window.kendo,o=i.history,r=i.Observable,s="init",a="routeMissing",l="change",c="back",d="same",u=/\((.*?)\)/g,h=/(\(\?)?:\w+/g,f=/\*\w+/g,p=/[\-{}\[\]+?.,\\\^$|#\s]/g,m=i.Class.extend({init:function(e,n,i){e instanceof RegExp||(e=t(e,i)),this.route=e,this._callback=n},callback:function(e,t,o){var r,s,a=0,l=i.parseQueryStringParams(e);if(l._back=t,e=n(e),r=this.route.exec(e).slice(1),s=r.length,o)for(;a<s;a++)void 0!==r[a]&&(r[a]=decodeURIComponent(r[a]));r.push(l),this._callback.apply(null,r)},worksWith:function(e,t,i){return!!this.route.test(n(e))&&(this.callback(e,t,i),!0)}}),g=r.extend({init:function(e){e||(e={}),r.fn.init.call(this),this.routes=[],this.pushState=e.pushState,this.hashBang=e.hashBang,this.root=e.root,this.ignoreCase=e.ignoreCase!==!1,this.bind([s,a,l,d],e)},destroy:function(){o.unbind(l,this._urlChangedProxy),o.unbind(d,this._sameProxy),o.unbind(c,this._backProxy),this.unbind()},start:function(){var e,t=this,n=function(){t._same()},i=function(e){t._back(e)},r=function(e){t._urlChanged(e)};o.start({same:n,change:r,back:i,pushState:t.pushState,hashBang:t.hashBang,root:t.root}),e={url:o.current||"/",preventDefault:$.noop},t.trigger(s,e)||t._urlChanged(e),this._urlChangedProxy=r,this._backProxy=i},route:function(e,t){this.routes.push(new m(e,t,this.ignoreCase))},navigate:function(e,t){i.history.navigate(e,t)},replace:function(e,t){i.history.replace(e,t)},_back:function(e){this.trigger(c,{url:e.url,to:e.to})&&e.preventDefault()},_same:function(){this.trigger(d)},_urlChanged:function(e){var t,n,o,r,s=e.url,c=void 0===e.decode,d=e.backButtonPressed;if(s||(s="/"),this.trigger(l,{url:e.url,params:i.parseQueryStringParams(e.url),backButtonPressed:d}))return void e.preventDefault();for(t=0,n=this.routes,r=n.length;t<r;t++)if(o=n[t],o.worksWith(s,d,c))return;this.trigger(a,{url:s,params:i.parseQueryStringParams(s),backButtonPressed:d})&&e.preventDefault()}});i.Router=g}(),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.data.odata.min",["kendo.core.min"],e)}(function(){return function(e,t){function n(i,r){var l,c,d,u,h,f,p,m,g=[],v=i.logic||"and",_=i.filters;for(l=0,c=_.length;l<c;l++)i=_[l],d=i.field,p=i.value,f=i.operator,i.filters?i=n(i,r):(m=i.ignoreCase,d=d.replace(/\./g,"/"),i=s[f],r&&(i=a[f]),"isnull"===f||"isnotnull"===f?i=o.format("{0} {1} null",d,i):"isempty"===f||"isnotempty"===f?i=o.format("{0} {1} ''",d,i):i&&p!==t&&(u=e.type(p),"string"===u?(h="'{1}'",p=p.replace(/'/g,"''"),m===!0&&(d="tolower("+d+")")):"date"===u?r?(h="{1:yyyy-MM-ddTHH:mm:ss+00:00}",p=o.timezone.apply(p,"Etc/UTC")):h="datetime'{1:yyyy-MM-ddTHH:mm:ss}'":h="{1}",i.length>3?"substringof"!==i?h="{0}({2},"+h+")":(h="{0}("+h+",{2})","doesnotcontain"===f&&(r?(h="{0}({2},'{1}') eq -1",i="indexof"):h+=" eq false")):h="{2} {0} "+h,i=o.format(h,i,p,d))),g.push(i);return i=g.join(" "+v+" "),g.length>1&&(i="("+i+")"),i}function i(e){for(var t in e)0===t.indexOf("@odata")&&delete e[t]}var o=window.kendo,r=e.extend,s={eq:"eq",neq:"ne",gt:"gt",gte:"ge",lt:"lt",lte:"le",contains:"substringof",doesnotcontain:"substringof",endswith:"endswith",startswith:"startswith",isnull:"eq",isnotnull:"ne",isempty:"eq",isnotempty:"ne"},a=r({},s,{contains:"contains"}),l={pageSize:e.noop,page:e.noop,filter:function(e,t,i){t&&(t=n(t,i),t&&(e.$filter=t))},sort:function(t,n){var i=e.map(n,function(e){var t=e.field.replace(/\./g,"/");return"desc"===e.dir&&(t+=" desc"),t}).join(",");i&&(t.$orderby=i)},skip:function(e,t){t&&(e.$skip=t)},take:function(e,t){t&&(e.$top=t)}},c={read:{dataType:"jsonp"}};r(!0,o.data,{schemas:{odata:{type:"json",data:function(e){return e.d.results||[e.d]},total:"d.__count"}},transports:{odata:{read:{cache:!0,dataType:"jsonp",jsonp:"$callback"},update:{cache:!0,dataType:"json",contentType:"application/json",type:"PUT"},create:{cache:!0,dataType:"json",contentType:"application/json",type:"POST"},destroy:{cache:!0,dataType:"json",type:"DELETE"},parameterMap:function(e,t,n){var i,r,s,a;if(e=e||{},t=t||"read",a=(this.options||c)[t],a=a?a.dataType:"json","read"===t){i={$inlinecount:"allpages"},"json"!=a&&(i.$format="json");for(s in e)l[s]?l[s](i,e[s],n):i[s]=e[s]}else{if("json"!==a)throw Error("Only json dataType can be used for "+t+" operation.");if("destroy"!==t){for(s in e)r=e[s],"number"==typeof r&&(e[s]=r+"");i=o.stringify(e)}}return i}}}}),r(!0,o.data,{schemas:{"odata-v4":{type:"json",data:function(t){return t=e.extend({},t),i(t),t.value?t.value:[t]},total:function(e){return e["@odata.count"]}}},transports:{"odata-v4":{read:{cache:!0,dataType:"json"},update:{cache:!0,dataType:"json",contentType:"application/json;IEEE754Compatible=true",type:"PUT"},create:{cache:!0,dataType:"json",contentType:"application/json;IEEE754Compatible=true",type:"POST"},destroy:{cache:!0,dataType:"json",type:"DELETE"},parameterMap:function(e,t){var n=o.data.transports.odata.parameterMap(e,t,!0);return"read"==t&&(n.$count=!0,delete n.$inlinecount),n}}}})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.data.xml.min",["kendo.core.min"],e)}(function(){return function(e,t){var n=window.kendo,i=e.isArray,o=e.isPlainObject,r=e.map,s=e.each,a=e.extend,l=n.getter,c=n.Class,d=c.extend({init:function(t){var l,c,d,u,h=this,f=t.total,p=t.model,m=t.parse,g=t.errors,v=t.serialize,_=t.data;p&&(o(p)&&(l=t.modelBase||n.data.Model,p.fields&&s(p.fields,function(t,n){o(n)&&n.field?e.isFunction(n.field)||(n=a(n,{field:h.getter(n.field)})):n={field:h.getter(n)},p.fields[t]=n}),c=p.id,c&&(d={},d[h.xpathToMember(c,!0)]={field:h.getter(c)},p.fields=a(d,p.fields),p.id=h.xpathToMember(c)),p=l.define(p)),h.model=p),f&&("string"==typeof f?(f=h.getter(f),h.total=function(e){return parseInt(f(e),10)}):"function"==typeof f&&(h.total=f)),g&&("string"==typeof g?(g=h.getter(g),h.errors=function(e){return g(e)||null}):"function"==typeof g&&(h.errors=g)),_&&("string"==typeof _?(_=h.xpathToMember(_),h.data=function(e){var t,n=h.evaluate(e,_);return n=i(n)?n:[n],h.model&&p.fields?(t=new h.model,r(n,function(e){if(e){var n,i={};for(n in p.fields)i[n]=t._parse(n,p.fields[n].field(e));return i}})):n}):"function"==typeof _&&(h.data=_)),"function"==typeof m&&(u=h.parse,h.parse=function(e){var t=m.call(h,e);return u.call(h,t)}),"function"==typeof v&&(h.serialize=v)},total:function(e){return this.data(e).length},errors:function(e){return e?e.errors:null},serialize:function(e){return e},parseDOM:function(e){var n,o,r,s,a,l,c,d={},u=e.attributes,h=u.length;for(c=0;c<h;c++)l=u[c],d["@"+l.nodeName]=l.nodeValue;for(o=e.firstChild;o;o=o.nextSibling)r=o.nodeType,3===r||4===r?d["#text"]=o.nodeValue:1===r&&(n=this.parseDOM(o),s=o.nodeName,a=d[s],i(a)?a.push(n):a=a!==t?[a,n]:n,d[s]=a);return d},evaluate:function(e,t){for(var n,o,r,s,a,l=t.split(".");n=l.shift();)if(e=e[n],i(e)){for(o=[],t=l.join("."),a=0,r=e.length;a<r;a++)s=this.evaluate(e[a],t),s=i(s)?s:[s],o.push.apply(o,s);return o}return e},parse:function(t){var n,i,o={};return n=t.documentElement||e.parseXML(t).documentElement,i=this.parseDOM(n),o[n.nodeName]=i,o},xpathToMember:function(e,t){return e?(e=e.replace(/^\//,"").replace(/\//g,"."),e.indexOf("@")>=0?e.replace(/\.?(@.*)/,t?"$1":'["$1"]'):e.indexOf("text()")>=0?e.replace(/(\.?text\(\))/,t?"#text":'["#text"]'):e):""},getter:function(e){return l(this.xpathToMember(e),!0)}});e.extend(!0,n.data,{XmlDataReader:d,readers:{xml:d}})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.data.min",["kendo.core.min","kendo.data.odata.min","kendo.data.xml.min"],e)}(function(){return function(e,t){function n(e,t,n,i){return function(o){var r,s={};for(r in o)s[r]=o[r];s.field=i?n+"."+o.field:n,t==Ae&&e._notifyChange&&e._notifyChange(s),e.trigger(t,s)}}function i(t,n){if(t===n)return!0;var o,r=e.type(t),s=e.type(n);if(r!==s)return!1;if("date"===r)return t.getTime()===n.getTime();if("object"!==r&&"array"!==r)return!1;for(o in t)if(!i(t[o],n[o]))return!1;return!0}function o(e,t){var n,i;for(i in e){if(n=e[i],ue(n)&&n.field&&n.field===t)return n;if(n===t)return n}return null}function r(e){this.data=e||[]}function s(e,n){if(e){var i=typeof e===ke?{field:e,dir:n}:e,o=fe(i)?i:i!==t?[i]:[];return pe(o,function(e){return!!e.dir})}}function a(e){var t,n,i,o,r=e.filters;if(r)for(t=0,n=r.length;t<n;t++)i=r[t],o=i.operator,o&&typeof o===ke&&(i.operator=X[o.toLowerCase()]||o),a(i)}function l(e){if(e&&!he(e))return!fe(e)&&e.filters||(e={logic:"and",filters:fe(e)?e:[e]}),a(e),e}function c(e,t){return!e.logic&&!t.logic&&(e.field===t.field&&e.value===t.value&&e.operator===t.operator)}function d(e){return e=e||{},he(e)?{logic:"and",filters:[]}:l(e)}function u(e,t){return t.logic||e.field>t.field?1:e.field<t.field?-1:0}function h(e,t){var n,i,o,r,s;if(e=d(e),t=d(t),e.logic!==t.logic)return!1;if(o=(e.filters||[]).slice(),r=(t.filters||[]).slice(),o.length!==r.length)return!1;for(o=o.sort(u),r=r.sort(u),s=0;s<o.length;s++)if(n=o[s],i=r[s],n.logic&&i.logic){if(!h(n,i))return!1}else if(!c(n,i))return!1;return!0}function f(e){return fe(e)?e:[e]}function p(e,n){var i=typeof e===ke?{field:e,dir:n}:e,o=fe(i)?i:i!==t?[i]:[];return U(o,function(e){return{field:e.field,dir:e.dir||"asc",aggregates:e.aggregates
}})}function m(e,t){return e&&e.getTime&&t&&t.getTime?e.getTime()===t.getTime():e===t}function g(e,t,n,i,o,r){var s,a,l,c,d;for(t=t||[],c=t.length,s=0;s<c;s++)a=t[s],l=a.aggregate,d=a.field,e[d]=e[d]||{},r[d]=r[d]||{},r[d][l]=r[d][l]||{},e[d][l]=Z[l.toLowerCase()](e[d][l],n,_e.accessor(d),i,o,r[d][l])}function v(e){return"number"==typeof e&&!isNaN(e)}function _(e){return e&&e.getTime}function b(e){var t,n=e.length,i=Array(n);for(t=0;t<n;t++)i[t]=e[t].toJSON();return i}function w(e,t,n,i,o){var r,s,a,l,c,d={};for(l=0,c=e.length;l<c;l++){r=e[l];for(s in t)a=o[s],a&&a!==s&&(d[a]||(d[a]=_e.setter(a)),d[a](r,t[s](r)),delete r[s])}}function y(e,t,n,i,o){var r,s,a,l,c;for(l=0,c=e.length;l<c;l++){r=e[l];for(s in t)r[s]=n._parse(s,t[s](r)),a=o[s],a&&a!==s&&delete r[a]}}function k(e,t,n,i,o){var r,s,a,l;for(s=0,l=e.length;s<l;s++)r=e[s],a=i[r.field],a&&a!=r.field&&(r.field=a),r.value=n._parse(r.field,r.value),r.hasSubgroups?k(r.items,t,n,i,o):y(r.items,t,n,i,o)}function x(e,t,n,i,o,r){return function(s){return s=e(s),s&&!he(i)&&("[object Array]"===$e.call(s)||s instanceof Qe||(s=[s]),n(s,i,new t,o,r)),s||[]}}function C(e,t,n,i){for(var o,r,s,a=0;t.length&&i&&(o=t[a],r=o.items,s=r.length,e&&e.field===o.field&&e.value===o.value?(e.hasSubgroups&&e.items.length?C(e.items[e.items.length-1],o.items,n,i):(r=r.slice(n,n+i),e.items=e.items.concat(r)),t.splice(a--,1)):o.hasSubgroups&&r.length?(C(o,r,n,i),o.items.length||t.splice(a--,1)):(r=r.slice(n,n+i),o.items=r,o.items.length||t.splice(a--,1)),0===r.length?n-=s:(n=0,i-=r.length),!(++a>=t.length)););a<t.length&&t.splice(a,t.length-a)}function S(e){var t,n,i,o,r,s=[];for(t=0,n=e.length;t<n;t++)if(r=e.at(t),r.hasSubgroups)s=s.concat(S(r.items));else for(i=r.items,o=0;o<i.length;o++)s.push(i.at(o));return s}function T(e,t){var n,i,o;if(t)for(n=0,i=e.length;n<i;n++)o=e.at(n),o.hasSubgroups?T(o.items,t):o.items=new W(o.items,t)}function D(e,t){for(var n=0,i=e.length;n<i;n++)if(e[n].hasSubgroups){if(D(e[n].items,t))return!0}else if(t(e[n].items,e[n]))return!0}function A(e,t,n,i){for(var o=0;o<e.length&&e[o].data!==t&&!E(e[o].data,n,i);o++);}function E(e,t,n){for(var i=0,o=e.length;i<o;i++){if(e[i]&&e[i].hasSubgroups)return E(e[i].items,t,n);if(e[i]===t||e[i]===n)return e[i]=n,!0}}function M(e,n,i,o,r){var s,a,l,c;for(s=0,a=e.length;s<a;s++)if(l=e[s],l&&!(l instanceof o))if(l.hasSubgroups===t||r){for(c=0;c<n.length;c++)if(n[c]===l){e[s]=n.at(c),A(i,n,l,e[s]);break}}else M(l.items,n,i,o,r)}function I(e,t){var n,i,o;for(n=0,i=e.length;n<i;n++)if(o=e.at(n),o.uid==t.uid)return e.splice(n,1),o}function R(e,t){return t?z(e,function(e){return e.uid&&e.uid==t.uid||e[t.idField]===t.id&&t.id!==t._defaultId}):-1}function F(e,t){return t?z(e,function(e){return e.uid==t.uid}):-1}function z(e,t){var n,i;for(n=0,i=e.length;n<i;n++)if(t(e[n]))return n;return-1}function P(e,t){var n,i;return e&&!he(e)?(n=e[t],i=ue(n)?n.from||n.field||t:e[t]||t,be(i)?t:i):t}function B(e,t){var n,i,o,r={};for(o in e)"filters"!==o&&(r[o]=e[o]);if(e.filters)for(r.filters=[],n=0,i=e.filters.length;n<i;n++)r.filters[n]=B(e.filters[n],t);else r.field=P(t.fields,r.field);return r}function L(e,t){var n,i,o,r,s,a=[];for(n=0,i=e.length;n<i;n++){o={},r=e[n];for(s in r)o[s]=r[s];o.field=P(t.fields,o.field),o.aggregates&&fe(o.aggregates)&&(o.aggregates=L(o.aggregates,t)),a.push(o)}return a}function H(t,n){var i,o,r,s,a,l,c,d,u,h;for(t=e(t)[0],i=t.options,o=n[0],r=n[1],s=[],a=0,l=i.length;a<l;a++)u={},d=i[a],c=d.parentNode,c===t&&(c=null),d.disabled||c&&c.disabled||(c&&(u.optgroup=c.label),u[o.field]=d.text,h=d.attributes.value,h=h&&h.specified?d.value:d.text,u[r.field]=h,s.push(u));return s}function N(t,n){var i,o,r,s,a,l,c,d=e(t)[0].tBodies[0],u=d?d.rows:[],h=n.length,f=[];for(i=0,o=u.length;i<o;i++){for(a={},c=!0,s=u[i].cells,r=0;r<h;r++)l=s[r],"th"!==l.nodeName.toLowerCase()&&(c=!1,a[n[r].field]=l.innerHTML);c||f.push(a)}return f}function O(e){return function(){var t=this._data,n=ie.fn[e].apply(this,je.call(arguments));return this._data!=t&&this._attachBubbleHandlers(),n}}function V(t,n){function i(e,t){return e.filter(t).add(e.find(t))}var o,r,s,a,l,c,d,u,h=e(t).children(),f=[],p=n[0].field,m=n[1]&&n[1].field,g=n[2]&&n[2].field,v=n[3]&&n[3].field;for(o=0,r=h.length;o<r;o++)s={_loaded:!0},a=h.eq(o),c=a[0].firstChild,u=a.children(),t=u.filter("ul"),u=u.filter(":not(ul)"),l=a.attr("data-id"),l&&(s.id=l),c&&(s[p]=3==c.nodeType?c.nodeValue:u.text()),m&&(s[m]=i(u,"a").attr("href")),v&&(s[v]=i(u,"img").attr("src")),g&&(d=i(u,".k-sprite").prop("className"),s[g]=d&&e.trim(d.replace("k-sprite",""))),t.length&&(s.items=V(t.eq(0),n)),"true"==a.attr("data-hasChildren")&&(s.hasChildren=!0),f.push(s);return f}var U,W,q,j,G,$,Y,K,Q,X,Z,J,ee,te,ne,ie,oe,re,se,ae,le,ce=e.extend,de=e.proxy,ue=e.isPlainObject,he=e.isEmptyObject,fe=e.isArray,pe=e.grep,me=e.ajax,ge=e.each,ve=e.noop,_e=window.kendo,be=_e.isFunction,we=_e.Observable,ye=_e.Class,ke="string",xe="function",Ce="create",Se="read",Te="update",De="destroy",Ae="change",Ee="sync",Me="get",Ie="error",Re="requestStart",Fe="progress",ze="requestEnd",Pe=[Ce,Se,Te,De],Be=function(e){return e},Le=_e.getter,He=_e.stringify,Ne=Math,Oe=[].push,Ve=[].join,Ue=[].pop,We=[].splice,qe=[].shift,je=[].slice,Ge=[].unshift,$e={}.toString,Ye=_e.support.stableSort,Ke=/^\/Date\((.*?)\)\/$/,Qe=we.extend({init:function(e,t){var n=this;n.type=t||q,we.fn.init.call(n),n.length=e.length,n.wrapAll(e,n)},at:function(e){return this[e]},toJSON:function(){var e,t,n=this.length,i=Array(n);for(e=0;e<n;e++)t=this[e],t instanceof q&&(t=t.toJSON()),i[e]=t;return i},parent:ve,wrapAll:function(e,t){var n,i,o=this,r=function(){return o};for(t=t||[],n=0,i=e.length;n<i;n++)t[n]=o.wrap(e[n],r);return t},wrap:function(e,t){var n,i=this;return null!==e&&"[object Object]"===$e.call(e)&&(n=e instanceof i.type||e instanceof $,n||(e=e instanceof q?e.toJSON():e,e=new i.type(e)),e.parent=t,e.bind(Ae,function(e){i.trigger(Ae,{field:e.field,node:e.node,index:e.index,items:e.items||[this],action:e.node?e.action||"itemloaded":"itemchange"})})),e},push:function(){var e,t=this.length,n=this.wrapAll(arguments);return e=Oe.apply(this,n),this.trigger(Ae,{action:"add",index:t,items:n}),e},slice:je,sort:[].sort,join:Ve,pop:function(){var e=this.length,t=Ue.apply(this);return e&&this.trigger(Ae,{action:"remove",index:e-1,items:[t]}),t},splice:function(e,t,n){var i,o,r,s=this.wrapAll(je.call(arguments,2));if(i=We.apply(this,[e,t].concat(s)),i.length)for(this.trigger(Ae,{action:"remove",index:e,items:i}),o=0,r=i.length;o<r;o++)i[o]&&i[o].children&&i[o].unbind(Ae);return n&&this.trigger(Ae,{action:"add",index:e,items:s}),i},shift:function(){var e=this.length,t=qe.apply(this);return e&&this.trigger(Ae,{action:"remove",index:0,items:[t]}),t},unshift:function(){var e,t=this.wrapAll(arguments);return e=Ge.apply(this,t),this.trigger(Ae,{action:"add",index:0,items:t}),e},indexOf:function(e){var t,n,i=this;for(t=0,n=i.length;t<n;t++)if(i[t]===e)return t;return-1},forEach:function(e){for(var t=0,n=this.length;t<n;t++)e(this[t],t,this)},map:function(e){for(var t=0,n=[],i=this.length;t<i;t++)n[t]=e(this[t],t,this);return n},reduce:function(e){var t,n=0,i=this.length;for(2==arguments.length?t=arguments[1]:n<i&&(t=this[n++]);n<i;n++)t=e(t,this[n],n,this);return t},reduceRight:function(e){var t,n=this.length-1;for(2==arguments.length?t=arguments[1]:n>0&&(t=this[n--]);n>=0;n--)t=e(t,this[n],n,this);return t},filter:function(e){for(var t,n=0,i=[],o=this.length;n<o;n++)t=this[n],e(t,n,this)&&(i[i.length]=t);return i},find:function(e){for(var t,n=0,i=this.length;n<i;n++)if(t=this[n],e(t,n,this))return t},every:function(e){for(var t,n=0,i=this.length;n<i;n++)if(t=this[n],!e(t,n,this))return!1;return!0},some:function(e){for(var t,n=0,i=this.length;n<i;n++)if(t=this[n],e(t,n,this))return!0;return!1},remove:function(e){var t=this.indexOf(e);t!==-1&&this.splice(t,1)},empty:function(){this.splice(0,this.length)}});"undefined"!=typeof Symbol&&Symbol.iterator&&!Qe.prototype[Symbol.iterator]&&(Qe.prototype[Symbol.iterator]=[][Symbol.iterator]),W=Qe.extend({init:function(e,t){we.fn.init.call(this),this.type=t||q;for(var n=0;n<e.length;n++)this[n]=e[n];this.length=n,this._parent=de(function(){return this},this)},at:function(e){var t=this[e];return t instanceof this.type?t.parent=this._parent:t=this[e]=this.wrap(t,this._parent),t}}),q=we.extend({init:function(e){var t,n,i=this,o=function(){return i};we.fn.init.call(this),this._handlers={};for(n in e)t=e[n],"object"==typeof t&&t&&!t.getTime&&"_"!=n.charAt(0)&&(t=i.wrap(t,n,o)),i[n]=t;i.uid=_e.guid()},shouldSerialize:function(e){return this.hasOwnProperty(e)&&"_handlers"!==e&&"_events"!==e&&typeof this[e]!==xe&&"uid"!==e},forEach:function(e){for(var t in this)this.shouldSerialize(t)&&e(this[t],t)},toJSON:function(){var e,t,n={};for(t in this)this.shouldSerialize(t)&&(e=this[t],(e instanceof q||e instanceof Qe)&&(e=e.toJSON()),n[t]=e);return n},get:function(e){var t,n=this;return n.trigger(Me,{field:e}),t="this"===e?n:_e.getter(e,!0)(n)},_set:function(e,t){var n,i,o,r=this,s=e.indexOf(".")>=0;if(s)for(n=e.split("."),i="";n.length>1;){if(i+=n.shift(),o=_e.getter(i,!0)(r),o instanceof q)return o.set(n.join("."),t),s;i+="."}return _e.setter(e)(r,t),s},set:function(e,t){var n=this,i=!1,o=e.indexOf(".")>=0,r=_e.getter(e,!0)(n);return r!==t&&(r instanceof we&&this._handlers[e]&&(this._handlers[e].get&&r.unbind(Me,this._handlers[e].get),r.unbind(Ae,this._handlers[e].change)),i=n.trigger("set",{field:e,value:t}),i||(o||(t=n.wrap(t,e,function(){return n})),(!n._set(e,t)||e.indexOf("(")>=0||e.indexOf("[")>=0)&&n.trigger(Ae,{field:e}))),i},parent:ve,wrap:function(e,t,i){var o,r,s,a,l=this,c=$e.call(e);return null==e||"[object Object]"!==c&&"[object Array]"!==c||(s=e instanceof Qe,a=e instanceof ie,"[object Object]"!==c||a||s?("[object Array]"===c||s||a)&&(s||a||(e=new Qe(e)),r=n(l,Ae,t,!1),e.bind(Ae,r),l._handlers[t]={change:r}):(e instanceof q||(e=new q(e)),o=n(l,Me,t,!0),e.bind(Me,o),r=n(l,Ae,t,!0),e.bind(Ae,r),l._handlers[t]={get:o,change:r}),e.parent=i),e}}),j={number:function(e){return _e.parseFloat(e)},date:function(e){return _e.parseDate(e)},"boolean":function(e){return typeof e===ke?"true"===e.toLowerCase():null!=e?!!e:e},string:function(e){return null!=e?e+"":e},"default":function(e){return e}},G={string:"",number:0,date:new Date,"boolean":!1,"default":""},$=q.extend({init:function(n){var i,o,r=this;if((!n||e.isEmptyObject(n))&&(n=e.extend({},r.defaults,n),r._initializers))for(i=0;i<r._initializers.length;i++)o=r._initializers[i],n[o]=r.defaults[o]();q.fn.init.call(r,n),r.dirty=!1,r.idField&&(r.id=r.get(r.idField),r.id===t&&(r.id=r._defaultId))},shouldSerialize:function(e){return q.fn.shouldSerialize.call(this,e)&&"uid"!==e&&!("id"!==this.idField&&"id"===e)&&"dirty"!==e&&"_accessors"!==e},_parse:function(e,t){var n,i=this,r=e,s=i.fields||{};return e=s[e],e||(e=o(s,r)),e&&(n=e.parse,!n&&e.type&&(n=j[e.type.toLowerCase()])),n?n(t):t},_notifyChange:function(e){var t=e.action;"add"!=t&&"remove"!=t||(this.dirty=!0)},editable:function(e){return e=(this.fields||{})[e],!e||e.editable!==!1},set:function(e,t,n){var o=this,r=o.dirty;o.editable(e)&&(t=o._parse(e,t),i(t,o.get(e))||(o.dirty=!0,q.fn.set.call(o,e,t,n)&&!r&&(o.dirty=r)))},accept:function(e){var t,n,i=this,o=function(){return i};for(t in e)n=e[t],"_"!=t.charAt(0)&&(n=i.wrap(e[t],t,o)),i._set(t,n);i.idField&&(i.id=i.get(i.idField)),i.dirty=!1},isNew:function(){return this.id===this._defaultId}}),$.define=function(e,n){n===t&&(n=e,e=$);var i,o,r,s,a,l,c,d,u=ce({defaults:{}},n),h={},f=u.id,p=[];if(f&&(u.idField=f),u.id&&delete u.id,f&&(u.defaults[f]=u._defaultId=""),"[object Array]"===$e.call(u.fields)){for(l=0,c=u.fields.length;l<c;l++)r=u.fields[l],typeof r===ke?h[r]={}:r.field&&(h[r.field]=r);u.fields=h}for(o in u.fields)r=u.fields[o],s=r.type||"default",a=null,d=o,o=typeof r.field===ke?r.field:o,r.nullable||(a=u.defaults[d!==o?d:o]=r.defaultValue!==t?r.defaultValue:G[s.toLowerCase()],"function"==typeof a&&p.push(o)),n.id===o&&(u._defaultId=a),u.defaults[d!==o?d:o]=a,r.parse=r.parse||j[s];return p.length>0&&(u._initializers=p),i=e.extend(u),i.define=function(e){return $.define(i,e)},u.fields&&(i.fields=u.fields,i.idField=u.idField),i},Y={selector:function(e){return be(e)?e:Le(e)},compare:function(e){var t=this.selector(e);return function(e,n){return e=t(e),n=t(n),null==e&&null==n?0:null==e?-1:null==n?1:e.localeCompare?e.localeCompare(n):e>n?1:e<n?-1:0}},create:function(e){var t=e.compare||this.compare(e.field);return"desc"==e.dir?function(e,n){return t(n,e,!0)}:t},combine:function(e){return function(t,n){var i,o,r=e[0](t,n);for(i=1,o=e.length;i<o;i++)r=r||e[i](t,n);return r}}},K=ce({},Y,{asc:function(e){var t=this.selector(e);return function(e,n){var i=t(e),o=t(n);return i&&i.getTime&&o&&o.getTime&&(i=i.getTime(),o=o.getTime()),i===o?e.__position-n.__position:null==i?-1:null==o?1:i.localeCompare?i.localeCompare(o):i>o?1:-1}},desc:function(e){var t=this.selector(e);return function(e,n){var i=t(e),o=t(n);return i&&i.getTime&&o&&o.getTime&&(i=i.getTime(),o=o.getTime()),i===o?e.__position-n.__position:null==i?1:null==o?-1:o.localeCompare?o.localeCompare(i):i<o?1:-1}},create:function(e){return this[e.dir](e.field)}}),U=function(e,t){var n,i=e.length,o=Array(i);for(n=0;n<i;n++)o[n]=t(e[n],n,e);return o},Q=function(){function e(e){return"string"==typeof e&&(e=e.replace(/[\r\n]+/g,"")),JSON.stringify(e)}function t(t){return function(n,i,o){return i+="",o&&(n="("+n+" || '').toLowerCase()",i=i.toLowerCase()),t(n,e(i),o)}}function n(t,n,i,o){if(null!=i){if(typeof i===ke){var r=Ke.exec(i);r?i=new Date((+r[1])):o?(i=e(i.toLowerCase()),n="(("+n+" || '')+'').toLowerCase()"):i=e(i)}i.getTime&&(n="("+n+"&&"+n+".getTime?"+n+".getTime():"+n+")",i=i.getTime())}return n+" "+t+" "+i}function i(e){var t,n,i,o;for(t="/^",n=!1,i=0;i<e.length;++i){if(o=e.charAt(i),n)t+="\\"+o;else{if("~"==o){n=!0;continue}t+="*"==o?".*":"?"==o?".":".+^$()[]{}|\\/\n\r\u2028\u2029 ".indexOf(o)>=0?"\\"+o:o}n=!1}return t+"$/"}return{quote:function(t){return t&&t.getTime?"new Date("+t.getTime()+")":e(t)},eq:function(e,t,i){return n("==",e,t,i)},neq:function(e,t,i){return n("!=",e,t,i)},gt:function(e,t,i){return n(">",e,t,i)},gte:function(e,t,i){return n(">=",e,t,i)},lt:function(e,t,i){return n("<",e,t,i)},lte:function(e,t,i){return n("<=",e,t,i)},startswith:t(function(e,t){return e+".lastIndexOf("+t+", 0) == 0"}),doesnotstartwith:t(function(e,t){return e+".lastIndexOf("+t+", 0) == -1"}),endswith:t(function(e,t){var n=t?t.length-2:0;return e+".indexOf("+t+", "+e+".length - "+n+") >= 0"}),doesnotendwith:t(function(e,t){var n=t?t.length-2:0;return e+".indexOf("+t+", "+e+".length - "+n+") < 0"}),contains:t(function(e,t){return e+".indexOf("+t+") >= 0"}),doesnotcontain:t(function(e,t){return e+".indexOf("+t+") == -1"}),matches:t(function(e,t){return t=t.substring(1,t.length-1),i(t)+".test("+e+")"}),doesnotmatch:t(function(e,t){return t=t.substring(1,t.length-1),"!"+i(t)+".test("+e+")"}),isempty:function(e){return e+" === ''"},isnotempty:function(e){return e+" !== ''"},isnull:function(e){return"("+e+" == null)"},isnotnull:function(e){return"("+e+" != null)"}}}(),r.filterExpr=function(e){var n,i,o,s,a,l,c=[],d={and:" && ",or:" || "},u=[],h=[],f=e.filters;for(n=0,i=f.length;n<i;n++)o=f[n],a=o.field,l=o.operator,o.filters?(s=r.filterExpr(o),o=s.expression.replace(/__o\[(\d+)\]/g,function(e,t){return t=+t,"__o["+(h.length+t)+"]"}).replace(/__f\[(\d+)\]/g,function(e,t){return t=+t,"__f["+(u.length+t)+"]"}),h.push.apply(h,s.operators),u.push.apply(u,s.fields)):(typeof a===xe?(s="__f["+u.length+"](d)",u.push(a)):s=_e.expr(a),typeof l===xe?(o="__o["+h.length+"]("+s+", "+Q.quote(o.value)+")",h.push(l)):o=Q[(l||"eq").toLowerCase()](s,o.value,o.ignoreCase===t||o.ignoreCase)),c.push(o);return{expression:"("+c.join(d[e.logic])+")",fields:u,operators:h}},X={"==":"eq",equals:"eq",isequalto:"eq",equalto:"eq",equal:"eq","!=":"neq",ne:"neq",notequals:"neq",isnotequalto:"neq",notequalto:"neq",notequal:"neq","<":"lt",islessthan:"lt",lessthan:"lt",less:"lt","<=":"lte",le:"lte",islessthanorequalto:"lte",lessthanequal:"lte",">":"gt",isgreaterthan:"gt",greaterthan:"gt",greater:"gt",">=":"gte",isgreaterthanorequalto:"gte",greaterthanequal:"gte",ge:"gte",notsubstringof:"doesnotcontain",isnull:"isnull",isempty:"isempty",isnotempty:"isnotempty"},r.normalizeFilter=l,r.compareFilters=h,r.prototype={toArray:function(){return this.data},range:function(e,t){return new r(this.data.slice(e,e+t))},skip:function(e){return new r(this.data.slice(e))},take:function(e){return new r(this.data.slice(0,e))},select:function(e){return new r(U(this.data,e))},order:function(e,t){var n={dir:t};return e&&(e.compare?n.compare=e.compare:n.field=e),new r(this.data.slice(0).sort(Y.create(n)))},orderBy:function(e){return this.order(e,"asc")},orderByDescending:function(e){return this.order(e,"desc")},sort:function(e,t,n){var i,o,r=s(e,t),a=[];if(n=n||Y,r.length){for(i=0,o=r.length;i<o;i++)a.push(n.create(r[i]));return this.orderBy({compare:n.combine(a)})}return this},filter:function(e){var t,n,i,o,s,a,c,d,u=this.data,h=[];if(e=l(e),!e||0===e.filters.length)return this;for(o=r.filterExpr(e),a=o.fields,c=o.operators,s=d=Function("d, __f, __o","return "+o.expression),(a.length||c.length)&&(d=function(e){return s(e,a,c)}),t=0,i=u.length;t<i;t++)n=u[t],d(n)&&h.push(n);return new r(h)},group:function(e,t){e=p(e||[]),t=t||this.data;var n,i=this,o=new r(i.data);return e.length>0&&(n=e[0],o=o.groupBy(n).select(function(i){var o=new r(t).filter([{field:i.field,operator:"eq",value:i.value,ignoreCase:!1}]);return{field:i.field,value:i.value,items:e.length>1?new r(i.items).group(e.slice(1),o.toArray()).toArray():i.items,hasSubgroups:e.length>1,aggregates:o.aggregate(n.aggregates)}})),o},groupBy:function(e){if(he(e)||!this.data.length)return new r([]);var t,n,i,o,s=e.field,a=this._sortForGrouping(s,e.dir||"asc"),l=_e.accessor(s),c=l.get(a[0],s),d={field:s,value:c,items:[]},u=[d];for(i=0,o=a.length;i<o;i++)t=a[i],n=l.get(t,s),m(c,n)||(c=n,d={field:s,value:c,items:[]},u.push(d)),d.items.push(t);return new r(u)},_sortForGrouping:function(e,t){var n,i,o=this.data;if(!Ye){for(n=0,i=o.length;n<i;n++)o[n].__position=n;for(o=new r(o).sort(e,t,K).toArray(),n=0,i=o.length;n<i;n++)delete o[n].__position;return o}return this.sort(e,t).toArray()},aggregate:function(e){var t,n,i={},o={};if(e&&e.length)for(t=0,n=this.data.length;t<n;t++)g(i,e,this.data[t],t,n,o);return i}},Z={sum:function(e,t,n){var i=n.get(t);return v(e)?v(i)&&(e+=i):e=i,e},count:function(e){return(e||0)+1},average:function(e,n,i,o,r,s){var a=i.get(n);return s.count===t&&(s.count=0),v(e)?v(a)&&(e+=a):e=a,v(a)&&s.count++,o==r-1&&v(e)&&(e/=s.count),e},max:function(e,t,n){var i=n.get(t);return v(e)||_(e)||(e=i),e<i&&(v(i)||_(i))&&(e=i),e},min:function(e,t,n){var i=n.get(t);return v(e)||_(e)||(e=i),e>i&&(v(i)||_(i))&&(e=i),e}},r.process=function(e,n){n=n||{};var i,o=new r(e),a=n.group,l=p(a||[]).concat(s(n.sort||[])),c=n.filterCallback,d=n.filter,u=n.skip,h=n.take;return d&&(o=o.filter(d),c&&(o=c(o)),i=o.toArray().length),l&&(o=o.sort(l),a&&(e=o.toArray())),u!==t&&h!==t&&(o=o.range(u,h)),a&&(o=o.group(a,e)),{total:i,data:o.toArray()}},J=ye.extend({init:function(e){this.data=e.data},read:function(e){e.success(this.data)},update:function(e){e.success(e.data)},create:function(e){e.success(e.data)},destroy:function(e){e.success(e.data)}}),ee=ye.extend({init:function(e){var t,n=this;e=n.options=ce({},n.options,e),ge(Pe,function(t,n){typeof e[n]===ke&&(e[n]={url:e[n]})}),n.cache=e.cache?te.create(e.cache):{find:ve,add:ve},t=e.parameterMap,be(e.push)&&(n.push=e.push),n.push||(n.push=Be),n.parameterMap=be(t)?t:function(e){var n={};return ge(e,function(e,i){e in t&&(e=t[e],ue(e)&&(i=e.value(i),e=e.key)),n[e]=i}),n}},options:{parameterMap:Be},create:function(e){return me(this.setup(e,Ce))},read:function(n){var i,o,r,s=this,a=s.cache;n=s.setup(n,Se),i=n.success||ve,o=n.error||ve,r=a.find(n.data),r!==t?i(r):(n.success=function(e){a.add(n.data,e),i(e)},e.ajax(n))},update:function(e){return me(this.setup(e,Te))},destroy:function(e){return me(this.setup(e,De))},setup:function(e,t){e=e||{};var n,i=this,o=i.options[t],r=be(o.data)?o.data(e.data):o.data;return e=ce(!0,{},o,e),n=ce(!0,{},r,e.data),e.data=i.parameterMap(n,t),be(e.url)&&(e.url=e.url(n)),e}}),te=ye.extend({init:function(){this._store={}},add:function(e,n){e!==t&&(this._store[He(e)]=n)},find:function(e){return this._store[He(e)]},clear:function(){this._store={}},remove:function(e){delete this._store[He(e)]}}),te.create=function(e){var t={inmemory:function(){return new te}};return ue(e)&&be(e.find)?e:e===!0?new te:t[e]()},ne=ye.extend({init:function(e){var t,n,i,o,r,s,a,l,c,d,u,h,f,p=this;e=e||{};for(t in e)n=e[t],p[t]=typeof n===ke?Le(n):n;o=e.modelBase||$,ue(p.model)&&(p.model=i=o.define(p.model)),r=de(p.data,p),p._dataAccessFunction=r,p.model&&(s=de(p.groups,p),a=de(p.serialize,p),l={},c={},d={},u={},h=!1,i=p.model,i.fields&&(ge(i.fields,function(e,t){var n;f=e,ue(t)&&t.field?f=t.field:typeof t===ke&&(f=t),ue(t)&&t.from&&(n=t.from),h=h||n&&n!==e||f!==e,c[e]=Le(n||f),d[e]=Le(e),l[n||f]=e,u[e]=n||f}),!e.serialize&&h&&(p.serialize=x(a,i,w,d,l,u))),p._dataAccessFunction=r,p.data=x(r,i,y,c,l,u),p.groups=x(s,i,k,c,l,u))},errors:function(e){return e?e.errors:null},parse:Be,data:Be,total:function(e){return e.length},groups:Be,aggregates:function(){return{}},serialize:function(e){return e}}),ie=we.extend({init:function(e){var n,i,o,r=this;e&&(i=e.data),e=r.options=ce({},r.options,e),r._map={},r._prefetch={},r._data=[],r._pristineData=[],r._ranges=[],r._view=[],r._pristineTotal=0,r._destroyed=[],r._pageSize=e.pageSize,r._page=e.page||(e.pageSize?1:t),r._sort=s(e.sort),r._filter=l(e.filter),r._group=p(e.group),r._aggregate=e.aggregate,r._total=e.total,r._shouldDetachObservableParents=!0,we.fn.init.call(r),r.transport=oe.create(e,i,r),be(r.transport.push)&&r.transport.push({pushCreate:de(r._pushCreate,r),pushUpdate:de(r._pushUpdate,r),pushDestroy:de(r._pushDestroy,r)}),null!=e.offlineStorage&&("string"==typeof e.offlineStorage?(o=e.offlineStorage,r._storage={getItem:function(){return JSON.parse(localStorage.getItem(o))},setItem:function(e){localStorage.setItem(o,He(r.reader.serialize(e)))}}):r._storage=e.offlineStorage),r.reader=new _e.data.readers[e.schema.type||"json"](e.schema),n=r.reader.model||{},r._detachObservableParents(),r._data=r._observe(r._data),r._online=!0,r.bind(["push",Ie,Ae,Re,Ee,ze,Fe],e)},options:{data:null,schema:{modelBase:$},offlineStorage:null,serverSorting:!1,serverPaging:!1,serverFiltering:!1,serverGrouping:!1,serverAggregates:!1,batch:!1},clone:function(){return this},online:function(n){return n!==t?this._online!=n&&(this._online=n,n)?this.sync():e.Deferred().resolve().promise():this._online},offlineData:function(e){return null==this.options.offlineStorage?null:e!==t?this._storage.setItem(e):this._storage.getItem()||[]},_isServerGrouped:function(){var e=this.group()||[];return this.options.serverGrouping&&e.length},_pushCreate:function(e){this._push(e,"pushCreate")},_pushUpdate:function(e){this._push(e,"pushUpdate")},_pushDestroy:function(e){this._push(e,"pushDestroy")},_push:function(e,t){var n=this._readData(e);n||(n=e),this[t](n)},_flatData:function(e,t){if(e){if(this._isServerGrouped())return S(e);if(!t)for(var n=0;n<e.length;n++)e.at(n)}return e},parent:ve,get:function(e){var t,n,i=this._flatData(this._data);for(t=0,n=i.length;t<n;t++)if(i[t].id==e)return i[t]},getByUid:function(e){var t,n,i=this._flatData(this._data);if(i)for(t=0,n=i.length;t<n;t++)if(i[t].uid==e)return i[t]},indexOf:function(e){return F(this._data,e)},at:function(e){return this._data.at(e)},data:function(e){var n,i=this;if(e===t){if(i._data)for(n=0;n<i._data.length;n++)i._data.at(n);return i._data}i._detachObservableParents(),i._data=this._observe(e),i._pristineData=e.slice(0),i._storeData(),i._ranges=[],i.trigger("reset"),i._addRange(i._data),i._total=i._data.length,i._pristineTotal=i._total,i._process(i._data)},view:function(e){return e===t?this._view:(this._view=this._observeView(e),t)},_observeView:function(e){var t,n=this;return M(e,n._data,n._ranges,n.reader.model||q,n._isServerGrouped()),t=new W(e,n.reader.model),t.parent=function(){return n.parent()},t},flatView:function(){var e=this.group()||[];return e.length?S(this._view):this._view},add:function(e){return this.insert(this._data.length,e)},_createNewModel:function(e){return this.reader.model?new this.reader.model(e):e instanceof q?e:new q(e)},insert:function(e,t){return t||(t=e,e=0),t instanceof $||(t=this._createNewModel(t)),this._isServerGrouped()?this._data.splice(e,0,this._wrapInEmptyGroup(t)):this._data.splice(e,0,t),t},pushInsert:function(e,t){var n,i,o,r,s,a;t||(t=e,e=0),fe(t)||(t=[t]),n=[],i=this.options.autoSync,this.options.autoSync=!1;try{for(o=0;o<t.length;o++)r=t[o],s=this.insert(e,r),n.push(s),a=s.toJSON(),this._isServerGrouped()&&(a=this._wrapInEmptyGroup(a)),this._pristineData.push(a),e++}finally{this.options.autoSync=i}n.length&&this.trigger("push",{type:"create",items:n})},pushCreate:function(e){this.pushInsert(this._data.length,e)},pushUpdate:function(e){var t,n,i,o,r;for(fe(e)||(e=[e]),t=[],n=0;n<e.length;n++)i=e[n],o=this._createNewModel(i),r=this.get(o.id),r?(t.push(r),r.accept(i),r.trigger(Ae),this._updatePristineForModel(r,i)):this.pushCreate(i);t.length&&this.trigger("push",{type:"update",items:t})},pushDestroy:function(e){var t=this._removeItems(e);t.length&&this.trigger("push",{type:"destroy",items:t})},_removeItems:function(e){var t,n,i,o,r,s;fe(e)||(e=[e]),t=[],n=this.options.autoSync,this.options.autoSync=!1;try{for(i=0;i<e.length;i++)o=e[i],r=this._createNewModel(o),s=!1,this._eachItem(this._data,function(e){var n,i;for(n=0;n<e.length;n++)if(i=e.at(n),i.id===r.id){t.push(i),e.splice(n,1),s=!0;break}}),s&&(this._removePristineForModel(r),this._destroyed.pop())}finally{this.options.autoSync=n}return t},remove:function(e){var t,n=this,i=n._isServerGrouped();return this._eachItem(n._data,function(o){if(t=I(o,e),t&&i)return t.isNew&&t.isNew()||n._destroyed.push(t),!0}),this._removeModelFromRanges(e),this._updateRangesLength(),e},destroyed:function(){return this._destroyed},created:function(){var e,t,n=[],i=this._flatData(this._data);for(e=0,t=i.length;e<t;e++)i[e].isNew&&i[e].isNew()&&n.push(i[e]);return n},updated:function(){var e,t,n=[],i=this._flatData(this._data);for(e=0,t=i.length;e<t;e++)i[e].isNew&&!i[e].isNew()&&i[e].dirty&&n.push(i[e]);return n},sync:function(){var t,n=this,i=[],o=[],r=n._destroyed,s=e.Deferred().resolve().promise();if(n.online()){if(!n.reader.model)return s;i=n.created(),o=n.updated(),t=[],n.options.batch&&n.transport.submit?t=n._sendSubmit(i,o,r):(t.push.apply(t,n._send("create",i)),t.push.apply(t,n._send("update",o)),t.push.apply(t,n._send("destroy",r))),s=e.when.apply(null,t).then(function(){var e,t;for(e=0,t=arguments.length;e<t;e++)arguments[e]&&n._accept(arguments[e]);n._storeData(!0),n._change({action:"sync"}),n.trigger(Ee)})}else n._storeData(!0),n._change({action:"sync"});return s},cancelChanges:function(e){var t=this;e instanceof _e.data.Model?t._cancelModel(e):(t._destroyed=[],t._detachObservableParents(),t._data=t._observe(t._pristineData),t.options.serverPaging&&(t._total=t._pristineTotal),t._ranges=[],t._addRange(t._data),t._change(),t._markOfflineUpdatesAsDirty())},_markOfflineUpdatesAsDirty:function(){var e=this;null!=e.options.offlineStorage&&e._eachItem(e._data,function(e){var t,n;for(t=0;t<e.length;t++)n=e.at(t),"update"!=n.__state__&&"create"!=n.__state__||(n.dirty=!0)})},hasChanges:function(){var e,t,n=this._flatData(this._data);if(this._destroyed.length)return!0;for(e=0,t=n.length;e<t;e++)if(n[e].isNew&&n[e].isNew()||n[e].dirty)return!0;return!1},_accept:function(t){var n,i=this,o=t.models,r=t.response,s=0,a=i._isServerGrouped(),l=i._pristineData,c=t.type;if(i.trigger(ze,{response:r,type:c}),r&&!he(r)){if(r=i.reader.parse(r),i._handleCustomErrors(r))return;r=i.reader.data(r),fe(r)||(r=[r])}else r=e.map(o,function(e){return e.toJSON()});for("destroy"===c&&(i._destroyed=[]),s=0,n=o.length;s<n;s++)"destroy"!==c?(o[s].accept(r[s]),"create"===c?l.push(a?i._wrapInEmptyGroup(o[s]):r[s]):"update"===c&&i._updatePristineForModel(o[s],r[s])):i._removePristineForModel(o[s])},_updatePristineForModel:function(e,t){this._executeOnPristineForModel(e,function(e,n){_e.deepExtend(n[e],t)})},_executeOnPristineForModel:function(e,t){this._eachPristineItem(function(n){var i=R(n,e);if(i>-1)return t(i,n),!0})},_removePristineForModel:function(e){this._executeOnPristineForModel(e,function(e,t){t.splice(e,1)})},_readData:function(e){var t=this._isServerGrouped()?this.reader.groups:this.reader.data;return t.call(this.reader,e)},_eachPristineItem:function(e){this._eachItem(this._pristineData,e)},_eachItem:function(e,t){e&&e.length&&(this._isServerGrouped()?D(e,t):t(e))},_pristineForModel:function(e){var t,n,i=function(i){if(n=R(i,e),n>-1)return t=i[n],!0};return this._eachPristineItem(i),t},_cancelModel:function(e){var t=this._pristineForModel(e);this._eachItem(this._data,function(n){var i=F(n,e);i>=0&&(!t||e.isNew()&&!t.__state__?n.splice(i,1):(n[i].accept(t),"update"==t.__state__&&(n[i].dirty=!0)))})},_submit:function(t,n){var i=this;i.trigger(Re,{type:"submit"}),i.trigger(Fe),i.transport.submit(ce({success:function(n,i){var o=e.grep(t,function(e){return e.type==i})[0];o&&o.resolve({response:n,models:o.models,type:i})},error:function(e,n,o){for(var r=0;r<t.length;r++)t[r].reject(e);i.error(e,n,o)}},n))},_sendSubmit:function(t,n,i){var o=this,r=[];return o.options.batch&&(t.length&&r.push(e.Deferred(function(e){e.type="create",e.models=t})),n.length&&r.push(e.Deferred(function(e){e.type="update",e.models=n})),i.length&&r.push(e.Deferred(function(e){e.type="destroy",e.models=i})),o._submit(r,{data:{created:o.reader.serialize(b(t)),updated:o.reader.serialize(b(n)),destroyed:o.reader.serialize(b(i))}})),r},_promise:function(t,n,i){var o=this;return e.Deferred(function(e){o.trigger(Re,{type:i}),o.trigger(Fe),o.transport[i].call(o.transport,ce({success:function(t){e.resolve({response:t,models:n,type:i})},error:function(t,n,i){e.reject(t),o.error(t,n,i)}},t))}).promise()},_send:function(e,t){var n,i,o=this,r=[],s=o.reader.serialize(b(t));if(o.options.batch)t.length&&r.push(o._promise({data:{models:s}},t,e));else for(n=0,i=t.length;n<i;n++)r.push(o._promise({data:s[n]},[t[n]],e));return r},read:function(t){var n=this,i=n._params(t),o=e.Deferred();return n._queueRequest(i,function(){var e=n.trigger(Re,{type:"read"});e?(n._dequeueRequest(),o.resolve(e)):(n.trigger(Fe),n._ranges=[],n.trigger("reset"),n.online()?n.transport.read({data:i,success:function(e){n._ranges=[],n.success(e,i),o.resolve()},error:function(){var e=je.call(arguments);n.error.apply(n,e),o.reject.apply(o,e)}}):null!=n.options.offlineStorage&&(n.success(n.offlineData(),i),o.resolve()))}),o.promise()},_readAggregates:function(e){return this.reader.aggregates(e)},success:function(e){var n,i,o,r,s,a,l,c,d=this,u=d.options;if(d.trigger(ze,{response:e,type:"read"}),d.online()){if(e=d.reader.parse(e),d._handleCustomErrors(e))return d._dequeueRequest(),t;d._total=d.reader.total(e),d._aggregate&&u.serverAggregates&&(d._aggregateResult=d._readAggregates(e)),e=d._readData(e),d._destroyed=[]}else{for(e=d._readData(e),n=[],i={},o=d.reader.model,r=o?o.idField:"id",s=0;s<this._destroyed.length;s++)a=this._destroyed[s][r],i[a]=a;for(s=0;s<e.length;s++)l=e[s],c=l.__state__,"destroy"==c?i[l[r]]||this._destroyed.push(this._createNewModel(l)):n.push(l);e=n,d._total=e.length}d._pristineTotal=d._total,d._pristineData=e.slice(0),d._detachObservableParents(),d._data=d._observe(e),d._markOfflineUpdatesAsDirty(),d._storeData(),d._addRange(d._data),d._process(d._data),d._dequeueRequest()},_detachObservableParents:function(){if(this._data&&this._shouldDetachObservableParents)for(var e=0;e<this._data.length;e++)this._data[e].parent&&(this._data[e].parent=ve)},_storeData:function(e){function t(e){var n,i,o,r=[];for(n=0;n<e.length;n++)i=e.at(n),o=i.toJSON(),s&&i.items?o.items=t(i.items):(o.uid=i.uid,
a&&(i.isNew()?o.__state__="create":i.dirty&&(o.__state__="update"))),r.push(o);return r}var n,i,o,r,s=this._isServerGrouped(),a=this.reader.model;if(null!=this.options.offlineStorage){for(n=t(this._data),i=[],o=0;o<this._destroyed.length;o++)r=this._destroyed[o].toJSON(),r.__state__="destroy",i.push(r);this.offlineData(n.concat(i)),e&&(this._pristineData=this._readData(n))}},_addRange:function(e){var t=this,n=t._skip||0,i=n+t._flatData(e,!0).length;t._ranges.push({start:n,end:i,data:e,timestamp:(new Date).getTime()}),t._ranges.sort(function(e,t){return e.start-t.start})},error:function(e,t,n){this._dequeueRequest(),this.trigger(ze,{}),this.trigger(Ie,{xhr:e,status:t,errorThrown:n})},_params:function(e){var t=this,n=ce({take:t.take(),skip:t.skip(),page:t.page(),pageSize:t.pageSize(),sort:t._sort,filter:t._filter,group:t._group,aggregate:t._aggregate},e);return t.options.serverPaging||(delete n.take,delete n.skip,delete n.page,delete n.pageSize),t.options.serverGrouping?t.reader.model&&n.group&&(n.group=L(n.group,t.reader.model)):delete n.group,t.options.serverFiltering?t.reader.model&&n.filter&&(n.filter=B(n.filter,t.reader.model)):delete n.filter,t.options.serverSorting?t.reader.model&&n.sort&&(n.sort=L(n.sort,t.reader.model)):delete n.sort,t.options.serverAggregates?t.reader.model&&n.aggregate&&(n.aggregate=L(n.aggregate,t.reader.model)):delete n.aggregate,n},_queueRequest:function(e,n){var i=this;i._requestInProgress?i._pending={callback:de(n,i),options:e}:(i._requestInProgress=!0,i._pending=t,n())},_dequeueRequest:function(){var e=this;e._requestInProgress=!1,e._pending&&e._queueRequest(e._pending.options,e._pending.callback)},_handleCustomErrors:function(e){if(this.reader.errors){var t=this.reader.errors(e);if(t)return this.trigger(Ie,{xhr:null,status:"customerror",errorThrown:"custom error",errors:t}),!0}return!1},_shouldWrap:function(e){var t=this.reader.model;return!(!t||!e.length)&&!(e[0]instanceof t)},_observe:function(e){var t,n=this,i=n.reader.model;return n._shouldDetachObservableParents=!0,e instanceof Qe?(n._shouldDetachObservableParents=!1,n._shouldWrap(e)&&(e.type=n.reader.model,e.wrapAll(e,e))):(t=n.pageSize()&&!n.options.serverPaging?W:Qe,e=new t(e,n.reader.model),e.parent=function(){return n.parent()}),n._isServerGrouped()&&T(e,i),n._changeHandler&&n._data&&n._data instanceof Qe?n._data.unbind(Ae,n._changeHandler):n._changeHandler=de(n._change,n),e.bind(Ae,n._changeHandler)},_updateTotalForAction:function(e,t){var n=this,i=parseInt(n._total,10);v(n._total)||(i=parseInt(n._pristineTotal,10)),"add"===e?i+=t.length:"remove"===e?i-=t.length:"itemchange"===e||"sync"===e||n.options.serverPaging?"sync"===e&&(i=n._pristineTotal=parseInt(n._total,10)):i=n._pristineTotal,n._total=i},_change:function(e){var t,n,i,o=this,r=e?e.action:"";if("remove"===r)for(t=0,n=e.items.length;t<n;t++)e.items[t].isNew&&e.items[t].isNew()||o._destroyed.push(e.items[t]);!o.options.autoSync||"add"!==r&&"remove"!==r&&"itemchange"!==r?(o._updateTotalForAction(r,e?e.items:[]),o._process(o._data,e)):(i=function(t){"sync"===t.action&&(o.unbind("change",i),o._updateTotalForAction(r,e.items))},o.first("change",i),o.sync())},_calculateAggregates:function(e,t){t=t||{};var n=new r(e),i=t.aggregate,o=t.filter;return o&&(n=n.filter(o)),n.aggregate(i)},_process:function(e,n){var i,o=this,r={};o.options.serverPaging!==!0&&(r.skip=o._skip,r.take=o._take||o._pageSize,r.skip===t&&o._page!==t&&o._pageSize!==t&&(r.skip=(o._page-1)*o._pageSize)),o.options.serverSorting!==!0&&(r.sort=o._sort),o.options.serverFiltering!==!0&&(r.filter=o._filter),o.options.serverGrouping!==!0&&(r.group=o._group),o.options.serverAggregates!==!0&&(r.aggregate=o._aggregate,o._aggregateResult=o._calculateAggregates(e,r)),i=o._queryProcess(e,r),o.view(i.data),i.total===t||o.options.serverFiltering||(o._total=i.total),n=n||{},n.items=n.items||o._view,o.trigger(Ae,n)},_queryProcess:function(e,t){return r.process(e,t)},_mergeState:function(e){var n=this;return e!==t&&(n._pageSize=e.pageSize,n._page=e.page,n._sort=e.sort,n._filter=e.filter,n._group=e.group,n._aggregate=e.aggregate,n._skip=n._currentRangeStart=e.skip,n._take=e.take,n._skip===t&&(n._skip=n._currentRangeStart=n.skip(),e.skip=n.skip()),n._take===t&&n._pageSize!==t&&(n._take=n._pageSize,e.take=n._take),e.sort&&(n._sort=e.sort=s(e.sort)),e.filter&&(n._filter=e.filter=l(e.filter)),e.group&&(n._group=e.group=p(e.group)),e.aggregate&&(n._aggregate=e.aggregate=f(e.aggregate))),e},query:function(n){var i,o,r=this.options.serverSorting||this.options.serverPaging||this.options.serverFiltering||this.options.serverGrouping||this.options.serverAggregates;return r||(this._data===t||0===this._data.length)&&!this._destroyed.length?this.read(this._mergeState(n)):(o=this.trigger(Re,{type:"read"}),o||(this.trigger(Fe),i=this._queryProcess(this._data,this._mergeState(n)),this.options.serverFiltering||(this._total=i.total!==t?i.total:this._data.length),this._aggregateResult=this._calculateAggregates(this._data,n),this.view(i.data),this.trigger(ze,{type:"read"}),this.trigger(Ae,{items:i.data})),e.Deferred().resolve(o).promise())},fetch:function(e){var t=this,n=function(n){n!==!0&&be(e)&&e.call(t)};return this._query().then(n)},_query:function(e){var t=this;return t.query(ce({},{page:t.page(),pageSize:t.pageSize(),sort:t.sort(),filter:t.filter(),group:t.group(),aggregate:t.aggregate()},e))},next:function(e){var t=this,n=t.page(),i=t.total();if(e=e||{},n&&!(i&&n+1>t.totalPages()))return t._skip=t._currentRangeStart=n*t.take(),n+=1,e.page=n,t._query(e),n},prev:function(e){var t=this,n=t.page();if(e=e||{},n&&1!==n)return t._skip=t._currentRangeStart=t._skip-t.take(),n-=1,e.page=n,t._query(e),n},page:function(e){var n,i=this;return e!==t?(e=Ne.max(Ne.min(Ne.max(e,1),i.totalPages()),1),i._query({page:e}),t):(n=i.skip(),n!==t?Ne.round((n||0)/(i.take()||1))+1:t)},pageSize:function(e){var n=this;return e!==t?(n._query({pageSize:e,page:1}),t):n.take()},sort:function(e){var n=this;return e!==t?(n._query({sort:e}),t):n._sort},filter:function(e){var n=this;return e===t?n._filter:(n.trigger("reset"),n._query({filter:e,page:1}),t)},group:function(e){var n=this;return e!==t?(n._query({group:e}),t):n._group},total:function(){return parseInt(this._total||0,10)},aggregate:function(e){var n=this;return e!==t?(n._query({aggregate:e}),t):n._aggregate},aggregates:function(){var e=this._aggregateResult;return he(e)&&(e=this._emptyAggregates(this.aggregate())),e},_emptyAggregates:function(e){var t,n,i={};if(!he(e))for(t={},fe(e)||(e=[e]),n=0;n<e.length;n++)t[e[n].aggregate]=0,i[e[n].field]=t;return i},_wrapInEmptyGroup:function(e){var t,n,i,o,r=this.group();for(i=r.length-1,o=0;i>=o;i--)n=r[i],t={value:e.get(n.field),field:n.field,items:t?[t]:[e],hasSubgroups:!!t,aggregates:this._emptyAggregates(n.aggregates)};return t},totalPages:function(){var e=this,t=e.pageSize()||e.total();return Ne.ceil((e.total()||0)/t)},inRange:function(e,t){var n=this,i=Ne.min(e+t,n.total());return!n.options.serverPaging&&n._data.length>0||n._findRange(e,i).length>0},lastRange:function(){var e=this._ranges;return e[e.length-1]||{start:0,end:0,data:[]}},firstItemUid:function(){var e=this._ranges;return e.length&&e[0].data.length&&e[0].data[0].uid},enableRequestsInProgress:function(){this._skipRequestsInProgress=!1},_timeStamp:function(){return(new Date).getTime()},range:function(e,n){var i,o,r,s,a,l,c,d;if(this._currentRequestTimeStamp=this._timeStamp(),this._skipRequestsInProgress=!0,e=Ne.min(e||0,this.total()),i=this,o=Ne.max(Ne.floor(e/n),0)*n,r=Ne.min(o+n,i.total()),s=i._findRange(e,Ne.min(e+n,i.total())),s.length){i._pending=t,i._skip=e>i.skip()?Ne.min(r,(i.totalPages()-1)*i.take()):o,i._currentRangeStart=e,i._take=n,a=i.options.serverPaging,l=i.options.serverSorting,c=i.options.serverFiltering,d=i.options.serverAggregates;try{i.options.serverPaging=!0,i._isServerGrouped()||i.group()&&i.group().length||(i.options.serverSorting=!0),i.options.serverFiltering=!0,i.options.serverPaging=!0,i.options.serverAggregates=!0,a&&(i._detachObservableParents(),i._data=s=i._observe(s)),i._process(s)}finally{i.options.serverPaging=a,i.options.serverSorting=l,i.options.serverFiltering=c,i.options.serverAggregates=d}}else n!==t&&(i._rangeExists(o,r)?o<e&&i.prefetch(r,n,function(){i.range(e,n)}):i.prefetch(o,n,function(){e>o&&r<i.total()&&!i._rangeExists(r,Ne.min(r+n,i.total()))?i.prefetch(r,n,function(){i.range(e,n)}):i.range(e,n)}))},_findRange:function(e,n){var i,o,r,a,l,c,d,u,h,f,m,g,v=this,_=v._ranges,b=[],w=v.options,y=w.serverSorting||w.serverPaging||w.serverFiltering||w.serverGrouping||w.serverAggregates;for(o=0,m=_.length;o<m;o++)if(i=_[o],e>=i.start&&e<=i.end){for(f=0,r=o;r<m;r++)if(i=_[r],h=v._flatData(i.data,!0),h.length&&e+f>=i.start&&(c=i.data,d=i.end,y||(g=p(v.group()||[]).concat(s(v.sort()||[])),u=v._queryProcess(i.data,{sort:g,filter:v.filter()}),h=c=u.data,u.total!==t&&(d=u.total)),a=0,e+f>i.start&&(a=e+f-i.start),l=h.length,d>n&&(l-=d-n),f+=l-a,b=v._mergeGroups(b,c,a,l),n<=i.end&&f==n-e))return b;break}return[]},_mergeGroups:function(e,t,n,i){if(this._isServerGrouped()){var o,r=t.toJSON();return e.length&&(o=e[e.length-1]),C(o,r,n,i),e.concat(r)}return e.concat(t.slice(n,i))},skip:function(){var e=this;return e._skip===t?e._page!==t?(e._page-1)*(e.take()||1):t:e._skip},currentRangeStart:function(){return this._currentRangeStart||0},take:function(){return this._take||this._pageSize},_prefetchSuccessHandler:function(e,t,n,i){var o=this,r=o._timeStamp();return function(s){var a,l,c,d=!1,u={start:e,end:t,data:[],timestamp:o._timeStamp()};if(o._dequeueRequest(),o.trigger(ze,{response:s,type:"read"}),s=o.reader.parse(s),c=o._readData(s),c.length){for(a=0,l=o._ranges.length;a<l;a++)if(o._ranges[a].start===e){d=!0,u=o._ranges[a];break}d||o._ranges.push(u)}u.data=o._observe(c),u.end=u.start+o._flatData(u.data,!0).length,o._ranges.sort(function(e,t){return e.start-t.start}),o._total=o.reader.total(s),(i||r>=o._currentRequestTimeStamp||!o._skipRequestsInProgress)&&(n&&c.length?n():o.trigger(Ae,{}))}},prefetch:function(e,t,n){var i=this,o=Ne.min(e+t,i.total()),r={take:t,skip:e,page:e/t+1,pageSize:t,sort:i._sort,filter:i._filter,group:i._group,aggregate:i._aggregate};i._rangeExists(e,o)?n&&n():(clearTimeout(i._timeout),i._timeout=setTimeout(function(){i._queueRequest(r,function(){i.trigger(Re,{type:"read"})?i._dequeueRequest():i.transport.read({data:i._params(r),success:i._prefetchSuccessHandler(e,o,n),error:function(){var e=je.call(arguments);i.error.apply(i,e)}})})},100))},_multiplePrefetch:function(e,t,n){var i=this,o=Ne.min(e+t,i.total()),r={take:t,skip:e,page:e/t+1,pageSize:t,sort:i._sort,filter:i._filter,group:i._group,aggregate:i._aggregate};i._rangeExists(e,o)?n&&n():i.trigger(Re,{type:"read"})||i.transport.read({data:i._params(r),success:i._prefetchSuccessHandler(e,o,n,!0)})},_rangeExists:function(e,t){var n,i,o=this,r=o._ranges;for(n=0,i=r.length;n<i;n++)if(r[n].start<=e&&r[n].end>=t)return!0;return!1},_removeModelFromRanges:function(e){var t,n,i,o,r;for(o=0,r=this._ranges.length;o<r&&(i=this._ranges[o],this._eachItem(i.data,function(i){t=I(i,e),t&&(n=!0)}),!n);o++);},_updateRangesLength:function(){var e,t,n,i,o=0;for(n=0,i=this._ranges.length;n<i;n++)e=this._ranges[n],e.start=e.start-o,t=this._flatData(e.data,!0).length,o=e.end-t,e.end=e.start+t}}),oe={},oe.create=function(t,n,i){var o,r=t.transport?e.extend({},t.transport):null;return r?(r.read=typeof r.read===ke?{url:r.read}:r.read,"jsdo"===t.type&&(r.dataSource=i),t.type&&(_e.data.transports=_e.data.transports||{},_e.data.schemas=_e.data.schemas||{},_e.data.transports[t.type]?ue(_e.data.transports[t.type])?r=ce(!0,{},_e.data.transports[t.type],r):o=new _e.data.transports[t.type](ce(r,{data:n})):_e.logToConsole("Unknown DataSource transport type '"+t.type+"'.\nVerify that registration scripts for this type are included after Kendo UI on the page.","warn"),t.schema=ce(!0,{},_e.data.schemas[t.type],t.schema)),o||(o=be(r.read)?r:new ee(r))):o=new J({data:t.data||[]}),o},ie.create=function(e){(fe(e)||e instanceof Qe)&&(e={data:e});var n,i,o,r=e||{},s=r.data,a=r.fields,l=r.table,c=r.select,d={};if(s||!a||r.transport||(l?s=N(l,a):c&&(s=H(c,a),r.group===t&&s[0]&&s[0].optgroup!==t&&(r.group="optgroup"))),_e.data.Model&&a&&(!r.schema||!r.schema.model)){for(n=0,i=a.length;n<i;n++)o=a[n],o.type&&(d[o.field]=o);he(d)||(r.schema=ce(!0,r.schema,{model:{fields:d}}))}return r.data=s,c=null,r.select=null,l=null,r.table=null,r instanceof ie?r:new ie(r)},re=$.define({idField:"id",init:function(e){var t,n=this,i=n.hasChildren||e&&e.hasChildren,o="items",r={};_e.data.Model.fn.init.call(n,e),typeof n.children===ke&&(o=n.children),r={schema:{data:o,model:{hasChildren:i,id:n.idField,fields:n.fields}}},typeof n.children!==ke&&ce(r,n.children),r.data=e,i||(i=r.schema.data),typeof i===ke&&(i=_e.getter(i)),be(i)&&(t=i.call(n,n),n.hasChildren=(!t||0!==t.length)&&!!t),n._childrenOptions=r,n.hasChildren&&n._initChildren(),n._loaded=!(!e||!e._loaded)},_initChildren:function(){var e,t,n,i=this;i.children instanceof se||(e=i.children=new se(i._childrenOptions),t=e.transport,n=t.parameterMap,t.parameterMap=function(e,t){return e[i.idField||"id"]=i.id,n&&(e=n(e,t)),e},e.parent=function(){return i},e.bind(Ae,function(e){e.node=e.node||i,i.trigger(Ae,e)}),e.bind(Ie,function(e){var t=i.parent();t&&(e.node=e.node||i,t.trigger(Ie,e))}),i._updateChildrenField())},append:function(e){this._initChildren(),this.loaded(!0),this.children.add(e)},hasChildren:!1,level:function(){for(var e=this.parentNode(),t=0;e&&e.parentNode;)t++,e=e.parentNode?e.parentNode():null;return t},_updateChildrenField:function(){var e=this._childrenOptions.schema.data;this[e||"items"]=this.children.data()},_childrenLoaded:function(){this._loaded=!0,this._updateChildrenField()},load:function(){var n,i,o={},r="_query";return this.hasChildren?(this._initChildren(),n=this.children,o[this.idField||"id"]=this.id,this._loaded||(n._data=t,r="read"),n.one(Ae,de(this._childrenLoaded,this)),this._matchFilter&&(o.filter={field:"_matchFilter",operator:"eq",value:!0}),i=n[r](o)):this.loaded(!0),i||e.Deferred().resolve().promise()},parentNode:function(){var e=this.parent();return e.parent()},loaded:function(e){return e===t?this._loaded:(this._loaded=e,t)},shouldSerialize:function(e){return $.fn.shouldSerialize.call(this,e)&&"children"!==e&&"_loaded"!==e&&"hasChildren"!==e&&"_childrenOptions"!==e}}),se=ie.extend({init:function(e){var t=re.define({children:e});e.filter&&!e.serverFiltering&&(this._hierarchicalFilter=e.filter,e.filter=null),ie.fn.init.call(this,ce(!0,{},{schema:{modelBase:t,model:t}},e)),this._attachBubbleHandlers()},_attachBubbleHandlers:function(){var e=this;e._data.bind(Ie,function(t){e.trigger(Ie,t)})},read:function(e){var t=ie.fn.read.call(this,e);return this._hierarchicalFilter&&this.filter(this._hierarchicalFilter),t},remove:function(e){var t,n=e.parentNode(),i=this;return n&&n._initChildren&&(i=n.children),t=ie.fn.remove.call(i,e),n&&!i.data().length&&(n.hasChildren=!1),t},success:O("success"),data:O("data"),insert:function(e,t){var n=this.parent();return n&&n._initChildren&&(n.hasChildren=!0,n._initChildren()),ie.fn.insert.call(this,e,t)},filter:function(e){return e===t?this._filter:(this.options.serverFiltering||(this._markHierarchicalQuery(e),e={logic:"or",filters:[e,{field:"_matchFilter",operator:"equals",value:!0}]}),this.trigger("reset"),this._query({filter:e,page:1}),t)},_markHierarchicalQuery:function(e){var n,i,o,s,a;return e=l(e),e&&0!==e.filters.length?(n=r.filterExpr(e),o=n.fields,s=n.operators,i=a=Function("d, __f, __o","return "+n.expression),(o.length||s.length)&&(a=function(e){return i(e,o,s)}),this._updateHierarchicalFilter(a),t):this},_updateHierarchicalFilter:function(e){var t,n,i=this._data,o=!1;for(n=0;n<i.length;n++)t=i[n],t.hasChildren?(t._matchFilter=t.children._updateHierarchicalFilter(e),t._matchFilter||(t._matchFilter=e(t))):t._matchFilter=e(t),t._matchFilter&&(o=!0);return o},_find:function(e,t){var n,i,o,r,s=this._data;if(s){if(o=ie.fn[e].call(this,t))return o;for(s=this._flatData(this._data),n=0,i=s.length;n<i;n++)if(r=s[n].children,r instanceof se&&(o=r[e](t)))return o}},get:function(e){return this._find("get",e)},getByUid:function(e){return this._find("getByUid",e)}}),se.create=function(e){e=e&&e.push?{data:e}:e;var t=e||{},n=t.data,i=t.fields,o=t.list;return n&&n._dataSource?n._dataSource:(n||!i||t.transport||o&&(n=V(o,i)),t.data=n,t instanceof se?t:new se(t))},ae=_e.Observable.extend({init:function(e,t,n){_e.Observable.fn.init.call(this),this._prefetching=!1,this.dataSource=e,this.prefetch=!n;var i=this;e.bind("change",function(){i._change()}),e.bind("reset",function(){i._reset()}),this._syncWithDataSource(),this.setViewSize(t)},setViewSize:function(e){this.viewSize=e,this._recalculate()},at:function(e){var n=this.pageSize,i=!0;return e>=this.total()?(this.trigger("endreached",{index:e}),null):this.useRanges?this.useRanges?((e<this.dataOffset||e>=this.skip+n)&&(i=this.range(Math.floor(e/n)*n)),e===this.prefetchThreshold&&this._prefetch(),e===this.midPageThreshold?this.range(this.nextMidRange,!0):e===this.nextPageThreshold?this.range(this.nextFullRange):e===this.pullBackThreshold&&this.range(this.offset===this.skip?this.previousMidRange:this.previousFullRange),i?this.dataSource.at(e-this.dataOffset):(this.trigger("endreached",{index:e}),null)):t:this.dataSource.view()[e]},indexOf:function(e){return this.dataSource.data().indexOf(e)+this.dataOffset},total:function(){return parseInt(this.dataSource.total(),10)},next:function(){var e=this,t=e.pageSize,n=e.skip-e.viewSize+t,i=Ne.max(Ne.floor(n/t),0)*t;this.offset=n,this.dataSource.prefetch(i,t,function(){e._goToRange(n,!0)})},range:function(e,t){if(this.offset===e)return!0;var n=this,i=this.pageSize,o=Ne.max(Ne.floor(e/i),0)*i,r=this.dataSource;return t&&(o+=i),r.inRange(e,i)?(this.offset=e,this._recalculate(),this._goToRange(e),!0):!this.prefetch||(r.prefetch(o,i,function(){n.offset=e,n._recalculate(),n._goToRange(e,!0)}),!1)},syncDataSource:function(){var e=this.offset;this.offset=null,this.range(e)},destroy:function(){this.unbind()},_prefetch:function(){var e=this,t=this.pageSize,n=this.skip+t,i=this.dataSource;i.inRange(n,t)||this._prefetching||!this.prefetch||(this._prefetching=!0,this.trigger("prefetching",{skip:n,take:t}),i.prefetch(n,t,function(){e._prefetching=!1,e.trigger("prefetched",{skip:n,take:t})}))},_goToRange:function(e,t){this.offset===e&&(this.dataOffset=e,this._expanding=t,this.dataSource.range(e,this.pageSize),this.dataSource.enableRequestsInProgress())},_reset:function(){this._syncPending=!0},_change:function(){var e=this.dataSource;this.length=this.useRanges?e.lastRange().end:e.view().length,this._syncPending&&(this._syncWithDataSource(),this._recalculate(),this._syncPending=!1,this.trigger("reset",{offset:this.offset})),this.trigger("resize"),this._expanding&&this.trigger("expand"),delete this._expanding},_syncWithDataSource:function(){var e=this.dataSource;this._firstItemUid=e.firstItemUid(),this.dataOffset=this.offset=e.skip()||0,this.pageSize=e.pageSize(),this.useRanges=e.options.serverPaging},_recalculate:function(){var e=this.pageSize,t=this.offset,n=this.viewSize,i=Math.ceil(t/e)*e;this.skip=i,this.midPageThreshold=i+e-1,this.nextPageThreshold=i+n-1,this.prefetchThreshold=i+Math.floor(e/3*2),this.pullBackThreshold=this.offset-1,this.nextMidRange=i+e-n,this.nextFullRange=i,this.previousMidRange=t-n,this.previousFullRange=i-e}}),le=_e.Observable.extend({init:function(e,t){var n=this;_e.Observable.fn.init.call(n),this.dataSource=e,this.batchSize=t,this._total=0,this.buffer=new ae(e,3*t),this.buffer.bind({endreached:function(e){n.trigger("endreached",{index:e.index})},prefetching:function(e){n.trigger("prefetching",{skip:e.skip,take:e.take})},prefetched:function(e){n.trigger("prefetched",{skip:e.skip,take:e.take})},reset:function(){n._total=0,n.trigger("reset")},resize:function(){n._total=Math.ceil(this.length/n.batchSize),n.trigger("resize",{total:n.total(),offset:this.offset})}})},syncDataSource:function(){this.buffer.syncDataSource()},at:function(e){var t,n,i=this.buffer,o=e*this.batchSize,r=this.batchSize,s=[];for(i.offset>o&&i.at(i.offset-1),n=0;n<r&&(t=i.at(o+n),null!==t);n++)s.push(t);return s},total:function(){return this._total},destroy:function(){this.buffer.destroy(),this.unbind()}}),ce(!0,_e.data,{readers:{json:ne},Query:r,DataSource:ie,HierarchicalDataSource:se,Node:re,ObservableObject:q,ObservableArray:Qe,LazyObservableArray:W,LocalTransport:J,RemoteTransport:ee,Cache:te,DataReader:ne,Model:$,Buffer:ae,BatchBuffer:le})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.binder.min",["kendo.core.min","kendo.data.min"],e)}(function(){return function(e,t){function n(t,n,i){return v.extend({init:function(e,t,n){var i=this;v.fn.init.call(i,e.element[0],t,n),i.widget=e,i._dataBinding=I(i.dataBinding,i),i._dataBound=I(i.dataBound,i),i._itemChange=I(i.itemChange,i)},itemChange:function(e){s(e.item[0],e.data,this._ns(e.ns),[e.data].concat(this.bindings[t]._parents()))},dataBinding:function(e){var t,n,i=this.widget,o=e.removedItems||i.items();for(t=0,n=o.length;t<n;t++)c(o[t],!1)},_ns:function(t){t=t||C.ui;var n=[C.ui,C.dataviz.ui,C.mobile.ui];return n.splice(e.inArray(t,n),1),n.unshift(t),C.rolesFromNamespaces(n)},dataBound:function(e){var i,o,r,a,l=this.widget,c=e.addedItems||l.items(),d=l[n],u=C.data.HierarchicalDataSource;if(!(u&&d instanceof u)&&c.length)for(r=e.addedDataItems||d.flatView(),a=this.bindings[t]._parents(),i=0,o=r.length;i<o;i++)s(c[i],r[i],this._ns(e.ns),[r[i]].concat(a))},refresh:function(e){var o,r,s,a=this,l=a.widget;e=e||{},e.action||(a.destroy(),l.bind("dataBinding",a._dataBinding),l.bind("dataBound",a._dataBound),l.bind("itemChange",a._itemChange),o=a.bindings[t].get(),l[n]instanceof C.data.DataSource&&l[n]!=o&&(o instanceof C.data.DataSource?l[i](o):o&&o._dataSource?l[i](o._dataSource):(l[n].data(o),r=C.ui.Select&&l instanceof C.ui.Select,s=C.ui.MultiSelect&&l instanceof C.ui.MultiSelect,a.bindings.value&&(r||s)&&l.value(f(a.bindings.value.get(),l.options.dataValueField)))))},destroy:function(){var e=this.widget;e.unbind("dataBinding",this._dataBinding),e.unbind("dataBound",this._dataBound),e.unbind("itemChange",this._itemChange)}})}function i(e,t){var n=C.initWidget(e,{},t);if(n)return new y(n)}function o(e){var t,n,i,r,s,a,l,c={};for(l=e.match(k),t=0,n=l.length;t<n;t++)i=l[t],r=i.indexOf(":"),s=i.substring(0,r),a=i.substring(r+1),"{"==a.charAt(0)&&(a=o(a)),c[s]=a;return c}function r(e,t,n){var i,o={};for(i in e)o[i]=new n(t,e[i]);return o}function s(e,t,n,a){var c,d,u,h,f=e.getAttribute("data-"+C.ns+"role"),v=e.getAttribute("data-"+C.ns+"bind"),_=[],b=!0,y={};if(a=a||[t],(f||v)&&l(e,!1),f&&(u=i(e,n)),v&&(v=o(v.replace(x,"")),u||(y=C.parseOptions(e,{textField:"",valueField:"",template:"",valueUpdate:N,valuePrimitive:!1,autoBind:!0}),y.roles=n,u=new w(e,y)),u.source=t,d=r(v,a,p),y.template&&(d.template=new g(a,"",y.template)),d.click&&(v.events=v.events||{},v.events.click=v.click,d.click.destroy(),delete d.click),d.source&&(b=!1),v.attr&&(d.attr=r(v.attr,a,p)),v.style&&(d.style=r(v.style,a,p)),v.events&&(d.events=r(v.events,a,m)),v.css&&(d.css=r(v.css,a,p)),u.bind(d)),u&&(e.kendoBindingTarget=u),h=e.children,b&&h){for(c=0;c<h.length;c++)_[c]=h[c];for(c=0;c<_.length;c++)s(_[c],t,n,a)}}function a(t,n){var i,o,r,a=C.rolesFromNamespaces([].slice.call(arguments,2));for(n=C.observable(n),t=e(t),i=0,o=t.length;i<o;i++)r=t[i],1===r.nodeType&&s(r,n,a)}function l(t,n){var i,o=t.kendoBindingTarget;o&&(o.destroy(),L?delete t.kendoBindingTarget:t.removeAttribute?t.removeAttribute("kendoBindingTarget"):t.kendoBindingTarget=null),n&&(i=C.widgetInstance(e(t)),i&&typeof i.destroy===H&&i.destroy())}function c(e,t){l(e,t),d(e,t)}function d(e,t){var n,i,o=e.children;if(o)for(n=0,i=o.length;n<i;n++)c(o[n],t)}function u(t){var n,i;for(t=e(t),n=0,i=t.length;n<i;n++)c(t[n],!1)}function h(e,t){var n=e.element,i=n[0].kendoBindingTarget;i&&a(n,i.source,t)}function f(e,t){var n,i,o=[],r=0;if(!t)return e;if(e instanceof D){for(n=e.length;r<n;r++)i=e[r],o[r]=i.get?i.get(t):i[t];e=o}else e instanceof T&&(e=e.get(t));return e}var p,m,g,v,_,b,w,y,k,x,C=window.kendo,S=C.Observable,T=C.data.ObservableObject,D=C.data.ObservableArray,A={}.toString,E={},M=C.Class,I=e.proxy,R="value",F="source",z="events",P="checked",B="css",L=!0,H="function",N="change";!function(){var e=document.createElement("a");try{delete e.test}catch(t){L=!1}}(),p=S.extend({init:function(e,t){var n=this;S.fn.init.call(n),n.source=e[0],n.parents=e,n.path=t,n.dependencies={},n.dependencies[t]=!0,n.observable=n.source instanceof S,n._access=function(e){n.dependencies[e.field]=!0},n.observable&&(n._change=function(e){n.change(e)},n.source.bind(N,n._change))},_parents:function(){var t,n=this.parents,i=this.get();return i&&"function"==typeof i.parent&&(t=i.parent(),e.inArray(t,n)<0&&(n=[t].concat(n))),n},change:function(e){var t,n,i=e.field,o=this;if("this"===o.path)o.trigger(N,e);else for(t in o.dependencies)if(0===t.indexOf(i)&&(n=t.charAt(i.length),!n||"."===n||"["===n)){o.trigger(N,e);break}},start:function(e){e.bind("get",this._access)},stop:function(e){e.unbind("get",this._access)},get:function(){var e=this,n=e.source,i=0,o=e.path,r=n;if(!e.observable)return r;for(e.start(e.source),r=n.get(o);r===t&&n;)n=e.parents[++i],n instanceof T&&(r=n.get(o));if(r===t)for(n=e.source;r===t&&n;)n=n.parent(),n instanceof T&&(r=n.get(o));return"function"==typeof r&&(i=o.lastIndexOf("."),i>0&&(n=n.get(o.substring(0,i))),e.start(n),r=n!==e.source?r.call(n,e.source):r.call(n),e.stop(n)),n&&n!==e.source&&(e.currentSource=n,n.unbind(N,e._change).bind(N,e._change)),e.stop(e.source),r},set:function(e){var t=this.currentSource||this.source,n=C.getter(this.path)(t);"function"==typeof n?t!==this.source?n.call(t,this.source,e):n.call(t,e):t.set(this.path,e)},destroy:function(){this.observable&&(this.source.unbind(N,this._change),this.currentSource&&this.currentSource.unbind(N,this._change)),this.unbind()}}),m=p.extend({get:function(){var e,t=this.source,n=this.path,i=0;for(e=t.get(n);!e&&t;)t=this.parents[++i],t instanceof T&&(e=t.get(n));return I(e,t)}}),g=p.extend({init:function(e,t,n){var i=this;p.fn.init.call(i,e,t),i.template=n},render:function(e){var t;return this.start(this.source),t=C.render(this.template,e),this.stop(this.source),t}}),v=M.extend({init:function(e,t,n){this.element=e,this.bindings=t,this.options=n},bind:function(e,t){var n=this;e=t?e[t]:e,e.bind(N,function(e){n.refresh(t||e)}),n.refresh(t)},destroy:function(){}}),_=v.extend({dataType:function(){var e=this.element.getAttribute("data-type")||this.element.type||"text";return e.toLowerCase()},parsedValue:function(){return this._parseValue(this.element.value,this.dataType())},_parseValue:function(e,t){return"date"==t?e=C.parseDate(e,"yyyy-MM-dd"):"datetime-local"==t?e=C.parseDate(e,["yyyy-MM-ddTHH:mm:ss","yyyy-MM-ddTHH:mm"]):"number"==t?e=C.parseFloat(e):"boolean"==t&&(e=e.toLowerCase(),e=null!==C.parseFloat(e)?!!C.parseFloat(e):"true"===e.toLowerCase()),e}}),E.attr=v.extend({refresh:function(e){this.element.setAttribute(e,this.bindings.attr[e].get())}}),E.css=v.extend({init:function(e,t,n){v.fn.init.call(this,e,t,n),this.classes={}},refresh:function(t){var n=e(this.element),i=this.bindings.css[t],o=this.classes[t]=i.get();o?n.addClass(t):n.removeClass(t)}}),E.style=v.extend({refresh:function(e){this.element.style[e]=this.bindings.style[e].get()||""}}),E.enabled=v.extend({refresh:function(){this.bindings.enabled.get()?this.element.removeAttribute("disabled"):this.element.setAttribute("disabled","disabled")}}),E.readonly=v.extend({refresh:function(){this.bindings.readonly.get()?this.element.setAttribute("readonly","readonly"):this.element.removeAttribute("readonly")}}),E.disabled=v.extend({refresh:function(){this.bindings.disabled.get()?this.element.setAttribute("disabled","disabled"):this.element.removeAttribute("disabled")}}),E.events=v.extend({init:function(e,t,n){v.fn.init.call(this,e,t,n),this.handlers={}},refresh:function(t){var n=e(this.element),i=this.bindings.events[t],o=this.handlers[t];o&&n.off(t,o),o=this.handlers[t]=i.get(),n.on(t,i.source,o)},destroy:function(){var t,n=e(this.element);for(t in this.handlers)n.off(t,this.handlers[t])}}),E.text=v.extend({refresh:function(){var t=this.bindings.text.get(),n=this.element.getAttribute("data-format")||"";null==t&&(t=""),e(this.element).text(C.toString(t,n))}}),E.visible=v.extend({refresh:function(){this.element.style.display=this.bindings.visible.get()?"":"none"}}),E.invisible=v.extend({refresh:function(){this.element.style.display=this.bindings.invisible.get()?"none":""}}),E.html=v.extend({refresh:function(){this.element.innerHTML=this.bindings.html.get()}}),E.value=_.extend({init:function(t,n,i){_.fn.init.call(this,t,n,i),this._change=I(this.change,this),this.eventName=i.valueUpdate||N,e(this.element).on(this.eventName,this._change),this._initChange=!1},change:function(){this._initChange=this.eventName!=N,this.bindings[R].set(this.parsedValue()),this._initChange=!1},refresh:function(){var e,t;this._initChange||(e=this.bindings[R].get(),null==e&&(e=""),t=this.dataType(),"date"==t?e=C.toString(e,"yyyy-MM-dd"):"datetime-local"==t&&(e=C.toString(e,"yyyy-MM-ddTHH:mm:ss")),this.element.value=e),this._initChange=!1},destroy:function(){e(this.element).off(this.eventName,this._change)}}),E.source=v.extend({init:function(e,t,n){v.fn.init.call(this,e,t,n);var i=this.bindings.source.get();i instanceof C.data.DataSource&&n.autoBind!==!1&&i.fetch()},refresh:function(e){var t=this,n=t.bindings.source.get();n instanceof D||n instanceof C.data.DataSource?(e=e||{},"add"==e.action?t.add(e.index,e.items):"remove"==e.action?t.remove(e.index,e.items):"itemchange"!=e.action&&t.render()):t.render()},container:function(){var e=this.element;return"table"==e.nodeName.toLowerCase()&&(e.tBodies[0]||e.appendChild(document.createElement("tbody")),e=e.tBodies[0]),e},template:function(){var e=this.options,t=e.template,n=this.container().nodeName.toLowerCase();return t||(t="select"==n?e.valueField||e.textField?C.format('<option value="#:{0}#">#:{1}#</option>',e.valueField||e.textField,e.textField||e.valueField):"<option>#:data#</option>":"tbody"==n?"<tr><td>#:data#</td></tr>":"ul"==n||"ol"==n?"<li>#:data#</li>":"#:data#",t=C.template(t)),t},add:function(t,n){var i,o,r,a,l=this.container(),c=l.cloneNode(!1),d=l.children[t];if(e(c).html(C.render(this.template(),n)),c.children.length)for(i=this.bindings.source._parents(),o=0,r=n.length;o<r;o++)a=c.children[0],l.insertBefore(a,d||null),s(a,n[o],this.options.roles,[n[o]].concat(i))},remove:function(e,t){var n,i,o=this.container();for(n=0;n<t.length;n++)i=o.children[e],c(i,!0),i.parentNode==o&&o.removeChild(i)},render:function(){var t,n,i,o=this.bindings.source.get(),r=this.container(),a=this.template();if(null!=o)if(o instanceof C.data.DataSource&&(o=o.view()),o instanceof D||"[object Array]"===A.call(o)||(o=[o]),this.bindings.template){if(d(r,!0),e(r).html(this.bindings.template.render(o)),r.children.length)for(t=this.bindings.source._parents(),n=0,i=o.length;n<i;n++)s(r.children[n],o[n],this.options.roles,[o[n]].concat(t))}else e(r).html(C.render(a,o))}}),E.input={checked:_.extend({init:function(t,n,i){_.fn.init.call(this,t,n,i),this._change=I(this.change,this),e(this.element).change(this._change)},change:function(){var e,t,n,i=this.element,o=this.value();if("radio"==i.type)o=this.parsedValue(),this.bindings[P].set(o);else if("checkbox"==i.type)if(e=this.bindings[P].get(),e instanceof D){if(o=this.parsedValue(),o instanceof Date){for(n=0;n<e.length;n++)if(e[n]instanceof Date&&+e[n]===+o){t=n;break}}else t=e.indexOf(o);t>-1?e.splice(t,1):e.push(o)}else this.bindings[P].set(o)},refresh:function(){var e,t,n=this.bindings[P].get(),i=n,o=this.dataType(),r=this.element;if("checkbox"==r.type)if(i instanceof D){if(e=-1,n=this.parsedValue(),n instanceof Date){for(t=0;t<i.length;t++)if(i[t]instanceof Date&&+i[t]===+n){
e=t;break}}else e=i.indexOf(n);r.checked=e>=0}else r.checked=i;else"radio"==r.type&&null!=n&&("date"==o?n=C.toString(n,"yyyy-MM-dd"):"datetime-local"==o&&(n=C.toString(n,"yyyy-MM-ddTHH:mm:ss")),r.checked=r.value===""+n)},value:function(){var e=this.element,t=e.value;return"checkbox"==e.type&&(t=e.checked),t},destroy:function(){e(this.element).off(N,this._change)}})},E.select={source:E.source.extend({refresh:function(n){var i,o=this,r=o.bindings.source.get();r instanceof D||r instanceof C.data.DataSource?(n=n||{},"add"==n.action?o.add(n.index,n.items):"remove"==n.action?o.remove(n.index,n.items):"itemchange"!=n.action&&n.action!==t||(o.render(),o.bindings.value&&o.bindings.value&&(i=f(o.bindings.value.get(),e(o.element).data("valueField")),null===i?o.element.selectedIndex=-1:o.element.value=i))):o.render()}}),value:_.extend({init:function(t,n,i){_.fn.init.call(this,t,n,i),this._change=I(this.change,this),e(this.element).change(this._change)},parsedValue:function(){var e,t,n,i,o=this.dataType(),r=[];for(n=0,i=this.element.options.length;n<i;n++)t=this.element.options[n],t.selected&&(e=t.attributes.value,e=e&&e.specified?t.value:t.text,r.push(this._parseValue(e,o)));return r},change:function(){var e,n,i,o,r,s,a,l,c=[],d=this.element,u=this.options.valueField||this.options.textField,h=this.options.valuePrimitive;for(r=0,s=d.options.length;r<s;r++)n=d.options[r],n.selected&&(o=n.attributes.value,o=o&&o.specified?n.value:n.text,c.push(u?o:this._parseValue(o,this.dataType())));if(u)for(e=this.bindings.source.get(),e instanceof C.data.DataSource&&(e=e.view()),i=0;i<c.length;i++)for(r=0,s=e.length;r<s;r++)if(a=e[r].get(u),l=a+""===c[i]){c[i]=e[r];break}o=this.bindings[R].get(),o instanceof D?o.splice.apply(o,[0,o.length].concat(c)):this.bindings[R].set(h||!(o instanceof T||null===o||o===t)&&u?c[0].get(u):c[0])},refresh:function(){var e,t,n,i=this.element,o=i.options,r=this.bindings[R].get(),s=r,a=this.options.valueField||this.options.textField,l=!1,c=this.dataType();for(s instanceof D||(s=new D([r])),i.selectedIndex=-1,n=0;n<s.length;n++)for(r=s[n],a&&r instanceof T&&(r=r.get(a)),"date"==c?r=C.toString(s[n],"yyyy-MM-dd"):"datetime-local"==c&&(r=C.toString(s[n],"yyyy-MM-ddTHH:mm:ss")),e=0;e<o.length;e++)t=o[e].value,""===t&&""!==r&&(t=o[e].text),null!=r&&t==""+r&&(o[e].selected=!0,l=!0)},destroy:function(){e(this.element).off(N,this._change)}})},E.widget={events:v.extend({init:function(e,t,n){v.fn.init.call(this,e.element[0],t,n),this.widget=e,this.handlers={}},refresh:function(e){var t=this.bindings.events[e],n=this.handlers[e];n&&this.widget.unbind(e,n),n=t.get(),this.handlers[e]=function(e){e.data=t.source,n(e),e.data===t.source&&delete e.data},this.widget.bind(e,this.handlers[e])},destroy:function(){var e;for(e in this.handlers)this.widget.unbind(e,this.handlers[e])}}),checked:v.extend({init:function(e,t,n){v.fn.init.call(this,e.element[0],t,n),this.widget=e,this._change=I(this.change,this),this.widget.bind(N,this._change)},change:function(){this.bindings[P].set(this.value())},refresh:function(){this.widget.check(this.bindings[P].get()===!0)},value:function(){var e=this.element,t=e.value;return"on"!=t&&"off"!=t||(t=e.checked),t},destroy:function(){this.widget.unbind(N,this._change)}}),visible:v.extend({init:function(e,t,n){v.fn.init.call(this,e.element[0],t,n),this.widget=e},refresh:function(){var e=this.bindings.visible.get();this.widget.wrapper[0].style.display=e?"":"none"}}),invisible:v.extend({init:function(e,t,n){v.fn.init.call(this,e.element[0],t,n),this.widget=e},refresh:function(){var e=this.bindings.invisible.get();this.widget.wrapper[0].style.display=e?"none":""}}),enabled:v.extend({init:function(e,t,n){v.fn.init.call(this,e.element[0],t,n),this.widget=e},refresh:function(){this.widget.enable&&this.widget.enable(this.bindings.enabled.get())}}),disabled:v.extend({init:function(e,t,n){v.fn.init.call(this,e.element[0],t,n),this.widget=e},refresh:function(){this.widget.enable&&this.widget.enable(!this.bindings.disabled.get())}}),source:n("source","dataSource","setDataSource"),value:v.extend({init:function(t,n,i){v.fn.init.call(this,t.element[0],n,i),this.widget=t,this._change=e.proxy(this.change,this),this.widget.first(N,this._change);var o=this.bindings.value.get();this._valueIsObservableObject=!i.valuePrimitive&&(null==o||o instanceof T),this._valueIsObservableArray=o instanceof D,this._initChange=!1},_source:function(){var e;return this.widget.dataItem&&(e=this.widget.dataItem(),e&&e instanceof T)?[e]:(this.bindings.source&&(e=this.bindings.source.get()),(!e||e instanceof C.data.DataSource)&&(e=this.widget.dataSource.flatView()),e)},change:function(){var e,t,n,i,o,r,s,a=this.widget.value(),l=this.options.dataValueField||this.options.dataTextField,c="[object Array]"===A.call(a),d=this._valueIsObservableObject,u=[];if(this._initChange=!0,l)if(""===a&&(d||this.options.valuePrimitive))a=null;else{for(s=this._source(),c&&(t=a.length,u=a.slice(0)),o=0,r=s.length;o<r;o++)if(n=s[o],i=n.get(l),c){for(e=0;e<t;e++)if(i==u[e]){u[e]=n;break}}else if(i==a){a=d?n:i;break}u[0]&&(a=this._valueIsObservableArray?u:d||!l?u[0]:u[0].get(l))}this.bindings.value.set(a),this._initChange=!1},refresh:function(){var e,n,i,o,r,s,a,l,c;if(!this._initChange){if(e=this.widget,n=e.options,i=n.dataTextField,o=n.dataValueField||i,r=this.bindings.value.get(),s=n.text||"",a=0,c=[],r===t&&(r=null),o)if(r instanceof D){for(l=r.length;a<l;a++)c[a]=r[a].get(o);r=c}else r instanceof T&&(s=r.get(i),r=r.get(o));n.autoBind!==!1||n.cascadeFrom||!e.listView||e.listView.bound()?e.value(r):(i!==o||s||(s=r),s||!r&&0!==r||!n.valuePrimitive?e._preselect(r,s):e.value(r))}this._initChange=!1},destroy:function(){this.widget.unbind(N,this._change)}}),gantt:{dependencies:n("dependencies","dependencies","setDependenciesDataSource")},multiselect:{value:v.extend({init:function(t,n,i){v.fn.init.call(this,t.element[0],n,i),this.widget=t,this._change=e.proxy(this.change,this),this.widget.first(N,this._change),this._initChange=!1},change:function(){var e,n,i,o,r,s,a,l,c,d=this,u=d.bindings[R].get(),h=d.options.valuePrimitive,f=h?d.widget.value():d.widget.dataItems(),p=this.options.dataValueField||this.options.dataTextField;if(f=f.slice(0),d._initChange=!0,u instanceof D){for(e=[],n=f.length,i=0,o=0,r=u[i],s=!1;r!==t;){for(c=!1,o=0;o<n;o++)if(h?s=f[o]==r:(l=f[o],l=l.get?l.get(p):l,s=l==(r.get?r.get(p):r)),s){f.splice(o,1),n-=1,c=!0;break}c?i+=1:(e.push(r),b(u,i,1),a=i),r=u[i]}b(u,u.length,0,f),e.length&&u.trigger("change",{action:"remove",items:e,index:a}),f.length&&u.trigger("change",{action:"add",items:f,index:u.length-1})}else d.bindings[R].set(f);d._initChange=!1},refresh:function(){if(!this._initChange){var e,n,i=this.options,o=this.widget,r=i.dataValueField||i.dataTextField,s=this.bindings.value.get(),a=s,l=0,c=[];if(s===t&&(s=null),r)if(s instanceof D){for(e=s.length;l<e;l++)n=s[l],c[l]=n.get?n.get(r):n;s=c}else s instanceof T&&(s=s.get(r));i.autoBind!==!1||i.valuePrimitive===!0||o._isBound()?o.value(s):o._preselect(a,s)}},destroy:function(){this.widget.unbind(N,this._change)}})},scheduler:{source:n("source","dataSource","setDataSource").extend({dataBound:function(e){var t,n,i,o,r=this.widget,a=e.addedItems||r.items();if(a.length)for(i=e.addedDataItems||r.dataItems(),o=this.bindings.source._parents(),t=0,n=i.length;t<n;t++)s(a[t],i[t],this._ns(e.ns),[i[t]].concat(o))}})}},b=function(e,t,n,i){var o,r,s,a,l;if(i=i||[],n=n||0,o=i.length,r=e.length,s=[].slice.call(e,t+n),a=s.length,o){for(o=t+o,l=0;t<o;t++)e[t]=i[l],l++;e.length=o}else if(n)for(e.length=t,n+=t;t<n;)delete e[--n];if(a){for(a=t+a,l=0;t<a;t++)e[t]=s[l],l++;e.length=a}for(t=e.length;t<r;)delete e[t],t++},w=M.extend({init:function(e,t){this.target=e,this.options=t,this.toDestroy=[]},bind:function(e){var t,n,i,o,r,s,a=this instanceof y,l=this.binders();for(t in e)t==R?n=!0:t==F?i=!0:t!=z||a?t==P?r=!0:t==B?s=!0:this.applyBinding(t,e,l):o=!0;i&&this.applyBinding(F,e,l),n&&this.applyBinding(R,e,l),r&&this.applyBinding(P,e,l),o&&!a&&this.applyBinding(z,e,l),s&&!a&&this.applyBinding(B,e,l)},binders:function(){return E[this.target.nodeName.toLowerCase()]||{}},applyBinding:function(e,t,n){var i,o=n[e]||E[e],r=this.toDestroy,s=t[e];if(o)if(o=new o(this.target,t,this.options),r.push(o),s instanceof p)o.bind(s),r.push(s);else for(i in s)o.bind(s,i),r.push(s[i]);else if("template"!==e)throw Error("The "+e+" binding is not supported by the "+this.target.nodeName.toLowerCase()+" element")},destroy:function(){var e,t,n=this.toDestroy;for(e=0,t=n.length;e<t;e++)n[e].destroy()}}),y=w.extend({binders:function(){return E.widget[this.target.options.name.toLowerCase()]||{}},applyBinding:function(e,t,n){var i,o=n[e]||E.widget[e],r=this.toDestroy,s=t[e];if(!o)throw Error("The "+e+" binding is not supported by the "+this.target.options.name+" widget");if(o=new o(this.target,t,this.target.options),r.push(o),s instanceof p)o.bind(s),r.push(s);else for(i in s)o.bind(s,i),r.push(s[i])}}),k=/[A-Za-z0-9_\-]+:(\{([^}]*)\}|[^,}]+)/g,x=/\s/g,C.unbind=u,C.bind=a,C.data.binders=E,C.data.Binder=v,C.notify=h,C.observable=function(e){return e instanceof T||(e=new T(e)),e},C.observableHierarchy=function(e){function t(e){var n,i;for(n=0;n<e.length;n++)e[n]._initChildren(),i=e[n].children,i.fetch(),e[n].items=i.data(),t(e[n].items)}var n=C.data.HierarchicalDataSource.create(e);return n.fetch(),t(n.data()),n._data._dataSource=n,n._data}}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.fx.min",["kendo.core.min"],e)}(function(){return function(e,t){function n(e){return parseInt(e,10)}function i(e,t){return n(e.css(t))}function o(e){var t,n=[];for(t in e)n.push(t);return n}function r(e){for(var t in e)U.indexOf(t)!=-1&&W.indexOf(t)==-1&&delete e[t];return e}function s(e,t){var n,i,o,r,s=[],a={};for(i in t)n=i.toLowerCase(),r=I&&U.indexOf(n)!=-1,!E.hasHW3D&&r&&W.indexOf(n)==-1?delete t[i]:(o=t[i],r?s.push(i+"("+o+")"):a[i]=o);return s.length&&(a[ae]=s.join(" ")),a}function a(e,t){var i,o,r;return I?(i=e.css(ae),i==K?"scale"==t?1:0:(o=i.match(RegExp(t+"\\s*\\(([\\d\\w\\.]+)")),r=0,o?r=n(o[1]):(o=i.match(B)||[0,0,0,0,0],t=t.toLowerCase(),H.test(t)?r=parseFloat(o[3]/o[2]):"translatey"==t?r=parseFloat(o[4]/o[2]):"scale"==t?r=parseFloat(o[2]):"rotate"==t&&(r=parseFloat(Math.atan2(o[2],o[1])))),r)):parseFloat(e.css(t))}function l(e){return e.charAt(0).toUpperCase()+e.substring(1)}function c(e,t){var n=p.extend(t),i=n.prototype.directions;S[l(e)]=n,S.Element.prototype[e]=function(e,t,i,o){return new n(this.element,e,t,i,o)},T(i,function(t,i){S.Element.prototype[e+l(i)]=function(e,t,o){return new n(this.element,i,e,t,o)}})}function d(e,n,i,o){c(e,{directions:g,startValue:function(e){return this._startValue=e,this},endValue:function(e){return this._endValue=e,this},shouldHide:function(){return this._shouldHide},prepare:function(e,r){var s,a,l=this,c="out"===this._direction,d=l.element.data(n),u=!(isNaN(d)||d==i);s=u?d:t!==this._startValue?this._startValue:c?i:o,a=t!==this._endValue?this._endValue:c?o:i,this._reverse?(e[n]=a,r[n]=s):(e[n]=s,r[n]=a),l._shouldHide=r[n]===o}})}function u(e,t){var n=C.directions[t].vertical,i=e[n?Z:X]()/2+"px";return _[t].replace("$size",i)}var h,f,p,m,g,v,_,b,w,y,k,x,C=window.kendo,S=C.effects,T=e.each,D=e.extend,A=e.proxy,E=C.support,M=E.browser,I=E.transforms,R=E.transitions,F={scale:0,scalex:0,scaley:0,scale3d:0},z={translate:0,translatex:0,translatey:0,translate3d:0},P=t!==document.documentElement.style.zoom&&!I,B=/matrix3?d?\s*\(.*,\s*([\d\.\-]+)\w*?,\s*([\d\.\-]+)\w*?,\s*([\d\.\-]+)\w*?,\s*([\d\.\-]+)\w*?/i,L=/^(-?[\d\.\-]+)?[\w\s]*,?\s*(-?[\d\.\-]+)?[\w\s]*/i,H=/translatex?$/i,N=/(zoom|fade|expand)(\w+)/,O=/(zoom|fade|expand)/,V=/[xy]$/i,U=["perspective","rotate","rotatex","rotatey","rotatez","rotate3d","scale","scalex","scaley","scalez","scale3d","skew","skewx","skewy","translate","translatex","translatey","translatez","translate3d","matrix","matrix3d"],W=["rotate","scale","scalex","scaley","skew","skewx","skewy","translate","translatex","translatey","matrix"],q={rotate:"deg",scale:"",skew:"px",translate:"px"},j=I.css,G=Math.round,$="",Y="px",K="none",Q="auto",X="width",Z="height",J="hidden",ee="origin",te="abortId",ne="overflow",ie="translate",oe="position",re="completeCallback",se=j+"transition",ae=j+"transform",le=j+"backface-visibility",ce=j+"perspective",de="1500px",ue="perspective("+de+")",he={left:{reverse:"right",property:"left",transition:"translatex",vertical:!1,modifier:-1},right:{reverse:"left",property:"left",transition:"translatex",vertical:!1,modifier:1},down:{reverse:"up",property:"top",transition:"translatey",vertical:!0,modifier:1},up:{reverse:"down",property:"top",transition:"translatey",vertical:!0,modifier:-1},top:{reverse:"bottom"},bottom:{reverse:"top"},"in":{reverse:"out",modifier:-1},out:{reverse:"in",modifier:1},vertical:{reverse:"vertical"},horizontal:{reverse:"horizontal"}};C.directions=he,D(e.fn,{kendoStop:function(e,t){return R?S.stopQueue(this,e||!1,t||!1):this.stop(e,t)}}),I&&!R&&(T(W,function(n,i){e.fn[i]=function(n){if(t===n)return a(this,i);var o=e(this)[0],r=i+"("+n+q[i.replace(V,"")]+")";return o.style.cssText.indexOf(ae)==-1?e(this).css(ae,r):o.style.cssText=o.style.cssText.replace(RegExp(i+"\\(.*?\\)","i"),r),this},e.fx.step[i]=function(t){e(t.elem)[i](t.now)}}),h=e.fx.prototype.cur,e.fx.prototype.cur=function(){return W.indexOf(this.prop)!=-1?parseFloat(e(this.elem)[this.prop]()):h.apply(this,arguments)}),C.toggleClass=function(e,t,n,i){return t&&(t=t.split(" "),R&&(n=D({exclusive:"all",duration:400,ease:"ease-out"},n),e.css(se,n.exclusive+" "+n.duration+"ms "+n.ease),setTimeout(function(){e.css(se,"").css(Z)},n.duration)),T(t,function(t,n){e.toggleClass(n,i)})),e},C.parseEffects=function(e,t){var n={};return"string"==typeof e?T(e.split(" "),function(e,i){var o=!O.test(i),r=i.replace(N,function(e,t,n){return t+":"+n.toLowerCase()}),s=r.split(":"),a=s[1],l={};s.length>1&&(l.direction=t&&o?he[a].reverse:a),n[s[0]]=l}):T(e,function(e){var i=this.direction;i&&t&&!O.test(e)&&(this.direction=he[i].reverse),n[e]=this}),n},R&&D(S,{transition:function(t,n,i){var r,a,l,c,d=0,u=t.data("keys")||[];i=D({duration:200,ease:"ease-out",complete:null,exclusive:"all"},i),l=!1,c=function(){l||(l=!0,a&&(clearTimeout(a),a=null),t.removeData(te).dequeue().css(se,"").css(se),i.complete.call(t))},i.duration=e.fx?e.fx.speeds[i.duration]||i.duration:i.duration,r=s(t,n),e.merge(u,o(r)),t.data("keys",e.unique(u)).height(),t.css(se,i.exclusive+" "+i.duration+"ms "+i.ease).css(se),t.css(r).css(ae),R.event&&(t.one(R.event,c),0!==i.duration&&(d=500)),a=setTimeout(c,i.duration+d),t.data(te,a),t.data(re,c)},stopQueue:function(e,t,n){var i,o=e.data("keys"),r=!n&&o,s=e.data(re);return r&&(i=C.getComputedStyles(e[0],o)),s&&s(),r&&e.css(i),e.removeData("keys").stop(t)}}),f=C.Class.extend({init:function(e,t){var n=this;n.element=e,n.effects=[],n.options=t,n.restore=[]},run:function(t){var n,i,o,a,l,c,d,u=this,h=t.length,f=u.element,p=u.options,m=e.Deferred(),g={},v={};for(u.effects=t,m.then(e.proxy(u,"complete")),f.data("animating",!0),i=0;i<h;i++)for(n=t[i],n.setReverse(p.reverse),n.setOptions(p),u.addRestoreProperties(n.restore),n.prepare(g,v),l=n.children(),o=0,c=l.length;o<c;o++)l[o].duration(p.duration).run();for(d in p.effects)D(v,p.effects[d].properties);for(f.is(":visible")||D(g,{display:f.data("olddisplay")||"block"}),I&&!p.reset&&(a=f.data("targetTransform"),a&&(g=D(a,g))),g=s(f,g),I&&!R&&(g=r(g)),f.css(g).css(ae),i=0;i<h;i++)t[i].setup();return p.init&&p.init(),f.data("targetTransform",v),S.animate(f,v,D({},p,{complete:m.resolve})),m.promise()},stop:function(){e(this.element).kendoStop(!0,!0)},addRestoreProperties:function(e){for(var t,n=this.element,i=0,o=e.length;i<o;i++)t=e[i],this.restore.push(t),n.data(t)||n.data(t,n.css(t))},restoreCallback:function(){var e,t,n,i=this.element;for(e=0,t=this.restore.length;e<t;e++)n=this.restore[e],i.css(n,i.data(n))},complete:function(){var t=this,n=0,i=t.element,o=t.options,r=t.effects,s=r.length;for(i.removeData("animating").dequeue(),o.hide&&i.data("olddisplay",i.css("display")).hide(),this.restoreCallback(),P&&!I&&setTimeout(e.proxy(this,"restoreCallback"),0);n<s;n++)r[n].teardown();o.completeCallback&&o.completeCallback(i)}}),S.promise=function(e,t){var n,i,o,r=[],s=new f(e,t),a=C.parseEffects(t.effects);t.effects=a;for(o in a)n=S[l(o)],n&&(i=new n(e,a[o].direction),r.push(i));r[0]?s.run(r):(e.is(":visible")||e.css({display:e.data("olddisplay")||"block"}).css("display"),t.init&&t.init(),e.dequeue(),s.complete())},D(S,{animate:function(n,o,s){var a=s.transition!==!1;delete s.transition,R&&"transition"in S&&a?S.transition(n,o,s):I?n.animate(r(o),{queue:!1,show:!1,hide:!1,duration:s.duration,complete:s.complete}):n.each(function(){var n=e(this),r={};T(U,function(e,s){var a,l,c,d,u,h,f,p=o?o[s]+" ":null;p&&(l=o,s in F&&o[s]!==t?(a=p.match(L),I&&D(l,{scale:+a[0]})):s in z&&o[s]!==t&&(c=n.css(oe),d="absolute"==c||"fixed"==c,n.data(ie)||(d?n.data(ie,{top:i(n,"top")||0,left:i(n,"left")||0,bottom:i(n,"bottom"),right:i(n,"right")}):n.data(ie,{top:i(n,"marginTop")||0,left:i(n,"marginLeft")||0})),u=n.data(ie),a=p.match(L),a&&(h=s==ie+"y"?0:+a[1],f=s==ie+"y"?+a[1]:+a[2],d?(isNaN(u.right)?isNaN(h)||D(l,{left:u.left+h}):isNaN(h)||D(l,{right:u.right-h}),isNaN(u.bottom)?isNaN(f)||D(l,{top:u.top+f}):isNaN(f)||D(l,{bottom:u.bottom-f})):(isNaN(h)||D(l,{marginLeft:u.left+h}),isNaN(f)||D(l,{marginTop:u.top+f})))),!I&&"scale"!=s&&s in l&&delete l[s],l&&D(r,l))}),M.msie&&delete r.scale,n.animate(r,{queue:!1,show:!1,hide:!1,duration:s.duration,complete:s.complete})})}}),S.animatedPromise=S.promise,p=C.Class.extend({init:function(e,t){var n=this;n.element=e,n._direction=t,n.options={},n._additionalEffects=[],n.restore||(n.restore=[])},reverse:function(){return this._reverse=!0,this.run()},play:function(){return this._reverse=!1,this.run()},add:function(e){return this._additionalEffects.push(e),this},direction:function(e){return this._direction=e,this},duration:function(e){return this._duration=e,this},compositeRun:function(){var e=this,t=new f(e.element,{reverse:e._reverse,duration:e._duration}),n=e._additionalEffects.concat([e]);return t.run(n)},run:function(){if(this._additionalEffects&&this._additionalEffects[0])return this.compositeRun();var t,n,i=this,o=i.element,a=0,l=i.restore,c=l.length,d=e.Deferred(),u={},h={},f=i.children(),p=f.length;for(d.then(e.proxy(i,"_complete")),o.data("animating",!0),a=0;a<c;a++)t=l[a],o.data(t)||o.data(t,o.css(t));for(a=0;a<p;a++)f[a].duration(i._duration).run();return i.prepare(u,h),o.is(":visible")||D(u,{display:o.data("olddisplay")||"block"}),I&&(n=o.data("targetTransform"),n&&(u=D(n,u))),u=s(o,u),I&&!R&&(u=r(u)),o.css(u).css(ae),i.setup(),o.data("targetTransform",h),S.animate(o,h,{duration:i._duration,complete:d.resolve}),d.promise()},stop:function(){var t=0,n=this.children(),i=n.length;for(t=0;t<i;t++)n[t].stop();return e(this.element).kendoStop(!0,!0),this},restoreCallback:function(){var e,t,n,i=this.element;for(e=0,t=this.restore.length;e<t;e++)n=this.restore[e],i.css(n,i.data(n))},_complete:function(){var t=this,n=t.element;n.removeData("animating").dequeue(),t.restoreCallback(),t.shouldHide()&&n.data("olddisplay",n.css("display")).hide(),P&&!I&&setTimeout(e.proxy(t,"restoreCallback"),0),t.teardown()},setOptions:function(e){D(!0,this.options,e)},children:function(){return[]},shouldHide:e.noop,setup:e.noop,prepare:e.noop,teardown:e.noop,directions:[],setReverse:function(e){return this._reverse=e,this}}),m=["left","right","up","down"],g=["in","out"],c("slideIn",{directions:m,divisor:function(e){return this.options.divisor=e,this},prepare:function(e,t){var n,i=this,o=i.element,r=C._outerWidth,s=C._outerHeight,a=he[i._direction],l=-a.modifier*(a.vertical?s(o):r(o)),c=l/(i.options&&i.options.divisor||1)+Y,d="0px";i._reverse&&(n=e,e=t,t=n),I?(e[a.transition]=c,t[a.transition]=d):(e[a.property]=c,t[a.property]=d)}}),c("tile",{directions:m,init:function(e,t,n){p.prototype.init.call(this,e,t),this.options={previous:n}},previousDivisor:function(e){return this.options.previousDivisor=e,this},children:function(){var e=this,t=e._reverse,n=e.options.previous,i=e.options.previousDivisor||1,o=e._direction,r=[C.fx(e.element).slideIn(o).setReverse(t)];return n&&r.push(C.fx(n).slideIn(he[o].reverse).divisor(i).setReverse(!t)),r}}),d("fade","opacity",1,0),d("zoom","scale",1,.01),c("slideMargin",{prepare:function(e,t){var n,i=this,o=i.element,r=i.options,s=o.data(ee),a=r.offset,l=i._reverse;l||null!==s||o.data(ee,parseFloat(o.css("margin-"+r.axis))),n=o.data(ee)||0,t["margin-"+r.axis]=l?n:n+a}}),c("slideTo",{prepare:function(e,t){var n=this,i=n.element,o=n.options,r=o.offset.split(","),s=n._reverse;I?(t.translatex=s?0:r[0],t.translatey=s?0:r[1]):(t.left=s?0:r[0],t.top=s?0:r[1]),i.css("left")}}),c("expand",{directions:["horizontal","vertical"],restore:[ne],prepare:function(e,n){var i=this,o=i.element,r=i.options,s=i._reverse,a="vertical"===i._direction?Z:X,l=o[0].style[a],c=o.data(a),d=parseFloat(c||l),u=G(o.css(a,Q)[a]());e.overflow=J,d=r&&r.reset?u||d:d||u,n[a]=(s?0:d)+Y,e[a]=(s?d:0)+Y,c===t&&o.data(a,l)},shouldHide:function(){return this._reverse},teardown:function(){var e=this,t=e.element,n="vertical"===e._direction?Z:X,i=t.data(n);i!=Q&&i!==$||setTimeout(function(){t.css(n,Q).css(n)},0)}}),v={position:"absolute",marginLeft:0,marginTop:0,scale:1},c("transfer",{init:function(e,t){this.element=e,this.options={target:t},this.restore=[]},setup:function(){this.element.appendTo(document.body)},prepare:function(e,t){var n=this,i=n.element,o=S.box(i),r=S.box(n.options.target),s=a(i,"scale"),l=S.fillScale(r,o),c=S.transformOrigin(r,o);D(e,v),t.scale=1,i.css(ae,"scale(1)").css(ae),i.css(ae,"scale("+s+")"),e.top=o.top,e.left=o.left,e.transformOrigin=c.x+Y+" "+c.y+Y,n._reverse?e.scale=l:t.scale=l}}),_={top:"rect(auto auto $size auto)",bottom:"rect($size auto auto auto)",left:"rect(auto $size auto auto)",right:"rect(auto auto auto $size)"},b={top:{start:"rotatex(0deg)",end:"rotatex(180deg)"},bottom:{start:"rotatex(-180deg)",end:"rotatex(0deg)"},left:{start:"rotatey(0deg)",end:"rotatey(-180deg)"},right:{start:"rotatey(180deg)",end:"rotatey(0deg)"}},c("turningPage",{directions:m,init:function(e,t,n){p.prototype.init.call(this,e,t),this._container=n},prepare:function(e,t){var n=this,i=n._reverse,o=i?he[n._direction].reverse:n._direction,r=b[o];e.zIndex=1,n._clipInHalf&&(e.clip=u(n._container,C.directions[o].reverse)),e[le]=J,t[ae]=ue+(i?r.start:r.end),e[ae]=ue+(i?r.end:r.start)},setup:function(){this._container.append(this.element)},face:function(e){return this._face=e,this},shouldHide:function(){var e=this,t=e._reverse,n=e._face;return t&&!n||!t&&n},clipInHalf:function(e){return this._clipInHalf=e,this},temporary:function(){return this.element.addClass("temp-page"),this}}),c("staticPage",{directions:m,init:function(e,t,n){p.prototype.init.call(this,e,t),this._container=n},restore:["clip"],prepare:function(e,t){var n=this,i=n._reverse?he[n._direction].reverse:n._direction;e.clip=u(n._container,i),e.opacity=.999,t.opacity=1},shouldHide:function(){var e=this,t=e._reverse,n=e._face;return t&&!n||!t&&n},face:function(e){return this._face=e,this}}),c("pageturn",{directions:["horizontal","vertical"],init:function(e,t,n,i){p.prototype.init.call(this,e,t),this.options={},this.options.face=n,this.options.back=i},children:function(){var e,t=this,n=t.options,i="horizontal"===t._direction?"left":"top",o=C.directions[i].reverse,r=t._reverse,s=n.face.clone(!0).removeAttr("id"),a=n.back.clone(!0).removeAttr("id"),l=t.element;return r&&(e=i,i=o,o=e),[C.fx(n.face).staticPage(i,l).face(!0).setReverse(r),C.fx(n.back).staticPage(o,l).setReverse(r),C.fx(s).turningPage(i,l).face(!0).clipInHalf(!0).temporary().setReverse(r),C.fx(a).turningPage(o,l).clipInHalf(!0).temporary().setReverse(r)]},prepare:function(e,t){e[ce]=de,e.transformStyle="preserve-3d",e.opacity=.999,t.opacity=1},teardown:function(){this.element.find(".temp-page").remove()}}),c("flip",{directions:["horizontal","vertical"],init:function(e,t,n,i){p.prototype.init.call(this,e,t),this.options={},this.options.face=n,this.options.back=i},children:function(){var e,t=this,n=t.options,i="horizontal"===t._direction?"left":"top",o=C.directions[i].reverse,r=t._reverse,s=t.element;return r&&(e=i,i=o,o=e),[C.fx(n.face).turningPage(i,s).face(!0).setReverse(r),C.fx(n.back).turningPage(o,s).setReverse(r)]},prepare:function(e){e[ce]=de,e.transformStyle="preserve-3d"}}),w=!E.mobileOS.android,y=".km-touch-scrollbar, .km-actionsheet-wrapper",c("replace",{_before:e.noop,_after:e.noop,init:function(t,n,i){p.prototype.init.call(this,t),this._previous=e(n),this._transitionClass=i},duration:function(){throw Error("The replace effect does not support duration setting; the effect duration may be customized through the transition class rule")},beforeTransition:function(e){return this._before=e,this},afterTransition:function(e){return this._after=e,this},_both:function(){return e().add(this._element).add(this._previous)},_containerClass:function(){var e=this._direction,t="k-fx k-fx-start k-fx-"+this._transitionClass;return e&&(t+=" k-fx-"+e),this._reverse&&(t+=" k-fx-reverse"),t},complete:function(t){if(!(!this.deferred||t&&e(t.target).is(y))){var n=this.container;n.removeClass("k-fx-end").removeClass(this._containerClass()).off(R.event,this.completeProxy),this._previous.hide().removeClass("k-fx-current"),this.element.removeClass("k-fx-next"),w&&n.css(ne,""),this.isAbsolute||this._both().css(oe,""),this.deferred.resolve(),delete this.deferred}},run:function(){if(this._additionalEffects&&this._additionalEffects[0])return this.compositeRun();var t,n=this,i=n.element,o=n._previous,r=i.parents().filter(o.parents()).first(),s=n._both(),a=e.Deferred(),l=i.css(oe);return r.length||(r=i.parent()),this.container=r,this.deferred=a,this.isAbsolute="absolute"==l,this.isAbsolute||s.css(oe,"absolute"),w&&(t=r.css(ne),r.css(ne,"hidden")),R?(i.addClass("k-fx-hidden"),r.addClass(this._containerClass()),this.completeProxy=e.proxy(this,"complete"),r.on(R.event,this.completeProxy),C.animationFrame(function(){i.removeClass("k-fx-hidden").addClass("k-fx-next"),o.css("display","").addClass("k-fx-current"),n._before(o,i),C.animationFrame(function(){r.removeClass("k-fx-start").addClass("k-fx-end"),n._after(o,i)})})):this.complete(),a.promise()},stop:function(){this.complete()}}),k=C.Class.extend({init:function(){var e=this;e._tickProxy=A(e._tick,e),e._started=!1},tick:e.noop,done:e.noop,onEnd:e.noop,onCancel:e.noop,start:function(){this.enabled()&&(this.done()?this.onEnd():(this._started=!0,C.animationFrame(this._tickProxy)))},enabled:function(){return!0},cancel:function(){this._started=!1,this.onCancel()},_tick:function(){var e=this;e._started&&(e.tick(),e.done()?(e._started=!1,e.onEnd()):C.animationFrame(e._tickProxy))}}),x=k.extend({init:function(e){var t=this;D(t,e),k.fn.init.call(t)},done:function(){return this.timePassed()>=this.duration},timePassed:function(){return Math.min(this.duration,new Date-this.startDate)},moveTo:function(e){var t=this,n=t.movable;t.initial=n[t.axis],t.delta=e.location-t.initial,t.duration="number"==typeof e.duration?e.duration:300,t.tick=t._easeProxy(e.ease),t.startDate=new Date,t.start()},_easeProxy:function(e){var t=this;return function(){t.movable.moveAxis(t.axis,e(t.timePassed(),t.initial,t.delta,t.duration))}}}),D(x,{easeOutExpo:function(e,t,n,i){return e==i?t+n:n*(-Math.pow(2,-10*e/i)+1)+t},easeOutBack:function(e,t,n,i,o){return o=1.70158,n*((e=e/i-1)*e*((o+1)*e+o)+1)+t}}),S.Animation=k,S.Transition=x,S.createEffect=c,S.box=function(t){t=e(t);var n=t.offset();return n.width=C._outerWidth(t),n.height=C._outerHeight(t),n},S.transformOrigin=function(e,t){var n=(e.left-t.left)*t.width/(t.width-e.width),i=(e.top-t.top)*t.height/(t.height-e.height);return{x:isNaN(n)?0:n,y:isNaN(i)?0:i}},S.fillScale=function(e,t){return Math.min(e.width/t.width,e.height/t.height)},S.fitScale=function(e,t){return Math.max(e.width/t.width,e.height/t.height)}}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.view.min",["kendo.core.min","kendo.binder.min","kendo.fx.min"],e)}(function(){return function(e,t){function n(e){if(!e)return{};var t=e.match(_)||[];return{type:t[1],direction:t[3],reverse:"reverse"===t[5]}}var i=window.kendo,o=i.Observable,r="SCRIPT",s="init",a="show",l="hide",c="transitionStart",d="transitionEnd",u="attach",h="detach",f=/unrecognized expression/,p=o.extend({init:function(e,t){var n=this;t=t||{},o.fn.init.call(n),n.content=e,n.id=i.guid(),n.tagName=t.tagName||"div",n.model=t.model,n._wrap=t.wrap!==!1,this._evalTemplate=t.evalTemplate||!1,n._fragments={},n.bind([s,a,l,c,d],t)},render:function(t){var n=this,o=!n.element;return o&&(n.element=n._createElement()),t&&e(t).append(n.element),o&&(i.bind(n.element,n.model),n.trigger(s)),t&&(n._eachFragment(u),n.trigger(a)),n.element},clone:function(){return new m(this)},triggerBeforeShow:function(){return!0},triggerBeforeHide:function(){return!0},showStart:function(){this.element.css("display","")},showEnd:function(){},hideEnd:function(){this.hide()},beforeTransition:function(e){this.trigger(c,{type:e})},afterTransition:function(e){this.trigger(d,{type:e})},hide:function(){this._eachFragment(h),this.element.detach(),this.trigger(l)},destroy:function(){var e=this.element;e&&(i.unbind(e),i.destroy(e),e.remove())},fragments:function(t){e.extend(this._fragments,t)},_eachFragment:function(e){for(var t in this._fragments)this._fragments[t][e](this,t)},_createElement:function(){var t,n,o,s=this,a="<"+s.tagName+" />";try{n=e(document.getElementById(s.content)||s.content),n[0].tagName===r&&(n=n.html())}catch(l){f.test(l.message)&&(n=s.content)}return"string"==typeof n?(n=n.replace(/^\s+|\s+$/g,""),s._evalTemplate&&(n=i.template(n)(s.model||{})),t=e(a).append(n),s._wrap||(t=t.contents())):(t=n,s._evalTemplate&&(o=e(i.template(e("<div />").append(t.clone(!0)).html())(s.model||{})),e.contains(document,t[0])&&t.replaceWith(o),t=o),s._wrap&&(t=t.wrapAll(a).parent())),t}}),m=i.Class.extend({init:function(t){e.extend(this,{element:t.element.clone(!0),transition:t.transition,id:t.id}),t.element.parent().append(this.element)},hideEnd:function(){this.element.remove()},beforeTransition:e.noop,afterTransition:e.noop}),g=p.extend({init:function(e,t){p.fn.init.call(this,e,t),this.containers={}},container:function(e){var t=this.containers[e];return t||(t=this._createContainer(e),this.containers[e]=t),t},showIn:function(e,t,n){this.container(e).show(t,n)},_createContainer:function(e){var t,n=this.render(),i=n.find(e);if(!i.length&&n.is(e)){if(!n.is(e))throw Error("can't find a container with the specified "+e+" selector");i=n}return t=new b(i),t.bind("accepted",function(e){e.view.render(i)}),t}}),v=p.extend({attach:function(e,t){e.element.find(t).replaceWith(this.render())},detach:function(){}}),_=/^(\w+)(:(\w+))?( (\w+))?$/,b=o.extend({init:function(e){o.fn.init.call(this),this.container=e,this.history=[],this.view=null,this.running=!1},after:function(){this.running=!1,this.trigger("complete",{view:this.view}),this.trigger("after")},end:function(){this.view.showEnd(),this.previous.hideEnd(),this.after()},show:function(e,t,o){if(!e.triggerBeforeShow()||this.view&&!this.view.triggerBeforeHide())return this.trigger("after"),!1;o=o||e.id;var r=this,s=e===r.view?e.clone():r.view,a=r.history,l=a[a.length-2]||{},c=l.id===o,d=t||(c?a[a.length-1].transition:e.transition),u=n(d);return r.running&&r.effect.stop(),"none"===d&&(d=null),r.trigger("accepted",{view:e}),r.view=e,r.previous=s,r.running=!0,c?a.pop():a.push({id:o,transition:d}),s?(d&&i.effects.enabled?(e.element.addClass("k-fx-hidden"),e.showStart(),c&&!t&&(u.reverse=!u.reverse),r.effect=i.fx(e.element).replace(s.element,u.type).beforeTransition(function(){e.beforeTransition("show"),s.beforeTransition("hide")}).afterTransition(function(){e.afterTransition("show"),s.afterTransition("hide")}).direction(u.direction).setReverse(u.reverse),
r.effect.run().then(function(){r.end()})):(e.showStart(),r.end()),!0):(e.showStart(),e.showEnd(),r.after(),!0)}});i.ViewContainer=b,i.Fragment=v,i.Layout=g,i.View=p,i.ViewClone=m}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.dom.min",["kendo.core.min"],e)}(function(){return function(e){function t(){this.node=null}function n(){}function i(e,t,n){this.nodeName=e,this.attr=t||{},this.children=n||[]}function o(e){this.nodeValue=e+""}function r(e){this.html=e}function s(e,t){for(h.innerHTML=t;h.firstChild;)e.appendChild(h.firstChild)}function a(e){return new r(e)}function l(e,t,n){return new i(e,t,n)}function c(e){return new o(e)}function d(e){this.root=e,this.children=[]}var u,h;t.prototype={remove:function(){this.node.parentNode&&this.node.parentNode.removeChild(this.node),this.attr={}},attr:{},text:function(){return""}},n.prototype={nodeName:"#null",attr:{style:{}},children:[],remove:function(){}},u=new n,i.prototype=new t,i.prototype.appendTo=function(e){var t,n=document.createElement(this.nodeName),i=this.children;for(t=0;t<i.length;t++)i[t].render(n,u);return e.appendChild(n),n},i.prototype.render=function(e,t){var n,i,o,r,s,a;if(t.nodeName!==this.nodeName)t.remove(),n=this.appendTo(e);else{if(n=t.node,o=this.children,r=o.length,s=t.children,a=s.length,Math.abs(a-r)>2)return void this.render({appendChild:function(n){e.replaceChild(n,t.node)}},u);for(i=0;i<r;i++)o[i].render(n,s[i]||u);for(i=r;i<a;i++)s[i].remove()}this.node=n,this.syncAttributes(t.attr),this.removeAttributes(t.attr)},i.prototype.syncAttributes=function(e){var t,n,i,o=this.attr;for(t in o)n=o[t],i=e[t],"style"===t?this.setStyle(n,i):n!==i&&this.setAttribute(t,n,i)},i.prototype.setStyle=function(e,t){var n,i=this.node;if(t)for(n in e)e[n]!==t[n]&&(i.style[n]=e[n]);else for(n in e)i.style[n]=e[n]},i.prototype.removeStyle=function(e){var t,n=this.attr.style||{},i=this.node;for(t in e)void 0===n[t]&&(i.style[t]="")},i.prototype.removeAttributes=function(e){var t,n=this.attr;for(t in e)"style"===t?this.removeStyle(e.style):void 0===n[t]&&this.removeAttribute(t)},i.prototype.removeAttribute=function(e){var t=this.node;"style"===e?t.style.cssText="":"className"===e?t.className="":t.removeAttribute(e)},i.prototype.setAttribute=function(e,t){var n=this.node;void 0!==n[e]?n[e]=t:n.setAttribute(e,t)},i.prototype.text=function(){var e,t="";for(e=0;e<this.children.length;++e)t+=this.children[e].text();return t},o.prototype=new t,o.prototype.nodeName="#text",o.prototype.render=function(e,t){var n;t.nodeName!==this.nodeName?(t.remove(),n=document.createTextNode(this.nodeValue),e.appendChild(n)):(n=t.node,this.nodeValue!==t.nodeValue&&n.parentNode&&(n.nodeValue=this.nodeValue)),this.node=n},o.prototype.text=function(){return this.nodeValue},r.prototype={nodeName:"#html",attr:{},remove:function(){var e,t;for(e=0;e<this.nodes.length;e++)t=this.nodes[e],t.parentNode&&t.parentNode.removeChild(t)},render:function(e,t){var n,i;if(t.nodeName!==this.nodeName||t.html!==this.html)for(t.remove(),n=e.lastChild,s(e,this.html),this.nodes=[],i=n?n.nextSibling:e.firstChild;i;i=i.nextSibling)this.nodes.push(i);else this.nodes=t.nodes.slice(0)}},h=document.createElement("div"),d.prototype={html:a,element:l,text:c,render:function(e){var t,n,i,o=this.children;for(t=0,n=e.length;t<n;t++)i=o[t],i?i.node&&i.node.parentNode||(i.remove(),i=u):i=u,e[t].render(this.root,i);for(t=n;t<o.length;t++)o[t].remove();this.children=e}},e.dom={html:a,text:c,element:l,Tree:d,Node:t}}(window.kendo),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.ooxml.min",["kendo.core.min"],e)}(function(){return function(e,t){function n(e){var t=Math.floor(e/26)-1;return(t>=0?n(t):"")+String.fromCharCode(65+e%26)}function i(e,t){return n(t)+(e+1)}function o(e,t){return n(t)+"$"+(e+1)}function r(e){var t=e.frozenRows||(e.freezePane||{}).rowSplit||1;return t-1}function s(e){return(e/7*100+.5)/100}function a(e){return.75*e}function l(e){return(e+"").replace(/[\x00-\x08]/g,"").replace(/\n/g,"\r\n")}function c(e){return e.length<6&&(e=e.replace(/(\w)/g,function(e,t){return t+t})),e=e.substring(1).toUpperCase(),e.length<8&&(e="FF"+e),e}function d(e){var t="thin";return 2===e?t="medium":3===e&&(t="thick"),t}function u(e,t){var n="";return t&&(n+="<"+e+' style="'+d(t.size)+'">',t.color&&(n+='<color rgb="'+c(t.color)+'"/>'),n+="</"+e+">"),n}function h(e){return"<border>"+u("left",e.left)+u("right",e.right)+u("top",e.top)+u("bottom",e.bottom)+"</border>"}function f(e,t){var n,i,o,r=[],s=[];for(p(e,function(e,t){var n={_source:e,index:t,height:e.height,cells:[]};r.push(n),s[t]=n}),n=m(r).slice(0),i={rowData:r,rowsByIndex:s,mergedCells:t},o=0;o<n.length;o++)b(n[o],i),delete n[o]._source;return m(r)}function p(e,t){var n,i,o;for(n=0;n<e.length;n++)i=e[n],i&&(o=i.index,"number"!=typeof o&&(o=n),t(i,o))}function m(e){return e.sort(function(e,t){return e.index-t.index})}function g(e,t){e.indexOf(t)<0&&e.push(t)}function v(e,t){var n,i,o,r;for(t=t,n=0;n<e.length;++n)if(i=e[n],o=i.substr(0,2),o==t)return r=i.substr(3),o=_(o),r=_(r),{rowSpan:r.row-o.row+1,colSpan:r.col-o.col+1}}function _(e){function t(e){e=e.toUpperCase();for(var t=0,n=0;n<e.length;++n)t=26*t+e.charCodeAt(n)-64;return t-1}function n(e){return parseInt(e,10)-1}var i=/^([a-z]+)(\d+)$/i.exec(e);return{row:n(i[2]),col:t(i[1])}}function b(e,t){var n,o,r,s,a,l,c,d,u,h=e._source,f=e.index,p=h.cells,m=e.cells;if(p)for(n=0;n<p.length;n++)if(o=p[n]||V,r=o.rowSpan||1,s=o.colSpan||1,a=w(m,o),l=i(f,a),1==r&&1==s&&(c=v(t.mergedCells,l),c&&(s=c.colSpan,r=c.rowSpan)),x(o,m,a,s),(r>1||s>1)&&g(t.mergedCells,l+":"+i(f+r-1,a+s-1)),r>1)for(d=f+1;d<f+r;d++)u=t.rowsByIndex[d],u||(u=t.rowsByIndex[d]={index:d,cells:[]},t.rowData.push(u)),x(o,u.cells,a-1,s+1)}function w(e,t){var n;return"number"==typeof t.index?(n=t.index,y(e,t,t.index)):n=k(e,t),n}function y(e,t,n){e[n]=t}function k(e,t){var n,i=e.length;for(n=0;n<e.length+1;n++)if(!e[n]){e[n]=t,i=n;break}return i}function x(e,t,n,i){var o,r;for(o=1;o<i;o++)r={borderTop:e.borderTop,borderRight:e.borderRight,borderBottom:e.borderBottom,borderLeft:e.borderLeft},y(t,r,n+o)}function C(e){return U({ref:e.ref,columns:e.columns,generators:{custom:W,dynamic:q,top:j,value:G}})}var S='<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r\n<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships"><Relationship Id="rId3" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties" Target="docProps/app.xml"/><Relationship Id="rId2" Type="http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties" Target="docProps/core.xml"/><Relationship Id="rId1" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument" Target="xl/workbook.xml"/></Relationships>',T=t.template('<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r\n<cp:coreProperties xmlns:cp="http://schemas.openxmlformats.org/package/2006/metadata/core-properties" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:dcterms="http://purl.org/dc/terms/" xmlns:dcmitype="http://purl.org/dc/dcmitype/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><dc:creator>${creator}</dc:creator><cp:lastModifiedBy>${lastModifiedBy}</cp:lastModifiedBy><dcterms:created xsi:type="dcterms:W3CDTF">${created}</dcterms:created><dcterms:modified xsi:type="dcterms:W3CDTF">${modified}</dcterms:modified></cp:coreProperties>'),D=t.template('<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r\n<Properties xmlns="http://schemas.openxmlformats.org/officeDocument/2006/extended-properties" xmlns:vt="http://schemas.openxmlformats.org/officeDocument/2006/docPropsVTypes"><Application>Microsoft Excel</Application><DocSecurity>0</DocSecurity><ScaleCrop>false</ScaleCrop><HeadingPairs><vt:vector size="2" baseType="variant"><vt:variant><vt:lpstr>Worksheets</vt:lpstr></vt:variant><vt:variant><vt:i4>${sheets.length}</vt:i4></vt:variant></vt:vector></HeadingPairs><TitlesOfParts><vt:vector size="${sheets.length}" baseType="lpstr"># for (var idx = 0; idx < sheets.length; idx++) { ## if (sheets[idx].options.title) { #<vt:lpstr>${sheets[idx].options.title}</vt:lpstr># } else { #<vt:lpstr>Sheet${idx+1}</vt:lpstr># } ## } #</vt:vector></TitlesOfParts><LinksUpToDate>false</LinksUpToDate><SharedDoc>false</SharedDoc><HyperlinksChanged>false</HyperlinksChanged><AppVersion>14.0300</AppVersion></Properties>'),A=t.template('<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r\n<Types xmlns="http://schemas.openxmlformats.org/package/2006/content-types"><Default Extension="rels" ContentType="application/vnd.openxmlformats-package.relationships+xml" /><Default Extension="xml" ContentType="application/xml" /><Override PartName="/xl/workbook.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml" /><Override PartName="/xl/styles.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml"/><Override PartName="/xl/sharedStrings.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml"/># for (var idx = 1; idx <= count; idx++) { #<Override PartName="/xl/worksheets/sheet${idx}.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml" /># } #<Override PartName="/docProps/core.xml" ContentType="application/vnd.openxmlformats-package.core-properties+xml" /><Override PartName="/docProps/app.xml" ContentType="application/vnd.openxmlformats-officedocument.extended-properties+xml" /></Types>'),E=t.template('<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r\n<workbook xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships"><fileVersion appName="xl" lastEdited="5" lowestEdited="5" rupBuild="9303" /><workbookPr defaultThemeVersion="124226" /><bookViews><workbookView xWindow="240" yWindow="45" windowWidth="18195" windowHeight="7995" /></bookViews><sheets># for (var idx = 0; idx < sheets.length; idx++) { ## var options = sheets[idx].options; ## var name = options.name || options.title ## if (name) { #<sheet name="${name}" sheetId="${idx+1}" r:id="rId${idx+1}" /># } else { #<sheet name="Sheet${idx+1}" sheetId="${idx+1}" r:id="rId${idx+1}" /># } ## } #</sheets># if (filterNames.length || userNames.length) { #<definedNames> # for (var di = 0; di < filterNames.length; di++) { #<definedName name="_xlnm._FilterDatabase" hidden="1" localSheetId="${filterNames[di].localSheetId}">${filterNames[di].name}!$${filterNames[di].from}:$${filterNames[di].to}</definedName> # } # # for (var i = 0; i < userNames.length; ++i) { #<definedName name="${userNames[i].name}" hidden="${userNames[i].hidden ? 1 : 0}" # if (userNames[i].localSheetId != null) { # localSheetId="${userNames[i].localSheetId}" # } #>${userNames[i].value}</definedName> # } #</definedNames># } #<calcPr fullCalcOnLoad="1" calcId="145621" /></workbook>'),M=t.template('<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r\n<worksheet xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" xmlns:x14ac="http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac" mc:Ignorable="x14ac"><dimension ref="A1" /><sheetViews><sheetView #if(index==0) {# tabSelected="1" #}# workbookViewId="0" #if (showGridLines === false) {# showGridLines="0" #}#># if (frozenRows || frozenColumns) { #<pane state="frozen"# if (frozenColumns) { # xSplit="${frozenColumns}"# } ## if (frozenRows) { # ySplit="${frozenRows}"# } # topLeftCell="${String.fromCharCode(65 + (frozenColumns || 0))}${(frozenRows || 0)+1}"/># } #</sheetView></sheetViews><sheetFormatPr x14ac:dyDescent="0.25" defaultRowHeight="#= defaults.rowHeight ? defaults.rowHeight * 0.75 : 15 #" # if (defaults.columnWidth) { # defaultColWidth="#= kendo.ooxml.toWidth(defaults.columnWidth) #" # } # /># if (defaultCellStyleId != null || (columns && columns.length > 0)) { #<cols># if (!columns || !columns.length) { #<col min="1" max="16384" style="${defaultCellStyleId}" # if (defaults.columnWidth) { # width="#= kendo.ooxml.toWidth(defaults.columnWidth) #" # } # /># } ## for (var ci = 0; ci < columns.length; ci++) { ## var column = columns[ci]; ## var columnIndex = typeof column.index === "number" ? column.index + 1 : (ci + 1); ## if (column.width === 0) { #<col #if(defaultCellStyleId!=null){# style="${defaultCellStyleId}" #}#min="${columnIndex}" max="${columnIndex}" hidden="1" customWidth="1" /># } else if (column.width) { #<col #if(defaultCellStyleId!=null){# style="${defaultCellStyleId}" #}#min="${columnIndex}" max="${columnIndex}" customWidth="1"# if (column.autoWidth) { # width="${((column.width*7+5)/7*256)/256}" bestFit="1"# } else { # width="#= kendo.ooxml.toWidth(column.width) #" # } #/># } ## } #</cols># } #<sheetData># for (var ri = 0; ri < data.length; ri++) { ## var row = data[ri]; ## var rowIndex = typeof row.index === "number" ? row.index + 1 : (ri + 1); #<row r="${rowIndex}" x14ac:dyDescent="0.25" # if (row.height === 0) { # hidden="1" # }   else if (row.height) { # ht="#= kendo.ooxml.toHeight(row.height) #" customHeight="1" # } # ># for (var ci = 0; ci < row.data.length; ci++) { ## var cell = row.data[ci];#<c r="#=cell.ref#"# if (cell.style) { # s="#=cell.style#" # } ## if (cell.type) { # t="#=cell.type#"# } #># if (cell.formula != null) { #<f>${cell.formula}</f># } ## if (cell.value != null) { #<v>${cell.value}</v># } #</c># } #</row># } #</sheetData># if (autoFilter) { #<autoFilter ref="${autoFilter.from}:${autoFilter.to}"/># } else if (filter) { ##= kendo.ooxml.spreadsheetFilters(filter) ## } ## if (mergeCells.length) { #<mergeCells count="${mergeCells.length}"># for (var ci = 0; ci < mergeCells.length; ci++) { #<mergeCell ref="${mergeCells[ci]}"/># } #</mergeCells># } ## if (validations.length) { #<dataValidations># for (var vi = 0; vi < validations.length; vi++) { ## var val = validations[vi]; #<dataValidation sqref="#= val.sqref.join(" ") #" showErrorMessage="#= val.showErrorMessage #" type="#= val.type #"# if (val.type != "list") {# operator="#= val.operator #" # } # allowBlank="#= val.allowBlank #" showDropDown="#= val.showDropDown #"# if (val.error) {# error="#= val.error #" # } ## if (val.errorTitle) {# errorTitle="#= val.errorTitle #" # } #># if (val.formula1) { #<formula1>#: val.formula1 #</formula1># } ## if (val.formula2) { #<formula2>#: val.formula2 #</formula2># } #</dataValidation># } #</dataValidations># } ## if (hyperlinks.length) { #<hyperlinks># for (var hi = 0; hi < hyperlinks.length; hi++) { #<hyperlink ref="${hyperlinks[hi].ref}" r:id="rId${hi}"/># } #</hyperlinks># } #<pageMargins left="0.7" right="0.7" top="0.75" bottom="0.75" header="0.3" footer="0.3" /></worksheet>'),I=t.template('<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r\n<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships"># for (var idx = 1; idx <= count; idx++) { #<Relationship Id="rId${idx}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet" Target="worksheets/sheet${idx}.xml" /># } #<Relationship Id="rId${count+1}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles" Target="styles.xml" /><Relationship Id="rId${count+2}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings" Target="sharedStrings.xml" /></Relationships>'),R=t.template('<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r\n<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships"># for (var i = 0; i < hyperlinks.length; i++) { #<Relationship Id="rId${i}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink" Target="${hyperlinks[i].target}" TargetMode="External" /># } #</Relationships>'),F=t.template('<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r\n<sst xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main" count="${count}" uniqueCount="${uniqueCount}"># for (var index in indexes) { #<si><t>${index.substring(1)}</t></si># } #</sst>'),z=t.template('<?xml version="1.0" encoding="UTF-8"?><styleSheet xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="x14ac" xmlns:x14ac="http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac"><numFmts count="${formats.length}"># for (var fi = 0; fi < formats.length; fi++) { ## var format = formats[fi]; #<numFmt formatCode="${format.format}" numFmtId="${165+fi}" /># } #</numFmts><fonts count="${fonts.length+1}" x14ac:knownFonts="1"><font><sz val="11" /><color theme="1" /><name val="Calibri" /><family val="2" /><scheme val="minor" /></font># for (var fi = 0; fi < fonts.length; fi++) { ## var font = fonts[fi]; #<font># if (font.fontSize) { #<sz val="${font.fontSize}" /># } else { #<sz val="11" /># } ## if (font.bold) { #<b/># } ## if (font.italic) { #<i/># } ## if (font.underline) { #<u/># } ## if (font.color) { #<color rgb="${font.color}" /># } else { #<color theme="1" /># } ## if (font.fontFamily) { #<name val="${font.fontFamily}" /><family val="2" /># } else { #<name val="Calibri" /><family val="2" /><scheme val="minor" /># } #</font># } #</fonts><fills count="${fills.length+2}"><fill><patternFill patternType="none"/></fill><fill><patternFill patternType="gray125"/></fill># for (var fi = 0; fi < fills.length; fi++) { ## var fill = fills[fi]; ## if (fill.background) { #<fill><patternFill patternType="solid"><fgColor rgb="${fill.background}"/></patternFill></fill># } ## } #</fills><borders count="${borders.length+1}"><border><left/><right/><top/><bottom/><diagonal/></border># for (var bi = 0; bi < borders.length; bi++) { ##= kendo.ooxml.borderTemplate(borders[bi]) ## } #</borders><cellStyleXfs count="1"><xf borderId="0" fillId="0" fontId="0" /></cellStyleXfs><cellXfs count="${styles.length+1}"><xf numFmtId="0" fontId="0" fillId="0" borderId="0" xfId="0"/># for (var si = 0; si < styles.length; si++) { ## var style = styles[si]; #<xf xfId="0"# if (style.fontId) { # fontId="${style.fontId}" applyFont="1"# } ## if (style.fillId) { # fillId="${style.fillId}" applyFill="1"# } ## if (style.numFmtId) { # numFmtId="${style.numFmtId}" applyNumberFormat="1"# } ## if (style.textAlign || style.verticalAlign || style.wrap) { # applyAlignment="1"# } ## if (style.borderId) { # borderId="${style.borderId}" applyBorder="1"# } #># if (style.textAlign || style.verticalAlign || style.wrap) { #<alignment# if (style.textAlign) { # horizontal="${style.textAlign}"# } ## if (style.verticalAlign) { # vertical="${style.verticalAlign}"# } ## if (style.wrap) { # wrapText="1"# } #/># } #</xf># } #</cellXfs><cellStyles count="1"><cellStyle name="Normal" xfId="0" builtinId="0"/></cellStyles><dxfs count="0" /><tableStyles count="0" defaultTableStyle="TableStyleMedium2" defaultPivotStyle="PivotStyleMedium9" /></styleSheet>'),P=new Date(1900,0,0),B=t.Class.extend({init:function(e,t,n,i){this.options=e,this._strings=t,this._styles=n,this._borders=i,this._validations={}},relsToXML:function(){var e=this.options.hyperlinks||[];return e.length?R({hyperlinks:e}):""},toXML:function(e){var t,n,o,s,a,l,c=this.options.mergedCells||[],d=this.options.rows||[],u=f(d,c);this._readCells(u),t=this.options.filter,t&&"number"==typeof t.from&&"number"==typeof t.to?t={from:i(r(this.options),t.from),to:i(r(this.options),t.to)}:t&&t.ref&&t.columns&&(n=t,t=null),o=[];for(s in this._validations)Object.prototype.hasOwnProperty.call(this._validations,s)&&o.push(this._validations[s]);return a=null,this.options.defaultCellStyle&&(a=this._lookupStyle(this.options.defaultCellStyle)),l=this.options.freezePane||{},M({frozenColumns:this.options.frozenColumns||l.colSplit,frozenRows:this.options.frozenRows||l.rowSplit,columns:this.options.columns,defaults:this.options.defaults||{},data:u,index:e,mergeCells:c,autoFilter:t,filter:n,showGridLines:this.options.showGridLines,hyperlinks:this.options.hyperlinks||[],validations:o,defaultCellStyleId:a})},_lookupString:function(e){var t="$"+e,n=this._strings.indexes[t];return void 0!==n?e=n:(e=this._strings.indexes[t]=this._strings.uniqueCount,this._strings.uniqueCount++),this._strings.count++,e},_lookupStyle:function(n){var i,o=t.stringify(n);return"{}"==o?0:(i=e.inArray(o,this._styles),i<0&&(i=this._styles.push(o)-1),i+1)},_lookupBorder:function(n){var i,o=t.stringify(n);if("{}"!=o)return i=e.inArray(o,this._borders),i<0&&(i=this._borders.push(o)-1),i+1},_readCells:function(e){var t,n,i,o,r;for(t=0;t<e.length;t++)for(n=e[t],i=n.cells,n.data=[],o=0;o<i.length;o++)r=this._cell(i[o],n.index,o),r&&n.data.push(r)},_cell:function(e,n,o){var r,s,a,c,d,u,h,f,p,m;return e&&e!==V?(r=e.value,s={},e.borderLeft&&(s.left=e.borderLeft),e.borderRight&&(s.right=e.borderRight),e.borderTop&&(s.top=e.borderTop),e.borderBottom&&(s.bottom=e.borderBottom),s=this._lookupBorder(s),a=this.options.defaultCellStyle||{},c={borderId:s},function(e){e("color"),e("background"),e("bold"),e("italic"),e("underline"),e("fontFamily")||e("fontName","fontFamily"),e("fontSize"),e("format"),e("textAlign")||e("hAlign","textAlign"),e("verticalAlign")||e("vAlign","verticalAlign"),e("wrap")}(function(t,n){var i=e[t];if(void 0===i&&(i=a[t]),void 0!==i)return c[n||t]=i,!0}),d=this.options.columns||[],u=d[o],h=typeof r,u&&u.autoWidth&&(f=r,"number"===h&&(f=t.toString(r,e.format)),u.width=Math.max(u.width||0,(f+"").length)),"string"===h?(r=l(r),r=this._lookupString(r),h="s"):"number"===h?h="n":"boolean"===h?(h="b",r=+r):r&&r.getTime?(h=null,p=(r.getTimezoneOffset()-P.getTimezoneOffset())*t.date.MS_PER_MINUTE,r=(r-P-p)/t.date.MS_PER_DAY+1,c.format||(c.format="mm-dd-yy")):(h=null,r=null),c=this._lookupStyle(c),m=i(n,o),e.validation&&this._addValidation(e.validation,m),{value:r,formula:e.formula,type:h,style:c,ref:m}):null},_addValidation:function(e,t){var n={showErrorMessage:"reject"==e.type?1:0,formula1:e.from,formula2:e.to,type:H[e.dataType]||e.dataType,operator:L[e.comparerType]||e.comparerType,allowBlank:e.allowNulls?1:0,showDropDown:e.showButton?0:1,error:e.messageTemplate,errorTitle:e.titleTemplate},i=JSON.stringify(n);this._validations[i]||(this._validations[i]=n,n.sqref=[]),this._validations[i].sqref.push(t)}}),L={greaterThanOrEqualTo:"greaterThanOrEqual",lessThanOrEqualTo:"lessThanOrEqual"},H={number:"decimal"},N={General:0,0:1,"0.00":2,"#,##0":3,"#,##0.00":4,"0%":9,"0.00%":10,"0.00E+00":11,"# ?/?":12,"# ??/??":13,"mm-dd-yy":14,"d-mmm-yy":15,"d-mmm":16,"mmm-yy":17,"h:mm AM/PM":18,"h:mm:ss AM/PM":19,"h:mm":20,"h:mm:ss":21,"m/d/yy h:mm":22,"#,##0 ;(#,##0)":37,"#,##0 ;[Red](#,##0)":38,"#,##0.00;(#,##0.00)":39,"#,##0.00;[Red](#,##0.00)":40,"mm:ss":45,"[h]:mm:ss":46,"mmss.0":47,"##0.0E+0":48,"@":49,"[$-404]e/m/d":27,"m/d/yy":30,t0:59,"t0.00":60,"t#,##0":61,"t#,##0.00":62,"t0%":67,"t0.00%":68,"t# ?/?":69,"t# ??/??":70},O=t.Class.extend({init:function(t){this.options=t||{},this._strings={indexes:{},count:0,uniqueCount:0},this._styles=[],this._borders=[],this._sheets=e.map(this.options.sheets||[],e.proxy(function(e){return e.defaults=this.options,new B(e,this._strings,this._styles,this._borders)},this))},toDataURL:function(){var n,i,s,a,l,d,u,h,f,p,m,g,v,_,b,w,y,k,x;if("undefined"==typeof JSZip)throw Error("JSZip not found. Check http://docs.telerik.com/kendo-ui/framework/excel/introduction#requirements for more details.");for(n=new JSZip,i=n.folder("docProps"),i.file("core.xml",T({creator:this.options.creator||"Kendo UI",lastModifiedBy:this.options.creator||"Kendo UI",created:this.options.date||(new Date).toJSON(),modified:this.options.date||(new Date).toJSON()})),s=this._sheets.length,i.file("app.xml",D({sheets:this._sheets})),a=n.folder("_rels"),a.file(".rels",S),l=n.folder("xl"),d=l.folder("_rels"),d.file("workbook.xml.rels",I({count:s})),u={},l.file("workbook.xml",E({sheets:this._sheets,filterNames:e.map(this._sheets,function(e,t){var n,i=e.options,s=i.name||i.title||"Sheet"+(t+1);if(u[s.toLowerCase()]=t,n=i.filter,n&&void 0!==n.from&&void 0!==n.to)return{localSheetId:t,name:s,from:o(r(i),n.from),to:o(r(i),n.to)}}),userNames:e.map(this.options.names||[],function(e){return{name:e.localName,localSheetId:e.sheet?u[e.sheet.toLowerCase()]:null,value:e.value,hidden:e.hidden}})})),h=l.folder("worksheets"),f=h.folder("_rels"),p=0;p<s;p++)m=this._sheets[p],g=t.format("sheet{0}.xml",p+1),v=m.relsToXML(),v&&f.file(g+".rels",v),h.file(g,m.toXML(p));return _=e.map(this._borders,e.parseJSON),b=e.map(this._styles,e.parseJSON),w=function(e){return e.underline||e.bold||e.italic||e.color||e.fontFamily||e.fontSize},y=e.map(b,function(e){if(e.color&&(e.color=c(e.color)),w(e))return e}),k=e.map(b,function(e){if(e.format&&void 0===N[e.format])return e}),x=e.map(b,function(e){if(e.background)return e.background=c(e.background),e}),l.file("styles.xml",z({fonts:y,fills:x,formats:k,borders:_,styles:e.map(b,function(t){var n={};return w(t)&&(n.fontId=e.inArray(t,y)+1),t.background&&(n.fillId=e.inArray(t,x)+2),n.textAlign=t.textAlign,n.verticalAlign=t.verticalAlign,n.wrap=t.wrap,n.borderId=t.borderId,t.format&&(n.numFmtId=void 0!==N[t.format]?N[t.format]:165+e.inArray(t,k)),n})})),l.file("sharedStrings.xml",F(this._strings)),n.file("[Content_Types].xml",A({count:s})),"data:application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;base64,"+n.generate({compression:"DEFLATE"})}}),V={},U=t.template('<autoFilter ref="${ref}"># for (var i = 0; i < columns.length; ++i) { ## var col = columns[i]; #<filterColumn colId="${col.index}">#= generators[col.filter](col) #</filterColumn># } #</autoFilter>'),W=t.template('<customFilters# if (logic == "and") {# and="1"# } #># for (var i = 0; i < criteria.length; ++i) { ## var f = criteria[i]; ## var op = kendo.ooxml.spreadsheetFilters.customOperator(f); ## var val = kendo.ooxml.spreadsheetFilters.customValue(f); #<customFilter# if (op) {# operator="${op}"#}# val="${val}"/># } #</customFilters>'),q=t.template('<dynamicFilter type="${kendo.ooxml.spreadsheetFilters.dynamicFilterType(type)}" />'),j=t.template('<top10 percent="#= /percent$/i.test(type) ? 1 : 0 #" top="#= /^top/i.test(type) ? 1 : 0 #"  val="#: value #" />'),G=t.template('<filters# if (blanks) {# blank="1"#}#># for (var i = 0; i < values.length; ++i) { #<filter val="${values[i]}" /># } #</filters>');C.customOperator=function(e){return{eq:"equal",gt:"greaterThan",gte:"greaterThanOrEqual",lt:"lessThan",lte:"lessThanOrEqual",ne:"notEqual",doesnotstartwith:"notEqual",doesnotendwith:"notEqual",doesnotcontain:"notEqual",doesnotmatch:"notEqual"}[e.operator.toLowerCase()]},C.customValue=function(e){function t(e){return e.replace(/([*?])/g,"~$1")}switch(e.operator.toLowerCase()){case"startswith":case"doesnotstartwith":return t(e.value)+"*";case"endswith":case"doesnotendwith":return"*"+t(e.value);case"contains":case"doesnotcontain":return"*"+t(e.value)+"*"}return e.value},C.dynamicFilterType=function(e){return{quarter1:"Q1",quarter2:"Q2",quarter3:"Q3",quarter4:"Q4",january:"M1",february:"M2",march:"M3",april:"M4",may:"M5",june:"M6",july:"M7",august:"M8",september:"M9",october:"M10",november:"M11",december:"M12"}[e.toLowerCase()]||e},t.ooxml={Workbook:O,Worksheet:B,toWidth:s,toHeight:a,borderTemplate:h,spreadsheetFilters:C}}(kendo.jQuery,kendo),kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.excel.min",["kendo.core.min","kendo.data.min","kendo.ooxml.min"],e)}(function(){return function(e,t){t.ExcelExporter=t.Class.extend({init:function(n){var i,o,r;n.columns=this._trimColumns(n.columns||[]),this.allColumns=e.map(this._leafColumns(n.columns||[]),this._prepareColumn),this.columns=e.grep(this.allColumns,function(e){return!e.hidden}),this.options=n,i=n.dataSource,i instanceof t.data.DataSource?(this.dataSource=new i.constructor(e.extend({},i.options,{page:n.allPages?0:i.page(),filter:i.filter(),pageSize:n.allPages?i.total():i.pageSize(),sort:i.sort(),group:i.group(),aggregate:i.aggregate()})),o=i.data(),o.length>0&&(this.dataSource._data=o,r=this.dataSource.transport,i._isServerGrouped()&&r.options&&r.options.data&&(r.options.data=null))):this.dataSource=t.data.DataSource.create(i)},_trimColumns:function(t){var n=this;return e.grep(t,function(e){var t=!!e.field;return!t&&e.columns&&(t=n._trimColumns(e.columns).length>0),t})},_leafColumns:function(e){var t,n=[];for(t=0;t<e.length;t++)e[t].columns?n=n.concat(this._leafColumns(e[t].columns)):n.push(e[t]);return n},workbook:function(){return e.Deferred(e.proxy(function(t){this.dataSource.fetch().then(e.proxy(function(){var e={sheets:[{columns:this._columns(),rows:this._rows(),freezePane:this._freezePane(),filter:this._filter()}]};t.resolve(e,this.dataSource.view())},this))},this)).promise()},_prepareColumn:function(n){var i,o;if(n.field)return i=function(e){return e.get(n.field)},o=null,n.values&&(o={},e.each(n.values,function(){o[this.value]=this.text}),i=function(e){return o[e.get(n.field)]}),e.extend({},n,{value:i,values:o,groupHeaderTemplate:t.template(n.groupHeaderTemplate||"#= title #: #= value #"),groupFooterTemplate:n.groupFooterTemplate?t.template(n.groupFooterTemplate):null,footerTemplate:n.footerTemplate?t.template(n.footerTemplate):null})},_filter:function(){if(!this.options.filterable)return null;var e=this._depth();return{from:e,to:e+this.columns.length-1}},_dataRow:function(t,n,i){var o,r,s,a,l,c,d,u,h,f;for(this._hierarchical()&&(n=this.dataSource.level(t)+1),o=[],r=0;r<n;r++)o[r]={background:"#dfdfdf",color:"#333"};if(i&&t.items)return s=e.grep(this.allColumns,function(e){return e.field==t.field})[0],a=s&&s.title?s.title:t.field,l=s?s.groupHeaderTemplate:null,c=a+": "+t.value,d=e.extend({title:a,field:t.field,value:s&&s.values?s.values[t.value]:t.value,aggregates:t.aggregates,items:t.items},t.aggregates[t.field]),l&&(c=l(d)),o.push({value:c,background:"#dfdfdf",color:"#333",colSpan:this.columns.length+i-n}),u=this._dataRows(t.items,n+1),u.unshift({type:"group-header",cells:o}),u.concat(this._footer(t));for(h=[],f=0;f<this.columns.length;f++)h[f]=this._cell(t,this.columns[f]);return this._hierarchical()&&(h[0].colSpan=i-n+1),[{type:"data",cells:o.concat(h)}]},_dataRows:function(e,t){var n,i=this._depth(),o=[];for(n=0;n<e.length;n++)o.push.apply(o,this._dataRow(e[n],t,i));return o},_footer:function(t){var n=[],i=!1,o=e.map(this.columns,e.proxy(function(n){if(n.groupFooterTemplate){var o={group:{items:t.items,field:t.field,value:t.value}};return i=!0,{background:"#dfdfdf",color:"#333",value:n.groupFooterTemplate(e.extend({},this.dataSource.aggregates(),t.aggregates,t.aggregates[n.field],o))}}return{background:"#dfdfdf",color:"#333"}},this));return i&&n.push({type:"group-footer",cells:e.map(Array(this.dataSource.group().length),function(){return{background:"#dfdfdf",color:"#333"}}).concat(o)}),n},_isColumnVisible:function(e){return this._visibleColumns([e]).length>0&&(e.field||e.columns)},_visibleColumns:function(t){var n=this;return e.grep(t,function(e){var t=!e.hidden;return t&&e.columns&&(t=n._visibleColumns(e.columns).length>0),t})},_headerRow:function(t,n){var i=e.map(t.cells,function(e){return{background:"#7a7a7a",color:"#fff",value:e.title,colSpan:e.colSpan>1?e.colSpan:1,rowSpan:t.rowSpan>1&&!e.colSpan?t.rowSpan:1}});return this._hierarchical()&&(i[0].colSpan=this._depth()+1),{type:"header",cells:e.map(Array(n.length),function(){return{background:"#7a7a7a",color:"#fff"}}).concat(i)}},_prependHeaderRows:function(e){var t,n=this.dataSource.group(),i=[{rowSpan:1,cells:[],index:0}];for(this._prepareHeaderRows(i,this.options.columns),t=i.length-1;t>=0;t--)e.unshift(this._headerRow(i[t],n))},_prepareHeaderRows:function(e,t,n,i){var o,r,s,a=i||e[e.length-1],l=e[a.index+1],c=0;for(s=0;s<t.length;s++)o=t[s],this._isColumnVisible(o)&&(r={title:o.title||o.field,colSpan:0},a.cells.push(r),o.columns&&o.columns.length&&(l||(l={
rowSpan:0,cells:[],index:e.length},e.push(l)),r.colSpan=this._trimColumns(this._visibleColumns(o.columns)).length,this._prepareHeaderRows(e,o.columns,r,l),c+=r.colSpan-1,a.rowSpan=e.length-a.index));n&&(n.colSpan+=c)},_rows:function(){var t,n,i=this.dataSource.group(),o=this._dataRows(this.dataSource.view(),0);return this.columns.length&&(this._prependHeaderRows(o),t=!1,n=e.map(this.columns,e.proxy(function(n){if(n.footerTemplate){t=!0;var i=this.dataSource.aggregates();return{background:"#dfdfdf",color:"#333",value:n.footerTemplate(e.extend({},i,i[n.field]))}}return{background:"#dfdfdf",color:"#333"}},this)),t&&o.push({type:"footer",cells:e.map(Array(i.length),function(){return{background:"#dfdfdf",color:"#333"}}).concat(n)})),o},_headerDepth:function(e){var t,n,i=1,o=0;for(t=0;t<e.length;t++)e[t].columns&&(n=this._headerDepth(e[t].columns),n>o&&(o=n));return i+o},_freezePane:function(){var t=this._visibleColumns(this.options.columns||[]),n=this._visibleColumns(this._trimColumns(this._leafColumns(e.grep(t,function(e){return e.locked})))).length;return{rowSplit:this._headerDepth(t),colSplit:n?n+this.dataSource.group().length:0}},_cell:function(e,t){return{value:t.value(e)}},_hierarchical:function(){return this.options.hierarchy&&this.dataSource.level},_depth:function(){var e,t,n,i=this.dataSource,o=0;if(this._hierarchical()){for(e=i.view(),t=0;t<e.length;t++)n=i.level(e[t]),n>o&&(o=n);o++}else o=i.group().length;return o},_columns:function(){var t=this._depth(),n=e.map(Array(t),function(){return{width:20}});return n.concat(e.map(this.columns,function(e){return{width:parseInt(e.width,10),autoWidth:!e.width}}))}}),t.ExcelMixin={extend:function(t){t.events.push("excelExport"),t.options.excel=e.extend(t.options.excel,this.options),t.saveAsExcel=this.saveAsExcel},options:{proxyURL:"",allPages:!1,filterable:!1,fileName:"Export.xlsx"},saveAsExcel:function(){var n=this.options.excel||{},i=new t.ExcelExporter({columns:this.columns,dataSource:this.dataSource,allPages:n.allPages,filterable:n.filterable,hierarchy:n.hierarchy});i.workbook().then(e.proxy(function(e,i){if(!this.trigger("excelExport",{workbook:e,data:i})){var o=new t.ooxml.Workbook(e);t.saveAs({dataURI:o.toDataURL(),fileName:e.fileName||n.fileName,proxyURL:n.proxyURL,forceProxy:n.forceProxy})}},this))}}}(kendo.jQuery,kendo),kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.data.signalr.min",["kendo.data.min"],e)}(function(){return function(e){var t=kendo.data.RemoteTransport.extend({init:function(e){var t,n=e&&e.signalr?e.signalr:{},i=n.promise;if(!i)throw Error('The "promise" option must be set.');if("function"!=typeof i.done||"function"!=typeof i.fail)throw Error('The "promise" option must be a Promise.');if(this.promise=i,t=n.hub,!t)throw Error('The "hub" option must be set.');if("function"!=typeof t.on||"function"!=typeof t.invoke)throw Error('The "hub" option is not a valid SignalR hub proxy.');this.hub=t,kendo.data.RemoteTransport.fn.init.call(this,e)},push:function(e){var t=this.options.signalr.client||{};t.create&&this.hub.on(t.create,e.pushCreate),t.update&&this.hub.on(t.update,e.pushUpdate),t.destroy&&this.hub.on(t.destroy,e.pushDestroy)},_crud:function(t,n){var i,o,r=this.hub,s=this.options.signalr.server;if(!s||!s[n])throw Error(kendo.format('The "server.{0}" option must be set.',n));i=[s[n]],o=this.parameterMap(t.data,n),e.isEmptyObject(o)||i.push(o),this.promise.done(function(){r.invoke.apply(r,i).done(t.success).fail(t.error)})},read:function(e){this._crud(e,"read")},create:function(e){this._crud(e,"create")},update:function(e){this._crud(e,"update")},destroy:function(e){this._crud(e,"destroy")}});e.extend(!0,kendo.data,{transports:{signalr:t}})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("drawing/util.min",["kendo.core.min"],e)}(function(){return function(e){function t(){return e.Deferred()}function n(t){return e.when.apply(e,t)}kendo.drawing.util=kendo.drawing.util||{},kendo.deepExtend(kendo.drawing.util,{createPromise:t,promiseAll:n})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.color.min",["kendo.core.min"],e)}(function(){function e(e,t,n){void 0===n&&(n="0");for(var i=e.toString(16);t>i.length;)i=n+i;return i}function t(e,t,n){var i=n;return i<0&&(i+=1),i>1&&(i-=1),i<1/6?e+6*(t-e)*i:i<.5?t:i<2/3?e+(t-e)*(2/3-i)*6:e}function n(e,t){var i,o,s;if(null==e||"none"===e)return null;if(e instanceof c)return e;if(s=e.toLowerCase(),i=a.exec(s))return s="transparent"===i[1]?new d(1,1,1,0):n(r[i[1]],t),s.match=[i[1]],s;if((i=/^#?([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})\b/i.exec(s))?o=new u(parseInt(i[1],16),parseInt(i[2],16),parseInt(i[3],16),1):(i=/^#?([0-9a-f])([0-9a-f])([0-9a-f])\b/i.exec(s))?o=new u(parseInt(i[1]+i[1],16),parseInt(i[2]+i[2],16),parseInt(i[3]+i[3],16),1):(i=/^rgb\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*\)/.exec(s))?o=new u(parseInt(i[1],10),parseInt(i[2],10),parseInt(i[3],10),1):(i=/^rgba\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9.]+)\s*\)/.exec(s))?o=new u(parseInt(i[1],10),parseInt(i[2],10),parseInt(i[3],10),parseFloat(i[4])):(i=/^rgb\(\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*\)/.exec(s))?o=new d(parseFloat(i[1])/100,parseFloat(i[2])/100,parseFloat(i[3])/100,1):(i=/^rgba\(\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9.]+)\s*\)/.exec(s))&&(o=new d(parseFloat(i[1])/100,parseFloat(i[2])/100,parseFloat(i[3])/100,parseFloat(i[4]))),o)o.match=i;else if(!t)throw Error("Cannot parse color: "+s);return o}var i,o,r,s,a,l,c,d,u,h,f,p;window.kendo=window.kendo||{},i=kendo.Class,o=kendo.support,r={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgrey:"a9a9a9",darkgreen:"006400",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",grey:"808080",green:"008000",greenyellow:"adff2f",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"778899",lightslategrey:"778899",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"00ff00",limegreen:"32cd32",linen:"faf0e6",magenta:"ff00ff",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",red:"ff0000",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"ffffff",whitesmoke:"f5f5f5",yellow:"ffff00",yellowgreen:"9acd32"},s=o.browser,a=["transparent"];for(l in r)r.hasOwnProperty(l)&&a.push(l);a=RegExp("^("+a.join("|")+")(\\W|$)","i"),c=i.extend({init:function(){},toHSV:function(){return this},toRGB:function(){return this},toHex:function(){return this.toBytes().toHex()},toBytes:function(){return this},toCss:function(){return"#"+this.toHex()},toCssRgba:function(){var e=this.toBytes();return"rgba("+e.r+", "+e.g+", "+e.b+", "+parseFloat((+this.a).toFixed(3))+")"},toDisplay:function(){return s.msie&&s.version<9?this.toCss():this.toCssRgba()},equals:function(e){return e===this||null!==e&&this.toCssRgba()===n(e).toCssRgba()},diff:function(e){var t,n;return null===e?NaN:(t=this.toBytes(),n=e.toBytes(),Math.sqrt(Math.pow(.3*(t.r-n.r),2)+Math.pow(.59*(t.g-n.g),2)+Math.pow(.11*(t.b-n.b),2)))},clone:function(){var e=this.toBytes();return e===this&&(e=new u(e.r,e.g,e.b,e.a)),e}}),d=c.extend({init:function(e,t,n,i){c.fn.init.call(this),this.r=e,this.g=t,this.b=n,this.a=i},toHSV:function(){var e,t,n=this,i=n.r,o=n.g,r=n.b,s=Math.min(i,o,r),a=Math.max(i,o,r),l=a-s,c=a;return 0===l?new h(0,0,c,this.a):(0!==a?(t=l/a,e=i===a?(o-r)/l:o===a?2+(r-i)/l:4+(i-o)/l,e*=60,e<0&&(e+=360)):(t=0,e=-1),new h(e,t,c,this.a))},toHSL:function(){var e,t,n,i=this,o=i.r,r=i.g,s=i.b,a=Math.max(o,r,s),l=Math.min(o,r,s),c=(a+l)/2;if(a===l)e=t=0;else{switch(n=a-l,t=c>.5?n/(2-a-l):n/(a+l),a){case o:e=(r-s)/n+(r<s?6:0);break;case r:e=(s-o)/n+2;break;case s:e=(o-r)/n+4}e*=60,t*=100,c*=100}return new f(e,t,c,this.a)},toBytes:function(){return new u(255*this.r,255*this.g,255*this.b,this.a)}}),u=d.extend({init:function(e,t,n,i){d.fn.init.call(this,Math.round(e),Math.round(t),Math.round(n),i)},toRGB:function(){return new d(this.r/255,this.g/255,this.b/255,this.a)},toHSV:function(){return this.toRGB().toHSV()},toHSL:function(){return this.toRGB().toHSL()},toHex:function(){return e(this.r,2)+e(this.g,2)+e(this.b,2)},toBytes:function(){return this}}),h=c.extend({init:function(e,t,n,i){c.fn.init.call(this),this.h=e,this.s=t,this.v=n,this.a=i},toRGB:function(){var e,t,n,i,o,r,s,a,l=this,c=l.h,u=l.s,h=l.v;if(0===u)e=t=n=h;else switch(c/=60,i=Math.floor(c),o=c-i,r=h*(1-u),s=h*(1-u*o),a=h*(1-u*(1-o)),i){case 0:e=h,t=a,n=r;break;case 1:e=s,t=h,n=r;break;case 2:e=r,t=h,n=a;break;case 3:e=r,t=s,n=h;break;case 4:e=a,t=r,n=h;break;default:e=h,t=r,n=s}return new d(e,t,n,this.a)},toHSL:function(){return this.toRGB().toHSL()},toBytes:function(){return this.toRGB().toBytes()}}),f=c.extend({init:function(e,t,n,i){c.fn.init.call(this),this.h=e,this.s=t,this.l=n,this.a=i},toRGB:function(){var e,n,i,o,r,s=this,a=s.h,l=s.s,c=s.l;return 0===l?e=n=i=c:(a/=360,l/=100,c/=100,o=c<.5?c*(1+l):c+l-c*l,r=2*c-o,e=t(r,o,a+1/3),n=t(r,o,a),i=t(r,o,a-1/3)),new d(e,n,i,this.a)},toHSV:function(){return this.toRGB().toHSV()},toBytes:function(){return this.toRGB().toBytes()}}),p=i.extend({init:function(e){var t,n,i,o,r,s,a,l=this;if(1===arguments.length)for(t=p.formats,n=this.resolveColor(e),i=0;i<t.length;i++)o=t[i].re,r=t[i].process,s=o.exec(n),s&&(a=r(s),l.r=a[0],l.g=a[1],l.b=a[2]);else this.r=arguments[0],this.g=arguments[1],this.b=arguments[2];this.r=this.normalizeByte(this.r),this.g=this.normalizeByte(this.g),this.b=this.normalizeByte(this.b)},toHex:function(){var e=this.padDigit,t=this.r.toString(16),n=this.g.toString(16),i=this.b.toString(16);return"#"+e(t)+e(n)+e(i)},resolveColor:function(e){var t=e||"black";return"#"===t.charAt(0)&&(t=t.substr(1,6)),t=t.replace(/ /g,""),t=t.toLowerCase(),t=p.namedColors[t]||t},normalizeByte:function(e){return e<0||isNaN(e)?0:e>255?255:e},padDigit:function(e){return 1===e.length?"0"+e:e},brightness:function(e){var t=Math.round;return this.r=t(this.normalizeByte(this.r*e)),this.g=t(this.normalizeByte(this.g*e)),this.b=t(this.normalizeByte(this.b*e)),this},percBrightness:function(){return Math.sqrt(.241*this.r*this.r+.691*this.g*this.g+.068*this.b*this.b)}}),p.fromBytes=function(e,t,n,i){return new u(e,t,n,null!=i?i:1)},p.fromRGB=function(e,t,n,i){return new d(e,t,n,null!=i?i:1)},p.fromHSV=function(e,t,n,i){return new h(e,t,n,null!=i?i:1)},p.fromHSL=function(e,t,n,i){return new f(e,t,n,null!=i?i:1)},p.formats=[{re:/^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,process:function(e){return[parseInt(e[1],10),parseInt(e[2],10),parseInt(e[3],10)]}},{re:/^(\w{2})(\w{2})(\w{2})$/,process:function(e){return[parseInt(e[1],16),parseInt(e[2],16),parseInt(e[3],16)]}},{re:/^(\w{1})(\w{1})(\w{1})$/,process:function(e){return[parseInt(e[1]+e[1],16),parseInt(e[2]+e[2],16),parseInt(e[3]+e[3],16)]}}],p.namedColors=r,kendo.deepExtend(kendo,{parseColor:n,Color:p})},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("util/text-metrics.min",["kendo.core.min"],e)}(function(){!function(e){function t(e){var t,n=[];for(t in e)n.push(t+e[t]);return n.sort().join("")}function n(e){var t,n=2166136261;for(t=0;t<e.length;++t)n+=(n<<1)+(n<<4)+(n<<7)+(n<<8)+(n<<24),n^=e.charCodeAt(t);return n>>>0}function i(){return{width:0,height:0,baseline:0}}function o(e,t,n){return l.current.measure(e,t,n)}var r,s,a,l;window.kendo.util=window.kendo.util||{},r=kendo.Class.extend({init:function(e){this._size=e,this._length=0,this._map={}},put:function(e,t){var n=this._map,i={key:e,value:t};n[e]=i,this._head?(this._tail.newer=i,i.older=this._tail,this._tail=i):this._head=this._tail=i,this._length>=this._size?(n[this._head.key]=null,this._head=this._head.newer,this._head.older=null):this._length++},get:function(e){var t=this._map[e];if(t)return t===this._head&&t!==this._tail&&(this._head=t.newer,this._head.older=null),t!==this._tail&&(t.older&&(t.older.newer=t.newer,t.newer.older=t.older),t.older=this._tail,t.newer=null,this._tail.newer=t,this._tail=t),t.value}}),s={baselineMarkerSize:1},"undefined"!=typeof document&&(a=document.createElement("div"),a.style.cssText="position: absolute !important; top: -4000px !important; width: auto !important; height: auto !important;padding: 0 !important; margin: 0 !important; border: 0 !important;line-height: normal !important; visibility: hidden !important; white-space: nowrap!important;"),l=kendo.Class.extend({init:function(t){this._cache=new r(1e3),this.options=e.extend({},s,t)},measure:function(e,o,r){var s,l,c,d,u,h,f,p;if(!e)return i();if(s=t(o),l=n(e+s),c=this._cache.get(l))return c;d=i(),u=r||a,h=this._baselineMarker().cloneNode(!1);for(f in o)p=o[f],void 0!==p&&(u.style[f]=p);return u.textContent=e,u.appendChild(h),document.body.appendChild(u),(e+"").length&&(d.width=u.offsetWidth-this.options.baselineMarkerSize,d.height=u.offsetHeight,d.baseline=h.offsetTop+this.options.baselineMarkerSize),d.width>0&&d.height>0&&this._cache.put(l,d),u.parentNode.removeChild(u),d},_baselineMarker:function(){var e=document.createElement("div");return e.style.cssText="display: inline-block; vertical-align: baseline;width: "+this.options.baselineMarkerSize+"px; height: "+this.options.baselineMarkerSize+"px;overflow: hidden;",e}}),l.current=new l,kendo.deepExtend(kendo.util,{LRUCache:r,TextMetrics:l,measureText:o,objectKey:t,hashKey:n})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("drawing/kendo-drawing.min",["drawing/util.min","kendo.color.min","util/text-metrics.min"],e)}(function(){!function(e){function t(e,t){return e.push.apply(e,t),e}function n(e){for(var t=[1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],n="";e>0;)e<t[0]?t.shift():(n+=Kt[t[0]],e-=t[0]);return n}function i(e){return typeof e!==Qt}function o(){return"kdef"+Xt++}function r(e){return e/Zt}function s(e){var t,n,i="";for(t=0;t<e.length;t++)n=e.charCodeAt(t),n<128?i+=nn(n):n<2048?(i+=nn(192|n>>>6),i+=nn(128|63&n)):n<65536&&(i+=nn(224|n>>>12),i+=nn(128|n>>>6&63),i+=nn(128|63&n));return i}function a(e){for(var t,n,i,o,r,a,l,c="",d=0,u=s(e);d<u.length;)t=u.charCodeAt(d++),n=u.charCodeAt(d++),i=u.charCodeAt(d++),o=t>>2,r=(3&t)<<4|n>>4,a=(15&n)<<2|i>>6,l=63&i,isNaN(n)?a=l=64:isNaN(i)&&(l=64),c=c+tn.charAt(o)+tn.charAt(r)+tn.charAt(a)+tn.charAt(l);return c}function l(e){return i((e.x||{}).location)?{x:e.x.location,y:e.y.location}:{x:e.pageX||e.clientX||0,y:e.pageY||e.clientY||0}}function c(e){return void 0===e&&(e={}),e.touch?e.touch.initialTouch:e.target}function d(e){return""===e||null===e||"none"===e||"transparent"===e||!i(e)}function u(e){if(e)return e[e.length-1]}function h(e,t,n){return Math.max(Math.min(e,n),t)}function f(e,t){function n(e,n){for(var i=[],o=0,r=0,s=0;o<e.length&&r<n.length;)t(e[o],n[r])<=0?i[s++]=e[o++]:i[s++]=n[r++];return o<e.length&&i.push.apply(i,e.slice(o)),r<n.length&&i.push.apply(i,n.slice(r)),i}return e.length<2?e.slice():function i(e){var t,o,r;return e.length<=1?e:(t=Math.floor(e.length/2),o=e.slice(0,t),r=e.slice(t),o=i(o),r=i(r),n(o,r))}(e)}function p(e){return e*Zt}function m(e){return e?Math.pow(10,e):1}function g(e,t){var n=m(t);return Math.round(e*n)/n}function v(e,t){return i(e)?e:t}function _(e,t){var n,i,o;for(n in t)for(i=n.trim().split(" "),o=0;o<i.length;o++)e.addEventListener(i[o],t[n],!1)}function b(e){var t=e.getBoundingClientRect(),n=document.documentElement;return{top:t.top+(window.pageYOffset||n.scrollTop)-(n.clientTop||0),left:t.left+(window.pageXOffset||n.scrollLeft)-(n.clientLeft||0)}}function w(e,t){var n,i,o={},r=window.getComputedStyle(e),s=Array.isArray(t)?t:[t];for(n=0;n<s.length;n++)i=s[n],o[i]=r[i];return o}function y(e){return isNaN(e)?e:e+"px"}function k(e,t){var n,o,r;return t?(n=t.width,o=t.height,i(n)&&(e.style.width=y(n)),i(o)&&(e.style.height=y(o)),void 0):(r=w(e,["width","height"]),{width:parseInt(r.width,10),height:parseInt(r.height,10)})}function x(e,t){var n,i,o;void 0===t&&(t={});for(n in t)for(i=n.trim().split(" "),o=0;o<i.length;o++)e.removeEventListener(i[o],t[n],!1)}function C(e){return function(t){return this[e]!==t&&(this[e]=t,this.geometryChange()),this}}function S(e){return function(){return this[e]}}function T(e,t){var n,i,o;for(n=0;n<t.length;n++)i=t[n],o=i.charAt(0).toUpperCase()+i.substring(1,i.length),e["set"+o]=C(i),e["get"+o]=S(i)}function D(e){return e&&"function"==typeof e.matrix?e.matrix():e}function A(e){return null===e?null:e instanceof un?e:new un(e)}function E(e,t,n,i){var o=0,r=0;return i&&(o=Math.atan2(i.c*n,i.a*t),0!==i.b&&(r=Math.atan2(i.d*n,i.b*t))),{x:o,y:r}}function M(e){var t="_"+e;return function(e){return i(e)?(this._observerField(t,e),this.geometryChange(),this):this[t]}}function I(e,t){for(var n=0;n<t.length;n++)e[t[n]]=M(t[n])}function R(e,t,n){return void 0===n&&(n=yn),0===g(Math.abs(e-t),n)}function F(e,t,n){return e<t||R(e,t,n)}function z(e,t,n,i){var o=t.x-e.x,r=i.x-n.x,s=t.y-e.y,a=i.y-n.y,l=e.x-n.x,c=e.y-n.y,d=o*a-r*s,u=(o*c-s*l)/d,h=(r*c-a*l)/d;if(u>=0&&u<=1&&h>=0&&h<=1)return new ln(e.x+h*o,e.y+h*s)}function P(e,t,n,i,o,s){var a=g((o-e)/n,3),l=g((s-t)/i,3);return g(r(Math.atan2(l,a)))}function B(e){var t,n,i,o,s,a,l,c,d,u,h,f,m,v,_,b,w,y,k,x,C,S,T,D,A,E=e.x1,M=e.y1,I=e.x2,R=e.y2,F=e.rx,z=e.ry,P=e.largeArc,B=e.swipe,L=e.rotation;return void 0===L&&(L=0),t=p(L),n=Math.cos(t),i=Math.sin(t),o=n*(E-I)/2+i*(M-R)/2,s=-i*(E-I)/2+n*(M-R)/2,a=P!==B?1:-1,l=Math.pow(o,2),c=Math.pow(s,2),d=Math.pow(F,2),u=Math.pow(z,2),h=l/d+c/u,h>1&&(h=Math.sqrt(l/d+c/u),F=h*F,d=Math.pow(F,2),z=h*z,u=Math.pow(z,2)),f=a*Math.sqrt((d*u-d*c-u*l)/(d*c+u*l)),isNaN(f)&&(f=0),m=f*(F*s)/z,v=-f*(z*o)/F,_=n*m-i*v+(E+I)/2,b=i*m+n*v+(M+R)/2,w=(o-m)/F,y=(s-v)/z,k=-(o+m)/F,x=-(s+v)/z,C=(y>=0?1:-1)*r(Math.acos(w/Math.sqrt(w*w+y*y))),S=g((w*k+y*x)/(Math.sqrt(w*w+y*y)*Math.sqrt(k*k+x*x)),10),T=(w*x-y*k>=0?1:-1)*r(Math.acos(S)),!B&&T>0&&(T-=360),B&&T<0&&(T+=360),D=C+T,A=D>=0?1:-1,D=Math.abs(D)%360*A,{center:new ln(_,b),startAngle:C,endAngle:D,radiusX:F,radiusY:z,xRotation:L}}function L(e,t){for(var n=e;n<t;)n+=90;return n}function H(e){var t="_"+e;return function(e){return i(e)?(this._observerField(t,ln.create(e)),this.geometryChange(),this):this[t]}}function N(e,t){for(var n=0;n<t.length;n++)e[t[n]]=H(t[n])}function O(e,t,n){var i=r(Math.atan2(t.y-e.y,t.x-e.x)),o=n.transformCopy(A().rotate(-i,e));return o.x<e.x}function V(e,t,n){var i=1-e;return Math.pow(i,3)*n[0][t]+3*Math.pow(i,2)*e*n[1][t]+3*Math.pow(e,2)*i*n[2][t]+Math.pow(e,3)*n[3][t]}function U(e,t){return[-e[0][t]+3*e[1][t]-3*e[2][t]+e[3][t],3*(e[0][t]-2*e[1][t]+e[2][t]),3*(-e[0][t]+e[1][t]),e[0][t]]}function W(e){return e<0?-1:1}function q(e,t,n){var i=Math.sqrt(Math.pow(t,2)-4*e*n);return[(-t+i)/(2*e),(-t-i)/(2*e)]}function j(e,t,n,i){var o,r,s,a,l,c,d,u,h,f,p,m,v;return 0===e?q(t,n,i):(o=(3*e*n-Math.pow(t,2))/(3*Math.pow(e,2)),r=(2*Math.pow(t,3)-9*e*t*n+27*Math.pow(e,2)*i)/(27*Math.pow(e,3)),s=Math.pow(o/3,3)+Math.pow(r/2,2),a=new Fn(0,1),l=-t/(3*e),s<0?(c=new Fn(-r/2,Math.sqrt(-s)).nthRoot(3),d=new Fn(-r/2,(-Math.sqrt(-s))).nthRoot(3)):(c=-r/2+Math.sqrt(s),c=new Fn(W(c)*Math.pow(Math.abs(c),1/3)),d=-r/2-Math.sqrt(s),d=new Fn(W(d)*Math.pow(Math.abs(d),1/3))),u=c.add(d),p=c.add(d).multiplyConstant(-.5),m=c.add(d.negate()).multiplyConstant(Math.sqrt(3)/2),h=p.add(a.multiply(m)),f=p.add(a.negate().multiply(m)),v=[],u.isReal()&&v.push(g(u.real+l,yn)),h.isReal()&&v.push(g(h.real+l,yn)),f.isReal()&&v.push(g(f.real+l,yn)),v)}function G(e,t,n,i,o){var r,s,a=U(e,i),l=j(a[0],a[1],a[2],a[3]-t[i]);for(s=0;s<l.length;s++)if(0<=l[s]&&l[s]<=1&&(r=V(l[s],n,e),Math.abs(r-t[n])<=o))return!0}function $(e,t,n){var i,o,r,s=U(e,"x"),a=j(s[0],s[1],s[2],s[3]-t.x),l=0;for(r=0;r<a.length;r++)i=V(a[r],"y",e),o=R(i,t.y)||i>t.y,o&&((0===a[r]||1===a[r])&&n.bottomRight().x>t.x||0<a[r]&&a[r]<1)&&l++;return l}function Y(e,t,n){var i,o,r,s,a,l;return e.x!==t.x&&(o=Math.min(e.x,t.x),r=Math.max(e.x,t.x),s=Math.min(e.y,t.y),a=Math.max(e.y,t.y),l=o<=n.x&&n.x<r,i=s===a?n.y<=s&&l:l&&(a-s)*((e.x-t.x)*(e.y-t.y)>0?n.x-o:r-n.x)/(r-o)+s-n.y>=0),i?1:0}function K(e){var t,n=e.length,i=Jt,o=en;for(t=0;t<n;t++)o=Math.max(o,e[t]),i=Math.min(i,e[t]);return{min:i,max:o}}function Q(e,t,n){var i,o,r,s;for(o=0;o<e.length;o++)r=e[o],r.visible()&&(s=t?r.bbox(n):r.rawBBox(),s&&(i=i?dn.union(i,s):s));return i}function X(e,t){var n,i,o,r;for(i=0;i<e.length;i++)o=e[i],o.visible()&&(r=o.clippedBBox(t),r&&(n=n?dn.union(n,r):r));return n}function Z(e,t,n){var i=n.transform()||A(),o=i.matrix();o.e+=e.x-t.origin.x,o.f+=e.y-t.origin.y,i.matrix(o),n.transform(i)}function J(e,t,n,i,o){var r;return r="start"===n?t.origin[i]:"end"===n?t.origin[i]+t.size[o]-e:t.origin[i]+(t.size[o]-e)/2}function ee(e,t,n,i,o){var r,s,a;for(r=0;r<e.length;r++)s=e[r].clippedBBox(),s&&(a=s.origin.clone(),a[i]=J(s.size[o],t,n||"start",i,o),Z(a,s,e[r]))}function te(e,t,n){ee(e,t,n,"x","width")}function ne(e,t,n){ee(e,t,n,"y","height")}function ie(e,t,n,i){var o,r,s,a,l;if(e.length>1)for(o=new ln,r=e[0].bbox,s=1;s<e.length;s++)a=e[s].element,l=e[s].bbox,o[t]=r.origin[t]+r.size[i],o[n]=l.origin[n],Z(o,l,a),l.origin[t]=o[t],r=l}function oe(e){var t,n,i,o=[];for(t=0;t<e.length;t++)n=e[t],i=n.clippedBBox(),i&&o.push({element:n,bbox:i});return o}function re(e){ie(oe(e),"x","y","width")}function se(e){ie(oe(e),"y","x","height")}function ae(e,t,n){var i,o,r,s,a=t.size[n],l=[],c=[],d=0,u=function(){c.push({element:i,bbox:o})};for(r=0;r<e.length;r++)i=e[r],o=i.clippedBBox(),o&&(s=o.size[n],d+s>a?c.length?(l.push(c),c=[],u(),d=s):(u(),l.push(c),c=[],d=0):(u(),d+=s));return c.length&&l.push(c),l}function le(e,t,n,i,o){var r,s,a,l,c=ae(e,t,o),d=t.origin.clone(),u=[];for(r=0;r<c.length;r++)for(s=c[r],a=s[0],d[i]=a.bbox.origin[i],Z(d,a.bbox,a.element),a.bbox.origin[n]=d[n],ie(s,n,i,o),u.push([]),l=0;l<s.length;l++)u[r].push(s[l].element);return u}function ce(e,t){return le(e,t,"x","y","width")}function de(e,t){return le(e,t,"y","x","height")}function ue(e,t){var n,i,o,r,s=e.clippedBBox();s&&(n=s.size,i=t.size,(i.width<n.width||i.height<n.height)&&(o=Math.min(i.width/n.width,i.height/n.height),r=e.transform()||A(),r.scale(o,o),e.transform(r)))}function he(e){return function(t){return i(t)?(this.options.set(e,t),this):this.options.get(e)}}function fe(e,t){for(var n=0;n<t.length;n++)e[t[n]]=he(t[n])}function pe(e){return.5-Math.cos(e*Math.PI)/2}function me(e){return e}function ge(e,t,n,i){var o=1.70158,r=0,s=i;return 0===e?n:1===e?n+i:(r||(r=.5),s<Math.abs(i)?(s=i,o=r/4):o=r/(2*Math.PI)*Math.asin(i/s),s*Math.pow(2,-10*e)*Math.sin((+e-o)*(1.1*Math.PI)/r)+i+n)}function ve(e,t,n){var i,o=t?0:1;for(i=0;i<e.length;i+=2)e.splice(i+o,0,n)}function _e(e,t){if(e&&t)return t.scaleCopy(2).translate(-e.x,-e.y)}function be(e,t,n){var i=t.clone().scale(2/3);return{controlOut:i.clone().translateWith(e.scaleCopy(oi)),controlIn:i.translateWith(n.scaleCopy(oi))}}function we(e){var t=[];return e.replace(si,function(e,n){t.push(parseFloat(n))}),t}function ye(e,t){return i(t)&&null!==t?" "+e+"='"+t+"' ":""}function ke(e){var t,n="";for(t=0;t<e.length;t++)n+=ye(e[t][0],e[t][1]);return n}function xe(e){var t,n,o="";for(t=0;t<e.length;t++)n=e[t][1],i(n)&&(o+=e[t][0]+":"+n+";");if(""!==o)return o}function Ce(e,t){return"clip"===e||"fill"===e&&(!t||"Gradient"===t.nodeType)}function Se(){var e=document.getElementsByTagName("base")[0],t=document.location.href,n=t.indexOf("#"),i="";return e&&!jt.browser.msie&&(n!==-1&&(t=t.substring(0,n)),i=t),i}function Te(e,t){var n=t?"":Se();return"url("+n+"#"+e+")"}function De(e){var t,n,i,o;try{t=e.getScreenCTM?e.getScreenCTM():null}catch(r){}t&&(n=-t.e%1,i=-t.f%1,o=e.style,0===n&&0===i||(o.left=n+"px",o.top=i+"px"))}function Ae(e){if(!e||!e.indexOf||e.indexOf("&")<0)return e;var t=Ae._element;return t.innerHTML=e,t.textContent||t.innerText}function Ee(e){var t,n,i,o=new Ii({skipBaseHref:!0}),r=e.clippedBBox(),s=e;return r&&(t=r.getOrigin(),n=new qn,n.transform(A().translate(-t.x,-t.y)),n.children.push(e),s=n),o.load([s]),i="<?xml version='1.0' ?><svg xmlns='"+mi+"' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1'>"+o.render()+"</svg>",o.destroy(),i}function Me(e,t){var n,i,o,r,s,a,l=t.segments;if(0!==l.length){for(n=l[0],i=n.anchor(),e.moveTo(i.x,i.y),o=1;o<l.length;o++)n=l[o],i=n.anchor(),r=l[o-1],s=r.controlOut(),a=n.controlIn(),s&&a?e.bezierCurveTo(s.x,s.y,a.x,a.y,i.x,i.y):e.lineTo(i.x,i.y);t.options.closed&&e.closePath()}}function Ie(e,t){return e._zIndex<t._zIndex?1:e._zIndex>t._zIndex?-1:0}function Re(e,t){var n,i,o;for(n=0;n<t.length;n++)i=t[n],o=kendo.parseColor(i.color()),o.a*=i.opacity(),e.addColorStop(i.offset(),o.toCssRgba())}function Fe(t,n){var i,o,r,s,a,l,c,d,u={width:"800px",height:"600px",cors:"Anonymous"},h=t,f=t.clippedBBox();return f&&(i=f.getOrigin(),h=new qn,h.transform(A().translate(-i.x,-i.y)),h.children.push(t),o=f.getSize(),u.width=o.width+"px",u.height=o.height+"px"),r=e.extend(u,n),s=document.createElement("div"),a=s.style,a.display="none",a.width=r.width,a.height=r.height,document.body.appendChild(s),l=new ao(s,r),l.suspendTracking(),l.draw(h),c=l.image(),d=function(){l.destroy(),document.body.removeChild(s)},c.then(d,d),c}function ze(e,t){var n=Ee(e);return t&&t.raw||(n="data:image/svg+xml;base64,"+a(n)),Gt().resolve(n)}function Pe(e){return Array.prototype.slice.call(e)}function Be(e,t){e.classList?e.classList.add(t):e.className+=" "+t}function Le(e,t){e.classList?e.classList.remove(t):e.className=e.className.split(/\s+/).reduce(function(e,n){return n!=t&&e.push(n),e},[]).join(" ")}function He(e,t){Object.keys(t).forEach(function(n){e.style[n]=t[n]})}function Ne(e,t){if(e.closest)return e.closest(t);for(;e&&!/^\[object (?:HTML)?Document\]$/.test(e+"");){if(ko(e,t))return e;e=e.parentNode}}function Oe(e){return"number"==typeof e?{x:e,y:e}:Array.isArray(e)?{x:e[0],y:e[1]}:{x:e.x,y:e.y}}function Ve(e,t){function n(e){var n=new qn,i=e.getBoundingClientRect();return gt(n,[s.x,0,0,s.y,-i.left*s.x,-i.top*s.y]),wo._clipbox=!1,wo._matrix=an.unit(),wo._stackingContext={element:e,group:n},wo._avoidLinks=t.avoidLinks===!0?"a":t.avoidLinks,Be(e,"k-pdf-export"),Nt(e,n),Le(e,"k-pdf-export"),n}function i(e){if(null!=e)return"string"==typeof e&&(e=kendo.template(e.replace(/^\s+|\s+$/g,""))),"function"==typeof e?function(t){var n,i=e(t);return i&&"string"==typeof i&&(n=document.createElement("div"),n.innerHTML=i,i=n.firstElementChild),i}:function(){return e.cloneNode(!0)}}function o(e,t,n,o,r,s,a){function l(){function t(){Xe(b,function(){e({pages:b,container:y})})}var i,o;("-"!=n||r)&&d(w),i=f(),w.parentNode.insertBefore(i,w),i.appendChild(w),v?(o=b.length,b.forEach(function(e,n){var i=v({element:e,pageNum:n+1,totalPages:b.length});i&&(e.appendChild(i),Ze(i,function(){0===--o&&t()}))})):t()}function c(e){if(a.keepTogether&&ko(e,a.keepTogether)&&e.offsetHeight<=r-k)return!0;var t=e.tagName;return!(/^h[1-6]$/i.test(t)&&e.offsetHeight>=r-k)&&(e.getAttribute("data-kendo-chart")||/^(?:img|tr|thead|th|tfoot|iframe|svg|object|canvas|input|textarea|select|video|h[1-6])/i.test(e.tagName))}function d(e){var t,i,o,s,a,l,u;for("TABLE"==e.tagName&&He(e,{tableLayout:"fixed"}),t=rt(e),i=parseFloat(st(t,"padding-bottom")),o=parseFloat(st(t,"border-bottom-width")),s=k,k+=i+o,a=!0,l=e.firstChild;l;l=l.nextSibling)if(1==l.nodeType){if(a=!1,ko(l,n)){h(l);continue}if(!r){d(l);continue}if(!/^(?:static|relative)$/.test(st(rt(l),"position")))continue;u=p(l),1==u?h(l):u&&c(l)?h(l):d(l)}else 3==l.nodeType&&r&&(m(l,a),a=!1);k=s}function u(e){var t=e.parentNode,n=t.firstChild;if(e===n)return!0;if(e===t.children[0]){if(7==n.nodeType||8==n.nodeType)return!0;if(3==n.nodeType)return!/\S/.test(n.data)}return!1}function h(e){var t,n,i,o,r,s,l;return 1==e.nodeType&&e!==w&&u(e)?h(e.parentNode):(t=Ne(e,"table"),n=t&&t.querySelector("colgroup"),a.repeatHeaders&&(i=t&&t.querySelector("thead"),o=Ne(e,".k-grid.k-widget"),o&&o.querySelector(".k-auto-scrollable")&&(r=o.querySelector(".k-grid-header"))),s=f(),l=_.createRange(),l.setStartBefore(w),l.setEndBefore(e),s.appendChild(l.extractContents()),w.parentNode.insertBefore(s,w),g(e.parentNode),t&&(t=Ne(e,"table"),a.repeatHeaders&&i&&t.insertBefore(i.cloneNode(!0),t.firstChild),n&&t.insertBefore(n.cloneNode(!0),t.firstChild)),void(a.repeatHeaders&&r&&(o=Ne(e,".k-grid.k-widget"),o.insertBefore(r.cloneNode(!0),o.firstChild))))}function f(){var e=_.createElement("KENDO-PDF-PAGE");return He(e,{display:"block",boxSizing:"content-box",width:o?o+"px":"auto",padding:s.top+"px "+s.right+"px "+s.bottom+"px "+s.left+"px",position:"relative",height:r?r+"px":"auto",overflow:r||o?"hidden":"visible",clear:"both"}),a&&a.pageClassName&&(e.className=a.pageClassName),b.push(e),e}function p(e){var t,n,i=e.getBoundingClientRect();return 0===i.width||0===i.height?0:(t=w.getBoundingClientRect().top,n=r-k,i.height>n?3:i.top-t>n?1:i.bottom-t>n?2:0)}function m(e,t){var n,i,o,r,s;/\S/.test(e.data)&&(n=e.data.length,i=_.createRange(),i.selectNodeContents(e),o=p(i),o&&(r=e,1==o?h(t?e.parentNode:e):(!function a(t,n,o){return i.setEnd(e,n),t==n||n==o?n:p(i)?a(t,t+n>>1,n):a(n,n+o>>1,o)}(0,n>>1,n),!/\S/.test(""+i)&&t?h(e.parentNode):(r=e.splitText(i.endOffset),s=f(),i.setStartBefore(w),s.appendChild(i.extractContents()),w.parentNode.insertBefore(s,w),g(r.parentNode))),m(r)))}function g(e){var t=Ne(e,"li");t&&(t.setAttribute("kendo-no-bullet","1"),g(t.parentNode))}var v=i(a.template),_=t.ownerDocument,b=[],w=a._destructive?t:xo(t),y=_.createElement("KENDO-PDF-DOCUMENT"),k=0;Pe(w.querySelectorAll("tfoot")).forEach(function(e){e.parentNode.appendChild(e)}),Pe(w.querySelectorAll("ol")).forEach(function(e){Pe(e.children).forEach(function(e,t){e.setAttribute("kendo-split-index",t)})}),He(y,{display:"block",position:"absolute",boxSizing:"content-box",left:"-10000px",top:"-10000px"}),o&&(He(y,{width:o+"px",paddingLeft:s.left+"px",paddingRight:s.right+"px"}),He(w,{overflow:"hidden"
})),t.parentNode.insertBefore(y,t),y.appendChild(w),a.beforePageBreak?setTimeout(function(){a.beforePageBreak(y,l)},15):setTimeout(l,15)}var r,s;if(t||(t={}),r=Gt(),!e)return r.reject("No element to export");if("function"!=typeof window.getComputedStyle)throw Error("window.getComputedStyle is missing.  You are using an unsupported browser, or running in IE8 compatibility mode.  Drawing HTML is supported in Chrome, Firefox, Safari and IE9+.");return kendo.pdf.defineFont(Ue(e.ownerDocument)),s=Oe(t.scale||1),Ze(e,function(){var i,a=t&&t.forcePageBreak,l=t&&t.paperSize&&"auto"!=t.paperSize,c=kendo.pdf.getPaperOptions(function(e,n){return"paperSize"==e?l?t[e]:"A4":e in t?t[e]:n}),d=l&&c.paperSize[0],u=l&&c.paperSize[1],h=t.margin&&c.margin,f=!!h;a||u?(h||(h={left:0,top:0,right:0,bottom:0}),d&&(d/=s.x),u&&(u/=s.y),h.left/=s.x,h.right/=s.x,h.top/=s.y,h.bottom/=s.y,i=new qn({pdf:{multiPage:!0,paperSize:l?c.paperSize:"auto",_ignoreMargin:f}}),o(function(e){if(t.progress){var o=!1,s=0;!function a(){if(s<e.pages.length){var l=n(e.pages[s]);i.append(l),t.progress({page:l,pageNum:++s,totalPages:e.pages.length,cancel:function(){o=!0}}),o?e.container.parentNode.removeChild(e.container):setTimeout(a)}else e.container.parentNode.removeChild(e.container),r.resolve(i)}()}else e.pages.forEach(function(e){i.append(n(e))}),e.container.parentNode.removeChild(e.container),r.resolve(i)},e,a,d?d-h.left-h.right:null,u?u-h.top-h.bottom:null,h,t)):r.resolve(n(e))}),r}function Ue(e){function t(e){if(e){var t=null;try{t=e.cssRules}catch(n){}t&&i(e,t)}}function n(e){var t,n=st(e.style,"src");return n?So(n).reduce(function(e,t){var n=To(t);return n&&e.push(n),e},[]):(t=To(e.cssText),t?[t]:[])}function i(e,i){var r,s,a,l,c,d,u;for(r=0;r<i.length;++r)switch(s=i[r],s.type){case 3:t(s.styleSheet);break;case 5:a=s.style,l=So(st(a,"font-family")),c=/^([56789]00|bold)$/i.test(st(a,"font-weight")),d="italic"==st(a,"font-style"),u=n(s),u.length>0&&o(e,l,c,d,u[0])}}function o(e,t,n,i,o){/^data:/i.test(o)||/^[^\/:]+:\/\//.test(o)||/^\//.test(o)||(o=(e.href+"").replace(/[^\/]*$/,"")+o),t.forEach(function(e){e=e.replace(/^(['"]?)(.*?)\1$/,"$2"),n&&(e+="|bold"),i&&(e+="|italic"),r[e]=o})}var r,s;for(null==e&&(e=document),r={},s=0;s<e.styleSheets.length;++s)t(e.styleSheets[s]);return r}function We(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function qe(e){return e="_counter_"+e,wo[e]}function je(e){var t=[],n=wo;for(e="_counter_"+e;n;)We(n,e)&&t.push(n[e]),n=Object.getPrototypeOf(n);return t.reverse()}function Ge(e,t){var n=wo;for(e="_counter_"+e;n&&!We(n,e);)n=Object.getPrototypeOf(n);n||(n=wo._root),n[e]=(n[e]||0)+(null==t?1:t)}function $e(e,t){e="_counter_"+e,wo[e]=null==t?0:t}function Ye(e,t,n){var i,o,r;for(i=0;i<e.length;)o=e[i++],r=parseFloat(e[i]),isNaN(r)?t(o,n):(t(o,r),++i)}function Ke(e){var t,n=st(e,"counter-reset");n&&Ye(So(n,/^\s+/),$e,0),t=st(e,"counter-increment"),t&&Ye(So(t,/^\s+/),Ge,1)}function Qe(e,t){var n=kendo.parseColor(e,!0);return n&&(n=n.toRGB(),t?n=n.toCssRgba():0===n.a&&(n=null)),n}function Xe(e,t){function n(){--i<=0&&t()}var i=0;e.forEach(function(e){var t,o,r=e.querySelectorAll("img");for(t=0;t<r.length;++t)o=r[t],o.complete||(i++,o.onload=o.onerror=n)}),i||n()}function Ze(e,t){function n(e){bo[e]||(bo[e]=!0,r.push(e))}function i(){--o<=0&&t()}var o,r=[];!function s(e){/^img$/i.test(e.tagName)&&n(e.src),Co(st(rt(e),"background-image")).forEach(function(e){"url"==e.type&&n(e.url)}),e.children&&Pe(e.children).forEach(s)}(e),o=r.length,0===o&&i(),r.forEach(function(e){var t=bo[e]=new window.Image;/^data:/i.test(e)||(t.crossOrigin="Anonymous"),t.src=e,t.complete?i():(t.onload=i,t.onerror=function(){bo[e]=null,i()})})}function Je(e){var t,n="";do t=e%26,n=String.fromCharCode(97+t)+n,e=Math.floor(e/26);while(e>0);return n}function et(e,t,n){var i,o;wo=Object.create(wo),wo[e.tagName.toLowerCase()]={element:e,style:t},i=st(t,"text-decoration"),i&&"none"!=i&&(o=st(t,"color"),i.split(/\s+/g).forEach(function(e){wo[e]||(wo[e]=o)})),ot(t)&&(wo._stackingContext={element:e,group:n})}function tt(){wo=Object.getPrototypeOf(wo)}function nt(e){if(null!=wo._clipbox){var t=e.bbox(wo._matrix);wo._clipbox=wo._clipbox?dn.intersect(wo._clipbox,t):t}}function it(){var e=wo._clipbox;return null==e||(e?0===e.width()||0===e.height():void 0)}function ot(e){function t(t){return st(e,t)}if("none"!=t("transform")||"static"!=t("position")||"auto"!=t("z-index")||t("opacity")<1)return!0}function rt(e,t){return window.getComputedStyle(e,t||null)}function st(e,t,n){var i=e.getPropertyValue(t);return null!=i&&""!==i||(vo.webkit?i=e.getPropertyValue("-webkit-"+t):vo.mozilla?i=e.getPropertyValue("-moz-"+t):vo.opera?i=e.getPropertyValue("-o-"+t):vo.msie&&(i=e.getPropertyValue("-ms-"+t))),arguments.length>2&&(null==i||""===i)?n:i}function at(e,t,n,i){e.setProperty(t,n,i),vo.webkit?e.setProperty("-webkit-"+t,n,i):vo.mozilla?e.setProperty("-moz-"+t,n,i):vo.opera?e.setProperty("-o-"+t,n,i):vo.msie&&(e.setProperty("-ms-"+t,n,i),t="ms"+t.replace(/(^|-)([a-z])/g,function(e,t,n){return t+n.toUpperCase()}),e[t]=n)}function lt(e,t){return t="border-"+t,{width:parseFloat(st(e,t+"-width")),style:st(e,t+"-style"),color:Qe(st(e,t+"-color"),!0)}}function ct(e,t){var n=e.style.cssText,i=t();return e.style.cssText=n,i}function dt(e,t){var n=st(e,"border-"+t+"-radius").split(/\s+/g).map(parseFloat);return 1==n.length&&n.push(n[0]),bt({x:n[0],y:n[1]})}function ut(e){var t=e.getBoundingClientRect();return t=ht(t,"border-*-width",e),t=ht(t,"padding-*",e)}function ht(e,t,n){var i,o,r,s,a;return"string"==typeof t?(i=rt(n),o=parseFloat(st(i,t.replace("*","top"))),r=parseFloat(st(i,t.replace("*","right"))),s=parseFloat(st(i,t.replace("*","bottom"))),a=parseFloat(st(i,t.replace("*","left")))):"number"==typeof t&&(o=r=s=a=t),{top:e.top+o,right:e.right-r,bottom:e.bottom-s,left:e.left+a,width:e.right-e.left-r-a,height:e.bottom-e.top-s-o}}function ft(e){var t,n,i=st(e,"transform");return"none"==i?null:(t=/^\s*matrix\(\s*(.*?)\s*\)\s*$/.exec(i),t?(n=st(e,"transform-origin"),t=t[1].split(/\s*,\s*/g).map(parseFloat),n=n.split(/\s+/g).map(parseFloat),{matrix:t,origin:n}):void 0)}function pt(e){return 180*e/Math.PI%360}function mt(e){var t=parseFloat(e);return/grad$/.test(e)?Math.PI*t/200:/rad$/.test(e)?t:/turn$/.test(e)?Math.PI*t*2:/deg$/.test(e)?Math.PI*t/180:void 0}function gt(e,t){return t=new an(t[0],t[1],t[2],t[3],t[4],t[5]),e.transform(t),t}function vt(e,t){e.clip(t)}function _t(e,t,n,i){for(var o=new Cn([t,n],i).curvePoints(),r=1;r<o.length;)e.curveTo(o[r++],o[r++],o[r++])}function bt(e){return(e.x<=0||e.y<=0)&&(e.x=e.y=0),e}function wt(e,t,n,i,o){var r=Math.max(0,t.x),s=Math.max(0,t.y),a=Math.max(0,n.x),l=Math.max(0,n.y),c=Math.max(0,i.x),d=Math.max(0,i.y),u=Math.max(0,o.x),h=Math.max(0,o.y),f=Math.min(e.width/(r+a),e.height/(l+d),e.width/(c+u),e.height/(h+s));return f<1&&(r*=f,s*=f,a*=f,l*=f,c*=f,d*=f,u*=f,h*=f),{tl:{x:r,y:s},tr:{x:a,y:l},br:{x:c,y:d},bl:{x:u,y:h}}}function yt(e,t,n){var i,o,r,s,a,l,c,d,u=rt(e),h=dt(u,"top-left"),f=dt(u,"top-right"),p=dt(u,"bottom-left"),m=dt(u,"bottom-right");return"padding"!=n&&"content"!=n||(i=lt(u,"top"),o=lt(u,"right"),r=lt(u,"bottom"),s=lt(u,"left"),h.x-=s.width,h.y-=i.width,f.x-=o.width,f.y-=i.width,m.x-=o.width,m.y-=r.width,p.x-=s.width,p.y-=r.width,"content"==n&&(a=parseFloat(st(u,"padding-top")),l=parseFloat(st(u,"padding-right")),c=parseFloat(st(u,"padding-bottom")),d=parseFloat(st(u,"padding-left")),h.x-=d,h.y-=a,f.x-=l,f.y-=a,m.x-=l,m.y-=c,p.x-=d,p.y-=c)),"number"==typeof n&&(h.x-=n,h.y-=n,f.x-=n,f.y-=n,m.x-=n,m.y-=n,p.x-=n,p.y-=n),kt(t,h,f,m,p)}function kt(e,t,n,i,o){var r=wt(e,t,n,i,o),s=r.tl,a=r.tr,l=r.br,c=r.bl,d=new Pn({fill:null,stroke:null});return d.moveTo(e.left,e.top+s.y),s.x&&_t(d,e.left+s.x,e.top+s.y,{startAngle:-180,endAngle:-90,radiusX:s.x,radiusY:s.y}),d.lineTo(e.right-a.x,e.top),a.x&&_t(d,e.right-a.x,e.top+a.y,{startAngle:-90,endAngle:0,radiusX:a.x,radiusY:a.y}),d.lineTo(e.right,e.bottom-l.y),l.x&&_t(d,e.right-l.x,e.bottom-l.y,{startAngle:0,endAngle:90,radiusX:l.x,radiusY:l.y}),d.lineTo(e.left+c.x,e.bottom),c.x&&_t(d,e.left+c.x,e.bottom-c.y,{startAngle:90,endAngle:180,radiusX:c.x,radiusY:c.y}),d.close()}function xt(e,t){var i=parseFloat(e)+"";switch(t){case"decimal-leading-zero":return i.length<2&&(i="0"+i),i;case"lower-roman":return n(e).toLowerCase();case"upper-roman":return n(e).toUpperCase();case"lower-latin":case"lower-alpha":return Je(e-1);case"upper-latin":case"upper-alpha":return Je(e-1).toUpperCase();default:return i}}function Ct(e,t){function n(e,t,n){return n?(n=n.replace(/^\s*(["'])(.*)\1\s*$/,"$2"),je(e).map(function(e){return xt(e,t)}).join(n)):xt(qe(e)||0,t)}var i,o=So(t,/^\s+/),r=[];return o.forEach(function(t){var o;(i=/^\s*(["'])(.*)\1\s*$/.exec(t))?r.push(i[2].replace(/\\([0-9a-f]{4})/gi,function(e,t){return String.fromCharCode(parseInt(t,16))})):(i=/^\s*counter\((.*?)\)\s*$/.exec(t))?(o=So(i[1]),r.push(n(o[0],o[1]))):(i=/^\s*counters\((.*?)\)\s*$/.exec(t))?(o=So(i[1]),r.push(n(o[0],o[2],o[1]))):r.push((i=/^\s*attr\((.*?)\)\s*$/.exec(t))?e.getAttribute(i[1])||"":t)}),r.join("")}function St(e){var t,n;if(e.cssText)return e.cssText;for(t=[],n=0;n<e.length;++n)t.push(e[n]+": "+st(e,e[n]));return t.join(";\n")}function Tt(e,t){function n(t,n){var o,r=rt(e,t);Ke(r),r.content&&"normal"!=r.content&&"none"!=r.content&&"0px"!=r.width&&(o=e.ownerDocument.createElement(_o),o.style.cssText=St(r),o.textContent=Ct(e,r.content),e.insertBefore(o,n),i.push(o))}var i,o;return e.tagName==_o?void Dt(e,t):(i=[],n(":before",e.firstChild),n(":after",null),o=e.className,e.className+=" kendo-pdf-hide-pseudo-elements",Dt(e,t),e.className=o,void i.forEach(function(t){e.removeChild(t)}))}function Dt(e,t){function i(t){var n,i,o,r,s,a;if(/^td$/i.test(e.tagName)&&(n=wo.table,n&&"collapse"==st(n.style,"border-collapse"))){if(i=lt(n.style,"left").width,o=lt(n.style,"top").width,0===i&&0===o)return t;if(r=n.element.getBoundingClientRect(),s=n.element.rows[0].cells[0],a=s.getBoundingClientRect(),a.top==r.top||a.left==r.left)return Pe(t).map(function(e){return{left:e.left+i,top:e.top+o,right:e.right+i,bottom:e.bottom+o,height:e.height,width:e.width}})}return t}function o(e,n,i,o,r,s,a,l){function c(t,n,o){var r=Math.PI/2*t/(t+i),s={x:n.x-t,y:n.y-i},a=new Pn({fill:{color:e},stroke:null}).moveTo(0,0);gt(a,o),_t(a,0,n.y,{startAngle:-90,endAngle:-pt(r),radiusX:n.x,radiusY:n.y}),s.x>0&&s.y>0?(a.lineTo(s.x*Math.cos(r),n.y-s.y*Math.sin(r)),_t(a,0,n.y,{startAngle:-pt(r),endAngle:-90,radiusX:s.x,radiusY:s.y,anticlockwise:!0})):s.x>0?a.lineTo(s.x,i).lineTo(0,i):a.lineTo(s.x,i).lineTo(s.x,0),u.append(a.close())}if(!(i<=0)){var d,u=new qn;gt(u,l),t.append(u),bt(s),bt(a),d=new Pn({fill:{color:e},stroke:null}),u.append(d),d.moveTo(s.x?Math.max(s.x,o):0,0).lineTo(n-(a.x?Math.max(a.x,r):0),0).lineTo(n-Math.max(a.x,r),i).lineTo(Math.max(s.x,o),i).close(),s.x&&c(o,s,[-1,0,0,1,s.x,0]),a.x&&c(r,a,[1,0,0,1,n-a.x,0])}}function r(n){var i,o,r=new qn;for(vt(r,kt(n,C,S,D,T)),t.append(r),"A"==e.tagName&&e.href&&!/^#?$/.test(e.getAttribute("href"))&&(wo._avoidLinks&&ko(e,wo._avoidLinks)||(r._pdfLink={url:e.href,top:n.top,right:n.right,bottom:n.bottom,left:n.left})),E&&(i=new Pn({fill:{color:E.toCssRgba()},stroke:null}),i.moveTo(n.left,n.top).lineTo(n.right,n.top).lineTo(n.right,n.bottom).lineTo(n.left,n.bottom).close(),r.append(i)),o=c.length;--o>=0;)s(r,n,c[o],d[o%d.length],u[o%u.length],h[o%h.length],f[o%f.length])}function s(t,n,i,o,r,s,a){function l(t,n,i,l,c){function d(){for(;g.origin.x>n.left;)g.origin.x-=i}function u(){for(;g.origin.y>n.top;)g.origin.y-=l}function h(){for(;g.origin.x<n.right;)c(t,g.clone()),g.origin.x+=i}var f,p,m,g,v,_=i/l,b=n;switch("content-box"==s?(b=ht(b,"border-*-width",e),b=ht(b,"padding-*",e)):"padding-box"==s&&(b=ht(b,"border-*-width",e)),/^\s*auto(\s+auto)?\s*$/.test(a)||("contain"==a?(f=Math.min(b.width/i,b.height/l),i*=f,l*=f):"cover"==a?(f=Math.max(b.width/i,b.height/l),i*=f,l*=f):(p=a.split(/\s+/g),i=/%$/.test(p[0])?b.width*parseFloat(p[0])/100:parseFloat(p[0]),l=1==p.length||"auto"==p[1]?i/_:/%$/.test(p[1])?b.height*parseFloat(p[1])/100:parseFloat(p[1]))),m=r+""){case"bottom":m="50% 100%";break;case"top":m="50% 0";break;case"left":m="0 50%";break;case"right":m="100% 50%";break;case"center":m="50% 50%"}if(m=m.split(/\s+/),1==m.length&&(m[1]="50%"),m[0]=/%$/.test(m[0])?parseFloat(m[0])/100*(b.width-i):parseFloat(m[0]),m[1]=/%$/.test(m[1])?parseFloat(m[1])/100*(b.height-l):parseFloat(m[1]),g=new dn([b.left+m[0],b.top+m[1]],[i,l]),"no-repeat"==o)c(t,g);else if("repeat-x"==o)d(),h();else if("repeat-y"==o)for(u();g.origin.y<n.bottom;)c(t,g.clone()),g.origin.y+=l;else if("repeat"==o)for(d(),u(),v=g.origin.clone();g.origin.y<n.bottom;)g.origin.x=v.x,h(),g.origin.y+=l}if(i&&"none"!=i)if("url"==i.type){if(/^url\(\"data:image\/svg/i.test(i.url))return;var c=bo[i.url];c&&c.width>0&&c.height>0&&l(t,n,c.width,c.height,function(e,t){e.append(new Un(i.url,t))})}else{if("linear"!=i.type)return;l(t,n,n.width,n.height,At(i))}}function a(){function i(n){ct(e,function(){e.style.position="relative";var i=e.ownerDocument.createElement(_o);i.style.position="absolute",i.style.boxSizing="border-box","outside"==r?(i.style.width="6em",i.style.left="-6.8em",i.style.textAlign="right"):i.style.left="0px",n(i),e.insertBefore(i,e.firstChild),Nt(i,t),e.removeChild(i)})}function o(t){var n,i=e.parentNode.children,o=e.getAttribute("kendo-split-index");if(null!=o)return t(0|o,i.length);for(n=0;n<i.length;++n)if(i[n]===e)return t(n,i.length)}var r,s=st(b,"list-style-type");if("none"!=s)switch(r=st(b,"list-style-position"),s){case"circle":case"disc":case"square":i(function(e){e.style.fontSize="60%",e.style.lineHeight="200%",e.style.paddingRight="0.5em",e.style.fontFamily="DejaVu Serif",e.innerHTML={disc:"●",circle:"◯",square:"■"}[s]});break;case"decimal":case"decimal-leading-zero":i(function(e){o(function(t){++t,"decimal-leading-zero"==s&&t<10&&(t="0"+t),e.innerHTML=t+"."})});break;case"lower-roman":case"upper-roman":i(function(e){o(function(t){t=n(t+1),"upper-roman"==s&&(t=t.toUpperCase()),e.innerHTML=t+"."})});break;case"lower-latin":case"lower-alpha":case"upper-latin":case"upper-alpha":i(function(e){o(function(t){t=Je(t),/^upper/i.test(s)&&(t=t.toUpperCase()),e.innerHTML=t+"."})})}}function l(n,i,s){function a(e){return{x:e.y,y:e.x}}var l,c,d,u,h,f,p,m;if(0!==n.width&&0!==n.height&&(r(n),l=x.width>0&&(i&&"ltr"==A||s&&"rtl"==A),c=y.width>0&&(s&&"ltr"==A||i&&"rtl"==A),0!==w.width||0!==x.width||0!==y.width||0!==k.width)){if(w.color==y.color&&w.color==k.color&&w.color==x.color&&w.width==y.width&&w.width==k.width&&w.width==x.width&&l&&c)return n=ht(n,w.width/2),d=yt(e,n,w.width/2),d.options.stroke={color:w.color,width:w.width},void t.append(d);if(0===C.x&&0===S.x&&0===D.x&&0===T.x&&w.width<2&&x.width<2&&y.width<2&&k.width<2)return w.width>0&&t.append(new Pn({stroke:{width:w.width,color:w.color}}).moveTo(n.left,n.top+w.width/2).lineTo(n.right,n.top+w.width/2)),k.width>0&&t.append(new Pn({stroke:{width:k.width,color:k.color}}).moveTo(n.left,n.bottom-k.width/2).lineTo(n.right,n.bottom-k.width/2)),l&&t.append(new Pn({stroke:{width:x.width,color:x.color}}).moveTo(n.left+x.width/2,n.top).lineTo(n.left+x.width/2,n.bottom)),void(c&&t.append(new Pn({stroke:{width:y.width,color:y.color}}).moveTo(n.right-y.width/2,n.top).lineTo(n.right-y.width/2,n.bottom)));u=wt(n,C,S,D,T),h=u.tl,f=u.tr,p=u.br,m=u.bl,o(w.color,n.width,w.width,x.width,y.width,h,f,[1,0,0,1,n.left,n.top]),o(k.color,n.width,k.width,y.width,x.width,p,m,[-1,0,0,-1,n.right,n.bottom]),o(x.color,n.height,x.width,k.width,w.width,a(m),a(h),[0,-1,1,0,n.left,n.bottom]),o(y.color,n.height,y.width,w.width,k.width,a(f),a(p),[0,1,-1,0,n.right,n.top])}}var c,d,u,h,f,p,m,g,v,_,b=rt(e),w=lt(b,"top"),y=lt(b,"right"),k=lt(b,"bottom"),x=lt(b,"left"),C=dt(b,"top-left"),S=dt(b,"top-right"),T=dt(b,"bottom-left"),D=dt(b,"bottom-right"),A=st(b,"direction"),E=st(b,"background-color");if(E=Qe(E),c=Co(st(b,"background-image")),d=So(st(b,"background-repeat")),u=So(st(b,"background-position")),h=So(st(b,"background-origin")),f=So(st(b,"background-size")),vo.msie&&vo.version<10&&(u=So(e.currentStyle.backgroundPosition)),p=ht(e.getBoundingClientRect(),"border-*-width",e),function(){var e,n,i,o,r,s,a,l=st(b,"clip"),c=/^\s*rect\((.*)\)\s*$/.exec(l);c&&(e=c[1].split(/[ ,]+/g),n="auto"==e[0]?p.top:parseFloat(e[0])+p.top,i="auto"==e[1]?p.right:parseFloat(e[1])+p.left,o="auto"==e[2]?p.bottom:parseFloat(e[2])+p.top,r="auto"==e[3]?p.left:parseFloat(e[3])+p.left,s=new qn,a=(new Pn).moveTo(r,n).lineTo(i,n).lineTo(i,o).lineTo(r,o).close(),vt(s,a),t.append(s),t=s,nt(a))}(),_=st(b,"display"),"table-row"==_)for(m=[],g=0,v=e.children;g<v.length;++g)m.push(v[g].getBoundingClientRect());else m=e.getClientRects(),1==m.length&&(m=[e.getBoundingClientRect()]);for(m=i(m),g=0;g<m.length;++g)l(m[g],0===g,g==m.length-1);return m.length>0&&"list-item"==_&&!e.getAttribute("kendo-no-bullet")&&a(m[0]),function(){function n(){var n=yt(e,p,"padding"),i=new qn;vt(i,n),t.append(i),t=i,nt(n)}Rt(e)?n():/^(hidden|auto|scroll)/.test(st(b,"overflow"))?n():/^(hidden|auto|scroll)/.test(st(b,"overflow-x"))?n():/^(hidden|auto|scroll)/.test(st(b,"overflow-y"))&&n()}(),Et(e,t)||Bt(e,t),t}function At(e){return function(t,n){var i,o,r,s,a,l,c,d,u,h,f,p,m,g=n.width(),v=n.height();switch(e.type){case"linear":switch(i=null!=e.angle?e.angle:Math.PI,e.to){case"top":i=0;break;case"left":i=-Math.PI/2;break;case"bottom":i=Math.PI;break;case"right":i=Math.PI/2;break;case"top left":case"left top":i=-Math.atan2(v,g);break;case"top right":case"right top":i=Math.atan2(v,g);break;case"bottom left":case"left bottom":i=Math.PI+Math.atan2(v,g);break;case"bottom right":case"right bottom":i=Math.PI-Math.atan2(v,g)}e.reverse&&(i-=Math.PI),i%=2*Math.PI,i<0&&(i+=2*Math.PI),o=Math.abs(g*Math.sin(i))+Math.abs(v*Math.cos(i)),r=Math.atan(g*Math.tan(i)/v),s=Math.sin(r),a=Math.cos(r),l=Math.abs(s)+Math.abs(a),c=l/2*s,d=l/2*a,i>Math.PI/2&&i<=3*Math.PI/2&&(c=-c,d=-d),u=[],h=0,f=e.stops.map(function(t,n){var i,r=t.percent;return r?r=parseFloat(r)/100:t.length?r=parseFloat(t.length)/o:0===n?r=0:n==e.stops.length-1&&(r=1),i={color:t.color.toCssRgba(),offset:r},null!=r?(h=r,u.forEach(function(e,t){var n=e.stop;n.offset=e.left+(h-e.left)*(t+1)/(u.length+1)}),u=[]):u.push({left:h,stop:i}),i}),p=[.5-c,.5+d],m=[.5+c,.5-d],t.append(Pn.fromRect(n).stroke(null).fill(new Xn({start:p,end:m,stops:f,userSpace:!1})));break;case"radial":window.console&&window.console.log&&window.console.log("Radial gradients are not yet supported in HTML renderer")}}}function Et(e,t){var n,i,o,r;if(window.kendo&&window.kendo.jQuery&&e.getAttribute(window.kendo.attr("role"))&&(n=window.kendo.widgetInstance(window.kendo.jQuery(e)),n&&(n.exportDOMVisual||n.exportVisual)))return!!(i=n.exportDOMVisual?n.exportDOMVisual():n.exportVisual())&&(o=new qn,o.children.push(i),r=e.getBoundingClientRect(),o.transform(A().translate(r.left,r.top)),t.append(o),!0)}function Mt(e,t,n){var i=ut(e),o=new dn([i.left,i.top],[i.width,i.height]),r=new Un(t,o);vt(r,yt(e,i,"content")),n.append(r)}function It(e,t){var n=rt(e),i=rt(t),o=parseFloat(st(n,"z-index")),r=parseFloat(st(i,"z-index")),s=st(n,"position"),a=st(i,"position");return isNaN(o)&&isNaN(r)?/static|absolute/.test(s)&&/static|absolute/.test(a)?0:"static"==s?-1:"static"==a?1:0:isNaN(o)?0===r?0:r>0?-1:1:isNaN(r)?0===o?0:o>0?1:-1:parseFloat(o)-parseFloat(r)}function Rt(e){return/^(?:textarea|select|input)$/i.test(e.tagName)}function Ft(e){return e.selectedOptions&&e.selectedOptions.length>0?e.selectedOptions[0]:e.options[e.selectedIndex]}function zt(e,t){var n=rt(e),i=st(n,"color"),o=e.getBoundingClientRect();"checkbox"==e.type?(t.append(Pn.fromRect(new dn([o.left+1,o.top+1],[o.width-2,o.height-2])).stroke(i,1)),e.checked&&t.append((new Pn).stroke(i,1.2).moveTo(o.left+.22*o.width,o.top+.55*o.height).lineTo(o.left+.45*o.width,o.top+.75*o.height).lineTo(o.left+.78*o.width,o.top+.22*o.width))):(t.append(new wn(new pn([(o.left+o.right)/2,(o.top+o.bottom)/2],Math.min(o.width-2,o.height-2)/2)).stroke(i,1)),e.checked&&t.append(new wn(new pn([(o.left+o.right)/2,(o.top+o.bottom)/2],Math.min(o.width-8,o.height-8)/2)).fill(i).stroke(null)))}function Pt(e,t){var n,i,o,r,s,a=e.tagName.toLowerCase();if("input"==a&&("checkbox"==e.type||"radio"==e.type))return zt(e,t);if(n=e.parentNode,i=e.ownerDocument,o=i.createElement(_o),o.style.cssText=St(rt(e)),"input"==a&&(o.style.whiteSpace="pre"),"select"!=a&&"textarea"!=a||(o.style.overflow="auto"),"select"==a)if(e.multiple)for(s=0;s<e.options.length;++s)r=i.createElement(_o),r.style.cssText=St(rt(e.options[s])),r.style.display="block",r.textContent=e.options[s].textContent,o.appendChild(r);else r=Ft(e),r&&(o.textContent=r.textContent);else o.textContent=e.value;n.insertBefore(o,e),o.scrollLeft=e.scrollLeft,o.scrollTop=e.scrollTop,e.style.display="none",Bt(o,t),e.style.display="",n.removeChild(o)}function Bt(e,t){var n,i,o,r,s,a,l;switch(wo._stackingContext.element===e&&(wo._stackingContext.group=t),e.tagName.toLowerCase()){case"img":Mt(e,e.src,t);break;case"canvas":try{Mt(e,e.toDataURL("image/png"),t)}catch(c){}break;case"textarea":case"input":case"select":Pt(e,t);break;default:for(n=[],i=[],o=[],r=e.firstChild;r;r=r.nextSibling)switch(r.nodeType){case 3:/\S/.test(r.data)&&Lt(e,r,t);break;case 1:s=rt(r),a=st(s,"float"),l=st(s,"position"),"static"!=l?o.push(r):"none"!=a?i.push(r):n.push(r)}f(n,It).forEach(function(e){Nt(e,t)}),f(i,It).forEach(function(e){Nt(e,t)}),f(o,It).forEach(function(e){Nt(e,t)})}}function Lt(e,t,n){function i(e){var t,n,i,o;if(vo.msie||vo.chrome){for(t=e.getClientRects(),n={top:1/0,right:-(1/0),bottom:-(1/0),left:1/0},i=0;i<t.length;++i)o=t[i],o.width<=1||o.bottom===x||(n.left=Math.min(o.left,n.left),n.top=Math.min(o.top,n.top),n.right=Math.max(o.right,n.right),n.bottom=Math.max(o.bottom,n.bottom));return n.width=n.right-n.left,n.height=n.bottom-n.top,n}return e.getBoundingClientRect()}function o(){var e,n,o,s,a,u,h,f=c,p=l.substr(c).search(/\S/);if(c+=p,p<0||c>=d)return!0;if(m.setStart(t,c),m.setEnd(t,c+1),e=i(m),n=!1,(v||_>1)&&(p=l.substr(c).search(/\s/),p>=0&&(m.setEnd(t,c+p),o=i(m),o.bottom==e.bottom&&(e=o,n=!0,c+=p))),!n){if(p=function g(n,o,r){m.setEnd(t,o);var s=i(m);return s.bottom!=e.bottom&&n<o?g(n,n+o>>1,o):s.right!=e.right?(e=s,o<r?g(o,o+r>>1,r):o):o}(c,Math.min(d,c+k),d),p==c)return!0;if(c=p,p=(""+m).search(/\s+$/),0===p)return!1;p>0&&(m.setEnd(t,m.startOffset+p),e=i(m))}if(vo.msie&&(e=m.getClientRects()[0]),s=""+m,/^(?:pre|pre-wrap)$/i.test(b)){if(/\t/.test(s)){for(a=0,p=f;p<m.startOffset;++p)u=l.charCodeAt(p),9==u?a+=8-a%8:10==u||13==u?a=0:a++;for(;(p=s.search("\t"))>=0;)h="        ".substr(0,8-(a+p)%8),s=s.substr(0,p)+h+s.substr(p+1)}}else s=s.replace(/\s+/g," ");n||(x=e.bottom),r(s,e)}function r(e,t){var i,o,r;vo.msie&&!isNaN(h)&&(i=Do(f),o=(t.top+t.bottom-i)/2,t={top:o,right:t.right,bottom:o+i,left:t.left,height:i,width:t.right-t.left}),r=new yo(e,new dn([t.left,t.top],[t.width,t.height]),{font:f,fill:{color:p}}),n.append(r)}function s(e){function t(t,i){var o,r;t&&(o=u/12,r=new Pn({stroke:{width:o,color:t}}),i-=o,r.moveTo(e.left,i).lineTo(e.right,i),n.append(r))}t(C,e.bottom),t(S,e.bottom-e.height/2.7),t(T,e.top)}var a,l,c,d,u,h,f,p,m,g,v,_,b,w,y,k,x,C,S,T,D;if(!it()&&(a=rt(e),!(parseFloat(st(a,"text-indent"))<-500)&&(l=t.data,c=0,d=l.search(/\S\s*$/)+1,d&&(u=st(a,"font-size"),h=st(a,"line-height"),f=[st(a,"font-style"),st(a,"font-variant"),st(a,"font-weight"),u,st(a,"font-family")].join(" "),u=parseFloat(u),h=parseFloat(h),0!==u)))){for(p=st(a,"color"),m=e.ownerDocument.createRange(),g=st(a,"text-align"),v="justify"==g,_=st(a,"column-count",1),b=st(a,"white-space"),vo.msie&&(w=a.textOverflow,"ellipsis"==w&&(y=e.style.textOverflow,e.style.textOverflow="clip")),k=e.getBoundingClientRect().width/u*5,0===k&&(k=500),x=null,C=wo.underline,S=wo["line-through"],T=wo.overline,D=C||S||T;!o(););vo.msie&&"ellipsis"==w&&(e.style.textOverflow=y),D&&(m.selectNode(t),Pe(m.getClientRects()).forEach(s))}}function Ht(e,t,n){var i,o,r,s,a,l;for("auto"!=n?(i=wo._stackingContext.group,n=parseFloat(n)):(i=t,n=0),o=i.children,r=0;r<o.length&&!(null!=o[r]._dom_zIndex&&o[r]._dom_zIndex>n);++r);return s=new qn,i.insert(r,s),s._dom_zIndex=n,i!==t&&wo._clipbox&&(a=wo._matrix.invert(),l=wo._clipbox.transformCopy(a),vt(s,Pn.fromRect(l))),s}function Nt(e,t){var n,i,o,r,s,a,l=rt(e);Ke(l),/^(style|script|link|meta|iframe|svg|col|colgroup)$/i.test(e.tagName)||null!=wo._clipbox&&(n=parseFloat(st(l,"opacity")),i=st(l,"visibility"),o=st(l,"display"),0!==n&&"hidden"!=i&&"none"!=o&&(r=ft(l),a=st(l,"z-index"),(r||n<1)&&"auto"==a&&(a=0),s=Ht(e,t,a),n<1&&s.opacity(n*s.opacity()),et(e,l,s),r?ct(e,function(){var t,n,i,o;at(e.style,"transform","none","important"),at(e.style,"transition","none","important"),"static"==st(l,"position")&&at(e.style,"position","relative","important"),t=e.getBoundingClientRect(),n=t.left+r.origin[0],i=t.top+r.origin[1],o=[1,0,0,1,-n,-i],o=Ot(o,r.matrix),o=Ot(o,[1,0,0,1,n,i]),o=gt(s,o),wo._matrix=wo._matrix.multiplyCopy(o),Tt(e,s)}):Tt(e,s),tt()))}function Ot(e,t){var n=e[0],i=e[1],o=e[2],r=e[3],s=e[4],a=e[5],l=t[0],c=t[1],d=t[2],u=t[3],h=t[4],f=t[5];return[n*l+i*d,n*c+i*u,o*l+r*d,o*c+r*u,s*l+a*d+h,s*c+a*u+f]}var Vt,Ut,Wt,qt,jt,Gt,$t,Yt,Kt,Qt,Xt,Zt,Jt,en,tn,nn,on,rn,sn,an,ln,cn,dn,un,hn,fn,pn,mn,gn,vn,_n,bn,wn,yn,kn,xn,Cn,Sn,Tn,Dn,An,En,Mn,In,Rn,Fn,zn,Pn,Bn,Ln,Hn,Nn,On,Vn,Un,Wn,qn,jn,Gn,$n,Yn,Kn,Qn,Xn,Zn,Jn,ei,ti,ni,ii,oi,ri,si,ai,li,ci,di,ui,hi,fi,pi,mi,gi,vi,_i,bi,wi,yi,ki,xi,Ci,Si,Ti,Di,Ai,Ei,Mi,Ii,Ri,Fi,zi,Pi,Bi,Li,Hi,Ni,Oi,Vi,Ui,Wi,qi,ji,Gi,$i,Yi,Ki,Qi,Xi,Zi,Ji,eo,to,no,io,oo,ro,so,ao,lo,co,uo,ho,fo,po,mo,go,vo,_o,bo,wo,yo,ko,xo,Co,So,To,Do,Ao;window.kendo=window.kendo||{},Vt=kendo.drawing,Ut=Vt.util,Wt=kendo.Class,qt=kendo.util,jt=kendo.support,Gt=Ut.createPromise,$t=Ut.promiseAll,Yt={extend:function(e){var t,n=this;for(t in this)"extend"!==t&&(e[t]=n[t])},observers:function(){return this._observers=this._observers||[]},addObserver:function(e){return this._observers?this._observers.push(e):this._observers=[e],this},removeObserver:function(e){var t=this.observers(),n=t.indexOf(e);return n!==-1&&t.splice(n,1),this},trigger:function(e,t){var n,i,o=this._observers;if(o&&!this._suspended)for(n=0;n<o.length;n++)i=o[n],i[e]&&i[e](t);return this},optionsChange:function(e){void 0===e&&(e={}),e.element=this,this.trigger("optionsChange",e)},geometryChange:function(){this.trigger("geometryChange",{element:this})},suspend:function(){return this._suspended=(this._suspended||0)+1,this},resume:function(){return this._suspended=Math.max((this._suspended||0)-1,0),this},_observerField:function(e,t){this[e]&&this[e].removeObserver(this),this[e]=t,t.addObserver(this)}},Kt={1:"i",10:"x",100:"c",2:"ii",20:"xx",200:"cc",3:"iii",30:"xxx",300:"ccc",4:"iv",40:"xl",400:"cd",5:"v",50:"l",500:"d",6:"vi",60:"lx",600:"dc",7:"vii",70:"lxx",700:"dcc",8:"viii",80:"lxxx",800:"dccc",9:"ix",90:"xc",900:"cm",1e3:"m"},Qt="undefined",Xt=1,Zt=Math.PI/180,Jt=Number.MAX_VALUE,en=-Number.MAX_VALUE,tn="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",nn=String.fromCharCode,on={append:t,arabicToRoman:n,createPromise:Gt,defined:i,definitionId:o,deg:r,encodeBase64:a,eventCoordinates:l,eventElement:c,isTransparent:d,last:u,limitValue:h,mergeSort:f,promiseAll:$t,rad:p,round:g,valueOrDefault:v,bindEvents:_,elementOffset:b,elementSize:k,elementStyles:w,unbindEvents:x,DEG_TO_RAD:Zt,MAX_NUM:Jt,MIN_NUM:en},rn={}.toString,sn=Wt.extend({init:function(e,t){var n,i,o=this;void 0===t&&(t=""),this.prefix=t;for(n in e)i=e[n],i=o._wrap(i,n),o[n]=i},get:function(e){for(var t,n=e.split("."),i=this;n.length&&i;)t=n.shift(),i=i[t];return i},set:function(e,t){var n=this.get(e);n!==t&&(this._set(e,this._wrap(t,e)),this.optionsChange({field:this.prefix+e,value:t}))},_set:function(e,t){var n,i,o,r=this,s=e.indexOf(".")>=0,a=this,l=e;if(s){for(n=l.split("."),i=this.prefix;n.length>1;)l=n.shift(),i+=l+".",o=a[l],o||(o=new sn({},i),o.addObserver(r),a[l]=o),a=o;l=n[0]}a._clear(l),a[l]=t},_clear:function(e){var t=this[e];t&&t.removeObserver&&t.removeObserver(this)},_wrap:function(e,t){var n=rn.call(e),o=e;return null!==o&&i(o)&&"[object Object]"===n&&(e instanceof sn||e instanceof Wt||(o=new sn(o,this.prefix+t+".")),o.addObserver(this)),o}}),Yt.extend(sn.prototype),an=Wt.extend({init:function(e,t,n,i,o,r){void 0===e&&(e=0),void 0===t&&(t=0),void 0===n&&(n=0),void 0===i&&(i=0),void 0===o&&(o=0),void 0===r&&(r=0),this.a=e,this.b=t,this.c=n,this.d=i,this.e=o,this.f=r},multiplyCopy:function(e){return new an(this.a*e.a+this.c*e.b,this.b*e.a+this.d*e.b,this.a*e.c+this.c*e.d,this.b*e.c+this.d*e.d,this.a*e.e+this.c*e.f+this.e,this.b*e.e+this.d*e.f+this.f)},invert:function(){var e=this,t=e.a,n=e.b,i=e.c,o=e.d,r=e.e,s=e.f,a=t*o-n*i;return 0===a?null:new an(o/a,-n/a,-i/a,t/a,(i*s-o*r)/a,(n*r-t*s)/a)},clone:function(){return new an(this.a,this.b,this.c,this.d,this.e,this.f)},equals:function(e){return!!e&&(this.a===e.a&&this.b===e.b&&this.c===e.c&&this.d===e.d&&this.e===e.e&&this.f===e.f)},round:function(e){return this.a=g(this.a,e),this.b=g(this.b,e),this.c=g(this.c,e),this.d=g(this.d,e),this.e=g(this.e,e),this.f=g(this.f,e),this},toArray:function(e){var t,n=[this.a,this.b,this.c,this.d,this.e,this.f];if(i(e))for(t=0;t<n.length;t++)n[t]=g(n[t],e);return n},toString:function(e,t){return void 0===t&&(t=","),this.toArray(e).join(t)}}),an.translate=function(e,t){return new an(1,0,0,1,e,t)},an.unit=function(){return new an(1,0,0,1,0,0)},an.rotate=function(e,t,n){var i=new an;return i.a=Math.cos(p(e)),i.b=Math.sin(p(e)),i.c=-i.b,i.d=i.a,i.e=t-t*i.a+n*i.b||0,i.f=n-n*i.a-t*i.b||0,i},an.scale=function(e,t){return new an(e,0,0,t,0,0)},an.IDENTITY=an.unit(),ln=Wt.extend({init:function(e,t){this.x=e||0,this.y=t||0},equals:function(e){return e&&e.x===this.x&&e.y===this.y},clone:function(){return new ln(this.x,this.y)},rotate:function(e,t){var n=ln.create(t)||ln.ZERO;return this.transform(an.rotate(e,n.x,n.y))},translate:function(e,t){return this.x+=e,this.y+=t,this.geometryChange(),this},translateWith:function(e){return this.translate(e.x,e.y)},move:function(e,t){return this.x=this.y=0,this.translate(e,t)},scale:function(e,t){return void 0===t&&(t=e),this.x*=e,this.y*=t,this.geometryChange(),this},scaleCopy:function(e,t){return this.clone().scale(e,t)},transform:function(e){var t=D(e),n=this,i=n.x,o=n.y;return this.x=t.a*i+t.c*o+t.e,this.y=t.b*i+t.d*o+t.f,this.geometryChange(),this},transformCopy:function(e){var t=this.clone();return e&&t.transform(e),t},distanceTo:function(e){var t=this.x-e.x,n=this.y-e.y;return Math.sqrt(t*t+n*n)},round:function(e){return this.x=g(this.x,e),this.y=g(this.y,e),this.geometryChange(),this},toArray:function(e){var t=i(e),n=t?g(this.x,e):this.x,o=t?g(this.y,e):this.y;return[n,o]},toString:function(e,t){var n,o,r;return void 0===t&&(t=" "),n=this,o=n.x,r=n.y,i(e)&&(o=g(o,e),r=g(r,e)),o+t+r}}),ln.create=function(e,t){if(i(e))return e instanceof ln?e:1===arguments.length&&2===e.length?new ln(e[0],e[1]):new ln(e,t)},ln.min=function(){var e,t,n=arguments,i=Jt,o=Jt;for(e=0;e<arguments.length;e++)t=n[e],i=Math.min(t.x,i),o=Math.min(t.y,o);return new ln(i,o)},ln.max=function(){var e,t,n=arguments,i=en,o=en;for(e=0;e<arguments.length;e++)t=n[e],i=Math.max(t.x,i),o=Math.max(t.y,o);return new ln(i,o)},ln.minPoint=function(){return new ln(en,en)},ln.maxPoint=function(){return new ln(Jt,Jt)},Object.defineProperties&&Object.defineProperties(ln,{ZERO:{get:function(){return new ln(0,0)}}}),T(ln.prototype,["x","y"]),Yt.extend(ln.prototype),cn=Wt.extend({init:function(e,t){this.width=e||0,this.height=t||0},equals:function(e){return e&&e.width===this.width&&e.height===this.height},clone:function(){return new cn(this.width,this.height)},toArray:function(e){var t=i(e),n=t?g(this.width,e):this.width,o=t?g(this.height,e):this.height;return[n,o]}}),cn.create=function(e,t){if(i(e))return e instanceof cn?e:1===arguments.length&&2===e.length?new cn(e[0],e[1]):new cn(e,t)},Object.defineProperties&&Object.defineProperties(cn,{ZERO:{get:function(){return new cn(0,0)}}}),T(cn.prototype,["width","height"]),Yt.extend(cn.prototype),
dn=Wt.extend({init:function(e,t){void 0===e&&(e=new ln),void 0===t&&(t=new cn),this.setOrigin(e),this.setSize(t)},clone:function(){return new dn(this.origin.clone(),this.size.clone())},equals:function(e){return e&&e.origin.equals(this.origin)&&e.size.equals(this.size)},setOrigin:function(e){return this._observerField("origin",ln.create(e)),this.geometryChange(),this},getOrigin:function(){return this.origin},setSize:function(e){return this._observerField("size",cn.create(e)),this.geometryChange(),this},getSize:function(){return this.size},width:function(){return this.size.width},height:function(){return this.size.height},topLeft:function(){return this.origin.clone()},bottomRight:function(){return this.origin.clone().translate(this.width(),this.height())},topRight:function(){return this.origin.clone().translate(this.width(),0)},bottomLeft:function(){return this.origin.clone().translate(0,this.height())},center:function(){return this.origin.clone().translate(this.width()/2,this.height()/2)},bbox:function(e){var t=this.topLeft().transformCopy(e),n=this.topRight().transformCopy(e),i=this.bottomRight().transformCopy(e),o=this.bottomLeft().transformCopy(e);return dn.fromPoints(t,n,i,o)},transformCopy:function(e){return dn.fromPoints(this.topLeft().transform(e),this.bottomRight().transform(e))},expand:function(e,t){return void 0===t&&(t=e),this.size.width+=2*e,this.size.height+=2*t,this.origin.translate(-e,-t),this},expandCopy:function(e,t){return this.clone().expand(e,t)},containsPoint:function(e){var t=this.origin,n=this.bottomRight();return!(e.x<t.x||e.y<t.y||n.x<e.x||n.y<e.y)},_isOnPath:function(e,t){var n=this.expandCopy(t,t),i=this.expandCopy(-t,-t);return n.containsPoint(e)&&!i.containsPoint(e)}}),dn.fromPoints=function(){var e=ln.min.apply(null,arguments),t=ln.max.apply(null,arguments),n=new cn(t.x-e.x,t.y-e.y);return new dn(e,n)},dn.union=function(e,t){return dn.fromPoints(ln.min(e.topLeft(),t.topLeft()),ln.max(e.bottomRight(),t.bottomRight()))},dn.intersect=function(e,t){var n={left:e.topLeft().x,top:e.topLeft().y,right:e.bottomRight().x,bottom:e.bottomRight().y},i={left:t.topLeft().x,top:t.topLeft().y,right:t.bottomRight().x,bottom:t.bottomRight().y};if(n.left<=i.right&&i.left<=n.right&&n.top<=i.bottom&&i.top<=n.bottom)return dn.fromPoints(new ln(Math.max(n.left,i.left),Math.max(n.top,i.top)),new ln(Math.min(n.right,i.right),Math.min(n.bottom,i.bottom)))},Yt.extend(dn.prototype),un=Wt.extend({init:function(e){void 0===e&&(e=an.unit()),this._matrix=e},clone:function(){return new un(this._matrix.clone())},equals:function(e){return e&&e._matrix.equals(this._matrix)},translate:function(e,t){return this._matrix=this._matrix.multiplyCopy(an.translate(e,t)),this._optionsChange(),this},scale:function(e,t,n){void 0===t&&(t=e),void 0===n&&(n=null);var i=n;return i&&(i=ln.create(i),this._matrix=this._matrix.multiplyCopy(an.translate(i.x,i.y))),this._matrix=this._matrix.multiplyCopy(an.scale(e,t)),i&&(this._matrix=this._matrix.multiplyCopy(an.translate(-i.x,-i.y))),this._optionsChange(),this},rotate:function(e,t){var n=ln.create(t)||ln.ZERO;return this._matrix=this._matrix.multiplyCopy(an.rotate(e,n.x,n.y)),this._optionsChange(),this},multiply:function(e){var t=D(e);return this._matrix=this._matrix.multiplyCopy(t),this._optionsChange(),this},matrix:function(e){return e?(this._matrix=e,this._optionsChange(),this):this._matrix},_optionsChange:function(){this.optionsChange({field:"transform",value:this})}}),Yt.extend(un.prototype),hn=Wt.extend({init:function(e){this._initOptions(e)},_initOptions:function(e){var t,n;void 0===e&&(e={}),t=e.clip,n=e.transform,n&&(e.transform=A(n)),t&&!t.id&&(t.id=o()),this.options=new sn(e),this.options.addObserver(this)},transform:function(e){return i(e)?void this.options.set("transform",A(e)):this.options.get("transform")},parentTransform:function(){for(var e,t,n=this;n.parent;)n=n.parent,t=n.transform(),t&&(e=t.matrix().multiplyCopy(e||an.unit()));if(e)return A(e)},currentTransform:function(e){var t,n,i,o;if(void 0===e&&(e=this.parentTransform()),t=this.transform(),n=D(t),i=D(e),o=n&&i?i.multiplyCopy(n):n||i)return A(o)},visible:function(e){return i(e)?(this.options.set("visible",e),this):this.options.get("visible")!==!1},clip:function(e){var t=this.options;return i(e)?(e&&!e.id&&(e.id=o()),t.set("clip",e),this):t.get("clip")},opacity:function(e){return i(e)?(this.options.set("opacity",e),this):v(this.options.get("opacity"),1)},clippedBBox:function(e){var t,n=this._clippedBBox(e);if(n)return t=this.clip(),t?dn.intersect(n,t.bbox(e)):n},containsPoint:function(e,t){var n,i;return!!this.visible()&&(n=this.currentTransform(t),i=e,n&&(i=e.transformCopy(n.matrix().invert())),this._hasFill()&&this._containsPoint(i)||this._isOnPath&&this._hasStroke()&&this._isOnPath(i))},_hasFill:function(){var e=this.options.fill;return e&&!d(e.color)},_hasStroke:function(){var e=this.options.stroke;return e&&e.width>0&&!d(e.color)},_clippedBBox:function(e){return this.bbox(e)}}),hn.prototype.nodeType="Element",Yt.extend(hn.prototype),fn=Math.PI/2,pn=Wt.extend({init:function(e,t){void 0===e&&(e=new ln),void 0===t&&(t=0),this.setCenter(e),this.setRadius(t)},setCenter:function(e){return this._observerField("center",ln.create(e)),this.geometryChange(),this},getCenter:function(){return this.center},equals:function(e){return e&&e.center.equals(this.center)&&e.radius===this.radius},clone:function(){return new pn(this.center.clone(),this.radius)},pointAt:function(e){return this._pointAt(p(e))},bbox:function(e){var t,n,i,o,r=this,s=E(this.center,this.radius,this.radius,e),a=ln.maxPoint(),l=ln.minPoint();for(t=0;t<4;t++)n=r._pointAt(s.x+t*fn).transformCopy(e),i=r._pointAt(s.y+t*fn).transformCopy(e),o=new ln(n.x,i.y),a=ln.min(a,o),l=ln.max(l,o);return dn.fromPoints(a,l)},_pointAt:function(e){var t=this,n=t.center,i=t.radius;return new ln(n.x+i*Math.cos(e),n.y+i*Math.sin(e))},containsPoint:function(e){var t=this,n=t.center,i=t.radius,o=Math.pow(e.x-n.x,2)+Math.pow(e.y-n.y,2)<=Math.pow(i,2);return o},_isOnPath:function(e,t){var n=this,i=n.center,o=n.radius,r=i.distanceTo(e);return o-t<=r&&r<=o+t}}),T(pn.prototype,["radius"]),Yt.extend(pn.prototype),mn="Gradient",gn={extend:function(e){e.fill=this.fill,e.stroke=this.stroke},fill:function(e,t){var n,o=this.options;return i(e)?(e&&e.nodeType!==mn?(n={color:e},i(t)&&(n.opacity=t),o.set("fill",n)):o.set("fill",e),this):o.get("fill")},stroke:function(e,t,n){return i(e)?(this.options.set("stroke.color",e),i(t)&&this.options.set("stroke.width",t),i(n)&&this.options.set("stroke.opacity",n),this):this.options.get("stroke")}},vn=""+an.IDENTITY,_n={extend:function(e){e.bbox=this.bbox,e.geometryChange=this.geometryChange},bbox:function(e){var t,n,i=D(this.currentTransform(e)),o=i?""+i:vn;return this._bboxCache&&this._matrixHash===o?t=this._bboxCache.clone():(t=this._bbox(i),this._bboxCache=t?t.clone():null,this._matrixHash=o),n=this.options.get("stroke.width"),n&&t&&t.expand(n/2),t},geometryChange:function(){delete this._bboxCache,this.trigger("geometryChange",{element:this})}},bn="#000",wn=hn.extend({init:function(e,t){void 0===e&&(e=new pn),void 0===t&&(t={}),hn.fn.init.call(this,t),this.geometry(e),i(this.options.stroke)||this.stroke(bn)},rawBBox:function(){return this._geometry.bbox()},_bbox:function(e){return this._geometry.bbox(e)},_containsPoint:function(e){return this.geometry().containsPoint(e)},_isOnPath:function(e){return this.geometry()._isOnPath(e,this.options.stroke.width/2)}}),wn.prototype.nodeType="Circle",gn.extend(wn.prototype),_n.extend(wn.prototype),I(wn.prototype,["geometry"]),yn=10,kn=45,xn=Math.pow,Cn=Wt.extend({init:function(e,t){void 0===e&&(e=new ln),void 0===t&&(t={}),this.setCenter(e),this.radiusX=t.radiusX,this.radiusY=t.radiusY||t.radiusX,this.startAngle=t.startAngle,this.endAngle=t.endAngle,this.anticlockwise=t.anticlockwise||!1,this.xRotation=t.xRotation},clone:function(){return new Cn(this.center,{radiusX:this.radiusX,radiusY:this.radiusY,startAngle:this.startAngle,endAngle:this.endAngle,anticlockwise:this.anticlockwise})},setCenter:function(e){return this._observerField("center",ln.create(e)),this.geometryChange(),this},getCenter:function(){return this.center},pointAt:function(e){var t=this.center,n=p(e);return new ln(t.x+this.radiusX*Math.cos(n),t.y+this.radiusY*Math.sin(n))},curvePoints:function(){var e,t,n,i,o=this,r=this.startAngle,s=this.anticlockwise?-1:1,a=[this.pointAt(r)],l=this._arcInterval(),c=l.endAngle-l.startAngle,d=Math.ceil(c/kn),u=c/d,h=r;for(this.xRotation&&(e=A().rotate(this.xRotation,this.center)),t=1;t<=d;t++)n=h+s*u,i=o._intervalCurvePoints(h,n,e),a.push(i.cp1,i.cp2,i.p2),h=n;return a},bbox:function(e){for(var t,n,i=this,o=this._arcInterval(),s=o.startAngle,a=o.endAngle,l=E(this.center,this.radiusX,this.radiusY,e),c=r(l.x),d=r(l.y),u=this.pointAt(a).transformCopy(e),h=L(c,s),f=L(d,s),p=this.pointAt(s).transformCopy(e),m=ln.min(p,u),g=ln.max(p,u);h<a||f<a;)t=void 0,h<a&&(t=i.pointAt(h).transformCopy(e),h+=90),n=void 0,f<a&&(n=i.pointAt(f).transformCopy(e),f+=90),p=new ln(t.x,n.y),m=ln.min(m,p),g=ln.max(g,p);return dn.fromPoints(m,g)},_arcInterval:function(){var e,t=this,n=t.startAngle,i=t.endAngle,o=t.anticlockwise;return o&&(e=n,n=i,i=e),(n>i||o&&n===i)&&(i+=360),{startAngle:n,endAngle:i}},_intervalCurvePoints:function(e,t,n){var i=this.pointAt(e),o=this.pointAt(t),r=this._derivativeAt(e),s=this._derivativeAt(t),a=(p(t)-p(e))/3,l=new ln(i.x+a*r.x,i.y+a*r.y),c=new ln(o.x-a*s.x,o.y-a*s.y);return n&&(i.transform(n),o.transform(n),l.transform(n),c.transform(n)),{p1:i,cp1:l,cp2:c,p2:o}},_derivativeAt:function(e){var t=p(e);return new ln(-this.radiusX*Math.sin(t),this.radiusY*Math.cos(t))},containsPoint:function(e){var t,n,i,o=this._arcInterval(),r=o.endAngle-o.startAngle,s=this,a=s.center,l=s.radiusX,c=s.radiusY,d=a.distanceTo(e),u=Math.atan2(e.y-a.y,e.x-a.x),h=l*c/Math.sqrt(xn(l,2)*xn(Math.sin(u),2)+xn(c,2)*xn(Math.cos(u),2)),f=this.pointAt(this.startAngle).round(yn),p=this.pointAt(this.endAngle).round(yn),m=z(a,e.round(yn),f,p);return r<180?t=m&&F(a.distanceTo(m),d)&&F(d,h):(n=P(a.x,a.y,l,c,e.x,e.y),360!==n&&(n=(360+n)%360),i=o.startAngle<=n&&n<=o.endAngle,t=i&&F(d,h)||!i&&(!m||m.equals(e))),t},_isOnPath:function(e,t){var n,i=this._arcInterval(),o=this.center,r=P(o.x,o.y,this.radiusX,this.radiusY,e.x,e.y);return 360!==r&&(r=(360+r)%360),n=i.startAngle<=r&&r<=i.endAngle,n&&this.pointAt(r).distanceTo(e)<=t}}),Cn.fromPoints=function(e,t,n,i,o,r,s){var a=B({x1:e.x,y1:e.y,x2:t.x,y2:t.y,rx:n,ry:i,largeArc:o,swipe:r,rotation:s});return new Cn(a.center,{startAngle:a.startAngle,endAngle:a.endAngle,radiusX:a.radiusX,radiusY:a.radiusY,xRotation:a.xRotation,anticlockwise:0===r})},T(Cn.prototype,["radiusX","radiusY","startAngle","endAngle","anticlockwise"]),Yt.extend(Cn.prototype),Sn=[].push,Tn=[].pop,Dn=[].splice,An=[].shift,En=[].slice,Mn=[].unshift,In=Wt.extend({init:function(e){void 0===e&&(e=[]),this.length=0,this._splice(0,e.length,e)},elements:function(e){return e?(this._splice(0,this.length,e),this._change(),this):this.slice(0)},push:function(){var e=arguments,t=Sn.apply(this,e);return this._add(e),t},slice:function(){return En.call(this)},pop:function(){var e=this.length,t=Tn.apply(this);return e&&this._remove([t]),t},splice:function(e,t){var n=En.call(arguments,2),i=this._splice(e,t,n);return this._change(),i},shift:function(){var e=this.length,t=An.apply(this);return e&&this._remove([t]),t},unshift:function(){var e=arguments,t=Mn.apply(this,e);return this._add(e),t},indexOf:function(e){var t,n=this,i=this.length;for(t=0;t<i;t++)if(n[t]===e)return t;return-1},_splice:function(e,t,n){var i=Dn.apply(this,[e,t].concat(n));return this._clearObserver(i),this._setObserver(n),i},_add:function(e){this._setObserver(e),this._change()},_remove:function(e){this._clearObserver(e),this._change()},_setObserver:function(e){var t,n=this;for(t=0;t<e.length;t++)e[t].addObserver(n)},_clearObserver:function(e){var t,n=this;for(t=0;t<e.length;t++)e[t].removeObserver(n)},_change:function(){}}),Yt.extend(In.prototype),Rn=In.extend({_change:function(){this.geometryChange()}}),Fn=Wt.extend({init:function(e,t){void 0===e&&(e=0),void 0===t&&(t=0),this.real=e,this.img=t},add:function(e){return new Fn(g(this.real+e.real,yn),g(this.img+e.img,yn))},addConstant:function(e){return new Fn(this.real+e,this.img)},negate:function(){return new Fn((-this.real),(-this.img))},multiply:function(e){return new Fn(this.real*e.real-this.img*e.img,this.real*e.img+this.img*e.real)},multiplyConstant:function(e){return new Fn(this.real*e,this.img*e)},nthRoot:function(e){var t=Math.atan2(this.img,this.real),n=Math.sqrt(Math.pow(this.img,2)+Math.pow(this.real,2)),i=Math.pow(n,1/e);return new Fn(i*Math.cos(t/e),i*Math.sin(t/e))},equals:function(e){return this.real===e.real&&this.img===e.img},isReal:function(){return 0===this.img}}),zn=Wt.extend({init:function(e,t,n){this.anchor(e||new ln),this.controlIn(t),this.controlOut(n)},bboxTo:function(e,t){var n,i=this.anchor().transformCopy(t),o=e.anchor().transformCopy(t);return n=this.controlOut()&&e.controlIn()?this._curveBoundingBox(i,this.controlOut().transformCopy(t),e.controlIn().transformCopy(t),o):this._lineBoundingBox(i,o)},_lineBoundingBox:function(e,t){return dn.fromPoints(e,t)},_curveBoundingBox:function(e,t,n,i){var o=[e,t,n,i],r=this._curveExtremesFor(o,"x"),s=this._curveExtremesFor(o,"y"),a=K([r.min,r.max,e.x,i.x]),l=K([s.min,s.max,e.y,i.y]);return dn.fromPoints(new ln(a.min,l.min),new ln(a.max,l.max))},_curveExtremesFor:function(e,t){var n=this._curveExtremes(e[0][t],e[1][t],e[2][t],e[3][t]);return{min:V(n.min,t,e),max:V(n.max,t,e)}},_curveExtremes:function(e,t,n,i){var o,r,s=e-3*t+3*n-i,a=-2*(e-2*t+n),l=e-t,c=Math.sqrt(a*a-4*s*l),d=0,u=1;return 0===s?0!==a&&(d=u=-l/a):isNaN(c)||(d=(-a+c)/(2*s),u=(-a-c)/(2*s)),o=Math.max(Math.min(d,u),0),(o<0||o>1)&&(o=0),r=Math.min(Math.max(d,u),1),(r>1||r<0)&&(r=1),{min:o,max:r}},_intersectionsTo:function(e,t){var n;return n=this.controlOut()&&e.controlIn()?$([this.anchor(),this.controlOut(),e.controlIn(),e.anchor()],t,this.bboxTo(e)):Y(this.anchor(),e.anchor(),t)},_isOnCurveTo:function(e,t,n,i){var o,r,s,a,l,c,d,u=this.bboxTo(e).expand(n,n);if(u.containsPoint(t))return o=this.anchor(),r=this.controlOut(),s=e.controlIn(),a=e.anchor(),"start"===i&&o.distanceTo(t)<=n?!O(o,r,t):"end"===i&&a.distanceTo(t)<=n?!O(a,s,t):(l=[o,r,s,a],!(!G(l,t,"x","y",n)&&!G(l,t,"y","x",n))||(c=A().rotate(45,t),d=[o.transformCopy(c),r.transformCopy(c),s.transformCopy(c),a.transformCopy(c)],G(d,t,"x","y",n)||G(d,t,"y","x",n)))},_isOnLineTo:function(e,t,n){var i=this.anchor(),o=e.anchor(),s=r(Math.atan2(o.y-i.y,o.x-i.x)),a=new dn([i.x,i.y-n/2],[i.distanceTo(o),n]);return a.containsPoint(t.transformCopy(A().rotate(-s,i)))},_isOnPathTo:function(e,t,n,i){var o;return o=this.controlOut()&&e.controlIn()?this._isOnCurveTo(e,t,n/2,i):this._isOnLineTo(e,t,n)}}),N(zn.prototype,["anchor","controlIn","controlOut"]),Yt.extend(zn.prototype),Pn=hn.extend({init:function(e){hn.fn.init.call(this,e),this.segments=new Rn,this.segments.addObserver(this),i(this.options.stroke)||(this.stroke("#000"),i(this.options.stroke.lineJoin)||this.options.set("stroke.lineJoin","miter"))},moveTo:function(e,t){return this.suspend(),this.segments.elements([]),this.resume(),this.lineTo(e,t),this},lineTo:function(e,t){var n=i(t)?new ln(e,t):e,o=new zn(n);return this.segments.push(o),this},curveTo:function(e,t,n){var i,o;return this.segments.length>0&&(i=u(this.segments),o=new zn(n,t),this.suspend(),i.controlOut(e),this.resume(),this.segments.push(o)),this},arc:function(e,t,n,i,o){var r,s,a,l,c;return this.segments.length>0&&(r=u(this.segments),s=r.anchor(),a=p(e),l=new ln(s.x-n*Math.cos(a),s.y-i*Math.sin(a)),c=new Cn(l,{startAngle:e,endAngle:t,radiusX:n,radiusY:i,anticlockwise:o}),this._addArcSegments(c)),this},arcTo:function(e,t,n,i,o,r){var s,a,l;return this.segments.length>0&&(s=u(this.segments),a=s.anchor(),l=Cn.fromPoints(a,e,t,n,i,o,r),this._addArcSegments(l)),this},_addArcSegments:function(e){var t,n,i=this;for(this.suspend(),t=e.curvePoints(),n=1;n<t.length;n+=3)i.curveTo(t[n],t[n+1],t[n+2]);this.resume(),this.geometryChange()},close:function(){return this.options.closed=!0,this.geometryChange(),this},rawBBox:function(){return this._bbox()},_containsPoint:function(e){var t,n,i,o=this.segments,r=o.length,s=0;for(i=1;i<r;i++)t=o[i-1],n=o[i],s+=t._intersectionsTo(n,e);return!this.options.closed&&o[0].anchor().equals(o[r-1].anchor())||(s+=Y(o[0].anchor(),o[r-1].anchor(),e)),s%2!==0},_isOnPath:function(e,t){var n,i=this.segments,o=i.length,r=t||this.options.stroke.width;if(o>1){if(i[0]._isOnPathTo(i[1],e,r,"start"))return!0;for(n=2;n<=o-2;n++)if(i[n-1]._isOnPathTo(i[n],e,r))return!0;if(i[o-2]._isOnPathTo(i[o-1],e,r,"end"))return!0}return!1},_bbox:function(e){var t,n,i,o,r=this.segments,s=r.length;if(1===s)n=r[0].anchor().transformCopy(e),t=new dn(n,cn.ZERO);else if(s>0)for(i=1;i<s;i++)o=r[i-1].bboxTo(r[i],e),t=t?dn.union(t,o):o;return t}}),Pn.fromRect=function(e,t){return new Pn(t).moveTo(e.topLeft()).lineTo(e.topRight()).lineTo(e.bottomRight()).lineTo(e.bottomLeft()).close()},Pn.fromPoints=function(e,t){var n,i,o;if(e){for(n=new Pn(t),i=0;i<e.length;i++)o=ln.create(e[i]),o&&(0===i?n.moveTo(o):n.lineTo(o));return n}},Pn.fromArc=function(e,t){var n=new Pn(t),i=e.startAngle,o=e.pointAt(i);return n.moveTo(o.x,o.y),n.arc(i,e.endAngle,e.radiusX,e.radiusY,e.anticlockwise),n},Pn.prototype.nodeType="Path",gn.extend(Pn.prototype),_n.extend(Pn.prototype),Bn="#000",Ln=hn.extend({init:function(e,t){void 0===e&&(e=new Cn),void 0===t&&(t={}),hn.fn.init.call(this,t),this.geometry(e),i(this.options.stroke)||this.stroke(Bn)},_bbox:function(e){return this._geometry.bbox(e)},rawBBox:function(){return this.geometry().bbox()},toPath:function(){var e,t=new Pn,n=this.geometry().curvePoints();if(n.length>0)for(t.moveTo(n[0].x,n[0].y),e=1;e<n.length;e+=3)t.curveTo(n[e],n[e+1],n[e+2]);return t},_containsPoint:function(e){return this.geometry().containsPoint(e)},_isOnPath:function(e){return this.geometry()._isOnPath(e,this.options.stroke.width/2)}}),Ln.prototype.nodeType="Arc",gn.extend(Ln.prototype),_n.extend(Ln.prototype),I(Ln.prototype,["geometry"]),Hn=hn.extend({init:function(e){hn.fn.init.call(this,e),this.paths=new Rn,this.paths.addObserver(this),i(this.options.stroke)||this.stroke("#000")},moveTo:function(e,t){var n=new Pn;return n.moveTo(e,t),this.paths.push(n),this},lineTo:function(e,t){return this.paths.length>0&&u(this.paths).lineTo(e,t),this},curveTo:function(e,t,n){return this.paths.length>0&&u(this.paths).curveTo(e,t,n),this},arc:function(e,t,n,i,o){return this.paths.length>0&&u(this.paths).arc(e,t,n,i,o),this},arcTo:function(e,t,n,i,o,r){return this.paths.length>0&&u(this.paths).arcTo(e,t,n,i,o,r),this},close:function(){return this.paths.length>0&&u(this.paths).close(),this},_bbox:function(e){return Q(this.paths,!0,e)},rawBBox:function(){return Q(this.paths,!1)},_containsPoint:function(e){var t,n=this.paths;for(t=0;t<n.length;t++)if(n[t]._containsPoint(e))return!0;return!1},_isOnPath:function(e){var t,n=this.paths,i=this.options.stroke.width;for(t=0;t<n.length;t++)if(n[t]._isOnPath(e,i))return!0;return!1},_clippedBBox:function(e){return X(this.paths,this.currentTransform(e))}}),Hn.prototype.nodeType="MultiPath",gn.extend(Hn.prototype),_n.extend(Hn.prototype),Nn="12px sans-serif",On="#000",Vn=hn.extend({init:function(e,t,n){void 0===t&&(t=new ln),void 0===n&&(n={}),hn.fn.init.call(this,n),this.content(e),this.position(t),this.options.font||(this.options.font=Nn),i(this.options.fill)||this.fill(On)},content:function(e){return i(e)?(this.options.set("content",e),this):this.options.get("content")},measure:function(){var e=qt.measureText(this.content(),{font:this.options.get("font")});return e},rect:function(){var e=this.measure(),t=this.position().clone();return new dn(t,[e.width,e.height])},bbox:function(e){var t=D(this.currentTransform(e));return this.rect().bbox(t)},rawBBox:function(){return this.rect().bbox()},_containsPoint:function(e){return this.rect().containsPoint(e)}}),Vn.prototype.nodeType="Text",gn.extend(Vn.prototype),N(Vn.prototype,["position"]),Un=hn.extend({init:function(e,t,n){void 0===t&&(t=new dn),void 0===n&&(n={}),hn.fn.init.call(this,n),this.src(e),this.rect(t)},src:function(e){return i(e)?(this.options.set("src",e),this):this.options.get("src")},bbox:function(e){var t=D(this.currentTransform(e));return this._rect.bbox(t)},rawBBox:function(){return this._rect.bbox()},_containsPoint:function(e){return this._rect.containsPoint(e)},_hasFill:function(){return this.src()}}),Un.prototype.nodeType="Image",I(Un.prototype,["rect"]),Wn={extend:function(e,t){e.traverse=function(e){var n,i,o=this[t];for(n=0;n<o.length;n++)i=o[n],i.traverse?i.traverse(e):e(i);return this}}},qn=hn.extend({init:function(e){hn.fn.init.call(this,e),this.children=[]},childrenChange:function(e,t,n){this.trigger("childrenChange",{action:e,items:t,index:n})},append:function(){return t(this.children,arguments),this._reparent(arguments,this),this.childrenChange("add",arguments),this},insert:function(e,t){return this.children.splice(e,0,t),t.parent=this,this.childrenChange("add",[t],e),this},insertAt:function(e,t){return this.insert(t,e)},remove:function(e){var t=this.children.indexOf(e);return t>=0&&(this.children.splice(t,1),e.parent=null,this.childrenChange("remove",[e],t)),this},removeAt:function(e){if(0<=e&&e<this.children.length){var t=this.children[e];this.children.splice(e,1),t.parent=null,this.childrenChange("remove",[t],e)}return this},clear:function(){var e=this.children;return this.children=[],this._reparent(e,null),this.childrenChange("remove",e,0),this},bbox:function(e){return Q(this.children,!0,this.currentTransform(e))},rawBBox:function(){return Q(this.children,!1)},_clippedBBox:function(e){return X(this.children,this.currentTransform(e))},currentTransform:function(e){return hn.prototype.currentTransform.call(this,e)||null},containsPoint:function(e,t){var n,i,o;if(this.visible())for(n=this.children,i=this.currentTransform(t),o=0;o<n.length;o++)if(n[o].containsPoint(e,i))return!0;return!1},_reparent:function(e,t){var n,i,o,r=this;for(n=0;n<e.length;n++)i=e[n],o=i.parent,o&&o!==r&&o.remove&&o.remove(i),i.parent=t}}),qn.prototype.nodeType="Group",Wn.extend(qn.prototype,"children"),jn={alignContent:"start",justifyContent:"start",alignItems:"start",spacing:0,orientation:"horizontal",lineSpacing:0,wrap:!0},Gn=qn.extend({init:function(t,n){qn.fn.init.call(this,e.extend({},jn,n)),this._rect=t,this._fieldMap={}},rect:function(e){return e?(this._rect=e,this):this._rect},_initMap:function(){var e=this.options,t=this._fieldMap;"horizontal"===e.orientation?(t.sizeField="width",t.groupsSizeField="height",t.groupAxis="x",t.groupsAxis="y"):(t.sizeField="height",t.groupsSizeField="width",t.groupAxis="y",t.groupsAxis="x")},reflow:function(){var e,t,n,i,o,r,s,a,l,c,d,u,h,f,p,m,g,v,_,b,w,y,k,x,C,S;if(this._rect&&0!==this.children.length){for(this._initMap(),this.options.transform&&this.transform(null),e=this.options,t=this._rect,n=this._initGroups(),i=n.groups,o=n.groupsSize,r=this._fieldMap,s=r.sizeField,a=r.groupsSizeField,l=r.groupAxis,c=r.groupsAxis,d=new ln,u=new ln,h=new cn,f=J(o,t,e.alignContent,c,a),b=0;b<i.length;b++){for(v=i[b],d[l]=p=J(v.size,t,e.justifyContent,l,s),d[c]=f,h[s]=v.size,h[a]=v.lineSize,_=new dn(d,h),w=0;w<v.bboxes.length;w++)g=v.elements[w],m=v.bboxes[w],u[l]=p,u[c]=J(m.size[a],_,e.alignItems,c,a),Z(u,m,g),p+=m.size[s]+e.spacing;f+=v.lineSize+e.lineSpacing}!e.wrap&&v.size>t.size[s]&&(y=t.size[s]/_.size[s],k=_.topLeft().scale(y,y),x=_.size[a]*y,C=J(x,t,e.alignContent,c,a),S=A(),"x"===l?S.translate(t.origin.x-k.x,C-k.y):S.translate(C-k.x,t.origin.y-k.y),S.scale(y,y),this.transform(S))}},_initGroups:function(){var e,t,n,i=this,o=this,r=o.options,s=o.children,a=r.lineSpacing,l=r.wrap,c=r.spacing,d=this._fieldMap.sizeField,u=this._newGroup(),h=[],f=function(){h.push(u),p+=u.lineSize+a},p=-a;for(e=0;e<s.length;e++)t=s[e],n=s[e].clippedBBox(),t.visible()&&n&&(l&&u.size+n.size[d]+c>i._rect.size[d]?0===u.bboxes.length?(i._addToGroup(u,n,t),f(),u=i._newGroup()):(f(),u=i._newGroup(),i._addToGroup(u,n,t)):i._addToGroup(u,n,t));return u.bboxes.length&&f(),{groups:h,groupsSize:p}},_addToGroup:function(e,t,n){e.size+=t.size[this._fieldMap.sizeField]+this.options.spacing,e.lineSize=Math.max(t.size[this._fieldMap.groupsSizeField],e.lineSize),e.bboxes.push(t),e.elements.push(n)},_newGroup:function(){return{lineSize:0,size:-this.options.spacing,bboxes:[],elements:[]}}}),$n=hn.extend({init:function(e,t){void 0===e&&(e=new dn),void 0===t&&(t={}),hn.fn.init.call(this,t),this.geometry(e),i(this.options.stroke)||this.stroke("#000")},_bbox:function(e){return this._geometry.bbox(e)},rawBBox:function(){return this._geometry.bbox()},_containsPoint:function(e){return this._geometry.containsPoint(e)},_isOnPath:function(e){return this.geometry()._isOnPath(e,this.options.stroke.width/2)}}),$n.prototype.nodeType="Rect",gn.extend($n.prototype),_n.extend($n.prototype),I($n.prototype,["geometry"]),Yn=In.extend({_change:function(){this.optionsChange({field:"stops"})}}),Kn=Wt.extend({init:function(e,t,n){this.options=new sn({offset:e,color:t,opacity:i(n)?n:1}),this.options.addObserver(this)}}),Kn.create=function(e){if(i(e)){var t;return t=e instanceof Kn?e:e.length>1?new Kn(e[0],e[1],e[2]):new Kn(e.offset,e.color,e.opacity)}},fe(Kn.prototype,["offset","color","opacity"]),Yt.extend(Kn.prototype),Qn=Wt.extend({init:function(e){void 0===e&&(e={}),this.stops=new Yn(this._createStops(e.stops)),this.stops.addObserver(this),this._userSpace=e.userSpace,this.id=o()},userSpace:function(e){return i(e)?(this._userSpace=e,this.optionsChange(),this):this._userSpace},_createStops:function(e){var t,n;for(void 0===e&&(e=[]),t=[],n=0;n<e.length;n++)t.push(Kn.create(e[n]));return t},addStop:function(e,t,n){this.stops.push(new Kn(e,t,n))},removeStop:function(e){var t=this.stops.indexOf(e);t>=0&&this.stops.splice(t,1)}}),Qn.prototype.nodeType="Gradient",Yt.extend(Qn.prototype),e.extend(Qn.prototype,{optionsChange:function(e){this.trigger("optionsChange",{field:"gradient"+(e?"."+e.field:""),value:this})},geometryChange:function(){this.optionsChange()}}),Xn=Qn.extend({init:function(e){void 0===e&&(e={}),Qn.fn.init.call(this,e),this.start(e.start||new ln),this.end(e.end||new ln(1,0))}}),N(Xn.prototype,["start","end"]),Zn=Qn.extend({init:function(e){void 0===e&&(e={}),Qn.fn.init.call(this,e),this.center(e.center||new ln),this._radius=i(e.radius)?e.radius:1,this._fallbackFill=e.fallbackFill},radius:function(e){return i(e)?(this._radius=e,this.geometryChange(),this):this._radius},fallbackFill:function(e){return i(e)?(this._fallbackFill=e,this.optionsChange(),this):this._fallbackFill}}),N(Zn.prototype,["center"]),Jn={swing:pe,linear:me,easeOutElastic:ge},ei=Date.now||function(){return(new Date).getTime()},ti=Wt.extend({init:function(t,n){this.options=e.extend({},this.options,n),this.element=t},setup:function(){},step:function(){},play:function(){var e,t,n,i=this,o=this.options,r=o.duration,s=o.delay;void 0===s&&(s=0),e=Jn[o.easing],t=ei()+s,n=t+r,0===r?(this.step(1),this.abort()):setTimeout(function(){var o=function(){var s,a,l,c;i._stopped||(s=ei(),a=h(s-t,0,r),l=a/r,c=e(l,a,0,1,r),i.step(c),s<n?kendo.animationFrame(o):i.abort())};o()},s)},abort:function(){this._stopped=!0},destroy:function(){this.abort()}}),ti.prototype.options={duration:500,easing:"swing"},ni=Wt.extend({init:function(){this._items=[]},register:function(e,t){this._items.push({name:e,type:t})},create:function(e,t){var n,i,o,r=this._items;if(t&&t.type)for(i=t.type.toLowerCase(),o=0;o<r.length;o++)if(r[o].name.toLowerCase()===i){n=r[o];break}if(n)return new n.type(e,t)}}),ni.current=new ni,ti.create=function(e,t,n){return ni.current.create(e,t,n)},ii={l:function(e,t){var n,i,o=t.parameters,r=t.position;for(n=0;n<o.length;n+=2)i=new ln(o[n],o[n+1]),t.isRelative&&i.translateWith(r),e.lineTo(i.x,i.y),r.x=i.x,r.y=i.y},c:function(e,t){var n,i,o,r,s=t.parameters,a=t.position;for(n=0;n<s.length;n+=6)i=new ln(s[n],s[n+1]),o=new ln(s[n+2],s[n+3]),r=new ln(s[n+4],s[n+5]),t.isRelative&&(o.translateWith(a),i.translateWith(a),r.translateWith(a)),e.curveTo(i,o,r),a.x=r.x,a.y=r.y},v:function(e,t){var n=t.isRelative?0:t.position.x;ve(t.parameters,!0,n),this.l(e,t)},h:function(e,t){var n=t.isRelative?0:t.position.y;ve(t.parameters,!1,n),this.l(e,t)},a:function(e,t){var n,i,o,r,s,a,l,c=t.parameters,d=t.position;for(n=0;n<c.length;n+=7)i=c[n],o=c[n+1],r=c[n+2],s=c[n+3],a=c[n+4],l=new ln(c[n+5],c[n+6]),t.isRelative&&l.translateWith(d),d.x===l.x&&d.y===l.y||(e.arcTo(l,i,o,s,a,r),d.x=l.x,d.y=l.y)},s:function(e,t){var n,i,o,r,s,a=t.parameters,l=t.position,c=t.previousCommand;for("s"!==c&&"c"!==c||(n=u(u(e.paths).segments).controlIn()),i=0;i<a.length;i+=4)o=new ln(a[i],a[i+1]),r=new ln(a[i+2],a[i+3]),s=void 0,t.isRelative&&(o.translateWith(l),r.translateWith(l)),s=n?_e(n,l):l.clone(),n=o,e.curveTo(s,o,r),l.x=r.x,l.y=r.y},q:function(e,t){var n,i,o,r,s=t.parameters,a=t.position;for(n=0;n<s.length;n+=4)i=new ln(s[n],s[n+1]),o=new ln(s[n+2],s[n+3]),t.isRelative&&(i.translateWith(a),o.translateWith(a)),r=be(a,i,o),e.curveTo(r.controlOut,r.controlIn,o),a.x=o.x,a.y=o.y},t:function(e,t){var n,i,o,r,s,a=t.parameters,l=t.position,c=t.previousCommand;for("q"!==c&&"t"!==c||(i=u(u(e.paths).segments),n=i.controlIn().clone().translateWith(l.scaleCopy(-1/3)).scale(1.5)),o=0;o<a.length;o+=2)r=new ln(a[o],a[o+1]),t.isRelative&&r.translateWith(l),n=n?_e(n,l):l.clone(),s=be(l,n,r),e.curveTo(s.controlOut,s.controlIn,r),l.x=r.x,l.y=r.y}},oi=1/3,ri=/([a-df-z]{1})([^a-df-z]*)(z)?/gi,si=/[,\s]?([+\-]?(?:\d*\.\d+|\d+)(?:[eE][+\-]?\d+)?)/g,ai="m",li="z",ci=Wt.extend({parse:function(e,t){var n,i=new Hn(t),o=new ln;return e.replace(ri,function(e,t,r,s){var a=t.toLowerCase(),l=a===t,c=we(r.trim());if(a===ai&&(l?(o.x+=c[0],o.y+=c[1]):(o.x=c[0],o.y=c[1]),i.moveTo(o.x,o.y),c.length>2&&(a="l",c.splice(0,2))),ii[a])ii[a](i,{parameters:c,position:o,isRelative:l,previousCommand:n}),s&&s.toLowerCase()===li&&i.close();else if(a!==ai)throw Error("Error while parsing SVG path. Unsupported command: "+a);n=a}),i}}),ci.current=new ci,Pn.parse=function(e,t){return ci.current.parse(e,t)},di=Wt.extend({init:function(){this._items=[]},register:function(e,t,n){var i=this._items,o=i[0],r={name:e,type:t,order:n};!o||n<o.order?i.unshift(r):i.push(r)},create:function(e,t){var n,i,o=this._items,r=o[0];if(t&&t.type)for(n=t.type.toLowerCase(),i=0;i<o.length;i++)if(o[i].name===n){r=o[i];break}return r?new r.type(e,t):void kendo.logToConsole("Warning: Unable to create Kendo UI Drawing Surface. Possible causes:\n- The browser does not support SVG and Canvas. User agent: "+navigator.userAgent)}}),di.current=new di,ui=["click","mouseenter","mouseleave","mousemove","resize","tooltipOpen","tooltipClose"],hi=kendo.Observable.extend({init:function(t,n){kendo.Observable.fn.init.call(this),this.options=e.extend({},n),this.element=t,this._click=this._handler("click"),this._mouseenter=this._handler("mouseenter"),this._mouseleave=this._handler("mouseleave"),this._mousemove=this._handler("mousemove"),this._visual=new qn,k(t,this.options),this.bind(ui,this.options),this._enableTracking()},draw:function(e){this._visual.children.push(e)},clear:function(){this._visual.children=[]},destroy:function(){this._visual=null,this.unbind()},eventTarget:function(e){for(var t,n=this,i=c(e);!t&&i&&(t=i._kendoNode,i!==n.element);)i=i.parentElement;if(t)return t.srcElement},exportVisual:function(){return this._visual},getSize:function(){return k(this.element)},currentSize:function(e){return e?void(this._size=e):this._size},setSize:function(e){k(this.element,e),this.currentSize(e),this._resize()},resize:function(e){var t=this.getSize(),n=this.currentSize();(e||(t.width>0||t.height>0)&&(!n||t.width!==n.width||t.height!==n.height))&&(this.currentSize(t),this._resize(t,e),this.trigger("resize",t))},size:function(e){return e?void this.setSize(e):this.getSize()},suspendTracking:function(){this._suspendedTracking=!0},resumeTracking:function(){this._suspendedTracking=!1;
},_enableTracking:function(){},_resize:function(){},_handler:function(e){var t=this;return function(n){var i=t.eventTarget(n);i&&!t._suspendedTracking&&t.trigger(e,{element:i,originalEvent:n,type:e})}},_elementOffset:function(){var e=this.element,t=w(e,["paddingLeft","paddingTop"]),n=t.paddingLeft,i=t.paddingTop,o=b(e),r=o.left,s=o.top;return{left:r+parseInt(n,10),top:s+parseInt(i,10)}},_surfacePoint:function(e){var t=this._elementOffset(),n=l(e),i=n.x-t.left,o=n.y-t.top;return new ln(i,o)}}),hi.create=function(e,t){return di.current.create(e,t)},hi.support={},fi=Wt.extend({init:function(e){this.childNodes=[],this.parent=null,e&&(this.srcElement=e,this.observe())},destroy:function(){var e,t,n=this;for(this.srcElement&&this.srcElement.removeObserver(this),e=this.childNodes,t=0;t<e.length;t++)n.childNodes[t].destroy();this.parent=null},load:function(){},observe:function(){this.srcElement&&this.srcElement.addObserver(this)},append:function(e){this.childNodes.push(e),e.parent=this},insertAt:function(e,t){this.childNodes.splice(t,0,e),e.parent=this},remove:function(e,t){var n,i=this,o=e+t;for(n=e;n<o;n++)i.childNodes[n].removeSelf();this.childNodes.splice(e,t)},removeSelf:function(){this.clear(),this.destroy()},clear:function(){this.remove(0,this.childNodes.length)},invalidate:function(){this.parent&&this.parent.invalidate()},geometryChange:function(){this.invalidate()},optionsChange:function(){this.invalidate()},childrenChange:function(e){"add"===e.action?this.load(e.items,e.index):"remove"===e.action&&this.remove(e.index,e.items.length),this.invalidate()}}),pi={},mi="http://www.w3.org/2000/svg",gi="none",vi=function(e,t){e.innerHTML=t},"undefined"!=typeof document&&(_i="<svg xmlns='"+mi+"'></svg>",bi=document.createElement("div"),wi="undefined"!=typeof DOMParser,bi.innerHTML=_i,wi&&bi.firstChild.namespaceURI!==mi&&(vi=function(e,t){var n=new DOMParser,i=n.parseFromString(t,"text/xml"),o=document.adoptNode(i.documentElement);e.innerHTML="",e.appendChild(o)})),yi=vi,ki="transform",xi={clip:"clip-path",fill:"fill"},Ci=fi.extend({init:function(e,t){fi.fn.init.call(this,e),this.definitions={},this.options=t},destroy:function(){this.element&&(this.element._kendoNode=null,this.element=null),this.clearDefinitions(),fi.fn.destroy.call(this)},load:function(e,t){var n,o,r,s,a,l=this;for(n=0;n<e.length;n++)o=e[n],r=o.children,s=new pi[o.nodeType](o,l.options),i(t)?l.insertAt(s,t):l.append(s),s.createDefinitions(),r&&r.length>0&&s.load(r),a=l.element,a&&s.attachTo(a,t)},root:function(){for(var e=this;e.parent;)e=e.parent;return e},attachTo:function(e,t){var n,o=document.createElement("div");yi(o,"<svg xmlns='"+mi+"' version='1.1'>"+this.render()+"</svg>"),n=o.firstChild.firstChild,n&&(i(t)?e.insertBefore(n,e.childNodes[t]||null):e.appendChild(n),this.setElement(n))},setElement:function(e){var t,n,i;for(this.element&&(this.element._kendoNode=null),this.element=e,this.element._kendoNode=this,t=this.childNodes,n=0;n<t.length;n++)i=e.childNodes[n],t[n].setElement(i)},clear:function(){var e,t;for(this.clearDefinitions(),this.element&&(this.element.innerHTML=""),e=this.childNodes,t=0;t<e.length;t++)e[t].destroy();this.childNodes=[]},removeSelf:function(){if(this.element){var e=this.element.parentNode;e&&e.removeChild(this.element),this.element=null}fi.fn.removeSelf.call(this)},template:function(){return this.renderChildren()},render:function(){return this.template()},renderChildren:function(){var e,t=this.childNodes,n="";for(e=0;e<t.length;e++)n+=t[e].render();return n},optionsChange:function(e){var t=e.field,n=e.value;"visible"===t?this.css("display",n?"":gi):xi[t]&&Ce(t,n)?this.updateDefinition(t,n):"opacity"===t?this.attr("opacity",n):"cursor"===t&&this.css("cursor",n),fi.fn.optionsChange.call(this,e)},attr:function(e,t){this.element&&this.element.setAttribute(e,t)},allAttr:function(e){var t,n=this;for(t=0;t<e.length;t++)n.attr(e[t][0],e[t][1])},css:function(e,t){this.element&&(this.element.style[e]=t)},allCss:function(e){var t,n=this;for(t=0;t<e.length;t++)n.css(e[t][0],e[t][1])},removeAttr:function(e){this.element&&this.element.removeAttribute(e)},mapTransform:function(e){var t=[];return e&&t.push([ki,"matrix("+e.matrix().toString(6)+")"]),t},renderTransform:function(){return ke(this.mapTransform(this.srcElement.transform()))},transformChange:function(e){e?this.allAttr(this.mapTransform(e)):this.removeAttr(ki)},mapStyle:function(){var e=this.srcElement.options,t=[["cursor",e.cursor]];return e.visible===!1&&t.push(["display",gi]),t},renderStyle:function(){return ye("style",xe(this.mapStyle(!0)))},renderOpacity:function(){return ye("opacity",this.srcElement.options.opacity)},createDefinitions:function(){var e,t,n,i,o=this.srcElement,r=this.definitions;if(o){e=o.options;for(n in xi)i=e.get(n),i&&Ce(n,i)&&(r[n]=i,t=!0);t&&this.definitionChange({action:"add",definitions:r})}},definitionChange:function(e){this.parent&&this.parent.definitionChange(e)},updateDefinition:function(e,t){var n=this.definitions,i=n[e],o=xi[e],r={};i&&(r[e]=i,this.definitionChange({action:"remove",definitions:r}),delete n[e]),t?(r[e]=t,this.definitionChange({action:"add",definitions:r}),n[e]=t,this.attr(o,this.refUrl(t.id))):i&&this.removeAttr(o)},clearDefinitions:function(){var e=this.definitions;this.definitionChange({action:"remove",definitions:e}),this.definitions={}},renderDefinitions:function(){return ke(this.mapDefinitions())},mapDefinitions:function(){var e,t=this,n=this.definitions,i=[];for(e in n)i.push([xi[e],t.refUrl(n[e].id)]);return i},refUrl:function(e){var t=(this.options||{}).skipBaseHref;return Te(e,t)}}),Si=Ci.extend({template:function(){return"<stop "+this.renderOffset()+" "+this.renderStyle()+" />"},renderOffset:function(){return ye("offset",this.srcElement.offset())},mapStyle:function(){var e=this.srcElement;return[["stop-color",e.color()],["stop-opacity",e.opacity()]]},optionsChange:function(e){"offset"===e.field?this.attr(e.field,e.value):"color"!==e.field&&"opacity"!==e.field||this.css("stop-"+e.field,e.value)}}),Ti=Ci.extend({init:function(e){Ci.fn.init.call(this,e),this.id=e.id,this.loadStops()},loadStops:function(){var e,t,n=this,i=this.srcElement.stops,o=this.element;for(e=0;e<i.length;e++)t=new Si(i[e]),n.append(t),o&&t.attachTo(o)},optionsChange:function(e){"gradient.stops"===e.field?(fi.prototype.clear.call(this),this.loadStops()):"gradient"===e.field&&this.allAttr(this.mapCoordinates())},renderCoordinates:function(){return ke(this.mapCoordinates())},mapSpace:function(){return["gradientUnits",this.srcElement.userSpace()?"userSpaceOnUse":"objectBoundingBox"]}}),Di=Ti.extend({template:function(){return"<linearGradient id='"+this.id+"' "+this.renderCoordinates()+">"+this.renderChildren()+"</linearGradient>"},mapCoordinates:function(){var e=this.srcElement,t=e.start(),n=e.end(),i=[["x1",t.x],["y1",t.y],["x2",n.x],["y2",n.y],this.mapSpace()];return i}}),Ai=Ti.extend({template:function(){return"<radialGradient id='"+this.id+"' "+this.renderCoordinates()+">"+this.renderChildren()+"</radialGradient>"},mapCoordinates:function(){var e=this.srcElement,t=e.center(),n=e.radius(),i=[["cx",t.x],["cy",t.y],["r",n],this.mapSpace()];return i}}),Ei=Ci.extend({init:function(e){Ci.fn.init.call(this),this.srcElement=e,this.id=e.id,this.load([e])},template:function(){return"<clipPath id='"+this.id+"'>"+this.renderChildren()+"</clipPath>"}}),Mi=Ci.extend({init:function(){Ci.fn.init.call(this),this.definitionMap={}},attachTo:function(e){this.element=e},template:function(){return"<defs>"+this.renderChildren()+"</defs>"},definitionChange:function(e){var t=e.definitions,n=e.action;"add"===n?this.addDefinitions(t):"remove"===n&&this.removeDefinitions(t)},createDefinition:function(e,t){var n;return"clip"===e?n=Ei:"fill"===e&&(t instanceof Xn?n=Di:t instanceof Zn&&(n=Ai)),new n(t)},addDefinitions:function(e){var t,n=this;for(t in e)n.addDefinition(t,e[t])},addDefinition:function(e,t){var n,i=this,o=i.element,r=i.definitionMap,s=t.id,a=r[s];a?a.count++:(n=this.createDefinition(e,t),r[s]={element:n,count:1},this.append(n),o&&n.attachTo(this.element))},removeDefinitions:function(e){var t,n=this;for(t in e)n.removeDefinition(e[t])},removeDefinition:function(e){var t=this.definitionMap,n=e.id,i=t[n];i&&(i.count--,0===i.count&&(this.remove(this.childNodes.indexOf(i.element),1),delete t[n]))}}),Ii=Ci.extend({init:function(e){Ci.fn.init.call(this),this.options=e,this.defs=new Mi},attachTo:function(e){this.element=e,this.defs.attachTo(e.firstElementChild)},clear:function(){fi.prototype.clear.call(this)},template:function(){return this.defs.render()+this.renderChildren()},definitionChange:function(e){this.defs.definitionChange(e)}}),Ri="rtl",Fi=hi.extend({init:function(t,n){hi.fn.init.call(this,t,n),this._root=new Ii(e.extend({rtl:w(t,"direction").direction===Ri},this.options)),yi(this.element,this._template()),this._rootElement=this.element.firstElementChild,De(this._rootElement),this._root.attachTo(this._rootElement),_(this.element,{click:this._click,mouseover:this._mouseenter,mouseout:this._mouseleave,mousemove:this._mousemove}),this.resize()},destroy:function(){this._root&&(this._root.destroy(),this._root=null,this._rootElement=null,x(this.element,{click:this._click,mouseover:this._mouseenter,mouseout:this._mouseleave,mousemove:this._mousemove})),hi.fn.destroy.call(this)},translate:function(e){var t=Math.round(e.x)+" "+Math.round(e.y)+" "+this._size.width+" "+this._size.height;this._offset=e,this._rootElement.setAttribute("viewBox",t)},draw:function(e){hi.fn.draw.call(this,e),this._root.load([e])},clear:function(){hi.fn.clear.call(this),this._root.clear()},svg:function(){return"<?xml version='1.0' ?>"+this._template()},exportVisual:function(){var e,t=this,n=t._visual,i=t._offset;return i&&(e=new qn,e.children.push(n),e.transform(A().translate(-i.x,-i.y)),n=e),n},_resize:function(){this._offset&&this.translate(this._offset)},_template:function(){return"<svg style='width: 100%; height: 100%; overflow: hidden;' xmlns='"+mi+"' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1'>"+this._root.render()+"</svg>"}}),Fi.prototype.type="svg","undefined"!=typeof document&&document.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure","1.1")&&(hi.support.svg=!0,di.current.register("svg",Fi,10)),zi=Ci.extend({template:function(){return"<g"+(this.renderTransform()+this.renderStyle()+this.renderOpacity()+this.renderDefinitions())+">"+this.renderChildren()+"</g>"},optionsChange:function(e){"transform"===e.field&&this.transformChange(e.value),Ci.fn.optionsChange.call(this,e)}}),pi.Group=zi,Pi={dot:[1.5,3.5],dash:[4,3.5],longdash:[8,3.5],dashdot:[3.5,3.5,1.5,3.5],longdashdot:[8,3.5,1.5,3.5],longdashdotdot:[8,3.5,1.5,3.5,1.5,3.5]},Bi="solid",Li="butt",Hi={"fill.opacity":"fill-opacity","stroke.color":"stroke","stroke.width":"stroke-width","stroke.opacity":"stroke-opacity"},Ni=" ",Oi=Ci.extend({geometryChange:function(){this.attr("d",this.renderData()),this.invalidate()},optionsChange:function(e){switch(e.field){case"fill":e.value?this.allAttr(this.mapFill(e.value)):this.removeAttr("fill");break;case"fill.color":this.allAttr(this.mapFill({color:e.value}));break;case"stroke":e.value?this.allAttr(this.mapStroke(e.value)):this.removeAttr("stroke");break;case"transform":this.transformChange(e.value);break;default:var t=Hi[e.field];t&&this.attr(t,e.value)}Ci.fn.optionsChange.call(this,e)},content:function(){this.element&&(this.element.textContent=this.srcElement.content())},renderData:function(){return this.printPath(this.srcElement)},printPath:function(e){var t,n,i,o,r,s=this,a=e.segments,l=a.length;if(l>0){for(t=[],o=1;o<l;o++)r=s.segmentType(a[o-1],a[o]),r!==i&&(i=r,t.push(r)),t.push("L"===r?s.printPoints(a[o].anchor()):s.printPoints(a[o-1].controlOut(),a[o].controlIn(),a[o].anchor()));return n="M"+this.printPoints(a[0].anchor())+Ni+t.join(Ni),e.options.closed&&(n+="Z"),n}},printPoints:function(){var e,t=arguments,n=t.length,i=[];for(e=0;e<n;e++)i.push(t[e].toString(3));return i.join(" ")},segmentType:function(e,t){return e.controlOut()&&t.controlIn()?"C":"L"},mapStroke:function(e){var t=[];return e&&!d(e.color)?(t.push(["stroke",e.color]),t.push(["stroke-width",e.width]),t.push(["stroke-linecap",this.renderLinecap(e)]),t.push(["stroke-linejoin",e.lineJoin]),i(e.opacity)&&t.push(["stroke-opacity",e.opacity]),i(e.dashType)&&t.push(["stroke-dasharray",this.renderDashType(e)])):t.push(["stroke",gi]),t},renderStroke:function(){return ke(this.mapStroke(this.srcElement.options.stroke))},renderDashType:function(e){var t,n,i,o=e.dashType,r=e.width;if(void 0===r&&(r=1),o&&o!==Bi){for(t=Pi[o.toLowerCase()],n=[],i=0;i<t.length;i++)n.push(t[i]*r);return n.join(" ")}},renderLinecap:function(e){var t=e.dashType,n=e.lineCap;return t&&"solid"!==t?Li:n},mapFill:function(e){var t=[];return e&&"Gradient"===e.nodeType||(e&&!d(e.color)?(t.push(["fill",e.color]),i(e.opacity)&&t.push(["fill-opacity",e.opacity])):t.push(["fill",gi])),t},renderFill:function(){return ke(this.mapFill(this.srcElement.options.fill))},template:function(){return"<path "+this.renderStyle()+" "+this.renderOpacity()+" "+ye("d",this.renderData())+this.renderStroke()+this.renderFill()+this.renderDefinitions()+this.renderTransform()+"></path>"}}),pi.Path=Oi,Vi=Oi.extend({renderData:function(){return this.printPath(this.srcElement.toPath())}}),pi.Arc=Vi,Ui=Oi.extend({geometryChange:function(){var e=this.center();this.attr("cx",e.x),this.attr("cy",e.y),this.attr("r",this.radius()),this.invalidate()},center:function(){return this.srcElement.geometry().center},radius:function(){return this.srcElement.geometry().radius},template:function(){return"<circle "+this.renderStyle()+" "+this.renderOpacity()+"cx='"+this.center().x+"' cy='"+this.center().y+"' r='"+this.radius()+"'"+this.renderStroke()+" "+this.renderFill()+" "+this.renderDefinitions()+this.renderTransform()+" ></circle>"}}),pi.Circle=Ui,Wi=Oi.extend({geometryChange:function(){var e=this.srcElement.geometry();this.attr("x",e.origin.x),this.attr("y",e.origin.y),this.attr("width",e.size.width),this.attr("height",e.size.height),this.invalidate()},size:function(){return this.srcElement.geometry().size},origin:function(){return this.srcElement.geometry().origin},template:function(){return"<rect "+this.renderStyle()+" "+this.renderOpacity()+" x='"+this.origin().x+"' y='"+this.origin().y+"' width='"+this.size().width+"' height='"+this.size().height+"' "+this.renderStroke()+" "+this.renderFill()+" "+this.renderDefinitions()+" "+this.renderTransform()+" />"}}),pi.Rect=Wi,qi=Oi.extend({geometryChange:function(){this.allAttr(this.mapPosition()),this.invalidate()},optionsChange:function(e){"src"===e.field&&this.allAttr(this.mapSource()),Oi.fn.optionsChange.call(this,e)},mapPosition:function(){var e=this.srcElement.rect(),t=e.topLeft();return[["x",t.x],["y",t.y],["width",e.width()+"px"],["height",e.height()+"px"]]},renderPosition:function(){return ke(this.mapPosition())},mapSource:function(e){var t=this.srcElement.src();return e&&(t=kendo.htmlEncode(t)),[["xlink:href",t]]},renderSource:function(){return ke(this.mapSource(!0))},template:function(){return"<image preserveAspectRatio='none' "+this.renderStyle()+" "+this.renderTransform()+" "+this.renderOpacity()+this.renderPosition()+" "+this.renderSource()+" "+this.renderDefinitions()+"></image>"}}),pi.Image=qi,"undefined"!=typeof document&&(Ae._element=document.createElement("span")),ji=Oi.extend({geometryChange:function(){var e=this.pos();this.attr("x",e.x),this.attr("y",e.y),this.invalidate()},optionsChange:function(e){"font"===e.field?(this.attr("style",xe(this.mapStyle())),this.geometryChange()):"content"===e.field&&Oi.fn.content.call(this,this.srcElement.content()),Oi.fn.optionsChange.call(this,e)},mapStyle:function(e){var t=Oi.fn.mapStyle.call(this,e),n=this.srcElement.options.font;return e&&(n=kendo.htmlEncode(n)),t.push(["font",n]),t},pos:function(){var e=this.srcElement.position(),t=this.srcElement.measure();return e.clone().setY(e.y+t.baseline)},renderContent:function(){var e=this.srcElement.content();return e=Ae(e),e=kendo.htmlEncode(e)},renderTextAnchor:function(){var e;return(this.options||{}).rtl&&(e="end"),ye("text-anchor",e)},template:function(){return"<text "+this.renderTextAnchor()+" "+this.renderStyle()+" "+this.renderOpacity()+" x='"+this.pos().x+"' y='"+this.pos().y+"'"+this.renderStroke()+" "+this.renderTransform()+" "+this.renderDefinitions()+this.renderFill()+">"+this.renderContent()+"</text>"}}),pi.Text=ji,Gi=Oi.extend({renderData:function(){var e,t,n=this,i=this.srcElement.paths;if(i.length>0){for(e=[],t=0;t<i.length;t++)e.push(n.printPath(i[t]));return e.join(" ")}}}),pi.MultiPath=Gi,$i={Circle:pn,Arc:Cn,Rect:dn,Point:ln,Segment:zn,Matrix:an,Size:cn,toMatrix:D,Transformation:un,transform:A},Yi={Surface:Fi,RootNode:Ii,Node:Ci,GroupNode:zi,ArcNode:Vi,CircleNode:Ui,RectNode:Wi,ImageNode:qi,TextNode:ji,PathNode:Oi,MultiPathNode:Gi,DefinitionNode:Mi,ClipNode:Ei,GradientStopNode:Si,LinearGradientNode:Di,RadialGradientNode:Ai,exportGroup:Ee},Ki={},Qi=fi.extend({init:function(e){fi.fn.init.call(this,e),e&&this.initClip()},initClip:function(){var e=this.srcElement.clip();e&&(this.clip=e,e.addObserver(this))},clear:function(){this.srcElement&&this.srcElement.removeObserver(this),this.clearClip(),fi.fn.clear.call(this)},clearClip:function(){this.clip&&(this.clip.removeObserver(this),delete this.clip)},setClip:function(e){this.clip&&(e.beginPath(),Me(e,this.clip),e.clip())},optionsChange:function(e){"clip"===e.field&&(this.clearClip(),this.initClip()),fi.fn.optionsChange.call(this,e)},setTransform:function(e){if(this.srcElement){var t=this.srcElement.transform();t&&e.transform.apply(e,t.matrix().toArray(6))}},loadElements:function(e,t,n){var o,r,s,a,l=this;for(o=0;o<e.length;o++)r=e[o],s=r.children,a=new Ki[r.nodeType](r,n),s&&s.length>0&&a.load(s,t,n),i(t)?l.insertAt(a,t):l.append(a)},load:function(e,t,n){this.loadElements(e,t,n),this.invalidate()},setOpacity:function(e){if(this.srcElement){var t=this.srcElement.opacity();i(t)&&this.globalAlpha(e,t)}},globalAlpha:function(e,t){var n=t;n&&e.globalAlpha&&(n*=e.globalAlpha),e.globalAlpha=n},visible:function(){var e=this.srcElement;return!e||e&&e.options.visible!==!1}}),Xi=Qi.extend({renderTo:function(e){var t,n,i;if(this.visible()){for(e.save(),this.setTransform(e),this.setClip(e),this.setOpacity(e),t=this.childNodes,n=0;n<t.length;n++)i=t[n],i.visible()&&i.renderTo(e);e.restore()}}}),Wn.extend(Xi.prototype,"childNodes"),Ki.Group=Xi,Zi=1e3/60,Ji=Xi.extend({init:function(e){Xi.fn.init.call(this),this.canvas=e,this.ctx=e.getContext("2d");var t=this._invalidate.bind(this);this.invalidate=kendo.throttle(function(){kendo.animationFrame(t)},Zi)},destroy:function(){Xi.fn.destroy.call(this),this.canvas=null,this.ctx=null},load:function(e,t,n){this.loadElements(e,t,n),this._invalidate()},_invalidate:function(){this.ctx&&(this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height),this.renderTo(this.ctx))}}),Wn.extend(Ji.prototype,"childNodes"),eo=Wt.extend({init:function(){this.shapes=[]},_add:function(e,t){this.shapes.push({bbox:t,shape:e}),e._quadNode=this},pointShapes:function(e){var t,n=this.shapes,i=n.length,o=[];for(t=0;t<i;t++)n[t].bbox.containsPoint(e)&&o.push(n[t].shape);return o},insert:function(e,t){this._add(e,t)},remove:function(e){var t,n=this.shapes,i=n.length;for(t=0;t<i;t++)if(n[t].shape===e){n.splice(t,1);break}}}),to=eo.extend({init:function(e){eo.fn.init.call(this),this.children=[],this.rect=e},inBounds:function(e){var t=this.rect,n=t.bottomRight(),i=e.bottomRight(),o=t.origin.x<=e.origin.x&&t.origin.y<=e.origin.y&&i.x<=n.x&&i.y<=n.y;return o},pointShapes:function(e){var n,i=this.children,o=i.length,r=eo.fn.pointShapes.call(this,e);for(n=0;n<o;n++)t(r,i[n].pointShapes(e));return r},insert:function(e,t){var n,i=this.children,o=!1;if(this.inBounds(t)){if(this.shapes.length<4)this._add(e,t);else{for(i.length||this._initChildren(),n=0;n<i.length;n++)if(i[n].insert(e,t)){o=!0;break}o||this._add(e,t)}o=!0}return o},_initChildren:function(){var e=this,t=e.rect,n=e.children,i=t.center(),o=t.width()/2,r=t.height()/2;n.push(new to(new dn([t.origin.x,t.origin.y],[o,r])),new to(new dn([i.x,t.origin.y],[o,r])),new to(new dn([t.origin.x,i.y],[o,r])),new to(new dn([i.x,i.y],[o,r])))}}),no=3e3,io=1e4,oo=75,ro=Wt.extend({init:function(){this.initRoots()},initRoots:function(){this.rootMap={},this.root=new eo,this.rootElements=[]},clear:function(){var e,t=this,n=this.rootElements;for(e=0;e<n.length;e++)t.remove(n[e]);this.initRoots()},pointShape:function(e){var t,n=(this.rootMap[Math.floor(e.x/no)]||{})[Math.floor(e.y/no)],i=this.root.pointShapes(e);for(n&&(i=i.concat(n.pointShapes(e))),this.assignZindex(i),i.sort(Ie),t=0;t<i.length;t++)if(i[t].containsPoint(e))return i[t]},assignZindex:function(e){var t,n,i,o,r,s=this;for(t=0;t<e.length;t++){for(n=e[t],i=0,o=Math.pow(io,oo),r=[];n;)r.push(n),n=n.parent;for(;r.length;)n=r.pop(),i+=((n.parent?n.parent.children:s.rootElements).indexOf(n)+1)*o,o/=io;e[t]._zIndex=i}},optionsChange:function(e){"transform"!==e.field&&"stroke.width"!==e.field||this.bboxChange(e.element)},geometryChange:function(e){this.bboxChange(e.element)},bboxChange:function(e){var t,n=this;if("Group"===e.nodeType)for(t=0;t<e.children.length;t++)n.bboxChange(e.children[t]);else e._quadNode&&e._quadNode.remove(e),this._insertShape(e)},add:function(e){var n=Array.isArray(e)?e.slice(0):[e];t(this.rootElements,n),this._insert(n)},childrenChange:function(e){var t,n=this;if("remove"===e.action)for(t=0;t<e.items.length;t++)n.remove(e.items[t]);else this._insert(Array.prototype.slice.call(e.items,0))},_insert:function(e){for(var n,i=this;e.length>0;)n=e.pop(),n.addObserver(i),"Group"===n.nodeType?t(e,n.children):i._insertShape(n)},_insertShape:function(e){var t,n,i,o,r=e.bbox();r&&(t=this.getSectors(r),n=t[0][0],i=t[1][0],this.inRoot(t)?this.root.insert(e,r):(o=this.rootMap,o[n]||(o[n]={}),o[n][i]||(o[n][i]=new to(new dn([n*no,i*no],[no,no]))),o[n][i].insert(e,r)))},remove:function(e){var t,n,i=this;if(e.removeObserver(this),"Group"===e.nodeType)for(t=e.children,n=0;n<t.length;n++)i.remove(t[n]);else e._quadNode&&(e._quadNode.remove(e),delete e._quadNode)},inRoot:function(e){return e[0].length>1||e[1].length>1},getSectors:function(e){var t,n,i=e.bottomRight(),o=Math.floor(i.x/no),r=Math.floor(i.y/no),s=[[],[]];for(t=Math.floor(e.origin.x/no);t<=o;t++)s[0].push(t);for(n=Math.floor(e.origin.y/no);n<=r;n++)s[1].push(n);return s}}),so=Wt.extend({init:function(e){e.bind("mouseenter",this._mouseenter.bind(this)),e.bind("mouseleave",this._mouseleave.bind(this)),this.element=e.element},clear:function(){this._resetCursor()},destroy:function(){this._resetCursor(),delete this.element},_mouseenter:function(e){var t=this._shapeCursor(e);t?(this._current||(this._defaultCursor=this._getCursor()),this._setCursor(t)):this._resetCursor()},_mouseleave:function(){this._resetCursor()},_shapeCursor:function(e){for(var t=e.element;t&&!i(t.options.cursor);)t=t.parent;if(t)return t.options.cursor},_getCursor:function(){if(this.element)return this.element.style.cursor},_setCursor:function(e){this.element&&(this.element.style.cursor=e,this._current=e)},_resetCursor:function(){this._current&&(this._setCursor(this._defaultCursor||""),delete this._current)}}),ao=hi.extend({init:function(e,t){var n,i;hi.fn.init.call(this,e,t),this.element.innerHTML=this._template(this),n=this.element.firstElementChild,i=k(e),n.width=i.width,n.height=i.height,this._rootElement=n,this._root=new Ji(n),this._mouseTrackHandler=this._trackMouse.bind(this),_(this.element,{click:this._mouseTrackHandler,mousemove:this._mouseTrackHandler})},destroy:function(){hi.fn.destroy.call(this),this._root&&(this._root.destroy(),this._root=null),this._searchTree&&(this._searchTree.clear(),delete this._searchTree),this._cursor&&(this._cursor.destroy(),delete this._cursor),x(this.element,{click:this._mouseTrackHandler,mousemove:this._mouseTrackHandler})},draw:function(e){hi.fn.draw.call(this,e),this._root.load([e],void 0,this.options.cors),this._searchTree&&this._searchTree.add([e])},clear:function(){hi.fn.clear.call(this),this._root.clear(),this._searchTree&&this._searchTree.clear(),this._cursor&&this._cursor.clear()},eventTarget:function(e){var t,n;if(this._searchTree)return t=this._surfacePoint(e),n=this._searchTree.pointShape(t)},image:function(){var e,t,n=this,i=n._root,o=n._rootElement,r=[];return i.traverse(function(e){e.loading&&r.push(e.loading)}),e=Gt(),t=function(){i._invalidate();try{var t=o.toDataURL();e.resolve(t)}catch(n){e.reject(n)}},$t(r).then(t,t),e},suspendTracking:function(){hi.fn.suspendTracking.call(this),this._searchTree&&(this._searchTree.clear(),delete this._searchTree)},resumeTracking:function(){var e,t,n;if(hi.fn.resumeTracking.call(this),!this._searchTree){for(this._searchTree=new ro,e=this._root.childNodes,t=[],n=0;n<e.length;n++)t.push(e[n].srcElement);this._searchTree.add(t)}},_resize:function(){this._rootElement.width=this._size.width,this._rootElement.height=this._size.height,this._root.invalidate()},_template:function(){return"<canvas style='width: 100%; height: 100%;'></canvas>"},_enableTracking:function(){this._searchTree=new ro,this._cursor=new so(this),hi.fn._enableTracking.call(this)},_trackMouse:function(e){var t,n;this._suspendedTracking||(t=this.eventTarget(e),"click"!==e.type?(n=this._currentShape,n&&n!==t&&this.trigger("mouseleave",{element:n,originalEvent:e,type:"mouseleave"}),t&&n!==t&&this.trigger("mouseenter",{element:t,originalEvent:e,type:"mouseenter"}),this.trigger("mousemove",{element:t,originalEvent:e,type:"mousemove"}),this._currentShape=t):t&&this.trigger("click",{element:t,originalEvent:e,type:"click"}))}}),ao.prototype.type="canvas","undefined"!=typeof document&&document.createElement("canvas").getContext&&(hi.support.canvas=!0,di.current.register("canvas",ao,20)),lo=Qi.extend({renderTo:function(e){e.save(),this.setTransform(e),this.setClip(e),this.setOpacity(e),e.beginPath(),this.renderPoints(e,this.srcElement),this.setLineDash(e),this.setLineCap(e),this.setLineJoin(e),this.setFill(e),this.setStroke(e),e.restore()},setFill:function(e){var t=this.srcElement.options.fill,n=!1;return t&&("Gradient"===t.nodeType?(this.setGradientFill(e,t),n=!0):d(t.color)||(e.fillStyle=t.color,e.save(),this.globalAlpha(e,t.opacity),e.fill(),e.restore(),n=!0)),n},setGradientFill:function(e,t){var n,i,o,r,s=this.srcElement.rawBBox();t instanceof Xn?(i=t.start(),o=t.end(),n=e.createLinearGradient(i.x,i.y,o.x,o.y)):t instanceof Zn&&(r=t.center(),n=e.createRadialGradient(r.x,r.y,0,r.x,r.y,t.radius())),Re(n,t.stops),e.save(),t.userSpace()||e.transform(s.width(),0,0,s.height(),s.origin.x,s.origin.y),e.fillStyle=n,e.fill(),e.restore()},setStroke:function(e){var t=this.srcElement.options.stroke;if(t&&!d(t.color)&&t.width>0)return e.strokeStyle=t.color,e.lineWidth=v(t.width,1),e.save(),this.globalAlpha(e,t.opacity),e.stroke(),e.restore(),!0},dashType:function(){var e=this.srcElement.options.stroke;if(e&&e.dashType)return e.dashType.toLowerCase()},setLineDash:function(e){var t,n=this.dashType();n&&n!==Bi&&(t=Pi[n],e.setLineDash?e.setLineDash(t):(e.mozDash=t,e.webkitLineDash=t))},setLineCap:function(e){var t=this.dashType(),n=this.srcElement.options.stroke;t&&t!==Bi?e.lineCap=Li:n&&n.lineCap&&(e.lineCap=n.lineCap)},setLineJoin:function(e){var t=this.srcElement.options.stroke;t&&t.lineJoin&&(e.lineJoin=t.lineJoin)},renderPoints:function(e,t){Me(e,t)}}),Ki.Path=lo,co=lo.extend({renderPoints:function(e){var t=this.srcElement.toPath();Me(e,t)}}),Ki.Arc=co,uo=lo.extend({renderPoints:function(e){var t=this.srcElement.geometry(),n=t.center,i=t.radius;e.arc(n.x,n.y,i,0,2*Math.PI)}}),Ki.Circle=uo,ho=lo.extend({renderPoints:function(e){var t=this.srcElement.geometry(),n=t.origin,i=t.size;e.rect(n.x,n.y,i.width,i.height)}}),Ki.Rect=ho,fo=lo.extend({init:function(e,t){lo.fn.init.call(this,e),this.onLoad=this.onLoad.bind(this),this.onError=this.onError.bind(this),this.loading=Gt();var n=this.img=new Image;t&&!/^data:/i.test(e.src())&&(n.crossOrigin=t),n.src=e.src(),n.complete?this.onLoad():(n.onload=this.onLoad,n.onerror=this.onError)},renderTo:function(e){"resolved"===this.loading.state()&&(e.save(),this.setTransform(e),this.setClip(e),this.drawImage(e),e.restore())},optionsChange:function(e){"src"===e.field?(this.loading=Gt(),this.img.src=this.srcElement.src()):lo.fn.optionsChange.call(this,e)},onLoad:function(){this.loading.resolve(),this.invalidate()},onError:function(){this.loading.reject(Error("Unable to load image '"+this.img.src+"'. Check for connectivity and verify CORS headers."))},drawImage:function(e){var t=this.srcElement.rect(),n=t.topLeft();e.drawImage(this.img,n.x,n.y,t.width(),t.height())}}),Ki.Image=fo,po=lo.extend({renderTo:function(e){var t=this.srcElement,n=t.position(),i=t.measure();e.save(),this.setTransform(e),this.setClip(e),this.setOpacity(e),e.beginPath(),e.font=t.options.font,e.textAlign="left",this.setFill(e)&&e.fillText(t.content(),n.x,n.y+i.baseline),this.setStroke(e)&&(this.setLineDash(e),e.strokeText(t.content(),n.x,n.y+i.baseline)),e.restore()}}),Ki.Text=po,mo=lo.extend({renderPoints:function(e){var t,n=this.srcElement.paths;for(t=0;t<n.length;t++)Me(e,n[t])}}),Ki.MultiPath=mo,go={Surface:ao,RootNode:Ji,Node:Qi,GroupNode:Xi,ArcNode:co,CircleNode:uo,RectNode:ho,ImageNode:fo,TextNode:po,PathNode:lo,MultiPathNode:mo},vo=jt.browser,_o="KENDO-PSEUDO-ELEMENT",bo={},wo={},wo._root=wo,yo=Vn.extend({init:function(e,t,n){Vn.fn.init.call(this,e,t.getOrigin(),n),this._pdfRect=t},rect:function(){return this._pdfRect},rawBBox:function(){return this._pdfRect}}),ko="undefined"!=typeof Element&&Element.prototype&&function(e){return e.matches?function(e,t){return e.matches(t)}:e.webkitMatchesSelector?function(e,t){return e.webkitMatchesSelector(t)}:e.mozMatchesSelector?function(e,t){return e.mozMatchesSelector(t)}:e.msMatchesSelector?function(e,t){return e.msMatchesSelector(t)}:function(e){return[].indexOf.call(document.querySelectorAll(e),this)!==-1}}(Element.prototype),xo=function(e){return e?function t(n){var i,o,r,s,a=n.cloneNode(!1);if(1==n.nodeType){i=e(n),o=e(a),s=i.data();for(r in s)o.data(r,s[r]);for(/^canvas$/i.test(n.tagName)?a.getContext("2d").drawImage(n,0,0):/^(?:input|select|textarea|option)$/i.test(n.tagName)&&(a.removeAttribute("id"),a.removeAttribute("name"),a.value=n.value,a.checked=n.checked,a.selected=n.selected),r=n.firstChild;r;r=r.nextSibling)a.appendChild(t(r))}return a}:function(e){var t,n=e.cloneNode(!0),i=e.querySelectorAll("canvas");return i.length&&Pe(n.querySelectorAll("canvas")).forEach(function(e,t){e.getContext("2d").drawImage(i[t],0,0)}),t=e.querySelectorAll("input, select, textarea, option"),Pe(n.querySelectorAll("input, select, textarea, option")).forEach(function(e,n){e.removeAttribute("id"),e.removeAttribute("name"),e.value=t[n].value,e.checked=t[n].checked,e.selected=t[n].selected}),n}}("undefined"!=typeof window&&window.kendo&&window.kendo.jQuery),Ve.getFontFaces=Ue,Ve.drawText=function(e){var t=new qn;return wo._clipbox=!1,wo._matrix=an.unit(),wo._stackingContext={element:e,group:t},et(e,rt(e),t),3==e.firstChild.nodeType?Lt(e,e.firstChild,t):Dt(e,t),tt(),t},Co=function(){function e(e){function f(){var t=s.exec(e);t&&(e=e.substr(t[1].length))}function p(t){f();var n=t.exec(e);if(n)return e=e.substr(n[1].length),n[1]}function m(){var t,o,r,s=kendo.parseColor(e,!0);if(s)return r=/^#[0-9a-f]+/i.exec(e)||/^rgba?\(.*?\)/i.exec(e)||/^..*?\b/.exec(e),e=e.substr(r[0].length),s=s.toRGB(),(t=p(i))||(o=p(n)),{color:s,length:t,percent:o}}function g(t){var i,s,d,u,h,f,g=[],v=!1;if(p(a)){for(i=p(r),i?(i=mt(i),p(c)):(s=p(o),"to"==s?s=p(o):s&&/^-/.test(t)&&(v=!0),d=p(o),p(c)),/-moz-/.test(t)&&null==i&&null==s&&(u=p(n),h=p(n),v=!0,"0%"==u?s="left":"100%"==u&&(s="right"),"0%"==h?d="top":"100%"==h&&(d="bottom"),p(c));e&&!p(l)&&(f=m());)g.push(f),p(c);return{type:"linear",angle:i,to:s&&d?s+" "+d:s?s:d?d:null,stops:g,reverse:v}}}function v(){if(p(a)){var e=p(u);return e=e.replace(/^['"]+|["']+$/g,""),p(l),{type:"url",url:e}}}var _,b=e;return We(h,b)?h[b]:((_=p(t))?_=g(_):(_=p(d))&&(_=v()),
h[b]=_||{type:"none"})}var t=/^((-webkit-|-moz-|-o-|-ms-)?linear-gradient\s*)\(/,n=/^([-0-9.]+%)/,i=/^([-0-9.]+px)/,o=/^(left|right|top|bottom|to|center)\W/,r=/^([-0-9.]+(deg|grad|rad|turn))/,s=/^(\s+)/,a=/^(\()/,l=/^(\))/,c=/^(,)/,d=/^(url)\(/,u=/^(.*?)\)/,h={},f={};return function(t){return We(f,t)?f[t]:f[t]=So(t).map(e)}}(),So=function(){var e={};return function(t,n){function i(e){return u=e.exec(t.substr(l))}function o(e){return e.replace(/^\s+|\s+$/g,"")}var r,s,a,l,c,d,u;if(n||(n=/^\s*,\s*/),r=t+n,We(e,r))return e[r];for(s=[],a=0,l=0,c=0,d=!1;l<t.length;)!d&&i(/^[\(\[\{]/)?(c++,l++):!d&&i(/^[\)\]\}]/)?(c--,l++):!d&&i(/^[\"\']/)?(d=u[0],l++):"'"==d&&i(/^\\\'/)?l+=2:'"'==d&&i(/^\\\"/)?l+=2:"'"==d&&i(/^\'/)?(d=!1,l++):'"'==d&&i(/^\"/)?(d=!1,l++):i(n)?(!d&&!c&&l>a&&(s.push(o(t.substring(a,l))),a=l+u[0].length),l+=u[0].length):l++;return a<l&&s.push(o(t.substring(a,l))),e[r]=s}}(),To=function(e){return function(t){var n,i=e[t];return i||((n=/url\((['"]?)([^'")]*?)\1\)\s+format\((['"]?)truetype\3\)/.exec(t))?i=e[t]=n[2]:(n=/url\((['"]?)([^'")]*?\.ttf)\1\)/.exec(t))&&(i=e[t]=n[2])),i}}(Object.create?Object.create(null):{}),Do=function(e){return function(t){var n=e[t];return null==n&&(n=e[t]=qt.measureText("Mapq",{font:t}).height),n}}(Object.create?Object.create(null):{}),Ao={svg:Yi,canvas:go,util:on,PathParser:ci,Surface:hi,BaseNode:fi,SurfaceFactory:di,OptionsStore:sn,exportImage:Fe,exportSVG:ze,QuadNode:to,ShapesQuadTree:ro,ObserversMixin:Yt,Element:hn,Circle:wn,Arc:Ln,Path:Pn,MultiPath:Hn,Text:Vn,Image:Un,Group:qn,Layout:Gn,Rect:$n,align:te,vAlign:ne,stack:re,vStack:se,wrap:ce,vWrap:de,fit:ue,LinearGradient:Xn,RadialGradient:Zn,GradientStop:Kn,Gradient:Qn,Animation:ti,AnimationFactory:ni,drawDOM:Ve},kendo.deepExtend(kendo,{drawing:Ao,geometry:$i}),kendo.drawing.Segment=kendo.geometry.Segment,kendo.dataviz.drawing=kendo.drawing,kendo.dataviz.geometry=kendo.geometry,kendo.drawing.util.measureText=kendo.util.measureText,kendo.drawing.util.objectKey=kendo.util.objectKey,kendo.drawing.Color=kendo.Color,kendo.util.encodeBase64=kendo.drawing.util.encodeBase64}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.popup.min",["kendo.core.min"],e)}(function(){return function(e,t){function n(t,n){return!(!t||!n)&&(t===n||e.contains(t,n))}var i,o,r,s=window.kendo,a=s.ui,l=a.Widget,c=s.Class,d=s.support,u=s.getOffset,h=s._outerWidth,f=s._outerHeight,p="open",m="close",g="deactivate",v="activate",_="center",b="left",w="right",y="top",k="bottom",x="absolute",C="hidden",S="body",T="location",D="position",A="visible",E="effects",M="k-state-active",I="k-state-border",R=/k-state-border-(\w+)/,F=".k-picker-wrap, .k-dropdown-wrap, .k-link",z="down",P=e(document.documentElement),B=e.proxy,L=e(window),H="scroll",N=d.transitions.css,O=N+"transform",V=e.extend,U=".kendoPopup",W=["font-size","font-family","font-stretch","font-style","font-weight","line-height"],q=l.extend({init:function(t,n){var i,o=this;n=n||{},n.isRtl&&(n.origin=n.origin||k+" "+w,n.position=n.position||y+" "+w),l.fn.init.call(o,t,n),t=o.element,n=o.options,o.collisions=n.collision?n.collision.split(" "):[],o.downEvent=s.applyEventMap(z,s.guid()),1===o.collisions.length&&o.collisions.push(o.collisions[0]),i=e(o.options.anchor).closest(".k-popup,.k-group").filter(":not([class^=km-])"),n.appendTo=e(e(n.appendTo)[0]||i[0]||document.body),o.element.hide().addClass("k-popup k-group k-reset").toggleClass("k-rtl",!!n.isRtl).css({position:x}).appendTo(n.appendTo).on("mouseenter"+U,function(){o._hovered=!0}).on("mouseleave"+U,function(){o._hovered=!1}),o.wrapper=e(),n.animation===!1&&(n.animation={open:{effects:{}},close:{hide:!0,effects:{}}}),V(n.animation.open,{complete:function(){o.wrapper.css({overflow:A}),o._activated=!0,o._trigger(v)}}),V(n.animation.close,{complete:function(){o._animationClose()}}),o._mousedownProxy=function(e){o._mousedown(e)},o._resizeProxy=d.mobileOS.android?function(e){setTimeout(function(){o._resize(e)},600)}:function(e){o._resize(e)},n.toggleTarget&&e(n.toggleTarget).on(n.toggleEvent+U,e.proxy(o.toggle,o))},events:[p,v,m,g],options:{name:"Popup",toggleEvent:"click",origin:k+" "+b,position:y+" "+b,anchor:S,appendTo:null,collision:"flip fit",viewport:window,copyAnchorStyles:!0,autosize:!1,modal:!1,adjustSize:{width:0,height:0},animation:{open:{effects:"slideIn:down",transition:!0,duration:200},close:{duration:100,hide:!0}}},_animationClose:function(){var e=this,t=e.wrapper.data(T);e.wrapper.hide(),t&&e.wrapper.css(t),e.options.anchor!=S&&e._hideDirClass(),e._closing=!1,e._trigger(g)},destroy:function(){var t,n=this,i=n.options,o=n.element.off(U);l.fn.destroy.call(n),i.toggleTarget&&e(i.toggleTarget).off(U),i.modal||(P.unbind(n.downEvent,n._mousedownProxy),n._toggleResize(!1)),s.destroy(n.element.children()),o.removeData(),i.appendTo[0]===document.body&&(t=o.parent(".k-animation-container"),t[0]?t.remove():o.remove())},open:function(t,n){var i,o,r=this,a={isFixed:!isNaN(parseInt(n,10)),x:t,y:n},l=r.element,c=r.options,u=e(c.anchor),h=l[0]&&l.hasClass("km-widget");if(!r.visible()){if(c.copyAnchorStyles&&(h&&"font-size"==W[0]&&W.shift(),l.css(s.getComputedStyles(u[0],W))),l.data("animating")||r._trigger(p))return;r._activated=!1,c.modal||(P.unbind(r.downEvent,r._mousedownProxy).bind(r.downEvent,r._mousedownProxy),r._toggleResize(!1),r._toggleResize(!0)),r.wrapper=o=s.wrap(l,c.autosize).css({overflow:C,display:"block",position:x}),d.mobileOS.android&&o.css(O,"translatez(0)"),o.css(D),e(c.appendTo)[0]==document.body&&o.css(y,"-10000px"),r.flipped=r._position(a),i=r._openAnimation(),c.anchor!=S&&r._showDirClass(i),l.data(E,i.effects).kendoStop(!0).kendoAnimate(i)}},_location:function(t){var n,i,o=this,r=o.element,a=o.options,l=e(a.anchor),c=r[0]&&r.hasClass("km-widget");return a.copyAnchorStyles&&(c&&"font-size"==W[0]&&W.shift(),r.css(s.getComputedStyles(l[0],W))),o.wrapper=n=s.wrap(r,a.autosize).css({overflow:C,display:"block",position:x}),d.mobileOS.android&&n.css(O,"translatez(0)"),n.css(D),e(a.appendTo)[0]==document.body&&n.css(y,"-10000px"),o._position(t||{}),i=n.offset(),{width:s._outerWidth(n),height:s._outerHeight(n),left:i.left,top:i.top}},_openAnimation:function(){var e=V(!0,{},this.options.animation.open);return e.effects=s.parseEffects(e.effects,this.flipped),e},_hideDirClass:function(){var t=e(this.options.anchor),n=((t.attr("class")||"").match(R)||["","down"])[1],i=I+"-"+n;t.removeClass(i).children(F).removeClass(M).removeClass(i),this.element.removeClass(I+"-"+s.directions[n].reverse)},_showDirClass:function(t){var n=t.effects.slideIn?t.effects.slideIn.direction:"down",i=I+"-"+n;e(this.options.anchor).addClass(i).children(F).addClass(M).addClass(i),this.element.addClass(I+"-"+s.directions[n].reverse)},position:function(){this.visible()&&(this.flipped=this._position())},toggle:function(){var e=this;e[e.visible()?m:p]()},visible:function(){return this.element.is(":"+A)},close:function(n){var i,o,r,a,l=this,c=l.options;if(l.visible()){if(i=l.wrapper[0]?l.wrapper:s.wrap(l.element).hide(),l._toggleResize(!1),l._closing||l._trigger(m))return l._toggleResize(!0),t;l.element.find(".k-popup").each(function(){var t=e(this),i=t.data("kendoPopup");i&&i.close(n)}),P.unbind(l.downEvent,l._mousedownProxy),n?o={hide:!0,effects:{}}:(o=V(!0,{},c.animation.close),r=l.element.data(E),a=o.effects,!a&&!s.size(a)&&r&&s.size(r)&&(o.effects=r,o.reverse=!0),l._closing=!0),l.element.kendoStop(!0),i.css({overflow:C}),l.element.kendoAnimate(o),n&&l._animationClose()}},_trigger:function(e){return this.trigger(e,{type:e})},_resize:function(e){var t=this;d.resize.indexOf(e.type)!==-1?(clearTimeout(t._resizeTimeout),t._resizeTimeout=setTimeout(function(){t._position(),t._resizeTimeout=null},50)):(!t._hovered||t._activated&&t.element.hasClass("k-list-container"))&&t.close()},_toggleResize:function(e){var t=e?"on":"off",n=d.resize;d.mobileOS.ios||d.mobileOS.android||(n+=" "+H),this._scrollableParents()[t](H,this._resizeProxy),L[t](n,this._resizeProxy)},_mousedown:function(t){var i=this,o=i.element[0],r=i.options,a=e(r.anchor)[0],l=r.toggleTarget,c=s.eventTarget(t),d=e(c).closest(".k-popup"),u=d.parent().parent(".km-shim").length;d=d[0],!u&&d&&d!==i.element[0]||"popover"!==e(t.target).closest("a").data("rel")&&(n(o,c)||n(a,c)||l&&n(e(l)[0],c)||i.close())},_fit:function(e,t,n){var i=0;return e+t>n&&(i=n-(e+t)),e<0&&(i=-e),i},_flip:function(e,t,n,i,o,r,s){var a=0;return s=s||t,r!==o&&r!==_&&o!==_&&(e+s>i&&(a+=-(n+t)),e+a<0&&(a+=n+t)),a},_scrollableParents:function(){return e(this.options.anchor).parentsUntil("body").filter(function(e,t){return s.isScrollable(t)})},_position:function(t){var n,i,o,r,a,l,c,p,m,g,v,_,b,w,y,k,C,S=this,A=S.element,E=S.wrapper,M=S.options,I=e(M.viewport),R=d.zoomLevel(),F=!!(I[0]==window&&window.innerWidth&&R<=1.02),z=e(M.anchor),P=M.origin.toLowerCase().split(" "),B=M.position.toLowerCase().split(" "),L=S.collisions,H=10002,N=0,O=document.documentElement;if(a=M.viewport===window?{top:window.pageYOffset||document.documentElement.scrollTop||0,left:window.pageXOffset||document.documentElement.scrollLeft||0}:I.offset(),F?(l=window.innerWidth,c=window.innerHeight):(l=I.width(),c=I.height()),F&&O.scrollHeight-O.clientHeight>0&&(p=M.isRtl?-1:1,l-=p*s.support.scrollbar()),n=z.parents().filter(E.siblings()),n[0])if(o=Math.max(+n.css("zIndex"),0))H=o+10;else for(i=z.parentsUntil(n),r=i.length;N<r;N++)o=+e(i[N]).css("zIndex"),o&&H<o&&(H=o+10);return E.css("zIndex",H),E.css(t&&t.isFixed?{left:t.x,top:t.y}:S._align(P,B)),m=u(E,D,z[0]===E.offsetParent()[0]),g=u(E),v=z.offsetParent().parent(".k-animation-container,.k-popup,.k-group"),v.length&&(m=u(E,D,!0),g=u(E)),g.top-=a.top,g.left-=a.left,S.wrapper.data(T)||E.data(T,V({},m)),_=V({},g),b=V({},m),w=M.adjustSize,"fit"===L[0]&&(b.top+=S._fit(_.top,f(E)+w.height,c/R)),"fit"===L[1]&&(b.left+=S._fit(_.left,h(E)+w.width,l/R)),y=V({},b),k=f(A),C=f(E),!E.height()&&k&&(C+=k),"flip"===L[0]&&(b.top+=S._flip(_.top,k,f(z),c/R,P[0],B[0],C)),"flip"===L[1]&&(b.left+=S._flip(_.left,h(A),h(z),l/R,P[1],B[1],h(E))),A.css(D,x),E.css(b),b.left!=y.left||b.top!=y.top},_align:function(t,n){var i,o=this,r=o.wrapper,s=e(o.options.anchor),a=t[0],l=t[1],c=n[0],d=n[1],p=u(s),m=e(o.options.appendTo),g=h(r),v=f(r),b=h(s),y=f(s),x=p.top,C=p.left,S=Math.round;return m[0]!=document.body&&(i=u(m),x-=i.top,C-=i.left),a===k&&(x+=y),a===_&&(x+=S(y/2)),c===k&&(x-=v),c===_&&(x-=S(v/2)),l===w&&(C+=b),l===_&&(C+=S(b/2)),d===w&&(C-=g),d===_&&(C-=S(g/2)),{top:x,left:C}}});a.plugin(q),i="kendoTabKeyTrap",o="a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), iframe, object, embed, [tabindex], *[contenteditable]",r=c.extend({init:function(t){this.element=e(t),this.element.autoApplyNS(i)},trap:function(){this.element.on("keydown",B(this._keepInTrap,this))},removeTrap:function(){this.element.kendoDestroy(i)},destroy:function(){this.element.kendoDestroy(i),this.element=t},shouldTrap:function(){return!0},_keepInTrap:function(e){var t,n,i,r,s,a;9===e.which&&this.shouldTrap()&&(t=e.target,n=this.element.find(o).filter(":visible[tabindex!=-1]"),i=n.sort(function(e,t){return e.tabIndex-t.tabIndex}),r=i.length,s=r-1,a=i.index(t),e.shiftKey?0===a?i.get(s).focus():i.get(a-1).focus():a===s?i.get(0).focus():i.get(a+1).focus(),e.preventDefault())}}),a.Popup.TabKeyTrap=r}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("drawing/surface-tooltip.min",["kendo.popup.min","drawing/kendo-drawing.min"],e)}(function(){!function(e){var t=".kendo",n=window.kendo,i=n.deepExtend,o=n.drawing.util,r=o.defined,s=o.limitValue,a=o.eventCoordinates,l=n._outerWidth,c=n._outerHeight,d=e.proxy,u='<div class="k-tooltip"><div class="k-tooltip-content"></div></div>',h='<div class="k-tooltip-button"><a href="\\#" class="k-icon k-i-close">close</a></div>',f=n.Class.extend({init:function(t,n){this.element=e(u),this.content=this.element.children(".k-tooltip-content"),n=n||{},this.options=i({},this.options,this._tooltipOptions(n)),this.popupOptions={appendTo:n.appendTo,animation:n.animation,copyAnchorStyles:!1,collision:"fit fit"},this._openPopupHandler=e.proxy(this._openPopup,this),this.surface=t,this._bindEvents()},options:{position:"top",showOn:"mouseenter",offset:7,autoHide:!0,hideDelay:0,showAfter:100},_bindEvents:function(){this._showHandler=d(this._showEvent,this),this._surfaceLeaveHandler=d(this._surfaceLeave,this),this._mouseleaveHandler=d(this._mouseleave,this),this._mousemoveHandler=d(this._mousemove,this),this.surface.bind("click",this._showHandler),this.surface.bind("mouseenter",this._showHandler),this.surface.bind("mouseleave",this._mouseleaveHandler),this.surface.bind("mousemove",this._mousemoveHandler),this.surface.element.on("mouseleave"+t,this._surfaceLeaveHandler),this.element.on("click"+t,".k-tooltip-button",d(this._hideClick,this))},getPopup:function(){return this.popup||(this.popup=new n.ui.Popup(this.element,this.popupOptions)),this.popup},destroy:function(){var e=this.popup;this.surface.unbind("click",this._showHandler),this.surface.unbind("mouseenter",this._showHandler),this.surface.unbind("mouseleave",this._mouseleaveHandler),this.surface.unbind("mousemove",this._mousemoveHandler),this.surface.element.off("mouseleave"+t,this._surfaceLeaveHandler),this.element.off("click"+t),e&&(e.destroy(),delete this.popup),delete this.popupOptions,clearTimeout(this._timeout),delete this.element,delete this.content,delete this.surface},_tooltipOptions:function(e){return e=e||{},{position:e.position,showOn:e.showOn,offset:e.offset,autoHide:e.autoHide,width:e.width,height:e.height,content:e.content,shared:e.shared,hideDelay:e.hideDelay,showAfter:e.showAfter}},_tooltipShape:function(e){for(;e&&!e.options.tooltip;)e=e.parent;return e},_updateContent:function(e,t,i){var o=i.content;if(n.isFunction(o)&&(o=o({element:t,target:e})),o)return this.content.html(o),!0},_position:function(e,t,n,i){var o,r=t.position,l=t.offset||0,c=this.surface,d=c._instance._elementOffset(),u=c.getSize(),h=c._instance._offset,f=e.bbox(),p=n.width,m=n.height,g=0,v=0;return f.origin.translate(d.left,d.top),h&&f.origin.translate(-h.x,-h.y),"cursor"==r&&i?(o=a(i),g=o.x-p/2,v=o.y-m-l):"left"==r?(g=f.origin.x-p-l,v=f.center().y-m/2):"right"==r?(g=f.bottomRight().x+l,v=f.center().y-m/2):"bottom"==r?(g=f.center().x-p/2,v=f.bottomRight().y+l):(g=f.center().x-p/2,v=f.origin.y-m-l),{left:s(g,d.left,d.left+u.width),top:s(v,d.top,d.top+u.height)}},show:function(e,t){this._show(e,e,i({},this.options,this._tooltipOptions(e.options.tooltip),t))},hide:function(){var e=this.popup,t=this._current;delete this._current,clearTimeout(this._showTimeout),e&&e.visible()&&t&&!this.surface.trigger("tooltipClose",{element:t.shape,target:t.target,popup:e})&&e.close()},_hideClick:function(e){e.preventDefault(),this.hide()},_show:function(e,t,n,i,o){var r,s,a=this._current;clearTimeout(this._timeout),a&&(a.shape===t&&n.shared||a.target===e)||(clearTimeout(this._showTimeout),r=this.getPopup(),!this.surface.trigger("tooltipOpen",{element:t,target:e,popup:r})&&this._updateContent(e,t,n)&&(this._autoHide(n),s=this._measure(n),r.visible()&&r.close(!0),this._current={options:n,elementSize:s,shape:t,target:e,position:this._position(n.shared?t:e,n,s,i)},o?this._showTimeout=setTimeout(this._openPopupHandler,n.showAfter||0):this._openPopup()))},_openPopup:function(){var e=this._current,t=e.position;this.getPopup().open(t.left,t.top)},_autoHide:function(t){t.autoHide&&this._closeButton&&(this.element.removeClass("k-tooltip-closable"),this._closeButton.remove(),delete this._closeButton),t.autoHide||this._closeButton||(this.element.addClass("k-tooltip-closable"),this._closeButton=e(h).prependTo(this.element))},_showEvent:function(e){var t,n=this._tooltipShape(e.element);n&&(t=i({},this.options,this._tooltipOptions(n.options.tooltip)),t&&t.showOn==e.type&&this._show(e.element,n,t,e.originalEvent,!0))},_measure:function(e){var t,n,i,o=this.getPopup();return this.element.css({width:"auto",height:"auto"}),i=o.visible(),i||o.wrapper.show(),this.element.css({width:r(e.width)?e.width:"auto",height:r(e.height)?e.height:"auto"}),t=l(this.element),n=c(this.element),i||o.wrapper.hide(),{width:t,height:n}},_mouseleave:function(e){var t,n;this.popup&&!this._popupRelatedTarget(e.originalEvent)&&(t=this,n=t._current,n&&n.options.autoHide&&(t._timeout=setTimeout(function(){clearTimeout(t._showTimeout),t.hide()},n.options.hideDelay||0)))},_mousemove:function(e){var t,n,i=this._current;i&&e.element&&(t=i.options,"cursor"==t.position&&(n=this._position(e.element,t,i.elementSize,e.originalEvent),i.position=n,this.getPopup().wrapper.css({left:n.left,top:n.top})))},_surfaceLeave:function(e){this.popup&&!this._popupRelatedTarget(e)&&(clearTimeout(this._showTimeout),this.hide())},_popupRelatedTarget:function(t){return t.relatedTarget&&e(t.relatedTarget).closest(this.popup.wrapper).length}});n.drawing.SurfaceTooltip=f}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("drawing/surface.min",["drawing/kendo-drawing.min","drawing/surface-tooltip.min"],e)}(function(){!function(e){function t(e){this._instance.translate(e)}var n,i=window.kendo,o=i.drawing,r=o.Surface,s=i.ui.Widget,a=i.deepExtend,l=e.proxy;i.support.svg=r.support.svg,i.support.canvas=r.support.canvas,n=s.extend({init:function(e,n){this.options=a({},this.options,n),s.fn.init.call(this,e,this.options),this._instance=r.create(this.element[0],n),this._instance.translate&&(this.translate=t),this._triggerInstanceHandler=l(this._triggerInstanceEvent,this),this._bindHandler("click"),this._bindHandler("mouseenter"),this._bindHandler("mouseleave"),this._bindHandler("mousemove"),this._enableTracking()},options:{name:"Surface",tooltip:{}},events:["click","mouseenter","mouseleave","mousemove","resize","tooltipOpen","tooltipClose"],_triggerInstanceEvent:function(e){this.trigger(e.type,e)},_bindHandler:function(e){this._instance.bind(e,this._triggerInstanceHandler)},draw:function(e){this._instance.draw(e)},clear:function(){this._instance&&this._instance.clear(),this.hideTooltip()},destroy:function(){this._instance&&(this._instance.destroy(),delete this._instance),this._tooltip&&(this._tooltip.destroy(),delete this._tooltip),s.fn.destroy.call(this)},exportVisual:function(){return this._instance.exportVisual()},eventTarget:function(e){return this._instance.eventTarget(e)},showTooltip:function(e,t){this._tooltip&&this._tooltip.show(e,t)},hideTooltip:function(){this._tooltip&&this._tooltip.hide()},suspendTracking:function(){this._instance.suspendTracking(),this.hideTooltip()},resumeTracking:function(){this._instance.resumeTracking()},getSize:function(){return{width:this.element.width(),height:this.element.height()}},setSize:function(e){this.element.css({width:e.width,height:e.height}),this._size=e,this._instance.currentSize(e),this._resize()},_resize:function(){this._instance.currentSize(this._size),this._instance._resize()},_enableTracking:function(){i.ui.Popup&&(this._tooltip=new o.SurfaceTooltip(this,this.options.tooltip||{}))}}),i.ui.plugin(n),n.create=function(e,t){return new n(e,t)},i.drawing.Surface=n}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("drawing/html.min",["drawing/kendo-drawing.min"],e)}(function(){!function(e){var t=window.kendo,n=t.drawing,i=n.drawDOM;n.drawDOM=function(t,n){return i(e(t)[0],n)},n.drawDOM.drawText=i.drawText,n.drawDOM.getFontFaces=i.getFontFaces}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.drawing.min",["drawing/util.min","drawing/kendo-drawing.min","drawing/surface-tooltip.min","drawing/surface.min","drawing/html.min"],e)}(function(){},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.validator.min",["kendo.core.min"],e)}(function(){return function(e,t){function n(t){var n,i=l.ui.validator.ruleResolvers||{},o={};for(n in i)e.extend(!0,o,i[n].resolve(t));return o}function i(e){return e.replace(/&amp/g,"&amp;").replace(/&quot;/g,'"').replace(/&#39;/g,"'").replace(/&lt;/g,"<").replace(/&gt;/g,">")}function o(e){return e=(e+"").split("."),e.length>1?e[1].length:0}function r(t){return e(e.parseHTML?e.parseHTML(t):t)}function s(t,n){var i,o,r,s,a=e();for(r=0,s=t.length;r<s;r++)i=t[r],h.test(i.className)&&(o=i.getAttribute(l.attr("for")),o===n&&(a=a.add(i)));return a}var a,l=window.kendo,c=l.ui.Widget,d=".kendoValidator",u="k-invalid-msg",h=RegExp(u,"i"),f="k-invalid",p="k-valid",m=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/i,g=/^(https?|ftp):\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,v=":input:not(:button,[type=submit],[type=reset],[disabled],[readonly])",_=":checkbox:not([disabled],[readonly])",b="[type=number],[type=range]",w="blur",y="name",k="form",x="novalidate",C="validate",S="change",T="validateInput",D=e.proxy,A=function(e,t){return"string"==typeof t&&(t=RegExp("^(?:"+t+")$")),t.test(e)},E=function(e,t,n){var i=e.val();return!e.filter(t).length||""===i||A(i,n)},M=function(e,t){return!!e.length&&null!=e[0].attributes[t]};l.ui.validator||(l.ui.validator={rules:{},messages:{}}),a=c.extend({init:function(t,i){var o=this,r=n(t),s="["+l.attr("validate")+"!=false]";i=i||{},i.rules=e.extend({},l.ui.validator.rules,r.rules,i.rules),i.messages=e.extend({},l.ui.validator.messages,r.messages,i.messages),c.fn.init.call(o,t,i),o._errorTemplate=l.template(o.options.errorTemplate),o.element.is(k)&&o.element.attr(x,x),o._inputSelector=v+s,o._checkboxSelector=_+s,o._errors={},o._attachEvents(),o._isValidated=!1},events:[C,S,T],options:{name:"Validator",errorTemplate:'<span class="k-widget k-tooltip k-tooltip-validation"><span class="k-icon k-i-warning"> </span> #=message#</span>',messages:{required:"{0} is required",pattern:"{0} is not valid",min:"{0} should be greater than or equal to {1}",max:"{0} should be smaller than or equal to {1}",step:"{0} is not valid",email:"{0} is not valid email",url:"{0} is not valid URL",date:"{0} is not valid date",dateCompare:"End date should be greater than or equal to the start date"},rules:{required:function(e){var t=e.filter("[type=checkbox]").length&&!e.is(":checked"),n=e.val();return!(M(e,"required")&&(!n||""===n||0===n.length||t))},pattern:function(e){return!e.filter("[type=text],[type=email],[type=url],[type=tel],[type=search],[type=password]").filter("[pattern]").length||""===e.val()||A(e.val(),e.attr("pattern"))},min:function(e){if(e.filter(b+",["+l.attr("type")+"=number]").filter("[min]").length&&""!==e.val()){var t=parseFloat(e.attr("min"))||0,n=l.parseFloat(e.val());return t<=n}return!0},max:function(e){if(e.filter(b+",["+l.attr("type")+"=number]").filter("[max]").length&&""!==e.val()){var t=parseFloat(e.attr("max"))||0,n=l.parseFloat(e.val());return t>=n}return!0},step:function(e){if(e.filter(b+",["+l.attr("type")+"=number]").filter("[step]").length&&""!==e.val()){var t,n=parseFloat(e.attr("min"))||0,i=parseFloat(e.attr("step"))||1,r=parseFloat(e.val()),s=o(i);return s?(t=Math.pow(10,s),Math.floor((r-n)*t)%(i*t)/Math.pow(100,s)===0):(r-n)%i===0}return!0},email:function(e){return E(e,"[type=email],["+l.attr("type")+"=email]",m)},url:function(e){return E(e,"[type=url],["+l.attr("type")+"=url]",g)},date:function(e){return!e.filter("[type^=date],["+l.attr("type")+"=date]").length||""===e.val()||null!==l.parseDate(e.val(),e.attr(l.attr("format")))}},validateOnBlur:!0},destroy:function(){c.fn.destroy.call(this),this.element.off(d)},value:function(){return!!this._isValidated&&0===this.errors().length},_submit:function(e){return!!this.validate()||(e.stopPropagation(),e.stopImmediatePropagation(),e.preventDefault(),!1)},_checkElement:function(e){var t=this.value();this.validateInput(e),this.value()!==t&&this.trigger(S)},_attachEvents:function(){var t=this;t.element.is(k)&&t.element.on("submit"+d,D(t._submit,t)),t.options.validateOnBlur&&(t.element.is(v)?(t.element.on(w+d,function(){t._checkElement(t.element)}),t.element.is(_)&&t.element.on("click"+d,function(){t._checkElement(t.element)})):(t.element.on(w+d,t._inputSelector,function(){t._checkElement(e(this))}),t.element.on("click"+d,t._checkboxSelector,function(){t._checkElement(e(this))})))},validate:function(){var e,t,n,i,o=!1,r=this.value();if(this._errors={},this.element.is(v))o=this.validateInput(this.element);else{for(i=!1,e=this.element.find(this._inputSelector),t=0,n=e.length;t<n;t++)this.validateInput(e.eq(t))||(i=!0);o=!i}return this.trigger(C,{valid:o}),r!==o&&this.trigger(S),o},validateInput:function(t){var n,o,s,a,c,d,h,m,g,v,_;return t=e(t),this._isValidated=!0,n=this,o=n._errorTemplate,s=n._checkValidity(t),a=s.valid,c="."+u,d=t.attr(y)||"",h=n._findMessageContainer(d).add(t.next(c).filter(function(){var t=e(this);return!t.filter("["+l.attr("for")+"]").length||t.attr(l.attr("for"))===d})).hide(),g=!t.attr("aria-invalid"),t.removeAttr("aria-invalid"),a?delete n._errors[d]:(m=n._extractMessage(t,s.key),n._errors[d]=m,v=r(o({message:i(m)})),_=h.attr("id"),n._decorateMessageContainer(v,d),_&&v.attr("id",_),h.replaceWith(v).length||v.insertAfter(t),v.show(),t.attr("aria-invalid",!0)),g!==a&&this.trigger(T,{valid:a,input:t}),t.toggleClass(f,!a),t.toggleClass(p,a),a},hideMessages:function(){var e=this,t="."+u,n=e.element;n.is(v)?n.next(t).hide():n.find(t).hide()},_findMessageContainer:function(t){var n,i,o,r=l.ui.validator.messageLocators,a=e();for(i=0,o=this.element.length;i<o;i++)a=a.add(s(this.element[i].getElementsByTagName("*"),t));for(n in r)a=a.add(r[n].locate(this.element,t));return a},_decorateMessageContainer:function(e,t){var n,i=l.ui.validator.messageLocators;e.addClass(u).attr(l.attr("for"),t||"");for(n in i)i[n].decorate(e,t);e.attr("role","alert")},_extractMessage:function(e,t){var n=this,i=n.options.messages[t],o=e.attr(y);return i=l.isFunction(i)?i(e):i,l.format(e.attr(l.attr(t+"-msg"))||e.attr("validationMessage")||e.attr("title")||i||"",o,e.attr(t)||e.attr(l.attr(t)))},_checkValidity:function(e){var t,n=this.options.rules;for(t in n)if(!n[t].call(this,e))return{valid:!1,key:t};return{valid:!0}},errors:function(){var e,t=[],n=this._errors;for(e in n)t.push(n[e]);return t}}),l.ui.plugin(a)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.userevents.min",["kendo.core.min"],e)}(function(){return function(e,t){function n(e,t){var n=e.x.location,i=e.y.location,o=t.x.location,r=t.y.location,s=n-o,a=i-r;return{center:{x:(n+o)/2,y:(i+r)/2},distance:Math.sqrt(s*s+a*a)}}function i(e){var t,n,i,o=[],r=e.originalEvent,a=e.currentTarget,l=0;if(e.api)o.push({id:2,event:e,target:e.target,currentTarget:e.target,location:e,type:"api"});else if(e.type.match(/touch/))for(n=r?r.changedTouches:[],t=n.length;l<t;l++)i=n[l],o.push({location:i,event:e,target:i.target,currentTarget:a,id:i.identifier,type:"touch"});else o.push(s.pointers||s.msPointers?{location:r,event:e,target:e.target,currentTarget:a,id:r.pointerId,type:"pointer"}:{id:1,event:e,target:e.target,currentTarget:a,location:e,type:"mouse"});return o}function o(e){for(var t=r.eventMap.up.split(" "),n=0,i=t.length;n<i;n++)e(t[n])}var r=window.kendo,s=r.support,a=r.Class,l=r.Observable,c=e.now,d=e.extend,u=s.mobileOS,h=u&&u.android,f=800,p=s.browser.msie?5:0,m="press",g="hold",v="select",_="start",b="move",w="end",y="cancel",k="tap",x="release",C="gesturestart",S="gesturechange",T="gestureend",D="gesturetap",A={api:0,touch:0,mouse:9,pointer:9},E=!s.touch||s.mouseAndTouchPresent,M=a.extend({init:function(e,t){var n=this;n.axis=e,n._updateLocationData(t),n.startLocation=n.location,n.velocity=n.delta=0,n.timeStamp=c()},move:function(e){var t=this,n=e["page"+t.axis],i=c(),o=i-t.timeStamp||1;!n&&h||(t.delta=n-t.location,t._updateLocationData(e),t.initialDelta=n-t.startLocation,t.velocity=t.delta/o,t.timeStamp=i)},_updateLocationData:function(e){var t=this,n=t.axis;t.location=e["page"+n],t.client=e["client"+n],t.screen=e["screen"+n]}}),I=a.extend({init:function(e,t,n){d(this,{x:new M("X",n.location),y:new M("Y",n.location),type:n.type,useClickAsTap:e.useClickAsTap,threshold:e.threshold||A[n.type],userEvents:e,target:t,currentTarget:n.currentTarget,initialTouch:n.target,id:n.id,pressEvent:n,_moved:!1,_finished:!1})},press:function(){this._holdTimeout=setTimeout(e.proxy(this,"_hold"),this.userEvents.minHold),this._trigger(m,this.pressEvent)},_hold:function(){this._trigger(g,this.pressEvent)},move:function(e){var t=this;if(!t._finished){if(t.x.move(e.location),t.y.move(e.location),!t._moved){if(t._withinIgnoreThreshold())return;if(R.current&&R.current!==t.userEvents)return t.dispose();t._start(e)}t._finished||t._trigger(b,e)}},end:function(e){this.endTime=c(),this._finished||(this._finished=!0,this._trigger(x,e),this._moved?this._trigger(w,e):this.useClickAsTap||this._trigger(k,e),clearTimeout(this._holdTimeout),this.dispose())},dispose:function(){var t=this.userEvents,n=t.touches;this._finished=!0,this.pressEvent=null,clearTimeout(this._holdTimeout),n.splice(e.inArray(this,n),1)},skip:function(){this.dispose()},cancel:function(){this.dispose()},isMoved:function(){return this._moved},_start:function(e){clearTimeout(this._holdTimeout),this.startTime=c(),this._moved=!0,this._trigger(_,e)},_trigger:function(e,t){var n=this,i=t.event,o={touch:n,x:n.x,y:n.y,target:n.target,event:i};n.userEvents.notify(e,o)&&i.preventDefault()},_withinIgnoreThreshold:function(){var e=this.x.initialDelta,t=this.y.initialDelta;return Math.sqrt(e*e+t*t)<=this.threshold}}),R=l.extend({init:function(t,n){var i,a,c,u=this,h=r.guid();n=n||{},i=u.filter=n.filter,u.threshold=n.threshold||p,u.minHold=n.minHold||f,u.touches=[],u._maxTouches=n.multiTouch?2:1,u.allowSelection=n.allowSelection,u.captureUpIfMoved=n.captureUpIfMoved,u.useClickAsTap=!n.fastTap&&!s.delayedClick(),u.eventNS=h,t=e(t).handler(u),l.fn.init.call(u),d(u,{element:t,surface:e(n.global&&E?t[0].ownerDocument.documentElement:n.surface||t),stopPropagation:n.stopPropagation,pressed:!1}),u.surface.handler(u).on(r.applyEventMap("move",h),"_move").on(r.applyEventMap("up cancel",h),"_end"),t.on(r.applyEventMap("down",h),i,"_start"),u.useClickAsTap&&t.on(r.applyEventMap("click",h),i,"_click"),(s.pointers||s.msPointers)&&(s.browser.version<11?t.css("-ms-touch-action","pinch-zoom double-tap-zoom"):t.css("touch-action",n.touchAction||"none")),n.preventDragEvent&&t.on(r.applyEventMap("dragstart",h),r.preventDefault),t.on(r.applyEventMap("mousedown",h),i,{root:t},"_select"),u.captureUpIfMoved&&s.eventCapture&&(a=u.surface[0],c=e.proxy(u.preventIfMoving,u),o(function(e){a.addEventListener(e,c,!0)})),u.bind([m,g,k,_,b,w,x,y,C,S,T,D,v],n)},preventIfMoving:function(e){this._isMoved()&&e.preventDefault()},destroy:function(){var e,t=this;
t._destroyed||(t._destroyed=!0,t.captureUpIfMoved&&s.eventCapture&&(e=t.surface[0],o(function(n){e.removeEventListener(n,t.preventIfMoving)})),t.element.kendoDestroy(t.eventNS),t.surface.kendoDestroy(t.eventNS),t.element.removeData("handler"),t.surface.removeData("handler"),t._disposeAll(),t.unbind(),delete t.surface,delete t.element,delete t.currentTarget)},capture:function(){R.current=this},cancel:function(){this._disposeAll(),this.trigger(y)},notify:function(e,t){var i=this,o=i.touches;if(this._isMultiTouch()){switch(e){case b:e=S;break;case w:e=T;break;case k:e=D}d(t,{touches:o},n(o[0],o[1]))}return this.trigger(e,d(t,{type:e}))},press:function(e,t,n){this._apiCall("_start",e,t,n)},move:function(e,t){this._apiCall("_move",e,t)},end:function(e,t){this._apiCall("_end",e,t)},_isMultiTouch:function(){return this.touches.length>1},_maxTouchesReached:function(){return this.touches.length>=this._maxTouches},_disposeAll:function(){for(var e=this.touches;e.length>0;)e.pop().dispose()},_isMoved:function(){return e.grep(this.touches,function(e){return e.isMoved()}).length},_select:function(e){this.allowSelection&&!this.trigger(v,{event:e})||e.preventDefault()},_start:function(t){var n,o,r=this,s=0,a=r.filter,l=i(t),c=l.length,d=t.which;if(!(d&&d>1||r._maxTouchesReached()))for(R.current=null,r.currentTarget=t.currentTarget,r.stopPropagation&&t.stopPropagation();s<c&&!r._maxTouchesReached();s++)o=l[s],n=a?e(o.currentTarget):r.element,n.length&&(o=new I(r,n,o),r.touches.push(o),o.press(),r._isMultiTouch()&&r.notify("gesturestart",{}))},_move:function(e){this._eachTouch("move",e)},_end:function(e){this._eachTouch("end",e)},_click:function(t){var n={touch:{initialTouch:t.target,target:e(t.currentTarget),endTime:c(),x:{location:t.pageX,client:t.clientX},y:{location:t.pageY,client:t.clientY}},x:t.pageX,y:t.pageY,target:e(t.currentTarget),event:t,type:"tap"};this.trigger("tap",n)&&t.preventDefault()},_eachTouch:function(e,t){var n,o,r,s,a=this,l={},c=i(t),d=a.touches;for(n=0;n<d.length;n++)o=d[n],l[o.id]=o;for(n=0;n<c.length;n++)r=c[n],s=l[r.id],s&&s[e](r)},_apiCall:function(t,n,i,o){this[t]({api:!0,pageX:n,pageY:i,clientX:n,clientY:i,target:e(o||this.element)[0],stopPropagation:e.noop,preventDefault:e.noop})}});R.defaultThreshold=function(e){p=e},R.minHold=function(e){f=e},r.getTouches=i,r.touchDelta=n,r.UserEvents=R}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.draganddrop.min",["kendo.core.min","kendo.userevents.min"],e)}(function(){return function(e,t){function n(t,n){try{return e.contains(t,n)||t==n}catch(i){return!1}}function i(e,t){return parseInt(e.css(t),10)||0}function o(e,t){return Math.min(Math.max(e,t.min),t.max)}function r(e,t){var n=A(e),o=_._outerWidth,r=_._outerHeight,s=n.left+i(e,"borderLeftWidth")+i(e,"paddingLeft"),a=n.top+i(e,"borderTopWidth")+i(e,"paddingTop"),l=s+e.width()-o(t,!0),c=a+e.height()-r(t,!0);return{x:{min:s,max:l},y:{min:a,max:c}}}function s(n,i,o){for(var r,s,a=0,l=i&&i.length,c=o&&o.length;n&&n.parentNode;){for(a=0;a<l;a++)if(r=i[a],r.element[0]===n)return{target:r,targetElement:n};for(a=0;a<c;a++)if(s=o[a],e.contains(s.element[0],n)&&b.matchesSelector.call(n,s.options.filter))return{target:s,targetElement:n};n=n.parentNode}return t}function a(e,t){var n,i=t.options.group,o=e[i];if(x.fn.destroy.call(t),o.length>1){for(n=0;n<o.length;n++)if(o[n]==t){o.splice(n,1);break}}else o.length=0,delete e[i]}function l(e){var t,n,i,o=c()[0];return e[0]===o?(n=o.scrollTop,i=o.scrollLeft,{top:n,left:i,bottom:n+y.height(),right:i+y.width()}):(t=e.offset(),t.bottom=t.top+e.height(),t.right=t.left+e.width(),t)}function c(){return e(_.support.browser.chrome?w.body:w.documentElement)}function d(t){var n,i=c();if(!t||t===w.body||t===w.documentElement)return i;for(n=e(t)[0];n&&!_.isScrollable(n)&&n!==w.body;)n=n.parentNode;return n===w.body?i:e(n)}function u(e,t,n){var i={x:0,y:0},o=50;return e-n.left<o?i.x=-(o-(e-n.left)):n.right-e<o&&(i.x=o-(n.right-e)),t-n.top<o?i.y=-(o-(t-n.top)):n.bottom-t<o&&(i.y=o-(n.bottom-t)),i}var h,f,p,m,g,v,_=window.kendo,b=_.support,w=window.document,y=e(window),k=_.Class,x=_.ui.Widget,C=_.Observable,S=_.UserEvents,T=e.proxy,D=e.extend,A=_.getOffset,E={},M={},I={},R=_.elementUnderCursor,F="keyup",z="change",P="dragstart",B="hold",L="drag",H="dragend",N="dragcancel",O="hintDestroyed",V="dragenter",U="dragleave",W="drop",q=C.extend({init:function(t,n){var i=this,o=t[0];i.capture=!1,o.addEventListener?(e.each(_.eventMap.down.split(" "),function(){o.addEventListener(this,T(i._press,i),!0)}),e.each(_.eventMap.up.split(" "),function(){o.addEventListener(this,T(i._release,i),!0)})):(e.each(_.eventMap.down.split(" "),function(){o.attachEvent(this,T(i._press,i))}),e.each(_.eventMap.up.split(" "),function(){o.attachEvent(this,T(i._release,i))})),C.fn.init.call(i),i.bind(["press","release"],n||{})},captureNext:function(){this.capture=!0},cancelCapture:function(){this.capture=!1},_press:function(e){var t=this;t.trigger("press"),t.capture&&e.preventDefault()},_release:function(e){var t=this;t.trigger("release"),t.capture&&(e.preventDefault(),t.cancelCapture())}}),j=C.extend({init:function(t){var n=this;C.fn.init.call(n),n.forcedEnabled=!1,e.extend(n,t),n.scale=1,n.horizontal?(n.measure="offsetWidth",n.scrollSize="scrollWidth",n.axis="x"):(n.measure="offsetHeight",n.scrollSize="scrollHeight",n.axis="y")},makeVirtual:function(){e.extend(this,{virtual:!0,forcedEnabled:!0,_virtualMin:0,_virtualMax:0})},virtualSize:function(e,t){this._virtualMin===e&&this._virtualMax===t||(this._virtualMin=e,this._virtualMax=t,this.update())},outOfBounds:function(e){return e>this.max||e<this.min},forceEnabled:function(){this.forcedEnabled=!0},getSize:function(){return this.container[0][this.measure]},getTotal:function(){return this.element[0][this.scrollSize]},rescale:function(e){this.scale=e},update:function(e){var t=this,n=t.virtual?t._virtualMax:t.getTotal(),i=n*t.scale,o=t.getSize();(0!==n||t.forcedEnabled)&&(t.max=t.virtual?-t._virtualMin:0,t.size=o,t.total=i,t.min=Math.min(t.max,o-i),t.minScale=o/n,t.centerOffset=(i-o)/2,t.enabled=t.forcedEnabled||i>o,e||t.trigger(z,t))}}),G=C.extend({init:function(e){var t=this;C.fn.init.call(t),t.x=new j(D({horizontal:!0},e)),t.y=new j(D({horizontal:!1},e)),t.container=e.container,t.forcedMinScale=e.minScale,t.maxScale=e.maxScale||100,t.bind(z,e)},rescale:function(e){this.x.rescale(e),this.y.rescale(e),this.refresh()},centerCoordinates:function(){return{x:Math.min(0,-this.x.centerOffset),y:Math.min(0,-this.y.centerOffset)}},refresh:function(){var e=this;e.x.update(),e.y.update(),e.enabled=e.x.enabled||e.y.enabled,e.minScale=e.forcedMinScale||Math.min(e.x.minScale,e.y.minScale),e.fitScale=Math.max(e.x.minScale,e.y.minScale),e.trigger(z)}}),$=C.extend({init:function(e){var t=this;D(t,e),C.fn.init.call(t)},outOfBounds:function(){return this.dimension.outOfBounds(this.movable[this.axis])},dragMove:function(e){var t=this,n=t.dimension,i=t.axis,o=t.movable,r=o[i]+e;n.enabled&&((r<n.min&&e<0||r>n.max&&e>0)&&(e*=t.resistance),o.translateAxis(i,e),t.trigger(z,t))}}),Y=k.extend({init:function(t){var n,i,o,r,s=this;D(s,{elastic:!0},t),o=s.elastic?.5:0,r=s.movable,s.x=n=new $({axis:"x",dimension:s.dimensions.x,resistance:o,movable:r}),s.y=i=new $({axis:"y",dimension:s.dimensions.y,resistance:o,movable:r}),s.userEvents.bind(["press","move","end","gesturestart","gesturechange"],{gesturestart:function(e){s.gesture=e,s.offset=s.dimensions.container.offset()},press:function(t){e(t.event.target).closest("a").is("[data-navigate-on-press=true]")&&t.sender.cancel()},gesturechange:function(e){var t,o,a,l=s.gesture,c=l.center,d=e.center,u=e.distance/l.distance,h=s.dimensions.minScale,f=s.dimensions.maxScale;r.scale<=h&&u<1&&(u+=.8*(1-u)),r.scale*u>=f&&(u=f/r.scale),o=r.x+s.offset.left,a=r.y+s.offset.top,t={x:(o-c.x)*u+d.x-o,y:(a-c.y)*u+d.y-a},r.scaleWith(u),n.dragMove(t.x),i.dragMove(t.y),s.dimensions.rescale(r.scale),s.gesture=e,e.preventDefault()},move:function(e){e.event.target.tagName.match(/textarea|input/i)||(n.dimension.enabled||i.dimension.enabled?(n.dragMove(e.x.delta),i.dragMove(e.y.delta),e.preventDefault()):e.touch.skip())},end:function(e){e.preventDefault()}})}}),K=b.transitions.prefix+"Transform";f=b.hasHW3D?function(e,t,n){return"translate3d("+e+"px,"+t+"px,0) scale("+n+")"}:function(e,t,n){return"translate("+e+"px,"+t+"px) scale("+n+")"},p=C.extend({init:function(t){var n=this;C.fn.init.call(n),n.element=e(t),n.element[0].style.webkitTransformOrigin="left top",n.x=0,n.y=0,n.scale=1,n._saveCoordinates(f(n.x,n.y,n.scale))},translateAxis:function(e,t){this[e]+=t,this.refresh()},scaleTo:function(e){this.scale=e,this.refresh()},scaleWith:function(e){this.scale*=e,this.refresh()},translate:function(e){this.x+=e.x,this.y+=e.y,this.refresh()},moveAxis:function(e,t){this[e]=t,this.refresh()},moveTo:function(e){D(this,e),this.refresh()},refresh:function(){var e,t=this,n=t.x,i=t.y;t.round&&(n=Math.round(n),i=Math.round(i)),e=f(n,i,t.scale),e!=t.coordinates&&(_.support.browser.msie&&_.support.browser.version<10?(t.element[0].style.position="absolute",t.element[0].style.left=t.x+"px",t.element[0].style.top=t.y+"px"):t.element[0].style[K]=e,t._saveCoordinates(e),t.trigger(z))},_saveCoordinates:function(e){this.coordinates=e}}),m=x.extend({init:function(e,t){var n,i=this;x.fn.init.call(i,e,t),n=i.options.group,n in M?M[n].push(i):M[n]=[i]},events:[V,U,W],options:{name:"DropTarget",group:"default"},destroy:function(){a(M,this)},_trigger:function(e,t){var n=this,i=E[n.options.group];if(i)return n.trigger(e,D({},t.event,{draggable:i,dropTarget:t.dropTarget}))},_over:function(e){this._trigger(V,e)},_out:function(e){this._trigger(U,e)},_drop:function(e){var t=this,n=E[t.options.group];n&&(n.dropped=!t._trigger(W,e))}}),m.destroyGroup=function(e){var t,n=M[e]||I[e];if(n){for(t=0;t<n.length;t++)x.fn.destroy.call(n[t]);n.length=0,delete M[e],delete I[e]}},m._cache=M,g=m.extend({init:function(e,t){var n,i=this;x.fn.init.call(i,e,t),n=i.options.group,n in I?I[n].push(i):I[n]=[i]},destroy:function(){a(I,this)},options:{name:"DropTargetArea",group:"default",filter:null}}),v=x.extend({init:function(e,t){var n=this;x.fn.init.call(n,e,t),n._activated=!1,n.userEvents=new S(n.element,{global:!0,allowSelection:!0,filter:n.options.filter,threshold:n.options.distance,start:T(n._start,n),hold:T(n._hold,n),move:T(n._drag,n),end:T(n._end,n),cancel:T(n._cancel,n),select:T(n._select,n)}),n._afterEndHandler=T(n._afterEnd,n),n._captureEscape=T(n._captureEscape,n)},events:[B,P,L,H,N,O],options:{name:"Draggable",distance:_.support.touch?0:5,group:"default",cursorOffset:null,axis:null,container:null,filter:null,ignore:null,holdToDrag:!1,autoScroll:!1,dropped:!1},cancelHold:function(){this._activated=!1},_captureEscape:function(e){var t=this;e.keyCode===_.keys.ESC&&(t._trigger(N,{event:e}),t.userEvents.cancel())},_updateHint:function(t){var n,i=this,r=i.options,s=i.boundaries,a=r.axis,l=i.options.cursorOffset;l?n={left:t.x.location+l.left,top:t.y.location+l.top}:(i.hintOffset.left+=t.x.delta,i.hintOffset.top+=t.y.delta,n=e.extend({},i.hintOffset)),s&&(n.top=o(n.top,s.y),n.left=o(n.left,s.x)),"x"===a?delete n.top:"y"===a&&delete n.left,i.hint.css(n)},_shouldIgnoreTarget:function(t){var n=this.options.ignore;return n&&e(t).is(n)},_select:function(e){this._shouldIgnoreTarget(e.event.target)||e.preventDefault()},_start:function(n){var i,o=this,s=o.options,a=s.container,l=s.hint;return this._shouldIgnoreTarget(n.touch.initialTouch)||s.holdToDrag&&!o._activated?(o.userEvents.cancel(),t):(o.currentTarget=n.target,o.currentTargetOffset=A(o.currentTarget),l&&(o.hint&&o.hint.stop(!0,!0).remove(),o.hint=_.isFunction(l)?e(l.call(o,o.currentTarget)):l,i=A(o.currentTarget),o.hintOffset=i,o.hint.css({position:"absolute",zIndex:2e4,left:i.left,top:i.top}).appendTo(w.body),o.angular("compile",function(){o.hint.removeAttr("ng-repeat");for(var t=e(n.target);!t.data("$$kendoScope")&&t.length;)t=t.parent();return{elements:o.hint.get(),scopeFrom:t.data("$$kendoScope")}})),E[s.group]=o,o.dropped=!1,a&&(o.boundaries=r(a,o.hint)),e(w).on(F,o._captureEscape),o._trigger(P,n)&&(o.userEvents.cancel(),o._afterEnd()),o.userEvents.capture(),t)},_hold:function(e){this.currentTarget=e.target,this._trigger(B,e)?this.userEvents.cancel():this._activated=!0},_drag:function(t){var n,i;t.preventDefault(),n=this._elementUnderCursor(t),this.options.autoScroll&&this._cursorElement!==n&&(this._scrollableParent=d(n),this._cursorElement=n),this._lastEvent=t,this._processMovement(t,n),this.options.autoScroll&&this._scrollableParent[0]&&(i=u(t.x.location,t.y.location,l(this._scrollableParent)),this._scrollCompenstation=e.extend({},this.hintOffset),this._scrollVelocity=i,0===i.y&&0===i.x?(clearInterval(this._scrollInterval),this._scrollInterval=null):this._scrollInterval||(this._scrollInterval=setInterval(e.proxy(this,"_autoScroll"),50))),this.hint&&this._updateHint(t)},_processMovement:function(n,i){this._withDropTarget(i,function(i,o){if(!i)return h&&(h._trigger(U,D(n,{dropTarget:e(h.targetElement)})),h=null),t;if(h){if(o===h.targetElement)return;h._trigger(U,D(n,{dropTarget:e(h.targetElement)}))}i._trigger(V,D(n,{dropTarget:e(o)})),h=D(i,{targetElement:o})}),this._trigger(L,D(n,{dropTarget:h,elementUnderCursor:i}))},_autoScroll:function(){var e,t,n,i,o,r,s,a,l=this._scrollableParent[0],d=this._scrollVelocity,u=this._scrollCompenstation;l&&(e=this._elementUnderCursor(this._lastEvent),this._processMovement(this._lastEvent,e),i=l===c()[0],i?(t=w.body.scrollHeight>y.height(),n=w.body.scrollWidth>y.width()):(t=l.offsetHeight<=l.scrollHeight,n=l.offsetWidth<=l.scrollWidth),o=l.scrollTop+d.y,r=t&&o>0&&o<l.scrollHeight,s=l.scrollLeft+d.x,a=n&&s>0&&s<l.scrollWidth,r&&(l.scrollTop+=d.y),a&&(l.scrollLeft+=d.x),this.hint&&i&&(a||r)&&(r&&(u.top+=d.y),a&&(u.left+=d.x),this.hint.css(u)))},_end:function(t){this._withDropTarget(this._elementUnderCursor(t),function(n,i){n&&(n._drop(D({},t,{dropTarget:e(i)})),h=null)}),this._cancel(this._trigger(H,t))},_cancel:function(e){var t=this;t._scrollableParent=null,this._cursorElement=null,clearInterval(this._scrollInterval),t._activated=!1,t.hint&&!t.dropped?setTimeout(function(){t.hint.stop(!0,!0),e?t._afterEndHandler():t.hint.animate(t.currentTargetOffset,"fast",t._afterEndHandler)},0):t._afterEnd()},_trigger:function(e,t){var n=this;return n.trigger(e,D({},t.event,{x:t.x,y:t.y,currentTarget:n.currentTarget,initialTarget:t.touch?t.touch.initialTouch:null,dropTarget:t.dropTarget,elementUnderCursor:t.elementUnderCursor}))},_elementUnderCursor:function(e){var t=R(e),i=this.hint;return i&&n(i[0],t)&&(i.hide(),t=R(e),t||(t=R(e)),i.show()),t},_withDropTarget:function(e,t){var n,i=this.options.group,o=M[i],r=I[i];(o&&o.length||r&&r.length)&&(n=s(e,o,r),n?t(n.target,n.targetElement):t())},destroy:function(){var e=this;x.fn.destroy.call(e),e._afterEnd(),e.userEvents.destroy(),this._scrollableParent=null,this._cursorElement=null,clearInterval(this._scrollInterval),e.currentTarget=null},_afterEnd:function(){var t=this;t.hint&&t.hint.remove(),delete E[t.options.group],t.trigger("destroy"),t.trigger(O),e(w).off(F,t._captureEscape)}}),_.ui.plugin(m),_.ui.plugin(g),_.ui.plugin(v),_.TapCapture=q,_.containerBoundaries=r,D(_.ui,{Pane:Y,PaneDimensions:G,Movable:p}),_.ui.Draggable.utils={autoScrollVelocity:u,scrollableViewPort:l,findScrollableParent:d}}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.mobile.scroller.min",["kendo.fx.min","kendo.draganddrop.min"],e)}(function(){return function(e,t){var n=window.kendo,i=n.mobile,o=n.effects,r=i.ui,s=e.proxy,a=e.extend,l=r.Widget,c=n.Class,d=n.ui.Movable,u=n.ui.Pane,h=n.ui.PaneDimensions,f=o.Transition,p=o.Animation,m=Math.abs,g=500,v=.7,_=.96,b=10,w=55,y=.5,k=5,x="km-scroller-release",C="km-scroller-refresh",S="pull",T="change",D="resize",A="scroll",E=2,M=p.extend({init:function(e){var t=this;p.fn.init.call(t),a(t,e),t.userEvents.bind("gestureend",s(t.start,t)),t.tapCapture.bind("press",s(t.cancel,t))},enabled:function(){return this.movable.scale<this.dimensions.minScale},done:function(){return this.dimensions.minScale-this.movable.scale<.01},tick:function(){var e=this.movable;e.scaleWith(1.1),this.dimensions.rescale(e.scale)},onEnd:function(){var e=this.movable;e.scaleTo(this.dimensions.minScale),this.dimensions.rescale(e.scale)}}),I=p.extend({init:function(e){var t=this;p.fn.init.call(t),a(t,e,{transition:new f({axis:e.axis,movable:e.movable,onEnd:function(){t._end()}})}),t.tapCapture.bind("press",function(){t.cancel()}),t.userEvents.bind("end",s(t.start,t)),t.userEvents.bind("gestureend",s(t.start,t)),t.userEvents.bind("tap",s(t.onEnd,t))},onCancel:function(){this.transition.cancel()},freeze:function(e){var t=this;t.cancel(),t._moveTo(e)},onEnd:function(){var e=this;e.paneAxis.outOfBounds()?e._snapBack():e._end()},done:function(){return m(this.velocity)<1},start:function(e){var t,n=this;n.dimension.enabled&&(n.paneAxis.outOfBounds()?n._snapBack():(t=e.touch.id===E?0:e.touch[n.axis].velocity,n.velocity=Math.max(Math.min(t*n.velocityMultiplier,w),-w),n.tapCapture.captureNext(),p.fn.start.call(n)))},tick:function(){var e=this,t=e.dimension,n=e.paneAxis.outOfBounds()?y:e.friction,i=e.velocity*=n,o=e.movable[e.axis]+i;!e.elastic&&t.outOfBounds(o)&&(o=Math.max(Math.min(o,t.max),t.min),e.velocity=0),e.movable.moveAxis(e.axis,o)},_end:function(){this.tapCapture.cancelCapture(),this.end()},_snapBack:function(){var e=this,t=e.dimension,n=e.movable[e.axis]>t.max?t.max:t.min;e._moveTo(n)},_moveTo:function(e){this.transition.moveTo({location:e,duration:g,ease:f.easeOutExpo})}}),R=p.extend({init:function(e){var t=this;n.effects.Animation.fn.init.call(this),a(t,e,{origin:{},destination:{},offset:{}})},tick:function(){this._updateCoordinates(),this.moveTo(this.origin)},done:function(){return m(this.offset.y)<k&&m(this.offset.x)<k},onEnd:function(){this.moveTo(this.destination),this.callback&&this.callback.call()},setCoordinates:function(e,t){this.offset={},this.origin=e,this.destination=t},setCallback:function(e){e&&n.isFunction(e)?this.callback=e:e=t},_updateCoordinates:function(){this.offset={x:(this.destination.x-this.origin.x)/4,y:(this.destination.y-this.origin.y)/4},this.origin={y:this.origin.y+this.offset.y,x:this.origin.x+this.offset.x}}}),F=c.extend({init:function(t){var n=this,i="x"===t.axis,o=e('<div class="km-touch-scrollbar km-'+(i?"horizontal":"vertical")+'-scrollbar" />');a(n,t,{element:o,elementSize:0,movable:new d(o),scrollMovable:t.movable,alwaysVisible:t.alwaysVisible,size:i?"width":"height"}),n.scrollMovable.bind(T,s(n.refresh,n)),n.container.append(o),t.alwaysVisible&&n.show()},refresh:function(){var e=this,t=e.axis,n=e.dimension,i=n.size,o=e.scrollMovable,r=i/n.total,s=Math.round(-o[t]*r),a=Math.round(i*r);r>=1?this.element.css("display","none"):this.element.css("display",""),s+a>i?a=i-s:s<0&&(a+=s,s=0),e.elementSize!=a&&(e.element.css(e.size,a+"px"),e.elementSize=a),e.movable.moveAxis(t,s)},show:function(){this.element.css({opacity:v,visibility:"visible"})},hide:function(){this.alwaysVisible||this.element.css({opacity:0})}}),z=l.extend({init:function(i,o){var r,c,f,p,g,v,_,b,w,y=this;return l.fn.init.call(y,i,o),i=y.element,(y._native=y.options.useNative&&n.support.hasNativeScrolling)?(i.addClass("km-native-scroller").prepend('<div class="km-scroll-header"/>'),a(y,{scrollElement:i,fixedContainer:i.children().first()}),t):(i.css("overflow","hidden").addClass("km-scroll-wrapper").wrapInner('<div class="km-scroll-container"/>').prepend('<div class="km-scroll-header"/>'),r=i.children().eq(1),c=new n.TapCapture(i),f=new d(r),p=new h({element:r,container:i,forcedEnabled:y.options.zoom}),g=this.options.avoidScrolling,v=new n.UserEvents(i,{touchAction:"pan-y",fastTap:!0,allowSelection:!0,preventDragEvent:!0,captureUpIfMoved:!0,multiTouch:y.options.zoom,start:function(t){p.refresh();var n=m(t.x.velocity),i=m(t.y.velocity),o=2*n>=i,r=e.contains(y.fixedContainer[0],t.event.target),s=2*i>=n;!r&&!g(t)&&y.enabled&&(p.x.enabled&&o||p.y.enabled&&s)?v.capture():v.cancel()}}),_=new u({movable:f,dimensions:p,userEvents:v,elastic:y.options.elastic}),b=new M({movable:f,dimensions:p,userEvents:v,tapCapture:c}),w=new R({moveTo:function(e){y.scrollTo(e.x,e.y)}}),f.bind(T,function(){y.scrollTop=-f.y,y.scrollLeft=-f.x,y.trigger(A,{scrollTop:y.scrollTop,scrollLeft:y.scrollLeft})}),y.options.mousewheelScrolling&&i.on("DOMMouseScroll mousewheel",s(this,"_wheelScroll")),a(y,{movable:f,dimensions:p,zoomSnapBack:b,animatedScroller:w,userEvents:v,pane:_,tapCapture:c,pulled:!1,enabled:!0,scrollElement:r,scrollTop:0,scrollLeft:0,fixedContainer:i.children().first()}),y._initAxis("x"),y._initAxis("y"),y._wheelEnd=function(){y._wheel=!1,y.userEvents.end(0,y._wheelY)},p.refresh(),y.options.pullToRefresh&&y._initPullToRefresh(),t)},_wheelScroll:function(e){this._wheel||(this._wheel=!0,this._wheelY=0,this.userEvents.press(0,this._wheelY)),clearTimeout(this._wheelTimeout),this._wheelTimeout=setTimeout(this._wheelEnd,50);var t=n.wheelDeltaY(e);t&&(this._wheelY+=t,this.userEvents.move(0,this._wheelY)),e.preventDefault()},makeVirtual:function(){this.dimensions.y.makeVirtual()},virtualSize:function(e,t){this.dimensions.y.virtualSize(e,t)},height:function(){return this.dimensions.y.size},scrollHeight:function(){return this.scrollElement[0].scrollHeight},scrollWidth:function(){return this.scrollElement[0].scrollWidth},options:{name:"Scroller",zoom:!1,pullOffset:140,visibleScrollHints:!1,elastic:!0,useNative:!1,mousewheelScrolling:!0,avoidScrolling:function(){return!1},pullToRefresh:!1,messages:{pullTemplate:"Pull to refresh",releaseTemplate:"Release to refresh",refreshTemplate:"Refreshing"}},events:[S,A,D],_resize:function(){this._native||this.contentResized()},setOptions:function(e){var t=this;l.fn.setOptions.call(t,e),e.pullToRefresh&&t._initPullToRefresh()},reset:function(){this._native?this.scrollElement.scrollTop(0):(this.movable.moveTo({x:0,y:0}),this._scale(1))},contentResized:function(){this.dimensions.refresh(),this.pane.x.outOfBounds()&&this.movable.moveAxis("x",this.dimensions.x.min),this.pane.y.outOfBounds()&&this.movable.moveAxis("y",this.dimensions.y.min)},zoomOut:function(){var e=this.dimensions;e.refresh(),this._scale(e.fitScale),this.movable.moveTo(e.centerCoordinates())},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},scrollTo:function(e,t){this._native?(this.scrollElement.scrollLeft(m(e)),this.scrollElement.scrollTop(m(t))):(this.dimensions.refresh(),this.movable.moveTo({x:e,y:t}))},animatedScrollTo:function(e,t,n){var i,o;this._native?this.scrollTo(e,t):(i={x:this.movable.x,y:this.movable.y},o={x:e,y:t},this.animatedScroller.setCoordinates(i,o),this.animatedScroller.setCallback(n),this.animatedScroller.start())},pullHandled:function(){var e=this;e.refreshHint.removeClass(C),e.hintContainer.html(e.pullTemplate({})),e.yinertia.onEnd(),e.xinertia.onEnd(),e.userEvents.cancel()},destroy:function(){l.fn.destroy.call(this),this.userEvents&&this.userEvents.destroy()},_scale:function(e){this.dimensions.rescale(e),this.movable.scaleTo(e)},_initPullToRefresh:function(){var e=this;e.dimensions.y.forceEnabled(),e.pullTemplate=n.template(e.options.messages.pullTemplate),e.releaseTemplate=n.template(e.options.messages.releaseTemplate),e.refreshTemplate=n.template(e.options.messages.refreshTemplate),e.scrollElement.prepend('<span class="km-scroller-pull"><span class="km-icon"></span><span class="km-loading-left"></span><span class="km-loading-right"></span><span class="km-template">'+e.pullTemplate({})+"</span></span>"),e.refreshHint=e.scrollElement.children().first(),e.hintContainer=e.refreshHint.children(".km-template"),e.pane.y.bind("change",s(e._paneChange,e)),e.userEvents.bind("end",s(e._dragEnd,e))},_dragEnd:function(){var e=this;e.pulled&&(e.pulled=!1,e.refreshHint.removeClass(x).addClass(C),e.hintContainer.html(e.refreshTemplate({})),e.yinertia.freeze(e.options.pullOffset/2),e.trigger("pull"))},_paneChange:function(){var e=this;e.movable.y/y>e.options.pullOffset?e.pulled||(e.pulled=!0,e.refreshHint.removeClass(C).addClass(x),e.hintContainer.html(e.releaseTemplate({}))):e.pulled&&(e.pulled=!1,e.refreshHint.removeClass(x),e.hintContainer.html(e.pullTemplate({})))},_initAxis:function(e){var t=this,n=t.movable,i=t.dimensions[e],o=t.tapCapture,r=t.pane[e],s=new F({axis:e,movable:n,dimension:i,container:t.element,alwaysVisible:t.options.visibleScrollHints});i.bind(T,function(){s.refresh()}),r.bind(T,function(){s.show()}),t[e+"inertia"]=new I({axis:e,paneAxis:r,movable:n,tapCapture:o,userEvents:t.userEvents,dimension:i,elastic:t.options.elastic,friction:t.options.friction||_,velocityMultiplier:t.options.velocityMultiplier||b,end:function(){s.hide(),t.trigger("scrollEnd",{axis:e,scrollTop:t.scrollTop,scrollLeft:t.scrollLeft})}})}});r.plugin(z)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.groupable.min",["kendo.core.min","kendo.draganddrop.min"],e)}(function(){return function(e,t){function n(e){return e.position().top+3}var i=window.kendo,o=i.ui.Widget,r=i._outerWidth,s=e.proxy,a=!1,l=".kendoGroupable",c="change",d=i.template('<div class="k-group-indicator" data-#=data.ns#field="${data.field}" data-#=data.ns#title="${data.title || ""}" data-#=data.ns#dir="${data.dir || "asc"}"><a href="\\#" class="k-link"><span class="k-icon k-i-sort-${(data.dir || "asc") == "asc" ? "asc-sm" : "desc-sm"}" title="(sorted ${(data.dir || "asc") == "asc" ? "ascending": "descending"})"></span>${data.title ? data.title: data.field}</a><a class="k-button k-button-icon k-bare"><span class="k-icon k-i-close"></span></a></div>',{useWithBlock:!1}),u=function(t){var n=t.attr(i.attr("title"));return n&&(n=i.htmlEncode(n)),e('<div class="k-header k-drag-clue" />').css({width:t.width(),paddingLeft:t.css("paddingLeft"),paddingRight:t.css("paddingRight"),lineHeight:t.height()+"px",paddingTop:t.css("paddingTop"),paddingBottom:t.css("paddingBottom")}).html(n||t.attr(i.attr("field"))).prepend('<span class="k-icon k-drag-status k-i-cancel" />')},h=e('<div class="k-grouping-dropclue"/>'),f=o.extend({init:function(d,f){var p,m,g=this,v=i.guid(),_=s(g._intializePositions,g),b=g._dropCuePositions=[];o.fn.init.call(g,d,f),a=i.support.isRtl(d),m=a?"right":"left",g.draggable=p=g.options.draggable||new i.ui.Draggable(g.element,{filter:g.options.draggableElements,hint:u,group:v}),g.groupContainer=e(g.options.groupContainer,g.element).kendoDropTarget({group:p.options.group,dragenter:function(e){g._canDrag(e.draggable.currentTarget)&&(e.draggable.hint.find(".k-drag-status").removeClass("k-i-cancel").addClass("k-i-plus"),h.css("top",n(g.groupContainer)).css(m,0).appendTo(g.groupContainer))},dragleave:function(e){e.draggable.hint.find(".k-drag-status").removeClass("k-i-plus").addClass("k-i-cancel"),h.remove()},drop:function(t){var n,o=t.draggable.currentTarget,r=o.attr(i.attr("field")),s=o.attr(i.attr("title")),l=g.indicator(r),c=g._dropCuePositions,d=c[c.length-1];(o.hasClass("k-group-indicator")||g._canDrag(o))&&(d?(n=g._dropCuePosition(i.getOffset(h).left+parseInt(d.element.css("marginLeft"),10)*(a?-1:1)+parseInt(d.element.css("marginRight"),10)),n&&g._canDrop(e(l),n.element,n.left)&&(n.before?n.element.before(l||g.buildIndicator(r,s)):n.element.after(l||g.buildIndicator(r,s)),g._change())):(g.groupContainer.append(g.buildIndicator(r,s)),g._change()))}}).kendoDraggable({filter:"div.k-group-indicator",hint:u,group:p.options.group,dragcancel:s(g._dragCancel,g),dragstart:function(e){var t=e.currentTarget,i=parseInt(t.css("marginLeft"),10),o=t.position(),s=a?o.left-i:o.left+r(t);_(),h.css({top:n(g.groupContainer),left:s}).appendTo(g.groupContainer),this.hint.find(".k-drag-status").removeClass("k-i-cancel").addClass("k-i-plus")},dragend:function(){g._dragEnd(this)},drag:s(g._drag,g)}).on("click"+l,".k-button",function(t){t.preventDefault(),g._removeIndicator(e(this).parent())}).on("click"+l,".k-link",function(t){var n=e(this).parent(),o=g.buildIndicator(n.attr(i.attr("field")),n.attr(i.attr("title")),"asc"==n.attr(i.attr("dir"))?"desc":"asc");n.before(o).remove(),g._change(),t.preventDefault()}),p.bind(["dragend","dragcancel","dragstart","drag"],{dragend:function(){g._dragEnd(this)},dragcancel:s(g._dragCancel,g),dragstart:function(e){var n,i,o;return g.options.allowDrag||g._canDrag(e.currentTarget)?(_(),b.length?(n=b[b.length-1].element,i=parseInt(n.css("marginRight"),10),o=n.position().left+r(n)+i):o=0,t):(e.preventDefault(),t)},drag:s(g._drag,g)}),g.dataSource=g.options.dataSource,g.dataSource&&g._refreshHandler?g.dataSource.unbind(c,g._refreshHandler):g._refreshHandler=s(g.refresh,g),g.dataSource&&(g.dataSource.bind("change",g._refreshHandler),g.refresh())},refresh:function(){var t=this,n=t.dataSource;t.groupContainer&&t.groupContainer.empty().append(e.map(n.group()||[],function(n){var o=n.field,r=i.attr("field"),s=t.element.find(t.options.filter).filter(function(){return e(this).attr(r)===o});return t.buildIndicator(n.field,s.attr(i.attr("title")),n.dir)}).join("")),t._invalidateGroupContainer()},destroy:function(){var e=this;o.fn.destroy.call(e),e.groupContainer.off(l),e.groupContainer.data("kendoDropTarget")&&e.groupContainer.data("kendoDropTarget").destroy(),e.groupContainer.data("kendoDraggable")&&e.groupContainer.data("kendoDraggable").destroy(),e.options.draggable||e.draggable.destroy(),e.dataSource&&e._refreshHandler&&(e.dataSource.unbind("change",e._refreshHandler),e._refreshHandler=null),e.groupContainer=e.element=e.draggable=null},events:["change"],options:{name:"Groupable",filter:"th",draggableElements:"th",messages:{empty:"Drag a column header and drop it here to group by that column"}},indicator:function(t){var n=e(".k-group-indicator",this.groupContainer);return e.grep(n,function(n){return e(n).attr(i.attr("field"))===t})[0]},buildIndicator:function(e,t,n){return d({field:e.replace(/"/g,"'"),dir:n,title:t,ns:i.ns})},descriptors:function(){var t,n,o,r,s,a=this,l=e(".k-group-indicator",a.groupContainer);return t=a.element.find(a.options.filter).map(function(){var t=e(this),o=t.attr(i.attr("aggregates")),a=t.attr(i.attr("field"));if(o&&""!==o)for(n=o.split(","),o=[],r=0,s=n.length;r<s;r++)o.push({field:a,aggregate:n[r]});return o}).toArray(),e.map(l,function(n){return n=e(n),o=n.attr(i.attr("field")),{field:o,dir:n.attr(i.attr("dir")),aggregates:t||[]}})},_removeIndicator:function(e){var t=this;e.remove(),t._invalidateGroupContainer(),t._change()},_change:function(){var e,n=this;if(n.dataSource){if(e=n.descriptors(),n.trigger("change",{groups:e}))return n.refresh(),t;n.dataSource.group(e)}},_dropCuePosition:function(t){var n,i,o,s,l,c=this._dropCuePositions;if(h.is(":visible")&&0!==c.length)return t=Math.ceil(t),n=c[c.length-1],i=n.left,o=n.right,s=parseInt(n.element.css("marginLeft"),10),l=parseInt(n.element.css("marginRight"),10),t>=o&&!a||t<i&&a?t={left:n.element.position().left+(a?-s:r(n.element)+l),element:n.element,before:!1}:(t=e.grep(c,function(e){return e.left<=t&&t<=e.right||a&&t>e.right})[0],t&&(t={left:a?t.element.position().left+r(t.element)+l:t.element.position().left-s,element:t.element,before:!0})),t},_drag:function(e){var t=this._dropCuePosition(e.x.location);t&&h.css({left:t.left,right:"auto"})},_canDrag:function(e){var t=e.attr(i.attr("field"));return"false"!=e.attr(i.attr("groupable"))&&t&&(e.hasClass("k-group-indicator")||!this.indicator(t))},_canDrop:function(e,t,n){var i=e.next(),o=e[0]!==t[0]&&(!i[0]||t[0]!==i[0]||!a&&n>i.position().left||a&&n<i.position().left);return o},_dragEnd:function(t){var n=this,o=t.currentTarget.attr(i.attr("field")),r=n.indicator(o);t!==n.options.draggable&&!t.dropped&&r&&n._removeIndicator(e(r)),n._dragCancel()},_dragCancel:function(){h.remove(),this._dropCuePositions=[]},_intializePositions:function(){var t,n=this,o=e(".k-group-indicator",n.groupContainer);n._dropCuePositions=e.map(o,function(n){return n=e(n),t=i.getOffset(n).left,{left:parseInt(t,10),
right:parseInt(t+r(n),10),element:n}})},_invalidateGroupContainer:function(){var e=this.groupContainer;e&&e.is(":empty")&&e.html(this.options.messages.empty)}});i.ui.plugin(f)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.reorderable.min",["kendo.core.min","kendo.draganddrop.min"],e)}(function(){return function(e,t){function n(t,n){t=e(t),n?t.find(".k-drag-status").removeClass("k-i-plus").addClass("k-i-cancel"):t.find(".k-drag-status").removeClass("k-i-cancel").addClass("k-i-plus")}var i=window.kendo,o=i._outerWidth,r=i._outerHeight,s=i.getOffset,a=i.ui.Widget,l="change",c="k-reorderable",d=a.extend({init:function(t,d){var u,h=this,f=i.guid()+"-reorderable";a.fn.init.call(h,t,d),t=h.element.addClass(c),d=h.options,h.draggable=u=d.draggable||new i.ui.Draggable(t,{group:f,autoScroll:!0,filter:d.filter,hint:d.hint}),h.reorderDropCue=e('<div class="k-reorder-cue"><div class="k-icon k-i-arrow-60-down"></div><div class="k-icon k-i-arrow-60-up"></div></div>'),t.find(u.options.filter).kendoDropTarget({group:u.options.group,dragenter:function(e){var t,i,a,l;h._draggable&&(t=this.element,a=!h._dropTargetAllowed(t)||h._isLastDraggable(),n(e.draggable.hint,a),a||(i=s(t),l=i.left,d.inSameContainer&&!d.inSameContainer({source:t,target:h._draggable,sourceIndex:h._index(t),targetIndex:h._index(h._draggable)})?h._dropTarget=t:h._index(t)>h._index(h._draggable)&&(l+=o(t)),h.reorderDropCue.css({height:r(t),top:i.top,left:l}).appendTo(document.body)))},dragleave:function(e){n(e.draggable.hint,!0),h.reorderDropCue.remove(),h._dropTarget=null},drop:function(){var e,t;h._dropTarget=null,h._draggable&&(e=this.element,t=h._draggable,h._dropTargetAllowed(e)&&!h._isLastDraggable()&&h.trigger(l,{element:h._draggable,target:e,oldIndex:h._index(t),newIndex:h._index(e),position:s(h.reorderDropCue).left>s(e).left?"after":"before"}))}}),u.bind(["dragcancel","dragend","dragstart","drag"],{dragcancel:function(){h.reorderDropCue.remove(),h._draggable=null,h._elements=null},dragend:function(){h.reorderDropCue.remove(),h._draggable=null,h._elements=null},dragstart:function(e){h._draggable=e.currentTarget,h._elements=h.element.find(h.draggable.options.filter)},drag:function(e){var t,n;h._dropTarget&&!this.hint.find(".k-drag-status").hasClass("k-i-cancel")&&(t=s(h._dropTarget).left,n=o(h._dropTarget),h.reorderDropCue.css(e.pageX>t+n/2?{left:t+n}:{left:t}))}})},options:{name:"Reorderable",filter:"*"},events:[l],_isLastDraggable:function(){var e,t=this.options.inSameContainer,n=this._draggable[0],i=this._elements.get(),o=!1;if(!t)return!1;for(;!o&&i.length>0;)e=i.pop(),o=n!==e&&t({source:n,target:e,sourceIndex:this._index(n),targetIndex:this._index(e)});return!o},_dropTargetAllowed:function(e){var t=this.options.inSameContainer,n=this.options.dragOverContainers,i=this._draggable;return i[0]!==e[0]&&(!t||!n||(!!t({source:i,target:e,sourceIndex:this._index(i),targetIndex:this._index(e)})||n(this._index(i),this._index(e))))},_index:function(e){return this._elements.index(e)},destroy:function(){var t=this;a.fn.destroy.call(t),t.element.find(t.draggable.options.filter).each(function(){var t=e(this);t.data("kendoDropTarget")&&t.data("kendoDropTarget").destroy()}),t.draggable&&(t.draggable.destroy(),t.draggable.element=t.draggable=null),t.elements=t.reorderDropCue=t._elements=t._draggable=null}});i.ui.plugin(d)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.resizable.min",["kendo.core.min","kendo.draganddrop.min"],e)}(function(){return function(e,t){var n=window.kendo,i=n.ui,o=i.Widget,r=e.proxy,s=n.isFunction,a=e.extend,l="horizontal",c="vertical",d="start",u="resize",h="resizeend",f=o.extend({init:function(e,t){var n=this;o.fn.init.call(n,e,t),n.orientation=n.options.orientation.toLowerCase()!=c?l:c,n._positionMouse=n.orientation==l?"x":"y",n._position=n.orientation==l?"left":"top",n._sizingDom=n.orientation==l?"outerWidth":"outerHeight",n.draggable=new i.Draggable(t.draggableElement||e,{distance:1,filter:t.handle,drag:r(n._resize,n),dragcancel:r(n._cancel,n),dragstart:r(n._start,n),dragend:r(n._stop,n)}),n.userEvents=n.draggable.userEvents},events:[u,h,d],options:{name:"Resizable",orientation:l},resize:function(){},_max:function(e){var n=this,i=n.hint?n.hint[n._sizingDom]():0,o=n.options.max;return s(o)?o(e):o!==t?n._initialElementPosition+o-i:o},_min:function(e){var n=this,i=n.options.min;return s(i)?i(e):i!==t?n._initialElementPosition+i:i},_start:function(t){var n=this,i=n.options.hint,o=e(t.currentTarget);n._initialElementPosition=o.position()[n._position],n._initialMousePosition=t[n._positionMouse].startLocation,i&&(n.hint=s(i)?e(i(o)):i,n.hint.css({position:"absolute"}).css(n._position,n._initialElementPosition).appendTo(n.element)),n.trigger(d,t),n._maxPosition=n._max(t),n._minPosition=n._min(t),e(document.body).css("cursor",o.css("cursor"))},_resize:function(e){var n,i=this,o=i._maxPosition,r=i._minPosition,s=i._initialElementPosition+(e[i._positionMouse].location-i._initialMousePosition);n=r!==t?Math.max(r,s):s,i.position=n=o!==t?Math.min(o,n):n,i.hint&&i.hint.toggleClass(i.options.invalidClass||"",n==o||n==r).css(i._position,n),i.resizing=!0,i.trigger(u,a(e,{position:n}))},_stop:function(t){var n=this;n.hint&&n.hint.remove(),n.resizing=!1,n.trigger(h,a(t,{position:n.position})),e(document.body).css("cursor","")},_cancel:function(e){var n=this;n.hint&&(n.position=t,n.hint.css(n._position,n._initialElementPosition),n._stop(e))},destroy:function(){var e=this;o.fn.destroy.call(e),e.draggable&&e.draggable.destroy()},press:function(e){if(e){var t=e.position(),n=this;n.userEvents.press(t.left,t.top,e[0]),n.targetPosition=t,n.target=e}},move:function(e){var n=this,i=n._position,o=n.targetPosition,r=n.position;r===t&&(r=o[i]),o[i]=r+e,n.userEvents.move(o.left,o.top)},end:function(){this.userEvents.end(),this.target=this.position=t}});n.ui.plugin(f)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.sortable.min",["kendo.draganddrop.min"],e)}(function(){return function(e,t){function n(t,n){try{return e.contains(t,n)||t==n}catch(i){return!1}}function i(e){return e.clone()}function o(e){return e.clone().removeAttr("id").css("visibility","hidden")}var r=window.kendo,s=r.ui.Widget,a=r._outerWidth,l=r._outerHeight,c="start",d="beforeMove",u="move",h="end",f="change",p="cancel",m="sort",g="remove",v="receive",_=">*",b=-1,w=s.extend({init:function(e,t){var n=this;s.fn.init.call(n,e,t),n.options.placeholder||(n.options.placeholder=o),n.options.hint||(n.options.hint=i),n.draggable=n._createDraggable()},events:[c,d,u,h,f,p],options:{name:"Sortable",hint:null,placeholder:null,filter:_,holdToDrag:!1,disabled:null,container:null,connectWith:null,handler:null,cursorOffset:null,axis:null,ignore:null,autoScroll:!1,cursor:"auto",moveOnDragEnter:!1},destroy:function(){this.draggable.destroy(),s.fn.destroy.call(this)},_createDraggable:function(){var t=this,n=t.element,i=t.options;return new r.ui.Draggable(n,{filter:i.filter,hint:r.isFunction(i.hint)?i.hint:e(i.hint),holdToDrag:i.holdToDrag,container:i.container?e(i.container):null,cursorOffset:i.cursorOffset,axis:i.axis,ignore:i.ignore,autoScroll:i.autoScroll,dragstart:e.proxy(t._dragstart,t),dragcancel:e.proxy(t._dragcancel,t),drag:e.proxy(t._drag,t),dragend:e.proxy(t._dragend,t)})},_dragstart:function(t){var n=this.draggedElement=t.currentTarget,i=this.options.disabled,o=this.options.handler,s=this.options.placeholder,a=this.placeholder=e(r.isFunction(s)?s.call(this,n):s);i&&n.is(i)?t.preventDefault():o&&!e(t.initialTarget).is(o)?t.preventDefault():this.trigger(c,{item:n,draggableEvent:t})?t.preventDefault():(n.css("display","none"),n.before(a),this._setCursor())},_dragcancel:function(){this._cancel(),this.trigger(p,{item:this.draggedElement}),this._resetCursor()},_drag:function(n){var i,o,r,s,a,l=this.draggedElement,c=this._findTarget(n),d={left:n.x.location,top:n.y.location},u={x:n.x.delta,y:n.y.delta},h=this.options.axis,f=this.options.moveOnDragEnter,p={item:l,list:this,draggableEvent:n};if("x"===h||"y"===h)return this._movementByAxis(h,d,u[h],p),t;if(c){if(i=this._getElementCenter(c.element),o={left:Math.round(d.left-i.left),top:Math.round(d.top-i.top)},e.extend(p,{target:c.element}),c.appendToBottom)return this._movePlaceholder(c,null,p),t;if(c.appendAfterHidden&&this._movePlaceholder(c,"next",p),this._isFloating(c.element)?u.x<0&&f||!f&&o.left<0?r="prev":(u.x>0&&f||!f&&o.left>0)&&(r="next"):u.y<0&&f||!f&&o.top<0?r="prev":(u.y>0&&f||!f&&o.top>0)&&(r="next"),r){for(a="prev"===r?jQuery.fn.prev:jQuery.fn.next,s=a.call(c.element);s.length&&!s.is(":visible");)s=a.call(s);s[0]!=this.placeholder[0]&&this._movePlaceholder(c,r,p)}}},_dragend:function(n){var i,o,r,s,a=this.placeholder,l=this.draggedElement,c=this.indexOf(l),d=this.indexOf(a),u=this.options.connectWith;return this._resetCursor(),r={action:m,item:l,oldIndex:c,newIndex:d,draggableEvent:n},d>=0?o=this.trigger(h,r):(i=a.parents(u).getKendoSortable(),r.action=g,s=e.extend({},r,{action:v,oldIndex:b,newIndex:i.indexOf(a)}),o=!(!this.trigger(h,r)&&!i.trigger(h,s))),o||d===c?(this._cancel(),t):(a.replaceWith(l),l.show(),this.draggable.dropped=!0,r={action:this.indexOf(l)!=b?m:g,item:l,oldIndex:c,newIndex:this.indexOf(l),draggableEvent:n},this.trigger(f,r),i&&(s=e.extend({},r,{action:v,oldIndex:b,newIndex:i.indexOf(l)}),i.trigger(f,s)),t)},_findTarget:function(n){var i,o,r=this._findElementUnderCursor(n),s=this.options.connectWith;return e.contains(this.element[0],r)?(i=this.items(),o=i.filter(r)[0]||i.has(r)[0],o?{element:e(o),sortable:this}:null):this.element[0]==r&&this._isEmpty()?{element:this.element,sortable:this,appendToBottom:!0}:this.element[0]==r&&this._isLastHidden()?(o=this.items().eq(0),{element:o,sortable:this,appendAfterHidden:!0}):s?this._searchConnectedTargets(r,n):t},_findElementUnderCursor:function(e){var t=r.elementUnderCursor(e),i=e.sender;return n(i.hint[0],t)&&(i.hint.hide(),t=r.elementUnderCursor(e),t||(t=r.elementUnderCursor(e)),i.hint.show()),t},_searchConnectedTargets:function(t,n){var i,o,r,s,a=e(this.options.connectWith);for(s=0;s<a.length;s++)if(i=a.eq(s).getKendoSortable(),e.contains(a[s],t)){if(i)return o=i.items(),r=o.filter(t)[0]||o.has(t)[0],r?(i.placeholder=this.placeholder,{element:e(r),sortable:i}):null}else if(a[s]==t){if(i&&i._isEmpty())return{element:a.eq(s),sortable:i,appendToBottom:!0};if(this._isCursorAfterLast(i,n))return r=i.items().last(),{element:r,sortable:i}}},_isCursorAfterLast:function(e,t){var n,i,o=e.items().last(),s={left:t.x.location,top:t.y.location};return n=r.getOffset(o),n.top+=l(o),n.left+=a(o),i=this._isFloating(o)?n.left-s.left:n.top-s.top,i<0},_movementByAxis:function(t,n,i,o){var r,s="x"===t?n.left:n.top,a=i<0?this.placeholder.prev():this.placeholder.next();a.length&&!a.is(":visible")&&(a=i<0?a.prev():a.next()),e.extend(o,{target:a}),r=this._getElementCenter(a),r&&(r="x"===t?r.left:r.top),a.length&&i<0&&s-r<0?this._movePlaceholder({element:a,sortable:this},"prev",o):a.length&&i>0&&s-r>0&&this._movePlaceholder({element:a,sortable:this},"next",o)},_movePlaceholder:function(e,t,n){var i=this.placeholder;e.sortable.trigger(d,n)||(t?"prev"===t?e.element.before(i):"next"===t&&e.element.after(i):e.element.append(i),e.sortable.trigger(u,n))},_setCursor:function(){var t,n=this.options.cursor;n&&"auto"!==n&&(t=e(document.body),this._originalCursorType=t.css("cursor"),t.css({cursor:n}),this._cursorStylesheet||(this._cursorStylesheet=e("<style>* { cursor: "+n+" !important; }</style>")),this._cursorStylesheet.appendTo(t))},_resetCursor:function(){this._originalCursorType&&(e(document.body).css("cursor",this._originalCursorType),this._originalCursorType=null,this._cursorStylesheet.remove())},_getElementCenter:function(e){var t=e.length?r.getOffset(e):null;return t&&(t.top+=l(e)/2,t.left+=a(e)/2),t},_isFloating:function(e){return/left|right/.test(e.css("float"))||/inline|table-cell/.test(e.css("display"))},_cancel:function(){this.draggedElement.show(),this.placeholder.remove()},_items:function(){var e,t=this.options.filter;return e=t?this.element.find(t):this.element.children()},indexOf:function(e){var t=this._items(),n=this.placeholder,i=this.draggedElement;return n&&e[0]==n[0]?t.not(i).index(e):t.not(n).index(e)},items:function(){var e=this.placeholder,t=this._items();return e&&(t=t.not(e)),t},_isEmpty:function(){return!this.items().length},_isLastHidden:function(){return 1===this.items().length&&this.items().is(":hidden")}});r.ui.plugin(w)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.selectable.min",["kendo.core.min","kendo.userevents.min"],e)}(function(){return function(e,t){function n(e,t){if(!e.is(":visible"))return!1;var n=o.getOffset(e),i=t.left+t.width,r=t.top+t.height;return n.right=n.left+o._outerWidth(e),n.bottom=n.top+o._outerHeight(e),!(n.left>i||n.right<t.left||n.top>r||n.bottom<t.top)}var i,o=window.kendo,r=o.ui.Widget,s=e.proxy,a=Math.abs,l="aria-selected",c="k-state-selected",d="k-state-selecting",u="k-selectable",h="change",f=".kendoSelectable",p="k-state-unselecting",m="input,a,textarea,.k-multiselect-wrap,select,button,.k-button>span,.k-button>img,span.k-icon.k-i-arrow-60-down,span.k-icon.k-i-arrow-60-up",g=o.support.browser.msie,v=!1;!function(e){!function(){e('<div class="parent"><span /></div>').on("click",">*",function(){v=!0}).find("span").click().end().off()}()}(e),i=r.extend({init:function(t,n){var i,a=this;r.fn.init.call(a,t,n),a._marquee=e("<div class='k-marquee'><div class='k-marquee-color'></div></div>"),a._lastActive=null,a.element.addClass(u),a.relatedTarget=a.options.relatedTarget,i=a.options.multiple,this.options.aria&&i&&a.element.attr("aria-multiselectable",!0),a.userEvents=new o.UserEvents(a.element,{global:!0,allowSelection:!0,filter:(v?"":"."+u+" ")+a.options.filter,tap:s(a._tap,a)}),i&&a.userEvents.bind("start",s(a._start,a)).bind("move",s(a._move,a)).bind("end",s(a._end,a)).bind("select",s(a._select,a))},events:[h],options:{name:"Selectable",filter:">*",multiple:!1,relatedTarget:e.noop},_isElement:function(e){var t,n=this.element,i=n.length,o=!1;for(e=e[0],t=0;t<i;t++)if(n[t]===e){o=!0;break}return o},_tap:function(t){var n,i=e(t.target),o=this,r=t.event.ctrlKey||t.event.metaKey,s=o.options.multiple,a=s&&t.event.shiftKey,l=t.event.which,d=t.event.button;!o._isElement(i.closest("."+u))||l&&3==l||d&&2==d||this._allowSelection(t.event.target)&&(n=i.hasClass(c),s&&r||o.clear(),i=i.add(o.relatedTarget(i)),a?o.selectRange(o._firstSelectee(),i):(n&&r?(o._unselect(i),o._notify(h)):o.value(i),o._lastActive=o._downTarget=i))},_start:function(n){var i,o=this,r=e(n.target),s=r.hasClass(c),a=n.event.ctrlKey||n.event.metaKey;if(this._allowSelection(n.event.target)){if(o._downTarget=r,!o._isElement(r.closest("."+u)))return o.userEvents.cancel(),t;o.options.useAllItems?o._items=o.element.find(o.options.filter):(i=r.closest(o.element),o._items=i.find(o.options.filter)),n.sender.capture(),o._marquee.appendTo(document.body).css({left:n.x.client+1,top:n.y.client+1,width:0,height:0}),a||o.clear(),r=r.add(o.relatedTarget(r)),s&&(o._selectElement(r,!0),a&&r.addClass(p))}},_move:function(e){var t=this,n={left:e.x.startLocation>e.x.location?e.x.location:e.x.startLocation,top:e.y.startLocation>e.y.location?e.y.location:e.y.startLocation,width:a(e.x.initialDelta),height:a(e.y.initialDelta)};t._marquee.css(n),t._invalidateSelectables(n,e.event.ctrlKey||e.event.metaKey),e.preventDefault()},_end:function(){var e,t=this;t._marquee.remove(),t._unselect(t.element.find(t.options.filter+"."+p)).removeClass(p),e=t.element.find(t.options.filter+"."+d),e=e.add(t.relatedTarget(e)),t.value(e),t._lastActive=t._downTarget,t._items=null},_invalidateSelectables:function(e,t){var i,o,r,s,a=this._downTarget[0],l=this._items;for(i=0,o=l.length;i<o;i++)s=l.eq(i),r=s.add(this.relatedTarget(s)),n(s,e)?s.hasClass(c)?t&&a!==s[0]&&r.removeClass(c).addClass(p):s.hasClass(d)||s.hasClass(p)||r.addClass(d):s.hasClass(d)?r.removeClass(d):t&&s.hasClass(p)&&r.removeClass(p).addClass(c)},value:function(e){var n=this,i=s(n._selectElement,n);return e?(e.each(function(){i(this)}),n._notify(h),t):n.element.find(n.options.filter+"."+c)},_firstSelectee:function(){var e,t=this;return null!==t._lastActive?t._lastActive:(e=t.value(),e.length>0?e[0]:t.element.find(t.options.filter)[0])},_selectElement:function(t,n){var i=e(t),o=!n&&this._notify("select",{element:t});i.removeClass(d),o||(i.addClass(c),this.options.aria&&i.attr(l,!0))},_notify:function(e,t){return t=t||{},this.trigger(e,t)},_unselect:function(e){return e.removeClass(c),this.options.aria&&e.attr(l,!1),e},_select:function(t){this._allowSelection(t.event.target)&&(!g||g&&!e(o._activeElement()).is(m))&&t.preventDefault()},_allowSelection:function(t){return!e(t).is(m)||(this.userEvents.cancel(),this._downTarget=null,!1)},resetTouchEvents:function(){this.userEvents.cancel()},clear:function(){var e=this.element.find(this.options.filter+"."+c);this._unselect(e)},selectRange:function(t,n){var i,o,r,s=this;for(s.clear(),s.element.length>1&&(r=s.options.continuousItems()),r&&r.length||(r=s.element.find(s.options.filter)),t=e.inArray(e(t)[0],r),n=e.inArray(e(n)[0],r),t>n&&(o=t,t=n,n=o),s.options.useAllItems||(n+=s.element.length-1),i=t;i<=n;i++)s._selectElement(r[i]);s._notify(h)},destroy:function(){var e=this;r.fn.destroy.call(e),e.element.off(f),e.userEvents.destroy(),e._marquee=e._lastActive=e.element=e.userEvents=null}}),i.parseOptions=function(e){var t="string"==typeof e&&e.toLowerCase();return{multiple:t&&t.indexOf("multiple")>-1,cell:t&&t.indexOf("cell")>-1}},o.ui.plugin(i)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.button.min",["kendo.core.min"],e)}(function(){return function(e,t){var n=window.kendo,i=n.ui.Widget,o=e.proxy,r=n.keys,s="click",a="k-button",l="k-button-icon",c="k-button-icontext",d=".kendoButton",u="disabled",h="k-state-disabled",f="k-state-focused",p="k-state-selected",m=i.extend({init:function(e,t){var r=this;i.fn.init.call(r,e,t),e=r.wrapper=r.element,t=r.options,e.addClass(a).attr("role","button"),t.enable=t.enable&&!e.attr(u),r.enable(t.enable),r._tabindex(),r._graphics(),e.on(s+d,o(r._click,r)).on("focus"+d,o(r._focus,r)).on("blur"+d,o(r._blur,r)).on("keydown"+d,o(r._keydown,r)).on("keyup"+d,o(r._keyup,r)),n.notify(r)},destroy:function(){var e=this;e.wrapper.off(d),i.fn.destroy.call(e)},events:[s],options:{name:"Button",icon:"",spriteCssClass:"",imageUrl:"",enable:!0},_isNativeButton:function(){return"button"==this.element.prop("tagName").toLowerCase()},_click:function(e){this.options.enable&&this.trigger(s,{event:e})&&e.preventDefault()},_focus:function(){this.options.enable&&this.element.addClass(f)},_blur:function(){this.element.removeClass(f)},_keydown:function(e){var t=this;t._isNativeButton()||e.keyCode!=r.ENTER&&e.keyCode!=r.SPACEBAR||(e.keyCode==r.SPACEBAR&&(e.preventDefault(),t.options.enable&&t.element.addClass(p)),t._click(e))},_keyup:function(){this.element.removeClass(p)},_graphics:function(){var t,n,i,o=this,r=o.element,s=o.options,a=s.icon,d=s.spriteCssClass,u=s.imageUrl;(d||u||a)&&(i=!0,r.contents().filter(function(){return!e(this).hasClass("k-sprite")&&!e(this).hasClass("k-icon")&&!e(this).hasClass("k-image")}).each(function(t,n){(1==n.nodeType||3==n.nodeType&&e.trim(n.nodeValue).length>0)&&(i=!1)}),r.addClass(i?l:c)),a?(t=r.children("span.k-icon").first(),t[0]||(t=e('<span class="k-icon"></span>').prependTo(r)),t.addClass("k-i-"+a)):d?(t=r.children("span.k-sprite").first(),t[0]||(t=e('<span class="k-sprite"></span>').prependTo(r)),t.addClass(d)):u&&(n=r.children("img.k-image").first(),n[0]||(n=e('<img alt="icon" class="k-image" />').prependTo(r)),n.attr("src",u))},enable:function(e){var n=this,i=n.element;e===t&&(e=!0),e=!!e,n.options.enable=e,i.toggleClass(h,!e).attr("aria-disabled",!e).attr(u,!e);try{i.blur()}catch(o){}}});n.ui.plugin(m)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.pager.min",["kendo.data.min"],e)}(function(){return function(e,t){function n(e,t,n,i,o){return e({idx:t,text:n,ns:c.ns,numeric:i,title:o||""})}function i(e,t,n){return C({className:e.substring(1),text:t,wrapClassName:n||""})}function o(e,t,n,i){e.find(t).parent().attr(c.attr("page"),n).attr("tabindex",-1).toggleClass("k-state-disabled",i)}function r(e,t){o(e,f,1,t<=1)}function s(e,t){o(e,m,Math.max(1,t-1),t<=1)}function a(e,t,n){o(e,g,Math.min(n,t+1),t>=n)}function l(e,t,n){o(e,p,n,t>=n)}var c=window.kendo,d=c.ui,u=d.Widget,h=e.proxy,f=".k-i-seek-w",p=".k-i-seek-e",m=".k-i-arrow-w",g=".k-i-arrow-e",v="change",_=".kendoPager",b="click",w="keydown",y="disabled",k="down",x=e(document.documentElement),C=c.template('<a href="\\#" aria-label="#=text#" title="#=text#" class="k-link k-pager-nav #= wrapClassName #"><span class="k-icon #= className #"></span></a>'),S=u.extend({init:function(t,n){var o,d,y,x,C=this;u.fn.init.call(C,t,n),n=C.options,C.dataSource=c.data.DataSource.create(n.dataSource),C.linkTemplate=c.template(C.options.linkTemplate),C.selectTemplate=c.template(C.options.selectTemplate),C.currentPageTemplate=c.template(C.options.currentPageTemplate),o=C.page(),d=C.totalPages(),C._refreshHandler=h(C.refresh,C),C.dataSource.bind(v,C._refreshHandler),C.downEvent=c.applyEventMap(k,c.guid()),n.previousNext&&(C.element.find(f).length||(C.element.append(i(f,n.messages.first,"k-pager-first")),r(C.element,o,d)),C.element.find(m).length||(C.element.append(i(m,n.messages.previous)),s(C.element,o,d))),n.numeric&&(C.list=C.element.find(".k-pager-numbers"),C.list.length||(C.list=e('<ul class="k-pager-numbers k-reset" />').appendTo(C.element))),n.input&&(C.element.find(".k-pager-input").length||C.element.append('<span class="k-pager-input k-label">'+n.messages.page+'<input class="k-textbox">'+c.format(n.messages.of,d)+"</span>"),C.element.on(w+_,".k-pager-input input",h(C._keydown,C))),n.previousNext&&(C.element.find(g).length||(C.element.append(i(g,n.messages.next)),a(C.element,o,d)),C.element.find(p).length||(C.element.append(i(p,n.messages.last,"k-pager-last")),l(C.element,o,d))),n.pageSizes&&(C.element.find(".k-pager-sizes").length||(y=n.pageSizes.length?n.pageSizes:["all",5,10,20],x=e.map(y,function(e){return e.toLowerCase&&"all"===e.toLowerCase()?"<option value='all'>"+n.messages.allPages+"</option>":"<option>"+e+"</option>"}),e('<span class="k-pager-sizes k-label"><select/>'+n.messages.itemsPerPage+"</span>").appendTo(C.element).find("select").html(x.join("")).end().appendTo(C.element)),C.element.find(".k-pager-sizes select").val(C.pageSize()),c.ui.DropDownList&&C.element.find(".k-pager-sizes select").show().kendoDropDownList(),C.element.on(v+_,".k-pager-sizes select",h(C._change,C))),n.refresh&&(C.element.find(".k-pager-refresh").length||C.element.append('<a href="#" class="k-pager-refresh k-link" title="'+n.messages.refresh+'" aria-label="'+n.messages.refresh+'"><span class="k-icon k-i-reload"></span></a>'),C.element.on(b+_,".k-pager-refresh",h(C._refreshClick,C))),n.info&&(C.element.find(".k-pager-info").length||C.element.append('<span class="k-pager-info k-label" />')),C.element.on(b+_,"a",h(C._click,C)).addClass("k-pager-wrap k-widget k-floatwrap"),C.element.on(b+_,".k-current-page",h(C._toggleActive,C)),n.autoBind&&C.refresh(),c.notify(C)},destroy:function(){var e=this;u.fn.destroy.call(e),e.element.off(_),e.dataSource.unbind(v,e._refreshHandler),e._refreshHandler=null,c.destroy(e.element),e.element=e.list=null},events:[v],options:{name:"Pager",selectTemplate:'<li><span class="k-state-selected">#=text#</span></li>',currentPageTemplate:'<li class="k-current-page"><span class="k-link k-pager-nav">#=text#</span></li>',linkTemplate:'<li><a tabindex="-1" href="\\#" class="k-link" data-#=ns#page="#=idx#" #if (title !== "") {# title="#=title#" #}#>#=text#</a></li>',buttonCount:10,autoBind:!0,numeric:!0,info:!0,input:!1,previousNext:!0,pageSizes:!1,refresh:!1,messages:{allPages:"All",display:"{0} - {1} of {2} items",empty:"No items to display",page:"Page",of:"of {0}",itemsPerPage:"items per page",first:"Go to the first page",previous:"Go to the previous page",next:"Go to the next page",last:"Go to the last page",refresh:"Refresh",morePages:"More pages"}},setDataSource:function(e){var t=this;t.dataSource.unbind(v,t._refreshHandler),t.dataSource=t.options.dataSource=e,e.bind(v,t._refreshHandler),t.options.autoBind&&e.fetch()},refresh:function(t){var i,o,d,u,h,f,p=this,m=1,g=p.page(),v="",_=p.options,b=p.pageSize(),w=p.dataSource.total(),k=p.totalPages(),C=p.linkTemplate,S=_.buttonCount;if(x.unbind(p.downEvent,e.proxy(p._hideList,p)),!t||"itemchange"!=t.action){if(_.numeric){for(g>S&&(d=g%S,m=0===d?g-S+1:g-d+1),o=Math.min(m+S-1,k),m>1&&(v+=n(C,m-1,"...",!1,_.messages.morePages)),i=m;i<=o;i++)v+=n(i==g?p.selectTemplate:C,i,i,!0);o<k&&(v+=n(C,i,"...",!1,_.messages.morePages)),""===v&&(v=p.selectTemplate({text:0})),v=this.currentPageTemplate({text:g})+v,p.list.removeClass("k-state-expanded").html(v)}_.info&&(v=w>0?c.format(_.messages.display,Math.min((g-1)*b+1,w),Math.min(g*b,w),w):_.messages.empty,p.element.find(".k-pager-info").html(v)),_.input&&p.element.find(".k-pager-input").html(p.options.messages.page+'<input class="k-textbox" aria-label="'+g+'">'+c.format(_.messages.of,k)).find("input").val(g).attr(y,w<1).toggleClass("k-state-disabled",w<1),_.previousNext&&(r(p.element,g,k),s(p.element,g,k),a(p.element,g,k),l(p.element,g,k)),_.pageSizes&&(u=p.element.find(".k-pager-sizes option[value='all']").length>0,h=u&&b===this.dataSource.total(),f=b,h&&(b="all",f=_.messages.allPages),p.element.find(".k-pager-sizes select").val(b).attr("aria-label",b).filter("["+c.attr("role")+"=dropdownlist]").kendoDropDownList("value",b).kendoDropDownList("text",f))}},_keydown:function(e){if(e.keyCode===c.keys.ENTER){var t=this.element.find(".k-pager-input").find("input"),n=parseInt(t.val(),10);(isNaN(n)||n<1||n>this.totalPages())&&(n=this.page()),t.val(n),this.page(n)}},_refreshClick:function(e){e.preventDefault(),this.dataSource.read()},_change:function(e){var t=e.currentTarget.value,n=parseInt(t,10),i=this.dataSource;isNaN(n)?"all"==(t+"").toLowerCase()&&i.pageSize(i.total()):i.pageSize(n)},_toggleActive:function(){var t=this;t.list.hasClass("k-state-expanded")?x.unbind(t.downEvent,e.proxy(t._hideList,t)):x.bind(t.downEvent,e.proxy(t._hideList,t)),t.list.toggleClass("k-state-expanded")},_hideList:function(t){var n=this,i=c.eventTarget(t);e.contains(n.list[0],i)||(x.unbind(n.downEvent,e.proxy(n._hideList,n)),n.list.removeClass("k-state-expanded"))},_click:function(t){var n=e(t.currentTarget);t.preventDefault(),n.is(".k-state-disabled")||this.page(n.attr(c.attr("page")))},totalPages:function(){return Math.ceil((this.dataSource.total()||0)/(this.pageSize()||1))},pageSize:function(){return this.dataSource.pageSize()||this.dataSource.total()},page:function(e){return e===t?this.dataSource.total()>0?this.dataSource.page():0:(this.trigger("pageChange",{index:e})||(this.dataSource.page(e),this.trigger(v,{index:e})),t)}});d.plugin(S)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.notification.min",["kendo.core.min","kendo.popup.min"],e)}(function(){return function(e,t){var n=window.kendo,i=n.ui.Widget,o=e.proxy,r=e.extend,s=window.setTimeout,a="click",l="show",c="hide",d="k-notification",u=".k-notification-wrap .k-i-close",h="k-hiding",f="info",p="success",m="warning",g="error",v="top",_="left",b="bottom",w="right",y="up",k=".kendoNotification",x='<div class="k-widget k-notification"></div>',C='<div class="k-notification-wrap"><span class="k-icon k-i-#=typeIcon#" title="#=typeIcon#"></span>#=content#<span class="k-icon k-i-close" title="Hide"></span></div>',S=C.replace("#=content#","#:content#"),T=i.extend({init:function(t,o){var r=this;i.fn.init.call(r,t,o),o=r.options,o.appendTo&&e(o.appendTo).is(t)||r.element.hide(),r._compileTemplates(o.templates),r._guid="_"+n.guid(),r._isRtl=n.support.isRtl(t),r._compileStacking(o.stacking,o.position.top,o.position.left),n.notify(r)},events:[l,c],options:{name:"Notification",position:{pinned:!0,top:null,left:null,bottom:20,right:20},stacking:"default",hideOnClick:!0,button:!1,allowHideAfter:0,autoHideAfter:5e3,appendTo:null,width:null,height:null,templates:[],animation:{open:{effects:"fade:in",duration:300},close:{effects:"fade:out",duration:600,hide:!0}}},_compileTemplates:function(t){var i=this,o=n.template;i._compiled={},e.each(t,function(t,n){i._compiled[n.type]=o(n.template||e("#"+n.templateId).html())}),i._defaultCompiled=o(C),i._safeCompiled=o(S)},_getCompiled:function(e,t){var n=t?this._safeCompiled:this._defaultCompiled;return e?this._compiled[e]||n:n},_compileStacking:function(e,t,n){var i,o,r=this,s={paddingTop:0,paddingRight:0,paddingBottom:0,paddingLeft:0},a=null!==n?_:w;switch(e){case"down":i=b+" "+a,o=v+" "+a,delete s.paddingBottom;break;case w:i=v+" "+w,o=v+" "+_,delete s.paddingRight;break;case _:i=v+" "+_,o=v+" "+w,delete s.paddingLeft;break;case y:i=v+" "+a,o=b+" "+a,delete s.paddingTop;break;default:null!==t?(i=b+" "+a,o=v+" "+a,delete s.paddingBottom):(i=v+" "+a,o=b+" "+a,delete s.paddingTop)}r._popupOrigin=i,r._popupPosition=o,r._popupPaddings=s},_attachPopupEvents:function(e,t){function n(e){e.on(a+k,function(){o._hidePopup(t)})}var i,o=this,r=e.allowHideAfter,l=!isNaN(r)&&r>0;e.hideOnClick?t.bind("activate",function(){l?s(function(){n(t.element)},r):n(t.element)}):e.button&&(i=t.element.find(u),l?s(function(){n(i)},r):n(i))},_showPopup:function(t,i){var o,a,l=this,c=i.autoHideAfter,d=i.position.left,f=i.position.top;a=e("."+l._guid+":not(."+h+")").last(),o=new n.ui.Popup(t,{anchor:a[0]?a:document.body,origin:l._popupOrigin,position:l._popupPosition,animation:i.animation,modal:!0,collision:"",isRtl:l._isRtl,close:function(){l._triggerHide(this.element)},deactivate:function(e){e.sender.element.off(k),e.sender.element.find(u).off(k),e.sender.destroy()}}),l._attachPopupEvents(i,o),a[0]?o.open():(null===d&&(d=e(window).width()-t.width()-i.position.right),null===f&&(f=e(window).height()-t.height()-i.position.bottom),o.open(d,f)),o.wrapper.addClass(l._guid).css(r({margin:0,zIndex:10050},l._popupPaddings)),i.position.pinned?(o.wrapper.css("position","fixed"),a[0]&&l._togglePin(o.wrapper,!0)):a[0]||l._togglePin(o.wrapper,!1),c>0&&s(function(){l._hidePopup(o)},c)},_hidePopup:function(e){e.wrapper.addClass(h),e.close()},_togglePin:function(t,n){var i=e(window),o=n?-1:1;t.css({top:parseInt(t.css(v),10)+o*i.scrollTop(),left:parseInt(t.css(_),10)+o*i.scrollLeft()})},_attachStaticEvents:function(e,t){function n(e){e.on(a+k,o(i._hideStatic,i,t))}var i=this,r=e.allowHideAfter,l=!isNaN(r)&&r>0;e.hideOnClick?l?s(function(){n(t)},r):n(t):e.button&&(l?s(function(){n(t.find(u))},r):n(t.find(u)))},_showStatic:function(e,t){var n=this,i=t.autoHideAfter,o=t.animation,r=t.stacking==y||t.stacking==_?"prependTo":"appendTo";e.addClass(n._guid)[r](t.appendTo).hide().kendoAnimate(o.open||!1),n._attachStaticEvents(t,e),i>0&&s(function(){n._hideStatic(e)},i)},_hideStatic:function(e){e.kendoAnimate(r(this.options.animation.close||!1,{complete:function(){e.off(k).find(u).off(k),e.remove()}})),this._triggerHide(e)},_triggerHide:function(e){this.trigger(c,{element:e}),this.angular("cleanup",function(){return{elements:e}})},show:function(i,o,s){var a,c,u=this,h=u.options,p=e(x);return o||(o=f),null!==i&&i!==t&&""!==i&&(n.isFunction(i)&&(i=i()),c={typeIcon:o,content:""},a=e.isPlainObject(i)?r(c,i):r(c,{content:i}),p.addClass(d+"-"+o).toggleClass(d+"-button",h.button).attr("data-role","alert").css({width:h.width,height:h.height}).append(u._getCompiled(o,s)(a)),u.angular("compile",function(){return{elements:p,data:[{dataItem:a}]}}),e(h.appendTo)[0]?u._showStatic(p,h):u._showPopup(p,h),
u.trigger(l,{element:p})),u},showText:function(e,t){this.show(e,t,!0)},info:function(e){return this.show(e,f)},success:function(e){return this.show(e,p)},warning:function(e){return this.show(e,m)},error:function(e){return this.show(e,g)},hide:function(){var t=this,n=t.getNotifications();return n.each(t.options.appendTo?function(n,i){t._hideStatic(e(i))}:function(n,i){var o=e(i).data("kendoPopup");o&&t._hidePopup(o)}),t},getNotifications:function(){var t=this,n=e("."+t._guid+":not(."+h+")");return t.options.appendTo?n:n.children("."+d)},setOptions:function(e){var n,o=this;i.fn.setOptions.call(o,e),n=o.options,e.templates!==t&&o._compileTemplates(n.templates),e.stacking===t&&e.position===t||o._compileStacking(n.stacking,n.position.top,n.position.left)},destroy:function(){i.fn.destroy.call(this),this.getNotifications().off(k).find(u).off(k)}});n.ui.plugin(T)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.tooltip.min",["kendo.core.min","kendo.popup.min"],e)}(function(){return function(e,t){function n(e){for(;e.length;)i(e),e=e.parent()}function i(e){var t=e.data(s.ns+"title");t&&(e.attr("title",t),e.removeData(s.ns+"title"))}function o(e){var t=e.attr("title");t&&(e.data(s.ns+"title",t),e.attr("title",""))}function r(e){for(;e.length&&!e.is("body");)o(e),e=e.parent()}var s=window.kendo,a=s.ui.Widget,l=s.ui.Popup,c=s.isFunction,d=e.isPlainObject,u=e.extend,h=e.proxy,f=e(document),p=s.isLocalUrl,m="_tt_active",g="aria-describedby",v="show",_="hide",b="error",w="contentLoad",y="requestStart",k="k-content-frame",x='<div role="tooltip" class="k-widget k-tooltip#if (!autoHide) {# k-tooltip-closable#}#">#if (!autoHide) {# <div class="k-tooltip-button"><a href="\\#" class="k-icon k-i-close" title="Close"></a></div> #}#<div class="k-tooltip-content"></div>#if (callout){ #<div class="k-callout k-callout-#=dir#"></div>#}#</div>',C=s.template("<iframe frameborder='0' class='"+k+"' src='#= content.url #'>This page requires frames in order to show content</iframe>"),S=".kendoTooltip",T={bottom:{origin:"bottom center",position:"top center"},top:{origin:"top center",position:"bottom center"},left:{origin:"center left",position:"center right",collision:"fit flip"},right:{origin:"center right",position:"center left",collision:"fit flip"},center:{position:"center center",origin:"center center"}},D={top:"bottom",bottom:"top",left:"right",right:"left",center:"center"},A={bottom:"n",top:"s",left:"e",right:"w",center:"n"},E={horizontal:{offset:"top",size:"outerHeight"},vertical:{offset:"left",size:"outerWidth"}},M=function(e){return e.target.data(s.ns+"title")},I=a.extend({init:function(e,t){var n,i=this;a.fn.init.call(i,e,t),n=i.options.position.match(/left|right/)?"horizontal":"vertical",i.dimensions=E[n],i._documentKeyDownHandler=h(i._documentKeyDown,i),i.element.on(i.options.showOn+S,i.options.filter,h(i._showOn,i)).on("mouseenter"+S,i.options.filter,h(i._mouseenter,i)),this.options.autoHide&&i.element.on("mouseleave"+S,i.options.filter,h(i._mouseleave,i))},options:{name:"Tooltip",filter:"",content:M,showAfter:100,callout:!0,position:"bottom",showOn:"mouseenter",autoHide:!0,width:null,height:null,animation:{open:{effects:"fade:in",duration:0},close:{effects:"fade:out",duration:40,hide:!0}}},events:[v,_,w,b,y],_mouseenter:function(t){r(e(t.currentTarget))},_showOn:function(t){var n=this,i=e(t.currentTarget);n.options.showOn&&n.options.showOn.match(/click|focus/)?n._show(i):(clearTimeout(n.timeout),n.timeout=setTimeout(function(){n._show(i)},n.options.showAfter))},_appendContent:function(e){var t,n=this,i=n.options.content,o=n.content,r=n.options.iframe;d(i)&&i.url?("iframe"in n.options||(r=!p(i.url)),n.trigger(y,{options:i,target:e}),r?(o.hide(),t=o.find("."+k)[0],t?t.src=i.url||t.src:o.html(C({content:i})),o.find("."+k).off("load"+S).on("load"+S,function(){n.trigger(w),o.show()})):(o.empty(),s.ui.progress(o,!0),n._ajaxRequest(i))):i&&c(i)?(i=i({sender:this,target:e}),o.html(i||"")):o.html(i),n.angular("compile",function(){return{elements:o}})},_ajaxRequest:function(e){var t=this;jQuery.ajax(u({type:"GET",dataType:"html",cache:!1,error:function(e,n){s.ui.progress(t.content,!1),t.trigger(b,{status:n,xhr:e})},success:h(function(e){s.ui.progress(t.content,!1),t.content.html(e),t.trigger(w)},t)},e))},_documentKeyDown:function(e){e.keyCode===s.keys.ESC&&this.hide()},refresh:function(){var e=this,t=e.popup;t&&t.options.anchor&&e._appendContent(t.options.anchor)},hide:function(){this.popup&&this.popup.close()},show:function(e){e=e||this.element,r(e),this._show(e)},_show:function(e){var t=this,i=t.target();t.popup||t._initPopup(),i&&i[0]!=e[0]&&(t.popup.close(),t.popup.element.kendoStop(!0,!0)),i&&i[0]==e[0]||(t._appendContent(e),t.popup.options.anchor=e),t.popup.one("deactivate",function(){n(e),e.removeAttr(g),this.element.removeAttr("id").attr("aria-hidden",!0),f.off("keydown"+S,t._documentKeyDownHandler)}),t.popup.open()},_initPopup:function(){var t=this,n=t.options,i=e(s.template(x)({callout:n.callout&&"center"!==n.position,dir:A[n.position],autoHide:n.autoHide}));t.popup=new l(i,u({activate:function(){var e=this.options.anchor,i=e[0].id||t.element[0].id;i&&(e.attr(g,i+m),this.element.attr("id",i+m)),n.callout&&t._positionCallout(),this.element.removeAttr("aria-hidden"),f.on("keydown"+S,t._documentKeyDownHandler),t.trigger(v)},close:function(){t.trigger(_)},copyAnchorStyles:!1,animation:n.animation},T[n.position])),i.css({width:n.width,height:n.height}),t.content=i.find(".k-tooltip-content"),t.arrow=i.find(".k-callout"),n.autoHide?i.on("mouseleave"+S,h(t._mouseleave,t)):i.on("click"+S,".k-tooltip-button",h(t._closeButtonClick,t))},_closeButtonClick:function(e){e.preventDefault(),this.hide()},_mouseleave:function(t){if(this.popup){var i=e(t.currentTarget),o=i.offset(),r=t.pageX,a=t.pageY;if(o.right=o.left+s._outerWidth(i),o.bottom=o.top+s._outerHeight(i),r>o.left&&r<o.right&&a>o.top&&a<o.bottom)return;this.popup.close()}else n(e(t.currentTarget));clearTimeout(this.timeout)},_positionCallout:function(){var t=this,n=t.options.position,i=t.dimensions,o=i.offset,r=t.popup,s=r.options.anchor,a=e(s).offset(),l=parseInt(t.arrow.css("border-top-width"),10),c=e(r.element).offset(),d=A[r.flipped?D[n]:n],u=a[o]-c[o]+e(s)[i.size]()/2-l;t.arrow.removeClass("k-callout-n k-callout-s k-callout-w k-callout-e").addClass("k-callout-"+d).css(o,u)},target:function(){return this.popup?this.popup.options.anchor:null},destroy:function(){var e=this.popup;e&&(e.element.off(S),e.destroy()),clearTimeout(this.timeout),this.element.off(S),f.off("keydown"+S,this._documentKeyDownHandler),a.fn.destroy.call(this)}});s.ui.plugin(I)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.list.min",["kendo.data.min","kendo.popup.min"],e)}(function(){return function(e,t){function n(e,n){return e!==t&&""!==e&&null!==e&&("boolean"===n?e=!!e:"number"===n?e=+e:"string"===n&&(e=""+e)),e}function i(e){return e[e.length-1]}function o(e){var t=e.selectedIndex;return t>-1?e.options[t]:{}}function r(e,t){var n,i,o,r,s=t.length,a=e.length,l=[],c=[];if(a)for(o=0;o<a;o++){for(n=e[o],i=!1,r=0;r<s;r++)if(n===t[r]){i=!0,l.push({index:o,item:n});break}i||c.push(n)}return{changed:l,unchanged:c}}function s(t){return!(!t||e.isEmptyObject(t))&&!(t.filters&&!t.filters.length)}function a(t,n){var i,o=!1;return t.filters&&(i=e.grep(t.filters,function(e){return o=a(e,n),e.filters?e.filters.length:e.field!=n}),o||t.filters.length===i.length||(o=!0),t.filters=i),o}var l,c,d=window.kendo,u=d.ui,h=d._outerWidth,f=d._outerHeight,p=u.Widget,m=d.keys,g=d.support,v=d.htmlEncode,_=d._activeElement,b=d.data.ObservableArray,w="id",y="change",k="k-state-focused",x="k-state-hover",C="k-i-loading",S="k-hidden",T=".k-group-header",D="_label",A="open",E="close",M="cascade",I="select",R="selected",F="requestStart",z="requestEnd",P="width",B=e.extend,L=e.proxy,H=e.isArray,N=g.browser,O=N.msie,V=O&&N.version<9,U=/"/g,W={ComboBox:"DropDownList",DropDownList:"ComboBox"},q=d.ui.DataBoundWidget.extend({init:function(t,n){var i,o=this,r=o.ns;p.fn.init.call(o,t,n),t=o.element,n=o.options,o._isSelect=t.is(I),o._isSelect&&o.element[0].length&&(n.dataSource||(n.dataTextField=n.dataTextField||"text",n.dataValueField=n.dataValueField||"value")),o.ul=e('<ul unselectable="on" class="k-list k-reset"/>').attr({tabIndex:-1,"aria-hidden":!0}),o.list=e("<div class='k-list-container'/>").append(o.ul).on("mousedown"+r,L(o._listMousedown,o)),i=t.attr(w),i&&(o.list.attr(w,i+"-list"),o.ul.attr(w,i+"_listbox")),o._header(),o._noData(),o._footer(),o._accessors(),o._initValue()},options:{valuePrimitive:!1,footerTemplate:"",headerTemplate:"",noDataTemplate:"No data found."},setOptions:function(e){p.fn.setOptions.call(this,e),e&&e.enable!==t&&(e.enabled=e.enable),this._header(),this._noData(),this._footer(),this._renderFooter(),this._renderNoData()},focus:function(){this._focused.focus()},readonly:function(e){this._editable({readonly:e===t||e,disable:!1})},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)})},_listOptions:function(t){var n=this,i=n.options,o=i.virtual,r=L(n._listBound,n);return o="object"==typeof o?o:{},t=e.extend({autoBind:!1,selectable:!0,dataSource:n.dataSource,click:L(n._click,n),change:L(n._listChange,n),activate:L(n._activateItem,n),deactivate:L(n._deactivateItem,n),dataBinding:function(){n.trigger("dataBinding")},dataBound:r,height:i.height,dataValueField:i.dataValueField,dataTextField:i.dataTextField,groupTemplate:i.groupTemplate,fixedGroupTemplate:i.fixedGroupTemplate,template:i.template},t,o),t.template||(t.template="#:"+d.expr(t.dataTextField,"data")+"#"),i.$angular&&(t.$angular=i.$angular),t},_initList:function(){var e=this,t=e._listOptions({selectedItemChange:L(e._listChange,e)});e.listView=e.options.virtual?new d.ui.VirtualList(e.ul,t):new d.ui.StaticList(e.ul,t),e.listView.bind("listBound",L(e._listBound,e)),e._setListValue()},_setListValue:function(e){e=e||this.options.value,e!==t&&this.listView.value(e).done(L(this._updateSelectionState,this))},_updateSelectionState:e.noop,_listMousedown:function(e){this.filterInput&&this.filterInput[0]===e.target||e.preventDefault()},_isFilterEnabled:function(){var e=this.options.filter;return e&&"none"!==e},_hideClear:function(){var e=this;e._clear&&this._clear.addClass(S)},_showClear:function(){var e=this;e._clear&&this._clear.removeClass(S)},_clearValue:function(){this._clearText(),this._accessor(""),this.listView.value([]),this._isFilterEnabled()&&!this.options.enforceMinLength&&this._filter({word:"",open:!1}),this._change()},_clearText:function(){this.text("")},_clearFilter:function(){this.options.virtual||this.listView.bound(!1),this._filterSource()},_filterSource:function(e,t){var n,i,o=this,r=o.options,l=o.dataSource,c=B({},l.filter()||{}),d=e||c.filters&&c.filters.length&&!e,u=a(c,r.dataTextField);(e||u)&&o.trigger("filtering",{filter:e})||(n={filters:[],logic:"and"},s(e)&&n.filters.push(e),s(c)&&(n.logic===c.logic?n.filters=n.filters.concat(c.filters):n.filters.push(c)),o._cascading&&this.listView.setDSFilter(n),i=B({},{page:d?1:l.page(),pageSize:d?l.options.pageSize:l.pageSize(),sort:l.sort(),filter:l.filter(),group:l.group(),aggregate:l.aggregate()},{filter:n}),l[t?"read":"query"](l._mergeState(i)))},_angularElement:function(e,t){e&&this.angular(t,function(){return{elements:e}})},_noData:function(){var n=e(this.noData),i=this.options.noDataTemplate;return this.angular("cleanup",function(){return{elements:n}}),d.destroy(n),n.remove(),i?(this.noData=e('<div class="k-nodata" style="display:none"><div></div></div>').appendTo(this.list),this.noDataTemplate="function"!=typeof i?d.template(i):i,t):(this.noData=null,t)},_renderNoData:function(){var e=this.noData;e&&(this._angularElement(e,"cleanup"),e.children(":first").html(this.noDataTemplate({instance:this})),this._angularElement(e,"compile"))},_toggleNoData:function(t){e(this.noData).toggle(t)},_toggleHeader:function(e){var t=this.listView.content.prev(T);t.toggle(e)},_footer:function(){var n=e(this.footer),i=this.options.footerTemplate;return this._angularElement(n,"cleanup"),d.destroy(n),n.remove(),i?(this.footer=e('<div class="k-footer"></div>').appendTo(this.list),this.footerTemplate="function"!=typeof i?d.template(i):i,t):(this.footer=null,t)},_renderFooter:function(){var e=this.footer;e&&(this._angularElement(e,"cleanup"),e.html(this.footerTemplate({instance:this})),this._angularElement(e,"compile"))},_header:function(){var n,i=e(this.header),o=this.options.headerTemplate;return this._angularElement(i,"cleanup"),d.destroy(i),i.remove(),o?(n="function"!=typeof o?d.template(o):o,i=e(n({})),this.header=i[0]?i:null,this.list.prepend(i),this._angularElement(this.header,"compile"),t):(this.header=null,t)},_allowOpening:function(){return this.options.noDataTemplate||this.dataSource.flatView().length},_initValue:function(){var e=this,t=e.options.value;null!==t?e.element.val(t):(t=e._accessor(),e.options.value=t),e._old=t},_ignoreCase:function(){var e,t=this,n=t.dataSource.reader.model;n&&n.fields&&(e=n.fields[t.options.dataTextField],e&&e.type&&"string"!==e.type&&(t.options.ignoreCase=!1))},_focus:function(e){return this.listView.focus(e)},_filter:function(e){var t=this,n=t.options,i=n.ignoreCase,o=n.dataTextField,r={value:i?e.word.toLowerCase():e.word,field:o,operator:n.filter,ignoreCase:i};t._open=e.open,t._filterSource(r)},search:function(e){var t=this.options;e="string"==typeof e?e:this._inputValue(),clearTimeout(this._typingTimeout),(!t.enforceMinLength&&!e.length||e.length>=t.minLength)&&(this._state="filter",this._isFilterEnabled()?this._filter({word:e,open:!0}):this._searchByWord(e))},current:function(e){return this._focus(e)},items:function(){return this.ul[0].children},destroy:function(){var e=this,t=e.ns;p.fn.destroy.call(e),e._unbindDataSource(),e.listView.destroy(),e.list.off(t),e.popup.destroy(),e._form&&e._form.off("reset",e._resetHandler)},dataItem:function(n){var i=this;if(n===t)return i.listView.selectedDataItems()[0];if("number"!=typeof n){if(i.options.virtual)return i.dataSource.getByUid(e(n).data("uid"));n=e(i.items()).index(n)}return i.dataSource.flatView()[n]},_activateItem:function(){var e=this.listView.focus();e&&this._focused.add(this.filterInput).attr("aria-activedescendant",e.attr("id"))},_deactivateItem:function(){this._focused.add(this.filterInput).removeAttr("aria-activedescendant")},_accessors:function(){var e=this,t=e.element,n=e.options,i=d.getter,o=t.attr(d.attr("text-field")),r=t.attr(d.attr("value-field"));!n.dataTextField&&o&&(n.dataTextField=o),!n.dataValueField&&r&&(n.dataValueField=r),e._text=i(n.dataTextField),e._value=i(n.dataValueField)},_aria:function(e){var n=this,i=n.options,o=n._focused.add(n.filterInput);i.suggest!==t&&o.attr("aria-autocomplete",i.suggest?"both":"list"),e=e?e+" "+n.ul[0].id:n.ul[0].id,o.attr("aria-owns",e),n.ul.attr("aria-live",n._isFilterEnabled()?"polite":"off"),n._ariaLabel()},_ariaLabel:function(){var t,n=this,i=n._focused,o=n.element,r=o.attr("id"),s=e("label[for='"+r+"']"),a=o.attr("aria-label"),l=o.attr("aria-labelledby");i!==o&&(a?i.attr("aria-label",a):l?i.attr("aria-labelledby",l):s.length&&(t=s.attr("id")||n._generateLabelId(s,r),i.attr("aria-labelledby",t)))},_generateLabelId:function(e,t){var n=t+D;return e.attr("id",n),n},_blur:function(){var e=this;e._change(),e.close()},_change:function(){var e,i=this,o=i.selectedIndex,r=i.options.value,s=i.value();i._isSelect&&!i.listView.bound()&&r&&(s=r),s!==n(i._old,typeof s)?e=!0:o!==t&&o!==i._oldIndex&&(e=!0),e&&(i._old=s,i._oldIndex=o,i._typing||i.element.trigger(y),i.trigger(y)),i.typing=!1},_data:function(){return this.dataSource.view()},_enable:function(){var e=this,n=e.options,i=e.element.is("[disabled]");n.enable!==t&&(n.enabled=n.enable),!n.enabled||i?e.enable(!1):e.readonly(e.element.is("[readonly]"))},_dataValue:function(e){var n=this._value(e);return n===t&&(n=this._text(e)),n},_offsetHeight:function(){var t=0,n=this.listView.content.prevAll(":visible");return n.each(function(){var n=e(this);t+=f(n,!0)}),t},_height:function(n){var i,o,r,s=this,a=s.list,l=s.options.height,c=s.popup.visible();if(n||s.options.noDataTemplate){if(o=a.add(a.parent(".k-animation-container")).show(),!a.is(":visible"))return o.hide(),t;l=s.listView.content[0].scrollHeight>l?l:"auto",o.height(l),"auto"!==l&&(i=s._offsetHeight(),r=f(e(s.footer))||0,l=l-i-r),s.listView.content.height(l),c||o.hide()}return l},_adjustListWidth:function(){var e,t,n=this.list,i=n[0].style.width,o=this.wrapper;if(n.data(P)||!i)return e=window.getComputedStyle?window.getComputedStyle(o[0],null):0,t=parseFloat(e&&e.width)||h(o),e&&N.msie&&(t+=parseFloat(e.paddingLeft)+parseFloat(e.paddingRight)+parseFloat(e.borderLeftWidth)+parseFloat(e.borderRightWidth)),i="border-box"!==n.css("box-sizing")?t-(h(n)-n.width()):t,n.css({fontFamily:o.css("font-family"),width:this.options.autoWidth?"auto":i,minWidth:i}).data(P,i),!0},_openHandler:function(e){this._adjustListWidth(),this.trigger(A)?e.preventDefault():(this._focused.attr("aria-expanded",!0),this.ul.attr("aria-hidden",!1))},_closeHandler:function(e){this.trigger(E)?e.preventDefault():(this._focused.attr("aria-expanded",!1),this.ul.attr("aria-hidden",!0))},_focusItem:function(){var e=this.listView,n=!e.focus(),o=i(e.select());o===t&&this.options.highlightFirst&&n&&(o=0),o!==t?e.focus(o):n&&e.scrollToIndex(0)},_calculateGroupPadding:function(e){var t=this.ul.children(".k-first:first"),n=this.listView.content.prev(T),i=0;n[0]&&"none"!==n[0].style.display&&("auto"!==e&&(i=d.support.scrollbar()),i+=parseFloat(t.css("border-right-width"),10)+parseFloat(t.children(".k-group").css("padding-right"),10),n.css("padding-right",i))},_calculatePopupHeight:function(e){var t=this._height(this.dataSource.flatView().length||e);this._calculateGroupPadding(t)},_resizePopup:function(e){this.options.virtual||(this.popup.element.is(":visible")?this._calculatePopupHeight(e):this.popup.one("open",function(e){return L(function(){this._calculatePopupHeight(e)},this)}.call(this,e)))},_popup:function(){var e=this;e.popup=new u.Popup(e.list,B({},e.options.popup,{anchor:e.wrapper,open:L(e._openHandler,e),close:L(e._closeHandler,e),animation:e.options.animation,isRtl:g.isRtl(e.wrapper),autosize:e.options.autoWidth}))},_makeUnselectable:function(){V&&this.list.find("*").not(".k-textbox").attr("unselectable","on")},_toggleHover:function(t){e(t.currentTarget).toggleClass(x,"mouseenter"===t.type)},_toggle:function(e,n){var i=this,o=g.mobileOS&&(g.touch||g.MSPointers||g.pointers);e=e!==t?e:!i.popup.visible(),n||o||i._focused[0]===_()||(i._prevent=!0,i._focused.focus(),i._prevent=!1),i[e?A:E]()},_triggerCascade:function(){var e=this;e._cascadeTriggered&&e._old===e.value()&&e._oldIndex===e.selectedIndex||(e._cascadeTriggered=!0,e.trigger(M,{userTriggered:e._userTriggered}))},_triggerChange:function(){this._valueBeforeCascade!==this.value()&&this.trigger(y)},_unbindDataSource:function(){var e=this;e.dataSource.unbind(F,e._requestStartHandler).unbind(z,e._requestEndHandler).unbind("error",e._errorHandler)},requireValueMapper:function(e,t){var n=(e.value instanceof Array?e.value.length:e.value)||(t instanceof Array?t.length:t);if(n&&e.virtual&&"function"!=typeof e.virtual.valueMapper)throw Error("ValueMapper is not provided while the value is being set. See http://docs.telerik.com/kendo-ui/controls/editors/combobox/virtualization#the-valuemapper-function")}});B(q,{inArray:function(e,t){var n,i,o=t.children;if(!e||e.parentNode!==t)return-1;for(n=0,i=o.length;n<i;n++)if(e===o[n])return n;return-1},unifyType:n}),d.ui.List=q,u.Select=q.extend({init:function(e,t){q.fn.init.call(this,e,t),this._initial=this.element.val()},setDataSource:function(e){var t,n=this;n.options.dataSource=e,n._dataSource(),n.listView.bound()&&(n._initialIndex=null),n.listView.setDataSource(n.dataSource),n.options.autoBind&&n.dataSource.fetch(),t=n._parentWidget(),t&&n._cascadeSelect(t)},close:function(){this.popup.close()},select:function(e){var n=this;return e===t?n.selectedIndex:n._select(e).done(function(){n._old=n._accessor(),n._oldIndex=n.selectedIndex})},_accessor:function(e,t){return this[this._isSelect?"_accessorSelect":"_accessorInput"](e,t)},_accessorInput:function(e){var n=this.element[0];return e===t?n.value:(null===e&&(e=""),n.value=e,t)},_accessorSelect:function(e,n){var i,r=this.element[0];return e===t?o(r).value||"":(o(r).selected=!1,n===t&&(n=-1),i=null!==e&&""!==e,i&&n==-1?this._custom(e):e?r.value=e:r.selectedIndex=n,t)},_custom:function(t){var n=this,i=n.element,o=n._customOption;o||(o=e("<option/>"),n._customOption=o,i.append(o)),o.text(t),o[0].selected=!0},_hideBusy:function(){var e=this;clearTimeout(e._busy),e._arrowIcon.removeClass(C),e._focused.attr("aria-busy",!1),e._busy=null,e._showClear()},_showBusy:function(e){var t=this;e.isDefaultPrevented()||(t._request=!0,t._busy||(t._busy=setTimeout(function(){t._arrowIcon&&(t._focused.attr("aria-busy",!0),t._arrowIcon.addClass(C),t._hideClear())},100)))},_requestEnd:function(){this._request=!1,this._hideBusy()},_dataSource:function(){var t,n=this,i=n.element,o=n.options,r=o.dataSource||{};r=e.isArray(r)?{data:r}:r,n._isSelect&&(t=i[0].selectedIndex,t>-1&&(o.index=t),r.select=i,r.fields=[{field:o.dataTextField},{field:o.dataValueField}]),n.dataSource?n._unbindDataSource():(n._requestStartHandler=L(n._showBusy,n),n._requestEndHandler=L(n._requestEnd,n),n._errorHandler=L(n._hideBusy,n)),n.dataSource=d.data.DataSource.create(r).bind(F,n._requestStartHandler).bind(z,n._requestEndHandler).bind("error",n._errorHandler)},_firstItem:function(){this.listView.focusFirst()},_lastItem:function(){this.listView.focusLast()},_nextItem:function(){this.listView.focusNext()},_prevItem:function(){this.listView.focusPrev()},_move:function(e){var n,i,o,r,s,a,l=this,c=l.listView,d=e.keyCode,u=d===m.DOWN;if(d===m.UP||u){if(e.altKey)l.toggle(u);else{if(!c.bound())return l._fetch||(l.dataSource.one(y,function(){l._fetch=!1,l._move(e)}),l._fetch=!0,l._filterSource()),e.preventDefault(),!0;if(o=l._focus(),l._fetch||o&&!o.hasClass("k-state-selected")||(u?(l._nextItem(),l._focus()||l._lastItem()):(l._prevItem(),l._focus()||l._firstItem())),n=c.dataItemByIndex(c.getElementIndex(l._focus())),l.trigger(I,{dataItem:n,item:l._focus()}))return l._focus(o),t;l._select(l._focus(),!0).done(function(){l.popup.visible()||l._blur()})}e.preventDefault(),i=!0}else if(d===m.ENTER||d===m.TAB){if(l.popup.visible()&&e.preventDefault(),o=l._focus(),n=l.dataItem(),l.popup.visible()||n&&l.text()===l._text(n)||(o=null),r=l.filterInput&&l.filterInput[0]===_(),o){if(n=c.dataItemByIndex(c.getElementIndex(o)),s=!0,n&&(s=l._value(n)!==q.unifyType(l.value(),typeof l._value(n))),s&&l.trigger(I,{dataItem:n,item:o}))return;l._select(o)}else l.input&&(l._accessor(l.input.val()),l.listView.value(l.input.val()));l._focusElement&&l._focusElement(l.wrapper),r&&d===m.TAB?l.wrapper.focusout():l._blur(),l.close(),i=!0}else d===m.ESC?(l.popup.visible()&&e.preventDefault(),l.close(),i=!0):!l.popup.visible()||d!==m.PAGEDOWN&&d!==m.PAGEUP||(e.preventDefault(),a=d===m.PAGEDOWN?1:-1,c.scrollWith(a*c.screenHeight()),i=!0);return i},_fetchData:function(){var e=this,t=!!e.dataSource.view().length;e._request||e.options.cascadeFrom||e.listView.bound()||e._fetch||t||(e._fetch=!0,e.dataSource.fetch().done(function(){e._fetch=!1}))},_options:function(e,n,i){var r,s,a,l,c=this,d=c.element,u=d[0],h=e.length,f="",p=0;for(n&&(f=n);p<h;p++)r="<option",s=e[p],a=c._text(s),l=c._value(s),l!==t&&(l+="",l.indexOf('"')!==-1&&(l=l.replace(U,"&quot;")),r+=' value="'+l+'"'),r+=">",a!==t&&(r+=v(a)),r+="</option>",f+=r;d.html(f),i!==t&&(u.value=i,u.value&&!i&&(u.selectedIndex=-1)),u.selectedIndex!==-1&&(r=o(u),r&&r.setAttribute(R,R))},_reset:function(){var t=this,n=t.element,i=n.attr("form"),o=i?e("#"+i):n.closest("form");o[0]&&(t._resetHandler=function(){setTimeout(function(){t.value(t._initial)})},t._form=o.on("reset",t._resetHandler))},_parentWidget:function(){var t,n,i=this.options.name;if(this.options.cascadeFrom)return t=e("#"+this.options.cascadeFrom),n=t.data("kendo"+i),n||(n=t.data("kendo"+W[i])),n},_cascade:function(){var e,t=this,n=t.options,i=n.cascadeFrom;if(i){if(e=t._parentWidget(),!e)return;t._cascadeHandlerProxy=L(t._cascadeHandler,t),t._cascadeFilterRequests=[],n.autoBind=!1,e.bind("set",function(){t.one("set",function(e){t._selectedValue=e.value})}),e.first(M,t._cascadeHandlerProxy),e.listView.bound()?(t._toggleCascadeOnFocus(),t._cascadeSelect(e)):(e.one("dataBound",function(){t._toggleCascadeOnFocus()}),e.value()||t.enable(!1))}},_toggleCascadeOnFocus:function(){var e=this,t=e._parentWidget(),n=O?"blur":"focusout";t._focused.add(t.filterInput).bind("focus",function(){t.unbind(M,e._cascadeHandlerProxy),t.first(y,e._cascadeHandlerProxy)}),t._focused.add(t.filterInput).bind(n,function(){t.unbind(y,e._cascadeHandlerProxy),t.first(M,e._cascadeHandlerProxy)})},_cascadeHandler:function(e){var t=this._parentWidget(),n=this.value();this._userTriggered=e.userTriggered,this.listView.bound()&&this._clearSelection(t,!0),this._cascadeSelect(t,n)},_cascadeChange:function(e){var t=this,n=t._accessor()||t._selectedValue;t._cascadeFilterRequests.length||(t._selectedValue=null),t._userTriggered?t._clearSelection(e,!0):n?(n!==t.listView.value()[0]&&t.value(n),t.dataSource.view()[0]&&t.selectedIndex!==-1||t._clearSelection(e,!0)):t.dataSource.flatView().length&&t.select(t.options.index),t.enable(),t._triggerCascade(),t._triggerChange(),t._userTriggered=!1},_cascadeSelect:function(e,n){var i,o,r=this,s=e.dataItem(),l=s?e._value(s):null,c=r.options.cascadeFromField||e.options.dataValueField;r._valueBeforeCascade=n!==t?n:r.value(),l||0===l?(i=r.dataSource.filter()||{},a(i,c),o=function(){var t=r._cascadeFilterRequests.shift();t&&r.unbind("dataBound",t),t=r._cascadeFilterRequests[0],t&&r.first("dataBound",t),r._cascadeChange(e)},r._cascadeFilterRequests.push(o),1===r._cascadeFilterRequests.length&&r.first("dataBound",o),r._cascading=!0,r._filterSource({field:c,operator:"eq",value:l}),r._cascading=!1):(r.enable(!1),r._clearSelection(e),r._triggerCascade(),r._triggerChange(),r._userTriggered=!1)}}),l=".StaticList",c=d.ui.DataBoundWidget.extend({init:function(t,n){p.fn.init.call(this,t,n),this.element.attr("role","listbox").on("click"+l,"li",L(this._click,this)).on("mouseenter"+l,"li",function(){e(this).addClass(x)}).on("mouseleave"+l,"li",function(){e(this).removeClass(x)}),this.content=this.element.wrap("<div class='k-list-scroller' unselectable='on'></div>").parent(),this.header=this.content.before('<div class="k-group-header" style="display:none"></div>').prev(),this.bound(!1),this._optionID=d.guid(),this._selectedIndices=[],this._view=[],this._dataItems=[],this._values=[];var i=this.options.value;i&&(this._values=e.isArray(i)?i.slice(0):[i]),this._getter(),this._templates(),this.setDataSource(this.options.dataSource),this._onScroll=L(function(){var e=this;clearTimeout(e._scrollId),e._scrollId=setTimeout(function(){e._renderHeader()},50)},this)},options:{name:"StaticList",dataValueField:null,valuePrimitive:!1,selectable:!0,template:null,groupTemplate:null,fixedGroupTemplate:null},events:["click",y,"activate","deactivate","dataBinding","dataBound","selectedItemChange"],setDataSource:function(t){var n,i=this,o=t||{};o=e.isArray(o)?{data:o}:o,o=d.data.DataSource.create(o),i.dataSource?(i.dataSource.unbind(y,i._refreshHandler),n=i.value(),i.value([]),i.bound(!1),i.value(n)):i._refreshHandler=L(i.refresh,i),i.setDSFilter(o.filter()),i.dataSource=o.bind(y,i._refreshHandler),i._fixedHeader()},skip:function(){return this.dataSource.skip()},setOptions:function(e){p.fn.setOptions.call(this,e),this._getter(),this._templates(),this._render()},destroy:function(){this.element.off(l),this._refreshHandler&&this.dataSource.unbind(y,this._refreshHandler),clearTimeout(this._scrollId),p.fn.destroy.call(this)},dataItemByIndex:function(e){return this.dataSource.flatView()[e]},screenHeight:function(){return this.content[0].clientHeight},scrollToIndex:function(e){var t=this.element[0].children[e];t&&this.scroll(t)},scrollWith:function(e){this.content.scrollTop(this.content.scrollTop()+e)},scroll:function(e){if(e){e[0]&&(e=e[0]);var t=this.content[0],n=e.offsetTop,i=e.offsetHeight,o=t.scrollTop,r=t.clientHeight,s=n+i;o>n?o=n:s>o+r&&(o=s-r),t.scrollTop=o}},selectedDataItems:function(e){return e===t?this._dataItems.slice():(this._dataItems=e,this._values=this._getValues(e),t)},_getValues:function(t){var n=this._valueGetter;return e.map(t,function(e){return n(e)})},focusNext:function(){var e=this.focus();e=e?e.next():0,this.focus(e)},focusPrev:function(){var e=this.focus();e=e?e.prev():this.element[0].children.length-1,this.focus(e)},focusFirst:function(){this.focus(this.element[0].children[0])},focusLast:function(){this.focus(i(this.element[0].children))},focus:function(n){var o,r=this,s=r._optionID;return n===t?r._current:(n=i(r._get(n)),n=e(this.element[0].children[n]),r._current&&(r._current.removeClass(k).removeAttr("aria-selected").removeAttr(w),r.trigger("deactivate")),o=!!n[0],o&&(n.addClass(k),r.scroll(n),n.attr("id",s)),r._current=o?n:null,r.trigger("activate"),t)},focusIndex:function(){return this.focus()?this.focus().index():t},skipUpdate:function(e){this._skipUpdate=e},select:function(n){var o,r,s,a=this,l=a.options.selectable,c="multiple"!==l&&l!==!1,d=a._selectedIndices,u=[],h=[];return n===t?d.slice():(n=a._get(n),1===n.length&&n[0]===-1&&(n=[]),r=e.Deferred().resolve(),s=a.isFiltered(),s&&!c&&a._deselectFiltered(n)?r:c&&!s&&e.inArray(i(n),d)!==-1?(a._dataItems.length&&a._view.length&&(a._dataItems=[a._view[d[0]].item]),r):(o=a._deselect(n),h=o.removed,n=o.indices,n.length&&(c&&(n=[i(n)]),u=a._select(n)),(u.length||h.length)&&(a._valueComparer=null,a.trigger(y,{added:u,removed:h})),r))},removeAt:function(e){return this._selectedIndices.splice(e,1),this._values.splice(e,1),this._valueComparer=null,{position:e,dataItem:this._dataItems.splice(e,1)[0]}},setValue:function(t){t=e.isArray(t)||t instanceof b?t.slice(0):[t],this._values=t,this._valueComparer=null},value:function(n){var i,o=this,r=o._valueDeferred;return n===t?o._values.slice():(o.setValue(n),r&&"resolved"!==r.state()||(o._valueDeferred=r=e.Deferred()),o.bound()&&(i=o._valueIndices(o._values),"multiple"===o.options.selectable&&o.select(-1),o.select(i),r.resolve()),o._skipUpdate=!1,r)},items:function(){return this.element.children(".k-item")},_click:function(t){t.isDefaultPrevented()||this.trigger("click",{item:e(t.currentTarget)})||this.select(t.currentTarget)},_valueExpr:function(e,t){var i,o,r=this,s=0,a=[];if(!r._valueComparer||r._valueType!==e){for(r._valueType=e;s<t.length;s++)a.push(n(t[s],e));i="for (var idx = 0; idx < "+a.length+"; idx++) { if (current === values[idx]) {   return idx; }} return -1;",o=Function("current","values",i),r._valueComparer=function(e){return o(e,a)}}return r._valueComparer},_dataItemPosition:function(e,t){var n=this._valueGetter(e),i=this._valueExpr(typeof n,t);return i(n)},_getter:function(){this._valueGetter=d.getter(this.options.dataValueField)},_deselect:function(t){var n,i,o,r=this,s=r.element[0].children,a=r.options.selectable,l=r._selectedIndices,c=r._dataItems,d=r._values,u=[],h=0,f=0;if(t=t.slice(),a!==!0&&t.length){if("multiple"===a)for(;h<t.length;h++)if(i=t[h],e(s[i]).hasClass("k-state-selected"))for(n=0;n<l.length;n++)if(o=l[n],o===i){e(s[o]).removeClass("k-state-selected"),u.push({position:n+f,dataItem:c.splice(n,1)[0]}),l.splice(n,1),t.splice(h,1),d.splice(n,1),f+=1,h-=1,n-=1;break}}else{for(;h<l.length;h++)e(s[l[h]]).removeClass("k-state-selected"),u.push({position:h,dataItem:c[h]});r._values=[],r._dataItems=[],r._selectedIndices=[]}return{indices:t,removed:u}},_deselectFiltered:function(t){for(var n,i,o,r=this.element[0].children,s=[],a=0;a<t.length;a++)i=t[a],n=this._view[i].item,o=this._dataItemPosition(n,this._values),o>-1&&(s.push(this.removeAt(o)),e(r[i]).removeClass("k-state-selected"));return!!s.length&&(this.trigger(y,{
added:[],removed:s}),!0)},_select:function(t){var n,o,r=this,s=r.element[0].children,a=r._view,l=[],c=0;for(i(t)!==-1&&r.focus(t);c<t.length;c++)o=t[c],n=a[o],o!==-1&&n&&(n=n.item,r._selectedIndices.push(o),r._dataItems.push(n),r._values.push(r._valueGetter(n)),e(s[o]).addClass("k-state-selected").attr("aria-selected",!0),l.push({dataItem:n}));return l},getElementIndex:function(t){return e(t).data("offset-index")},_get:function(e){return"number"==typeof e?e=[e]:H(e)||(e=this.getElementIndex(e),e=[e!==t?e:-1]),e},_template:function(){var e=this,t=e.options,n=t.template;return n?(n=d.template(n),n=function(e){return'<li tabindex="-1" role="option" unselectable="on" class="k-item">'+n(e)+"</li>"}):n=d.template('<li tabindex="-1" role="option" unselectable="on" class="k-item">${'+d.expr(t.dataTextField,"data")+"}</li>",{useWithBlock:!1}),n},_templates:function(){var e,t,n=this.options,i={template:n.template,groupTemplate:n.groupTemplate,fixedGroupTemplate:n.fixedGroupTemplate};for(t in i)e=i[t],e&&"function"!=typeof e&&(i[t]=d.template(e));this.templates=i},_normalizeIndices:function(e){for(var n=[],i=0;i<e.length;i++)e[i]!==t&&n.push(e[i]);return n},_valueIndices:function(e,t){var n,i=this._view,o=0;if(t=t?t.slice():[],!e.length)return[];for(;o<i.length;o++)n=this._dataItemPosition(i[o].item,e),n!==-1&&(t[n]=o);return this._normalizeIndices(t)},_firstVisibleItem:function(){for(var t=this.element[0],n=this.content[0],i=n.scrollTop,o=e(t.children[0]).height(),r=Math.floor(i/o)||0,s=t.children[r]||t.lastChild,a=s.offsetTop<i;s;)if(a){if(s.offsetTop+o>i||!s.nextSibling)break;s=s.nextSibling}else{if(s.offsetTop<=i||!s.previousSibling)break;s=s.previousSibling}return this._view[e(s).data("offset-index")]},_fixedHeader:function(){this.isGrouped()&&this.templates.fixedGroupTemplate?(this.header.show(),this.content.scroll(this._onScroll)):(this.header.hide(),this.content.off("scroll",this._onScroll))},_renderHeader:function(){var e,t=this.templates.fixedGroupTemplate;t&&(e=this._firstVisibleItem(),e&&this.header.html(t(e.group)))},_renderItem:function(e){var t='<li tabindex="-1" role="option" unselectable="on" class="k-item',n=e.item,i=0!==e.index,o=e.selected;return i&&e.newGroup&&(t+=" k-first"),o&&(t+=" k-state-selected"),t+='"'+(o?' aria-selected="true"':"")+' data-offset-index="'+e.index+'">',t+=this.templates.template(n),i&&e.newGroup&&(t+='<div class="k-group">'+this.templates.groupTemplate(e.group)+"</div>"),t+"</li>"},_render:function(){var e,t,n,i,o="",r=0,s=0,a=[],l=this.dataSource.view(),c=this.value(),d=this.isGrouped();if(d)for(r=0;r<l.length;r++)for(t=l[r],n=!0,i=0;i<t.items.length;i++)e={selected:this._selected(t.items[i],c),item:t.items[i],group:t.value,newGroup:n,index:s},a[s]=e,s+=1,o+=this._renderItem(e),n=!1;else for(r=0;r<l.length;r++)e={selected:this._selected(l[r],c),item:l[r],index:r},a[r]=e,o+=this._renderItem(e);this._view=a,this.element[0].innerHTML=o,d&&a.length&&this._renderHeader()},_selected:function(e,t){var n=!this.isFiltered()||"multiple"===this.options.selectable;return n&&this._dataItemPosition(e,t)!==-1},setDSFilter:function(e){this._lastDSFilter=B({},e)},isFiltered:function(){return this._lastDSFilter||this.setDSFilter(this.dataSource.filter()),!d.data.Query.compareFilters(this.dataSource.filter(),this._lastDSFilter)},refresh:function(e){var t,n=this,i=e&&e.action,o=n.options.skipUpdateOnBind,s="itemchange"===i;n.trigger("dataBinding"),n._angularItems("cleanup"),n._fixedHeader(),n._render(),n.bound(!0),s||"remove"===i?(t=r(n._dataItems,e.items),t.changed.length&&(s?n.trigger("selectedItemChange",{items:t.changed}):n.value(n._getValues(t.unchanged)))):n.isFiltered()||n._skipUpdate?(n.focus(0),n._skipUpdate&&(n._skipUpdate=!1,n._selectedIndices=n._valueIndices(n._values,n._selectedIndices))):o||i&&"add"!==i||n.value(n._values),n._valueDeferred&&n._valueDeferred.resolve(),n._angularItems("compile"),n.trigger("dataBound")},bound:function(e){return e===t?this._bound:(this._bound=e,t)},isGrouped:function(){return(this.dataSource.group()||[]).length}}),u.plugin(c)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.calendar.min",["kendo.core.min"],e)}(function(){return function(e,t){function n(e,t,n,i){var o,r=e.getFullYear(),s=t.getFullYear(),a=n.getFullYear();return r-=r%i,o=r+(i-1),r<s&&(r=s),o>a&&(o=a),r+"-"+o}function i(e){var t,n=0,i=e.min,o=e.max,r=e.start,s=e.setter,l=e.build,c=e.weekNumberBuild,d=e.cells||12,u=e.isWeekColumnVisible,h=e.perRow||4,f=e.weekNumber||O,p=e.content||H,m=e.empty||N,g=e.html||'<table tabindex="0" role="grid" class="k-content k-meta-view" cellspacing="0"><tbody><tr role="row">';for(u&&(g+=f(c(r)));n<d;n++)n>0&&n%h===0&&(g+='</tr><tr role="row">',u&&(g+=f(c(r)))),r=new Se(r.getFullYear(),r.getMonth(),r.getDate(),0,0,0),M(r,0),t=l(r,n,e.disableDates),g+=a(r,i,o)?p(t):m(t),s(r,1);return g+"</tr></tbody></table>"}function o(e,t,n){var i=e.getFullYear(),o=t.getFullYear(),r=o,s=0;return n&&(o-=o%n,r=o-o%n+n-1),i>r?s=1:i<o&&(s=-1),s}function r(){var e=new Se;return new Se(e.getFullYear(),e.getMonth(),e.getDate())}function s(e,t,n){var i=r();return e&&(i=new Se((+e))),t>i?i=new Se((+t)):n<i&&(i=new Se((+n))),i}function a(e,t,n){return+e>=+t&&+e<=+n}function l(e,t){return e.slice(t).concat(e.slice(0,t))}function c(e,t,n){t=t instanceof Se?t.getFullYear():e.getFullYear()+n*t,e.setFullYear(t)}function d(t){var n=e(this).hasClass("k-state-disabled");n||e(this).toggleClass(ie,fe.indexOf(t.type)>-1||t.type==ue)}function u(e){e.preventDefault()}function h(e){return P(e).calendars.standard}function f(e){var n=Te[e.start],i=Te[e.depth],o=P(e.culture);e.format=F(e.format||o.calendars.standard.patterns.d),isNaN(n)&&(n=0,e.start=Z),(i===t||i>n)&&(e.depth=Z),null===e.dates&&(e.dates=[])}function p(e){U&&e.find("*").attr("unselectable","on")}function m(e,t){e.addClass("k-"+t)}function g(e,t){for(var n=0,i=t.length;n<i;n++)if(e===+t[n])return!0;return!1}function v(e,t){return!!e&&(e.getFullYear()===t.getFullYear()&&e.getMonth()===t.getMonth()&&e.getDate()===t.getDate())}function _(e,t){return!!e&&(e.getFullYear()===t.getFullYear()&&e.getMonth()===t.getMonth())}function b(t){return C.isFunction(t)?t:e.isArray(t)?y(t):e.noop}function w(e){var t,n=[];for(t=0;t<e.length;t++)n.push(e[t].setHours(0,0,0,0));return n}function y(t){var n,i,o,r,s,a=[],l=["su","mo","tu","we","th","fr","sa"],c="if (found) { return true } else {return false}";if(t[0]instanceof Se)a=w(t),n="var found = date && $.inArray(date.setHours(0, 0, 0, 0),["+a+"]) > -1;"+c;else{for(o=0;o<t.length;o++)r=t[o].slice(0,2).toLowerCase(),s=e.inArray(r,l),s>-1&&a.push(s);n="var found = date && $.inArray(date.getDay(),["+a+"]) > -1;"+c}return i=Function("date",n)}function k(e,t){return e instanceof Date&&t instanceof Date&&(e=e.getTime(),t=t.getTime()),e===t}var x,C=window.kendo,S=C.support,T=C.ui,D=T.Widget,A=C.keys,E=C.parseDate,M=C.date.adjustDST,I=C.date.getDate,R=C.date.weekInYear,F=C._extractFormat,z=C.template,P=C.getCulture,B=C.support.transitions,L=B?B.css+"transform-origin":"",H=z('<td#=data.cssClass# role="gridcell"><a tabindex="-1" class="k-link" href="\\#" data-#=data.ns#value="#=data.dateString#">#=data.value#</a></td>',{useWithBlock:!1}),N=z('<td role="gridcell">&nbsp;</td>',{useWithBlock:!1}),O=z('<td class="k-alt">#= data.weekNumber #</td>',{useWithBlock:!1}),V=C.support.browser,U=V.msie&&V.version<9,W=C._outerHeight,q=C._outerWidth,j=".kendoCalendar",G="click"+j,$="keydown"+j,Y="id",K="min",Q="left",X="slideIn",Z="month",J="century",ee="change",te="navigate",ne="value",ie="k-state-hover",oe="k-state-disabled",re="k-state-focused",se="k-other-month",ae=' class="'+se+'"',le="k-nav-today",ce="td:has(.k-link)",de="blur"+j,ue="focus",he=ue+j,fe=S.touch?"touchstart":"mouseenter",pe=S.touch?"touchstart"+j:"mouseenter"+j,me=S.touch?"touchend"+j+" touchmove"+j:"mouseleave"+j,ge=6e4,ve=864e5,_e="_prevArrow",be="_nextArrow",we="aria-disabled",ye="aria-selected",ke="aria-label",xe=e.proxy,Ce=e.extend,Se=Date,Te={month:0,year:1,decade:2,century:3},De=D.extend({init:function(t,n){var i,o,a=this;D.fn.init.call(a,t,n),t=a.wrapper=a.element,n=a.options,n.url=window.unescape(n.url),a.options.disableDates=b(a.options.disableDates),a._templates(),a._header(),a._footer(a.footer),o=t.addClass("k-widget k-calendar "+(n.weekNumber?" k-week-number":"")).on(pe+" "+me,ce,d).on($,"table.k-content",xe(a._move,a)).on(G,ce,function(t){var n=t.currentTarget.firstChild,i=a._toDateObject(n);n.href.indexOf("#")!=-1&&t.preventDefault(),"month"==a._view.name&&a.options.disableDates(i)||a._click(e(n))}).on("mouseup"+j,"table.k-content, .k-footer",function(){a._focusView(a.options.focusOnNav!==!1)}).attr(Y),o&&(a._cellID=o+"_cell_selected"),f(n),i=E(n.value,n.format,n.culture),a._index=Te[n.start],a._current=new Se((+s(i,n.min,n.max))),a._addClassProxy=function(){if(a._active=!0,a._cell.hasClass(oe)){var e=a._view.toDateString(r());a._cell=a._cellByDate(e)}a._cell.addClass(re)},a._removeClassProxy=function(){a._active=!1,a._cell.removeClass(re)},a.value(i),C.notify(a)},options:{name:"Calendar",value:null,min:new Se(1900,0,1),max:new Se(2099,11,31),dates:[],url:"",culture:"",footer:"",format:"",month:{},weekNumber:!1,start:Z,depth:Z,animation:{horizontal:{effects:X,reverse:!0,duration:500,divisor:2},vertical:{effects:"zoomIn",duration:400}},messages:{weekColumnHeader:""}},events:[ee,te],setOptions:function(e){var t=this;f(e),e.disableDates=b(e.disableDates),D.fn.setOptions.call(t,e),t._templates(),t._footer(t.footer),t._index=Te[t.options.start],t.navigate()},destroy:function(){var e=this,t=e._today;e.element.off(j),e._title.off(j),e[_e].off(j),e[be].off(j),C.destroy(e._table),t&&C.destroy(t.off(j)),D.fn.destroy.call(e)},current:function(){return this._current},view:function(){return this._view},focus:function(e){e=e||this._table,this._bindTable(e),e.focus()},min:function(e){return this._option(K,e)},max:function(e){return this._option("max",e)},navigateToPast:function(){this._navigate(_e,-1)},navigateToFuture:function(){this._navigate(be,1)},navigateUp:function(){var e=this,t=e._index;e._title.hasClass(oe)||e.navigate(e._current,++t)},navigateDown:function(e){var n=this,i=n._index,o=n.options.depth;if(e)return i===Te[o]?(k(n._value,n._current)&&k(n._value,e)||(n.value(e),n.trigger(ee)),t):(n.navigate(e,--i),t)},navigate:function(n,i){var o,r,a,l,c,d,u,h,f,g,v,_,b,w,y,k,C;i=isNaN(i)?Te[i]:i,o=this,r=o.options,a=r.culture,l=r.min,c=r.max,d=o._title,u=o._table,h=o._oldTable,f=o._value,g=o._current,v=n&&+n>+g,_=i!==t&&i!==o._index,n||(n=g),o._current=n=new Se((+s(n,l,c))),i===t?i=o._index:o._index=i,o._view=w=x.views[i],y=w.compare,k=i===Te[J],d.toggleClass(oe,k).attr(we,k),k=y(n,l)<1,o[_e].toggleClass(oe,k).attr(we,k),k=y(n,c)>-1,o[be].toggleClass(oe,k).attr(we,k),u&&h&&h.data("animating")&&(h.kendoStop(!0,!0),u.kendoStop(!0,!0)),o._oldTable=u,u&&!o._changeView||(d.html(w.title(n,l,c,a)),o._table=b=e(w.content(Ce({min:l,max:c,date:n,url:r.url,dates:r.dates,format:r.format,culture:a,disableDates:r.disableDates,isWeekColumnVisible:r.weekNumber,messages:r.messages},o[w.name]))),m(b,w.name),p(b),C=u&&u.data("start")===b.data("start"),o._animate({from:u,to:b,vertical:_,future:v,replace:C}),o.trigger(te),o._focus(n)),i===Te[r.depth]&&f&&!o.options.disableDates(f)&&o._class("k-state-selected",f),o._class(re,n),!u&&o._cell&&o._cell.removeClass(re),o._changeView=!0},value:function(e){var n=this,i=n._view,o=n.options,r=n._view,s=o.min,l=o.max;return e===t?n._value:(null===e&&(n._current=new Date(n._current.getFullYear(),n._current.getMonth(),n._current.getDate())),e=E(e,o.format,o.culture),null!==e&&(e=new Se((+e)),a(e,s,l)||(e=null)),null!==e&&n.options.disableDates(e)?n._value===t&&(n._value=null):n._value=e,r&&null===e&&n._cell?n._cell.removeClass("k-state-selected"):(n._changeView=!e||i&&0!==i.compare(e,n._current),n.navigate(e)),t)},_move:function(t){var n,i,o,r,l=this,c=l.options,d=t.keyCode,u=l._view,h=l._index,f=l.options.min,p=l.options.max,m=new Se((+l._current)),g=C.support.isRtl(l.wrapper),v=l.options.disableDates;return t.target===l._table[0]&&(l._active=!0),t.ctrlKey?d==A.RIGHT&&!g||d==A.LEFT&&g?(l.navigateToFuture(),i=!0):d==A.LEFT&&!g||d==A.RIGHT&&g?(l.navigateToPast(),i=!0):d==A.UP?(l.navigateUp(),i=!0):d==A.DOWN&&(l._click(e(l._cell[0].firstChild)),i=!0):(d==A.RIGHT&&!g||d==A.LEFT&&g?(n=1,i=!0):d==A.LEFT&&!g||d==A.RIGHT&&g?(n=-1,i=!0):d==A.UP?(n=0===h?-7:-4,i=!0):d==A.DOWN?(n=0===h?7:4,i=!0):d==A.ENTER?(l._click(e(l._cell[0].firstChild)),i=!0):d==A.HOME||d==A.END?(o=d==A.HOME?"first":"last",r=u[o](m),m=new Se(r.getFullYear(),r.getMonth(),r.getDate(),m.getHours(),m.getMinutes(),m.getSeconds(),m.getMilliseconds()),i=!0):d==A.PAGEUP?(i=!0,l.navigateToPast()):d==A.PAGEDOWN&&(i=!0,l.navigateToFuture()),(n||o)&&(o||u.setDate(m,n),v(m)&&(m=l._nextNavigatable(m,n)),f=I(f),a(m,f,p)&&l._focus(s(m,c.min,c.max)))),i&&t.preventDefault(),l._current},_nextNavigatable:function(e,t){var n=this,i=!0,o=n._view,r=n.options.min,s=n.options.max,l=n.options.disableDates,c=new Date(e.getTime());for(o.setDate(c,-t);i;){if(o.setDate(e,t),!a(e,r,s)){e=c;break}i=l(e)}return e},_animate:function(e){var t=this,n=e.from,i=e.to,o=t._active;n?n.parent().data("animating")?(n.off(j),n.parent().kendoStop(!0,!0).remove(),n.remove(),i.insertAfter(t.element[0].firstChild),t._focusView(o)):!n.is(":visible")||t.options.animation===!1||e.replace?(i.insertAfter(n),n.off(j).remove(),t._focusView(o)):t[e.vertical?"_vertical":"_horizontal"](n,i,e.future):(i.insertAfter(t.element[0].firstChild),t._bindTable(i))},_horizontal:function(e,t,n){var i=this,o=i._active,r=i.options.animation.horizontal,s=r.effects,a=q(e);s&&s.indexOf(X)!=-1&&(e.add(t).css({width:a}),e.wrap("<div/>"),i._focusView(o,e),e.parent().css({position:"relative",width:2*a,"float":Q,"margin-left":n?0:-a}),t[n?"insertAfter":"insertBefore"](e),Ce(r,{effects:X+":"+(n?"right":Q),complete:function(){e.off(j).remove(),i._oldTable=null,t.unwrap(),i._focusView(o)}}),e.parent().kendoStop(!0,!0).kendoAnimate(r))},_vertical:function(e,t){var n,i,o=this,r=o.options.animation.vertical,s=r.effects,a=o._active;s&&s.indexOf("zoom")!=-1&&(t.css({position:"absolute",top:W(e.prev()),left:0}).insertBefore(e),L&&(n=o._cellByDate(o._view.toDateString(o._current)),i=n.position(),i=i.left+parseInt(n.width()/2,10)+"px "+(i.top+parseInt(n.height()/2,10)+"px"),t.css(L,i)),e.kendoStop(!0,!0).kendoAnimate({effects:"fadeOut",duration:600,complete:function(){e.off(j).remove(),o._oldTable=null,t.css({position:"static",top:0,left:0}),o._focusView(a)}}),t.kendoStop(!0,!0).kendoAnimate(r))},_cellByDate:function(t){return this._table.find("td:not(."+se+")").filter(function(){return e(this.firstChild).attr(C.attr(ne))===t})},_class:function(t,n){var i,o=this,r=o._cellID,s=o._cell,a=o._view.toDateString(n);s&&s.removeAttr(ye).removeAttr(ke).removeAttr(Y),n&&"month"==o._view.name&&(i=o.options.disableDates(n)),s=o._table.find("td:not(."+se+")").removeClass(t).filter(function(){return e(this.firstChild).attr(C.attr(ne))===a}).attr(ye,!0),(t===re&&!o._active&&o.options.focusOnNav!==!1||i)&&(t=""),s.addClass(t),s[0]&&(o._cell=s),r&&(s.attr(Y,r),o._table.removeAttr("aria-activedescendant").attr("aria-activedescendant",r))},_bindTable:function(e){e.on(he,this._addClassProxy).on(de,this._removeClassProxy)},_click:function(e){var t=this,n=t.options,i=new Date((+t._current)),o=t._toDateObject(e);M(o,0),"month"==t._view.name&&t.options.disableDates(o)&&(o=t._value),t._view.setDate(i,o),t.navigateDown(s(i,n.min,n.max))},_focus:function(e){var t=this,n=t._view;0!==n.compare(e,t._current)?t.navigate(e):(t._current=e,t._class(re,e))},_focusView:function(e,t){e&&this.focus(t)},_footer:function(n){var i=this,o=r(),s=i.element,a=s.find(".k-footer");return n?(a[0]||(a=e('<div class="k-footer"><a href="#" class="k-link k-nav-today"></a></div>').appendTo(s)),i._today=a.show().find(".k-link").html(n(o)).attr("title",C.toString(o,"D",i.options.culture)),i._toggle(),t):(i._toggle(!1),a.hide(),t)},_header:function(){var e,t=this,n=t.element;n.find(".k-header")[0]||n.html('<div class="k-header"><a href="#" role="button" class="k-link k-nav-prev" '+ke+'="Previous"><span class="k-icon k-i-arrow-60-left"></span></a><a href="#" role="button" aria-live="assertive" aria-atomic="true" class="k-link k-nav-fast"></a><a href="#" role="button" class="k-link k-nav-next" '+ke+'="Next"><span class="k-icon k-i-arrow-60-right"></span></a></div>'),e=n.find(".k-link").on(pe+" "+me+" "+he+" "+de,d).click(!1),t._title=e.eq(1).on(G,function(){t._active=t.options.focusOnNav!==!1,t.navigateUp()}),t[_e]=e.eq(0).on(G,function(){t._active=t.options.focusOnNav!==!1,t.navigateToPast()}),t[be]=e.eq(2).on(G,function(){t._active=t.options.focusOnNav!==!1,t.navigateToFuture()})},_navigate:function(e,t){var n=this,i=n._index+1,o=new Se((+n._current));e=n[e],e.hasClass(oe)||(i>3?o.setFullYear(o.getFullYear()+100*t):x.views[i].setDate(o,t),n.navigate(o))},_option:function(e,n){var i,o=this,r=o.options,s=o._value||o._current;return n===t?r[e]:(n=E(n,r.format,r.culture),n&&(r[e]=new Se((+n)),i=e===K?n>s:s>n,(i||_(s,n))&&(i&&(o._value=null),o._changeView=!0),o._changeView||(o._changeView=!(!r.month.content&&!r.month.empty)),o.navigate(o._value),o._toggle()),t)},_toggle:function(e){var n=this,i=n.options,o=n.options.disableDates(r()),s=n._today;e===t&&(e=a(r(),i.min,i.max)),s&&(s.off(G),e&&!o?s.addClass(le).removeClass(oe).on(G,xe(n._todayClick,n)):s.removeClass(le).addClass(oe).on(G,u))},_todayClick:function(e){var t=this,n=Te[t.options.depth],i=t.options.disableDates,o=r();e.preventDefault(),i(o)||(0===t._view.compare(t._current,o)&&t._index==n&&(t._changeView=!1),t._value=o,t.navigate(o,n),t.trigger(ee))},_toDateObject:function(t){var n=e(t).attr(C.attr(ne)).split("/");return n=new Se(n[0],n[1],n[2])},_templates:function(){var e=this,t=e.options,n=t.footer,i=t.month,o=i.content,r=i.weekNumber,s=i.empty;e.month={content:z('<td#=data.cssClass# role="gridcell"><a tabindex="-1" class="k-link#=data.linkClass#" href="#=data.url#" '+C.attr("value")+'="#=data.dateString#" title="#=data.title#">'+(o||"#=data.value#")+"</a></td>",{useWithBlock:!!o}),empty:z('<td role="gridcell">'+(s||"&nbsp;")+"</td>",{useWithBlock:!!s}),weekNumber:z('<td class="k-alt">'+(r||"#= data.weekNumber #")+"</td>",{useWithBlock:!!r})},e.footer=n!==!1?z(n||'#= kendo.toString(data,"D","'+t.culture+'") #',{useWithBlock:!1}):null}});T.plugin(De),x={firstDayOfMonth:function(e){return new Se(e.getFullYear(),e.getMonth(),1)},firstVisibleDay:function(e,t){t=t||C.culture().calendar;for(var n=t.firstDay,i=new Se(e.getFullYear(),e.getMonth(),0,e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds());i.getDay()!=n;)x.setTime(i,-1*ve);return i},setTime:function(e,t){var n=e.getTimezoneOffset(),i=new Se(e.getTime()+t),o=i.getTimezoneOffset()-n;e.setTime(i.getTime()+o*ge)},views:[{name:Z,title:function(e,t,n,i){return h(i).months.names[e.getMonth()]+" "+e.getFullYear()},content:function(e){var t=this,n=0,o=e.min,r=e.max,s=e.date,a=e.dates,c=e.format,d=e.culture,u=e.url,f=e.isWeekColumnVisible,p=u&&a[0],m=h(d),v=m.firstDay,_=m.days,b=l(_.names,v),w=l(_.namesShort,v),y=x.firstVisibleDay(s,m),k=t.first(s),S=t.last(s),T=t.toDateString,D=new Se,A='<table tabindex="0" role="grid" class="k-content" cellspacing="0" data-start="'+T(y)+'"><thead><tr role="row">';for(f&&(A+='<th scope="col" class="k-alt">'+e.messages.weekColumnHeader+"</th>");n<7;n++)A+='<th scope="col" title="'+b[n]+'">'+w[n]+"</th>";return D=new Se(D.getFullYear(),D.getMonth(),D.getDate()),M(D,0),D=+D,i({cells:42,perRow:7,html:A+='</tr></thead><tbody><tr role="row">',start:y,isWeekColumnVisible:f,weekNumber:e.weekNumber,min:new Se(o.getFullYear(),o.getMonth(),o.getDate()),max:new Se(r.getFullYear(),r.getMonth(),r.getDate()),content:e.content,empty:e.empty,setter:t.setDate,disableDates:e.disableDates,build:function(e,t,n){var i=[],o=e.getDay(),r="",s="#";return(e<k||e>S)&&i.push(se),n(e)&&i.push(oe),+e===D&&i.push("k-today"),0!==o&&6!==o||i.push("k-weekend"),p&&g(+e,a)&&(s=u.replace("{0}",C.toString(e,c,d)),r=" k-action-link"),{date:e,dates:a,ns:C.ns,title:C.toString(e,"D",d),value:e.getDate(),dateString:T(e),cssClass:i[0]?' class="'+i.join(" ")+'"':"",linkClass:r,url:s}},weekNumberBuild:function(e){return{weekNumber:R(e,C.culture().calendar.firstDay),currentDate:e}}})},first:function(e){return x.firstDayOfMonth(e)},last:function(e){var t=new Se(e.getFullYear(),e.getMonth()+1,0),n=x.firstDayOfMonth(e),i=Math.abs(t.getTimezoneOffset()-n.getTimezoneOffset());return i&&t.setHours(n.getHours()+i/60),t},compare:function(e,t){var n,i=e.getMonth(),o=e.getFullYear(),r=t.getMonth(),s=t.getFullYear();return n=o>s?1:o<s?-1:i==r?0:i>r?1:-1},setDate:function(e,t){var n=e.getHours();t instanceof Se?e.setFullYear(t.getFullYear(),t.getMonth(),t.getDate()):x.setTime(e,t*ve),M(e,n)},toDateString:function(e){return e.getFullYear()+"/"+e.getMonth()+"/"+e.getDate()}},{name:"year",title:function(e){return e.getFullYear()},content:function(e){var t=h(e.culture).months.namesAbbr,n=this.toDateString,o=e.min,r=e.max;return i({min:new Se(o.getFullYear(),o.getMonth(),1),max:new Se(r.getFullYear(),r.getMonth(),1),start:new Se(e.date.getFullYear(),0,1),setter:this.setDate,build:function(e){return{value:t[e.getMonth()],ns:C.ns,dateString:n(e),cssClass:""}}})},first:function(e){return new Se(e.getFullYear(),0,e.getDate())},last:function(e){return new Se(e.getFullYear(),11,e.getDate())},compare:function(e,t){return o(e,t)},setDate:function(e,t){var n,i=e.getHours();t instanceof Se?(n=t.getMonth(),e.setFullYear(t.getFullYear(),n,e.getDate()),n!==e.getMonth()&&e.setDate(0)):(n=e.getMonth()+t,e.setMonth(n),n>11&&(n-=12),n>0&&e.getMonth()!=n&&e.setDate(0)),M(e,i)},toDateString:function(e){return e.getFullYear()+"/"+e.getMonth()+"/1"}},{name:"decade",title:function(e,t,i){return n(e,t,i,10)},content:function(e){var t=e.date.getFullYear(),n=this.toDateString;return i({start:new Se(t-t%10-1,0,1),min:new Se(e.min.getFullYear(),0,1),max:new Se(e.max.getFullYear(),0,1),setter:this.setDate,build:function(e,t){return{value:e.getFullYear(),ns:C.ns,dateString:n(e),cssClass:0===t||11==t?ae:""}}})},first:function(e){var t=e.getFullYear();return new Se(t-t%10,e.getMonth(),e.getDate())},last:function(e){var t=e.getFullYear();return new Se(t-t%10+9,e.getMonth(),e.getDate())},compare:function(e,t){return o(e,t,10)},setDate:function(e,t){c(e,t,1)},toDateString:function(e){return e.getFullYear()+"/0/1"}},{name:J,title:function(e,t,i){return n(e,t,i,100)},content:function(e){var t=e.date.getFullYear(),n=e.min.getFullYear(),o=e.max.getFullYear(),r=this.toDateString,s=n,a=o;return s-=s%10,a-=a%10,a-s<10&&(a=s+9),i({start:new Se(t-t%100-10,0,1),min:new Se(s,0,1),max:new Se(a,0,1),setter:this.setDate,build:function(e,t){var i=e.getFullYear(),s=i+9;return i<n&&(i=n),s>o&&(s=o),{ns:C.ns,value:i+" - "+s,dateString:r(e),cssClass:0===t||11==t?ae:""}}})},first:function(e){var t=e.getFullYear();return new Se(t-t%100,e.getMonth(),e.getDate())},last:function(e){var t=e.getFullYear();return new Se(t-t%100+99,e.getMonth(),e.getDate())},compare:function(e,t){return o(e,t,100)},setDate:function(e,t){c(e,t,10)},toDateString:function(e){var t=e.getFullYear();return t-t%10+"/0/1"}}]},x.isEqualDatePart=v,x.isEqualDate=k,x.makeUnselectable=p,x.restrictValue=s,x.isInRange=a,x.addClassToViewContainer=m,x.normalize=f,x.viewsEnum=Te,x.disabled=b,C.calendar=x}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.datepicker.min",["kendo.calendar.min","kendo.popup.min"],e)}(function(){return function(e,t){function n(t){var n=t.parseFormats,i=t.format;P.normalize(t),n=e.isArray(n)?n:[n],n.length||n.push("yyyy-MM-dd"),e.inArray(i,n)===-1&&n.splice(0,0,t.format),t.parseFormats=n}function i(e){e.preventDefault()}var o,r=window.kendo,s=r.ui,a=s.Widget,l=r.parseDate,c=r.keys,d=r.template,u=r._activeElement,h="<div />",f="<span />",p=".kendoDatePicker",m="click"+p,g="open",v="close",_="change",b="disabled",w="readonly",y="k-state-default",k="k-state-focused",x="k-state-selected",C="k-state-disabled",S="k-state-hover",T="mouseenter"+p+" mouseleave"+p,D="mousedown"+p,A="id",E="min",M="max",I="month",R="aria-disabled",F="aria-expanded",z="aria-hidden",P=r.calendar,B=P.isInRange,L=P.restrictValue,H=P.isEqualDatePart,N=e.extend,O=e.proxy,V=Date,U=function(t){var n,i=this,o=document.body,a=e(h).attr(z,"true").addClass("k-calendar-container").appendTo(o);i.options=t=t||{},n=t.id,n&&(n+="_dateview",a.attr(A,n),i._dateViewID=n),i.popup=new s.Popup(a,N(t.popup,t,{name:"Popup",isRtl:r.support.isRtl(t.anchor)})),i.div=a,i.value(t.value)};U.prototype={_calendar:function(){var t,n=this,o=n.calendar,a=n.options;o||(t=e(h).attr(A,r.guid()).appendTo(n.popup.element).on(D,i).on(m,"td:has(.k-link)",O(n._click,n)),n.calendar=o=new s.Calendar(t),n._setOptions(a),r.calendar.makeUnselectable(o.element),o.navigate(n._value||n._current,a.start),n.value(n._value))},_setOptions:function(e){this.calendar.setOptions({focusOnNav:!1,change:e.change,culture:e.culture,dates:e.dates,depth:e.depth,footer:e.footer,format:e.format,max:e.max,min:e.min,month:e.month,weekNumber:e.weekNumber,start:e.start,disableDates:e.disableDates})},setOptions:function(e){var t=this.options,n=e.disableDates;n&&(e.disableDates=P.disabled(n)),this.options=N(t,e,{change:t.change,close:t.close,open:t.open}),this.calendar&&this._setOptions(this.options)},destroy:function(){this.popup.destroy()},open:function(){var e=this;e._calendar(),e.popup.open()},close:function(){this.popup.close()},min:function(e){this._option(E,e)},max:function(e){this._option(M,e)},toggle:function(){var e=this;e[e.popup.visible()?v:g]()},move:function(e){var t=this,n=e.keyCode,i=t.calendar,o=e.ctrlKey&&n==c.DOWN||n==c.ENTER,r=!1;if(e.altKey)n==c.DOWN?(t.open(),e.preventDefault(),r=!0):n==c.UP&&(t.close(),e.preventDefault(),r=!0);else if(t.popup.visible()){if(n==c.ESC||o&&i._cell.hasClass(x))return t.close(),e.preventDefault(),!0;t._current=i._move(e),r=!0}return r},current:function(e){this._current=e,this.calendar._focus(e)},value:function(e){var t=this,n=t.calendar,i=t.options,o=i.disableDates;o&&o(e)&&(e=null),t._value=e,t._current=new V((+L(e,i.min,i.max))),n&&n.value(e)},_click:function(e){e.currentTarget.className.indexOf(x)!==-1&&this.close()},_option:function(e,t){var n=this,i=n.calendar;n.options[e]=t,i&&i[e](t)}},U.normalize=n,r.DateView=U,o=a.extend({init:function(t,i){var o,c,d=this;a.fn.init.call(d,t,i),t=d.element,i=d.options,i.disableDates=r.calendar.disabled(i.disableDates),i.min=l(t.attr("min"))||l(i.min),i.max=l(t.attr("max"))||l(i.max),n(i),d._initialOptions=N({},i),d._wrapper(),d.dateView=new U(N({},i,{id:t.attr(A),anchor:d.wrapper,change:function(){d._change(this.value()),d.close()},close:function(e){d.trigger(v)?e.preventDefault():(t.attr(F,!1),c.attr(z,!0))},open:function(e){var n,i=d.options;d.trigger(g)?e.preventDefault():(d.element.val()!==d._oldText&&(n=l(t.val(),i.parseFormats,i.culture),d.dateView[n?"current":"value"](n)),t.attr(F,!0),c.attr(z,!1),d._updateARIA(n))}})),c=d.dateView.div,d._icon();try{t[0].setAttribute("type","text")}catch(u){t[0].type="text"}t.addClass("k-input").attr({role:"combobox","aria-expanded":!1,"aria-owns":d.dateView._dateViewID}),d._reset(),d._template(),o=t.is("[disabled]")||e(d.element).parents("fieldset").is(":disabled"),o?d.enable(!1):d.readonly(t.is("[readonly]")),i.dateInput&&(d._dateInput=new s.DateInput(t,{culture:i.culture,format:i.format,min:i.min,max:i.max,value:i.value})),d._old=d._update(i.value||d.element.val()),d._oldText=t.val(),r.notify(d)},events:[g,v,_],options:{name:"DatePicker",value:null,footer:"",format:"",culture:"",parseFormats:[],min:new Date(1900,0,1),max:new Date(2099,11,31),start:I,depth:I,animation:{},month:{},dates:[],ARIATemplate:'Current focused date is #=kendo.toString(data.current, "D")#',dateInput:!1},setOptions:function(e){var t=this,i=t._value;a.fn.setOptions.call(t,e),e=t.options,e.min=l(e.min),e.max=l(e.max),n(e),t.dateView.setOptions(e),t._dateInput&&t._dateInput.setOptions({culture:e.culture,format:e.format,min:e.min,max:e.max,value:e.value}),i&&(t.element.val(r.toString(i,e.format,e.culture)),t._updateARIA(i))},_editable:function(e){var t=this,n=t._dateIcon.off(p),o=t.element.off(p),r=t._inputWrapper.off(p),s=e.readonly,a=e.disable;s||a?(r.addClass(a?C:y).removeClass(a?y:C),o.attr(b,a).attr(w,s).attr(R,a)):(r.addClass(y).removeClass(C).on(T,t._toggleHover),o.removeAttr(b).removeAttr(w).attr(R,!1).on("keydown"+p,O(t._keydown,t)).on("focusout"+p,O(t._blur,t)).on("focus"+p,function(){t._inputWrapper.addClass(k)}),n.on(m,O(t._click,t)).on(D,i))},readonly:function(e){this._editable({readonly:e===t||e,disable:!1})},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)})},destroy:function(){var e=this;a.fn.destroy.call(e),e.dateView.destroy(),e.element.off(p),e._dateIcon.off(p),e._inputWrapper.off(p),e._form&&e._form.off("reset",e._resetHandler)},open:function(){this.dateView.open()},close:function(){this.dateView.close()},min:function(e){return this._option(E,e)},max:function(e){return this._option(M,e)},value:function(e){var n=this;return e===t?n._value:(n._old=n._update(e),null===n._old&&n.element.val(""),n._oldText=n.element.val(),t)},_toggleHover:function(t){e(t.currentTarget).toggleClass(S,"mouseenter"===t.type)},_blur:function(){var e=this,t=e.element.val();e.close(),t!==e._oldText&&e._change(t),e._inputWrapper.removeClass(k)},_click:function(){var e=this,t=e.element;e.dateView.toggle(),r.support.touch||t[0]===u()||t.focus()},_change:function(e){var t,n,i,o=this,s=o.element.val();e=o._update(e),t=!r.calendar.isEqualDate(o._old,e),n=t&&!o._typing,i=s!==o.element.val(),(n||i)&&o.element.trigger(_),t&&(o._old=e,o._oldText=o.element.val(),o.trigger(_)),o._typing=!1},_keydown:function(e){var t=this,n=t.dateView,i=t.element.val(),o=!1;n.popup.visible()||e.keyCode!=c.ENTER||i===t._oldText?(o=n.move(e),t._updateARIA(n._current),o?t._dateInput&&e.stopImmediatePropagation&&e.stopImmediatePropagation():t._typing=!0):t._change(i)},_icon:function(){var t,n=this,i=n.element;t=i.next("span.k-select"),t[0]||(t=e('<span unselectable="on" class="k-select" aria-label="select"><span class="k-icon k-i-calendar"></span></span>').insertAfter(i)),n._dateIcon=t.attr({role:"button","aria-controls":n.dateView._dateViewID})},_option:function(e,n){var i=this,o=i.options;return n===t?o[e]:(n=l(n,o.parseFormats,o.culture),n&&(o[e]=new V((+n)),i.dateView[e](n)),t)},_update:function(e){var t,n=this,i=n.options,o=i.min,s=i.max,a=n._value,c=l(e,i.parseFormats,i.culture),d=null===c&&null===a||c instanceof Date&&a instanceof Date;return i.disableDates(c)&&(c=null,n._old||n.element.val()||(e=null)),+c===+a&&d?(t=r.toString(c,i.format,i.culture),t!==e&&n.element.val(null===c?e:t),c):(null!==c&&H(c,o)?c=L(c,o,s):B(c,o,s)||(c=null),n._value=c,n.dateView.value(c),n._dateInput?n._dateInput.value(c||e):n.element.val(r.toString(c||e,i.format,i.culture)),n._updateARIA(c),c)},_wrapper:function(){var t,n=this,i=n.element;t=i.parents(".k-datepicker"),t[0]||(t=i.wrap(f).parent().addClass("k-picker-wrap k-state-default"),t=t.wrap(f).parent()),t[0].style.cssText=i[0].style.cssText,i.css({width:"100%",height:i[0].style.height}),n.wrapper=t.addClass("k-widget k-datepicker k-header").addClass(i[0].className),n._inputWrapper=e(t[0].firstChild)},_reset:function(){var t=this,n=t.element,i=n.attr("form"),o=i?e("#"+i):n.closest("form");o[0]&&(t._resetHandler=function(){t.value(n[0].defaultValue),t.max(t._initialOptions.max),t.min(t._initialOptions.min)},t._form=o.on("reset",t._resetHandler))},_template:function(){this._ariaTemplate=d(this.options.ARIATemplate)},_updateARIA:function(e){var t,n=this,i=n.dateView.calendar;n.element.removeAttr("aria-activedescendant"),i&&(t=i._cell,t.attr("aria-label",n._ariaTemplate({current:e||i.current()})),n.element.attr("aria-activedescendant",t.attr("id")))}}),s.plugin(o)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){
(n||t)()}),function(e,define){define("kendo.dateinput.min",["kendo.core.min"],e)}(function(){return function(e,t){function n(e,t,n,i){var o,r,s,a,l=e[i+e.length-n.length];if(e=e.substring(0,i+e.length-n.length),n=n.substring(0,i),o=[],e===n&&i>0)return o.push([t[i-1],n[i-1]]),o;if(0===e.indexOf(n)&&(0===n.length||t[n.length-1]!==t[n.length])){for(s="",r=n.length;r<e.length;r++)t[r]!==s&&w.indexOf(t[r])>=0&&(s=t[r],o.push([s,""]));return o}if(" "===n[n.length-1]||n[n.length-1]===l)return[[t[i-1]," "]];if(0===n.indexOf(e)||w.indexOf(t[i-1])===-1){for(a=t[0],r=Math.max(0,e.length-1);r<t.length;r++)if(w.indexOf(t[r])>=0){a=t[r];break}return[[a,n[i-1]]]}return[[t[i-1],n[i-1]]]}var i,o=window,r=o.kendo,s=r.caret,a=r.ui,l=a.Widget,c=r.keys,d=".kendoDateInput",u=e.proxy,h={}.toString,f=(r.support.propertyChangeEvent?"propertychange.kendoDateInput input":"input")+d,p="k-state-disabled",m="k-state-default",g="k-state-invalid",v="disabled",_="readonly",b="change",w="dMyHhmftsz",y=l.extend({init:function(t,n){var i,o,s=this;l.fn.init.call(s,t,n),t=s.element,n=s.options,n.format=r._extractFormat(n.format||r.getCulture(n.culture).calendars.standard.patterns.d),n.min=r.parseDate(t.attr("min"))||r.parseDate(n.min),n.max=r.parseDate(t.attr("max"))||r.parseDate(n.max),i=(t.parent().attr("class")||"").indexOf("k-picker-wrap")>=0,i?s.wrapper=t.parent():(s.wrapper=t.wrap("<span class='k-widget k-dateinput'></span>").parent(),s.wrapper.addClass(t[0].className),s.wrapper[0].style.cssText=t[0].style.cssText,t.css({width:"100%",height:t[0].style.height})),e("<span class='k-icon k-i-warning'></span>").insertAfter(t),s._form(),s.element.addClass(i?" ":"k-textbox").attr("autocomplete","off").on("focusout"+d,function(){s._change()});try{t[0].setAttribute("type","text")}catch(a){t[0].type="text"}o=t.is("[disabled]")||e(s.element).parents("fieldset").is(":disabled"),o?s.enable(!1):s.readonly(t.is("[readonly]")),s.value(s.options.value||t.val()),r.notify(s)},options:{name:"DateInput",culture:"",value:"",format:"",min:new Date(1900,0,1),max:new Date(2099,11,31),messages:{year:"year",month:"month",day:"day",weekday:"day of the week",hour:"hours",minute:"minutes",second:"seconds",dayperiod:"AM/PM"}},events:[b],min:function(e){return e===t?this.options.min:(this.options.min=e,t)},max:function(e){return e===t?this.options.max:(this.options.max=e,t)},setOptions:function(e){var t=this;l.fn.setOptions.call(t,e),this._unbindInput(),this._bindInput(),this._updateElementValue()},destroy:function(){var e=this;e.element.off(d),e._formElement&&e._formElement.off("reset",e._resetHandler),l.fn.destroy.call(e)},value:function(e){return e===t?this._dateTime.getDateObject():(null===e&&(e=""),"[object Date]"!==h.call(e)&&(e=r.parseDate(e,this.options.format,this.options.culture)),e&&!e.getTime()&&(e=null),this._dateTime=new i(e,this.options.format,this.options.culture,this.options.messages),this._updateElementValue(),this._oldValue=e,t)},_updateElementValue:function(){var e=this._dateTime.toPair(this.options.format,this.options.culture,this.options.messages);this.element.val(e[0]),this._oldText=e[0],this._format=e[1]},readonly:function(e){this._editable({readonly:e===t||e,disable:!1})},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)})},_bindInput:function(){var e=this;e.element.on("paste"+d,u(e._paste,e)).on("keydown"+d,u(e._keydown,e)).on(f,u(e._input,e)).on("mouseup"+d,u(e._mouseUp,e)).on("DOMMouseScroll"+d+" mousewheel"+d,u(e._scroll,e))},_unbindInput:function(){this.element.off("keydown"+d).off("paste"+d).off(f).off("mouseup"+d).off("DOMMouseScroll"+d+" mousewheel"+d)},_editable:function(e){var t=this,n=t.element,i=e.disable,o=e.readonly,r=t.wrapper;t._unbindInput(),o||i?(r.addClass(p).removeClass(m),n.attr(v,i).attr(_,o)):(r.addClass(m).removeClass(p),n.removeAttr(v).removeAttr(_),t._bindInput())},_change:function(){var e=this,t=e._oldValue,n=e.value();n&&e.min()&&n<e.min()&&(e.value(e.min()),n=e.value()),n&&e.max()&&n>e.max()&&(e.value(e.max()),n=e.value()),(t&&n&&n.getTime()!==t.getTime()||t&&!n||!t&&n)&&(e._oldValue=n,e.trigger(b),e.element.trigger(b))},_input:function(){var e,t,i,o,a,l,c,d=this,u=d.element[0],h=!1;if(r._activeElement()===u){if(e=n(this._oldText,this._format,this.element[0].value,s(this.element[0])[0]),t=1===e.length&&" "===e[0][1],!t)for(i=0;i<e.length;i++)o=this._dateTime.parsePart(e[i][0],e[i][1]),h=h||!o;this._updateElementValue(),e.length&&" "!==e[0][0]&&(this._selectSegment(e[0][0]),t||(a=e[0][0],setTimeout(function(){d._selectSegment(a)}))),t&&(l={keyCode:39,preventDefault:function(){}},this._keydown(l)),h&&(clearTimeout(d._blinkInvalidTimeout),c=g,d.wrapper.addClass(g),d._blinkInvalidTimeout=setTimeout(function(){d.wrapper.removeClass(c)},100))}},_mouseUp:function(){var e=s(this.element[0]);e[0]===e[1]&&this._selectNearestSegment()},_scroll:function(e){if(r._activeElement()===this.element[0]&&!this.element.is("[readonly]")){e=window.event||e;var t={keyCode:37,preventDefault:function(){}};t.keyCode=e.shiftKey?(e.wheelDelta||-e.detail)>0?37:39:(e.wheelDelta||-e.detail)>0?38:40,this._keydown(t),e.returnValue=!1,e.preventDefault&&e.preventDefault(),e.stopPropagation&&e.stopPropagation()}},_form:function(){var t=this,n=t.element,i=n.attr("form"),o=i?e("#"+i):n.closest("form");o[0]&&(t._resetHandler=function(){setTimeout(function(){t.value(n[0].value)})},t._formElement=o.on("reset",t._resetHandler))},_paste:function(e){e.preventDefault()},_keydown:function(e){var t,n,i,o,a,l,d=e.keyCode;if(37==d||39==d)for(e.preventDefault(),t=s(this.element[0]),t[0]!=t[1]&&this._selectNearestSegment(),n=37==d?-1:1,i=n==-1?s(this.element[0])[0]-1:s(this.element[0])[1]+1;i>=0&&i<this._format.length;){if(w.indexOf(this._format[i])>=0){this._selectSegment(this._format[i]);break}i+=n}38!=d&&40!=d||(e.preventDefault(),t=s(this.element[0]),o=this._format[t[0]],w.indexOf(o)>=0&&(this._dateTime.modifyPart(o,38==d?1:-1),this._updateElementValue(),this._selectSegment(o))),r.support.browser.msie&&r.support.browser.version<10&&(a=e.keyCode?e.keyCode:e.which,8!==a&&46!==a||(l=this,setTimeout(function(){l._input()},0))),d===c.ENTER&&this._change()},_selectNearestSegment:function(){var e,n,i=s(this.element[0]),o=i[0];for(e=o,n=o-1;e<this._format.length||n>=0;e++,n--){if(e<this._format.length&&w.indexOf(this._format[e])!==-1)return this._selectSegment(this._format[e]),t;if(n>=0&&w.indexOf(this._format[n])!==-1)return this._selectSegment(this._format[n]),t}},_selectSegment:function(e){var t,n=-1,i=0;for(t=0;t<this._format.length;t++)this._format[t]===e&&(i=t+1,n===-1&&(n=t));n<0&&(n=0),s(this.element,n,i)}});a.plugin(y),i=function(e,n,i,o){function s(e,t,n){return e+="",t=t||2,n=t-e.length,n?k[t].substring(0,n)+e:e}function a(e){return D=e,A}function l(e,t){switch(e){case"y":h=t;break;case"M":f=t,t||(u.setMonth(0),b="");break;case"d":p=t;break;case"H":case"h":m=t,t||(w="");break;case"m":g=t;break;case"s":v=t;break;default:return}}var c,d,u=null,h=!0,f=!0,p=!0,m=!0,g=!0,v=!0,_=!0,b="",w="",y={},k=["","0","00","000","0000"],x=/dddd|ddd|dd|d|MMMM|MMM|MM|M|yyyy|yy|HH|H|hh|h|mm|m|fff|ff|f|tt|ss|s|zzz|zz|z|"[^"]*"|'[^']*'/g,C=null,S=null,T=null,D=!1,A=function(e){var n,i,o,r,a;switch(e){case"d":o=p?u.getDate():y.day;break;case"dd":o=p?s(u.getDate()):y.day;break;case"ddd":o=p&&f&&h?T.namesAbbr[u.getDay()]:y.weekday;break;case"dddd":o=p&&f&&h?T.names[u.getDay()]:y.weekday;break;case"M":o=f?u.getMonth()+1:y.month;break;case"MM":o=f?s(u.getMonth()+1):y.month;break;case"MMM":o=f?C.namesAbbr[u.getMonth()]:y.month;break;case"MMMM":o=f?C.names[u.getMonth()]:y.month;break;case"yy":o=h?s(u.getFullYear()%100):y.year;break;case"yyyy":o=h?s(u.getFullYear(),4):y.year;break;case"h":o=m?u.getHours()%12||12:y.hour;break;case"hh":o=m?s(u.getHours()%12||12):y.hour;break;case"H":o=m?u.getHours():y.hour;break;case"HH":o=m?s(u.getHours()):y.hour;break;case"m":o=g?u.getMinutes():y.minute;break;case"mm":o=g?s(u.getMinutes()):y.minute;break;case"s":o=v?u.getSeconds():y.second;break;case"ss":o=v?s(u.getSeconds()):y.second;break;case"f":o=_?Math.floor(u.getMilliseconds()/100):_;break;case"ff":o=u.getMilliseconds(),o>99&&(o=Math.floor(o/10)),o=_?s(o):e;break;case"fff":o=_?s(u.getMilliseconds(),3):e;break;case"tt":o=m?u.getHours()<12?S.AM[0]:S.PM[0]:y.dayperiod;break;case"zzz":n=u.getTimezoneOffset(),i=n<0,o=(""+Math.abs(n/60)).split(".")[0],n=Math.abs(n)-60*o,o=(i?"+":"-")+s(o),o+=":"+s(n);break;case"z":case"zz":o=u.getTimezoneOffset()/60,i=o<0,o=(""+Math.abs(o)).split(".")[0],o=(i?"+":"-")+("zz"===e?s(o):o)}if(o=o!==t?o:e.slice(1,e.length-1),D){for(o=""+o,r="","ddd"==e&&(e="EEE"),"dddd"==e&&(e="EEEE"),a=0;a<o.length;a++)r+=e[0];return r}return o};if(this.setValue=function(e){p=e},this.getValue=function(){return p},this.modifyPart=function(e,t){var n,i=new Date(u&&u.getTime?u.getTime():u);switch(e){case"y":i.setFullYear(i.getFullYear()+t);break;case"M":n=i.getMonth()+t,i.setMonth(n),i.getMonth()%12!==(n+12)%12&&(i.setDate(1),i.setMonth(n));break;case"d":case"E":i.setDate(i.getDate()+t);break;case"H":case"h":i.setHours(i.getHours()+t);break;case"m":i.setMinutes(i.getMinutes()+t);break;case"s":i.setSeconds(i.getSeconds()+t);break;case"t":i.setHours((i.getHours()+12)%24)}i.getFullYear()>0&&(l(e,!0),u=i)},this.parsePart=function(e,t){var n,i,o,r,s,a,c,d,_;if(!t)return l(e,!1),!0;switch(n=new Date(u&&u.getTime?u.getTime():u),e){case"d":if(o=(p?10*n.getDate():0)+parseInt(t,10),isNaN(o))return;for(;o>31;)o=parseInt((""+o).slice(1),10);if(o<1)p=!1;else{if(n.setDate(o),n.getMonth()!==u.getMonth())return;p=!0}break;case"M":if(r=(f?10*(n.getMonth()+1):0)+parseInt(t,10),isNaN(r)){for(s=S.months.names,b+=t.toLowerCase();b.length>0;){for(a=0;a<s.length;a++)if(0===s[a].toLowerCase().indexOf(b))return n.setMonth(a),f=!0,u=n,!0;b=b.substring(1,b.length)}return!1}for(;r>12;)r=parseInt((""+r).slice(1),10);r<1?f=!1:(n.setMonth(r-1),n.getMonth()!==r-1&&(n.setDate(1),n.setMonth(r-1)),f=!0);break;case"y":if(c=(h?10*n.getFullYear():0)+parseInt(t,10),isNaN(c))return;for(;c>9999;)c=parseInt((""+c).slice(1),10);c<1?h=!1:(n.setFullYear(c),h=!0);break;case"h":if(i=(m?10*(n.getHours()%12||12):0)+parseInt(t,10),isNaN(i))return;for(;i>12;)i=parseInt((""+i).slice(1),10);n.setHours(12*Math.floor(n.getHours()/12)+i%12),m=!0;break;case"H":if(i=(m?10*n.getHours():0)+parseInt(t,10),isNaN(i))return;for(;i>23;)i=parseInt((""+i).slice(1),10);n.setHours(i),m=!0;break;case"m":if(d=(g?10*n.getMinutes():0)+parseInt(t,10),isNaN(d))return;for(;d>59;)d=parseInt((""+d).slice(1),10);n.setMinutes(d),g=!0;break;case"s":if(_=(v?10*n.getSeconds():0)+parseInt(t,10),isNaN(_))return;for(;_>59;)_=parseInt((""+_).slice(1),10);n.setSeconds(_),v=!0;break;case"t":if(m){for(w+=t.toLowerCase();w.length>0;){if(0===S.AM[0].toLowerCase().indexOf(w)&&n.getHours()>=12||0===S.PM[0].toLowerCase().indexOf(w)&&n.getHours()<12)return n.setHours((n.getHours()+12)%24),u=n,!0;w=w.substring(1,w.length)}return!1}}return u=n,!0},this.toPair=function(e,t,n){return e?(t=r.getCulture(t),S=t.calendars.standard,e=S.patterns[e]||e,T=S.days,C=S.months,y=n,[e.replace(x,a(!1)),e.replace(x,a(!0))]):["",""]},this.getDateObject=function(){return h&&f&&p&&m&&g&&v&&_?new Date(u.getTime()):null},e)u=new Date(e.getTime());else for(u=new Date,c=this.toPair(n,i,o)[1],d=0;d<c.length;d++)l(c[d],!1)}}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.autocomplete.min",["kendo.list.min","kendo.mobile.scroller.min"],e)}(function(){return function(e,t){function n(e,t,n){return n?t.substring(0,e).split(n).length-1:0}function i(e,t,i){return t.split(i)[n(e,t,i)]}function o(e,t,i,o,r){var s=t.split(o);return s.splice(n(e,t,o),1,i),o&&""!==s[s.length-1]&&s.push(""),s.join(r)}var r=window.kendo,s=r.support,a=r.caret,l=r._activeElement,c=s.placeholder,d=r.ui,u=d.List,h=r.keys,f=r.data.DataSource,p="aria-disabled",m="aria-readonly",g="change",v="k-state-default",_="disabled",b="readonly",w="k-state-focused",y="k-state-selected",k="k-state-disabled",x="k-state-hover",C=".kendoAutoComplete",S="mouseenter"+C+" mouseleave"+C,T=e.proxy,D=u.extend({init:function(t,n){var i,o,s=this;s.ns=C,n=e.isArray(n)?{dataSource:n}:n,u.fn.init.call(s,t,n),t=s.element,n=s.options,n.placeholder=n.placeholder||t.attr("placeholder"),c&&t.attr("placeholder",n.placeholder),s._wrapper(),s._loader(),s._clearButton(),s._dataSource(),s._ignoreCase(),t[0].type="text",i=s.wrapper,s._popup(),t.addClass("k-input").on("keydown"+C,T(s._keydown,s)).on("keypress"+C,T(s._keypress,s)).on("paste"+C,T(s._search,s)).on("focus"+C,function(){s._prev=s._accessor(),s._oldText=s._prev,s._placeholder(!1),i.addClass(w)}).on("focusout"+C,function(){s._change(),s._placeholder(),i.removeClass(w)}).attr({autocomplete:"off",role:"textbox","aria-haspopup":!0}),s._clear.on("click"+C,T(s._clearValue,s)),s._enable(),s._old=s._accessor(),t[0].id&&t.attr("aria-owns",s.ul[0].id),s._aria(),s._placeholder(),s._initList(),o=e(s.element).parents("fieldset").is(":disabled"),o&&s.enable(!1),s.listView.bind("click",function(e){e.preventDefault()}),s._resetFocusItemHandler=e.proxy(s._resetFocusItem,s),r.notify(s),s._toggleCloseVisibility()},options:{name:"AutoComplete",enabled:!0,suggest:!1,template:"",groupTemplate:"#:data#",fixedGroupTemplate:"#:data#",dataTextField:"",minLength:1,enforceMinLength:!1,delay:200,height:200,filter:"startswith",ignoreCase:!0,highlightFirst:!1,separator:null,placeholder:"",animation:{},virtual:!1,value:null,clearButton:!0},_dataSource:function(){var e=this;e.dataSource&&e._refreshHandler?e._unbindDataSource():(e._progressHandler=T(e._showBusy,e),e._errorHandler=T(e._hideBusy,e)),e.dataSource=f.create(e.options.dataSource).bind("progress",e._progressHandler).bind("error",e._errorHandler)},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this.listView.setDataSource(this.dataSource)},events:["open","close",g,"select","filtering","dataBinding","dataBound"],setOptions:function(e){var t=this._listOptions(e);u.fn.setOptions.call(this,e),this.listView.setOptions(t),this._accessors(),this._aria()},_listOptions:function(t){var n=u.fn._listOptions.call(this,e.extend(t,{skipUpdateOnBind:!0}));return n.dataValueField=n.dataTextField,n.selectedItemChange=null,n},_editable:function(e){var t=this,n=t.element,i=t.wrapper.off(C),o=e.readonly,r=e.disable;o||r?(i.addClass(r?k:v).removeClass(r?v:k),n.attr(_,r).attr(b,o).attr(p,r).attr(m,o)):(i.addClass(v).removeClass(k).on(S,t._toggleHover),n.removeAttr(_).removeAttr(b).attr(p,!1).attr(m,!1))},close:function(){var e=this,t=e.listView.focus();t&&t.removeClass(y),e.popup.close()},destroy:function(){var e=this;e.element.off(C),e._clear.off(C),e.wrapper.off(C),u.fn.destroy.call(e)},refresh:function(){this.listView.refresh()},select:function(e){this._select(e)},search:function(t){var n,o=this,r=o.options,s=r.ignoreCase,l=o._separator();t=t||o._accessor(),clearTimeout(o._typingTimeout),l&&(t=i(a(o.element)[0],t,l)),n=t.length,(!r.enforceMinLength&&!n||n>=r.minLength)&&(o._open=!0,o._mute(function(){this.listView.value([])}),o._filterSource({value:s?t.toLowerCase():t,operator:r.filter,field:r.dataTextField,ignoreCase:s}),o.one("close",e.proxy(o._unifySeparators,o))),o._toggleCloseVisibility()},suggest:function(e){var i,o=this,r=o._last,s=o._accessor(),c=o.element[0],d=a(c)[0],f=o._separator(),p=s.split(f),m=n(d,s,f),g=d;return r==h.BACKSPACE||r==h.DELETE?(o._last=t,t):(e=e||"","string"!=typeof e&&(e[0]&&(e=o.dataSource.view()[u.inArray(e[0],o.ul[0])]),e=e?o._text(e):""),d<=0&&(d=s.toLowerCase().indexOf(e.toLowerCase())+1),i=s.substring(0,d).lastIndexOf(f),i=i>-1?d-(i+f.length):d,s=p[m].substring(0,i),e&&(e=""+e,i=e.toLowerCase().indexOf(s.toLowerCase()),i>-1&&(e=e.substring(i+s.length),g=d+e.length,s+=e),f&&""!==p[p.length-1]&&p.push("")),p[m]=s,o._accessor(p.join(f||"")),c===l()&&a(c,d,g),t)},value:function(e){return e===t?this._accessor():(this.listView.value(e),this._accessor(e),this._old=this._accessor(),this._oldText=this._accessor(),t)},_click:function(e){var n=e.item,i=this,o=i.element,r=i.listView.dataItemByIndex(i.listView.getElementIndex(n));return e.preventDefault(),i._active=!0,i.trigger("select",{dataItem:r,item:n})?(i.close(),t):(i._oldText=o.val(),i._select(n).done(function(){i._blur(),a(o,o.val().length)}),t)},_clearText:e.noop,_resetFocusItem:function(){var e=this.options.highlightFirst?0:-1;this.options.virtual&&this.listView.scrollTo(0),this.listView.focus(e)},_listBound:function(){var e,n=this,i=n.popup,o=n.options,r=n.dataSource.flatView(),s=r.length,a=n.dataSource._group.length,c=n.element[0]===l();n._renderFooter(),n._renderNoData(),n._toggleNoData(!s),n._toggleHeader(!!a&&!!s),n._resizePopup(),i.position(),s&&o.suggest&&c&&n.suggest(r[0]),n._open&&(n._open=!1,e=n._allowOpening()?"open":"close",n._typingTimeout&&!c&&(e="close"),s&&(n._resetFocusItem(),o.virtual&&n.popup.unbind("activate",n._resetFocusItemHandler).one("activate",n._resetFocusItemHandler)),i[e](),n._typingTimeout=t),n._touchScroller&&n._touchScroller.reset(),n._hideBusy(),n._makeUnselectable(),n.trigger("dataBound")},_mute:function(e){this._muted=!0,e.call(this),this._muted=!1},_listChange:function(){var e=this._active||this.element[0]===l();e&&!this._muted&&this._selectValue(this.listView.selectedDataItems()[0])},_selectValue:function(e){var t=this._separator(),n="";e&&(n=this._text(e)),null===n&&(n=""),t&&(n=o(a(this.element)[0],this._accessor(),n,t,this._defaultSeparator())),this._prev=n,this._accessor(n),this._placeholder()},_unifySeparators:function(){return this._accessor(this.value().split(this._separator()).join(this._defaultSeparator())),this},_change:function(){var e=this,t=e._unifySeparators().value(),n=t!==u.unifyType(e._old,typeof t),i=n&&!e._typing,o=e._oldText!==t;e._old=t,e._oldText=t,(i||o)&&e.element.trigger(g),n&&e.trigger(g),e.typing=!1,e._toggleCloseVisibility()},_accessor:function(e){var n=this,i=n.element[0];return e===t?(e=i.value,i.className.indexOf("k-readonly")>-1&&e===n.options.placeholder?"":e):(i.value=null===e?"":e,n._placeholder(),t)},_keydown:function(e){var t,n,i=this,o=e.keyCode,r=i.listView,s=i.popup.visible(),a=r.focus();if(i._last=o,o===h.DOWN)s&&this._move(a?"focusNext":"focusFirst"),e.preventDefault();else if(o===h.UP)s&&this._move(a?"focusPrev":"focusLast"),e.preventDefault();else if(o===h.ENTER||o===h.TAB){if(o===h.ENTER&&s&&e.preventDefault(),s&&a){if(t=r.dataItemByIndex(r.getElementIndex(a)),i.trigger("select",{dataItem:t,item:a}))return;this._select(a)}this._blur()}else o===h.ESC?(s&&e.preventDefault(),i.close()):!i.popup.visible()||o!==h.PAGEDOWN&&o!==h.PAGEUP?i._search():(e.preventDefault(),n=o===h.PAGEDOWN?1:-1,r.scrollWith(n*r.screenHeight()))},_keypress:function(){this._oldText=this.element.val(),this._typing=!0},_move:function(e){this.listView[e](),this.options.suggest&&this.suggest(this.listView.focus())},_hideBusy:function(){var e=this;clearTimeout(e._busy),e._loading.hide(),e.element.attr("aria-busy",!1),e._busy=null,e._showClear()},_showBusy:function(){var e=this;e._busy||(e._busy=setTimeout(function(){e.element.attr("aria-busy",!0),e._loading.show(),e._hideClear()},100))},_placeholder:function(e){if(!c){var n,i=this,o=i.element,r=i.options.placeholder;if(r){if(n=o.val(),e===t&&(e=!n),e||(r=n!==r?n:""),n===i._old&&!e)return;o.toggleClass("k-readonly",e).val(r),r||o[0]!==document.activeElement||a(o[0],0,0)}}},_separator:function(){var e=this.options.separator;return e instanceof Array?RegExp(e.join("|"),"gi"):e},_defaultSeparator:function(){var e=this.options.separator;return e instanceof Array?e[0]:e},_inputValue:function(){return this.element.val()},_search:function(){var e=this;clearTimeout(e._typingTimeout),e._typingTimeout=setTimeout(function(){e._prev!==e._accessor()&&(e._prev=e._accessor(),e.search())},e.options.delay)},_select:function(e){var t=this;return t._active=!0,t.listView.select(e).done(function(){t._active=!1})},_loader:function(){this._loading=e('<span class="k-icon k-i-loading" style="display:none"></span>').insertAfter(this.element)},_clearButton:function(){this._clear=e('<span unselectable="on" class="k-icon k-clear-value k-i-close" title="clear"></span>').attr({role:"button",tabIndex:-1}),this.options.clearButton&&this._clear.insertAfter(this.element)},_toggleHover:function(t){e(t.currentTarget).toggleClass(x,"mouseenter"===t.type)},_toggleCloseVisibility:function(){this.value()?this._showClear():this._hideClear()},_wrapper:function(){var e,t=this,n=t.element,i=n[0];e=n.parent(),e.is("span.k-widget")||(e=n.wrap("<span />").parent()),e.attr("tabindex",-1),e.attr("role","presentation"),e[0].style.cssText=i.style.cssText,n.css({width:"100%",height:i.style.height}),t._focused=t.element,t.wrapper=e.addClass("k-widget k-autocomplete k-header").addClass(i.className)}});d.plugin(D)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.dropdownlist.min",["kendo.list.min","kendo.mobile.scroller.min"],e)}(function(){return function(e,t){function n(e,t,n){for(var i,o=0,r=t.length-1;o<r;++o)i=t[o],i in e||(e[i]={}),e=e[i];e[t[r]]=n}function i(e,t){return e>=t&&(e-=t),e}function o(e,t){for(var n=0;n<e.length;n++)if(e.charAt(n)!==t)return!1;return!0}var r=window.kendo,s=r.ui,a=s.List,l=s.Select,c=r.support,d=r._activeElement,u=r.data.ObservableObject,h=r.keys,f=".kendoDropDownList",p="disabled",m="readonly",g="change",v="k-state-focused",_="k-state-default",b="k-state-disabled",w="aria-disabled",y="mouseenter"+f+" mouseleave"+f,k="tabindex",x="filter",C="accept",S="The `optionLabel` option is not valid due to missing fields. Define a custom optionLabel as shown here http://docs.telerik.com/kendo-ui/api/javascript/ui/dropdownlist#configuration-optionLabel",T=e.proxy,D=l.extend({init:function(n,i){var o,s,a,c=this,d=i&&i.index;c.ns=f,i=e.isArray(i)?{dataSource:i}:i,l.fn.init.call(c,n,i),i=c.options,n=c.element.on("focus"+f,T(c._focusHandler,c)),c._focusInputHandler=e.proxy(c._focusInput,c),c.optionLabel=e(),c._optionLabel(),c._inputTemplate(),c._reset(),c._prev="",c._word="",c._wrapper(),c._tabindex(),c.wrapper.data(k,c.wrapper.attr(k)),c._span(),c._popup(),c._mobile(),c._dataSource(),c._ignoreCase(),c._filterHeader(),c._aria(),c._enable(),c._oldIndex=c.selectedIndex=-1,d!==t&&(i.index=d),c._initialIndex=i.index,c.requireValueMapper(c.options),c._initList(),c._cascade(),i.autoBind?c.dataSource.fetch():c.selectedIndex===-1&&(s=i.text||"",s||(o=i.optionLabel,o&&0===i.index?s=o:c._isSelect&&(s=n.children(":selected").text())),c._textAccessor(s)),a=e(c.element).parents("fieldset").is(":disabled"),a&&c.enable(!1),c.listView.bind("click",function(e){e.preventDefault()}),r.notify(c)},options:{name:"DropDownList",enabled:!0,autoBind:!0,index:0,text:null,value:null,delay:500,height:200,dataTextField:"",dataValueField:"",optionLabel:"",cascadeFrom:"",cascadeFromField:"",ignoreCase:!0,animation:{},filter:"none",minLength:1,enforceMinLength:!1,virtual:!1,template:null,valueTemplate:null,optionLabelTemplate:null,groupTemplate:"#:data#",fixedGroupTemplate:"#:data#"},events:["open","close",g,"select","filtering","dataBinding","dataBound","cascade","set"],setOptions:function(e){l.fn.setOptions.call(this,e),this.listView.setOptions(this._listOptions(e)),this._optionLabel(),this._inputTemplate(),this._accessors(),this._filterHeader(),this._enable(),this._aria(),!this.value()&&this.hasOptionLabel()&&this.select(0)},destroy:function(){var e=this;l.fn.destroy.call(e),e.wrapper.off(f),e.element.off(f),e._inputWrapper.off(f),e._arrow.off(),e._arrow=null,e._arrowIcon=null,e.optionLabel.off()},open:function(){var e=this;e.popup.visible()||(e.listView.bound()&&e._state!==C?e._allowOpening()&&(e.popup.one("activate",e._focusInputHandler),e.popup.open(),e._resizeFilterInput(),e._focusItem()):(e._open=!0,e._state="rebind",e.filterInput&&(e.filterInput.val(""),e._prev=""),e.filterInput&&1!==e.options.minLength?(e.refresh(),e.popup.one("activate",e._focusInputHandler),e.popup.open(),e._resizeFilterInput()):e._filterSource()))},_focusInput:function(){this._focusElement(this.filterInput)},_resizeFilterInput:function(){var e,t,n=this.filterInput,i=this._prevent;n&&(e=this.filterInput[0]===d(),t=r.caret(this.filterInput[0])[0],this._prevent=!0,n.css("display","none").css("width",this.popup.element.css("width")).css("display","inline-block"),e&&(n.focus(),r.caret(n[0],t)),this._prevent=i)},_allowOpening:function(){return this.hasOptionLabel()||this.filterInput||l.fn._allowOpening.call(this)},toggle:function(e){this._toggle(e,!0)},current:function(e){var n;return e===t?(n=this.listView.focus(),!n&&0===this.selectedIndex&&this.hasOptionLabel()?this.optionLabel:n):(this._focus(e),t)},dataItem:function(n){var i=this,o=null;if(null===n)return n;if(n===t)o=i.listView.selectedDataItems()[0];else{if("number"!=typeof n){if(i.options.virtual)return i.dataSource.getByUid(e(n).data("uid"));n=n.hasClass("k-list-optionlabel")?-1:e(i.items()).index(n)}else i.hasOptionLabel()&&(n-=1);o=i.dataSource.flatView()[n]}return o||(o=i._optionLabelDataItem()),o},refresh:function(){this.listView.refresh()},text:function(e){var n,i=this,o=i.options.ignoreCase;return e=null===e?"":e,e===t?i._textAccessor():"string"!=typeof e?(i._textAccessor(e),t):(n=o?e.toLowerCase():e,i._select(function(e){return e=i._text(e),o&&(e=(e+"").toLowerCase()),e===n}).done(function(){i._textAccessor(i.dataItem()||e)}),t)},_clearFilter:function(){e(this.filterInput).val(""),l.fn._clearFilter.call(this)},value:function(e){var n=this,i=n.listView,o=n.dataSource;return e===t?(e=n._accessor()||n.listView.value()[0],e===t||null===e?"":e):(n.requireValueMapper(n.options,e),!e&&n.hasOptionLabel()||(n._initialIndex=null),this.trigger("set",{value:e}),n._request&&n.options.cascadeFrom&&n.listView.bound()?(n._valueSetter&&o.unbind(g,n._valueSetter),n._valueSetter=T(function(){n.value(e)},n),o.one(g,n._valueSetter),t):(n._isFilterEnabled()&&i.bound()&&i.isFiltered()?n._clearFilter():n._fetchData(),i.value(e).done(function(){n._old=n._accessor(),n._oldIndex=n.selectedIndex}),t))},hasOptionLabel:function(){return this.optionLabel&&!!this.optionLabel[0]},_optionLabel:function(){var n=this,i=n.options,o=i.optionLabel,s=i.optionLabelTemplate;return o?(s||(s="#:",s+="string"==typeof o?"data":r.expr(i.dataTextField,"data"),s+="#"),"function"!=typeof s&&(s=r.template(s)),n.optionLabelTemplate=s,n.hasOptionLabel()||(n.optionLabel=e('<div class="k-list-optionlabel"></div>').prependTo(n.list)),n.optionLabel.html(s(o)).off().click(T(n._click,n)).on(y,n._toggleHover),n.angular("compile",function(){return{elements:n.optionLabel,data:[{dataItem:n._optionLabelDataItem()}]}}),t):(n.optionLabel.off().remove(),n.optionLabel=e(),t)},_optionLabelText:function(){var e=this.options.optionLabel;return"string"==typeof e?e:this._text(e)},_optionLabelDataItem:function(){var t=this,n=t.options.optionLabel;return t.hasOptionLabel()?e.isPlainObject(n)?new u(n):t._assignInstance(t._optionLabelText(),""):null},_buildOptions:function(e){var n,i,o,r=this;r._isSelect&&(n=r.listView.value()[0],i=r._optionLabelDataItem(),o=i&&r._value(i),n!==t&&null!==n||(n=""),i&&(o!==t&&null!==o||(o=""),i='<option value="'+o+'">'+r._text(i)+"</option>"),r._options(e,i,n),n!==a.unifyType(r._accessor(),typeof n)&&(r._customOption=null,r._custom(n)))},_listBound:function(){var e,t=this,n=t._initialIndex,i=t._state===x,o=t.dataSource.flatView();t._presetValue=!1,t._renderFooter(),t._renderNoData(),t._toggleNoData(!o.length),t._resizePopup(!0),t.popup.position(),t._buildOptions(o),t._makeUnselectable(),i||(t._open&&t.toggle(t._allowOpening()),t._open=!1,t._fetch||(o.length?(!t.listView.value().length&&n>-1&&null!==n&&t.select(n),t._initialIndex=null,e=t.listView.selectedDataItems()[0],e&&t.text()!==t._text(e)&&t._selectValue(e)):t._textAccessor()!==t._optionLabelText()&&(t.listView.value(""),t._selectValue(null),t._oldIndex=t.selectedIndex))),t._hideBusy(),t.trigger("dataBound")},_listChange:function(){this._selectValue(this.listView.selectedDataItems()[0]),(this._presetValue||this._old&&this._oldIndex===-1)&&(this._oldIndex=this.selectedIndex)},_filterPaste:function(){this._search()},_focusHandler:function(){this.wrapper.focus()},_focusinHandler:function(){this._inputWrapper.addClass(v),this._prevent=!1},_focusoutHandler:function(){var e=this,t=window.self!==window.top;e._prevent||(clearTimeout(e._typingTimeout),c.mobileOS.ios&&t?e._change():e._blur(),e._inputWrapper.removeClass(v),e._prevent=!0,e._open=!1,e.element.blur())},_wrapperMousedown:function(){this._prevent=!!this.filterInput},_wrapperClick:function(e){e.preventDefault(),this.popup.unbind("activate",this._focusInputHandler),this._focused=this.wrapper,this._toggle()},_editable:function(e){var t=this,n=t.element,i=e.disable,o=e.readonly,r=t.wrapper.add(t.filterInput).off(f),s=t._inputWrapper.off(y);o||i?i?(r.removeAttr(k),s.addClass(b).removeClass(_)):(s.addClass(_).removeClass(b),r.on("focusin"+f,T(t._focusinHandler,t)).on("focusout"+f,T(t._focusoutHandler,t))):(n.removeAttr(p).removeAttr(m),s.addClass(_).removeClass(b).on(y,t._toggleHover),r.attr(k,r.data(k)).attr(w,!1).on("keydown"+f,T(t._keydown,t)).on("focusin"+f,T(t._focusinHandler,t)).on("focusout"+f,T(t._focusoutHandler,t)).on("mousedown"+f,T(t._wrapperMousedown,t)).on("paste"+f,T(t._filterPaste,t)),t.wrapper.on("click"+f,T(t._wrapperClick,t)),t.filterInput||r.on("keypress"+f,T(t._keypress,t))),n.attr(p,i).attr(m,o),r.attr(w,i)},_keydown:function(e){var n,i,o,r=this,s=e.keyCode,a=e.altKey,l=r.popup.visible();if(r.filterInput&&(n=r.filterInput[0]===d()),s===h.LEFT?(s=h.UP,i=!0):s===h.RIGHT&&(s=h.DOWN,i=!0),!i||!n){if(e.keyCode=s,(a&&s===h.UP||s===h.ESC)&&r._focusElement(r.wrapper),r._state===x&&s===h.ESC&&r._clearFilter(),s===h.ENTER&&r._typingTimeout&&r.filterInput&&l)return e.preventDefault(),t;if(i=r._move(e),!i){if((!l||!r.filterInput)&&(o=r._focus(),s===h.HOME?(i=!0,r._firstItem()):s===h.END&&(i=!0,r._lastItem()),i)){if(r.trigger("select",{dataItem:r._getElementDataItem(r._focus()),item:r._focus()}))return r._focus(o),t;r._select(r._focus(),!0).done(function(){l||r._blur()}),e.preventDefault()}a||i||!r.filterInput||r._search()}}},_matchText:function(e,n){var i=this.options.ignoreCase;return e!==t&&null!==e&&(e+="",i&&(e=e.toLowerCase()),0===e.indexOf(n))},_shuffleData:function(e,t){var n=this._optionLabelDataItem();return n&&(e=[n].concat(e)),e.slice(t).concat(e.slice(0,t))},_selectNext:function(){var e,t,n,r=this,s=r.dataSource.flatView(),a=s.length+(r.hasOptionLabel()?1:0),l=o(r._word,r._last),c=r.selectedIndex;for(c===-1?c=0:(c+=l?1:0,c=i(c,a)),s=s.toJSON?s.toJSON():s.slice(),s=r._shuffleData(s,c),n=0;n<a&&(t=r._text(s[n]),!l||!r._matchText(t,r._last))&&!r._matchText(t,r._word);n++);n!==a&&(e=r._focus(),r._select(i(c+n,a)).done(function(){var t=function(){r.popup.visible()||r._change()};r.trigger("select",{dataItem:r._getElementDataItem(r._focus()),item:r._focus()})?r._select(e).done(t):t()}))},_keypress:function(e){var t,n=this;0!==e.which&&e.keyCode!==r.keys.ENTER&&(t=String.fromCharCode(e.charCode||e.keyCode),n.options.ignoreCase&&(t=t.toLowerCase())," "===t&&e.preventDefault(),n._word+=t,n._last=t,n._search())},_popupOpen:function(){var e=this.popup;e.wrapper=r.wrap(e.element),e.element.closest(".km-root")[0]&&(e.wrapper.addClass("km-popup km-widget"),this.wrapper.addClass("km-widget"))},_popup:function(){l.fn._popup.call(this),this.popup.one("open",T(this._popupOpen,this))},_getElementDataItem:function(e){return e&&e[0]?e[0]===this.optionLabel[0]?this._optionLabelDataItem():this.listView.dataItemByIndex(this.listView.getElementIndex(e)):null},_click:function(n){var i=this,o=n.item||e(n.currentTarget);return n.preventDefault(),i.trigger("select",{dataItem:i._getElementDataItem(o),item:o})?(i.close(),t):(i._userTriggered=!0,i._select(o).done(function(){i._focusElement(i.wrapper),i._blur()}),t)},_focusElement:function(e){var t=d(),n=this.wrapper,i=this.filterInput,o=e===i?n:i,r=c.mobileOS&&(c.touch||c.MSPointers||c.pointers);i&&i[0]===e[0]&&r||i&&o[0]===t&&(this._prevent=!0,this._focused=e.focus());
},_searchByWord:function(e){var t,n;e&&(t=this,n=t.options.ignoreCase,n&&(e=e.toLowerCase()),t._select(function(n){return t._matchText(t._text(n),e)}))},_inputValue:function(){return this.text()},_search:function(){var e=this,n=e.dataSource;if(clearTimeout(e._typingTimeout),e._isFilterEnabled())e._typingTimeout=setTimeout(function(){var t=e.filterInput.val();e._prev!==t&&(e._prev=t,e.search(t),e._resizeFilterInput()),e._typingTimeout=null},e.options.delay);else{if(e._typingTimeout=setTimeout(function(){e._word=""},e.options.delay),!e.listView.bound())return n.fetch().done(function(){e._selectNext()}),t;e._selectNext()}},_get:function(t){var n,i,o,r="function"==typeof t,s=r?e():e(t);if(this.hasOptionLabel()&&("number"==typeof t?t>-1&&(t-=1):s.hasClass("k-list-optionlabel")&&(t=-1)),r){for(n=this.dataSource.flatView(),o=0;o<n.length;o++)if(t(n[o])){t=o,i=!0;break}i||(t=-1)}return t},_firstItem:function(){this.hasOptionLabel()?this._focus(this.optionLabel):this.listView.focusFirst()},_lastItem:function(){this._resetOptionLabel(),this.listView.focusLast()},_nextItem:function(){this.optionLabel.hasClass("k-state-focused")?(this._resetOptionLabel(),this.listView.focusFirst()):this.listView.focusNext()},_prevItem:function(){this.optionLabel.hasClass("k-state-focused")||(this.listView.focusPrev(),this.listView.focus()||this._focus(this.optionLabel))},_focusItem:function(){var e=this.options,n=this.listView,i=n.focus(),o=n.select();o=o[o.length-1],o===t&&e.highlightFirst&&!i&&(o=0),o!==t?n.focus(o):!e.optionLabel||e.virtual&&"dataItem"===e.virtual.mapValueTo?n.scrollToIndex(0):(this._focus(this.optionLabel),this._select(this.optionLabel))},_resetOptionLabel:function(e){this.optionLabel.removeClass("k-state-focused"+(e||"")).removeAttr("id")},_focus:function(e){var n=this.listView,i=this.optionLabel;return e===t?(e=n.focus(),!e&&i.hasClass("k-state-focused")&&(e=i),e):(this._resetOptionLabel(),e=this._get(e),n.focus(e),e===-1&&(i.addClass("k-state-focused").attr("id",n._optionID),this._focused.add(this.filterInput).removeAttr("aria-activedescendant").attr("aria-activedescendant",n._optionID)),t)},_select:function(e,t){var n=this;return e=n._get(e),n.listView.select(e).done(function(){t||n._state!==x||(n._state=C),e===-1&&n._selectValue(null)})},_selectValue:function(e){var n=this,i=n.options.optionLabel,o=n.listView.select(),r="",s="";o=o[o.length-1],o===t&&(o=-1),this._resetOptionLabel(" k-state-selected"),e||0===e?(s=e,r=n._dataValue(e),i&&(o+=1)):i&&(n._focus(n.optionLabel.addClass("k-state-selected")),s=n._optionLabelText(),r="string"==typeof i?"":n._value(i),o=0),n.selectedIndex=o,null===r&&(r=""),n._textAccessor(s),n._accessor(r,o),n._triggerCascade()},_mobile:function(){var e=this,t=e.popup,n=c.mobileOS,i=t.element.parents(".km-root").eq(0);i.length&&n&&(t.options.animation.open.effects=n.android||n.meego?"fadeIn":n.ios||n.wp?"slideIn:up":t.options.animation.open.effects)},_filterHeader:function(){var t;this.filterInput&&(this.filterInput.off(f).parent().remove(),this.filterInput=null),this._isFilterEnabled()&&(t='<span class="k-icon k-i-zoom"></span>',this.filterInput=e('<input class="k-textbox"/>').attr({placeholder:this.element.attr("placeholder"),title:this.element.attr("title"),role:"listbox","aria-haspopup":!0,"aria-expanded":!1}),this.list.prepend(e('<span class="k-list-filter" />').append(this.filterInput.add(t))))},_span:function(){var t,n=this,i=n.wrapper,o="span.k-input";t=i.find(o),t[0]||(i.append('<span unselectable="on" class="k-dropdown-wrap k-state-default"><span unselectable="on" class="k-input">&nbsp;</span><span unselectable="on" class="k-select" aria-label="select"><span class="k-icon k-i-arrow-60-down"></span></span></span>').append(n.element),t=i.find(o)),n.span=t,n._inputWrapper=e(i[0].firstChild),n._arrow=i.find(".k-select"),n._arrowIcon=n._arrow.find(".k-icon")},_wrapper:function(){var e,t=this,n=t.element,i=n[0];e=n.parent(),e.is("span.k-widget")||(e=n.wrap("<span />").parent(),e[0].style.cssText=i.style.cssText,e[0].title=i.title),t._focused=t.wrapper=e.addClass("k-widget k-dropdown k-header").addClass(i.className).css("display","").attr({accesskey:n.attr("accesskey"),unselectable:"on",role:"listbox","aria-haspopup":!0,"aria-expanded":!1}),n.hide().removeAttr("accesskey")},_clearSelection:function(e){this.select(e.value()?0:-1)},_inputTemplate:function(){var t=this,n=t.options.valueTemplate;if(n=n?r.template(n):e.proxy(r.template("#:this._text(data)#",{useWithBlock:!1}),t),t.valueTemplate=n,t.hasOptionLabel()&&!t.options.optionLabelTemplate)try{t.valueTemplate(t._optionLabelDataItem())}catch(i){throw Error(S)}},_textAccessor:function(n){var i,o=null,r=this.valueTemplate,s=this._optionLabelText(),a=this.span;if(n===t)return a.text();e.isPlainObject(n)||n instanceof u?o=n:s&&s===n&&(o=this.options.optionLabel),o||(o=this._assignInstance(n,this._accessor())),this.hasOptionLabel()&&(o!==s&&this._text(o)!==s||(r=this.optionLabelTemplate,"string"!=typeof this.options.optionLabel||this.options.optionLabelTemplate||(o=s))),i=function(){return{elements:a.get(),data:[{dataItem:o}]}},this.angular("cleanup",i);try{a.html(r(o))}catch(l){a.html("")}this.angular("compile",i)},_preselect:function(e,t){e||t||(t=this._optionLabelText()),this._accessor(e),this._textAccessor(t),this._old=this._accessor(),this._oldIndex=this.selectedIndex,this.listView.setValue(e),this._initialIndex=null,this._presetValue=!0},_assignInstance:function(e,t){var i=this.options.dataTextField,o={};return i?(n(o,i.split("."),e),n(o,this.options.dataValueField.split("."),t),o=new u(o)):o=e,o}});s.plugin(D)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.combobox.min",["kendo.list.min","kendo.mobile.scroller.min"],e)}(function(){return function(e,t){var n=window.kendo,i=n.ui,o=i.List,r=i.Select,s=n.caret,a=n.support,l=a.placeholder,c=n._activeElement,d=n.keys,u=".kendoComboBox",h="click"+u,f="mousedown"+u,p="disabled",m="readonly",g="change",v="k-state-default",_="k-state-focused",b="k-state-disabled",w="aria-disabled",y="filter",k="accept",x="rebind",C="mouseenter"+u+" mouseleave"+u,S=e.proxy,T=r.extend({init:function(t,i){var o,s,a=this;a.ns=u,i=e.isArray(i)?{dataSource:i}:i,r.fn.init.call(a,t,i),i=a.options,t=a.element.on("focus"+u,S(a._focusHandler,a)),i.placeholder=i.placeholder||t.attr("placeholder"),a._reset(),a._wrapper(),a._input(),a._clearButton(),a._tabindex(a.input),a._popup(),a._dataSource(),a._ignoreCase(),a._enable(),a._oldIndex=a.selectedIndex=-1,a._aria(),a._initialIndex=i.index,a.requireValueMapper(a.options),a._initList(),a._cascade(),i.autoBind?a._filterSource():(o=i.text,!o&&a._isSelect&&(o=t.children(":selected").text()),o&&a._setText(o)),o||a._placeholder(),s=e(a.element).parents("fieldset").is(":disabled"),s&&a.enable(!1),n.notify(a),a._toggleCloseVisibility()},options:{name:"ComboBox",enabled:!0,index:-1,text:null,value:null,autoBind:!0,delay:200,dataTextField:"",dataValueField:"",minLength:1,enforceMinLength:!1,height:200,highlightFirst:!0,filter:"none",placeholder:"",suggest:!1,cascadeFrom:"",cascadeFromField:"",ignoreCase:!0,animation:{},virtual:!1,template:null,groupTemplate:"#:data#",fixedGroupTemplate:"#:data#",clearButton:!0,syncValueAndText:!0},events:["open","close",g,"select","filtering","dataBinding","dataBound","cascade","set"],setOptions:function(e){r.fn.setOptions.call(this,e),this.listView.setOptions(e),this._accessors(),this._aria()},destroy:function(){var e=this;e.input.off(u),e.element.off(u),e._inputWrapper.off(u),clearTimeout(e._pasteTimeout),e._arrow.off(h+" "+f),e._clear.off(h+" "+f),r.fn.destroy.call(e)},_change:function(){var e=this,n=e.text(),i=n&&n!==e._oldText&&n!==e.options.placeholder,o=e.selectedIndex,s=o===-1;return!e.options.syncValueAndText&&!e.value()&&s&&i?(e._old="",e._oldIndex=o,e._oldText=n,e._typing||e.element.trigger(g),e.trigger(g),e._typing=!1,t):(r.fn._change.call(e),e._toggleCloseVisibility(),t)},_focusHandler:function(){this.input.focus()},_arrowClick:function(){this._toggle()},_inputFocus:function(){this._inputWrapper.addClass(_),this._placeholder(!1)},_inputFocusout:function(){var e,n,i=this,o=i.value();return i._inputWrapper.removeClass(_),clearTimeout(i._typingTimeout),i._typingTimeout=null,i.text(i.text()),e=i._focus(),n=this.listView.dataItemByIndex(this.listView.getElementIndex(e)),o!==i.value()&&i.trigger("select",{dataItem:n,item:e})?(i.value(o),t):(i._placeholder(),i._blur(),i.element.blur(),t)},_inputPaste:function(){var e=this;clearTimeout(e._pasteTimeout),e._pasteTimeout=null,e._pasteTimeout=setTimeout(function(){e.search()})},_editable:function(e){var t=this,n=e.disable,i=e.readonly,o=t._inputWrapper.off(u),r=t.element.add(t.input.off(u)),s=t._arrow.off(h+" "+f),a=t._clear;i||n?(o.addClass(n?b:v).removeClass(n?v:b),r.attr(p,n).attr(m,i).attr(w,n)):(o.addClass(v).removeClass(b).on(C,t._toggleHover),r.removeAttr(p).removeAttr(m).attr(w,!1),s.on(h,S(t._arrowClick,t)).on(f,function(e){e.preventDefault()}),a.on(h,S(t._clearValue,t)).on(f,function(e){e.preventDefault()}),t.input.on("keydown"+u,S(t._keydown,t)).on("focus"+u,S(t._inputFocus,t)).on("focusout"+u,S(t._inputFocusout,t)).on("paste"+u,S(t._inputPaste,t)))},open:function(){var e=this,t=e._state;e.popup.visible()||(!e.listView.bound()&&t!==y||t===k?(e._open=!0,e._state=x,1!==e.options.minLength?(e.refresh(),e._openPopup()):e._filterSource()):e._allowOpening()&&(e._openPopup(),e._focusItem()))},_scrollToFocusedItem:function(){var e=this.listView;e.scrollToIndex(e.getElementIndex(e.focus()))},_openPopup:function(){this.popup.one("activate",S(this._scrollToFocusedItem,this)),this.popup.open()},_updateSelectionState:function(){var e=this,n=e.options.text,i=e.options.value;e.listView.isFiltered()||(e.selectedIndex===-1?(n!==t&&null!==n||(n=i),e._accessor(i),e.input.val(n||e.input.val()),e._placeholder()):e._oldIndex===-1&&(e._oldIndex=e.selectedIndex))},_buildOptions:function(e){var n,i=this;i._isSelect&&(n=i._customOption,i._state===x&&(i._state=""),i._customOption=t,i._options(e,"",i.value()),n&&n[0].selected&&i._custom(n.val()))},_updateSelection:function(){var n,i=this,o=i.listView,r=i._initialIndex,s=null!==r&&r>-1,a=i._state===y;return a?(e(o.focus()).removeClass("k-state-selected"),t):(i._fetch||(o.value().length||(s?i.select(r):i._accessor()&&o.value(i._accessor())),i._initialIndex=null,n=o.selectedDataItems()[0],n&&(i._value(n)!==i.value()&&i._custom(i._value(n)),i.text()&&i.text()!==i._text(n)&&i._selectValue(n))),t)},_updateItemFocus:function(){var e=this.listView;this.options.highlightFirst?e.focus()||e.focusIndex()||e.focus(0):e.focus(-1)},_listBound:function(){var e=this,n=e.input[0]===c(),i=e.dataSource.flatView(),o=e.listView.skip(),r=i.length,s=e.dataSource._group.length,a=o===t||0===o;e._presetValue=!1,e._renderFooter(),e._renderNoData(),e._toggleNoData(!r),e._toggleHeader(!!s&&!!r),e._resizePopup(),e.popup.position(),e._buildOptions(i),e._makeUnselectable(),e._updateSelection(),i.length&&a&&(e._updateItemFocus(),e.options.suggest&&n&&e.input.val()&&e.suggest(i[0])),e._open&&(e._open=!1,e._typingTimeout&&!n?e.popup.close():e.toggle(e._allowOpening()),e._typingTimeout=null),e._hideBusy(),e.trigger("dataBound")},_listChange:function(){this._selectValue(this.listView.selectedDataItems()[0]),this._presetValue&&(this._oldIndex=this.selectedIndex)},_get:function(e){var t,n,i;if("function"==typeof e){for(t=this.dataSource.flatView(),i=0;i<t.length;i++)if(e(t[i])){e=i,n=!0;break}n||(e=-1)}return e},_select:function(e,t){var n=this;return e=n._get(e),e===-1&&(n.input[0].value="",n._accessor("")),n.listView.select(e).done(function(){t||n._state!==y||(n._state=k)})},_selectValue:function(e){var n=this.listView.select(),i="",o="";n=n[n.length-1],n===t&&(n=-1),this.selectedIndex=n,n!==-1||e?((e||0===e)&&(i=this._dataValue(e),o=this._text(e)),null===i&&(i="")):(o=this.input[0].value,this.options.syncValueAndText&&(i=o),this.listView.focus(-1)),this._setDomInputValue(o),this._accessor(i!==t?i:o,n),this._placeholder(),this._triggerCascade()},_setDomInputValue:function(e){var t,n,i=this,o=s(this.input);o&&o.length&&(t=o[0]),this._prev=this.input[0].value=e,t&&this.selectedIndex===-1&&(n=a.mobileOS,n.wp||n.android?setTimeout(function(){i.input[0].setSelectionRange(t,t)},0):this.input[0].setSelectionRange(t,t))},refresh:function(){this.listView.refresh()},_toggleCloseVisibility:function(){this.text()?this._showClear():this._hideClear()},suggest:function(e){var n,i=this,r=i.input[0],a=i.text(),l=s(r)[0],u=i._last;return u==d.BACKSPACE||u==d.DELETE?(i._last=t,t):(e=e||"","string"!=typeof e&&(e[0]&&(e=i.dataSource.view()[o.inArray(e[0],i.ul[0])]),e=e?i._text(e):""),l<=0&&(l=a.toLowerCase().indexOf(e.toLowerCase())+1),e?(e=""+e,n=e.toLowerCase().indexOf(a.toLowerCase()),n>-1&&(a+=e.substring(n+a.length))):a=a.substring(0,l),a.length===l&&e||(r.value=a,r===c()&&s(r,l,a.length)),t)},text:function(e){var n,i,r,s,a,l;return e=null===e?"":e,n=this,i=n.input[0],r=n.options.ignoreCase,s=e,e===t?i.value:n.options.autoBind!==!1||n.listView.bound()?(a=n.dataItem(),a&&n._text(a)===e&&(l=n._value(a),l===o.unifyType(n._old,typeof l))?(n._triggerCascade(),t):(r&&!n.listView.value().length&&(s=s.toLowerCase()),n._select(function(e){return e=n._text(e),r&&!n.listView.value().length&&(e=(e+"").toLowerCase()),e===s}).done(function(){n.selectedIndex<0&&(i.value=e,n.options.syncValueAndText&&n._accessor(e),n._triggerCascade()),n._prev=i.value}),t)):(n._setText(e),t)},toggle:function(e){this._toggle(e,!0)},value:function(e){var n=this,i=n.options,o=n.listView;return e===t?(e=n._accessor()||n.listView.value()[0],e===t||null===e?"":e):(n.requireValueMapper(n.options,e),n.trigger("set",{value:e}),e===i.value&&n.input.val()===i.text||(n._accessor(e),n._isFilterEnabled()&&o.bound()&&o.isFiltered()?n._clearFilter():n._fetchData(),o.value(e).done(function(){n.selectedIndex===-1&&(n._accessor(e),n.input.val(e),n._placeholder(!0)),n._old=n._accessor(),n._oldIndex=n.selectedIndex,n._prev=n.input.val(),n._state===y&&(n._state=k)})),t)},_click:function(e){var n=this,i=e.item,o=n.listView.dataItemByIndex(n.listView.getElementIndex(i));return e.preventDefault(),n.trigger("select",{dataItem:o,item:i})?(n.close(),t):(n._userTriggered=!0,n._select(i).done(function(){n._blur()}),t)},_inputValue:function(){return this.text()},_searchByWord:function(e){var n,i=this,o=i.options,r=i.dataSource,s=o.ignoreCase,a=function(n){var o=i._text(n);if(o!==t)return o+="",(""===o||""!==e)&&(s&&(o=o.toLowerCase()),0===o.indexOf(e))};return s&&(e=e.toLowerCase()),i.ul[0].firstChild?(this.listView.focus(this._get(a)),n=this.listView.focus(),n&&(o.suggest&&i.suggest(n),this.open()),this.options.highlightFirst&&!e&&this.listView.focusFirst(),t):(r.one(g,function(){r.view()[0]&&i.search(e)}).fetch(),t)},_input:function(){var t,n,i=this,o=i.element.removeClass("k-input")[0],r=o.accessKey,s=i.wrapper,a="input.k-input",c=o.name||"";c&&(c='name="'+c+'_input" '),t=s.find(a),t[0]||(s.append('<span tabindex="-1" unselectable="on" class="k-dropdown-wrap k-state-default"><input '+c+'class="k-input" type="text" autocomplete="off"/><span unselectable="on" class="k-select" aria-label="select"><span class="k-icon k-i-arrow-60-down"></span></span></span>').append(i.element),t=s.find(a)),t[0].style.cssText=o.style.cssText,t[0].title=o.title,n=parseInt(this.element.prop("maxlength")||this.element.attr("maxlength"),10),n>-1&&(t[0].maxLength=n),t.addClass(o.className).css({width:"100%",height:o.style.height}).attr({role:"combobox","aria-expanded":!1}).show(),l&&t.attr("placeholder",i.options.placeholder),r&&(o.accessKey="",t[0].accessKey=r),i._focused=i.input=t,i._inputWrapper=e(s[0].firstChild),i._arrow=s.find(".k-select").attr({role:"button",tabIndex:-1}),i._arrowIcon=i._arrow.find(".k-icon"),o.id&&i._arrow.attr("aria-controls",i.ul[0].id)},_clearButton:function(){this._clear=e('<span unselectable="on" class="k-icon k-clear-value k-i-close" title="clear"></span>').attr({role:"button",tabIndex:-1}),this.options.clearButton&&(this._clear.insertAfter(this.input),this.wrapper.addClass("k-combobox-clearable"))},_keydown:function(e){var t=this,n=e.keyCode;t._last=n,clearTimeout(t._typingTimeout),t._typingTimeout=null,n==d.TAB||t._move(e)||t._search()},_placeholder:function(e){if(!l){var n,i=this,o=i.input,r=i.options.placeholder;if(r){if(n=i.value(),e===t&&(e=!n),o.toggleClass("k-readonly",e),!e){if(n)return;r=""}o.val(r),r||o[0]!==c()||s(o[0],0,0)}}},_search:function(){var e=this;e._typingTimeout=setTimeout(function(){var t=e.text();e._prev!==t&&(e._prev=t,"none"===e.options.filter&&e.listView.select(-1),e.search(t),e._toggleCloseVisibility()),e._typingTimeout=null},e.options.delay)},_setText:function(e){this.input.val(e),this._prev=e},_wrapper:function(){var e=this,t=e.element,n=t.parent();n.is("span.k-widget")||(n=t.hide().wrap("<span />").parent(),n[0].style.cssText=t[0].style.cssText),e.wrapper=n.addClass("k-widget k-combobox k-header").addClass(t[0].className).css("display","")},_clearSelection:function(e,t){var n=this,i=e.value(),o=i&&e.selectedIndex===-1;this.selectedIndex==-1&&this.value()||(t||!i||o)&&(n.options.value="",n.value(""))},_preselect:function(e,t){this.input.val(t),this._accessor(e),this._old=this._accessor(),this._oldIndex=this.selectedIndex,this.listView.setValue(e),this._placeholder(),this._initialIndex=null,this._presetValue=!0}});i.plugin(T)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.multiselect.min",["kendo.list.min","kendo.mobile.scroller.min"],e)}(function(){return function(e,t){function n(e,t){var n;if(null===e&&null!==t||null!==e&&null===t)return!1;if(n=e.length,n!==t.length)return!1;for(;n--;)if(e[n]!==t[n])return!1;return!0}var i=window.kendo,o=i.ui,r=o.List,s=i.keys,a=i._activeElement,l=i.data.ObservableArray,c=e.proxy,d="id",u="li",h="accept",f="filter",p="rebind",m="open",g="close",v="change",_="progress",b="select",w="deselect",y="aria-disabled",k="k-state-focused",x="k-hidden",C="k-state-hover",S="k-state-disabled",T="disabled",D="readonly",A=".kendoMultiSelect",E="click"+A,M="keydown"+A,I="mouseenter"+A,R="mouseleave"+A,F=I+" "+R,z=/"/g,P=e.isArray,B=["font-family","font-size","font-stretch","font-style","font-weight","letter-spacing","text-transform","line-height"],L=r.extend({init:function(t,n){var o,s,a=this;a.ns=A,r.fn.init.call(a,t,n),a._optionsMap={},a._customOptions={},a._wrapper(),a._tagList(),a._input(),a._textContainer(),a._loader(),a._clearButton(),a._tabindex(a.input),t=a.element.attr("multiple","multiple").hide(),n=a.options,n.placeholder||(n.placeholder=t.data("placeholder")),o=t.attr(d),o&&(a._tagID=o+"_tag_active",o+="_taglist",a.tagList.attr(d,o)),a._aria(o),a._dataSource(),a._ignoreCase(),a._popup(),a._tagTemplate(),a.requireValueMapper(a.options),a._initList(),a._reset(),a._enable(),a._placeholder(),n.autoBind?a.dataSource.fetch():n.value&&a._preselect(n.value),s=e(a.element).parents("fieldset").is(":disabled"),s&&a.enable(!1),i.notify(a),a._toggleCloseVisibility()},options:{name:"MultiSelect",tagMode:"multiple",enabled:!0,autoBind:!0,autoClose:!0,highlightFirst:!0,dataTextField:"",dataValueField:"",filter:"startswith",ignoreCase:!0,minLength:1,enforceMinLength:!1,delay:100,value:null,maxSelectedItems:null,placeholder:"",height:200,animation:{},virtual:!1,itemTemplate:"",tagTemplate:"",groupTemplate:"#:data#",fixedGroupTemplate:"#:data#",clearButton:!0},events:[m,g,v,b,w,"filtering","dataBinding","dataBound"],setDataSource:function(e){this.options.dataSource=e,this._state="",this._dataSource(),this.listView.setDataSource(this.dataSource),this.options.autoBind&&this.dataSource.fetch()},setOptions:function(e){var t=this._listOptions(e);r.fn.setOptions.call(this,e),this.listView.setOptions(t),this._accessors(),this._aria(this.tagList.attr(d)),this._tagTemplate()},currentTag:function(e){var n=this;return e===t?n._currentTag:(n._currentTag&&(n._currentTag.removeClass(k).removeAttr(d),n.input.removeAttr("aria-activedescendant")),e&&(e.addClass(k).attr(d,n._tagID),n.input.attr("aria-activedescendant",n._tagID)),n._currentTag=e,t)},dataItems:function(){return this.listView.selectedDataItems()},destroy:function(){var e=this,t=e.ns;clearTimeout(e._busy),clearTimeout(e._typingTimeout),e.wrapper.off(t),e.tagList.off(t),e.input.off(t),e._clear.off(t),r.fn.destroy.call(e)},_activateItem:function(){r.fn._activateItem.call(this),this.currentTag(null)},_listOptions:function(t){var n=this,o=r.fn._listOptions.call(n,e.extend(t,{selectedItemChange:c(n._selectedItemChange,n),selectable:"multiple"})),s=this.options.itemTemplate||this.options.template,a=o.itemTemplate||s||o.template;return a||(a="#:"+i.expr(o.dataTextField,"data")+"#"),o.template=a,o},_setListValue:function(){r.fn._setListValue.call(this,this._initialValues.slice(0))},_listChange:function(e){var n,i=this.dataSource.flatView(),o=this._optionsMap,r=this._value;for(this._state===p&&(this._state=""),n=0;n<e.added.length;n++)if(o[r(e.added[n].dataItem)]===t){this._render(i);break}this._selectValue(e.added,e.removed)},_selectedItemChange:function(e){var t,n,i=e.items;for(n=0;n<i.length;n++)t=i[n],this.tagList.children().eq(t.index).children("span:first").html(this.tagTextTemplate(t.item))},_wrapperMousedown:function(t){var n=this,o="input"!==t.target.nodeName.toLowerCase(),r=e(t.target),s=r.hasClass("k-select")||r.hasClass("k-icon");s&&(s=!r.closest(".k-select").children(".k-i-arrow-60-down").length),!o||s&&i.support.mobileOS||t.preventDefault(),s||(n.input[0]!==a()&&o&&n.input.focus(),1===n.options.minLength&&n.open())},_inputFocus:function(){this._placeholder(!1),this.wrapper.addClass(k)},_inputFocusout:function(){var e=this;clearTimeout(e._typingTimeout),e.wrapper.removeClass(k),e._placeholder(!e.listView.selectedDataItems()[0],!0),e.close(),e._state===f&&(e._state=h,e.listView.skipUpdate(!0)),e.element.blur()},_removeTag:function(e){var n,i,o=this,r=o._state,s=e.index(),a=o.listView,l=a.value()[s],c=o.listView.selectedDataItems()[s],d=o._customOptions[l];return o.trigger(w,{dataItem:c,item:e})?(o._close(),t):(d!==t||r!==h&&r!==f||(d=o._optionsMap[l]),i=function(){o.currentTag(null),o._change(),o._close()},d===t?a.select(a.select()[s]).done(i):(n=o.element[0].children[d],n.selected=!1,a.removeAt(s),e.remove(),i()),t)},_tagListClick:function(t){var n=e(t.currentTarget);n.children(".k-i-arrow-60-down").length||this._removeTag(n.closest(u))},_clearClick:function(){var t=this;t.tagList.children().each(function(n,i){t._removeTag(e(i))}),t.input.val(""),t._search(),t.trigger("change"),t.focus()},_editable:function(t){var n=this,i=t.disable,o=t.readonly,r=n.wrapper.off(A),s=n.tagList.off(A),a=n.element.add(n.input.off(A));o||i?(i?r.addClass(S):r.removeClass(S),a.attr(T,i).attr(D,o).attr(y,i)):(r.removeClass(S).on(F,n._toggleHover).on("mousedown"+A+" touchend"+A,c(n._wrapperMousedown,n)),n.input.on(M,c(n._keydown,n)).on("paste"+A,c(n._search,n)).on("focus"+A,c(n._inputFocus,n)).on("focusout"+A,c(n._inputFocusout,n)),n._clear.on("click"+A,c(n._clearClick,n)),a.removeAttr(T).removeAttr(D).attr(y,!1),s.on(I,u,function(){e(this).addClass(C)}).on(R,u,function(){e(this).removeClass(C)}).on(E,"li.k-button .k-select",c(n._tagListClick,n)))},_close:function(){var e=this;e.options.autoClose?e.close():e.popup.position()},_filterSource:function(e,t){t||(t=this._retrieveData),this._retrieveData=!1,r.fn._filterSource.call(this,e,t)},close:function(){this.popup.close()},open:function(){var e=this;e._request&&(e._retrieveData=!1),e._retrieveData||!e.listView.bound()||e._state===h?(e._open=!0,e._state=p,e.listView.skipUpdate(!0),e._filterSource()):e._allowOpening()&&(e.popup.open(),e._focusItem())},toggle:function(e){e=e!==t?e:!this.popup.visible(),this[e?m:g]()},refresh:function(){this.listView.refresh()},_listBound:function(){var e=this,n=e.dataSource.flatView(),i=e.listView.skip();e._render(n),e._renderFooter(),e._renderNoData(),e._toggleNoData(!n.length),e._resizePopup(),e._open&&(e._open=!1,e.toggle(e._allowOpening())),e.popup.position(),!e.options.highlightFirst||i!==t&&0!==i||e.listView.focusFirst(),e._touchScroller&&e._touchScroller.reset(),e._hideBusy(),e._makeUnselectable(),e.trigger("dataBound")},_inputValue:function(){var e=this,t=e.input.val();return e.options.placeholder===t&&(t=""),t},value:function(e){var n=this,i=n.listView,o=i.value().slice(),r=n.options.maxSelectedItems,s=i.bound()&&i.isFiltered();return e===t?o:(n.requireValueMapper(n.options,e),e=n._normalizeValues(e),null!==r&&e.length>r&&(e=e.slice(0,r)),s&&n._clearFilter(),i.value(e),n._old=i.value(),s||n._fetchData(),t)},_preselect:function(t,n){var o=this;P(t)||t instanceof i.data.ObservableArray||(t=[t]),(e.isPlainObject(t[0])||t[0]instanceof i.data.ObservableObject||!o.options.dataValueField)&&(o.dataSource.data(t),o.value(n||o._initialValues),o._retrieveData=!0)},_setOption:function(e,t){var n=this.element[0].children[this._optionsMap[e]];n&&(n.selected=t)},_fetchData:function(){var e=this,t=!!e.dataSource.view().length,n=0===e.listView.value().length;n||e._request||(e._retrieveData||!e._fetch&&!t)&&(e._fetch=!0,e._retrieveData=!1,e.dataSource.read().done(function(){e._fetch=!1}))},_isBound:function(){return this.listView.bound()&&!this._retrieveData},_dataSource:function(){var e=this,t=e.element,n=e.options,o=n.dataSource||{};o=P(o)?{data:o}:o,o.select=t,o.fields=[{field:n.dataTextField},{field:n.dataValueField}],e.dataSource&&e._refreshHandler?e._unbindDataSource():(e._progressHandler=c(e._showBusy,e),e._errorHandler=c(e._hideBusy,e)),e.dataSource=i.data.DataSource.create(o).bind(_,e._progressHandler).bind("error",e._errorHandler)},_reset:function(){var t=this,n=t.element,i=n.attr("form"),o=i?e("#"+i):n.closest("form");o[0]&&(t._resetHandler=function(){setTimeout(function(){t.value(t._initialValues),t._placeholder()})},t._form=o.on("reset",t._resetHandler))},_initValue:function(){var e=this.options.value||this.element.val();this._old=this._initialValues=this._normalizeValues(e)},_normalizeValues:function(t){var n=this;return null===t?t=[]:t&&e.isPlainObject(t)?t=[n._value(t)]:t&&e.isPlainObject(t[0])?t=e.map(t,function(e){return n._value(e)}):P(t)||t instanceof l?P(t)&&(t=t.slice()):t=[t],t},_change:function(){var e=this,t=e.value();n(t,e._old)||(e._old=t.slice(),e.trigger(v),e.element.trigger(v)),e._toggleCloseVisibility()},_click:function(e){var t=this,n=e.item;e.preventDefault(),t._select(n).done(function(){t._change(),t._close()})},_keydown:function(n){var o,r=this,a=n.keyCode,l=r._currentTag,c=r.listView,d=c.focus(),u=r.input.val(),h=i.support.isRtl(r.wrapper),f=r.popup.visible();if(a===s.DOWN){if(n.preventDefault(),!f)return r.open(),d||c.focusFirst(),t;d?(c.focusNext(),c.focus()||c.focusLast()):c.focusFirst()}else if(a===s.UP)f&&(d&&c.focusPrev(),c.focus()||r.close()),n.preventDefault();else if(a===s.LEFT&&!h||a===s.RIGHT&&h)u||(l=l?l.prev():e(r.tagList[0].lastChild),l[0]&&r.currentTag(l));else if(a===s.RIGHT&&!h||a===s.LEFT&&h)!u&&l&&(l=l.next(),r.currentTag(l[0]?l:null));else if(a===s.ENTER&&f)r._select(d).done(function(){r._change(),r._close()}),n.preventDefault();else if(a===s.ESC)f?n.preventDefault():r.currentTag(null),r.close();else if(a===s.HOME)f?c.focusFirst():u||(l=r.tagList[0].firstChild,l&&r.currentTag(e(l)));else if(a===s.END)f?c.focusLast():u||(l=r.tagList[0].lastChild,l&&r.currentTag(e(l)));else if(a!==s.DELETE&&a!==s.BACKSPACE||u)!r.popup.visible()||a!==s.PAGEDOWN&&a!==s.PAGEUP?(clearTimeout(r._typingTimeout),setTimeout(function(){r._scale()}),r._search()):(n.preventDefault(),o=a===s.PAGEDOWN?1:-1,c.scrollWith(o*c.screenHeight()));else{if("single"===r.options.tagMode)return c.value([]),r._change(),r._close(),t;a!==s.BACKSPACE||l||(l=e(r.tagList[0].lastChild)),l&&l[0]&&r._removeTag(l)}},_hideBusy:function(){var e=this;clearTimeout(e._busy),e.input.attr("aria-busy",!1),e._loading.addClass(x),e._request=!1,e._busy=null,e._showClear()},_showBusyHandler:function(){this.input.attr("aria-busy",!0),this._loading.removeClass(x),this._hideClear()},_showBusy:function(){var e=this;e._request=!0,e._busy||(e._busy=setTimeout(c(e._showBusyHandler,e),100))},_placeholder:function(e,n){var o=this,r=o.input,s=a(),l=o.options.placeholder,c=r.val(),d=r[0]===s,u=c.length;d&&!o.options.autoClose&&c!==l||(u=0,c=""),e===t&&(e=!1,r[0]!==s&&(e=!o.listView.selectedDataItems()[0])),o._prev=c,r.toggleClass("k-readonly",e).val(e?l:c),d&&!n&&i.caret(r[0],u,u),o._scale()},_scale:function(){var e,t=this,n=t.wrapper,i=n.width(),o=t._span.text(t.input.val());n.is(":visible")?e=o.width()+25:(o.appendTo(document.documentElement),i=e=o.width()+25,o.appendTo(n)),t.input.width(e>i?i:e)},_option:function(e,n,o){var r="<option";return e!==t&&(e+="",e.indexOf('"')!==-1&&(e=e.replace(z,"&quot;")),r+=' value="'+e+'"'),o&&(r+=" selected"),r+=">",n!==t&&(r+=i.htmlEncode(n)),r+="</option>"},_render:function(e){var t,n,i,o,r,s,a=this.listView.selectedDataItems(),l=this.listView.value(),c=e.length,d="";for(l.length!==a.length&&(a=this._buildSelectedItems(l)),r={},s={},o=0;o<c;o++)n=e[o],i=this._value(n),t=this._selectedItemIndex(i,a),t!==-1&&a.splice(t,1),s[i]=o,d+=this._option(i,this._text(n),t!==-1);if(a.length)for(o=0;o<a.length;o++)n=a[o],i=this._value(n),r[i]=c,s[i]=c,c+=1,d+=this._option(i,this._text(n),!0);this._customOptions=r,this._optionsMap=s,this.element.html(d)},_buildSelectedItems:function(e){var t,n,i=this.options.dataValueField,o=this.options.dataTextField,r=[];for(n=0;n<e.length;n++)t={},t[i]=e[n],t[o]=e[n],r.push(t);return r},_selectedItemIndex:function(e,t){for(var n=this._value,i=0;i<t.length;i++)if(e===n(t[i]))return i;return-1},_search:function(){var e=this;e._typingTimeout=setTimeout(function(){var t=e._inputValue();e._prev!==t&&(e._prev=t,e.search(t),e._toggleCloseVisibility())},e.options.delay)},_toggleCloseVisibility:function(){this.value().length||this.input.val()&&this.input.val()!==this.options.placeholder?this._showClear():this._hideClear()},_allowOpening:function(){return this._allowSelection()&&r.fn._allowOpening.call(this)},_allowSelection:function(){var e=this.options.maxSelectedItems;return null===e||e>this.listView.value().length},_angularTagItems:function(t){var n=this;n.angular(t,function(){return{elements:n.tagList[0].children,data:e.map(n.dataItems(),function(e){return{dataItem:e}})}})},_selectValue:function(e,t){var n,i,o,r=this,s=r.value(),a=r.dataSource.total(),l=r.tagList,c=r._value;if(r._angularTagItems("cleanup"),"multiple"===r.options.tagMode){for(o=t.length-1;o>-1;o--)n=t[o],l[0].removeChild(l[0].children[n.position]),r._setOption(c(n.dataItem),!1);for(o=0;o<e.length;o++)i=e[o],l.append(r.tagTemplate(i.dataItem)),r._setOption(c(i.dataItem),!0)}else{for((!r._maxTotal||r._maxTotal<a)&&(r._maxTotal=a),l.html(""),s.length&&l.append(r.tagTemplate({values:s,dataItems:r.dataItems(),maxTotal:r._maxTotal,currentTotal:a})),o=t.length-1;o>-1;o--)r._setOption(c(t[o].dataItem),!1);for(o=0;o<e.length;o++)r._setOption(c(e[o].dataItem),!0)}r._angularTagItems("compile"),r._placeholder()},_select:function(t){var n,i,o,r,s=e.Deferred().resolve();return t?(n=this,i=n.listView,o=i.dataItemByIndex(i.getElementIndex(t)),r=t.hasClass("k-state-selected"),n._state===p&&(n._state=""),n._allowSelection()?n.trigger(r?w:b,{dataItem:o,item:t})?(n._close(),s):i.select(t).done(function(){n._placeholder(),n._state===f&&(n._state=h,i.skipUpdate(!0))}):s):s},_input:function(){var t=this,n=t.element,i=n[0].accessKey,o=t._innerWrapper.children("input.k-input");o[0]||(o=e('<input class="k-input" style="width: 25px" />').appendTo(t._innerWrapper)),n.removeAttr("accesskey"),t._focused=t.input=o.attr({accesskey:i,autocomplete:"off",role:"listbox",title:n[0].title,"aria-expanded":!1})},_tagList:function(){var t=this,n=t._innerWrapper.children("ul");n[0]||(n=e('<ul role="listbox" deselectable="on" class="k-reset"/>').appendTo(t._innerWrapper)),t.tagList=n},_tagTemplate:function(){var e,t=this,n=t.options,o=n.tagTemplate,r=n.dataSource,s="multiple"===n.tagMode;t.element[0].length&&!r&&(n.dataTextField=n.dataTextField||"text",
n.dataValueField=n.dataValueField||"value"),e=s?i.template("#:"+i.expr(n.dataTextField,"data")+"#",{useWithBlock:!1}):i.template("#:values.length# item(s) selected"),t.tagTextTemplate=o=o?i.template(o):e,t.tagTemplate=function(e){return'<li class="k-button" deselectable="on"><span deselectable="on">'+o(e)+'</span><span unselectable="on" aria-label="'+(s?"delete":"open")+'" class="k-select"><span class="k-icon '+(s?"k-i-close":"k-i-arrow-60-down")+'"></span></span></li>'}},_loader:function(){this._loading=e('<span class="k-icon k-i-loading '+x+'"></span>').insertAfter(this.input)},_clearButton:function(){this._clear=e('<span deselectable="on" class="k-icon k-clear-value k-i-close" title="clear"></span>').attr({role:"button",tabIndex:-1}),this.options.clearButton&&this._clear.insertAfter(this.input)},_textContainer:function(){var t=i.getComputedStyles(this.input[0],B);t.position="absolute",t.visibility="hidden",t.top=-3333,t.left=-3333,this._span=e("<span/>").css(t).appendTo(this.wrapper)},_wrapper:function(){var t=this,n=t.element,i=n.parent("span.k-multiselect");i[0]||(i=n.wrap('<div class="k-widget k-multiselect k-header" deselectable="on" />').parent(),i[0].style.cssText=n[0].style.cssText,i[0].title=n[0].title,e('<div class="k-multiselect-wrap k-floatwrap" deselectable="on" />').insertBefore(n)),t.wrapper=i.addClass(n[0].className).css("display",""),t._innerWrapper=e(i[0].firstChild)}});o.plugin(L)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.slider.min",["kendo.draganddrop.min"],e)}(function(){return function(e,t){function n(e,t,n){var i=n?" k-slider-horizontal":" k-slider-vertical",o=e.style?e.style:t.attr("style"),r=t.attr("class")?" "+t.attr("class"):"",s="";return"bottomRight"==e.tickPlacement?s=" k-slider-bottomright":"topLeft"==e.tickPlacement&&(s=" k-slider-topleft"),o=o?" style='"+o+"'":"","<div class='k-widget k-slider"+i+r+"'"+o+"><div class='k-slider-wrap"+(e.showButtons?" k-slider-buttons":"")+s+"'></div></div>"}function i(e,t,n,i){var o="";return o=n?!i&&"increase"==t||i&&"increase"!=t?"k-i-arrow-60-right":"k-i-arrow-60-left":"increase"==t?"k-i-arrow-60-up":"k-i-arrow-60-down","<a class='k-button k-button-"+t+"' title='"+e[t+"ButtonTitle"]+"' aria-label='"+e[t+"ButtonTitle"]+"'><span class='k-icon "+o+"'></span></a>"}function o(e,t){var n,i="<ul class='k-reset k-slider-items'>",o=S.floor(d(t/e.smallStep))+1;for(n=0;n<o;n++)i+="<li class='k-tick' role='presentation'>&nbsp;</li>";return i+="</ul>"}function r(e,t){var n=t.is("input")?1:2,i=2==n?e.leftDragHandleTitle:e.dragHandleTitle;return"<div class='k-slider-track'><div class='k-slider-selection'><!-- --></div><a href='#' class='k-draghandle' title='"+i+"' role='slider' aria-valuemin='"+e.min+"' aria-valuemax='"+e.max+"' aria-valuenow='"+(n>1?e.selectionStart||e.min:e.value||e.min)+"'>Drag</a>"+(n>1?"<a href='#' class='k-draghandle' title='"+e.rightDragHandleTitle+"'role='slider' aria-valuemin='"+e.min+"' aria-valuemax='"+e.max+"' aria-valuenow='"+(e.selectionEnd||e.max)+"'>Drag</a>":"")+"</div>"}function s(e){return function(t){return t+e}}function a(e){return function(){return e}}function l(e){return(e+"").replace(".",m.cultures.current.numberFormat["."])}function c(e){var t=""+e,n=0;return t=t.split("."),t[1]&&(n=t[1].length),n=n>10?10:n}function d(e){var t,n;return e=parseFloat(e,10),t=c(e),n=S.pow(10,t||0),S.round(e*n)/n}function u(e,n){var i=k(e.getAttribute(n));return null===i&&(i=t),i}function h(e){return typeof e!==Q}function f(e){return 1e4*e}var p,m=window.kendo,g=m.ui.Widget,v=m.ui.Draggable,_=m._outerWidth,b=m._outerHeight,w=e.extend,y=m.format,k=m.parseFloat,x=e.proxy,C=e.isArray,S=Math,T=m.support,D=T.pointers,A=T.msPointers,E="change",M="slide",I=".slider",R="touchstart"+I+" mousedown"+I,F=D?"pointerdown"+I:A?"MSPointerDown"+I:R,z="touchend"+I+" mouseup"+I,P=D?"pointerup":A?"MSPointerUp"+I:z,B="moveSelection",L="keydown"+I,H="click"+I,N="mouseover"+I,O="focus"+I,V="blur"+I,U=".k-draghandle",W=".k-slider-track",q=".k-tick",j="k-state-selected",G="k-state-focused",$="k-state-default",Y="k-state-disabled",K="disabled",Q="undefined",X="tabindex",Z=m.getTouches,J=g.extend({init:function(e,t){var n,i=this;if(g.fn.init.call(i,e,t),t=i.options,i._isHorizontal="horizontal"==t.orientation,i._isRtl=i._isHorizontal&&m.support.isRtl(e),i._position=i._isHorizontal?"left":"bottom",i._sizeFn=i._isHorizontal?"width":"height",i._outerSize=i._isHorizontal?_:b,t.tooltip.format=t.tooltip.enabled?t.tooltip.format||"{0}":"{0}",t.smallStep<=0)throw Error("Kendo UI Slider smallStep must be a positive number.");i._createHtml(),i.wrapper=i.element.closest(".k-slider"),i._trackDiv=i.wrapper.find(W),i._setTrackDivWidth(),i._maxSelection=i._trackDiv[i._sizeFn](),i._sliderItemsInit(),i._reset(),i._tabindex(i.wrapper.find(U)),i[t.enabled?"enable":"disable"](),n=m.support.isRtl(i.wrapper)?-1:1,i._keyMap={37:s(-1*n*t.smallStep),40:s(-t.smallStep),39:s(1*n*t.smallStep),38:s(+t.smallStep),35:a(t.max),36:a(t.min),33:s(+t.largeStep),34:s(-t.largeStep)},m.notify(i)},events:[E,M],options:{enabled:!0,min:0,max:10,smallStep:1,largeStep:5,orientation:"horizontal",tickPlacement:"both",tooltip:{enabled:!0,format:"{0}"}},_distance:function(){return d(this.options.max-this.options.min)},_resize:function(){this._setTrackDivWidth(),this.wrapper.find(".k-slider-items").remove(),this._maxSelection=this._trackDiv[this._sizeFn](),this._sliderItemsInit(),this._refresh(),this.options.enabled&&this.enable(!0)},_sliderItemsInit:function(){var t=this,n=t.options,i=t._maxSelection/((n.max-n.min)/n.smallStep),r=t._calculateItemsWidth(S.floor(t._distance()/n.smallStep));"none"!=n.tickPlacement&&i>=2&&(e(this.element).parent().find(".k-slider-items").remove(),t._trackDiv.before(o(n,t._distance())),t._setItemsWidth(r),t._setItemsTitle()),t._calculateSteps(r),"none"!=n.tickPlacement&&i>=2&&n.largeStep>=n.smallStep&&t._setItemsLargeTick()},getSize:function(){return m.dimensions(this.wrapper)},_setTrackDivWidth:function(){var e=this,t=2*parseFloat(e._trackDiv.css(e._isRtl?"right":e._position),10);e._trackDiv[e._sizeFn](e.wrapper[e._sizeFn]()-2-t)},_setItemsWidth:function(t){var n,i=this,o=i.options,r=0,s=t.length-1,a=i.wrapper.find(q),l=0,c=2,d=a.length,u=0;for(n=0;n<d-2;n++)e(a[n+1])[i._sizeFn](t[n]);if(i._isHorizontal?(e(a[r]).addClass("k-first")[i._sizeFn](t[s-1]),e(a[s]).addClass("k-last")[i._sizeFn](t[s])):(e(a[s]).addClass("k-first")[i._sizeFn](t[s]),e(a[r]).addClass("k-last")[i._sizeFn](t[s-1])),i._distance()%o.smallStep!==0&&!i._isHorizontal){for(n=0;n<t.length;n++)u+=t[n];l=i._maxSelection-u,l+=parseFloat(i._trackDiv.css(i._position),10)+c,i.wrapper.find(".k-slider-items").css("padding-top",l)}},_setItemsTitle:function(){for(var t=this,n=t.options,i=t.wrapper.find(q),o=n.min,r=i.length,s=t._isHorizontal&&!t._isRtl?0:r-1,a=t._isHorizontal&&!t._isRtl?r:-1,l=t._isHorizontal&&!t._isRtl?1:-1;s-a!==0;s+=l)e(i[s]).attr("title",y(n.tooltip.format,d(o))),o+=n.smallStep},_setItemsLargeTick:function(){var t,n,i,o=this,r=o.options,s=o.wrapper.find(q),a=0;if(f(r.largeStep)%f(r.smallStep)===0||o._distance()/r.largeStep>=3)for(o._isHorizontal||o._isRtl||(s=e.makeArray(s).reverse()),a=0;a<s.length;a++)t=e(s[a]),n=o._values[a],i=d(f(n-this.options.min)),i%f(r.smallStep)===0&&i%f(r.largeStep)===0&&(t.addClass("k-tick-large").html("<span class='k-label'>"+t.attr("title")+"</span>"),0!==a&&a!==s.length-1&&t.css("line-height",t[o._sizeFn]()+"px"))},_calculateItemsWidth:function(e){var t,n,i,o=this,r=o.options,s=parseFloat(o._trackDiv.css(o._sizeFn))+1,a=o._distance(),l=s/a;for(a/r.smallStep-S.floor(a/r.smallStep)>0&&(s-=a%r.smallStep*l),t=s/e,n=[],i=0;i<e-1;i++)n[i]=t;return n[e-1]=n[e]=t/2,o._roundWidths(n)},_roundWidths:function(e){var t,n=0,i=e.length;for(t=0;t<i;t++)n+=e[t]-S.floor(e[t]),e[t]=S.floor(e[t]);return n=S.round(n),this._addAdditionalSize(n,e)},_addAdditionalSize:function(e,t){if(0===e)return t;var n,i=parseFloat(t.length-1)/parseFloat(1==e?e:e-1);for(n=0;n<e;n++)t[parseInt(S.round(i*n),10)]+=1;return t},_calculateSteps:function(e){var t,n=this,i=n.options,o=i.min,r=0,s=n._distance(),a=S.ceil(s/i.smallStep),l=1;if(a+=s/i.smallStep%1===0?1:0,e.splice(0,0,2*e[a-2]),e.splice(a-1,1,2*e.pop()),n._pixelSteps=[r],n._values=[o],0!==a){for(;l<a;)r+=(e[l-1]+e[l])/2,n._pixelSteps[l]=r,o+=i.smallStep,n._values[l]=d(o),l++;t=s%i.smallStep===0?a-1:a,n._pixelSteps[t]=n._maxSelection,n._values[t]=i.max,n._isRtl&&(n._pixelSteps.reverse(),n._values.reverse())}},_getValueFromPosition:function(e,t){var n,i=this,o=i.options,r=S.max(o.smallStep*(i._maxSelection/i._distance()),0),s=0,a=r/2;if(i._isHorizontal?(s=e-t.startPoint,i._isRtl&&(s=i._maxSelection-s)):s=t.startPoint-e,i._maxSelection-(parseInt(i._maxSelection%r,10)-3)/2<s)return o.max;for(n=0;n<i._pixelSteps.length;n++)if(S.abs(i._pixelSteps[n]-s)-1<=a)return d(i._values[n])},_getFormattedValue:function(e,t){var n,i,o,r=this,s="",a=r.options.tooltip;return C(e)?(i=e[0],o=e[1]):t&&t.type&&(i=t.selectionStart,o=t.selectionEnd),t&&(n=t.tooltipTemplate),!n&&a.template&&(n=m.template(a.template)),C(e)||t&&t.type?n?s=n({selectionStart:i,selectionEnd:o}):(i=y(a.format,i),o=y(a.format,o),s=i+" - "+o):(t&&(t.val=e),s=n?n({value:e}):y(a.format,e)),s},_getDraggableArea:function(){var e=this,t=m.getOffset(e._trackDiv);return{startPoint:e._isHorizontal?t.left:t.top+e._maxSelection,endPoint:e._isHorizontal?t.left+e._maxSelection:t.top}},_createHtml:function(){var e=this,t=e.element,o=e.options,s=t.find("input");2==s.length?(s.eq(0).prop("value",l(o.selectionStart)),s.eq(1).prop("value",l(o.selectionEnd))):t.prop("value",l(o.value)),t.wrap(n(o,t,e._isHorizontal)).hide(),o.showButtons&&t.before(i(o,"increase",e._isHorizontal,e._isRtl)).before(i(o,"decrease",e._isHorizontal,e._isRtl)),t.before(r(o,t))},_focus:function(t){var n=this,i=t.target,o=n.value(),r=n._drag;r||(i==n.wrapper.find(U).eq(0)[0]?(r=n._firstHandleDrag,n._activeHandle=0):(r=n._lastHandleDrag,n._activeHandle=1),o=o[n._activeHandle]),e(i).addClass(G+" "+j),r&&(n._activeHandleDrag=r,r.selectionStart=n.options.selectionStart,r.selectionEnd=n.options.selectionEnd,r._updateTooltip(o))},_focusWithMouse:function(t){t=e(t);var n=this,i=t.is(U)?t.index():0;window.setTimeout(function(){n.wrapper.find(U)[2==i?1:0].focus()},1),n._setTooltipTimeout()},_blur:function(t){var n=this,i=n._activeHandleDrag;e(t.target).removeClass(G+" "+j),i&&(i._removeTooltip(),delete n._activeHandleDrag,delete n._activeHandle)},_setTooltipTimeout:function(){var e=this;e._tooltipTimeout=window.setTimeout(function(){var t=e._drag||e._activeHandleDrag;t&&t._removeTooltip()},300)},_clearTooltipTimeout:function(){var e,t=this;window.clearTimeout(this._tooltipTimeout),e=t._drag||t._activeHandleDrag,e&&e.tooltipDiv&&e.tooltipDiv.stop(!0,!1).css("opacity",1)},_reset:function(){var t=this,n=t.element,i=n.attr("form"),o=i?e("#"+i):n.closest("form");o[0]&&(t._form=o.on("reset",x(t._formResetHandler,t)))},min:function(e){return e?(this.setOptions({min:e}),t):this.options.min},max:function(e){return e?(this.setOptions({max:e}),t):this.options.max},setOptions:function(e){g.fn.setOptions.call(this,e),this._sliderItemsInit(),this._refresh()},destroy:function(){this._form&&this._form.off("reset",this._formResetHandler),g.fn.destroy.call(this)}}),ee=J.extend({init:function(n,i){var o,r=this;n.type="text",i=w({},{value:u(n,"value"),min:u(n,"min"),max:u(n,"max"),smallStep:u(n,"step")},i),n=e(n),i&&i.enabled===t&&(i.enabled=!n.is("[disabled]")),J.fn.init.call(r,n,i),i=r.options,h(i.value)&&null!==i.value||(i.value=i.min,n.prop("value",l(i.min))),i.value=S.max(S.min(i.value,i.max),i.min),o=r.wrapper.find(U),this._selection=new ee.Selection(o,r,i),r._drag=new ee.Drag(o,"",r,i)},options:{name:"Slider",showButtons:!0,increaseButtonTitle:"Increase",decreaseButtonTitle:"Decrease",dragHandleTitle:"drag",tooltip:{format:"{0:#,#.##}"},value:null},enable:function(n){var i,o,r,s=this,a=s.options;s.disable(),n!==!1&&(s.wrapper.removeClass(Y).addClass($),s.wrapper.find("input").removeAttr(K),i=function(n){var i,o,r,a=Z(n)[0];if(a){if(i=s._isHorizontal?a.location.pageX:a.location.pageY,o=s._getDraggableArea(),r=e(n.target),r.hasClass("k-draghandle"))return r.addClass(G+" "+j),t;s._update(s._getValueFromPosition(i,o)),s._focusWithMouse(n.target),s._drag.dragstart(n),n.preventDefault()}},s.wrapper.find(q+", "+W).on(F,i).end().on(F,function(){e(document.documentElement).one("selectstart",m.preventDefault)}).on(P,function(){s._drag._end()}),s.wrapper.find(U).attr(X,0).on(z,function(){s._setTooltipTimeout()}).on(H,function(e){s._focusWithMouse(e.target),e.preventDefault()}).on(O,x(s._focus,s)).on(V,x(s._blur,s)),o=x(function(e){var t=s._nextValueByIndex(s._valueIndex+1*e);s._setValueInRange(t),s._drag._updateTooltip(t)},s),a.showButtons&&(r=x(function(e,t){this._clearTooltipTimeout(),(1===e.which||T.touch&&0===e.which)&&(o(t),this.timeout=setTimeout(x(function(){this.timer=setInterval(function(){o(t)},60)},this),200))},s),s.wrapper.find(".k-button").on(z,x(function(e){this._clearTimer(),s._focusWithMouse(e.target)},s)).on(N,function(t){e(t.currentTarget).addClass("k-state-hover")}).on("mouseout"+I,x(function(t){e(t.currentTarget).removeClass("k-state-hover"),this._clearTimer()},s)).eq(0).on(R,x(function(e){r(e,1)},s)).click(!1).end().eq(1).on(R,x(function(e){r(e,-1)},s)).click(m.preventDefault)),s.wrapper.find(U).off(L,!1).on(L,x(this._keydown,s)),a.enabled=!0)},disable:function(){var t=this;t.wrapper.removeClass($).addClass(Y),e(t.element).prop(K,K),t.wrapper.find(".k-button").off(R).on(R,function(t){t.preventDefault(),e(this).addClass("k-state-active")}).off(z).on(z,function(t){t.preventDefault(),e(this).removeClass("k-state-active")}).off("mouseleave"+I).on("mouseleave"+I,m.preventDefault).off(N).on(N,m.preventDefault),t.wrapper.find(q+", "+W).off(F).off(P),t.wrapper.find(U).attr(X,-1).off(z).off(L).off(H).off(O).off(V),t.options.enabled=!1},_update:function(e){var t=this,n=t.value()!=e;t.value(e),n&&t.trigger(E,{value:t.options.value})},value:function(e){var n=this,i=n.options;return e=d(e),isNaN(e)?i.value:(e>=i.min&&e<=i.max&&i.value!=e&&(n.element.prop("value",l(e)),i.value=e,n._refreshAriaAttr(e),n._refresh()),t)},_refresh:function(){this.trigger(B,{value:this.options.value})},_refreshAriaAttr:function(e){var t,n=this,i=n._drag;t=i&&i._tooltipDiv?i._tooltipDiv.text():n._getFormattedValue(e,null),this.wrapper.find(U).attr("aria-valuenow",e).attr("aria-valuetext",t)},_clearTimer:function(){clearTimeout(this.timeout),clearInterval(this.timer)},_keydown:function(e){var t=this;e.keyCode in t._keyMap&&(t._clearTooltipTimeout(),t._setValueInRange(t._keyMap[e.keyCode](t.options.value)),t._drag._updateTooltip(t.value()),e.preventDefault())},_setValueInRange:function(e){var n=this,i=n.options;return e=d(e),isNaN(e)?(n._update(i.min),t):(e=S.max(S.min(e,i.max),i.min),n._update(e),t)},_nextValueByIndex:function(e){var t=this._values.length;return this._isRtl&&(e=t-1-e),this._values[S.max(0,S.min(e,t-1))]},_formResetHandler:function(){var e=this,t=e.options.min;setTimeout(function(){var n=e.element[0].value;e.value(""===n||isNaN(n)?t:n)})},destroy:function(){var e=this;J.fn.destroy.call(e),e.wrapper.off(I).find(".k-button").off(I).end().find(U).off(I).end().find(q+", "+W).off(I).end(),e._drag.draggable.destroy(),e._drag._removeTooltip(!0)}});ee.Selection=function(e,t,n){function i(i){var o=i-n.min,r=t._valueIndex=S.ceil(d(o/n.smallStep)),s=parseInt(t._pixelSteps[r],10),a=t._trackDiv.find(".k-slider-selection"),l=parseInt(t._outerSize(e)/2,10),c=t._isRtl?2:0;a[t._sizeFn](t._isRtl?t._maxSelection-s:s),e.css(t._position,s-l-c)}i(n.value),t.bind([M,B],function(e){i(parseFloat(e.value,10))}),t.bind(E,function(e){i(parseFloat(e.sender.value(),10))})},ee.Drag=function(e,t,n,i){var o=this;o.owner=n,o.options=i,o.element=e,o.type=t,o.draggable=new v(e,{distance:0,dragstart:x(o._dragstart,o),drag:x(o.drag,o),dragend:x(o.dragend,o),dragcancel:x(o.dragcancel,o)}),e.click(!1)},ee.Drag.prototype={dragstart:function(e){this.owner._activeDragHandle=this,this.draggable.userEvents.cancel(),this._dragstart(e),this.dragend()},_dragstart:function(n){var i=this,o=i.owner,r=i.options;return r.enabled?(this.owner._activeDragHandle=this,o.element.off(N),o.wrapper.find("."+G).removeClass(G+" "+j),i.element.addClass(G+" "+j),e(document.documentElement).css("cursor","pointer"),i.dragableArea=o._getDraggableArea(),i.step=S.max(r.smallStep*(o._maxSelection/o._distance()),0),i.type?(i.selectionStart=r.selectionStart,i.selectionEnd=r.selectionEnd,o._setZIndex(i.type)):i.oldVal=i.val=r.value,i._removeTooltip(!0),i._createTooltip(),t):(n.preventDefault(),t)},_createTooltip:function(){var t,n,i=this,o=i.owner,r=i.options.tooltip,s="",a=e(window);r.enabled&&(r.template&&(t=i.tooltipTemplate=m.template(r.template)),e(".k-slider-tooltip").remove(),i.tooltipDiv=e("<div class='k-widget k-tooltip k-slider-tooltip'><!-- --></div>").appendTo(document.body),s=o._getFormattedValue(i.val||o.value(),i),i.type||(n="k-callout-"+(o._isHorizontal?"s":"e"),i.tooltipInnerDiv="<div class='k-callout "+n+"'><!-- --></div>",s+=i.tooltipInnerDiv),i.tooltipDiv.html(s),i._scrollOffset={top:a.scrollTop(),left:a.scrollLeft()},i.moveTooltip())},drag:function(e){var t,n=this,i=n.owner,o=e.x.location,r=e.y.location,s=n.dragableArea.startPoint,a=n.dragableArea.endPoint;e.preventDefault(),n.val=i._isHorizontal?i._isRtl?n.constrainValue(o,s,a,o<a):n.constrainValue(o,s,a,o>=a):n.constrainValue(r,a,s,r<=a),n.oldVal!=n.val&&(n.oldVal=n.val,n.type?("firstHandle"==n.type?n.selectionStart=n.val<n.selectionEnd?n.val:n.selectionEnd=n.val:n.val>n.selectionStart?n.selectionEnd=n.val:n.selectionStart=n.selectionEnd=n.val,t={values:[n.selectionStart,n.selectionEnd],value:[n.selectionStart,n.selectionEnd]}):t={value:n.val},i.trigger(M,t)),n._updateTooltip(n.val)},_updateTooltip:function(e){var t=this,n=t.options,i=n.tooltip,o="";i.enabled&&(t.tooltipDiv||t._createTooltip(),o=t.owner._getFormattedValue(d(e),t),t.type||(o+=t.tooltipInnerDiv),t.tooltipDiv.html(o),t.moveTooltip())},dragcancel:function(){return this.owner._refresh(),e(document.documentElement).css("cursor",""),this._end()},dragend:function(){var t=this,n=t.owner;return e(document.documentElement).css("cursor",""),t.type?n._update(t.selectionStart,t.selectionEnd):(n._update(t.val),t.draggable.userEvents._disposeAll()),t.draggable.userEvents.cancel(),t._end()},_end:function(){var e=this,t=e.owner;return t._focusWithMouse(e.element),t.element.on(N),!1},_removeTooltip:function(t){var n=this,i=n.owner;n.tooltipDiv&&i.options.tooltip.enabled&&i.options.enabled&&(t?(n.tooltipDiv.remove(),n.tooltipDiv=null):n.tooltipDiv.fadeOut("slow",function(){e(this).remove(),n.tooltipDiv=null}))},moveTooltip:function(){var t,n,i,o,r=this,s=r.owner,a=0,l=0,c=r.element,d=m.getOffset(c),u=8,h=e(window),f=r.tooltipDiv.find(".k-callout"),p=_(r.tooltipDiv),g=b(r.tooltipDiv);r.type?(t=s.wrapper.find(U),d=m.getOffset(t.eq(0)),n=m.getOffset(t.eq(1)),s._isHorizontal?(a=n.top,l=d.left+(n.left-d.left)/2):(a=d.top+(n.top-d.top)/2,l=n.left),o=_(t.eq(0))+2*u):(a=d.top,l=d.left,o=_(c)+2*u),s._isHorizontal?(l-=parseInt((p-s._outerSize(c))/2,10),a-=g+f.height()+u):(a-=parseInt((g-s._outerSize(c))/2,10),l-=p+f.width()+u),s._isHorizontal?(i=r._flip(a,g,o,b(h)+r._scrollOffset.top),a+=i,l+=r._fit(l,p,_(h)+r._scrollOffset.left)):(i=r._flip(l,p,o,_(h)+r._scrollOffset.left),a+=r._fit(a,g,b(h)+r._scrollOffset.top),l+=i),i>0&&f&&(f.removeClass(),f.addClass("k-callout k-callout-"+(s._isHorizontal?"n":"w"))),r.tooltipDiv.css({top:a,left:l})},_fit:function(e,t,n){var i=0;return e+t>n&&(i=n-(e+t)),e<0&&(i=-e),i},_flip:function(e,t,n,i){var o=0;return e+t>i&&(o+=-(n+t)),e+o<0&&(o+=n+t),o},constrainValue:function(e,t,n,i){var o=this,r=0;return r=t<e&&e<n?o.owner._getValueFromPosition(e,o.dragableArea):i?o.options.max:o.options.min}},m.ui.plugin(ee),p=J.extend({init:function(n,i){var o,r=this,s=e(n).find("input"),a=s.eq(0)[0],c=s.eq(1)[0];a.type="text",c.type="text",i&&i.showButtons&&(window.console&&window.console.warn("showbuttons option is not supported for the range slider, ignoring"),i.showButtons=!1),i=w({},{selectionStart:u(a,"value"),min:u(a,"min"),max:u(a,"max"),smallStep:u(a,"step")},{selectionEnd:u(c,"value"),min:u(c,"min"),max:u(c,"max"),smallStep:u(c,"step")},i),i&&i.enabled===t&&(i.enabled=!s.is("[disabled]")),J.fn.init.call(r,n,i),i=r.options,h(i.selectionStart)&&null!==i.selectionStart||(i.selectionStart=i.min,s.eq(0).prop("value",l(i.min))),h(i.selectionEnd)&&null!==i.selectionEnd||(i.selectionEnd=i.max,s.eq(1).prop("value",l(i.max))),o=r.wrapper.find(U),this._selection=new p.Selection(o,r,i),r._firstHandleDrag=new ee.Drag(o.eq(0),"firstHandle",r,i),r._lastHandleDrag=new ee.Drag(o.eq(1),"lastHandle",r,i)},options:{name:"RangeSlider",leftDragHandleTitle:"drag",rightDragHandleTitle:"drag",tooltip:{format:"{0:#,#.##}"},selectionStart:null,selectionEnd:null},enable:function(n){var i,o=this,r=o.options;o.disable(),n!==!1&&(o.wrapper.removeClass(Y).addClass($),o.wrapper.find("input").removeAttr(K),i=function(n){var i,s,a,l,c,d,u,h=Z(n)[0];if(h){if(i=o._isHorizontal?h.location.pageX:h.location.pageY,s=o._getDraggableArea(),a=o._getValueFromPosition(i,s),l=e(n.target),l.hasClass("k-draghandle"))return o.wrapper.find("."+G).removeClass(G+" "+j),l.addClass(G+" "+j),t;a<r.selectionStart?(c=a,d=r.selectionEnd,u=o._firstHandleDrag):a>o.selectionEnd?(c=r.selectionStart,d=a,u=o._lastHandleDrag):a-r.selectionStart<=r.selectionEnd-a?(c=a,d=r.selectionEnd,u=o._firstHandleDrag):(c=r.selectionStart,d=a,u=o._lastHandleDrag),u.dragstart(n),o._setValueInRange(c,d),o._focusWithMouse(u.element)}},o.wrapper.find(q+", "+W).on(F,i).end().on(F,function(){e(document.documentElement).one("selectstart",m.preventDefault)}).on(P,function(){o._activeDragHandle&&o._activeDragHandle._end()}),o.wrapper.find(U).attr(X,0).on(z,function(){o._setTooltipTimeout()}).on(H,function(e){o._focusWithMouse(e.target),e.preventDefault()}).on(O,x(o._focus,o)).on(V,x(o._blur,o)),o.wrapper.find(U).off(L,m.preventDefault).eq(0).on(L,x(function(e){this._keydown(e,"firstHandle")},o)).end().eq(1).on(L,x(function(e){this._keydown(e,"lastHandle")},o)),o.options.enabled=!0)},disable:function(){var e=this;e.wrapper.removeClass($).addClass(Y),e.wrapper.find("input").prop(K,K),e.wrapper.find(q+", "+W).off(F).off(P),e.wrapper.find(U).attr(X,-1).off(z).off(L).off(H).off(O).off(V),e.options.enabled=!1},_keydown:function(e,t){var n,i,o,r=this,s=r.options.selectionStart,a=r.options.selectionEnd;e.keyCode in r._keyMap&&(r._clearTooltipTimeout(),"firstHandle"==t?(o=r._activeHandleDrag=r._firstHandleDrag,s=r._keyMap[e.keyCode](s),s>a&&(a=s)):(o=r._activeHandleDrag=r._lastHandleDrag,a=r._keyMap[e.keyCode](a),s>a&&(s=a)),r._setValueInRange(d(s),d(a)),n=Math.max(s,r.options.selectionStart),i=Math.min(a,r.options.selectionEnd),o.selectionEnd=Math.max(i,r.options.selectionStart),o.selectionStart=Math.min(n,r.options.selectionEnd),o._updateTooltip(r.value()[r._activeHandle]),e.preventDefault())},_update:function(e,t){var n=this,i=n.value(),o=i[0]!=e||i[1]!=t;n.value([e,t]),o&&n.trigger(E,{values:[e,t],value:[e,t]})},value:function(e){return e&&e.length?this._value(e[0],e[1]):this._value()},_value:function(e,n){var i=this,o=i.options,r=o.selectionStart,s=o.selectionEnd;return isNaN(e)&&isNaN(n)?[r,s]:(e=d(e),n=d(n),e>=o.min&&e<=o.max&&n>=o.min&&n<=o.max&&e<=n&&(r==e&&s==n||(i.element.find("input").eq(0).prop("value",l(e)).end().eq(1).prop("value",l(n)),o.selectionStart=e,o.selectionEnd=n,i._refresh(),i._refreshAriaAttr(e,n))),t)},values:function(e,t){return C(e)?this._value(e[0],e[1]):this._value(e,t)},_refresh:function(){var e=this,t=e.options;e.trigger(B,{values:[t.selectionStart,t.selectionEnd],value:[t.selectionStart,t.selectionEnd]}),t.selectionStart==t.max&&t.selectionEnd==t.max&&e._setZIndex("firstHandle")},_refreshAriaAttr:function(e,t){var n,i=this,o=i.wrapper.find(U),r=i._activeHandleDrag;n=i._getFormattedValue([e,t],r),o.eq(0).attr("aria-valuenow",e),o.eq(1).attr("aria-valuenow",t),o.attr("aria-valuetext",n)},_setValueInRange:function(e,t){var n=this.options;e=S.max(S.min(e,n.max),n.min),t=S.max(S.min(t,n.max),n.min),e==n.max&&t==n.max&&this._setZIndex("firstHandle"),this._update(S.min(e,t),S.max(e,t))},_setZIndex:function(t){this.wrapper.find(U).each(function(n){e(this).css("z-index","firstHandle"==t?1-n:n)})},_formResetHandler:function(){var e=this,t=e.options;setTimeout(function(){var n=e.element.find("input"),i=n[0].value,o=n[1].value;e.values(""===i||isNaN(i)?t.min:i,""===o||isNaN(o)?t.max:o)})},destroy:function(){var e=this;J.fn.destroy.call(e),e.wrapper.off(I).find(q+", "+W).off(I).end().find(U).off(I),e._firstHandleDrag.draggable.destroy(),e._lastHandleDrag.draggable.destroy()}}),p.Selection=function(e,t,n){function i(i){i=i||[];var r=i[0]-n.min,s=i[1]-n.min,a=S.ceil(d(r/n.smallStep)),l=S.ceil(d(s/n.smallStep)),c=t._pixelSteps[a],u=t._pixelSteps[l],h=parseInt(t._outerSize(e.eq(0))/2,10),f=t._isRtl?2:0;e.eq(0).css(t._position,c-h-f).end().eq(1).css(t._position,u-h-f),o(c,u)}function o(e,n){var i,o,r=t._trackDiv.find(".k-slider-selection");i=S.abs(e-n),r[t._sizeFn](i),t._isRtl?(o=S.max(e,n),r.css("right",t._maxSelection-o-1)):(o=S.min(e,n),r.css(t._position,o-1))}i(t.value()),t.bind([E,M,B],function(e){i(e.values)})},m.ui.plugin(p)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.colorpicker.min",["kendo.core.min","kendo.color.min","kendo.popup.min","kendo.slider.min","kendo.userevents.min","kendo.button.min"],e)}(function(){return function(e,t,n){function i(e,t,n){n=d(n),n&&!n.equals(e.color())&&("change"==t&&(e._value=n),n=1!=n.a?n.toCssRgba():n.toCss(),e.trigger(t,{value:n}))}function o(e,t,n){var i,o;return e=Array.prototype.slice.call(e),i=e.length,o=e.indexOf(t),o<0?n<0?e[i-1]:e[0]:(o+=n,o<0?o+=i:o%=i,e[o])}function r(e){e.preventDefault()}function s(e,t){return function(){return e.apply(t,arguments)}}var a=window.kendo,l=a.ui,c=l.Widget,d=a.parseColor,u=a.Color,h=a.keys,f="background-color",p="k-state-selected",m="000000,7f7f7f,880015,ed1c24,ff7f27,fff200,22b14c,00a2e8,3f48cc,a349a4,ffffff,c3c3c3,b97a57,ffaec9,ffc90e,efe4b0,b5e61d,99d9ea,7092be,c8bfe7",g="FFFFFF,FFCCFF,FF99FF,FF66FF,FF33FF,FF00FF,CCFFFF,CCCCFF,CC99FF,CC66FF,CC33FF,CC00FF,99FFFF,99CCFF,9999FF,9966FF,9933FF,9900FF,FFFFCC,FFCCCC,FF99CC,FF66CC,FF33CC,FF00CC,CCFFCC,CCCCCC,CC99CC,CC66CC,CC33CC,CC00CC,99FFCC,99CCCC,9999CC,9966CC,9933CC,9900CC,FFFF99,FFCC99,FF9999,FF6699,FF3399,FF0099,CCFF99,CCCC99,CC9999,CC6699,CC3399,CC0099,99FF99,99CC99,999999,996699,993399,990099,FFFF66,FFCC66,FF9966,FF6666,FF3366,FF0066,CCFF66,CCCC66,CC9966,CC6666,CC3366,CC0066,99FF66,99CC66,999966,996666,993366,990066,FFFF33,FFCC33,FF9933,FF6633,FF3333,FF0033,CCFF33,CCCC33,CC9933,CC6633,CC3333,CC0033,99FF33,99CC33,999933,996633,993333,990033,FFFF00,FFCC00,FF9900,FF6600,FF3300,FF0000,CCFF00,CCCC00,CC9900,CC6600,CC3300,CC0000,99FF00,99CC00,999900,996600,993300,990000,66FFFF,66CCFF,6699FF,6666FF,6633FF,6600FF,33FFFF,33CCFF,3399FF,3366FF,3333FF,3300FF,00FFFF,00CCFF,0099FF,0066FF,0033FF,0000FF,66FFCC,66CCCC,6699CC,6666CC,6633CC,6600CC,33FFCC,33CCCC,3399CC,3366CC,3333CC,3300CC,00FFCC,00CCCC,0099CC,0066CC,0033CC,0000CC,66FF99,66CC99,669999,666699,663399,660099,33FF99,33CC99,339999,336699,333399,330099,00FF99,00CC99,009999,006699,003399,000099,66FF66,66CC66,669966,666666,663366,660066,33FF66,33CC66,339966,336666,333366,330066,00FF66,00CC66,009966,006666,003366,000066,66FF33,66CC33,669933,666633,663333,660033,33FF33,33CC33,339933,336633,333333,330033,00FF33,00CC33,009933,006633,003333,000033,66FF00,66CC00,669900,666600,663300,660000,33FF00,33CC00,339900,336600,333300,330000,00FF00,00CC00,009900,006600,003300,000000",v="#ffffff",_={apply:"Apply",cancel:"Cancel",noColor:"no color",clearColor:"Clear color",previewInput:"Color Hexadecimal Code"},b=".kendoColorTools",w="click"+b,y="keydown"+b,k=a.support.browser,x=k.msie&&k.version<9,C=c.extend({init:function(e,t){var n,i=this;c.fn.init.call(i,e,t),e=i.element,t=i.options,i._value=t.value=d(t.value),i._tabIndex=e.attr("tabIndex")||0,n=i._ariaId=t.ariaId,n&&e.attr("aria-labelledby",n),t._standalone&&(i._triggerSelect=i._triggerChange)},options:{name:"ColorSelector",value:null,_standalone:!0},events:["change","select","cancel"],color:function(e){return e!==n&&(this._value=d(e),this._updateUI(this._value)),this._value},value:function(e){return e=this.color(e),e&&(e=this.options.opacity?e.toCssRgba():e.toCss()),e||null},enable:function(t){0===arguments.length&&(t=!0),e(".k-disabled-overlay",this.wrapper).remove(),t||this.wrapper.append("<div class='k-disabled-overlay'></div>"),this._onEnable(t)},_select:function(e,t){var n=this._value;e=this.color(e),t||(this.element.trigger("change"),e.equals(n)?this._standalone||this.trigger("cancel"):this.trigger("change",{value:this.value()}))},_triggerSelect:function(e){i(this,"select",e)},_triggerChange:function(e){i(this,"change",e)},destroy:function(){this.element&&this.element.off(b),this.wrapper&&this.wrapper.off(b).find("*").off(b),this.wrapper=null,c.fn.destroy.call(this)},_updateUI:e.noop,_selectOnHide:function(){return null},_cancel:function(){this.trigger("cancel")}}),S=C.extend({init:function(t,n){var i,o,r,l,c=this;if(C.fn.init.call(c,t,n),t=c.wrapper=c.element,n=c.options,i=n.palette,"websafe"==i?(i=g,n.columns=18):"basic"==i&&(i=m),"string"==typeof i&&(i=i.split(",")),e.isArray(i)&&(i=e.map(i,function(e){return d(e)})),c._selectedID=(n.ariaId||a.guid())+"_selected",t.addClass("k-widget k-colorpalette").attr("role","grid").attr("aria-readonly","true").append(e(c._template({colors:i,columns:n.columns,tileSize:n.tileSize,value:c._value,id:n.ariaId}))).on(w,".k-item",function(t){c._select(e(t.currentTarget).css(f))}).attr("tabIndex",c._tabIndex).on(y,s(c._keydown,c)),o=n.tileSize){if(/number|string/.test(typeof o))r=l=parseFloat(o);else{if("object"!=typeof o)throw Error("Unsupported value for the 'tileSize' argument");r=parseFloat(o.width),l=parseFloat(o.height)}t.find(".k-item").css({width:r,height:l})}},focus:function(){this.wrapper.focus()},options:{name:"ColorPalette",columns:10,tileSize:null,palette:"basic"},_onEnable:function(e){e?this.wrapper.attr("tabIndex",this._tabIndex):this.wrapper.removeAttr("tabIndex")},_keydown:function(t){var n,i,s=this.wrapper,a=s.find(".k-item"),l=a.filter("."+p).get(0),c=t.keyCode;if(c==h.LEFT?n=o(a,l,-1):c==h.RIGHT?n=o(a,l,1):c==h.DOWN?n=o(a,l,this.options.columns):c==h.UP?n=o(a,l,-this.options.columns):c==h.ENTER?(r(t),l&&this._select(e(l).css(f))):c==h.ESC&&this._cancel(),n){r(t),this._current(n);try{i=d(n.css(f)),this._triggerSelect(i)}catch(u){}}},_current:function(t){this.wrapper.find("."+p).removeClass(p).attr("aria-selected",!1).removeAttr("id"),e(t).addClass(p).attr("aria-selected",!0).attr("id",this._selectedID),this.element.removeAttr("aria-activedescendant").attr("aria-activedescendant",this._selectedID)},_updateUI:function(t){var n=null;this.wrapper.find(".k-item").each(function(){var i=d(e(this).css(f));if(i&&i.equals(t))return n=this,!1}),this._current(n)},_template:a.template('<table class="k-palette k-reset" role="presentation"><tr role="row"># for (var i = 0; i < colors.length; ++i) { ## var selected = colors[i].equals(value); ## if (i && i % columns == 0) { # </tr><tr role="row"> # } #<td role="gridcell" unselectable="on" style="background-color:#= colors[i].toCss() #"#= selected ? " aria-selected=true" : "" # #=(id && i === 0) ? "id=\\""+id+"\\" " : "" # class="k-item#= selected ? " '+p+'" : "" #" aria-label="#= colors[i].toCss() #"></td># } #</tr></table>')}),T=C.extend({init:function(t,n){var i=this;C.fn.init.call(i,t,n),n=i.options,n.messages=n.options?e.extend(i.options.messages,n.options.messages):i.options.messages,t=i.element,i.wrapper=t.addClass("k-widget k-flatcolorpicker").append(i._template(n)),i._hueElements=e(".k-hsv-rectangle, .k-transparency-slider .k-slider-track",t),i._selectedColor=e(".k-selected-color-display",t),i._colorAsText=e("input.k-color-value",t),
i._sliders(),i._hsvArea(),i._updateUI(i._value||d("#f00")),t.find("input.k-color-value").on(y,function(t){var n,o,r=this;if(t.keyCode==h.ENTER)try{n=d(r.value),o=i.color(),i._select(n,n.equals(o))}catch(s){e(r).addClass("k-state-error")}else i.options.autoupdate&&setTimeout(function(){var e=d(r.value,!0);e&&i._updateUI(e,!0)},10)}).end().on(w,".k-controls button.apply",function(){i.options._clearedColor?i.trigger("change"):i._select(i._getHSV())}).on(w,".k-controls button.cancel",function(){i._updateUI(i.color()),i._cancel()}),x&&i._applyIEFilter()},destroy:function(){this._hueSlider.destroy(),this._opacitySlider&&this._opacitySlider.destroy(),this._hueSlider=this._opacitySlider=this._hsvRect=this._hsvHandle=this._hueElements=this._selectedColor=this._colorAsText=null,C.fn.destroy.call(this)},options:{name:"FlatColorPicker",opacity:!1,buttons:!1,input:!0,preview:!0,clearButton:!1,autoupdate:!0,messages:_},_applyIEFilter:function(){var e=this.element.find(".k-hue-slider .k-slider-track")[0],t=e.currentStyle.backgroundImage;t=t.replace(/^url\([\'\"]?|[\'\"]?\)$/g,""),e.style.filter="progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+t+"', sizingMethod='scale')"},_sliders:function(){function e(e){n._updateUI(n._getHSV(e.value,null,null,null))}function t(e){n._updateUI(n._getHSV(null,null,null,e.value/100))}var n=this,i=n.element,o=i.find(".k-hue-slider"),r=i.find(".k-transparency-slider");o.attr("aria-label","hue saturation"),n._hueSlider=o.kendoSlider({min:0,max:360,tickPlacement:"none",showButtons:!1,slide:e,change:e}).data("kendoSlider"),r.attr("aria-label","opacity"),n._opacitySlider=r.kendoSlider({min:0,max:100,tickPlacement:"none",showButtons:!1,slide:t,change:t}).data("kendoSlider")},_hsvArea:function(){function e(e,n){var i=this.offset,o=e-i.left,r=n-i.top,s=this.width,a=this.height;o=o<0?0:o>s?s:o,r=r<0?0:r>a?a:r,t._svChange(o/s,1-r/a)}var t=this,n=t.element,i=n.find(".k-hsv-rectangle"),o=i.find(".k-draghandle").attr("tabIndex",0).on(y,s(t._keydown,t));t._hsvEvents=new a.UserEvents(i,{global:!0,press:function(t){this.offset=a.getOffset(i),this.width=i.width(),this.height=i.height(),o.focus(),e.call(this,t.x.location,t.y.location)},start:function(){i.addClass("k-dragging"),o.focus()},move:function(t){t.preventDefault(),e.call(this,t.x.location,t.y.location)},end:function(){i.removeClass("k-dragging")}}),t._hsvRect=i,t._hsvHandle=o},_onEnable:function(e){this._hueSlider.enable(e),this._opacitySlider&&this._opacitySlider.enable(e),this.wrapper.find("input").attr("disabled",!e);var t=this._hsvRect.find(".k-draghandle");e?t.attr("tabIndex",this._tabIndex):t.removeAttr("tabIndex")},_keydown:function(e){function t(t,n){var o=i._getHSV();o[t]+=n*(e.shiftKey?.01:.05),o[t]<0&&(o[t]=0),o[t]>1&&(o[t]=1),i._updateUI(o),r(e)}function n(t){var n=i._getHSV();n.h+=t*(e.shiftKey?1:5),n.h<0&&(n.h=0),n.h>359&&(n.h=359),i._updateUI(n),r(e)}var i=this;switch(e.keyCode){case h.LEFT:e.ctrlKey?n(-1):t("s",-1);break;case h.RIGHT:e.ctrlKey?n(1):t("s",1);break;case h.UP:t(e.ctrlKey&&i._opacitySlider?"a":"v",1);break;case h.DOWN:t(e.ctrlKey&&i._opacitySlider?"a":"v",-1);break;case h.ENTER:i._select(i._getHSV());break;case h.F2:i.wrapper.find("input.k-color-value").focus().select();break;case h.ESC:i._cancel()}},focus:function(){this._hsvHandle.focus()},_getHSV:function(e,t,n,i){var o=this._hsvRect,r=o.width(),s=o.height(),a=this._hsvHandle.position();return null==e&&(e=this._hueSlider.value()),null==t&&(t=a.left/r),null==n&&(n=1-a.top/s),null==i&&(i=this._opacitySlider?this._opacitySlider.value()/100:1),u.fromHSV(e,t,n,i)},_svChange:function(e,t){var n=this._getHSV(null,e,t,null);this._updateUI(n)},_updateUI:function(e,t){var n=this,i=n._hsvRect;e&&(this._colorAsText.attr("title",n.options.messages.previewInput),this._colorAsText.removeClass("k-state-error"),n._selectedColor.css(f,e.toDisplay()),t||n._colorAsText.val(n._opacitySlider?e.toCssRgba():e.toCss()),n._triggerSelect(e),e=e.toHSV(),n._hsvHandle.css({left:e.s*i.width()+"px",top:(1-e.v)*i.height()+"px"}),n._hueElements.css(f,u.fromHSV(e.h,1,1,1).toCss()),n._hueSlider.value(e.h),n._opacitySlider&&n._opacitySlider.value(100*e.a))},_selectOnHide:function(){return this.options.buttons?null:this._getHSV()},_template:a.template('# if (preview) { #<div class="k-selected-color"><div class="k-selected-color-display"><div class="k-color-input"><input class="k-color-value" # if (clearButton && !_standalone) { #placeholder="#: messages.noColor #" # } ##= !data.input ? \'style="visibility: hidden;"\' : "" #># if (clearButton && !_standalone) { #<span class="k-clear-color k-button k-bare" title="#: messages.clearColor #"></span># } #</div></div></div># } ## if (clearButton && !_standalone && !preview) { #<div class="k-clear-color-container"><span class="k-clear-color k-button k-bare">#: messages.clearColor #</span></div># } #<div class="k-hsv-rectangle"><div class="k-hsv-gradient"></div><div class="k-draghandle"></div></div><input class="k-hue-slider" /># if (opacity) { #<input class="k-transparency-slider" /># } ## if (buttons) { #<div unselectable="on" class="k-controls"><button class="k-button k-primary apply">#: messages.apply #</button> <button class="k-button cancel">#: messages.cancel #</button></div># } #')}),D=c.extend({init:function(t,n){var i,o,r,s,a,l=this;c.fn.init.call(l,t,n),n=l.options,t=l.element,i=t.attr("value")||t.val(),i=i?d(i,!0):d(n.value,!0),l._value=n.value=i,o=l.wrapper=e(l._template(n)),t.hide().after(o),t.is("input")&&(t.appendTo(o),r=t.closest("label"),s=t.attr("id"),s&&(r=r.add('label[for="'+s+'"]')),r.click(function(e){l.open(),e.preventDefault()})),l._tabIndex=t.attr("tabIndex")||0,l.enable(!t.attr("disabled")),a=t.attr("accesskey"),a&&(t.attr("accesskey",null),o.attr("accesskey",a)),l.bind("activate",function(e){e.isDefaultPrevented()||l.toggle()}),l._updateUI(i)},destroy:function(){this.wrapper.off(b).find("*").off(b),this._popup&&(this._selector.destroy(),this._popup.destroy()),this._selector=this._popup=this.wrapper=null,c.fn.destroy.call(this)},enable:function(e){var t=this,n=t.wrapper,i=n.children(".k-picker-wrap"),o=i.find(".k-select");0===arguments.length&&(e=!0),t.element.attr("disabled",!e),n.attr("aria-disabled",!e),o.off(b).on("mousedown"+b,r),n.addClass("k-state-disabled").removeAttr("tabIndex").add("*",n).off(b),e?n.removeClass("k-state-disabled").attr("tabIndex",t._tabIndex).on("mouseenter"+b,function(){i.addClass("k-state-hover")}).on("mouseleave"+b,function(){i.removeClass("k-state-hover")}).on("focus"+b,function(){i.addClass("k-state-focused")}).on("blur"+b,function(){i.removeClass("k-state-focused")}).on(y,s(t._keydown,t)).on(w,".k-select",s(t.toggle,t)).on(w,t.options.toolIcon?".k-tool-icon":".k-selected-color",function(){t.trigger("activate")}):t.close()},_template:a.template('<span role="textbox" aria-haspopup="true" class="k-widget k-colorpicker k-header"><span class="k-picker-wrap k-state-default"># if (toolIcon) { #<span class="k-icon k-tool-icon #= toolIcon #"><span class="k-selected-color"></span></span># } else { #<span class="k-selected-color"><span class="k-icon k-i-line" style="display: none;"></span></span># } #<span class="k-select" unselectable="on" aria-label="select"><span class="k-icon k-i-arrow-60-down"></span></span></span></span>'),options:{name:"ColorPicker",palette:null,columns:10,toolIcon:null,value:null,messages:_,opacity:!1,buttons:!0,preview:!0,clearButton:!1,ARIATemplate:'Current selected color is #=data || ""#'},events:["activate","change","select","open","close"],open:function(){this.element.prop("disabled")||this._getPopup().open()},close:function(){var e=this._selector&&this._selector.options||{};e._closing=!0,this._getPopup().close(),delete e._closing},toggle:function(){this.element.prop("disabled")||this._getPopup().toggle()},_noColorIcon:function(){return this.wrapper.find(".k-picker-wrap > .k-selected-color > .k-icon.k-i-line")},color:C.fn.color,value:C.fn.value,_select:C.fn._select,_triggerSelect:C.fn._triggerSelect,_isInputTypeColor:function(){var e=this.element[0];return/^input$/i.test(e.tagName)&&/^color$/i.test(e.type)},_updateUI:function(e){var t="";e&&(t=this._isInputTypeColor()||1==e.a?e.toCss():e.toCssRgba(),this.element.val(t)),this._ariaTemplate||(this._ariaTemplate=a.template(this.options.ARIATemplate)),this.wrapper.attr("aria-label",this._ariaTemplate(t)),this._triggerSelect(e),this.wrapper.find(".k-selected-color").css(f,e?e.toDisplay():v),this._noColorIcon()[t?"hide":"show"]()},_keydown:function(e){var t=e.keyCode;this._getPopup().visible()?(t==h.ESC?this._selector._cancel():this._selector._keydown(e),r(e)):t!=h.ENTER&&t!=h.DOWN||(this.open(),r(e))},_getPopup:function(){var t,i,o,r,s=this,l=s._popup;return l||(t=s.options,i=t.palette?S:T,t._standalone=!1,delete t.select,delete t.change,delete t.cancel,o=a.guid(),r=s._selector=new i(e('<div id="'+o+'"/>').appendTo(document.body),t),s.wrapper.attr("aria-owns",o),s._popup=l=r.wrapper.kendoPopup({anchor:s.wrapper,adjustSize:{width:5,height:0}}).data("kendoPopup"),r.element.find(".k-clear-color").kendoButton({icon:"reset-color",click:function(e){r.options._clearedColor=!0,s.value(null),s.element.val(null),s._updateUI(null),r._colorAsText.val(""),r._hsvHandle.css({top:"0px",left:"0px"}),r._selectedColor.css(f,v),s.trigger("change",{value:s.value()}),e.preventDefault()}}),r.bind({select:function(e){s._updateUI(d(e.value)),delete r.options._clearedColor},change:function(){r.options._clearedColor||s._select(r.color()),s.close()},cancel:function(){r.options._clearedColor&&!s.value()&&r.value()&&s._select(r.color(),!0),s.close()}}),l.bind({close:function(e){var t,i,o,a;return s.trigger("close")?(e.preventDefault(),n):(s.wrapper.children(".k-picker-wrap").removeClass("k-state-focused"),t=r._selectOnHide(),i=r.value(),o=s.value(),a=r.options,t?a._clearedColor&&!o||s._select(t):(setTimeout(function(){s.wrapper&&s.wrapper.focus()}),!a._closing&&a._clearedColor&&!o&&i?s._select(i,!0):s._updateUI(s.color())),n)},open:function(e){s.trigger("open")?e.preventDefault():s.wrapper.children(".k-picker-wrap").addClass("k-state-focused")},activate:function(){r._select(s.color(),!0),r.focus(),s.wrapper.children(".k-picker-wrap").addClass("k-state-focused")}})),l}});l.plugin(S),l.plugin(T),l.plugin(D)}(jQuery,parseInt),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.numerictextbox.min",["kendo.core.min","kendo.userevents.min"],e)}(function(){return function(e,t){function n(e,t){var n="k-i-arrow-"+("increase"===e?"60-up":"60-down");return'<span unselectable="on" class="k-link k-link-'+e+'" aria-label="'+t+'" title="'+t+'"><span unselectable="on" class="'+A+" "+n+'"></span></span>'}function i(e,t){var n=(""+parseFloat(e,10)).split(D);return n[1]&&(n[1]=n[1].substring(0,t)),n.join(D)}var o=window.kendo,r=o.caret,s=o.keys,a=o.ui,l=a.Widget,c=o._activeElement,d=o._extractFormat,u=o.parseFloat,h=o.support.placeholder,f=o.getCulture,p="change",m="disabled",g="readonly",v="k-input",_="spin",b=".kendoNumericTextBox",w="touchend",y="mouseleave"+b,k="mouseenter"+b+" "+y,x="k-state-default",C="k-state-focused",S="k-state-hover",T="focus",D=".",A="k-icon",E="k-state-selected",M="k-state-disabled",I="k-state-invalid",R="aria-disabled",F=/^(-)?(\d*)$/,z=null,P=e.proxy,B=e.extend,L=l.extend({init:function(n,i){var r,s,a,c,u,h=this,f=i&&i.step!==t;l.fn.init.call(h,n,i),i=h.options,n=h.element.on("focusout"+b,P(h._focusout,h)).attr("role","spinbutton"),i.placeholder=i.placeholder||n.attr("placeholder"),h._initialOptions=B({},i),r=h.min(n.attr("min")),s=h.max(n.attr("max")),a=h._parse(n.attr("step")),i.min===z&&r!==z&&(i.min=r),i.max===z&&s!==z&&(i.max=s),f||a===z||(i.step=a),h._reset(),h._wrapper(),h._arrows(),h._validation(),h._input(),o.support.mobileOS?h._text.on(w+b+" "+T+b,function(){o.support.browser.edge?h._text.one(T+b,function(){h._toggleText(!1),n.focus()}):(h._toggleText(!1),n.focus())}):h._text.on(T+b,P(h._click,h)),n.attr("aria-valuemin",i.min!==z?i.min*i.factor:i.min).attr("aria-valuemax",i.max!==z?i.max*i.factor:i.max),i.format=d(i.format),c=i.value,h.value(c!==z?c:n.val()),u=n.is("[disabled]")||e(h.element).parents("fieldset").is(":disabled"),u?h.enable(!1):h.readonly(n.is("[readonly]")),o.notify(h)},options:{name:"NumericTextBox",decimals:z,restrictDecimals:!1,min:z,max:z,value:z,step:1,round:!0,culture:"",format:"n",spinners:!0,placeholder:"",factor:1,upArrowText:"Increase value",downArrowText:"Decrease value"},events:[p,_],_editable:function(e){var t=this,n=t.element,i=e.disable,o=e.readonly,r=t._text.add(n),s=t._inputWrapper.off(k);t._toggleText(!0),t._upArrowEventHandler.unbind("press"),t._downArrowEventHandler.unbind("press"),n.off("keydown"+b).off("keypress"+b).off("keyup"+b).off("paste"+b),o||i?(s.addClass(i?M:x).removeClass(i?x:M),r.attr(m,i).attr(g,o).attr(R,i)):(s.addClass(x).removeClass(M).on(k,t._toggleHover),r.removeAttr(m).removeAttr(g).attr(R,!1),t._upArrowEventHandler.bind("press",function(e){e.preventDefault(),t._spin(1),t._upArrow.addClass(E)}),t._downArrowEventHandler.bind("press",function(e){e.preventDefault(),t._spin(-1),t._downArrow.addClass(E)}),t.element.on("keydown"+b,P(t._keydown,t)).on("keypress"+b,P(t._keypress,t)).on("keyup"+b,P(t._keyup,t)).on("paste"+b,P(t._paste,t)))},readonly:function(e){this._editable({readonly:e===t||e,disable:!1})},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)})},destroy:function(){var e=this;e.element.add(e._text).add(e._upArrow).add(e._downArrow).add(e._inputWrapper).off(b),e._upArrowEventHandler.destroy(),e._downArrowEventHandler.destroy(),e._form&&e._form.off("reset",e._resetHandler),l.fn.destroy.call(e)},min:function(e){return this._option("min",e)},max:function(e){return this._option("max",e)},step:function(e){return this._option("step",e)},value:function(e){var n,i=this;return e===t?i._value:(e=i._parse(e),n=i._adjust(e),e===n&&(i._update(e),i._old=i._value),t)},focus:function(){this._focusin()},_adjust:function(e){var t=this,n=t.options,i=n.min,o=n.max;return e===z?e:(i!==z&&e<i?e=i:o!==z&&e>o&&(e=o),e)},_arrows:function(){var t,i=this,r=function(){clearTimeout(i._spinning),t.removeClass(E)},s=i.options,a=s.spinners,l=i.element;t=l.siblings("."+A),t[0]||(t=e(n("increase",s.upArrowText)+n("decrease",s.downArrowText)).insertAfter(l),t.wrapAll('<span class="k-select"/>')),a||(t.parent().toggle(a),i._inputWrapper.addClass("k-expand-padding")),i._upArrow=t.eq(0),i._upArrowEventHandler=new o.UserEvents(i._upArrow,{release:r}),i._downArrow=t.eq(1),i._downArrowEventHandler=new o.UserEvents(i._downArrow,{release:r})},_validation:function(){var t=this,n=t.element;t._validationIcon=e("<span class='"+A+" k-i-warning'></span>").hide().insertAfter(n)},_blur:function(){var e=this;e._toggleText(!0),e._change(e.element.val())},_click:function(e){var t=this;clearTimeout(t._focusing),t._focusing=setTimeout(function(){var n,i,o,s=e.target,a=r(s)[0],l=s.value.substring(0,a),c=t._format(t.options.format),d=c[","],u=0;d&&(i=RegExp("\\"+d,"g"),o=RegExp("([\\d\\"+d+"]+)(\\"+c[D]+")?(\\d+)?")),o&&(n=o.exec(l)),n&&(u=n[0].replace(i,"").length,l.indexOf("(")!=-1&&t._value<0&&u++),t._focusin(),r(t.element[0],u)})},_change:function(e){var t=this,n=t.options.factor;n&&1!==n&&(e=parseFloat(e),null!==e&&(e/=n)),t._update(e),e=t._value,t._old!=e&&(t._old=e,t._typing||t.element.trigger(p),t.trigger(p)),t._typing=!1},_culture:function(e){return e||f(this.options.culture)},_focusin:function(){var e=this;e._inputWrapper.addClass(C),e._toggleText(!1),e.element[0].focus()},_focusout:function(){var e=this;clearTimeout(e._focusing),e._inputWrapper.removeClass(C).removeClass(S),e._blur(),e._removeInvalidState()},_format:function(e,t){var n=this._culture(t).numberFormat;return e=e.toLowerCase(),e.indexOf("c")>-1?n=n.currency:e.indexOf("p")>-1&&(n=n.percent),n},_input:function(){var t,n=this,i=n.options,o="k-formatted-value",r=n.element.addClass(v).show()[0],s=r.accessKey,a=n.wrapper;t=a.find(D+o),t[0]||(t=e('<input type="text"/>').insertBefore(r).addClass(o));try{r.setAttribute("type","text")}catch(l){r.type="text"}n._initialTitle=r.title,t[0].title=r.title,t[0].tabIndex=r.tabIndex,t[0].style.cssText=r.style.cssText,t.prop("placeholder",i.placeholder),s&&(t.attr("accesskey",s),r.accessKey=""),n._text=t.addClass(r.className).attr({role:"spinbutton","aria-valuemin":i.min!==z?i.min*i.factor:i.min,"aria-valuemax":i.max!==z?i.max*i.factor:i.max})},_keydown:function(e){var t=this,n=e.keyCode;t._key=n,n==s.DOWN?t._step(-1):n==s.UP?t._step(1):n==s.ENTER?t._change(t.element.val()):t._typing=!0},_keypress:function(e){var t,n,i,o,a,l,c,d,u,h,f;0===e.which||e.metaKey||e.ctrlKey||e.keyCode===s.BACKSPACE||e.keyCode===s.ENTER||(t=this,n=t.options.min,i=t.element,o=r(i),a=o[0],l=o[1],c=String.fromCharCode(e.which),d=t._format(t.options.format),u=t._key===s.NUMPAD_DOT,h=i.val(),u&&(c=d[D]),h=h.substring(0,a)+c+h.substring(l),f=t._numericRegex(d).test(h),f&&u?(i.val(h),r(i,a+c.length),e.preventDefault()):(null!==n&&n>=0&&"-"===h.charAt(0)||!f)&&(t._addInvalidState(),e.preventDefault()),t._key=0)},_keyup:function(){this._removeInvalidState()},_addInvalidState:function(){var e=this;e._inputWrapper.addClass(I),e._validationIcon.show()},_removeInvalidState:function(){var e=this;e._inputWrapper.removeClass(I),e._validationIcon.hide()},_numericRegex:function(e){var t=this,n=e[D],i=t.options.decimals,o="*";return n===D&&(n="\\"+n),i===z&&(i=e.decimals),0===i?F:(t.options.restrictDecimals&&(o="{0,"+i+"}"),t._separator!==n&&(t._separator=n,t._floatRegExp=RegExp("^(-)?(((\\d+("+n+"\\d"+o+")?)|("+n+"\\d"+o+")))?$")),t._floatRegExp)},_paste:function(e){var t=this,n=e.target,i=n.value,o=t._format(t.options.format);setTimeout(function(){var e=t._parse(n.value);e===z?t._update(i):(n.value=(""+e).replace(D,o[D]),t._adjust(e)===e&&t._numericRegex(o).test(n.value)||t._update(i))})},_option:function(e,n){var i=this,o=i.element,r=i.options;return n===t?r[e]:(n=i._parse(n),(n||"step"!==e)&&(r[e]=n,o.add(i._text).attr("aria-value"+e,n),o.attr(e,n)),t)},_spin:function(e,t){var n=this;t=t||500,clearTimeout(n._spinning),n._spinning=setTimeout(function(){n._spin(e,50)},t),n._step(e)},_step:function(e){var t=this,n=t.element,i=t._parse(n.val())||0;c()!=n[0]&&t._focusin(),t.options.factor&&i&&(i/=t.options.factor),i+=t.options.step*e,t._update(t._adjust(i)),t._typing=!1,t.trigger(_)},_toggleHover:function(t){e(t.currentTarget).toggleClass(S,"mouseenter"===t.type)},_toggleText:function(e){var t=this;t._text.toggle(e),t.element.toggle(!e)},_parse:function(e,t){return u(e,this._culture(t),this.options.format)},_round:function(e,t){var n=this.options.round?o._round:i;return n(e,t)},_update:function(e){var t,n=this,i=n.options,r=i.factor,s=i.format,a=i.decimals,l=n._culture(),c=n._format(s,l);a===z&&(a=c.decimals),e=n._parse(e,l),t=e!==z,t&&(e=parseFloat(n._round(e,a),10)),n._value=e=n._adjust(e),n._placeholder(o.toString(e,s,l)),t?(r&&(e=parseFloat(n._round(e*r,a),10)),e=""+e,e.indexOf("e")!==-1&&(e=n._round(+e,a)),e=e.replace(D,c[D])):e=null,n.element.val(e),n.element.add(n._text).attr("aria-valuenow",e)},_placeholder:function(e){var t=this._text;t.val(e),h||e||t.val(this.options.placeholder),t.attr("title",this._initialTitle||t.val())},_wrapper:function(){var t,n=this,i=n.element,o=i[0];t=i.parents(".k-numerictextbox"),t.is("span.k-numerictextbox")||(t=i.hide().wrap('<span class="k-numeric-wrap k-state-default" />').parent(),t=t.wrap("<span/>").parent()),t[0].style.cssText=o.style.cssText,o.style.width="",n.wrapper=t.addClass("k-widget k-numerictextbox").addClass(o.className).css("display",""),n._inputWrapper=e(t[0].firstChild)},_reset:function(){var t=this,n=t.element,i=n.attr("form"),o=i?e("#"+i):n.closest("form");o[0]&&(t._resetHandler=function(){setTimeout(function(){t.value(n[0].value),t.max(t._initialOptions.max),t.min(t._initialOptions.min)})},t._form=o.on("reset",t._resetHandler))}});a.plugin(L)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.filtermenu.min",["kendo.datepicker.min","kendo.numerictextbox.min","kendo.dropdownlist.min","kendo.binder.min"],e)}(function(){return function(e,t){function n(t,i){t.filters&&(t.filters=e.grep(t.filters,function(e){return n(e,i),e.filters?e.filters.length:e.field!=i}))}function i(e){var t,n,i,o,r,s;if(e&&e.length)for(s=[],t=0,n=e.length;t<n;t++)i=e[t],r=""!==i.text?i.text||i.value||i:i.text,o=null==i.value?i.text||i:i.value,s[t]={text:r,value:o};return s}function o(t,n){return e.grep(t,function(t){return t.filters?(t.filters=e.grep(t.filters,function(e){return e.field!=n}),t.filters.length):t.field!=n})}function r(t,n){t.filters&&(t.filters=e.grep(t.filters,function(e){return r(e,n),e.filters?e.filters.length:e.field==n&&"eq"==e.operator}))}function s(n){return"and"==n.logic&&n.filters.length>1?[]:n.filters?e.map(n.filters,function(e){return s(e)}):null!==n.value&&n.value!==t?[n.value]:[]}function a(e,n){for(var i,o,r=c.getter(n,!0),s=[],a=0,l={};a<e.length;)i=e[a++],o=r(i),o===t||null===o||l.hasOwnProperty(o)||(s.push(i),l[o]=!0);return s}function l(e,t){return function(n){var i=e(n);return a(i,t)}}var c=window.kendo,d=c.ui,u=e.proxy,h="kendoPopup",f="init",p="open",m="refresh",g="change",v=".kendoFilterMenu",_="Is equal to",b="Is not equal to",w={number:"numerictextbox",date:"datepicker"},y={string:"text",number:"number",date:"date"},k=c.isFunction,x=d.Widget,C='<div><div class="k-filter-help-text">#=messages.info#</div><label><input type="radio" data-#=ns#bind="checked: filters[0].value" value="true" name="filters[0].value"/>#=messages.isTrue#</label><label><input type="radio" data-#=ns#bind="checked: filters[0].value" value="false" name="filters[0].value"/>#=messages.isFalse#</label><div><button type="submit" class="k-button k-primary">#=messages.filter#</button><button type="reset" class="k-button">#=messages.clear#</button></div></div>',S='<div><div class="k-filter-help-text">#=messages.info#</div><select title="#=messages.operator#" data-#=ns#bind="value: filters[0].operator" data-#=ns#role="dropdownlist">#for(var op in operators){#<option value="#=op#">#=operators[op]#</option>#}#</select>#if(values){#<select title="#=messages.value#" data-#=ns#bind="value:filters[0].value" data-#=ns#text-field="text" data-#=ns#value-field="value" data-#=ns#source=\'#=kendo.stringify(values).replace(/\'/g,"&\\#39;")#\' data-#=ns#role="dropdownlist" data-#=ns#option-label="#=messages.selectValue#" data-#=ns#value-primitive="true"></select>#}else{#<input title="#=messages.value#" data-#=ns#bind="value:filters[0].value" class="k-textbox" type="text" #=role ? "data-" + ns + "role=\'" + role + "\'" : ""# />#}##if(extra){#<select title="#=messages.logic#" class="k-filter-and" data-#=ns#bind="value: logic" data-#=ns#role="dropdownlist"><option value="and">#=messages.and#</option><option value="or">#=messages.or#</option></select><select title="#=messages.additionalOperator#" data-#=ns#bind="value: filters[1].operator" data-#=ns#role="dropdownlist">#for(var op in operators){#<option value="#=op#">#=operators[op]#</option>#}#</select>#if(values){#<select title="#=messages.additionalValue#" data-#=ns#bind="value:filters[1].value" data-#=ns#text-field="text" data-#=ns#value-field="value" data-#=ns#source=\'#=kendo.stringify(values).replace(/\'/g,"&\\#39;")#\' data-#=ns#role="dropdownlist" data-#=ns#option-label="#=messages.selectValue#" data-#=ns#value-primitive="true"></select>#}else{#<input title="#=messages.additionalValue#" data-#=ns#bind="value: filters[1].value" class="k-textbox" type="text" #=role ? "data-" + ns + "role=\'" + role + "\'" : ""#/>#}##}#<div><button type="submit" class="k-button k-primary">#=messages.filter#</button><button type="reset" class="k-button">#=messages.clear#</button></div></div>',T='<div data-#=ns#role="view" data-#=ns#init-widgets="false" data-#=ns#use-native-scrolling="true" class="k-grid-filter-menu"><div data-#=ns#role="header" class="k-header"><button class="k-button k-i-cancel">#=messages.cancel#</button>#=title#<button type="submit" class="k-button k-submit">#=messages.filter#</button></div><form title="#=messages.info#" class="k-filter-menu k-mobile-list"><ul class="k-filter-help-text"><li><span class="k-link">#=messages.info#</span><ul><li class="k-item"><label class="k-label">#=messages.operator#<select data-#=ns#bind="value: filters[0].operator">#for(var op in operators){#<option value="#=op#">#=operators[op]#</option>#}#</select></label></li><li class="k-item"><label class="k-label">#=messages.value##if(values){#<select data-#=ns#bind="value:filters[0].value"><option value="">#=messages.selectValue#</option>#for(var val in values){#<option value="#=values[val].value#">#=values[val].text#</option>#}#</select>#}else{#<input data-#=ns#bind="value:filters[0].value" class="k-textbox" type="#=inputType#" #=useRole ? "data-" + ns + "role=\'" + role + "\'" : ""# />#}#</label></li>#if(extra){#</ul><ul class="k-filter-help-text"><li><span class="k-link"></span><li class="k-item"><label class="k-label"><input type="radio" name="logic" class="k-check" data-#=ns#bind="checked: logic" value="and" />#=messages.and#</label></li><li class="k-item"><label class="k-label"><input type="radio" name="logic" class="k-check" data-#=ns#bind="checked: logic" value="or" />#=messages.or#</label></li></ul><ul class="k-filter-help-text"><li><span class="k-link"></span><li class="k-item"><label class="k-label">#=messages.additionalOperator#<select data-#=ns#bind="value: filters[1].operator">#for(var op in operators){#<option value="#=op#">#=operators[op]#</option>#}#</select></label></li><li class="k-item"><label class="k-label">#=messages.additionalValue##if(values){#<select data-#=ns#bind="value:filters[1].value"><option value="">#=messages.selectValue#</option>#for(var val in values){#<option value="#=values[val].value#">#=values[val].text#</option>#}#</select>#}else{#<input data-#=ns#bind="value:filters[1].value" class="k-textbox" type="#=inputType#" #=useRole ? "data-" + ns + "role=\'" + role + "\'" : ""# />#}#</label></li>#}#</ul></li><li class="k-button-container"><button type="reset" class="k-button">#=messages.clear#</button></li></ul></div></form></div>',D='<div data-#=ns#role="view" data-#=ns#init-widgets="false" data-#=ns#use-native-scrolling="true" class="k-grid-filter-menu"><div data-#=ns#role="header" class="k-header"><button class="k-button k-i-cancel">#=messages.cancel#</button>#=title#<button type="submit" class="k-button k-submit">#=messages.filter#</button></div><form title="#=messages.info#" class="k-filter-menu k-mobile-list"><ul class="k-filter-help-text"><li><span class="k-link">#=messages.info#</span><ul><li class="k-item"><label class="k-label"><input class="k-check" type="radio" data-#=ns#bind="checked: filters[0].value" value="true" name="filters[0].value"/>#=messages.isTrue#</label></li><li class="k-item"><label class="k-label"><input class="k-check" type="radio" data-#=ns#bind="checked: filters[0].value" value="false" name="filters[0].value"/>#=messages.isFalse#</label></li></ul></li><li class="k-button-container"><button type="reset" class="k-button">#=messages.clear#</button></li></ul></form></div>',A=x.extend({init:function(t,n){var i,o,r,s,a=this,l="string";x.fn.init.call(a,t,n),i=a.operators=n.operators||{},t=a.element,n=a.options,n.appendToElement||(r=t.addClass("k-with-icon k-filterable").find(".k-grid-filter"),r[0]||(r=t.prepend('<a class="k-grid-filter" href="#" title="'+n.messages.filter+'" aria-label="'+n.messages.filter+'"><span class="k-icon k-i-filter"></span></a>').find(".k-grid-filter")),r.attr("tabindex",-1).on("click"+v,u(a._click,a))),a.link=r||e(),a.dataSource=M.create(n.dataSource),a.field=n.field||t.attr(c.attr("field")),a.model=a.dataSource.reader.model,a._parse=function(e){return null!=e?e+"":e},a.model&&a.model.fields&&(s=a.model.fields[a.field],s&&(l=s.type||"string",s.parse&&(a._parse=u(s.parse,s)))),n.values&&(l="enums"),a.type=l,i=i[l]||n.operators[l];for(o in i)break;a._defaultFilter=function(){return{field:a.field,operator:o||"eq",value:""}},a._refreshHandler=u(a.refresh,a),a.dataSource.bind(g,a._refreshHandler),n.appendToElement?a._init():a.refresh()},_init:function(){var t,n=this,i=n.options.ui,o=k(i);n.pane=n.options.pane,n.pane&&(n._isMobile=!0),o||(t=i||w[n.type]),n._isMobile?n._createMobileForm(t):n._createForm(t),n.form.on("submit"+v,u(n._submit,n)).on("reset"+v,u(n._reset,n)),o&&n.form.find(".k-textbox").removeClass("k-textbox").each(function(){i(e(this))}),n.form.find("["+c.attr("role")+"=numerictextbox]").removeClass("k-textbox").end().find("["+c.attr("role")+"=datetimepicker]").removeClass("k-textbox").end().find("["+c.attr("role")+"=timepicker]").removeClass("k-textbox").end().find("["+c.attr("role")+"=datepicker]").removeClass("k-textbox"),n.refresh(),n.trigger(f,{field:n.field,container:n.form}),c.cycleForm(n.form)},_createForm:function(t){var n=this,o=n.options,r=n.operators||{},s=n.type;r=r[s]||o.operators[s],n.form=e('<form title="'+n.options.messages.info+'" class="k-filter-menu"/>').html(c.template("boolean"===s?C:S)({field:n.field,format:o.format,ns:c.ns,messages:o.messages,extra:o.extra,operators:r,type:s,role:t,values:i(o.values)})),o.appendToElement?(n.element.append(n.form),n.popup=n.element.closest(".k-popup").data(h)):n.popup=n.form[h]({anchor:n.link,open:u(n._open,n),activate:u(n._activate,n),close:function(){n.options.closeCallback&&n.options.closeCallback(n.element)}}).data(h),n.form.on("keydown"+v,u(n._keydown,n))},_createMobileForm:function(t){var n=this,o=n.options,r=n.operators||{},s=n.type;r=r[s]||o.operators[s],n.form=e("<div />").html(c.template("boolean"===s?D:T)({field:n.field,title:o.title||n.field,format:o.format,ns:c.ns,messages:o.messages,extra:o.extra,operators:r,type:s,role:t,useRole:!c.support.input.date&&"date"===s||"number"===s,inputType:y[s],values:i(o.values)})),n.view=n.pane.append(n.form.html()),n.form=n.view.element.find("form"),n.view.element.on("click",".k-submit",function(e){n.form.submit(),e.preventDefault()}).on("click",".k-i-cancel",function(e){n._closeForm(),e.preventDefault()})},refresh:function(){var e=this,t=e.dataSource.filter()||{filters:[],logic:"and"},n=[e._defaultFilter()],i=e._defaultFilter().operator;(e.options.extra||"isnull"!==i&&"isnotnull"!==i)&&n.push(e._defaultFilter()),e.filterModel=c.observable({logic:"and",filters:n}),e.form&&c.bind(e.form.children().first(),e.filterModel),e._bind(t)?e.link.addClass("k-state-active"):e.link.removeClass("k-state-active")},destroy:function(){var e=this;x.fn.destroy.call(e),e.form&&(c.unbind(e.form),c.destroy(e.form),e.form.unbind(v),e.popup&&(e.popup.destroy(),e.popup=null),e.form=null),e.view&&(e.view.purge(),e.view=null),e.link.unbind(v),e._refreshHandler&&(e.dataSource.unbind(g,e._refreshHandler),e.dataSource=null),e.element=e.link=e._refreshHandler=e.filterModel=null},_bind:function(e){var t,n,i,o,r=this,s=e.filters,a=!1,l=0,c=r.filterModel;for(t=0,n=s.length;t<n;t++)o=s[t],o.field==r.field?(c.set("logic",e.logic),i=c.filters[l],i||(c.filters.push({field:r.field}),i=c.filters[l]),i.set("value",r._parse(o.value)),i.set("operator",o.operator),l++,a=!0):o.filters&&(a=a||r._bind(o));return a},_stripFilters:function(t){return e.grep(t,function(e){return""!==e.value&&null!=e.value||"isnull"===e.operator||"isnotnull"===e.operator||"isempty"===e.operator||"isnotempty"===e.operator})},_merge:function(e){var t,i,o,r=this,s=e.logic||"and",a=this._stripFilters(e.filters),l=r.dataSource.filter()||{filters:[],logic:"and"};for(n(l,r.field),i=0,o=a.length;i<o;i++)t=a[i],t.value=r._parse(t.value);return a.length&&(l.filters.length?(e.filters=a,"and"!==l.logic&&(l.filters=[{logic:l.logic,filters:l.filters}],l.logic="and"),l.filters.push(a.length>1?e:a[0])):(l.filters=a,l.logic=s)),l},filter:function(e){var t=this._stripFilters(e.filters);t.length&&this.trigger("change",{filter:{logic:e.logic,filters:t},field:this.field})||(e=this._merge(e),e.filters.length&&this.dataSource.filter(e))},clear:function(){var t=this,n=t.dataSource.filter()||{
filters:[]};this.trigger("change",{filter:null,field:t.field})||(n.filters=e.grep(n.filters,function(e){return e.filters?(e.filters=o(e.filters,t.field),e.filters.length):e.field!=t.field}),n.filters.length||(n=null),t.dataSource.filter(n))},_submit:function(e){e.preventDefault(),e.stopPropagation(),this.filter(this.filterModel.toJSON()),this._closeForm()},_reset:function(){this.clear(),this.options.search&&this.container&&this.container.find("label").parent().show(),this._closeForm()},_closeForm:function(){this._isMobile?this.pane.navigate("",this.options.animations.right):this.popup.close()},_click:function(e){e.preventDefault(),e.stopPropagation(),this.popup||this.pane||this._init(),this._isMobile?this.pane.navigate(this.view,this.options.animations.left):this.popup.toggle()},_open:function(){var t;e(".k-filter-menu").not(this.form).each(function(){t=e(this).data(h),t&&t.close()})},_activate:function(){this.form.find(":kendoFocusable:first").focus(),this.trigger(p,{field:this.field,container:this.form})},_keydown:function(e){e.keyCode==c.keys.ESC&&this.popup.close()},events:[f,"change",p],options:{name:"FilterMenu",extra:!0,appendToElement:!1,type:"string",operators:{string:{eq:_,neq:b,startswith:"Starts with",contains:"Contains",doesnotcontain:"Does not contain",endswith:"Ends with",isnull:"Is null",isnotnull:"Is not null",isempty:"Is empty",isnotempty:"Is not empty"},number:{eq:_,neq:b,gte:"Is greater than or equal to",gt:"Is greater than",lte:"Is less than or equal to",lt:"Is less than",isnull:"Is null",isnotnull:"Is not null"},date:{eq:_,neq:b,gte:"Is after or equal to",gt:"Is after",lte:"Is before or equal to",lt:"Is before",isnull:"Is null",isnotnull:"Is not null"},enums:{eq:_,neq:b,isnull:"Is null",isnotnull:"Is not null"}},messages:{info:"Show items with value that:",isTrue:"is true",isFalse:"is false",filter:"Filter",clear:"Clear",and:"And",or:"Or",selectValue:"-Select value-",operator:"Operator",value:"Value",additionalValue:"Additional value",additionalOperator:"Additional operator",logic:"Filters logic",cancel:"Cancel"},animations:{left:"slide",right:"slide:right"}}}),E=".kendoFilterMultiCheck",M=c.data.DataSource,I='<div data-#=ns#role="view" data-#=ns#init-widgets="false" class="k-grid-filter-menu"><div data-#=ns#role="header" class="k-header"><button class="k-button k-i-cancel">#=messages.cancel#</button>#=title#<button type="submit" class="k-button k-submit">#=messages.filter#</button></div><form class="k-filter-menu k-mobile-list">#if(search){#<div class=\'k-textbox k-space-right\'><input placeholder=\'#=messages.search#\'/><span class=\'k-icon k-i-zoom\' /></div>#}#<ul class="k-multicheck-wrap"></ul></li><li class="k-button-container">#if(messages.selectedItemsFormat){#<div class=\'k-filter-selected-items\'></div>#}#<button type="reset" class="k-button">#=messages.clear#</button></li></ul></form></div>',R=x.extend({init:function(t,n){var i,o;x.fn.init.call(this,t,n),n=this.options,this.element=e(t),i=this.field=this.options.field||this.element.attr(c.attr("field")),o=n.checkSource,this._foreignKeyValues()?(this.checkSource=M.create(n.values),this.checkSource.fetch()):n.forceUnique?(o=n.dataSource.options,delete o.pageSize,this.checkSource=M.create(o),this.checkSource.reader.data=l(this.checkSource.reader.data,this.field)):this.checkSource=M.create(o),this.dataSource=n.dataSource,this.model=this.dataSource.reader.model,this._parse=function(e){return e+""},this.model&&this.model.fields&&(i=this.model.fields[this.field],i&&("number"==i.type?this._parse=parseFloat:i.parse&&(this._parse=u(i.parse,i)),this.type=i.type||"string")),n.appendToElement?this._init():this._createLink(),this._refreshHandler=u(this.refresh,this),this.dataSource.bind(g,this._refreshHandler)},_createLink:function(){var e=this.element,t=e.addClass("k-with-icon k-filterable").find(".k-grid-filter");t[0]||(t=e.prepend('<a class="k-grid-filter" href="#" aria-label="'+this.options.messages.filter+'"><span class="k-icon k-i-filter"/></a>').find(".k-grid-filter")),this._link=t.attr("tabindex",-1).on("click"+v,u(this._click,this))},_init:function(){var e=this,t=this.options.forceUnique,n=this.options;this.pane=n.pane,this.pane&&(this._isMobile=!0),this._createForm(),this._foreignKeyValues()?this.refresh():t&&!this.checkSource.options.serverPaging&&this.dataSource.data().length?(this.checkSource.data(a(this.dataSource.data(),this.field)),this.refresh()):(this._attachProgress(),this.checkSource.fetch(function(){e.refresh.call(e)})),this.options.forceUnique||(this.checkChangeHandler=function(){e.container.empty(),e.refresh()},this.checkSource.bind(g,this.checkChangeHandler)),this.form.on("keydown"+E,u(this._keydown,this)).on("submit"+E,u(this._filter,this)).on("reset"+E,u(this._reset,this)),this.trigger(f,{field:this.field,container:this.form})},_attachProgress:function(){var e=this;this._progressHandler=function(){d.progress(e.container,!0)},this._progressHideHandler=function(){d.progress(e.container,!1)},this.checkSource.bind("progress",this._progressHandler).bind("change",this._progressHideHandler)},_input:function(){var e=this;e._clearTypingTimeout(),e._typingTimeout=setTimeout(function(){e.search()},100)},_clearTypingTimeout:function(){this._typingTimeout&&(clearTimeout(this._typingTimeout),this._typingTimeout=null)},search:function(){var e,t,n,i=this.options.ignoreCase,o=this.searchTextBox[0].value,r=this.container.find("label");for(i&&(o=o.toLowerCase()),e=0,this.options.checkAll&&r.length&&(r[0].parentNode.style.display=o?"none":"",e++);e<r.length;)t=r[e],n=t.textContent||t.innerText,i&&(n=n.toLowerCase()),t.parentNode.style.display=n.indexOf(o)>=0?"":"none",e++},_activate:function(){this.form.find(":kendoFocusable:first").focus(),this.trigger(p,{field:this.field,container:this.form})},_createForm:function(){var t,n,i=this.options,o="";this._isMobile||(i.search&&(o+="<div class='k-textbox k-space-right'><input placeholder='"+i.messages.search+"'/><span class='k-icon k-i-zoom' /></div>"),o+="<ul class='k-reset k-multicheck-wrap'></ul>",i.messages.selectedItemsFormat&&(o+="<div class='k-filter-selected-items'>"+c.format(i.messages.selectedItemsFormat,0)+"</div>"),o+="<button type='submit' class='k-button k-primary'>"+i.messages.filter+"</button>",o+="<button type='reset' class='k-button'>"+i.messages.clear+"</button>",this.form=e('<form class="k-filter-menu"/>').html(o),this.container=this.form.find(".k-multicheck-wrap")),this._isMobile?(t=this,t.form=e("<div />").html(c.template(I)({field:t.field,title:i.title||t.field,ns:c.ns,messages:i.messages,search:i.search})),t.view=t.pane.append(t.form.html()),t.form=t.view.element.find("form"),n=this.view.element,this.container=n.find(".k-multicheck-wrap"),n.on("click",".k-submit",function(e){t.form.submit(),e.preventDefault()}).on("click",".k-i-cancel",function(e){t._closeForm(),e.preventDefault()})):i.appendToElement?(this.popup=this.element.closest(".k-popup").data(h),this.element.append(this.form)):this.popup=this.form.kendoPopup({anchor:this._link,activate:u(this._activate,this)}).data(h),i.search&&(this.searchTextBox=this.form.find(".k-textbox > input"),this.searchTextBox.on("input",u(this._input,this)))},createCheckAllItem:function(){var t=this.options,n=c.template(t.itemTemplate({field:"all",mobile:this._isMobile})),i=e(n({all:t.messages.checkAll}));this.container.prepend(i),this.checkBoxAll=i.find(":checkbox").eq(0).addClass("k-check-all"),this.checkAllHandler=u(this.checkAll,this),this.checkBoxAll.on(g+E,this.checkAllHandler)},updateCheckAllState:function(){if(this.options.messages.selectedItemsFormat&&this.form.find(".k-filter-selected-items").text(c.format(this.options.messages.selectedItemsFormat,this.container.find(":checked:not(.k-check-all)").length)),this.checkBoxAll){var e=this.container.find(":checkbox:not(.k-check-all)").length==this.container.find(":checked:not(.k-check-all)").length;this.checkBoxAll.prop("checked",e)}},refresh:function(e){var t=this.options.forceUnique,n=this.dataSource,i=this.getFilterArray();this._link&&this._link.toggleClass("k-state-active",0!==i.length),this.form&&(e&&t&&e.sender===n&&!n.options.serverPaging&&("itemchange"==e.action||"add"==e.action||"remove"==e.action||n.options.autoSync&&"sync"===e.action)&&!this._foreignKeyValues()&&(this.checkSource.data(a(this.dataSource.data(),this.field)),this.container.empty()),this.container.is(":empty")&&this.createCheckBoxes(),this.checkValues(i),this.trigger(m))},getFilterArray:function(){var t,n=e.extend(!0,{},{filters:[],logic:"and"},this.dataSource.filter());return r(n,this.field),t=s(n)},createCheckBoxes:function(){var e,t,n,i=this.options,o={field:this.field,format:i.format,mobile:this._isMobile,type:this.type};this.options.forceUnique?this._foreignKeyValues()?(e=this.checkSource.data(),o.valueField="value",o.field="text"):e=this.checkSource.data():e=this.checkSource.view(),t=c.template(i.itemTemplate(o)),n=c.render(t,e),i.checkAll&&this.createCheckAllItem(),this.container.on(g+E,":checkbox",u(this.updateCheckAllState,this)),this.container.append(n)},checkAll:function(){var e=this.checkBoxAll.is(":checked");this.container.find(":checkbox").prop("checked",e)},checkValues:function(t){var n=this;e(e.grep(this.container.find(":checkbox").prop("checked",!1),function(i){var o,r,s=!1;if(!e(i).is(".k-check-all"))for(o=n._parse(e(i).val()),r=0;r<t.length;r++)if(s="date"==n.type?t[r].getTime()==o.getTime():t[r]==o)return s})).prop("checked",!0),this.updateCheckAllState()},_filter:function(t){var n,i;t.preventDefault(),t.stopPropagation(),n={logic:"or"},i=this,n.filters=e.map(this.form.find(":checkbox:checked:not(.k-check-all)"),function(t){return{value:e(t).val(),operator:"eq",field:i.field}}),n.filters.length&&this.trigger("change",{filter:n,field:i.field})||(n=this._merge(n),n.filters.length&&this.dataSource.filter(n),this._closeForm())},_stripFilters:function(t){return e.grep(t,function(e){return null!=e.value})},_foreignKeyValues:function(){var e=this.options;return e.values&&!e.checkSource},destroy:function(){var e=this;x.fn.destroy.call(e),e.form&&(c.unbind(e.form),c.destroy(e.form),e.form.unbind(E),e.popup&&(e.popup.destroy(),e.popup=null),e.form=null,e.container&&(e.container.unbind(E),e.container=null),e.checkBoxAll&&e.checkBoxAll.unbind(E)),e.view&&(e.view.purge(),e.view=null),e._link&&e._link.unbind(v),e._refreshHandler&&(e.dataSource.unbind(g,e._refreshHandler),e.dataSource=null),e.checkChangeHandler&&e.checkSource.unbind(g,e.checkChangeHandler),e._progressHandler&&e.checkSource.unbind("progress",e._progressHandler),e._progressHideHandler&&e.checkSource.unbind("change",e._progressHideHandler),this._clearTypingTimeout(),this.searchTextBox=null,e.element=e.checkSource=e.container=e.checkBoxAll=e._link=e._refreshHandler=e.checkAllHandler=null},options:{name:"FilterMultiCheck",itemTemplate:function(e){var n=e.field,i=e.format,o=e.valueField,r=e.mobile,s="";return o===t&&(o=n),"date"==e.type&&(s=":yyyy-MM-ddTHH:mm:sszzz"),"<li class='k-item'><label class='k-label'><input type='checkbox' class='"+(r?"k-check":"")+"'  value='#:kendo.format('{0"+s+"}',"+o+")#'/>#:kendo.format('"+(i?i:"{0}")+"', "+n+")#</label></li>"},checkAll:!0,search:!1,ignoreCase:!0,appendToElement:!1,messages:{checkAll:"Select All",clear:"Clear",filter:"Filter",search:"Search",cancel:"Cancel",selectedItemsFormat:"{0} items selected"},forceUnique:!0,animations:{left:"slide",right:"slide:right"}},events:[f,m,"change",p]});e.extend(R.fn,{_click:A.fn._click,_keydown:A.fn._keydown,_reset:A.fn._reset,_closeForm:A.fn._closeForm,clear:A.fn.clear,_merge:A.fn._merge}),d.plugin(A),d.plugin(R)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.menu.min",["kendo.popup.min"],e)}(function(){return function(e,t){function n(e,t){return e=e.split(" ")[!t+0]||e,e.replace("top","up").replace("bottom","down")}function i(e,t,n){e=e.split(" ")[!t+0]||e;var i={origin:["bottom",n?"right":"left"],position:["top",n?"right":"left"]},o=/left|right/.test(e);return o?(i.origin=["top",e],i.position[1]=C.directions[e].reverse):(i.origin[0]=e,i.position[0]=C.directions[e].reverse),i.origin=i.origin.join(" "),i.position=i.position.join(" "),i}function o(t,n){try{return e.contains(t,n)}catch(i){return!1}}function r(t){t=e(t),t.addClass("k-item").children(O).addClass(Y),t.children("a").addClass(W).children(O).addClass(Y),t.filter(":not([disabled])").addClass(me),t.filter(".k-separator").empty().append("&nbsp;"),t.filter("li[disabled]").addClass(_e).removeAttr("disabled").attr("aria-disabled",!0),t.filter("[role]").length||t.attr("role","menuitem"),t.children("."+W).length||t.contents().filter(function(){return!(this.nodeName.match(H)||3==this.nodeType&&!e.trim(this.nodeValue))}).wrapAll("<span class='"+W+"'/>"),s(t),l(t)}function s(t){t=e(t),t.find("> .k-link > [class*=k-i-arrow]:not(.k-sprite)").remove(),t.filter(":has(.k-menu-group)").children(".k-link:not(:has([class*=k-i-arrow]:not(.k-sprite)))").each(function(){var t=e(this),n=a(t);t.append("<span class='k-icon "+n+"'/>")})}function a(e){var t,n=e.parent().parent(),i=C.support.isRtl(n);return t=n.hasClass(U+"-horizontal")?" k-i-arrow-60-down":i?" k-i-arrow-60-left":" k-i-arrow-60-right"}function l(t){t=e(t),t.filter(".k-first:not(:first-child)").removeClass($),t.filter(".k-last:not(:last-child)").removeClass(q),t.filter(":first-child").addClass($),t.filter(":last-child").addClass(q)}function c(t,n){var i=u(n);i&&d(t,i),n.items&&e(t).children("ul").children("li").each(function(e){c(this,n.items[e])})}function d(t,n){e(t).children(".k-link").data({selectHandler:n})}function u(e){var t=e.select,n=C.isFunction;return t&&n(t)?t:null}function h(e){return e?"li[data-groupparent='"+e+"']":"li[data-groupparent]"}function f(e){return e?"ul[data-group='"+e+"']":"ul[data-group]"}function p(t,n){var i=t.find(h()),o=[];return i.each(function(i,r){var s,a;for(r=e(r),s=r.data(he),a=t;s;)a=n.find(f(s)+":visible"),a.length&&o.push(a),r=a.find(h()),s=r.data(he)}),o}function m(t,n){var i=t.data(ue);return i?n.find(h(i)):e([])}function g(t,n){var i=t.data(he);return i?n.children(ke).children(f(i)):e([])}function v(t,n){var i,o,r=[],s=function(e){for(;e.parentNode&&!n.is(e.parentNode);)r.push(e.parentNode),e=e.parentNode},a=t[0]||t;for(s(a),i=r[r.length-1];e(i).is(ke)&&(o=e(i).children("ul"),a=m(o,n)[0]);)r.push(a),s(a),i=r[r.length-1];return r}function _(e){var t=0;return e.wheelDelta&&(t=-e.wheelDelta/120,t=t>0?Math.ceil(t):Math.floor(t)),e.detail&&(t=Math.round(e.detail/3)),t}function b(e,t){for(var n=0,i=e.parentNode;i&&!isNaN(i[t]);)n+=i[t],i=i.parentNode;return n}function w(e){return ne&&e.originalEvent.pointerType in Fe}function y(e){var t=e.originalEvent;return D&&/touch/i.test(t.type||"")}function k(e){e.contents().filter(function(){return"LI"!=this.nodeName}).remove()}var x,C=window.kendo,S=C.ui,T=C._activeElement,D=C.support.touch&&C.support.mobileOS,A="mousedown",E="click",M=30,I=50,R=e.extend,F=e.proxy,z=e.each,P=C.template,B=C.keys,L=S.Widget,H=/^(ul|a|div)$/i,N=".kendoMenu",O="img",V="open",U="k-menu",W="k-link",q="k-last",j="close",G="timer",$="k-first",Y="k-image",K="select",Q="zIndex",X="activate",Z="deactivate",J="touchstart"+N+" MSPointerDown"+N+" pointerdown"+N,ee=C.support.pointers,te=C.support.msPointers,ne=te||ee,ie=ee?"pointerenter":te?"MSPointerEnter":"mouseenter",oe=ee?"pointerleave":te?"MSPointerLeave":"mouseleave",re="DOMMouseScroll"+N+" mousewheel"+N,se=C.support.resize+N,ae="scrollWidth",le="scrollHeight",ce="offsetWidth",de="offsetHeight",ue="group",he="groupparent",fe=e(document.documentElement),pe="kendoPopup",me="k-state-default",ge="k-state-hover",ve="k-state-focused",_e="k-state-disabled",be="k-state-selected",we=".k-menu",ye=".k-menu-group",ke=".k-animation-container",xe=ye+","+ke,Ce=":not(.k-list) > .k-item",Se=".k-item.k-state-disabled",Te=".k-item:not(.k-state-disabled)",De=".k-item:not(.k-state-disabled) > .k-link",Ae=":not(.k-item.k-separator)",Ee=Ae+":eq(0)",Me=Ae+":last",Ie="div:not(.k-animation-container,.k-list-container)",Re=".k-menu-scroll-button",Fe={2:1,touch:1},ze={content:P("<div #= contentCssAttributes(item) # tabindex='-1'>#= content(item) #</div>"),group:P("<ul class='#= groupCssClass(group) #'#= groupAttributes(group) # role='menu' aria-hidden='true'>#= renderItems(data) #</ul>"),itemWrapper:P("<#= tag(item) # class='#= textClass(item) #'#= textAttributes(item) #>#= image(data) ##= sprite(item) ##= text(item) ##= arrow(data) #</#= tag(item) #>"),item:P("<li class='#= wrapperCssClass(group, item) #' #= itemCssAttributes(item) # role='menuitem'  #=item.items ? \"aria-haspopup='true'\": \"\"##=item.enabled === false ? \"aria-disabled='true'\" : ''#>#= itemWrapper(data) ## if (item.items) { ##= subGroup({ items: item.items, menu: menu, group: { expanded: item.expanded } }) ## } else if (item.content || item.contentUrl) { ##= renderContent(data) ## } #</li>"),scrollButton:P("<span class='k-button k-button-icon k-menu-scroll-button k-scroll-#= direction #' unselectable='on'><span class='k-icon k-i-arrow-60-#= direction #'></span></span>"),image:P("<img #= imageCssAttributes(item) # alt='' src='#= item.imageUrl #' />"),arrow:P("<span class='#= arrowClass(item, group) #'></span>"),sprite:P("<span class='k-sprite #= spriteCssClass #'></span>"),empty:P("")},Pe={wrapperCssClass:function(e,t){var n="k-item",i=t.index;return n+=t.enabled===!1?" k-state-disabled":" k-state-default",e.firstLevel&&0===i&&(n+=" k-first"),i==e.length-1&&(n+=" k-last"),t.cssClass&&(n+=" "+t.cssClass),t.attr&&t.attr.hasOwnProperty("class")&&(n+=" "+t.attr["class"]),t.selected&&(n+=" "+be),n},itemCssAttributes:function(e){var t,n="",i=e.attr||{};for(t in i)i.hasOwnProperty(t)&&"class"!==t&&(n+=t+'="'+i[t]+'" ');return n},imageCssAttributes:function(e){var t,n="",i=e.imageAttr||{};i["class"]?i["class"]+=" "+Y:i["class"]=Y;for(t in i)i.hasOwnProperty(t)&&(n+=t+'="'+i[t]+'" ');return n},contentCssAttributes:function(e){var t,n="",i=e.contentAttr||{},o="k-content k-group k-menu-group";i["class"]?i["class"]+=" "+o:i["class"]=o;for(t in i)i.hasOwnProperty(t)&&(n+=t+'="'+i[t]+'" ');return n},textClass:function(){return W},textAttributes:function(e){return e.url?" href='"+e.url+"'":""},arrowClass:function(e,t){var n="k-icon";return n+=t.horizontal?" k-i-arrow-60-down":" k-i-arrow-60-right"},text:function(e){return e.encoded===!1?e.text:C.htmlEncode(e.text)},tag:function(e){return e.url?"a":"span"},groupAttributes:function(e){return e.expanded!==!0?" style='display:none'":""},groupCssClass:function(){return"k-group k-menu-group"},content:function(e){return e.content?e.content:"&nbsp;"}},Be=L.extend({init:function(e,t){var n=this;L.fn.init.call(n,e,t),e=n.wrapper=n.element,t=n.options,n._initData(t),n._updateClasses(),n._animations(t),n.nextItemZIndex=100,n._tabindex(),n._initOverflow(t),n._attachMenuEventsHandlers(),t.openOnClick&&(n.clicked=!1),e.attr("role","menubar"),e[0].id&&(n._ariaId=C.format("{0}_mn_active",e[0].id)),C.notify(n)},events:[V,j,X,Z,K],options:{name:"Menu",animation:{open:{duration:200},close:{duration:100}},orientation:"horizontal",direction:"default",openOnClick:!1,closeOnClick:!0,hoverDelay:100,scrollable:!1,popupCollision:t},_initData:function(e){var t=this;e.dataSource&&(t.angular("cleanup",function(){return{elements:t.element.children()}}),t.element.empty(),t.append(e.dataSource,t.element),t.angular("compile",function(){return{elements:t.element.children()}}))},_attachMenuEventsHandlers:function(){var t=this,n=t.element,i=t.options,o=t._overflowWrapper();(o||n).on(J,Te,F(t._focusHandler,t)).on(E+N,Se,!1).on(E+N,Te,F(t._click,t)).on(J+" "+A+N,".k-content",F(t._preventClose,t)).on(ie+N,Te,F(t._mouseenter,t)).on(oe+N,Te,F(t._mouseleave,t)).on(ie+N+" "+oe+N+" "+A+N+" "+E+N,De,F(t._toggleHover,t)),n.on("keydown"+N,F(t._keydown,t)).on("focus"+N,F(t._focus,t)).on("focus"+N,".k-content",F(t._focus,t)).on("blur"+N,F(t._removeHoverItem,t)).on("blur"+N,"[tabindex]",F(t._checkActiveElement,t)),o&&o.on(oe+N,xe,F(t._mouseleavePopup,t)).on(ie+N,xe,F(t._mouseenterPopup,t)),i.openOnClick&&(t._documentClickHandler=F(t._documentClick,t),e(document).click(t._documentClickHandler))},_detachMenuEventsHandlers:function(){var t=this,n=t._overflowWrapper();n&&n.off(N),t.element.off(N),t._documentClickHandler&&e(document).unbind("click",t._documentClickHandler)},_initOverflow:function(t){var n,i,o,r,s=this,a="horizontal"==t.orientation;t.scrollable&&(s._openedPopups={},s._scrollWrapper=s.element.wrap("<div class='k-menu-scroll-wrapper "+t.orientation+"'></div>").parent(),a&&k(s.element),n=e(ze.scrollButton({direction:a?"left":"up"})),i=e(ze.scrollButton({direction:a?"right":"down"})),n.add(i).appendTo(s._scrollWrapper),s._initScrolling(s.element,n,i,a),o=s.element.outerWidth(),r=s.element[0].style.width,r="auto"===r?"":r,a&&e(window).on(se,C.throttle(function(){s._setOverflowWrapperWidth(o,r),s._toggleScrollButtons(s.element,n,i,a)},100)),s._setOverflowWrapperWidth(o,r),s._toggleScrollButtons(s.element,n,i,a))},_overflowWrapper:function(){return this._scrollWrapper||this._popupsWrapper},_setOverflowWrapperWidth:function(e,t){var n,i,o,r,s=this,a=s._scrollWrapper.css("width");s._scrollWrapper.css({width:""}),n=s._scrollWrapper.outerWidth(),s._scrollWrapper.css({width:a}),i=s.element.outerWidth(),o=s.element[0].offsetWidth-s.element[0].clientWidth,i!=n&&(r=t?Math.min(e,n):n,s.element.width(r-o),s._scrollWrapper.width(r))},_reinitOverflow:function(e){var t=this,n=e.scrollable&&!t.options.scrollable||!e.scrollable&&t.options.scrollable||e.scrollable&&t.options.scrollable&&e.scrollable.distance!=t.options.scrollable.distance||e.orientation!=t.options.orientation;n&&(t._detachMenuEventsHandlers(),t._destroyOverflow(),t._initOverflow(e),t._attachMenuEventsHandlers())},_destroyOverflow:function(){var n=this,i=n._overflowWrapper();i&&(i.off(N),i.find(Re).off(N).remove(),i.children(ke).each(function(t,n){var o,r=e(n).children(ye);r.off(re),o=m(r,i),o.length&&o.append(n)}),i.find(h()).removeAttr("data-groupparent"),i.find(f()).removeAttr("data-group"),n.element.off(re),e(window).off(se),i.contents().unwrap(),n._scrollWrapper=n._popupsWrapper=n._openedPopups=t)},_initScrolling:function(t,n,i,o){var r=this,s=r.options.scrollable,a=e.isNumeric(s.distance)?s.distance:I,l=a/2,c="-="+a,d="+="+a,u="-="+2*a,h="+="+2*a,f=!1,p=!1,m=function(e){var s=o?{scrollLeft:e}:{scrollTop:e};t.finish().animate(s,"fast","linear",function(){f&&m(e)}),r._toggleScrollButtons(t,n,i,o)},g=function(e){f||p||(m(e.data.direction),f=!0)},v=function(s){var a=o?{scrollLeft:s.data.direction}:{scrollTop:s.data.direction};p=y(s)||w(s),t.stop().animate(a,"fast","linear",function(){p?(r._toggleScrollButtons(t,n,i,o),f=!0):e(s.currentTarget).trigger(ie)}),f=!1,s.stopPropagation(),s.preventDefault()};n.on(ie+N,{direction:c},g).on(C.eventMap.down+N,{direction:u},v),i.on(ie+N,{direction:d},g).on(C.eventMap.down+N,{direction:h},v),n.add(i).on(oe+N,function(){t.stop(),f=!1,r._toggleScrollButtons(t,n,i,o)}),t.on(re,function(e){var s,a,c,d;e.ctrlKey||e.shiftKey||e.altKey||(s=_(e.originalEvent),a=Math.abs(s)*l,c=(s>0?"+=":"-=")+a,d=o?{scrollLeft:c}:{scrollTop:c},r._closeChildPopups(t),t.finish().animate(d,"fast","linear",function(){r._toggleScrollButtons(t,n,i,o)}),e.preventDefault())})},_toggleScrollButtons:function(e,t,n,i){var o=i?e.scrollLeft():e.scrollTop(),r=i?ae:le,s=i?ce:de;t.toggle(0!==o),n.toggle(o<e[0][r]-e[0][s]-1)},setOptions:function(e){var t=this.options.animation;this._animations(e),e.animation=R(!0,t,e.animation),"dataSource"in e&&this._initData(e),this._updateClasses(),this._reinitOverflow(e),L.fn.setOptions.call(this,e)},destroy:function(){var e=this;L.fn.destroy.call(e),e._detachMenuEventsHandlers(),e._destroyOverflow(),C.destroy(e.element)},enable:function(e,t){return this._toggleDisabled(e,t!==!1),this},disable:function(e){return this._toggleDisabled(e,!1),this},append:function(e,t){t=this.element.find(t);var n=this._insert(e,t,t.length?t.find("> .k-menu-group, > .k-animation-container > .k-menu-group"):null);return z(n.items,function(t){n.group.append(this),s(this),c(this,e[t]||e)}),s(t),l(n.group.find(".k-first, .k-last").add(n.items)),this},insertBefore:function(e,t){t=this.element.find(t);var n=this._insert(e,t,t.parent());return z(n.items,function(n){t.before(this),s(this),l(this),c(this,e[n]||e)}),l(t),this},insertAfter:function(e,t){t=this.element.find(t);var n=this._insert(e,t,t.parent());return z(n.items,function(n){t.after(this),s(this),l(this),c(this,e[n]||e)}),l(t),this},_insert:function(t,n,i){var o,s,a,l,c=this;return n&&n.length||(i=c.element),a=e.isPlainObject(t),l={firstLevel:i.hasClass(U),horizontal:i.hasClass(U+"-horizontal"),expanded:!0,length:i.children().length},n&&!i.length&&(i=e(Be.renderGroup({group:l})).appendTo(n)),a||e.isArray(t)?o=e(e.map(a?[t]:t,function(t,n){return"string"==typeof t?e(t).get():e(Be.renderItem({group:l,item:R(t,{index:n})})).get()})):(o="string"==typeof t&&"<"!=t.charAt(0)?c.element.find(t):e(t),s=o.find("> ul").addClass("k-menu-group").attr("role","menu"),o=o.filter("li"),o.add(s.find("> li")).each(function(){r(this)})),{items:o,group:i}},remove:function(e){var t,n,i,o;return e=this.element.find(e),t=this,n=e.parentsUntil(t.element,Ce),i=e.parent("ul:not(.k-menu)"),e.remove(),i&&!i.children(Ce).length&&(o=i.parent(ke),o.length?o.remove():i.remove()),n.length&&(n=n.eq(0),s(n),l(n)),t},open:function(o){var r,s,a=this,l=a.options,c="horizontal"==l.orientation,d=l.direction,u=C.support.isRtl(a.wrapper),f=a._overflowWrapper();return o=(f||a.element).find(o),/^(top|bottom|default)$/.test(d)&&(d=u?c?(d+" left").replace("default","bottom"):"left":c?(d+" right").replace("default","bottom"):"right"),r=">.k-popup:visible,>.k-animation-container>.k-popup:visible",s=function(){var t=e(this).data(pe);t&&t.close(!0)},o.siblings().find(r).each(s),f&&o.find(r).each(s),o.each(function(){var o=e(this);clearTimeout(o.data(G)),o.data(G,setTimeout(function(){var r,s,p,m,g,v,_,b,w,y,k=o.find(".k-menu-group:first:hidden");!k[0]&&f&&(s=a._getPopup(o),k=s&&s.element),k.is(":visible")||k[0]&&a._triggerEvent({item:o[0],type:V})===!1&&(!k.find(".k-menu-group")[0]&&k.children(".k-item").length>1?(p=e(window).height(),m=function(){k.css({maxHeight:p-(C._outerHeight(k)-k.height())-C.getShadows(k).bottom,overflow:"auto"})},C.support.browser.msie&&C.support.browser.version<=7?setTimeout(m,0):m()):k.css({maxHeight:"",overflow:""}),o.data(Q,o.css(Q)),g=a.nextItemZIndex++,o.css(Q,g),a.options.scrollable&&o.parent().siblings(Re).css({zIndex:++g}),r=k.data(pe),v=o.parent().hasClass(U),_=v&&c,b=i(d,v,u),w=l.animation.open.effects,y=w!==t?w:"slideIn:"+n(d,v),r?(r=k.data(pe),r.options.origin=b.origin,r.options.position=b.position,r.options.animation.open.effects=y):r=k.kendoPopup({activate:function(){a._triggerEvent({item:this.wrapper.parent(),type:X})},deactivate:function(e){e.sender.element.removeData("targetTransform").css({opacity:""}),a._triggerEvent({item:this.wrapper.parent(),type:Z})},origin:b.origin,position:b.position,collision:l.popupCollision!==t?l.popupCollision:_?"fit":"fit flip",anchor:o,appendTo:f||o,animation:{open:R(!0,{effects:y},l.animation.open),close:l.animation.close},open:F(a._popupOpen,a),close:function(e){var t,n=e.sender.wrapper.parent();f&&(t=e.sender.element.data(ue),t&&(n=(f||a.element).find(h(t))),e.sender.wrapper.children(Re).hide()),a._triggerEvent({item:n[0],type:j})?e.preventDefault():(n.css(Q,n.data(Q)),n.removeData(Q),a.options.scrollable&&n.parent().siblings(Re).css({zIndex:""}),(D||ne)&&(n.removeClass(ge),a._removeHoverItem()))}}).data(pe),k.removeAttr("aria-hidden"),a._configurePopupOverflow(r,o),r.open(),a._initPopupScrolling(r))},a.options.hoverDelay))}),a},_configurePopupOverflow:function(e,t){var n,i=this;i.options.scrollable&&(i._wrapPopupElement(e),t.attr("data-groupparent")||(n=(new Date).getTime(),t.attr("data-groupparent",n),e.element.attr("data-group",n)))},_wrapPopupElement:function(e){e.element.parent().is(ke)||(e.wrapper=C.wrap(e.element,e.options.autosize).css({overflow:"hidden",display:"block",position:"absolute"}))},_initPopupScrolling:function(e,t,n){var i=this;i.options.scrollable&&e.element[0].scrollHeight>e.element[0].offsetHeight&&i._initPopupScrollButtons(e,t,n)},_initPopupScrollButtons:function(t,n,i){var o=this,r=t.wrapper.children(Re),s=o.options.animation,a=(s&&s.open&&s.open.duration||0)+M;setTimeout(function(){var s,a;r.length||(s=e(ze.scrollButton({direction:n?"left":"up"})),a=e(ze.scrollButton({direction:n?"right":"down"})),r=s.add(a).appendTo(t.wrapper),o._initScrolling(t.element,s,a,n),i||r.on(ie+N,function(){var n=o._overflowWrapper();e(p(t.element,n)).each(function(e,t){var i=n.find(h(t.data(ue)));o.close(i)})}).on(oe+N,function(){setTimeout(function(){e.isEmptyObject(o._openedPopups)&&o._closeParentPopups(t.element)},M)})),o._toggleScrollButtons(t.element,r.first(),r.last(),n)},a)},_popupOpen:function(e){e.sender.element.children("."+ve).removeClass(ve),this.options.scrollable&&this._setPopupHeight(e.sender)},_setPopupHeight:function(t,n){var i,o,r,s,a,l,c,d,u,h=t.element,f=h.add(h.parent(ke));f.height(h.hasClass(U)&&this._initialHeight||""),i=t._location(n),o=e(window).height(),r=i.height,s=n?0:Math.max(i.top,0),a=n?0:b(this._overflowWrapper()[0],"scrollTop"),l=window.innerHeight-o,c=o-C.getShadows(h).bottom+l,d=c+a>r+s,d||(u=Math.min(c,c-s+a),f.css({overflow:"hidden",height:u+"px"}))},close:function(t,n){var i,o,r=this,s=r._overflowWrapper(),a=s||r.element;return t=a.find(t),t.length||(t=a.find(">.k-item")),i=function(t){var n=!1;return e.isEmptyObject(r._openedPopups)?n:(e(p(t,s)).each(function(e,t){return n=!!r._openedPopups[""+t.data(ue)],!n}),n)},o=function(e){var t=e.data(he);return!s||!t||!r._openedPopups[""+t]},t.each(function(){var a=e(this);!n&&r._isRootItem(a)&&(r.clicked=!1),clearTimeout(a.data(G)),a.data(G,setTimeout(function(){var e=r._getPopup(a);if(e&&(o(a)||r._forceClose)){if(!r._forceClose&&i(e.element))return;e.close(),e.element.attr("aria-hidden",!0),s&&r._forceClose&&t.last().is(a[0])&&delete r._forceClose}},r.options.hoverDelay))}),r},_getPopup:function(e){var t,n,i=this,o=e.find(".k-menu-group:not(.k-list-container):not(.k-calendar-container):first:visible").data(pe),r=i._overflowWrapper();return!o&&r&&(t=e.data(he),t&&(n=r.find(f(t)),o=n.data(pe))),o},_toggleDisabled:function(t,n){this.element.find(t).each(function(){e(this).toggleClass(me,n).toggleClass(_e,!n).attr("aria-disabled",!n)})},_toggleHover:function(t){var n=e(C.eventTarget(t)||t.target).closest(Ce),i=t.type==ie||A.indexOf(t.type)!==-1;n.parents("li."+_e).length||n.toggleClass(ge,i||"mousedown"==t.type||"click"==t.type),this._removeHoverItem()},_preventClose:function(){this.options.closeOnClick||(this._closurePrevented=!0)},_checkActiveElement:function(t){var n=this,i=e(t?t.currentTarget:this._hoverItem()),r=n._findRootParent(i)[0];this._closurePrevented||setTimeout(function(){document.hasFocus()&&(o(r,C._activeElement())||!t||o(r,t.currentTarget))||n.close(r)},0),this._closurePrevented=!1},_removeHoverItem:function(){var e=this._hoverItem();e&&e.hasClass(ve)&&(e.removeClass(ve),this._oldHoverItem=null)},_updateClasses:function(){var e,t=this.element,n=".k-menu-init div ul";t.removeClass("k-menu-horizontal k-menu-vertical"),t.addClass("k-widget k-reset k-header k-menu-init "+U).addClass(U+"-"+this.options.orientation),t.find("li > ul").filter(function(){return!C.support.matchesSelector.call(this,n)}).addClass("k-group k-menu-group").attr("role","menu").attr("aria-hidden",t.is(":visible")).end().find("li > div").addClass("k-content").attr("tabindex","-1"),e=t.find("> li,.k-menu-group > li"),t.removeClass("k-menu-init"),e.each(function(){r(this)})},_mouseenter:function(t){var n=this,i=e(t.currentTarget),r=n._itemHasChildren(i),s=i.data(he)||i.parent().data(ue),a=w(t);s&&(n._openedPopups[""+s]=!0),t.delegateTarget!=i.parents(we)[0]&&t.delegateTarget!=i.parents(".k-menu-scroll-wrapper,.k-popups-wrapper")[0]||(n.options.openOnClick&&!n.clicked||D||a&&n._isRootItem(i.closest(Ce))||!o(t.currentTarget,t.relatedTarget)&&r&&n.open(i),
(n.options.openOnClick&&n.clicked||D)&&i.siblings().each(F(function(e,t){n.close(t,!0)},n)))},_mouseleave:function(n){var i=this,r=e(n.currentTarget),s=r.data(he),a=r.children(ke).length||r.children(ye).length||s,l=e(window);return s&&delete i._openedPopups[""+s],r.parentsUntil(ke,".k-list-container,.k-calendar-container")[0]?(n.stopImmediatePropagation(),t):i.options.openOnClick||D||w(n)||o(n.currentTarget,n.relatedTarget||n.target)||!a||o(n.currentTarget,C._activeElement())?((!n.toElement&&!n.relatedTarget||n.clientX<0||n.clientY<0||n.clientY>l.height()||n.clientX>l.width())&&i.close(r),t):(i.close(r),t)},_mouseenterPopup:function(t){var n,i=this,o=e(t.currentTarget);o.parent().is(ke)||(o=o.children("ul"),n=o.data(ue),n&&(i._openedPopups[""+n]=!0))},_mouseleavePopup:function(t){var n=this,i=e(t.currentTarget);!w(t)&&i.is(ke)&&n._closePopups(i.children("ul"))},_closePopups:function(t){var n,i=this,o=i._overflowWrapper(),r=t.data(ue);r&&(delete i._openedPopups[""+r],n=o.find(h(r)),setTimeout(function(){if(i.options.openOnClick)i._closeChildPopups(t);else if(e.isEmptyObject(i._openedPopups)){var o=i._innerPopup(t);i._closeParentPopups(o)}else i.close(n,!0)},0))},_closeChildPopups:function(t){var n=this,i=n._overflowWrapper();e(p(t,i)).each(function(){var e=i.find(h(this.data(ue)));n.close(e,!0)})},_innerPopup:function(e){var t=this._overflowWrapper(),n=p(e,t);return n[n.length-1]||e},_closeParentPopups:function(e){var t=this,n=t._overflowWrapper(),i=e.data(ue),o=n.find(h(i));for(i=o.parent().data(ue),t.close(o,!0);i&&!t._openedPopups[i]&&!o.parent().is(we);)o=n.find(h(i)),t.close(o,!0),i=o.parent().data(ue)},_click:function(n){for(var i,o,r,s,a,l,c=this,d=c.options,u=e(C.eventTarget(n)),h=u[0],p=u[0]?u[0].nodeName.toUpperCase():"",m="INPUT"==p||"SELECT"==p||"BUTTON"==p||"LABEL"==p,g=u.closest("."+W),v=u.closest(Ce),_=v[0],b=g.attr("href"),w=u.attr("href"),y=e("<a href='#' />").attr("href"),k=!!b&&b!==y,x=k&&!!b.match(/^#/),S=!!w&&w!==y,T=c._overflowWrapper();h&&h.parentNode!=_;)h=h.parentNode;if(!e(h).is(Ie)){if(v.hasClass(_e))return n.preventDefault(),t;if(n.handled||!c._triggerSelect(u,_)||m||n.preventDefault(),n.handled=!0,o=v.children(xe),T&&(a=v.data(he),a&&(o=T.find(f(a)))),r=o.is(":visible"),s=d.openOnClick&&r&&c._isRootItem(v),d.closeOnClick&&(!k||x)&&(!o.length||s))return v.removeClass(ge).css("height"),c._oldHoverItem=c._findRootParent(v),l=c._parentsUntil(g,c.element,Ce),c._forceClose=!!T,c.close(l),c.clicked=!1,"MSPointerUp".indexOf(n.type)!=-1&&n.preventDefault(),t;k&&n.enterKey&&g[0].click(),(c._isRootItem(v)&&d.openOnClick||C.support.touch||ne&&c._isRootItem(v.closest(Ce)))&&(k||m||S||n.preventDefault(),c.clicked=!0,i=o.is(":visible")?j:V,(d.closeOnClick||i!=j)&&c[i](v))}},_parentsUntil:function(n,i,o){var r,s,a=this._overflowWrapper();return a?(r=v(n,a),s=[],e(r).each(function(){var n=e(this);return!n.is(i)&&(n.is(o)&&s.push(this),t)}),e(s)):n.parentsUntil(i,o)},_triggerSelect:function(e,t){var n,i,o,r=e.data("selectHandler");return r&&(n=this._getEventData(e),r.call(this,n)),i=n&&n.isDefaultPrevented(),o=this._triggerEvent({item:t,type:K}),i||o},_getEventData:function(e){var t={sender:this,target:e,_defaultPrevented:!1,preventDefault:function(){this._defaultPrevented=!0},isDefaultPrevented:function(){return this._defaultPrevented}};return t},_documentClick:function(e){var t=this;o((t._overflowWrapper()||t.element)[0],e.target)||(t.clicked=!1)},_focus:function(n){var i=this,o=n.target,r=i._hoverItem(),s=T();return o==i.wrapper[0]||e(o).is(":kendoFocusable")?(s===n.currentTarget&&(r.length?i._moveHover([],r):i._oldHoverItem||i._moveHover([],i.wrapper.children().first())),t):(n.stopPropagation(),e(o).closest(".k-content").closest(".k-menu-group").closest(".k-item").addClass(ve),i.wrapper.focus(),t)},_keydown:function(e){var n,i,o,r=this,s=e.keyCode,a=r._oldHoverItem,l=C.support.isRtl(r.wrapper);if(e.target==e.currentTarget||s==B.ESC){if(a||(a=r._oldHoverItem=r._hoverItem()),i=r._itemBelongsToVertival(a),o=r._itemHasChildren(a),s==B.RIGHT)n=r[l?"_itemLeft":"_itemRight"](a,i,o);else if(s==B.LEFT)n=r[l?"_itemRight":"_itemLeft"](a,i,o);else if(s==B.DOWN)n=r._itemDown(a,i,o);else if(s==B.UP)n=r._itemUp(a,i,o);else if(s==B.ESC)n=r._itemEsc(a,i);else if(s==B.ENTER||s==B.SPACEBAR)n=a.children(".k-link"),n.length>0&&(r._click({target:n[0],preventDefault:function(){},enterKey:!0}),r._moveHover(a,r._findRootParent(a)));else if(s==B.TAB)return n=r._findRootParent(a),r._moveHover(a,n),r._checkActiveElement(),t;n&&n[0]&&(e.preventDefault(),e.stopPropagation())}},_hoverItem:function(){return this.wrapper.find(".k-item.k-state-hover,.k-item.k-state-focused").filter(":visible")},_itemBelongsToVertival:function(e){var t=this.wrapper.hasClass("k-menu-vertical");return e.length?e.parent().hasClass("k-menu-group")||t:t},_itemHasChildren:function(e){return!!(e&&e.length&&e[0].nodeType)&&(e.children("ul.k-menu-group, div.k-animation-container").length>0||!!e.data(he)&&!!this._overflowWrapper().children(f(e.data(he))))},_moveHover:function(t,n){var i=this,o=i._ariaId;t.length&&n.length&&t.removeClass(ve),n.length&&(n[0].id&&(o=n[0].id),n.addClass(ve),i._oldHoverItem=n,o&&(i.element.removeAttr("aria-activedescendant"),e("#"+o).removeAttr("id"),n.attr("id",o),i.element.attr("aria-activedescendant",o)),i._scrollToItem(n))},_findRootParent:function(e){return this._isRootItem(e)?e:this._parentsUntil(e,we,"li.k-item").last()},_isRootItem:function(e){return e.parent().hasClass(U)},_itemRight:function(e,t,n){var i,o,r,s,a=this;if(!e.hasClass(_e))return t?n?(a.open(e),i=a._childPopupElement(e).children().first()):"horizontal"==a.options.orientation&&(o=a._findRootParent(e),r=a._overflowWrapper(),r&&(s=g(o,r),a._closeChildPopups(s)),a.close(o),i=o.nextAll(Ee)):(i=e.nextAll(Ee),i.length||(i=e.prevAll(Me))),i&&!i.length?i=a.wrapper.children(".k-item").first():i||(i=[]),a._moveHover(e,i),i},_itemLeft:function(e,t){var n,i,o=this;return t?(n=e.parent().closest(".k-item"),i=o._overflowWrapper(),!n.length&&i&&(n=m(e.parent(),i)),o.close(n),o._isRootItem(n)&&"horizontal"==o.options.orientation&&(n=n.prevAll(Ee))):(n=e.prevAll(Ee),n.length||(n=e.nextAll(Me))),n.length||(n=o.wrapper.children(".k-item").last()),o._moveHover(e,n),n},_itemDown:function(e,t,n){var i,o=this;if(t)i=e.nextAll(Ee);else{if(!n||e.hasClass(_e))return;o.open(e),i=o._childPopupElement(e).children().first()}return!i.length&&e.length?i=e.parent().children().first():e.length||(i=o.wrapper.children(".k-item").first()),o._moveHover(e,i),i},_itemUp:function(e,t){var n,i=this;if(t)return n=e.prevAll(Ee),!n.length&&e.length?n=e.parent().children().last():e.length||(n=i.wrapper.children(".k-item").last()),i._moveHover(e,n),n},_scrollToItem:function(e){var t,n,i,o,r,s,a,l,c,d,u,h,f=this;f.options.scrollable&&e&&e.length&&(t=e.parent(),n=!!t.hasClass(U)&&"horizontal"==f.options.orientation,i=n?"scrollLeft":"scrollTop",o=n?C._outerWidth:C._outerHeight,r=t[i](),s=o(e),a=e[0][n?"offsetLeft":"offsetTop"],l=o(t),c=t.siblings(Re),d=c.length?o(c.first()):0,r+l<a+s+d?u=a+s-l+d:r>a-d&&(u=a-d),isNaN(u)||(h={},h[i]=u,t.finish().animate(h,"fast","linear",function(){f._toggleScrollButtons(t,c.first(),c.last(),n)})))},_itemEsc:function(e,t){var n,i=this;return t?(n=e.parent().closest(".k-item"),i.close(n),i._moveHover(e,n),n):e},_childPopupElement:function(e){var t=e.find(".k-menu-group"),n=this._overflowWrapper();return!t.length&&n&&(t=g(e,n)),t},_triggerEvent:function(e){var t=this;return t.trigger(e.type,{type:e.type,item:e.item})},_focusHandler:function(t){var n=this,i=e(C.eventTarget(t)).closest(Ce);i.hasClass(_e)||setTimeout(function(){n._moveHover([],i),i.children(".k-content")[0]&&i.parent().closest(".k-item").removeClass(ve)},200)},_animations:function(e){e&&"animation"in e&&!e.animation&&(e.animation={open:{effects:{}},close:{hide:!0,effects:{}}})}});R(Be,{renderItem:function(e){e=R({menu:{},group:{}},e);var t=ze.empty,n=e.item;return ze.item(R(e,{image:n.imageUrl?ze.image:t,sprite:n.spriteCssClass?ze.sprite:t,itemWrapper:ze.itemWrapper,renderContent:Be.renderContent,arrow:n.items||n.content?ze.arrow:t,subGroup:Be.renderGroup},Pe))},renderGroup:function(e){return ze.group(R({renderItems:function(e){for(var t="",n=0,i=e.items,o=i?i.length:0,r=R({length:o},e.group);n<o;n++)t+=Be.renderItem(R(e,{group:r,item:R({index:n},i[n])}));return t}},e,Pe))},renderContent:function(e){return ze.content(R(e,Pe))}}),x=Be.extend({init:function(t,n){var i=this;Be.fn.init.call(i,t,n),i._marker=C.guid().substring(0,8),i.target=e(i.options.target),i._popup(),i._wire()},_initOverflow:function(e){var t=this;e.scrollable&&!t._overflowWrapper()&&(t._openedPopups={},t._popupsWrapper=(t.element.parent().is(ke)?t.element.parent():t.element).wrap("<div class='k-popups-wrapper "+e.orientation+"'></div>").parent(),"horizontal"==t.options.orientation&&k(t.element),e.appendTo&&e.appendTo.append(t._popupsWrapper),t._initialHeight=t.element[0].style.height,t._initialWidth=t.element[0].style.width)},options:{name:"ContextMenu",filter:null,showOn:"contextmenu",orientation:"vertical",alignToAnchor:!1,target:"body"},events:[V,j,X,Z,K],setOptions:function(t){var n=this;Be.fn.setOptions.call(n,t),n.target.off(n.showOn+N+n._marker,n._showProxy),n.userEvents&&n.userEvents.destroy(),n.target=e(n.options.target),t.orientation&&n.popup.wrapper[0]&&n.popup.element.unwrap(),n._wire(),Be.fn.setOptions.call(this,t)},destroy:function(){var e=this;e.target.off(e.options.showOn+N+e._marker),fe.off(C.support.mousedown+N+e._marker,e._closeProxy),e.userEvents&&e.userEvents.destroy(),Be.fn.destroy.call(e)},open:function(n,i){var r,s,a=this;return n=e(n)[0],o(a.element[0],e(n)[0])||a._itemHasChildren(e(n))?Be.fn.open.call(a,n):a._triggerEvent({item:a.element,type:V})===!1&&(a.popup.visible()&&a.options.filter&&(a.popup.close(!0),a.popup.element.kendoStop(!0)),i!==t?(r=a._overflowWrapper(),r&&(s=r.offset(),n-=s.left,i-=s.top),a.popup.wrapper.hide(),a._configurePopupScrolling(n,i),a.popup.open(n,i)):(a.popup.options.anchor=(n?n:a.popup.anchor)||a.target,a.popup.element.kendoStop(!0),a._configurePopupScrolling(),a.popup.open()),fe.off(a.popup.downEvent,a.popup._mousedownProxy),fe.on(C.support.mousedown+N+a._marker,a._closeProxy)),a},_configurePopupScrolling:function(e,n){var i=this,o=i.popup,r="horizontal"==i.options.orientation;i.options.scrollable&&(i._wrapPopupElement(o),o.element.parent().css({position:"",height:""}),o.element.css({visibility:"hidden",display:"",position:""}),r?i._setPopupWidth(o,isNaN(e)?t:{isFixed:!0,x:e,y:n}):i._setPopupHeight(o,isNaN(e)?t:{isFixed:!0,x:e,y:n}),o.element.css({visibility:"",display:"none",position:"absolute"}),i._initPopupScrollButtons(o,r,!0),o.element.siblings(Re).hide())},_setPopupWidth:function(t,n){var i,o,r,s,a,l,c,d,u=t.element,h=u.add(u.parent(ke));h.width(this._initialWidth||""),i=t._location(n),o=e(window).width(),r=i.width,s=Math.max(i.left,0),a=n?0:b(this._overflowWrapper()[0],"scrollLeft"),l=C.getShadows(u),c=o-l.left-l.right,d=c+a>r+s,d||h.css({overflow:"hidden",width:c-s+a+"px"})},close:function(){var t=this;o(t.element[0],e(arguments[0])[0])||t._itemHasChildren(arguments[0])?Be.fn.close.call(t,arguments[0]):t.popup.visible()&&t._triggerEvent({item:t.element,type:j})===!1&&(t.popup.close(),fe.off(C.support.mousedown+N,t._closeProxy),t.unbind(K,t._closeTimeoutProxy))},_showHandler:function(e){var t,n=e,i=this,r=i.options;e.event&&(n=e.event,n.pageX=e.x.location,n.pageY=e.y.location),o(i.element[0],e.relatedTarget||e.target)||(i._eventOrigin=n,n.preventDefault(),n.stopImmediatePropagation(),i.element.find("."+ve).removeClass(ve),(r.filter&&C.support.matchesSelector.call(n.currentTarget,r.filter)||!r.filter)&&(r.alignToAnchor?(i.popup.options.anchor=n.currentTarget,i.open(n.currentTarget)):(i.popup.options.anchor=n.currentTarget,i._targetChild?(t=i.target.offset(),i.open(n.pageX-t.left,n.pageY-t.top)):i.open(n.pageX,n.pageY))))},_closeHandler:function(t){var n,i=this,r=e(t.relatedTarget||t.target),s=r.closest(i.target.selector)[0]==i.target[0],a=r.closest(Te),l=i._itemHasChildren(a),c=i._overflowWrapper(),d=o(i.element[0],r[0])||c&&o(c[0],r[0]);i._eventOrigin=t,n=3!==t.which,i.popup.visible()&&(n&&s||!s)&&(i.options.closeOnClick&&!l&&d||!d)&&(d?(this.unbind(K,this._closeTimeoutProxy),i.bind(K,i._closeTimeoutProxy)):i.close())},_wire:function(){var e=this,t=e.options,n=e.target;e._showProxy=F(e._showHandler,e),e._closeProxy=F(e._closeHandler,e),e._closeTimeoutProxy=F(e.close,e),n[0]&&(C.support.mobileOS&&"contextmenu"==t.showOn?(e.userEvents=new C.UserEvents(n,{filter:t.filter,allowSelection:!1}),n.on(t.showOn+N+e._marker,!1),e.userEvents.bind("hold",e._showProxy)):t.filter?n.on(t.showOn+N+e._marker,t.filter,e._showProxy):n.on(t.showOn+N+e._marker,e._showProxy))},_triggerEvent:function(n){var i=this,o=e(i.popup.options.anchor)[0],r=i._eventOrigin;return i._eventOrigin=t,i.trigger(n.type,R({type:n.type,item:n.item||this.element[0],target:o},r?{event:r}:{}))},_popup:function(){var t=this,n=t._overflowWrapper();t._triggerProxy=F(t._triggerEvent,t),t.popup=t.element.addClass("k-context-menu").kendoPopup({anchor:t.target||"body",copyAnchorStyles:t.options.copyAnchorStyles,collision:t.options.popupCollision||"fit",animation:t.options.animation,activate:t._triggerProxy,deactivate:t._triggerProxy,appendTo:n||t.options.appendTo,close:n?function(t){e(p(t.sender.element,n)).each(function(e,t){var n=t.data(pe);n&&n.close(!0)})}:e.noop}).data(pe),t._targetChild=o(t.target[0],t.popup.element[0])}}),S.plugin(Be),S.plugin(x)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.columnmenu.min",["kendo.popup.min","kendo.filtermenu.min","kendo.menu.min"],e)}(function(){return function(e,t){function n(t){return e.trim(t).replace(/&nbsp;/gi,"")}function i(e,t){var n,i,o,r={};for(n=0,i=e.length;n<i;n++)o=e[n],r[o[t]]=o;return r}function o(e){var t,n=[];for(t=0;t<e.length;t++)e[t].columns?n=n.concat(o(e[t].columns)):n.push(e[t]);return n}var r=window.kendo,s=r.ui,a=e.proxy,l=e.extend,c=e.grep,d=e.map,u=e.inArray,h="k-state-selected",f="asc",p="desc",m="change",g="init",v="open",_="select",b="kendoPopup",w="kendoFilterMenu",y="kendoMenu",k=".kendoColumnMenu",x=s.Widget,C=x.extend({init:function(t,n){var i,o=this;x.fn.init.call(o,t,n),t=o.element,n=o.options,o.owner=n.owner,o.dataSource=n.dataSource,o.field=t.attr(r.attr("field")),o.title=t.attr(r.attr("title")),i=t.find(".k-header-column-menu"),i[0]||(i=t.addClass("k-with-icon").prepend('<a class="k-header-column-menu" href="#" title="'+n.messages.settings+'" aria-label="'+n.messages.settings+'"><span class="k-icon k-i-more-vertical"></span></a>').find(".k-header-column-menu")),o.link=i.attr("tabindex",-1).on("click"+k,a(o._click,o)),o.wrapper=e('<div class="k-column-menu"/>'),o._refreshHandler=a(o.refresh,o),o.dataSource.bind(m,o._refreshHandler)},_init:function(){var e=this;e.pane=e.options.pane,e.pane&&(e._isMobile=!0),e._isMobile?e._createMobileMenu():e._createMenu(),e.owner._muteAngularRebind(function(){e._angularItems("compile")}),e._sort(),e._columns(),e._filter(),e._lockColumns(),e.trigger(g,{field:e.field,container:e.wrapper})},events:[g,v,"sort","filtering"],options:{name:"ColumnMenu",messages:{sortAscending:"Sort Ascending",sortDescending:"Sort Descending",filter:"Filter",columns:"Columns",done:"Done",settings:"Column Settings",lock:"Lock",unlock:"Unlock"},filter:"",columns:!0,sortable:!0,filterable:!0,animations:{left:"slide"}},_createMenu:function(){var e=this,t=e.options;e.wrapper.html(r.template(S)({uid:r.guid(),ns:r.ns,messages:t.messages,sortable:t.sortable,filterable:t.filterable,columns:e._ownerColumns(),showColumns:t.columns,lockedColumns:t.lockedColumns})),e.popup=e.wrapper[b]({anchor:e.link,open:a(e._open,e),activate:a(e._activate,e),close:function(){e.options.closeCallback&&e.options.closeCallback(e.element)}}).data(b),e.menu=e.wrapper.children()[y]({orientation:"vertical",closeOnClick:!1}).data(y)},_createMobileMenu:function(){var e=this,t=e.options,n=r.template(T)({ns:r.ns,field:e.field,title:e.title||e.field,messages:t.messages,sortable:t.sortable,filterable:t.filterable,columns:e._ownerColumns(),showColumns:t.columns,lockedColumns:t.lockedColumns});e.view=e.pane.append(n),e.wrapper=e.view.element.find(".k-column-menu"),e.menu=new D(e.wrapper.children(),{pane:e.pane}),e.view.element.on("click",".k-done",function(t){e.close(),t.preventDefault()}),e.options.lockedColumns&&e.view.bind("show",function(){e._updateLockedColumns()})},_angularItems:function(t){var n=this;n.angular(t,function(){var t=n.wrapper.find(".k-columns-item input["+r.attr("field")+"]").map(function(){return e(this).closest("li")}),i=d(n._ownerColumns(),function(e){return{column:e._originalObject}});return{elements:t,data:i}})},destroy:function(){var e=this;e._angularItems("cleanup"),x.fn.destroy.call(e),e.filterMenu&&e.filterMenu.destroy(),e._refreshHandler&&e.dataSource.unbind(m,e._refreshHandler),e.options.columns&&e.owner&&(e._updateColumnsMenuHandler&&(e.owner.unbind("columnShow",e._updateColumnsMenuHandler),e.owner.unbind("columnHide",e._updateColumnsMenuHandler)),e._updateColumnsLockedStateHandler&&(e.owner.unbind("columnLock",e._updateColumnsLockedStateHandler),e.owner.unbind("columnUnlock",e._updateColumnsLockedStateHandler))),e.menu&&(e.menu.element.off(k),e.menu.destroy()),e.wrapper.off(k),e.popup&&e.popup.destroy(),e.view&&e.view.purge(),e.link.off(k),e.owner=null,e.wrapper=null,e.element=null},close:function(){this.menu.close(),this.popup&&(this.popup.close(),this.popup.element.off("keydown"+k))},_click:function(e){e.preventDefault(),e.stopPropagation();var t=this.options;t.filter&&this.element.is(!t.filter)||(this.popup||this.pane||this._init(),this._isMobile?this.pane.navigate(this.view,this.options.animations.left):this.popup.toggle())},_open:function(){var t=this;e(".k-column-menu").not(t.wrapper).each(function(){e(this).data(b).close()}),t.popup.element.on("keydown"+k,function(e){e.keyCode==r.keys.ESC&&t.close()}),t.options.lockedColumns&&t._updateLockedColumns()},_activate:function(){this.menu.element.focus(),this.trigger(v,{field:this.field,container:this.wrapper})},_ownerColumns:function(){var e=o(this.owner.columns),t=c(e,function(e){var t=!0,i=n(e.title||"");return e.menu!==!1&&(e.field||i.length)||(t=!1),t});return d(t,function(t){return{originalField:t.field,field:t.field||t.title,title:t.title||t.field,hidden:t.hidden,index:u(t,e),locked:!!t.locked,_originalObject:t}})},_sort:function(){var t=this;t.options.sortable&&(t.refresh(),t.menu.bind(_,function(n){var i,o=e(n.item);o.hasClass("k-sort-asc")?i=f:o.hasClass("k-sort-desc")&&(i=p),i&&(o.parent().find(".k-sort-"+(i==f?p:f)).removeClass(h),t._sortDataSource(o,i),t.close())}))},_sortDataSource:function(e,n){var i,o,r=this,s=r.options.sortable,a=null===s.compare?t:s.compare,l=r.dataSource,c=l.sort()||[],d=e.hasClass(h)&&s&&s.allowUnsort!==!1;if(n=d?t:n,!r.trigger("sort",{sort:{field:r.field,dir:n,compare:a}})){if(d?e.removeClass(h):e.addClass(h),"multiple"===s.mode){for(i=0,o=c.length;i<o;i++)if(c[i].field===r.field){c.splice(i,1);break}c.push({field:r.field,dir:n,compare:a})}else c=[{field:r.field,dir:n,compare:a}];l.sort(c)}},_columns:function(){var t=this;t.options.columns&&(t._updateColumnsMenu(),t._updateColumnsMenuHandler=a(t._updateColumnsMenu,t),t.owner.bind(["columnHide","columnShow"],t._updateColumnsMenuHandler),t._updateColumnsLockedStateHandler=a(t._updateColumnsLockedState,t),t.owner.bind(["columnUnlock","columnLock"],t._updateColumnsLockedStateHandler),t.menu.bind(_,function(n){var i,s,a,l=e(n.item),d=o(t.owner.columns);t._isMobile&&n.preventDefault(),l.parent().closest("li.k-columns-item")[0]&&(i=l.find(":checkbox"),i.attr("disabled")||(a=i.attr(r.attr("field")),s=c(d,function(e){return e.field==a||e.title==a})[0],s.hidden===!0?t.owner.showColumn(s):t.owner.hideColumn(s)))}))},_updateColumnsMenu:function(){var e,t,n,i,o,s,a=r.attr("field"),l=r.attr("locked"),h=c(this._ownerColumns(),function(e){return!e.hidden}),f=c(h,function(e){return e.originalField}),p=c(f,function(e){return e.locked===!0}).length,m=c(f,function(e){return e.locked!==!0}).length;for(h=d(h,function(e){return e.field}),this.wrapper.find("[role='menuitemcheckbox']").attr("aria-checked",!1),s=this.wrapper.find(".k-columns-item input["+a+"]").prop("disabled",!1).prop("checked",!1),e=0,t=s.length;e<t;e++)n=s.eq(e),o="true"===n.attr(l),i=!1,u(n.attr(a),h)>-1&&(i=!0,n.prop("checked",i)),n.closest("[role='menuitemcheckbox']").attr("aria-checked",i),i&&(1==p&&o&&n.prop("disabled",!0),1!=m||o||n.prop("disabled",!0))},_updateColumnsLockedState:function(){var e,t,n,o,s=r.attr("field"),a=r.attr("locked"),l=i(this._ownerColumns(),"field"),c=this.wrapper.find(".k-columns-item input[type=checkbox]");for(e=0,t=c.length;e<t;e++)n=c.eq(e),o=l[n.attr(s)],o&&n.attr(a,o.locked);this._updateColumnsMenu()},_filter:function(){var t=this,n=w,i=t.options;i.filterable!==!1&&(i.filterable.multi&&(n="kendoFilterMultiCheck",i.filterable.dataSource&&(i.filterable.checkSource=i.filterable.dataSource,delete i.filterable.dataSource)),t.filterMenu=t.wrapper.find(".k-filterable")[n](l(!0,{},{appendToElement:!0,dataSource:i.dataSource,values:i.values,field:t.field,title:t.title,change:function(e){t.trigger("filtering",{filter:e.filter,field:e.field})&&e.preventDefault()}},i.filterable)).data(n),t._isMobile&&t.menu.bind(_,function(n){var i=e(n.item);i.hasClass("k-filter-item")&&t.pane.navigate(t.filterMenu.view,t.options.animations.left)}))},_lockColumns:function(){var t=this;t.menu.bind(_,function(n){var i=e(n.item);i.hasClass("k-lock")?(t.owner.lockColumn(t.field),t.close()):i.hasClass("k-unlock")&&(t.owner.unlockColumn(t.field),t.close())})},_updateLockedColumns:function(){var e,t,n,i,o=this.field,r=this.owner.columns,s=c(r,function(e){return e.field==o||e.title==o})[0];s&&(e=s.locked===!0,t=c(r,function(t){return!t.hidden&&(t.locked&&e||!t.locked&&!e)}).length,n=this.wrapper.find(".k-lock").removeClass("k-state-disabled"),i=this.wrapper.find(".k-unlock").removeClass("k-state-disabled"),(e||1==t)&&n.addClass("k-state-disabled"),e&&1!=t||i.addClass("k-state-disabled"),this._updateColumnsLockedState())},refresh:function(){var e,t,n,i=this,o=i.options.dataSource.sort()||[],r=i.field;for(i.wrapper.find(".k-sort-asc, .k-sort-desc").removeClass(h),t=0,n=o.length;t<n;t++)e=o[t],r==e.field&&i.wrapper.find(".k-sort-"+e.dir).addClass(h);i.link[i._filterExist(i.dataSource.filter())?"addClass":"removeClass"]("k-state-active")},_filterExist:function(e){var t,n,i,o=!1;if(e){for(e=e.filters,n=0,i=e.length;n<i;n++)t=e[n],t.field==this.field?o=!0:t.filters&&(o=o||this._filterExist(t));return o}}}),S='<ul id="#=uid#">#if(sortable){#<li class="k-item k-sort-asc"><span class="k-link"><span class="k-icon k-i-sort-asc-sm"></span>${messages.sortAscending}</span></li><li class="k-item k-sort-desc"><span class="k-link"><span class="k-icon k-i-sort-desc-sm"></span>${messages.sortDescending}</span></li>#if(showColumns || filterable){#<li class="k-separator" role="presentation"></li>#}##}##if(showColumns){#<li class="k-item k-columns-item" aria-haspopup="true"><span class="k-link"><span class="k-icon k-i-columns"></span>${messages.columns}</span><ul>#for (var idx = 0; idx < columns.length; idx++) {#<li role="menuitemcheckbox" aria-checked="false"><input type="checkbox" data-#=ns#field="#=columns[idx].field.replace(/"/g,"&\\#34;")#" data-#=ns#index="#=columns[idx].index#" data-#=ns#locked="#=columns[idx].locked#"/>#=columns[idx].title#</li>#}#</ul></li>#if(filterable || lockedColumns){#<li class="k-separator" role="presentation"></li>#}##}##if(filterable){#<li class="k-item k-filter-item" aria-haspopup="true"><span class="k-link"><span class="k-icon k-i-filter"></span>${messages.filter}</span><ul><li><div class="k-filterable"></div></li></ul></li>#if(lockedColumns){#<li class="k-separator" role="presentation"></li>#}##}##if(lockedColumns){#<li class="k-item k-lock"><span class="k-link"><span class="k-icon k-i-lock"></span>${messages.lock}</span></li><li class="k-item k-unlock"><span class="k-link"><span class="k-icon k-i-unlock"></span>${messages.unlock}</span></li>#}#</ul>',T='<div data-#=ns#role="view" data-#=ns#init-widgets="false" data-#=ns#use-native-scrolling="true" class="k-grid-column-menu"><div data-#=ns#role="header" class="k-header">${messages.settings}<button class="k-button k-done">#=messages.done#</button></div><div class="k-column-menu k-mobile-list"><ul><li><span class="k-link">${title}</span><ul>#if(sortable){#<li class="k-item k-sort-asc"><span class="k-link"><span class="k-icon k-i-sort-asc-sm"></span>${messages.sortAscending}</span></li><li class="k-item k-sort-desc"><span class="k-link"><span class="k-icon k-i-sort-desc-sm"></span>${messages.sortDescending}</span></li>#}##if(lockedColumns){#<li class="k-item k-lock"><span class="k-link"><span class="k-icon k-i-lock"></span>${messages.lock}</span></li><li class="k-item k-unlock"><span class="k-link"><span class="k-icon k-i-unlock"></span>${messages.unlock}</span></li>#}##if(filterable){#<li class="k-item k-filter-item"><span class="k-link k-filterable"><span class="k-icon k-i-filter"></span>${messages.filter}</span></li>#}#</ul></li>#if(showColumns){#<li class="k-columns-item"><span class="k-link">${messages.columns}</span><ul>#for (var idx = 0; idx < columns.length; idx++) {#<li class="k-item"><label class="k-label"><input type="checkbox" class="k-check" data-#=ns#field="#=columns[idx].field.replace(/"/g,"&\\#34;")#" data-#=ns#index="#=columns[idx].index#" data-#=ns#locked="#=columns[idx].locked#"/>#=columns[idx].title#</label></li>#}#</ul></li>#}#</ul></div></div>',D=x.extend({init:function(e,t){x.fn.init.call(this,e,t),this.element.on("click"+k,"li.k-item:not(.k-separator):not(.k-state-disabled)","_click")},events:[_],_click:function(t){e(t.target).is("[type=checkbox]")||t.preventDefault(),this.trigger(_,{item:t.currentTarget})},close:function(){this.options.pane.navigate("")},destroy:function(){x.fn.destroy.call(this),this.element.off(k)}});s.plugin(C)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.columnsorter.min",["kendo.core.min"],e)}(function(){return function(e,t){var n=window.kendo,i=n.ui,o=i.Widget,r="dir",s="asc",a="single",l="field",c="desc",d=".kendoColumnSorter",u=".k-link",h="aria-sort",f=e.proxy,p=o.extend({init:function(e,t){var n,i=this;o.fn.init.call(i,e,t),i._refreshHandler=f(i.refresh,i),i.dataSource=i.options.dataSource.bind("change",i._refreshHandler),i.directions=i.options.initialDirection===s?[s,c]:[c,s],n=i.element.find(u),n[0]||(n=i.element.wrapInner('<a class="k-link" href="#"/>').find(u)),i.link=n,i.element.on("click"+d,f(i._click,i))},options:{name:"ColumnSorter",mode:a,allowUnsort:!0,compare:null,filter:"",initialDirection:s,showIndexes:!1},events:["change"],destroy:function(){var e=this;o.fn.destroy.call(e),e.element.off(d),e.dataSource.unbind("change",e._refreshHandler),e._refreshHandler=e.element=e.link=e.dataSource=null},refresh:function(){var i,o,a,d,u,f,p=this,m=p.dataSource.sort()||[],g=p.element,v=g.attr(n.attr(l));for(g.removeAttr(n.attr(r)),g.removeAttr(h),i=0,o=m.length;i<o;i++)a=m[i],v==a.field&&(g.attr(n.attr(r),a.dir),u=i+1);d=g.attr(n.attr(r)),g.is("th")&&(f=g.closest("table"),f.parent().hasClass("k-grid-header-wrap")?f=f.closest(".k-grid").find(".k-grid-content > table"):f.parent().hasClass("k-grid")||(f=null),f&&(g.toggleClass("k-sorted",d!==t),f.children("colgroup").children().eq(g.index()).toggleClass("k-sorted",d!==t))),g.find(".k-i-sort-asc-sm,.k-i-sort-desc-sm,.k-sort-order").remove(),d===s?(e('<span class="k-icon k-i-sort-asc-sm" />').appendTo(p.link),g.attr(h,"ascending")):d===c&&(e('<span class="k-icon k-i-sort-desc-sm" />').appendTo(p.link),g.attr(h,"descending")),p.options.showIndexes&&m.length>1&&u&&e('<span class="k-sort-order" />').html(u).appendTo(p.link)},_toggleSortDirection:function(e){var n=this.directions;return e===n[n.length-1]&&this.options.allowUnsort?t:n[0]===e?n[1]:n[0]},_click:function(e){var i,o,s=this,c=s.element,d=c.attr(n.attr(l)),u=c.attr(n.attr(r)),h=s.options,f=null===s.options.compare?t:s.options.compare,p=s.dataSource.sort()||[];if(e.preventDefault(),(!h.filter||c.is(h.filter))&&(u=this._toggleSortDirection(u),!this.trigger("change",{sort:{field:d,dir:u,compare:f}}))){if(h.mode===a)p=[{field:d,dir:u,compare:f}];else if("multiple"===h.mode){for(i=0,o=p.length;i<o;i++)if(p[i].field===d){p.splice(i,1);break}p.push({field:d,dir:u,compare:f})}this.dataSource.sort(p)}}});i.plugin(p)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.editable.min",["kendo.datepicker.min","kendo.numerictextbox.min","kendo.validator.min","kendo.binder.min"],e)}(function(){return function(e,t){function n(t){return t=null!=t?t:"",t.type||e.type(t)||"string"}function i(t){t.find(":input:not(:button, ["+a.attr("role")+"=upload], ["+a.attr("skip")+"], [type=file]), select").each(function(){var t=a.attr("bind"),n=this.getAttribute(t)||"",i="checkbox"===this.type||"radio"===this.type?"checked:":"value:",o=this.name;n.indexOf(i)===-1&&o&&(n+=(n.length?",":"")+i+o,e(this).attr(t,n))})}function o(e){var t,i,o=(e.model.fields||e.model)[e.field],r=n(o),s=o?o.validation:{},l=a.attr("type"),c=a.attr("bind"),d={name:e.field,title:e.title};for(t in s)i=s[t],p(t,_)>=0?d[l]=t:h(i)||(d[t]=f(i)?i.value||t:i),d[a.attr(t+"-msg")]=i.message;return p(r,_)>=0&&(d[l]=r),d[c]=("boolean"===r?"checked:":"value:")+e.field,d}function r(e){var t,n,i,o,r,s;if(e&&e.length)for(s=[],t=0,n=e.length;t<n;t++)i=e[t],r=i.text||i.value||i,o=null==i.value?i.text||i:i.value,s[t]={text:r,value:o};return s}function s(e,t){var n,i,o=e?e.validation||{}:{};for(n in o)i=o[n],f(i)&&i.value&&(i=i.value),h(i)&&(t[n]=i)}var a=window.kendo,l=a.ui,c=l.Widget,d=e.extend,u=a.support.browser.msie&&a.support.browser.version<9,h=a.isFunction,f=e.isPlainObject,p=e.inArray,m=/("|\%|'|\[|\]|\$|\.|\,|\:|\;|\+|\*|\&|\!|\#|\(|\)|<|>|\=|\?|\@|\^|\{|\}|\~|\/|\||`)/g,g='<div class="k-widget k-tooltip k-tooltip-validation" style="margin:0.5em"><span class="k-icon k-i-warning"> </span>#=message#<div class="k-callout k-callout-n"></div></div>',v="change",_=["url","email","number","date","boolean"],b={number:function(t,n){var i=o(n);e('<input type="text"/>').attr(i).appendTo(t).kendoNumericTextBox({format:n.format}),e("<span "+a.attr("for")+'="'+n.field+'" class="k-invalid-msg"/>').hide().appendTo(t)},date:function(t,n){var i=o(n),r=n.format;r&&(r=a._extractFormat(r)),i[a.attr("format")]=r,e('<input type="text"/>').attr(i).appendTo(t).kendoDatePicker({format:n.format}),e("<span "+a.attr("for")+'="'+n.field+'" class="k-invalid-msg"/>').hide().appendTo(t)},string:function(t,n){var i=o(n);e('<input type="text" class="k-input k-textbox"/>').attr(i).appendTo(t)},"boolean":function(t,n){var i=o(n);e('<input type="checkbox" />').attr(i).appendTo(t)},values:function(t,n){var i=o(n),s=a.stringify(r(n.values));e("<select "+a.attr("text-field")+'="text"'+a.attr("value-field")+'="value"'+a.attr("source")+"='"+(s?s.replace(/\'/g,"&apos;"):s)+"'"+a.attr("role")+'="dropdownlist"/>').attr(i).appendTo(t),e("<span "+a.attr("for")+'="'+n.field+'" class="k-invalid-msg"/>').hide().appendTo(t)}},w=c.extend({init:function(t,n){var i=this;n.target&&(n.$angular=n.target.options.$angular),c.fn.init.call(i,t,n),i._validateProxy=e.proxy(i._validate,i),i.refresh()},events:[v],options:{name:"Editable",editors:b,clearContainer:!0,errorTemplate:g},editor:function(e,t){var i=this,o=i.options.editors,r=f(e),s=r?e.field:e,l=i.options.model||{},c=r&&e.values,u=c?"values":n(t),h=r&&e.editor,p=h?e.editor:o[u],g=i.element.find("["+a.attr("container-for")+"="+s.replace(m,"\\$1")+"]");p=p?p:o.string,h&&"string"==typeof e.editor&&(p=function(t){t.append(e.editor)}),g=g.length?g:i.element,p(g,d(!0,{},r?e:{field:s},{model:l}))},_validate:function(t){var n,i=this,o=t.value,r=i._validationEventInProgress,s={},l=a.attr("bind"),c=t.field.replace(m,"\\$1"),d=RegExp("(value|checked)\\s*:\\s*"+c+"\\s*(,|$)");
s[t.field]=t.value,n=e(":input["+l+'*="'+c+'"]',i.element).filter("["+a.attr("validate")+"!='false']").filter(function(){return d.test(e(this).attr(l))}),n.length>1&&(n=n.filter(function(){var t=e(this);return!t.is(":radio")||t.val()==o}));try{i._validationEventInProgress=!0,(!i.validatable.validateInput(n)||!r&&i.trigger(v,{values:s}))&&t.preventDefault()}finally{i._validationEventInProgress=!1}},end:function(){return this.validatable.validate()},destroy:function(){var e=this;e.angular("cleanup",function(){return{elements:e.element}}),c.fn.destroy.call(e),e.options.model.unbind("set",e._validateProxy),a.unbind(e.element),e.validatable&&e.validatable.destroy(),a.destroy(e.element),e.element.removeData("kendoValidator"),e.element.is("["+a.attr("role")+"=editable]")&&e.element.removeAttr(a.attr("role"))},refresh:function(){var n,o,r,l,c,d,h,p,m=this,g=m.options.fields||[],v=m.options.clearContainer?m.element.empty():m.element,_=m.options.model||{},b={};for(e.isArray(g)||(g=[g]),n=0,o=g.length;n<o;n++)r=g[n],l=f(r),c=l?r.field:r,d=(_.fields||_)[c],s(d,b),m.editor(r,d);if(m.options.target&&m.angular("compile",function(){return{elements:v,data:v.map(function(){return{dataItem:_}})}}),!o){h=_.fields||_;for(c in h)s(h[c],b)}i(v),m.validatable&&m.validatable.destroy(),a.bind(v,m.options.model),m.options.model.unbind("set",m._validateProxy),m.options.model.bind("set",m._validateProxy),m.validatable=new a.ui.Validator(v,{validateOnBlur:!1,errorTemplate:m.options.errorTemplate||t,rules:b}),p=v.find(":kendoFocusable").eq(0).focus(),u&&p.focus()}});l.plugin(w)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.window.min",["kendo.draganddrop.min","kendo.popup.min"],e)}(function(){return function(e,t){function n(e){return t!==e}function i(e,t,n){return Math.max(Math.min(parseInt(e,10),n===1/0?n:parseInt(n,10)),parseInt(t,10))}function o(){return!this.type||this.type.toLowerCase().indexOf("script")>=0}function r(e){var t=this;t.owner=e,t._preventDragging=!1,t._draggable=new u(e.wrapper,{filter:">"+T,group:e.wrapper.id+"-resizing",dragstart:g(t.dragstart,t),drag:g(t.drag,t),dragend:g(t.dragend,t)}),t._draggable.userEvents.bind("press",g(t.addOverlay,t)),t._draggable.userEvents.bind("release",g(t.removeOverlay,t))}function s(t){for(var n,i,o={top:t.offsetTop,left:t.offsetLeft},r=t.offsetParent;r;)o.top+=r.offsetTop,o.left+=r.offsetLeft,n=e(r).css("overflowX"),i=e(r).css("overflowY"),"auto"!==i&&"scroll"!==i||(o.top-=r.scrollTop),"auto"!==n&&"scroll"!==n||(o.left-=r.scrollLeft),r=r.offsetParent;return o}function a(e,t){var n=this;n.owner=e,n._preventDragging=!1,n._draggable=new u(e.wrapper,{filter:t,group:e.wrapper.id+"-moving",dragstart:g(n.dragstart,n),drag:g(n.drag,n),dragend:g(n.dragend,n),dragcancel:g(n.dragcancel,n)}),n._draggable.userEvents.stopPropagation=!1}var l=window.kendo,c=l.ui.Widget,d=l.ui.Popup.TabKeyTrap,u=l.ui.Draggable,h=e.isPlainObject,f=l._activeElement,p=l._outerWidth,m=l._outerHeight,g=e.proxy,v=e.extend,_=e.each,b=l.template,w="body",y=".kendoWindow",k=".k-window",x=".k-window-title",C=x+"bar",S=".k-window-content",T=".k-resize-handle",D=".k-overlay",A="k-content-frame",E="k-i-loading",M="k-state-hover",I="k-state-focused",R="k-window-maximized",F=":visible",z="hidden",P="cursor",B="open",L="activate",H="deactivate",N="close",O="refresh",V="minimize",U="maximize",W="resizeStart",q="resize",j="resizeEnd",G="dragstart",$="dragend",Y="error",K="overflow",Q="zIndex",X=".k-window-actions .k-i-window-minimize,.k-window-actions .k-i-window-maximize",Z=".k-i-pin",J=".k-i-unpin",ee=Z+","+J,te=".k-window-titlebar .k-window-action",ne=".k-window-titlebar .k-i-refresh",ie=/^0[a-z]*$/i,oe=l.isLocalUrl,re=c.extend({init:function(i,r){var s,a,u,f,p,m,v,_=this,b={},w=!1,T=r&&r.actions&&!r.actions.length;c.fn.init.call(_,i,r),r=_.options,f=r.position,i=_.element,p=r.content,T&&(r.actions=[]),_.appendTo=e(r.appendTo),p&&!h(p)&&(p=r.content={url:p}),i.find("script").filter(o).remove(),i.parent().is(_.appendTo)||f.top!==t&&f.left!==t||(i.is(F)?(b=i.offset(),w=!0):(a=i.css("visibility"),u=i.css("display"),i.css({visibility:z,display:""}),b=i.offset(),i.css({visibility:a,display:u})),f.top===t&&(f.top=b.top),f.left===t&&(f.left=b.left)),n(r.visible)&&null!==r.visible||(r.visible=i.is(F)),s=_.wrapper=i.closest(k),i.is(".k-content")&&s[0]||(i.addClass("k-window-content k-content"),_._createWindow(i,r),s=_.wrapper=i.closest(k),_._dimensions()),_._position(),p&&_.refresh(p),r.visible&&_.toFront(),m=s.children(S),_._tabindex(m),r.visible&&r.modal&&_._overlay(s.is(F)).css({opacity:.5}),s.on("mouseenter"+y,te,g(_._buttonEnter,_)).on("mouseleave"+y,te,g(_._buttonLeave,_)).on("click"+y,"> "+te,g(_._windowActionHandler,_)),m.on("keydown"+y,g(_._keydown,_)).on("focus"+y,g(_._focus,_)).on("blur"+y,g(_._blur,_)),this._resizable(),this._draggable(),r.pinned&&_.pin(),v=i.attr("id"),v&&(v+="_wnd_title",s.children(C).children(x).attr("id",v),m.attr({role:"dialog","aria-labelledby":v})),s.add(s.children(".k-resize-handle,"+C)).on("mousedown"+y,g(_.toFront,_)),_.touchScroller=l.touchScroller(i),_._resizeHandler=g(_._onDocumentResize,_),_._marker=l.guid().substring(0,8),e(window).on("resize"+y+_._marker,_._resizeHandler),r.visible&&(_.trigger(B),_.trigger(L)),l.notify(_),this.options.modal&&(this._tabKeyTrap=new d(s),this._tabKeyTrap.trap(),this._tabKeyTrap.shouldTrap=function(){return m.data("isFront")})},_buttonEnter:function(t){e(t.currentTarget).addClass(M)},_buttonLeave:function(t){e(t.currentTarget).removeClass(M)},_focus:function(){this.wrapper.addClass(I)},_blur:function(){this.wrapper.removeClass(I)},_dimensions:function(){var e,t,n=this.wrapper,o=this.options,r=o.width,s=o.height,a=o.maxHeight,l=["minWidth","minHeight","maxWidth","maxHeight"];for(this.title(o.title),e=0;e<l.length;e++)t=o[l[e]]||"",t!=1/0&&n.css(l[e],t);a!=1/0&&this.element.css("maxHeight",a),n.width(r?(""+r).indexOf("%")>0?r:i(r,o.minWidth,o.maxWidth):""),n.height(s?(""+s).indexOf("%")>0?s:i(s,o.minHeight,o.maxHeight):""),o.visible||n.hide()},_position:function(){var e=this.wrapper,t=this.options.position;0===t.top&&(t.top=""+t.top),0===t.left&&(t.left=""+t.left),e.css({top:t.top||"",left:t.left||""})},_animationOptions:function(e){var t=this.options.animation,n={open:{effects:{}},close:{hide:!0,effects:{}}};return t&&t[e]||n[e]},_resize:function(){l.resize(this.element.children())},_resizable:function(){var t=this.options.resizable,n=this.wrapper;this.resizing&&(n.off("dblclick"+y).children(T).remove(),this.resizing.destroy(),this.resizing=null),t&&(n.on("dblclick"+y,C,g(function(t){e(t.target).closest(".k-window-action").length||this.toggleMaximization()},this)),_("n e s w se sw ne nw".split(" "),function(e,t){n.append(se.resizeHandle(t))}),this.resizing=new r(this)),n=null},_draggable:function(){var e=this.options.draggable;this.dragging&&(this.dragging.destroy(),this.dragging=null),e&&(this.dragging=new a(this,e.dragHandle||C))},_actions:function(){var t=this.options,n=t.actions,i=t.pinned,o=this.wrapper.children(C),r=o.find(".k-window-actions"),s=["maximize","minimize"];n=e.map(n,function(e){return e=i&&"pin"===e.toLowerCase()?"unpin":e,{name:s.indexOf(e.toLowerCase())>-1?"window-"+e:e}}),r.html(l.render(se.action,n))},setOptions:function(e){var n,i;c.fn.setOptions.call(this,e),n=this.options.scrollable!==!1,this.restore(),this._dimensions(),this._position(),this._resizable(),this._draggable(),this._actions(),t!==e.modal&&(i=this.options.visible!==!1,this._overlay(e.modal&&i)),this.element.css(K,n?"":"hidden")},events:[B,L,H,N,V,U,O,W,q,j,G,$,Y],options:{name:"Window",animation:{open:{effects:{zoom:{direction:"in"},fade:{direction:"in"}},duration:350},close:{effects:{zoom:{direction:"out",properties:{scale:.7}},fade:{direction:"out"}},duration:350,hide:!0}},title:"",actions:["Close"],autoFocus:!0,modal:!1,resizable:!0,draggable:!0,minWidth:90,minHeight:50,maxWidth:1/0,maxHeight:1/0,pinned:!1,scrollable:!0,position:{},content:null,visible:null,height:null,width:null,appendTo:"body",isMaximized:!1,isMinimized:!1},_closable:function(){return e.inArray("close",e.map(this.options.actions,function(e){return e.toLowerCase()}))>-1},_keydown:function(e){var t,n,o,r,s,a,c=this,d=c.options,u=l.keys,h=e.keyCode,f=c.wrapper,p=10,m=c.options.isMaximized;h==u.ESC&&c._closable()&&c._close(!1),e.target!=e.currentTarget||c._closing||(!d.draggable||e.ctrlKey||m||(t=l.getOffset(f),h==u.UP?n=f.css("top",t.top-p):h==u.DOWN?n=f.css("top",t.top+p):h==u.LEFT?n=f.css("left",t.left-p):h==u.RIGHT&&(n=f.css("left",t.left+p))),d.resizable&&e.ctrlKey&&!m&&(h==u.UP?(n=!0,r=f.height()-p):h==u.DOWN&&(n=!0,r=f.height()+p),h==u.LEFT?(n=!0,o=f.width()-p):h==u.RIGHT&&(n=!0,o=f.width()+p),n&&(s=i(o,d.minWidth,d.maxWidth),a=i(r,d.minHeight,d.maxHeight),isNaN(s)||(f.width(s),c.options.width=s+"px"),isNaN(a)||(f.height(a),c.options.height=a+"px"),c.resize())),n&&e.preventDefault())},_overlay:function(t){var n=this.appendTo.children(D),i=this.wrapper;return n.length||(n=e("<div class='k-overlay' />")),n.insertBefore(i[0]).toggle(t).css(Q,parseInt(i.css(Q),10)-1),n},_actionForIcon:function(e){var t=/\bk-i(-\w+)+\b/.exec(e[0].className)[0];return{"k-i-close":"_close","k-i-window-maximize":"maximize","k-i-window-minimize":"minimize","k-i-window-restore":"restore","k-i-refresh":"refresh","k-i-pin":"pin","k-i-unpin":"unpin"}[t]},_windowActionHandler:function(n){var i,o;if(!this._closing)return i=e(n.target).closest(".k-window-action").find(".k-icon"),o=this._actionForIcon(i),o?(n.preventDefault(),this[o](),!1):t},_modals:function(){var t=this,n=e(k).filter(function(){var n=e(this),i=t._object(n),o=i&&i.options;return o&&o.modal&&o.visible&&o.appendTo===t.options.appendTo&&n.is(F)}).sort(function(t,n){return+e(t).css("zIndex")-+e(n).css("zIndex")});return t=null,n},_object:function(e){var n=e.children(S),i=l.widgetInstance(n);return i?i:t},center:function(){var t,n,i=this,o=i.options.position,r=i.wrapper,s=e(window),a=0,l=0;return i.options.isMaximized?i:(i.options.pinned||(a=s.scrollTop(),l=s.scrollLeft()),n=l+Math.max(0,(s.width()-r.width())/2),t=a+Math.max(0,(s.height()-r.height()-parseInt(r.css("paddingTop"),10))/2),r.css({left:n,top:t}),o.top=t,o.left=n,i)},title:function(e){var t,n=this,i=n.wrapper,o=n.options,r=i.children(C),s=r.children(x);return arguments.length?(e===!1?(i.addClass("k-window-titleless"),r.remove()):(r.length?s.html(l.htmlEncode(e)):(i.prepend(se.titlebar(o)),n._actions(),r=i.children(C)),t=parseInt(m(r),10),i.css("padding-top",t),r.css("margin-top",-t)),n.options.title=e,n):s.html()},content:function(e,t){var i=this.wrapper.children(S),o=i.children(".km-scroll-container");return i=o[0]?o:i,n(e)?(this.angular("cleanup",function(){return{elements:i.children()}}),l.destroy(this.element.children()),i.empty().html(e),this.angular("compile",function(){var e,n=[];for(e=i.length;--e>=0;)n.push({dataItem:t});return{elements:i.children(),data:n}}),this):i.html()},open:function(){var t,n,i,o=this,r=o.wrapper,s=o.options,a=this._animationOptions("open"),c=r.children(S),d=e(document);return o.trigger(B)||(o._closing&&r.kendoStop(!0,!0),o._closing=!1,o.toFront(),s.autoFocus&&o.element.focus(),s.visible=!0,s.modal&&(n=!!o._modals().length,t=o._overlay(n),t.kendoStop(!0,!0),a.duration&&l.effects.Fade&&!n?(i=l.fx(t).fadeIn(),i.duration(a.duration||0),i.endValue(.5),i.play()):t.css("opacity",.5),t.show(),e(window).on("focus",function(){c.data("isFront")&&o.element.focus()})),r.is(F)||(c.css(K,z),r.show().kendoStop().kendoAnimate({effects:a.effects,duration:a.duration,complete:g(this._activate,this)}))),s.isMaximized&&(o._documentScrollTop=d.scrollTop(),o._documentScrollLeft=d.scrollLeft(),e("html, body").css(K,z)),o},_activate:function(){var e=this.options.scrollable!==!1;this.options.autoFocus&&this.element.focus(),this.element.css(K,e?"":"hidden"),l.resize(this.element.children()),this.trigger(L)},_removeOverlay:function(n){var i,o=this._modals(),r=this.options,s=r.modal&&!o.length,a=r.modal?this._overlay(!0):e(t),c=this._animationOptions("close");s?!n&&c.duration&&l.effects.Fade?(i=l.fx(a).fadeOut(),i.duration(c.duration||0),i.startValue(.5),i.play()):this._overlay(!1).remove():o.length&&this._object(o.last())._overlay(!0)},_close:function(t){var n=this,i=n.wrapper,o=n.options,r=this._animationOptions("open"),s=this._animationOptions("close"),a=e(document);if(i.is(F)&&!n.trigger(N,{userTriggered:!t})){if(n._closing)return;n._closing=!0,o.visible=!1,e(k).each(function(t,n){var o=e(n).children(S);n!=i&&o.find("> ."+A).length>0&&o.children(D).remove()}),this._removeOverlay(),i.kendoStop().kendoAnimate({effects:s.effects||r.effects,reverse:s.reverse===!0,duration:s.duration,complete:g(this._deactivate,this)})}n.options.isMaximized&&(e("html, body").css(K,""),n._documentScrollTop&&n._documentScrollTop>0&&a.scrollTop(n._documentScrollTop),n._documentScrollLeft&&n._documentScrollLeft>0&&a.scrollLeft(n._documentScrollLeft))},_deactivate:function(){var e,t=this;t.wrapper.hide().css("opacity",""),t.trigger(H),t.options.modal&&(e=t._object(t._modals().last()),e&&e.toFront())},close:function(){return this._close(!0),this},_actionable:function(t){return e(t).is(te+","+te+" .k-icon,:input,a")},_shouldFocus:function(t){var n=f(),i=this.element;return this.options.autoFocus&&!e(n).is(i)&&!this._actionable(t)&&(!i.find(n).length||!i.find(t).length)},toFront:function(t){var n,i,o=this,r=o.wrapper,s=r[0],a=+r.css(Q),l=a,c=t&&t.target||null;return e(k).each(function(t,n){var i=e(n),o=i.css(Q),r=i.children(S);isNaN(o)||(a=Math.max(+o,a)),r.data("isFront",n==s),n!=s&&r.find("> ."+A).length>0&&r.append(se.overlay)}),(!r[0].style.zIndex||l<a)&&r.css(Q,a+2),o.element.find("> .k-overlay").remove(),o._shouldFocus(c)&&(o.element.focus(),n=e(window).scrollTop(),i=parseInt(r.position().top,10),!o.options.pinned&&i>0&&i<n&&(n>0?e(window).scrollTop(i):r.css("top",n))),r=null,o},toggleMaximization:function(){return this._closing?this:this[this.options.isMaximized?"restore":"maximize"]()},restore:function(){var t=this,n=t.options,i=n.minHeight,o=t.restoreOptions,r=e(document);return n.isMaximized||n.isMinimized?(i&&i!=1/0&&t.wrapper.css("min-height",i),t.wrapper.css({position:n.pinned?"fixed":"absolute",left:o.left,top:o.top,width:o.width,height:o.height}).removeClass(R).find(".k-window-content,.k-resize-handle").show().end().find(".k-window-titlebar .k-i-window-restore").parent().remove().end().end().find(X).parent().show().end().end().find(ee).parent().show(),t.options.width=o.width,t.options.height=o.height,e("html, body").css(K,""),this._documentScrollTop&&this._documentScrollTop>0&&r.scrollTop(this._documentScrollTop),this._documentScrollLeft&&this._documentScrollLeft>0&&r.scrollLeft(this._documentScrollLeft),n.isMaximized=n.isMinimized=!1,t.resize(),t):t},_sizingAction:function(e,t){var n=this,i=n.wrapper,o=i[0].style,r=n.options;return r.isMaximized||r.isMinimized?n:(n.restoreOptions={width:o.width,height:o.height},i.children(T).hide().end().children(C).find(X).parent().hide().eq(0).before(se.action({name:"window-restore"})),t.call(n),n.wrapper.children(C).find(ee).parent().toggle("maximize"!==e),n.trigger(e),n)},maximize:function(){return this._sizingAction("maximize",function(){var t=this,n=t.wrapper,i=n.position(),o=e(document);v(t.restoreOptions,{left:i.left,top:i.top}),n.css({left:0,top:0,position:"fixed"}).addClass(R),this._documentScrollTop=o.scrollTop(),this._documentScrollLeft=o.scrollLeft(),e("html, body").css(K,z),t.options.isMaximized=!0,t._onDocumentResize()}),this},isMaximized:function(){return this.options.isMaximized},minimize:function(){return this._sizingAction("minimize",function(){var e=this;e.wrapper.css({height:"",minHeight:""}),e.element.hide(),e.options.isMinimized=!0}),this},isMinimized:function(){return this.options.isMinimized},pin:function(){var t=this,n=e(window),i=t.wrapper,o=parseInt(i.css("top"),10),r=parseInt(i.css("left"),10);t.options.isMaximized||(i.css({position:"fixed",top:o-n.scrollTop(),left:r-n.scrollLeft()}),i.children(C).find(Z).addClass("k-i-unpin").removeClass("k-i-pin"),t.options.pinned=!0,t.options.draggable=!1)},unpin:function(){var t=this,n=e(window),i=t.wrapper,o=parseInt(i.css("top"),10),r=parseInt(i.css("left"),10);t.options.isMaximized||(i.css({position:"",top:o+n.scrollTop(),left:r+n.scrollLeft()}),i.children(C).find(J).addClass("k-i-pin").removeClass("k-i-unpin"),t.options.pinned=!1,t.options.draggable=!0)},_onDocumentResize:function(){var t,n,i=this,o=i.wrapper,r=e(window),s=l.support.zoomLevel();i.options.isMaximized&&(t=r.width()/s,n=r.height()/s-parseInt(o.css("padding-top"),10),o.css({width:t,height:n}),i.options.width=t,i.options.height=n,i.resize())},refresh:function(t){var i,o,r,s=this,a=s.options,l=e(s.element);return h(t)||(t={url:t}),t=v({},a.content,t),o=n(a.iframe)?a.iframe:t.iframe,r=t.url,r?(n(o)||(o=!oe(r)),o?(i=l.find("."+A)[0],i?i.src=r||i.src:l.html(se.contentFrame(v({},a,{content:t}))),l.find("."+A).unbind("load"+y).on("load"+y,g(this._triggerRefresh,this))):s._ajaxRequest(t)):(t.template&&s.content(b(t.template)({})),s.trigger(O)),l.toggleClass("k-window-iframecontent",!!o),s},_triggerRefresh:function(){this.trigger(O)},_ajaxComplete:function(){clearTimeout(this._loadingIconTimeout),this.wrapper.find(ne).removeClass(E)},_ajaxError:function(e,t){this.trigger(Y,{status:t,xhr:e})},_ajaxSuccess:function(e){return function(t){var n=t;e&&(n=b(e)(t||{})),this.content(n,t),this.element.prop("scrollTop",0),this.trigger(O)}},_showLoading:function(){this.wrapper.find(ne).addClass(E)},_ajaxRequest:function(t){this._loadingIconTimeout=setTimeout(g(this._showLoading,this),100),e.ajax(v({type:"GET",dataType:"html",cache:!1,error:g(this._ajaxError,this),complete:g(this._ajaxComplete,this),success:g(this._ajaxSuccess(t.template),this)},t))},_destroy:function(){this.resizing&&this.resizing.destroy(),this.dragging&&this.dragging.destroy(),this.wrapper.off(y).children(S).off(y).end().find(".k-resize-handle,.k-window-titlebar").off(y),e(window).off("resize"+y+this._marker),clearTimeout(this._loadingIconTimeout),c.fn.destroy.call(this),this.unbind(t),l.destroy(this.wrapper),this._removeOverlay(!0)},destroy:function(){this._destroy(),this.wrapper.empty().remove(),this.wrapper=this.appendTo=this.element=e()},_createWindow:function(){var t,n,i=this.element,o=this.options,r=l.support.isRtl(i);o.scrollable===!1&&i.css("overflow","hidden"),n=e(se.wrapper(o)),t=i.find("iframe:not(.k-content)").map(function(){var e=this.getAttribute("src");return this.src="",e}),n.toggleClass("k-rtl",r).appendTo(this.appendTo).append(i).find("iframe:not(.k-content)").each(function(e){this.src=t[e]}),n.find(".k-window-title").css(r?"left":"right",p(n.find(".k-window-actions"))+10),i.css("visibility","").show(),i.find("[data-role=editor]").each(function(){var t=e(this).data("kendoEditor");t&&t.refresh()}),n=i=null}}),se={wrapper:b("<div class='k-widget k-window' />"),action:b("<a role='button' href='\\#' class='k-button k-bare k-button-icon k-window-action' aria-label='#= name #'><span class='k-icon k-i-#= name.toLowerCase() #'></span></a>"),titlebar:b("<div class='k-window-titlebar k-header'>&nbsp;<span class='k-window-title'>#: title #</span><div class='k-window-actions' /></div>"),overlay:"<div class='k-overlay' />",contentFrame:b("<iframe frameborder='0' title='#= title #' class='"+A+"' src='#= content.url #'>This page requires frames in order to show content</iframe>"),resizeHandle:b("<div class='k-resize-handle k-resize-#= data #'></div>")};r.prototype={addOverlay:function(){this.owner.wrapper.append(se.overlay)},removeOverlay:function(){this.owner.wrapper.find(D).remove()},dragstart:function(t){var n,i,o,r,a,c,d,u=this,h=u.owner,f=h.wrapper;u._preventDragging=h.trigger(W),u._preventDragging||(u.elementPadding=parseInt(f.css("padding-top"),10),u.initialPosition=l.getOffset(f,"position"),u.resizeDirection=t.currentTarget.prop("className").replace("k-resize-handle k-resize-",""),u.initialSize={width:f.width(),height:f.height()},u.containerOffset=l.getOffset(h.appendTo,"position"),n=f.offsetParent(),n.is("html")?u.containerOffset.top=u.containerOffset.left=0:(i=n.css("margin-top"),o=n.css("margin-left"),r=!ie.test(i)||!ie.test(o),r&&(a=s(f[0]),c=a.left-u.containerOffset.left-u.initialPosition.left,d=a.top-u.containerOffset.top-u.initialPosition.top,u._relativeElMarginLeft=c>1?c:0,u._relativeElMarginTop=d>1?d:0,u.initialPosition.left+=u._relativeElMarginLeft,u.initialPosition.top+=u._relativeElMarginTop)),f.children(T).not(t.currentTarget).hide(),e(w).css(P,t.currentTarget.css(P)))},drag:function(t){var n,o,r,s,a,l,c,d,u,h,f,p,m,g,v;this._preventDragging||(n=this,o=n.owner,r=o.wrapper,s=o.options,a=n.resizeDirection,l=n.containerOffset,c=n.initialPosition,d=n.initialSize,m=Math.max(t.x.location,0),g=Math.max(t.y.location,0),a.indexOf("e")>=0?(u=m-c.left-l.left,r.width(i(u,s.minWidth,s.maxWidth))):a.indexOf("w")>=0&&(p=c.left+d.width+l.left,u=i(p-m,s.minWidth,s.maxWidth),r.css({left:p-u-l.left-(n._relativeElMarginLeft||0),width:u})),v=g,o.options.pinned&&(v-=e(window).scrollTop()),a.indexOf("s")>=0?(h=v-c.top-n.elementPadding-l.top,r.height(i(h,s.minHeight,s.maxHeight))):a.indexOf("n")>=0&&(f=c.top+d.height+l.top,h=i(f-v,s.minHeight,s.maxHeight),r.css({top:f-h-l.top-(n._relativeElMarginTop||0),height:h})),u&&(o.options.width=u+"px"),h&&(o.options.height=h+"px"),o.resize())},dragend:function(t){if(!this._preventDragging){var n=this,i=n.owner,o=i.wrapper;return o.children(T).not(t.currentTarget).show(),e(w).css(P,""),i.touchScroller&&i.touchScroller.reset(),27==t.keyCode&&o.css(n.initialPosition).css(n.initialSize),i.trigger(j),!1}},destroy:function(){this._draggable&&this._draggable.destroy(),this._draggable=this.owner=null}},a.prototype={dragstart:function(t){var n=this.owner,i=n.element,o=i.find(".k-window-actions"),r=l.getOffset(n.appendTo);this._preventDragging=n.trigger(G)||!n.options.draggable,this._preventDragging||(n.initialWindowPosition=l.getOffset(n.wrapper,"position"),n.initialPointerPosition={left:t.x.client,top:t.y.client},n.startPosition={left:t.x.client-n.initialWindowPosition.left,top:t.y.client-n.initialWindowPosition.top},n.minLeftPosition=o.length>0?p(o)+parseInt(o.css("right"),10)-p(i):20-p(i),n.minLeftPosition-=r.left,n.minTopPosition=-r.top,n.wrapper.append(se.overlay).children(T).hide(),e(w).css(P,t.currentTarget.css(P)))},drag:function(t){var n,i;this._preventDragging||(n=this.owner,i=n.options.position,i.top=Math.max(t.y.client-n.startPosition.top,n.minTopPosition),i.left=Math.max(t.x.client-n.startPosition.left,n.minLeftPosition),l.support.transforms?e(n.wrapper).css("transform","translate("+(t.x.client-n.initialPointerPosition.left)+"px, "+(t.y.client-n.initialPointerPosition.top)+"px)"):e(n.wrapper).css(i))},_finishDrag:function(){var t=this.owner;t.wrapper.children(T).toggle(!t.options.isMinimized).end().find(D).remove(),e(w).css(P,"")},dragcancel:function(e){this._preventDragging||(this._finishDrag(),e.currentTarget.closest(k).css(this.owner.initialWindowPosition))},dragend:function(){if(!this._preventDragging)return e(this.owner.wrapper).css(this.owner.options.position).css("transform",""),this._finishDrag(),this.owner.trigger($),!1},destroy:function(){this._draggable&&this._draggable.destroy(),this._draggable=this.owner=null}},l.ui.plugin(re)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.mobile.view.min",["kendo.core.min","kendo.fx.min","kendo.mobile.scroller.min","kendo.view.min"],e)}(function(){return function(e,t){function n(e){var t,n,i=e.find(k("popover")),o=a.roles;for(t=0,n=i.length;t<n;t++)r.initWidget(i[t],{},o)}function i(e){r.triggeredByInput(e)||e.preventDefault()}function o(t){t.each(function(){r.initWidget(e(this),{},a.roles)})}var r=window.kendo,s=r.mobile,a=s.ui,l=r.attr,c=a.Widget,d=r.ViewClone,u="init",h='<div style="height: 100%; width: 100%; position: absolute; top: 0; left: 0; z-index: 20000; display: none" />',f="beforeShow",p="show",m="afterShow",g="beforeHide",v="transitionEnd",_="transitionStart",b="hide",w="destroy",y=r.attrValue,k=r.roleSelector,x=r.directiveSelector,C=r.compileMobileDirective,S=c.extend({init:function(t,n){c.fn.init.call(this,t,n),this.params={},e.extend(this,n),this.transition=this.transition||this.defaultTransition,this._id(),this.options.$angular?this._overlay():(this._layout(),this._overlay(),this._scroller(),this._model())},events:[u,f,p,m,g,b,w,_,v],options:{name:"View",title:"",layout:null,getLayout:e.noop,reload:!1,transition:"",defaultTransition:"",useNativeScrolling:!1,stretch:!1,zoom:!1,model:null,modelScope:window,scroller:{},initWidgets:!0},enable:function(e){t===e&&(e=!0),e?this.overlay.hide():this.overlay.show()},destroy:function(){this.layout&&this.layout.detach(this),this.trigger(w),c.fn.destroy.call(this),this.scroller&&this.scroller.destroy(),this.options.$angular&&this.element.scope().$destroy(),r.destroy(this.element)},purge:function(){this.destroy(),this.element.remove()},triggerBeforeShow:function(){return!this.trigger(f,{view:this})},triggerBeforeHide:function(){return!this.trigger(g,{view:this})},showStart:function(){var e=this.element;e.css("display",""),this.inited?this._invokeNgController():(this.inited=!0,this.trigger(u,{view:this})),this.layout&&this.layout.attach(this),this._padIfNativeScrolling(),this.trigger(p,{view:this}),r.resize(e)},showEnd:function(){this.trigger(m,{view:this}),this._padIfNativeScrolling()},hideEnd:function(){var e=this;e.element.hide(),e.trigger(b,{view:e}),e.layout&&e.layout.trigger(b,{view:e,layout:e.layout})},beforeTransition:function(e){this.trigger(_,{type:e})},afterTransition:function(e){this.trigger(v,{type:e})},_padIfNativeScrolling:function(){if(s.appLevelNativeScrolling()){var e=r.support.mobileOS&&r.support.mobileOS.android,t=s.application.skin()||"",n=s.application.os.android||t.indexOf("android")>-1,i="flat"===t||t.indexOf("material")>-1,o=!e&&!n||i?"header":"footer",a=!e&&!n||i?"footer":"header";this.content.css({paddingTop:this[o].height(),paddingBottom:this[a].height()})}},contentElement:function(){var e=this;return e.options.stretch?e.content:e.scrollerContent},clone:function(){return new d(this)},_scroller:function(){var t=this;s.appLevelNativeScrolling()||(t.options.stretch?t.content.addClass("km-stretched-view"):(t.content.kendoMobileScroller(e.extend(t.options.scroller,{zoom:t.options.zoom,useNative:t.options.useNativeScrolling})),t.scroller=t.content.data("kendoMobileScroller"),t.scrollerContent=t.scroller.scrollElement),r.support.kineticScrollNeeded&&(e(t.element).on("touchmove",".km-header",i),t.options.useNativeScrolling||t.options.stretch||e(t.element).on("touchmove",".km-content",i)))},_model:function(){var e=this,t=e.element,i=e.options.model;"string"==typeof i&&(i=r.getter(i)(e.options.modelScope)),e.model=i,n(t),e.element.css("display",""),e.options.initWidgets&&(i?r.bind(t,i,a,r.ui,r.dataviz.ui):s.init(t.children())),e.element.css("display","none")},_id:function(){var e=this.element,t=e.attr("id")||"";this.id=y(e,"url")||"#"+t,"#"==this.id&&(this.id=r.guid(),e.attr("id",this.id))},_layout:function(){var e=k("content"),t=this.element;t.addClass("km-view"),this.header=t.children(k("header")).addClass("km-header"),this.footer=t.children(k("footer")).addClass("km-footer"),t.children(e)[0]||t.wrapInner("<div "+l("role")+'="content"></div>'),this.content=t.children(k("content")).addClass("km-content"),this.element.prepend(this.header).append(this.footer),this.layout=this.options.getLayout(this.layout),this.layout&&this.layout.setup(this)},_overlay:function(){this.overlay=e(h).appendTo(this.element)},_invokeNgController:function(){var t,n,i;this.options.$angular&&(t=this.element.controller(),n=this.options.$angular[0],t&&(i=e.proxy(this,"_callController",t,n),/^\$(digest|apply)$/.test(n.$$phase)?i():n.$apply(i)))},_callController:function(e,t){this.element.injector().invoke(e.constructor,e,{$scope:t})}}),T=c.extend({init:function(e,t){c.fn.init.call(this,e,t),e=this.element,this.header=e.children(this._locate("header")).addClass("km-header"),this.footer=e.children(this._locate("footer")).addClass("km-footer"),this.elements=this.header.add(this.footer),n(e),this.options.$angular||r.mobile.init(this.element.children()),this.element.detach(),this.trigger(u,{layout:this})},_locate:function(e){return this.options.$angular?x(e):k(e)},options:{name:"Layout",id:null,platform:null},events:[u,p,b],setup:function(e){e.header[0]||(e.header=this.header),e.footer[0]||(e.footer=this.footer)},detach:function(e){var t=this;e.header===t.header&&t.header[0]&&e.element.prepend(t.header.detach()[0].cloneNode(!0)),e.footer===t.footer&&t.footer.length&&e.element.append(t.footer.detach()[0].cloneNode(!0))},attach:function(e){var t=this,n=t.currentView;n&&t.detach(n),e.header===t.header&&(t.header.detach(),e.element.children(k("header")).remove(),e.element.prepend(t.header)),e.footer===t.footer&&(t.footer.detach(),e.element.children(k("footer")).remove(),e.element.append(t.footer)),t.trigger(p,{layout:t,view:e}),t.currentView=e}}),D=r.Observable,A=/<body[^>]*>(([\u000a\u000d\u2028\u2029]|.)*)<\/body>/i,E="loadStart",M="loadComplete",I="showStart",R="sameViewRequested",F="viewShow",z="viewTypeDetermined",P="after",B=D.extend({init:function(t){var n,i,s,a,l=this;if(D.fn.init.call(l),e.extend(l,t),l.sandbox=e("<div />"),s=l.container,n=l._hideViews(s),l.rootView=n.first(),!l.rootView[0]&&t.rootNeeded)throw i=s[0]==r.mobile.application.element[0]?'Your kendo mobile application element does not contain any direct child elements with data-role="view" attribute set. Make sure that you instantiate the mobile application using the correct container.':'Your pane element does not contain any direct child elements with data-role="view" attribute set.',Error(i);l.layouts={},l.viewContainer=new r.ViewContainer(l.container),l.viewContainer.bind("accepted",function(e){e.view.params=l.params}),l.viewContainer.bind("complete",function(e){l.trigger(F,{view:e.view})}),l.viewContainer.bind(P,function(){l.trigger(P)}),this.getLayoutProxy=e.proxy(this,"_getLayout"),l._setupLayouts(s),a=s.children(l._locate("modalview drawer")),l.$angular?(l.$angular[0].viewOptions={defaultTransition:l.transition,loader:l.loader,container:l.container,getLayout:l.getLayoutProxy},a.each(function(n,i){C(e(i),t.$angular[0])})):o(a),this.bind(this.events,t)},events:[I,P,F,E,M,R,z],destroy:function(){r.destroy(this.container);for(var e in this.layouts)this.layouts[e].destroy()},view:function(){return this.viewContainer.view},showView:function(e,t,n){if(e=e.replace(RegExp("^"+this.remoteViewURLPrefix),""),""===e&&this.remoteViewURLPrefix&&(e="/"),e.replace(/^#/,"")===this.url)return this.trigger(R),!1;this.trigger(I);var i=this,o=function(n){return i.viewContainer.show(n,t,e)},s=i._findViewElement(e),a=r.widgetInstance(s);return i.url=e.replace(/^#/,""),i.params=n,a&&a.reload&&(a.purge(),s=[]),this.trigger(z,{remote:0===s.length,url:e}),s[0]?(a||(a=i._createView(s)),o(a)):(this.serverNavigation?location.href=e:i._loadView(e,o),!0)},append:function(e,t){var n,i,r,s=this.sandbox,a=(t||"").split("?")[0],c=this.container;return A.test(e)&&(e=RegExp.$1),s[0].innerHTML=e,c.append(s.children("script, style")),n=this._hideViews(s),r=n.first(),r.length||(n=r=s.wrapInner("<div data-role=view />").children()),a&&r.hide().attr(l("url"),a),this._setupLayouts(s),i=s.children(this._locate("modalview drawer")),c.append(s.children(this._locate("layout modalview drawer")).add(n)),o(i),this._createView(r)},_locate:function(e){return this.$angular?x(e):k(e)},_findViewElement:function(e){var t,n=e.split("?")[0];return n?(t=this.container.children("["+l("url")+"='"+n+"']"),t[0]||n.indexOf("/")!==-1||(t=this.container.children("#"===n.charAt(0)?n:"#"+n)),t):this.rootView},_createView:function(e){return this.$angular?C(e,this.$angular[0]):r.initWidget(e,{defaultTransition:this.transition,loader:this.loader,container:this.container,getLayout:this.getLayoutProxy,
modelScope:this.modelScope,reload:y(e,"reload")},a.roles)},_getLayout:function(e){return""===e?null:e?this.layouts[e]:this.layouts[this.layout]},_loadView:function(t,n){this._xhr&&this._xhr.abort(),this.trigger(E),this._xhr=e.get(r.absoluteURL(t,this.remoteViewURLPrefix),"html").always(e.proxy(this,"_xhrComplete",n,t))},_xhrComplete:function(e,t,n){var i=!0;if("object"==typeof n&&0===n.status){if(!(n.responseText&&n.responseText.length>0))return;i=!0,n=n.responseText}this.trigger(M),i&&e(this.append(n,t))},_hideViews:function(e){return e.children(this._locate("view splitview")).hide()},_setupLayouts:function(t){var n,i=this;t.children(i._locate("layout")).each(function(){n=i.$angular?C(e(this),i.$angular[0]):r.initWidget(e(this),{},a.roles);var t=n.options.platform;t&&t!==s.application.os.name?n.destroy():i.layouts[n.options.id]=n})}});r.mobile.ViewEngine=B,a.plugin(S),a.plugin(T)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.mobile.loader.min",["kendo.core.min"],e)}(function(){return function(e,t){var n=window.kendo,i=n.mobile.ui,o=i.Widget,r=e.map(n.eventMap,function(e){return e}).join(" ").split(" "),s=o.extend({init:function(t,n){var i=this,r=e('<div class="km-loader"><span class="km-loading km-spin"></span><span class="km-loading-left"></span><span class="km-loading-right"></span></div>');o.fn.init.call(i,r,n),i.container=t,i.captureEvents=!1,i._attachCapture(),r.append(i.options.loading).hide().appendTo(t)},options:{name:"Loader",loading:"<h1>Loading...</h1>",timeout:100},show:function(){var e=this;clearTimeout(e._loading),e.options.loading!==!1&&(e.captureEvents=!0,e._loading=setTimeout(function(){e.element.show()},e.options.timeout))},hide:function(){this.captureEvents=!1,clearTimeout(this._loading),this.element.hide()},changeMessage:function(e){this.options.loading=e,this.element.find(">h1").html(e)},transition:function(){this.captureEvents=!0,this.container.css("pointer-events","none")},transitionDone:function(){this.captureEvents=!1,this.container.css("pointer-events","")},_attachCapture:function(){function e(e){n.captureEvents&&e.preventDefault()}var t,n=this;for(n.captureEvents=!1,t=0;t<r.length;t++)n.container[0].addEventListener(r[t],e,!0)}});i.plugin(s)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.mobile.pane.min",["kendo.mobile.view.min","kendo.mobile.loader.min"],e)}(function(){return function(e,t){var n=window.kendo,i=n.mobile,o=n.roleSelector,r=i.ui,s=r.Widget,a=i.ViewEngine,l=r.View,c=i.ui.Loader,d="external",u="href",h="#!",f="navigate",p="viewShow",m="sameViewRequested",g=n.support.mobileOS,v=g.ios&&!g.appMode&&g.flatVersion>=700,_=/popover|actionsheet|modalview|drawer/,b="#:back",w=n.attrValue,y=s.extend({init:function(e,t){var i=this;s.fn.init.call(i,e,t),t=i.options,e=i.element,e.addClass("km-pane"),i.options.collapsible&&e.addClass("km-collapsible-pane"),this.history=[],this.historyCallback=function(e,t,n){var o=i.transition;return i.transition=null,v&&n&&(o="none"),i.viewEngine.showView(e,o,t)},this._historyNavigate=function(e){if(e===b){if(1===i.history.length)return;i.history.pop(),e=i.history[i.history.length-1]}else i.history.push(e);i.historyCallback(e,n.parseQueryStringParams(e))},this._historyReplace=function(e){var t=n.parseQueryStringParams(e);i.history[i.history.length-1]=e,i.historyCallback(e,t)},i.loader=new c(e,{loading:i.options.loading}),i.viewEngine=new a({container:e,transition:t.transition,modelScope:t.modelScope,rootNeeded:!t.initial,serverNavigation:t.serverNavigation,remoteViewURLPrefix:t.root||"",layout:t.layout,$angular:t.$angular,loader:i.loader,showStart:function(){i.loader.transition(),i.closeActiveDialogs()},after:function(){i.loader.transitionDone()},viewShow:function(e){i.trigger(p,e)},loadStart:function(){i.loader.show()},loadComplete:function(){i.loader.hide()},sameViewRequested:function(){i.trigger(m)},viewTypeDetermined:function(e){e.remote&&i.options.serverNavigation||i.trigger(f,{url:e.url})}}),this._setPortraitWidth(),n.onResize(function(){i._setPortraitWidth()}),i._setupAppLinks()},closeActiveDialogs:function(){var t=this.element.find(o("actionsheet popover modalview")).filter(":visible");t.each(function(){n.widgetInstance(e(this),r).close()})},navigateToInitial:function(){var e=this.options.initial;return e&&this.navigate(e),e},options:{name:"Pane",portraitWidth:"",transition:"",layout:"",collapsible:!1,initial:null,modelScope:window,loading:"<h1>Loading...</h1>"},events:[f,p,m],append:function(e){return this.viewEngine.append(e)},destroy:function(){s.fn.destroy.call(this),this.viewEngine.destroy(),this.userEvents.destroy()},navigate:function(e,t){e instanceof l&&(e=e.id),this.transition=t,this._historyNavigate(e)},replace:function(e,t){e instanceof l&&(e=e.id),this.transition=t,this._historyReplace(e)},bindToRouter:function(e){var t=this,i=this.history,o=this.viewEngine;e.bind("init",function(t){var r,s=t.url,a=e.pushState?s:"/";o.rootView.attr(n.attr("url"),a),r=i.length,"/"===s&&r&&(e.navigate(i[r-1],!0),t.preventDefault())}),e.bind("routeMissing",function(e){t.historyCallback(e.url,e.params,e.backButtonPressed)||e.preventDefault()}),e.bind("same",function(){t.trigger(m)}),t._historyNavigate=function(t){e.navigate(t)},t._historyReplace=function(t){e.replace(t)}},hideLoading:function(){this.loader.hide()},showLoading:function(){this.loader.show()},changeLoadingMessage:function(e){this.loader.changeMessage(e)},view:function(){return this.viewEngine.view()},_setPortraitWidth:function(){var e,t=this.options.portraitWidth;t&&(e=n.mobile.application.element.is(".km-vertical")?t:"auto",this.element.css("width",e))},_setupAppLinks:function(){var t=this,i="tab",r="[data-"+n.ns+"navigate-on-press]",s=e.map(["button","backbutton","detailbutton","listview-link"],function(e){return o(e)+":not("+r+")"}).join(",");this.element.handler(this).on("down",o(i)+","+r,"_mouseup").on("click",o(i)+","+s+","+r,"_appLinkClick"),this.userEvents=new n.UserEvents(this.element,{fastTap:!0,filter:s,tap:function(e){e.event.currentTarget=e.touch.currentTarget,t._mouseup(e.event)}}),this.element.css("-ms-touch-action","")},_appLinkClick:function(t){var n=e(t.currentTarget).attr("href"),i=n&&"#"!==n[0]&&this.options.serverNavigation;i||w(e(t.currentTarget),"rel")==d||t.preventDefault()},_mouseup:function(o){if(!(o.which>1||o.isDefaultPrevented())){var s=this,a=e(o.currentTarget),l=w(a,"transition"),c=w(a,"rel")||"",f=w(a,"target"),p=a.attr(u),m=v&&0===a[0].offsetHeight,g=p&&"#"!==p[0]&&this.options.serverNavigation;m||g||c===d||t===p||p===h||(a.attr(u,h),setTimeout(function(){a.attr(u,p)}),c.match(_)?(n.widgetInstance(e(p),r).openFor(a),"actionsheet"!==c&&"drawer"!==c||o.stopPropagation()):("_top"===f?s=i.application.pane:f&&(s=e("#"+f).data("kendoMobilePane")),s.navigate(p,l)),o.preventDefault())}}});y.wrap=function(e){e.is(o("view"))||(e=e.wrap("<div data-"+n.ns+'role="view" data-stretch="true"></div>').parent());var t=e.wrap('<div class="km-pane-wrapper"><div></div></div>').parent(),i=new y(t);return i.navigate(""),i},r.plugin(y)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.mobile.popover.min",["kendo.popup.min","kendo.mobile.pane.min"],e)}(function(){return function(e,t){var n=window.kendo,i=n.mobile,o=i.ui,r="hide",s="open",a="close",l='<div class="km-popup-wrapper" />',c='<div class="km-popup-arrow" />',d='<div class="km-popup-overlay" />',u="km-up km-down km-left km-right",h=o.Widget,f={down:{origin:"bottom center",position:"top center"},up:{origin:"top center",position:"bottom center"},left:{origin:"center left",position:"center right",collision:"fit flip"},right:{origin:"center right",position:"center left",collision:"fit flip"}},p={animation:{open:{effects:"fade:in",duration:0},close:{effects:"fade:out",duration:400}}},m={horizontal:{offset:"top",size:"height"},vertical:{offset:"left",size:"width"}},g={up:"down",down:"up",left:"right",right:"left"},v=h.extend({init:function(t,i){var o,s,a=this,u=t.closest(".km-modalview-wrapper"),g=t.closest(".km-root").children(".km-pane").first(),v=u[0]?u:g;i.viewport?g=i.viewport:g[0]||(g=window),i.container?v=i.container:v[0]||(v=document.body),o={viewport:g,copyAnchorStyles:!1,autosize:!0,open:function(){a.overlay.show()},activate:e.proxy(a._activate,a),deactivate:function(){a.overlay.hide(),a._apiCall||a.trigger(r),a._apiCall=!1}},h.fn.init.call(a,t,i),t=a.element,i=a.options,t.wrap(l).addClass("km-popup").show(),s=a.options.direction.match(/left|right/)?"horizontal":"vertical",a.dimensions=m[s],a.wrapper=t.parent().css({width:i.width,height:i.height}).addClass("km-popup-wrapper km-"+i.direction).hide(),a.arrow=e(c).prependTo(a.wrapper).hide(),a.overlay=e(d).appendTo(v).hide(),o.appendTo=a.overlay,i.className&&a.overlay.addClass(i.className),a.popup=new n.ui.Popup(a.wrapper,e.extend(!0,o,p,f[i.direction]))},options:{name:"Popup",width:240,height:"",direction:"down",container:null,viewport:null},events:[r],show:function(t){this.popup.options.anchor=e(t),this.popup.open()},hide:function(){this._apiCall=!0,this.popup.close()},destroy:function(){h.fn.destroy.call(this),this.popup.destroy(),this.overlay.remove()},target:function(){return this.popup.options.anchor},_activate:function(){var t=this,n=t.options.direction,i=t.dimensions,o=i.offset,r=t.popup,s=r.options.anchor,a=e(s).offset(),l=e(r.element).offset(),c=r.flipped?g[n]:n,d=2*t.arrow[i.size](),h=t.element[i.size]()-t.arrow[i.size](),f=e(s)[i.size](),p=a[o]-l[o]+f/2;p<d&&(p=d),p>h&&(p=h),t.wrapper.removeClass(u).addClass("km-"+c),t.arrow.css(o,p).show()}}),_=h.extend({init:function(t,i){var r,s=this;s.initialOpen=!1,h.fn.init.call(s,t,i),r=e.extend({className:"km-popover-root",hide:function(){s.trigger(a)}},this.options.popup),s.popup=new v(s.element,r),s.popup.overlay.on("move",function(e){e.target==s.popup.overlay[0]&&e.preventDefault()}),s.pane=new o.Pane(s.element,e.extend(this.options.pane,{$angular:this.options.$angular})),n.notify(s,o)},options:{name:"PopOver",popup:{},pane:{}},events:[s,a],open:function(e){this.popup.show(e),this.initialOpen?this.pane.view()._invokeNgController():(this.pane.navigateToInitial()||this.pane.navigate(""),this.popup.popup._position(),this.initialOpen=!0)},openFor:function(e){this.open(e),this.trigger(s,{target:this.popup.target()})},close:function(){this.popup.hide()},destroy:function(){h.fn.destroy.call(this),this.pane.destroy(),this.popup.destroy(),n.destroy(this.element)}});o.plugin(v),o.plugin(_)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.mobile.shim.min",["kendo.popup.min"],e)}(function(){return function(e,t){var n=window.kendo,i=n.mobile.ui,o=n.ui.Popup,r='<div class="km-shim"/>',s="hide",a=i.Widget,l=a.extend({init:function(t,i){var l=this,c=n.mobile.application,d=n.support.mobileOS,u=c?c.os.name:d?d.name:"ios",h="ios"===u||"wp"===u||!!c&&c.os.skin,f="blackberry"===u,p=i.align||(h?"bottom center":f?"center right":"center center"),m=i.position||(h?"bottom center":f?"center right":"center center"),g=i.effect||(h?"slideIn:up":f?"slideIn:left":"fade:in"),v=e(r).handler(l).hide();a.fn.init.call(l,t,i),l.shim=v,t=l.element,i=l.options,i.className&&l.shim.addClass(i.className),i.modal||l.shim.on("down","_hide"),(c?c.element:e(document.body)).append(v),l.popup=new o(l.element,{anchor:v,modal:!0,appendTo:v,origin:p,position:m,animation:{open:{effects:g,duration:i.duration},close:{duration:i.duration}},close:function(e){var t=!1;l._apiCall||(t=l.trigger(s)),t&&e.preventDefault(),l._apiCall=!1},deactivate:function(){v.hide()},open:function(){v.show()}}),n.notify(l)},events:[s],options:{name:"Shim",modal:!1,align:t,position:t,effect:t,duration:200},show:function(){this.popup.open()},hide:function(){this._apiCall=!0,this.popup.close()},destroy:function(){a.fn.destroy.call(this),this.shim.kendoDestroy(),this.popup.destroy(),this.shim.remove()},_hide:function(t){t&&e.contains(this.shim.children().children(".k-popup")[0],t.target)||this.popup.close()}});i.plugin(l)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.mobile.actionsheet.min",["kendo.mobile.popover.min","kendo.mobile.shim.min"],e)}(function(){return function(e,t){var n=window.kendo,i=n.support,o=n.mobile.ui,r=o.Shim,s=o.Popup,a=o.Widget,l="open",c="close",d="command",u="li>a",h="actionsheetContext",f='<div class="km-actionsheet-wrapper" />',p=n.template('<li class="km-actionsheet-cancel"><a href="\\#">#:cancel#</a></li>'),m=a.extend({init:function(t,l){var c,d,h,m=this,g=i.mobileOS;a.fn.init.call(m,t,l),l=m.options,h=l.type,t=m.element,d="auto"===h?g&&g.tablet:"tablet"===h,c=d?s:r,l.cancelTemplate&&(p=n.template(l.cancelTemplate)),t.addClass("km-actionsheet").append(p({cancel:m.options.cancel})).wrap(f).on("up",u,"_click").on("click",u,n.preventDefault),m.view().bind("destroy",function(){m.destroy()}),m.wrapper=t.parent().addClass(h?" km-actionsheet-"+h:""),m.shim=new c(m.wrapper,e.extend({modal:g.ios&&g.majorVersion<7,className:"km-actionsheet-root"},m.options.popup)),m._closeProxy=e.proxy(m,"_close"),m._shimHideProxy=e.proxy(m,"_shimHide"),m.shim.bind("hide",m._shimHideProxy),d&&n.onResize(m._closeProxy),n.notify(m,o)},events:[l,c,d],options:{name:"ActionSheet",cancel:"Cancel",type:"auto",popup:{height:"auto"}},open:function(t,n){var i=this;i.target=e(t),i.context=n,i.shim.show(t)},close:function(){this.context=this.target=null,this.shim.hide()},openFor:function(e){var t=this,n=e.data(h);t.open(e,n),t.trigger(l,{target:e,context:n})},destroy:function(){a.fn.destroy.call(this),n.unbindResize(this._closeProxy),this.shim.destroy()},_click:function(t){var i,o,r,s;t.isDefaultPrevented()||(i=e(t.currentTarget),o=i.data("action"),o&&(r={target:this.target,context:this.context},s=this.options.$angular,s?this.element.injector().get("$parse")(o)(s[0])(r):n.getter(o)(window)(r)),this.trigger(d,{target:this.target,context:this.context,currentTarget:i}),t.preventDefault(),this._close())},_shimHide:function(e){this.trigger(c)?e.preventDefault():this.context=this.target=null},_close:function(e){this.trigger(c)?e.preventDefault():this.close()}});o.plugin(m)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.progressbar.min",["kendo.core.min"],e)}(function(){return function(e,t){var n=window.kendo,i=n.ui,o=i.Widget,r="horizontal",s="vertical",a=0,l=100,c=0,d=5,u="k-progressbar",h="k-progressbar-reverse",f="k-progressbar-indeterminate",p="k-complete",m="k-state-selected",g="k-progress-status",v="k-state-selected",_="k-state-default",b="k-state-disabled",w={VALUE:"value",PERCENT:"percent",CHUNK:"chunk"},y="change",k="complete",x="boolean",C=Math,S=e.extend,T=e.proxy,D=100,A=400,E=3,M={progressStatus:"<span class='k-progress-status-wrap'><span class='k-progress-status'></span></span>"},I=o.extend({init:function(e,t){var n=this;o.fn.init.call(this,e,t),t=n.options,n._progressProperty=t.orientation===r?"width":"height",n._fields(),t.value=n._validateValue(t.value),n._validateType(t.type),n._wrapper(),n._progressAnimation(),t.value!==t.min&&t.value!==!1&&n._updateProgress()},setOptions:function(e){var t=this;o.fn.setOptions.call(t,e),e.hasOwnProperty("reverse")&&t.wrapper.toggleClass("k-progressbar-reverse",e.reverse),e.hasOwnProperty("enable")&&t.enable(e.enable),t._progressAnimation(),t._validateValue(),t._updateProgress()},events:[y,k],options:{name:"ProgressBar",orientation:r,reverse:!1,min:a,max:l,value:c,enable:!0,type:w.VALUE,chunkCount:d,showStatus:!0,animation:{}},_fields:function(){var t=this;t._isStarted=!1,t.progressWrapper=t.progressStatus=e()},_validateType:function(t){var i=!1;if(e.each(w,function(e,n){if(n===t)return i=!0,!1}),!i)throw Error(n.format("Invalid ProgressBar type '{0}'",t))},_wrapper:function(){var e,t=this,n=t.wrapper=t.element,i=t.options,o=i.orientation;n.addClass("k-widget "+u),n.addClass(u+"-"+(o===r?r:s)),i.enable===!1&&n.addClass(b),i.reverse&&n.addClass(h),i.value===!1&&n.addClass(f),i.type===w.CHUNK?t._addChunkProgressWrapper():i.showStatus&&(t.progressStatus=t.wrapper.prepend(M.progressStatus).find("."+g),e=i.value!==!1?i.value:i.min,t.progressStatus.text(i.type===w.VALUE?e:t._calculatePercentage(e).toFixed()+"%"))},value:function(e){return this._value(e)},_value:function(e){var n,i=this,o=i.options;return e===t?o.value:(typeof e!==x?(e=i._roundValue(e),isNaN(e)||(n=i._validateValue(e),n!==o.value&&(i.wrapper.removeClass(f),o.value=n,i._isStarted=!0,i._updateProgress()))):e||(i.wrapper.addClass(f),o.value=!1),t)},_roundValue:function(e){e=parseFloat(e);var t=C.pow(10,E);return C.floor(e*t)/t},_validateValue:function(e){var t=this,n=t.options;if(e!==!1){if(e<=n.min||e===!0)return n.min;if(e>=n.max)return n.max}else if(e===!1)return!1;return isNaN(t._roundValue(e))?n.min:e},_updateProgress:function(){var e=this,t=e.options,n=e._calculatePercentage();t.type===w.CHUNK?(e._updateChunks(n),e._onProgressUpdateAlways(t.value)):e._updateProgressWrapper(n)},_updateChunks:function(e){var t,n=this,i=n.options,o=i.chunkCount,a=parseInt(D/o*100,10)/100,l=parseInt(100*e,10)/100,c=C.floor(l/a);t=n.wrapper.find(i.orientation===r&&!i.reverse||i.orientation===s&&i.reverse?"li.k-item:lt("+c+")":"li.k-item:gt(-"+(c+1)+")"),n.wrapper.find("."+v).removeClass(v).addClass(_),t.removeClass(_).addClass(v)},_updateProgressWrapper:function(e){var t=this,n=t.options,i=t.wrapper.find("."+m),o=t._isStarted?t._animation.duration:0,r={};0===i.length&&t._addRegularProgressWrapper(),r[t._progressProperty]=e+"%",t.progressWrapper.animate(r,{duration:o,start:T(t._onProgressAnimateStart,t),progress:T(t._onProgressAnimate,t),complete:T(t._onProgressAnimateComplete,t,n.value),always:T(t._onProgressUpdateAlways,t,n.value)})},_onProgressAnimateStart:function(){this.progressWrapper.show()},_onProgressAnimate:function(e){var t,n=this,i=n.options,o=parseFloat(e.elem.style[n._progressProperty],10);i.showStatus&&(t=1e4/parseFloat(n.progressWrapper[0].style[n._progressProperty]),n.progressWrapper.find(".k-progress-status-wrap").css(n._progressProperty,t+"%")),i.type!==w.CHUNK&&o<=98&&n.progressWrapper.removeClass(p)},_onProgressAnimateComplete:function(e){var t,n=this,i=n.options,o=parseFloat(n.progressWrapper[0].style[n._progressProperty]);i.type!==w.CHUNK&&o>98&&n.progressWrapper.addClass(p),i.showStatus&&(t=i.type===w.VALUE?e:i.type==w.PERCENT?n._calculatePercentage(e).toFixed()+"%":C.floor(n._calculatePercentage(e))+"%",n.progressStatus.text(t)),e===i.min&&n.progressWrapper.hide()},_onProgressUpdateAlways:function(e){var t=this,n=t.options;t._isStarted&&t.trigger(y,{value:e}),e===n.max&&t._isStarted&&t.trigger(k,{value:n.max})},enable:function(e){var n=this,i=n.options;i.enable=t===e||e,n.wrapper.toggleClass(b,!i.enable)},destroy:function(){var e=this;o.fn.destroy.call(e)},_addChunkProgressWrapper:function(){var e,t=this,n=t.options,i=t.wrapper,o=D/n.chunkCount,r="";for(n.chunkCount<=1&&(n.chunkCount=1),r+="<ul class='k-reset'>",e=n.chunkCount-1;e>=0;e--)r+="<li class='k-item k-state-default'></li>";r+="</ul>",i.append(r).find(".k-item").css(t._progressProperty,o+"%").first().addClass("k-first").end().last().addClass("k-last"),t._normalizeChunkSize()},_normalizeChunkSize:function(){var e=this,t=e.options,n=e.wrapper.find(".k-item:last"),i=parseFloat(n[0].style[e._progressProperty]),o=D-t.chunkCount*i;o>0&&n.css(e._progressProperty,i+o+"%")},_addRegularProgressWrapper:function(){var t=this;t.progressWrapper=e("<div class='"+m+"'></div>").appendTo(t.wrapper),t.options.showStatus&&(t.progressWrapper.append(M.progressStatus),t.progressStatus=t.wrapper.find("."+g))},_calculateChunkSize:function(){var e=this,t=e.options.chunkCount,n=e.wrapper.find("ul.k-reset");return(parseInt(n.css(e._progressProperty),10)-(t-1))/t},_calculatePercentage:function(e){var n=this,i=n.options,o=e!==t?e:i.value,r=i.min,s=i.max;return n._onePercent=C.abs((s-r)/100),C.abs((o-r)/n._onePercent)},_progressAnimation:function(){var e=this,t=e.options,n=t.animation;e._animation=n===!1?{duration:0}:S({duration:A},t.animation)}});n.ui.plugin(I)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("pdf/core.min",["kendo.core.min","kendo.color.min","kendo.drawing.min"],e)}(function(){return function(e){function t(e){function t(){return S>=T}function n(){return S<T?e[S++]:0}function i(t){w(S),e[S++]=255&t,S>T&&(T=S)}function o(){return n()<<8|n()}function r(e){i(e>>8),i(e)}function s(){var e=o();return e>=32768?e-65536:e}function a(e){r(e<0?e+65536:e)}function l(){return 65536*o()+o()}function c(e){r(e>>>16&65535),r(65535&e)}function d(){var e=l();return e>=2147483648?e-4294967296:e}function u(e){c(e<0?e+4294967296:e)}function h(){return l()/65536}function f(e){c(Math.round(65536*e))}function p(){return d()/65536}function m(e){u(Math.round(65536*e))}function g(e){return b(e,n)}function v(e){return String.fromCharCode.apply(String,g(e))}function _(e){for(var t=0;t<e.length;++t)i(e.charCodeAt(t))}function b(e,t){for(var n=Array(e),i=0;i<e;++i)n[i]=t();return n}var w,y,k,x,C,S=0,T=0;return null==e?e=Ce?new Uint8Array(256):[]:T=e.length,w=Ce?function(t){if(t>=e.length){var n=new Uint8Array(Math.max(t+256,2*e.length));n.set(e,0),e=n}}:function(){},y=Ce?function(){return new Uint8Array(e.buffer,0,T)}:function(){return e},k=Ce?function(t){if("string"==typeof t)return _(t);var n=t.length;w(S+n),e.set(t,S),S+=n,S>T&&(T=S)}:function(e){if("string"==typeof e)return _(e);for(var t=0;t<e.length;++t)i(e[t])},x=Ce?function(t,n){if(e.buffer.slice)return new Uint8Array(e.buffer.slice(t,t+n));var i=new Uint8Array(n);return i.set(new Uint8Array(e.buffer,t,n)),i}:function(t,n){return e.slice(t,t+n)},C={eof:t,readByte:n,writeByte:i,readShort:o,writeShort:r,readLong:l,writeLong:c,readFixed:h,writeFixed:f,readShort_:s,writeShort_:a,readLong_:d,writeLong_:u,readFixed_:p,writeFixed_:m,read:g,write:k,readString:v,writeString:_,times:b,get:y,slice:x,offset:function(e){return null!=e?(S=e,C):S},skip:function(e){S+=e},toString:function(){throw Error("FIX CALLER.  BinaryStream is no longer convertible to string!")},length:function(){return T},saveExcursion:function(e){var t=S;try{return e()}finally{S=t}},writeBase64:function(e){window.atob?_(window.atob(e)):k(Se.decode(e))},base64:function(){return Se.encode(y())}}}function n(e){for(var t,n,i=[],o=0,r=e.length;o<r;)t=e.charCodeAt(o++),t>=55296&&t<=56319&&o<r?(n=e.charCodeAt(o++),56320==(64512&n)?i.push(((1023&t)<<10)+(1023&n)+65536):(i.push(t),o--)):i.push(t);return i}function i(e){return e.map(function(e){var t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|1023&e),t+=String.fromCharCode(e)}).join("")}function o(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function r(e){return Object.keys(e).sort(function(e,t){return e-t}).map(parseFloat)}function s(e){var t,n,i;for(this.raw=e,this.scalerType=e.readLong(),this.tableCount=e.readShort(),this.searchRange=e.readShort(),this.entrySelector=e.readShort(),this.rangeShift=e.readShort(),t=this.tables={},n=0;n<this.tableCount;++n)i={tag:e.readString(4),checksum:e.readLong(),offset:e.readLong(),length:e.readLong()},t[i.tag]=i}function a(e){function t(e,t){this.definition=t,this.length=t.length,this.offset=t.offset,this.file=e,this.rawData=e.raw,this.parse(e.raw)}t.prototype.raw=function(){return this.rawData.slice(this.offset,this.length)};for(var n in e)o(e,n)&&(t[n]=t.prototype[n]=e[n]);return t}function l(){var e,t="",n=Be+"";for(e=0;e<n.length;++e)t+=String.fromCharCode(n.charCodeAt(e)-48+65);return++Be,t}function c(e){this.font=e,this.subset={},this.unicodes={},this.ogid2ngid={0:0},this.ngid2ogid={0:0},this.ncid2ogid={},this.next=this.firstChar=1,this.nextGid=1,this.psName=l()+"+"+this.font.psName}function d(e,n){var i,o,r,s,a=this,l=a.contents=t(e);if("ttcf"==l.readString(4)){if(o=function(){l.offset(i),a.parse()},!n)throw Error("Must specify a name for TTC files");for(l.readLong(),r=l.readLong(),s=0;s<r;++s)if(i=l.readLong(),l.saveExcursion(o),a.psName==n)return;throw Error("Font "+n+" not found in collection")}l.offset(0),a.parse()}function u(){function e(){var t,n,o,r=arguments;for(t=0;t<arguments.length;++t){if(n=r[t],void 0===n)throw Error("Cannot output undefined to PDF");if(n instanceof E)n.beforeRender(e),n.render(e);else if(Ge(n))x(n,e);else if(k(n))C(n,e);else if("number"==typeof n){if(isNaN(n))throw Error("Cannot output NaN to PDF");o=n.toFixed(7),o.indexOf(".")>=0&&(o=o.replace(/\.?0+$/,"")),"-0"==o&&(o="0"),i.writeString(o)}else/string|boolean/.test(typeof n)?i.writeString(n+""):"function"==typeof n.get?i.write(n.get()):"object"==typeof n&&(n?e(new Xe(n)):i.writeString("null"))}}var n=0,i=t();return e.writeData=function(e){i.write(e)},e.withIndent=function(t){++n,t(e),--n},e.indent=function(){e(Ne,b("",2*n,"  ")),e.apply(null,arguments)},e.offset=function(){return i.offset()},e.toString=function(){throw Error("FIX CALLER")},e.get=function(){return i.get()},e.stream=function(){return i},e}function h(e,t){var n=e.beforeRender,i=e.render;e.beforeRender=function(){},e.render=function(e){e(t," 0 R")},e.renderFull=function(o){e._offset=o.offset(),o(t," 0 obj "),n.call(e,o),i.call(e,o),o(" endobj")}}function f(e){var t,n,i;if("function"!=typeof e&&(t=e,e=function(e,n){return e in t?t[e]:n}),n=e("paperSize",Ve.a4),!n)return{};if("string"==typeof n&&(n=Ve[n.toLowerCase()],null==n))throw Error("Unknown paper size");return n[0]=A(n[0]),n[1]=A(n[1]),e("landscape",!1)&&(n=[Math.max(n[0],n[1]),Math.min(n[0],n[1])]),i=e("margin"),i&&("string"==typeof i||"number"==typeof i?(i=A(i,0),i={left:i,top:i,right:i,bottom:i}):i={left:A(i.left,0),top:A(i.top,0),right:A(i.right,0),bottom:A(i.bottom,0)},e("addMargin")&&(n[0]+=i.left+i.right,n[1]+=i.top+i.bottom)),{paperSize:n,margin:i}}function p(e){function t(t,n){return e&&null!=e[t]?e[t]:n}var n,i,o=this,r=u(),s=0,a=[];o.getOption=t,o.attach=function(e){return a.indexOf(e)<0&&(h(e,++s),a.push(e)),e},o.pages=[],o.FONTS={},o.IMAGES={},o.GRAD_COL_FUNCTIONS={},o.GRAD_OPC_FUNCTIONS={},o.GRAD_COL={},o.GRAD_OPC={},n=o.attach(new Je),i=o.attach(new et),n.setPages(i),o.addPage=function(e){var t,n,r,s=f(function(t,n){return e&&null!=e[t]?e[t]:n}),a=s.paperSize,l=s.margin,c=a[0],d=a[1];return l&&(c-=l.left+l.right,d-=l.top+l.bottom),t=new Ze(u(),null,(!0)),n={Contents:o.attach(t),Parent:i,MediaBox:[0,0,a[0],a[1]]},r=new rt(o,n),r._content=t,i.addPage(o.attach(r)),r.transform(1,0,0,-1,0,a[1]),l&&(r.translate(l.left,l.top),r.rect(0,0,c,d),r.clip()),o.pages.push(r),r},o.render=function(){var e,i;for(r("%PDF-1.4",Ne,"%ÂÁÚÏÎ",Ne,Ne),e=0;e<a.length;++e)a[e].renderFull(r),r(Ne,Ne);for(i=r.offset(),r("xref",Ne,0," ",a.length+1,Ne),r("0000000000 65535 f ",Ne),e=0;e<a.length;++e)r(w(a[e]._offset,10)," 00000 n ",Ne);return r(Ne),r("trailer",Ne),r(new Xe({Size:a.length+1,Root:n,Info:new Xe({Producer:new $e(t("producer","Kendo UI PDF Generator")),Title:new $e(t("title","")),Author:new $e(t("author","")),Subject:new $e(t("subject","")),Keywords:new $e(t("keywords","")),Creator:new $e(t("creator","Kendo UI PDF Generator")),CreationDate:t("date",new Date)})}),Ne,Ne),r("startxref",Ne,i,Ne),r("%%EOF",Ne),r.stream().offset(0)}}function m(e,t){function n(){window.console&&(window.console.error?window.console.error("Cannot load URL: %s",e):window.console.log("Cannot load URL: %s",e)),t(null)}var i=new XMLHttpRequest;i.open("GET",e,!0),He&&(i.responseType="arraybuffer"),i.onload=function(){200==i.status||304==i.status?t(He?new Uint8Array(i.response):new window.VBArray(i.responseBody).toArray()):n()},i.onerror=n,i.send(null)}function g(e,t){var n=Ue[e];n?t(n):m(e,function(n){if(null==n)throw Error("Cannot load font from "+e);var i=new d(n);Ue[e]=i,t(i)})}function v(e,n){function i(e){c.src=e,c.complete&&!Le.msie?r():(c.onload=r,c.onerror=o)}function o(){n(We[e]="TAINTED")}function r(){var i,r,l,d,u,h,f,p,m,g,v,_;if(a&&/^image\/jpe?g$/i.test(a.type))return i=new FileReader,i.onload=function(){c=new R(t(new Uint8Array(this.result))),URL.revokeObjectURL(s),n(We[e]=c)},void i.readAsArrayBuffer(a);r=document.createElement("canvas"),r.width=c.width,r.height=c.height,l=r.getContext("2d"),l.drawImage(c,0,0);try{d=l.getImageData(0,0,c.width,c.height)}catch(b){return void o()}finally{s&&URL.revokeObjectURL(s)}for(u=!1,h=t(),f=t(),p=d.data,m=0;m<p.length;)h.writeByte(p[m++]),h.writeByte(p[m++]),h.writeByte(p[m++]),g=p[m++],g<255&&(u=!0),f.writeByte(g);u?c=new F(c.width,c.height,h,f):(v=r.toDataURL("image/jpeg"),v=v.substr(v.indexOf(";base64,")+8),_=t(),_.writeBase64(v),c=new R(_)),n(We[e]=c)}var s,a,l,c=We[e];c?n(c):(c=new Image,/^data:/i.test(e)||(c.crossOrigin="Anonymous"),He&&!/^data:/i.test(e)?(l=new XMLHttpRequest,l.onload=function(){a=l.response,s=URL.createObjectURL(a),i(s)},l.onerror=o,l.open("GET",e,!0),l.responseType="blob",l.send()):i(e))}function _(e){return function(t,n){function i(){0===--o&&n()}var o=t.length,r=o;if(0===o)return n();for(;r-- >0;)e(t[r],i)}}function b(e,t,n){for(;e.length<t;)e=n+e;return e}function w(e,t){return b(e+"",t,"0")}function y(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function k(e){return e instanceof Date}function x(e,t){t("["),e.length>0&&t.withIndent(function(){for(var n=0;n<e.length;++n)n>0&&n%8===0?t.indent(e[n]):t(" ",e[n])}),t(" ]")}function C(e,t){t("(D:",w(e.getUTCFullYear(),4),w(e.getUTCMonth()+1,2),w(e.getUTCDate(),2),w(e.getUTCHours(),2),w(e.getUTCMinutes(),2),w(e.getUTCSeconds(),2),"Z)")}function S(e){return e*(72/25.4)}function T(e){return S(10*e)}function D(e){return 72*e}function A(e,t){var n,i;if("number"==typeof e)return e;if("string"==typeof e&&(n=/^\s*([0-9.]+)\s*(mm|cm|in|pt)\s*$/.exec(e),n&&(i=parseFloat(n[1]),!isNaN(i))))return"pt"==n[2]?i:{mm:S,cm:T,"in":D}[n[2]](i);if(null!=t)return t;throw Error("Can't parse unit: "+e)}function E(){}function M(e,t,n){n||(n=E),e.prototype=new n;for(var i in t)y(t,i)&&(e.prototype[i]=t[i]);return e}function I(e){return y(Qe,e)?Qe[e]:Qe[e]=new Ke(e)}function R(e){var t,n,i,o,r,s,a,l,c;if(e.offset(0),r=e.readShort(),65496!=r)throw Error("Invalid JPEG image");for(;!e.eof();){if(s=e.readByte(),255!=s)throw Error("Invalid JPEG image");if(a=e.readByte(),l=e.readShort(),tt.indexOf(a)>=0){o=e.readByte(),n=e.readShort(),t=e.readShort(),i=e.readByte();break}e.skip(l-2)}if(null==i)throw Error("Invalid JPEG image");switch(c={Type:I("XObject"),Subtype:I("Image"),Width:t,Height:n,BitsPerComponent:o,Filter:I("DCTDecode")},i){case 1:c.ColorSpace=I("DeviceGray");break;case 3:c.ColorSpace=I("DeviceRGB");break;case 4:c.ColorSpace=I("DeviceCMYK"),c.Decode=[1,0,1,0,1,0,1,0]}this.asStream=function(){e.offset(0);var t=new Ze(e,c);return t._resourceName=I("I"+ ++Oe),t}}function F(e,t,n,i){this.asStream=function(o){var r=new Ze(i,{Type:I("XObject"),Subtype:I("Image"),Width:e,Height:t,BitsPerComponent:8,ColorSpace:I("DeviceGray")},(!0)),s=new Ze(n,{Type:I("XObject"),Subtype:I("Image"),Width:e,Height:t,BitsPerComponent:8,ColorSpace:I("DeviceRGB"),SMask:o.attach(r)},(!0));return s._resourceName=I("I"+ ++Oe),s}}function z(e){return e.map(function(e){return Ge(e)?z(e):"number"==typeof e?(Math.round(1e3*e)/1e3).toFixed(3):e}).join(" ")}function P(e,t,n,i,o,r,s){var a=z([t,n,i,o,r,s]),l=e.GRAD_COL_FUNCTIONS[a];return l||(l=e.GRAD_COL_FUNCTIONS[a]=e.attach(new Xe({FunctionType:2,Domain:[0,1],Range:[0,1,0,1,0,1],N:1,C0:[t,n,i],C1:[o,r,s]}))),l}function B(e,t,n){var i=z([t,n]),o=e.GRAD_OPC_FUNCTIONS[i];return o||(o=e.GRAD_OPC_FUNCTIONS[i]=e.attach(new Xe({FunctionType:2,Domain:[0,1],Range:[0,1],N:1,C0:[t],C1:[n]}))),o}function L(e,t){function n(e){return 1==e.length?e[0]:{FunctionType:3,Functions:e,Domain:[0,1],Bounds:u,Encode:h}}var i,o,r,s,a,l=!1,c=[],d=[],u=[],h=[];for(i=1;i<t.length;++i)o=t[i-1],r=t[i],s=o.color,a=r.color,d.push(P(e,s.r,s.g,s.b,a.r,a.g,a.b)),(s.a<1||a.a<1)&&(l=!0),u.push(r.offset),
h.push(0,1);if(l)for(i=1;i<t.length;++i)o=t[i-1],r=t[i],s=o.color,a=r.color,c.push(B(e,s.a,a.a));return u.pop(),{hasAlpha:l,colors:n(d),opacities:l?n(c):null}}function H(e,t,n,i,o,r){var s,a,l;return r||(l=[t].concat(i),n.forEach(function(e){l.push(e.offset,e.color.r,e.color.g,e.color.b)}),a=z(l),s=e.GRAD_COL[a]),s||(s=new Xe({Type:I("Shading"),ShadingType:t?3:2,ColorSpace:I("DeviceRGB"),Coords:i,Domain:[0,1],Function:o,Extend:[!0,!0]}),e.attach(s),s._resourceName="S"+ ++Oe,a&&(e.GRAD_COL[a]=s)),s}function N(e,t,n,i,o,r){var s,a,l;return r||(l=[t].concat(i),n.forEach(function(e){l.push(e.offset,e.color.a)}),a=z(l),s=e.GRAD_OPC[a]),s||(s=new Xe({Type:I("ExtGState"),AIS:!1,CA:1,ca:1,SMask:{Type:I("Mask"),S:I("Luminosity"),G:e.attach(new Ze("/a0 gs /s0 sh",{Type:I("XObject"),Subtype:I("Form"),FormType:1,BBox:r?[r.left,r.top+r.height,r.left+r.width,r.top]:[0,1,1,0],Group:{Type:I("Group"),S:I("Transparency"),CS:I("DeviceGray"),I:!0},Resources:{ExtGState:{a0:{CA:1,ca:1}},Shading:{s0:{ColorSpace:I("DeviceGray"),Coords:i,Domain:[0,1],ShadingType:t?3:2,Function:o,Extend:[!0,!0]}}}}))}}),e.attach(s),s._resourceName="O"+ ++Oe,a&&(e.GRAD_OPC[a]=s)),s}function O(e,t,n){var i="radial"==t.type,o=L(e,t.stops),r=i?[t.start.x,t.start.y,t.start.r,t.end.x,t.end.y,t.end.r]:[t.start.x,t.start.y,t.end.x,t.end.y],s=H(e,i,t.stops,r,o.colors,t.userSpace&&n),a=o.hasAlpha?N(e,i,t.stops,r,o.opacities,t.userSpace&&n):null;return{hasAlpha:o.hasAlpha,shading:s,opacity:a}}function V(e){return e.replace(/^\s*(['"])(.*)\1\s*$/,"$2")}function U(e){var t,n=/^\s*((normal|italic)\s+)?((normal|small-caps)\s+)?((normal|bold|\d+)\s+)?(([0-9.]+)(px|pt))(\/(([0-9.]+)(px|pt)|normal))?\s+(.*?)\s*$/i,i=n.exec(e);return i?(t=i[8]?parseInt(i[8],10):12,{italic:i[2]&&"italic"==i[2].toLowerCase(),variant:i[4],bold:i[6]&&/bold|700/i.test(i[6]),fontSize:t,lineHeight:i[12]?"normal"==i[12]?t:parseInt(i[12],10):null,fontFamily:i[14].split(/\s*,\s*/g).map(V)}):{fontSize:12,fontFamily:"sans-serif"}}function W(e){function t(t){return e.bold&&(t+="|bold"),e.italic&&(t+="|italic"),t.toLowerCase()}var n,i,o,r=e.fontFamily;if(r instanceof Array)for(o=0;o<r.length&&(n=t(r[o]),!(i=st[n]));++o);else i=st[r.toLowerCase()];for(;"function"==typeof i;)i=i();return i||(i="Times-Roman"),i}function q(e,t){e=e.toLowerCase(),st[e]=function(){return st[t]},st[e+"|bold"]=function(){return st[t+"|bold"]},st[e+"|italic"]=function(){return st[t+"|italic"]},st[e+"|bold|italic"]=function(){return st[t+"|bold|italic"]}}function j(e,t){if(1==arguments.length)for(var n in e)y(e,n)&&j(n,e[n]);else switch(e=e.toLowerCase(),st[e]=t,e){case"dejavu sans":st["sans-serif"]=t;break;case"dejavu sans|bold":st["sans-serif|bold"]=t;break;case"dejavu sans|italic":st["sans-serif|italic"]=t;break;case"dejavu sans|bold|italic":st["sans-serif|bold|italic"]=t;break;case"dejavu serif":st.serif=t;break;case"dejavu serif|bold":st["serif|bold"]=t;break;case"dejavu serif|italic":st["serif|italic"]=t;break;case"dejavu serif|bold|italic":st["serif|bold|italic"]=t;break;case"dejavu mono":st.monospace=t;break;case"dejavu mono|bold":st["monospace|bold"]=t;break;case"dejavu mono|italic":st["monospace|italic"]=t;break;case"dejavu mono|bold|italic":st["monospace|bold|italic"]=t}}function G(e,t){var n=e[0],i=e[1],o=e[2],r=e[3],s=e[4],a=e[5],l=t[0],c=t[1],d=t[2],u=t[3],h=t[4],f=t[5];return[n*l+i*d,n*c+i*u,o*l+r*d,o*c+r*u,s*l+a*d+h,s*c+a*u+f]}function $(e){return 1===e[0]&&0===e[1]&&0===e[2]&&1===e[3]&&0===e[4]&&0===e[5]}function Y(e,t){function n(e,t,n){return n||(n=a),n.pdf&&null!=n.pdf[e]?n.pdf[e]:t}function i(){function i(e){var t,i,o,s,a,l=e.options,c=ve(e),d=c.bbox;e=c.root,t=n("paperSize",n("paperSize","auto"),l),i=!1,"auto"==t&&(d?(o=d.getSize(),t=[o.width,o.height],i=!0,s=d.getOrigin(),c=new ye.Group,c.transform(new xe.Matrix(1,0,0,1,(-s.x),(-s.y))),c.append(e),e=c):t="A4"),a=r.addPage({paperSize:t,margin:n("margin",n("margin"),l),addMargin:i,landscape:n("landscape",n("landscape",!1),l)}),J(e,a,r)}if(!(--o>0)){var r=new p({producer:n("producer"),title:n("title"),author:n("author"),subject:n("subject"),keywords:n("keywords"),creator:n("creator"),date:n("date")});l?e.children.forEach(i):i(e),t(r.render(),r)}}var o,r=[],s=[],a=e.options,l=n("multiPage");e.traverse(function(e){Z({Image:function(e){s.indexOf(e.src())<0&&s.push(e.src())},Text:function(e){var t=U(e.options.font),n=W(t);r.indexOf(n)<0&&r.push(n)}},e)}),o=2,qe(r,i),je(s,i)}function K(e,t){Y(e,function(e){t("data:application/pdf;base64,"+e.base64())})}function Q(e,t){Y(e,function(e){t(new window.Blob([e.get()],{type:"application/pdf"}))})}function X(t,n,i,o){window.Blob&&!we.safari?Q(t,function(t){e.saveAs({dataURI:t,fileName:n}),o&&o(t)}):K(t,function(t){e.saveAs({dataURI:t,fileName:n,proxyURL:i}),o&&o(t)})}function Z(e,t){var n=e[t.nodeType];return n?n.call.apply(n,arguments):t}function J(e,t,n){var i,o,r;e.options._pdfDebug&&t.comment("BEGIN: "+e.options._pdfDebug),i=e.transform(),o=e.opacity(),t.save(),null!=o&&o<1&&t.setOpacity(o),ee(e,t,n),te(e,t,n),i&&(r=i.matrix(),t.transform(r.a,r.b,r.c,r.d,r.e,r.f)),ne(e,t,n),Z({Path:le,MultiPath:ce,Circle:de,Arc:ue,Text:he,Image:pe,Group:fe,Rect:me},e,t,n),t.restore(),e.options._pdfDebug&&t.comment("END: "+e.options._pdfDebug)}function ee(e,t){var n,i,o,r,s,a,l=e.stroke&&e.stroke();if(l){if(n=l.color){if(n=ge(n),null==n)return;t.setStrokeColor(n.r,n.g,n.b),1!=n.a&&t.setStrokeOpacity(n.a)}if(i=l.width,null!=i){if(0===i)return;t.setLineWidth(i)}o=l.dashType,o&&t.setDashPattern(ct[o],0),r=l.lineCap,r&&t.setLineCap(dt[r]),s=l.lineJoin,s&&t.setLineJoin(ut[s]),a=l.opacity,null!=a&&t.setStrokeOpacity(a)}}function te(e,t){var n,i,o=e.fill&&e.fill();if(o&&!(o instanceof ye.Gradient)){if(n=o.color){if(n=ge(n),null==n)return;t.setFillColor(n.r,n.g,n.b),1!=n.a&&t.setFillOpacity(n.a)}i=o.opacity,null!=i&&t.setFillOpacity(i)}}function ne(e,t,n){var i=e.clip();i&&(ae(i,t,n),t.clip())}function ie(e){return e&&(e instanceof ye.Gradient||e.color&&!/^(none|transparent)$/i.test(e.color)&&(null==e.width||e.width>0)&&(null==e.opacity||e.opacity>0))}function oe(e,t,n,i){var o,r,s,a,l,c,d,u,h=e.fill();if(h instanceof ye.Gradient)return i?t.clipStroke():t.clip(),o=h instanceof ye.RadialGradient,o?(r={x:h.center().x,y:h.center().y,r:0},s={x:h.center().x,y:h.center().y,r:h.radius()}):(r={x:h.start().x,y:h.start().y},s={x:h.end().x,y:h.end().y}),a=h.stops.elements().map(function(e){var t,n=e.offset();return n=/%$/.test(n)?parseFloat(n)/100:parseFloat(n),t=ge(e.color()),t.a*=e.opacity(),{offset:n,color:t}}),a.unshift(a[0]),a.push(a[a.length-1]),l={userSpace:h.userSpace(),type:o?"radial":"linear",start:r,end:s,stops:a},c=e.rawBBox(),d=c.topLeft(),u=c.getSize(),c={left:d.x,top:d.y,width:u.width,height:u.height},t.gradient(l,c),!0}function re(e,t,n){ie(e.fill())&&ie(e.stroke())?oe(e,t,n,!0)||t.fillStroke():ie(e.fill())?oe(e,t,n,!1)||t.fill():ie(e.stroke())?t.stroke():t.nop()}function se(e,t){var n,i,o,r=e.segments;if(4==r.length&&e.options.closed){for(n=[],i=0;i<r.length;++i){if(r[i].controlIn())return!1;n[i]=r[i].anchor()}if(o=n[0].y==n[1].y&&n[1].x==n[2].x&&n[2].y==n[3].y&&n[3].x==n[0].x||n[0].x==n[1].x&&n[1].y==n[2].y&&n[2].x==n[3].x&&n[3].y==n[0].y)return t.rect(n[0].x,n[0].y,n[2].x-n[0].x,n[2].y-n[0].y),!0}}function ae(e,t,n){var i,o,r,s,a,l,c=e.segments;if(0!==c.length&&!se(e,t,n)){for(o=0;o<c.length;++o)r=c[o],s=r.anchor(),i?(a=i.controlOut(),l=r.controlIn(),a&&l?t.bezier(a.x,a.y,l.x,l.y,s.x,s.y):t.lineTo(s.x,s.y)):t.moveTo(s.x,s.y),i=r;e.options.closed&&t.close()}}function le(e,t,n){ae(e,t,n),re(e,t,n)}function ce(e,t,n){var i,o=e.paths;for(i=0;i<o.length;++i)ae(o[i],t,n);re(e,t,n)}function de(e,t,n){var i=e.geometry();t.circle(i.center.x,i.center.y,i.radius),re(e,t,n)}function ue(e,t,n){var i,o=e.geometry().curvePoints();for(t.moveTo(o[0].x,o[0].y),i=1;i<o.length;)t.bezier(o[i].x,o[i++].y,o[i].x,o[i++].y,o[i].x,o[i++].y);re(e,t,n)}function he(e,t){var n,i=U(e.options.font),o=e._position;e.fill()&&e.stroke()?n=lt.fillAndStroke:e.fill()?n=lt.fill:e.stroke()&&(n=lt.stroke),t.transform(1,0,0,-1,o.x,o.y+i.fontSize),t.beginText(),t.setFont(W(i),i.fontSize),t.setTextRenderingMode(n),t.showText(e.content(),e._pdfRect?e._pdfRect.width():null),t.endText()}function fe(e,t,n){var i,o;for(e._pdfLink&&t.addLink(e._pdfLink.url,e._pdfLink),i=e.children,o=0;o<i.length;++o)J(i[o],t,n)}function pe(e,t){var n,i,o,r=e.src();r&&(n=e.rect(),i=n.getOrigin(),o=n.getSize(),t.transform(o.width,0,0,-o.height,i.x,i.y+o.height),t.drawImage(r))}function me(e,t,n){var i=e.geometry();t.rect(i.origin.x,i.origin.y,i.size.width,i.size.height),re(e,t,n)}function ge(t){var n=e.parseColor(t,!0);return n?n.toRGB():null}function ve(e){function t(e){return a=!0,e}function n(e){return e.visible()&&e.opacity()>0&&(ie(e.fill())||ie(e.stroke()))}function i(e){var t,n,i=[];for(t=0;t<e.length;++t)n=s(e[t]),null!=n&&i.push(n);return i}function o(e,t){var n,i=l,o=c;e.transform()&&(c=c.multiplyCopy(e.transform().matrix())),n=e.clip(),n&&(n=n.bbox(),n&&(n=n.bbox(c),l=l?xe.Rect.intersect(l,n):n));try{return t()}finally{l=i,c=o}}function r(e){if(null==l)return!1;var t=e.rawBBox().bbox(c);return l&&t&&(t=xe.Rect.intersect(t,l)),t}function s(s){return o(s,function(){if(!(s instanceof ye.Group||s instanceof ye.MultiPath)){var o=r(s);if(!o)return t(null);d=d?xe.Rect.union(d,o):o}return Z({Path:function(e){return 0!==e.segments.length&&n(e)?e:t(null)},MultiPath:function(e){if(!n(e))return t(null);var o=new ye.MultiPath(e.options);return o.paths=i(e.paths),0===o.paths.length?t(null):o},Circle:function(e){return n(e)?e:t(null)},Arc:function(e){return n(e)?e:t(null)},Text:function(e){return/\S/.test(e.content())&&n(e)?e:t(null)},Image:function(e){return e.visible()&&e.opacity()>0?e:t(null)},Group:function(n){var o=new ye.Group(n.options);return o.children=i(n.children),o._pdfLink=n._pdfLink,n===e||0!==o.children.length||n._pdfLink?o:t(null)},Rect:function(e){return n(e)?e:t(null)}},s)})}var a,l=!1,c=xe.Matrix.unit(),d=null;do a=!1,e=s(e);while(e&&a);return{root:e,bbox:d}}function _e(e,t){var n,i=ke.createPromise();for(n in t)"margin"==n&&e.options.pdf&&e.options.pdf._ignoreMargin||e.options.set("pdf."+n,t[n]);return K(e,i.resolve),i}var be,we,ye,ke,xe,Ce,Se,Te,De,Ae,Ee,Me,Ie,Re,Fe,ze,Pe,Be,Le,He,Ne,Oe,Ve,Ue,We,qe,je,Ge,$e,Ye,Ke,Qe,Xe,Ze,Je,et,tt,nt,it,ot,rt,st,at,lt,ct,dt,ut;window.kendo.pdf=window.kendo.pdf||{},be=e.support,we=be.browser,ye=e.drawing,ke=ye.util,xe=e.geometry,Ce="undefined"!=typeof Uint8Array,Se=function(){var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";return{decode:function(t){for(var n,i,o,r,s,a,l,c=t.replace(/[^A-Za-z0-9\+\/\=]/g,""),d=0,u=c.length,h=[];d<u;)n=e.indexOf(c.charAt(d++)),i=e.indexOf(c.charAt(d++)),o=e.indexOf(c.charAt(d++)),r=e.indexOf(c.charAt(d++)),s=n<<2|i>>>4,a=(15&i)<<4|o>>>2,l=(3&o)<<6|r,h.push(s),64!=o&&h.push(a),64!=r&&h.push(l);return h},encode:function(t){for(var n,i,o,r,s,a,l,c=0,d=t.length,u="";c<d;)n=t[c++],i=t[c++],o=t[c++],r=n>>>2,s=(3&n)<<4|i>>>4,a=(15&i)<<2|o>>>6,l=63&o,c-d==2?a=l=64:c-d==1&&(l=64),u+=e.charAt(r)+e.charAt(s)+e.charAt(a)+e.charAt(l);return u}}}(),s.prototype={readTable:function(e,t){var n=this.tables[e];if(!n)throw Error("Table "+e+" not found in directory");return this[e]=n.table=new t(this,n)},render:function(e){var n,i,r,s,a,l,c,d,u=this,h=Object.keys(e).length,f=Math.pow(2,Math.floor(Math.log(h)/Math.LN2)),p=16*f,m=Math.floor(Math.log(f)/Math.LN2),g=16*h-p,v=t();v.writeLong(this.scalerType),v.writeShort(h),v.writeShort(p),v.writeShort(m),v.writeShort(g),n=16*h,i=v.offset()+n,r=null,s=t();for(a in e)if(o(e,a))for(l=e[a],v.writeString(a),v.writeLong(u.checksum(l)),v.writeLong(i),v.writeLong(l.length),s.write(l),"head"==a&&(r=i),i+=l.length;i%4;)s.writeByte(0),i++;return v.write(s.get()),c=this.checksum(v.get()),d=2981146554-c,v.offset(r+8),v.writeLong(d),v.get()},checksum:function(e){e=t(e);for(var n=0;!e.eof();)n+=e.readLong();return 4294967295&n}},Te=a({parse:function(e){e.offset(this.offset),this.version=e.readLong(),this.revision=e.readLong(),this.checkSumAdjustment=e.readLong(),this.magicNumber=e.readLong(),this.flags=e.readShort(),this.unitsPerEm=e.readShort(),this.created=e.read(8),this.modified=e.read(8),this.xMin=e.readShort_(),this.yMin=e.readShort_(),this.xMax=e.readShort_(),this.yMax=e.readShort_(),this.macStyle=e.readShort(),this.lowestRecPPEM=e.readShort(),this.fontDirectionHint=e.readShort_(),this.indexToLocFormat=e.readShort_(),this.glyphDataFormat=e.readShort_()},render:function(e){var n=t();return n.writeLong(this.version),n.writeLong(this.revision),n.writeLong(0),n.writeLong(this.magicNumber),n.writeShort(this.flags),n.writeShort(this.unitsPerEm),n.write(this.created),n.write(this.modified),n.writeShort_(this.xMin),n.writeShort_(this.yMin),n.writeShort_(this.xMax),n.writeShort_(this.yMax),n.writeShort(this.macStyle),n.writeShort(this.lowestRecPPEM),n.writeShort_(this.fontDirectionHint),n.writeShort_(e),n.writeShort_(this.glyphDataFormat),n.get()}}),De=a({parse:function(e){e.offset(this.offset);var t=this.file.head.indexToLocFormat;this.offsets=0===t?e.times(this.length/2,function(){return 2*e.readShort()}):e.times(this.length/4,e.readLong)},offsetOf:function(e){return this.offsets[e]},lengthOf:function(e){return this.offsets[e+1]-this.offsets[e]},render:function(e){var n,i=t(),o=e[e.length-1]>65535;for(n=0;n<e.length;++n)o?i.writeLong(e[n]):i.writeShort(e[n]/2);return{format:o?1:0,table:i.get()}}}),Ae=a({parse:function(e){e.offset(this.offset),this.version=e.readLong(),this.ascent=e.readShort_(),this.descent=e.readShort_(),this.lineGap=e.readShort_(),this.advanceWidthMax=e.readShort(),this.minLeftSideBearing=e.readShort_(),this.minRightSideBearing=e.readShort_(),this.xMaxExtent=e.readShort_(),this.caretSlopeRise=e.readShort_(),this.caretSlopeRun=e.readShort_(),this.caretOffset=e.readShort_(),e.skip(8),this.metricDataFormat=e.readShort_(),this.numOfLongHorMetrics=e.readShort()},render:function(e){var n=t();return n.writeLong(this.version),n.writeShort_(this.ascent),n.writeShort_(this.descent),n.writeShort_(this.lineGap),n.writeShort(this.advanceWidthMax),n.writeShort_(this.minLeftSideBearing),n.writeShort_(this.minRightSideBearing),n.writeShort_(this.xMaxExtent),n.writeShort_(this.caretSlopeRise),n.writeShort_(this.caretSlopeRun),n.writeShort_(this.caretOffset),n.write([0,0,0,0,0,0,0,0]),n.writeShort_(this.metricDataFormat),n.writeShort(e.length),n.get()}}),Ee=a({parse:function(e){e.offset(this.offset),this.version=e.readLong(),this.numGlyphs=e.readShort(),this.maxPoints=e.readShort(),this.maxContours=e.readShort(),this.maxComponentPoints=e.readShort(),this.maxComponentContours=e.readShort(),this.maxZones=e.readShort(),this.maxTwilightPoints=e.readShort(),this.maxStorage=e.readShort(),this.maxFunctionDefs=e.readShort(),this.maxInstructionDefs=e.readShort(),this.maxStackElements=e.readShort(),this.maxSizeOfInstructions=e.readShort(),this.maxComponentElements=e.readShort(),this.maxComponentDepth=e.readShort()},render:function(e){var n=t();return n.writeLong(this.version),n.writeShort(e.length),n.writeShort(this.maxPoints),n.writeShort(this.maxContours),n.writeShort(this.maxComponentPoints),n.writeShort(this.maxComponentContours),n.writeShort(this.maxZones),n.writeShort(this.maxTwilightPoints),n.writeShort(this.maxStorage),n.writeShort(this.maxFunctionDefs),n.writeShort(this.maxInstructionDefs),n.writeShort(this.maxStackElements),n.writeShort(this.maxSizeOfInstructions),n.writeShort(this.maxComponentElements),n.writeShort(this.maxComponentDepth),n.get()}}),Me=a({parse:function(e){var t,n,i;e.offset(this.offset),t=this.file,n=t.hhea,this.metrics=e.times(n.numOfLongHorMetrics,function(){return{advance:e.readShort(),lsb:e.readShort_()}}),i=t.maxp.numGlyphs-t.hhea.numOfLongHorMetrics,this.leftSideBearings=e.times(i,e.readShort_)},forGlyph:function(e){var t=this.metrics,n=t.length;return e<n?t[e]:{advance:t[n-1].advance,lsb:this.leftSideBearings[e-n]}},render:function(e){var n,i,o=this,r=t();for(n=0;n<e.length;++n)i=o.forGlyph(e[n]),r.writeShort(i.advance),r.writeShort_(i.lsb);return r.get()}}),Ie=function(){function e(e){this.raw=e}function n(e){var t,n,o;for(this.raw=e,t=this.glyphIds=[],n=this.idOffsets=[];;){if(o=e.readShort(),n.push(e.offset()),t.push(e.readShort()),!(o&s))break;e.skip(o&i?4:2),o&c?e.skip(8):o&l?e.skip(4):o&r&&e.skip(2)}}var i,r,s,l,c;return e.prototype={compound:!1,render:function(){return this.raw.get()}},i=1,r=8,s=32,l=64,c=128,n.prototype={compound:!0,render:function(e){var n,i,o=this,r=t(this.raw.get());for(n=0;n<this.glyphIds.length;++n)i=o.glyphIds[n],r.offset(o.idOffsets[n]),r.writeShort(e[i]);return r.get()}},a({parse:function(){this.cache={}},glyphFor:function(i){var r,s,a,l,c,d,u,h,f,p,m,g=this.cache;return o(g,i)?g[i]:(r=this.file.loca,s=r.lengthOf(i),0===s?g[i]=null:(a=this.rawData,l=this.offset+r.offsetOf(i),c=t(a.slice(l,s)),d=c.readShort_(),u=c.readShort_(),h=c.readShort_(),f=c.readShort_(),p=c.readShort_(),m=g[i]=d==-1?new n(c):new e(c),m.numberOfContours=d,m.xMin=u,m.yMin=h,m.xMax=f,m.yMax=p,m))},render:function(e,n,i){var o,r,s,a=t(),l=[];for(o=0;o<n.length;++o)r=n[o],s=e[r],l.push(a.offset()),s&&a.write(s.render(i));return l.push(a.offset()),{table:a.get(),offsets:l}}})}(),Re=function(){function e(e,t){this.text=e,this.length=e.length,this.platformID=t.platformID,this.platformSpecificID=t.platformSpecificID,this.languageID=t.languageID,this.nameID=t.nameID}return a({parse:function(t){var n,i,o,r,s,a,l;for(t.offset(this.offset),t.readShort(),n=t.readShort(),i=this.offset+t.readShort(),o=t.times(n,function(){return{platformID:t.readShort(),platformSpecificID:t.readShort(),languageID:t.readShort(),nameID:t.readShort(),length:t.readShort(),offset:t.readShort()+i}}),r=this.strings={},s=0;s<o.length;++s)a=o[s],t.offset(a.offset),l=t.readString(a.length),r[a.nameID]||(r[a.nameID]=[]),r[a.nameID].push(new e(l,a));this.postscriptEntry=r[6][0],this.postscriptName=this.postscriptEntry.text.replace(/[^\x20-\x7F]/g,"")},render:function(n){var i,r,s,a,l,c,d=this,u=this.strings,h=0;for(i in u)o(u,i)&&(h+=u[i].length);r=t(),s=t(),r.writeShort(0),r.writeShort(h),r.writeShort(6+12*h);for(i in u)if(o(u,i))for(a=6==i?[new e(n,d.postscriptEntry)]:u[i],l=0;l<a.length;++l)c=a[l],r.writeShort(c.platformID),r.writeShort(c.platformSpecificID),r.writeShort(c.languageID),r.writeShort(c.nameID),r.writeShort(c.length),r.writeShort(s.offset()),s.writeString(c.text);return r.write(s.get()),r.get()}})}(),Fe=function(){var e=".notdef .null nonmarkingreturn space exclam quotedbl numbersign dollar percent ampersand quotesingle parenleft parenright asterisk plus comma hyphen period slash zero one two three four five six seven eight nine colon semicolon less equal greater question at A B C D E F G H I J K L M N O P Q R S T U V W X Y Z bracketleft backslash bracketright asciicircum underscore grave a b c d e f g h i j k l m n o p q r s t u v w x y z braceleft bar braceright asciitilde Adieresis Aring Ccedilla Eacute Ntilde Odieresis Udieresis aacute agrave acircumflex adieresis atilde aring ccedilla eacute egrave ecircumflex edieresis iacute igrave icircumflex idieresis ntilde oacute ograve ocircumflex odieresis otilde uacute ugrave ucircumflex udieresis dagger degree cent sterling section bullet paragraph germandbls registered copyright trademark acute dieresis notequal AE Oslash infinity plusminus lessequal greaterequal yen mu partialdiff summation product pi integral ordfeminine ordmasculine Omega ae oslash questiondown exclamdown logicalnot radical florin approxequal Delta guillemotleft guillemotright ellipsis nonbreakingspace Agrave Atilde Otilde OE oe endash emdash quotedblleft quotedblright quoteleft quoteright divide lozenge ydieresis Ydieresis fraction currency guilsinglleft guilsinglright fi fl daggerdbl periodcentered quotesinglbase quotedblbase perthousand Acircumflex Ecircumflex Aacute Edieresis Egrave Iacute Icircumflex Idieresis Igrave Oacute Ocircumflex apple Ograve Uacute Ucircumflex Ugrave dotlessi circumflex tilde macron breve dotaccent ring cedilla hungarumlaut ogonek caron Lslash lslash Scaron scaron Zcaron zcaron brokenbar Eth eth Yacute yacute Thorn thorn minus multiply onesuperior twosuperior threesuperior onehalf onequarter threequarters franc Gbreve gbreve Idotaccent Scedilla scedilla Cacute cacute Ccaron ccaron dcroat".split(/\s+/g);return a({parse:function(e){var t,n,i=this;switch(e.offset(this.offset),this.format=e.readLong(),this.italicAngle=e.readFixed_(),this.underlinePosition=e.readShort_(),this.underlineThickness=e.readShort_(),this.isFixedPitch=e.readLong(),this.minMemType42=e.readLong(),this.maxMemType42=e.readLong(),this.minMemType1=e.readLong(),this.maxMemType1=e.readLong(),this.format){case 65536:case 196608:break;case 131072:for(t=e.readShort(),this.glyphNameIndex=e.times(t,e.readShort),this.names=[],n=this.offset+this.length;e.offset()<n;)i.names.push(e.readString(e.readByte()));break;case 151552:t=e.readShort(),this.offsets=e.read(t);break;case 262144:this.map=e.times(this.file.maxp.numGlyphs,e.readShort)}},glyphFor:function(t){switch(this.format){case 65536:return e[t]||".notdef";case 131072:var n=this.glyphNameIndex[t];return n<e.length?e[n]:this.names[n-e.length]||".notdef";case 151552:case 196608:return".notdef";case 262144:return this.map[t]||65535}},render:function(n){var i,o,r,s,a,l,c,d=this;if(196608==this.format)return this.raw();for(i=t(this.rawData.slice(this.offset,32)),i.writeLong(131072),i.offset(32),o=[],r=[],s=0;s<n.length;++s)a=n[s],l=d.glyphFor(a),c=e.indexOf(l),c>=0?o.push(c):(o.push(e.length+r.length),r.push(l));for(i.writeShort(n.length),s=0;s<o.length;++s)i.writeShort(o[s]);for(s=0;s<r.length;++s)i.writeByte(r[s].length),i.writeString(r[s]);return i.get()}})}(),ze=function(){function e(e,t,n){var i=this;i.platformID=e.readShort(),i.platformSpecificID=e.readShort(),i.offset=t+e.readLong(),e.saveExcursion(function(){var t,o,r,s,a,l,c,d,u,h,f,p,m,g,v,_,b;switch(e.offset(i.offset),i.format=e.readShort()){case 0:for(i.length=e.readShort(),i.language=e.readShort(),o=0;o<256;++o)n[o]=e.readByte();break;case 4:for(i.length=e.readShort(),i.language=e.readShort(),r=e.readShort()/2,e.skip(6),s=e.times(r,e.readShort),e.skip(2),a=e.times(r,e.readShort),l=e.times(r,e.readShort_),c=e.times(r,e.readShort),d=(i.length+i.offset-e.offset())/2,u=e.times(d,e.readShort),o=0;o<r;++o)for(h=a[o],f=s[o],t=h;t<=f;++t)0===c[o]?p=t+l[o]:(m=c[o]/2-(r-o)+(t-h),p=u[m]||0,0!==p&&(p+=l[o])),n[t]=65535&p;break;case 6:for(i.length=e.readShort(),i.language=e.readShort(),t=e.readShort(),g=e.readShort();g-- >0;)n[t++]=e.readShort();break;case 12:for(e.readShort(),i.length=e.readLong(),i.language=e.readLong(),v=e.readLong();v-- >0;)for(t=e.readLong(),_=e.readLong(),b=e.readLong();t<=_;)n[t++]=b++;break;default:window.console&&window.console.error("Unhandled CMAP format: "+i.format)}})}function n(e,n){function i(t){return n[e[t]]}var o,s,a,l,c,d,u,h,f,p,m,g,v,_,b,w,y,k=r(e),x=[],C=[],S=null,T=null;for(o=0;o<k.length;++o)s=k[o],a=i(s),l=a-s,null!=S&&l===T||(S&&C.push(S),x.push(s),T=l),S=s;for(S&&C.push(S),C.push(65535),x.push(65535),c=x.length,d=2*c,u=2*Math.pow(2,Math.floor(Math.log(c)/Math.LN2)),h=Math.log(u/2)/Math.LN2,f=d-u,p=[],m=[],g=[],o=0;o<c;++o){if(v=x[o],_=C[o],65535==v){p.push(0),m.push(0);break}if(b=i(v),v-b>=32768)for(p.push(0),m.push(2*(g.length+c-o)),w=v;w<=_;++w)g.push(i(w));else p.push(b-v),m.push(0)}return y=t(),y.writeShort(3),y.writeShort(1),y.writeLong(12),y.writeShort(4),y.writeShort(16+8*c+2*g.length),y.writeShort(0),y.writeShort(d),y.writeShort(u),y.writeShort(h),y.writeShort(f),C.forEach(y.writeShort),y.writeShort(0),x.forEach(y.writeShort),p.forEach(y.writeShort_),m.forEach(y.writeShort),g.forEach(y.writeShort),y.get()}return a({parse:function(t){var n,i=this,o=i.offset;t.offset(o),i.codeMap={},i.version=t.readShort(),n=t.readShort(),i.tables=t.times(n,function(){return new e(t,o,i.codeMap)})},render:function(e,i){var o=t();return o.writeShort(0),o.writeShort(1),o.write(n(e,i)),o.get()}})}(),Pe=a({parse:function(e){e.offset(this.offset),this.version=e.readShort(),this.averageCharWidth=e.readShort_(),this.weightClass=e.readShort(),this.widthClass=e.readShort(),this.type=e.readShort(),this.ySubscriptXSize=e.readShort_(),this.ySubscriptYSize=e.readShort_(),this.ySubscriptXOffset=e.readShort_(),this.ySubscriptYOffset=e.readShort_(),this.ySuperscriptXSize=e.readShort_(),this.ySuperscriptYSize=e.readShort_(),this.ySuperscriptXOffset=e.readShort_(),this.ySuperscriptYOffset=e.readShort_(),this.yStrikeoutSize=e.readShort_(),this.yStrikeoutPosition=e.readShort_(),this.familyClass=e.readShort_(),this.panose=e.times(10,e.readByte),this.charRange=e.times(4,e.readLong),this.vendorID=e.readString(4),this.selection=e.readShort(),this.firstCharIndex=e.readShort(),this.lastCharIndex=e.readShort(),this.version>0&&(this.ascent=e.readShort_(),this.descent=e.readShort_(),this.lineGap=e.readShort_(),this.winAscent=e.readShort(),this.winDescent=e.readShort(),this.codePageRange=e.times(2,e.readLong),this.version>1&&(this.xHeight=e.readShort(),this.capHeight=e.readShort(),this.defaultChar=e.readShort(),this.breakChar=e.readShort(),this.maxContext=e.readShort()))},render:function(){return this.raw()}}),Be=1e5,c.prototype={use:function(e){var t,i,o,r=this;return"string"==typeof e?n(e).reduce(function(e,t){return e+String.fromCharCode(r.use(t))},""):(t=r.unicodes[e],t||(t=r.next++,r.subset[t]=e,r.unicodes[e]=t,i=r.font.cmap.codeMap[e],i&&(r.ncid2ogid[t]=i,null==r.ogid2ngid[i]&&(o=r.nextGid++,r.ogid2ngid[i]=o,r.ngid2ogid[o]=i))),t)},encodeText:function(e){return this.use(e)},glyphIds:function(){return r(this.ogid2ngid)},glyphsFor:function(e,t){var n,i,o,r=this;for(t||(t={}),n=0;n<e.length;++n)i=e[n],t[i]||(o=t[i]=r.font.glyf.glyphFor(i),o&&o.compound&&r.glyphsFor(o.glyphIds,t));return t},render:function(){var e,t,n,i,s,a,l,c,d=this,u=this.glyphsFor(this.glyphIds());for(e in u)o(u,e)&&(e=parseInt(e,10),null==d.ogid2ngid[e]&&(t=d.nextGid++,d.ogid2ngid[e]=t,d.ngid2ogid[t]=e));return n=r(this.ngid2ogid),i=n.map(function(e){return this.ngid2ogid[e]},this),s=this.font,a=s.glyf.render(u,i,this.ogid2ngid),l=s.loca.render(a.offsets),this.lastChar=this.next-1,c={cmap:ze.render(this.ncid2ogid,this.ogid2ngid),glyf:a.table,loca:l.table,hmtx:s.hmtx.render(i),hhea:s.hhea.render(i),maxp:s.maxp.render(i),post:s.post.render(i),name:s.name.render(this.psName),head:s.head.render(l.format),"OS/2":s.os2.render()},this.font.directory.render(c)},cidToGidMap:function(){var e,n,i,o=this,r=t(),s=0;for(e=this.firstChar;e<this.next;++e){for(;s<e;)r.writeShort(0),s++;n=o.ncid2ogid[e],n?(i=o.ogid2ngid[n],r.writeShort(i)):r.writeShort(0),s++}return r.get()}},d.prototype={parse:function(){var e=this.directory=new s(this.contents);this.head=e.readTable("head",Te),this.loca=e.readTable("loca",De),this.hhea=e.readTable("hhea",Ae),this.maxp=e.readTable("maxp",Ee),this.hmtx=e.readTable("hmtx",Me),this.glyf=e.readTable("glyf",Ie),this.name=e.readTable("name",Re),this.post=e.readTable("post",Fe),this.cmap=e.readTable("cmap",ze),this.os2=e.readTable("OS/2",Pe),this.psName=this.name.postscriptName,this.ascent=this.os2.ascent||this.hhea.ascent,this.descent=this.os2.descent||this.hhea.descent,this.lineGap=this.os2.lineGap||this.hhea.lineGap,this.scale=1e3/this.head.unitsPerEm},widthOfGlyph:function(e){return this.hmtx.forGlyph(e).advance*this.scale},makeSubset:function(){return new c(this)}},Le=e.support.browser,He="undefined"!=typeof Uint8Array,Ne="\n",Oe=0,Ve={a0:[2383.94,3370.39],a1:[1683.78,2383.94],a2:[1190.55,1683.78],a3:[841.89,1190.55],a4:[595.28,841.89],a5:[419.53,595.28],a6:[297.64,419.53],a7:[209.76,297.64],a8:[147.4,209.76],a9:[104.88,147.4],a10:[73.7,104.88],b0:[2834.65,4008.19],b1:[2004.09,2834.65],b2:[1417.32,2004.09],b3:[1000.63,1417.32],b4:[708.66,1000.63],b5:[498.9,708.66],b6:[354.33,498.9],b7:[249.45,354.33],b8:[175.75,249.45],b9:[124.72,175.75],b10:[87.87,124.72],c0:[2599.37,3676.54],c1:[1836.85,2599.37],c2:[1298.27,1836.85],c3:[918.43,1298.27],c4:[649.13,918.43],c5:[459.21,649.13],c6:[323.15,459.21],c7:[229.61,323.15],c8:[161.57,229.61],c9:[113.39,161.57],c10:[79.37,113.39],executive:[521.86,756],folio:[612,936],legal:[612,1008],letter:[612,792],tabloid:[792,1224]},Ue={"Times-Roman":!0,"Times-Bold":!0,"Times-Italic":!0,"Times-BoldItalic":!0,Helvetica:!0,"Helvetica-Bold":!0,"Helvetica-Oblique":!0,"Helvetica-BoldOblique":!0,Courier:!0,"Courier-Bold":!0,"Courier-Oblique":!0,"Courier-BoldOblique":!0,Symbol:!0,ZapfDingbats:!0},We={},qe=_(g),je=_(v),p.prototype={loadFonts:qe,loadImages:je,getFont:function(e){var t=this.FONTS[e];if(!t){if(t=Ue[e],!t)throw Error("Font "+e+" has not been loaded");t=this.attach(t===!0?new nt(e):new it(this,t)),this.FONTS[e]=t}return t},getImage:function(e){var t=this.IMAGES[e];if(!t){if(t=We[e],!t)throw Error("Image "+e+" has not been loaded");if("TAINTED"===t)return null;t=this.IMAGES[e]=this.attach(t.asStream(this))}return t},getOpacityGS:function(e,t){var n,i,o,r=parseFloat(e).toFixed(3);return e=parseFloat(r),r+=t?"S":"F",n=this._opacityGSCache||(this._opacityGSCache={}),i=n[r],i||(o={Type:I("ExtGState")},t?o.CA=e:o.ca=e,i=this.attach(new Xe(o)),i._resourceName=I("GS"+ ++Oe),n[r]=i),i},dict:function(e){return new Xe(e)},name:function(e){return I(e)},stream:function(e,t){return new Ze(t,e)}},Ge=Array.isArray||function(e){return e instanceof Array},E.prototype.beforeRender=function(){},$e=M(function(e){this.value=e},{render:function(e){var t,n="",i=this.value;for(t=0;t<i.length;++t)n+=String.fromCharCode(255&i.charCodeAt(t));e("(",n.replace(/([\(\)\\])/g,"\\$1"),")")},toString:function(){return this.value}}),Ye=M(function(e){this.value=e},{render:function(e){var t,n=this;for(e("<"),t=0;t<this.value.length;++t)e(w(n.value.charCodeAt(t).toString(16),4));e(">")}},$e),Ke=M(function(e){this.name=e},{render:function(e){e("/"+this.escape())},escape:function(){return this.name.replace(/[^\x21-\x7E]/g,function(e){return"#"+w(e.charCodeAt(0).toString(16),2)})},toString:function(){return this.name}}),Qe={},Ke.get=I,Xe=M(function(e){this.props=e},{render:function(e){var t=this.props,n=!0;e("<<"),e.withIndent(function(){for(var i in t)y(t,i)&&!/^_/.test(i)&&(n=!1,e.indent(I(i)," ",t[i]))}),n||e.indent(),e(">>")}}),Ze=M(function(e,n,i){if("string"==typeof e){var o=t();o.write(e),e=o}this.data=e,this.props=n||{},this.compress=i},{render:function(e){var t=this.data.get(),n=this.props;this.compress&&window.pako&&"function"==typeof window.pako.deflate&&(n.Filter?n.Filter instanceof Array||(n.Filter=[n.Filter]):n.Filter=[],n.Filter.unshift(I("FlateDecode")),t=window.pako.deflate(t)),n.Length=t.length,e(new Xe(n)," stream",Ne),e.writeData(t),e(Ne,"endstream")}}),Je=M(function(e){e=this.props=e||{},e.Type=I("Catalog")},{setPages:function(e){this.props.Pages=e}},Xe),et=M(function(){this.props={Type:I("Pages"),Kids:[],Count:0}},{addPage:function(e){this.props.Kids.push(e),this.props.Count++}},Xe),tt=[192,193,194,195,197,198,199,201,202,203,205,206,207],nt=M(function(e){this.props={Type:I("Font"),Subtype:I("Type1"),BaseFont:I(e)},this._resourceName=I("F"+ ++Oe)},{encodeText:function(e){return new $e(e+"")}},Xe),it=M(function(e,t,n){var i,o;n=this.props=n||{},n.Type=I("Font"),n.Subtype=I("Type0"),n.Encoding=I("Identity-H"),this._pdf=e,this._font=t,this._sub=t.makeSubset(),this._resourceName=I("F"+ ++Oe),i=t.head,this.name=t.psName,o=this.scale=t.scale,this.bbox=[i.xMin*o,i.yMin*o,i.xMax*o,i.yMax*o],this.italicAngle=t.post.italicAngle,this.ascent=t.ascent*o,this.descent=t.descent*o,this.lineGap=t.lineGap*o,this.capHeight=t.os2.capHeight||this.ascent,this.xHeight=t.os2.xHeight||0,this.stemV=0,this.familyClass=(t.os2.familyClass||0)>>8,this.isSerif=this.familyClass>=1&&this.familyClass<=7,this.isScript=10==this.familyClass,this.flags=(t.post.isFixedPitch?1:0)|(this.isSerif?2:0)|(this.isScript?8:0)|(0!==this.italicAngle?64:0)|32},{encodeText:function(e){return new Ye(this._sub.encodeText(e+""))},getTextWidth:function(e,t){var n,i,o=this,r=0,s=this._font.cmap.codeMap;for(n=0;n<t.length;++n)i=s[t.charCodeAt(n)],r+=o._font.widthOfGlyph(i||0);return r*e/1e3},beforeRender:function(){
var e,n,i,o,r=this,s=r._sub,a=s.render(),l=new Ze(t(a),{Length1:a.length},(!0)),c=r._pdf.attach(new Xe({Type:I("FontDescriptor"),FontName:I(r._sub.psName),FontBBox:r.bbox,Flags:r.flags,StemV:r.stemV,ItalicAngle:r.italicAngle,Ascent:r.ascent,Descent:r.descent,CapHeight:r.capHeight,XHeight:r.xHeight,FontFile2:r._pdf.attach(l)})),d=s.ncid2ogid,h=s.firstChar,f=s.lastChar,p=[];!function m(e,t){if(e<=f){var n=d[e];null==n?m(e+1):(t||p.push(e,t=[]),t.push(r._font.widthOfGlyph(n)),m(e+1,t))}}(h),e=new Xe({Type:I("Font"),Subtype:I("CIDFontType2"),BaseFont:I(r._sub.psName),CIDSystemInfo:new Xe({Registry:new $e("Adobe"),Ordering:new $e("Identity"),Supplement:0}),FontDescriptor:c,FirstChar:h,LastChar:f,DW:Math.round(r._font.widthOfGlyph(0)),W:p,CIDToGIDMap:r._pdf.attach(r._makeCidToGidMap())}),n=r.props,n.BaseFont=I(r._sub.psName),n.DescendantFonts=[r._pdf.attach(e)],i=new ot(h,f,s.subset),o=new Ze(u(),null,(!0)),o.data(i),n.ToUnicode=r._pdf.attach(o)},_makeCidToGidMap:function(){return new Ze(t(this._sub.cidToGidMap()),null,(!0))}},Xe),ot=M(function(e,t,n){this.firstChar=e,this.lastChar=t,this.map=n},{render:function(e){e.indent("/CIDInit /ProcSet findresource begin"),e.indent("12 dict begin"),e.indent("begincmap"),e.indent("/CIDSystemInfo <<"),e.indent("  /Registry (Adobe)"),e.indent("  /Ordering (UCS)"),e.indent("  /Supplement 0"),e.indent(">> def"),e.indent("/CMapName /Adobe-Identity-UCS def"),e.indent("/CMapType 2 def"),e.indent("1 begincodespacerange"),e.indent("  <0000><ffff>"),e.indent("endcodespacerange");var t=this;e.indent(t.lastChar-t.firstChar+1," beginbfchar"),e.withIndent(function(){var n,o,r,s;for(n=t.firstChar;n<=t.lastChar;++n){for(o=t.map[n],r=i([o]),e.indent("<",w(n.toString(16),4),">","<"),s=0;s<r.length;++s)e(w(r.charCodeAt(s).toString(16),4));e(">")}}),e.indent("endbfchar"),e.indent("endcmap"),e.indent("CMapName currentdict /CMap defineresource pop"),e.indent("end"),e.indent("end")}}),rt=M(function(e,t){this._pdf=e,this._rcount=0,this._textMode=!1,this._fontResources={},this._gsResources={},this._xResources={},this._patResources={},this._shResources={},this._opacity=1,this._matrix=[1,0,0,1,0,0],this._annotations=[],this._font=null,this._fontSize=null,this._contextStack=[],t=this.props=t||{},t.Type=I("Page"),t.ProcSet=[I("PDF"),I("Text"),I("ImageB"),I("ImageC"),I("ImageI")],t.Resources=new Xe({Font:new Xe(this._fontResources),ExtGState:new Xe(this._gsResources),XObject:new Xe(this._xResources),Pattern:new Xe(this._patResources),Shading:new Xe(this._shResources)}),t.Annots=this._annotations},{_out:function(){this._content.data.apply(null,arguments)},transform:function(e,t,n,i,o,r){$(arguments)||(this._matrix=G(arguments,this._matrix),this._out(e," ",t," ",n," ",i," ",o," ",r," cm"),this._out(Ne))},translate:function(e,t){this.transform(1,0,0,1,e,t)},scale:function(e,t){this.transform(e,0,0,t,0,0)},rotate:function(e){var t=Math.cos(e),n=Math.sin(e);this.transform(t,n,-n,t,0,0)},beginText:function(){this._textMode=!0,this._out("BT",Ne)},endText:function(){this._textMode=!1,this._out("ET",Ne)},_requireTextMode:function(){if(!this._textMode)throw Error("Text mode required; call page.beginText() first")},_requireFont:function(){if(!this._font)throw Error("No font selected; call page.setFont() first")},setFont:function(e,t){this._requireTextMode(),null==e?e=this._font:e instanceof it||(e=this._pdf.getFont(e)),null==t&&(t=this._fontSize),this._fontResources[e._resourceName]=e,this._font=e,this._fontSize=t,this._out(e._resourceName," ",t," Tf",Ne)},setTextLeading:function(e){this._requireTextMode(),this._out(e," TL",Ne)},setTextRenderingMode:function(e){this._requireTextMode(),this._out(e," Tr",Ne)},showText:function(e,t){var n,i;this._requireFont(),e.length>1&&t&&this._font instanceof it&&(n=this._font.getTextWidth(this._fontSize,e),i=t/n*100,this._out(i," Tz ")),this._out(this._font.encodeText(e)," Tj",Ne)},showTextNL:function(e){this._requireFont(),this._out(this._font.encodeText(e)," '",Ne)},addLink:function(e,t){var n=this._toPage({x:t.left,y:t.bottom}),i=this._toPage({x:t.right,y:t.top});this._annotations.push(new Xe({Type:I("Annot"),Subtype:I("Link"),Rect:[n.x,n.y,i.x,i.y],Border:[0,0,0],A:new Xe({Type:I("Action"),S:I("URI"),URI:new $e(e)})}))},setStrokeColor:function(e,t,n){this._out(e," ",t," ",n," RG",Ne)},setOpacity:function(e){this.setFillOpacity(e),this.setStrokeOpacity(e),this._opacity*=e},setStrokeOpacity:function(e){if(e<1){var t=this._pdf.getOpacityGS(this._opacity*e,!0);this._gsResources[t._resourceName]=t,this._out(t._resourceName," gs",Ne)}},setFillColor:function(e,t,n){this._out(e," ",t," ",n," rg",Ne)},setFillOpacity:function(e){if(e<1){var t=this._pdf.getOpacityGS(this._opacity*e,!1);this._gsResources[t._resourceName]=t,this._out(t._resourceName," gs",Ne)}},gradient:function(e,t){var n,i,o;this.save(),this.rect(t.left,t.top,t.width,t.height),this.clip(),e.userSpace||this.transform(t.width,0,0,t.height,t.left,t.top),n=O(this._pdf,e,t),i=n.shading._resourceName,this._shResources[i]=n.shading,n.hasAlpha&&(o=n.opacity._resourceName,this._gsResources[o]=n.opacity,this._out("/"+o+" gs ")),this._out("/"+i+" sh",Ne),this.restore()},setDashPattern:function(e,t){this._out(e," ",t," d",Ne)},setLineWidth:function(e){this._out(e," w",Ne)},setLineCap:function(e){this._out(e," J",Ne)},setLineJoin:function(e){this._out(e," j",Ne)},setMitterLimit:function(e){this._out(e," M",Ne)},save:function(){this._contextStack.push(this._context()),this._out("q",Ne)},restore:function(){this._out("Q",Ne),this._context(this._contextStack.pop())},moveTo:function(e,t){this._out(e," ",t," m",Ne)},lineTo:function(e,t){this._out(e," ",t," l",Ne)},bezier:function(e,t,n,i,o,r){this._out(e," ",t," ",n," ",i," ",o," ",r," c",Ne)},bezier1:function(e,t,n,i){this._out(e," ",t," ",n," ",i," y",Ne)},bezier2:function(e,t,n,i){this._out(e," ",t," ",n," ",i," v",Ne)},close:function(){this._out("h",Ne)},rect:function(e,t,n,i){this._out(e," ",t," ",n," ",i," re",Ne)},ellipse:function(e,t,n,i){function o(t){return e+t}function r(e){return t+e}var s=.5522847498307936;this.moveTo(o(0),r(i)),this.bezier(o(n*s),r(i),o(n),r(i*s),o(n),r(0)),this.bezier(o(n),r(-i*s),o(n*s),r(-i),o(0),r(-i)),this.bezier(o(-n*s),r(-i),o(-n),r(-i*s),o(-n),r(0)),this.bezier(o(-n),r(i*s),o(-n*s),r(i),o(0),r(i))},circle:function(e,t,n){this.ellipse(e,t,n,n)},stroke:function(){this._out("S",Ne)},nop:function(){this._out("n",Ne)},clip:function(){this._out("W n",Ne)},clipStroke:function(){this._out("W S",Ne)},closeStroke:function(){this._out("s",Ne)},fill:function(){this._out("f",Ne)},fillStroke:function(){this._out("B",Ne)},drawImage:function(e){var t=this._pdf.getImage(e);t&&(this._xResources[t._resourceName]=t,this._out(t._resourceName," Do",Ne))},comment:function(e){var t=this;e.split(/\r?\n/g).forEach(function(e){t._out("% ",e,Ne)})},_context:function(e){return null==e?{opacity:this._opacity,matrix:this._matrix}:(this._opacity=e.opacity,void(this._matrix=e.matrix))},_toPage:function(e){var t=this._matrix,n=t[0],i=t[1],o=t[2],r=t[3],s=t[4],a=t[5];return{x:n*e.x+o*e.y+s,y:i*e.x+r*e.y+a}}},Xe),st={serif:"Times-Roman","serif|bold":"Times-Bold","serif|italic":"Times-Italic","serif|bold|italic":"Times-BoldItalic","sans-serif":"Helvetica","sans-serif|bold":"Helvetica-Bold","sans-serif|italic":"Helvetica-Oblique","sans-serif|bold|italic":"Helvetica-BoldOblique",monospace:"Courier","monospace|bold":"Courier-Bold","monospace|italic":"Courier-Oblique","monospace|bold|italic":"Courier-BoldOblique",zapfdingbats:"ZapfDingbats","zapfdingbats|bold":"ZapfDingbats","zapfdingbats|italic":"ZapfDingbats","zapfdingbats|bold|italic":"ZapfDingbats"},q("Times New Roman","serif"),q("Courier New","monospace"),q("Arial","sans-serif"),q("Helvetica","sans-serif"),q("Verdana","sans-serif"),q("Tahoma","sans-serif"),q("Georgia","sans-serif"),q("Monaco","monospace"),q("Andale Mono","monospace"),at={fill:0,stroke:1,fillAndStroke:2,invisible:3,fillAndClip:4,strokeAndClip:5,fillStrokeClip:6,clip:7},lt=at,ct={dash:[4],dashDot:[4,2,1,2],dot:[1,2],longDash:[8,2],longDashDot:[8,2,1,2],longDashDotDot:[8,2,1,2,1,2],solid:[]},dt={butt:0,round:1,square:2},ut={miter:0,round:1,bevel:2},e.deepExtend(e.pdf,{Document:p,BinaryStream:t,defineFont:j,parseFontDef:U,getFontURL:W,loadFonts:qe,loadImages:je,getPaperOptions:f,TEXT_RENDERING_MODE:at,exportPDF:_e,saveAs:X,toDataURL:K,toBlob:Q,render:Y}),e.drawing.exportPDF=e.pdf.exportPDF,e.drawing.pdf=e.pdf}(kendo),kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("pdf/mixins.min",["pdf/core.min"],e)}(function(){return function(e,t){kendo.PDFMixin={extend:function(e){e.events.push("pdfExport"),e.options.pdf=this.options,e.saveAsPDF=this.saveAsPDF,e._drawPDF=this._drawPDF,e._drawPDFShadow=this._drawPDFShadow},options:{fileName:"Export.pdf",proxyURL:"",paperSize:"auto",allPages:!1,landscape:!1,margin:null,title:null,author:null,subject:null,keywords:null,creator:"Kendo UI PDF Generator v."+kendo.version,date:null},saveAsPDF:function(){var t,n=new e.Deferred,i=n.promise(),o={promise:i};if(!this.trigger("pdfExport",o))return t=this.options.pdf,t.multiPage=t.multiPage||t.allPages,this._drawPDF(n).then(function(e){return kendo.drawing.exportPDF(e,t)}).done(function(e){kendo.saveAs({dataURI:e,fileName:t.fileName,proxyURL:t.proxyURL,forceProxy:t.forceProxy,proxyTarget:t.proxyTarget}),n.resolve()}).fail(function(e){n.reject(e)}),i},_drawPDF:function(t){var n=new e.Deferred;return kendo.drawing.drawDOM(this.wrapper).done(function(e){var i={page:e,pageNumber:1,progress:1,totalPages:1};t.notify(i),n.resolve(i.page)}).fail(function(e){n.reject(e)}),n},_drawPDFShadow:function(t,n){var i,o,r;return t=t||{},i=this.wrapper,o=e("<div class='k-pdf-export-shadow'>"),t.width&&o.css({width:t.width,overflow:"visible"}),i.before(o),o.append(t.content||i.clone(!0,!0)),r=e.Deferred(),setTimeout(function(){var e=kendo.drawing.drawDOM(o,n);e.always(function(){o.remove()}).then(function(){r.resolve.apply(r,arguments)}).fail(function(){r.reject.apply(r,arguments)}).progress(function(){r.progress.apply(r,arguments)})},15),r.promise()}}}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.pdf.min",["kendo.core.min","kendo.drawing.min","pdf/core.min","pdf/mixins.min"],e)}(function(){},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.grid.min",["kendo.data.min","kendo.columnsorter.min","kendo.editable.min","kendo.window.min","kendo.filtermenu.min","kendo.columnmenu.min","kendo.groupable.min","kendo.pager.min","kendo.selectable.min","kendo.sortable.min","kendo.reorderable.min","kendo.resizable.min","kendo.mobile.actionsheet.min","kendo.mobile.pane.min","kendo.ooxml.min","kendo.excel.min","kendo.progressbar.min","kendo.pdf.min"],e)}(function(){return function(e,t){function n(e){return Array(e+1).join('<td class="k-group-cell">&nbsp;</td>')}function i(e){var t,n=" ";if(e){if(typeof e===bt)return e;for(t in e)n+=t+'="'+e[t]+'"'}return n}function o(t,n){e("th, th .k-grid-filter, th .k-link",t).add(document.body).css("cursor",n)}function r(t,n,i,o,r){var s,a=n;for(n=e(),r=r||1,s=0;s<r;s++)n=n.add(t.eq(a+s));"number"==typeof i?n[o?"insertBefore":"insertAfter"](t.eq(i)):n.appendTo(i)}function s(t,n,i){return e(t).add(n).find(i)}function a(e,t,n){var i,o,r,s;for(n=Se(n)?n:[n],i=0,o=n.length;i<o;i++)r=n[i],ye(r)&&r.click&&(s=r.name||r.text,t.on(mt+Ve,"a.k-grid-"+(s||"").replace(/\s/g,""),{commandName:s},Ae(r.click,e)))}function l(e,t,n){return xe(e,function(e){var i,o;return e=typeof e===bt?{field:e}:e,f(e)&&!n||(e.attributes=W(e.attributes),e.footerAttributes=W(e.footerAttributes),e.headerAttributes=W(e.headerAttributes),i=!0),e.columns&&(e.columns=l(e.columns,t,i)),o=he.guid(),e.headerAttributes=ke({id:o},e.headerAttributes),ke({encoded:t,hidden:i},e)})}function c(e,t){var n=[];return d(e,t,n),n[n.length-1]}function d(e,t,n){var i,o;for(n=n||[],i=0;i<t.length;i++){if(e===t[i])return!0;if(t[i].columns){if(o=n.length,n.push(t[i]),d(e,t[i].columns,n))return!0;n.splice(o,n.length-o)}}return!1}function u(e,t){var n=t?q:W;e.hidden=!t,e.attributes=n(e.attributes),e.footerAttributes=n(e.footerAttributes),e.headerAttributes=n(e.headerAttributes)}function h(){return"none"!==this.style.display}function f(e){return p([e]).length>0}function p(e){return Ce(e,function(e){var t=!e.hidden;return t&&e.columns&&(t=p(e.columns).length>0),t})}function m(t){return e(t).map(function(){return this.toArray()})}function g(e,t,n){var i=b(F(t)),o=b(z(t)),r=e.rowSpan;e.rowSpan=n?i>o?r-(i-o)||1:r+(o-i):i>o?r+(i-o):r-(o-i)||1}function v(t,n,i,o,r,s,a){var l,c,d=b(t),u=b([n]);d>u&&(l=Array(a+1).join('<th class="k-group-cell k-header" scope="col">&nbsp;</th>'),c=s.children(":not(.k-filter-row)"),e(Array(d-u+1).join("<tr>"+l+"</tr>")).insertAfter(c.last())),M(s,d-u),w(i,o,r,s)}function _(t,n,i){var o,r,s,a,l,c,d,u;for(i=i||0,s=n,n=H(n),a={},l=t.find(">tr:not(.k-filter-row)"),c=function(){var t=e(this);return!t.hasClass("k-group-cell")&&!t.hasClass("k-hierarchy-cell")},d=0,u=n.length;d<u;d++)o=y(n[d],s),a[o.row]||(a[o.row]=l.eq(o.row).find(".k-header").filter(c)),r=a[o.row].eq(o.cell),r.attr(he.attr("index"),i+d);return n.length}function b(e){var t,n,i=1,o=0;for(t=0;t<e.length;t++)e[t].columns&&(n=b(e[t].columns),n>o&&(o=n));return i+o}function w(t,n,i,o){var r,s,a=C(t[0],n),l=i.find(">tr:not(.k-filter-row):eq("+a.row+")>th.k-header"),c=e(),d=a.cell;for(r=0;r<t.length;r++)c=c.add(l.eq(d+r));for(o.find(">tr:not(.k-filter-row)").eq(a.row).append(c),s=[],r=0;r<t.length;r++)t[r].columns&&(s=s.concat(t[r].columns));s.length&&w(s,n,i,o)}function y(e,t,n,i){var o,r;for(n=n||0,i=i||{},i[n]=i[n]||0,r=0;r<t.length;r++){if(t[r]==e){o={cell:i[n],row:n};break}if(t[r].columns&&(o=y(e,t[r].columns,n+1,i)))break;i[n]++}return o}function k(e,t,n,i){var o,r=n.locked;do o=e[t],t+=i?1:-1;while(o&&t>-1&&t<e.length&&o!=n&&!o.columns&&o.locked==r);return o}function x(e,t,n,i){var o,r,s,a;return t.columns?(t=t.columns,t[i?0:t.length-1]):(o=c(t,e),r=o?o.columns:e,s=Te(t,r),0===s&&i?s++:s!=r.length-1||i?(s>0||0===s&&!i)&&(s+=i?-1:1):s--,a=Te(n,r),t=k(r,s,n,a>s),t&&t!=n&&t.columns?x(e,t,n,i):null)}function C(e,t,n,i){var o,r;for(n=n||0,i=i||{},i[n]=i[n]||0,r=0;r<t.length;r++){if(t[r]==e){o={cell:i[n],row:n};break}if(t[r].columns&&(o=C(e,t[r].columns,n+1,i)))break;t[r].hidden||i[n]++}return o}function S(e){var t=T(F(e));return t.concat(T(z(e)))}function T(e){var t,n=[],i=[];for(t=0;t<e.length;t++)n.push(e[t]),e[t].columns&&(i=i.concat(e[t].columns));return i.length&&(n=n.concat(T(i))),n}function D(e){var t,n,i=0;for(n=0;n<e.length;n++)t=e[n],t.columns?i+=D(t.columns):t.hidden&&i++;return i}function A(e){var t,n,i,o=0;for(n=0,i=e.length;n<i;n++)t=e[n].style.width,t&&t.indexOf("%")==-1&&(o+=parseInt(t,10));return o}function E(e,t){var n,i,o=e.find("tr:not(.k-filter-row) th:not(.k-group-cell,.k-hierarchy-cell)");for(i=0;i<o.length;i++)n=o[i].rowSpan,n>1&&(o[i].rowSpan=n-t||1)}function M(e,t){var n,i=e.find("tr:not(.k-filter-row) th:not(.k-group-cell,.k-hierarchy-cell)");for(n=0;n<i.length;n++)i[n].rowSpan+=t}function I(t){var n,i=t.find("tr:not(.k-filter-row)"),o=i.filter(function(){return!e(this).children().length}).remove().length,r=i.find("th:not(.k-group-cell,.k-hierarchy-cell)");for(n=0;n<r.length;n++)r[n].rowSpan>1&&(r[n].rowSpan-=o);return i.length-o}function R(e,t,n,i,o){var r,s,a,l=[];for(r=0,a=e.length;r<a;r++)s=n[i]||[],s.push(t.eq(o+r)),n[i]=s,e[r].columns&&(l=l.concat(e[r].columns));l.length&&R(l,t,n,i+1,o+e.length)}function F(e){return Ce(e,function(e){return e.locked})}function z(e){return Ce(e,function(e){return!e.locked})}function P(e){return Ce(e,function(e){return!e.locked&&f(e)})}function B(e){return Ce(e,function(e){return e.locked&&f(e)})}function L(e){var t,n=[];for(t=0;t<e.length;t++)e[t].hidden||(e[t].columns?n=n.concat(L(e[t].columns)):n.push(e[t]));return n}function H(e){var t,n=[];for(t=0;t<e.length;t++)e[t].columns?n=n.concat(H(e[t].columns)):n.push(e[t]);return n}function N(n){var i,o=n.find(">tr:not(.k-filter-row)"),r=function(){var t=e(this);return!t.hasClass("k-group-cell")&&!t.hasClass("k-hierarchy-cell")},s=e();return o.length>1&&(s=o.find("th").filter(r).filter(function(){return this.rowSpan>1})),s=s.add(o.last().find("th").filter(r)),i=he.attr("index"),s.sort(function(n,o){var r,s;return n=e(n),o=e(o),r=n.attr(i),s=o.attr(i),r===t&&(r=e(n).index()),s===t&&(s=e(o).index()),r=parseInt(r,10),s=parseInt(s,10),r>s?1:r<s?-1:0}),s}function O(t){var n,i,o,r,s,a,l,c=t.closest("table"),d=e().add(t),u=t.closest("tr"),h=c.find("tr:not(.k-filter-row)"),f=h.index(u);if(f>0){for(n=h.eq(f-1),i=n.find("th:not(.k-group-cell,.k-hierarchy-cell)").filter(function(){return!e(this).attr("rowspan")}),o=0,r=u.find("th:not(.k-group-cell,.k-hierarchy-cell)").index(t),s=t.prevAll(":not(.k-group-cell,.k-hierarchy-cell)").filter(function(){return this.colSpan>1}),a=0;a<s.length;a++)o+=s[a].colSpan||1;for(r+=Math.max(o-1,0),o=0,a=0;a<i.length;a++)if(l=i.eq(a),o+=l.attr("colSpan")?l[0].colSpan:1,r>=a&&r<o){d=O(l).add(d);break}}return d}function V(t){var n,i,o,r,s,a,l,c=t.closest("thead"),d=e().add(t),u=t.closest("tr"),h=c.find("tr:not(.k-filter-row)"),f=h.index(u)+t[0].rowSpan,p=he.attr("colspan");if(f<=h.length-1){for(n=u.next(),i=t.prevAll(":not(.k-group-cell,.k-hierarchy-cell)"),i=i.filter(function(){return!this.rowSpan||1===this.rowSpan}),r=0,o=0;o<i.length;o++)r+=parseInt(i.eq(o).attr(p),10)||1;for(s=n.find("th:not(.k-group-cell,.k-hierarchy-cell)"),a=parseInt(t.attr(p),10)||1,o=0;o<a;)n=s.eq(o+r),d=d.add(V(n)),l=parseInt(n.attr(p),10),l>1&&(a-=l-1),o++}return d}function U(t,n,i,o){var r,s=t;return o&&t.empty(),me?t[0].innerHTML=i:(r=document.createElement("div"),r.innerHTML="<table><tbody>"+i+"</tbody></table>",t=r.firstChild.firstChild,n[0].replaceChild(t,s[0]),t=e(t)),t}function W(e){e=e||{};var t=e.style;return t?(t=t.replace(/((.*)?display)(.*)?:([^;]*)/i,"$1:none"),t===e.style&&(t=t.replace(/(.*)?/i,"display:none;$1"))):t="display:none",ke({},e,{style:t})}function q(e){e=e||{};var t=e.style;return t&&(e.style=t.replace(/(display\s*:\s*none\s*;?)*/gi,"")),e}function j(t,n,i,o){var r,s=t.find(">colgroup"),a=xe(n,function(e){return r=e.width,r&&0!==parseInt(r,10)?he.format('<col style="width:{0}"/>',typeof r===bt?r:r+"px"):"<col />"});(i||s.find(".k-hierarchy-col").length)&&a.splice(0,0,'<col class="k-hierarchy-col" />'),s.length&&s.remove(),s=e(Array(o+1).join('<col class="k-group-col">')+a.join("")),s.is("colgroup")||(s=e("<colgroup/>").append(s)),t.prepend(s),Bt.msie&&8==Bt.version&&(t.css("display","inline-table"),window.setTimeout(function(){t.css("display","")},1))}function G(e,t){var n,i,o=0,r=e.find("th:not(.k-group-cell)");for(n=0,i=t.length;n<i;n++)t[n].locked&&(r.eq(n).insertBefore(r.eq(o)),r=e.find("th:not(.k-group-cell)"),o++)}function $(e){var t,n,i,o={};for(n=0,i=e.length;n<i;n++)t=e[n],o[t.value]=t.text;return o}function Y(e,t,n,i){var o=n&&n.length&&ye(n[0])&&"value"in n[0],r=o?$(n)[e]:e;return r=null!=r?r:"",t?he.format(t,r):i===!1?r:he.htmlEncode(r)}function K(e,t,n){for(var i,o=0,r=e[o];r;){if(i=!!n||"none"!==r.style.display,i&&!Mt.test(r.className)&&--t<0){r.style.display=n?"":"none";break}r=e[++o]}}function Q(t,n){for(var i,o,r=0,s=t.length;r<s;r+=1)o=t.eq(r),o.is(".k-grouping-row,.k-detail-row")?(i=o.children(":not(.k-group-cell):first,.k-detail-cell").last(),i.attr("colspan",parseInt(i.attr("colspan"),10)-1)):(o.hasClass("k-grid-edit-row")&&(i=o.children(".k-edit-container")[0])&&(i=e(i),i.attr("colspan",parseInt(i.attr("colspan"),10)-1),i.find("col").eq(n).remove(),o=i.find("tr:first")),K(o[0].cells,n,!1))}function X(e){var t,n,i=[];for(n=0;n<e.length&&(t=e[n],"field"in t&&"value"in t&&"items"in t);n++)i.push(t),t.hasSubgroups&&(i=i.concat(X(t.items)));return i}function Z(e){var t,n,i=[];for(n=0;n<e.length&&(t=e[n],"field"in t&&"value"in t&&"items"in t);n++)t.hasSubgroups&&(i=i.concat(Z(t.items))),i.push(t.aggregates);return i}function J(t,n){for(var i,o,r,s=0,a=t.length;s<a;s+=1)o=t.eq(s),o.is(".k-grouping-row,.k-detail-row")?(i=o.children(":not(.k-group-cell):first,.k-detail-cell").last(),i.attr("colspan",parseInt(i.attr("colspan"),10)+1)):(o.hasClass("k-grid-edit-row")&&(i=o.children(".k-edit-container")[0])&&(i=e(i),i.attr("colspan",parseInt(i.attr("colspan"),10)+1),j(i.find(">form>table"),p(r),!1,0),o=i.find("tr:first")),K(o[0].cells,n,!0))}function ee(e,t,n){n=n||1;var i,o,r;for(o=0,r=e.length;o<r;o++)i=e.eq(o).children().last(),i.attr("colspan",parseInt(i.attr("colspan"),10)+n),i=t.eq(o).children().last(),i.attr("colspan",parseInt(i.attr("colspan"),10)-n)}function te(e){var t,n,i=0,o=e.find(">colgroup>col");for(t=0,n=o.length;t<n;t+=1)i+=parseInt(o[t].style.width,10);return i}function ne(e,t){var n,i,o,r;e=e[0],t=t[0],e.rows.length!==t.rows.length&&(n=e.offsetHeight,i=t.offsetHeight,n>i?(o=t.rows[t.rows.length-1],It.test(o.className)&&(o=t.rows[t.rows.length-2]),r=n-i):(o=e.rows[e.rows.length-1],It.test(o.className)&&(o=e.rows[e.rows.length-2]),r=i-n),o.style.height=o.offsetHeight+r+"px")}function ie(e,t){var n,i=e.offsetHeight,o=t.offsetHeight;i>o?n=i+"px":i<o&&(n=o+"px"),n&&(e.style.height=t.style.height=n)}function oe(e,t){var n,i,o;if(typeof e===bt&&e===t)return e;if(ye(e)&&e.name===t)return e;if(Se(e))for(n=0,i=e.length;n<i;n++)if(o=e[n],typeof o===bt&&o===t||o.name===t)return o;return null}function re(t,n){var i,o,r=Bt.msie||Bt.edge;if(n===!0){if(t=e(t),i=t.parent().scrollTop(),o=t.parent().scrollLeft(),r)try{t[0].setActive()}catch(s){t[0].focus()}else t[0].focus();t.parent().scrollTop(i).scrollLeft(o)}else e(t).one("focusin",function(e){e.preventDefault()}).focus()}function se(e,t){return!(!e.field||e.selectable)&&(!(t.editable&&!t.editable(e.field))&&!(e.editable&&!e.editable(t)))}function ae(t){return e(t).is(":button,a,:input,a>.k-icon,textarea,span.k-select,span.k-icon,span.k-link,.k-input,.k-multiselect-wrap,.k-tool-icon")}function le(n){var i=e(n.currentTarget),o=i.is("th"),r=this.table.add(this.lockedTable),s=this.thead.parent().add(e(">table",this.lockedHeader)),a=ae(n.target),l=i.closest("table")[0];if(!he.support.touch)return a&&i.find(he.roleSelector("filtercell")).length?(this._setCurrent(i),t):(l!==r[0]&&l!==r[1]&&l!==s[0]&&l!==s[1]||e(n.target).is("a.k-i-expand, a.k-i-collapse")||(this.options.navigatable&&this._setCurrent(i),!o&&a||setTimeout(function(){Ht&&e(he._activeElement()).hasClass("k-widget")||ae(he._activeElement())||re(l,!0)}),o&&n.preventDefault()),t)}function ce(e){return e&&(e.hasClass("k-edit-cell")||e.parent().hasClass("k-grid-edit-row"))}function de(e,t,i){return'<tr role="row" class="k-grouping-row">'+n(t)+'<td colspan="'+e+'" aria-expanded="true"><p class="k-reset"><a class="k-icon k-i-collapse" href="#" tabindex="-1" '+Tt+'="'+Ct+'"></a>'+i+"</p></td></tr>"}function ue(e){return'<tr role="row" class="k-grouping-row"><td colspan="'+e+'" aria-expanded="true"><p class="k-reset">&nbsp;</p></td></tr>'}var he=window.kendo,fe=he.ui,pe=he.data.DataSource,me=he.support.tbodyInnerHtml,ge=he._activeElement,ve=fe.Widget,_e=he._outerWidth,be=he._outerHeight,we=he.keys,ye=e.isPlainObject,ke=e.extend,xe=e.map,Ce=e.grep,Se=e.isArray,Te=e.inArray,De=Array.prototype.push,Ae=e.proxy,Ee=he.isFunction,Me=e.isEmptyObject,Ie=Math,Re="progress",Fe="error",ze=":not(.k-group-cell):not(.k-hierarchy-cell):visible",Pe="tbody>tr:not(.k-grouping-row):not(.k-detail-row):not(.k-group-footer) > td:not(.k-group-cell):not(.k-hierarchy-cell)",Be="tr:not(.k-footer-template):visible",Le=":not(.k-group-cell):not(.k-hierarchy-cell):visible",He="tr:not(.k-grouping-row):not(.k-detail-row):not(.k-footer-template):not(.k-group-footer):visible",Ne=Be+":first>"+Le+":first",Oe="th.k-header:not(.k-group-cell):not(.k-hierarchy-cell)",Ve=".kendoGrid",Ue="edit",We="beforeEdit",qe="save",je="remove",Ge="detailInit",$e="filterMenuInit",Ye="columnMenuInit",Ke="filterMenuOpen",Qe="columnMenuOpen",Xe="cellClose",Ze="change",Je="columnHide",et="columnShow",tt="saveChanges",nt="dataBound",it="detailExpand",ot="detailCollapse",rt="k-state-focused",st="k-state-selected",at="k-checkbox",lt="input[data-role='checkbox']."+at,ct="k-grid-norecords",dt="columnResize",ut="columnReorder",ht="columnLock",ft="columnUnlock",pt="navigate",mt="click",gt="height",vt="tabIndex",_t="function",bt="string",wt="Are you sure you want to delete this record?",yt="No records available.",kt="Delete",xt="Cancel",Ct="Collapse",St="Expand",Tt="aria-label",Dt=/(\}|\#)/gi,At=/#/gi,Et="[\\x20\\t\\r\\n\\f]",Mt=RegExp("(^|"+Et+")(k-group-cell|k-hierarchy-cell)("+Et+"|$)"),It=RegExp("(^|"+Et+")(k-filter-row)("+Et+"|$)"),Rt='# if (iconClass) {#<a role="button" class="k-button k-button-icontext #=className#" #=attr# href="\\#"><span class="#=iconClass# #=imageClass#"></span>#=text#</a># } else { #<a role="button" class="k-button k-button-icontext #=className#" #=attr# href="\\#">#=text#</a># } #',Ft='<input class="'+at+'" data-role="checkbox" aria-label="Select row" aria-checked="false" type="checkbox"><label class="k-checkbox-label k-no-text">&\\#8203;</label>',zt='<input class="'+at+'" data-role="checkbox" aria-label="Select all rows" aria-checked="false" type="checkbox"><label class="k-checkbox-label k-no-text">&#8203;</label>',Pt=!1,Bt=he.support.browser,Lt=Bt.msie&&7==Bt.version,Ht=Bt.msie&&8==Bt.version,Nt=ve.extend({init:function(e,t){var n=this;ve.fn.init.call(n,e,t),n._refreshHandler=Ae(n.refresh,n),n.setDataSource(t.dataSource),n.wrap()},setDataSource:function(e){var t=this;t.dataSource&&t.dataSource.unbind(Ze,t._refreshHandler),t.dataSource=e,t.dataSource.bind(Ze,t._refreshHandler)},options:{name:"VirtualScrollable",itemHeight:e.noop,prefetch:!0},destroy:function(){var e=this;ve.fn.destroy.call(e),e.dataSource.unbind(Ze,e._refreshHandler),e.wrapper.add(e.verticalScrollbar).off(Ve),e.drag&&(e.drag.destroy(),e.drag=null),e.wrapper=e.element=e.verticalScrollbar=null,e._refreshHandler=null},wrap:function(){var t,n=this,i=he.support.scrollbar()+1,o=n.element;o.css({width:"auto",overflow:"hidden"}).css(Pt?"padding-left":"padding-right",i),n.content=o.children().first(),t=n.wrapper=n.content.wrap('<div class="k-virtual-scrollable-wrap"/>').parent().bind("DOMMouseScroll"+Ve+" mousewheel"+Ve,Ae(n._wheelScroll,n)),he.support.kineticScrollNeeded&&(n.drag=new he.UserEvents(n.wrapper,{global:!0,start:function(e){e.sender.capture()},move:function(e){n.verticalScrollbar.scrollTop(n.verticalScrollbar.scrollTop()-e.y.delta),t.scrollLeft(t.scrollLeft()-e.x.delta),e.preventDefault()}})),n.verticalScrollbar=e('<div class="k-scrollbar k-scrollbar-vertical" />').css({width:i}).appendTo(o).bind("scroll"+Ve,Ae(n._scroll,n))},_wheelScroll:function(e){if(!e.ctrlKey){var t=this.verticalScrollbar,n=t.scrollTop(),i=he.wheelDeltaY(e);!i||i>0&&0===n||i<0&&n+t[0].clientHeight==t[0].scrollHeight||(e.preventDefault(),this.verticalScrollbar.scrollTop(n+-i))}},_scroll:function(e){var t=this,n=!t.options.prefetch,i=e.currentTarget.scrollTop,o=t.dataSource,r=t.itemHeight,s=o.skip()||0,a=t._rangeStart||s,l=t.element.innerHeight(),c=!!(t._scrollbarTop&&t._scrollbarTop>i),d=Ie.max(Ie.floor(i/r),0),u=Ie.max(d+Ie.floor(l/r),0);t._scrollTop=i-a*r,t._scrollbarTop=i,t._scrolling=n,t._fetch(d,u,c)||(t.wrapper[0].scrollTop=t._scrollTop),n&&(t._scrollingTimeout&&clearTimeout(t._scrollingTimeout),t._scrollingTimeout=setTimeout(function(){t._scrolling=!1,t._page(t._rangeStart,t.dataSource.take())},100))},itemIndex:function(e){var t=this._rangeStart||this.dataSource.skip()||0;return t+e},position:function(e){var t,n=this._rangeStart||this.dataSource.skip()||0,i=this.dataSource.pageSize();return t=e>n?e-n+1:n-e-1,t>i?i:t},scrollIntoView:function(e){var t=this.wrapper[0],n=t.clientHeight,i=this._scrollTop||t.scrollTop,o=e[0].offsetTop,r=e[0].offsetHeight;i>o?this.verticalScrollbar[0].scrollTop-=n/2:o+r>=i+n&&(this.verticalScrollbar[0].scrollTop+=n/2)},_fetch:function(t,n,i){var o=this,r=o.dataSource,s=o.itemHeight,a=r.take(),l=o._rangeStart||r.skip()||0,c=Ie.floor(t/a)*a,d=!1,u=.33;return t<l?(d=!0,l=Ie.max(0,n-a),o._scrollTop=(t-l)*s,o._page(l,a)):n>=l+a&&!i?(d=!0,l=t,o._scrollTop=s,o._page(l,a)):!o._fetching&&o.options.prefetch&&(t<c+a-a*u&&t>a&&r.prefetch(c-a,a,e.noop),n>c+a*u&&r.prefetch(c+a,a,e.noop)),d},fetching:function(){return this._fetching},_page:function(e,t){var n=this,i=!n.options.prefetch,o=n.dataSource;clearTimeout(n._timeout),n._fetching=!0,n._rangeStart=e,o.inRange(e,t)?o.range(e,t):(i||he.ui.progress(n.wrapper.parent(),!0),n._timeout=setTimeout(function(){n._scrolling||(i&&he.ui.progress(n.wrapper.parent(),!0),o.range(e,t))},100))},repaintScrollbar:function(){var e,t=this,n="",i=25e4,o=t.dataSource,r=he.support.kineticScrollNeeded?0:he.support.scrollbar(),s=t.wrapper[0],a=t.itemHeight=t.options.itemHeight()||0,l=s.scrollWidth>s.offsetWidth?r:0,c=o.total()*a+l;for(e=0;e<Ie.floor(c/i);e++)n+='<div style="width:1px;height:'+i+'px"></div>';c%i&&(n+='<div style="width:1px;height:'+c%i+'px"></div>'),t.verticalScrollbar.html(n),s.scrollTop=t._scrollTop},refresh:function(){var e=this,t=e.dataSource,n=e._rangeStart;he.ui.progress(e.wrapper.parent(),!1),clearTimeout(e._timeout),e.repaintScrollbar(),e.drag&&e.drag.cancel(),n&&!e._fetching&&(e._rangeStart=t.skip(),1===t.page()&&(e.verticalScrollbar[0].scrollTop=0)),e._fetching=!1}}),Ot={create:{text:"Add new record",imageClass:"k-i-plus",className:"k-grid-add",iconClass:"k-icon"},cancel:{text:"Cancel changes",imageClass:"k-i-cancel",className:"k-grid-cancel-changes",iconClass:"k-icon"},save:{text:"Save changes",imageClass:"k-i-check",className:"k-grid-save-changes",iconClass:"k-icon"},destroy:{text:"Delete",imageClass:"k-i-close",className:"k-grid-delete",iconClass:"k-icon"},edit:{text:"Edit",imageClass:"k-i-edit",className:"k-grid-edit",iconClass:"k-icon"},update:{text:"Update",imageClass:"k-i-check",className:"k-primary k-grid-update",iconClass:"k-icon"},canceledit:{text:"Cancel",imageClass:"k-i-cancel",className:"k-grid-cancel",iconClass:"k-icon"},excel:{text:"Export to Excel",imageClass:"k-i-file-excel",className:"k-grid-excel",iconClass:"k-icon"},pdf:{text:"Export to PDF",imageClass:"k-i-file-pdf",className:"k-grid-pdf",iconClass:"k-icon"}},Vt=he.ui.DataBoundWidget.extend({init:function(t,n,i){var o=this;n=Se(n)?{dataSource:n}:n,ve.fn.init.call(o,t,n),i&&(o._events=i),Pt=he.support.isRtl(t),o._element(),o._aria(),o._columns(o.options.columns),o._dataSource(),o._tbody(),o._pageable(),o._thead(),o._groupable(),o._toolbar(),o._setContentHeight(),o._templates(),o._navigatable(),o._selectable(),o._clipboard(),o._details(),o._editable(),o._attachCustomCommandsEvent(),o._minScreenSupport(),o.options.autoBind?o.dataSource.fetch():(o._group=o._groups()>0,o._footer()),o.lockedContent&&(o.wrapper.addClass("k-grid-lockedcolumns"),o._resizeHandler=function(){o.resize()},e(window).on("resize"+Ve,o._resizeHandler)),he.notify(o)},events:[Ze,"dataBinding","cancel",nt,it,ot,Ge,$e,Ke,Ye,Qe,Ue,We,qe,je,tt,Xe,dt,ut,et,Je,ht,ft,pt,"page","sort","filter","group"],setDataSource:function(e){var t=this,n=t.options.scrollable;t.options.dataSource=e,t._dataSource(),t._pageable(),t._thead(),n&&(n.virtual?t.content.find(">.k-virtual-scrollable-wrap").scrollLeft(0):t.content.scrollLeft(0)),t.options.groupable&&t._groupable(),t.virtualScrollable&&t.virtualScrollable.setDataSource(t.options.dataSource),t.options.navigatable&&t._navigatable(),t.options.selectable&&t._selectable(),t.options.autoBind&&e.fetch()},options:{name:"Grid",columns:[],toolbar:null,autoBind:!0,filterable:!1,scrollable:!0,sortable:!1,selectable:!1,allowCopy:!1,navigatable:!1,pageable:!1,persistSelection:!1,editable:!1,groupable:!1,rowTemplate:"",altRowTemplate:"",noRecords:!1,dataSource:{},height:null,resizable:!1,reorderable:!1,columnMenu:!1,detailTemplate:null,columnResizeHandleWidth:3,mobile:"",messages:{editable:{cancelDelete:xt,confirmation:wt,confirmDelete:kt},commands:{create:Ot.create.text,cancel:Ot.cancel.text,save:Ot.save.text,destroy:Ot.destroy.text,edit:Ot.edit.text,update:Ot.update.text,canceledit:Ot.canceledit.text,excel:Ot.excel.text,pdf:Ot.pdf.text},noRecords:yt,expandCollapseColumnHeader:""
}},destroy:function(){var t,n=this;n._angularItems("cleanup"),n._destroyColumnAttachments(),ve.fn.destroy.call(n),this._navigatableTables=null,n._resizeHandler&&e(window).off("resize"+Ve,n._resizeHandler),n.pager&&n.pager.element&&n.pager.destroy(),n.pager=null,n.groupable&&n.groupable.element&&n.groupable.element.kendoGroupable("destroy"),n.groupable=null,n.options.reorderable&&n.wrapper.data("kendoReorderable").destroy(),n.selectable&&n.selectable.element&&(n.selectable.destroy(),n.clearArea(),n.options.persistSelection===!0&&(n._selectedIds=null),n.copyHandler&&(n.wrapper.off("keydown",n.copyHandler),n.unbind(n.copyHandler)),n.updateClipBoardState&&(n.unbind(n.updateClipBoardState),n.updateClipBoardState=null),n.clearAreaHandler&&n.wrapper.off("keyup",n.clearAreaHandler)),n.selectable=null,n.resizable&&(n.resizable.destroy(),n._resizeUserEvents&&(n._resizeHandleDocumentClickHandler&&e(document).off("click",n._resizeHandleDocumentClickHandler),n._resizeUserEvents.destroy(),n._resizeUserEvents=null),n.resizable=null),n.virtualScrollable&&n.virtualScrollable.element&&n.virtualScrollable.destroy(),n.virtualScrollable=null,n._destroyEditable(),n.dataSource&&(n.dataSource.unbind(Ze,n._refreshHandler).unbind(Re,n._progressHandler).unbind(Fe,n._errorHandler),n._refreshHandler=n._progressHandler=n._errorHandler=null),t=n.element.add(n.wrapper).add(n.table).add(n.thead).add(n.wrapper.find(">.k-grid-toolbar")),n.content&&(t=t.add(n.content).add(n.content.find(">.k-virtual-scrollable-wrap"))),n.lockedHeader&&n._removeLockedContainers(),n.pane&&n.pane.destroy(),n.minScreenResizeHandler&&e(window).off("resize",n.minScreenResizeHandler),n._draggableInstance&&n._draggableInstance.element&&n._draggableInstance.destroy(),n._draggableInstance=null,t.off(Ve),he.destroy(n.wrapper),n.rowTemplate=n.altRowTemplate=n.lockedRowTemplate=n.lockedAltRowTemplate=n.detailTemplate=n.footerTemplate=n.groupFooterTemplate=n.lockedGroupFooterTemplate=n.noRecordsTemplate=null,n.scrollables=n.thead=n.tbody=n.element=n.table=n.content=n.footer=n.wrapper=n.lockedTable=n.lockedContent=n.lockedHeader=n.lockedFooter=n._groupableClickHandler=n._setContentWidthHandler=null},getOptions:function(){var n,i,o,r=this.options;return r.dataSource=null,n=ke(!0,{},this.options),n.columns=he.deepExtend([],this.columns),i=this.dataSource,o=i.options.data&&i._data,i.options.data=null,n.dataSource=e.extend(!0,{},i.options),i.options.data=o,n.dataSource.data=o,n.dataSource.page=i.page(),n.dataSource.filter=i.filter(),n.dataSource.pageSize=i.pageSize(),n.dataSource.sort=i.sort(),n.dataSource.group=i.group(),n.dataSource.aggregate=i.aggregate(),n.dataSource.transport&&(n.dataSource.transport.dataSource=null),n.pageable&&n.pageable.pageSize&&(n.pageable.pageSize=i.pageSize()),n.$angular=t,n},setOptions:function(e){var t,n,i,o,r=this.getOptions();he.deepExtend(r,e),e.dataSource||(r.dataSource=this.dataSource),t=this.wrapper,n=this._events,i=this.element,this.destroy(),this.options=null,this._isMobile&&(o=t.closest(he.roleSelector("pane")).parent(),o.after(t),o.remove(),t.removeClass("k-grid-mobile")),t[0]!==i[0]&&(t.before(i),t.remove()),i.empty(),this.init(i,r,n),this._setEvents(r)},items:function(){return this.lockedContent?this._items(this.tbody).add(this._items(this.lockedTable.children("tbody"))):this._items(this.tbody)},_items:function(t){return t.children().filter(function(){var t=e(this);return!t.hasClass("k-grouping-row")&&!t.hasClass("k-detail-row")&&!t.hasClass("k-group-footer")})},dataItems:function(){var e,t,n,i=he.ui.DataBoundWidget.fn.dataItems.call(this);if(this.lockedContent){for(e=i.length,t=Array(2*e),n=e;--n>=0;)t[n]=t[n+e]=i[n];i=t}return i},_destroyColumnAttachments:function(){var t=this;t.resizeHandle=null,t.thead&&(this.angular("cleanup",function(){return{elements:t.thead.get()}}),t.thead.add(t.lockedHeader).find("th").each(function(){var t=e(this),n=t.data("kendoFilterMenu"),i=t.data("kendoColumnSorter"),o=t.data("kendoColumnMenu");n&&n.destroy(),i&&i.destroy(),o&&o.destroy()}))},_attachCustomCommandsEvent:function(){var e,t,n,i=this,o=H(i.columns||[]);for(t=0,n=o.length;t<n;t++)e=o[t].command,e&&a(i,i.wrapper,e)},_aria:function(){var e=this.element.attr("id")||"aria";e&&(this._cellId=e+"_active_cell")},_element:function(){var t=this,n=t.element;n.is("table")||(n=t.options.scrollable?t.element.find("> .k-grid-content > table"):t.element.children("table"),n.length||(n=e("<table />").appendTo(t.element))),Lt&&n.attr("cellspacing",0),t.table=n.attr("role",t._hasDetails()?"treegrid":"grid"),t._wrapper()},_createResizeHandle:function(t,n){var i,o,r,s,a,l,c,d=this,u=d.options.columnResizeHandleWidth,h=d.options.scrollable,f=d.resizeHandle,p=this._groups();if(f&&d.lockedContent&&f.data("th")[0]!==n[0]&&(f.off(Ve).remove(),f=null),f||(f=d.resizeHandle=e('<div class="k-resize-handle"><div class="k-resize-handle-inner"></div></div>'),t.append(f)),Pt)i=n.position().left,h&&(s=n.closest(".k-grid-header-wrap, .k-grid-header-locked"),a=Bt.msie?s.scrollLeft():0,l=Bt.webkit?s[0].scrollWidth-s[0].offsetWidth-s.scrollLeft():0,c=Bt.mozilla?s[0].scrollWidth-s[0].offsetWidth-(s[0].scrollWidth-s[0].offsetWidth-s.scrollLeft()):0,i-=l-c+a);else{for(i=n[0].offsetWidth,o=N(n.closest("thead")).filter(":visible"),r=0;r<o.length&&o[r]!=n[0];r++)i+=o[r].offsetWidth;p>0&&(i+=_e(t.find(".k-group-cell:first"))*p),d._hasDetails()&&(i+=_e(t.find(".k-hierarchy-cell:first")))}f.css({top:n.position().top,left:i-u,height:be(n),width:3*u}).data("th",n).show(),f.off("dblclick"+Ve).on("dblclick"+Ve,function(){d._autoFitLeafColumn(n.data("index"))})},_positionColumnResizeHandle:function(){var t=this,n=t.options.columnResizeHandleWidth,i=t.lockedHeader?t.lockedHeader.find("thead:first"):e();t.thead.add(i).on("mousemove"+Ve,"th",function(i){function r(){var t,n=parseFloat(e(document.documentElement).css("zoom"));return isNaN(n)&&(n=1),t=parseFloat(e(document.body).css("zoom")),isNaN(t)&&(t=1),n*t}var s,a,l,c=e(this);c.hasClass("k-group-cell")||c.hasClass("k-hierarchy-cell")||(s=i.clientX/r(),a=e(window).scrollLeft(),l=c.offset().left+(Pt?0:this.offsetWidth),s+a>l-n&&s+a<l+n?t._createResizeHandle(c.closest("div"),c):t.resizeHandle?t.resizeHandle.hide():o(t.wrapper,""))})},_resizeHandleDocumentClick:function(t){e(t.target).closest(".k-column-active").length||(e(document).off(t),this._hideResizeHandle())},_hideResizeHandle:function(){this.resizeHandle&&(this.resizeHandle.data("th").removeClass("k-column-active"),this.lockedContent&&!this._isMobile?(this.resizeHandle.off(Ve).remove(),this.resizeHandle=null):this.resizeHandle.hide())},_positionColumnResizeHandleTouch:function(){var t=this,n=t.lockedHeader?t.lockedHeader.find("thead:first"):e();t._resizeUserEvents=new he.UserEvents(n.add(t.thead),{filter:"th:not(.k-group-cell):not(.k-hierarchy-cell)",threshold:10,hold:function(n){var i=e(n.target);n.preventDefault(),i.addClass("k-column-active"),t._createResizeHandle(i.closest("div"),i),t._resizeHandleDocumentClickHandler||(t._resizeHandleDocumentClickHandler=Ae(t._resizeHandleDocumentClick,t)),e(document).on("click",t._resizeHandleDocumentClickHandler)}})},_resizable:function(){var t,n,i,r,s,a,l,c,d=this,u=d.options,h=this._isMobile,f=he.support.mobileOS?0:he.support.scrollbar();u.resizable&&(t=u.scrollable?d.wrapper.find(".k-grid-header-wrap:first"):d.wrapper,h?d._positionColumnResizeHandleTouch(t):d._positionColumnResizeHandle(t),d.resizable&&d.resizable.destroy(),d.resizable=new fe.Resizable(t.add(d.lockedHeader),{handle:(u.scrollable?"":">")+".k-resize-handle",hint:function(t){return e('<div class="k-grid-resize-indicator" />').css({height:be(t.data("th"))+d.tbody.attr("clientHeight")})},start:function(t){var f,p,m,g;c=e(t.currentTarget).data("th"),h&&d._hideResizeHandle(),f=c.closest("table"),p=e.inArray(c[0],N(c.closest("thead")).filter(":visible")),a=f.parent().hasClass("k-grid-header-locked"),m=a?d.lockedTable:d.table,g=d.footer||e(),d.footer&&d.lockedContent&&(g=d.footer.children(a?".k-grid-footer-locked":".k-grid-footer-wrap")),o(d.wrapper,"col-resize"),l=u.scrollable?f.find("col:not(.k-group-col):not(.k-hierarchy-col):eq("+p+")").add(m.children("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col):eq("+p+")")).add(g.find("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col):eq("+p+")")):m.children("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col):eq("+p+")"),n=t.x.location,i=_e(c),r=H(d.columns)[p].minResizableWidth||10,s=_e(a?m.children("tbody"):d.tbody),Bt.webkit&&d.wrapper.addClass("k-grid-column-resizing")},resize:function(t){var o,h,p,m,g,v,_=Pt?-1:1,b=i+t.x.location*_-n*_;u.scrollable?(a&&d.lockedFooter?o=d.lockedFooter.children("table"):d.footer&&(o=d.footer.find(">.k-grid-footer-wrap>table")),o&&o[0]||(o=e()),h=c.closest("table"),p=a?d.lockedTable:d.table,m=!1,g=d.wrapper.width()-f,v=b,a&&s-i+v>g&&(v=i+(g-s-2*f),v<0&&(v=b),m=!0),v>10&&v>=r&&(l.css("width",v),s&&(v=m?g-2*f:s+t.x.location*_-n*_,p.add(h).add(o).css("width",v),a||(d._footerWidth=v)))):b>10&&b>=r&&l.css("width",b)},resizeend:function(){var e,t,n,r=_e(c);o(d.wrapper,""),Bt.webkit&&d.wrapper.removeClass("k-grid-column-resizing"),i!=r&&(t=d.lockedHeader?d.lockedHeader.find("thead:first tr:first").add(d.thead.find("tr:first")):c.parent(),n=c.attr(he.attr("index")),n||(n=t.find("th:not(.k-group-cell):not(.k-hierarchy-cell)").index(c)),e=H(d.columns)[n],e.width=r,d.trigger(dt,{column:e,oldWidth:i,newWidth:r}),d._applyLockedContainersWidth(),d._syncLockedContentHeight(),d._syncLockedHeaderHeight()),d._hideResizeHandle(),c=null}}))},_draggable:function(){var t,n=this;n.options.reorderable&&(n._draggableInstance&&n._draggableInstance.destroy(),t=n.wrapper.children(".k-grid-header"),n._draggableInstance=n.wrapper.kendoDraggable({group:he.guid(),autoScroll:!0,filter:n.content?".k-grid-header:first "+Oe:"table:first>.k-grid-header "+Oe,dragstart:function(){t.children(".k-grid-header-wrap").unbind("scroll"+Ve+"scrolling").bind("scroll"+Ve+"scrolling",function(e){n.virtualScrollable?n.content.find(">.k-virtual-scrollable-wrap").scrollLeft(this.scrollLeft):n.scrollables.not(e.currentTarget).scrollLeft(this.scrollLeft)})},dragend:function(){t.children(".k-grid-header-wrap").unbind("scroll"+Ve+"scrolling")},drag:function(){n._hideResizeHandle()},hint:function(t){var n=t.attr(he.attr("title"));return n&&(n=he.htmlEncode(n)),e('<div class="k-header k-drag-clue" />').css({width:t.width(),paddingLeft:t.css("paddingLeft"),paddingRight:t.css("paddingRight"),lineHeight:t.height()+"px",paddingTop:t.css("paddingTop"),paddingBottom:t.css("paddingBottom")}).html(n||t.attr(he.attr("field"))||t.text()).prepend('<span class="k-icon k-drag-status k-i-cancel" />')}}).data("kendoDraggable"))},_reorderable:function(){var t,n=this;n.options.reorderable&&(n.wrapper.data("kendoReorderable")&&n.wrapper.data("kendoReorderable").destroy(),t=function(e,t,i){var o=e[t],r=e[i],s=c(o,n.columns);return e=s?s.columns:n.columns,Te(r,e)},n.wrapper.kendoReorderable({draggable:n._draggableInstance,dragOverContainers:function(e,i){var o=S(n.columns);return o[e].lockable!==!1&&t(o,e,i)>-1},inSameContainer:function(i){return e(i.source).parent()[0]===e(i.target).parent()[0]&&t(S(n.columns),i.sourceIndex,i.targetIndex)>-1},change:function(e){var i=S(n.columns),o=i[e.oldIndex],r=t(i,e.oldIndex,e.newIndex);n.trigger(ut,{newIndex:r,oldIndex:Te(o,i),column:o}),n.reorderColumn(r,o,"before"===e.position)}}))},_reorderHeader:function(e,t,n){var i,o,a,l,c=this,d=y(e[0],c.columns),u=y(t,c.columns),h=[];for(i=0;i<e.length;i++)e[i].columns&&(h=h.concat(e[i].columns));o=s(c.lockedHeader,c.thead,"tr:eq("+d.row+")>th.k-header:not(.k-group-cell,.k-hierarchy-cell)"),a=F(e).length,l=F([t]).length,h.length?(a>0&&0===l?v(e,t,h,c.columns,c.lockedHeader.find("thead"),c.thead,this._groups()):0===a&&l>0&&v(e,t,h,c.columns,c.thead,c.lockedHeader.find("thead"),this._groups()),(t.columns||d.cell-u.cell>1||u.cell-d.cell>1)&&(t=x(c.columns,t,e[0],n),t&&c._reorderHeader(h,t,n))):a!==l&&g(o[d.cell],c.columns,a),r(o,d.cell,u.cell,n,e.length)},_reorderContent:function(t,n,i){var o,a,l,c,d=this,u=e(),h=t[0],f=p(t),m=Te(h,H(d.columns)),g=Te(n,H(d.columns)),v=Te(h,L(d.columns)),_=Te(n,L(d.columns)),b=F(d.columns).length,w=!!n.locked,y=d.footer||d.wrapper.find(".k-grid-footer"),k=o=_;for(n.hidden&&(w?(_=d.lockedTable.find("colgroup"),k=d.lockedHeader.find("colgroup"),o=e(d.lockedFooter).find(">table>colgroup")):(_=d.tbody.prev(),k=d.thead.prev(),o=y.find(".k-grid-footer-wrap").find(">table>colgroup"))),d._hasFilterRow()&&r(d.wrapper.find(".k-filter-row th:not(.k-group-cell,.k-hierarchy-cell)"),m,g,i,t.length),r(s(d.lockedHeader,d.thead.prev(),"col:not(.k-group-col,.k-hierarchy-col)"),v,k,i,f.length),d.options.scrollable&&r(s(d.lockedTable,d.tbody.prev(),"col:not(.k-group-col,.k-hierarchy-col)"),v,_,i,f.length),y&&y.length&&(r(s(d.lockedFooter,y.find(".k-grid-footer-wrap"),">table>colgroup>col:not(.k-group-col,.k-hierarchy-col)"),v,o,i,f.length),r(y.find(".k-footer-template>td:not(.k-group-cell,.k-hierarchy-cell)"),m,g,i,t.length)),a=d.tbody.children(":not(.k-grouping-row,.k-detail-row)"),d.lockedTable&&(b>g?b<=m&&ee(d.lockedTable.find(">tbody>tr.k-grouping-row"),d.table.find(">tbody>tr.k-grouping-row"),t.length):b>m&&ee(d.table.find(">tbody>tr.k-grouping-row"),d.lockedTable.find(">tbody>tr.k-grouping-row"),t.length),u=d.lockedTable.find(">tbody>tr:not(.k-grouping-row,.k-detail-row)")),l=0,c=a.length;l<c;l+=1)r(s(u[l],a[l],">td:not(.k-group-cell,.k-hierarchy-cell)"),m,g,i,t.length)},_autoFitLeafColumn:function(e){this.autoFitColumn(H(this.columns)[e])},autoFitColumn:function(t){var n,i,o,r,s,a,l,c,d,u,p,m,g,v,_,b,w,y,k,x=this,C=x.options,S=x.columns,D=x.lockedHeader?N(x.lockedHeader.find(">table>thead")).filter(h).length:0,A="col:not(.k-group-col):not(.k-hierarchy-col)",E="td:visible:not(.k-group-cell):not(.k-hierarchy-cell)";if(t="number"==typeof t?S[t]:ye(t)?Ce(T(S),function(e){return e===t})[0]:Ce(T(S),function(e){return e.field===t})[0],t&&f(t)){for(n=Te(t,H(S)),r=t.locked,o=r?x.lockedHeader.children("table"):x.thead.parent(),i=o.find("[data-index='"+n+"']"),c=r?x.lockedTable:x.table,d=x.footer||e(),x.footer&&x.lockedContent&&(d=x.footer.children(r?".k-grid-footer-locked":".k-grid-footer-wrap")),u=d.find("table").first(),x.lockedHeader&&!r&&(n-=D),p=0;p<S.length&&S[p]!==t;p++)S[p].hidden&&n--;if(C.scrollable?(s=o.find(A).eq(n).add(c.children("colgroup").find(A).eq(n)).add(u.find("colgroup").find(A).eq(n)),r||(a=c.parent(),l=a.scrollLeft())):s=c.children("colgroup").find(A).eq(n),m=o.add(c).add(u),g=_e(i),s.width(""),m.css("table-layout","fixed"),s.width("auto"),m.addClass("k-autofitting"),m.css("table-layout",""),v=Math.ceil(Math.max(_e(i),_e(c.find("tr:not(.k-grouping-row)").eq(0).children(E).eq(n)),_e(u.find("tr").eq(0).children(E).eq(n))))+1,s.width(v),t.width=v,C.scrollable){for(_=o.find("col"),w=0,y=0,k=_.length;y<k;y+=1){if(b=_[y].style.width,!b||b.indexOf("%")!=-1){w=0;break}w+=parseInt(b,10)}w&&m.each(function(){this.style.width=w+"px"})}Bt.msie&&8==Bt.version&&(m.css("display","inline-table"),setTimeout(function(){m.css("display","table")},1)),m.removeClass("k-autofitting"),l&&a.scrollLeft(l),x.trigger(dt,{column:t,oldWidth:g,newWidth:v}),x._applyLockedContainersWidth(),x._syncLockedContentHeight(),x._syncLockedHeaderHeight()}},reorderColumn:function(e,n,i){var o,r,s=this,a=c(n,s.columns),l=a?a.columns:s.columns,d=Te(n,l),u=l[e],h=!!u.locked,f=F(s.columns).length;d!==e&&(!n.locked&&h&&1==z(s.columns).length||n.locked&&!h&&1==f||(s._hideResizeHandle(),i===t&&(i=e<d),r=[n],s._reorderHeader(r,u,i),s.lockedHeader&&(I(s.thead),I(s.lockedHeader)),u.columns&&(u=H(u.columns),u=u[i?0:u.length-1]),n.columns&&(r=H(n.columns)),s._reorderContent(r,u,i),o=!!n.locked,o=o!=h,n.locked=h,l.splice(i?e:e+1,0,n),l.splice(d<e?d:d+1,1),s._templates(),s._updateColumnCellIndex(),s._updateTablesWidth(),s._applyLockedContainersWidth(),s._syncLockedHeaderHeight(),s._syncLockedContentHeight(),s._updateFirstColumnClass(),o&&(h?s.trigger(ht,{column:n}):s.trigger(ft,{column:n}))))},_updateColumnCellIndex:function(){var e,t=0;this.lockedHeader&&(e=this.lockedHeader.find("thead"),t=_(e,F(this.columns))),_(this.thead,z(this.columns),t)},lockColumn:function(e){var t,n=this.columns;e="number"==typeof e?n[e]:Ce(n,function(t){return t.field===e})[0],!e||e.locked||e.hidden||(t=F(n).length-1,this.reorderColumn(t,e,!1))},unlockColumn:function(e){var t,n=this.columns;e="number"==typeof e?n[e]:Ce(n,function(t){return t.field===e})[0],e&&e.locked&&!e.hidden&&(t=F(n).length,this.reorderColumn(t,e,!0))},cellIndex:function(t){var n=0;return this.lockedTable&&!e.contains(this.lockedTable[0],t[0])&&(n=H(F(this.columns)).length),e(t).parent().children("td:not(.k-group-cell,.k-hierarchy-cell)").index(t)+n},_modelForContainer:function(t){t=e(t),t.is("tr")||"popup"===this._editMode()||(t=t.closest("tr"));var n=t.attr(he.attr("uid"));return this.dataSource.getByUid(n)},_editable:function(){var t,n=this,i=n.selectable&&n.selectable.options.multiple,o=n.options.editable,r=function(){var t=ge(),i=n._editContainer;!i||e.contains(i[0],t)||i[0]===t||e(t).closest(".k-animation-container").length||n.editable.end()&&n.closeCell()};o&&(this.wrapper.addClass("k-editable"),t=n._editMode(),"incell"===t?o.update!==!1&&n.wrapper.on(mt+Ve,"tr:not(.k-grouping-row) > td",function(t){var o=e(this),r=n.lockedTable&&o.closest("table")[0]===n.lockedTable[0];o.hasClass("k-hierarchy-cell")||o.hasClass("k-detail-cell")||o.hasClass("k-group-cell")||o.hasClass("k-edit-cell")||o.has("a.k-grid-delete").length||o.has("button.k-grid-delete").length||o.closest("tbody")[0]!==n.tbody[0]&&!r||e(t.target).is(":input")||(n.editable?n.editable.end()&&(i&&e(ge()).blur(),n.closeCell(),n.editCell(o)):n.editCell(o))}).on("focusin"+Ve,function(){e.contains(this,ge())||(clearTimeout(n.timer),n.timer=null)}).on("focusout"+Ve,function(){n.timer=setTimeout(r,1)}):o.update!==!1&&n.wrapper.on(mt+Ve,"tbody>tr:not(.k-detail-row,.k-grouping-row):visible a.k-grid-edit",function(t){t.preventDefault(),n.editRow(e(this).closest("tr"))}),o.destroy!==!1?n.wrapper.on(mt+Ve,"tbody>tr:not(.k-detail-row,.k-grouping-row):visible .k-grid-delete",function(t){t.preventDefault(),t.stopPropagation(),n.removeRow(e(this).closest("tr"))}):n.wrapper.on(mt+Ve,"tbody>tr:not(.k-detail-row,.k-grouping-row):visible button.k-grid-delete",function(e){e.stopPropagation(),n._confirmation()||e.preventDefault()}))},editCell:function(t){var n,i,o,r;if(t=e(t),n=this,i=H(n.columns)[n.cellIndex(t)],o=n._modelForContainer(t),n.closeCell(),o&&se(i,o)&&!i.command){if(n.trigger(We,{model:o}))return;n._attachModelChange(o),n._editContainer=t,n.editable=t.addClass("k-edit-cell").kendoEditable({fields:{field:i.field,format:i.format,editor:i.editor,values:i.values},model:o,target:n,change:function(e){n.trigger(qe,{values:e.values,container:t,model:o})&&e.preventDefault()}}).data("kendoEditable"),r=t.parent().addClass("k-grid-edit-row"),n.lockedContent&&ie(r[0],n._relatedRow(r).addClass("k-grid-edit-row")[0]),n.trigger(Ue,{container:t,model:o})}},_adjustLockedHorizontalScrollBar:function(){var e=this.table,t=e.parent(),n=e[0].offsetWidth>t[0].clientWidth?he.support.scrollbar():0;this.lockedContent.height(t.height()-n)},_syncLockedContentHeight:function(){this.lockedTable&&(this.touchScroller||this._adjustLockedHorizontalScrollBar(),this._adjustRowsHeight(this.table,this.lockedTable))},_syncLockedHeaderHeight:function(){var e,t;this.lockedHeader&&(e=this.lockedHeader.children("table"),t=this.thead.parent(),this._adjustRowsHeight(e,t),ne(e,t))},_syncLockedFooterHeight:function(){this.lockedFooter&&this.footer&&this.footer.length&&this._adjustRowsHeight(this.lockedFooter.children("table"),this.footer.find(".k-grid-footer-wrap > table"))},_destroyEditable:function(){var e=this,t=function(){if(e.editable){var t=e.editView?e.editView.element:e._editContainer;t&&(t.off(mt+Ve,"a.k-grid-cancel",e._editCancelClickHandler),t.off(mt+Ve,"a.k-grid-update",e._editUpdateClickHandler)),e._detachModelChange(),e.editable.destroy(),e.editable=null,e._editContainer=null,e._destroyEditView()}};e.editable&&("popup"!==e._editMode()||e._isMobile?t():e._editContainer.data("kendoWindow").bind("deactivate",t).close()),e._actionSheet&&(e._actionSheet.destroy(),e._actionSheet=null)},_destroyEditView:function(){this.editView&&(this.editView.purge(),this.editView=null,this.pane.navigate(""))},_attachModelChange:function(e){var t=this;t._modelChangeHandler=function(e){t._modelChange({field:e.field,model:this})},e.bind("change",t._modelChangeHandler)},_detachModelChange:function(){var e=this,t=e._editContainer,n=e._modelForContainer(t);n&&n.unbind(Ze,e._modelChangeHandler)},closeCell:function(t){var n,i,o,r,s=this,a=s._editContainer;a&&(n=a.closest("tr").attr(he.attr("uid")),r=s.dataSource.getByUid(n),t&&s.trigger("cancel",{container:a,model:r})||(s.trigger(Xe,{type:t?"cancel":"save",model:r,container:a}),a.removeClass("k-edit-cell"),i=H(s.columns)[s.cellIndex(a)],o=a.parent().removeClass("k-grid-edit-row"),s._destroyEditable(),s._displayCell(a,i,r),a.hasClass("k-dirty-cell")&&e('<span class="k-dirty"/>').prependTo(a),s.trigger("itemChange",{item:o,data:r,ns:fe}),s.lockedContent&&ie(o.css("height","")[0],s._relatedRow(o).css("height","")[0])))},_displayCell:function(e,t,n){var i=this,o={storage:{},count:0},r=ke({},he.Template,i.options.templateSettings),s=he.template(i._cellTmpl(t,o),r);o.count>0&&(s=Ae(s,o.storage)),e.empty().html(s(n)),i.angular("compile",function(){return{elements:e,data:[{dataItem:n}]}})},removeRow:function(e){this._confirmation(e)&&this._removeRow(e)},_removeRow:function(t){var n,i=this,o=i._editMode();"incell"!==o&&i.cancelRow(),t=e(t),i.lockedContent&&(t=t.add(i._relatedRow(t))),t=t.hide(),n=i._modelForContainer(t),n&&!i.trigger(je,{row:t,model:n})?(i.dataSource.remove(n),"inline"!==o&&"popup"!==o||i.dataSource.sync()):"incell"===o&&i._destroyEditable()},_editMode:function(){var e="incell",t=this.options.editable;return t!==!0&&(e="string"==typeof t?t:t.mode||e),e},editRow:function(t){var n,i,o,r=this;t instanceof he.data.ObservableObject?n=t:(t=e(t),n=r._modelForContainer(t)),i=r._editMode(),r.cancelRow(),n&&(t=r.tbody.children("["+he.attr("uid")+"="+n.uid+"]"),r._attachModelChange(n),"popup"===i?r._createPopupEditor(n):"inline"===i?r._createInlineEditor(t,n):"incell"===i&&e(t).children(ze).each(function(){var t=e(this),i=H(r.columns)[r.cellIndex(t)];if(n=r._modelForContainer(t),n&&(!n.editable||n.editable(i.field))&&i.field&&!i.selectable)return r.editCell(t),!1}),o=r.editView?r.editView.element:r._editContainer,o&&(this._editCancelClickHandler||(this._editCancelClickHandler=Ae(this._editCancelClick,this)),o.on(mt+Ve,"a.k-grid-cancel",this._editCancelClickHandler),this._editUpdateClickHandler||(this._editUpdateClickHandler=Ae(this._editUpdateClick,this)),o.on(mt+Ve,"a.k-grid-update",this._editUpdateClickHandler)))},_editUpdateClick:function(e){e.preventDefault(),e.stopPropagation(),this.saveRow()},_editCancelClick:function(t){var n,i=this,o=i.options.navigatable,r=i.editable.options.model,s=i.editView?i.editView.element:i._editContainer;t.preventDefault(),t.stopPropagation(),i.trigger("cancel",{container:s,model:r})||(n=i.items().index(e(i.current()).parent()),i.cancelRow(),o&&(i._setCurrent(i.items().eq(n).children().filter(Le).first()),re(i.table,!0)))},_createPopupEditor:function(n){var i,o,r,s,a,l,c,d,u,h,f,p=this,m="<div "+he.attr("uid")+'="'+n.uid+'" class="k-popup-edit-form'+(p._isMobile?" k-mobile-list":"")+'"><div class="k-edit-form-container">',g=[],v=H(p.columns),_=p.options.editable,b=_.template,w=ye(_)?_.window:{},y=ke({},he.Template,p.options.templateSettings);if(!p.trigger(We,{model:n})){if(w=w||{},b)for(typeof b===bt&&(b=window.unescape(b)),m+=he.template(b,y)(n),r=0,s=v.length;r<s;r++)i=v[r],i.command&&(d=oe(i.command,"edit"),d&&(o=d));else for(r=0,s=v.length;r<s;r++)i=v[r],i.selectable||(i.command?i.command&&(d=oe(i.command,"edit"),d&&(o=d)):(m+='<div class="k-edit-label"><label for="'+i.field+'">'+(i.title||i.field||"")+"</label></div>",se(i,n)?(g.push({field:i.field,format:i.format,editor:i.editor,values:i.values}),m+="<div "+he.attr("container-for")+'="'+i.field+'" class="k-edit-field"></div>'):(h={storage:{},count:0},a=he.template(p._cellTmpl(i,h),y),h.count>0&&(a=Ae(a,h.storage)),m+='<div class="k-edit-field">'+a(n)+"</div>")));o&&ye(o)&&(o.text&&ye(o.text)&&(l=o.text.update,c=o.text.cancel),o.attr&&(u=o.attr)),p._isMobile?(m+="</div></div>",p.editView=p.pane.append("<div data-"+he.ns+'role="view" data-'+he.ns+'use-native-scrolling="true" data-'+he.ns+'init-widgets="false" class="k-grid-edit-form"><div data-'+he.ns+'role="header" class="k-header">'+p._createButton({name:"update",text:l,attr:u})+(w.title||"Edit")+p._createButton({name:"canceledit",text:c,attr:u})+"</div>"+m+"</div>"),f=p._editContainer=p.editView.element.find(".k-popup-edit-form")):(m+='<div class="k-edit-buttons k-state-default">',m+=p._createButton({name:"update",text:l,attr:u})+p._createButton({name:"canceledit",text:c,attr:u}),m+="</div></div></div>",f=p._editContainer=e(m).appendTo(p.wrapper).eq(0).kendoWindow(ke({modal:!0,resizable:!1,draggable:!0,title:"Edit",visible:!1,close:function(i){if(i.userTriggered){if(i.sender.element.focus(),p.trigger("cancel",{container:f,model:n}))return i.preventDefault(),t;var o=p.items().index(e(p.current()).parent());p.cancelRow(),p.options.navigatable&&(p._setCurrent(p.items().eq(o).children().filter(Le).first()),re(p.table,!0))}}},w))),p.editable=p._editContainer.kendoEditable({fields:g,model:n,clearContainer:!1,target:p}).data("kendoEditable"),p._isMobile&&f.find("input[type=checkbox],input[type=radio]").parent(".k-edit-field").addClass("k-check").prev(".k-edit-label").addClass("k-check").click(function(){e(this).next().children("input").click()}),p._openPopUpEditor(),p.trigger(Ue,{container:f,model:n})}},_openPopUpEditor:function(){this._isMobile?this.pane.navigate(this.editView,this._editAnimation):this._editContainer.data("kendoWindow").center().open()},_createInlineEditor:function(t,n){var i,o,r,s=this,a=[];s.trigger(We,{model:n})||(s.lockedContent&&(t=t.add(s._relatedRow(t))),t.children(":not(.k-group-cell,.k-hierarchy-cell)").each(function(){if(o=e(this),i=H(s.columns)[s.cellIndex(o)],!i.command&&se(i,n))a.push({field:i.field,format:i.format,editor:i.editor,values:i.values}),o.attr(he.attr("container-for"),i.field),o.empty();else if(i.command&&(r=oe(i.command,"edit"))){o.empty();var t,l,c;ye(r)&&(r.text&&ye(r.text)&&(t=r.text.update,l=r.text.cancel),r.attr&&(c=r.attr)),e(s._createButton({name:"update",text:t,attr:c})+s._createButton({name:"canceledit",text:l,attr:c})).appendTo(o)}}),s._editContainer=t,s.editable=new he.ui.Editable(t.addClass("k-grid-edit-row"),{target:s,fields:a,model:n,clearContainer:!1}),t.length>1&&(ie(t[0],t[1]),s._applyLockedContainersWidth()),s.trigger(Ue,{container:t,model:n}))},cancelRow:function(e){var t,n=this,i=n._editContainer;if(i){if(t=n._modelForContainer(i),e&&n.trigger("cancel",{container:i,model:t}))return;n._destroyEditable(),n.dataSource.cancelChanges(t),n._displayRow("popup"!==n._editMode()?i:n.tbody.find("["+he.attr("uid")+"="+t.uid+"]"))}},saveRow:function(){var t=this._editContainer,n=this._modelForContainer(t),i=e.Deferred();return t&&this.editable?!this.editable.end()||this.trigger(qe,{container:t,model:n})?i.reject().promise():this.dataSource.sync():i.resolve().promise()},_displayRow:function(t){var n,i,o,r,s,a=this,l=a._modelForContainer(t),c=t.hasClass("k-state-selected"),d=t.hasClass("k-alt");l&&(a.lockedContent&&(n=e((d?a.lockedAltRowTemplate:a.lockedRowTemplate)(l)),a._relatedRow(t.last()).replaceWith(n)),a.angular("cleanup",function(){return{elements:t.get()}}),i=e((d?a.altRowTemplate:a.rowTemplate)(l)),t.replaceWith(i),a.trigger("itemChange",{item:i,data:l,ns:fe}),n&&n.length&&a.trigger("itemChange",{item:n,data:l,ns:fe}),r=i,s=[{dataItem:l}],n&&n.length&&(r=i.add(n),s.push({dataItem:l})),a.angular("compile",function(){return{elements:r.get(),data:s}}),c&&(a.options.selectable||e.grep(H(a.columns),function(e){return e.selectable}).length)&&a.select(i.add(n)),n&&ie(i[0],n[0]),o=i.next(),o.hasClass("k-detail-row")&&o.is(":visible")&&i.find(".k-hierarchy-cell .k-icon").removeClass("k-i-expand").addClass("k-i-collapse"))},_showMessage:function(t,n){var i,o,r,s=this;return s._isMobile?(i=he.template('<ul><li class="km-actionsheet-title">#:title#</li><li><a href="\\#" class="k-button k-grid-delete">#:confirmDelete#</a></li></ul>'),o=e(i(t)).appendTo(s.view.element),r=s._actionSheet=new he.mobile.ui.ActionSheet(o,{cancel:t.cancelDelete,cancelTemplate:'<li class="km-actionsheet-cancel"><a class="k-button" href="\\#">#:cancel#</a></li>',close:function(){this.destroy()},command:function(t){var i=e(t.currentTarget).parent();i.hasClass("km-actionsheet-cancel")||s._removeRow(n)},popup:s._actionSheetPopupOptions}),r.open(n),!1):window.confirm(t.title)},_confirmation:function(e){var t=this,n=t.options.editable,i=n===!0||typeof n===bt?t.options.messages.editable.confirmation:n.confirmation;return ye(n)&&typeof n.mode===bt&&typeof i!==bt&&i!==!1&&(i=t.options.messages.editable.confirmation),i===!1||null==i||(typeof i===_t&&(i=i(t._modelForContainer(e))),t._showMessage({confirmDelete:n.confirmDelete||t.options.messages.editable.confirmDelete,cancelDelete:n.cancelDelete||t.options.messages.editable.cancelDelete,title:i===!0?t.options.messages.editable.confirmation:i},e))},cancelChanges:function(){this.dataSource.cancelChanges()},saveChanges:function(){var e=this;(e.editable&&e.editable.end()||!e.editable)&&!e.trigger(tt)&&e.dataSource.sync()},addRow:function(){var e,t,n,i,o,r,s=this,a=s.dataSource,l=s._editMode(),c=s.options.editable.createAt||"",d=a.pageSize(),u=a.view()||[];(s.editable&&s.editable.end()||!s.editable)&&("incell"!=l&&s.cancelRow(),e=a.indexOf(u[0]),"bottom"==c.toLowerCase()&&(e+=u.length,d&&!a.options.serverPaging&&d<=u.length&&(e-=1)),e<0&&(e=a.page()>a.totalPages()?(a.page()-1)*d:0),t=a.insert(e,{}),n=t.uid,i=s.lockedContent?s.lockedTable:s.table,o=i.find("tr["+he.attr("uid")+"="+n+"]"),r=o.children("td:not(.k-group-cell,.k-hierarchy-cell)").eq(s._firstEditableColumnIndex(o)),"inline"===l&&o.length?s.editRow(o):"popup"===l?s.editRow(t):r.length&&s.editCell(r),"bottom"==c.toLowerCase()&&s.lockedContent&&(s.lockedContent[0].scrollTop=s.content[0].scrollTop=s.table[0].offsetHeight))},_firstEditableColumnIndex:function(e){var t,n,i,o=this,r=H(o.columns),s=o._modelForContainer(e);for(n=0,i=r.length;n<i;n++)if(t=r[n],s&&(!s.editable||s.editable(t.field))&&!t.command&&t.field&&t.hidden!==!0)return n;return-1},_toolbar:function(){var t,n=this,i=n.wrapper,o=n.options.toolbar,r=n.options.editable;o&&(t=n.wrapper.find(".k-grid-toolbar"),t.length||(Ee(o)||(o=typeof o===bt?o:n._toolbarTmpl(o).replace(At,"\\#"),o=Ae(he.template(o),n)),t=e('<div class="k-header k-grid-toolbar" />').html(o({})).prependTo(i),n.angular("compile",function(){return{elements:t.get()}})),r&&r.create!==!1&&t.on(mt+Ve,".k-grid-add",function(e){e.preventDefault(),n.addRow()}).on(mt+Ve,".k-grid-cancel-changes",function(e){e.preventDefault(),n.cancelChanges()}).on(mt+Ve,".k-grid-save-changes",function(e){e.preventDefault(),n.saveChanges()}),t.on(mt+Ve,".k-grid-excel",function(e){e.preventDefault(),n.saveAsExcel()}),t.on(mt+Ve,".k-grid-pdf",function(e){e.preventDefault(),n.saveAsPDF()}))},_toolbarTmpl:function(e){var t,n,i=this,o="";if(Se(e))for(t=0,n=e.length;t<n;t++)o+=i._createButton(e[t]);return o},_createButton:function(e){var n,o=e.template||Rt,r=typeof e===bt?e:e.name||e.text,s=Ot[r]?Ot[r].className:"k-grid-"+(r||"").replace(/\s/g,""),a={className:s,text:r,imageClass:"",attr:"",iconClass:""},l=this.options.messages.commands;if(!(r||ye(e)&&e.template))throw Error("Custom commands should have name specified");return ye(e)?(e=ke(!0,{},e),e.className&&Te(a.className,e.className.split(" "))<0?e.className+=" "+a.className:e.className===t&&(e.className=a.className),"edit"===r&&ye(e.text)&&(e=ke(!0,{},e),e.text=e.text.edit),e.attr&&(ye(e.attr)&&(e.attr=i(e.attr)),
typeof e.attr===bt&&(n=e.attr.match(/class="(.+?)"/),n&&Te(n[1],e.className.split(" "))<0&&(e.className+=" "+n[1]))),a=ke(!0,a,Ot[r],{text:l[r]},e)):a=ke(!0,a,Ot[r],{text:l[r]}),he.template(o)(a)},_hasFooters:function(){return!!this.footerTemplate||!!this.groupFooterTemplate||this.footer&&this.footer.length>0||this.wrapper.find(".k-grid-footer").length>0},_groupable:function(){var t=this;t._groupableClickHandler?t.table.add(t.lockedTable).off(mt+Ve,t._groupableClickHandler):t._groupableClickHandler=function(n){var i=e(this),o=i.closest("tr");i.hasClass("k-i-collapse")?t.collapseGroup(o):t.expandGroup(o),n.preventDefault(),n.stopPropagation()},t._isLocked()?t.lockedTable.on(mt+Ve,".k-grouping-row .k-i-expand, .k-grouping-row .k-i-collapse",t._groupableClickHandler):t.table.on(mt+Ve,".k-grouping-row .k-i-expand, .k-grouping-row .k-i-collapse",t._groupableClickHandler),t._attachGroupable()},_attachGroupable:function(){var t=this,n=t.wrapper,i=t.options.groupable,o=Oe+"["+he.attr("field")+"]",r=t.content?".k-grid-header:first "+o:"table:first>.k-grid-header "+o;i&&i.enabled!==!1&&(n.has("div.k-grouping-header")[0]||e("<div>&nbsp;</div>").addClass("k-grouping-header").prependTo(n),t.groupable&&t.groupable.destroy(),t.groupable=new fe.Groupable(n,ke({},i,{draggable:t._draggableInstance,groupContainer:">div.k-grouping-header",dataSource:t.dataSource,draggableElements:r,filter:r,allowDrag:t.options.reorderable,change:function(e){t.trigger("group",{groups:e.groups})&&e.preventDefault()}})))},_continuousItems:function(t,n){var i,o,r,s,a,l,c,d;if(this.lockedContent){for(i=this,o=i.table.add(i.lockedTable),r=e(t,o[0]),s=e(t,o[1]),a=n?F(i.columns).length:1,l=n?i.columns.length-a:1,c=[],d=0;d<r.length;d+=a)De.apply(c,r.slice(d,d+a)),De.apply(c,s.splice(0,l));return c}},_selectable:function(){var n,i,o,r,s=this,a=[],l=s._isLocked(),c=s.options.selectable,d=s.dataSource.options;if(c){if(s.selectable&&s.selectable.destroy(),s.options.persistSelection===!0){if(!d.schema||!d.schema.model||!d.schema.model.id)throw Error("Selection persistence requires a data source with a model that has e defined id");s._selectedIds={}}c=he.ui.Selectable.parseOptions(c),n=c.multiple,i=c.cell,s._hasDetails()&&(a[a.length]=".k-detail-row"),(s.options.groupable||s._hasFooters())&&(a[a.length]=".k-grouping-row,.k-group-footer"),a=a.join(","),""!==a&&(a=":not("+a+")"),o=s.table,l&&(o=o.add(s.lockedTable)),r=">"+(i?Pe:"tbody>tr"+a),s.selectable=new he.ui.Selectable(o,{filter:r,aria:!0,multiple:n,change:function(){s.options.persistSelection&&!i&&s._persistSelectedRows(),s.trigger(Ze)},useAllItems:l&&n&&i,relatedTarget:function(t){var n,o,r,a;if(!i&&l){for(o=e(),r=0,a=t.length;r<a;r++)n=s._relatedRow(t[r]),Te(n[0],t)<0&&(o=o.add(n));return o}},continuousItems:function(){return s._continuousItems(r,i)}}),s.options.navigatable&&o.on("keydown"+Ve,function(r){var a=s.current(),c=r.target;if(r.keyCode===we.SPACEBAR&&!r.shiftKey&&e.inArray(c,o)>-1&&!a.is(".k-edit-cell,.k-header")&&a.parent().is(":not(.k-grouping-row,.k-detail-row,.k-group-footer)")){if(r.preventDefault(),r.stopPropagation(),a=i?a:a.parent(),l&&!i&&(a=a.add(s._relatedRow(a))),n)if(r.ctrlKey){if(a.hasClass(st))return a.removeClass(st),s.trigger(Ze),t}else s.selectable.clear();else s.selectable.clear();i||(s.selectable._lastActive=a),s.selectable.value(a)}else!i&&(r.shiftKey&&r.keyCode==we.LEFT||r.shiftKey&&r.keyCode==we.RIGHT||r.shiftKey&&r.keyCode==we.UP||r.shiftKey&&r.keyCode==we.DOWN||r.keyCode===we.SPACEBAR&&r.shiftKey)&&(r.preventDefault(),r.stopPropagation(),a=a.parent(),l&&(a=a.add(s._relatedRow(a))),n?(s.selectable._lastActive||(s.selectable._lastActive=a),s.selectable.selectRange(s.selectable._firstSelectee(),a)):(s.selectable.clear(),s.selectable.value(a)))})}},_clipboard:function(){var e,t=this.options,n=t.selectable;n&&t.allowCopy&&(e=this,t.navigatable||e.table.add(e.lockedTable).attr("tabindex",0).on("mousedown"+Ve+" keydown"+Ve,".k-detail-cell",function(e){e.target!==e.currentTarget&&e.stopImmediatePropagation()}).on("mousedown"+Ve,Be+">"+Le,Ae(le,e)),e.copyHandler=Ae(e.copySelection,e),e.updateClipBoardState=function(){e.areaClipBoard&&e.areaClipBoard.val(e.getTSV()).focus().select()},e.bind("change",e.updateClipBoardState),e.wrapper.on("keydown",e.copyHandler),e.clearAreaHandler=Ae(e.clearArea,e),e.wrapper.on("keyup",e.clearAreaHandler))},copySelection:function(t){t instanceof jQuery.Event&&!t.ctrlKey&&!t.metaKey||e(t.target).is("input:visible,textarea:visible")||window.getSelection&&""+window.getSelection()||document.selection&&document.selection.createRange().text||(this.areaClipBoard||(this.areaClipBoard=e("<textarea />").css({position:"fixed",top:"50%",left:"50%",opacity:0,width:0,height:0}).appendTo(this.wrapper)),this.areaClipBoard.val(this.getTSV()).focus().select())},getTSV:function(){var t,n,i,o,r,s,a=this,l=a.select(),c="\t",d=a.options.allowCopy,u=!0;return e.isPlainObject(d)&&d.delimeter&&(c=d.delimeter),t="",l.length&&(l.eq(0).is("tr")&&(l=l.find("td:not(.k-group-cell)")),u&&l.filter(":visible"),n=[],i=this.columns.length,o=a._isLocked()&&F(a.columns).length,r=!0,e.each(l,function(t,s){var l,c,d,h;s=e(s),l=s.closest("tr"),c=l.index(),d=s.index(),u&&(d-=s.prevAll(":hidden").length),o&&r&&(r=e.contains(a.lockedTable[0],s[0])),a._groups()&&r&&(d-=a._groups()),d=r?d:d+o,i>d&&(i=d),h=s.text(),n[c]||(n[c]=[]),n[c][d]=h}),s=n.length,n=e.each(n,function(e,t){t&&(n[e]=t.slice(i),s>e&&(s=e))}),e.each(n.slice(s),function(e,n){t+=n?n.join(c)+"\r\n":"\r\n"})),t},clearArea:function(t){var n;this.areaClipBoard&&t&&t.target===this.areaClipBoard[0]&&(n=this.options.navigatable?e(this.current()).closest("table"):this.table,re(n,!0)),this.areaClipBoard&&(this.areaClipBoard.remove(),this.areaClipBoard=null)},_minScreenSupport:function(){var t=this.hideMinScreenCols();t&&(this.minScreenResizeHandler=Ae(this.hideMinScreenCols,this),e(window).on("resize",this.minScreenResizeHandler))},hideMinScreenCols:function(){var e=this.columns,t=window.innerWidth>0?window.innerWidth:screen.width;return this._iterateMinScreenCols(e,t)},_iterateMinScreenCols:function(e,n){var i,o,r,s=!1;for(i=0;i<e.length;i++)o=e[i],r=o.minScreenWidth,r!==t&&null!==r&&(s=!0,r>n?this.hideColumn(o):this.showColumn(o)),!o.hidden&&o.columns&&(s=this._iterateMinScreenCols(o.columns,n)||s);return s},_relatedRow:function(t){var n,i,o=this.lockedTable;return t=e(t),o?(n=t.closest(this.table.add(this.lockedTable)),i=n.find(">tbody>tr").index(t),n=n[0]===this.table[0]?o:this.table,n.find(">tbody>tr").eq(i)):t},clearSelection:function(){var t=this;t.selectable&&t.selectable.clear(),e.grep(H(t.columns),function(e){return e.selectable}).length&&t._deselectCheckRows(t.select()),t.options.persistSelection&&t._persistSelectedRows(),t.trigger(Ze)},select:function(n){var i=this,o=i.selectable;return n=i.table.add(i.lockedTable).find(n),n.length?(o&&!o.options.multiple&&(o.clear(),n=n.first()),i._isLocked()&&(n=n.add(n.map(function(){return i._relatedRow(this)}))),o?o.value(n):(n.each(function(){e(this).addClass(st).find(lt).prop("checked",!0).attr("aria-label","Deselect row").attr("aria-checked",!0)}),i.select().length===i.items().length&&i._toggleHeaderCheckState(!0),i.options.persistSelection&&i._persistSelectedRows(),i.trigger(Ze)),t):o?o.value():i.items().filter("."+st)},_toggleHeaderCheckState:function(e){var t=this;e?t.thead.add(t.lockedHeader).find("tr "+lt).prop("checked",!0).attr("aria-checked",!0).attr("aria-label","Deselect all rows"):t.thead.add(t.lockedHeader).find("tr "+lt).prop("checked",!1).attr("aria-checked",!1).attr("aria-label","Select all rows")},_deselectCheckRows:function(t){var n=this;t=n.table.add(n.lockedTable).find(t),t.each(function(){e(this).removeClass(st).find(lt).attr("aria-checked",!1).prop("checked",!1).attr("aria-label","Select row")}),n._toggleHeaderCheckState(!1),n.options.persistSelection&&n._persistSelectedRows(),n.trigger(Ze)},_persistSelectedRows:function(){var e,t,n,i=this,o=i.items(),r=i.dataSource.options,s=r.schema.model.id,a={};for(i.select().each(function(){t=i.dataItem(this),a[t[s]]=!0}),n=0;n<o.length;n++)t=i.dataItem(o[n]),e=t[s],a[e]?i._selectedIds[e]=!0:delete i._selectedIds[e]},selectedKeyNames:function(){var e,t=this,n=[];for(e in t._selectedIds)n.push(e);return n.sort(),n},_updateCurrentAttr:function(t,n){var i=e(t).data("headerId");e(t).removeClass(rt).closest("table").removeAttr("aria-activedescendant"),i?(i=i.replace(this._cellId,""),e(t).attr("id",i)):e(t).removeAttr("id"),n.data("headerId",n.attr("id")).attr("id",this._cellId).addClass(rt).closest("table").attr("aria-activedescendant",this._cellId),this._current=n},_scrollCurrent:function(){var t,n,i,o,r,s,a=this._current,l=this.options.scrollable;a&&l&&(t=a.parent(),n=t.closest("table").parent(),i=n.is(".k-grid-content-locked,.k-grid-header-locked"),o=n.is(".k-grid-content-locked,.k-grid-content,.k-virtual-scrollable-wrap"),r=e(this.content).find(">.k-virtual-scrollable-wrap").addBack().last()[0],o&&(l.virtual?(s=Math.max(Te(t[0],this._items(t.parent())),0),this._rowVirtualIndex=this.virtualScrollable.itemIndex(s),this.virtualScrollable.scrollIntoView(t)):this._scrollTo(this._relatedRow(t)[0],r)),this.lockedContent&&(this.lockedContent[0].scrollTop=r.scrollTop),i||this._scrollTo(a[0],r))},current:function(e){return this._setCurrent(e,!0)},_setCurrent:function(t,n){var i=this._current;return t=e(t),t.length&&(i&&i[0]===t[0]||(this._updateCurrentAttr(i,t),this._scrollCurrent(),n||this.trigger(pt,{element:t}))),this._current},_removeCurrent:function(){this._current&&(this._current.removeClass(rt),this._current=null)},_scrollTo:function(t,n){var i,o=t.tagName.toLowerCase(),r="td"===o||"th"===o,s=t[r?"offsetLeft":"offsetTop"],a=t[r?"offsetWidth":"offsetHeight"],l=n[r?"scrollLeft":"scrollTop"],c=n[r?"clientWidth":"clientHeight"],d=s+a,u=0,h=0,f=0;Pt&&r&&(i=e(t).closest("table")[0],Bt.msie?h=i.offsetLeft:Bt.mozilla&&(f=i.offsetLeft-he.support.scrollbar())),l=Math.abs(l+h-f),u=l>s?s:d>l+c?a<=c?d-c:s:l,u=Math.abs(u+h)+f,n[r?"scrollLeft":"scrollTop"]=u},_navigatable:function(){var t,n,i,o=this;o.options.navigatable&&(t=o.table.add(o.lockedTable),n=o.thead.parent().add(e(">table",o.lockedHeader)),i=t,o.options.scrollable&&(i=i.add(n),n.attr(vt,-1)),this._navigatableTables=i,i.off("mousedown"+Ve+" focus"+Ve+" focusout"+Ve+" keydown"+Ve),n.on("keydown"+Ve,Ae(o._openHeaderMenu,o)).find("a.k-link").attr("tabIndex",-1),t.attr(vt,Ie.max(t.attr(vt)||0,0)).on("mousedown"+Ve+" keydown"+Ve,".k-detail-cell",function(e){e.target!==e.currentTarget&&e.stopImmediatePropagation()}),i.on(he.support.touch?"touchstart"+Ve:"mousedown"+Ve,Be+">"+Le,Ae(le,o)).on("focus"+Ve,Ae(o._tableFocus,o)).on("focusout"+Ve,Ae(o._tableBlur,o)).on("keydown"+Ve,Ae(o._tableKeyDown,o)))},_openHeaderMenu:function(e){e.altKey&&e.keyCode==we.DOWN&&(this.current().find(".k-grid-filter, .k-header-column-menu").click(),e.stopImmediatePropagation())},_setTabIndex:function(e){this._navigatableTables.attr(vt,-1),e.attr(vt,0)},_tableFocus:function(t){var n,i;he.support.touch||(n=this.current(),i=e(t.currentTarget),n&&n.is(":visible")?n.addClass(rt):this._setCurrent(i.find(Ne)),this._setTabIndex(i))},_tableBlur:function(){var e=this.current();e&&e.removeClass(rt)},_tableKeyDown:function(n){var i,o=this.current(),r=this.virtualScrollable&&this.virtualScrollable.fetching(),s=e(n.target),a=!n.isDefaultPrevented()&&!s.is(":button,a,:input,a>.k-icon");return r?(n.preventDefault(),t):(o=o?o:e(this.lockedTable).add(this.table).find(Ne),o.length&&(i=!1,a&&n.keyCode==we.UP&&(i=this._moveUp(o,n.shiftKey)),a&&n.keyCode==we.DOWN&&(i=this._moveDown(o,n.shiftKey)),a&&n.keyCode==(Pt?we.LEFT:we.RIGHT)&&(i=this._moveRight(o,n.altKey,n.shiftKey,n.currentTarget)),a&&n.keyCode==(Pt?we.RIGHT:we.LEFT)&&(i=this._moveLeft(o,n.altKey,n.shiftKey,n.currentTarget)),a&&n.keyCode==we.PAGEDOWN&&(i=this._handlePageDown()),a&&n.keyCode==we.PAGEUP&&(i=this._handlePageUp()),n.keyCode!=we.ENTER&&n.keyCode!=we.F2||(i=this._handleEnterKey(o,n.currentTarget,s)),n.keyCode==we.ESC&&(i=this._handleEscKey(o,n.currentTarget)),n.keyCode==we.TAB&&(i=this._handleTabKey(o,n.currentTarget,n.shiftKey)),i&&(n.preventDefault(),n.stopPropagation())),t)},_moveLeft:function(t,n,i,o){var r,s,a=t.parent(),l=a.parent();return n?this.collapseRow(a):(s=l.find(Be).index(a),r=this._prevHorizontalCell(l,t,s),r[0]||(i?this.lockedTable?(r=this._relatedRow(a),e.contains(this.lockedTable[0],a[0])&&(r=r.prevAll(He+":first")),r=r.children(ze+":last")):r=this._tabNext(t,o,!0):(l=this._horizontalContainer(l),r=this._prevHorizontalCell(l,t,s),r[0]!==t[0]&&re(l.parent(),!0))),this._setCurrent(r)),!0},_moveRight:function(t,n,i,o){var r,s,a=t.parent(),l=a.parent();return n?this.expandRow(a):(s=l.find(Be).index(a),r=this._nextHorizontalCell(l,t,s),r[0]||(i?this.lockedTable?(r=this._relatedRow(a),e.contains(this.table[0],a[0])&&(r=r.nextAll(He+":first")),r=r.children(ze+":first")):r=this._tabNext(t,o,!1):(l=this._horizontalContainer(l,!0),r=this._nextHorizontalCell(l,t,s),r[0]!==t[0]&&re(l.parent(),!0))),this._setCurrent(r)),!0},_moveUp:function(e,t){var n,i=e.parent().parent();return t?(n=e.parent(),n=n.prevAll(He+":first"),n=e.parent().is(He)?n.children().eq(e.index()):n.children(ze+":last")):(n=this._prevVerticalCell(i,e),n[0]||(i=this._verticalContainer(i,!0),n=this._prevVerticalCell(i,e),n[0]&&re(i.parent(),!0))),this._setCurrent(n),!0},_moveDown:function(e,t){var n,i=e.parent().parent();return t?(n=e.parent(),n=n.nextAll(He+":first"),n=e.parent().is(He)?n.children().eq(e.index()):n.children(ze+":first")):(n=this._nextVerticalCell(i,e),n[0]||(i=this._verticalContainer(i),n=this._nextVerticalCell(i,e),n[0]&&re(i.parent(),!0))),this._setCurrent(n),!0},_handlePageDown:function(){return!!this.options.pageable&&(this.dataSource.page(this.dataSource.page()+1),!0)},_handlePageUp:function(){return!!this.options.pageable&&(this.dataSource.page(this.dataSource.page()-1),!0)},_handleTabKey:function(t,n,i){var o,r=this.options.editable&&"incell"==this._editMode();return!(!r||t.is("th"))&&(o=e(ge()).closest(".k-edit-cell"),o[0]&&o[0]!==t[0]&&(t=o),o=this._tabNext(t,n,i),!!o.length&&(this._handleEditing(t,o,o.closest("table")),!0))},_handleEscKey:function(t,n){var i,o=ge(),r="incell"==this._editMode();return ce(t)?(r?this.closeCell(!0):(i=e(t).parent().index(),o&&o.blur(),this.cancelRow(!0),i>=0&&this._setCurrent(this.items().eq(i).children(Le).first())),Bt.msie&&Bt.version<9&&document.body.focus(),re(n,!0),!0):!!t.has(o).length&&(re(n,!0),!0)},_toggleCurrent:function(e,t){var n=e.parent();return n.is(".k-grouping-row")?(n.find(".k-icon:first").click(),!0):!(t||!n.is(".k-master-row"))&&(n.find(".k-icon:first").click(),!0)},_handleEnterKey:function(t,n,i){var o,r=this.options.editable&&this.options.editable.update!==!1,s=i.closest("[role=gridcell]");return i.is("table")||e.contains(t[0],i[0])||(t=s),t.is("th")?(t.find(".k-link").click(),!0):!!this._toggleCurrent(t,r)||(o=t.find(":kendoFocusable:first"),o[0]&&!t.hasClass("k-edit-cell")&&t.hasClass("k-state-focused")?(o.focus(),!0):!(!r||i.is(":button,.k-button,textarea"))&&(s[0]||(s=t),this._handleEditing(s,!1,n),!0))},_nextHorizontalCell:function(e,t,n){var i,o,r,s=t.nextAll(ze);return s.length||(i=e.find(Be),o=i.index(t.parent()),o!=-1)?s.first():t.hasClass("k-header")?(r=[],R([F(this.columns)[0]],V(i.eq(0).children().first()),r,0,0),r[n]?r[n][0]:t):t.parent().hasClass("k-filter-row")?i.last().children(ze).first():i.eq(n).children(ze).first()},_prevHorizontalCell:function(e,t,n){var i,o,r,s,a=t.prevAll(ze);return a.length||(i=e.find(Be),o=i.index(t.parent()),o!=-1)?a.first():t.hasClass("k-header")?(r=[],s=F(this.columns),R([s[s.length-1]],V(i.eq(0).children().last()),r,0,0),r[n]?r[n][0]:t):t.parent().hasClass("k-filter-row")?i.last().children(ze).last():i.eq(n).children(ze).last()},_currentDataIndex:function(e,n){var i,o=n.attr("data-index");return o?(i=F(this.columns).length,i&&!e.closest("div").hasClass("k-grid-content-locked")[0]?o-i:o):t},_prevVerticalCell:function(t,n){var i,o=n.parent(),r=t.children(Be),s=r.index(o),a=this._currentDataIndex(t,n);if(a||n.hasClass("k-header"))return i=O(n),i.eq(i.length-2);if(a=o.children(ze).index(n),o.hasClass("k-filter-row"))return N(t).eq(a);if(s==-1){if(o=t.find(".k-filter-row"),!o[0])return N(t).eq(a)}else o=0===s?e():r.eq(s-1);return i=o.children(ze),i.eq(i.length>a?a:0)},_nextVerticalCell:function(e,n){var i,o=n.parent(),r=e.children(Be),s=r.index(o),a=this._currentDataIndex(e,n);return s!=-1&&a===t&&n.hasClass("k-header")?V(n).eq(1):(a=a?parseInt(a,10):o.children(ze).index(n),o=r.eq(s==-1?0:s+n[0].rowSpan),i=o.children(ze),i.eq(i.length>a?a:0))},_verticalContainer:function(e,t){var n=e.parent(),i=this._navigatableTables.length,o=Math.floor(i/2),r=Te(n[0],this._navigatableTables);return t&&(o*=-1),r+=o,(r>=0||r<i)&&(n=this._navigatableTables.eq(r)),n.find(t?"thead":"tbody")},_horizontalContainer:function(e,t){var n,i,o=this._navigatableTables.length;return o<=2?e:(n=e.parent(),i=Te(n[0],this._navigatableTables),i+=t?1:-1,!t||2!=i&&i!=o?!t&&(1==i||i<0)?e:this._navigatableTables.eq(i).find("thead, tbody"):e)},_tabNext:function(e,t,n){var i=!0,o=n?e.prevAll(ze+":first"):e.nextAll(":visible:first");return o.length||(o=e.parent(),this.lockedTable&&(i=n&&t==this.lockedTable[0]||!n&&t==this.table[0],o=this._relatedRow(o)),i&&(o=o[n?"prevAll":"nextAll"]("tr:not(.k-grouping-row):not(.k-detail-row):visible:first")),o=o.children(ze+(n?":last":":first"))),o},_handleEditing:function(n,i,o){var r,s,a=this,l=e(ge()),c=a._editMode(),d=Bt.msie,u=d&&Bt.version<9,h=a._editContainer,f=a.options.editable&&a.options.editable.update!==!1;if(o=e(o),s="incell"==c?n.hasClass("k-edit-cell"):n.parent().hasClass("k-grid-edit-row"),a.editable){if(e.contains(h[0],l[0])&&(Bt.opera||u?l.blur().change().triggerHandler("blur"):(l.blur(),d&&l.blur())),!a.editable)return re(o),t;if(!a.editable.end())return a._setCurrent("incell"==c?h:h.children().filter(ze).first()),r=h.find(":kendoFocusable:first")[0],r&&r.focus(),t;"incell"==c?a.closeCell():(a.saveRow(),s=!0)}i&&a._setCurrent(i),u&&document.body.focus(),re(o,!0),f&&(!s&&!i||i)&&("incell"==c?a.editCell(a.current()):a.editRow(a.current().parent()))},_wrapper:function(){var e=this,t=e.table,n=e.options.height,i=e.element;i.is("div")||(i=i.wrap("<div/>").parent()),e.wrapper=i.addClass("k-grid k-widget k-display-block"),n&&(e.wrapper.css(gt,n),t.css(gt,"auto")),e._initMobile()},_initMobile:function(){var t,n=this.options,i=this;this._isMobile=n.mobile===!0&&he.support.mobileOS||"phone"===n.mobile||"tablet"===n.mobile,this._isMobile&&(t=this.wrapper.addClass("k-grid-mobile").wrap("<div data-"+he.ns+'stretch="true" data-'+he.ns+'role="view" data-'+he.ns+'init-widgets="false"></div>').parent(),this.pane=he.mobile.ui.Pane.wrap(t),this.view=this.pane.view(),this._actionSheetPopupOptions=e(document.documentElement).hasClass("km-root")?{modal:!1}:{align:"bottom center",position:"bottom center",effect:"slideIn:up"},n.height&&this.pane.element.parent().css(gt,n.height),this._editAnimation="slide",this.view.bind("show",function(){i._isLocked()&&(i._updateTablesWidth(),i._applyLockedContainersWidth(),i._syncLockedContentHeight(),i._syncLockedHeaderHeight(),i._syncLockedFooterHeight())}))},_tbody:function(){var t,n=this,i=n.table;t=i.find(">tbody"),t.length||(t=e("<tbody/>").appendTo(i)),n.tbody=t.attr("role","rowgroup")},_scrollable:function(){var t,n,i,o,r=this,s=r.options,a=s.scrollable,l=a!==!0&&a.virtual&&!r.virtualScrollable,c=!he.support.kineticScrollNeeded||l?he.support.scrollbar():0;a&&(t=r.wrapper.children(".k-grid-header"),t[0]||(t=e('<div class="k-grid-header" />').insertBefore(r.table)),t.css(Pt?"padding-left":"padding-right",a.virtual?c+1:c),n=e('<table role="grid" />'),Lt&&n.attr("cellspacing",0),n.width(r.table[0].style.width),n.append(r.thead),t.empty().append(e('<div class="k-grid-header-wrap k-auto-scrollable" />').append(n)),r.content=r.table.parent(),r.content.is(".k-virtual-scrollable-wrap, .km-scroll-container")&&(r.content=r.content.parent()),r.content.is(".k-grid-content, .k-virtual-scrollable-wrap")||(r.content=r.table.wrap('<div class="k-grid-content k-auto-scrollable" />').parent()),l&&(r.virtualScrollable=new Nt(r.content,{dataSource:r.dataSource,itemHeight:function(){return r._averageRowHeight()}})),r.scrollables=t.children(".k-grid-header-wrap").add(r.content),i=r.wrapper.find(".k-grid-footer"),i.length&&(r.scrollables=r.scrollables.add(i.children(".k-grid-footer-wrap"))),a.virtual?r.content.find(">.k-virtual-scrollable-wrap").unbind("scroll"+Ve).bind("scroll"+Ve,function(){r.scrollables.scrollLeft(this.scrollLeft),r.lockedContent&&(r.lockedContent[0].scrollTop=this.scrollTop)}):(r.content.unbind("scroll"+Ve).bind("scroll"+Ve,function(e){r.scrollables.not(e.currentTarget).scrollLeft(this.scrollLeft),r.lockedContent&&e.currentTarget==r.content[0]&&(r.lockedContent[0].scrollTop=this.scrollTop)}),o=r.content.data("kendoTouchScroller"),o&&o.destroy(),o=he.touchScroller(r.content),o&&o.movable&&(r.touchScroller=o,o.movable.bind("change",function(e){r.scrollables.scrollLeft(-e.sender.x),r.lockedContent&&r.lockedContent.scrollTop(-e.sender.y)}),r.one(nt,function(e){e.sender.wrapper.addClass("k-grid-backface")}))))},_renderNoRecordsContent:function(){var t,n=this;n.options.noRecords&&(t=n.table.parent().children("."+ct),t.length&&(n.angular("cleanup",function(){return{elements:t.get()}}),t.remove()),n.dataSource&&n.dataSource.view().length||(t=e(n.noRecordsTemplate({})).insertAfter(n.table),n.angular("compile",function(){return{elements:t.get(),data:[{}]}})))},_setContentWidth:function(t){var n,i=this,o="k-grid-content-expander",r='<div class="'+o+'"></div>',s=i.resizable;i.options.scrollable&&i.wrapper.is(":visible")&&(n=i.table.parent().children("."+o),i._setContentWidthHandler=Ae(i._setContentWidth,i),i.dataSource&&i.dataSource.view().length?n[0]&&(n.remove(),s&&s.unbind("resize",i._setContentWidthHandler)):(n[0]||(n=e(r).appendTo(i.table.parent()),s&&s.bind("resize",i._setContentWidthHandler)),i.thead&&(n.width(i.thead.width()),isNaN(parseFloat(t,10))||i.content.scrollLeft(t))),i._applyLockedContainersWidth(),i.lockedHeader&&0===i.table[0].clientWidth&&(i.table[0].style.width="1px"))},_applyLockedContainersWidth:function(){if(this.options.scrollable&&this.lockedHeader){var e,t=this.thead.parent(),n=t.parent(),i=this.wrapper[0].clientWidth,o=this._groups(),r=he.support.scrollbar(),s=this.lockedHeader.find(">table>colgroup>col:not(.k-group-col, .k-hierarchy-col)"),a=t.find(">colgroup>col:not(.k-group-col, .k-hierarchy-col)"),l=A(s),c=A(a);o>0&&(l+=_e(this.lockedHeader.find(".k-group-cell:first"))*o),l>=i&&(l=i-3*r),this.lockedHeader.add(this.lockedContent).width(l),n[0].style.width=n.parent().width()-l-2+"px",t.add(this.table).width(c),this.virtualScrollable&&(i-=r),this.content[0].style.width=i-l-2+"px",this.lockedFooter&&this.lockedFooter.length&&(this.lockedFooter.width(l),e=this.footer.find(".k-grid-footer-wrap"),e[0].style.width=n[0].clientWidth+"px",e.children().first().width(c))}},_setContentHeight:function(){var e,t=this,n=t.options,i=t.wrapper.innerHeight(),o=t.wrapper.children(".k-grid-header"),r=he.support.scrollbar();n.scrollable&&t.wrapper.is(":visible")&&(i-=be(o),t.pager&&(i-=be(t.pager.element)),n.groupable&&(i-=be(t.wrapper.children(".k-grouping-header"))),n.toolbar&&(i-=be(t.wrapper.children(".k-grid-toolbar"))),t.footerTemplate&&(i-=be(t.wrapper.children(".k-grid-footer"))),e=function(e){var t,n;return!!e[0].style.height||(t=e.height(),e.height("auto"),n=e.height(),t!=n?(e.height(""),!0):(e.height(""),!1))},e(t.wrapper)&&(i>2*r?(t.lockedContent&&(r=t.table[0].offsetWidth>t.table.parent()[0].clientWidth?r:0,t.lockedContent.height(i-r)),t.content.height(i)):t.content.height(2*r+1)))},_averageRowHeight:function(){var e,t=this,n=t._items(t.tbody).length,i=t._rowHeight;return 0===n?i:(t._rowHeight||(t._rowHeight=i=be(t.table)/n,t._sum=i,t._measures=1),e=be(t.table)/n,i!==e&&(t._measures++,t._sum+=e,t._rowHeight=t._sum/t._measures),i)},_dataSource:function(){var e,n=this,i=n.options,o=i.dataSource;o=Se(o)?{data:o}:o,ye(o)&&(ke(o,{table:n.table,fields:n.columns}),e=i.pageable,ye(e)&&e.pageSize!==t&&(o.pageSize=e.pageSize)),n.dataSource&&n._refreshHandler?n.dataSource.unbind(Ze,n._refreshHandler).unbind(Re,n._progressHandler).unbind(Fe,n._errorHandler):(n._refreshHandler=Ae(n.refresh,n),n._progressHandler=Ae(n._requestStart,n),n._errorHandler=Ae(n._error,n)),n.dataSource=pe.create(o).bind(Ze,n._refreshHandler).bind(Re,n._progressHandler).bind(Fe,n._errorHandler)},_error:function(){this._progress(!1)},_requestStart:function(){this._progress(!0)},_modelChange:function(t){var n,i,o,r,s,a,l,c,d,u,h=this,f=h.tbody,p=t.model,m=h.tbody.find("tr["+he.attr("uid")+"="+p.uid+"]"),g=m.hasClass("k-alt"),v=h._items(f).index(m),_=h.lockedContent;if(_&&(n=h._relatedRow(m)),m.add(n).children(".k-edit-cell").length&&!h.options.rowTemplate)m.add(n).children(":not(.k-group-cell,.k-hierarchy-cell)").each(function(){i=e(this),o=H(h.columns)[h.cellIndex(i)],o.field===t.field&&(i.hasClass("k-edit-cell")?i.addClass("k-dirty-cell"):(h._displayCell(i,o,p),e('<span class="k-dirty"/>').prependTo(i)))});else if(!m.hasClass("k-grid-edit-row")){for(a=e().add(m),_&&(r=(g?h.lockedAltRowTemplate:h.lockedRowTemplate)(p),a=a.add(n),n.replaceWith(r)),h.angular("cleanup",function(){return{elements:a.get()}}),r=(g?h.altRowTemplate:h.rowTemplate)(p),m.replaceWith(r),r=h._items(f).eq(v),u=[{dataItem:p}],_&&(m=m.add(n),n=h._relatedRow(r)[0],ie(r[0],n),r=r.add(n),u.push({dataItem:p})),h.angular("compile",function(){return{elements:r.get(),data:u}}),s=h.options.selectable,s&&m.hasClass("k-state-selected")&&h.select(r),c=a.children(":not(.k-group-cell,.k-hierarchy-cell)"),l=r.children(":not(.k-group-cell,.k-hierarchy-cell)"),v=0,d=h.columns.length;v<d;v++)o=h.columns[v],i=l.eq(v),s&&c.eq(v).hasClass("k-state-selected")&&i.addClass("k-state-selected"),o.field===t.field&&e('<span class="k-dirty"/>').prependTo(i);h.trigger("itemChange",{item:r,data:p,ns:fe})}},_pageable:function(){var t,n=this,i=n.options.pageable;i&&(t=n.wrapper.children("div.k-grid-pager"),t.length||(t=e('<div class="k-pager-wrap k-grid-pager"/>').appendTo(n.wrapper)),n.pager&&n.pager.destroy(),n.pager="object"==typeof i&&i instanceof he.ui.Pager?i:new he.ui.Pager(t,ke({},i,{dataSource:n.dataSource})),n.pager.bind("pageChange",function(e){n.trigger("page",{page:e.index})&&e.preventDefault()}))},_footer:function(){var t,n,i,o=this,r=o.dataSource.aggregates(),s="",a=o.footerTemplate,l=o.options,c=o.footer||o.wrapper.find(".k-grid-footer");a?(s=e(o._wrapFooter(a(r))),c.length?(n=s,o.angular("cleanup",function(){return{elements:c.get()}}),c.replaceWith(n),c=o.footer=n):c=o.footer=l.scrollable?l.pageable?s.insertBefore(o.wrapper.children("div.k-grid-pager")):s.appendTo(o.wrapper):s.insertBefore(o.tbody),o.angular("compile",function(){return{elements:c.find("td:not(.k-group-cell, .k-hierarchy-cell)").get(),data:xe(o.columns,function(e){return{column:e,aggregate:r[e.field]}})}})):c&&!o.footer&&(o.footer=c),c.length&&(l.scrollable&&(t=c.attr("tabindex",-1).children(".k-grid-footer-wrap"),o.scrollables=e(o.scrollables.filter(function(){return!e(this).is(".k-grid-footer-wrap")}).toArray()).add(t)),o._footerWidth&&c.find("table").css("width",o._footerWidth),t&&(i=o.content.scrollLeft(),l.scrollable!==!0&&l.scrollable.virtual&&(i=o.wrapper.find(".k-virtual-scrollable-wrap").scrollLeft()),t.scrollLeft(i))),o.lockedContent&&(o._appendLockedColumnFooter(),o._applyLockedContainersWidth(),o._syncLockedFooterHeight())},_wrapFooter:function(t){var n=this,i="",o=he.support.mobileOS?0:he.support.scrollbar();return n.options.scrollable?(i=e('<div class="k-grid-footer"><div class="k-grid-footer-wrap"><table'+(Lt?' cellspacing="0"':"")+"><tbody>"+t+"</tbody></table></div></div>"),n._appendCols(i.find("table")),i.css(Pt?"padding-left":"padding-right",o),i):'<tfoot class="k-grid-footer">'+t+"</tfoot>"},_columnMenu:function(){var e,n,i,o,r,s,a,l,c,d=this,u=H(d.columns),h=d.options,f=h.columnMenu,p=Ce(d.columns,function(e){return e.columns!==t}).length>0,m=this._isMobile,g=function(e){d.trigger(Ye,{field:e.field,container:e.container})},v=function(e){d.trigger(Qe,{field:e.field,container:e.container})},_=function(e){re(e.closest("table"),!0)},b=function(e){d.trigger("sort",{sort:e.sort})&&e.preventDefault()},w=function(e){d.trigger("filter",{filter:e.filter,field:e.field})&&e.preventDefault()},y=h.$angular;if(f)for("boolean"==typeof f&&(f={}),s=N(d.thead),a=0,l=s.length;a<l;a++)n=u[a],c=s.eq(a),n.command||!n.field&&!c.attr("data-"+he.ns+"field")||(e=c.data("kendoColumnMenu"),e&&e.destroy(),o=n.sortable!==!1&&f.sortable!==!1&&h.sortable!==!1&&ke({},h.sortable,{compare:(n.sortable||{}).compare}),r=!(!h.filterable||n.filterable===!1||f.filterable===!1)&&ke({pane:d.pane},h.filterable,n.filterable),n.filterable&&n.filterable.dataSource&&(r.forceUnique=!1,r.checkSource=n.filterable.dataSource),r&&(r.format=n.format),i={dataSource:d.dataSource,values:n.values,columns:f.columns,sortable:o,filterable:r,messages:f.messages,owner:d,closeCallback:_,init:g,open:v,pane:d.pane,sort:b,filtering:w,filter:m?":not(.k-column-active)":"",lockedColumns:!p&&n.lockable!==!1&&F(u).length>0},y&&(i.$angular=y),c.kendoColumnMenu(i))},_headerCells:function(){return this.thead.find("th").filter(function(){var t=e(this);return!t.hasClass("k-group-cell")&&!t.hasClass("k-hierarchy-cell")})},_filterable:function(){var e,t,n,i,o,r,s,a=this,l=H(a.columns),c=function(e){a.trigger($e,{field:e.field,container:e.container})},d=function(e){re(e.closest("table"),!0)},u=function(e){a.trigger("filter",{filter:e.filter,field:e.field})&&e.preventDefault()},h=function(e){a.trigger(Ke,{field:e.field,container:e.container})},f=a.options.filterable;if(f&&typeof f.mode==bt&&f.mode.indexOf("menu")==-1&&(f=!1),f&&!a.options.columnMenu)for(t=N(a.thead),i=0,o=t.length;i<o;i++)n=t.eq(i),l[i].filterable===!1||l[i].command||!l[i].field&&!n.attr("data-"+he.ns+"field")||(e=n.data("kendoFilterMenu"),e&&e.destroy(),e=n.data("kendoFilterMultiCheck"),e&&e.destroy(),r=l[i].filterable,s=ke({},f,r,{dataSource:a.dataSource,values:l[i].values,format:l[i].format,closeCallback:d,title:l[i].title||l[i].field,init:c,open:h,pane:a.pane,change:u}),r&&r.messages&&(s.messages=ke(!0,{},f.messages,r.messages)),r&&r.dataSource&&(s.forceUnique=!1,s.checkSource=r.dataSource),r&&r.multi?n.kendoFilterMultiCheck(s):n.kendoFilterMenu(s))},_filterRow:function(){var t,n,i,o,r,s,a,l,c,d,u,h,f,p,m,g=this;if(g._hasFilterRow())for(n=g.options.$angular,i=H(g.columns),o=g.options.filterable,r=g.thead.find(".k-filter-row"),s=function(e){g.trigger("filter",{filter:e.filter,field:e.field})&&e.preventDefault()},this._updateHeader(this.dataSource.group().length),a=0;a<i.length;a++)if(c=i[a],d=g.options.filterable.operators,u=!1,h=e("<th/>"),f=c.field,c.hidden&&h.hide(),r.append(h),f&&c.filterable!==!1){if(p=c.filterable&&c.filterable.cell||{},l=g.options.dataSource,l instanceof pe&&(l=g.options.dataSource.options),m=ke(!0,{},o.messages),c.filterable&&ke(!0,m,c.filterable.messages),p.enabled===!1){h.html("&nbsp;");continue}p.dataSource&&(l=p.dataSource,u=!0),c.filterable&&c.filterable.operators&&(d=c.filterable.operators),t={column:c,dataSource:g.dataSource,suggestDataSource:l,customDataSource:u,field:f,messages:m,values:c.values,template:p.template,delay:p.delay,inputWidth:p.inputWidth,suggestionOperator:p.suggestionOperator,minLength:p.minLength,dataTextField:p.dataTextField,operator:p.operator,operators:d,showOperators:p.showOperators,change:s},n&&(t.$angular=n),e("<span/>").attr(he.attr("field"),f).appendTo(h).kendoFilterCell(t)}else h.html("&nbsp;")},_sortable:function(){var e,t,n,i,o,r,s=this,a=H(s.columns),l=s.options.sortable,c=function(e){s.trigger("sort",{sort:e.sort})&&e.preventDefault()};if(l){for(i=N(s.thead),o=0,r=i.length;o<r;o++)e=a[o],e.sortable!==!1&&!e.command&&e.field&&(n=i.eq(o),t=n.data("kendoColumnSorter"),t&&t.destroy(),n.attr("data-"+he.ns+"field",e.field).kendoColumnSorter(ke({},l,e.sortable,{
dataSource:s.dataSource,aria:!0,filter:":not(.k-column-active)",change:c})));i=null}},_columns:function(t){var n,i,o,r=this,s=r.table,a=s.find("col"),c=r.options.dataSource;if(t=t.length?t:xe(s.find("th"),function(t,n){t=e(t);var i=t.attr(he.attr("sortable")),o=t.attr(he.attr("filterable")),r=t.attr(he.attr("type")),s=t.attr(he.attr("groupable")),l=t.attr(he.attr("field")),c=t.attr(he.attr("title")),d=t.attr(he.attr("menu"));return l||(l=t.text().replace(/\s|[^A-z0-9]/g,"")),{field:l,type:r,title:c,sortable:"false"!==i,filterable:"false"!==o,groupable:"false"!==s,menu:d,template:t.attr(he.attr("template")),width:a.eq(n).css("width")}}),n=!(r.table.find("tbody tr").length>0&&(!c||!c.transport)),r.options.scrollable){if(o=t,i=F(t),t=z(t),i.length>0&&0===t.length)throw Error("There should be at least one non locked column");G(r.element.find("tr:has(th):first"),o),t=i.concat(t)}r.columns=l(t,n),e.grep(H(r.columns),function(e){return e.selectable}).length&&(r.options.persistSelection&&(r._selectedIds={}),r.wrapper.on(mt+Ve,"tbody > tr "+lt,Ae(r._checkboxClick,r)),r.wrapper.on(mt+Ve,"thead > tr "+lt,Ae(r._headerCheckboxClick,r)))},_headerCheckboxClick:function(t){var n=this,i=e(t.target),o=i.prop("checked"),r=i.closest(".k-grid.k-widget").getKendoGrid();n===r&&(o?n.select(r.items()):n.clearSelection())},_checkboxClick:function(t){var n=this,i=e(t.target).closest("tr"),o=!i.hasClass(st);n===i.closest(".k-grid.k-widget").getKendoGrid()&&(o?n.select(i):n._deselectCheckRows(i))},_groups:function(){var e=this.dataSource.group();return e?e.length:0},_tmpl:function(e,t,o,r){var s,a,l,c,d=this,u=ke({},he.Template,d.options.templateSettings),h=t.length,f={storage:{},count:0},p=d._hasDetails(),m=[],g=d._groups(),v=d.options.navigatable;if(!e){for(e="<tr",o&&m.push("k-alt"),p&&m.push("k-master-row"),m.length&&(e+=' class="'+m.join(" ")+'"'),h&&(e+=" "+he.attr("uid")+'="#='+he.expr("uid",u.paramName)+'#"'),e+=" role='row'>",g>0&&!r&&(e+=n(g)),p&&(e+='<td class="k-hierarchy-cell"><a class="k-icon k-i-expand" href="\\#" '+Tt+'="'+St+'" tabindex="-1"></a></td>'),s=0;s<h;s++)l=t[s],a=l.template,c=typeof a,e+="<td"+i(l.attributes),v&&(e+=" aria-describedby='"+l.headerAttributes.id+"'"),e+=" role='gridcell'>",e+=d._cellTmpl(l,f),e+="</td>";e+="</tr>"}return e=he.template(e,u),f.count>0?Ae(e,f.storage):e},_headerCellText:function(e){var t=this,n=ke({},he.Template,t.options.templateSettings),i=e.headerTemplate,o=typeof i,r=e.title||e.field||"";return o===_t?r=he.template(i,n)({}):o===bt&&(r=i),r},_cellTmpl:function(e,t){var n,i,o=this,r=ke({},he.Template,o.options.templateSettings),s=e.template,a=r.paramName,l=e.field,c="",d=e.format,u=typeof s,h=e.values;if(e.command){if(Se(e.command)){for(n=0,i=e.command.length;n<i;n++)c+=e.command[n].visible?he.format("#= {0}(data)? '{1}':'' #",e.command[n].visible,o._createButton(e.command[n]).replace(At,"\\#")):o._createButton(e.command[n]).replace(At,"\\#");return c}return o._createButton(e.command).replace(At,"\\#")}return e.selectable?Ft:(u===_t?(t.storage["tmpl"+t.count]=s,c+="#=this.tmpl"+t.count+"("+a+")#",t.count++):u===bt?c+=s:h&&h.length&&ye(h[0])&&"value"in h[0]&&l?(c+="#var v ="+he.stringify($(h)).replace(At,"\\#")+"#",c+="#var f = v[",r.useWithBlock||(c+=a+"."),c+=l+"]#",c+="${f != null ? f : ''}"):(c+=e.encoded?"#:":"#=",d&&(c+='kendo.format("'+d.replace(Dt,"\\$1")+'",'),l?(l=he.expr(l,a),c+=l+"==null?'':"+l):c+="''",d&&(c+=")"),c+="#"),c)},_templates:function(){var t=this,n=t.options,i=t.dataSource,o=i.group(),r=t.footer||t.wrapper.find(".k-grid-footer"),s=i.aggregate(),a=H(t.columns),l=H(F(t.columns)),c=n.scrollable?H(z(t.columns)):a;if(n.scrollable&&l.length){if(n.rowTemplate||n.altRowTemplate)throw Error("Having both row template and locked columns is not supported");t.rowTemplate=t._tmpl(n.rowTemplate,c,!1,!0),t.altRowTemplate=t._tmpl(n.altRowTemplate||n.rowTemplate,c,!0,!0),t.lockedRowTemplate=t._tmpl(n.rowTemplate,l),t.lockedAltRowTemplate=t._tmpl(n.altRowTemplate||n.rowTemplate,l,!0)}else t.rowTemplate=t._tmpl(n.rowTemplate,c),t.altRowTemplate=t._tmpl(n.altRowTemplate||n.rowTemplate,c,!0);t._hasDetails()&&(t.detailTemplate=t._detailTmpl(n.detailTemplate||"")),(t._group&&!Me(s)||!Me(s)&&!r.length||Ce(a,function(e){return e.footerTemplate}).length)&&(t.footerTemplate=t._footerTmpl(a,s,"footerTemplate","k-footer-template")),o&&Ce(a,function(e){return e.groupFooterTemplate}).length&&(s=e.map(o,function(e){return e.aggregates}),t.groupFooterTemplate=t._footerTmpl(c,s,"groupFooterTemplate","k-group-footer",l.length),n.scrollable&&l.length&&(t.lockedGroupFooterTemplate=t._footerTmpl(l,s,"groupFooterTemplate","k-group-footer"))),t.options.noRecords&&(t.noRecordsTemplate=t._noRecordsTmpl())},_noRecordsTmpl:function(){var t,n,i,o='<div class="{0}">{1}</div>',r='<div class="k-grid-norecords-template"{1}>{0}</div>',s=this.options.scrollable&&!this.wrapper[0].style.height?' style="margin:0 auto;position:static;"':"",a={storage:{},count:0},l=e.extend({},he.Template,this.options.templateSettings),c=l.paramName,d="";return t=this.options.noRecords.template?this.options.noRecords.template:he.format(r,this.options.messages.noRecords,s),n=typeof t,"function"===n?(a.storage["tmpl"+a.count]=t,d+="#=this.tmpl"+a.count+"("+c+")#",a.count++):"string"===n&&(d+=t),i=he.template(he.format(o,ct,d),l),a.count>0&&(i=e.proxy(i,a.storage)),i},_footerTmpl:function(e,t,o,r,s){var a,l,c,d,u,h=this,f=ke({},he.Template,h.options.templateSettings),p=f.paramName,m="",g={},v=0,_={},b=h._groups(),w=h.dataSource._emptyAggregates(t);for(m+='<tr class="'+r+'">',b>0&&!s&&(m+=n(b)),h._hasDetails()&&(m+='<td class="k-hierarchy-cell">&nbsp;</td>'),a=0,l=e.length;a<l;a++)u=e[a],c=u[o],d=typeof c,m+="<td"+i(u.footerAttributes)+">",c?(d!==_t&&(_=w[u.field]?ke({},f,{paramName:p+"['"+u.field+"']"}):{},c=he.template(c,_)),g["tmpl"+v]=c,m+="#=this.tmpl"+v+"("+p+")#",v++):m+="&nbsp;",m+="</td>";return m+="</tr>",m=he.template(m,f),v>0?Ae(m,g):m},_detailTmpl:function(e){var t=this,i="",o=ke({},he.Template,t.options.templateSettings),r=o.paramName,s={},a=0,l=t._groups(),c=p(H(t.columns)).length,d=typeof e;return i+='<tr class="k-detail-row">',l>0&&(i+=n(l)),i+='<td class="k-hierarchy-cell"></td><td class="k-detail-cell"'+(c?' colspan="'+c+'"':"")+">",d===_t?(s["tmpl"+a]=e,i+="#=this.tmpl"+a+"("+r+")#",a++):i+=e,i+="</td></tr>",i=he.template(i,o),a>0?Ae(i,s):i},_hasDetails:function(){var e=this;return null!==e.options.detailTemplate||(e._events[Ge]||[]).length},_hasFilterRow:function(){var t=this.options.filterable,n=t&&typeof t.mode==bt&&t.mode.indexOf("row")!=-1,i=this.columns,o=e.grep(i,function(e){return e.filterable===!1});return i.length&&o.length==i.length&&(n=!1),n},_details:function(){var t=this;if(t.options.scrollable&&t._hasDetails()&&F(t.columns).length)throw Error("Having both detail template and locked columns is not supported");t.table.on(mt+Ve,".k-hierarchy-cell .k-i-expand, .k-hierarchy-cell .k-i-collapse",function(n){var i,o,r=e(this),s=r.hasClass("k-i-expand"),a=r.closest("tr.k-master-row"),l=t.detailTemplate,c=t._hasDetails(),d=s?Ct:St;return r.toggleClass("k-i-expand",!s).toggleClass("k-i-collapse",s).attr(Tt,d),i=a.next(),c&&!i.hasClass("k-detail-row")&&(o=t.dataItem(a),i=e(l(o)).addClass(a.hasClass("k-alt")?"k-alt":"").insertAfter(a),t.angular("compile",function(){return{elements:i.get(),data:[{dataItem:o}]}}),t.trigger(Ge,{masterRow:a,detailRow:i,data:o,detailCell:i.find(".k-detail-cell")})),t.trigger(s?it:ot,{masterRow:a,detailRow:i}),i.toggle(s),t._current&&t._current.attr("aria-expanded",s),n.preventDefault(),!1})},dataItem:function(t){if(t=e(t)[0],!t)return null;var n,i,o=this.tbody.children(),r=/k-grouping-row|k-detail-row|k-group-footer/,s=t.sectionRowIndex;for(i=s,n=0;n<s;n++)r.test(o[n].className)&&i--;return this._data[i]},expandRow:function(t){e(t).find("> td .k-i-expand").click()},collapseRow:function(t){e(t).find("> td .k-i-collapse").click()},_createHeaderCells:function(e,n){var o,r,s,a,l,c,d=this,u="",h=H(d.columns);for(o=0,a=e.length;o<a;o++)r=e[o].column||e[o],s=d._headerCellText(r),l="",c=Te(r,h),r.selectable?(u+="<th scope='col'"+i(r.headerAttributes),n&&!e[o].colSpan&&(u+=" rowspan='"+n+"'"),c>-1&&(u+=he.attr("index")+"='"+c+"'"),s=r.headerTemplate?s:zt,u+=">"+s+"</th>"):r.command?(u+="<th scope='col'"+i(r.headerAttributes),n&&!e[o].colSpan&&(u+=" rowspan='"+n+"'"),c>-1&&(u+=he.attr("index")+"='"+c+"'"),u+=">"+s+"</th>"):(r.field&&(l=he.attr("field")+"='"+r.field+"' "),u+="<th scope='col' role='columnheader' "+l,u+=" aria-haspopup='true'",n&&!e[o].colSpan&&(u+=" rowspan='"+n+"'"),e[o].colSpan>1&&(u+='colspan="'+(e[o].colSpan-D(r.columns))+'" ',u+=he.attr("colspan")+"='"+e[o].colSpan+"'"),r.title&&(u+=he.attr("title")+'="'+r.title.replace('"',"&quot;").replace(/'/g,"'")+'" '),r.groupable!==t&&(u+=he.attr("groupable")+"='"+r.groupable+"' "),r.aggregates&&r.aggregates.length&&(u+=he.attr("aggregates")+"='"+r.aggregates+"'"),c>-1&&(u+=he.attr("index")+"='"+c+"'"),u+=i(r.headerAttributes),u+=">"+s+"</th>");return u},_appendLockedColumnContent:function(){var t,n,i,o,r,s=this.columns,a=this.table.find("colgroup"),l=a.find("col:not(.k-group-col,.k-hierarchy-col)"),c=e(),d=0,u=0;for(t=0,n=s.length;t<n;t++)if(s[t].locked)if(f(s[t])){for(o=1,s[t].columns&&(o=H(s[t].columns).length-D(s[t].columns)),o=o||1,r=0;r<o;r++)c=c.add(l.eq(t+u+r-d));u+=o-1}else d++;i=e('<div class="k-grid-content-locked"><table'+(Lt?' cellspacing="0"':"")+"><colgroup/><tbody></tbody></table></div>"),a.detach(),i.find("colgroup").append(c),a.insertBefore(this.table.find("tbody")),this.lockedContent=i.insertBefore(this.content),this.lockedTable=i.children("table")},_appendLockedColumnFooter:function(){var t,n,i=this,o=i.footer,r=o.find(".k-footer-template>td"),s=o.find(".k-grid-footer-wrap>table>colgroup>col"),a=e('<div class="k-grid-footer-locked"><table><colgroup /><tbody><tr class="k-footer-template"></tr></tbody></table></div>'),l=i._groups(),c=e(),d=e();for(c=c.add(r.filter(".k-group-cell")),t=0,n=H(F(i.columns)).length;t<n;t++)c=c.add(r.eq(t+l));for(d=d.add(s.filter(".k-group-col")),t=0,n=p(H(B(i.columns))).length;t<n;t++)d=d.add(s.eq(t+l));c.appendTo(a.find("tr")),d.appendTo(a.find("colgroup")),i.lockedFooter=a.prependTo(o)},_appendLockedColumnHeader:function(t){var n,i,o,r,s,a,l,c,d,u,h,p=this,g=this.columns,v=[],_=0,b=e(),w=p._hasFilterRow(),y=0,k=e(),x=0,C=e(),S=p.thead.prev().find("col:not(.k-group-col,.k-hierarchy-col)"),T=p.thead.find("tr:first .k-header:not(.k-group-cell,.k-hierarchy-cell)"),A=p.thead.find(".k-filter-row").find("th:not(.k-group-cell,.k-hierarchy-cell)"),M=0;for(n=0,o=g.length;n<o;n++){if(g[n].locked){if(l=T.eq(n),x=H(g[n].columns||[]).length,f(g[n])){for(c=null,g[n].columns&&(c=x-D(g[n].columns)),c=c||1,d=0;d<c;d++)b=b.add(S.eq(n+M+d-_));M+=c-1}for(R([g[n]],V(l),v,0,0),x=x||1,u=0;u<x;u++)k=k.add(A.eq(y+u));y+=x}g[n].columns&&(_+=D(g[n].columns)),f(g[n])||_++}if(v.length){for(i='<div class="k-grid-header-locked" style="width:1px"><table'+(Lt?' cellspacing="0"':"")+"><colgroup/><thead>",i+=Array(v.length+1).join("<tr></tr>"),i+=(w?'<tr class="k-filter-row" />':"")+"</thead></table></div>",a=e(i),S=a.find("colgroup"),S.append(p.thead.prev().find("col.k-group-col").add(b)),r=a.find("thead tr:not(.k-filter-row)"),n=0,o=v.length;n<o;n++)C=m(v[n]),r.eq(n).append(p.thead.find("tr:eq("+n+") .k-group-cell").add(C));return h=I(this.thead),v.length<h&&E(a,h-v.length),s=a.find(".k-filter-row"),s.append(p.thead.find(".k-filter-row .k-group-cell").add(k)),this.lockedHeader=a.prependTo(t),this.thead.find(".k-group-cell").remove(),!0}return!1},_removeLockedContainers:function(){var e=this.lockedHeader.add(this.lockedContent).add(this.lockedFooter);he.destroy(e),e.off(Ve).remove(),this.lockedHeader=this.lockedContent=this.lockedFooter=null,this.selectable=null},_thead:function(){var t,n,i,o,r,s,a,l=this,c=l.columns,d=l._hasDetails()&&c.length,u=l._hasFilterRow(),h="",f=l.table.find(">thead"),p=l.element.find("thead:first").length>0;if(f.length||(f=e("<thead/>").insertBefore(l.tbody)),l.lockedHeader&&l.thead?(n=l.thead.find("tr:has(th):not(.k-filter-row)").html(""),n.remove(),n=e(),l._removeLockedContainers()):n=l.element.find(p?"thead:first tr:has(th):not(.k-filter-row)":"tr:has(th):first"),!n.length&&(n=f.children().first(),!n.length)){for(i=[{rowSpan:1,cells:[],index:0}],l._prepareColumns(i,c),t=0;t<i.length;t++)h+="<tr>",d&&(h+='<th class="k-hierarchy-cell" scope="col">'+l.options.messages.expandCollapseColumnHeader+"</th>"),h+=l._createHeaderCells(i[t].cells,i[t].rowSpan),h+="</tr>";n=e(h)}u&&(o=e("<tr/>"),o.addClass("k-filter-row"),(d||n.find(".k-hierarchy-cell").length)&&o.prepend('<th class="k-hierarchy-cell" scope="col">&nbsp;</th>'),r=(l.thead||f).find(".k-filter-row"),r.length&&(he.destroy(r),r.remove()),f.append(o)),n.children().length?d&&!n.find(".k-hierarchy-cell")[0]&&n.prepend('<th class="k-hierarchy-cell" scope="col">&nbsp;</th>'):(h="",d&&(h+='<th class="k-hierarchy-cell" scope="col">&nbsp;</th>'),h+=l._createHeaderCells(c),n.html(h)),n.attr("role","row").find("th").addClass("k-header"),l.options.scrollable||f.addClass("k-grid-header"),n.find("script").remove().end().prependTo(f),l.thead&&l._destroyColumnAttachments(),this.angular("cleanup",function(){return{elements:f.find("th").get()}}),this.angular("compile",function(){return{elements:f.find("th").get(),data:xe(c,function(e){return{column:e}})}}),l.thead=f.attr("role","rowgroup"),l._sortable(),l._filterable(),l._filterRow(),l._scrollable(),l._updateCols(),l._columnMenu(),a=this.options.scrollable&&F(this.columns).length,a&&(s=l._appendLockedColumnHeader(l.thead.closest(".k-grid-header")),l._appendLockedColumnContent(),l.lockedContent.bind("DOMMouseScroll"+Ve+" mousewheel"+Ve,Ae(l._wheelScroll,l))),l._updateColumnCellIndex(),l._updateFirstColumnClass(),l._resizable(),l._draggable(),l._reorderable(),l._updateHeader(l._groups()),a&&(s&&l._syncLockedHeaderHeight(),l._applyLockedContainersWidth()),l.groupable&&l._attachGroupable()},_retrieveFirstColumn:function(t,n){var i,o=e();if(n.length&&t[0]){for(i=t[0];i.columns&&i.columns.length;)i=i.columns[0],n=n.filter(":not(:first())");o=o.add(n)}return o},_updateFirstColumnClass:function(){var t,n,i=this,o=i.columns||[],r=i._hasDetails()&&o.length;r||i._groups()||(t=i.thead.find(">tr:not(.k-filter-row):not(:first)"),o=z(o),n=i._retrieveFirstColumn(o,t),i._isLocked()&&(t=i.lockedHeader.find("thead>tr:not(.k-filter-row):not(:first)"),o=F(i.columns),n=n.add(i._retrieveFirstColumn(o,t))),n.each(function(){var t=e(this).find("th");t.removeClass("k-first"),t.eq(0).addClass("k-first")}))},_prepareColumns:function(e,t,n,i){var o,r,s=i||e[e.length-1],a=e[s.index+1],l=0;for(o=0;o<t.length;o++)r={column:t[o],colSpan:0},s.cells.push(r),t[o].columns&&t[o].columns.length&&(a||(a={rowSpan:0,cells:[],index:e.length},e.push(a)),r.colSpan=t[o].columns.length,this._prepareColumns(e,t[o].columns,r,a),l+=r.colSpan-1,s.rowSpan=e.length-s.index);n&&(n.colSpan+=l)},_wheelScroll:function(e){var t,n,i;e.ctrlKey||(t=this.content,this.options.scrollable.virtual&&(t=this.virtualScrollable.verticalScrollbar),n=t.scrollTop(),i=he.wheelDeltaY(e),i&&(t[0].scrollHeight>t[0].clientHeight&&(t[0].scrollTop<t[0].scrollHeight-t[0].clientHeight&&i<0||t[0].scrollTop>0&&i>0)&&e.preventDefault(),t.scrollTop(n+-i)))},_isLocked:function(){return null!=this.lockedHeader},_updateHeaderCols:function(){var e=this.thead.parent().add(this.table);this._isLocked()?j(e,L(P(this.columns)),this._hasDetails(),0):j(e,L(p(this.columns)),this._hasDetails(),0)},_updateCols:function(e){e=e||this.thead.parent().add(this.table),this._appendCols(e,this._isLocked())},_updateLockedCols:function(e){this._isLocked()&&(e=e||this.lockedHeader.find("table").add(this.lockedTable),j(e,L(B(this.columns)),this._hasDetails(),this._groups()))},_appendCols:function(e,t){t?j(e,L(P(this.columns)),this._hasDetails(),0):j(e,L(p(this.columns)),this._hasDetails(),this._groups())},_autoColumns:function(e){if(e&&e.toJSON){var t,n,i=this;e=e.toJSON(),n=!(i.table.find("tbody tr").length>0&&(!i.dataSource||!i.dataSource.transport));for(t in e)i.columns.push({field:t,encoded:n,headerAttributes:{id:he.guid()}});i._thead(),i._templates()}},_rowsHtml:function(e,t){var n,i,o=this,r="",s=t.rowTemplate,a=t.altRowTemplate;for(n=0,i=e.length;n<i;n++)r+=n%2?a(e[n]):s(e[n]),o._data.push(e[n]);return r},_groupRowHtml:function(e,t,n,i,o,r){var s,a,l,c,d=this,u="",h=e.field,f=Ce(H(d.columns),function(e){return e.field==h})[0]||{},p=f.groupHeaderTemplate,m=(f.title||h)+": "+Y(e.value,f.format,f.values,f.encoded),g=d._groupAggregatesDefaultObject||{},v=e.items,_=ke({},g,e.aggregates),b=ke({},{field:e.field,value:e.value,items:v,aggregates:_},e.aggregates[e.field]),w=o.groupFooterTemplate;if(p&&(m=typeof p===_t?p(b):he.template(p)(b)),u+=i(t,n,m),e.hasSubgroups)for(s=0,a=v.length;s<a;s++)u+=d._groupRowHtml(v[s],r?t:t-1,n+1,i,o,r);else u+=d._rowsHtml(v,o);if(w){l={};for(c in _)l[c]=ke({},_[c],{group:{field:e.field,value:e.value,items:v}});u+=w(l)}return u},collapseGroup:function(t){var n,i,o,r,s,a,l,c,d,u;for(t=e(t),i=this.options.groupable,o=i.showFooter,r=o?0:1,a=e(),this._isLocked()&&(t.closest("div").hasClass("k-grid-content-locked")?a=this.tbody.children("tr:eq("+t.index()+")").nextAll("tr"):(a=t.nextAll("tr"),t=this.lockedTable.find(">tbody>tr:eq("+t.index()+")"))),n=t.find(".k-group-cell").length,t.find(".k-i-collapse").addClass("k-i-expand").removeClass("k-i-collapse"),t.find("td[aria-expanded='true']:first").attr("aria-expanded",!1).find("a").attr(Tt,St),t=t.nextAll("tr"),u=[],l=0,c=t.length;l<c&&(d=t.eq(l),s=d.find(".k-group-cell").length,d.hasClass("k-grouping-row")?r++:d.hasClass("k-group-footer")&&r--,!(s<=n||d.hasClass("k-group-footer")&&r<0));l++)a.length&&u.push(a[l]),u.push(d[0]);e(u).hide()},expandGroup:function(t){t=e(t);var n,i,o,r,s,a=this,l=a.options.groupable.showFooter,c=e(),d=[],u=1;for(this._isLocked()&&(t.closest("div").hasClass("k-grid-content-locked")?c=this.tbody.children("tr:eq("+t.index()+")").nextAll("tr"):(c=t.nextAll("tr"),t=this.lockedTable.find(">tbody>tr:eq("+t.index()+")"))),n=t.find(".k-group-cell").length,t.find(".k-i-expand").addClass("k-i-collapse").removeClass("k-i-expand"),t.find("td[aria-expanded='false']:first").attr("aria-expanded",!0).find("a").attr(Tt,Ct),t=t.nextAll("tr"),r=0,s=t.length;r<s&&(i=t.eq(r),o=i.find(".k-group-cell").length,!(o<=n));r++)o!=n+1||i.hasClass("k-detail-row")||(i.show(),c.eq(r).show(),i.hasClass("k-grouping-row")&&i.find(".k-icon").hasClass("k-i-collapse")&&a.expandGroup(i),i.hasClass("k-master-row")&&i.find(".k-icon").hasClass("k-i-collapse")&&(i.next().show(),c.eq(r+1).show())),i.hasClass("k-grouping-row")&&(l&&d.push(i.is(":visible")),u++),i.hasClass("k-group-footer")&&(l&&i.toggle(d.pop()),1==u?(i.show(),c.eq(r).show()):u--)},_updateHeader:function(t){var n=this,i=n._isLocked()?n.lockedHeader.find("thead"):n.thead,o=i.find("tr.k-filter-row").find("th.k-group-cell").length,r=i.find("tr:first").find("th.k-group-cell").length,s=i.children("tr:not(:first)").filter(function(){return!e(this).children(":visible").length});t>r?(e(Array(t-r+1).join('<th class="k-group-cell k-header" scope="col">'+n.options.messages.expandCollapseColumnHeader+"</th>")).prependTo(i.children("tr:not(.k-filter-row)")),n.element.is(":visible")&&s.find("th.k-group-cell").hide()):t<r&&i.find("tr").each(function(){e(this).find("th.k-group-cell").filter(":eq("+t+"),:gt("+t+")").remove()}),t>o&&e(Array(t-o+1).join('<th class="k-group-cell k-header" scope="col">&nbsp;</th>')).prependTo(i.find(".k-filter-row"))},_firstDataItem:function(e,t){return e&&t&&(e=e.hasSubgroups?this._firstDataItem(e.items[0],t):e.items[0]),e},_updateTablesWidth:function(){var t,n=this;n._isLocked()&&(t=e(">.k-grid-footer>.k-grid-footer-wrap>table",n.wrapper).add(n.thead.parent()).add(n.table),n._footerWidth=te(t.eq(0)),t.width(n._footerWidth),t=e(">.k-grid-footer>.k-grid-footer-locked>table",n.wrapper).add(n.lockedHeader.find(">table")).add(n.lockedTable),t.width(te(t.eq(0))))},hideColumn:function(n){var i,o,r,a,l,c,d,m,g,v,_=this,b=0,w=_.footer||_.wrapper.find(".k-grid-footer"),y=_.columns,k=_.lockedHeader?N(_.lockedHeader.find(">table>thead")).filter(h).length:0;if(n="number"==typeof n?y[n]:ye(n)?Ce(T(y),function(e){return e===n})[0]:Ce(T(y),function(e){return e.field===n})[0],n&&f(n)){if(n.columns&&n.columns.length){for(c=C(n,y),u(n,!1),K(s(e(">table>thead",_.lockedHeader),_.thead,">tr:eq("+c.row+")>th"),c.cell,!1),r=0;r<n.columns.length;r++)this.hideColumn(n.columns[r]);return _.trigger(Je,{column:n}),t}if(g=Te(n,p(H(y))),u(n,!1),_._setParentsVisibility(n,!1),_._templates(),_._updateCols(),_._updateLockedCols(),v=_.thead,d=g,_.lockedHeader&&k>g?v=_.lockedHeader.find(">table>thead"):d-=k,i=N(v).filter(h).eq(d),i[0].style.display="none",K(s(e(">table>thead",_.lockedHeader),_.thead,">tr.k-filter-row>th"),g,!1),w[0]&&(_._updateCols(w.find(">.k-grid-footer-wrap>table")),_._updateLockedCols(w.find(">.k-grid-footer-locked>table")),K(w.find(".k-footer-template>td"),g,!1)),_.lockedTable&&k>g?Q(_.lockedTable.find(">tbody>tr"),g):Q(_.tbody.children(),g-k),_.lockedTable)_._updateTablesWidth(),_._applyLockedContainersWidth(),_._syncLockedContentHeight(),_._syncLockedHeaderHeight(),_._syncLockedFooterHeight();else{for(a=_.thead.prev().find("col"),r=0,m=a.length;r<m;r+=1){if(l=a[r].style.width,!l||l.indexOf("%")!=-1){b=0;break}b+=parseInt(l,10)}o=e(">.k-grid-header table:first,>.k-grid-footer table:first",_.wrapper).add(_.table),_._footerWidth=null,b&&(o.each(function(){this.style.width=b+"px"}),_._footerWidth=b),Bt.msie&&8==Bt.version&&(o.css("display","inline-table"),setTimeout(function(){o.css("display","table")},1))}_._updateFirstColumnClass(),_.trigger(Je,{column:n})}},_setParentsVisibility:function(t,n){var i,o,r,a,l,c=this.columns,h=[],f=n?function(e){return p(e.columns).length&&e.hidden}:function(e){return!p(e.columns).length&&!e.hidden};if(d(t,c,h)&&h.length)for(i=h.length-1;i>=0;i--)o=h[i],r=y(o,c),a=s(e(">table>thead",this.lockedHeader),this.thead,">tr:eq("+r.row+")>th:not(.k-group-cell):not(.k-hierarchy-cell)").eq(r.cell),f(o)&&(u(o,n),a[0].style.display=n?"":"none"),a.filter("["+he.attr("colspan")+"]").length&&(l=parseInt(a.attr(he.attr("colspan")),10),a[0].colSpan=l-D(o.columns)||1)},showColumn:function(n){var i,o,r,a,l,c,d,h,p,m,g,v=this,_=v.columns,b=v.footer||v.wrapper.find(".k-grid-footer"),w=v.lockedHeader?N(v.lockedHeader.find(">table>thead")).length:0;if(n="number"==typeof n?_[n]:ye(n)?Ce(T(_),function(e){return e===n})[0]:Ce(T(_),function(e){return e.field===n})[0],n&&!f(n)){if(n.columns&&n.columns.length){for(d=y(n,_),u(n,!0),K(s(e(">table>thead",v.lockedHeader),v.thead,">tr:eq("+d.row+")>th"),d.cell,!0),i=0;i<n.columns.length;i++)this.showColumn(n.columns[i]);return v.trigger(et,{column:n}),t}if(m=Te(n,H(_)),u(n,!0),v._setParentsVisibility(n,!0),v._templates(),v._updateCols(),v._updateLockedCols(),g=v.thead,c=m,v.lockedHeader&&w>m?g=v.lockedHeader.find(">table>thead"):c-=w,r=N(g).eq(c),r[0].style.display="",K(s(e(">table>thead",v.lockedHeader),v.thead,">tr.k-filter-row>th"),m,!0),b[0]&&(v._updateCols(b.find(">.k-grid-footer-wrap>table")),v._updateLockedCols(b.find(">.k-grid-footer-locked>table")),K(b.find(".k-footer-template>td"),m,!0)),v.lockedTable&&w>m?J(v.lockedTable.find(">tbody>tr"),m):J(v.tbody.children(),m-w),v.lockedTable)v._updateTablesWidth(),v._applyLockedContainersWidth(),v._syncLockedContentHeight(),v._syncLockedHeaderHeight();else if(a=e(">.k-grid-header table:first,>.k-grid-footer table:first",v.wrapper).add(v.table),n.width){for(l=0,p=v.thead.prev().find("col"),i=0,o=p.length;i<o;i+=1){if(h=p[i].style.width,h.indexOf("%")>-1){l=0;break}l+=parseInt(h,10)}v._footerWidth=null,l&&(a.each(function(){this.style.width=l+"px"}),v._footerWidth=l)}else a.width("");v._updateFirstColumnClass(),v.trigger(et,{column:n})}},_progress:function(e){var t=this.element;this._editContainer&&"popup"===this._editMode()?t=this._editContainer:this.lockedContent?t=this.wrapper:this.element.is("table")?t=this.element.parent():this.content&&this.content.length&&(t=this.content),he.ui.progress(t,e)},_resize:function(e,t){this._syncLockedContentHeight(),this._syncLockedHeaderHeight(),this.content&&(this._setContentWidth(),this._setContentHeight()),this.virtualScrollable&&(t||this._rowHeight)&&(t&&(this._rowHeight=null),this.virtualScrollable.repaintScrollbar())},_isActiveInTable:function(){var t=ge();return!!t&&(this.table[0]===t||e.contains(this.table[0],t)||this._isLocked()&&(this.lockedTable[0]===t||e.contains(this.lockedTable[0],t)))},refresh:function(t){var n,i=this,o=i.dataSource.view(),r=i.options.navigatable,s=e(i.current()),a=!1,l=!!e.grep(H(i.columns),function(e){return e.selectable}).length,c=(i.dataSource.group()||[]).length,d=c+L(p(i.columns)).length;t&&"itemchange"===t.action&&i.editable||(t&&"remove"===t.action&&i.editable&&i.editable.options.model&&Te(i.editable.options.model,t.items)>-1&&i.editable.options.model.unbind(Ze,i._modelChangeHandler),t=t||{},i.trigger("dataBinding",{action:t.action||"rebind",index:t.index,items:t.items})||(i._angularItems("cleanup"),r&&(i._isActiveInTable()||i._editContainer&&i._editContainer.data("kendoWindow"))&&(a=s.is("th"),n=Math.max(i.cellIndex(s),0)),i._destroyEditable(),i._progress(!1),i._hideResizeHandle(),i._data=[],i.columns.length||(i._autoColumns(i._firstDataItem(o[0],c)),d=c+i.columns.length),i._group=c>0||i._group,i._group&&(i._templates(),i._updateCols(),i._updateLockedCols(),i._updateHeader(c),i._group=c>0),i._renderContent(o,d,c),i._renderLockedContent(o,d,c),i._footer(),i._renderNoRecordsContent(),i._setContentHeight(),i._setContentWidth(i.content&&i.content.scrollLeft()),i.lockedTable&&(i.options.scrollable.virtual?i.content.find(">.k-virtual-scrollable-wrap").trigger("scroll"):i.touchScroller?i.touchScroller.movable.trigger("change"):(i.wrapper.one("scroll",function(e){e.stopPropagation()}),i.content.trigger("scroll"))),i._restoreCurrent(n,a),i.touchScroller&&i.touchScroller.contentResized(),i.selectable&&i.selectable.resetTouchEvents(),i._muteAngularRebind(function(){i._angularItems("compile")}),l&&i._toggleHeaderCheckState(!1),i.options.persistSelection&&(i.selectable&&!he.ui.Selectable.parseOptions(i.options.selectable).cell||l)&&i._restoreSelection(),i.trigger(nt)))},_restoreCurrent:function(n,i){var o,r,s;n===t||n<0||(this._removeCurrent(),i?this._setCurrent(this.thead.find("th:not(.k-group-cell)").eq(n)):(o=0,this._rowVirtualIndex?o=this.virtualScrollable.position(this._rowVirtualIndex):n=0,r=e(),this.lockedTable&&(r=this.lockedTable.find(">tbody>tr").eq(o)),r=r.add(this.tbody.children().eq(o)),s=r.find(">td:not(.k-group-cell):not(.k-hierarchy-cell)").eq(n),this._setCurrent(s)),this._current&&re(this._current.closest("table")[0],!0))},_restoreSelection:function(){var e,t=this,n=t.items();e=Ce(n,function(e){var n=t.dataItem(e)[t.dataSource.options.schema.model.id];if(t._selectedIds[n])return e}),t.select(e)},_angularItems:function(e){he.ui.DataBoundWidget.fn._angularItems.call(this,e),"cleanup"===e&&this._cleanupDetailItems(),this._angularGroupItems(e),this._angularGroupFooterItems(e)},_cleanupDetailItems:function(){var e=this;e._hasDetails()&&(e.angular("cleanup",function(){return{elements:e.tbody.children(".k-detail-row")}}),e.tbody.find(".k-detail-cell").empty())},_angularGroupItems:function(t){var n=this,i=n.tbody;n.lockedContent&&(i=n.lockedTable.find("tbody")),n._group&&n.angular(t,function(){return{elements:i.children(".k-grouping-row"),data:e.map(X(n.dataSource.view()),function(e){return{dataItem:e}})}})},_angularGroupFooterItems:function(t){var n=this,i=n.tbody;n.lockedContent&&(i=n.element),n._group&&n.groupFooterTemplate&&n.angular(t,function(){return{elements:i.find(".k-group-footer"),data:e.map(Z(n.dataSource.view()),function(e){return{dataItem:e}})}})},_renderContent:function(e,t,n){var i,o,r=this,s="",a=null!=r.lockedContent,l={rowTemplate:r.rowTemplate,altRowTemplate:r.altRowTemplate,groupFooterTemplate:r.groupFooterTemplate};if(t=a?t-L(B(r.columns)).length:t,n>0)for(t=a?t-n:t,r.detailTemplate&&t++,r.groupFooterTemplate&&(r._groupAggregatesDefaultObject=r.dataSource.aggregates()),i=0,o=e.length;i<o;i++)s+=r._groupRowHtml(e[i],t,0,a?ue:de,l,a);else s+=r._rowsHtml(e,l);r.tbody=U(r.tbody,r.table,s,this.options.$angular)},_renderLockedContent:function(e,t,n){var i,o,r,s="",a={rowTemplate:this.lockedRowTemplate,altRowTemplate:this.lockedAltRowTemplate,groupFooterTemplate:this.lockedGroupFooterTemplate};if(this.lockedContent){if(r=this.lockedTable,n>0)for(t-=p(H(z(this.columns))).length,i=0,o=e.length;i<o;i++)s+=this._groupRowHtml(e[i],t,0,de,a);else s=this._rowsHtml(e,a);U(r.children("tbody"),r,s,this.options.$angular),this._syncLockedContentHeight()}},_adjustRowsHeight:function(e,t){var n,i,o,r,s=e[0].rows,a=s.length,l=t[0].rows,c=e.add(t),d=c.length,u=[];for(n=0;n<a&&l[n];n++)s[n].style.height&&(s[n].style.height=l[n].style.height="");for(n=0;n<a&&l[n];n++)i=s[n].offsetHeight,o=l[n].offsetHeight,r=0,i>o?r=i:i<o&&(r=o),u.push(r);for(n=0;n<d;n++)c[n].style.display="none";for(n=0;n<a;n++)u[n]&&(s[n].style.height=l[n].style.height=u[n]+1+"px");for(n=0;n<d;n++)c[n].style.display=""}});he.ExcelMixin&&he.ExcelMixin.extend(Vt.prototype),he.PDFMixin&&(he.PDFMixin.extend(Vt.prototype),Vt.prototype._drawPDF_autoPageBreak=function(n){function i(){u&&a!==t?(d.one("change",o),d.page(a)):(l.refresh(),o())}function o(){f.appendTo(document.body);var t=e.extend({},l.options.pdf,{_destructive:!0,progress:function(e){n.notify({page:e.page,pageNumber:e.pageNum,progress:.5+e.pageNum/e.totalPages/2,totalPages:e.totalPages})}});he.drawing.drawDOM(p,t).always(function(){f.remove()}).then(function(e){c.resolve(e)}).fail(function(e){c.reject(e)})}function r(){var e=d.page(),t=u?d.totalPages():1;s.append(h.find("tr")),e<t?d.page(e+1):(d.unbind("change",r),i())}var s,a,l=this,c=new e.Deferred,d=l.dataSource,u=l.options.pdf.allPages,h=l.wrapper.find('table[role="grid"] > tbody'),f=e("<div>").css({position:"absolute",left:-1e4,top:-1e4}),p=l.wrapper.clone().css({height:"auto",width:"auto"}).appendTo(f);return p.find(".k-grid-content").css({height:"auto",width:"auto",overflow:"visible"}),p.find('table[role="grid"]').css({height:"auto",width:"100%",overflow:"visible"}),p.find(".k-grid-pager, .k-grid-toolbar, .k-grouping-header").remove(),p.find(".k-grid-header").css({paddingRight:0}),this._initPDFProgress(n),s=p.find('table[role="grid"] > tbody').empty(),a=d.page(),u?(d.bind("change",r),d.page(1)):r(),c.promise()},Vt.prototype._drawPDF=function(n){function i(){a&&c!==t?(s.unbind("change",o),s.one("change",function(){r.resolve(l)}),s.page(c)):r.resolve(l)}function o(){d._drawPDFShadow({width:d.wrapper.width()},{avoidLinks:d.options.pdf.avoidLinks}).done(function(e){var t=s.page(),o=a?s.totalPages():1,r={page:e,pageNumber:t,progress:t/o,totalPages:o};n.notify(r),l.append(r.page),t<o?s.page(t+1):i()}).fail(function(e){r.reject(e)})}var r,s,a,l,c,d=this;return d.options.pdf.paperSize&&"auto"!=d.options.pdf.paperSize?d._drawPDF_autoPageBreak(n):(r=new e.Deferred,s=d.dataSource,a=d.options.pdf.allPages,this._initPDFProgress(n),l=new he.drawing.Group,c=s.page(),a?(s.bind("change",o),s.page(1)):o(),r.promise())},Vt.prototype._initPDFProgress=function(t){var n,i=e("<div class='k-loading-pdf-mask'><div class='k-loading-color'/></div>");i.prepend(this.wrapper.clone().css({position:"absolute",top:0,left:0})),this.wrapper.append(i),n=e("<div class='k-loading-pdf-progress'>").appendTo(i).kendoProgressBar({type:"chunk",chunkCount:10,min:0,max:1,value:0}).data("kendoProgressBar"),t.progress(function(e){n.value(e.progress)}).always(function(){he.destroy(i),i.remove()})}),fe.plugin(Vt),fe.plugin(Nt)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.listview.min",["kendo.data.min","kendo.editable.min","kendo.selectable.min"],e)}(function(){return function(e,t){var n=window.kendo,i="change",o="cancel",r="dataBound",s="dataBinding",a=n.ui.Widget,l=n.keys,c=">*:not(.k-loading-mask)",d="progress",u="error",h="k-state-focused",f="k-state-selected",p="k-edit-item",m="edit",g="remove",v="save",_="click",b=".kendoListView",w=e.proxy,y=n._activeElement,k=n.ui.progress,x=n.data.DataSource,C=n.ui.DataBoundWidget.extend({
init:function(t,i){var o=this;i=e.isArray(i)?{dataSource:i}:i,a.fn.init.call(o,t,i),i=o.options,o.wrapper=t=o.element,t[0].id&&(o._itemId=t[0].id+"_lv_active"),o._element(),o._dataSource(),o._templates(),o._navigatable(),o._selectable(),o._pageable(),o._crudHandlers(),o.options.autoBind&&o.dataSource.fetch(),n.notify(o)},events:[i,o,s,r,m,g,v],options:{name:"ListView",autoBind:!0,selectable:!1,navigatable:!1,template:"",altTemplate:"",editTemplate:""},setOptions:function(e){a.fn.setOptions.call(this,e),this._templates(),this.selectable&&(this.selectable.destroy(),this.selectable=null),this._selectable()},_templates:function(){var e=this.options;this.template=n.template(e.template||""),this.altTemplate=n.template(e.altTemplate||e.template),this.editTemplate=n.template(e.editTemplate||"")},_item:function(e){return this.element.children()[e]()},items:function(){return this.element.children()},dataItem:function(t){var i=n.attr("uid"),o=e(t).closest("["+i+"]").attr(i);return this.dataSource.getByUid(o)},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this.options.autoBind&&e.fetch()},_unbindDataSource:function(){var e=this;e.dataSource.unbind(i,e._refreshHandler).unbind(d,e._progressHandler).unbind(u,e._errorHandler)},_dataSource:function(){var e=this;e.dataSource&&e._refreshHandler?e._unbindDataSource():(e._refreshHandler=w(e.refresh,e),e._progressHandler=w(e._progress,e),e._errorHandler=w(e._error,e)),e.dataSource=x.create(e.options.dataSource).bind(i,e._refreshHandler).bind(d,e._progressHandler).bind(u,e._errorHandler)},_progress:function(){k(this.element,!0)},_error:function(){k(this.element,!1)},_element:function(){this.element.addClass("k-widget k-listview").attr("role","listbox")},refresh:function(e){var i,o,a,l,c,d=this,u=d.dataSource.view(),h="",f=d.template,p=d.altTemplate,m=y();if(e=e||{},"itemchange"===e.action)return d._hasBindingTarget()||d.editable||(i=e.items[0],a=d.items().filter("["+n.attr("uid")+"="+i.uid+"]"),a.length>0&&(l=a.index(),d.angular("cleanup",function(){return{elements:[a]}}),a.replaceWith(f(i)),a=d.items().eq(l),a.attr(n.attr("uid"),i.uid),d.angular("compile",function(){return{elements:[a],data:[{dataItem:i}]}}),d.trigger("itemChange",{item:a,data:i}))),t;if(!d.trigger(s,{action:e.action||"rebind",items:e.items,index:e.index})){for(d._angularItems("cleanup"),d._destroyEditable(),l=0,c=u.length;l<c;l++)h+=l%2?p(u[l]):f(u[l]);for(d.element.html(h),o=d.items(),l=0,c=u.length;l<c;l++)o.eq(l).attr(n.attr("uid"),u[l].uid).attr("role","option").attr("aria-selected","false");d.element[0]===m&&d.options.navigatable&&d.current(o.eq(0)),d._angularItems("compile"),d.trigger(r,{action:e.action||"rebind",items:e.items,index:e.index})}},_pageable:function(){var t,i,o=this,r=o.options.pageable;e.isPlainObject(r)&&(i=r.pagerId,t=e.extend({},r,{dataSource:o.dataSource,pagerId:null}),o.pager=new n.ui.Pager(e("#"+i),t))},_selectable:function(){var e,o,r=this,s=r.options.selectable,a=r.options.navigatable;s&&(e=n.ui.Selectable.parseOptions(s).multiple,r.selectable=new n.ui.Selectable(r.element,{aria:!0,multiple:e,filter:c,change:function(){r.trigger(i)}}),a&&r.element.on("keydown"+b,function(n){if(n.keyCode===l.SPACEBAR){if(o=r.current(),n.target==n.currentTarget&&n.preventDefault(),e)if(n.ctrlKey){if(o&&o.hasClass(f))return o.removeClass(f),t}else r.selectable.clear();else r.selectable.clear();r.selectable.value(o)}}))},current:function(e){var n=this,i=n.element,o=n._current,r=n._itemId;return e===t?o:(o&&o[0]&&(o[0].id===r&&o.removeAttr("id"),o.removeClass(h),i.removeAttr("aria-activedescendant")),e&&e[0]&&(r=e[0].id||r,n._scrollTo(e[0]),i.attr("aria-activedescendant",r),e.addClass(h).attr("id",r)),n._current=e,t)},_scrollTo:function(t){var n,i,o=this,r=!1,s="scroll";"auto"==o.wrapper.css("overflow")||o.wrapper.css("overflow")==s?n=o.wrapper[0]:(n=window,r=!0),i=function(i,o){var a=r?e(t).offset()[i.toLowerCase()]:t["offset"+i],l=t["client"+o],c=e(n)[s+i](),d=e(n)[o.toLowerCase()]();a+l>c+d?e(n)[s+i](a+l-d):a<c&&e(n)[s+i](a)},i("Top","Height"),i("Left","Width")},_navigatable:function(){var t=this,i=t.options.navigatable,o=t.element,r=function(n){t.current(e(n.currentTarget)),e(n.target).is(":button,a,:input,a>.k-icon,textarea")||o.focus()};i&&(t._tabindex(),o.on("focus"+b,function(){var e=t._current;e&&e.is(":visible")||(e=t._item("first")),t.current(e)}).on("focusout"+b,function(){t._current&&t._current.removeClass(h)}).on("keydown"+b,function(i){var r,s,a=i.keyCode,c=t.current(),d=e(i.target),u=!d.is(":button,textarea,a,a>.t-icon,input"),h=d.is(":text,:password"),f=n.preventDefault,m=o.find("."+p),g=y();if(!(!u&&!h&&l.ESC!=a||h&&l.ESC!=a&&l.ENTER!=a))if(l.UP===a||l.LEFT===a)c&&(c=c.prev()),t.current(c&&c[0]?c:t._item("last")),f(i);else if(l.DOWN===a||l.RIGHT===a)c&&(c=c.next()),t.current(c&&c[0]?c:t._item("first")),f(i);else if(l.PAGEUP===a)t.current(null),t.dataSource.page(t.dataSource.page()-1),f(i);else if(l.PAGEDOWN===a)t.current(null),t.dataSource.page(t.dataSource.page()+1),f(i);else if(l.HOME===a)t.current(t._item("first")),f(i);else if(l.END===a)t.current(t._item("last")),f(i);else if(l.ENTER===a)0!==m.length&&(u||h)?(r=t.items().index(m),g&&g.blur(),t.save(),s=function(){t.element.trigger("focus"),t.current(t.items().eq(r))},t.one("dataBound",s)):""!==t.options.editTemplate&&t.edit(c);else if(l.ESC===a){if(m=o.find("."+p),0===m.length)return;r=t.items().index(m),t.cancel(),t.element.trigger("focus"),t.current(t.items().eq(r))}}),o.on("mousedown"+b+" touchstart"+b,c,w(r,t)))},clearSelection:function(){var e=this;e.selectable.clear(),e.trigger(i)},select:function(n){var i=this,o=i.selectable;return n=e(n),n.length?(o.options.multiple||(o.clear(),n=n.first()),o.value(n),t):o.value()},_destroyEditable:function(){var e=this;e.editable&&(e.editable.destroy(),delete e.editable)},_modelFromElement:function(e){var t=e.attr(n.attr("uid"));return this.dataSource.getByUid(t)},_closeEditable:function(){var e,t,i,o=this,r=o.editable,s=o.template;return r&&(r.element.index()%2&&(s=o.altTemplate),o.angular("cleanup",function(){return{elements:[r.element]}}),e=o._modelFromElement(r.element),o._destroyEditable(),i=r.element.index(),r.element.replaceWith(s(e)),t=o.items().eq(i),t.attr(n.attr("uid"),e.uid),o._hasBindingTarget()&&n.bind(t,e),o.angular("compile",function(){return{elements:[t],data:[{dataItem:e}]}})),!0},edit:function(e){var t,i,o=this,r=o._modelFromElement(e),s=r.uid;o.cancel(),e=o.items().filter("["+n.attr("uid")+"="+s+"]"),i=e.index(),e.replaceWith(o.editTemplate(r)),t=o.items().eq(i).addClass(p).attr(n.attr("uid"),r.uid),o.editable=t.kendoEditable({model:r,clearContainer:!1,errorTemplate:!1,target:o}).data("kendoEditable"),o.trigger(m,{model:r,item:t})},save:function(){var e,t,n=this,i=n.editable;i&&(t=i.element,e=n._modelFromElement(t),i.end()&&!n.trigger(v,{model:e,item:t})&&(n._closeEditable(),n.dataSource.sync()))},remove:function(e){var t=this,n=t.dataSource,i=t._modelFromElement(e);t.editable&&(n.cancelChanges(t._modelFromElement(t.editable.element)),t._closeEditable()),t.trigger(g,{model:i,item:e})||(e.hide(),n.remove(i),n.sync())},add:function(){var e,t=this,n=t.dataSource,i=n.indexOf((n.view()||[])[0]);i<0&&(i=0),t.cancel(),e=n.insert(i,{}),t.edit(t.element.find("[data-uid='"+e.uid+"']"))},cancel:function(){var e,t,n=this,i=n.dataSource;n.editable&&(e=n.editable.element,t=n._modelFromElement(e),n.trigger(o,{model:t,container:e})||(i.cancelChanges(t),n._closeEditable()))},_crudHandlers:function(){var t=this,i=_+b;t.element.on(i,".k-edit-button",function(i){var o=e(this).closest("["+n.attr("uid")+"]");t.edit(o),i.preventDefault()}),t.element.on(i,".k-delete-button",function(i){var o=e(this).closest("["+n.attr("uid")+"]");t.remove(o),i.preventDefault()}),t.element.on(i,".k-update-button",function(e){t.save(),e.preventDefault()}),t.element.on(i,".k-cancel-button",function(e){t.cancel(),e.preventDefault()})},destroy:function(){var e=this;a.fn.destroy.call(e),e._unbindDataSource(),e._destroyEditable(),e.element.off(b),e.pager&&e.pager.destroy(),n.destroy(e.element)}});n.ui.plugin(C)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.listbox.min",["kendo.draganddrop.min","kendo.data.min","kendo.selectable.min"],e)}(function(){return function(e,t){function n(t){var n=e.map(t,function(t){return e(t).index()});return n}function i(e){return t===e}function o(e){return e.clone().removeClass(ue).addClass(_.format("{0} {1} {2}",H,Y,q)).width(e.width())}function r(){return e("<li>").addClass(j)}var s,a,l,c,d,u,h,f,p,m,g,v,_=window.kendo,b=_.attr,w=_.data,y=_.keys,k=_.template,x=_.ui.Widget,C=w.DataSource,S=_.ui.Selectable,T=_.ui.DataBoundWidget,D=_.Class,A=e.extend,E=e.noop,M=e.proxy,I="-",R=".",F=" ",z="#",P="kendoListBox",B=R+P,L="k-state-disabled",H="k-state-selected",N=".k-item:not(.k-state-disabled)",O=".k-list:not(.k-state-disabled) >"+N,V="k-listbox-toolbar",U="li > a.k-button:not(.k-state-disabled)",W="k-state-focused",q="k-drag-clue",j="k-drop-hint",G="k-reset k-list",$=".k-reset.k-list",Y="k-reset",K="click"+B,Q="keydown"+B,X="blur"+B,Z=_._outerWidth,J=_._outerHeight,ee="change",te="dataBound",ne="add",ie="remove",oe="reorder",re="moveUp",se="moveDown",ae="transferTo",le="transferFrom",ce="transferAllTo",de="transferAllFrom",ue="k-ghost",he="uid",fe="tabindex",pe="command",me=-1,ge=1,ve="dragstart",_e="drag",be="drop",we="dragend",ye="ul.k-reset.k-list>li.k-item",ke="right",xe="bottom",Ce=[V+I+"left",V+I+ke,V+I+"top",V+I+xe],Se=T.extend({init:function(e,t){var n=this;x.fn.init.call(n,e,t),n._wrapper(),n._list(),e=n.element.attr("multiple","multiple").hide(),e[0]&&!n.options.dataSource&&(n.options.dataTextField=n.options.dataTextField||"text",n.options.dataValueField=n.options.dataValueField||"value"),n._templates(),n._selectable(),n._dataSource(),n._createToolbar(),n._createDraggable(),n._createNavigatable()},destroy:function(){var e=this;T.fn.destroy.call(e),isNaN(e._listTabIndex)||(e._getList().off(),e._listTabIndex=null),e._unbindDataSource(),e._destroySelectable(),e._destroyToolbar(),e.wrapper.off(B),e._target&&(e._target=null),e._draggable&&(e._draggable.destroy(),e.placeholder=null),_.destroy(e.element)},events:[ee,te,ne,ie,oe,ve,_e,be,we],options:{name:"ListBox",autoBind:!0,template:"",dataTextField:"",dataValueField:"",selectable:"single",draggable:null,dropSources:[],connectWith:"",navigatable:!0,toolbar:{position:ke,tools:[]},messages:{tools:{remove:"Delete",moveUp:"Move Up",moveDown:"Move Down",transferTo:"Transfer To",transferFrom:"Transfer From",transferAllTo:"Transfer All To",transferAllFrom:"Transfer All From"}}},add:function(e){var t,n=this,i=e&&e.length?e:[e],o=i.length;for(n._unbindDataSource(),t=0;t<o;t++)n._addItem(i[t]);n._bindDataSource(),n._syncElement()},_addItem:function(t){var n=this,i=n.templates.itemTemplate({item:t,r:n.templates.itemContent});e(i).attr(b(he),t.uid).appendTo(n._getList()),"string"==typeof t?n.dataSource._data.push(t):n.dataSource.add(t)},_addItemAt:function(t,n){var i=this,o=i.templates.itemTemplate({item:t,r:i.templates.itemContent});i._unbindDataSource(),"string"==typeof t?(i._insertElementAt(o,n),i.dataSource._data.push(t)):(i._insertElementAt(e(o).attr(b(he),t.uid),n),i.dataSource.add(t)),i._bindDataSource(),i._syncElement()},_insertElementAt:function(t,n){var i=this,o=i._getList();n>0?e(t).insertAfter(o.children().eq(n-1)):e(o).prepend(t)},_createNavigatable:function(){var e=this,t=e.options;t.navigatable&&e._getList().on(K,N,M(e._click,e)).on(Q,M(e._keyDown,e)).on(X,M(e._blur,e))},_getTabIndex:function(){var e,t=this;return isNaN(t._listTabIndex)?(e=t.element.attr(fe),t._listTabIndex=isNaN(e)?0:e,t.element.removeAttr(fe),t._listTabIndex):t._listTabIndex},_blur:function(){this._target&&(this._target.removeClass(W),this._getList().removeAttr("aria-activedescendant")),this._target=null},_click:function(t){var n=this,i=e(t.currentTarget),o=n._target;o&&o.removeClass(W),n._target=i,i.addClass(W),n._getList().attr("aria-activedescendant",i.attr("id")),n._getList()[0]!==_._activeElement()&&n.focus()},_getNavigatableItem:function(e){var t,n=this;return t=n._target?n._target:n.items().filter(N).first(),e===y.UP&&n._target&&(t=n._target.prevAll(N).first()),e===y.DOWN&&n._target&&(t=n._target.nextAll(N).first()),t.length?t:null},_scrollIntoView:function(e){var t,n,i,o,r;e&&(e[0]&&(e=e[0]),t=this._getList().parent()[0],n=e.offsetTop,i=t.scrollTop,o=t.clientHeight,r=n+e.offsetHeight,i>n?i=n:r>i+o&&(i=r-o),t.scrollTop=i)},_keyDown:function(e){var n,i=this,o=e.keyCode,r=i._getNavigatableItem(o);if(i._target&&i._target.removeClass(W),(!e.shiftKey||e.ctrlKey||o!==y.DOWN&&o!==y.UP)&&(i._shiftSelecting=!1),o==y.DELETE)i._executeCommand(ie),i._target&&(i._target.removeClass(W),i._getList().removeAttr("aria-activedescendant"),i._target=null),n=!0;else if(o===y.DOWN||o===y.UP){if(!r)return e.preventDefault(),t;if(e.shiftKey&&!e.ctrlKey)i._shiftSelecting||(i.clearSelection(),i._shiftSelecting=!0),i._target&&r.hasClass("k-state-selected")?(i._target.removeClass(H),i.trigger(ee)):i.select("single"==i.options.selectable?r:r.add(i._target));else{if(e.shiftKey&&e.ctrlKey)return i._executeCommand(o===y.DOWN?se:re),i._scrollIntoView(i._target),e.preventDefault(),t;e.shiftKey||e.ctrlKey||("multiple"===i.options.selectable&&i.clearSelection(),i.select(r))}i._target=r,i._target?(i._target.addClass(W),i._scrollIntoView(i._target),i._getList().attr("aria-activedescendant",i._target.attr("id"))):i._getList().removeAttr("aria-activedescendant"),n=!0}else o==y.SPACEBAR?(e.ctrlKey&&i._target?i._target.hasClass(H)?(i._target.removeClass(H),i.trigger(ee)):i.select(i._target):(i.clearSelection(),i.select(i._target)),n=!0):e.ctrlKey&&o==y.RIGHT?(i._executeCommand(e.shiftKey?ce:ae),i._target=i.select().length?i.select():null,n=!0):e.ctrlKey&&o==y.LEFT&&(i._executeCommand(e.shiftKey?de:le),n=!0);n&&e.preventDefault()},focus:function(){this._getList().focus()},_createDraggable:function(){var t,n=this,i=n.options.draggable;if(i){if(t=i.hint,!n.options.selectable)throw Error("Dragging requires selection to be enabled");t||(t=o),n._draggable=new _.ui.Draggable(n.wrapper,{filter:i.filter?i.filter:ye,hint:_.isFunction(t)?t:e(t),dragstart:M(n._dragstart,n),dragcancel:M(n._clear,n),drag:M(n._drag,n),dragend:M(n._dragend,n)})}},_dragstart:function(n){var i=this,o=i.draggedElement=n.currentTarget,s=i.options.draggable.placeholder,a=i.dataItem(o),l={dataItems:a,items:e(o),draggableEvent:n};return i.options.draggable.enabled===!1?(n.preventDefault(),t):(s||(s=r),i.placeholder=e(_.isFunction(s)?s.call(i,o):s),o.is(R+L)?n.preventDefault():i.trigger(ve,l)?n.preventDefault():(i.clearSelection(),i.select(o),o.addClass(ue)),t)},_clear:function(){this.draggedElement.removeClass(ue),this.placeholder.remove()},_findElementUnderCursor:function(t){var n=_.elementUnderCursor(t),i=t.sender;return(e.contains(i.hint[0],n)||i.hint[0]===n)&&(i.hint.hide(),n=_.elementUnderCursor(t),i.hint.show()),n},_findTarget:function(t){var n,i,o=this,r=o._findElementUnderCursor(t),s=e(r),a=o._getList();return e.contains(a[0],r)?(n=o.items(),r=s.is("li")?r:s.closest("li")[0],i=n.filter(r)[0]||n.has(r)[0],i?(i=e(i),i.hasClass(L)?null:{element:i,listBox:o}):null):a[0]==r||a.parent()[0]==r?{element:e(a),appendToBottom:!0,listBox:o}:o._searchConnectedListBox(s)},_getElementCenter:function(e){var t=e.length?_.getOffset(e):null;return t&&(t.top+=J(e)/2,t.left+=Z(e)/2),t},_searchConnectedListBox:function(t){var n,i,o,r,s=t;return r=t.hasClass("k-list-scroller k-selectable")?t:t.closest(".k-list-scroller.k-selectable"),r.length?(n=r.parent().find("[data-role='listbox']").getKendoListBox(),n&&e.inArray(this.element[0].id,n.options.dropSources)!==-1?(i=n.items(),t=t.is("li")?t[0]:t.closest("li")[0],o=i.filter(t)[0]||i.has(t)[0],o?(o=e(o),o.hasClass(L)?null:{element:o,listBox:n}):!i.length||s.hasClass("k-list-scroller k-selectable")||s.hasClass("k-reset k-list")?{element:n._getList(),listBox:n,appendToBottom:!0}:null):null):null},_drag:function(n){var i,o,r,s=this,a=s.draggedElement,l=s._findTarget(n),c={left:n.x.location,top:n.y.location},d=s.dataItem(a),u={dataItems:[d],items:e(a),draggableEvent:n};if(s.trigger(_e,u))return n.preventDefault(),t;if(l){if(i=this._getElementCenter(l.element),o={left:Math.round(c.left-i.left),top:Math.round(c.top-i.top)},l.appendToBottom)return s._movePlaceholder(l,null,a),t;o.top<0?r="prev":o.top>0&&(r="next"),r&&l.element[0]!=s.placeholder[0]&&s._movePlaceholder(l,r,a)}else s.placeholder.parent().length&&s.placeholder.remove()},_movePlaceholder:function(t,n,i){var o=this,s=o.placeholder,a=t.listBox.options.draggable;s.parent().length&&(o.placeholder.remove(),o.placeholder=e(a&&a.placeholder?_.isFunction(a.placeholder)?a.placeholder.call(o,i):a.placeholder:r.call(o,i))),n?"prev"===n?t.element.before(o.placeholder):"next"===n&&t.element.after(o.placeholder):t.element.append(o.placeholder)},_dragend:function(n){var i=this,o=i.draggedElement,r=i.items(),s=r.not(i.draggedElement).index(i.placeholder),a=r.not(i.placeholder).index(i.draggedElement),l=i.dataItem(o),c={dataItems:[l],items:e(o)},d=i.placeholder.closest(".k-widget.k-listbox").find("[data-role='listbox']").getKendoListBox();return i.trigger(be,A({},c,{draggableEvent:n}))?(n.preventDefault(),this._clear(),t):(s>=0?s===a||i.trigger(oe,A({},c,{offset:s-a}))||(o.removeClass(ue),i.reorder(o,s)):d&&(i.trigger(ie,c)||i.remove(e(o)),d.trigger(ne,c)||d._addItemAt(l,d.items().index(i.placeholder))),i._clear(),i._draggable.dropped=!0,i.trigger(we,A({},c,{draggableEvent:n})),t)},reorder:function(t,n){var i=this,o=i.dataSource,r=i.dataItem(t),s=o.at(n),a=i.items()[n],l=e(t);r&&a&&s&&(i._removeElement(l),i._insertElementAt(l,n),i._updateToolbar())},remove:function(t){var n,i=this,o=i._getItems(t),r=o.length;for(i._unbindDataSource(),n=0;n<r;n++)i._removeItem(e(o[n]));i._bindDataSource(),i._syncElement(),i._updateToolbar(),i._updateAllToolbars()},_removeItem:function(e){var t,n,i=this,o=i.dataSource,r=i.dataItem(e);if(r&&o){if("string"==typeof r){for(t=o._data,n=0;n<t.length;n++)if(r===t[n]){t[n]=t[t.length-1],t.pop();break}}else o.remove(r);i._removeElement(e)}},_removeElement:function(t){_.destroy(t),e(t).off().remove()},dataItem:function(t){var n=b(he),i=e(t).attr(n)||e(t).closest("["+n+"]").attr(n);return i?this.dataSource.getByUid(i):e(t).html()},_dataItems:function(t){var n,i=[],o=e(t),r=o.length;for(n=0;n<r;n++)i.push(this.dataItem(o.eq(n)));return i},items:function(){var e=this._getList();return e.children()},select:function(e){var t,n=this,o=n.selectable;return i(e)?o.value():(t=n.items().filter(e).filter(O),o.options.multiple||(o.clear(),t=t.first()),o.value(t))},clearSelection:function(){var e=this,t=e.selectable;t&&t.clear()},enable:function(t,n){var o,r=this,s=!!i(n)||!!n,a=r._getItems(t),l=a.length;for(o=0;o<l;o++)r._enableItem(e(a[o]),s);r._updateAllToolbars()},_enableItem:function(t,n){var i=this,o=i.dataItem(t);o&&(n?e(t).removeClass(L):e(t).addClass(L).removeClass(H))},setDataSource:function(e){var t=this;t.options.dataSource=e,t._dataSource()},_dataSource:function(){var t=this,n=t.options,i=n.dataSource||{};i=e.isArray(i)?{data:i}:i,i.select=t.element,i.fields=[{field:n.dataTextField},{field:n.dataValueField}],t._unbindDataSource(),t.dataSource=C.create(i),t._bindDataSource(),t.options.autoBind&&t.dataSource.fetch()},_bindDataSource:function(){var e=this,t=e.dataSource;e._dataChangeHandler=M(e.refresh,e),t&&t.bind(ee,e._dataChangeHandler)},_unbindDataSource:function(){var e=this,t=e.dataSource;t&&t.unbind(ee,e._dataChangeHandler)},_wrapper:function(){var t=this,n=t.element,i=n.parent("div.k-listbox");i[0]||(i=n.wrap('<div class="k-widget k-listbox" deselectable="on" />').parent(),i[0].style.cssText=n[0].style.cssText,i[0].title=n[0].title,e('<div class="k-list-scroller" />').insertBefore(n)),t.wrapper=i.addClass(n[0].className).css("display",""),t._innerWrapper=e(i[0].firstChild)},_list:function(){var t=this;e("<ul class='"+G+"' role='listbox'></ul>").appendTo(t._innerWrapper),t.options.navigatable&&t._getList().attr(fe,t._getTabIndex())},_templates:function(){var e,t=this,n=this.options;e=n.template&&"string"==typeof n.template?_.template(n.template):n.template?n.template:_.template("${"+_.expr(n.dataTextField,"data")+"}",{useWithBlock:!1}),t.templates={itemTemplate:_.template("# var item = data.item, r = data.r; # <li class='k-item' role='option' aria-selected='false'>#=r(item)#</li>",{useWithBlock:!1}),itemContent:e,toolbar:"<div class='"+V+"'></div>"}},refresh:function(){var e,t=this,n=t.dataSource.view(),i=t.templates.itemTemplate,o="";for(e=0;e<n.length;e++)o+=i({item:n[e],r:t.templates.itemContent});t._getList().html(o),t._setItemIds(),t._createToolbar(),t._syncElement(),t._updateToolbar(),t._updateAllToolbars(),t.trigger(te)},_syncElement:function(){var e,t="",n=this.dataSource.view();for(e=0;e<n.length;e++)t+=this._option(n[e][this.options.dataValueField]||n[e],n[e][this.options.dataTextField]||n[e],!0);this.element.html(t)},_option:function(e,n){var i="<option";return e!==t&&(e+="",e.indexOf('"')!==-1&&(e=e.replace(/"/g,"&quot;")),i+=' value="'+e+'"'),i+=" selected>",n!==t&&(i+=_.htmlEncode(n)),i+="</option>"},_setItemIds:function(){var e,t=this,n=t.items(),i=t.dataSource.view(),o=i.length;for(e=0;e<o;e++)n.eq(e).attr(b(he),i[e].uid).attr("id",i[e].uid)},_selectable:function(){var e=this,t=e.options.selectable,n=S.parseOptions(t);n.multiple&&e.element.attr("aria-multiselectable","true"),e.selectable=new S(e._innerWrapper,{aria:!0,multiple:n.multiple,filter:N,change:M(e._onSelect,e)})},_onSelect:function(){var e=this;e._updateToolbar(),e._updateAllToolbars(),e.trigger(ee)},_destroySelectable:function(){var e=this;e.selectable&&(e.selectable.destroy(),e.selectable=null)},_getList:function(){return this.wrapper.find($)},_getItems:function(e){return this.items().filter(e)},_createToolbar:function(){var t,n=this,i=n.options.toolbar,o=i.position||ke,r=o===xe?"insertAfter":"insertBefore",s=i.tools||[],a=n.options.messages;n._destroyToolbar(),n.wrapper.removeClass(Ce.join(F)),s.length&&s.length>0&&(t=e(n.templates.toolbar)[r](n._innerWrapper),n.toolbar=new v(t,A({},i,{listBox:n,messages:a})),n.wrapper.addClass(V+I+o))},_destroyToolbar:function(){var e=this;e.toolbar&&(e.toolbar.destroy(),e.toolbar=null)},_executeCommand:function(e){var t=this,n=s.current.create(e,{listBox:t});n&&(n.execute(),t._updateToolbar(),t._updateAllToolbars())},_updateToolbar:function(){var e=this.toolbar;e&&e._updateToolStates()},_updateAllToolbars:function(){var t,n,i=e("select[data-role='listbox']"),o=i.length;for(n=0;n<o;n++)t=e(i[n]).data(P),t&&t._updateToolbar()}});_.ui.plugin(Se),s=D.extend({init:function(){this._commands=[]},register:function(e,t){this._commands.push({commandName:e,commandType:t})},create:function(e,t){var n,i,o,r=this._commands,s=r.length,a=e?e.toLowerCase():"";for(o=0;o<s;o++)if(i=r[o],i.commandName.toLowerCase()===a){n=i;break}if(n)return new n.commandType(t)}}),s.current=new s,a=D.extend({init:function(e){var t=this;t.options=A({},t.options,e),t.listBox=t.options.listBox},options:{listBox:null},getItems:function(){return e(this.listBox.select())},execute:E,canExecute:E}),l=a.extend({execute:function(){var e=this,t=e.listBox,n=e.getItems();t.trigger(ie,{dataItems:t._dataItems(n),items:n})||t.remove(n)},canExecute:function(){return this.listBox.select().length>0}}),s.current.register(ie,l),c=a.extend({execute:function(){var e=this;e.canExecute()&&e.moveItems()},canExecute:E,moveItems:function(){var t,i=this,o=i.listBox,r=i.options,s=i.getItems(),a=r.offset,l=n(s),c=e.makeArray(s.sort(i.itemComparer)),d=r.moveAction;if(!o.trigger(oe,{dataItems:o._dataItems(c),items:e(c),offset:a}))for(;c.length>0&&l.length>0;)t=c[d](),o.reorder(t,l[d]()+a)},options:{offset:0,moveAction:"pop"},itemComparer:function(t,n){var i=e(t).index(),o=e(n).index();return i===o?0:i>o?1:-1}}),d=c.extend({options:{offset:me,moveAction:"shift"},canExecute:function(){var e=this.getItems(),t=n(e);return t.length>0&&t[0]>0}}),s.current.register(re,d),u=c.extend({options:{offset:ge,moveAction:"pop"},canExecute:function(){var t=this,i=t.getItems(),o=n(i);return o.length>0&&e(o).last()[0]<t.listBox.items().length-1}}),s.current.register(se,u),h=a.extend({options:{filter:N},execute:function(){var e=this,t=e.getSourceListBox(),n=e.getItems().filter(e.options.filter),i=t?t._dataItems(n):[],o=e.getDestinationListBox(),r=e.getUpdatedSelection(n);o&&n.length>0&&(o.trigger(ne,{dataItems:i,items:n})||o.add(i),t.trigger(ie,{dataItems:i,items:n})||(t.remove(n),e.updateSelection(r)))},getUpdatedSelection:function(t){var n=this,i=n.options.filter,o=n.getSourceListBox(),r=o?o.items().filter(i).last():null,s=e(t).filter(r).length>0,a=s?e(t).prevAll(i)[0]:e(t).nextAll(i)[0];return 1===e(t).length&&a?a:null},updateSelection:function(t){var n=this.getSourceListBox();n&&t&&(e(n.select(e(t))),n._scrollIntoView(t))},getSourceListBox:E,getDestinationListBox:E}),f=h.extend({canExecute:function(){var e=this.getSourceListBox();return!!e&&e.select().length>0},getSourceListBox:function(){return this.listBox},getDestinationListBox:function(){var t=this.getSourceListBox();return t&&t.options.connectWith?e(z+t.options.connectWith).data(P):null},getItems:function(){var t=this.getSourceListBox();return t?e(t.select()):e()}}),s.current.register(ae,f),p=h.extend({canExecute:function(){var e=this.getSourceListBox();return!!e&&e.select().length>0},getSourceListBox:function(){var t=this.getDestinationListBox();return t&&t.options.connectWith?e(z+t.options.connectWith).data(P):null},getDestinationListBox:function(){return this.listBox},getItems:function(){var t=this.getSourceListBox();return t?e(t.select()):e()}}),s.current.register(le,p),m=f.extend({canExecute:function(){var e=this.getSourceListBox();return!!e&&e.items().filter(N).length>0},getItems:function(){var t=this.getSourceListBox();return t?t.items():e()},getUpdatedSelection:E,updateSelection:E}),s.current.register(ce,m),g=p.extend({canExecute:function(){var e=this.getSourceListBox();return!!e&&e.items().filter(N).length>0},getItems:function(){var t=this.getSourceListBox();return t?t.items():e()},getUpdatedSelection:E,updateSelection:E}),s.current.register(de,g),v=D.extend({init:function(t,n){var i=this;i.element=e(t).addClass(V),i.options=A({},i.options,n),i.listBox=i.options.listBox,i._initTemplates(),i._createTools(),i._updateToolStates(),i._attachEventHandlers()},destroy:function(){var e=this;e._detachEventHandlers(),_.destroy(e.element),e.element.remove(),e.element=null},options:{position:ke,tools:[]},_initTemplates:function(){this.templates={tool:k("<li><a href='\\\\#' class='k-button k-button-icon k-tool' data-command='#= command #' title='#= text #' aria-label='#= text #' role='button'><span class='k-icon #= iconClass #'></span></a></li>")}},_createTools:function(){var t,n,i=this,o=i.options.tools,r=o.length,s=i.options.messages.tools,a=i._createToolList();for(n=0;n<r;n++)t=A({},v.defaultTools[o[n]],{text:s[o[n]]}),t&&a.append(e(i.templates.tool(t)));i.element.append(a)},_createToolList:function(){return e("<ul class='k-reset' />")},_attachEventHandlers:function(){var e=this;e.element.on(K,U,M(e._onToolClick,e))},_detachEventHandlers:function(){this.element.off(B).find("*").off(B)},_onToolClick:function(t){t.preventDefault(),this._executeToolCommand(e(t.currentTarget).data(pe))},_executeToolCommand:function(e){var t=this,n=t.listBox;n&&n._executeCommand(e)},_updateToolStates:function(){var e,t=this,n=t.options.tools,i=n.length;for(e=0;e<i;e++)t._updateToolState(n[e])},_updateToolState:function(t){var n=this,i=s.current.create(t,{listBox:n.listBox}),o=n.element.find("[data-command='"+t+"']")[0];o&&i&&i.canExecute&&(i.canExecute()?e(o).removeClass(L):e(o).addClass(L))}}),v.defaultTools={remove:{command:ie,iconClass:"k-i-x"},moveUp:{command:re,iconClass:"k-i-arrow-60-up"},moveDown:{command:se,iconClass:"k-i-arrow-60-down"},transferTo:{command:ae,iconClass:"k-i-arrow-60-right"},transferFrom:{command:le,iconClass:"k-i-arrow-60-left"},transferAllTo:{command:ce,iconClass:"k-i-arrow-double-60-right"},transferAllFrom:{command:de,iconClass:"k-i-arrow-double-60-left"}},A(Se,{ToolBar:v})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.upload.min",["kendo.core.min"],e)}(function(){return function(e,t){function n(t){return e.map(i(t),function(e){return e.name}).join(", ")}function i(e){var t=e[0];return t.files?o(t.files):[{name:a(t.value),extension:s(t.value),size:null}]}function o(t){return e.map(t,function(e){return r(e)})}function r(e){var t=e.name||e.fileName;return{name:C.htmlEncode(t),extension:s(t),size:"number"==typeof e.size?e.size:e.fileSize,rawFile:e}}function s(e){var t=e.match(A);return t?t[0]:""}function a(e){var t=e.lastIndexOf("\\");return t!=-1?e.substr(t+1):e}function l(t,n){var i=C.guid();return e.map(t,function(e){return e.uid=n?C.guid():i,e})}function c(e,t){var n,i=d(t.allowedExtensions),o=t.maxFileSize,r=t.minFileSize;for(n=0;n<e.length;n++)u(e[n],i),h(e[n],r,o)}function d(t){var n=e.map(t,function(e){var t="."===e.substring(0,1)?e:"."+e;return t.toLowerCase()});return n}function u(t,n){n.length>0&&n.indexOf(t.extension.toLowerCase())<0&&(t.validationErrors=t.validationErrors||[],e.inArray(q,t.validationErrors)===-1&&t.validationErrors.push(q))}function h(t,n,i){0!==n&&t.size<n&&(t.validationErrors=t.validationErrors||[],e.inArray(W,t.validationErrors)===-1&&t.validationErrors.push(W)),0!==i&&t.size>i&&(t.validationErrors=t.validationErrors||[],e.inArray(U,t.validationErrors)===-1&&t.validationErrors.push(U))}function f(e){var t,n=0;if("number"!=typeof e[0].size)return"";for(t=0;t<e.length;t++)e[t].size&&(n+=e[t].size);return n/=1024,n<1024?n.toFixed(2)+" KB":(n/1024).toFixed(2)+" MB"}function p(t){return!t.multiple&&e(".k-file",t.wrapper).length>1}function m(n,i,o,r){var s,a;return i._supportsRemove()?(s=n.data("fileNames"),a=e.map(s,function(e){return e.name}),r===!1?(i._removeFileEntry(n),t):(i._submitRemove(a,o,function(e,t,o){var r=i.trigger(R,{operation:"remove",files:s,response:e,XMLHttpRequest:o});r||i._removeFileEntry(n)},function(e){p(i)&&i._removeFileEntry(n),i.trigger(F,{operation:"remove",files:s,XMLHttpRequest:e}),D("Server response: "+e.responseText)}),t)):(!p(i)&&r||i._removeFileEntry(n),t)}function g(t,n,i){var o=!1,r="";try{r=e.parseJSON(v(t)),o=!0}catch(s){i()}o&&n(r)}function v(e){return t!==e&&""!==e||(e="{}"),e}function _(e){e.stopPropagation(),e.preventDefault()}function b(e,t,n,i){var o,r;e.on("dragenter"+t,function(e){n(e),r=new Date,o||(o=setInterval(function(){var e=new Date-r;e>100&&(i(),clearInterval(o),o=null)},100))}).on("dragover"+t,function(){r=new Date})}function w(e){return e.is(".k-file-progress, .k-file-success, .k-file-error")}function y(t){return e(t.target).closest(".k-file")}var k,x,C=window.kendo,S=C.ui.Widget,T=C.antiForgeryTokens,D=C.logToConsole,A=/\.([^\.]+)$/,E=".kendoUpload",M="select",I="upload",R="success",F="error",z="complete",P="cancel",B="clear",L="pause",H="resume",N="progress",O="remove",V="validationErrors",U="invalidMaxFileSize",W="invalidMinFileSize",q="invalidFileExtension",j=1e3,G=2e3,$={loading:"k-i-loading",warning:"k-i-warning",success:"k-i-check"},Y=S.extend({init:function(t,n){var i,o,r,s=this;S.fn.init.call(s,t,n),s.name=t.name,s.multiple=s.options.multiple,s.directory=s.options.directory,s.localization=s.options.localization,i=s.element,s.wrapper=i.closest(".k-upload"),0===s.wrapper.length&&(s.wrapper=s._wrapInput(i)),s._activeInput(i),s.toggle(s.options.enabled),o=s._ns=E+"-"+C.guid(),i.closest("form").on("submit"+o,e.proxy(s._onParentFormSubmit,s)).on("reset"+o,e.proxy(s._onParentFormReset,s)),s.options.async.saveUrl?(s._module=s._supportsFormData()?new x(s):new k(s),s._async=!0,r=s.options.files,r.length>0&&s._renderInitialFiles(r)):s._module=new K(s),s._supportsDrop()&&(""!==s.options.dropZone?s._setupCustomDropZone():s._setupDropZone()),s.wrapper.on("click",".k-upload-action",e.proxy(s._onFileAction,s)).on("click",".k-clear-selected",e.proxy(s._onClearSelected,s)).on("click",".k-upload-selected",e.proxy(s._onUploadSelected,s)),
s.element.val()&&s._onInputChange({target:s.element})},events:[M,I,R,F,z,P,B,N,O,L,H],options:{name:"Upload",enabled:!0,multiple:!0,directory:!1,showFileList:!0,template:"",files:[],async:{autoRetryAfter:0,bufferChunkSize:1e7,maxAutoRetries:1,removeVerb:"POST",autoUpload:!0,withCredentials:!0,accept:"*/*; q=0.5, application/json",useArrayBuffer:!1},localization:{select:"Select files...",cancel:"Cancel",retry:"Retry",remove:"Remove",pause:"Pause",resume:"Resume",clearSelectedFiles:"Clear",uploadSelectedFiles:"Upload",dropFilesHere:"Drop files here to upload",invalidFiles:"Invalid file(s). Please check file upload requirements.",statusUploading:"uploading",statusUploaded:"uploaded",statusWarning:"warning",statusFailed:"failed",headerStatusUploading:"Uploading...",headerStatusPaused:"Paused",headerStatusUploaded:"Done",invalidMaxFileSize:"File size too large.",invalidMinFileSize:"File size too small.",invalidFileExtension:"File type not allowed."},validation:{allowedExtensions:[],maxFileSize:0,minFileSize:0},dropZone:""},setOptions:function(e){var t=this,n=t.element;S.fn.setOptions.call(t,e),t.multiple=t.options.multiple,t.directory=t.options.directory,n.attr("multiple",!!t._supportsMultiple()&&t.multiple),t.directory&&(n.attr("webkitdirectory",t.directory),n.attr("directory",t.directory)),t.toggle(t.options.enabled)},enable:function(e){e=t===e||e,this.toggle(e)},disable:function(){this.toggle(!1)},toggle:function(e){e=t===e?e:!e,this.wrapper.toggleClass("k-state-disabled",e),this.element.prop("disabled",e)},focus:function(){this.element.focus()},destroy:function(){var t=this,n=e(t.options.dropZone);e(document).add(e(".k-dropzone",t.wrapper)).add(t.wrapper.closest("form")).off(t._ns),n.length>0&&n.off(t._ns),e(t.element).off(E),S.fn.destroy.call(t)},pause:function(t){this._module.onPause({target:e(t,this.wrapper)});var n=t.find(".k-i-pause-sm");n.removeClass("k-i-pause-sm").addClass("k-i-play-sm").attr("title",this.localization.resume),e(n).parent().attr("aria-label",this.localization.resume)},resume:function(t){this._module.onResume({target:e(t,this.wrapper)});var n=t.find(".k-i-play-sm");n.removeClass("k-i-play-sm").addClass("k-i-pause-sm").attr("title",this.localization.pause),e(n).parent().attr("aria-label",this.localization.pause)},upload:function(){var e=this;e._module.onSaveSelected()},getFiles:function(){var t,n,i,o=this,r=[],s=o.wrapper.find(".k-file");for(n=0;n<s.length;n++)if(t=e(s[n]).data("fileNames"))for(i=0;i<t.length;i++)r.push(t[i]);return r},clearAllFiles:function(){var e=this,t=e.wrapper.find(".k-file");t.each(function(t,n){e._removeFileByDomElement(n,!1)})},removeAllFiles:function(){var e=this,t=e.wrapper.find(".k-file");t.each(function(t,n){e._removeFileByDomElement(n,!0)})},removeFileByUid:function(e){this._removeFileByUid(e,!0)},clearFileByUid:function(e){this._removeFileByUid(e,!1)},_removeFileByUid:function(t,n){var i,o=this;"string"==typeof t&&(i=e(".k-file["+C.attr("uid")+'="'+t+'"]',o.wrapper),i.length>0&&o._removeFileByDomElement(i,n))},clearFile:function(e){this._removeFile(e,!1)},removeFile:function(e){this._removeFile(e,!0)},_removeFile:function(t,n){var i,o=this,r=o.wrapper.find(".k-file");"function"==typeof t&&r.each(function(r,s){i=e(s).data("fileNames"),t(i)&&o._removeFileByDomElement(s,n)})},_removeFileByDomElement:function(t,n){var i,o=this,r={target:e(t,o.wrapper)};o.options.async.saveUrl?(e(t).hasClass("k-file-progress")?o._module.onCancel(r):o._module.onRemove(r,{},n),i=e(".k-file",o.wrapper),0===i.length?o._hideHeaderUploadstatus():o._updateHeaderUploadStatus()):o._module.onRemove(r,{},n)},_addInput:function(t){if(t[0].nodeType){var n=this,i=t.clone().val("");i.insertAfter(n.element).data("kendoUpload",n),e(n.element).hide().attr("tabindex","-1").removeAttr("id").off(E),n._activeInput(i),n.element.focus()}},_activeInput:function(t){var n=this,i=n.wrapper;n.element=t,n.directory&&(t.attr("webkitdirectory",n.directory),t.attr("directory",n.directory)),t.attr("multiple",!!n._supportsMultiple()&&n.multiple).attr("autocomplete","off").on("click"+E,function(e){i.hasClass("k-state-disabled")&&e.preventDefault()}).on("focus"+E,function(){e(this).parent().addClass("k-state-focused")}).on("blur"+E,function(){e(this).parent().removeClass("k-state-focused")}).on("change"+E,e.proxy(n._onInputChange,n)).on("keydown"+E,e.proxy(n._onInputKeyDown,n))},_onInputKeyDown:function(e){var t=this,n=t.wrapper.find(".k-upload-action:visible:first");e.keyCode===C.keys.TAB&&n.length>0&&(e.preventDefault(),n.focus())},_onInputChange:function(t){var n,i=this,o=e(t.target),r=l(i._inputFiles(o),i._isAsyncNonBatch());c(r,i.options.validation),n=i.trigger(M,{files:r}),n?(i._addInput(o),o.remove()):i._module.onSelect({target:o},r)},_readDirectory:function(t){var n=new e.Deferred,i=t.createReader();return i.readEntries(function(e){n.resolve(e)},n.reject),n.promise()},_readFile:function(e){var t=this,n=e.fullPath;e.file(function(e){e.relativePath=n.slice(1),t.droppedFolderFiles.push(e),t.droppedFolderCounter--,0===t.droppedFolderCounter&&setTimeout(function(){0===t.droppedFolderCounter&&t.droppedFolderFiles.length&&(t._proceedDroppedItems(t.droppedFolderFiles),t.droppedFolderFiles=[])},0)},function(){D("File error.")})},_traverseFileTree:function(e,t){var n=this;t||n.droppedFolderCounter--,this._readDirectory(e).then(function(e){n.droppedFolderCounter+=e.length;for(var t=0;t<e.length;t++)e[t].isFile?n._readFile(e[t]):e[t].isDirectory&&n._traverseFileTree(e[t])})},_onDrop:function(e){var t,n,i,o=e.originalEvent.dataTransfer,r=this,s=o.files;if(_(e),r.options.directoryDrop&&o.items)for(t=o.items.length,r.droppedFolderCounter=0,r.droppedFolderFiles=[],n=0;n<t;n++)o.items[n].webkitGetAsEntry?(i=o.items[n].webkitGetAsEntry(),i.isDirectory?r._traverseFileTree(i,!0):i.isFile&&r.droppedFolderFiles.push(o.files[n])):r._proceedDroppedItems(s);else r._proceedDroppedItems(s)},_proceedDroppedItems:function(t){var n,i=this,r=l(o(t),i._isAsyncNonBatch());t.length>0&&!i.wrapper.hasClass("k-state-disabled")&&(!i.multiple&&r.length>1&&r.splice(1,r.length-1),c(r,i.options.validation),n=i.trigger(M,{files:r}),n||i._module.onSelect({target:e(".k-dropzone",i.wrapper)},r))},_filesContainValidationErrors:function(t){var n=!1;return e(t).each(function(e,t){if(t[V]&&t[V].length>0)return n=!0,!1}),n},_isAsyncNonBatch:function(){return this._async&&!this.options.async.batch||!1},_renderInitialFiles:function(e){var t,n,i=this,o=0;for(e=l(e,!0),o=0;o<e.length;o++)t=e[o],n=i._enqueueFile(t.name,{fileNames:[t]}),n.addClass("k-file-success").data("files",[e[o]]),i._supportsRemove()&&i._fileAction(n,O)},_prepareTemplateData:function(e,t){var n=t.fileNames,i={},o=0,r=0;for(r=0;r<n.length;r++)o+=n[r].size;return i.name=e,i.size=o,i.files=t.fileNames,i},_prepareDefaultSingleFileEntryTemplate:function(t){var n=this,i=t.fileNames[0],o=f(t.fileNames),r=i[V],s="";return s+=r&&r.length>0?"<li class='k-file k-file-invalid'><span class='k-progress'></span><span class='k-file-invalid-extension-wrapper'><span class='k-file-invalid-icon'>!</span><span class='k-file-state'></span></span><span class='k-file-name-size-wrapper'><span class='k-file-name k-file-name-invalid' title='"+i.name+"'>"+i.name+"</span><span class='k-file-validation-message'>"+n.localization[r[0]]+"</span></span>":"<li class='k-file'><span class='k-progress'></span><span class='k-file-extension-wrapper'><span class='k-file-extension'>"+i.extension.substring(1)+"</span><span class='k-file-state'></span></span><span class='k-file-name-size-wrapper'><span class='k-file-name' title='"+i.name+"'>"+i.name+"</span><span class='k-file-size'>"+o+"</span></span>",s+="<strong class='k-upload-status'></strong>",e(s)},_prepareDefaultMultipleFileEntriesTemplate:function(t){var n,i,o=this,r=t.fileNames,s=o._filesContainValidationErrors(r),a=f(r),l="";for(l+=s?"<li class='k-file k-file-invalid'><span class='k-progress'></span><span class='k-multiple-files-invalid-extension-wrapper'><span class='k-file-invalid-icon'>!</span>":"<li class='k-file'><span class='k-progress'></span><span class='k-multiple-files-extension-wrapper'>",l+="<span class='k-file-state'></span></span>",r.sort(function(e,t){return e[V]?-1:t[V]?1:0}),l+="<span class='k-file-name-size-wrapper'>",n=0;n<r.length;n++)i=r[n],l+=i[V]&&i[V].length>0?"<span class='k-file-name k-file-name-invalid' title='"+i.name+"'>"+i.name+"</span>":"<span class='k-file-name' title='"+i.name+"'>"+i.name+"</span>";return l+=s?"<span class='k-file-validation-message'>"+o.localization.invalidFiles+"</span>":"<span class='k-file-information'>Total: "+r.length+" files, "+a+"</span>",l+="</span><strong class='k-upload-status'></strong>",e(l)},_enqueueFile:function(t,n){var i,o,r,s,a=this,l=n.fileNames[0].uid,c=e(".k-upload-files",a.wrapper),d=a.options,u=d.template;return 0===c.length&&(c=e("<ul class='k-upload-files k-reset'></ul>").appendTo(a.wrapper),a.options.showFileList||c.hide(),a.wrapper.removeClass("k-upload-empty")),i=e(".k-file",c),u?(r=a._prepareTemplateData(t,n),u=C.template(u),o=e("<li class='k-file'>"+u(r)+"</li>"),o.find(".k-upload-action").addClass("k-button"),a.angular("compile",function(){return{elements:o,data:[r]}})):o=1===n.fileNames.length?a._prepareDefaultSingleFileEntryTemplate(n):a._prepareDefaultMultipleFileEntriesTemplate(n),o.attr(C.attr("uid"),l).appendTo(c).data(n),a._async||e(".k-progress",o).width("100%"),!a.multiple&&i.length>0&&(s={files:i.data("fileNames"),headers:{}},a.trigger(O,s)||a._module.onRemove({target:e(i,a.wrapper)},s)),o},_removeFileEntry:function(t){var n,i,o,r=this,s=t.closest(".k-upload-files");t.remove(),n=e(".k-file",s),i=e(".k-file-success, .k-file-error",s),o=e(".k-file-invalid",s),i.length!==n.length&&o.length!==n.length||this._hideUploadButton(),0===n.length?(s.remove(),r.wrapper.addClass("k-upload-empty"),r._hideHeaderUploadstatus()):r._updateHeaderUploadStatus()},_fileAction:function(e,t,n){var i,o={remove:"k-i-x",cancel:"k-i-cancel",retry:"k-i-retry",pause:"k-i-pause-sm"},r={remove:"k-i-close",cancel:"k-i-close",retry:"k-i-reload-sm",pause:"k-i-pause-sm"};o.hasOwnProperty(t)&&(n||this._clearFileAction(e),this.options.template?(i=e.find(".k-upload-action").first(),i.find(".k-icon").length?i.next(".k-upload-action").length&&i.next(".k-upload-action").addClass("k-button").append("<span class='k-icon "+r[t]+" "+o[t]+"' title='"+this.localization[t]+"'aria-label='"+this.localization[t]+"'></span>").show():i.addClass("k-button").append("<span class='k-icon "+r[t]+" "+o[t]+"' title='"+this.localization[t]+"'aria-label='"+this.localization[t]+"'></span>").show()):(n||e.find(".k-upload-status .k-upload-action").remove(),e.find(".k-upload-status").append(this._renderAction(o[t],this.localization[t],r[t]))))},_fileState:function(t,n){var i=this.localization,o={uploading:{text:i.statusUploading},uploaded:{text:i.statusUploaded},failed:{text:i.statusFailed}},r=o[n];r&&e("span.k-file-state",t).text(r.text)},_renderAction:function(t,n,i){return""!==t?e("<button type='button' class='k-button k-upload-action' aria-label='"+n+"'><span class='k-icon "+i+" "+t+"' title='"+n+"'></span></button>").on("focus",function(){e(this).addClass("k-state-focused")}).on("blur",function(){e(this).removeClass("k-state-focused")}):e("<button type='button' class='k-button'>"+n+"</button>")},_clearFileAction:function(t){e(".k-upload-action",t).empty().hide()},_onFileAction:function(t){var n,i,o,r,s,a,l=this;return l.wrapper.hasClass("k-state-disabled")||(n=e(t.target).closest(".k-upload-action"),i=n.find(".k-icon"),o=n.closest(".k-file"),r=o.data("fileNames"),s=l._filesContainValidationErrors(r),a={files:r,headers:{}},i.hasClass("k-i-x")?l.trigger(O,a)||l._module.onRemove({target:e(o,l.wrapper)},a,!s):i.hasClass("k-i-cancel")?(l.trigger(P,a),l._module.onCancel({target:e(o,l.wrapper)}),l._checkAllComplete(),l._updateHeaderUploadStatus()):i.hasClass("k-i-pause-sm")?(l.trigger(L,a),l.pause(o),l._updateHeaderUploadStatus()):i.hasClass("k-i-play-sm")?(l.trigger(H,a),l.resume(o)):i.hasClass("k-i-retry")&&(e(".k-i-warning",o).remove(),e(".k-progress",o).finish().show(),l._module.onRetry({target:e(o,l.wrapper)}))),!1},_onUploadSelected:function(){var e=this,t=e.wrapper;return t.hasClass("k-state-disabled")||this._module.onSaveSelected(),!1},_onClearSelected:function(){var e=this,t=e.wrapper,n={};return t.hasClass("k-state-disabled")||e.trigger(B,n)||e.clearAllFiles(),!1},_onFileProgress:function(t,n){var i,o;n>100&&(n=100),this.options.template?e(".k-progress",t.target).width(n+"%"):(i=e(".k-upload-pct",t.target),o=e(".k-i-warning",t.target),o.length?o.removeClass("k-i-warning").removeClass("k-icon").addClass("k-upload-pct"):0===i.length&&e(".k-upload-status",t.target).prepend("<span class='k-upload-pct'></span>"),100!==n?e(".k-upload-pct",t.target).text(n+"%"):e(".k-upload-pct",t.target).remove(),e(".k-progress",t.target).width(n+"%")),this.trigger(N,{files:y(t).data("fileNames"),percentComplete:n})},_onUploadSuccess:function(e,t,n){var i=this,o=y(e),r=i.trigger(R,{files:o.data("fileNames"),response:t,operation:"upload",XMLHttpRequest:n});r?i._setUploadErrorState(o):(i._fileState(o,"uploaded"),o.removeClass("k-file-progress").addClass("k-file-success"),i._updateHeaderUploadStatus(),i._supportsRemove()?i._fileAction(o,O):i._clearFileAction(o)),i._hideUploadProgress(o),i._checkAllComplete()},_onUploadError:function(e,t){var n=this,i=n._module,o=y(e),r=o.data("uid");n._setUploadErrorState(o),n.trigger(F,{operation:"upload",files:o.data("fileNames"),XMLHttpRequest:t}),D("Server response: "+t.responseText),n.options.async.chunkSize?i._decreasePosition&&i._decreasePosition(r):n._hideUploadProgress(o),n._checkAllComplete(),this.options.async.autoRetryAfter&&this._autoRetryAfter(o)},_autoRetryAfter:function(e){var t=this,n=this._module.retries;n&&(n[e.data("uid")]||(n[e.data("uid")]=1),n[e.data("uid")]<=this.options.async.maxAutoRetries&&(n[e.data("uid")]++,setTimeout(function(){t._module.performUpload(e)},this.options.async.autoRetryAfter)))},_setUploadErrorState:function(t){var n,i=this;i._fileState(t,"failed"),t.removeClass("k-file-progress").addClass("k-file-error"),i._updateUploadProgress(t),n=e(".k-upload-pct",t),n.length>0?(n.parent().find(".k-i-warning").length||n.removeClass("k-upload-pct").addClass("k-icon k-i-warning"),n.empty()):e(".k-upload-status",t).prepend("<span class='k-icon k-i-warning'></span>"),this._updateHeaderUploadStatus(),this._fileAction(t,"retry"),this._fileAction(t,O,!0)},_updateUploadProgress:function(t){var n,i,o,r=this;r.options.async.chunkSize?(n=t.data("uid"),r._module.metaData&&(i=r._module.metaData[n],i&&(o=i.totalChunks?Math.round(i.chunkIndex/i.totalChunks*100):100,r._onFileProgress({target:e(t,r.wrapper)},o)))):e(".k-progress",t).width("100%")},_hideUploadProgress:function(t){e(".k-progress",t).delay(j).fadeOut(G,function(){e(this).css("width","0%")})},_showUploadButton:function(){var t=this,n=e(".k-upload-selected",t.wrapper),i=e(".k-clear-selected",t.wrapper);0===n.length&&(n=t._renderAction("",this.localization.uploadSelectedFiles).addClass("k-upload-selected"),i=t._renderAction("",this.localization.clearSelectedFiles).addClass("k-clear-selected")),this.wrapper.append(i,n)},_hideUploadButton:function(){e(".k-upload-selected, .k-clear-selected",this.wrapper).remove()},_showHeaderUploadStatus:function(t){var n=this,i=n.localization,o=e(".k-dropzone",n.wrapper),r=e(".k-upload-status-total",n.wrapper);0!==r.length&&r.remove(),r='<strong class="k-upload-status k-upload-status-total"><span class="k-icon"></span></strong>',t?(r=e(r).append(i.headerStatusUploading),r.find(".k-icon").addClass($.loading)):(r=e(r).append(i.headerStatusUploaded),r.find(".k-icon").addClass($.warning)),o.length>0?o.append(r):e(".k-upload-button",n.wrapper).after(r)},_updateHeaderUploadStatus:function(){var t,n,i=this,o=e(".k-upload-status-total",this.wrapper),r=e(".k-file",i.wrapper).not(".k-file-success, .k-file-error, .k-file-invalid"),s=e(".k-file-invalid",i.wrapper),a=e(".k-file-error",i.wrapper),l=e(".k-file",i.wrapper).find(".k-i-play-sm");!l.length||l.length!==r.length&&i.options.async.concurrent?(0===r.length||s.length>0||a.length>0)&&(t=e(".k-file.k-file-error, .k-file.k-file-invalid",i.wrapper),o=e(".k-upload-status-total",i.wrapper),n=e(".k-icon",o).removeClass().addClass("k-icon").addClass(0!==t.length?$.warning:$.success),o.html(n).append(i.localization.headerStatusUploaded)):(n=e(".k-icon",o).removeClass().addClass("k-icon").addClass("k-i-pause-sm"),o.html(n).append(i.localization.headerStatusPaused))},_hideHeaderUploadstatus:function(){e(".k-upload-status-total",this.wrapper).remove()},_onParentFormSubmit:function(){var n,i=this,o=i.element;t!==this._module.onAbort&&this._module.onAbort(),o.value||(n=e(o),n.attr("disabled","disabled"),window.setTimeout(function(){n.removeAttr("disabled")},0))},_onParentFormReset:function(){e(".k-upload-files",this.wrapper).remove()},_supportsFormData:function(){return"undefined"!=typeof FormData},_supportsMultiple:function(){var e=this._userAgent().indexOf("Windows")>-1;return!(C.support.browser.opera||C.support.browser.safari&&e)},_supportsDrop:function(){var e=this._userAgent().toLowerCase(),t=/chrome/.test(e),n=!t&&/safari/.test(e),i=n&&/windows/.test(e);return!i&&this._supportsFormData()&&this.options.async.saveUrl},_userAgent:function(){return navigator.userAgent},_setupDropZone:function(){var t,n,i=this;e(".k-upload-button",i.wrapper).wrap("<div class='k-dropzone'></div>"),t=i._ns,n=e(".k-dropzone",i.wrapper).append(e("<em>"+i.localization.dropFilesHere+"</em>")).on("dragenter"+t,_).on("dragover"+t,function(e){e.preventDefault()}).on("drop"+t,e.proxy(i._onDrop,i)),b(n,t,function(){n.closest(".k-upload").hasClass("k-state-disabled")||n.addClass("k-dropzone-hovered")},function(){n.removeClass("k-dropzone-hovered")}),i._bindDocumentDragEventWrappers(n)},_setupCustomDropZone:function(){var t,n=this,i=e(n.options.dropZone);e(".k-upload-button",n.wrapper).wrap("<div class='k-dropzone'></div>"),t=n._ns,i.on("dragenter"+t,_).on("dragover"+t,function(e){e.preventDefault()}).on("drop"+t,e.proxy(n._onDrop,n)),b(i,t,function(t){n.wrapper.hasClass("k-state-disabled")||(i.removeClass("k-dropzone-hovered"),e(t.target).addClass("k-dropzone-hovered"))},function(){i.removeClass("k-dropzone-hovered")}),n._bindDocumentDragEventWrappers(i)},_bindDocumentDragEventWrappers:function(t){var n=this,i=n._ns;b(e(document),i,function(){n.wrapper.hasClass("k-state-disabled")||(t.addClass("k-dropzone-active"),t.closest(".k-upload").removeClass("k-upload-empty"))},function(){t.removeClass("k-dropzone-active"),0===e("li.k-file",t.closest(".k-upload")).length&&t.closest(".k-upload").addClass("k-upload-empty")})},_supportsRemove:function(){return!!this.options.async.removeUrl},_submitRemove:function(t,n,i,o){var r=this,s=r.options.async.removeField||"fileNames",a=e.extend(n.data,T());a[s]=t,jQuery.ajax({type:this.options.async.removeVerb,dataType:"json",dataFilter:v,url:this.options.async.removeUrl,traditional:!0,data:a,headers:n.headers,success:i,error:o,xhrFields:{withCredentials:this.options.async.withCredentials}})},_wrapInput:function(e){var t=this,n=t.options;return e.wrap("<div class='k-widget k-upload k-header'><div class='k-button k-upload-button' aria-label='"+this.localization.select+"'></div></div>"),n.async.saveUrl||e.closest(".k-upload").addClass("k-upload-sync"),e.closest(".k-upload").addClass("k-upload-empty"),e.closest(".k-button").append("<span>"+this.localization.select+"</span>"),e.closest(".k-upload")},_checkAllComplete:function(){0===e(".k-file.k-file-progress",this.wrapper).length&&this.trigger(z)},_inputFiles:function(e){return i(e)}}),K=function(e){this.name="syncUploadModule",this.element=e.wrapper,this.upload=e,this.element.closest("form").attr("enctype","multipart/form-data").attr("encoding","multipart/form-data")};K.prototype={onSelect:function(t,i){var o,r,s=this.upload,a=e(t.target),l=s._filesContainValidationErrors(i);s._addInput(a),o={fileNames:i},l?a.remove():o.relatedInput=a,r=s._enqueueFile(n(a),o),l&&s._hideUploadProgress(r),s._fileAction(r,O)},onRemove:function(e){var t=y(e),n=t.data("relatedInput");n&&n.remove(),this.upload._removeFileEntry(t)}},k=function(e){this.name="iframeUploadModule",this.element=e.wrapper,this.upload=e,this.iframes=[]},Y._frameId=0,k.prototype={onSelect:function(t,n){var i=this.upload,o=e(t.target),r=i._filesContainValidationErrors(n),s=this.prepareUpload(o,n,r);i.options.async.autoUpload?r?(i._fileAction(s,O),i._showHeaderUploadStatus(!1)):this.performUpload(s):(i._fileAction(s,O),r?i._updateHeaderUploadStatus():i._showUploadButton()),r&&i._hideUploadProgress(s)},prepareUpload:function(t,i,o){var r,s,a,l,c=this.upload,d=e(c.element),u=c.options.async.saveField||t.attr("name");return c._addInput(t),t.attr("name",u),o?(t.remove(),s={fileNames:i}):(a=this.createFrame(c.name+"_"+Y._frameId++),this.registerFrame(a),l=this.createForm(c.options.async.saveUrl,a.attr("name")).append(d),s={frame:a,relatedInput:d,fileNames:i}),r=c._enqueueFile(n(t),s),a&&a.data({form:l,file:r}),r},performUpload:function(t){var n,i,o,r={files:t.data("fileNames")},s=t.data("frame"),a=this.upload;if(a.trigger(I,r))a._removeFileEntry(s.data("file")),this.cleanupFrame(s),this.unregisterFrame(s);else{a._hideUploadButton(),a._showHeaderUploadStatus(!0),s.appendTo(document.body),n=s.data("form").attr("action",a.options.async.saveUrl).appendTo(document.body),r.data=e.extend({},r.data,T());for(i in r.data)o=n.find("input[name='"+i+"']"),0===o.length&&(o=e("<input>",{type:"hidden",name:i}).prependTo(n)),o.val(r.data[i]);a._fileAction(t,P),a._fileState(t,"uploading"),e(t).removeClass("k-file-error").addClass("k-file-progress"),s.one("load",e.proxy(this.onIframeLoad,this)),n[0].submit()}},onSaveSelected:function(){var t=this,n=t.upload;e(".k-file",this.element).each(function(){var i=e(this),o=w(i),r=n._filesContainValidationErrors(i.data("fileNames"));o||r||t.performUpload(i)})},onIframeLoad:function(t){var n,i=e(t.target);try{n=i.contents().text()}catch(o){n="Error trying to get server response: "+o}this.processResponse(i,n)},processResponse:function(t,n){var i=t.data("file"),o=this,r={responseText:n};g(n,function(n){e.extend(r,{statusText:"OK",status:"200"}),o.upload._onFileProgress({target:e(i,o.upload.wrapper)},100),o.upload._onUploadSuccess({target:e(i,o.upload.wrapper)},n,r),o.cleanupFrame(t),o.unregisterFrame(t)},function(){e.extend(r,{statusText:"error",status:"500"}),o.upload._onUploadError({target:e(i,o.upload.wrapper)},r)})},onCancel:function(t){var n=e(t.target).data("frame");this.stopFrameSubmit(n),this.cleanupFrame(n),this.unregisterFrame(n),this.upload._removeFileEntry(n.data("file"))},onRetry:function(e){var t=y(e);this.performUpload(t)},onRemove:function(e,t,n){var i=this,o=i.upload,r=y(e),s=r.data("frame");s?(i.unregisterFrame(s),o._removeFileEntry(r),i.cleanupFrame(s)):r.hasClass("k-file-success")?m(r,o,t,n):o._removeFileEntry(r)},onAbort:function(){var t=this.element,n=this;e.each(this.iframes,function(){e("input",this.data("form")).appendTo(t),n.stopFrameSubmit(this[0]),this.data("form").remove(),this.remove()}),this.iframes=[]},createFrame:function(t){return e("<iframe name='"+t+"' id='"+t+"' style='display:none;' />")},createForm:function(t,n){return e("<form enctype='multipart/form-data' method='POST' action='"+t+"' target='"+n+"'/>")},stopFrameSubmit:function(e){t!==e.stop?e.stop():e.document&&e.document.execCommand("Stop")},registerFrame:function(e){this.iframes.push(e)},unregisterFrame:function(t){this.iframes=e.grep(this.iframes,function(e){return e.attr("name")!=t.attr("name")})},cleanupFrame:function(e){var t=e.data("form");e.data("file").data("frame",null),setTimeout(function(){t.remove(),e.remove()},1)}},x=function(e){this.name="formDataUploadModule",this.element=e.wrapper,this.upload=e,this.position={},this.metaData={},this.cancelled={},this.resume={},this.paused={},this.retries={}},x.prototype={onSelect:function(t,n){var i,o,r=this.upload,s=this,a=e(t.target),l=this.prepareUpload(a,n);e.each(l,function(t){i=r._filesContainValidationErrors(e(this.data("fileNames"))),r.options.async.autoUpload?i?(r._fileAction(this,O),r._showHeaderUploadStatus(!1)):r.options.async.chunkSize?(s.prepareChunk(this),o=this.prev(),(r.options.async.concurrent||0===t&&!o.length||0===t&&o.hasClass("k-file-success"))&&s.performUpload(this)):s.performUpload(this):(r._fileAction(this,O),i?r._updateHeaderUploadStatus():(r._showUploadButton(),this.addClass("k-toupload"))),i&&r._hideUploadProgress(this)})},prepareUpload:function(t,n){var i=this.enqueueFiles(n);return t.is("input")&&(e.each(i,function(){e(this).data("relatedInput",t)}),t.data("relatedFileEntries",i),this.upload._addInput(t)),i},enqueueFiles:function(t){var n,i,o,r,s=this.upload,a=t.length,l=[];if(s.options.async.batch===!0)n=e.map(t,function(e){return e.name}).join(", "),(s.directory||s.options.directoryDrop)&&e(t).each(function(){(this.rawFile.webkitRelativePath||this.rawFile.relativePath)&&(this.name=this.rawFile.webkitRelativePath||this.rawFile.relativePath)}),r=s._enqueueFile(n,{fileNames:t}),r.data("files",t),l.push(r);else for(i=0;i<a;i++)o=t[i],n=o.name,(s.directory||s.options.directoryDrop)&&(o.rawFile.webkitRelativePath||o.rawFile.relativePath)&&(o.name=o.rawFile.webkitRelativePath||o.rawFile.relativePath),r=s._enqueueFile(n,{fileNames:[o]}),r.data("files",[o]),l.push(r);return l},performUpload:function(t){var n,i,o=this.upload,r=this.createFormData(),s=this.createXHR(),a={files:t.data("fileNames"),XMLHttpRequest:s};if(o.trigger(I,a))this.removeFileEntry(t);else{if(0===t.find(".k-i-cancel").length&&(o.options.async.chunkSize&&o._fileAction(t,L),o._fileAction(t,P,o.options.async.chunkSize)),o.wrapper.find(".k-toupload").length||o._hideUploadButton(),o._showHeaderUploadStatus(!0),a.formData)r=a.formData;else{a.data=e.extend({},a.data,T());for(i in a.data)r.append(i,a.data[i]);n=t.data("files"),n&&this.populateFormData(r,n)}o._fileState(t,"uploading"),e(t).removeClass("k-file-error").addClass("k-file-progress"),o.options.async.useArrayBuffer&&window.FileReader?this._readFile(o.options.async.saveUrl,r,t,s):this.postFormData(o.options.async.saveUrl,r,t,s)}},_readFile:function(n,i,o,r){var s=this,a=s.upload,l=o.data("files")[0],c=new FileReader;c.onload=function(c){try{s.fileArrayBuffer=s.fileArrayBuffer?s._appendBuffer(s.fileArrayBuffer,c.target.result):c.target.result}catch(d){return a._onUploadError({target:e(o,a.wrapper)},r),t}s.position[l.uid]>l.size?(s.postFormData(a.options.async.saveUrl,s.fileArrayBuffer,o,r),s.fileArrayBuffer=null):s._readFile(n,i,o,r)},c.onerror=function(){a._onUploadError({target:e(o,a.wrapper)},r)},c.readAsArrayBuffer(s._getCurrentChunk(l.rawFile,l.uid))},_appendBuffer:function(e,t){var n=new Uint8Array(e.byteLength+t.byteLength);return n.set(new Uint8Array(e),0),n.set(new Uint8Array(t),e.byteLength),n.buffer},onSaveSelected:function(){var t=this,n=t.upload;e(".k-toupload",this.element).filter(function(){var t=e(this),i=w(t),o=n._filesContainValidationErrors(t.data("fileNames"));return!i&&!o}).each(function(i){var o=e(this),r=o.prev();o.removeClass("k-toupload"),n.options.async.chunkSize?(t.prepareChunk(o),(n.options.async.concurrent||0===i&&!r.length||0===i&&r.hasClass("k-file-success")||r.hasClass("k-file-error"))&&t.performUpload(o)):t.performUpload(o)})},onCancel:function(e){var t=y(e);this.upload.options.async.chunkSize&&(this.cancelled[t.data("uid")]=!0),this.stopUploadRequest(t),this.removeFileEntry(t)},onPause:function(e){var t=y(e),n=t.data("uid"),i=this.upload.options.async;i.chunkSize&&(this.retries[n]=i.maxAutoRetries+1,this.paused[n]=!0,this.resume[n]=!1)},onResume:function(e){var t=y(e),n=t.data("uid");this.upload.options.async.chunkSize&&(delete this.paused[n],this.resume[n]=!0,this.retries[t.data("uid")]=1,this._increaseChunkIndex(n),this.performUpload(t))},onRetry:function(e){var t=y(e),n=this.upload.options.async;n.chunkSize&&(this.retries[t.data("uid")]=n.maxAutoRetries+1,delete this.paused[t.data("uid")]),this.performUpload(t)},onRemove:function(e,t,n){var i=this,o=i.upload,r=y(e),s=this.upload.options.async;s.chunkSize&&(this.retries[r.data("uid")]=s.maxAutoRetries+1),r.hasClass("k-file-success")?m(r,o,t,n):i.removeFileEntry(r)},createXHR:function(){return new XMLHttpRequest},postFormData:function(e,t,n,i){var o,r=this;n.data("request",i),i.addEventListener("load",function(e){r.onRequestSuccess.call(r,e,n)},!1),i.addEventListener(F,function(e){r.onRequestError.call(r,e,n)},!1),i.upload.addEventListener("progress",function(e){r.onRequestProgress.call(r,e,n)},!1),i.open("POST",e,!0),i.withCredentials=this.upload.options.async.withCredentials,o=this.upload.options.async.accept,o&&i.setRequestHeader("Accept",o),i.send(t)},createFormData:function(){return new FormData},populateFormData:function(e,t){var n,i,o,r,s=t.length,a=this.upload;if(a.options.async.chunkSize)o=t[0].uid,n=this._getCurrentChunk(t[0].rawFile,o),e.append(a.options.async.saveField||a.name,n),r=JSON.stringify(this.metaData[o]),e.append("metadata",r);else for(i=0;i<s;i++)e.append(a.options.async.saveField||a.name,t[i].rawFile);return e},onRequestSuccess:function(t,n){function i(){s.upload._onUploadError({target:e(n,s.upload.wrapper)},r)}function o(t){var i=s.upload.options.async.batch,o=s.upload.options.async.chunkSize,a=s.upload.options.async.concurrent,l=t.fileUid;s.paused[l]||s.cancelled[l]||(delete s.retries[l],!o||i||t.uploaded?!o||i||a||!n.next().length||n.next().hasClass("k-toupload")?(s.upload._onFileProgress({target:e(n,s.upload.wrapper)},100),s.upload._onUploadSuccess({target:e(n,s.upload.wrapper)},t,r),s.cleanupFileEntry(n)):(s.upload._onFileProgress({target:e(n,s.upload.wrapper)},100),s._resetChunkIndex(l),s.upload._onUploadSuccess({target:e(n,s.upload.wrapper)},t,r),s.performUpload(n.next())):(s._increaseChunkIndex(l),s.performUpload(n)))}var r=t.target,s=this;r.status>=200&&r.status<=299?g(r.responseText,o,i):i()},onRequestError:function(t,n){var i=t.target;this.upload._onUploadError({target:e(n,this.upload.wrapper)},i)},cleanupFileEntry:function(t){var n=t.data("relatedInput"),i=!0;n&&(e.each(n.data("relatedFileEntries")||[],function(){this.parent().length>0&&this[0]!=t[0]&&(i=i&&this.hasClass("k-file-success"))}),i&&n.remove())},removeFileEntry:function(e){var t=this.upload.options.async.chunkSize,n=this.upload.options.async.concurrent;this.cleanupFileEntry(e),t&&!n&&e.next().length&&this.performUpload(e.next()),this.upload._removeFileEntry(e)},onRequestProgress:function(t,n){var i,o=Math.round(100*t.loaded/t.total),r=n.data("uid");this.upload.options.async.chunkSize&&(i=this.metaData[r],o=i.totalChunks?Math.round(i.chunkIndex/i.totalChunks*100):100),this.upload._onFileProgress({target:e(n,this.upload.wrapper)},o)},stopUploadRequest:function(e){e.data("request").abort()},prepareChunk:function(e){var t=e.data("files")[0].rawFile,n=e.data("files")[0].uid,i=this.upload.options.async.chunkSize;this.position[n]=0,this.metaData[n]={chunkIndex:0,contentType:t.type,fileName:t.name,totalFileSize:t.size,totalChunks:Math.ceil(t.size/i),uploadUid:n}},_decreaseChunkIndex:function(e){this.metaData[e].chunkIndex--},_increaseChunkIndex:function(e){this.metaData[e].chunkIndex++},_resetChunkIndex:function(e){this.metaData[e].chunkIndex=0},_decreasePosition:function(e){this.position[e]-=this.upload.options.async.chunkSize},_getCurrentChunk:function(e,t){var n,i=this.position[t],o=this.upload.options.async,r=o.chunkSize||o.bufferChunkSize;return this.position[t]||(this.position[t]=0),this.position[t]+=r,(n=this._getChunker(e))?e[n](i,this.position[t]):e},_getChunker:function(e){return e.slice?"slice":e.mozSlice?"mozSlice":e.webkitSlice?"webkitSlice":null}},C.ui.plugin(Y)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.filebrowser.min",["kendo.listview.min","kendo.dropdownlist.min","kendo.upload.min"],e)}(function(){return function(e,t){function n(e,t,n){var i,o;e.on("dragenter"+x,function(){t(),o=new Date,i||(i=setInterval(function(){
var e=new Date-o;e>100&&(n(),clearInterval(i),i=null)},100))}).on("dragover"+x,function(){o=new Date})}function i(e,n){return e!==t&&e.match(/\/$/)||(e=(e||"")+"/"),e+n}function o(e){if(!e)return"";var t=" bytes";return e>=1073741824?(t=" GB",e/=1073741824):e>=1048576?(t=" MB",e/=1048576):e>=1024&&(t=" KB",e/=1024),Math.round(100*e)/100+t}function r(e,t){var n=e[t];return h(n)?n.from||n.field||t:n}var s,a,l,c,d=window.kendo,u=d.ui.Widget,h=e.isPlainObject,f=e.proxy,p=e.extend,m=d.support.placeholder,g=d.support.browser,v=d.isFunction,_=/(^\/|\/$)/g,b="change",w="apply",y="error",k="click",x=".kendoFileBrowser",C=".kendoBreadcrumbs",S=".kendoSearchBox",T="name",D="size",A="type",E={field:A,dir:"asc"},M=d.template('<li class="k-tile-empty"><strong>${text}</strong></li>'),I='<div class="k-widget k-filebrowser-toolbar k-header k-floatwrap"><div class="k-toolbar-wrap"># if (showUpload) { # <div class="k-widget k-upload"><div class="k-button k-button-icontext k-upload-button"><span class="k-icon k-i-plus"></span>#=messages.uploadFile#<input type="file" name="file" /></div></div># } ## if (showCreate) { #<button type="button" class="k-button k-button-icon"><span class="k-icon k-i-folder-add" /></button># } ## if (showDelete) { #<button type="button" class="k-button k-button-icon k-state-disabled"><span class="k-icon k-i-close" /></button>&nbsp;# } #</div><div class="k-tiles-arrange"><label>#=messages.orderBy#: <select /></label></div></div>';p(!0,d.data,{schemas:{filebrowser:{data:function(e){return e.items||e||[]},model:{id:"name",fields:{name:"name",size:"size",type:"type"}}}}}),p(!0,d.data,{transports:{filebrowser:d.data.RemoteTransport.extend({init:function(t){d.data.RemoteTransport.fn.init.call(this,e.extend(!0,{},this.options,t))},_call:function(t,n){n.data=e.extend({},n.data,{path:this.options.path()}),v(this.options[t])?this.options[t].call(this,n):d.data.RemoteTransport.fn[t].call(this,n)},read:function(e){this._call("read",e)},create:function(e){this._call("create",e)},destroy:function(e){this._call("destroy",e)},update:function(){},options:{read:{type:"POST"},update:{type:"POST"},create:{type:"POST"},destroy:{type:"POST"}}})}}),s=g.msie&&g.version<8?function(e){return e.offsetTop}:function(t){return t.offsetTop-e(t).height()},a=u.extend({init:function(e,t){var n=this;t=t||{},u.fn.init.call(n,e,t),n.element.addClass("k-filebrowser"),n.element.on(k+x,".k-filebrowser-toolbar button:not(.k-state-disabled):has(.k-i-close)",f(n._deleteClick,n)).on(k+x,".k-filebrowser-toolbar button:not(.k-state-disabled):has(.k-i-folder-add)",f(n._addClick,n)).on("keydown"+x,"li.k-state-selected input",f(n._directoryKeyDown,n)).on("blur"+x,"li.k-state-selected input",f(n._directoryBlur,n)),n._dataSource(),n.refresh(),n.path(n.options.path)},options:{name:"FileBrowser",messages:{uploadFile:"Upload",orderBy:"Arrange by",orderByName:"Name",orderBySize:"Size",directoryNotFound:"A directory with this name was not found.",emptyFolder:"Empty Folder",deleteFile:'Are you sure you want to delete "{0}"?',invalidFileType:'The selected file "{0}" is not valid. Supported file types are {1}.',overwriteFile:'A file with name "{0}" already exists in the current directory. Do you want to overwrite it?',dropFilesHere:"drop file here to upload",search:"Search"},transport:{},path:"/",fileTypes:"*.*"},events:[y,b,w],destroy:function(){var e=this;u.fn.destroy.call(e),e.dataSource.unbind(y,e._errorHandler),e.element.add(e.list).add(e.toolbar).off(x),d.destroy(e.element)},value:function(){var e,t=this,n=t._selectedItem(),o=t.options.transport.fileUrl;if(n&&"f"===n.get(A))return e=i(t.path(),n.get(T)).replace(_,""),o&&(e=v(o)?o(e):d.format(o,encodeURIComponent(e))),e},_selectedItem:function(){var e=this.listView,t=e.select();if(t.length)return this.dataSource.getByUid(t.attr(d.attr("uid")))},_toolbar:function(){var t=this,n=d.template(I),i=t.options.messages,o=[{text:i.orderByName,value:"name"},{text:i.orderBySize,value:"size"}];t.toolbar=e(n({messages:i,showUpload:t.options.transport.uploadUrl,showCreate:t.options.transport.create,showDelete:t.options.transport.destroy})).appendTo(t.element).find(".k-upload input").kendoUpload({multiple:!1,localization:{dropFilesHere:i.dropFilesHere},async:{saveUrl:t.options.transport.uploadUrl,autoUpload:!0},upload:f(t._fileUpload,t),error:function(e){t._error({xhr:e.XMLHttpRequest,status:"error"})}}).end(),t.upload=t.toolbar.find(".k-upload input").data("kendoUpload"),t.arrangeBy=t.toolbar.find(".k-tiles-arrange select").kendoDropDownList({dataSource:o,dataTextField:"text",dataValueField:"value",change:function(){t.orderBy(this.value())}}).data("kendoDropDownList"),t._attachDropzoneEvents()},_attachDropzoneEvents:function(){var t=this;t.options.transport.uploadUrl&&(n(e(document.documentElement),e.proxy(t._dropEnter,t),e.proxy(t._dropLeave,t)),t._scrollHandler=f(t._positionDropzone,t))},_dropEnter:function(){this._positionDropzone(),e(document).on("scroll"+x,this._scrollHandler)},_dropLeave:function(){this._removeDropzone(),e(document).off("scroll"+x,this._scrollHandler)},_positionDropzone:function(){var e=this,t=e.element,n=t.offset();e.toolbar.find(".k-dropzone").addClass("k-filebrowser-dropzone").offset(n).css({width:t[0].clientWidth,height:t[0].clientHeight,lineHeight:t[0].clientHeight+"px"})},_removeDropzone:function(){this.toolbar.find(".k-dropzone").removeClass("k-filebrowser-dropzone").css({width:"",height:"",lineHeight:"",top:"",left:""})},_deleteClick:function(){var e=this,t=e.listView.select(),n=d.format(e.options.messages.deleteFile,t.find("strong").text());t.length&&e._showMessage(n,"confirm")&&e.listView.remove(t)},_addClick:function(){this.createDirectory()},_getFieldName:function(e){return r(this.dataSource.reader.model.fields,e)},_fileUpload:function(e){var t,n=this,i=n.options,o=i.fileTypes,r=RegExp(("("+o.split(",").join(")|(")+")").replace(/\*\./g,".*."),"i"),s=e.files[0].name,a=T,l=D;r.test(s)?(e.data={path:n.path()},t=n._createFile(s),t?n.upload.one("success",function(e){var i=n._insertFileToList(t);i.set(a,e.response[n._getFieldName(a)]),i.set(l,e.response[n._getFieldName(l)]),n._tiles=n.listView.items().filter("["+d.attr("type")+"=f]")}):e.preventDefault()):(e.preventDefault(),n._showMessage(d.format(i.messages.invalidFileType,s,o)))},_findFile:function(e){var t,n,i,o=this.dataSource.data(),r=A,s=T;for(e=e.toLowerCase(),t=0,i=o.length;t<i;t++)if("f"===o[t].get(r)&&o[t].get(s).toLowerCase()===e){n=o[t];break}return n},_createFile:function(e){var t=this,n={},i=A,o=t._findFile(e);return o?t._showMessage(d.format(t.options.messages.overwriteFile,e),"confirm")?(o._override=!0,o):null:(n[i]="f",n[T]=e,n[D]=0,n)},_insertFileToList:function(e){var t,n,i,o,r;if(e._override)return e;for(n=this.dataSource,i=n.view(),o=0,r=i.length;o<r;o++)if("f"===i[o].get(A)){t=o;break}return n.insert(++t,e)},createDirectory:function(){var e,t,n=this,i=0,o=A,r=T,s=n.dataSource.data(),a=n._nameDirectory(),l=new n.dataSource.reader.model;for(e=0,t=s.length;e<t;e++)"d"===s[e].get(o)&&(i=e);l.set(o,"d"),l.set(r,a),n.listView.one("dataBound",function(){var e=n.listView.items().filter("["+d.attr("uid")+"="+l.uid+"]"),t=e.find("input");e.length&&this.edit(e),this.element.scrollTop(e.attr("offsetTop")-this.element[0].offsetHeight),setTimeout(function(){t.select()})}).one("save",function(e){var t=e.model.get(r);t?e.model.set(r,n._nameExists(t,l.uid)?n._nameDirectory():t):e.model.set(r,a)}),n.dataSource.insert(++i,l)},_directoryKeyDown:function(e){13==e.keyCode&&e.currentTarget.blur()},_directoryBlur:function(){this.listView.save()},_nameExists:function(e,t){var n,i,o=this.dataSource.data(),r=A,s=T;for(n=0,i=o.length;n<i;n++)if("d"===o[n].get(r)&&o[n].get(s).toLowerCase()===e.toLowerCase()&&o[n].uid!==t)return!0;return!1},_nameDirectory:function(){var t,n,i,o="New folder",r=this.dataSource.data(),s=[],a=A,l=T;for(n=0,i=r.length;n<i;n++)"d"===r[n].get(a)&&r[n].get(l).toLowerCase().indexOf(o.toLowerCase())>-1&&s.push(r[n].get(l));if(e.inArray(o,s)>-1){n=2;do t=o+" ("+n+")",n++;while(e.inArray(t,s)>-1);o=t}return o},orderBy:function(e){this.dataSource.sort([{field:A,dir:"asc"},{field:e,dir:"asc"}])},search:function(e){this.dataSource.filter({field:T,operator:"contains",value:e})},_content:function(){var t=this;t.list=e('<ul class="k-reset k-floats k-tiles" />').appendTo(t.element).on("dblclick"+x,"li",f(t._dblClick,t)),t.listView=new d.ui.ListView(t.list,{dataSource:t.dataSource,template:t._itemTmpl(),editTemplate:t._editTmpl(),selectable:!0,autoBind:!1,dataBinding:function(e){t.toolbar.find(".k-i-close").parent().addClass("k-state-disabled"),"remove"!==e.action&&"sync"!==e.action||e.preventDefault()},dataBound:function(){t.dataSource.view().length?t._tiles=this.items().filter("["+d.attr("type")+"=f]"):this.wrapper.append(M({text:t.options.messages.emptyFolder}))},change:f(t._listViewChange,t)})},_dblClick:function(t){var n,o=this,r=e(t.currentTarget);r.hasClass("k-edit-item")&&o._directoryBlur(),r.filter("["+d.attr("type")+"=d]").length?(n=o.dataSource.getByUid(r.attr(d.attr("uid"))),n&&(o.path(i(o.path(),n.get(T))),o.breadcrumbs.value(o.path()))):r.filter("["+d.attr("type")+"=f]").length&&o.trigger(w)},_listViewChange:function(){var e=this._selectedItem();e&&(this.toolbar.find(".k-i-close").parent().removeClass("k-state-disabled"),this.trigger(b,{selected:e}))},_dataSource:function(){var e,t=this,n=t.options,i=n.transport,o=p({},E),r={field:T,dir:"asc"},s={type:i.type||"filebrowser",sort:[o,r]};h(i)&&(i.path=f(t.path,t),s.transport=i),h(n.schema)?s.schema=n.schema:i.type&&h(d.data.schemas[i.type])&&(e=d.data.schemas[i.type]),t.dataSource&&t._errorHandler?t.dataSource.unbind(y,t._errorHandler):t._errorHandler=f(t._error,t),t.dataSource=d.data.DataSource.create(s).bind(y,t._errorHandler)},_navigation:function(){var t=this,n=e('<div class="k-floatwrap"><input/><input/></div>').appendTo(this.element);t.breadcrumbs=n.find("input:first").kendoBreadcrumbs({value:t.options.path,change:function(){t.path(this.value())}}).data("kendoBreadcrumbs"),t.searchBox=n.parent().find("input:last").kendoSearchBox({label:t.options.messages.search,change:function(){t.search(this.value())}}).data("kendoSearchBox")},_error:function(e){var t,n,i=this;i.trigger(y,e)||(t=e.xhr.status,"error"==e.status?"404"==t?i._showMessage(i.options.messages.directoryNotFound):"0"!=t&&i._showMessage("Error! The requested URL returned "+t+" - "+e.xhr.statusText):"timeout"==t&&i._showMessage("Error! Server timeout."),n=i.dataSource,n.hasChanges()&&n.cancelChanges())},_showMessage:function(e,t){return window[t||"alert"](e)},refresh:function(){var e=this;e._navigation(),e._toolbar(),e._content()},_editTmpl:function(){var e='<li class="k-tile k-state-selected" '+d.attr("uid")+'="#=uid#" ';return e+=d.attr("type")+'="${'+A+'}">',e+="#if("+A+' == "d") { #',e+='<div class="k-thumb"><span class="k-icon k-i-folder"></span></div>',e+="#}else{#",e+='<div class="k-thumb"><span class="k-icon k-i-loading"></span></div>',e+="#}#",e+="#if("+A+' == "d") { #',e+='<input class="k-input" '+d.attr("bind")+'="value:'+T+'"/>',e+="#}#",e+="</li>",f(d.template(e),{sizeFormatter:o})},_itemTmpl:function(){var e='<li class="k-tile" '+d.attr("uid")+'="#=uid#" ';return e+=d.attr("type")+'="${'+A+'}">',e+="#if("+A+' == "d") { #',e+='<div class="k-thumb"><span class="k-icon k-i-folder"></span></div>',e+="#}else{#",e+='<div class="k-thumb"><span class="k-icon k-i-file"></span></div>',e+="#}#",e+="<strong>${"+T+"}</strong>",e+="#if("+A+' == "f") { # <span class="k-filesize">${this.sizeFormatter('+D+")}</span> #}#",e+="</li>",f(d.template(e),{sizeFormatter:o})},path:function(e){var n=this,i=n._path||"";return e!==t?(n._path=e.replace(_,"")+"/",n.dataSource.read({path:n._path}),t):(i&&(i=i.replace(_,"")),"/"===i||""===i?"":i+"/")}}),l=u.extend({init:function(e,t){var n=this;t=t||{},u.fn.init.call(n,e,t),m&&n.element.attr("placeholder",n.options.label),n._wrapper(),n.element.on("keydown"+S,f(n._keydown,n)).on("change"+S,f(n._updateValue,n)),n.wrapper.on(k+S,"a",f(n._click,n)),m||n.element.on("focus"+S,f(n._focus,n)).on("blur"+S,f(n._blur,n))},options:{name:"SearchBox",label:"Search",value:""},events:[b],destroy:function(){var e=this;e.wrapper.add(e.element).add(e.label).off(S),u.fn.destroy.call(e)},_keydown:function(e){13===e.keyCode&&this._updateValue()},_click:function(e){e.preventDefault(),this._updateValue()},_updateValue:function(){var e=this,t=e.element.val();t!==e.value()&&(e.value(t),e.trigger(b))},_blur:function(){this._updateValue(),this._toggleLabel()},_toggleLabel:function(){m||this.label.toggle(!this.element.val())},_focus:function(){this.label.hide()},_wrapper:function(){var t=this.element,n=t.parents(".k-search-wrap");t[0].style.width="",t.addClass("k-input"),n.length||(n=t.wrap(e('<div class="k-widget k-search-wrap k-textbox"/>')).parent(),m||e('<label style="display:block">'+this.options.label+"</label>").insertBefore(t),e('<a href="#" class="k-icon k-i-zoom k-search"/>').appendTo(n)),this.wrapper=n,this.label=n.find(">label")},value:function(e){var n=this;return e!==t?(n.options.value=e,n.element.val(e),n._toggleLabel(),t):n.options.value}}),c=u.extend({init:function(e,t){var n=this;t=t||{},u.fn.init.call(n,e,t),n._wrapper(),n.wrapper.on("focus"+C,"input",f(n._focus,n)).on("blur"+C,"input",f(n._blur,n)).on("keydown"+C,"input",f(n._keydown,n)).on(k+C,"a.k-i-arrow-60-up:first",f(n._rootClick,n)).on(k+C,"a:not(.k-i-arrow-60-up)",f(n._click,n)),n.value(n.options.value)},options:{name:"Breadcrumbs",gap:50},events:[b],destroy:function(){var e=this;u.fn.destroy.call(e),e.wrapper.add(e.wrapper.find("input")).add(e.wrapper.find("a")).off(C)},_update:function(e){e="/"===(e||"").charAt(0)?e:"/"+(e||""),e!==this.value()&&(this.value(e),this.trigger(b))},_click:function(t){t.preventDefault(),this._update(this._path(e(t.target).prevAll("a:not(.k-i-arrow-60-up)").addBack()))},_rootClick:function(e){e.preventDefault(),this._update("")},_focus:function(){var e=this,t=e.element;e.overlay.hide(),e.element.val(e.value()),setTimeout(function(){t.select()})},_blur:function(){if(!this.overlay.is(":visible")){var e=this,t=e.element,n=t.val().replace(/\/{2,}/g,"/");e.overlay.show(),t.val(""),e._update(n)}},_keydown:function(e){var t=this;13===e.keyCode&&(t._blur(),setTimeout(function(){t.overlay.find("a:first").focus()}))},_wrapper:function(){var t,n=this.element,i=n.parents(".k-breadcrumbs");n[0].style.width="",n.addClass("k-input"),i.length||(i=n.wrap(e('<div class="k-widget k-breadcrumbs k-textbox"/>')).parent()),t=i.find(".k-breadcrumbs-wrap"),t.length||(t=e('<div class="k-breadcrumbs-wrap"/>').appendTo(i)),this.wrapper=i,this.overlay=t},refresh:function(){var n,i,o,r,s="",a=this.value();for(a!==t&&a.match(/^\//)||(a="/"+(a||"")),n=a.split("/"),o=0,r=n.length;o<r;o++)i=n[o],i&&(s||(s+='<a href="#" class="k-icon k-i-arrow-60-up" title="Go to parent folder"></a>'),s+='<a class="k-link" href="#">'+n[o]+"</a>",s+='<span class="k-icon k-i-arrow-60-right" title="Go to child folder"></span>');this.overlay.empty().append(e(s)),this._adjustSectionWidth()},_adjustSectionWidth:function(){var t,n=this,i=n.wrapper,o=i.width()-n.options.gap,r=n.overlay.find("a");r.each(function(n){t=e(this),t.parent().width()>o&&(n==r.length-1?t.width(o):t.prev().addBack().hide())})},value:function(e){return e!==t?(this._value=e.replace(/\/{2,}/g,"/"),this.refresh(),t):this._value},_path:function(t){return"/"+e.map(t,function(t){return e(t).text()}).join("/")}}),d.ui.plugin(a),d.ui.plugin(c),d.ui.plugin(l)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.imagebrowser.min",["kendo.filebrowser.min"],e)}(function(){return function(e,t){function n(e,n){return e!==t&&e.match(/\/$/)||(e=(e||"")+"/"),e+n}function i(e){if(!e)return"";var t=" bytes";return e>=1073741824?(t=" GB",e/=1073741824):e>=1048576?(t=" MB",e/=1048576):e>=1024&&(t=" KB",e/=1024),Math.round(100*e)/100+t}var o,r,s=window.kendo,a=s.ui.FileBrowser,l=e.isPlainObject,c=e.proxy,d=e.extend,u=s.support.browser,h=s.isFunction,f=/(^\/|\/$)/g,p="error",m=".kendoImageBrowser",g="name",v="size",_="type",b={field:_,dir:"asc"},w=s.template('<li class="k-tile-empty"><strong>${text}</strong></li>');d(!0,s.data,{schemas:{imagebrowser:{data:function(e){return e.items||e||[]},model:{id:"name",fields:{name:"name",size:"size",type:"type"}}}}}),d(!0,s.data,{transports:{imagebrowser:s.data.RemoteTransport.extend({init:function(t){s.data.RemoteTransport.fn.init.call(this,e.extend(!0,{},this.options,t))},_call:function(t,n){n.data=e.extend({},n.data,{path:this.options.path()}),h(this.options[t])?this.options[t].call(this,n):s.data.RemoteTransport.fn[t].call(this,n)},read:function(e){this._call("read",e)},create:function(e){this._call("create",e)},destroy:function(e){this._call("destroy",e)},update:function(){},options:{read:{type:"POST"},update:{type:"POST"},create:{type:"POST"},destroy:{type:"POST"}}})}}),o=u.msie&&u.version<8?function(e){return e.offsetTop}:function(t){return t.offsetTop-e(t).height()},r=a.extend({init:function(e,t){var n=this;t=t||{},a.fn.init.call(n,e,t),n.element.addClass("k-imagebrowser")},options:{name:"ImageBrowser",fileTypes:"*.png,*.gif,*.jpg,*.jpeg"},value:function(){var e,t=this,i=t._selectedItem(),o=t.options.transport.imageUrl;if(i&&"f"===i.get(_))return e=n(t.path(),i.get(g)).replace(f,""),o&&(e=h(o)?o(e):s.format(o,encodeURIComponent(e))),e},_fileUpload:function(e){var t,n=this,i=n.options,o=i.fileTypes,r=RegExp(("("+o.split(",").join(")|(")+")").replace(/\*\./g,".*."),"i"),a=e.files[0].name,l=g,c=v;r.test(a)?(e.data={path:n.path()},t=n._createFile(a),t?(t._uploading=!0,n.upload.one("success",function(e){delete t._uploading;var i=n._insertFileToList(t);i.set(l,e.response[n._getFieldName(l)]),i.set(c,e.response[n._getFieldName(c)]),n._tiles=n.listView.items().filter("["+s.attr("type")+"=f]"),n._scroll()})):e.preventDefault()):(e.preventDefault(),n._showMessage(s.format(i.messages.invalidFileType,a,o)))},_content:function(){var t=this;t.list=e('<ul class="k-reset k-floats k-tiles" />').appendTo(t.element).on("scroll"+m,c(t._scroll,t)).on("dblclick"+m,"li",c(t._dblClick,t)),t.listView=new s.ui.ListView(t.list,{dataSource:t.dataSource,template:t._itemTmpl(),editTemplate:t._editTmpl(),selectable:!0,autoBind:!1,dataBinding:function(e){t.toolbar.find(".k-i-close").parent().addClass("k-state-disabled"),"remove"!==e.action&&"sync"!==e.action||e.preventDefault()},dataBound:function(){t.dataSource.view().length?(t._tiles=this.items().filter("["+s.attr("type")+"=f]"),t._scroll()):this.wrapper.append(w({text:t.options.messages.emptyFolder}))},change:c(t._listViewChange,t)})},_dataSource:function(){var e,t=this,n=t.options,i=n.transport,o=d({},b),r={field:g,dir:"asc"},a={type:i.type||"imagebrowser",sort:[o,r]};l(i)&&(i.path=c(t.path,t),a.transport=i),l(n.schema)?a.schema=n.schema:i.type&&l(s.data.schemas[i.type])&&(e=s.data.schemas[i.type]),t.dataSource&&t._errorHandler?t.dataSource.unbind(p,t._errorHandler):t._errorHandler=c(t._error,t),t.dataSource=s.data.DataSource.create(a).bind(p,t._errorHandler)},_loadImage:function(t){var n=this,i=e(t),o=n.dataSource.getByUid(i.attr(s.attr("uid"))),r=o.get(g),a=n.options.transport.thumbnailUrl,l=e("<img />",{alt:r}),c="?";o._uploading||(l.hide().on("load"+m,function(){e(this).prev().remove().end().addClass("k-image").fadeIn()}),i.find(".k-i-loading").after(l),h(a)?a=a(n.path(),encodeURIComponent(r)):(a.indexOf("?")>=0&&(c="&"),a=a+c+"path="+encodeURIComponent(n.path()+r),o._override&&(a+="&_="+(new Date).getTime(),delete o._override)),l.attr("src",a),t.loaded=!0)},_scroll:function(){var e=this;e.options.transport&&e.options.transport.thumbnailUrl&&(clearTimeout(e._timeout),e._timeout=setTimeout(function(){var t=s._outerHeight(e.list),n=e.list.scrollTop(),i=n+t;e._tiles.each(function(){var t=o(this),r=t+this.offsetHeight;if((t>=n&&t<i||r>=n&&r<i)&&e._loadImage(this),t>i)return!1}),e._tiles=e._tiles.filter(function(){return!this.loaded})},250))},_itemTmpl:function(){var e=this,t='<li class="k-tile" '+s.attr("uid")+'="#=uid#" ';return t+=s.attr("type")+'="${'+_+'}">',t+="#if("+_+' == "d") { #',t+='<div class="k-thumb"><span class="k-icon k-i-folder"></span></div>',t+="#}else{#",t+=e.options.transport&&e.options.transport.thumbnailUrl?'<div class="k-thumb"><span class="k-icon k-i-loading"></span></div>':'<div class="k-thumb"><span class="k-icon k-i-file"></span></div>',t+="#}#",t+="<strong>${"+g+"}</strong>",t+="#if("+_+' == "f") { # <span class="k-filesize">${this.sizeFormatter('+v+")}</span> #}#",t+="</li>",c(s.template(t),{sizeFormatter:i})}}),s.ui.plugin(r)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.tabstrip.min",["kendo.data.min"],e)}(function(){return function(e,t){function n(t){t.children(b).addClass(A),t.children("a").addClass(x).children(b).addClass(A),t.filter(":not([disabled]):not([class*=k-state-disabled])").addClass(H),t.filter("li[disabled]").addClass(L).removeAttr("disabled"),t.filter(":not([class*=k-state])").children("a").filter(":focus").parent().addClass(N+" "+U),t.attr("role","tab"),t.filter("."+N).attr("aria-selected",!0),t.each(function(){var t=e(this);t.children("."+x).length||t.contents().filter(function(){return!(this.nodeName.match(v)||3==this.nodeType&&!d(this.nodeValue))}).wrapAll("<span UNSELECTABLE='on' class='"+x+"'/>")})}function i(e){var t=e.children(".k-item");t.filter(".k-first:not(:first-child)").removeClass(E),t.filter(".k-last:not(:last-child)").removeClass(C),t.filter(":first-child").addClass(E),t.filter(":last-child").addClass(C)}function o(e,t){return"<span class='k-button k-button-icon k-bare k-tabstrip-"+e+"' unselectable='on'><span class='k-icon "+t+"'></span></span>"}var r=window.kendo,s=r.ui,a=r.keys,l=e.map,c=e.each,d=e.trim,u=e.extend,h=r.isFunction,f=r.template,p=r._outerWidth,m=r._outerHeight,g=s.Widget,v=/^(a|div)$/i,_=".kendoTabStrip",b="img",w="href",y="prev",k="show",x="k-link",C="k-last",S="click",T="error",D=":empty",A="k-image",E="k-first",M="select",I="activate",R="k-content",F="contentUrl",z="mouseenter",P="mouseleave",B="contentLoad",L="k-state-disabled",H="k-state-default",N="k-state-active",O="k-state-focused",V="k-state-hover",U="k-tab-on-top",W=".k-item:not(."+L+")",q=".k-tabstrip-items > "+W+":not(."+N+")",j={content:f("<div class='k-content'#= contentAttributes(data) # role='tabpanel'>#= content(item) #</div>"),itemWrapper:f("<#= tag(item) # class='k-link'#= contentUrl(item) ##= textAttributes(item) #>#= image(item) ##= sprite(item) ##= text(item) #</#= tag(item) #>"),item:f("<li class='#= wrapperCssClass(group, item) #' role='tab' #=item.active ? \"aria-selected='true'\" : ''#>#= itemWrapper(data) #</li>"),image:f("<img class='k-image' alt='' src='#= imageUrl #' />"),sprite:f("<span class='k-sprite #= spriteCssClass #'></span>"),empty:f("")},G={wrapperCssClass:function(e,t){var n="k-item",i=t.index;return n+=t.enabled===!1?" k-state-disabled":" k-state-default",0===i&&(n+=" k-first"),i==e.length-1&&(n+=" k-last"),n},textAttributes:function(e){return e.url?" href='"+e.url+"'":""},text:function(e){return e.encoded===!1?e.text:r.htmlEncode(e.text)},tag:function(e){return e.url?"a":"span"},contentAttributes:function(e){return e.active!==!0?" style='display:none' aria-hidden='true' aria-expanded='false'":""},content:function(e){return e.content?e.content:e.contentUrl?"":"&nbsp;"},contentUrl:function(e){return e.contentUrl?r.attr("content-url")+'="'+e.contentUrl+'"':""}},$=g.extend({init:function(t,n){var i,o,s,a=this;g.fn.init.call(a,t,n),a._animations(a.options),n=a.options,a._contentUrls=n.contentUrls||[],a._wrapper(),a._isRtl=r.support.isRtl(a.wrapper),a._tabindex(),a._updateClasses(),a._dataSource(),n.dataSource&&a.dataSource.fetch(),a._tabPosition(),a._scrollable(),a._contentUrls.length?a.wrapper.find(".k-tabstrip-items > .k-item").each(function(t,n){var i=a._contentUrls[t];"string"==typeof i&&e(n).find(">."+x).data(F,i)}):a._contentUrls.length=a.tabGroup.find("li.k-item").length,a.wrapper.on(z+_+" "+P+_,q,a._toggleHover).on("focus"+_,e.proxy(a._active,a)).on("blur"+_,function(){a._current(null)}),a._keyDownProxy=e.proxy(a._keydown,a),n.navigatable&&a.wrapper.on("keydown"+_,a._keyDownProxy),a.options.value&&(i=a.options.value),a.wrapper.children(".k-tabstrip-items").on(S+_,".k-state-disabled .k-link",!1).on(S+_," > "+W,function(t){var n,i=a.wrapper[0];if(i!==document.activeElement)if(n=r.support.browser.msie)try{i.setActive()}catch(o){i.focus()}else i.focus();a._click(e(t.currentTarget))&&t.preventDefault()}),o=a.tabGroup.children("li."+N),s=a.contentHolder(o.index()),o[0]&&s.length>0&&0===s[0].childNodes.length&&a.activateTab(o.eq(0)),a.element.attr("role","tablist"),a.element[0].id&&(a._ariaId=a.element[0].id+"_ts_active"),a.value(i),r.notify(a)},_active:function(){var e=this.tabGroup.children().filter("."+N);e=e[0]?e:this._endItem("first"),e[0]&&this._current(e)},_endItem:function(e){return this.tabGroup.children(W)[e]()},_item:function(e,t){var n;return n=t===y?"last":"first",e?(e=e[t](),e[0]||(e=this._endItem(n)),e.hasClass(L)&&(e=this._item(e,t)),e):this._endItem(n)},_current:function(e){var n=this,i=n._focused,o=n._ariaId;return e===t?i:(i&&(i[0].id===o&&i.removeAttr("id"),i.removeClass(O)),e&&(e.hasClass(N)||e.addClass(O),n.element.removeAttr("aria-activedescendant"),o=e[0].id||o,o&&(e.attr("id",o),n.element.attr("aria-activedescendant",o))),n._focused=e,t)},_keydown:function(e){var n,i=this,o=e.keyCode,r=i._current(),s=i._isRtl;if(e.target==e.currentTarget){if(o==a.DOWN||o==a.RIGHT)n=s?y:"next";else if(o==a.UP||o==a.LEFT)n=s?"next":y;else if(o==a.ENTER||o==a.SPACEBAR)i._click(r),e.preventDefault();else{if(o==a.HOME)return i._click(i._endItem("first")),e.preventDefault(),t;if(o==a.END)return i._click(i._endItem("last")),e.preventDefault(),t}n&&(i._click(i._item(r,n)),e.preventDefault())}},_dataSource:function(){var t=this;t.dataSource&&t._refreshHandler?t.dataSource.unbind("change",t._refreshHandler):t._refreshHandler=e.proxy(t.refresh,t),t.dataSource=r.data.DataSource.create(t.options.dataSource).bind("change",t._refreshHandler)},setDataSource:function(e){var t=this;t.options.dataSource=e,t._dataSource(),t.dataSource.fetch()},_animations:function(e){e&&"animation"in e&&!e.animation&&(e.animation={open:{effects:{}},close:{effects:{}}})},refresh:function(e){var t,n,i,o,s=this,a=s.options,l=r.getter(a.dataTextField),c=r.getter(a.dataContentField),d=r.getter(a.dataContentUrlField),u=r.getter(a.dataImageUrlField),h=r.getter(a.dataUrlField),f=r.getter(a.dataSpriteCssClass),p=[],m=s.dataSource.view();for(e=e||{},i=e.action,i&&(m=e.items),t=0,o=m.length;t<o;t++)n={text:l(m[t])},a.dataContentField&&(n.content=c(m[t])),a.dataContentUrlField&&(n.contentUrl=d(m[t])),a.dataUrlField&&(n.url=h(m[t])),a.dataImageUrlField&&(n.imageUrl=u(m[t])),a.dataSpriteCssClass&&(n.spriteCssClass=f(m[t])),p[t]=n;if("add"==e.action)e.index<s.tabGroup.children().length?s.insertBefore(p,s.tabGroup.children().eq(e.index)):s.append(p);else if("remove"==e.action)for(t=0;t<m.length;t++)s.remove(e.index);else"itemchange"==e.action?(t=s.dataSource.view().indexOf(m[0]),e.field===a.dataTextField&&s.tabGroup.children().eq(t).find(".k-link").text(m[0].get(e.field)),e.field===a.dataUrlField&&(s._contentUrls[t]=m[0].get(e.field))):(s.trigger("dataBinding"),s.remove("li"),s._contentUrls=[],s.append(p),s.trigger("dataBound"))},value:function(n){var i=this;return n===t?i.select().text():(n!=i.value()&&i.tabGroup.children().each(function(){e.trim(e(this).text())==n&&i.select(this)}),t)},items:function(){return this.tabGroup[0].children},setOptions:function(e){var t=this,n=t.options.animation;t._animations(e),e.contentUrls&&(t._contentUrls=e.contentUrls),e.animation=u(!0,n,e.animation),e.navigatable?t.wrapper.on("keydown"+_,t._keyDownProxy):t.wrapper.off("keydown"+_,t._keyDownProxy),g.fn.setOptions.call(t,e)},events:[M,I,k,T,B,"change","dataBinding","dataBound"],options:{name:"TabStrip",dataTextField:"",dataContentField:"",dataImageUrlField:"",dataUrlField:"",dataSpriteCssClass:"",dataContentUrlField:"",tabPosition:"top",animation:{open:{effects:"expand:vertical fadeIn",duration:200},close:{duration:200}},collapsible:!1,navigatable:!0,contentUrls:!1,scrollable:{distance:200}},destroy:function(){var e=this,t=e.scrollWrap;g.fn.destroy.call(e),e._refreshHandler&&e.dataSource.unbind("change",e._refreshHandler),e.wrapper.off(_),e.wrapper.children(".k-tabstrip-items").off(_),e._scrollableModeActive&&(e._scrollPrevButton.off().remove(),e._scrollNextButton.off().remove()),r.destroy(e.wrapper),t.children(".k-tabstrip").unwrap()},select:function(t){var n=this;return 0===arguments.length?n.tabGroup.children("li."+N):(isNaN(t)||(t=n.tabGroup.children().get(t)),t=n.tabGroup.find(t),e(t).each(function(t,i){i=e(i),i.hasClass(N)||n.trigger(M,{item:i[0],contentElement:n.contentHolder(i.index())[0]})||n.activateTab(i)}),n)},enable:function(e,t){return this._toggleDisabled(e,t!==!1),this},disable:function(e){return this._toggleDisabled(e,!1),this},reload:function(t){var n,i;return t=this.tabGroup.find(t),n=this,i=n._contentUrls,t.each(function(){var t=e(this),o=t.find("."+x).data(F)||i[t.index()],r=n.contentHolder(t.index());o&&n.ajaxRequest(t,r,null,o)}),n},append:function(e){var t=this,n=t._create(e);return c(n.tabs,function(e){var i=n.contents[e];t.tabGroup.append(this),"bottom"==t.options.tabPosition?t.tabGroup.before(i):t._scrollableModeActive?t._scrollPrevButton.before(i):t.wrapper.append(i),t.angular("compile",function(){return{elements:[i]}})}),i(t.tabGroup),t._updateContentElements(),t.resize(!0),t},_appendUrlItem:function(e){this._contentUrls.push(e)},_moveUrlItem:function(e,t){this._contentUrls.splice(t,0,this._contentUrls.splice(e,1)[0])},_removeUrlItem:function(e){this._contentUrls.splice(e,1)},insertBefore:function(t,n){n=e(t).is(e(n))?this.tabGroup.find(n).next():this.tabGroup.find(n);var o=this,r=o._create(t),s=o.element.find("#"+n.attr("aria-controls"));return c(r.tabs,function(t){var i=r.contents[t],a=r.newTabsCreated?o._contentUrls.length-(r.tabs.length-t):e(i).index()-1;n.before(this),s.before(i),o._moveUrlItem(a,e(this).index()),o.angular("compile",function(){return{elements:[i]}})}),i(o.tabGroup),o._updateContentElements(r.newTabsCreated),o.resize(!0),o},insertAfter:function(t,n){n=e(t).is(e(n))?this.tabGroup.find(n).prev():this.tabGroup.find(n);var o=this,r=o._create(t),s=o.element.find("#"+n.attr("aria-controls"));return c(r.tabs,function(t){var i=r.contents[t],a=r.newTabsCreated?o._contentUrls.length-(r.tabs.length-t):e(i).index()-1;n.after(this),s.after(i),o._moveUrlItem(a,e(this).index()),o.angular("compile",function(){return{elements:[i]}})}),i(o.tabGroup),o._updateContentElements(r.newTabsCreated),o.resize(!0),o},remove:function(t){var n,i=this,o=typeof t;return"string"===o?t=i.tabGroup.find(t):"number"===o&&(t=i.tabGroup.children().eq(t)),n=t.map(function(){var t=e(this).index(),n=i.contentElement(t);return r.destroy(n),i._removeUrlItem(t),n}),t.remove(),n.empty(),n.remove(),i._updateContentElements(),i.resize(!0),i},_create:function(t){var i,o,s,a=this,c=!1;return t=t instanceof r.data.ObservableArray?t.toJSON():t,e.isPlainObject(t)||e.isArray(t)?(t=e.isArray(t)?t:[t],c=!0,i=l(t,function(n,i){return a._appendUrlItem(t[i].contentUrl||null),e($.renderItem({group:a.tabGroup,item:u(n,{index:i})}))}),o=l(t,function(t,n){if("string"==typeof t.content||t.contentUrl)return e($.renderContent({item:u(t,{index:n})}))})):(i="string"==typeof t&&"<"!=t[0]?a.element.find(t):e(t),o=e(),i.each(function(){if(/k-tabstrip-items/.test(this.parentNode.className)){var t=a.element.find("#"+this.getAttribute("aria-controls"));s=t}else s=e("<div class='"+R+"'/>");o=o.add(s)}),n(i)),{tabs:i,contents:o,newTabsCreated:c}},_toggleDisabled:function(t,n){t=this.tabGroup.find(t),t.each(function(){e(this).toggleClass(H,n).toggleClass(L,!n)})},_updateClasses:function(){var o,r,s,a=this;a.wrapper.addClass("k-widget k-header k-tabstrip"),a.tabGroup=a.wrapper.children("ul").addClass("k-tabstrip-items k-reset"),
a.tabGroup[0]||(a.tabGroup=e("<ul class='k-tabstrip-items k-reset'/>").appendTo(a.wrapper)),o=a.tabGroup.find("li").addClass("k-item"),o.length&&(r=o.filter("."+N).index(),s=r>=0?r:t,a.tabGroup.contents().filter(function(){return 3==this.nodeType&&!d(this.nodeValue)}).remove()),r>=0&&o.eq(r).addClass(U),a.contentElements=a.wrapper.children("div"),a.contentElements.addClass(R).eq(s).addClass(N).css({display:"block"}),o.length&&(n(o),i(a.tabGroup),a._updateContentElements(!0))},_elementId:function(e,t){var n,i=e.attr("id"),o=this.element.attr("id");return!i||i.indexOf(o+"-")>-1?(n=(o||r.guid())+"-",n+(t+1)):i},_updateContentElements:function(t){var n=this,i=n._contentUrls,o=n.tabGroup.children(".k-item"),s=n.wrapper.children("div"),a=n._elementId.bind(n);s.length&&o.length>s.length?s.each(function(n){var i=a(e(this),n),r=o.filter("[aria-controls="+(this.id||0)+"]")[0];!r&&t&&(r=o[n]),r&&r.setAttribute("aria-controls",i),this.setAttribute("id",i)}):o.each(function(t){var o=s.eq(t),r=a(o,t);this.setAttribute("aria-controls",r),!o.length&&i[t]?e("<div class='"+R+"'/>").appendTo(n.wrapper).attr("id",r):(o.attr("id",r),e(this).children(".k-loading")[0]||i[t]||e("<span class='k-loading k-complete'/>").prependTo(this)),o.attr("role","tabpanel"),o.filter(":not(."+N+")").attr("aria-hidden",!0).attr("aria-expanded",!1),o.filter("."+N).attr("aria-expanded",!0)}),n.contentElements=n.contentAnimators=n.wrapper.children("div"),n.tabsHeight=m(n.tabGroup)+parseInt(n.wrapper.css("border-top-width"),10)+parseInt(n.wrapper.css("border-bottom-width"),10),r.kineticScrollNeeded&&r.mobile.ui.Scroller&&(r.touchScroller(n.contentElements),n.contentElements=n.contentElements.children(".km-scroll-container"))},_wrapper:function(){var e=this;e.wrapper=e.element.is("ul")?e.element.wrapAll("<div />").parent():e.element,e.scrollWrap=e.wrapper.parent(".k-tabstrip-wrapper"),e.scrollWrap[0]||(e.scrollWrap=e.wrapper.wrapAll("<div class='k-tabstrip-wrapper' />").parent())},_tabPosition:function(){var e=this,t=e.options.tabPosition;e.wrapper.addClass("k-floatwrap k-tabstrip-"+t),"bottom"==t&&e.tabGroup.appendTo(e.wrapper),e.resize(!0)},_setContentElementsDimensions:function(){var e,t,n,i,o,r,s=this,a=s.options.tabPosition;"left"!=a&&"right"!=a||(e=s.wrapper.children(".k-content"),t=e.filter(":visible"),n="margin-"+a,i=s.tabGroup,o=p(i),r=Math.ceil(i.height())-parseInt(t.css("padding-top"),10)-parseInt(t.css("padding-bottom"),10)-parseInt(t.css("border-top-width"),10)-parseInt(t.css("border-bottom-width"),10),setTimeout(function(){e.css(n,o).css("min-height",r)}))},_resize:function(){this._setContentElementsDimensions(),this._scrollable()},_sizeScrollWrap:function(e){var t,n;e.is(":visible")&&(t=this.options.tabPosition,n=Math.floor(m(e,!0))+("left"===t||"right"===t?2:this.tabsHeight),this.scrollWrap.css("height",n).css("height"))},_toggleHover:function(t){e(t.currentTarget).toggleClass(V,t.type==z)},_click:function(e){var t,n,i=this,o=e.find("."+x),r=o.attr(w),s=i.options.collapsible,a=e.index(),l=i.contentHolder(a);if(e.closest(".k-widget")[0]==i.wrapper[0]){if(e.is("."+L+(s?"":",."+N)))return!0;if(n=o.data(F)||i._contentUrls[a]||r&&("#"==r.charAt(r.length-1)||r.indexOf("#"+i.element[0].id+"-")!=-1),t=!r||n,i.tabGroup.children("[data-animating]").length)return t;if(i.trigger(M,{item:e[0],contentElement:l[0]}))return!0;if(t!==!1)return s&&e.is("."+N)?(i.deactivateTab(e),!0):(i.activateTab(e)&&(t=!0),t)}},_scrollable:function(){var e,t,n,i,s,a,l=this,c=l.options;l._scrollableAllowed()&&(l.wrapper.addClass("k-tabstrip-scrollable"),e=l.wrapper[0].offsetWidth,t=l.tabGroup[0].scrollWidth,t>e&&!l._scrollableModeActive?(l._nowScrollingTabs=!1,l._isRtl=r.support.isRtl(l.element),s=r.support.mobileOS?"touchstart":"mousedown",a=r.support.mobileOS?"touchend":"mouseup",l.wrapper.append(o("prev","k-i-arrow-60-left")+o("next","k-i-arrow-60-right")),n=l._scrollPrevButton=l.wrapper.children(".k-tabstrip-prev"),i=l._scrollNextButton=l.wrapper.children(".k-tabstrip-next"),l.tabGroup.css({marginLeft:p(n)+9,marginRight:p(i)+12}),n.on(s+_,function(){l._nowScrollingTabs=!0,l._scrollTabsByDelta(c.scrollable.distance*(l._isRtl?1:-1))}),i.on(s+_,function(){l._nowScrollingTabs=!0,l._scrollTabsByDelta(c.scrollable.distance*(l._isRtl?-1:1))}),n.add(i).on(a+_,function(){l._nowScrollingTabs=!1}),l._scrollableModeActive=!0,l._toggleScrollButtons()):l._scrollableModeActive&&t<=e?(l._scrollableModeActive=!1,l.wrapper.removeClass("k-tabstrip-scrollable"),l._scrollPrevButton.off().remove(),l._scrollNextButton.off().remove(),l.tabGroup.css({marginLeft:"",marginRight:""})):l._scrollableModeActive?l._toggleScrollButtons():l.wrapper.removeClass("k-tabstrip-scrollable"))},_scrollableAllowed:function(){var e=this.options;return e.scrollable&&!isNaN(e.scrollable.distance)&&("top"==e.tabPosition||"bottom"==e.tabPosition)},_scrollTabsToItem:function(e){var t,n=this,i=n.tabGroup,o=i.scrollLeft(),r=p(e),s=n._isRtl?e.position().left:e.position().left-i.children().first().position().left,a=i[0].offsetWidth,l=Math.ceil(parseFloat(i.css("padding-left")));n._isRtl?s<0?t=o+s-(a-o)-l:s+r>a&&(t=o+s-r+2*l):o+a<s+r?t=s+r-a+2*l:o>s&&(t=s-l),i.finish().animate({scrollLeft:t},"fast","linear",function(){n._toggleScrollButtons()})},_scrollTabsByDelta:function(e){var t=this,n=t.tabGroup,i=n.scrollLeft();n.finish().animate({scrollLeft:i+e},"fast","linear",function(){t._nowScrollingTabs?t._scrollTabsByDelta(e):t._toggleScrollButtons()})},_toggleScrollButtons:function(){var e=this,t=e.tabGroup,n=t.scrollLeft();e._scrollPrevButton.toggle(e._isRtl?n<t[0].scrollWidth-t[0].offsetWidth-1:0!==n),e._scrollNextButton.toggle(e._isRtl?0!==n:n<t[0].scrollWidth-t[0].offsetWidth-1)},deactivateTab:function(e){var t=this,n=t.options.animation,i=n.open,o=u({},n.close),s=o&&"effects"in o;e=t.tabGroup.find(e),o=u(s?o:u({reverse:!0},i),{hide:!0}),r.size(i.effects)?(e.kendoAddClass(H,{duration:i.duration}),e.kendoRemoveClass(N,{duration:i.duration})):(e.addClass(H),e.removeClass(N)),e.removeAttr("aria-selected"),t.contentAnimators.filter("."+N).kendoStop(!0,!0).kendoAnimate(o).removeClass(N).attr("aria-hidden",!0)},activateTab:function(e){var t,n,i,o,s,a,l,c,d,h,f,p,g,v,_;if(!this.tabGroup.children("[data-animating]").length)return e=this.tabGroup.find(e),t=this,n=t.options.animation,i=n.open,o=u({},n.close),s=o&&"effects"in o,a=e.parent().children(),l=a.filter("."+N),c=a.index(e),o=u(s?o:u({reverse:!0},i),{hide:!0}),r.size(i.effects)?(l.kendoRemoveClass(N,{duration:o.duration}),e.kendoRemoveClass(V,{duration:o.duration})):(l.removeClass(N),e.removeClass(V)),d=t.contentAnimators,t.inRequest&&(t.xhr.abort(),t.inRequest=!1),0===d.length?(t.tabGroup.find("."+U).removeClass(U),e.addClass(U).css("z-index"),e.addClass(N),t._current(e),t.trigger("change"),t._scrollableModeActive&&t._scrollTabsToItem(e),!1):(h=d.filter("."+N),f=t.contentHolder(c),p=f.closest(".k-content"),t.tabsHeight=m(t.tabGroup)+parseInt(t.wrapper.css("border-top-width"),10)+parseInt(t.wrapper.css("border-bottom-width"),10),t._sizeScrollWrap(h),0===f.length?(h.removeClass(N).attr("aria-hidden",!0).kendoStop(!0,!0).kendoAnimate(o),!1):(e.attr("data-animating",!0),g=(e.children("."+x).data(F)||t._contentUrls[c]||!1)&&f.is(D),v=function(){t.tabGroup.find("."+U).removeClass(U),e.addClass(U).css("z-index"),r.size(i.effects)?(l.kendoAddClass(H,{duration:i.duration}),e.kendoAddClass(N,{duration:i.duration})):(l.addClass(H),e.addClass(N)),l.removeAttr("aria-selected"),e.attr("aria-selected",!0),t._current(e),t._sizeScrollWrap(p),p.addClass(N).removeAttr("aria-hidden").kendoStop(!0,!0).attr("aria-expanded",!0).kendoAnimate(u({init:function(){t.trigger(k,{item:e[0],contentElement:f[0]}),r.resize(f)}},i,{complete:function(){e.removeAttr("data-animating"),t.trigger(I,{item:e[0],contentElement:f[0]}),r.resize(f),t.scrollWrap.css("height","").css("height")}}))},_=function(){g?(e.removeAttr("data-animating"),t.ajaxRequest(e,f,function(){e.attr("data-animating",!0),v(),t.trigger("change")})):(v(),t.trigger("change")),t._scrollableModeActive&&t._scrollTabsToItem(e)},h.removeClass(N),h.attr("aria-hidden",!0),h.attr("aria-expanded",!1),h.length?h.kendoStop(!0,!0).kendoAnimate(u({complete:_},o)):_(),!0))},contentElement:function(n){var i,o,s,a;if(isNaN(n-0))return t;if(i=this.contentElements&&this.contentElements[0]&&!r.kineticScrollNeeded?this.contentElements:this.contentAnimators,o=e(this.tabGroup.children()[n]).attr("aria-controls"),i)for(s=0,a=i.length;s<a;s++)if(i.eq(s).closest(".k-content")[0].id==o)return i[s];return t},contentHolder:function(t){var n=e(this.contentElement(t)),i=n.children(".km-scroll-container");return r.support.touch&&i[0]?i:n},ajaxRequest:function(t,n,i,o){var s,a,l,c,d,u,f,p,m,g;t=this.tabGroup.find(t),s=this,a=e.ajaxSettings.xhr,l=t.find("."+x),c={},d=t.width()/2,u=!1,f=t.find(".k-loading").removeClass("k-complete"),f[0]||(f=e("<span class='k-loading'/>").prependTo(t)),p=2*d-f.width(),m=function(){f.animate({marginLeft:(parseInt(f.css("marginLeft"),10)||0)<d?p:0},500,m)},r.support.browser.msie&&r.support.browser.version<10&&setTimeout(m,40),o=o||l.data(F)||s._contentUrls[t.index()]||l.attr(w),s.inRequest=!0,g={type:"GET",cache:!1,url:o,dataType:"html",data:c,xhr:function(){var t=this,n=a(),i=t.progressUpload?"progressUpload":!!t.progress&&"progress";return n&&e.each([n,n.upload],function(){this.addEventListener&&this.addEventListener("progress",function(e){i&&t[i](e)},!1)}),t.noProgress=!(window.XMLHttpRequest&&"upload"in new XMLHttpRequest),n},progress:function(e){if(e.lengthComputable){var t=parseInt(e.loaded/e.total*100,10)+"%";f.stop(!0).addClass("k-progress").css({width:t,marginLeft:0})}},error:function(e,t){s.trigger("error",{xhr:e,status:t})&&this.complete()},stopProgress:function(){clearInterval(u),f.stop(!0).addClass("k-progress")[0].style.cssText=""},complete:function(e){s.inRequest=!1,this.noProgress?setTimeout(this.stopProgress,500):this.stopProgress(),"abort"==e.statusText&&f.remove()},success:function(e){var a,l,c;f.addClass("k-complete");try{a=this,l=10,a.noProgress&&(f.width(l+"%"),u=setInterval(function(){a.progress({lengthComputable:!0,loaded:Math.min(l,100),total:100}),l+=10},40)),s.angular("cleanup",function(){return{elements:n.get()}}),r.destroy(n),n.html(e)}catch(d){c=window.console,c&&c.error&&c.error(d.name+": "+d.message+" in "+o),this.error(this.xhr,"error")}i&&i.call(s,n),s.angular("compile",function(){return{elements:n.get()}}),s.trigger(B,{item:t[0],contentElement:n[0]})}},"object"==typeof o&&(g=e.extend(!0,{},g,o),h(g.url)&&(g.url=g.url())),s.xhr=e.ajax(g)}});u($,{renderItem:function(e){e=u({tabStrip:{},group:{}},e);var t=j.empty,n=e.item;return j.item(u(e,{image:n.imageUrl?j.image:t,sprite:n.spriteCssClass?j.sprite:t,itemWrapper:j.itemWrapper},G))},renderContent:function(e){return j.content(u(e,G))}}),r.ui.plugin($)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("util/undoredostack.min",["kendo.core.min"],e)}(function(){!function(e){var t=e.Observable.extend({init:function(t){e.Observable.fn.init.call(this,t),this.clear()},events:["undo","redo"],push:function(e){this.stack=this.stack.slice(0,this.currentCommandIndex+1),this.currentCommandIndex=this.stack.push(e)-1},undo:function(){if(this.canUndo()){var e=this.stack[this.currentCommandIndex--];e.undo(),this.trigger("undo",{command:e})}},redo:function(){if(this.canRedo()){var e=this.stack[++this.currentCommandIndex];e.redo(),this.trigger("redo",{command:e})}},clear:function(){this.stack=[],this.currentCommandIndex=-1},canUndo:function(){return this.currentCommandIndex>=0},canRedo:function(){return this.currentCommandIndex!=this.stack.length-1}});e.deepExtend(e,{util:{UndoRedoStack:t}})}(kendo)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("editor/main.min",["util/undoredostack.min","kendo.combobox.min","kendo.dropdownlist.min","kendo.window.min","kendo.colorpicker.min"],e)}(function(){!function(e,t){var n,i,o,r,s,a=window.kendo,l=a.Class,c=a.ui.Widget,d=a.support.mobileOS,u=a.support.browser,h=e.extend,f=e.proxy,p=a.deepExtend,m=a.keys,g="select",v="select.k-select-overlay",_=l.extend({init:function(e){this.options=e},getHtml:function(){var e=this.options;return a.template(e.template,{useWithBlock:!1})(e)}}),b={editorWrapperTemplate:'<table cellspacing="4" cellpadding="0" class="k-widget k-editor k-header" role="presentation"><tbody><tr role="presentation"><td class="k-editor-toolbar-wrap" role="presentation"><ul class="k-editor-toolbar" role="toolbar" /></td></tr><tr><td class="k-editable-area" /></tr></tbody></table>',buttonTemplate:'# var iconCssClass= "k-icon k-i-" + kendo.toHyphens(data.cssClass.replace("k-", ""));#<a tabindex="0" role="button" class="k-tool"#= data.popup ? " data-popup" : "" # unselectable="on" title="#= data.title #"><span unselectable="on" class="k-tool-icon #= iconCssClass #"></span><span class="k-tool-text">#= data.title #</span></a>',colorPickerTemplate:'<div class="k-colorpicker k-icon k-i-#= data.cssClass.replace("k-", "") #" />',comboBoxTemplate:'<select title="#= data.title #" class="#= data.cssClass #" />',dropDownListTemplate:'<span class="k-editor-dropdown"><select title="#= data.title #" class="#= data.cssClass #" /></span>',separatorTemplate:'<span class="k-separator" />',overflowAnchorTemplate:'<a tabindex="0" role="button" class="k-tool k-overflow-anchor" data-popup unselectable="on" title="#= data.title #" aria-haspopup="true" aria-expanded="false"><span unselectable="on" class="k-icon k-i-more-vertical"></span><span class="k-tool-text">#= data.title #</span></a>',formatByName:function(t,n){for(var i=0;i<n.length;i++)if(e.inArray(t,n[i].tags)>=0)return n[i]},getToolCssClass:function(e){var t={superscript:"sup-script",subscript:"sub-script",justifyLeft:"align-left",justifyCenter:"align-center",justifyRight:"align-right",justifyFull:"align-justify",insertUnorderedList:"list-unordered",insertOrderedList:"list-ordered","import":"login",indent:"indent-increase",outdent:"indent-decrease",createLink:"link-horizontal",unlink:"unlink-horizontal",insertImage:"image",insertFile:"file-add",viewHtml:"html",foreColor:"foreground-color",backColor:"paint",createTable:"table-insert",addColumnLeft:"table-column-insert-left",addColumnRight:"table-column-insert-right",addRowAbove:"table-row-insert-above",addRowBelow:"table-row-insert-below",deleteRow:"table-row-delete",deleteColumn:"table-column-delete",tableWizard:"table-properties",tableWizardInsert:"table-wizard",cleanFormatting:"clear-css"},n=t[e];return n?n:e},registerTool:function(e,t){var n=t.options;n&&n.template&&(n.template.options.cssClass="k-"+b.getToolCssClass(e)),t.name||(t.options.name=e,t.name=e.toLowerCase()),x.defaultTools[e]=t},registerFormat:function(e,t){x.fn.options.formats[e]=t}},w={bold:"Bold",italic:"Italic",underline:"Underline",strikethrough:"Strikethrough",superscript:"Superscript",subscript:"Subscript",justifyCenter:"Center text",justifyLeft:"Align text left",justifyRight:"Align text right",justifyFull:"Justify",insertUnorderedList:"Insert unordered list",insertOrderedList:"Insert ordered list",indent:"Indent",outdent:"Outdent",createLink:"Insert hyperlink",unlink:"Remove hyperlink",insertImage:"Insert image",insertFile:"Insert file",insertHtml:"Insert HTML",viewHtml:"View HTML",fontName:"Select font family",fontNameInherit:"(inherited font)",fontSize:"Select font size",fontSizeInherit:"(inherited size)",formatBlock:"Format",formatting:"Format",foreColor:"Color",backColor:"Background color",style:"Styles",emptyFolder:"Empty Folder",editAreaTitle:"Editable area. Press F10 for toolbar.",uploadFile:"Upload",overflowAnchor:"More tools",orderBy:"Arrange by:",orderBySize:"Size",orderByName:"Name",invalidFileType:'The selected file "{0}" is not valid. Supported file types are {1}.',deleteFile:'Are you sure you want to delete "{0}"?',overwriteFile:'A file with name "{0}" already exists in the current directory. Do you want to overwrite it?',directoryNotFound:"A directory with this name was not found.",imageWebAddress:"Web address",imageAltText:"Alternate text",imageWidth:"Width (px)",imageHeight:"Height (px)",fileWebAddress:"Web address",fileTitle:"Title",fileText:"Text",linkWebAddress:"Web address",linkText:"Text",linkToolTip:"ToolTip",linkOpenInNewWindow:"Open link in new window",dialogUpdate:"Update",dialogInsert:"Insert",dialogOk:"Ok",dialogCancel:"Cancel",cleanFormatting:"Clean formatting",createTable:"Create a table",createTableHint:"Create a {0} x {1} table",addColumnLeft:"Add column on the left",addColumnRight:"Add column on the right",addRowAbove:"Add row above",addRowBelow:"Add row below",deleteRow:"Delete row",deleteColumn:"Delete column",tableWizard:"Table Wizard",tableTab:"Table",cellTab:"Cell",accessibilityTab:"Accessibility",caption:"Caption",summary:"Summary",width:"Width",height:"Height",units:"Units",cellSpacing:"Cell Spacing",cellPadding:"Cell Padding",cellMargin:"Cell Margin",alignment:"Alignment",background:"Background",cssClass:"CSS Class",id:"ID",border:"Border",borderStyle:"Border Style",collapseBorders:"Collapse borders",wrapText:"Wrap text",associateCellsWithHeaders:"Associate cells with headers",alignLeft:"Align Left",alignCenter:"Align Center",alignRight:"Align Right",alignLeftTop:"Align Left Top",alignCenterTop:"Align Center Top",alignRightTop:"Align Right Top",alignLeftMiddle:"Align Left Middle",alignCenterMiddle:"Align Center Middle",alignRightMiddle:"Align Right Middle",alignLeftBottom:"Align Left Bottom",alignCenterBottom:"Align Center Bottom",alignRightBottom:"Align Right Bottom",alignRemove:"Remove Alignment",columns:"Columns",rows:"Rows",selectAllCells:"Select All Cells",exportAs:"Export As","import":"Import"},y=!d||d.ios&&d.flatVersion>=500||!d.ios&&t!==document.documentElement.contentEditable,k={basic:["bold","italic","underline"],alignment:["justifyLeft","justifyCenter","justifyRight"],lists:["insertUnorderedList","insertOrderedList"],indenting:["indent","outdent"],links:["createLink","unlink"],tables:["tableWizard","createTable","addColumnLeft","addColumnRight","addRowAbove","addRowBelow","deleteRow","deleteColumn"]},x=c.extend({init:function(n,i){var o,r,s,l,d,u=this,m=a.ui.editor,g=m.Dom;y&&(c.fn.init.call(u,n,i),u.options=p({},u.options,i),u.options.tools=u.options.tools.slice(),n=u.element,d=n[0],l=g.name(d),this._registerHandler(n.closest("form"),"submit",f(u.update,u,t)),s=h({},u.options),s.editor=u,"textarea"==l?(u._wrapTextarea(),r=u.wrapper.find(".k-editor-toolbar"),d.id&&r.attr("aria-controls",d.id)):(u.element.attr("contenteditable",!0).addClass("k-widget k-editor k-editor-inline"),s.popup=!0,r=e('<ul class="k-editor-toolbar" role="toolbar" />').insertBefore(n)),u.toolbar=new m.Toolbar(r[0],s),u.toolbar.bindTo(u),"textarea"==l&&setTimeout(function(){var e=u.wrapper[0].style.height,t=parseInt(e,10),n=u.wrapper.height();e.indexOf("px")>0&&!isNaN(t)&&n>t&&u.wrapper.height(t-(n-t))}),u._resizable(),u._initializeContentElement(u),u.keyboard=new m.Keyboard([new m.BackspaceHandler(u),new m.TypingHandler(u),new m.SystemHandler(u),new m.SelectAllHandler(u)]),u.clipboard=new m.Clipboard(this),u.undoRedoStack=new a.util.UndoRedoStack,i&&i.value?o=i.value:u.textarea?(o=d.value,u.options.encoded&&e.trim(d.defaultValue).length&&(o=d.defaultValue),o=o.replace(/[\r\n\v\f\t ]+/gi," ")):o=d.innerHTML,u.value(o||a.ui.editor.emptyElementContent),this._registerHandler(document,{mousedown:function(){u._endTyping()},mouseup:function(e){u._mouseup(e)}}),u._initializeImmutables(),u.toolbar.resize(),a.notify(u))},setOptions:function(e){var t=this;c.fn.setOptions.call(t,e),e.tools&&t.toolbar.bindTo(t)},_endTyping:function(){var e=this.keyboard;try{e.isTypingInProgress()&&(e.endTyping(!0),this.saveSelection())}catch(t){}},_selectionChange:function(){this._selectionStarted=!1,this.saveSelection(),this.trigger("select",{})},_resizable:function(){var n,i=this.options.resizable,o=e.isPlainObject(i)?i.content===t||i.content===!0:i;o&&this.textarea&&(e("<div class='k-resize-handle'><span class='k-icon k-i-arrow-45-down-right' /></div>").insertAfter(this.textarea),this.wrapper.kendoResizable(h({},this.options.resizable,{start:function(t){var n=this.editor=e(t.currentTarget).closest(".k-editor");this.initialSize=n.height(),n.find("td:last").append("<div class='k-overlay' />")},resize:function(e){var t=e.y.initialDelta,n=this.initialSize+t,i=this.options.min||0,o=this.options.max||1/0;n=Math.min(o,Math.max(i,n)),this.editor.height(n)},resizeend:function(){this.editor.find(".k-overlay").remove(),this.editor=null}})),a.support.mobileOS.ios&&(n=this.wrapper.getKendoResizable(),n.draggable.options.ignore=v))},_initializeTableResizing:function(){var e=this;a.ui.editor.TableResizing.create(e),e._showTableResizeHandlesProxy=f(e._showTableResizeHandles,e),e.bind(g,e._showTableResizeHandlesProxy)},_destroyTableResizing:function(){var e=this,t=e.tableResizing;t&&(t.destroy(),e.tableResizing=null),e._showTableResizeHandlesProxy&&e.unbind(g,e._showTableResizeHandlesProxy)},_showTableResizeHandles:function(){var e=this,t=e.tableResizing;t&&t.showResizeHandles()},_initializeColumnResizing:function(){a.ui.editor.ColumnResizing.create(this)},_destroyColumnResizing:function(){var e=this;e.columnResizing&&(e.columnResizing.destroy(),e.columnResizing=null)},_initializeRowResizing:function(){a.ui.editor.RowResizing.create(this)},_destroyRowResizing:function(){var e=this;e.rowResizing&&(e.rowResizing.destroy(),e.rowResizing=null)},_wrapTextarea:function(){var t=this,n=t.element,i=n[0].style.width,o=n[0].style.height,r=b.editorWrapperTemplate,s=e(r).insertBefore(n).width(i).height(o),a=s.find(".k-editable-area");n.attr("autocomplete","off").appendTo(a).addClass("k-content k-raw-content").css("display","none"),t.textarea=n,t.wrapper=s},_createContentElement:function(t){var n,i,o,r=this,s=r.textarea,l=r.options.domain,c=l||document.domain,h="",f='javascript:""';return(l||c!=location.hostname)&&(h='<script>document.domain="'+c+'"</script>',f="javascript:document.write('"+h+"')"),s.hide(),n=e("<iframe />",{title:r.options.messages.editAreaTitle,frameBorder:"0"})[0],e(n).css("display","").addClass("k-content").attr("tabindex",s[0].tabIndex).insertBefore(s),n.src=f,i=n.contentWindow||n,o=i.document||n.contentDocument,e(n).one("load",function(){r.toolbar.decorateFrom(o.body)}),o.open(),o.write("<!DOCTYPE html><html><head><meta charset='utf-8' /><style>html,body{padding:0;margin:0;height:100%;min-height:100%;}body{box-sizing:border-box;font-size:12px;font-family:Verdana,Geneva,sans-serif;margin-top:-1px;padding:5px .4em 0;word-wrap: break-word;-webkit-nbsp-mode: space;-webkit-line-break: after-white-space;"+(a.support.isRtl(s)?"direction:rtl;":"")+(u.msie||u.edge?"height:auto;":"")+(d.ios?"word-break:break-all;":"")+"}h1{font-size:2em;margin:.67em 0}h2{font-size:1.5em}h3{font-size:1.16em}h4{font-size:1em}h5{font-size:.83em}h6{font-size:.7em}p{margin:0 0 1em;}.k-marker{display:none;}.k-paste-container,.Apple-style-span{position:absolute;left:-10000px;width:1px;height:1px;overflow:hidden}ul,ol{padding-left:2.5em}span{-ms-high-contrast-adjust:none;}a{color:#00a}code{font-size:1.23em}telerik\\3Ascript{display: none;}.k-table{width:100%;border-spacing:0;margin: 0 0 1em;}.k-table td{min-width:1px;padding:.2em .3em;}.k-table,.k-table td{outline:0;border: 1px dotted #ccc;}.k-table p{margin:0;padding:0;}.k-column-resize-handle-wrapper {position: absolute; height: 10px; width:10px; cursor: col-resize; z-index: 2;}.k-column-resize-handle {width: 100%; height: 100%;}.k-column-resize-handle > .k-column-resize-marker {width:2px; height:100%; margin:0 auto; background-color:#00b0ff; display:none; opacity:0.8;}.k-row-resize-handle-wrapper {position: absolute; cursor: row-resize; z-index:2; width: 10px; height: 10px;}.k-row-resize-handle {display: table; width: 100%; height: 100%;}.k-row-resize-marker-wrapper{display: table-cell; height:100%; width:100%; margin:0; padding:0; vertical-align: middle;}.k-row-resize-marker{margin: 0; padding:0; width:100%; height:2px; background-color: #00b0ff; opacity:0.8; display:none;}.k-table-resize-handle-wrapper {position: absolute; background-color: #fff; border: 1px solid #000; z-index: 100; width: 5px; height: 5px;}.k-table-resize-handle {width: 100%; height: 100%;}.k-table-resize-handle.k-resize-east{cursor:e-resize;}.k-table-resize-handle.k-resize-north{cursor:n-resize;}.k-table-resize-handle.k-resize-northeast{cursor:ne-resize;}.k-table-resize-handle.k-resize-northwest{cursor:nw-resize;}.k-table-resize-handle.k-resize-south{cursor:s-resize;}.k-table-resize-handle.k-resize-southeast{cursor:se-resize;}.k-table-resize-handle.k-resize-southwest{cursor:sw-resize;}.k-table-resize-handle.k-resize-west{cursor:w-resize;}.k-table.k-table-resizing{opacity:0.6;}k\\:script{display:none;}</style>"+h+"<script>(function(d,c){d[c]('header'),d[c]('article'),d[c]('nav'),d[c]('section'),d[c]('footer');})(document, 'createElement');</script>"+e.map(t,function(e){return"<link rel='stylesheet' href='"+e+"'>"}).join("")+"</head><body autocorrect='off' contenteditable='true'></body></html>"),o.close(),i},_blur:function(){var e=this.textarea,t=e?e.val():this._oldValue,n=this.options.encoded?this.encodedValue():this.value();this.update(),e&&e.trigger("blur"),n!=t&&this.trigger("change")},_spellCorrect:function(e){var n,i=!1;this._registerHandler(e.body,{contextmenu:function(){e.one("select",function(){n=null}),e._spellCorrectTimeout=setTimeout(function(){n=new a.ui.editor.RestorePoint(e.getRange(),e.body),i=!1},10)},input:function(){if(n)return a.support.browser.mozilla&&!i?(i=!0,t):(a.ui.editor._finishUpdate(e,n),t)}})},_registerHandler:function(t,n,i){var o,r,s,l=this,c=".kendoEditor";if(t=e(t),this._handlers||(this._handlers=[]),t.length)if(e.isPlainObject(n))for(s in n)n.hasOwnProperty(s)&&this._registerHandler(t,s,n[s]);else for(o=a.applyEventMap(n).split(" "),r=0;r<o.length;r++)l._handlers.push({element:t,type:o[r]+c,handler:i}),t.on(o[r]+c,i)},_deregisterHandlers:function(){var e,t,n=this._handlers;for(e=0;e<n.length;e++)t=n[e],t.element.off(t.type,t.handler);this._handlers=[]},_initializeContentElement:function(){var n,i,o,r=this;r.textarea?(r.window=r._createContentElement(r.options.stylesheets),n=r.document=r.window.contentDocument||r.window.document,r.body=n.body,i=r.window,o=n,this._registerHandler(n,"mouseup",f(this._mouseup,this))):(r.window=window,n=r.document=document,r.body=r.element[0],i=r.body,o=r.body,r.toolbar.decorateFrom(r.body)),this._registerHandler(i,"blur",f(this._blur,this)),r._registerHandler(o,"down",f(r._mousedown,r));try{n.execCommand("enableInlineTableEditing",null,!1)}catch(s){}a.support.touch&&this._registerHandler(n,{keydown:function(){a._activeElement()!=n.body&&r.window.focus()}}),this._spellCorrect(r),this._registerHandler(r.body,{keydown:function(e){var n,i,o,s,a,l,c,d,u,h;return(e.keyCode!==m.BACKSPACE&&e.keyCode!==m.DELETE||"true"===r.body.getAttribute("contenteditable"))&&(e.keyCode===m.F10?(setTimeout(f(r.toolbar.focus,r.toolbar),100),e.preventDefault(),t):(e.keyCode!=m.LEFT&&e.keyCode!=m.RIGHT||(n=r.getRange(),i=e.keyCode==m.LEFT,o=n[i?"startContainer":"endContainer"],s=n[i?"startOffset":"endOffset"],a=i?-1:1,l=s+a,c=i?l:s,3==o.nodeType&&"\ufeff"==o.nodeValue[c]&&(n.setStart(o,l),n.collapse(!0),r.selectRange(n))),d=r.toolbar.tools,u=r.keyboard.toolFromShortcut(d,e),h=u?d[u].options:{},u&&!h.keyPressCommand?(e.preventDefault(),/^(undo|redo)$/.test(u)||r.keyboard.endTyping(!0),r.trigger("keydown",e),r.exec(u),r._runPostContentKeyCommands(e),!1):(r.keyboard.clearTimeout(),r.keyboard.keydown(e),t)))},keypress:function(e){setTimeout(function(){r._runPostContentKeyCommands(e),r._showTableResizeHandles()},0)},keyup:function(t){var n=[m.BACKSPACE,m.TAB,m.PAGEUP,m.PAGEDOWN,m.END,m.HOME,m.LEFT,m.UP,m.RIGHT,m.DOWN,m.INSERT,m.DELETE];(e.inArray(t.keyCode,n)>-1||65==t.keyCode&&t.ctrlKey&&!t.altKey&&!t.shiftKey)&&r._selectionChange(),r.keyboard.keyup(t)},click:function(e){var t,n=a.ui.editor.Dom;"img"===n.name(e.target)&&(t=r.createRange(),t.selectNode(e.target),r.selectRange(t))},"cut copy paste":function(e){r.clipboard["on"+e.type](e)},focusin:function(){r.body.hasAttribute("contenteditable")&&(e(this).addClass("k-state-active"),r.toolbar.show())},focusout:function(){setTimeout(function(){var t,n=a._activeElement(),i=r.body,o=r.toolbar;o.options.popup&&(t=o.window.element.get(0),t&&!e.contains(t,n)&&t!=n&&(o.preventPopupHide=!1)),n==i||e.contains(i,n)||e(n).is(".k-editortoolbar-dragHandle")||o.focused()||(e(i).removeClass("k-state-active"),o.hide())},10)}}),r._initializeColumnResizing(),r._initializeRowResizing(),r._initializeTableResizing()},_initializeImmutables:function(){var e=this,t=a.ui.editor;e.options.immutables&&(e.immutables=new t.Immutables(e))},_mousedown:function(t){var n,i=this;i._selectionStarted=!0,u.gecko||(n=e(t.target),(2==t.which||1==t.which&&t.ctrlKey)&&n.is("a[href]")&&window.open(n.attr("href"),"_new"))},_mouseup:function(t){var n=this;a.support.mobileOS.ios&&t&&e(t.target).is(v)||n._selectionStarted&&setTimeout(function(){n._selectionChange()},1)},_runPostContentKeyCommands:function(e){var t,n,i,o,r=this.getRange(),s=this.keyboard.toolsFromShortcut(this.toolbar.tools,e);for(t=0;t<s.length;t++)n=s[t],i=n.options,i.keyPressCommand&&(o=new i.command({range:r}),o.changesContent()&&(this.keyboard.endTyping(!0),this.exec(n.name)))},refresh:function(){var e,t=this;t.textarea&&(t._destroyResizings(),e=t.value(),t.textarea.val(e),t.wrapper.find("iframe").remove(),t._initializeContentElement(t),t.value(e))},events:["select","change","execute","error","paste","keydown","keyup"],options:{name:"Editor",messages:w,formats:{},encoded:!0,domain:null,resizable:!1,deserialization:{custom:null},serialization:{entities:!0,semantic:!0,scripts:!1},pasteCleanup:{all:!1,css:!1,custom:null,keepNewLines:!1,msAllFormatting:!1,msConvertLists:!0,msTags:!0,none:!1,span:!1},stylesheets:[],dialogOptions:{modal:!0,resizable:!1,draggable:!0,animation:!1},imageBrowser:null,fileBrowser:null,fontName:[{text:"Arial",value:"Arial,Helvetica,sans-serif"},{text:"Courier New",value:"'Courier New',Courier,monospace"},{text:"Georgia",value:"Georgia,serif"},{text:"Impact",value:"Impact,Charcoal,sans-serif"},{text:"Lucida Console",value:"'Lucida Console',Monaco,monospace"},{text:"Tahoma",value:"Tahoma,Geneva,sans-serif"},{text:"Times New Roman",value:"'Times New Roman',Times,serif"},{text:"Trebuchet MS",value:"'Trebuchet MS',Helvetica,sans-serif"},{text:"Verdana",value:"Verdana,Geneva,sans-serif"}],fontSize:[{text:"1 (8pt)",value:"xx-small"},{text:"2 (10pt)",value:"x-small"},{text:"3 (12pt)",value:"small"},{text:"4 (14pt)",value:"medium"},{text:"5 (18pt)",value:"large"},{text:"6 (24pt)",value:"x-large"},{text:"7 (36pt)",value:"xx-large"}],formatBlock:[{text:"Paragraph",value:"p"},{text:"Quotation",value:"blockquote"},{text:"Heading 1",value:"h1"},{text:"Heading 2",value:"h2"},{text:"Heading 3",value:"h3"},{text:"Heading 4",value:"h4"},{text:"Heading 5",value:"h5"},{text:"Heading 6",value:"h6"}],tools:[].concat.call(["formatting"],k.basic,k.alignment,k.lists,k.indenting,k.links,["insertImage"],k.tables)},destroy:function(){var e=this;c.fn.destroy.call(this),this._endTyping(!0),this._deregisterHandlers(),clearTimeout(this._spellCorrectTimeout),this._focusOutside(),this.toolbar.destroy(),e._destroyUploadWidget(),e._destroyResizings(),a.destroy(this.wrapper)},_destroyResizings:function(){var e=this;e._destroyTableResizing(),a.ui.editor.TableResizing.dispose(e),e._destroyRowResizing(),a.ui.editor.RowResizing.dispose(e),e._destroyColumnResizing(),a.ui.editor.ColumnResizing.dispose(e)},_focusOutside:function(){if(a.support.browser.msie&&this.textarea){var t=e("<input style='position:fixed;left:1px;top:1px;width:1px;height:1px;font-size:0;border:0;opacity:0' />").appendTo(document.body).focus();t.blur().remove()}},_destroyUploadWidget:function(){var e=this;e._uploadWidget&&(e._uploadWidget.destroy(),e._uploadWidget=null)},state:function(e){var t,n,i=x.defaultTools[e],o=i&&(i.options.finder||i.finder),r=a.ui.editor.RangeUtils;
return!!o&&(t=this.getRange(),n=r.textNodes(t),!n.length&&t.collapsed&&(n=[t.startContainer]),o.getFormat?o.getFormat(n):o.isFormatted(n))},value:function(e){var n=this.body,i=a.ui.editor,o=this.options,r=i.Serializer.domToXhtml(n,o.serialization);return e===t?r:(e!=r&&(i.Serializer.htmlToDom(e,n,o.deserialization),this.selectionRestorePoint=null,this.update(),this.toolbar.refreshTools()),t)},saveSelection:function(t){t=t||this.getRange();var n=t.commonAncestorContainer,i=this.body;(n==i||e.contains(i,n))&&(this.selectionRestorePoint=new a.ui.editor.RestorePoint(t,i))},_focusBody:function(){var e,t=this.body,n=this.wrapper&&this.wrapper.find("iframe")[0],i=this.document.documentElement,o=a._activeElement();n?o!=t&&o!=n&&(e=i.scrollTop,t.focus(),i.scrollTop=e):(e=t.scrollTop,t.focus(),t.scrollTop=e)},restoreSelection:function(){this._focusBody(),this.selectionRestorePoint&&this.selectRange(this.selectionRestorePoint.toRange())},focus:function(){this.restoreSelection()},update:function(e){e=e||this.options.encoded?this.encodedValue():this.value(),this.textarea?this.textarea.val(e):this._oldValue=e},encodedValue:function(){return a.ui.editor.Dom.encode(this.value())},createRange:function(e){return a.ui.editor.RangeUtils.createRange(e||this.document)},getSelection:function(){return a.ui.editor.SelectionUtils.selectionFromDocument(this.document)},selectRange:function(e){this._focusBody();var t=this.getSelection();t.removeAllRanges(),t.addRange(e),this.saveSelection(e)},getRange:function(){var e=this.getSelection(),t=e&&e.rangeCount>0?e.getRangeAt(0):this.createRange(),n=this.document;return t.startContainer!=n||t.endContainer!=n||t.startOffset||t.endOffset||(t.setStart(this.body,0),t.collapse(!0)),t},_containsRange:function(e){var t=a.ui.editor.Dom,n=this.body;return e&&t.isAncestorOrSelf(n,e.startContainer)&&t.isAncestorOrSelf(n,e.endContainer)},selectedHtml:function(){return a.ui.editor.Serializer.domToXhtml(this.getRange().cloneContents())},paste:function(t,n){this.focus();var i=new a.ui.editor.InsertHtmlCommand(e.extend({range:this.getRange(),html:t},n));i.editor=this,i.exec()},exec:function(e,n){var i,o,r,s,a=this,l=null;if(!e)throw Error("kendoEditor.exec(): `name` parameter cannot be empty");if("true"!==a.body.getAttribute("contenteditable")&&"print"!==e&&"pdf"!==e)return!1;if(e=e.toLowerCase(),a.keyboard.isTypingInProgress()||(a._focusBody(),a.selectRange(a._range||a.getRange())),o=a.toolbar.toolById(e),!o)for(s in x.defaultTools)if(s.toLowerCase()==e){o=x.defaultTools[s];break}if(o){if(i=a.getRange(),o.command&&(l=o.command(h({range:i,body:a.body,immutables:!!a.immutables},n))),r=a.trigger("execute",{name:e,command:l}))return;if(/^(undo|redo)$/i.test(e))a.undoRedoStack[e]();else if(l&&(a.execCommand(l),l.async))return l.change=f(a._selectionChange,a),t;a._selectionChange()}},execCommand:function(e){e.managesUndoRedo||this.undoRedoStack.push(e),e.editor=this,e.exec()}});x.defaultTools={undo:{options:{key:"Z",ctrl:!0}},redo:{options:{key:"Y",ctrl:!0}}},a.ui.plugin(x),n=l.extend({init:function(e){this.options=e},initialize:function(e,t){e.attr({unselectable:"on",title:t.title}),e.children(".k-tool-text").html(t.title)},command:function(e){return new this.options.command(e)},update:e.noop}),n.exec=function(e,t,n){e.exec(t,{value:n})},i=n.extend({init:function(e){n.fn.init.call(this,e)},command:function(e){var t=this;return new a.ui.editor.FormatCommand(h(e,{formatter:t.options.formatter}))},update:function(e,t){var n=this.options.finder.isFormatted(t);e.toggleClass("k-state-selected",n),e.attr("aria-pressed",n)}}),b.registerTool("separator",new n({template:new _({template:b.separatorTemplate})})),o=u.msie&&u.version<9?"\ufeff":"",r="\ufeff",s=r,u.msie&&10==u.version&&(s="&nbsp;"),h(a.ui,{editor:{ToolTemplate:_,EditorUtils:b,Tool:n,FormatTool:i,_bomFill:o,emptyElementContent:r,emptyTableCellContent:s}}),a.PDFMixin&&(a.PDFMixin.extend(x.prototype),x.prototype._drawPDF=function(){return a.drawing.drawDOM(this.body,this.options.pdf)},x.prototype.saveAsPDF=function(){var t,n=new e.Deferred,i=n.promise(),o={promise:i};if(!this.trigger("pdfExport",o))return t=this.options.pdf,this._drawPDF(n).then(function(e){return a.drawing.exportPDF(e,t)}).done(function(e){a.saveAs({dataURI:e,fileName:t.fileName,proxyURL:t.proxyURL,forceProxy:t.forceProxy}),n.resolve()}).fail(function(e){n.reject(e)}),i})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("editor/dom.min",["editor/main.min"],e)}(function(){!function(e){function t(e){var t,n,i={};for(t=0,n=e.length;t<n;t++)i[e[t]]=!0;return i}var n,i,o,r,s,a,l,c,d,u,h,f=window.kendo,p=e.map,m=e.extend,g=f.support.browser,v="style",_="float",b="cssFloat",w="styleFloat",y="class",k="k-marker",x=t("area,base,basefont,br,col,frame,hr,img,input,isindex,link,meta,param,embed".split(",")),C="div,p,h1,h2,h3,h4,h5,h6,address,applet,blockquote,button,center,dd,dir,dl,dt,fieldset,form,frameset,hr,iframe,isindex,map,menu,noframes,noscript,object,pre,script,table,tbody,td,tfoot,th,thead,tr,header,article,nav,footer,section,aside,main,figure,figcaption".split(","),S=C.concat(["ul","ol","li"]),T=t(S),D="span,em,a,abbr,acronym,applet,b,basefont,bdo,big,br,button,cite,code,del,dfn,font,i,iframe,img,input,ins,kbd,label,map,object,q,s,samp,script,select,small,strike,strong,sub,sup,textarea,tt,u,var,data,time,mark,ruby".split(","),A=t(D),E=t("checked,compact,declare,defer,disabled,ismap,multiple,nohref,noresize,noshade,nowrap,readonly,selected".split(",")),M=function(e){1==e.nodeType&&e.normalize()};g.msie&&g.version>=8&&(M=function(e){if(1==e.nodeType&&e.firstChild)for(var t=e.firstChild,n=t;;){if(n=n.nextSibling,!n)break;3==n.nodeType&&3==t.nodeType&&(n.nodeValue=t.nodeValue+n.nodeValue,h.remove(t)),t=n}}),n=/^\s+$/,i=/^[\n\r\t]+$/,o=/rgb\s*\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*\)/i,r=/\ufeff/g,s=/^(\s+|\ufeff)$/,l="color,padding-left,padding-right,padding-top,padding-bottom,background-color,background-attachment,background-image,background-position,background-repeat,border-top-style,border-top-width,border-top-color,border-bottom-style,border-bottom-width,border-bottom-color,border-left-style,border-left-width,border-left-color,border-right-style,border-right-width,border-right-color,font-family,font-size,font-style,font-variant,font-weight,line-height".split(","),c=/[<>\&]/g,d=/[\u00A0-\u2666<>\&]/g,u={34:"quot",38:"amp",39:"apos",60:"lt",62:"gt",160:"nbsp",161:"iexcl",162:"cent",163:"pound",164:"curren",165:"yen",166:"brvbar",167:"sect",168:"uml",169:"copy",170:"ordf",171:"laquo",172:"not",173:"shy",174:"reg",175:"macr",176:"deg",177:"plusmn",178:"sup2",179:"sup3",180:"acute",181:"micro",182:"para",183:"middot",184:"cedil",185:"sup1",186:"ordm",187:"raquo",188:"frac14",189:"frac12",190:"frac34",191:"iquest",192:"Agrave",193:"Aacute",194:"Acirc",195:"Atilde",196:"Auml",197:"Aring",198:"AElig",199:"Ccedil",200:"Egrave",201:"Eacute",202:"Ecirc",203:"Euml",204:"Igrave",205:"Iacute",206:"Icirc",207:"Iuml",208:"ETH",209:"Ntilde",210:"Ograve",211:"Oacute",212:"Ocirc",213:"Otilde",214:"Ouml",215:"times",216:"Oslash",217:"Ugrave",218:"Uacute",219:"Ucirc",220:"Uuml",221:"Yacute",222:"THORN",223:"szlig",224:"agrave",225:"aacute",226:"acirc",227:"atilde",228:"auml",229:"aring",230:"aelig",231:"ccedil",232:"egrave",233:"eacute",234:"ecirc",235:"euml",236:"igrave",237:"iacute",238:"icirc",239:"iuml",240:"eth",241:"ntilde",242:"ograve",243:"oacute",244:"ocirc",245:"otilde",246:"ouml",247:"divide",248:"oslash",249:"ugrave",250:"uacute",251:"ucirc",252:"uuml",253:"yacute",254:"thorn",255:"yuml",402:"fnof",913:"Alpha",914:"Beta",915:"Gamma",916:"Delta",917:"Epsilon",918:"Zeta",919:"Eta",920:"Theta",921:"Iota",922:"Kappa",923:"Lambda",924:"Mu",925:"Nu",926:"Xi",927:"Omicron",928:"Pi",929:"Rho",931:"Sigma",932:"Tau",933:"Upsilon",934:"Phi",935:"Chi",936:"Psi",937:"Omega",945:"alpha",946:"beta",947:"gamma",948:"delta",949:"epsilon",950:"zeta",951:"eta",952:"theta",953:"iota",954:"kappa",955:"lambda",956:"mu",957:"nu",958:"xi",959:"omicron",960:"pi",961:"rho",962:"sigmaf",963:"sigma",964:"tau",965:"upsilon",966:"phi",967:"chi",968:"psi",969:"omega",977:"thetasym",978:"upsih",982:"piv",8226:"bull",8230:"hellip",8242:"prime",8243:"Prime",8254:"oline",8260:"frasl",8472:"weierp",8465:"image",8476:"real",8482:"trade",8501:"alefsym",8592:"larr",8593:"uarr",8594:"rarr",8595:"darr",8596:"harr",8629:"crarr",8656:"lArr",8657:"uArr",8658:"rArr",8659:"dArr",8660:"hArr",8704:"forall",8706:"part",8707:"exist",8709:"empty",8711:"nabla",8712:"isin",8713:"notin",8715:"ni",8719:"prod",8721:"sum",8722:"minus",8727:"lowast",8730:"radic",8733:"prop",8734:"infin",8736:"ang",8743:"and",8744:"or",8745:"cap",8746:"cup",8747:"int",8756:"there4",8764:"sim",8773:"cong",8776:"asymp",8800:"ne",8801:"equiv",8804:"le",8805:"ge",8834:"sub",8835:"sup",8836:"nsub",8838:"sube",8839:"supe",8853:"oplus",8855:"otimes",8869:"perp",8901:"sdot",8968:"lceil",8969:"rceil",8970:"lfloor",8971:"rfloor",9001:"lang",9002:"rang",9674:"loz",9824:"spades",9827:"clubs",9829:"hearts",9830:"diams",338:"OElig",339:"oelig",352:"Scaron",353:"scaron",376:"Yuml",710:"circ",732:"tilde",8194:"ensp",8195:"emsp",8201:"thinsp",8204:"zwnj",8205:"zwj",8206:"lrm",8207:"rlm",8211:"ndash",8212:"mdash",8216:"lsquo",8217:"rsquo",8218:"sbquo",8220:"ldquo",8221:"rdquo",8222:"bdquo",8224:"dagger",8225:"Dagger",8240:"permil",8249:"lsaquo",8250:"rsaquo",8364:"euro"},h={block:T,inline:A,findNodeIndex:function(e,t){var n=0;if(!e)return-1;for(;;){if(e=e.previousSibling,!e)break;t&&3==e.nodeType||n++}return n},isDataNode:function(e){return e&&null!==e.nodeValue&&null!==e.data},isAncestorOf:function(t,n){try{return!h.isDataNode(t)&&(e.contains(t,h.isDataNode(n)?n.parentNode:n)||n.parentNode==t)}catch(i){return!1}},isAncestorOrSelf:function(e,t){return h.isAncestorOf(e,t)||e==t},findClosestAncestor:function(e,t){if(h.isAncestorOf(e,t))for(;t&&t.parentNode!=e;)t=t.parentNode;return t},getNodeLength:function(e){return h.isDataNode(e)?e.length:e.childNodes.length},splitDataNode:function(e,t){for(var n,i=e.cloneNode(!1),o="",r=e.nextSibling;r&&3==r.nodeType&&r.nodeValue;)o+=r.nodeValue,n=r,r=r.nextSibling,h.remove(n);e.deleteData(t,e.length),i.deleteData(0,t),i.nodeValue+=o,h.insertAfter(i,e)},attrEquals:function(e,t){var n,i;for(n in t)if(i=e[n],n==_&&(i=e[f.support.cssFloat?b:w]),"object"==typeof i){if(!h.attrEquals(i,t[n]))return!1}else if(i!=t[n])return!1;return!0},blockParentOrBody:function(e){return h.parentOfType(e,S)||e.ownerDocument.body},blockParents:function(t){var n,i,o,r=[];for(n=0,i=t.length;n<i;n++)o=h.parentOfType(t[n],h.blockElements),o&&e.inArray(o,r)<0&&r.push(o);return r},windowFromDocument:function(e){return e.defaultView||e.parentWindow},normalize:M,blockElements:S,nonListBlockElements:C,inlineElements:D,empty:x,fillAttrs:E,nodeTypes:{ELEMENT_NODE:1,ATTRIBUTE_NODE:2,TEXT_NODE:3,CDATA_SECTION_NODE:4,ENTITY_REFERENCE_NODE:5,ENTITY_NODE:6,PROCESSING_INSTRUCTION_NODE:7,COMMENT_NODE:8,DOCUMENT_NODE:9,DOCUMENT_TYPE_NODE:10,DOCUMENT_FRAGMENT_NODE:11,NOTATION_NODE:12},toHex:function(e){var t=o.exec(e);return t?"#"+p(t.slice(1),function(e){return e=parseInt(e,10).toString(16),e.length>1?e:"0"+e}).join(""):e},encode:function(e,t){var n=!t||t.entities?d:c;return e.replace(n,function(e){var t=e.charCodeAt(0),n=u[t];return n?"&"+n+";":e})},isBom:function(e){return e&&3===e.nodeType&&/^[\ufeff]+$/.test(e.nodeValue)},stripBom:function(e){return(e||"").replace(r,"")},stripBomNode:function(e){h.isBom(e)&&e.parentNode.removeChild(e)},insignificant:function(e){var t=e.attributes;return"k-marker"==e.className||h.is(e,"br")&&("k-br"==e.className||t._moz_dirty||t._moz_editor_bogus_node)},tableCell:function(e){return h.is(e,"td")||h.is(e,"th")},significantNodes:function(t){return e.grep(t,function(e){var t=h.name(e);return"br"!=t&&(!h.insignificant(e)&&(!h.emptyTextNode(e)&&!(1==e.nodeType&&!x[t]&&h.emptyNode(e))))})},emptyTextNode:function(e){return e&&3==e.nodeType&&s.test(e.nodeValue)},emptyNode:function(e){return 1==e.nodeType&&!h.significantNodes(e.childNodes).length},name:function(e){return e.nodeName.toLowerCase()},significantChildNodes:function(t){return e.grep(t.childNodes,function(e){return 3!=e.nodeType||!h.isWhitespace(e)})},lastTextNode:function(e){var t,n=null;if(3==e.nodeType)return e;for(t=e.lastChild;t;t=t.previousSibling)if(n=h.lastTextNode(t))return n;return n},is:function(e,t){return e&&h.name(e)==t},isMarker:function(e){return e.className==k},isWhitespace:function(e){return n.test(e.nodeValue)},allWhitespaceContent:function(e){for(var t=e.firstChild;t&&h.isWhitespace(t);)t=t.nextSibling;return!t},isEmptyspace:function(e){return i.test(e.nodeValue)},htmlIndentSpace:function(t){var n,o,s,a,l,c;return!(!h.isDataNode(t)||!h.isWhitespace(t))&&(!!i.test(t.nodeValue)||(n=function(e,t){for(;e[t];)if(e=e[t],h.significantNodes([e]).length>0)return e},o=t.parentNode,s=n(t,"previousSibling"),a=n(t,"nextSibling"),r.test(t.nodeValue)?!(!s&&!a):!!e(o).is("tr,tbody,thead,tfoot,table,ol,ul")||!!((h.isBlock(o)||h.is(o,"body"))&&(l=s&&h.isBlock(s),c=a&&h.isBlock(a),!a&&l||!s&&c||l&&c))))},isBlock:function(e){return T[h.name(e)]},isEmpty:function(e){return x[h.name(e)]},isInline:function(e){return A[h.name(e)]},list:function(e){var t=e?h.name(e):"";return"ul"==t||"ol"==t||"dl"==t},scrollContainer:function(e){var t=h.windowFromDocument(e),n=(t.contentWindow||t).document||t.ownerDocument||t;return n=f.support.browser.webkit||"BackCompat"==n.compatMode?n.body:n.documentElement},scrollTo:function(t){var n,i,o=e(h.isDataNode(t)?t.parentNode:t),r=h.windowFromDocument(t.ownerDocument),s=r.innerHeight,a=h.scrollContainer(t.ownerDocument);n=o.offset().top,i=o[0].offsetHeight,i||(i=parseInt(o.css("line-height"),10)||Math.ceil(1.2*parseInt(o.css("font-size"),10))||15),i+n>a.scrollTop+s&&(a.scrollTop=i+n-s)},persistScrollTop:function(e){a=h.scrollContainer(e).scrollTop},offset:function(e,t){for(var n={top:e.offsetTop,left:e.offsetLeft},i=e.offsetParent;i&&(!t||h.isAncestorOf(t,i));)n.top+=i.offsetTop,n.left+=i.offsetLeft,i=i.offsetParent;return n},restoreScrollTop:function(e){"number"==typeof a&&(h.scrollContainer(e).scrollTop=a)},insertAt:function(e,t,n){e.insertBefore(t,e.childNodes[n]||null)},insertBefore:function(e,t){return t.parentNode?t.parentNode.insertBefore(e,t):t},insertAfter:function(e,t){return t.parentNode.insertBefore(e,t.nextSibling)},remove:function(e){e.parentNode&&e.parentNode.removeChild(e)},removeChildren:function(e){for(;e.firstChild;)e.removeChild(e.firstChild)},removeTextSiblings:function(e){for(var t=e.parentNode;e.nextSibling&&3==e.nextSibling.nodeType;)t.removeChild(e.nextSibling);for(;e.previousSibling&&3==e.previousSibling.nodeType;)t.removeChild(e.previousSibling)},trim:function(e){var t,n;for(t=e.childNodes.length-1;t>=0;t--)n=e.childNodes[t],h.isDataNode(n)?h.stripBom(n.nodeValue).length||h.remove(n):n.className!=k&&(h.trim(n),(0===n.childNodes.length||h.allWhitespaceContent(n)&&h.isBlock(n)&&!h.isEmpty(n))&&h.remove(n));return e},closest:function(e,t){for(;e&&h.name(e)!=t;)e=e.parentNode;return e},closestBy:function(e,t,n){for(;e&&!t(e);){if(n&&n(e))return null;e=e.parentNode}return e},sibling:function(e,t){do e=e[t];while(e&&1!=e.nodeType);return e},next:function(e){return h.sibling(e,"nextSibling")},prev:function(e){return h.sibling(e,"previousSibling")},parentOfType:function(e,t){do e=e.parentNode;while(e&&!h.ofType(e,t));return e},ofType:function(t,n){return e.inArray(h.name(t),n)>=0},changeTag:function(e,t,n){var i,o,r,s,a,l=h.create(e.ownerDocument,t),c=e.attributes;if(!n)for(i=0,o=c.length;i<o;i++)a=c[i],a.specified&&(r=a.nodeName,s=a.nodeValue,r==y?l.className=s:r==v?l.style.cssText=e.style.cssText:l.setAttribute(r,s));for(;e.firstChild;)l.appendChild(e.firstChild);return h.insertBefore(l,e),h.remove(e),l},editableParent:function(e){for(;e&&(3==e.nodeType||"true"!==e.contentEditable);)e=e.parentNode;return e},wrap:function(e,t){return h.insertBefore(t,e),t.appendChild(e),t},unwrap:function(e){for(var t=e.parentNode;e.firstChild;)t.insertBefore(e.firstChild,e);t.removeChild(e)},wrapper:function(t){var n=h.closestBy(t,function(e){return e.parentNode&&h.significantNodes(e.parentNode.childNodes).length>1});return e(n).is("body,.k-editor")?void 0:n},create:function(e,t,n){return h.attr(e.createElement(t),n)},attr:function(e,t){t=m({},t),t&&v in t&&(h.style(e,t.style),delete t.style);for(var n in t)null===t[n]?(e.removeAttribute(n),delete t[n]):"className"==n&&(e[n]=t[n]);return m(e,t)},style:function(t,n){e(t).css(n||{})},unstyle:function(e,t){for(var n in t)n==_&&(n=f.support.cssFloat?b:w),e.style[n]="";""===e.style.cssText&&e.removeAttribute(v)},inlineStyle:function(t,n,i){var o,r=e(h.create(t.ownerDocument,n,i));return t.appendChild(r[0]),o=p(l,function(e){return g.msie&&"line-height"==e&&"1px"==r.css(e)?"line-height:1.5":e+":"+r.css(e)}).join(";"),r.remove(),o},getEffectiveBackground:function(e){var t=e.css("background-color")||"";return t.indexOf("rgba(0, 0, 0, 0")<0&&"transparent"!==t?t:"html"===e[0].tagName.toLowerCase()?"Window":h.getEffectiveBackground(e.parent())},innerText:function(e){var t=e.innerHTML;return t=t.replace(/<!--(.|\s)*?-->/gi,""),t=t.replace(/<\/?[^>]+?\/?>/gm,"")},removeClass:function(t,n){var i,o,r=" "+t.className+" ",s=n.split(" ");for(i=0,o=s.length;i<o;i++)r=r.replace(" "+s[i]+" "," ");r=e.trim(r),r.length?t.className=r:t.removeAttribute(y)},commonAncestor:function(){var e,t,n,i,o,r=arguments.length,s=[],a=1/0,l=null;if(!r)return null;if(1==r)return arguments[0];for(e=0;e<r;e++){for(t=[],n=arguments[e];n;)t.push(n),n=n.parentNode;s.push(t.reverse()),a=Math.min(a,t.length)}if(1==r)return s[0][0];for(e=0;e<a;e++){for(i=s[0][e],o=1;o<r;o++)if(i!=s[o][e])return l;l=i}return l},closestSplittableParent:function(t){var n,i,o;return n=1==t.length?h.parentOfType(t[0],["ul","ol"]):h.commonAncestor.apply(null,t),n||(n=h.parentOfType(t[0],["p","td"])||t[0].ownerDocument.body),h.isInline(n)&&(n=h.blockParentOrBody(n)),i=p(t,h.editableParent),o=h.commonAncestor(i)[0],e.contains(n,o)&&(n=o),n},closestEditable:function(t,n){var i,o=h.editableParent(t);return i=h.ofType(t,n)?t:h.parentOfType(t,n),i&&o&&e.contains(i,o)?i=o:!i&&o&&(i=o),i},closestEditableOfType:functi