{"version":3,"sources":["kendo.mobile.js"],"names":["f","define","$","window","undefined","Class","compilePart","part","stringPart","split","join","replace","first","charAt","rest","substring","pad","number","digits","end","length","zeros","getShadows","element","shadow","css","kendo","support","transitions","radius","match","boxShadowRegExp","blur","math","max","left","right","bottom","wrap","autosize","percentage","width","height","percentWidth","percentHeight","forceWidth","browser","outerWidth","_outerWidth","outerHeight","_outerHeight","parent","windowOuterWidth","removeClass","hasClass","wrapResize","style","percentRegExp","test","is","addClass","boxSizing","mozBoxSizing","webkitBoxSizing","msie","floor","version","zoom","children","wrapper","wrapperStyle","display","position","deepExtend","destination","i","arguments","deepExtendOne","source","property","propValue","propType","propInit","destProp","ObservableArray","data","LazyObservableArray","DataSource","HierarchicalDataSource","OBJECT","constructor","Array","RegExp","isFunction","ArrayBuffer","UNDEFINED","Date","getTime","clone","testRx","agent","rxs","dflt","rx","hasOwnProperty","toHyphens","str","g","toLowerCase","toCamelCase","strMatch","g1","toUpperCase","getComputedStyles","properties","computedStyle","styles","document","defaultView","getComputedStyle","each","idx","value","getPropertyValue","currentStyle","size","isScrollable","className","indexOf","overflow","scrollLeft","isRtl","webkit","mozila","mozilla","el","scrollWidth","clientWidth","Math","abs","obj","key","result","getOffset","type","positioned","offset","sign","top","pointers","msPointers","pageYOffset","documentElement","scrollTop","pageXOffset","parseEffects","input","effects","this","fx","Element","prepareAnimationOptions","options","duration","reverse","complete","STRING","BOOLEAN","extend","init","noop","teardown","hide","completeCallback","animate","instance","queue","promise","toggleClass","classes","add","htmlEncode","ampRegExp","ltRegExp","gtRegExp","quoteRegExp","aposRegExp","unescape","template","decodeURIComponent","error","_","m1","m2","String","fromCharCode","parseInt","parseOption","option","dashRegExp","getAttribute","ns","numberRegExp","parseFloat","jsonRegExp","jsonFormatRegExp","Function","parseOptions","role","templateRegExp","html","containmentComparer","a","b","contains","resizableWidget","widget","inArray","attr","focusable","isTabIndexNotNaN","nodeName","disabled","href","visible","expr","pseudos","parents","addBack","filter","kendoJQuery","selector","context","fn","Template","preventDefault","isDefaultPrevented","Observable","argumentNameRegExp","encodeRegExp","escapedCurlyRegExp","curlyRegExp","escapedSharpRegExp","sharpRegExp","directions","eventTarget","wrapExpression","localUrlRe","Widget","DataBoundWidget","ContainerNullObject","MobileWidget","MOUSE_EVENTS","EXCLUDE_BUST_CLICK_SELECTOR","MouseEventNormalizer","eventMap","getEventMap","eventRegEx","on","rootjQuery","animationFrame","animationQueue","cultures","isArray","proxy","JSON","formatRegExp","FUNCTION","NUMBER","NULL","getterCache","setterCache","slice","noDepricateExtend","src","copyIsArray","copy","name","target","deep","jQuery","isPlainObject","proto","member","base","that","subclass","apply","prototype","Object","_initOptions","_defaultPrevented","_events","bind","eventName","handlers","one","original","handler","events","eventNames","handlersIsFunction","unbind","push","unshift","trigger","e","sender","call","splice","paramName","useWithBlock","render","compile","parts","settings","argumentName","functionBody","_slotCount","Error","format","quote","string","escapable","lastIndex","c","meta","charCodeAt","toString","holder","k","v","partial","mind","gap","toJSON","rep","isFinite","indent","\b","\t","\n","\f","\r","\"","\\","valueOf","getUTCFullYear","getUTCMonth","getUTCDate","getUTCHours","getUTCMinutes","getUTCSeconds","Number","Boolean","stringify","replacer","space","","findCulture","culture","numberFormat","getCulture","current","formatDate","date","calendar","calendars","standard","days","months","patterns","dateFormatRegExp","minutes","getDate","namesAbbr","getDay","names","getMonth","getFullYear","getHours","getMinutes","getSeconds","getMilliseconds","AM","PM","getTimezoneOffset","formatNumber","decimal","precision","pattern","literals","symbol","isCurrency","isPercent","customPrecision","formatAndPrecision","negative","integer","fraction","integerLength","fractionLength","replacement","ch","hasGroup","hasNegativeFormat","decimalIndex","sharpIndex","zeroIndex","hasZero","hasSharp","percentIndex","currencyIndex","startZeroIndex","start","exp","rounded","POINT","decimals","EMPTY","toLocaleString","standardFormatRegExp","exec","currency","percent","toExponential","round","groupInteger","literalRegExp","quoteChar","literal","PLACEHOLDER","SHARP","ZERO","COMMA","commaRegExp","lastIndexOf","EN","objectToString",",",".","groupSize","abbr","namesShort","d","D","F","G","m","M","s","t","T","u","y","Y","/",":","firstDay","twoDigitYearMax","cultureName","newGroupSize","groupSizes","shift","toFixed","min","fmt","values","index","placeholderFormat","_extractFormat","_activeElement","activeElement","_round","includeMargin","outOfRange","designatorPredicate","designator","mapDesignators","designators","map","adjustDST","hours","setHours","lowerArray","array","lowerLocalInfo","localInfo","newLocalInfo","parseExact","strict","count","pmHour","UTC","matches","amDesignators","pmDesignators","hoursOffset","minutesOffset","hasTime","lookAhead","getNumber","rg","substr","valueIdx","getIndexByName","lower","nameLength","subValue","matchLength","matchIdx","checkLiteral","year","month","day","seconds","milliseconds","defaultYear","_lowerDays","_lowerMonths","longTimeZoneRegExp","shortTimeZoneRegExp","isNaN","setFullYear","parseMicrosoftFormatOffset","getDefaultFormats","cultureFormats","formatIdx","FORMATS_SEQUENCE","STANDARD_FORMATS","formats","concat","internalParseDate","tzoffset","dateRegExp","offsetRegExp","timezone","convert","nonBreakingSpaceRegExp","exponentRegExp","2","3","4","parseDate","parseExactDate","percentSymbol","table","docStyle","transforms","elementProto","mobileOS","documentMode","chrome","mobileChrome","safari","_scrollbar","scrollbar","refresh","div","createElement","cssText","innerHTML","body","appendChild","offsetWidth","removeChild","closest","tbodyInnerHtml","touch","HTMLElement","hasHW3D","WebKitCSSMatrix","cssFlexbox","lowPrefix","prefix","hasTransitions","event","devicePixelRatio","screenWidth","screen","availWidth","innerWidth","screenHeight","availHeight","innerHeight","detectOS","ua","minorVersion","os","notAndroidPhone","agentRxs","wp","fire","android","iphone","ipad","meego","webos","blackberry","playbook","windows","tizen","sailfish","ffos","osRxs","ios","flat","formFactorRxs","tablet","browserRxs","omini","omobile","firefox","mobilesafari","ie","navigator","device","majorVersion","flatVersion","cordova","PhoneGap","appMode","standalone","location","protocol","userAgent","wpDevicePixelRatio","hasNativeScrolling","delayedClick","mouseAndTouchPresent","detectBrowser","edge","opera","detectClipboardAccess","commands","queryCommandSupported","cut","paste","clipboard","zoomLevel","ie11WidthCorrection","docEl","scrollHeight","clientHeight","cssBorderSpacing","borderSpacing","cssClass","docElement","eventCapture","addEventListener","placeholder","propertyChangeEvent","types","setAttribute","cssFloat","stableSort","threshold","sorted","field","sort","matchesSelector","webkitMatchesSelector","mozMatchesSelector","msMatchesSelector","oMatchesSelector","nodeList","querySelectorAll","parentNode","matchMedia","pushState","history","hashChange","customElements","crios","MSPointerEvent","PointerEvent","kineticScrollNeeded","down","up","in","out","enabled","dequeue","disable","promiseShim","enable","animatedPromise","kendoStop","clearQueue","gotoEnd","stop","kendoAnimate","kendoAddClass","kendoRemoveClass","kendoToggleClass","toggle","touches","originalEvent","changedTouches","elementFromPoint","clientX","clientY","callback","mousedown","mouseup","mousemove","mousecancel","click","resize","members","widgets","_widgetRegisteredCallbacks","ui","mobile","dataviz","drawing","spreadsheet","messages","keys","INSERT","DELETE","BACKSPACE","TAB","ENTER","ESC","LEFT","UP","RIGHT","DOWN","END","HOME","SPACEBAR","PAGEUP","PAGEDOWN","F2","F10","F12","NUMPAD_PLUS","NUMPAD_MINUS","NUMPAD_DOT","isLocalUrl","url","expression","safe","getter","setter","accessor","get","set","guid","random","id","roleSelector","directiveSelector","directives","selectors","triggeredByInput","tagName","onWidgetRegistered","len","logToConsole","message","console","suppressLog","log","dataSource","props","angular","componentTypes","componentType","defaults","_hasBindingTarget","kendoBindingTarget","_tabindex","TABINDEX","tabindex","removeAttr","setOptions","_setEvents","force","getSize","currentSize","_size","_resize","dimensions","setSize","destroy","removeData","_destroy","_muteAngularRebind","_muteRebind","dataItems","flatView","_angularItems","cmd","elements","items","dataItem","domElement","offsetHeight","notify","initWidget","roles","fullPath","widgetKeyRegExp","widgetKey","nodeType","isEmptyObject","rolesFromNamespaces","namespaces","find","widgetsArray","makeArray","widgetInstance","progress","container","leftRight","webkitCorrection","containerScrollLeft","mask","opacity","loading","prependTo","remove","plugin","register","widgetEntry","args","method","nullObject","autoApplyNS","kendoDestroy","view","viewElement","viewHasNativeScrolling","useNativeScrolling","eq","appLevelNativeScrolling","application","themes","views","touchScroller","useNative","Scroller","kendoMobileScroller","suites","editorToolbar","elementData","onResize","setTimeout","unbindResize","off","attrValue","Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","kendoFocusable","setupMouseMute","mouseTrap","bustClick","captureMouse","stopPropagation","muteMouse","clearTimeout","mouseTrapTimeoutID","unMuteMouse","move","cancel","MSPointerEnter","MSPointerLeave","orig","fix","special","delegateType","bindType","handle","ret","related","relatedTarget","handleObj","origType","applyEventMap","keyDownHandler","kendoKeydown","preventKendoKeydown","keyDownCallBack","pop","search","touchstart","touchend","ruleToDate","rule","targetDay","ourDay","time","cache","getUTCDay","setUTCDate","findRule","utcTime","rules","zone","grep","from","to","findZone","zones","until","zoneRules","zoneAndRule","info","fromOffset","toOffset","diff","fromLocalOffset","toLocalOffset","tempToOffset","toLocalDate","Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec","Sun","Mon","Tue","Wed","Thu","Fri","Sat","setDayOfWeek","dir","setDate","dayOfWeek","firstDayOfMonth","lastDayOfMonth","last","timeOffset","moveDateToWeekStart","weekStartDay","addDays","calcWeekInYear","firstWeekInYear","newDate","diffInMS","MS_PER_DAY","weekInYear","prevWeekDate","nextWeekDate","weekNumber","toUtcTime","toInvariantTime","isInTimeRange","msValue","msMin","msMax","isInDateRange","setTime","ignoreDST","difference","MS_PER_MINUTE","today","isToday","staticDate","nextDay","previousDay","MS_PER_HOUR","stripWhitespace","iterator","child","createNodeIterator","NodeFilter","SHOW_TEXT","node","FILTER_ACCEPT","FILTER_REJECT","nextNode","referenceNode","textContent","trim","childNodes","nodeValue","requestAnimationFrame","webkitRequestAnimationFrame","mozRequestAnimationFrame","oRequestAnimationFrame","msRequestAnimationFrame","queueAnimation","runNextAnimation","parseQueryStringParams","queryString","params","paramParts","elementUnderCursor","x","client","wheelDeltaY","jQueryEvent","delta","deltaY","wheelDelta","detail","axis","VERTICAL_AXIS","throttle","delay","timeout","throttled","lastExecTime","elapsed","caret","rangeElement","rangeDuplicated","selectionStart","selectionEnd","isPosition","focus","setSelectionRange","selection","createTextRange","collapse","moveStart","moveEnd","select","duplicate","moveToBookmark","createRange","getBookmark","setEndPoint","text","compileMobileDirective","scope","injector","invoke","$compile","$$phase","$digest","antiForgeryTokens","tokens","csrf_token","csrf_param","cycleForm","form","firstElement","lastElement","keyCode","shiftKey","focusElement","scrollTopPositions","scrollableParents","parentsUntil","setActive","focusNextElement","focussable","nextElement","getWidgetFocusableElement","nextFocusable","addAttribute","attribute","removeAttribute","toggleAttribute","matchesMedia","mediaQuery","media","_bootstrapToMedia","bootstrapMedia","xs","sm","md","lg","xl","fileGroupMap","audio","video","image","txt","presentation","programming","pdf","config","zip","disc-image","getFileGroup","extension","withPrefix","extensions","fileTypeMap","groups","getFileSizeMessage","sizes","pow","selectorFromClasses","postToProxy","dataURI","fileName","proxyURL","proxyTarget","action","contentType","base64","appendTo","submit","saveAsBlob","blob","atob","Uint8Array","Blob","buffer","msSaveBlob","saveAsDataURI","URL","createObjectURL","fileSaver","download","createEvent","initMouseEvent","dispatchEvent","revokeObjectURL","downloadAttribute","saveAs","save","forceProxy","proxyModelSetters","observable","forEach","defineProperty","dirty","setDefaults","path","curr","amd","a1","a2","a3","parseInteger","parseCSS","propertyName","acc","strip3DTransforms","transformProps","transform2d","normalizeCSS","lowerKey","isTransformed","transformation","cssValues","TRANSFORM","animationProperty","transform","computed","NONE","matrix3dRegExp","translateXRegExp","atan2","capitalize","word","createEffect","definition","effectClass","Effect","direction","opt1","opt2","opt3","theDirection","createToggleEffect","defaultStart","defaultEnd","IN_OUT","startValue","_startValue","endValue","_endValue","shouldHide","_shouldHide","prepare","_direction","startDataValue","startDataValueIsSet","_reverse","clipInHalf","vertical","HEIGHT","WIDTH","CLIPS","curProxy","EffectSet","FOUR_DIRECTIONS","TRANSFER_START_STATE","ROTATIONS","RESTORE_OVERFLOW","IGNORE_TRANSITION_EVENT_SELECTOR","Animation","Transition","scaleProperties","scale","scalex","scaley","scale3d","translateProperties","translate","translatex","translatey","translate3d","hasZoom","cssParamsRegExp","oldEffectsRegExp","singleEffectRegExp","unitRegExp","transform2units","rotate","skew","cssPrefix","BLANK","PX","AUTO","HIDDEN","ORIGIN","ABORT_ID","OVERFLOW","TRANSLATE","POSITION","COMPLETE_CALLBACK","TRANSITION","BACKFACE","PERSPECTIVE","DEFAULT_PERSPECTIVE","TRANSFORM_PERSPECTIVE","transition","modifier","horizontal","stopQueue","val","transformValue","step","elem","now","cur","prop","exclusive","ease","mirror","redirectedEffect","resolved","$1","$2","effect","effectBody","timeoutID","stopTransitionCalled","stopTransition","oldKeys","speeds","merge","uniqueSort","unique","taskKeys","retainPosition","restore","run","jdx","childrenLength","effectName","deferred","Deferred","done","setReverse","addRestoreProperties","reset","setup","resolve","restoreCallback","effectSet","parsedEffects","useTransition","show","multiple","single","isFixed","originalPosition","dX","dY","currentValue","marginLeft","marginTop","_additionalEffects","play","additional","_duration","compositeRun","_complete","divisor","tmp","previous","previousDivisor","slideIn","margin","origin","setLength","oldLength","realLength","outerBox","box","innerBox","currentScale","fillScale","transformOrigin","_container","rotation","zIndex","_clipInHalf","clip","append","face","_face","temporary","back","temp","reverseDirection","faceClone","backClone","staticPage","turningPage","transformStyle","_before","_after","transitionClass","_previous","_transitionClass","beforeTransition","afterTransition","_both","_element","_containerClass","containerClass","completeProxy","isAbsolute","originalOverflow","both","_tickProxy","_tick","_started","tick","onEnd","onCancel","timePassed","startDate","moveTo","movable","initial","_easeProxy","moveAxis","easeOutExpo","easeOutBack","inner","outer","fitScale","toOdataFilter","useOdataFour","operator","ignoreCase","logic","filters","odataFilters","odataFiltersVersionFour","stripMetadata","hex16","createBoundary","createDelimeter","boundary","close","NEWLINE","createCommand","transport","item","httpVerb","command","transportUrl","commandPrefix","getOperationHeader","changeset","changeId","header","getOperationContent","content","DOUBLELINE","getOperations","collection","skipContent","requestBody","processCollection","colection","getBoundary","createBatchRequest","colections","batchURL","batch","headers","Content-Type","updated","destroyed","created","parseBatchResponse","responseText","changeBody","status","code","marker","jsonModel","responseMarkers","markerIndex","collections","models","passed","parse","neq","gt","gte","lt","lte","doesnotcontain","endswith","startswith","isnull","isnotnull","isnullorempty","isnotnullorempty","isempty","isnotempty","mappers","pageSize","page","useVersionFour","$filter","orderby","order","$orderby","skip","$skip","take","$top","defaultDataType","read","dataType","schemas","odata","results","total","transports","jsonp","update","create","parameterMap","$inlinecount","$format","odata-v4","$count","ajax","success","response","responses","XmlDataReader","idField","xmlParse","model","errors","serialize","modelBase","Model","fields","xpathToMember","modelInstance","evaluate","record","_parse","xml","parseDOM","parsedNode","attributes","attributeCount","firstChild","nextSibling","intermediateResult","tree","parseXML","raw","readers","eventHandler","CHANGE","_notifyChange","equal","xtype","ytype","getFieldByName","fieldName","Query","normalizeSort","descriptor","descriptors","sortFields","sorts","sortObject","normalizeOperator","operatorMap","normalizeFilter","compareDescriptor","f1","f2","normalizeDescriptor","fieldComparer","compareFilters","expr1","expr2","filters1","filters2","normalizeAggregate","expressions","normalizeGroup","compare","skipItemSorting","aggregates","normalizeGroupWithoutCompare","anyGroupDescriptorHasCompare","groupDescriptors","groupValueComparer","calculateAggregate","accumulator","state","aggr","functionName","aggregate","functions","isNumber","isDate","serializeRecords","getters","originalFieldNames","fieldNames","originalName","setters","convertRecords","convertGroup","hasSubgroups","wrapDataAccess","originalFunction","converter","wrapDataAccessBase","fillLastGroup","originalGroup","newGroup","currOriginal","currentNew","mergeGroups","dest","group","flatGroups","indexFunction","groupIndex","itemIndex","groupsLength","indexFn","flattenGroups","at","wrapGroupItems","eachGroupItems","func","replaceInRanges","ranges","replaceInRange","replaceWithObservable","serverGrouping","viewIndex","removeModel","uid","indexOfPristineModel","_defaultId","indexOfModel","comparer","fieldNameFromModel","convertFilterDescriptorsField","convertDescriptorsField","inferSelect","firstField","secondField","optgroup","label","specified","inferTable","fieldIndex","cells","cell","empty","tbody","tBodies","rows","fieldCount","dataMethod","_data","_attachBubbleHandlers","inferList","list","textChild","textField","urlField","spriteCssClassField","imageUrlField","_loaded","hasChildren","ObservableObject","parsers","defaultValues","Comparer","StableComparer","operators","LocalTransport","RemoteTransport","Cache","DataReader","Transport","Node","Buffer","BatchBuffer","ASCENDING","CREATE","READ","UPDATE","DESTROY","SYNC","GET","ERROR","REQUESTSTART","PROGRESS","REQUESTEND","crud","identity","o","wrapAll","serializeFunctions","json","object","omitChangeEvent","howMany","thisArg","reduce","reduceRight","every","some","Symbol","_parent","_handlers","shouldSerialize","_set","paths","composite","isSetPrevented","change","isObservableArray","isDataSource","boolean","default","_initializers","dirtyFields","editable","accept","isNew","functionFields","nullable","defaultValue","localeCompare","combine","comparers","asc","valueA","valueB","__position","desc","textOp","impl","ignore","accentFoldingFiltering","toLocaleLowerCase","op","getMatchRegexp","esc","doesnotstartwith","n","doesnotendwith","doesnotmatch","filterExpr","and","or","fieldFunctions","operatorFunctions","==","equals","isequalto","equalto","!=","ne","notequals","isnotequalto","notequalto","notequal","<","islessthan","lessthan","less","<=","le","islessthanorequalto","lessthanequal",">","isgreaterthan","greaterthan","greater",">=","isgreaterthanorequalto","greaterthanequal","ge","notsubstringof","toArray","range","inPlace","orderBy","orderByDescending","compiled","predicate","allData","groupPaging","groupAllData","itemCount","subgroupCount","groupBy","groupValue","_sortForGrouping","_sortGroups","sum","average","process","customGroupSort","query","groupDescriptorsWithoutCompare","normalizedSort","groupDescriptorsWithoutSort","filterCallback","groupDescriptor","parameters","operation","_store","clear","store","inmemory","schema","dataFunction","groupsFunction","serializeFunction","serializeGetters","_dataAccessFunction","fromName","_wrapDataAccessBase","_map","_prefetch","_pristineData","_ranges","_view","_pristineTotal","_destroyed","_pageSize","_page","_sort","_sortFields","_filter","_group","_aggregate","_total","_groupPaging","_groupsState","_shouldDetachObservableParents","pushCreate","_pushCreate","pushUpdate","_pushUpdate","pushDestroy","_pushDestroy","offlineStorage","_storage","getItem","localStorage","setItem","reader","_detachObservableParents","_observe","_online","serverSorting","serverPaging","serverFiltering","serverAggregates","inPlaceSort","online","sync","offlineData","_isServerGrouped","_isServerGroupPaged","_isGroupPaged","_push","_readData","_flatData","useRanges","getByUid","_getByUid","_storeData","_addRange","_process","_observeView","insert","_createNewModel","_wrapInEmptyGroup","_insertModelInRange","pushInsert","pushed","autoSync","pristine","rangeSpan","_getCurrentRangeSpan","pristineData","_updatePristineForModel","_removeItems","removePristine","shouldRemovePristine","found","_eachItem","_removePristineForModel","hasGroups","_removeModelFromRanges","promises","_sendSubmit","_send","when","then","_accept","_syncEnd","_change","cancelChanges","_cancelModel","_changesCanceled","_markOfflineUpdatesAsDirty","__state__","hasChanges","serverGroup","_handleCustomErrors","_executeOnPristineForModel","_eachPristineItem","_pristineForModel","_modelCanceled","_submit","reject","_promise","converted","_params","_queueRequest","isPrevented","_dequeueRequest","_readAggregates","replaceSubset","itemIds","j","_serverGroupsTotal","_aggregateResult","_skip","endless","_changeHandler","updatePristine","timestamp","_timeStamp","outerStart","outerEnd","_sortRanges","_groupsFlat","_appendToGroupsFlat","_updateOuterRangesLength","_getGroupByUid","xhr","errorThrown","_requestInProgress","_pending","_shouldWrap","arrayType","_updateTotalForAction","_calculateAggregates","_take","currentRangeStart","_clearEmptyGroups","_queryProcess","dataToAggregate","_setView","_setFilterTotal","_mergeState","_currentRangeStart","moreItemsCount","remote","_hasExpandedSubGroups","_findGroupedRange","itemsLength","hasNotRequestedItems","groupCount","itemsToSkip","taken","getGroupSubGroupCount","_fetchingGroupItems","skipped","getGroupItems","includeParents","excludeHeader","currentItems","subgroups","_composeItemsFilter","findSubgroups","_timeout","_groupItemsSuccessHandler","includeSubGroupCount","_subGroupCountSuccessHandler","totalField","_updateRangePristineData","_currentRequestTimeStamp","_skipRequestsInProgress","indexOfCurrentGroup","currentGroup","dataLength","indexes","rangesLength","_containsSubGroup","_cloneGroup","subgroup","currentSubGroup","filterTotal","setDefaultValue","fetch","_query","next","totalPages","prev","_pageableQueryOptions","getGroupsFlat","groupsTotal","includeExpanded","_calculateGroupsTotal","itemsField","ignoreState","_groupsTotal","countGroupRange","_emptyAggregates","ceil","inRange","_findRange","lastRange","firstItemUid","enableRequestsInProgress","pageSkip","_originalPageSkip","_originalSize","_adjustPageSkip","_groupRangeExists","_rangeExists","prefetch","_processRangeData","skipIdx","takeIdx","startIndex","endIndex","rangeData","rangeEnd","processed","flatData","prevRangeEnd","currentDataLength","groupMapOptions","isGroupPaged","startField","endField","_mergeGroups","_getRangesMismatch","mismatch","prevGroup","eventData","paging","sorting","filtering","_omitPrefetch","_prefetchSuccessHandler","_multiplePrefetch","prevRange","_getPrevRange","_getNextRange","availableItemsCount","_removeModelFromRange","_updateRangesLength","rangeLength","mismatchFound","mismatchLength","lengthDifference","transportOptions","hasChildrenObject","childrenField","childrenOptions","_childrenOptions","_initChildren","_updateChildrenField","loaded","level","_childrenLoaded","load","_matchFilter","_hierarchicalFilter","_markHierarchicalQuery","_updateHierarchicalFilter","_find","_dataSource","viewSize","disablePrefetch","_prefetching","_reset","_syncWithDataSource","setViewSize","_recalculate","itemPresent","dataOffset","prefetchThreshold","midPageThreshold","nextMidRange","nextPageThreshold","nextFullRange","pullBackThreshold","previousMidRange","previousFullRange","_goToRange","nextRange","syncDataSource","prefetchOffset","expanding","_expanding","_syncPending","_firstItemUid","batchSize","batchBuffer","endreached","prefetching","prefetched","isJQueryPromise","fail","isNativePromise","hub","signalr","callbacks","_crud","server","dataSourceBinding","bindingName","Binder","bindings","_dataBinding","dataBinding","_dataBound","dataBound","_itemChange","itemChange","bindElement","_ns","_parents","removedItems","unbindElementTree","all","addedItems","hds","addedDataItems","multiselect","dropdowntree","Select","MultiSelect","DropDownTree","treeview","retrievePrimitiveValues","dataValueField","bindingTargetForRole","WidgetBindingTarget","parseBindings","token","colonIndex","keyValueRegExp","createBindings","binding","childrenCopy","unbindElement","whiteSpaceRegExp","valueField","valueUpdate","valuePrimitive","autoBind","BindingTarget","Binding","TemplateBinding","EventBinding","dom","destroyWidget","bindingTarget","deleteExpando","destroyWidgets","unbindElementChildren","namespace","TypedBinder","arraySplice","binders","VALUE","SOURCE","EVENTS","CHECKED","CSS","dependencies","_access","dependency","currentSource","parsedValue","_parseValue","readonly","dataFormat","invisible","_initChange","cloneNode","reference","insertBefore","checked","selectedIndex","selected","valueIndex","sourceValue","optionIndex","optionValue","check","_range","_valueIsObservableObject","_valueIsObservableArray","_source","valueLength","sourceItem","dataTextField","isObservableObject","cascadeFrom","listView","bound","_preselect","newLength","old","same","removeIndex","newValue","oldValues","selectedNode","nonPrimitiveValues","_isMultipleSelection","_getAllChecked","newValues","selectedValue","gantt","_isBound","scheduler","grid","arr","addLength","shifted","shiftedLength","toDestroy","hasValue","hasSource","hasEvents","hasChecked","hasCss","widgetBinding","specificBinders","applyBinding","binder","observableHierarchy","recursiveRead","resolveRules","resolvers","validator","ruleResolvers","decode","numberOfDecimalDigits","parseHtml","parseHTML","searchForMessageContainer","containers","invalidMsgRegExp","SUMMARYTEMPLATE","Validator","NS","INVALIDMSG","INVALIDINPUT","VALIDINPUT","VALIDATIONSUMMARY","INVALIDLABEL","MESSAGEBOX","ARIAINVALID","ARIADESCRIBEDBY","emailRegExp","urlRegExp","INPUTSELECTOR","CHECKBOXSELECTOR","NUMBERINPUTSELECTOR","BLUR","NAME","FORM","NOVALIDATE","VALIDATE","VALIDATE_INPUT","patternMatcher","matcher","hasAttribute","allowSubmit","validateOnInit","validateAttributeSelector","_errorTemplate","errorTemplate","_summaryTemplate","validationSummary","_inputSelector","_checkboxSelector","_errors","_attachEvents","_isValidated","_validateOnInit","validate","required","email","dateCompare","checkbox","raise","validateOnBlur","_allowSubmit","stopImmediatePropagation","_checkElement","validateInput","inputs","invalid","isValid","showValidationSummary","valid","lbl","messageText","messageLabel","wasValid","lblId","parentElement","inputWrap","inputLabel","errorId","_checkValidity","_findMessageContainer","_extractMessage","_decorateMessageContainer","replaceWith","insertAfter","_inputWrapper","_inputLabel","_associateMessageContainer","hideMessages","_disassociateMessageContainers","labels","hideValidationSummary","locators","messageLocators","getElementsByTagName","locate","decorate","ruleKey","nonDefaultMessage","customMessage","_getInputNames","_errorsByName","inputNames","_renderSummary","prevElement","_summaryClick","link","errorsList","summary","absoluteURL","pathPrefix","regEx","host","hashDelimiter","bang","locationHash","stripRoot","root","fixHash","fixBang","BACK","SAME","CHECK_URL_INTERVAL","BROKEN_BACK_NAV","hashStrip","HistoryAdapter","forward","replaceLocation","PushStateAdapter","navigate","title","replaceState","normalize","pathname","normalizeCurrent","fixedUrl","hash","hashBang","HashAdapter","_id","_interval","setInterval","clearInterval","History","adapter","createAdapter","historyLength","locations","silent","_navigate","backCalled","_checkUrl","navigatingInExisting","backButtonPressed","namedParamReplace","optional","routeToRegExp","route","escapeRegExp","optionalParam","namedParam","splatParam","stripUrl","INIT","ROUTE_MISSING","Route","_callback","queryStringParams","_back","worksWith","Router","routes","_urlChangedProxy","_sameProxy","_backProxy","initEventObject","sameProxy","_same","backProxy","urlChangedProxy","_urlChanged","parseTransition","transitionRegExp","SCRIPT","TRANSITION_START","TRANSITION_END","SHOW","HIDE","ATTACH","DETACH","sizzleErrorRegExp","bodyRegExp","LOAD_START","LOAD_COMPLETE","SHOW_START","SAME_VIEW_REQUESTED","VIEW_SHOW","VIEW_TYPE_DETERMINED","AFTER","classNames","stretchedView","footer","View","renderOnInit","_createElement","wrapInSections","_renderSections","_wrap","_evalTemplate","evalTemplate","_fragments","detachOnHide","detachOnDestroy","notInitialized","_eachFragment","ViewClone","triggerBeforeShow","triggerBeforeHide","showStart","showEnd","hideEnd","detach","purge","fragments","methodName","getElementById","contents","_wrapper","_createContent","_createHeader","_createFooter","ccontentElements","contentSelector","contentElement","Layout","_createContainer","showIn","ViewContainer","Fragment","attach","running","after","locationID","previousEntry","theTransition","transitionData","ViewEngine","sandbox","_hideViews","rootView","layouts","viewContainer","showView","remoteViewURLPrefix","_findViewElement","reload","_createView","urlPath","wrapInner","_locate","$angular","_findViewElementById","_createSpaView","_createMobileView","defaultTransition","loader","getLayout","getLayoutProxy","modelScope","viewOptions","touchDelta","touch1","touch2","x1","y1","x2","y2","dx","dy","center","distance","sqrt","getTouches","currentTarget","api","identifier","pointerId","withEachUpEvent","downEvents","OS","invalidZeroEvents","DEFAULT_MIN_HOLD","CLICK_DELAY","DEFAULT_THRESHOLD","PRESS","HOLD","SELECT","START","MOVE","CANCEL","TAP","DOUBLETAP","RELEASE","GESTURESTART","GESTURECHANGE","GESTUREEND","GESTURETAP","THRESHOLD","mouse","pointer","ENABLE_GLOBAL_SURFACE","TouchAxis","_updateLocationData","startLocation","velocity","timeStamp","timeDelta","initialDelta","Touch","userEvents","touchInfo","useClickAsTap","initialTouch","pressEvent","_clicks","supportDoubleTap","_moved","_finished","press","_holdTimeout","minHold","_trigger","_tap","_clickTimeout","_hold","preventMove","_shouldNotMove","_withinIgnoreThreshold","UserEvents","dispose","_start","endTime","activeTouches","isMoved","startTime","xDelta","yDelta","defaultAction","surfaceElement","preventIfMovingProxy","_maxTouches","multiTouch","allowSelection","captureUpIfMoved","fastTap","eventNS","surface","global","ownerDocument","pressed","touchAction","preventDragEvent","preventIfMoving","_isMoved","removeEventListener","_disposeAll","capture","_isMultiTouch","_apiCall","_maxTouchesReached","_select","which","_move","_eachTouch","_end","_click","pageX","pageY","matchingTouch","dict","defaultThreshold","numericCssPropery","within","containerBoundaries","minX","minY","maxX","maxY","checkTarget","targets","areas","theTarget","theFilter","targetLen","areaLen","targetElement","destroyDroppable","groupName","droppables","scrollableViewPort","scrollableRoot","$window","findScrollableParent","autoScrollVelocity","mouseX","mouseY","rect","AUTO_SCROLL_AREA","lastDropTarget","Movable","DropTarget","DropTargetArea","Draggable","draggables","dropTargets","dropAreas","KEYUP","DRAGSTART","DRAG","DRAGEND","DRAGCANCEL","HINTDESTROYED","DRAGENTER","DRAGLEAVE","DROP","TapCapture","_press","_release","attachEvent","captureNext","cancelCapture","PaneDimension","forcedEnabled","measure","scrollSize","makeVirtual","virtual","_virtualMin","_virtualMax","virtualSize","outOfBounds","forceEnabled","getTotal","rescale","scaledTotal","minScale","centerOffset","PaneDimensions","forcedMinScale","maxScale","newScale","centerCoordinates","PaneAxis","dimension","dragMove","resistance","translateAxis","Pane","elastic","gesturestart","gesture","gesturechange","coordinates","offsetX","offsetY","previousGesture","previousCenter","scaleDelta","scaleWith","TRANSFORM_STYLE","webkitTransformOrigin","_saveCoordinates","by","scaleTo","newCoordinates","draggable","dropTarget","_over","_out","_drop","dropped","destroyGroup","_cache","_activated","hold","_drag","_cancel","_afterEndHandler","_afterEnd","_captureEscape","cursorOffset","holdToDrag","autoScroll","cancelHold","_updateHint","boundaries","hintOffset","hint","_shouldIgnoreTarget","ignoreSelector","currentTargetOffset","scopeTarget","scopeFrom","cursorElement","_elementUnderCursor","_cursorElement","_scrollableParent","_lastEvent","_processMovement","_scrollCompenstation","_scrollVelocity","_scrollInterval","_withDropTarget","_autoScroll","yIsScrollable","xIsScrollable","isRootNode","yInBounds","xInBounds","compensation","initialTarget","utils","tabKeyTrapNS","focusableNodesSelector","TabKeyTrap","OPEN","CLOSE","DEACTIVATE","ACTIVATE","CENTER","TOP","BOTTOM","ABSOLUTE","BODY","LOCATION","VISIBLE","EFFECTS","ACTIVE","ACTIVEBORDER","ACTIVEBORDERREGEXP","ACTIVECHILDREN","MOUSEDOWN","DOCUMENT_ELEMENT","WINDOW","SCROLL","Popup","parentPopup","collisions","collision","downEvent","anchor","_hovered","scrollArea","animation","open","_animationClose","_mousedownProxy","_mousedown","_resizeProxy","toggleTarget","toggleEvent","viewport","copyAnchorStyles","modal","adjustSize","_hideDirClass","_closing","_toggleResize","fixed","flipped","_position","_openAnimation","_showDirClass","_location","dirClass","skipEffects","openEffects","closeEffects","popup","ev","_resizeTimeout","_scrollableParents","_fit","viewPortSize","output","_flip","anchorSize","boxSize","siblingContainer","parentZIndex","viewportOffset","viewportWidth","viewportHeight","pos","anchorParent","offsets","flipPos","elementHeight","wrapperHeight","isWindow","origins","positions","siblings","_align","offsetParent","appendToOffset","verticalOrigin","horizontalOrigin","verticalPosition","horizontalPosition","anchorOffset","anchorWidth","anchorHeight","trap","_keepInTrap","removeTrap","shouldTrap","sortedElements","_focusableElements","_sortFocusableElements","_nextFocusable","_focus","tabIndex","attrName","contentWindow","_haveSelectionRange","elementType","MAX_DOUBLE_TAP_DISTANCE","eventProxy","_triggerTouch","gestureEventProxy","tap","gestureend","enableSwipe","minXDelta","maxYDelta","maxDuration","doubleTapTimeout","lastTap","_dragstart","_swipestart","_swipemove","SNAPBACK_DURATION","SCROLLBAR_OPACITY","FRICTION","VELOCITY_MULTIPLIER","MAX_VELOCITY","OUT_OF_BOUNDS_FRICTION","ANIMATED_SCROLLER_PRECISION","RELEASECLASS","REFRESHCLASS","PULL","RESIZE","MOUSE_WHEEL_ID","ZoomSnapBack","tapCapture","DragInertia","freeze","_moveTo","paneAxis","_snapBack","velocityMultiplier","friction","snapBack","AnimatedScroller","_updateCoordinates","setCoordinates","setCallback","ScrollBar","elementSize","scrollMovable","alwaysVisible","paneSize","sizeRatio","visibility","avoidScrolling","pane","zoomSnapBack","animatedScroller","_native","prepend","scrollElement","fixedContainer","velocityX","velocityY","horizontalSwipe","originatedFromFixedContainer","verticalSwipe","scrollTo","mousewheelScrolling","pulled","_initAxis","_wheelEnd","_wheel","_wheelY","pullToRefresh","_initPullToRefresh","_wheelScroll","ctrlKey","_wheelTimeout","pullOffset","visibleScrollHints","pullTemplate","releaseTemplate","refreshTemplate","contentResized","_scale","zoomOut","animatedScrollTo","pullHandled","refreshHint","hintContainer","yinertia","xinertia","_paneChange","_dragEnd","scrollBar","initPopOvers","popovers","preventScrollIfNotInput","initWidgets","UI_OVERLAY","BEFORE_SHOW","AFTER_SHOW","BEFORE_HIDE","_overlay","_layout","_scroller","_model","layout","stretch","scroller","overlay","$destroy","inited","_invokeNgController","_padIfNativeScrolling","isAndroid","skin","isAndroidForced","hasPlatformIndependentSkin","topContainer","bottomContainer","paddingTop","paddingBottom","scrollerContent","idAttrValue","controller","$apply","_callController","$scope","platform","previousView","currentView","errorMessage","rootNeeded","_setupLayouts","showClosure","serverNavigation","_loadView","modalViews","_getLayout","_xhr","abort","always","_xhrComplete","CAPTURE_EVENTS","Loader","captureEvents","_attachCapture","_loading","changeMessage","transitionDone","EXTERNAL","HREF","DUMMY_HREF","NAVIGATE","SKIP_TRANSITION_ON_BACK_BUTTON","WIDGET_RELS","collapsible","historyCallback","viewEngine","_historyNavigate","_historyReplace","closeActiveDialogs","viewShow","loadStart","loadComplete","sameViewRequested","viewTypeDetermined","_setPortraitWidth","_setupAppLinks","dialogs","navigateToInitial","portraitWidth","bindToRouter","router","attrUrl","hideLoading","showLoading","changeLoadingMessage","linkRoles","pressedButtonSelector","buttonSelectors","_mouseup","_appLinkClick","rel","delayedTouchEnd","openFor","paneContainer","WRAPPER","ARROW","OVERLAY","DIRECTION_CLASSES","DIRECTIONS","ANIMATION","DIMENSIONS","REVERSE","popupOptions","containerPopup","activate","_activate","deactivate","arrow","elementOffset","offsetAmount","PopOver","initialOpen","SHIM","Shim","app","osname","ioswp","bb","align","shim","prevented","_hide","BEFORE_OPEN","WRAP","ModalView","_shim","AXIS","SWIPE_TO_OPEN","AFTER_HIDE","NULL_VIEW","Drawer","drawer","_viewShow","_attachTransition","swipeToOpen","_update","leftPositioned","swipeToOpenViews","_show","_moveViewTo","visibleOnCurrentView","_currentViewIncludedIn","_setAsCurrent","currentOffset","canMoveLeft","canMoveRight","leftSwipe","limitedPosition","newPosition","shouldShow","pastHalf","velocityThreshold","EXPANED_PANE_SHIM","SplitView","_style","panes","_paramsHistory","expandedPaneShim","_shimUserEvents","collapsePanes","expandPanes","osCssClass","variant","setDefaultPlatform","statusBarStyle","wp8Background","noVariantSet","isOrientationHorizontal","orientation","getOrientationClass","HORIZONTAL","VERTICAL","setMinimumHeight","applyViewportHeight","HEAD","viewportTemplate","DEFAULT_OS","BERRYPHONEGAP","FONT_SIZE_COEF","CHROME","BROKEN_WEBVIEW_RESIZE","INITIALLY_HORIZONTAL","MOBILE_PLATFORMS","ios7","usedWithBlock","systemMeta","clipTemplate","ENABLE_CLIP","iconMeta","HIDEBAR","SUPPORT_SWIPE_TO_GO_BACK","HISTORY_TRANSITION","BARCOMPENSATION","STATUS_BAR_HEIGHT","SCREEN","Application","bootstrap","paneOptions","startHistory","_setupPlatform","_attachMeta","_setupElementClass","_attachHideBarHandlers","updateDocumentTitle","_setupDocumentTitle","_startHistory","hideAddressBar","browserHistory","historyTransition","retina","refreshBackgroundColorProxy","_resizeToScreenHeight","includeStatusBar","_clearExistingMeta","icon","hideBar","_initialHeight","defaultTitle","_hideBar","COMMAND","BUTTONS","CONTEXT_DATA","cancelTemplate","ActionSheet","ShimClass","_closeProxy","_shimHideProxy","actionData","_close","_shimHide","highlightButton","highlight","ANDROID3UP","deactivateTimeoutID","createBadge","CLICK","DISABLED","DISABLEDSTATE","Button","useTap","clickOn","_userEvents","release","_timeoutDeactivate","badge","badgeElement","button","iconSpan","span","iconElement","BackButton","DetailButton","DISABLE","SELECTOR","ButtonGroup","_button","selectOn","_enable","li","buttongroup","COLLAPSIBLE","HEADER","CONTENT","INSET","HEADER_WRAPPER","CONTENT_WRAPPER","COLLAPSED","EXPANDED","ANIMATED","EXAPND","COLLAPSE","Collapsible","_buildHeader","not","collapsed","inset","collapseIcon","expandIcon","iconPosition","expand","instant","_getContentHeight","isCollapsed","whitespace","TEXT_NODE","whitespaceRegExp","addIcon","querySelector","enhanceItem","ICON_SELECTOR","enhanceLinkItem","itemAndDetailButtons","otherNodes","enhanceCheckBoxItem","putAt","VirtualListViewItem","LOAD_ICON","VirtualListViewLoadingIndicator","VirtualListViewPressToLoadMore","VirtualListViewItemBinder","ListViewItemBinder","ListViewFilter","ListView","ITEM_SELECTOR","HIGHLIGHT_SELECTOR","GROUP_CLASS","ACTIVE_CLASS","GROUP_WRAPPER","GROUP_TEMPLATE","SEARCH_TEMPLATE","STYLED","DATABOUND","DATABINDING","ITEM_CHANGE","buttonRegExp","HeaderFixer","headerFixer","cacheHeaders","_shouldFixHeaders","_cacheHeaders","_scrollHandler","_fixHeader","fixedHeaders","headerPair","currentHeader","DEFAULT_PULL_PARAMETERS","RefreshHandler","pullParameters","setDataSource","pull","_pulled","_first","VirtualList","itemConstructor","prevItem","endReached","below","totalHeight","averageItemHeight","remainingItemsCount","batchUpdate","nextIndex","initialOffset","lastDirection","above","firstItem","lastItem","padding","lastTop","topBorder","bottomBorder","setDataItem","_loadIcon","_loadButton","loadMoreText","loadMore","kendoMobileButton","_hideShowButton","_showLoadButton","chromeHeight","_scroll","_scrollEnd","pressToLoadMore","virtualViewSize","updateScrollerSize","updateSize","itemBinder","_refreshHandler","_progressHandler","_unbindDataSource","adding","removing","prependOnRefresh","appendOnRefresh","groupedMode","findByDataItem","_shouldShowLoading","replaceGrouped","insertAt","endlessScroll","filterable","before","autoFilter","searchInput","_oldFilter","_filterChange","clearButton","_dataSourceChange","_refreshInput","appliedFilters","_search","_applyFilter","_clearFilter","scrollTreshold","scrollThreshold","_headerFixer","_itemsCache","_templates","_itemBinder","_pullToRefreshHandler","_enhanceItems","headerTemplate","emptyDataSource","unwrap","_scrollerInstance","triggerChange","_renderItems","groupTemplate","replaceItem","newItem","_dim","_toggle","_highlight","clicked","plainItem","dataIDAttribute","templateProxy","groupTemplateProxy","_headerTemplate","buttonElement","_styleGroups","rootItems","groupHeader","grouped","enhanced","createContainer","toggleTitle","centerElement","noTitle","showTitle","prevAll","NavBar","leftElement","rightElement","DRAG_START","DRAG_END","ElasticPane","ScrollViewContent","VirtualScrollViewContent","Page","ScrollView","CHANGING","REFRESH","CURRENT_PAGE_CLASS","VIRTUAL_PAGE_CLASS","CLEANUP","VIRTUAL_PAGE_COUNT","LEFT_PAGE","CETER_PAGE","RIGHT_PAGE","LEFT_SWIPE","NUDGE","RIGHT_SWIPE","Pager","scrollView","_changeProxy","_refreshProxy","_refresh","pageHTML","pageCount","ScrollViewPager","updateDimension","transitionTo","ScrollViewElasticPane","_getPages","contentHeight","enablePager","pagerOverlay","paneMoved","swipeType","bounce","snap","nextPage","approx","minSnap","maxSnap","currentPage","updatePage","forcePageUpdate","resizeTo","containerHeight","pager","pageElements","_paged","pages","_initPages","_buffer","_pendingPageRefresh","_pendingWidgetRefresh","_resetPages","itemsPerPage","_resetProxy","_endReachedProxy","emptyTemplate","emptyTemplateProxy","setWidth","_repositionPages","_updatePagesContent","thresholdPassed","isEndReached","_cancelMove","_moveBackward","_moveForward","setPageContent","_resetMovable","_onResize","_onReset","_onEndReached","theContent","VirtualPage","mobileContainer","transitionEnd","dragStart","dragEnd","_syncWithContent","_content","viewInit","bounceVelocityThreshold","prevPage","_dragStart","_transitionEnd","limitValue","minLimit","maxLimit","SWITCHON","SWITCHOFF","MARGINLEFT","ACTIVE_STATE","DISABLED_STATE","RESOLVEDPREFIX","TRANSFORMSTYLE","SWITCH_MARKUP","Switch","onLabel","offLabel","background","constrain","snapPoint","_animateBackground","handleWidth","_stop","ACTIVE_STATE_CLASS","TabStrip","_buildButton","switchTo","tab","tabs","_setActiveItem","switchByFullUrl","currentItem","tabstrip","withoutTimeout","$timeout","createWidget","attrs","origAttr","controllers","createIt","originalElement","destroyRegister","kNgDisabled","isDisabled","kNgReadonly","isReadonly","kRebind","ctor","OPTIONS_NOW","exposeWidget","$emit","destroyWidgetOnScopeDestroy","setupRebind","$eval","bindToKNgDisabled","bindToKNgReadonly","kNgModel","bindToKNgModel","ngModel","bindToNgModel","ngForm","propagateClassToWidgetWrapper","kNgDelay","delayValue","parsed","unresolved","unwatch","$watch","$root","unregister","$attr","addOption","scopeValue","widgetOptions","widgetEvents","optionsPath","kOptions","optionsValue","defaultOptions","dataName","eventKey","optionName","ignoredOwnProperties","ignoredAttributes","kDataSource","createDataSource","PanelBar","Menu","$log","warn","oldValue","kendoWidget","$parse","assign","formValue","isForm","formRegExp","haveChangeOnElement","viewRender","onChange","currentVal","$viewValue","$modelValue","$render","formPristine","$pristine","$setViewValue","$setPristine","digest","AutoComplete","$isEmpty","rangePickerModels","rangePickerStartModel","rangePickerEndModel","updating","valueIsCollection","currentValueLength","watchHandler","changeHandler","DateRangePicker","_startDateInput","_endDateInput","RangeSlider","$angular_setLogicValue","$watchCollection","$setDirty","$angular_getLogicValue","deregister","$on","suspend","mo","disconnect","resume","observe","prevClassList","MutationObserver","classList","changes","chg","currClassList","w","attributeName","cls","ComboBox","rebindAttr","templateOptions","isUpload","_cleanUp","WIDGET_TEMPLATE_OPTIONS","templateContents","replaceChild","setTemplate","createDirectives","klass","isMobile","make","directiveName","widgetName","module","directive","directiveFactory","shortcut","dashed","SKIP_SHORTCUTS","restrict","tag","TAGNAMES","scopeField","kScopeField","MANUAL_DIRECTIVES","kendoWidgetInstance","isDigesting","destroyScope","defadvice","origMethod","pendingPatches","self","$injector","$defaultCompile","encode","encOpen","encClose","TreeList","TreeView","Scheduler","PivotGrid","PivotConfigurator","ContextMenu","toDataSource","ds","mew","factory","kendoRenderedTimeout","RENDERED","require","$attrs","$element","roleattr","Editor","NumericTextBox","DatePicker","DateTimePicker","TimePicker","ColorPicker","MaskedTextBox","Upload","MobileButton","MobileBackButton","MobileDetailButton","MobileListView","entry","arg","$angular_scope","$angular_init","itemScope","$$kendoScope","vars","$new","$angular_makeEventHandler","kendoEvent","elems","columns","colIdx","locals","isString","selectable","_checkBoxSelection","angularDataItem","templateSettings","col","encoded","terminal","pre","_instance","post","kAttr","priority","TreeMap","MobileScrollView","Grid","templateDirectives","templates","templateName","outerHTML"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;CAwBC,SAAUA,EAAGC,QACVA,OAAO,cAAe,UAAWD,IACnC,WAgsHE,MAzrHC,UAAUE,EAAGC,EAAQC,GA2ClB,QAASC,MA+GT,QAASC,GAAYC,EAAMC,GACvB,GAAIA,EACA,MAAO,IAAOD,EAAKE,MAAM,KAAMC,KAAK,OAAQD,MAAM,OAAOC,KAAK,WAAWC,QAAQ,MAAO,OAAOA,QAAQ,MAAO,OAAOA,QAAQ,MAAO,OAAS,GAE7I,IAAIC,GAAQL,EAAKM,OAAO,GAAIC,EA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Km1B,GAAYlsB,EAAU,IAAMjP,GAAOo2B,SAGxDp8B,GAAMohC,gBAAkB,SAAUvhC,EAASshC,EAAWn7B,GAClD,GAAIiP,GAAUpV,EAAQmM,KAAKm1B,IAAc,EACzCthC,GAAQmM,KAAKm1B,EAAWlsB,EAAQhW,QAAQ+G,EAAO,IAAIo2B,SAEvDp8B,GAAMqhC,gBAAkB,SAAUxhC,EAASshC,EAAWn7B,GAClD,GAAIiP,GAAUpV,EAAQmM,KAAKm1B,IAAc,EACrClsB,GAAQ3O,QAAQN,GAAS,EACzBhG,GAAMkhC,aAAarhC,EAASshC,EAAWn7B,GAEvChG,GAAMohC,gBAAgBvhC,EAASshC,EAAWn7B,IAGlDhG,GAAMshC,aAAe,SAAUC,GAC3B,GAAIC,GAAQxhC,GAAMyhC,kBAAkBF,IAAeA,CACnD,OAAOthC,IAAQioB,YAAczpB,EAAOypB,WAAWsZ,GAAOpkB,SAE1Dpd,GAAMyhC,kBAAoB,SAAUC,GAChC,OACIC,GAAM,qBACNC,GAAM,qBACNC,GAAM,qBACNC,GAAM,qBACNC,GAAM,uBACRL,IAEN1hC,GAAMgiC,cACFC,OACI,OACA,OACA,OACA,OACA,OACA,OACA,OACA,OACA,OACA,OACA,OACA,OACA,QAEJC,OACI,OACA,OACA,OACA,OACA,OACA,OACA,MACA,QACA,OACA,OACA,OACA,OACA,OACA,MACA,OACA,OACA,QAEJC,OACI,MACA,OACA,QACA,OACA,OACA,OACA,OACA,OACA,OACA,OACA,OACA,QACA,OACA,OACA,MACA,OACA,OACA,QACA,OACA,SAEJC,KACI,OACA,QACA,OACA,SACA,OACA,OACA,OACA,OACA,OACA,QACA,OACA,QAEJC,cACI,OACA,OACA,OACA,OACA,SAEJ1+B,MACI,OACA,OACA,SAEJ2+B,aACI,OACA,OACA,OACA,OACA,OACA,OACA,OACA,OACA,OACA,QACA,OACA,QACA,OACA,OACA,OACA,OACA,QACA,OACA,OACA,OACA,OACA,OACA,QACA,MACA,OACA,OACA,U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EAAW,4EAA8EvhF,EAAQzN,KAAK,oBAW9IP,OAAOuB,MAAM8P,OAAQrR,OAAO4vB,SACvB5vB,OAAOuB,OACE,kBAAVzB,SAAwBA,OAAOonC,IAAMpnC,OAAS,SAAUqnC,EAAIC,EAAIC,IACrEA,GAAMD,OAEV,SAAUvnC,EAAGC,QACVA,OAAO,gBACH,aACA,WACA,mBACA,iBACA,aACA,qBACA,eACA,kBACA,eACA,aACA,mBACA,oBACA,cACA,cACA,uBACA,sBACA,wBACA,oBACA,oBACA,yBACA,sBACA,yBACA,oBACA,2BACA,2BACA,sBACA,2BACA,2BACA,wBACA,sBACA,0BACA,sBACA,wBACA,iBACDD,IACL,WACE,YACA,OAAOG,QAAOuB,OACE,kBAAVzB,SAAwBA,OAAOonC,IAAMpnC,OAAS,SAAUqnC,EAAIC,EAAIC,IACrEA,GAAMD","file":"kendo.mobile.min.js","sourcesContent":["/*!\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n*/\n(function (f, define) {\n define('kendo.core', ['jquery'], f);\n}(function () {\n var __meta__ = {\n id: 'core',\n name: 'Core',\n category: 'framework',\n description: 'The core of the Kendo framework.'\n };\n (function ($, window, undefined) {\n var kendo = window.kendo = window.kendo || { cultures: {} }, extend = $.extend, each = $.each, isArray = $.isArray, proxy = $.proxy, noop = $.noop, math = Math, Template, JSON = window.JSON || {}, support = {}, percentRegExp = /%/, formatRegExp = /\\{(\\d+)(:[^\\}]+)?\\}/g, boxShadowRegExp = /(\\d+(?:\\.?)\\d*)px\\s*(\\d+(?:\\.?)\\d*)px\\s*(\\d+(?:\\.?)\\d*)px\\s*(\\d+)?/i, numberRegExp = /^(\\+|-?)\\d+(\\.?)\\d*$/, FUNCTION = 'function', STRING = 'string', NUMBER = 'number', OBJECT = 'object', NULL = 'null', BOOLEAN = 'boolean', UNDEFINED = 'undefined', getterCache = {}, setterCache = {}, slice = [].slice, noDepricateExtend = function () {\n var src, copyIsArray, copy, name, options, clone, target = arguments[0] || {}, i = 1, length = arguments.length, deep = false;\n if (typeof target === 'boolean') {\n deep = target;\n target = arguments[i] || {};\n i++;\n }\n if (typeof target !== 'object' && !jQuery.isFunction(target)) {\n target = {};\n }\n if (i === length) {\n target = this;\n i--;\n }\n for (; i < length; i++) {\n if ((options = arguments[i]) != null) {\n for (name in options) {\n if (name == 'filters' || name == 'concat' || name == ':') {\n continue;\n }\n src = target[name];\n copy = options[name];\n if (target === copy) {\n continue;\n }\n if (deep && copy && (jQuery.isPlainObject(copy) || (copyIsArray = jQuery.isArray(copy)))) {\n if (copyIsArray) {\n copyIsArray = false;\n clone = src && jQuery.isArray(src) ? src : [];\n } else {\n clone = src && jQuery.isPlainObject(src) ? src : {};\n }\n target[name] = noDepricateExtend(deep, clone, copy);\n } else if (copy !== undefined) {\n target[name] = copy;\n }\n }\n }\n }\n return target;\n };\n kendo.version = '2020.3.915'.replace(/^\\s+|\\s+$/g, '');\n function Class() {\n }\n Class.extend = function (proto) {\n var base = function () {\n }, member, that = this, subclass = proto && proto.init ? proto.init : function () {\n that.apply(this, arguments);\n }, fn;\n base.prototype = that.prototype;\n fn = subclass.fn = subclass.prototype = new base();\n for (member in proto) {\n if (proto[member] != null && proto[member].constructor === Object) {\n fn[member] = extend(true, {}, base.prototype[member], proto[member]);\n } else {\n fn[member] = proto[member];\n }\n }\n fn.constructor = subclass;\n subclass.extend = that.extend;\n return subclass;\n };\n Class.prototype._initOptions = function (options) {\n this.options = deepExtend({}, this.options, options);\n };\n var isFunction = kendo.isFunction = function (fn) {\n return typeof fn === 'function';\n };\n var preventDefault = function () {\n this._defaultPrevented = true;\n };\n var isDefaultPrevented = function () {\n return this._defaultPrevented === true;\n };\n var Observable = Class.extend({\n init: function () {\n this._events = {};\n },\n bind: function (eventName, handlers, one) {\n var that = this, idx, eventNames = typeof eventName === STRING ? [eventName] : eventName, length, original, handler, handlersIsFunction = typeof handlers === FUNCTION, events;\n if (handlers === undefined) {\n for (idx in eventName) {\n that.bind(idx, eventName[idx]);\n }\n return that;\n }\n for (idx = 0, length = eventNames.length; idx < length; idx++) {\n eventName = eventNames[idx];\n handler = handlersIsFunction ? handlers : handlers[eventName];\n if (handler) {\n if (one) {\n original = handler;\n handler = function () {\n that.unbind(eventName, handler);\n original.apply(that, arguments);\n };\n handler.original = original;\n }\n events = that._events[eventName] = that._events[eventName] || [];\n events.push(handler);\n }\n }\n return that;\n },\n one: function (eventNames, handlers) {\n return this.bind(eventNames, handlers, true);\n },\n first: function (eventName, handlers) {\n var that = this, idx, eventNames = typeof eventName === STRING ? [eventName] : eventName, length, handler, handlersIsFunction = typeof handlers === FUNCTION, events;\n for (idx = 0, length = eventNames.length; idx < length; idx++) {\n eventName = eventNames[idx];\n handler = handlersIsFunction ? handlers : handlers[eventName];\n if (handler) {\n events = that._events[eventName] = that._events[eventName] || [];\n events.unshift(handler);\n }\n }\n return that;\n },\n trigger: function (eventName, e) {\n var that = this, events = that._events[eventName], idx, length;\n if (events) {\n e = e || {};\n e.sender = that;\n e._defaultPrevented = false;\n e.preventDefault = preventDefault;\n e.isDefaultPrevented = isDefaultPrevented;\n events = events.slice();\n for (idx = 0, length = events.length; idx < length; idx++) {\n events[idx].call(that, e);\n }\n return e._defaultPrevented === true;\n }\n return false;\n },\n unbind: function (eventName, handler) {\n var that = this, events = that._events[eventName], idx;\n if (eventName === undefined) {\n that._events = {};\n } else if (events) {\n if (handler) {\n for (idx = events.length - 1; idx >= 0; idx--) {\n if (events[idx] === handler || events[idx].original === handler) {\n events.splice(idx, 1);\n }\n }\n } else {\n that._events[eventName] = [];\n }\n }\n return that;\n }\n });\n function compilePart(part, stringPart) {\n if (stringPart) {\n return '\\'' + part.split('\\'').join('\\\\\\'').split('\\\\\"').join('\\\\\\\\\\\\\"').replace(/\\n/g, '\\\\n').replace(/\\r/g, '\\\\r').replace(/\\t/g, '\\\\t') + '\\'';\n } else {\n var first = part.charAt(0), rest = part.substring(1);\n if (first === '=') {\n return '+(' + rest + ')+';\n } else if (first === ':') {\n return '+$kendoHtmlEncode(' + rest + ')+';\n } else {\n return ';' + part + ';$kendoOutput+=';\n }\n }\n }\n var argumentNameRegExp = /^\\w+/, encodeRegExp = /\\$\\{([^}]*)\\}/g, escapedCurlyRegExp = /\\\\\\}/g, curlyRegExp = /__CURLY__/g, escapedSharpRegExp = /\\\\#/g, sharpRegExp = /__SHARP__/g, zeros = [\n '',\n '0',\n '00',\n '000',\n '0000'\n ];\n Template = {\n paramName: 'data',\n useWithBlock: true,\n render: function (template, data) {\n var idx, length, html = '';\n for (idx = 0, length = data.length; idx < length; idx++) {\n html += template(data[idx]);\n }\n return html;\n },\n compile: function (template, options) {\n var settings = extend({}, this, options), paramName = settings.paramName, argumentName = paramName.match(argumentNameRegExp)[0], useWithBlock = settings.useWithBlock, functionBody = 'var $kendoOutput, $kendoHtmlEncode = kendo.htmlEncode;', fn, parts, idx;\n if (isFunction(template)) {\n return template;\n }\n functionBody += useWithBlock ? 'with(' + paramName + '){' : '';\n functionBody += '$kendoOutput=';\n parts = template.replace(escapedCurlyRegExp, '__CURLY__').replace(encodeRegExp, '#=$kendoHtmlEncode($1)#').replace(curlyRegExp, '}').replace(escapedSharpRegExp, '__SHARP__').split('#');\n for (idx = 0; idx < parts.length; idx++) {\n functionBody += compilePart(parts[idx], idx % 2 === 0);\n }\n functionBody += useWithBlock ? ';}' : ';';\n functionBody += 'return $kendoOutput;';\n functionBody = functionBody.replace(sharpRegExp, '#');\n try {\n fn = new Function(argumentName, functionBody);\n fn._slotCount = Math.floor(parts.length / 2);\n return fn;\n } catch (e) {\n throw new Error(kendo.format('Invalid template:\\'{0}\\' Generated code:\\'{1}\\'', template, functionBody));\n }\n }\n };\n function pad(number, digits, end) {\n number = number + '';\n digits = digits || 2;\n end = digits - number.length;\n if (end) {\n return zeros[digits].substring(0, end) + number;\n }\n return number;\n }\n (function () {\n var escapable = /[\\\\\\\"\\x00-\\x1f\\x7f-\\x9f\\u00ad\\u0600-\\u0604\\u070f\\u17b4\\u17b5\\u200c-\\u200f\\u2028-\\u202f\\u2060-\\u206f\\ufeff\\ufff0-\\uffff]/g, gap, indent, meta = {\n '\\b': '\\\\b',\n '\\t': '\\\\t',\n '\\n': '\\\\n',\n '\\f': '\\\\f',\n '\\r': '\\\\r',\n '\"': '\\\\\"',\n '\\\\': '\\\\\\\\'\n }, rep, toString = {}.toString;\n if (typeof Date.prototype.toJSON !== FUNCTION) {\n Date.prototype.toJSON = function () {\n var that = this;\n return isFinite(that.valueOf()) ? pad(that.getUTCFullYear(), 4) + '-' + pad(that.getUTCMonth() + 1) + '-' + pad(that.getUTCDate()) + 'T' + pad(that.getUTCHours()) + ':' + pad(that.getUTCMinutes()) + ':' + pad(that.getUTCSeconds()) + 'Z' : null;\n };\n String.prototype.toJSON = Number.prototype.toJSON = Boolean.prototype.toJSON = function () {\n return this.valueOf();\n };\n }\n function quote(string) {\n escapable.lastIndex = 0;\n return escapable.test(string) ? '\"' + string.replace(escapable, function (a) {\n var c = meta[a];\n return typeof c === STRING ? c : '\\\\u' + ('0000' + a.charCodeAt(0).toString(16)).slice(-4);\n }) + '\"' : '\"' + string + '\"';\n }\n function str(key, holder) {\n var i, k, v, length, mind = gap, partial, value = holder[key], type;\n if (value && typeof value === OBJECT && typeof value.toJSON === FUNCTION) {\n value = value.toJSON(key);\n }\n if (typeof rep === FUNCTION) {\n value = rep.call(holder, key, value);\n }\n type = typeof value;\n if (type === STRING) {\n return quote(value);\n } else if (type === NUMBER) {\n return isFinite(value) ? String(value) : NULL;\n } else if (type === BOOLEAN || type === NULL) {\n return String(value);\n } else if (type === OBJECT) {\n if (!value) {\n return NULL;\n }\n gap += indent;\n partial = [];\n if (toString.apply(value) === '[object Array]') {\n length = value.length;\n for (i = 0; i < length; i++) {\n partial[i] = str(i, value) || NULL;\n }\n v = partial.length === 0 ? '[]' : gap ? '[\\n' + gap + partial.join(',\\n' + gap) + '\\n' + mind + ']' : '[' + partial.join(',') + ']';\n gap = mind;\n return v;\n }\n if (rep && typeof rep === OBJECT) {\n length = rep.length;\n for (i = 0; i < length; i++) {\n if (typeof rep[i] === STRING) {\n k = rep[i];\n v = str(k, value);\n if (v) {\n partial.push(quote(k) + (gap ? ': ' : ':') + v);\n }\n }\n }\n } else {\n for (k in value) {\n if (Object.hasOwnProperty.call(value, k)) {\n v = str(k, value);\n if (v) {\n partial.push(quote(k) + (gap ? ': ' : ':') + v);\n }\n }\n }\n }\n v = partial.length === 0 ? '{}' : gap ? '{\\n' + gap + partial.join(',\\n' + gap) + '\\n' + mind + '}' : '{' + partial.join(',') + '}';\n gap = mind;\n return v;\n }\n }\n if (typeof JSON.stringify !== FUNCTION) {\n JSON.stringify = function (value, replacer, space) {\n var i;\n gap = '';\n indent = '';\n if (typeof space === NUMBER) {\n for (i = 0; i < space; i += 1) {\n indent += ' ';\n }\n } else if (typeof space === STRING) {\n indent = space;\n }\n rep = replacer;\n if (replacer && typeof replacer !== FUNCTION && (typeof replacer !== OBJECT || typeof replacer.length !== NUMBER)) {\n throw new Error('JSON.stringify');\n }\n return str('', { '': value });\n };\n }\n }());\n (function () {\n var dateFormatRegExp = /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, standardFormatRegExp = /^(n|c|p|e)(\\d*)$/i, literalRegExp = /(\\\\.)|(['][^']*[']?)|([\"][^\"]*[\"]?)/g, commaRegExp = /\\,/g, EMPTY = '', POINT = '.', COMMA = ',', SHARP = '#', ZERO = '0', PLACEHOLDER = '??', EN = 'en-US', objectToString = {}.toString;\n kendo.cultures['en-US'] = {\n name: EN,\n numberFormat: {\n pattern: ['-n'],\n decimals: 2,\n ',': ',',\n '.': '.',\n groupSize: [3],\n percent: {\n pattern: [\n '-n %',\n 'n %'\n ],\n decimals: 2,\n ',': ',',\n '.': '.',\n groupSize: [3],\n symbol: '%'\n },\n currency: {\n name: 'US Dollar',\n abbr: 'USD',\n pattern: [\n '($n)',\n '$n'\n ],\n decimals: 2,\n ',': ',',\n '.': '.',\n groupSize: [3],\n symbol: '$'\n }\n },\n calendars: {\n standard: {\n days: {\n names: [\n 'Sunday',\n 'Monday',\n 'Tuesday',\n 'Wednesday',\n 'Thursday',\n 'Friday',\n 'Saturday'\n ],\n namesAbbr: [\n 'Sun',\n 'Mon',\n 'Tue',\n 'Wed',\n 'Thu',\n 'Fri',\n 'Sat'\n ],\n namesShort: [\n 'Su',\n 'Mo',\n 'Tu',\n 'We',\n 'Th',\n 'Fr',\n 'Sa'\n ]\n },\n months: {\n names: [\n 'January',\n 'February',\n 'March',\n 'April',\n 'May',\n 'June',\n 'July',\n 'August',\n 'September',\n 'October',\n 'November',\n 'December'\n ],\n namesAbbr: [\n 'Jan',\n 'Feb',\n 'Mar',\n 'Apr',\n 'May',\n 'Jun',\n 'Jul',\n 'Aug',\n 'Sep',\n 'Oct',\n 'Nov',\n 'Dec'\n ]\n },\n AM: [\n 'AM',\n 'am',\n 'AM'\n ],\n PM: [\n 'PM',\n 'pm',\n 'PM'\n ],\n patterns: {\n d: 'M/d/yyyy',\n D: 'dddd, MMMM dd, yyyy',\n F: 'dddd, MMMM dd, yyyy h:mm:ss tt',\n g: 'M/d/yyyy h:mm tt',\n G: 'M/d/yyyy h:mm:ss tt',\n m: 'MMMM dd',\n M: 'MMMM dd',\n s: 'yyyy\\'-\\'MM\\'-\\'ddTHH\\':\\'mm\\':\\'ss',\n t: 'h:mm tt',\n T: 'h:mm:ss tt',\n u: 'yyyy\\'-\\'MM\\'-\\'dd HH\\':\\'mm\\':\\'ss\\'Z\\'',\n y: 'MMMM, yyyy',\n Y: 'MMMM, yyyy'\n },\n '/': '/',\n ':': ':',\n firstDay: 0,\n twoDigitYearMax: 2029\n }\n }\n };\n function findCulture(culture) {\n if (culture) {\n if (culture.numberFormat) {\n return culture;\n }\n if (typeof culture === STRING) {\n var cultures = kendo.cultures;\n return cultures[culture] || cultures[culture.split('-')[0]] || null;\n }\n return null;\n }\n return null;\n }\n function getCulture(culture) {\n if (culture) {\n culture = findCulture(culture);\n }\n return culture || kendo.cultures.current;\n }\n kendo.culture = function (cultureName) {\n var cultures = kendo.cultures, culture;\n if (cultureName !== undefined) {\n culture = findCulture(cultureName) || cultures[EN];\n culture.calendar = culture.calendars.standard;\n cultures.current = culture;\n } else {\n return cultures.current;\n }\n };\n kendo.findCulture = findCulture;\n kendo.getCulture = getCulture;\n kendo.culture(EN);\n function formatDate(date, format, culture) {\n culture = getCulture(culture);\n var calendar = culture.calendars.standard, days = calendar.days, months = calendar.months;\n format = calendar.patterns[format] || format;\n return format.replace(dateFormatRegExp, function (match) {\n var minutes;\n var result;\n var sign;\n if (match === 'd') {\n result = date.getDate();\n } else if (match === 'dd') {\n result = pad(date.getDate());\n } else if (match === 'ddd') {\n result = days.namesAbbr[date.getDay()];\n } else if (match === 'dddd') {\n result = days.names[date.getDay()];\n } else if (match === 'M') {\n result = date.getMonth() + 1;\n } else if (match === 'MM') {\n result = pad(date.getMonth() + 1);\n } else if (match === 'MMM') {\n result = months.namesAbbr[date.getMonth()];\n } else if (match === 'MMMM') {\n result = months.names[date.getMonth()];\n } else if (match === 'yy') {\n result = pad(date.getFullYear() % 100);\n } else if (match === 'yyyy') {\n result = pad(date.getFullYear(), 4);\n } else if (match === 'h') {\n result = date.getHours() % 12 || 12;\n } else if (match === 'hh') {\n result = pad(date.getHours() % 12 || 12);\n } else if (match === 'H') {\n result = date.getHours();\n } else if (match === 'HH') {\n result = pad(date.getHours());\n } else if (match === 'm') {\n result = date.getMinutes();\n } else if (match === 'mm') {\n result = pad(date.getMinutes());\n } else if (match === 's') {\n result = date.getSeconds();\n } else if (match === 'ss') {\n result = pad(date.getSeconds());\n } else if (match === 'f') {\n result = math.floor(date.getMilliseconds() / 100);\n } else if (match === 'ff') {\n result = date.getMilliseconds();\n if (result > 99) {\n result = math.floor(result / 10);\n }\n result = pad(result);\n } else if (match === 'fff') {\n result = pad(date.getMilliseconds(), 3);\n } else if (match === 'tt') {\n result = date.getHours() < 12 ? calendar.AM[0] : calendar.PM[0];\n } else if (match === 'zzz') {\n minutes = date.getTimezoneOffset();\n sign = minutes < 0;\n result = math.abs(minutes / 60).toString().split('.')[0];\n minutes = math.abs(minutes) - result * 60;\n result = (sign ? '+' : '-') + pad(result);\n result += ':' + pad(minutes);\n } else if (match === 'zz' || match === 'z') {\n result = date.getTimezoneOffset() / 60;\n sign = result < 0;\n result = math.abs(result).toString().split('.')[0];\n result = (sign ? '+' : '-') + (match === 'zz' ? pad(result) : result);\n }\n return result !== undefined ? result : match.slice(1, match.length - 1);\n });\n }\n function formatNumber(number, format, culture) {\n culture = getCulture(culture);\n var numberFormat = culture.numberFormat, decimal = numberFormat[POINT], precision = numberFormat.decimals, pattern = numberFormat.pattern[0], literals = [], symbol, isCurrency, isPercent, customPrecision, formatAndPrecision, negative = number < 0, integer, fraction, integerLength, fractionLength, replacement = EMPTY, value = EMPTY, idx, length, ch, hasGroup, hasNegativeFormat, decimalIndex, sharpIndex, zeroIndex, hasZero, hasSharp, percentIndex, currencyIndex, startZeroIndex, start = -1, end;\n if (number === undefined) {\n return EMPTY;\n }\n if (!isFinite(number)) {\n return number;\n }\n if (!format) {\n return culture.name.length ? number.toLocaleString() : number.toString();\n }\n formatAndPrecision = standardFormatRegExp.exec(format);\n if (formatAndPrecision) {\n format = formatAndPrecision[1].toLowerCase();\n isCurrency = format === 'c';\n isPercent = format === 'p';\n if (isCurrency || isPercent) {\n numberFormat = isCurrency ? numberFormat.currency : numberFormat.percent;\n decimal = numberFormat[POINT];\n precision = numberFormat.decimals;\n symbol = numberFormat.symbol;\n pattern = numberFormat.pattern[negative ? 0 : 1];\n }\n customPrecision = formatAndPrecision[2];\n if (customPrecision) {\n precision = +customPrecision;\n }\n if (format === 'e') {\n var exp = customPrecision ? number.toExponential(precision) : number.toExponential();\n return exp.replace(POINT, numberFormat[POINT]);\n }\n if (isPercent) {\n number *= 100;\n }\n number = round(number, precision);\n negative = number < 0;\n number = number.split(POINT);\n integer = number[0];\n fraction = number[1];\n if (negative) {\n integer = integer.substring(1);\n }\n value = groupInteger(integer, 0, integer.length, numberFormat);\n if (fraction) {\n value += decimal + fraction;\n }\n if (format === 'n' && !negative) {\n return value;\n }\n number = EMPTY;\n for (idx = 0, length = pattern.length; idx < length; idx++) {\n ch = pattern.charAt(idx);\n if (ch === 'n') {\n number += value;\n } else if (ch === '$' || ch === '%') {\n number += symbol;\n } else {\n number += ch;\n }\n }\n return number;\n }\n if (format.indexOf('\\'') > -1 || format.indexOf('\"') > -1 || format.indexOf('\\\\') > -1) {\n format = format.replace(literalRegExp, function (match) {\n var quoteChar = match.charAt(0).replace('\\\\', ''), literal = match.slice(1).replace(quoteChar, '');\n literals.push(literal);\n return PLACEHOLDER;\n });\n }\n format = format.split(';');\n if (negative && format[1]) {\n format = format[1];\n hasNegativeFormat = true;\n } else if (number === 0 && format[2]) {\n format = format[2];\n if (format.indexOf(SHARP) == -1 && format.indexOf(ZERO) == -1) {\n return format;\n }\n } else {\n format = format[0];\n }\n percentIndex = format.indexOf('%');\n currencyIndex = format.indexOf('$');\n isPercent = percentIndex != -1;\n isCurrency = currencyIndex != -1;\n if (isPercent) {\n number *= 100;\n }\n if (isCurrency && format[currencyIndex - 1] === '\\\\') {\n format = format.split('\\\\').join('');\n isCurrency = false;\n }\n if (isCurrency || isPercent) {\n numberFormat = isCurrency ? numberFormat.currency : numberFormat.percent;\n decimal = numberFormat[POINT];\n precision = numberFormat.decimals;\n symbol = numberFormat.symbol;\n }\n hasGroup = format.indexOf(COMMA) > -1;\n if (hasGroup) {\n format = format.replace(commaRegExp, EMPTY);\n }\n decimalIndex = format.indexOf(POINT);\n length = format.length;\n if (decimalIndex != -1) {\n fraction = number.toString().split('e');\n if (fraction[1]) {\n fraction = round(number, Math.abs(fraction[1]));\n } else {\n fraction = fraction[0];\n }\n fraction = fraction.split(POINT)[1] || EMPTY;\n zeroIndex = format.lastIndexOf(ZERO) - decimalIndex;\n sharpIndex = format.lastIndexOf(SHARP) - decimalIndex;\n hasZero = zeroIndex > -1;\n hasSharp = sharpIndex > -1;\n idx = fraction.length;\n if (!hasZero && !hasSharp) {\n format = format.substring(0, decimalIndex) + format.substring(decimalIndex + 1);\n length = format.length;\n decimalIndex = -1;\n idx = 0;\n }\n if (hasZero && zeroIndex > sharpIndex) {\n idx = zeroIndex;\n } else if (sharpIndex > zeroIndex) {\n if (hasSharp && idx > sharpIndex) {\n var rounded = round(number, sharpIndex, negative);\n while (rounded.charAt(rounded.length - 1) === ZERO && sharpIndex > 0 && sharpIndex > zeroIndex) {\n sharpIndex--;\n rounded = round(number, sharpIndex, negative);\n }\n idx = sharpIndex;\n } else if (hasZero && idx < zeroIndex) {\n idx = zeroIndex;\n }\n }\n }\n number = round(number, idx, negative);\n sharpIndex = format.indexOf(SHARP);\n startZeroIndex = zeroIndex = format.indexOf(ZERO);\n if (sharpIndex == -1 && zeroIndex != -1) {\n start = zeroIndex;\n } else if (sharpIndex != -1 && zeroIndex == -1) {\n start = sharpIndex;\n } else {\n start = sharpIndex > zeroIndex ? zeroIndex : sharpIndex;\n }\n sharpIndex = format.lastIndexOf(SHARP);\n zeroIndex = format.lastIndexOf(ZERO);\n if (sharpIndex == -1 && zeroIndex != -1) {\n end = zeroIndex;\n } else if (sharpIndex != -1 && zeroIndex == -1) {\n end = sharpIndex;\n } else {\n end = sharpIndex > zeroIndex ? sharpIndex : zeroIndex;\n }\n if (start == length) {\n end = start;\n }\n if (start != -1) {\n value = number.toString().split(POINT);\n integer = value[0];\n fraction = value[1] || EMPTY;\n integerLength = integer.length;\n fractionLength = fraction.length;\n if (negative && number * -1 >= 0) {\n negative = false;\n }\n number = format.substring(0, start);\n if (negative && !hasNegativeFormat) {\n number += '-';\n }\n for (idx = start; idx < length; idx++) {\n ch = format.charAt(idx);\n if (decimalIndex == -1) {\n if (end - idx < integerLength) {\n number += integer;\n break;\n }\n } else {\n if (zeroIndex != -1 && zeroIndex < idx) {\n replacement = EMPTY;\n }\n if (decimalIndex - idx <= integerLength && decimalIndex - idx > -1) {\n number += integer;\n idx = decimalIndex;\n }\n if (decimalIndex === idx) {\n number += (fraction ? decimal : EMPTY) + fraction;\n idx += end - decimalIndex + 1;\n continue;\n }\n }\n if (ch === ZERO) {\n number += ch;\n replacement = ch;\n } else if (ch === SHARP) {\n number += replacement;\n }\n }\n if (hasGroup) {\n number = groupInteger(number, start + (negative && !hasNegativeFormat ? 1 : 0), Math.max(end, integerLength + start), numberFormat);\n }\n if (end >= start) {\n number += format.substring(end + 1);\n }\n if (isCurrency || isPercent) {\n value = EMPTY;\n for (idx = 0, length = number.length; idx < length; idx++) {\n ch = number.charAt(idx);\n value += ch === '$' || ch === '%' ? symbol : ch;\n }\n number = value;\n }\n length = literals.length;\n if (length) {\n for (idx = 0; idx < length; idx++) {\n number = number.replace(PLACEHOLDER, literals[idx]);\n }\n }\n }\n return number;\n }\n var groupInteger = function (number, start, end, numberFormat) {\n var decimalIndex = number.indexOf(numberFormat[POINT]);\n var groupSizes = numberFormat.groupSize.slice();\n var groupSize = groupSizes.shift();\n var integer, integerLength;\n var idx, parts, value;\n var newGroupSize;\n end = decimalIndex !== -1 ? decimalIndex : end + 1;\n integer = number.substring(start, end);\n integerLength = integer.length;\n if (integerLength >= groupSize) {\n idx = integerLength;\n parts = [];\n while (idx > -1) {\n value = integer.substring(idx - groupSize, idx);\n if (value) {\n parts.push(value);\n }\n idx -= groupSize;\n newGroupSize = groupSizes.shift();\n groupSize = newGroupSize !== undefined ? newGroupSize : groupSize;\n if (groupSize === 0) {\n if (idx > 0) {\n parts.push(integer.substring(0, idx));\n }\n break;\n }\n }\n integer = parts.reverse().join(numberFormat[COMMA]);\n number = number.substring(0, start) + integer + number.substring(end);\n }\n return number;\n };\n var round = function (value, precision, negative) {\n precision = precision || 0;\n value = value.toString().split('e');\n value = Math.round(+(value[0] + 'e' + (value[1] ? +value[1] + precision : precision)));\n if (negative) {\n value = -value;\n }\n value = value.toString().split('e');\n value = +(value[0] + 'e' + (value[1] ? +value[1] - precision : -precision));\n return value.toFixed(Math.min(precision, 20));\n };\n var toString = function (value, fmt, culture) {\n if (fmt) {\n if (objectToString.call(value) === '[object Date]') {\n return formatDate(value, fmt, culture);\n } else if (typeof value === NUMBER) {\n return formatNumber(value, fmt, culture);\n }\n }\n return value !== undefined ? value : '';\n };\n kendo.format = function (fmt) {\n var values = arguments;\n return fmt.replace(formatRegExp, function (match, index, placeholderFormat) {\n var value = values[parseInt(index, 10) + 1];\n return toString(value, placeholderFormat ? placeholderFormat.substring(1) : '');\n });\n };\n kendo._extractFormat = function (format) {\n if (format.slice(0, 3) === '{0:') {\n format = format.slice(3, format.length - 1);\n }\n return format;\n };\n kendo._activeElement = function () {\n try {\n return document.activeElement;\n } catch (e) {\n return document.documentElement.activeElement;\n }\n };\n kendo._round = round;\n kendo._outerWidth = function (element, includeMargin) {\n return $(element).outerWidth(includeMargin || false) || 0;\n };\n kendo._outerHeight = function (element, includeMargin) {\n return $(element).outerHeight(includeMargin || false) || 0;\n };\n kendo.toString = toString;\n }());\n (function () {\n var nonBreakingSpaceRegExp = /\\u00A0/g, exponentRegExp = /[eE][\\-+]?[0-9]+/, shortTimeZoneRegExp = /[+|\\-]\\d{1,2}/, longTimeZoneRegExp = /[+|\\-]\\d{1,2}:?\\d{2}/, dateRegExp = /^\\/Date\\((.*?)\\)\\/$/, offsetRegExp = /[+-]\\d*/, FORMATS_SEQUENCE = [\n [],\n [\n 'G',\n 'g',\n 'F'\n ],\n [\n 'D',\n 'd',\n 'y',\n 'm',\n 'T',\n 't'\n ]\n ], STANDARD_FORMATS = [\n [\n 'yyyy-MM-ddTHH:mm:ss.fffffffzzz',\n 'yyyy-MM-ddTHH:mm:ss.fffffff',\n 'yyyy-MM-ddTHH:mm:ss.fffzzz',\n 'yyyy-MM-ddTHH:mm:ss.fff',\n 'ddd MMM dd yyyy HH:mm:ss',\n 'yyyy-MM-ddTHH:mm:sszzz',\n 'yyyy-MM-ddTHH:mmzzz',\n 'yyyy-MM-ddTHH:mmzz',\n 'yyyy-MM-ddTHH:mm:ss',\n 'yyyy-MM-dd HH:mm:ss',\n 'yyyy/MM/dd HH:mm:ss'\n ],\n [\n 'yyyy-MM-ddTHH:mm',\n 'yyyy-MM-dd HH:mm',\n 'yyyy/MM/dd HH:mm'\n ],\n [\n 'yyyy/MM/dd',\n 'yyyy-MM-dd',\n 'HH:mm:ss',\n 'HH:mm'\n ]\n ], numberRegExp = {\n 2: /^\\d{1,2}/,\n 3: /^\\d{1,3}/,\n 4: /^\\d{4}/\n }, objectToString = {}.toString;\n function outOfRange(value, start, end) {\n return !(value >= start && value <= end);\n }\n function designatorPredicate(designator) {\n return designator.charAt(0);\n }\n function mapDesignators(designators) {\n return $.map(designators, designatorPredicate);\n }\n function adjustDST(date, hours) {\n if (!hours && date.getHours() === 23) {\n date.setHours(date.getHours() + 2);\n }\n }\n function lowerArray(data) {\n var idx = 0, length = data.length, array = [];\n for (; idx < length; idx++) {\n array[idx] = (data[idx] + '').toLowerCase();\n }\n return array;\n }\n function lowerLocalInfo(localInfo) {\n var newLocalInfo = {}, property;\n for (property in localInfo) {\n newLocalInfo[property] = lowerArray(localInfo[property]);\n }\n return newLocalInfo;\n }\n function parseExact(value, format, culture, strict) {\n if (!value) {\n return null;\n }\n var lookAhead = function (match) {\n var i = 0;\n while (format[idx] === match) {\n i++;\n idx++;\n }\n if (i > 0) {\n idx -= 1;\n }\n return i;\n }, getNumber = function (size) {\n var rg = numberRegExp[size] || new RegExp('^\\\\d{1,' + size + '}'), match = value.substr(valueIdx, size).match(rg);\n if (match) {\n match = match[0];\n valueIdx += match.length;\n return parseInt(match, 10);\n }\n return null;\n }, getIndexByName = function (names, lower) {\n var i = 0, length = names.length, name, nameLength, matchLength = 0, matchIdx = 0, subValue;\n for (; i < length; i++) {\n name = names[i];\n nameLength = name.length;\n subValue = value.substr(valueIdx, nameLength);\n if (lower) {\n subValue = subValue.toLowerCase();\n }\n if (subValue == name && nameLength > matchLength) {\n matchLength = nameLength;\n matchIdx = i;\n }\n }\n if (matchLength) {\n valueIdx += matchLength;\n return matchIdx + 1;\n }\n return null;\n }, checkLiteral = function () {\n var result = false;\n if (value.charAt(valueIdx) === format[idx]) {\n valueIdx++;\n result = true;\n }\n return result;\n }, calendar = culture.calendars.standard, year = null, month = null, day = null, hours = null, minutes = null, seconds = null, milliseconds = null, idx = 0, valueIdx = 0, literal = false, date = new Date(), twoDigitYearMax = calendar.twoDigitYearMax || 2029, defaultYear = date.getFullYear(), ch, count, length, pattern, pmHour, UTC, matches, amDesignators, pmDesignators, hoursOffset, minutesOffset, hasTime, match;\n if (!format) {\n format = 'd';\n }\n pattern = calendar.patterns[format];\n if (pattern) {\n format = pattern;\n }\n format = format.split('');\n length = format.length;\n for (; idx < length; idx++) {\n ch = format[idx];\n if (literal) {\n if (ch === '\\'') {\n literal = false;\n } else {\n checkLiteral();\n }\n } else {\n if (ch === 'd') {\n count = lookAhead('d');\n if (!calendar._lowerDays) {\n calendar._lowerDays = lowerLocalInfo(calendar.days);\n }\n if (day !== null && count > 2) {\n continue;\n }\n day = count < 3 ? getNumber(2) : getIndexByName(calendar._lowerDays[count == 3 ? 'namesAbbr' : 'names'], true);\n if (day === null || outOfRange(day, 1, 31)) {\n return null;\n }\n } else if (ch === 'M') {\n count = lookAhead('M');\n if (!calendar._lowerMonths) {\n calendar._lowerMonths = lowerLocalInfo(calendar.months);\n }\n month = count < 3 ? getNumber(2) : getIndexByName(calendar._lowerMonths[count == 3 ? 'namesAbbr' : 'names'], true);\n if (month === null || outOfRange(month, 1, 12)) {\n return null;\n }\n month -= 1;\n } else if (ch === 'y') {\n count = lookAhead('y');\n year = getNumber(count);\n if (year === null) {\n return null;\n }\n if (count == 2) {\n if (typeof twoDigitYearMax === 'string') {\n twoDigitYearMax = defaultYear + parseInt(twoDigitYearMax, 10);\n }\n year = defaultYear - defaultYear % 100 + year;\n if (year > twoDigitYearMax) {\n year -= 100;\n }\n }\n } else if (ch === 'h') {\n lookAhead('h');\n hours = getNumber(2);\n if (hours == 12) {\n hours = 0;\n }\n if (hours === null || outOfRange(hours, 0, 11)) {\n return null;\n }\n } else if (ch === 'H') {\n lookAhead('H');\n hours = getNumber(2);\n if (hours === null || outOfRange(hours, 0, 23)) {\n return null;\n }\n } else if (ch === 'm') {\n lookAhead('m');\n minutes = getNumber(2);\n if (minutes === null || outOfRange(minutes, 0, 59)) {\n return null;\n }\n } else if (ch === 's') {\n lookAhead('s');\n seconds = getNumber(2);\n if (seconds === null || outOfRange(seconds, 0, 59)) {\n return null;\n }\n } else if (ch === 'f') {\n count = lookAhead('f');\n match = value.substr(valueIdx, count).match(numberRegExp[3]);\n milliseconds = getNumber(count);\n if (milliseconds !== null) {\n milliseconds = parseFloat('0.' + match[0], 10);\n milliseconds = kendo._round(milliseconds, 3);\n milliseconds *= 1000;\n }\n if (milliseconds === null || outOfRange(milliseconds, 0, 999)) {\n return null;\n }\n } else if (ch === 't') {\n count = lookAhead('t');\n amDesignators = calendar.AM;\n pmDesignators = calendar.PM;\n if (count === 1) {\n amDesignators = mapDesignators(amDesignators);\n pmDesignators = mapDesignators(pmDesignators);\n }\n pmHour = getIndexByName(pmDesignators);\n if (!pmHour && !getIndexByName(amDesignators)) {\n return null;\n }\n } else if (ch === 'z') {\n UTC = true;\n count = lookAhead('z');\n if (value.substr(valueIdx, 1) === 'Z') {\n checkLiteral();\n continue;\n }\n matches = value.substr(valueIdx, 6).match(count > 2 ? longTimeZoneRegExp : shortTimeZoneRegExp);\n if (!matches) {\n return null;\n }\n matches = matches[0].split(':');\n hoursOffset = matches[0];\n minutesOffset = matches[1];\n if (!minutesOffset && hoursOffset.length > 3) {\n valueIdx = hoursOffset.length - 2;\n minutesOffset = hoursOffset.substring(valueIdx);\n hoursOffset = hoursOffset.substring(0, valueIdx);\n }\n hoursOffset = parseInt(hoursOffset, 10);\n if (outOfRange(hoursOffset, -12, 13)) {\n return null;\n }\n if (count > 2) {\n minutesOffset = matches[0][0] + minutesOffset;\n minutesOffset = parseInt(minutesOffset, 10);\n if (isNaN(minutesOffset) || outOfRange(minutesOffset, -59, 59)) {\n return null;\n }\n }\n } else if (ch === '\\'') {\n literal = true;\n checkLiteral();\n } else if (!checkLiteral()) {\n return null;\n }\n }\n }\n if (strict && !/^\\s*$/.test(value.substr(valueIdx))) {\n return null;\n }\n hasTime = hours !== null || minutes !== null || seconds || null;\n if (year === null && month === null && day === null && hasTime) {\n year = defaultYear;\n month = date.getMonth();\n day = date.getDate();\n } else {\n if (year === null) {\n year = defaultYear;\n }\n if (day === null) {\n day = 1;\n }\n }\n if (pmHour && hours < 12) {\n hours += 12;\n }\n if (UTC) {\n if (hoursOffset) {\n hours += -hoursOffset;\n }\n if (minutesOffset) {\n minutes += -minutesOffset;\n }\n value = new Date(Date.UTC(year, month, day, hours, minutes, seconds, milliseconds));\n } else {\n value = new Date(year, month, day, hours, minutes, seconds, milliseconds);\n adjustDST(value, hours);\n }\n if (year < 100) {\n value.setFullYear(year);\n }\n if (value.getDate() !== day && UTC === undefined) {\n return null;\n }\n return value;\n }\n function parseMicrosoftFormatOffset(offset) {\n var sign = offset.substr(0, 1) === '-' ? -1 : 1;\n offset = offset.substring(1);\n offset = parseInt(offset.substr(0, 2), 10) * 60 + parseInt(offset.substring(2), 10);\n return sign * offset;\n }\n function getDefaultFormats(culture) {\n var length = math.max(FORMATS_SEQUENCE.length, STANDARD_FORMATS.length);\n var calendar = culture.calendar || culture.calendars.standard;\n var patterns = calendar.patterns;\n var cultureFormats, formatIdx, idx;\n var formats = [];\n for (idx = 0; idx < length; idx++) {\n cultureFormats = FORMATS_SEQUENCE[idx];\n for (formatIdx = 0; formatIdx < cultureFormats.length; formatIdx++) {\n formats.push(patterns[cultureFormats[formatIdx]]);\n }\n formats = formats.concat(STANDARD_FORMATS[idx]);\n }\n return formats;\n }\n function internalParseDate(value, formats, culture, strict) {\n if (objectToString.call(value) === '[object Date]') {\n return value;\n }\n var idx = 0;\n var date = null;\n var length;\n var tzoffset;\n if (value && value.indexOf('/D') === 0) {\n date = dateRegExp.exec(value);\n if (date) {\n date = date[1];\n tzoffset = offsetRegExp.exec(date.substring(1));\n date = new Date(parseInt(date, 10));\n if (tzoffset) {\n tzoffset = parseMicrosoftFormatOffset(tzoffset[0]);\n date = kendo.timezone.apply(date, 0);\n date = kendo.timezone.convert(date, 0, -1 * tzoffset);\n }\n return date;\n }\n }\n culture = kendo.getCulture(culture);\n if (!formats) {\n formats = getDefaultFormats(culture);\n }\n formats = isArray(formats) ? formats : [formats];\n length = formats.length;\n for (; idx < length; idx++) {\n date = parseExact(value, formats[idx], culture, strict);\n if (date) {\n return date;\n }\n }\n return date;\n }\n kendo.parseDate = function (value, formats, culture) {\n return internalParseDate(value, formats, culture, false);\n };\n kendo.parseExactDate = function (value, formats, culture) {\n return internalParseDate(value, formats, culture, true);\n };\n kendo.parseInt = function (value, culture) {\n var result = kendo.parseFloat(value, culture);\n if (result) {\n result = result | 0;\n }\n return result;\n };\n kendo.parseFloat = function (value, culture, format) {\n if (!value && value !== 0) {\n return null;\n }\n if (typeof value === NUMBER) {\n return value;\n }\n value = value.toString();\n culture = kendo.getCulture(culture);\n var number = culture.numberFormat, percent = number.percent, currency = number.currency, symbol = currency.symbol, percentSymbol = percent.symbol, negative = value.indexOf('-'), parts, isPercent;\n if (exponentRegExp.test(value)) {\n value = parseFloat(value.replace(number['.'], '.'));\n if (isNaN(value)) {\n value = null;\n }\n return value;\n }\n if (negative > 0) {\n return null;\n } else {\n negative = negative > -1;\n }\n if (value.indexOf(symbol) > -1 || format && format.toLowerCase().indexOf('c') > -1) {\n number = currency;\n parts = number.pattern[0].replace('$', symbol).split('n');\n if (value.indexOf(parts[0]) > -1 && value.indexOf(parts[1]) > -1) {\n value = value.replace(parts[0], '').replace(parts[1], '');\n negative = true;\n }\n } else if (value.indexOf(percentSymbol) > -1) {\n isPercent = true;\n number = percent;\n symbol = percentSymbol;\n }\n value = value.replace('-', '').replace(symbol, '').replace(nonBreakingSpaceRegExp, ' ').split(number[','].replace(nonBreakingSpaceRegExp, ' ')).join('').replace(number['.'], '.');\n value = parseFloat(value);\n if (isNaN(value)) {\n value = null;\n } else if (negative) {\n value *= -1;\n }\n if (value && isPercent) {\n value /= 100;\n }\n return value;\n };\n }());\n function getShadows(element) {\n var shadow = element.css(kendo.support.transitions.css + 'box-shadow') || element.css('box-shadow'), radius = shadow ? shadow.match(boxShadowRegExp) || [\n 0,\n 0,\n 0,\n 0,\n 0\n ] : [\n 0,\n 0,\n 0,\n 0,\n 0\n ], blur = math.max(+radius[3], +(radius[4] || 0));\n return {\n left: -radius[1] + blur,\n right: +radius[1] + blur,\n bottom: +radius[2] + blur\n };\n }\n function wrap(element, autosize) {\n var browser = support.browser, percentage, outerWidth = kendo._outerWidth, outerHeight = kendo._outerHeight, parent = element.parent(), windowOuterWidth = outerWidth(window);\n parent.removeClass('k-animation-container-sm');\n if (!parent.hasClass('k-animation-container')) {\n var width = element[0].style.width, height = element[0].style.height, percentWidth = percentRegExp.test(width), percentHeight = percentRegExp.test(height), forceWidth = element.hasClass('k-tooltip') || element.is('.k-menu-horizontal.k-context-menu');\n percentage = percentWidth || percentHeight;\n if (!percentWidth && (!autosize || autosize && width || forceWidth)) {\n width = autosize ? outerWidth(element) + 1 : outerWidth(element);\n }\n if (!percentHeight && (!autosize || autosize && height) || element.is('.k-menu-horizontal.k-context-menu')) {\n height = outerHeight(element);\n }\n element.wrap($('
').addClass('k-animation-container').css({\n width: width,\n height: height\n }));\n parent = element.parent();\n if (percentage) {\n element.css({\n width: '100%',\n height: '100%',\n boxSizing: 'border-box',\n mozBoxSizing: 'border-box',\n webkitBoxSizing: 'border-box'\n });\n }\n } else {\n wrapResize(element, autosize);\n }\n if (windowOuterWidth < outerWidth(parent)) {\n parent.addClass('k-animation-container-sm');\n wrapResize(element, autosize);\n }\n if (browser.msie && math.floor(browser.version) <= 7) {\n element.css({ zoom: 1 });\n element.children('.k-menu').width(element.width());\n }\n return parent;\n }\n function wrapResize(element, autosize) {\n var percentage, outerWidth = kendo._outerWidth, outerHeight = kendo._outerHeight, wrapper = element.parent('.k-animation-container'), wrapperStyle = wrapper[0].style;\n if (wrapper.is(':hidden')) {\n wrapper.css({\n display: '',\n position: ''\n });\n }\n percentage = percentRegExp.test(wrapperStyle.width) || percentRegExp.test(wrapperStyle.height);\n if (!percentage) {\n wrapper.css({\n width: autosize ? outerWidth(element) + 1 : outerWidth(element),\n height: outerHeight(element),\n boxSizing: 'content-box',\n mozBoxSizing: 'content-box',\n webkitBoxSizing: 'content-box'\n });\n }\n }\n function deepExtend(destination) {\n var i = 1, length = arguments.length;\n for (i = 1; i < length; i++) {\n deepExtendOne(destination, arguments[i]);\n }\n return destination;\n }\n function deepExtendOne(destination, source) {\n var ObservableArray = kendo.data.ObservableArray, LazyObservableArray = kendo.data.LazyObservableArray, DataSource = kendo.data.DataSource, HierarchicalDataSource = kendo.data.HierarchicalDataSource, property, propValue, propType, propInit, destProp;\n for (property in source) {\n propValue = source[property];\n propType = typeof propValue;\n if (propType === OBJECT && propValue !== null) {\n propInit = propValue.constructor;\n } else {\n propInit = null;\n }\n if (propInit && propInit !== Array && propInit !== ObservableArray && propInit !== LazyObservableArray && propInit !== DataSource && propInit !== HierarchicalDataSource && propInit !== RegExp && (!kendo.isFunction(window.ArrayBuffer) || propInit !== ArrayBuffer)) {\n if (propValue instanceof Date) {\n destination[property] = new Date(propValue.getTime());\n } else if (isFunction(propValue.clone)) {\n destination[property] = propValue.clone();\n } else {\n destProp = destination[property];\n if (typeof destProp === OBJECT) {\n destination[property] = destProp || {};\n } else {\n destination[property] = {};\n }\n deepExtendOne(destination[property], propValue);\n }\n } else if (propType !== UNDEFINED) {\n destination[property] = propValue;\n }\n }\n return destination;\n }\n function testRx(agent, rxs, dflt) {\n for (var rx in rxs) {\n if (rxs.hasOwnProperty(rx) && rxs[rx].test(agent)) {\n return rx;\n }\n }\n return dflt !== undefined ? dflt : agent;\n }\n function toHyphens(str) {\n return str.replace(/([a-z][A-Z])/g, function (g) {\n return g.charAt(0) + '-' + g.charAt(1).toLowerCase();\n });\n }\n function toCamelCase(str) {\n return str.replace(/\\-(\\w)/g, function (strMatch, g1) {\n return g1.toUpperCase();\n });\n }\n function getComputedStyles(element, properties) {\n var styles = {}, computedStyle;\n if (document.defaultView && document.defaultView.getComputedStyle) {\n computedStyle = document.defaultView.getComputedStyle(element, '');\n if (properties) {\n $.each(properties, function (idx, value) {\n styles[value] = computedStyle.getPropertyValue(value);\n });\n }\n } else {\n computedStyle = element.currentStyle;\n if (properties) {\n $.each(properties, function (idx, value) {\n styles[value] = computedStyle[toCamelCase(value)];\n });\n }\n }\n if (!kendo.size(styles)) {\n styles = computedStyle;\n }\n return styles;\n }\n function isScrollable(element) {\n if (element && element.className && typeof element.className === 'string' && element.className.indexOf('k-auto-scrollable') > -1) {\n return true;\n }\n var overflow = getComputedStyles(element, ['overflow']).overflow;\n return overflow == 'auto' || overflow == 'scroll';\n }\n function scrollLeft(element, value) {\n var webkit = support.browser.webkit;\n var mozila = support.browser.mozilla;\n var el = element instanceof $ ? element[0] : element;\n var isRtl;\n if (!element) {\n return;\n }\n isRtl = support.isRtl(element);\n if (value !== undefined) {\n if (isRtl && webkit) {\n el.scrollLeft = el.scrollWidth - el.clientWidth - value;\n } else if (isRtl && mozila) {\n el.scrollLeft = -value;\n } else {\n el.scrollLeft = value;\n }\n } else {\n if (isRtl && webkit) {\n return el.scrollWidth - el.clientWidth - el.scrollLeft;\n } else {\n return Math.abs(el.scrollLeft);\n }\n }\n }\n (function () {\n support._scrollbar = undefined;\n support.scrollbar = function (refresh) {\n if (!isNaN(support._scrollbar) && !refresh) {\n return support._scrollbar;\n } else {\n var div = document.createElement('div'), result;\n div.style.cssText = 'overflow:scroll;overflow-x:hidden;zoom:1;clear:both;display:block';\n div.innerHTML = ' ';\n document.body.appendChild(div);\n support._scrollbar = result = div.offsetWidth - div.scrollWidth;\n document.body.removeChild(div);\n return result;\n }\n };\n support.isRtl = function (element) {\n return $(element).closest('.k-rtl').length > 0;\n };\n var table = document.createElement('table');\n try {\n table.innerHTML = '';\n support.tbodyInnerHtml = true;\n } catch (e) {\n support.tbodyInnerHtml = false;\n }\n support.touch = 'ontouchstart' in window;\n var docStyle = document.documentElement.style;\n var transitions = support.transitions = false, transforms = support.transforms = false, elementProto = 'HTMLElement' in window ? HTMLElement.prototype : [];\n support.hasHW3D = 'WebKitCSSMatrix' in window && 'm11' in new window.WebKitCSSMatrix() || 'MozPerspective' in docStyle || 'msPerspective' in docStyle;\n support.cssFlexbox = 'flexWrap' in docStyle || 'WebkitFlexWrap' in docStyle || 'msFlexWrap' in docStyle;\n each([\n 'Moz',\n 'webkit',\n 'O',\n 'ms'\n ], function () {\n var prefix = this.toString(), hasTransitions = typeof table.style[prefix + 'Transition'] === STRING;\n if (hasTransitions || typeof table.style[prefix + 'Transform'] === STRING) {\n var lowPrefix = prefix.toLowerCase();\n transforms = {\n css: lowPrefix != 'ms' ? '-' + lowPrefix + '-' : '',\n prefix: prefix,\n event: lowPrefix === 'o' || lowPrefix === 'webkit' ? lowPrefix : ''\n };\n if (hasTransitions) {\n transitions = transforms;\n transitions.event = transitions.event ? transitions.event + 'TransitionEnd' : 'transitionend';\n }\n return false;\n }\n });\n table = null;\n support.transforms = transforms;\n support.transitions = transitions;\n support.devicePixelRatio = window.devicePixelRatio === undefined ? 1 : window.devicePixelRatio;\n try {\n support.screenWidth = window.outerWidth || window.screen ? window.screen.availWidth : window.innerWidth;\n support.screenHeight = window.outerHeight || window.screen ? window.screen.availHeight : window.innerHeight;\n } catch (e) {\n support.screenWidth = window.screen.availWidth;\n support.screenHeight = window.screen.availHeight;\n }\n support.detectOS = function (ua) {\n var os = false, minorVersion, match = [], notAndroidPhone = !/mobile safari/i.test(ua), agentRxs = {\n wp: /(Windows Phone(?: OS)?)\\s(\\d+)\\.(\\d+(\\.\\d+)?)/,\n fire: /(Silk)\\/(\\d+)\\.(\\d+(\\.\\d+)?)/,\n android: /(Android|Android.*(?:Opera|Firefox).*?\\/)\\s*(\\d+)\\.?(\\d+(\\.\\d+)?)?/,\n iphone: /(iPhone|iPod).*OS\\s+(\\d+)[\\._]([\\d\\._]+)/,\n ipad: /(iPad).*OS\\s+(\\d+)[\\._]([\\d_]+)/,\n meego: /(MeeGo).+NokiaBrowser\\/(\\d+)\\.([\\d\\._]+)/,\n webos: /(webOS)\\/(\\d+)\\.(\\d+(\\.\\d+)?)/,\n blackberry: /(BlackBerry|BB10).*?Version\\/(\\d+)\\.(\\d+(\\.\\d+)?)/,\n playbook: /(PlayBook).*?Tablet\\s*OS\\s*(\\d+)\\.(\\d+(\\.\\d+)?)/,\n windows: /(MSIE)\\s+(\\d+)\\.(\\d+(\\.\\d+)?)/,\n tizen: /(tizen).*?Version\\/(\\d+)\\.(\\d+(\\.\\d+)?)/i,\n sailfish: /(sailfish).*rv:(\\d+)\\.(\\d+(\\.\\d+)?).*firefox/i,\n ffos: /(Mobile).*rv:(\\d+)\\.(\\d+(\\.\\d+)?).*Firefox/\n }, osRxs = {\n ios: /^i(phone|pad|pod)$/i,\n android: /^android|fire$/i,\n blackberry: /^blackberry|playbook/i,\n windows: /windows/,\n wp: /wp/,\n flat: /sailfish|ffos|tizen/i,\n meego: /meego/\n }, formFactorRxs = { tablet: /playbook|ipad|fire/i }, browserRxs = {\n omini: /Opera\\sMini/i,\n omobile: /Opera\\sMobi/i,\n firefox: /Firefox|Fennec/i,\n mobilesafari: /version\\/.*safari/i,\n ie: /MSIE|Windows\\sPhone/i,\n chrome: /chrome|crios/i,\n webkit: /webkit/i\n };\n for (var agent in agentRxs) {\n if (agentRxs.hasOwnProperty(agent)) {\n match = ua.match(agentRxs[agent]);\n if (match) {\n if (agent == 'windows' && 'plugins' in navigator) {\n return false;\n }\n os = {};\n os.device = agent;\n os.tablet = testRx(agent, formFactorRxs, false);\n os.browser = testRx(ua, browserRxs, 'default');\n os.name = testRx(agent, osRxs);\n os[os.name] = true;\n os.majorVersion = match[2];\n os.minorVersion = (match[3] || '0').replace('_', '.');\n minorVersion = os.minorVersion.replace('.', '').substr(0, 2);\n os.flatVersion = os.majorVersion + minorVersion + new Array(3 - (minorVersion.length < 3 ? minorVersion.length : 2)).join('0');\n os.cordova = typeof window.PhoneGap !== UNDEFINED || typeof window.cordova !== UNDEFINED;\n os.appMode = window.navigator.standalone || /file|local|wmapp/.test(window.location.protocol) || os.cordova;\n if (os.android && (support.devicePixelRatio < 1.5 && os.flatVersion < 400 || notAndroidPhone) && (support.screenWidth > 800 || support.screenHeight > 800)) {\n os.tablet = agent;\n }\n break;\n }\n }\n }\n return os;\n };\n var mobileOS = support.mobileOS = support.detectOS(navigator.userAgent);\n support.wpDevicePixelRatio = mobileOS.wp ? screen.width / 320 : 0;\n support.hasNativeScrolling = false;\n if (mobileOS.ios || mobileOS.android && mobileOS.majorVersion > 2 || mobileOS.wp) {\n support.hasNativeScrolling = mobileOS;\n }\n support.delayedClick = function () {\n if (support.touch) {\n if (mobileOS.ios) {\n return true;\n }\n if (mobileOS.android) {\n if (!support.browser.chrome) {\n return true;\n }\n if (support.browser.version < 32) {\n return false;\n }\n return !($('meta[name=viewport]').attr('content') || '').match(/user-scalable=no/i);\n }\n }\n return false;\n };\n support.mouseAndTouchPresent = support.touch && !(support.mobileOS.ios || support.mobileOS.android);\n support.detectBrowser = function (ua) {\n var browser = false, match = [], browserRxs = {\n edge: /(edge)[ \\/]([\\w.]+)/i,\n webkit: /(chrome|crios)[ \\/]([\\w.]+)/i,\n safari: /(webkit)[ \\/]([\\w.]+)/i,\n opera: /(opera)(?:.*version|)[ \\/]([\\w.]+)/i,\n msie: /(msie\\s|trident.*? rv:)([\\w.]+)/i,\n mozilla: /(mozilla)(?:.*? rv:([\\w.]+)|)/i\n };\n for (var agent in browserRxs) {\n if (browserRxs.hasOwnProperty(agent)) {\n match = ua.match(browserRxs[agent]);\n if (match) {\n browser = {};\n browser[agent] = true;\n browser[match[1].toLowerCase().split(' ')[0].split('/')[0]] = true;\n browser.version = parseInt(document.documentMode || match[2], 10);\n break;\n }\n }\n }\n return browser;\n };\n support.browser = support.detectBrowser(navigator.userAgent);\n support.detectClipboardAccess = function () {\n var commands = {\n copy: document.queryCommandSupported ? document.queryCommandSupported('copy') : false,\n cut: document.queryCommandSupported ? document.queryCommandSupported('cut') : false,\n paste: document.queryCommandSupported ? document.queryCommandSupported('paste') : false\n };\n if (support.browser.chrome) {\n commands.paste = false;\n if (support.browser.version >= 43) {\n commands.copy = true;\n commands.cut = true;\n }\n }\n return commands;\n };\n support.clipboard = support.detectClipboardAccess();\n support.zoomLevel = function () {\n try {\n var browser = support.browser;\n var ie11WidthCorrection = 0;\n var docEl = document.documentElement;\n if (browser.msie && browser.version == 11 && docEl.scrollHeight > docEl.clientHeight && !support.touch) {\n ie11WidthCorrection = support.scrollbar();\n }\n return support.touch ? docEl.clientWidth / window.innerWidth : browser.msie && browser.version >= 10 ? ((top || window).document.documentElement.offsetWidth + ie11WidthCorrection) / (top || window).innerWidth : 1;\n } catch (e) {\n return 1;\n }\n };\n support.cssBorderSpacing = typeof docStyle.borderSpacing != 'undefined' && !(support.browser.msie && support.browser.version < 8);\n (function (browser) {\n var cssClass = '', docElement = $(document.documentElement), majorVersion = parseInt(browser.version, 10);\n if (browser.msie) {\n cssClass = 'ie';\n } else if (browser.mozilla) {\n cssClass = 'ff';\n } else if (browser.safari) {\n cssClass = 'safari';\n } else if (browser.webkit) {\n cssClass = 'webkit';\n } else if (browser.opera) {\n cssClass = 'opera';\n } else if (browser.edge) {\n cssClass = 'edge';\n }\n if (cssClass) {\n cssClass = 'k-' + cssClass + ' k-' + cssClass + majorVersion;\n }\n if (support.mobileOS) {\n cssClass += ' k-mobile';\n }\n if (!support.cssFlexbox) {\n cssClass += ' k-no-flexbox';\n }\n docElement.addClass(cssClass);\n }(support.browser));\n support.eventCapture = document.documentElement.addEventListener;\n var input = document.createElement('input');\n support.placeholder = 'placeholder' in input;\n support.propertyChangeEvent = 'onpropertychange' in input;\n support.input = function () {\n var types = [\n 'number',\n 'date',\n 'time',\n 'month',\n 'week',\n 'datetime',\n 'datetime-local'\n ];\n var length = types.length;\n var value = 'test';\n var result = {};\n var idx = 0;\n var type;\n for (; idx < length; idx++) {\n type = types[idx];\n input.setAttribute('type', type);\n input.value = value;\n result[type.replace('-', '')] = input.type !== 'text' && input.value !== value;\n }\n return result;\n }();\n input.style.cssText = 'float:left;';\n support.cssFloat = !!input.style.cssFloat;\n input = null;\n support.stableSort = function () {\n var threshold = 513;\n var sorted = [{\n index: 0,\n field: 'b'\n }];\n for (var i = 1; i < threshold; i++) {\n sorted.push({\n index: i,\n field: 'a'\n });\n }\n sorted.sort(function (a, b) {\n return a.field > b.field ? 1 : a.field < b.field ? -1 : 0;\n });\n return sorted[0].index === 1;\n }();\n support.matchesSelector = elementProto.webkitMatchesSelector || elementProto.mozMatchesSelector || elementProto.msMatchesSelector || elementProto.oMatchesSelector || elementProto.matchesSelector || elementProto.matches || function (selector) {\n var nodeList = document.querySelectorAll ? (this.parentNode || document).querySelectorAll(selector) || [] : $(selector), i = nodeList.length;\n while (i--) {\n if (nodeList[i] == this) {\n return true;\n }\n }\n return false;\n };\n support.matchMedia = 'matchMedia' in window;\n support.pushState = window.history && window.history.pushState;\n var documentMode = document.documentMode;\n support.hashChange = 'onhashchange' in window && !(support.browser.msie && (!documentMode || documentMode <= 8));\n support.customElements = 'registerElement' in window.document;\n var chrome = support.browser.chrome, mobileChrome = support.browser.crios, mozilla = support.browser.mozilla, safari = support.browser.safari;\n support.msPointers = !chrome && window.MSPointerEvent;\n support.pointers = !chrome && !mobileChrome && !mozilla && !safari && window.PointerEvent;\n support.kineticScrollNeeded = mobileOS && (support.touch || support.msPointers || support.pointers);\n }());\n function size(obj) {\n var result = 0, key;\n for (key in obj) {\n if (obj.hasOwnProperty(key) && key != 'toJSON') {\n result++;\n }\n }\n return result;\n }\n function getOffset(element, type, positioned) {\n if (!type) {\n type = 'offset';\n }\n var offset = element[type]();\n var result = {\n top: offset.top,\n right: offset.right,\n bottom: offset.bottom,\n left: offset.left\n };\n if (support.browser.msie && (support.pointers || support.msPointers) && !positioned) {\n var sign = support.isRtl(element) ? 1 : -1;\n result.top -= window.pageYOffset - document.documentElement.scrollTop;\n result.left -= window.pageXOffset + sign * document.documentElement.scrollLeft;\n }\n return result;\n }\n var directions = {\n left: { reverse: 'right' },\n right: { reverse: 'left' },\n down: { reverse: 'up' },\n up: { reverse: 'down' },\n top: { reverse: 'bottom' },\n bottom: { reverse: 'top' },\n 'in': { reverse: 'out' },\n out: { reverse: 'in' }\n };\n function parseEffects(input) {\n var effects = {};\n each(typeof input === 'string' ? input.split(' ') : input, function (idx) {\n effects[idx] = this;\n });\n return effects;\n }\n function fx(element) {\n return new kendo.effects.Element(element);\n }\n var effects = {};\n $.extend(effects, {\n enabled: true,\n Element: function (element) {\n this.element = $(element);\n },\n promise: function (element, options) {\n if (!element.is(':visible')) {\n element.css({ display: element.data('olddisplay') || 'block' }).css('display');\n }\n if (options.hide) {\n element.data('olddisplay', element.css('display')).hide();\n }\n if (options.init) {\n options.init();\n }\n if (options.completeCallback) {\n options.completeCallback(element);\n }\n element.dequeue();\n },\n disable: function () {\n this.enabled = false;\n this.promise = this.promiseShim;\n },\n enable: function () {\n this.enabled = true;\n this.promise = this.animatedPromise;\n }\n });\n effects.promiseShim = effects.promise;\n function prepareAnimationOptions(options, duration, reverse, complete) {\n if (typeof options === STRING) {\n if (isFunction(duration)) {\n complete = duration;\n duration = 400;\n reverse = false;\n }\n if (isFunction(reverse)) {\n complete = reverse;\n reverse = false;\n }\n if (typeof duration === BOOLEAN) {\n reverse = duration;\n duration = 400;\n }\n options = {\n effects: options,\n duration: duration,\n reverse: reverse,\n complete: complete\n };\n }\n return extend({\n effects: {},\n duration: 400,\n reverse: false,\n init: noop,\n teardown: noop,\n hide: false\n }, options, {\n completeCallback: options.complete,\n complete: noop\n });\n }\n function animate(element, options, duration, reverse, complete) {\n var idx = 0, length = element.length, instance;\n for (; idx < length; idx++) {\n instance = $(element[idx]);\n instance.queue(function () {\n effects.promise(instance, prepareAnimationOptions(options, duration, reverse, complete));\n });\n }\n return element;\n }\n function toggleClass(element, classes, options, add) {\n if (classes) {\n classes = classes.split(' ');\n each(classes, function (idx, value) {\n element.toggleClass(value, add);\n });\n }\n return element;\n }\n if (!('kendoAnimate' in $.fn)) {\n extend($.fn, {\n kendoStop: function (clearQueue, gotoEnd) {\n return this.stop(clearQueue, gotoEnd);\n },\n kendoAnimate: function (options, duration, reverse, complete) {\n return animate(this, options, duration, reverse, complete);\n },\n kendoAddClass: function (classes, options) {\n return kendo.toggleClass(this, classes, options, true);\n },\n kendoRemoveClass: function (classes, options) {\n return kendo.toggleClass(this, classes, options, false);\n },\n kendoToggleClass: function (classes, options, toggle) {\n return kendo.toggleClass(this, classes, options, toggle);\n }\n });\n }\n var ampRegExp = /&/g, ltRegExp = //g;\n function htmlEncode(value) {\n return ('' + value).replace(ampRegExp, '&').replace(ltRegExp, '<').replace(gtRegExp, '>').replace(quoteRegExp, '"').replace(aposRegExp, ''');\n }\n function unescape(value) {\n var template;\n try {\n template = window.decodeURIComponent(value);\n } catch (error) {\n template = value.replace(/%u([\\dA-F]{4})|%([\\dA-F]{2})/gi, function (_, m1, m2) {\n return String.fromCharCode(parseInt('0x' + (m1 || m2), 16));\n });\n }\n return template;\n }\n var eventTarget = function (e) {\n return e.target;\n };\n if (support.touch) {\n eventTarget = function (e) {\n var touches = 'originalEvent' in e ? e.originalEvent.changedTouches : 'changedTouches' in e ? e.changedTouches : null;\n return touches ? document.elementFromPoint(touches[0].clientX, touches[0].clientY) : e.target;\n };\n each([\n 'swipe',\n 'swipeLeft',\n 'swipeRight',\n 'swipeUp',\n 'swipeDown',\n 'doubleTap',\n 'tap'\n ], function (m, value) {\n $.fn[value] = function (callback) {\n return this.bind(value, callback);\n };\n });\n }\n if (support.touch) {\n if (!support.mobileOS) {\n support.mousedown = 'mousedown touchstart';\n support.mouseup = 'mouseup touchend';\n support.mousemove = 'mousemove touchmove';\n support.mousecancel = 'mouseleave touchcancel';\n support.click = 'click';\n support.resize = 'resize';\n } else {\n support.mousedown = 'touchstart';\n support.mouseup = 'touchend';\n support.mousemove = 'touchmove';\n support.mousecancel = 'touchcancel';\n support.click = 'touchend';\n support.resize = 'orientationchange';\n }\n } else if (support.pointers) {\n support.mousemove = 'pointermove';\n support.mousedown = 'pointerdown';\n support.mouseup = 'pointerup';\n support.mousecancel = 'pointercancel';\n support.click = 'pointerup';\n support.resize = 'orientationchange resize';\n } else if (support.msPointers) {\n support.mousemove = 'MSPointerMove';\n support.mousedown = 'MSPointerDown';\n support.mouseup = 'MSPointerUp';\n support.mousecancel = 'MSPointerCancel';\n support.click = 'MSPointerUp';\n support.resize = 'orientationchange resize';\n } else {\n support.mousemove = 'mousemove';\n support.mousedown = 'mousedown';\n support.mouseup = 'mouseup';\n support.mousecancel = 'mouseleave';\n support.click = 'click';\n support.resize = 'resize';\n }\n var wrapExpression = function (members, paramName) {\n var result = paramName || 'd', index, idx, length, member, count = 1;\n for (idx = 0, length = members.length; idx < length; idx++) {\n member = members[idx];\n if (member !== '') {\n index = member.indexOf('[');\n if (index !== 0) {\n if (index == -1) {\n member = '.' + member;\n } else {\n count++;\n member = '.' + member.substring(0, index) + ' || {})' + member.substring(index);\n }\n }\n count++;\n result += member + (idx < length - 1 ? ' || {})' : ')');\n }\n }\n return new Array(count).join('(') + result;\n }, localUrlRe = /^([a-z]+:)?\\/\\//i;\n extend(kendo, {\n widgets: [],\n _widgetRegisteredCallbacks: [],\n ui: kendo.ui || {},\n fx: kendo.fx || fx,\n effects: kendo.effects || effects,\n mobile: kendo.mobile || {},\n data: kendo.data || {},\n dataviz: kendo.dataviz || {},\n drawing: kendo.drawing || {},\n spreadsheet: { messages: {} },\n keys: {\n INSERT: 45,\n DELETE: 46,\n BACKSPACE: 8,\n TAB: 9,\n ENTER: 13,\n ESC: 27,\n LEFT: 37,\n UP: 38,\n RIGHT: 39,\n DOWN: 40,\n END: 35,\n HOME: 36,\n SPACEBAR: 32,\n PAGEUP: 33,\n PAGEDOWN: 34,\n F2: 113,\n F10: 121,\n F12: 123,\n NUMPAD_PLUS: 107,\n NUMPAD_MINUS: 109,\n NUMPAD_DOT: 110\n },\n support: kendo.support || support,\n animate: kendo.animate || animate,\n ns: '',\n attr: function (value) {\n return 'data-' + kendo.ns + value;\n },\n getShadows: getShadows,\n wrap: wrap,\n deepExtend: deepExtend,\n getComputedStyles: getComputedStyles,\n isScrollable: isScrollable,\n scrollLeft: scrollLeft,\n size: size,\n toCamelCase: toCamelCase,\n toHyphens: toHyphens,\n getOffset: kendo.getOffset || getOffset,\n parseEffects: kendo.parseEffects || parseEffects,\n toggleClass: kendo.toggleClass || toggleClass,\n directions: kendo.directions || directions,\n Observable: Observable,\n Class: Class,\n Template: Template,\n template: proxy(Template.compile, Template),\n render: proxy(Template.render, Template),\n stringify: proxy(JSON.stringify, JSON),\n eventTarget: eventTarget,\n htmlEncode: htmlEncode,\n unescape: unescape,\n isLocalUrl: function (url) {\n return url && !localUrlRe.test(url);\n },\n expr: function (expression, safe, paramName) {\n expression = expression || '';\n if (typeof safe == STRING) {\n paramName = safe;\n safe = false;\n }\n paramName = paramName || 'd';\n if (expression && expression.charAt(0) !== '[') {\n expression = '.' + expression;\n }\n if (safe) {\n expression = expression.replace(/\"([^.]*)\\.([^\"]*)\"/g, '\"$1_$DOT$_$2\"');\n expression = expression.replace(/'([^.]*)\\.([^']*)'/g, '\\'$1_$DOT$_$2\\'');\n expression = wrapExpression(expression.split('.'), paramName);\n expression = expression.replace(/_\\$DOT\\$_/g, '.');\n } else {\n expression = paramName + expression;\n }\n return expression;\n },\n getter: function (expression, safe) {\n var key = expression + safe;\n return getterCache[key] = getterCache[key] || new Function('d', 'return ' + kendo.expr(expression, safe));\n },\n setter: function (expression) {\n return setterCache[expression] = setterCache[expression] || new Function('d,value', kendo.expr(expression) + '=value');\n },\n accessor: function (expression) {\n return {\n get: kendo.getter(expression),\n set: kendo.setter(expression)\n };\n },\n guid: function () {\n var id = '', i, random;\n for (i = 0; i < 32; i++) {\n random = math.random() * 16 | 0;\n if (i == 8 || i == 12 || i == 16 || i == 20) {\n id += '-';\n }\n id += (i == 12 ? 4 : i == 16 ? random & 3 | 8 : random).toString(16);\n }\n return id;\n },\n roleSelector: function (role) {\n return role.replace(/(\\S+)/g, '[' + kendo.attr('role') + '=$1],').slice(0, -1);\n },\n directiveSelector: function (directives) {\n var selectors = directives.split(' ');\n if (selectors) {\n for (var i = 0; i < selectors.length; i++) {\n if (selectors[i] != 'view') {\n selectors[i] = selectors[i].replace(/(\\w*)(view|bar|strip|over)$/, '$1-$2');\n }\n }\n }\n return selectors.join(' ').replace(/(\\S+)/g, 'kendo-mobile-$1,').slice(0, -1);\n },\n triggeredByInput: function (e) {\n return /^(label|input|textarea|select)$/i.test(e.target.tagName);\n },\n onWidgetRegistered: function (callback) {\n for (var i = 0, len = kendo.widgets.length; i < len; i++) {\n callback(kendo.widgets[i]);\n }\n kendo._widgetRegisteredCallbacks.push(callback);\n },\n logToConsole: function (message, type) {\n var console = window.console;\n if (!kendo.suppressLog && typeof console != 'undefined' && console.log) {\n console[type || 'log'](message);\n }\n }\n });\n var Widget = Observable.extend({\n init: function (element, options) {\n var that = this;\n that.element = kendo.jQuery(element).handler(that);\n that.angular('init', options);\n Observable.fn.init.call(that);\n var dataSource = options ? options.dataSource : null;\n var props;\n if (options) {\n props = (that.componentTypes || {})[(options || {}).componentType];\n }\n if (dataSource) {\n options = extend({}, options, { dataSource: {} });\n }\n options = that.options = extend(true, {}, that.options, that.defaults, props || {}, options);\n if (dataSource) {\n options.dataSource = dataSource;\n }\n if (!that.element.attr(kendo.attr('role'))) {\n that.element.attr(kendo.attr('role'), (options.name || '').toLowerCase());\n }\n that.element.data('kendo' + options.prefix + options.name, that);\n that.bind(that.events, options);\n },\n events: [],\n options: { prefix: '' },\n _hasBindingTarget: function () {\n return !!this.element[0].kendoBindingTarget;\n },\n _tabindex: function (target) {\n target = target || this.wrapper;\n var element = this.element, TABINDEX = 'tabindex', tabindex = target.attr(TABINDEX) || element.attr(TABINDEX);\n element.removeAttr(TABINDEX);\n target.attr(TABINDEX, !isNaN(tabindex) ? tabindex : 0);\n },\n setOptions: function (options) {\n this._setEvents(options);\n $.extend(this.options, options);\n },\n _setEvents: function (options) {\n var that = this, idx = 0, length = that.events.length, e;\n for (; idx < length; idx++) {\n e = that.events[idx];\n if (that.options[e] && options[e]) {\n that.unbind(e, that.options[e]);\n if (that._events && that._events[e]) {\n delete that._events[e];\n }\n }\n }\n that.bind(that.events, options);\n },\n resize: function (force) {\n var size = this.getSize(), currentSize = this._size;\n if (force || (size.width > 0 || size.height > 0) && (!currentSize || size.width !== currentSize.width || size.height !== currentSize.height)) {\n this._size = size;\n this._resize(size, force);\n this.trigger('resize', size);\n }\n },\n getSize: function () {\n return kendo.dimensions(this.element);\n },\n size: function (size) {\n if (!size) {\n return this.getSize();\n } else {\n this.setSize(size);\n }\n },\n setSize: $.noop,\n _resize: $.noop,\n destroy: function () {\n var that = this;\n that.element.removeData('kendo' + that.options.prefix + that.options.name);\n that.element.removeData('handler');\n that.unbind();\n },\n _destroy: function () {\n this.destroy();\n },\n angular: function () {\n },\n _muteAngularRebind: function (callback) {\n this._muteRebind = true;\n callback.call(this);\n this._muteRebind = false;\n }\n });\n var DataBoundWidget = Widget.extend({\n dataItems: function () {\n return this.dataSource.flatView();\n },\n _angularItems: function (cmd) {\n var that = this;\n that.angular(cmd, function () {\n return {\n elements: that.items(),\n data: $.map(that.dataItems(), function (dataItem) {\n return { dataItem: dataItem };\n })\n };\n });\n }\n });\n kendo.dimensions = function (element, dimensions) {\n var domElement = element[0];\n if (dimensions) {\n element.css(dimensions);\n }\n return {\n width: domElement.offsetWidth,\n height: domElement.offsetHeight\n };\n };\n kendo.notify = noop;\n var templateRegExp = /template$/i, jsonRegExp = /^\\s*(?:\\{(?:.|\\r\\n|\\n)*\\}|\\[(?:.|\\r\\n|\\n)*\\])\\s*$/, jsonFormatRegExp = /^\\{(\\d+)(:[^\\}]+)?\\}|^\\[[A-Za-z_]+\\]$/, dashRegExp = /([A-Z])/g;\n function parseOption(element, option) {\n var value;\n if (option.indexOf('data') === 0) {\n option = option.substring(4);\n option = option.charAt(0).toLowerCase() + option.substring(1);\n }\n option = option.replace(dashRegExp, '-$1');\n value = element.getAttribute('data-' + kendo.ns + option);\n if (value === null) {\n value = undefined;\n } else if (value === 'null') {\n value = null;\n } else if (value === 'true') {\n value = true;\n } else if (value === 'false') {\n value = false;\n } else if (numberRegExp.test(value) && option != 'mask') {\n value = parseFloat(value);\n } else if (jsonRegExp.test(value) && !jsonFormatRegExp.test(value)) {\n value = new Function('return (' + value + ')')();\n }\n return value;\n }\n function parseOptions(element, options, source) {\n var result = {}, option, value, role = element.getAttribute('data-' + kendo.ns + 'role');\n for (option in options) {\n value = parseOption(element, option);\n if (value !== undefined) {\n if (templateRegExp.test(option) && role != 'drawer') {\n if (typeof value === 'string') {\n if ($('#' + value).length) {\n value = kendo.template($('#' + value).html());\n } else if (source) {\n value = kendo.template(source[value]);\n }\n } else {\n value = element.getAttribute(option);\n }\n }\n result[option] = value;\n }\n }\n return result;\n }\n kendo.initWidget = function (element, options, roles) {\n var result, option, widget, idx, length, role, value, dataSource, fullPath, widgetKeyRegExp;\n if (!roles) {\n roles = kendo.ui.roles;\n } else if (roles.roles) {\n roles = roles.roles;\n }\n element = element.nodeType ? element : element[0];\n role = element.getAttribute('data-' + kendo.ns + 'role');\n if (!role) {\n return;\n }\n fullPath = role.indexOf('.') === -1;\n if (fullPath) {\n widget = roles[role];\n } else {\n widget = kendo.getter(role)(window);\n }\n var data = $(element).data(), widgetKey = widget ? 'kendo' + widget.fn.options.prefix + widget.fn.options.name : '';\n if (fullPath) {\n widgetKeyRegExp = new RegExp('^kendo.*' + role + '$', 'i');\n } else {\n widgetKeyRegExp = new RegExp('^' + widgetKey + '$', 'i');\n }\n for (var key in data) {\n if (key.match(widgetKeyRegExp)) {\n if (key === widgetKey) {\n result = data[key];\n } else {\n return data[key];\n }\n }\n }\n if (!widget) {\n return;\n }\n dataSource = parseOption(element, 'dataSource');\n options = $.extend({}, parseOptions(element, $.extend({}, widget.fn.options, widget.fn.defaults)), options);\n if (dataSource) {\n if (typeof dataSource === STRING) {\n options.dataSource = kendo.getter(dataSource)(window);\n } else {\n options.dataSource = dataSource;\n }\n }\n for (idx = 0, length = widget.fn.events.length; idx < length; idx++) {\n option = widget.fn.events[idx];\n value = parseOption(element, option);\n if (value !== undefined) {\n options[option] = kendo.getter(value)(window);\n }\n }\n if (!result) {\n result = new widget(element, options);\n } else if (!$.isEmptyObject(options)) {\n result.setOptions(options);\n }\n return result;\n };\n kendo.rolesFromNamespaces = function (namespaces) {\n var roles = [], idx, length;\n if (!namespaces[0]) {\n namespaces = [\n kendo.ui,\n kendo.dataviz.ui\n ];\n }\n for (idx = 0, length = namespaces.length; idx < length; idx++) {\n roles[idx] = namespaces[idx].roles;\n }\n return extend.apply(null, [{}].concat(roles.reverse()));\n };\n kendo.init = function (element) {\n var roles = kendo.rolesFromNamespaces(slice.call(arguments, 1));\n $(element).find('[data-' + kendo.ns + 'role]').addBack().each(function () {\n kendo.initWidget(this, {}, roles);\n });\n };\n kendo.destroy = function (element) {\n $(element).find('[data-' + kendo.ns + 'role]').addBack().each(function () {\n var data = $(this).data();\n for (var key in data) {\n if (key.indexOf('kendo') === 0 && typeof data[key].destroy === FUNCTION) {\n data[key].destroy();\n }\n }\n });\n };\n function containmentComparer(a, b) {\n return $.contains(a, b) ? -1 : 1;\n }\n function resizableWidget() {\n var widget = $(this);\n return $.inArray(widget.attr('data-' + kendo.ns + 'role'), [\n 'slider',\n 'rangeslider',\n 'breadcrumb'\n ]) > -1 || widget.is(':visible');\n }\n kendo.resize = function (element, force) {\n var widgets = $(element).find('[data-' + kendo.ns + 'role]').addBack().filter(resizableWidget);\n if (!widgets.length) {\n return;\n }\n var widgetsArray = $.makeArray(widgets);\n widgetsArray.sort(containmentComparer);\n $.each(widgetsArray, function () {\n var widget = kendo.widgetInstance($(this));\n if (widget) {\n widget.resize(force);\n }\n });\n };\n kendo.parseOptions = parseOptions;\n extend(kendo.ui, {\n Widget: Widget,\n DataBoundWidget: DataBoundWidget,\n roles: {},\n progress: function (container, toggle, options) {\n var mask = container.find('.k-loading-mask'), support = kendo.support, browser = support.browser, isRtl, leftRight, webkitCorrection, containerScrollLeft, cssClass;\n options = $.extend({}, {\n width: '100%',\n height: '100%',\n top: container.scrollTop(),\n opacity: false\n }, options);\n cssClass = options.opacity ? 'k-loading-mask k-opaque' : 'k-loading-mask';\n if (toggle) {\n if (!mask.length) {\n isRtl = support.isRtl(container);\n leftRight = isRtl ? 'right' : 'left';\n containerScrollLeft = container.scrollLeft();\n webkitCorrection = browser.webkit ? !isRtl ? 0 : container[0].scrollWidth - container.width() - 2 * containerScrollLeft : 0;\n mask = $(kendo.format('
{1}
', cssClass, kendo.ui.progress.messages.loading)).width(options.width).height(options.height).css('top', options.top).css(leftRight, Math.abs(containerScrollLeft) + webkitCorrection).prependTo(container);\n }\n } else if (mask) {\n mask.remove();\n }\n },\n plugin: function (widget, register, prefix) {\n var name = widget.fn.options.name, getter;\n register = register || kendo.ui;\n prefix = prefix || '';\n register[name] = widget;\n register.roles[name.toLowerCase()] = widget;\n getter = 'getKendo' + prefix + name;\n name = 'kendo' + prefix + name;\n var widgetEntry = {\n name: name,\n widget: widget,\n prefix: prefix || ''\n };\n kendo.widgets.push(widgetEntry);\n for (var i = 0, len = kendo._widgetRegisteredCallbacks.length; i < len; i++) {\n kendo._widgetRegisteredCallbacks[i](widgetEntry);\n }\n $.fn[name] = function (options) {\n var value = this, args;\n if (typeof options === STRING) {\n args = slice.call(arguments, 1);\n this.each(function () {\n var widget = $.data(this, name), method, result;\n if (!widget) {\n throw new Error(kendo.format('Cannot call method \\'{0}\\' of {1} before it is initialized', options, name));\n }\n method = widget[options];\n if (typeof method !== FUNCTION) {\n throw new Error(kendo.format('Cannot find method \\'{0}\\' of {1}', options, name));\n }\n result = method.apply(widget, args);\n if (result !== undefined) {\n value = result;\n return false;\n }\n });\n } else {\n this.each(function () {\n return new widget(this, options);\n });\n }\n return value;\n };\n $.fn[name].widget = widget;\n $.fn[getter] = function () {\n return this.data(name);\n };\n }\n });\n kendo.ui.progress.messages = { loading: 'Loading...' };\n var ContainerNullObject = {\n bind: function () {\n return this;\n },\n nullObject: true,\n options: {}\n };\n var MobileWidget = Widget.extend({\n init: function (element, options) {\n Widget.fn.init.call(this, element, options);\n this.element.autoApplyNS();\n this.wrapper = this.element;\n this.element.addClass('km-widget');\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n this.element.kendoDestroy();\n },\n options: { prefix: 'Mobile' },\n events: [],\n view: function () {\n var viewElement = this.element.closest(kendo.roleSelector('view splitview modalview drawer'));\n return kendo.widgetInstance(viewElement, kendo.mobile.ui) || ContainerNullObject;\n },\n viewHasNativeScrolling: function () {\n var view = this.view();\n return view && view.options.useNativeScrolling;\n },\n container: function () {\n var element = this.element.closest(kendo.roleSelector('view layout modalview drawer splitview'));\n return kendo.widgetInstance(element.eq(0), kendo.mobile.ui) || ContainerNullObject;\n }\n });\n extend(kendo.mobile, {\n init: function (element) {\n kendo.init(element, kendo.mobile.ui, kendo.ui, kendo.dataviz.ui);\n },\n appLevelNativeScrolling: function () {\n return kendo.mobile.application && kendo.mobile.application.options && kendo.mobile.application.options.useNativeScrolling;\n },\n roles: {},\n ui: {\n Widget: MobileWidget,\n DataBoundWidget: DataBoundWidget.extend(MobileWidget.prototype),\n roles: {},\n plugin: function (widget) {\n kendo.ui.plugin(widget, kendo.mobile.ui, 'Mobile');\n }\n }\n });\n deepExtend(kendo.dataviz, {\n init: function (element) {\n kendo.init(element, kendo.dataviz.ui);\n },\n ui: {\n roles: {},\n themes: {},\n views: [],\n plugin: function (widget) {\n kendo.ui.plugin(widget, kendo.dataviz.ui);\n }\n },\n roles: {}\n });\n kendo.touchScroller = function (elements, options) {\n if (!options) {\n options = {};\n }\n options.useNative = true;\n return $(elements).map(function (idx, element) {\n element = $(element);\n if (support.kineticScrollNeeded && kendo.mobile.ui.Scroller && !element.data('kendoMobileScroller')) {\n element.kendoMobileScroller(options);\n return element.data('kendoMobileScroller');\n } else {\n return false;\n }\n })[0];\n };\n kendo.preventDefault = function (e) {\n e.preventDefault();\n };\n kendo.widgetInstance = function (element, suites) {\n var role = element.data(kendo.ns + 'role'), widgets = [], i, length, elementData = element.data('kendoView');\n if (role) {\n if (role === 'content') {\n role = 'scroller';\n }\n if (role === 'editortoolbar') {\n var editorToolbar = element.data('kendoEditorToolbar');\n if (editorToolbar) {\n return editorToolbar;\n }\n }\n if (role === 'view' && elementData) {\n return elementData;\n }\n if (suites) {\n if (suites[0]) {\n for (i = 0, length = suites.length; i < length; i++) {\n widgets.push(suites[i].roles[role]);\n }\n } else {\n widgets.push(suites.roles[role]);\n }\n } else {\n widgets = [\n kendo.ui.roles[role],\n kendo.dataviz.ui.roles[role],\n kendo.mobile.ui.roles[role]\n ];\n }\n if (role.indexOf('.') >= 0) {\n widgets = [kendo.getter(role)(window)];\n }\n for (i = 0, length = widgets.length; i < length; i++) {\n var widget = widgets[i];\n if (widget) {\n var instance = element.data('kendo' + widget.fn.options.prefix + widget.fn.options.name);\n if (instance) {\n return instance;\n }\n }\n }\n }\n };\n kendo.onResize = function (callback) {\n var handler = callback;\n if (support.mobileOS.android) {\n handler = function () {\n setTimeout(callback, 600);\n };\n }\n $(window).on(support.resize, handler);\n return handler;\n };\n kendo.unbindResize = function (callback) {\n $(window).off(support.resize, callback);\n };\n kendo.attrValue = function (element, key) {\n return element.data(kendo.ns + key);\n };\n kendo.days = {\n Sunday: 0,\n Monday: 1,\n Tuesday: 2,\n Wednesday: 3,\n Thursday: 4,\n Friday: 5,\n Saturday: 6\n };\n function focusable(element, isTabIndexNotNaN) {\n var nodeName = element.nodeName.toLowerCase();\n return (/input|select|textarea|button|object/.test(nodeName) ? !element.disabled : 'a' === nodeName ? element.href || isTabIndexNotNaN : isTabIndexNotNaN) && visible(element);\n }\n function visible(element) {\n return $.expr.pseudos.visible(element) && !$(element).parents().addBack().filter(function () {\n return $.css(this, 'visibility') === 'hidden';\n }).length;\n }\n $.extend($.expr.pseudos, {\n kendoFocusable: function (element) {\n var idx = $.attr(element, 'tabindex');\n return focusable(element, !isNaN(idx) && idx > -1);\n }\n });\n var MOUSE_EVENTS = [\n 'mousedown',\n 'mousemove',\n 'mouseenter',\n 'mouseleave',\n 'mouseover',\n 'mouseout',\n 'mouseup',\n 'click'\n ];\n var EXCLUDE_BUST_CLICK_SELECTOR = 'label, input, [data-rel=external]';\n var MouseEventNormalizer = {\n setupMouseMute: function () {\n var idx = 0, length = MOUSE_EVENTS.length, element = document.documentElement;\n if (MouseEventNormalizer.mouseTrap || !support.eventCapture) {\n return;\n }\n MouseEventNormalizer.mouseTrap = true;\n MouseEventNormalizer.bustClick = false;\n MouseEventNormalizer.captureMouse = false;\n var handler = function (e) {\n if (MouseEventNormalizer.captureMouse) {\n if (e.type === 'click') {\n if (MouseEventNormalizer.bustClick && !$(e.target).is(EXCLUDE_BUST_CLICK_SELECTOR)) {\n e.preventDefault();\n e.stopPropagation();\n }\n } else {\n e.stopPropagation();\n }\n }\n };\n for (; idx < length; idx++) {\n element.addEventListener(MOUSE_EVENTS[idx], handler, true);\n }\n },\n muteMouse: function (e) {\n MouseEventNormalizer.captureMouse = true;\n if (e.data.bustClick) {\n MouseEventNormalizer.bustClick = true;\n }\n clearTimeout(MouseEventNormalizer.mouseTrapTimeoutID);\n },\n unMuteMouse: function () {\n clearTimeout(MouseEventNormalizer.mouseTrapTimeoutID);\n MouseEventNormalizer.mouseTrapTimeoutID = setTimeout(function () {\n MouseEventNormalizer.captureMouse = false;\n MouseEventNormalizer.bustClick = false;\n }, 400);\n }\n };\n var eventMap = {\n down: 'touchstart mousedown',\n move: 'mousemove touchmove',\n up: 'mouseup touchend touchcancel',\n cancel: 'mouseleave touchcancel'\n };\n if (support.touch && (support.mobileOS.ios || support.mobileOS.android)) {\n eventMap = {\n down: 'touchstart',\n move: 'touchmove',\n up: 'touchend touchcancel',\n cancel: 'touchcancel'\n };\n } else if (support.pointers) {\n eventMap = {\n down: 'pointerdown',\n move: 'pointermove',\n up: 'pointerup',\n cancel: 'pointercancel pointerleave'\n };\n } else if (support.msPointers) {\n eventMap = {\n down: 'MSPointerDown',\n move: 'MSPointerMove',\n up: 'MSPointerUp',\n cancel: 'MSPointerCancel MSPointerLeave'\n };\n }\n if (support.msPointers && !('onmspointerenter' in window)) {\n $.each({\n MSPointerEnter: 'MSPointerOver',\n MSPointerLeave: 'MSPointerOut'\n }, function (orig, fix) {\n $.event.special[orig] = {\n delegateType: fix,\n bindType: fix,\n handle: function (event) {\n var ret, target = this, related = event.relatedTarget, handleObj = event.handleObj;\n if (!related || related !== target && !$.contains(target, related)) {\n event.type = handleObj.origType;\n ret = handleObj.handler.apply(this, arguments);\n event.type = fix;\n }\n return ret;\n }\n };\n });\n }\n var getEventMap = function (e) {\n return eventMap[e] || e;\n }, eventRegEx = /([^ ]+)/g;\n kendo.applyEventMap = function (events, ns) {\n events = events.replace(eventRegEx, getEventMap);\n if (ns) {\n events = events.replace(eventRegEx, '$1.' + ns);\n }\n return events;\n };\n kendo.keyDownHandler = function (e, widget) {\n var events = widget._events.kendoKeydown;\n if (!events) {\n return true;\n }\n events = events.slice();\n e.sender = widget;\n e.preventKendoKeydown = false;\n for (var idx = 0, length = events.length; idx < length; idx++) {\n events[idx].call(widget, e);\n }\n return !e.preventKendoKeydown;\n };\n var on = $.fn.on;\n function kendoJQuery(selector, context) {\n return new kendoJQuery.fn.init(selector, context);\n }\n noDepricateExtend(true, kendoJQuery, $);\n kendoJQuery.fn = kendoJQuery.prototype = new $();\n kendoJQuery.fn.constructor = kendoJQuery;\n kendoJQuery.fn.init = function (selector, context) {\n if (context && context instanceof $ && !(context instanceof kendoJQuery)) {\n context = kendoJQuery(context);\n }\n return $.fn.init.call(this, selector, context, rootjQuery);\n };\n kendoJQuery.fn.init.prototype = kendoJQuery.fn;\n var rootjQuery = kendoJQuery(document);\n extend(kendoJQuery.fn, {\n handler: function (handler) {\n this.data('handler', handler);\n return this;\n },\n autoApplyNS: function (ns) {\n this.data('kendoNS', ns || kendo.guid());\n return this;\n },\n on: function () {\n var that = this, ns = that.data('kendoNS');\n if (arguments.length === 1) {\n return on.call(that, arguments[0]);\n }\n var context = that, args = slice.call(arguments);\n if (typeof args[args.length - 1] === UNDEFINED) {\n args.pop();\n }\n var callback = args[args.length - 1], events = kendo.applyEventMap(args[0], ns);\n if (support.mouseAndTouchPresent && events.search(/mouse|click/) > -1 && this[0] !== document.documentElement) {\n MouseEventNormalizer.setupMouseMute();\n var selector = args.length === 2 ? null : args[1], bustClick = events.indexOf('click') > -1 && events.indexOf('touchend') > -1;\n on.call(this, {\n touchstart: MouseEventNormalizer.muteMouse,\n touchend: MouseEventNormalizer.unMuteMouse\n }, selector, { bustClick: bustClick });\n }\n if (arguments[0].indexOf('keydown') !== -1 && args[1] && args[1].options) {\n args[0] = events;\n var widget = args[1];\n var keyDownCallBack = args[args.length - 1];\n args[args.length - 1] = function (e) {\n if (kendo.keyDownHandler(e, widget)) {\n return keyDownCallBack.apply(this, [e]);\n }\n };\n on.apply(that, args);\n return that;\n }\n if (typeof callback === STRING) {\n context = that.data('handler');\n callback = context[callback];\n args[args.length - 1] = function (e) {\n callback.call(context, e);\n };\n }\n args[0] = events;\n on.apply(that, args);\n return that;\n },\n kendoDestroy: function (ns) {\n ns = ns || this.data('kendoNS');\n if (ns) {\n this.off('.' + ns);\n }\n return this;\n }\n });\n kendo.jQuery = kendoJQuery;\n kendo.eventMap = eventMap;\n kendo.timezone = function () {\n var months = {\n Jan: 0,\n Feb: 1,\n Mar: 2,\n Apr: 3,\n May: 4,\n Jun: 5,\n Jul: 6,\n Aug: 7,\n Sep: 8,\n Oct: 9,\n Nov: 10,\n Dec: 11\n };\n var days = {\n Sun: 0,\n Mon: 1,\n Tue: 2,\n Wed: 3,\n Thu: 4,\n Fri: 5,\n Sat: 6\n };\n function ruleToDate(year, rule) {\n var date;\n var targetDay;\n var ourDay;\n var month = rule[3];\n var on = rule[4];\n var time = rule[5];\n var cache = rule[8];\n if (!cache) {\n rule[8] = cache = {};\n }\n if (cache[year]) {\n return cache[year];\n }\n if (!isNaN(on)) {\n date = new Date(Date.UTC(year, months[month], on, time[0], time[1], time[2], 0));\n } else if (on.indexOf('last') === 0) {\n date = new Date(Date.UTC(year, months[month] + 1, 1, time[0] - 24, time[1], time[2], 0));\n targetDay = days[on.substr(4, 3)];\n ourDay = date.getUTCDay();\n date.setUTCDate(date.getUTCDate() + targetDay - ourDay - (targetDay > ourDay ? 7 : 0));\n } else if (on.indexOf('>=') >= 0) {\n date = new Date(Date.UTC(year, months[month], on.substr(5), time[0], time[1], time[2], 0));\n targetDay = days[on.substr(0, 3)];\n ourDay = date.getUTCDay();\n date.setUTCDate(date.getUTCDate() + targetDay - ourDay + (targetDay < ourDay ? 7 : 0));\n } else if (on.indexOf('<=') >= 0) {\n date = new Date(Date.UTC(year, months[month], on.substr(5), time[0], time[1], time[2], 0));\n targetDay = days[on.substr(0, 3)];\n ourDay = date.getUTCDay();\n date.setUTCDate(date.getUTCDate() + targetDay - ourDay - (targetDay > ourDay ? 7 : 0));\n }\n return cache[year] = date;\n }\n function findRule(utcTime, rules, zone) {\n rules = rules[zone];\n if (!rules) {\n var time = zone.split(':');\n var offset = 0;\n if (time.length > 1) {\n offset = time[0] * 60 + Number(time[1]);\n }\n return [\n -1000000,\n 'max',\n '-',\n 'Jan',\n 1,\n [\n 0,\n 0,\n 0\n ],\n offset,\n '-'\n ];\n }\n var year = new Date(utcTime).getUTCFullYear();\n rules = jQuery.grep(rules, function (rule) {\n var from = rule[0];\n var to = rule[1];\n return from <= year && (to >= year || from == year && to == 'only' || to == 'max');\n });\n rules.push(utcTime);\n rules.sort(function (a, b) {\n if (typeof a != 'number') {\n a = Number(ruleToDate(year, a));\n }\n if (typeof b != 'number') {\n b = Number(ruleToDate(year, b));\n }\n return a - b;\n });\n var rule = rules[jQuery.inArray(utcTime, rules) - 1] || rules[rules.length - 1];\n return isNaN(rule) ? rule : null;\n }\n function findZone(utcTime, zones, timezone) {\n var zoneRules = zones[timezone];\n if (typeof zoneRules === 'string') {\n zoneRules = zones[zoneRules];\n }\n if (!zoneRules) {\n throw new Error('Timezone \"' + timezone + '\" is either incorrect, or kendo.timezones.min.js is not included.');\n }\n for (var idx = zoneRules.length - 1; idx >= 0; idx--) {\n var until = zoneRules[idx][3];\n if (until && utcTime > until) {\n break;\n }\n }\n var zone = zoneRules[idx + 1];\n if (!zone) {\n throw new Error('Timezone \"' + timezone + '\" not found on ' + utcTime + '.');\n }\n return zone;\n }\n function zoneAndRule(utcTime, zones, rules, timezone) {\n if (typeof utcTime != NUMBER) {\n utcTime = Date.UTC(utcTime.getFullYear(), utcTime.getMonth(), utcTime.getDate(), utcTime.getHours(), utcTime.getMinutes(), utcTime.getSeconds(), utcTime.getMilliseconds());\n }\n var zone = findZone(utcTime, zones, timezone);\n return {\n zone: zone,\n rule: findRule(utcTime, rules, zone[1])\n };\n }\n function offset(utcTime, timezone) {\n if (timezone == 'Etc/UTC' || timezone == 'Etc/GMT') {\n return 0;\n }\n var info = zoneAndRule(utcTime, this.zones, this.rules, timezone);\n var zone = info.zone;\n var rule = info.rule;\n return kendo.parseFloat(rule ? zone[0] - rule[6] : zone[0]);\n }\n function abbr(utcTime, timezone) {\n var info = zoneAndRule(utcTime, this.zones, this.rules, timezone);\n var zone = info.zone;\n var rule = info.rule;\n var base = zone[2];\n if (base.indexOf('/') >= 0) {\n return base.split('/')[rule && +rule[6] ? 1 : 0];\n } else if (base.indexOf('%s') >= 0) {\n return base.replace('%s', !rule || rule[7] == '-' ? '' : rule[7]);\n }\n return base;\n }\n function convert(date, fromOffset, toOffset) {\n var tempToOffset = toOffset;\n var diff;\n if (typeof fromOffset == STRING) {\n fromOffset = this.offset(date, fromOffset);\n }\n if (typeof toOffset == STRING) {\n toOffset = this.offset(date, toOffset);\n }\n var fromLocalOffset = date.getTimezoneOffset();\n date = new Date(date.getTime() + (fromOffset - toOffset) * 60000);\n var toLocalOffset = date.getTimezoneOffset();\n if (typeof tempToOffset == STRING) {\n tempToOffset = this.offset(date, tempToOffset);\n }\n diff = toLocalOffset - fromLocalOffset + (toOffset - tempToOffset);\n return new Date(date.getTime() + diff * 60000);\n }\n function apply(date, timezone) {\n return this.convert(date, date.getTimezoneOffset(), timezone);\n }\n function remove(date, timezone) {\n return this.convert(date, timezone, date.getTimezoneOffset());\n }\n function toLocalDate(time) {\n return this.apply(new Date(time), 'Etc/UTC');\n }\n return {\n zones: {},\n rules: {},\n offset: offset,\n convert: convert,\n apply: apply,\n remove: remove,\n abbr: abbr,\n toLocalDate: toLocalDate\n };\n }();\n kendo.date = function () {\n var MS_PER_MINUTE = 60000, MS_PER_DAY = 86400000;\n function adjustDST(date, hours) {\n if (hours === 0 && date.getHours() === 23) {\n date.setHours(date.getHours() + 2);\n return true;\n }\n return false;\n }\n function setDayOfWeek(date, day, dir) {\n var hours = date.getHours();\n dir = dir || 1;\n day = (day - date.getDay() + 7 * dir) % 7;\n date.setDate(date.getDate() + day);\n adjustDST(date, hours);\n }\n function dayOfWeek(date, day, dir) {\n date = new Date(date);\n setDayOfWeek(date, day, dir);\n return date;\n }\n function firstDayOfMonth(date) {\n return new Date(date.getFullYear(), date.getMonth(), 1);\n }\n function lastDayOfMonth(date) {\n var last = new Date(date.getFullYear(), date.getMonth() + 1, 0), first = firstDayOfMonth(date), timeOffset = Math.abs(last.getTimezoneOffset() - first.getTimezoneOffset());\n if (timeOffset) {\n last.setHours(first.getHours() + timeOffset / 60);\n }\n return last;\n }\n function moveDateToWeekStart(date, weekStartDay) {\n if (weekStartDay !== 1) {\n return addDays(dayOfWeek(date, weekStartDay, -1), 4);\n }\n return addDays(date, 4 - (date.getDay() || 7));\n }\n function calcWeekInYear(date, weekStartDay) {\n var firstWeekInYear = new Date(date.getFullYear(), 0, 1, -6);\n var newDate = moveDateToWeekStart(date, weekStartDay);\n var diffInMS = newDate.getTime() - firstWeekInYear.getTime();\n var days = Math.floor(diffInMS / MS_PER_DAY);\n return 1 + Math.floor(days / 7);\n }\n function weekInYear(date, weekStartDay) {\n if (weekStartDay === undefined) {\n weekStartDay = kendo.culture().calendar.firstDay;\n }\n var prevWeekDate = addDays(date, -7);\n var nextWeekDate = addDays(date, 7);\n var weekNumber = calcWeekInYear(date, weekStartDay);\n if (weekNumber === 0) {\n return calcWeekInYear(prevWeekDate, weekStartDay) + 1;\n }\n if (weekNumber === 53 && calcWeekInYear(nextWeekDate, weekStartDay) > 1) {\n return 1;\n }\n return weekNumber;\n }\n function getDate(date) {\n date = new Date(date.getFullYear(), date.getMonth(), date.getDate(), 0, 0, 0);\n adjustDST(date, 0);\n return date;\n }\n function toUtcTime(date) {\n return Date.UTC(date.getFullYear(), date.getMonth(), date.getDate(), date.getHours(), date.getMinutes(), date.getSeconds(), date.getMilliseconds());\n }\n function getMilliseconds(date) {\n return toInvariantTime(date).getTime() - getDate(toInvariantTime(date));\n }\n function isInTimeRange(value, min, max) {\n var msMin = getMilliseconds(min), msMax = getMilliseconds(max), msValue;\n if (!value || msMin == msMax) {\n return true;\n }\n if (min >= max) {\n max += MS_PER_DAY;\n }\n msValue = getMilliseconds(value);\n if (msMin > msValue) {\n msValue += MS_PER_DAY;\n }\n if (msMax < msMin) {\n msMax += MS_PER_DAY;\n }\n return msValue >= msMin && msValue <= msMax;\n }\n function isInDateRange(value, min, max) {\n var msMin = min.getTime(), msMax = max.getTime(), msValue;\n if (msMin >= msMax) {\n msMax += MS_PER_DAY;\n }\n msValue = value.getTime();\n return msValue >= msMin && msValue <= msMax;\n }\n function addDays(date, offset) {\n var hours = date.getHours();\n date = new Date(date);\n setTime(date, offset * MS_PER_DAY);\n adjustDST(date, hours);\n return date;\n }\n function setTime(date, milliseconds, ignoreDST) {\n var offset = date.getTimezoneOffset();\n var difference;\n date.setTime(date.getTime() + milliseconds);\n if (!ignoreDST) {\n difference = date.getTimezoneOffset() - offset;\n date.setTime(date.getTime() + difference * MS_PER_MINUTE);\n }\n }\n function setHours(date, time) {\n date = new Date(date.getFullYear(), date.getMonth(), date.getDate(), time.getHours(), time.getMinutes(), time.getSeconds(), time.getMilliseconds());\n adjustDST(date, time.getHours());\n return date;\n }\n function today() {\n return getDate(new Date());\n }\n function isToday(date) {\n return getDate(date).getTime() == today().getTime();\n }\n function toInvariantTime(date) {\n var staticDate = new Date(1980, 1, 1, 0, 0, 0);\n if (date) {\n staticDate.setHours(date.getHours(), date.getMinutes(), date.getSeconds(), date.getMilliseconds());\n }\n return staticDate;\n }\n return {\n adjustDST: adjustDST,\n dayOfWeek: dayOfWeek,\n setDayOfWeek: setDayOfWeek,\n getDate: getDate,\n isInDateRange: isInDateRange,\n isInTimeRange: isInTimeRange,\n isToday: isToday,\n nextDay: function (date) {\n return addDays(date, 1);\n },\n previousDay: function (date) {\n return addDays(date, -1);\n },\n toUtcTime: toUtcTime,\n MS_PER_DAY: MS_PER_DAY,\n MS_PER_HOUR: 60 * MS_PER_MINUTE,\n MS_PER_MINUTE: MS_PER_MINUTE,\n setTime: setTime,\n setHours: setHours,\n addDays: addDays,\n today: today,\n toInvariantTime: toInvariantTime,\n firstDayOfMonth: firstDayOfMonth,\n lastDayOfMonth: lastDayOfMonth,\n weekInYear: weekInYear,\n getMilliseconds: getMilliseconds\n };\n }();\n kendo.stripWhitespace = function (element) {\n if (document.createNodeIterator) {\n var iterator = document.createNodeIterator(element, NodeFilter.SHOW_TEXT, function (node) {\n return node.parentNode == element ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_REJECT;\n }, false);\n while (iterator.nextNode()) {\n if (iterator.referenceNode && !iterator.referenceNode.textContent.trim()) {\n iterator.referenceNode.parentNode.removeChild(iterator.referenceNode);\n }\n }\n } else {\n for (var i = 0; i < element.childNodes.length; i++) {\n var child = element.childNodes[i];\n if (child.nodeType == 3 && !/\\S/.test(child.nodeValue)) {\n element.removeChild(child);\n i--;\n }\n if (child.nodeType == 1) {\n kendo.stripWhitespace(child);\n }\n }\n }\n };\n var animationFrame = window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame || window.oRequestAnimationFrame || window.msRequestAnimationFrame || function (callback) {\n setTimeout(callback, 1000 / 60);\n };\n kendo.animationFrame = function (callback) {\n animationFrame.call(window, callback);\n };\n var animationQueue = [];\n kendo.queueAnimation = function (callback) {\n animationQueue[animationQueue.length] = callback;\n if (animationQueue.length === 1) {\n kendo.runNextAnimation();\n }\n };\n kendo.runNextAnimation = function () {\n kendo.animationFrame(function () {\n if (animationQueue[0]) {\n animationQueue.shift()();\n if (animationQueue[0]) {\n kendo.runNextAnimation();\n }\n }\n });\n };\n kendo.parseQueryStringParams = function (url) {\n var queryString = url.split('?')[1] || '', params = {}, paramParts = queryString.split(/&|=/), length = paramParts.length, idx = 0;\n for (; idx < length; idx += 2) {\n if (paramParts[idx] !== '') {\n params[decodeURIComponent(paramParts[idx])] = decodeURIComponent(paramParts[idx + 1]);\n }\n }\n return params;\n };\n kendo.elementUnderCursor = function (e) {\n if (typeof e.x.client != 'undefined') {\n return document.elementFromPoint(e.x.client, e.y.client);\n }\n };\n kendo.wheelDeltaY = function (jQueryEvent) {\n var e = jQueryEvent.originalEvent, deltaY = e.wheelDeltaY, delta;\n if (e.wheelDelta) {\n if (deltaY === undefined || deltaY) {\n delta = e.wheelDelta;\n }\n } else if (e.detail && e.axis === e.VERTICAL_AXIS) {\n delta = -e.detail * 10;\n }\n return delta;\n };\n kendo.throttle = function (fn, delay) {\n var timeout;\n var lastExecTime = 0;\n if (!delay || delay <= 0) {\n return fn;\n }\n var throttled = function () {\n var that = this;\n var elapsed = +new Date() - lastExecTime;\n var args = arguments;\n function exec() {\n fn.apply(that, args);\n lastExecTime = +new Date();\n }\n if (!lastExecTime) {\n return exec();\n }\n if (timeout) {\n clearTimeout(timeout);\n }\n if (elapsed > delay) {\n exec();\n } else {\n timeout = setTimeout(exec, delay - elapsed);\n }\n };\n throttled.cancel = function () {\n clearTimeout(timeout);\n };\n return throttled;\n };\n kendo.caret = function (element, start, end) {\n var rangeElement;\n var isPosition = start !== undefined;\n if (end === undefined) {\n end = start;\n }\n if (element[0]) {\n element = element[0];\n }\n if (isPosition && element.disabled) {\n return;\n }\n try {\n if (element.selectionStart !== undefined) {\n if (isPosition) {\n element.focus();\n var mobile = support.mobileOS;\n if (mobile.wp || mobile.android) {\n setTimeout(function () {\n element.setSelectionRange(start, end);\n }, 0);\n } else {\n element.setSelectionRange(start, end);\n }\n } else {\n start = [\n element.selectionStart,\n element.selectionEnd\n ];\n }\n } else if (document.selection) {\n if ($(element).is(':visible')) {\n element.focus();\n }\n rangeElement = element.createTextRange();\n if (isPosition) {\n rangeElement.collapse(true);\n rangeElement.moveStart('character', start);\n rangeElement.moveEnd('character', end - start);\n rangeElement.select();\n } else {\n var rangeDuplicated = rangeElement.duplicate(), selectionStart, selectionEnd;\n rangeElement.moveToBookmark(document.selection.createRange().getBookmark());\n rangeDuplicated.setEndPoint('EndToStart', rangeElement);\n selectionStart = rangeDuplicated.text.length;\n selectionEnd = selectionStart + rangeElement.text.length;\n start = [\n selectionStart,\n selectionEnd\n ];\n }\n }\n } catch (e) {\n start = [];\n }\n return start;\n };\n kendo.compileMobileDirective = function (element, scope) {\n var angular = window.angular;\n element.attr('data-' + kendo.ns + 'role', element[0].tagName.toLowerCase().replace('kendo-mobile-', '').replace('-', ''));\n angular.element(element).injector().invoke([\n '$compile',\n function ($compile) {\n $compile(element)(scope);\n if (!/^\\$(digest|apply)$/.test(scope.$$phase)) {\n scope.$digest();\n }\n }\n ]);\n return kendo.widgetInstance(element, kendo.mobile.ui);\n };\n kendo.antiForgeryTokens = function () {\n var tokens = {}, csrf_token = $('meta[name=csrf-token],meta[name=_csrf]').attr('content'), csrf_param = $('meta[name=csrf-param],meta[name=_csrf_header]').attr('content');\n $('input[name^=\\'__RequestVerificationToken\\']').each(function () {\n tokens[this.name] = this.value;\n });\n if (csrf_param !== undefined && csrf_token !== undefined) {\n tokens[csrf_param] = csrf_token;\n }\n return tokens;\n };\n kendo.cycleForm = function (form) {\n var firstElement = form.find('input, .k-widget').first();\n var lastElement = form.find('button, .k-button').last();\n function focus(el) {\n var widget = kendo.widgetInstance(el);\n if (widget && widget.focus) {\n widget.focus();\n } else {\n el.focus();\n }\n }\n lastElement.on('keydown', function (e) {\n if (e.keyCode == kendo.keys.TAB && !e.shiftKey) {\n e.preventDefault();\n focus(firstElement);\n }\n });\n firstElement.on('keydown', function (e) {\n if (e.keyCode == kendo.keys.TAB && e.shiftKey) {\n e.preventDefault();\n focus(lastElement);\n }\n });\n };\n kendo.focusElement = function (element) {\n var scrollTopPositions = [];\n var scrollableParents = element.parentsUntil('body').filter(function (index, element) {\n var computedStyle = kendo.getComputedStyles(element, ['overflow']);\n return computedStyle.overflow !== 'visible';\n }).add(window);\n scrollableParents.each(function (index, parent) {\n scrollTopPositions[index] = $(parent).scrollTop();\n });\n try {\n element[0].setActive();\n } catch (e) {\n element[0].focus();\n }\n scrollableParents.each(function (index, parent) {\n $(parent).scrollTop(scrollTopPositions[index]);\n });\n };\n kendo.focusNextElement = function () {\n if (document.activeElement) {\n var focussable = $(':kendoFocusable');\n var index = focussable.index(document.activeElement);\n if (index > -1) {\n var nextElement = focussable[index + 1] || focussable[0];\n nextElement.focus();\n }\n }\n };\n kendo.trim = function (value) {\n if (!!value) {\n return value.toString().trim();\n } else {\n return '';\n }\n };\n kendo.getWidgetFocusableElement = function (element) {\n var nextFocusable = element.closest(':kendoFocusable'), widgetInstance = kendo.widgetInstance(element), target;\n if (nextFocusable.length) {\n target = nextFocusable;\n } else if (widgetInstance) {\n target = widgetInstance.options.name === 'Editor' ? $(widgetInstance.body) : widgetInstance.wrapper.find(':kendoFocusable').first();\n } else {\n target = element;\n }\n return target;\n };\n kendo.addAttribute = function (element, attribute, value) {\n var current = element.attr(attribute) || '';\n if (current.indexOf(value) < 0) {\n element.attr(attribute, (current + ' ' + value).trim());\n }\n };\n kendo.removeAttribute = function (element, attribute, value) {\n var current = element.attr(attribute) || '';\n element.attr(attribute, current.replace(value, '').trim());\n };\n kendo.toggleAttribute = function (element, attribute, value) {\n var current = element.attr(attribute) || '';\n if (current.indexOf(value) < 0) {\n kendo.addAttribute(element, attribute, value);\n } else {\n kendo.removeAttribute(element, attribute, value);\n }\n };\n kendo.matchesMedia = function (mediaQuery) {\n var media = kendo._bootstrapToMedia(mediaQuery) || mediaQuery;\n return support.matchMedia && window.matchMedia(media).matches;\n };\n kendo._bootstrapToMedia = function (bootstrapMedia) {\n return {\n 'xs': '(max-width: 576px)',\n 'sm': '(min-width: 576px)',\n 'md': '(min-width: 768px)',\n 'lg': '(min-width: 992px)',\n 'xl': '(min-width: 1200px)'\n }[bootstrapMedia];\n };\n kendo.fileGroupMap = {\n audio: [\n '.aif',\n '.iff',\n '.m3u',\n '.m4a',\n '.mid',\n '.mp3',\n '.mpa',\n '.wav',\n '.wma',\n '.ogg',\n '.wav',\n '.wma',\n '.wpl'\n ],\n video: [\n '.3g2',\n '.3gp',\n '.avi',\n '.asf',\n '.flv',\n '.m4u',\n '.rm',\n '.h264',\n '.m4v',\n '.mkv',\n '.mov',\n '.mp4',\n '.mpg',\n '.rm',\n '.swf',\n '.vob',\n '.wmv'\n ],\n image: [\n '.ai',\n '.dds',\n '.heic',\n '.jpe',\n 'jfif',\n '.jif',\n '.jp2',\n '.jps',\n '.eps',\n '.bmp',\n '.gif',\n '.jpeg',\n '.jpg',\n '.png',\n '.ps',\n '.psd',\n '.svg',\n '.svgz',\n '.tif',\n '.tiff'\n ],\n txt: [\n '.doc',\n '.docx',\n '.log',\n '.pages',\n '.tex',\n '.wpd',\n '.wps',\n '.odt',\n '.rtf',\n '.text',\n '.txt',\n '.wks'\n ],\n presentation: [\n '.key',\n '.odp',\n '.pps',\n '.ppt',\n '.pptx'\n ],\n data: [\n '.xlr',\n '.xls',\n '.xlsx'\n ],\n programming: [\n '.tmp',\n '.bak',\n '.msi',\n '.cab',\n '.cpl',\n '.cur',\n '.dll',\n '.dmp',\n '.drv',\n '.icns',\n '.ico',\n '.link',\n '.sys',\n '.cfg',\n '.ini',\n '.asp',\n '.aspx',\n '.cer',\n '.csr',\n '.css',\n '.dcr',\n '.htm',\n '.html',\n '.js',\n '.php',\n '.rss',\n '.xhtml'\n ],\n pdf: ['.pdf'],\n config: [\n '.apk',\n '.app',\n '.bat',\n '.cgi',\n '.com',\n '.exe',\n '.gadget',\n '.jar',\n '.wsf'\n ],\n zip: [\n '.7z',\n '.cbr',\n '.gz',\n '.sitx',\n '.arj',\n '.deb',\n '.pkg',\n '.rar',\n '.rpm',\n '.tar.gz',\n '.z',\n '.zip',\n '.zipx'\n ],\n 'disc-image': [\n '.dmg',\n '.iso',\n '.toast',\n '.vcd',\n '.bin',\n '.cue',\n '.mdf'\n ]\n };\n kendo.getFileGroup = function (extension, withPrefix) {\n var fileTypeMap = kendo.fileGroupMap;\n var groups = Object.keys(fileTypeMap);\n var type = 'file';\n if (extension === undefined || !extension.length) {\n return type;\n }\n for (var i = 0; i < groups.length; i += 1) {\n var extensions = fileTypeMap[groups[i]];\n if (extensions.indexOf(extension.toLowerCase()) > -1) {\n return withPrefix ? 'file-' + groups[i] : groups[i];\n }\n }\n return type;\n };\n kendo.getFileSizeMessage = function (size) {\n var sizes = [\n 'Bytes',\n 'KB',\n 'MB',\n 'GB',\n 'TB'\n ];\n if (size === 0) {\n return '0 Byte';\n }\n var i = parseInt(Math.floor(Math.log(size) / Math.log(1024)), 10);\n return Math.round(size / Math.pow(1024, i), 2) + ' ' + sizes[i];\n };\n kendo.selectorFromClasses = function (classes) {\n return '.' + classes.split(' ').join('.');\n };\n (function () {\n function postToProxy(dataURI, fileName, proxyURL, proxyTarget) {\n var form = $('
').attr({\n action: proxyURL,\n method: 'POST',\n target: proxyTarget\n });\n var data = kendo.antiForgeryTokens();\n data.fileName = fileName;\n var parts = dataURI.split(';base64,');\n data.contentType = parts[0].replace('data:', '');\n data.base64 = parts[1];\n for (var name in data) {\n if (data.hasOwnProperty(name)) {\n $('').attr({\n value: data[name],\n name: name,\n type: 'hidden'\n }).appendTo(form);\n }\n }\n form.appendTo('body').submit().remove();\n }\n var fileSaver = document.createElement('a');\n var downloadAttribute = 'download' in fileSaver && !kendo.support.browser.edge;\n function saveAsBlob(dataURI, fileName) {\n var blob = dataURI;\n if (typeof dataURI == 'string') {\n var parts = dataURI.split(';base64,');\n var contentType = parts[0];\n var base64 = atob(parts[1]);\n var array = new Uint8Array(base64.length);\n for (var idx = 0; idx < base64.length; idx++) {\n array[idx] = base64.charCodeAt(idx);\n }\n blob = new Blob([array.buffer], { type: contentType });\n }\n navigator.msSaveBlob(blob, fileName);\n }\n function saveAsDataURI(dataURI, fileName) {\n if (window.Blob && dataURI instanceof Blob) {\n dataURI = URL.createObjectURL(dataURI);\n }\n fileSaver.download = fileName;\n fileSaver.href = dataURI;\n var e = document.createEvent('MouseEvents');\n e.initMouseEvent('click', true, false, window, 0, 0, 0, 0, 0, false, false, false, false, 0, null);\n fileSaver.dispatchEvent(e);\n setTimeout(function () {\n URL.revokeObjectURL(dataURI);\n });\n }\n kendo.saveAs = function (options) {\n var save = postToProxy;\n if (!options.forceProxy) {\n if (downloadAttribute) {\n save = saveAsDataURI;\n } else if (navigator.msSaveBlob) {\n save = saveAsBlob;\n }\n }\n save(options.dataURI, options.fileName, options.proxyURL, options.proxyTarget);\n };\n }());\n kendo.proxyModelSetters = function proxyModelSetters(data) {\n var observable = {};\n Object.keys(data || {}).forEach(function (property) {\n Object.defineProperty(observable, property, {\n get: function () {\n return data[property];\n },\n set: function (value) {\n data[property] = value;\n data.dirty = true;\n }\n });\n });\n return observable;\n };\n (function () {\n kendo.defaults = kendo.defaults || {};\n kendo.setDefaults = function (key, value) {\n var path = key.split('.');\n var curr = kendo.defaults;\n key = path.pop();\n path.forEach(function (part) {\n if (curr[part] === undefined) {\n curr[part] = {};\n }\n curr = curr[part];\n });\n if (value.constructor === Object) {\n curr[key] = deepExtend({}, curr[key], value);\n } else {\n curr[key] = value;\n }\n };\n }());\n }(jQuery, window));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.fx', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'fx',\n name: 'Effects',\n category: 'framework',\n description: 'Required for animation effects in all Kendo UI widgets.',\n depends: ['core']\n };\n (function ($, undefined) {\n var kendo = window.kendo, fx = kendo.effects, each = $.each, extend = $.extend, proxy = $.proxy, support = kendo.support, browser = support.browser, transforms = support.transforms, transitions = support.transitions, scaleProperties = {\n scale: 0,\n scalex: 0,\n scaley: 0,\n scale3d: 0\n }, translateProperties = {\n translate: 0,\n translatex: 0,\n translatey: 0,\n translate3d: 0\n }, hasZoom = typeof document.documentElement.style.zoom !== 'undefined' && !transforms, matrix3dRegExp = /matrix3?d?\\s*\\(.*,\\s*([\\d\\.\\-]+)\\w*?,\\s*([\\d\\.\\-]+)\\w*?,\\s*([\\d\\.\\-]+)\\w*?,\\s*([\\d\\.\\-]+)\\w*?/i, cssParamsRegExp = /^(-?[\\d\\.\\-]+)?[\\w\\s]*,?\\s*(-?[\\d\\.\\-]+)?[\\w\\s]*/i, translateXRegExp = /translatex?$/i, oldEffectsRegExp = /(zoom|fade|expand)(\\w+)/, singleEffectRegExp = /(zoom|fade|expand)/, unitRegExp = /[xy]$/i, transformProps = [\n 'perspective',\n 'rotate',\n 'rotatex',\n 'rotatey',\n 'rotatez',\n 'rotate3d',\n 'scale',\n 'scalex',\n 'scaley',\n 'scalez',\n 'scale3d',\n 'skew',\n 'skewx',\n 'skewy',\n 'translate',\n 'translatex',\n 'translatey',\n 'translatez',\n 'translate3d',\n 'matrix',\n 'matrix3d'\n ], transform2d = [\n 'rotate',\n 'scale',\n 'scalex',\n 'scaley',\n 'skew',\n 'skewx',\n 'skewy',\n 'translate',\n 'translatex',\n 'translatey',\n 'matrix'\n ], transform2units = {\n 'rotate': 'deg',\n scale: '',\n skew: 'px',\n translate: 'px'\n }, cssPrefix = transforms.css, round = Math.round, BLANK = '', PX = 'px', NONE = 'none', AUTO = 'auto', WIDTH = 'width', HEIGHT = 'height', HIDDEN = 'hidden', ORIGIN = 'origin', ABORT_ID = 'abortId', OVERFLOW = 'overflow', TRANSLATE = 'translate', POSITION = 'position', COMPLETE_CALLBACK = 'completeCallback', TRANSITION = cssPrefix + 'transition', TRANSFORM = cssPrefix + 'transform', BACKFACE = cssPrefix + 'backface-visibility', PERSPECTIVE = cssPrefix + 'perspective', DEFAULT_PERSPECTIVE = '1500px', TRANSFORM_PERSPECTIVE = 'perspective(' + DEFAULT_PERSPECTIVE + ')', directions = {\n left: {\n reverse: 'right',\n property: 'left',\n transition: 'translatex',\n vertical: false,\n modifier: -1\n },\n right: {\n reverse: 'left',\n property: 'left',\n transition: 'translatex',\n vertical: false,\n modifier: 1\n },\n down: {\n reverse: 'up',\n property: 'top',\n transition: 'translatey',\n vertical: true,\n modifier: 1\n },\n up: {\n reverse: 'down',\n property: 'top',\n transition: 'translatey',\n vertical: true,\n modifier: -1\n },\n top: { reverse: 'bottom' },\n bottom: { reverse: 'top' },\n 'in': {\n reverse: 'out',\n modifier: -1\n },\n out: {\n reverse: 'in',\n modifier: 1\n },\n vertical: { reverse: 'vertical' },\n horizontal: { reverse: 'horizontal' }\n };\n kendo.directions = directions;\n extend($.fn, {\n kendoStop: function (clearQueue, gotoEnd) {\n if (transitions) {\n return fx.stopQueue(this, clearQueue || false, gotoEnd || false);\n } else {\n return this.stop(clearQueue, gotoEnd);\n }\n }\n });\n if (transforms && !transitions) {\n each(transform2d, function (idx, value) {\n $.fn[value] = function (val) {\n if (typeof val == 'undefined') {\n return animationProperty(this, value);\n } else {\n var that = $(this)[0], transformValue = value + '(' + val + transform2units[value.replace(unitRegExp, '')] + ')';\n if (that.style.cssText.indexOf(TRANSFORM) == -1) {\n $(this).css(TRANSFORM, transformValue);\n } else {\n that.style.cssText = that.style.cssText.replace(new RegExp(value + '\\\\(.*?\\\\)', 'i'), transformValue);\n }\n }\n return this;\n };\n $.fx.step[value] = function (fx) {\n $(fx.elem)[value](fx.now);\n };\n });\n var curProxy = $.fx.prototype.cur;\n $.fx.prototype.cur = function () {\n if (transform2d.indexOf(this.prop) != -1) {\n return parseFloat($(this.elem)[this.prop]());\n }\n return curProxy.apply(this, arguments);\n };\n }\n kendo.toggleClass = function (element, classes, options, add) {\n if (classes) {\n classes = classes.split(' ');\n if (transitions) {\n options = extend({\n exclusive: 'all',\n duration: 400,\n ease: 'ease-out'\n }, options);\n element.css(TRANSITION, options.exclusive + ' ' + options.duration + 'ms ' + options.ease);\n setTimeout(function () {\n element.css(TRANSITION, '').css(HEIGHT);\n }, options.duration);\n }\n each(classes, function (idx, value) {\n element.toggleClass(value, add);\n });\n }\n return element;\n };\n kendo.parseEffects = function (input, mirror) {\n var effects = {};\n if (typeof input === 'string') {\n each(input.split(' '), function (idx, value) {\n var redirectedEffect = !singleEffectRegExp.test(value), resolved = value.replace(oldEffectsRegExp, function (match, $1, $2) {\n return $1 + ':' + $2.toLowerCase();\n }), effect = resolved.split(':'), direction = effect[1], effectBody = {};\n if (effect.length > 1) {\n effectBody.direction = mirror && redirectedEffect ? directions[direction].reverse : direction;\n }\n effects[effect[0]] = effectBody;\n });\n } else {\n each(input, function (idx) {\n var direction = this.direction;\n if (direction && mirror && !singleEffectRegExp.test(idx)) {\n this.direction = directions[direction].reverse;\n }\n effects[idx] = this;\n });\n }\n return effects;\n };\n function parseInteger(value) {\n return parseInt(value, 10);\n }\n function parseCSS(element, property) {\n return parseInteger(element.css(property));\n }\n function keys(obj) {\n var acc = [];\n for (var propertyName in obj) {\n acc.push(propertyName);\n }\n return acc;\n }\n function strip3DTransforms(properties) {\n for (var key in properties) {\n if (transformProps.indexOf(key) != -1 && transform2d.indexOf(key) == -1) {\n delete properties[key];\n }\n }\n return properties;\n }\n function normalizeCSS(element, properties) {\n var transformation = [], cssValues = {}, lowerKey, key, value, isTransformed;\n for (key in properties) {\n lowerKey = key.toLowerCase();\n isTransformed = transforms && transformProps.indexOf(lowerKey) != -1;\n if (!support.hasHW3D && isTransformed && transform2d.indexOf(lowerKey) == -1) {\n delete properties[key];\n } else {\n value = properties[key];\n if (isTransformed) {\n transformation.push(key + '(' + value + ')');\n } else {\n cssValues[key] = value;\n }\n }\n }\n if (transformation.length) {\n cssValues[TRANSFORM] = transformation.join(' ');\n }\n return cssValues;\n }\n if (transitions) {\n extend(fx, {\n transition: function (element, properties, options) {\n var css, delay = 0, oldKeys = element.data('keys') || [], timeoutID;\n options = extend({\n duration: 200,\n ease: 'ease-out',\n complete: null,\n exclusive: 'all'\n }, options);\n var stopTransitionCalled = false;\n var stopTransition = function () {\n if (!stopTransitionCalled) {\n stopTransitionCalled = true;\n if (timeoutID) {\n clearTimeout(timeoutID);\n timeoutID = null;\n }\n element.removeData(ABORT_ID).dequeue().css(TRANSITION, '').css(TRANSITION);\n options.complete.call(element);\n }\n };\n options.duration = $.fx ? $.fx.speeds[options.duration] || options.duration : options.duration;\n css = normalizeCSS(element, properties);\n $.merge(oldKeys, keys(css));\n if ($.hasOwnProperty('uniqueSort')) {\n element.data('keys', $.uniqueSort(oldKeys)).height();\n } else {\n element.data('keys', $.unique(oldKeys)).height();\n }\n element.css(TRANSITION, options.exclusive + ' ' + options.duration + 'ms ' + options.ease).css(TRANSITION);\n element.css(css).css(TRANSFORM);\n if (transitions.event) {\n element.one(transitions.event, stopTransition);\n if (options.duration !== 0) {\n delay = 500;\n }\n }\n timeoutID = setTimeout(stopTransition, options.duration + delay);\n element.data(ABORT_ID, timeoutID);\n element.data(COMPLETE_CALLBACK, stopTransition);\n },\n stopQueue: function (element, clearQueue, gotoEnd) {\n var cssValues, taskKeys = element.data('keys'), retainPosition = !gotoEnd && taskKeys, completeCallback = element.data(COMPLETE_CALLBACK);\n if (retainPosition) {\n cssValues = kendo.getComputedStyles(element[0], taskKeys);\n }\n if (completeCallback) {\n completeCallback();\n }\n if (retainPosition) {\n element.css(cssValues);\n }\n return element.removeData('keys').stop(clearQueue);\n }\n });\n }\n function animationProperty(element, property) {\n if (transforms) {\n var transform = element.css(TRANSFORM);\n if (transform == NONE) {\n return property == 'scale' ? 1 : 0;\n }\n var match = transform.match(new RegExp(property + '\\\\s*\\\\(([\\\\d\\\\w\\\\.]+)')), computed = 0;\n if (match) {\n computed = parseInteger(match[1]);\n } else {\n match = transform.match(matrix3dRegExp) || [\n 0,\n 0,\n 0,\n 0,\n 0\n ];\n property = property.toLowerCase();\n if (translateXRegExp.test(property)) {\n computed = parseFloat(match[3] / match[2]);\n } else if (property == 'translatey') {\n computed = parseFloat(match[4] / match[2]);\n } else if (property == 'scale') {\n computed = parseFloat(match[2]);\n } else if (property == 'rotate') {\n computed = parseFloat(Math.atan2(match[2], match[1]));\n }\n }\n return computed;\n } else {\n return parseFloat(element.css(property));\n }\n }\n var EffectSet = kendo.Class.extend({\n init: function (element, options) {\n var that = this;\n that.element = element;\n that.effects = [];\n that.options = options;\n that.restore = [];\n },\n run: function (effects) {\n var that = this, effect, idx, jdx, length = effects.length, element = that.element, options = that.options, deferred = $.Deferred(), start = {}, end = {}, target, children, childrenLength;\n that.effects = effects;\n deferred.done($.proxy(that, 'complete'));\n element.data('animating', true);\n for (idx = 0; idx < length; idx++) {\n effect = effects[idx];\n effect.setReverse(options.reverse);\n effect.setOptions(options);\n that.addRestoreProperties(effect.restore);\n effect.prepare(start, end);\n children = effect.children();\n for (jdx = 0, childrenLength = children.length; jdx < childrenLength; jdx++) {\n children[jdx].duration(options.duration).run();\n }\n }\n for (var effectName in options.effects) {\n extend(end, options.effects[effectName].properties);\n }\n if (!element.is(':visible')) {\n extend(start, { display: element.data('olddisplay') || 'block' });\n }\n if (transforms && !options.reset) {\n target = element.data('targetTransform');\n if (target) {\n start = extend(target, start);\n }\n }\n start = normalizeCSS(element, start);\n if (transforms && !transitions) {\n start = strip3DTransforms(start);\n }\n element.css(start).css(TRANSFORM);\n for (idx = 0; idx < length; idx++) {\n effects[idx].setup();\n }\n if (options.init) {\n options.init();\n }\n element.data('targetTransform', end);\n fx.animate(element, end, extend({}, options, { complete: deferred.resolve }));\n return deferred.promise();\n },\n stop: function () {\n $(this.element).kendoStop(true, true);\n },\n addRestoreProperties: function (restore) {\n var element = this.element, value, i = 0, length = restore.length;\n for (; i < length; i++) {\n value = restore[i];\n this.restore.push(value);\n if (!element.data(value)) {\n element.data(value, element.css(value));\n }\n }\n },\n restoreCallback: function () {\n var element = this.element;\n for (var i = 0, length = this.restore.length; i < length; i++) {\n var value = this.restore[i];\n element.css(value, element.data(value));\n }\n },\n complete: function () {\n var that = this, idx = 0, element = that.element, options = that.options, effects = that.effects, length = effects.length;\n element.removeData('animating').dequeue();\n if (options.hide) {\n element.data('olddisplay', element.css('display')).hide();\n }\n this.restoreCallback();\n if (hasZoom && !transforms) {\n setTimeout($.proxy(this, 'restoreCallback'), 0);\n }\n for (; idx < length; idx++) {\n effects[idx].teardown();\n }\n if (options.completeCallback) {\n options.completeCallback(element);\n }\n }\n });\n fx.promise = function (element, options) {\n var effects = [], effectClass, effectSet = new EffectSet(element, options), parsedEffects = kendo.parseEffects(options.effects), effect;\n options.effects = parsedEffects;\n for (var effectName in parsedEffects) {\n effectClass = fx[capitalize(effectName)];\n if (effectClass) {\n effect = new effectClass(element, parsedEffects[effectName].direction);\n effects.push(effect);\n }\n }\n if (effects[0]) {\n effectSet.run(effects);\n } else {\n if (!element.is(':visible')) {\n element.css({ display: element.data('olddisplay') || 'block' }).css('display');\n }\n if (options.init) {\n options.init();\n }\n element.dequeue();\n effectSet.complete();\n }\n };\n extend(fx, {\n animate: function (elements, properties, options) {\n var useTransition = options.transition !== false;\n delete options.transition;\n if (transitions && 'transition' in fx && useTransition) {\n fx.transition(elements, properties, options);\n } else {\n if (transforms) {\n elements.animate(strip3DTransforms(properties), {\n queue: false,\n show: false,\n hide: false,\n duration: options.duration,\n complete: options.complete\n });\n } else {\n elements.each(function () {\n var element = $(this), multiple = {};\n each(transformProps, function (idx, value) {\n var params, currentValue = properties ? properties[value] + ' ' : null;\n if (currentValue) {\n var single = properties;\n if (value in scaleProperties && properties[value] !== undefined) {\n params = currentValue.match(cssParamsRegExp);\n if (transforms) {\n extend(single, { scale: +params[0] });\n }\n } else {\n if (value in translateProperties && properties[value] !== undefined) {\n var position = element.css(POSITION), isFixed = position == 'absolute' || position == 'fixed';\n if (!element.data(TRANSLATE)) {\n if (isFixed) {\n element.data(TRANSLATE, {\n top: parseCSS(element, 'top') || 0,\n left: parseCSS(element, 'left') || 0,\n bottom: parseCSS(element, 'bottom'),\n right: parseCSS(element, 'right')\n });\n } else {\n element.data(TRANSLATE, {\n top: parseCSS(element, 'marginTop') || 0,\n left: parseCSS(element, 'marginLeft') || 0\n });\n }\n }\n var originalPosition = element.data(TRANSLATE);\n params = currentValue.match(cssParamsRegExp);\n if (params) {\n var dX = value == TRANSLATE + 'y' ? +null : +params[1], dY = value == TRANSLATE + 'y' ? +params[1] : +params[2];\n if (isFixed) {\n if (!isNaN(originalPosition.right)) {\n if (!isNaN(dX)) {\n extend(single, { right: originalPosition.right - dX });\n }\n } else {\n if (!isNaN(dX)) {\n extend(single, { left: originalPosition.left + dX });\n }\n }\n if (!isNaN(originalPosition.bottom)) {\n if (!isNaN(dY)) {\n extend(single, { bottom: originalPosition.bottom - dY });\n }\n } else {\n if (!isNaN(dY)) {\n extend(single, { top: originalPosition.top + dY });\n }\n }\n } else {\n if (!isNaN(dX)) {\n extend(single, { marginLeft: originalPosition.left + dX });\n }\n if (!isNaN(dY)) {\n extend(single, { marginTop: originalPosition.top + dY });\n }\n }\n }\n }\n }\n if (!transforms && value != 'scale' && value in single) {\n delete single[value];\n }\n if (single) {\n extend(multiple, single);\n }\n }\n });\n if (browser.msie) {\n delete multiple.scale;\n }\n element.animate(multiple, {\n queue: false,\n show: false,\n hide: false,\n duration: options.duration,\n complete: options.complete\n });\n });\n }\n }\n }\n });\n fx.animatedPromise = fx.promise;\n var Effect = kendo.Class.extend({\n init: function (element, direction) {\n var that = this;\n that.element = element;\n that._direction = direction;\n that.options = {};\n that._additionalEffects = [];\n if (!that.restore) {\n that.restore = [];\n }\n },\n reverse: function () {\n this._reverse = true;\n return this.run();\n },\n play: function () {\n this._reverse = false;\n return this.run();\n },\n add: function (additional) {\n this._additionalEffects.push(additional);\n return this;\n },\n direction: function (value) {\n this._direction = value;\n return this;\n },\n duration: function (duration) {\n this._duration = duration;\n return this;\n },\n compositeRun: function () {\n var that = this, effectSet = new EffectSet(that.element, {\n reverse: that._reverse,\n duration: that._duration\n }), effects = that._additionalEffects.concat([that]);\n return effectSet.run(effects);\n },\n run: function () {\n if (this._additionalEffects && this._additionalEffects[0]) {\n return this.compositeRun();\n }\n var that = this, element = that.element, idx = 0, restore = that.restore, length = restore.length, value, deferred = $.Deferred(), start = {}, end = {}, target, children = that.children(), childrenLength = children.length;\n deferred.done($.proxy(that, '_complete'));\n element.data('animating', true);\n for (idx = 0; idx < length; idx++) {\n value = restore[idx];\n if (!element.data(value)) {\n element.data(value, element.css(value));\n }\n }\n for (idx = 0; idx < childrenLength; idx++) {\n children[idx].duration(that._duration).run();\n }\n that.prepare(start, end);\n if (!element.is(':visible')) {\n extend(start, { display: element.data('olddisplay') || 'block' });\n }\n if (transforms) {\n target = element.data('targetTransform');\n if (target) {\n start = extend(target, start);\n }\n }\n start = normalizeCSS(element, start);\n if (transforms && !transitions) {\n start = strip3DTransforms(start);\n }\n element.css(start).css(TRANSFORM);\n that.setup();\n element.data('targetTransform', end);\n fx.animate(element, end, {\n duration: that._duration,\n complete: deferred.resolve\n });\n return deferred.promise();\n },\n stop: function () {\n var idx = 0, children = this.children(), childrenLength = children.length;\n for (idx = 0; idx < childrenLength; idx++) {\n children[idx].stop();\n }\n $(this.element).kendoStop(true, true);\n return this;\n },\n restoreCallback: function () {\n var element = this.element;\n for (var i = 0, length = this.restore.length; i < length; i++) {\n var value = this.restore[i];\n element.css(value, element.data(value));\n }\n },\n _complete: function () {\n var that = this, element = that.element;\n element.removeData('animating').dequeue();\n that.restoreCallback();\n if (that.shouldHide()) {\n element.data('olddisplay', element.css('display')).hide();\n }\n if (hasZoom && !transforms) {\n setTimeout($.proxy(that, 'restoreCallback'), 0);\n }\n that.teardown();\n },\n setOptions: function (options) {\n extend(true, this.options, options);\n },\n children: function () {\n return [];\n },\n shouldHide: $.noop,\n setup: $.noop,\n prepare: $.noop,\n teardown: $.noop,\n directions: [],\n setReverse: function (reverse) {\n this._reverse = reverse;\n return this;\n }\n });\n function capitalize(word) {\n return word.charAt(0).toUpperCase() + word.substring(1);\n }\n function createEffect(name, definition) {\n var effectClass = Effect.extend(definition), directions = effectClass.prototype.directions;\n fx[capitalize(name)] = effectClass;\n fx.Element.prototype[name] = function (direction, opt1, opt2, opt3) {\n return new effectClass(this.element, direction, opt1, opt2, opt3);\n };\n each(directions, function (idx, theDirection) {\n fx.Element.prototype[name + capitalize(theDirection)] = function (opt1, opt2, opt3) {\n return new effectClass(this.element, theDirection, opt1, opt2, opt3);\n };\n });\n }\n var FOUR_DIRECTIONS = [\n 'left',\n 'right',\n 'up',\n 'down'\n ], IN_OUT = [\n 'in',\n 'out'\n ];\n createEffect('slideIn', {\n directions: FOUR_DIRECTIONS,\n divisor: function (value) {\n this.options.divisor = value;\n return this;\n },\n prepare: function (start, end) {\n var that = this, tmp, element = that.element, outerWidth = kendo._outerWidth, outerHeight = kendo._outerHeight, direction = directions[that._direction], offset = -direction.modifier * (direction.vertical ? outerHeight(element) : outerWidth(element)), startValue = offset / (that.options && that.options.divisor || 1) + PX, endValue = '0px';\n if (that._reverse) {\n tmp = start;\n start = end;\n end = tmp;\n }\n if (transforms) {\n start[direction.transition] = startValue;\n end[direction.transition] = endValue;\n } else {\n start[direction.property] = startValue;\n end[direction.property] = endValue;\n }\n }\n });\n createEffect('tile', {\n directions: FOUR_DIRECTIONS,\n init: function (element, direction, previous) {\n Effect.prototype.init.call(this, element, direction);\n this.options = { previous: previous };\n },\n previousDivisor: function (value) {\n this.options.previousDivisor = value;\n return this;\n },\n children: function () {\n var that = this, reverse = that._reverse, previous = that.options.previous, divisor = that.options.previousDivisor || 1, dir = that._direction;\n var children = [kendo.fx(that.element).slideIn(dir).setReverse(reverse)];\n if (previous) {\n children.push(kendo.fx(previous).slideIn(directions[dir].reverse).divisor(divisor).setReverse(!reverse));\n }\n return children;\n }\n });\n function createToggleEffect(name, property, defaultStart, defaultEnd) {\n createEffect(name, {\n directions: IN_OUT,\n startValue: function (value) {\n this._startValue = value;\n return this;\n },\n endValue: function (value) {\n this._endValue = value;\n return this;\n },\n shouldHide: function () {\n return this._shouldHide;\n },\n prepare: function (start, end) {\n var that = this, startValue, endValue, out = this._direction === 'out', startDataValue = that.element.data(property), startDataValueIsSet = !(isNaN(startDataValue) || startDataValue == defaultStart);\n if (startDataValueIsSet) {\n startValue = startDataValue;\n } else if (typeof this._startValue !== 'undefined') {\n startValue = this._startValue;\n } else {\n startValue = out ? defaultStart : defaultEnd;\n }\n if (typeof this._endValue !== 'undefined') {\n endValue = this._endValue;\n } else {\n endValue = out ? defaultEnd : defaultStart;\n }\n if (this._reverse) {\n start[property] = endValue;\n end[property] = startValue;\n } else {\n start[property] = startValue;\n end[property] = endValue;\n }\n that._shouldHide = end[property] === defaultEnd;\n }\n });\n }\n createToggleEffect('fade', 'opacity', 1, 0);\n createToggleEffect('zoom', 'scale', 1, 0.01);\n createEffect('slideMargin', {\n prepare: function (start, end) {\n var that = this, element = that.element, options = that.options, origin = element.data(ORIGIN), offset = options.offset, margin, reverse = that._reverse;\n if (!reverse && origin === null) {\n element.data(ORIGIN, parseFloat(element.css('margin-' + options.axis)));\n }\n margin = element.data(ORIGIN) || 0;\n end['margin-' + options.axis] = !reverse ? margin + offset : margin;\n }\n });\n createEffect('slideTo', {\n prepare: function (start, end) {\n var that = this, element = that.element, options = that.options, offset = options.offset.split(','), reverse = that._reverse;\n if (transforms) {\n end.translatex = !reverse ? offset[0] : 0;\n end.translatey = !reverse ? offset[1] : 0;\n } else {\n end.left = !reverse ? offset[0] : 0;\n end.top = !reverse ? offset[1] : 0;\n }\n element.css('left');\n }\n });\n createEffect('expand', {\n directions: [\n 'horizontal',\n 'vertical'\n ],\n restore: [OVERFLOW],\n prepare: function (start, end) {\n var that = this, element = that.element, options = that.options, reverse = that._reverse, property = that._direction === 'vertical' ? HEIGHT : WIDTH, setLength = element[0].style[property], oldLength = element.data(property), length = parseFloat(oldLength || setLength), realLength = round(element.css(property, AUTO)[property]());\n start.overflow = HIDDEN;\n length = options && options.reset ? realLength || length : length || realLength;\n end[property] = (reverse ? 0 : length) + PX;\n start[property] = (reverse ? length : 0) + PX;\n if (oldLength === undefined) {\n element.data(property, setLength);\n }\n },\n shouldHide: function () {\n return this._reverse;\n },\n teardown: function () {\n var that = this, element = that.element, property = that._direction === 'vertical' ? HEIGHT : WIDTH, length = element.data(property);\n if (length == AUTO || length === BLANK) {\n setTimeout(function () {\n element.css(property, AUTO).css(property);\n }, 0);\n }\n }\n });\n var TRANSFER_START_STATE = {\n position: 'absolute',\n marginLeft: 0,\n marginTop: 0,\n scale: 1\n };\n createEffect('transfer', {\n init: function (element, target) {\n this.element = element;\n this.options = { target: target };\n this.restore = [];\n },\n setup: function () {\n this.element.appendTo(document.body);\n },\n prepare: function (start, end) {\n var that = this, element = that.element, outerBox = fx.box(element), innerBox = fx.box(that.options.target), currentScale = animationProperty(element, 'scale'), scale = fx.fillScale(innerBox, outerBox), transformOrigin = fx.transformOrigin(innerBox, outerBox);\n extend(start, TRANSFER_START_STATE);\n end.scale = 1;\n element.css(TRANSFORM, 'scale(1)').css(TRANSFORM);\n element.css(TRANSFORM, 'scale(' + currentScale + ')');\n start.top = outerBox.top;\n start.left = outerBox.left;\n start.transformOrigin = transformOrigin.x + PX + ' ' + transformOrigin.y + PX;\n if (that._reverse) {\n start.scale = scale;\n } else {\n end.scale = scale;\n }\n }\n });\n var CLIPS = {\n top: 'rect(auto auto $size auto)',\n bottom: 'rect($size auto auto auto)',\n left: 'rect(auto $size auto auto)',\n right: 'rect(auto auto auto $size)'\n };\n var ROTATIONS = {\n top: {\n start: 'rotatex(0deg)',\n end: 'rotatex(180deg)'\n },\n bottom: {\n start: 'rotatex(-180deg)',\n end: 'rotatex(0deg)'\n },\n left: {\n start: 'rotatey(0deg)',\n end: 'rotatey(-180deg)'\n },\n right: {\n start: 'rotatey(180deg)',\n end: 'rotatey(0deg)'\n }\n };\n function clipInHalf(container, direction) {\n var vertical = kendo.directions[direction].vertical, size = container[vertical ? HEIGHT : WIDTH]() / 2 + 'px';\n return CLIPS[direction].replace('$size', size);\n }\n createEffect('turningPage', {\n directions: FOUR_DIRECTIONS,\n init: function (element, direction, container) {\n Effect.prototype.init.call(this, element, direction);\n this._container = container;\n },\n prepare: function (start, end) {\n var that = this, reverse = that._reverse, direction = reverse ? directions[that._direction].reverse : that._direction, rotation = ROTATIONS[direction];\n start.zIndex = 1;\n if (that._clipInHalf) {\n start.clip = clipInHalf(that._container, kendo.directions[direction].reverse);\n }\n start[BACKFACE] = HIDDEN;\n end[TRANSFORM] = TRANSFORM_PERSPECTIVE + (reverse ? rotation.start : rotation.end);\n start[TRANSFORM] = TRANSFORM_PERSPECTIVE + (reverse ? rotation.end : rotation.start);\n },\n setup: function () {\n this._container.append(this.element);\n },\n face: function (value) {\n this._face = value;\n return this;\n },\n shouldHide: function () {\n var that = this, reverse = that._reverse, face = that._face;\n return reverse && !face || !reverse && face;\n },\n clipInHalf: function (value) {\n this._clipInHalf = value;\n return this;\n },\n temporary: function () {\n this.element.addClass('temp-page');\n return this;\n }\n });\n createEffect('staticPage', {\n directions: FOUR_DIRECTIONS,\n init: function (element, direction, container) {\n Effect.prototype.init.call(this, element, direction);\n this._container = container;\n },\n restore: ['clip'],\n prepare: function (start, end) {\n var that = this, direction = that._reverse ? directions[that._direction].reverse : that._direction;\n start.clip = clipInHalf(that._container, direction);\n start.opacity = 0.999;\n end.opacity = 1;\n },\n shouldHide: function () {\n var that = this, reverse = that._reverse, face = that._face;\n return reverse && !face || !reverse && face;\n },\n face: function (value) {\n this._face = value;\n return this;\n }\n });\n createEffect('pageturn', {\n directions: [\n 'horizontal',\n 'vertical'\n ],\n init: function (element, direction, face, back) {\n Effect.prototype.init.call(this, element, direction);\n this.options = {};\n this.options.face = face;\n this.options.back = back;\n },\n children: function () {\n var that = this, options = that.options, direction = that._direction === 'horizontal' ? 'left' : 'top', reverseDirection = kendo.directions[direction].reverse, reverse = that._reverse, temp, faceClone = options.face.clone(true).removeAttr('id'), backClone = options.back.clone(true).removeAttr('id'), element = that.element;\n if (reverse) {\n temp = direction;\n direction = reverseDirection;\n reverseDirection = temp;\n }\n return [\n kendo.fx(options.face).staticPage(direction, element).face(true).setReverse(reverse),\n kendo.fx(options.back).staticPage(reverseDirection, element).setReverse(reverse),\n kendo.fx(faceClone).turningPage(direction, element).face(true).clipInHalf(true).temporary().setReverse(reverse),\n kendo.fx(backClone).turningPage(reverseDirection, element).clipInHalf(true).temporary().setReverse(reverse)\n ];\n },\n prepare: function (start, end) {\n start[PERSPECTIVE] = DEFAULT_PERSPECTIVE;\n start.transformStyle = 'preserve-3d';\n start.opacity = 0.999;\n end.opacity = 1;\n },\n teardown: function () {\n this.element.find('.temp-page').remove();\n }\n });\n createEffect('flip', {\n directions: [\n 'horizontal',\n 'vertical'\n ],\n init: function (element, direction, face, back) {\n Effect.prototype.init.call(this, element, direction);\n this.options = {};\n this.options.face = face;\n this.options.back = back;\n },\n children: function () {\n var that = this, options = that.options, direction = that._direction === 'horizontal' ? 'left' : 'top', reverseDirection = kendo.directions[direction].reverse, reverse = that._reverse, temp, element = that.element;\n if (reverse) {\n temp = direction;\n direction = reverseDirection;\n reverseDirection = temp;\n }\n return [\n kendo.fx(options.face).turningPage(direction, element).face(true).setReverse(reverse),\n kendo.fx(options.back).turningPage(reverseDirection, element).setReverse(reverse)\n ];\n },\n prepare: function (start) {\n start[PERSPECTIVE] = DEFAULT_PERSPECTIVE;\n start.transformStyle = 'preserve-3d';\n }\n });\n var RESTORE_OVERFLOW = !support.mobileOS.android;\n var IGNORE_TRANSITION_EVENT_SELECTOR = '.km-touch-scrollbar, .km-actionsheet-wrapper';\n createEffect('replace', {\n _before: $.noop,\n _after: $.noop,\n init: function (element, previous, transitionClass) {\n Effect.prototype.init.call(this, element);\n this._previous = $(previous);\n this._transitionClass = transitionClass;\n },\n duration: function () {\n throw new Error('The replace effect does not support duration setting; the effect duration may be customized through the transition class rule');\n },\n beforeTransition: function (callback) {\n this._before = callback;\n return this;\n },\n afterTransition: function (callback) {\n this._after = callback;\n return this;\n },\n _both: function () {\n return $().add(this._element).add(this._previous);\n },\n _containerClass: function () {\n var direction = this._direction, containerClass = 'k-fx k-fx-start k-fx-' + this._transitionClass;\n if (direction) {\n containerClass += ' k-fx-' + direction;\n }\n if (this._reverse) {\n containerClass += ' k-fx-reverse';\n }\n return containerClass;\n },\n complete: function (e) {\n if (!this.deferred || e && $(e.target).is(IGNORE_TRANSITION_EVENT_SELECTOR)) {\n return;\n }\n var container = this.container;\n container.removeClass('k-fx-end').removeClass(this._containerClass()).off(transitions.event, this.completeProxy);\n this._previous.hide().removeClass('k-fx-current');\n this.element.removeClass('k-fx-next');\n if (RESTORE_OVERFLOW) {\n container.css(OVERFLOW, '');\n }\n if (!this.isAbsolute) {\n this._both().css(POSITION, '');\n }\n this.deferred.resolve();\n delete this.deferred;\n },\n run: function () {\n if (this._additionalEffects && this._additionalEffects[0]) {\n return this.compositeRun();\n }\n var that = this, element = that.element, previous = that._previous, container = element.parents().filter(previous.parents()).first(), both = that._both(), deferred = $.Deferred(), originalPosition = element.css(POSITION), originalOverflow;\n if (!container.length) {\n container = element.parent();\n }\n this.container = container;\n this.deferred = deferred;\n this.isAbsolute = originalPosition == 'absolute';\n if (!this.isAbsolute) {\n both.css(POSITION, 'absolute');\n }\n if (RESTORE_OVERFLOW) {\n originalOverflow = container.css(OVERFLOW);\n container.css(OVERFLOW, 'hidden');\n }\n if (!transitions) {\n this.complete();\n } else {\n element.addClass('k-fx-hidden');\n container.addClass(this._containerClass());\n this.completeProxy = $.proxy(this, 'complete');\n container.on(transitions.event, this.completeProxy);\n kendo.animationFrame(function () {\n element.removeClass('k-fx-hidden').addClass('k-fx-next');\n previous.css('display', '').addClass('k-fx-current');\n that._before(previous, element);\n kendo.animationFrame(function () {\n container.removeClass('k-fx-start').addClass('k-fx-end');\n that._after(previous, element);\n });\n });\n }\n return deferred.promise();\n },\n stop: function () {\n this.complete();\n }\n });\n var Animation = kendo.Class.extend({\n init: function () {\n var that = this;\n that._tickProxy = proxy(that._tick, that);\n that._started = false;\n },\n tick: $.noop,\n done: $.noop,\n onEnd: $.noop,\n onCancel: $.noop,\n start: function () {\n if (!this.enabled()) {\n return;\n }\n if (!this.done()) {\n this._started = true;\n kendo.animationFrame(this._tickProxy);\n } else {\n this.onEnd();\n }\n },\n enabled: function () {\n return true;\n },\n cancel: function () {\n this._started = false;\n this.onCancel();\n },\n _tick: function () {\n var that = this;\n if (!that._started) {\n return;\n }\n that.tick();\n if (!that.done()) {\n kendo.animationFrame(that._tickProxy);\n } else {\n that._started = false;\n that.onEnd();\n }\n }\n });\n var Transition = Animation.extend({\n init: function (options) {\n var that = this;\n extend(that, options);\n Animation.fn.init.call(that);\n },\n done: function () {\n return this.timePassed() >= this.duration;\n },\n timePassed: function () {\n return Math.min(this.duration, new Date() - this.startDate);\n },\n moveTo: function (options) {\n var that = this, movable = that.movable;\n that.initial = movable[that.axis];\n that.delta = options.location - that.initial;\n that.duration = typeof options.duration == 'number' ? options.duration : 300;\n that.tick = that._easeProxy(options.ease);\n that.startDate = new Date();\n that.start();\n },\n _easeProxy: function (ease) {\n var that = this;\n return function () {\n that.movable.moveAxis(that.axis, ease(that.timePassed(), that.initial, that.delta, that.duration));\n };\n }\n });\n extend(Transition, {\n easeOutExpo: function (t, b, c, d) {\n return t == d ? b + c : c * (-Math.pow(2, -10 * t / d) + 1) + b;\n },\n easeOutBack: function (t, b, c, d, s) {\n s = 1.70158;\n return c * ((t = t / d - 1) * t * ((s + 1) * t + s) + 1) + b;\n }\n });\n fx.Animation = Animation;\n fx.Transition = Transition;\n fx.createEffect = createEffect;\n fx.box = function (element) {\n element = $(element);\n var result = element.offset();\n result.width = kendo._outerWidth(element);\n result.height = kendo._outerHeight(element);\n return result;\n };\n fx.transformOrigin = function (inner, outer) {\n var x = (inner.left - outer.left) * outer.width / (outer.width - inner.width), y = (inner.top - outer.top) * outer.height / (outer.height - inner.height);\n return {\n x: isNaN(x) ? 0 : x,\n y: isNaN(y) ? 0 : y\n };\n };\n fx.fillScale = function (inner, outer) {\n return Math.min(inner.width / outer.width, inner.height / outer.height);\n };\n fx.fitScale = function (inner, outer) {\n return Math.max(inner.width / outer.width, inner.height / outer.height);\n };\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.data.odata', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'data.odata',\n name: 'OData',\n category: 'framework',\n depends: ['core'],\n hidden: true\n };\n (function ($, undefined) {\n var kendo = window.kendo, extend = $.extend, NEWLINE = '\\r\\n', DOUBLELINE = '\\r\\n\\r\\n', isFunction = kendo.isFunction, odataFilters = {\n eq: 'eq',\n neq: 'ne',\n gt: 'gt',\n gte: 'ge',\n lt: 'lt',\n lte: 'le',\n contains: 'substringof',\n doesnotcontain: 'substringof',\n endswith: 'endswith',\n startswith: 'startswith',\n isnull: 'eq',\n isnotnull: 'ne',\n isnullorempty: 'eq',\n isnotnullorempty: 'ne',\n isempty: 'eq',\n isnotempty: 'ne'\n }, odataFiltersVersionFour = extend({}, odataFilters, { contains: 'contains' }), mappers = {\n pageSize: $.noop,\n page: $.noop,\n filter: function (params, filter, useVersionFour) {\n if (filter) {\n filter = toOdataFilter(filter, useVersionFour);\n if (filter) {\n params.$filter = filter;\n }\n }\n },\n sort: function (params, orderby) {\n var expr = $.map(orderby, function (value) {\n var order = value.field.replace(/\\./g, '/');\n if (value.dir === 'desc') {\n order += ' desc';\n }\n return order;\n }).join(',');\n if (expr) {\n params.$orderby = expr;\n }\n },\n skip: function (params, skip) {\n if (skip) {\n params.$skip = skip;\n }\n },\n take: function (params, take) {\n if (take) {\n params.$top = take;\n }\n }\n }, defaultDataType = { read: { dataType: 'jsonp' } };\n function toOdataFilter(filter, useOdataFour) {\n var result = [], logic = filter.logic || 'and', idx, length, field, type, format, operator, value, ignoreCase, filters = filter.filters;\n for (idx = 0, length = filters.length; idx < length; idx++) {\n filter = filters[idx];\n field = filter.field;\n value = filter.value;\n operator = filter.operator;\n if (filter.filters) {\n filter = toOdataFilter(filter, useOdataFour);\n } else {\n ignoreCase = filter.ignoreCase;\n field = field.replace(/\\./g, '/');\n filter = odataFilters[operator];\n if (useOdataFour) {\n filter = odataFiltersVersionFour[operator];\n }\n if (operator === 'isnullorempty') {\n filter = kendo.format('{0} {1} null or {0} {1} \\'\\'', field, filter);\n } else if (operator === 'isnotnullorempty') {\n filter = kendo.format('{0} {1} null and {0} {1} \\'\\'', field, filter);\n } else if (operator === 'isnull' || operator === 'isnotnull') {\n filter = kendo.format('{0} {1} null', field, filter);\n } else if (operator === 'isempty' || operator === 'isnotempty') {\n filter = kendo.format('{0} {1} \\'\\'', field, filter);\n } else if (filter && value !== undefined) {\n type = $.type(value);\n if (type === 'string') {\n format = '\\'{1}\\'';\n value = value.replace(/'/g, '\\'\\'');\n if (ignoreCase === true) {\n field = 'tolower(' + field + ')';\n }\n } else if (type === 'date') {\n if (useOdataFour) {\n format = '{1:yyyy-MM-ddTHH:mm:ss+00:00}';\n value = kendo.timezone.apply(value, 'Etc/UTC');\n } else {\n format = 'datetime\\'{1:yyyy-MM-ddTHH:mm:ss}\\'';\n }\n } else {\n format = '{1}';\n }\n if (filter.length > 3) {\n if (filter !== 'substringof') {\n format = '{0}({2},' + format + ')';\n } else {\n format = '{0}(' + format + ',{2})';\n if (operator === 'doesnotcontain') {\n if (useOdataFour) {\n format = '{0}({2},\\'{1}\\') eq -1';\n filter = 'indexof';\n } else {\n format += ' eq false';\n }\n }\n }\n } else {\n format = '{2} {0} ' + format;\n }\n filter = kendo.format(format, filter, value, field);\n }\n }\n result.push(filter);\n }\n filter = result.join(' ' + logic + ' ');\n if (result.length > 1) {\n filter = '(' + filter + ')';\n }\n return filter;\n }\n function stripMetadata(obj) {\n for (var name in obj) {\n if (name.indexOf('@odata') === 0) {\n delete obj[name];\n }\n }\n }\n function hex16() {\n return Math.floor((1 + Math.random()) * 65536).toString(16).substr(1);\n }\n function createBoundary(prefix) {\n return prefix + hex16() + '-' + hex16() + '-' + hex16();\n }\n function createDelimeter(boundary, close) {\n var result = NEWLINE + '--' + boundary;\n if (close) {\n result += '--';\n }\n return result;\n }\n function createCommand(transport, item, httpVerb, command) {\n var transportUrl = transport.options[command].url;\n var commandPrefix = kendo.format('{0} ', httpVerb);\n if (isFunction(transportUrl)) {\n return commandPrefix + transportUrl(item);\n } else {\n return commandPrefix + transportUrl;\n }\n }\n function getOperationHeader(changeset, changeId) {\n var header = '';\n header += createDelimeter(changeset, false);\n header += NEWLINE + 'Content-Type: application/http';\n header += NEWLINE + 'Content-Transfer-Encoding: binary';\n header += NEWLINE + 'Content-ID: ' + changeId;\n return header;\n }\n function getOperationContent(item) {\n var content = '';\n content += NEWLINE + 'Content-Type: application/json;odata=minimalmetadata';\n content += NEWLINE + 'Prefer: return=representation';\n content += DOUBLELINE + kendo.stringify(item);\n return content;\n }\n function getOperations(collection, changeset, changeId, command, transport, skipContent) {\n var requestBody = '';\n for (var i = 0; i < collection.length; i++) {\n requestBody += getOperationHeader(changeset, changeId);\n requestBody += DOUBLELINE + createCommand(transport, collection[i], transport.options[command].type, command) + ' HTTP/1.1';\n if (!skipContent) {\n requestBody += getOperationContent(collection[i]);\n }\n requestBody += NEWLINE;\n changeId++;\n }\n return requestBody;\n }\n function processCollection(colection, boundary, changeset, changeId, transport, command, skipContent) {\n var requestBody = '';\n requestBody += getBoundary(boundary, changeset);\n requestBody += getOperations(colection, changeset, changeId, command, transport, skipContent);\n requestBody += createDelimeter(changeset, true);\n requestBody += NEWLINE;\n return requestBody;\n }\n function getBoundary(boundary, changeset) {\n var requestBody = '';\n requestBody += '--' + boundary + NEWLINE;\n requestBody += 'Content-Type: multipart/mixed; boundary=' + changeset + NEWLINE;\n return requestBody;\n }\n function createBatchRequest(transport, colections) {\n var options = {};\n var boundary = createBoundary('sf_batch_');\n var requestBody = '';\n var changeId = 0;\n var batchURL = transport.options.batch.url;\n var changeset = createBoundary('sf_changeset_');\n options.type = transport.options.batch.type;\n options.url = isFunction(batchURL) ? batchURL() : batchURL;\n options.headers = { 'Content-Type': 'multipart/mixed; boundary=' + boundary };\n if (colections.updated.length) {\n requestBody += processCollection(colections.updated, boundary, changeset, changeId, transport, 'update', false);\n changeId += colections.updated.length;\n changeset = createBoundary('sf_changeset_');\n }\n if (colections.destroyed.length) {\n requestBody += processCollection(colections.destroyed, boundary, changeset, changeId, transport, 'destroy', true);\n changeId += colections.destroyed.length;\n changeset = createBoundary('sf_changeset_');\n }\n if (colections.created.length) {\n requestBody += processCollection(colections.created, boundary, changeset, changeId, transport, 'create', false);\n }\n requestBody += createDelimeter(boundary, true);\n options.data = requestBody;\n return options;\n }\n function parseBatchResponse(responseText) {\n var responseMarkers = responseText.match(/--changesetresponse_[a-z0-9-]+$/gm);\n var markerIndex = 0;\n var collections = [];\n var changeBody;\n var status;\n var code;\n var marker;\n var jsonModel;\n collections.push({\n models: [],\n passed: true\n });\n for (var i = 0; i < responseMarkers.length; i++) {\n marker = responseMarkers[i];\n if (marker.lastIndexOf('--', marker.length - 1)) {\n if (i < responseMarkers.length - 1) {\n collections.push({\n models: [],\n passed: true\n });\n }\n continue;\n }\n if (!markerIndex) {\n markerIndex = responseText.indexOf(marker);\n } else {\n markerIndex = responseText.indexOf(marker, markerIndex + marker.length);\n }\n changeBody = responseText.substring(markerIndex, responseText.indexOf('--', markerIndex + 1));\n status = changeBody.match(/^HTTP\\/1\\.\\d (\\d{3}) (.*)$/gm).pop();\n code = kendo.parseFloat(status.match(/\\d{3}/g).pop());\n if (code >= 200 && code <= 299) {\n jsonModel = changeBody.match(/\\{.*\\}/gm);\n if (jsonModel) {\n collections[collections.length - 1].models.push(JSON.parse(jsonModel[0]));\n }\n } else {\n collections[collections.length - 1].passed = false;\n }\n }\n return collections;\n }\n extend(true, kendo.data, {\n schemas: {\n odata: {\n type: 'json',\n data: function (data) {\n return data.d.results || [data.d];\n },\n total: 'd.__count'\n }\n },\n transports: {\n odata: {\n read: {\n cache: true,\n dataType: 'jsonp',\n jsonp: '$callback'\n },\n update: {\n cache: true,\n dataType: 'json',\n contentType: 'application/json',\n type: 'PUT'\n },\n create: {\n cache: true,\n dataType: 'json',\n contentType: 'application/json',\n type: 'POST'\n },\n destroy: {\n cache: true,\n dataType: 'json',\n type: 'DELETE'\n },\n parameterMap: function (options, type, useVersionFour) {\n var params, value, option, dataType;\n options = options || {};\n type = type || 'read';\n dataType = (this.options || defaultDataType)[type];\n dataType = dataType ? dataType.dataType : 'json';\n if (type === 'read') {\n params = { $inlinecount: 'allpages' };\n if (dataType != 'json') {\n params.$format = 'json';\n }\n for (option in options) {\n if (mappers[option]) {\n mappers[option](params, options[option], useVersionFour);\n } else {\n params[option] = options[option];\n }\n }\n } else {\n if (dataType !== 'json') {\n throw new Error('Only json dataType can be used for ' + type + ' operation.');\n }\n if (type !== 'destroy') {\n for (option in options) {\n value = options[option];\n if (typeof value === 'number') {\n options[option] = value + '';\n }\n }\n params = kendo.stringify(options);\n }\n }\n return params;\n }\n }\n }\n });\n extend(true, kendo.data, {\n schemas: {\n 'odata-v4': {\n type: 'json',\n data: function (data) {\n if ($.isArray(data)) {\n for (var i = 0; i < data.length; i++) {\n stripMetadata(data[i]);\n }\n return data;\n } else {\n data = $.extend({}, data);\n stripMetadata(data);\n if (data.value) {\n return data.value;\n }\n return [data];\n }\n },\n total: function (data) {\n return data['@odata.count'];\n }\n }\n },\n transports: {\n 'odata-v4': {\n batch: { type: 'POST' },\n read: {\n cache: true,\n dataType: 'json'\n },\n update: {\n cache: true,\n dataType: 'json',\n contentType: 'application/json;IEEE754Compatible=true',\n type: 'PUT'\n },\n create: {\n cache: true,\n dataType: 'json',\n contentType: 'application/json;IEEE754Compatible=true',\n type: 'POST'\n },\n destroy: {\n cache: true,\n dataType: 'json',\n type: 'DELETE'\n },\n parameterMap: function (options, type) {\n var result = kendo.data.transports.odata.parameterMap(options, type, true);\n if (type == 'read') {\n result.$count = true;\n delete result.$inlinecount;\n }\n return result;\n },\n submit: function (e) {\n var that = this;\n var options = createBatchRequest(that, e.data);\n var collections = e.data;\n if (!collections.updated.length && !collections.destroyed.length && !collections.created.length) {\n return;\n }\n $.ajax(extend(true, {}, {\n success: function (response) {\n var responses = parseBatchResponse(response);\n var index = 0;\n var current;\n if (collections.updated.length) {\n current = responses[index];\n if (current.passed) {\n e.success(current.models.length ? current.models : [], 'update');\n }\n index++;\n }\n if (collections.destroyed.length) {\n current = responses[index];\n if (current.passed) {\n e.success([], 'destroy');\n }\n index++;\n }\n if (collections.created.length) {\n current = responses[index];\n if (current.passed) {\n e.success(current.models, 'create');\n }\n }\n },\n error: function (response, status, error) {\n e.error(response, status, error);\n }\n }, options));\n }\n }\n }\n });\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.data.xml', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'data.xml',\n name: 'XML',\n category: 'framework',\n depends: ['core'],\n hidden: true\n };\n (function ($, undefined) {\n var kendo = window.kendo, isArray = $.isArray, isPlainObject = $.isPlainObject, map = $.map, each = $.each, extend = $.extend, getter = kendo.getter, Class = kendo.Class;\n var XmlDataReader = Class.extend({\n init: function (options) {\n var that = this, total = options.total, model = options.model, parse = options.parse, errors = options.errors, serialize = options.serialize, data = options.data;\n if (model) {\n if (isPlainObject(model)) {\n var base = options.modelBase || kendo.data.Model;\n if (model.fields) {\n each(model.fields, function (field, value) {\n if (isPlainObject(value) && value.field) {\n if (!$.isFunction(value.field)) {\n value = extend(value, { field: that.getter(value.field) });\n }\n } else {\n value = { field: that.getter(value) };\n }\n model.fields[field] = value;\n });\n }\n var id = model.id;\n if (id) {\n var idField = {};\n idField[that.xpathToMember(id, true)] = { field: that.getter(id) };\n model.fields = extend(idField, model.fields);\n model.id = that.xpathToMember(id);\n }\n model = base.define(model);\n }\n that.model = model;\n }\n if (total) {\n if (typeof total == 'string') {\n total = that.getter(total);\n that.total = function (data) {\n return parseInt(total(data), 10);\n };\n } else if (typeof total == 'function') {\n that.total = total;\n }\n }\n if (errors) {\n if (typeof errors == 'string') {\n errors = that.getter(errors);\n that.errors = function (data) {\n return errors(data) || null;\n };\n } else if (typeof errors == 'function') {\n that.errors = errors;\n }\n }\n if (data) {\n if (typeof data == 'string') {\n data = that.xpathToMember(data);\n that.data = function (value) {\n var result = that.evaluate(value, data), modelInstance;\n result = isArray(result) ? result : [result];\n if (that.model && model.fields) {\n modelInstance = new that.model();\n return map(result, function (value) {\n if (value) {\n var record = {}, field;\n for (field in model.fields) {\n record[field] = modelInstance._parse(field, model.fields[field].field(value));\n }\n return record;\n }\n });\n }\n return result;\n };\n } else if (typeof data == 'function') {\n that.data = data;\n }\n }\n if (typeof parse == 'function') {\n var xmlParse = that.parse;\n that.parse = function (data) {\n var xml = parse.call(that, data);\n return xmlParse.call(that, xml);\n };\n }\n if (typeof serialize == 'function') {\n that.serialize = serialize;\n }\n },\n total: function (result) {\n return this.data(result).length;\n },\n errors: function (data) {\n return data ? data.errors : null;\n },\n serialize: function (data) {\n return data;\n },\n parseDOM: function (element) {\n var result = {}, parsedNode, node, nodeType, nodeName, member, attribute, attributes = element.attributes, attributeCount = attributes.length, idx;\n for (idx = 0; idx < attributeCount; idx++) {\n attribute = attributes[idx];\n result['@' + attribute.nodeName] = attribute.nodeValue;\n }\n for (node = element.firstChild; node; node = node.nextSibling) {\n nodeType = node.nodeType;\n if (nodeType === 3 || nodeType === 4) {\n result['#text'] = node.nodeValue;\n } else if (nodeType === 1) {\n parsedNode = this.parseDOM(node);\n nodeName = node.nodeName;\n member = result[nodeName];\n if (isArray(member)) {\n member.push(parsedNode);\n } else if (member !== undefined) {\n member = [\n member,\n parsedNode\n ];\n } else {\n member = parsedNode;\n }\n result[nodeName] = member;\n }\n }\n return result;\n },\n evaluate: function (value, expression) {\n var members = expression.split('.'), member, result, length, intermediateResult, idx;\n while (member = members.shift()) {\n value = value[member];\n if (isArray(value)) {\n result = [];\n expression = members.join('.');\n for (idx = 0, length = value.length; idx < length; idx++) {\n intermediateResult = this.evaluate(value[idx], expression);\n intermediateResult = isArray(intermediateResult) ? intermediateResult : [intermediateResult];\n result.push.apply(result, intermediateResult);\n }\n return result;\n }\n }\n return value;\n },\n parse: function (xml) {\n var documentElement, tree, result = {};\n documentElement = xml.documentElement || $.parseXML(xml).documentElement;\n tree = this.parseDOM(documentElement);\n result[documentElement.nodeName] = tree;\n return result;\n },\n xpathToMember: function (member, raw) {\n if (!member) {\n return '';\n }\n member = member.replace(/^\\//, '').replace(/\\//g, '.');\n if (member.indexOf('@') >= 0) {\n return member.replace(/\\.?(@.*)/, raw ? '$1' : '[\"$1\"]');\n }\n if (member.indexOf('text()') >= 0) {\n return member.replace(/(\\.?text\\(\\))/, raw ? '#text' : '[\"#text\"]');\n }\n return member;\n },\n getter: function (member) {\n return getter(this.xpathToMember(member), true);\n }\n });\n $.extend(true, kendo.data, {\n XmlDataReader: XmlDataReader,\n readers: { xml: XmlDataReader }\n });\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.data', [\n 'kendo.core',\n 'kendo.data.odata',\n 'kendo.data.xml'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'data',\n name: 'Data source',\n category: 'framework',\n description: 'Powerful component for using local and remote data.Fully supports CRUD, Sorting, Paging, Filtering, Grouping, and Aggregates.',\n depends: ['core'],\n features: [\n {\n id: 'data-odata',\n name: 'OData',\n description: 'Support for accessing Open Data Protocol (OData) services.',\n depends: ['data.odata']\n },\n {\n id: 'data-signalr',\n name: 'SignalR',\n description: 'Support for binding to SignalR hubs.',\n depends: ['data.signalr']\n },\n {\n id: 'data-XML',\n name: 'XML',\n description: 'Support for binding to XML.',\n depends: ['data.xml']\n }\n ]\n };\n (function ($, undefined) {\n var extend = $.extend, proxy = $.proxy, isPlainObject = $.isPlainObject, isEmptyObject = $.isEmptyObject, isArray = $.isArray, grep = $.grep, ajax = $.ajax, map, each = $.each, noop = $.noop, kendo = window.kendo, isFunction = kendo.isFunction, Observable = kendo.Observable, Class = kendo.Class, STRING = 'string', FUNCTION = 'function', ASCENDING = 'asc', CREATE = 'create', READ = 'read', UPDATE = 'update', DESTROY = 'destroy', CHANGE = 'change', SYNC = 'sync', GET = 'get', ERROR = 'error', REQUESTSTART = 'requestStart', PROGRESS = 'progress', REQUESTEND = 'requestEnd', crud = [\n CREATE,\n READ,\n UPDATE,\n DESTROY\n ], identity = function (o) {\n return o;\n }, getter = kendo.getter, stringify = kendo.stringify, math = Math, push = [].push, join = [].join, pop = [].pop, splice = [].splice, shift = [].shift, slice = [].slice, unshift = [].unshift, toString = {}.toString, stableSort = kendo.support.stableSort, dateRegExp = /^\\/Date\\((.*?)\\)\\/$/;\n var ObservableArray = Observable.extend({\n init: function (array, type) {\n var that = this;\n that.type = type || ObservableObject;\n Observable.fn.init.call(that);\n that.length = array.length;\n that.wrapAll(array, that);\n },\n at: function (index) {\n return this[index];\n },\n toJSON: function (serializeFunctions) {\n var idx, length = this.length, value, json = new Array(length);\n for (idx = 0; idx < length; idx++) {\n value = this[idx];\n if (value instanceof ObservableObject) {\n value = value.toJSON(serializeFunctions);\n }\n json[idx] = value;\n }\n return json;\n },\n parent: noop,\n wrapAll: function (source, target) {\n var that = this, idx, length, parent = function () {\n return that;\n };\n target = target || [];\n for (idx = 0, length = source.length; idx < length; idx++) {\n target[idx] = that.wrap(source[idx], parent);\n }\n return target;\n },\n wrap: function (object, parent) {\n var that = this, observable;\n if (object !== null && toString.call(object) === '[object Object]') {\n observable = object instanceof that.type || object instanceof Model;\n if (!observable) {\n object = object instanceof ObservableObject ? object.toJSON() : object;\n object = new that.type(object);\n }\n object.parent = parent;\n object.bind(CHANGE, function (e) {\n that.trigger(CHANGE, {\n field: e.field,\n node: e.node,\n index: e.index,\n items: e.items || [this],\n action: e.node ? e.action || 'itemloaded' : 'itemchange'\n });\n });\n }\n return object;\n },\n push: function () {\n var index = this.length, items = this.wrapAll(arguments), result;\n result = push.apply(this, items);\n if (!this.omitChangeEvent) {\n this.trigger(CHANGE, {\n action: 'add',\n index: index,\n items: items\n });\n }\n return result;\n },\n slice: slice,\n sort: [].sort,\n join: join,\n pop: function () {\n var length = this.length, result = pop.apply(this);\n if (length) {\n this.trigger(CHANGE, {\n action: 'remove',\n index: length - 1,\n items: [result]\n });\n }\n return result;\n },\n splice: function (index, howMany, item) {\n var items = this.wrapAll(slice.call(arguments, 2)), result, i, len;\n result = splice.apply(this, [\n index,\n howMany\n ].concat(items));\n if (result.length) {\n this.trigger(CHANGE, {\n action: 'remove',\n index: index,\n items: result\n });\n for (i = 0, len = result.length; i < len; i++) {\n if (result[i] && result[i].children) {\n result[i].unbind(CHANGE);\n }\n }\n }\n if (item) {\n this.trigger(CHANGE, {\n action: 'add',\n index: index,\n items: items\n });\n }\n return result;\n },\n shift: function () {\n var length = this.length, result = shift.apply(this);\n if (length) {\n this.trigger(CHANGE, {\n action: 'remove',\n index: 0,\n items: [result]\n });\n }\n return result;\n },\n unshift: function () {\n var items = this.wrapAll(arguments), result;\n result = unshift.apply(this, items);\n this.trigger(CHANGE, {\n action: 'add',\n index: 0,\n items: items\n });\n return result;\n },\n indexOf: function (item) {\n var that = this, idx, length;\n for (idx = 0, length = that.length; idx < length; idx++) {\n if (that[idx] === item) {\n return idx;\n }\n }\n return -1;\n },\n forEach: function (callback, thisArg) {\n var idx = 0;\n var length = this.length;\n var context = thisArg || window;\n for (; idx < length; idx++) {\n callback.call(context, this[idx], idx, this);\n }\n },\n map: function (callback, thisArg) {\n var idx = 0;\n var result = [];\n var length = this.length;\n var context = thisArg || window;\n for (; idx < length; idx++) {\n result[idx] = callback.call(context, this[idx], idx, this);\n }\n return result;\n },\n reduce: function (callback) {\n var idx = 0, result, length = this.length;\n if (arguments.length == 2) {\n result = arguments[1];\n } else if (idx < length) {\n result = this[idx++];\n }\n for (; idx < length; idx++) {\n result = callback(result, this[idx], idx, this);\n }\n return result;\n },\n reduceRight: function (callback) {\n var idx = this.length - 1, result;\n if (arguments.length == 2) {\n result = arguments[1];\n } else if (idx > 0) {\n result = this[idx--];\n }\n for (; idx >= 0; idx--) {\n result = callback(result, this[idx], idx, this);\n }\n return result;\n },\n filter: function (callback, thisArg) {\n var idx = 0;\n var result = [];\n var item;\n var length = this.length;\n var context = thisArg || window;\n for (; idx < length; idx++) {\n item = this[idx];\n if (callback.call(context, item, idx, this)) {\n result[result.length] = item;\n }\n }\n return result;\n },\n find: function (callback, thisArg) {\n var idx = 0;\n var item;\n var length = this.length;\n var context = thisArg || window;\n for (; idx < length; idx++) {\n item = this[idx];\n if (callback.call(context, item, idx, this)) {\n return item;\n }\n }\n },\n every: function (callback, thisArg) {\n var idx = 0;\n var item;\n var length = this.length;\n var context = thisArg || window;\n for (; idx < length; idx++) {\n item = this[idx];\n if (!callback.call(context, item, idx, this)) {\n return false;\n }\n }\n return true;\n },\n some: function (callback, thisArg) {\n var idx = 0;\n var item;\n var length = this.length;\n var context = thisArg || window;\n for (; idx < length; idx++) {\n item = this[idx];\n if (callback.call(context, item, idx, this)) {\n return true;\n }\n }\n return false;\n },\n remove: function (item) {\n var idx = this.indexOf(item);\n if (idx !== -1) {\n this.splice(idx, 1);\n }\n },\n empty: function () {\n this.splice(0, this.length);\n }\n });\n if (typeof Symbol !== 'undefined' && Symbol.iterator && !ObservableArray.prototype[Symbol.iterator]) {\n ObservableArray.prototype[Symbol.iterator] = [][Symbol.iterator];\n }\n var LazyObservableArray = ObservableArray.extend({\n init: function (data, type, events) {\n Observable.fn.init.call(this);\n this.type = type || ObservableObject;\n if (events) {\n this._events = events;\n }\n for (var idx = 0; idx < data.length; idx++) {\n this[idx] = data[idx];\n }\n this.length = idx;\n this._parent = proxy(function () {\n return this;\n }, this);\n },\n at: function (index) {\n var item = this[index];\n if (!(item instanceof this.type)) {\n item = this[index] = this.wrap(item, this._parent);\n } else {\n item.parent = this._parent;\n }\n return item;\n }\n });\n function eventHandler(context, type, field, prefix) {\n return function (e) {\n var event = {}, key;\n for (key in e) {\n event[key] = e[key];\n }\n if (prefix) {\n event.field = field + '.' + e.field;\n } else {\n event.field = field;\n }\n if (type == CHANGE && context._notifyChange) {\n context._notifyChange(event);\n }\n context.trigger(type, event);\n };\n }\n var ObservableObject = Observable.extend({\n init: function (value) {\n var that = this, member, field, parent = function () {\n return that;\n };\n Observable.fn.init.call(this);\n this._handlers = {};\n for (field in value) {\n member = value[field];\n if (typeof member === 'object' && member && !member.getTime && field.charAt(0) != '_') {\n member = that.wrap(member, field, parent);\n }\n that[field] = member;\n }\n that.uid = kendo.guid();\n },\n shouldSerialize: function (field, serializeFunctions) {\n return this.hasOwnProperty(field) && field !== '_handlers' && field !== '_events' && (serializeFunctions && serializeFunctions[field] || typeof this[field] !== FUNCTION) && field !== 'uid';\n },\n forEach: function (f) {\n for (var i in this) {\n if (this.shouldSerialize(i)) {\n f(this[i], i);\n }\n }\n },\n toJSON: function (serializeFunctions) {\n var result = {}, value, field;\n for (field in this) {\n if (this.shouldSerialize(field, serializeFunctions)) {\n value = this[field];\n if (value instanceof ObservableObject || value instanceof ObservableArray) {\n value = value.toJSON(serializeFunctions);\n }\n result[field] = value;\n }\n }\n return result;\n },\n get: function (field) {\n var that = this, result;\n that.trigger(GET, { field: field });\n if (field === 'this') {\n result = that;\n } else {\n result = kendo.getter(field, true)(that);\n }\n return result;\n },\n _set: function (field, value) {\n var that = this;\n var composite = field.indexOf('.') >= 0;\n if (composite) {\n var paths = field.split('.'), path = '';\n while (paths.length > 1) {\n path += paths.shift();\n var obj = kendo.getter(path, true)(that);\n if (obj instanceof ObservableObject) {\n obj.set(paths.join('.'), value);\n return composite;\n }\n path += '.';\n }\n }\n kendo.setter(field)(that, value);\n return composite;\n },\n set: function (field, value) {\n var that = this, isSetPrevented = false, composite = field.indexOf('.') >= 0, current = kendo.getter(field, true)(that);\n if (current !== value) {\n if (current instanceof Observable && this._handlers[field]) {\n if (this._handlers[field].get) {\n current.unbind(GET, this._handlers[field].get);\n }\n current.unbind(CHANGE, this._handlers[field].change);\n }\n isSetPrevented = that.trigger('set', {\n field: field,\n value: value\n });\n if (!isSetPrevented) {\n if (!composite) {\n value = that.wrap(value, field, function () {\n return that;\n });\n }\n if (!that._set(field, value) || field.indexOf('(') >= 0 || field.indexOf('[') >= 0) {\n that.trigger(CHANGE, { field: field });\n }\n }\n }\n return isSetPrevented;\n },\n parent: noop,\n wrap: function (object, field, parent) {\n var that = this;\n var get;\n var change;\n var type = toString.call(object);\n if (object != null && (type === '[object Object]' || type === '[object Array]')) {\n var isObservableArray = object instanceof ObservableArray;\n var isDataSource = object instanceof DataSource;\n if (type === '[object Object]' && !isDataSource && !isObservableArray) {\n if (!(object instanceof ObservableObject)) {\n object = new ObservableObject(object);\n }\n get = eventHandler(that, GET, field, true);\n object.bind(GET, get);\n change = eventHandler(that, CHANGE, field, true);\n object.bind(CHANGE, change);\n that._handlers[field] = {\n get: get,\n change: change\n };\n } else if (type === '[object Array]' || isObservableArray || isDataSource) {\n if (!isObservableArray && !isDataSource) {\n object = new ObservableArray(object);\n }\n change = eventHandler(that, CHANGE, field, false);\n object.bind(CHANGE, change);\n that._handlers[field] = { change: change };\n }\n object.parent = parent;\n }\n return object;\n }\n });\n function equal(x, y) {\n if (x === y) {\n return true;\n }\n var xtype = $.type(x), ytype = $.type(y), field;\n if (xtype !== ytype) {\n return false;\n }\n if (xtype === 'date') {\n return x.getTime() === y.getTime();\n }\n if (xtype !== 'object' && xtype !== 'array') {\n return false;\n }\n for (field in x) {\n if (!equal(x[field], y[field])) {\n return false;\n }\n }\n return true;\n }\n var parsers = {\n 'number': function (value) {\n if (typeof value === STRING && value.toLowerCase() === 'null') {\n return null;\n }\n return kendo.parseFloat(value);\n },\n 'date': function (value) {\n if (typeof value === STRING && value.toLowerCase() === 'null') {\n return null;\n }\n return kendo.parseDate(value);\n },\n 'boolean': function (value) {\n if (typeof value === STRING) {\n if (value.toLowerCase() === 'null') {\n return null;\n } else {\n return value.toLowerCase() === 'true';\n }\n }\n return value != null ? !!value : value;\n },\n 'string': function (value) {\n if (typeof value === STRING && value.toLowerCase() === 'null') {\n return null;\n }\n return value != null ? value + '' : value;\n },\n 'default': function (value) {\n return value;\n }\n };\n var defaultValues = {\n 'string': '',\n 'number': 0,\n 'date': new Date(),\n 'boolean': false,\n 'default': ''\n };\n function getFieldByName(obj, name) {\n var field, fieldName;\n for (fieldName in obj) {\n field = obj[fieldName];\n if (isPlainObject(field) && field.field && field.field === name) {\n return field;\n } else if (field === name) {\n return field;\n }\n }\n return null;\n }\n var Model = ObservableObject.extend({\n init: function (data) {\n var that = this;\n if (!data || $.isEmptyObject(data)) {\n data = $.extend({}, that.defaults, data);\n if (that._initializers) {\n for (var idx = 0; idx < that._initializers.length; idx++) {\n var name = that._initializers[idx];\n data[name] = that.defaults[name]();\n }\n }\n }\n ObservableObject.fn.init.call(that, data);\n that.dirty = false;\n that.dirtyFields = {};\n if (that.idField) {\n that.id = that.get(that.idField);\n if (that.id === undefined) {\n that.id = that._defaultId;\n }\n }\n },\n shouldSerialize: function (field) {\n return ObservableObject.fn.shouldSerialize.call(this, field) && field !== 'uid' && !(this.idField !== 'id' && field === 'id') && field !== 'dirty' && field !== 'dirtyFields' && field !== '_accessors';\n },\n _parse: function (field, value) {\n var that = this, fieldName = field, fields = that.fields || {}, parse;\n field = fields[field];\n if (!field) {\n field = getFieldByName(fields, fieldName);\n }\n if (field) {\n parse = field.parse;\n if (!parse && field.type) {\n parse = parsers[field.type.toLowerCase()];\n }\n }\n return parse ? parse(value) : value;\n },\n _notifyChange: function (e) {\n var action = e.action;\n if (action == 'add' || action == 'remove') {\n this.dirty = true;\n this.dirtyFields[e.field] = true;\n }\n },\n editable: function (field) {\n field = (this.fields || {})[field];\n return field ? field.editable !== false : true;\n },\n set: function (field, value) {\n var that = this;\n var dirty = that.dirty;\n if (that.editable(field)) {\n value = that._parse(field, value);\n if (!equal(value, that.get(field))) {\n that.dirty = true;\n that.dirtyFields[field] = true;\n if (ObservableObject.fn.set.call(that, field, value) && !dirty) {\n that.dirty = dirty;\n if (!that.dirty) {\n that.dirtyFields[field] = false;\n }\n }\n } else {\n that.trigger('equalSet', {\n field: field,\n value: value\n });\n }\n }\n },\n accept: function (data) {\n var that = this, parent = function () {\n return that;\n }, field;\n for (field in data) {\n var value = data[field];\n if (field.charAt(0) != '_') {\n value = that.wrap(data[field], field, parent);\n }\n that._set(field, value);\n }\n if (that.idField) {\n that.id = that.get(that.idField);\n }\n that.dirty = false;\n that.dirtyFields = {};\n },\n isNew: function () {\n return this.id === this._defaultId;\n }\n });\n Model.define = function (base, options) {\n if (options === undefined) {\n options = base;\n base = Model;\n }\n var model, proto = extend({ defaults: {} }, options), name, field, type, value, idx, length, fields = {}, originalName, id = proto.id, functionFields = [];\n if (id) {\n proto.idField = id;\n }\n if (proto.id) {\n delete proto.id;\n }\n if (id) {\n proto.defaults[id] = proto._defaultId = '';\n }\n if (toString.call(proto.fields) === '[object Array]') {\n for (idx = 0, length = proto.fields.length; idx < length; idx++) {\n field = proto.fields[idx];\n if (typeof field === STRING) {\n fields[field] = {};\n } else if (field.field) {\n fields[field.field] = field;\n }\n }\n proto.fields = fields;\n }\n for (name in proto.fields) {\n field = proto.fields[name];\n type = field.type || 'default';\n value = null;\n originalName = name;\n name = typeof field.field === STRING ? field.field : name;\n if (!field.nullable) {\n value = proto.defaults[originalName !== name ? originalName : name] = field.defaultValue !== undefined ? field.defaultValue : defaultValues[type.toLowerCase()];\n if (typeof value === 'function') {\n functionFields.push(name);\n }\n }\n if (options.id === name) {\n proto._defaultId = value;\n }\n proto.defaults[originalName !== name ? originalName : name] = value;\n field.parse = field.parse || parsers[type];\n }\n if (functionFields.length > 0) {\n proto._initializers = functionFields;\n }\n model = base.extend(proto);\n model.define = function (options) {\n return Model.define(model, options);\n };\n if (proto.fields) {\n model.fields = proto.fields;\n model.idField = proto.idField;\n }\n return model;\n };\n var Comparer = {\n selector: function (field) {\n return isFunction(field) ? field : getter(field);\n },\n compare: function (field) {\n var selector = this.selector(field);\n return function (a, b) {\n a = selector(a);\n b = selector(b);\n if (a == null && b == null) {\n return 0;\n }\n if (a == null) {\n return -1;\n }\n if (b == null) {\n return 1;\n }\n if (a.localeCompare) {\n return a.localeCompare(b);\n }\n return a > b ? 1 : a < b ? -1 : 0;\n };\n },\n create: function (sort) {\n var compare = sort.compare || this.compare(sort.field);\n if (sort.dir == 'desc') {\n return function (a, b) {\n return compare(b, a, true);\n };\n }\n return compare;\n },\n combine: function (comparers) {\n return function (a, b) {\n var result = comparers[0](a, b), idx, length;\n for (idx = 1, length = comparers.length; idx < length; idx++) {\n result = result || comparers[idx](a, b);\n }\n return result;\n };\n }\n };\n var StableComparer = extend({}, Comparer, {\n asc: function (field) {\n var selector = this.selector(field);\n return function (a, b) {\n var valueA = selector(a);\n var valueB = selector(b);\n if (valueA && valueA.getTime && valueB && valueB.getTime) {\n valueA = valueA.getTime();\n valueB = valueB.getTime();\n }\n if (valueA === valueB) {\n return a.__position - b.__position;\n }\n if (valueA == null) {\n return -1;\n }\n if (valueB == null) {\n return 1;\n }\n if (valueA.localeCompare) {\n return valueA.localeCompare(valueB);\n }\n return valueA > valueB ? 1 : -1;\n };\n },\n desc: function (field) {\n var selector = this.selector(field);\n return function (a, b) {\n var valueA = selector(a);\n var valueB = selector(b);\n if (valueA && valueA.getTime && valueB && valueB.getTime) {\n valueA = valueA.getTime();\n valueB = valueB.getTime();\n }\n if (valueA === valueB) {\n return a.__position - b.__position;\n }\n if (valueA == null) {\n return 1;\n }\n if (valueB == null) {\n return -1;\n }\n if (valueB.localeCompare) {\n return valueB.localeCompare(valueA);\n }\n return valueA < valueB ? 1 : -1;\n };\n },\n create: function (sort) {\n return this[sort.dir](sort.field);\n }\n });\n map = function (array, callback) {\n var idx, length = array.length, result = new Array(length);\n for (idx = 0; idx < length; idx++) {\n result[idx] = callback(array[idx], idx, array);\n }\n return result;\n };\n var operators = function () {\n function quote(str) {\n if (typeof str == 'string') {\n str = str.replace(/[\\r\\n]+/g, '');\n }\n return JSON.stringify(str);\n }\n function textOp(impl) {\n return function (a, b, ignore, accentFoldingFiltering) {\n b += '';\n if (ignore) {\n a = '(' + a + ' + \\'\\').toString()' + (accentFoldingFiltering ? '.toLocaleLowerCase(\\'' + accentFoldingFiltering + '\\')' : '.toLowerCase()');\n b = accentFoldingFiltering ? b.toLocaleLowerCase(accentFoldingFiltering) : b.toLowerCase();\n }\n return impl(a, quote(b), ignore);\n };\n }\n function operator(op, a, b, ignore, accentFoldingFiltering) {\n if (b != null) {\n if (typeof b === STRING) {\n var date = dateRegExp.exec(b);\n if (date) {\n b = new Date(+date[1]);\n } else if (ignore) {\n b = quote(accentFoldingFiltering ? b.toLocaleLowerCase(accentFoldingFiltering) : b.toLowerCase());\n a = '((' + a + ' || \\'\\')+\\'\\')' + (accentFoldingFiltering ? '.toLocaleLowerCase(\\'' + accentFoldingFiltering + '\\')' : '.toLowerCase()');\n } else {\n b = quote(b);\n }\n }\n if (b.getTime) {\n a = '(' + a + '&&' + a + '.getTime?' + a + '.getTime():' + a + ')';\n b = b.getTime();\n }\n }\n return a + ' ' + op + ' ' + b;\n }\n function getMatchRegexp(pattern) {\n for (var rx = '/^', esc = false, i = 0; i < pattern.length; ++i) {\n var ch = pattern.charAt(i);\n if (esc) {\n rx += '\\\\' + ch;\n } else if (ch == '~') {\n esc = true;\n continue;\n } else if (ch == '*') {\n rx += '.*';\n } else if (ch == '?') {\n rx += '.';\n } else if ('.+^$()[]{}|\\\\/\\n\\r\\u2028\\u2029\\xA0'.indexOf(ch) >= 0) {\n rx += '\\\\' + ch;\n } else {\n rx += ch;\n }\n esc = false;\n }\n return rx + '$/';\n }\n return {\n quote: function (value) {\n if (value && value.getTime) {\n return 'new Date(' + value.getTime() + ')';\n }\n return quote(value);\n },\n eq: function (a, b, ignore, accentFoldingFiltering) {\n return operator('==', a, b, ignore, accentFoldingFiltering);\n },\n neq: function (a, b, ignore, accentFoldingFiltering) {\n return operator('!=', a, b, ignore, accentFoldingFiltering);\n },\n gt: function (a, b, ignore) {\n return operator('>', a, b, ignore);\n },\n gte: function (a, b, ignore) {\n return operator('>=', a, b, ignore);\n },\n lt: function (a, b, ignore) {\n return operator('<', a, b, ignore);\n },\n lte: function (a, b, ignore) {\n return operator('<=', a, b, ignore);\n },\n startswith: textOp(function (a, b) {\n return a + '.lastIndexOf(' + b + ', 0) == 0';\n }),\n doesnotstartwith: textOp(function (a, b) {\n return a + '.lastIndexOf(' + b + ', 0) == -1';\n }),\n endswith: textOp(function (a, b) {\n var n = b ? b.length - 2 : 0;\n return a + '.indexOf(' + b + ', ' + a + '.length - ' + n + ') >= 0';\n }),\n doesnotendwith: textOp(function (a, b) {\n var n = b ? b.length - 2 : 0;\n return a + '.indexOf(' + b + ', ' + a + '.length - ' + n + ') < 0';\n }),\n contains: textOp(function (a, b) {\n return a + '.indexOf(' + b + ') >= 0';\n }),\n doesnotcontain: textOp(function (a, b) {\n return a + '.indexOf(' + b + ') == -1';\n }),\n matches: textOp(function (a, b) {\n b = b.substring(1, b.length - 1);\n return getMatchRegexp(b) + '.test(' + a + ')';\n }),\n doesnotmatch: textOp(function (a, b) {\n b = b.substring(1, b.length - 1);\n return '!' + getMatchRegexp(b) + '.test(' + a + ')';\n }),\n isempty: function (a) {\n return a + ' === \\'\\'';\n },\n isnotempty: function (a) {\n return a + ' !== \\'\\'';\n },\n isnull: function (a) {\n return '(' + a + ' == null)';\n },\n isnotnull: function (a) {\n return '(' + a + ' != null)';\n },\n isnullorempty: function (a) {\n return '(' + a + ' === null) || (' + a + ' === \\'\\')';\n },\n isnotnullorempty: function (a) {\n return '(' + a + ' !== null) && (' + a + ' !== \\'\\')';\n }\n };\n }();\n function Query(data) {\n this.data = data || [];\n }\n Query.filterExpr = function (expression) {\n var expressions = [], logic = {\n and: ' && ',\n or: ' || '\n }, idx, length, filter, expr, fieldFunctions = [], operatorFunctions = [], field, operator, filters = expression.filters;\n for (idx = 0, length = filters.length; idx < length; idx++) {\n filter = filters[idx];\n field = filter.field;\n operator = filter.operator;\n if (filter.filters) {\n expr = Query.filterExpr(filter);\n filter = expr.expression.replace(/__o\\[(\\d+)\\]/g, function (match, index) {\n index = +index;\n return '__o[' + (operatorFunctions.length + index) + ']';\n }).replace(/__f\\[(\\d+)\\]/g, function (match, index) {\n index = +index;\n return '__f[' + (fieldFunctions.length + index) + ']';\n });\n operatorFunctions.push.apply(operatorFunctions, expr.operators);\n fieldFunctions.push.apply(fieldFunctions, expr.fields);\n } else {\n if (typeof field === FUNCTION) {\n expr = '__f[' + fieldFunctions.length + '](d)';\n fieldFunctions.push(field);\n } else {\n expr = kendo.expr(field);\n }\n if (typeof operator === FUNCTION) {\n filter = '__o[' + operatorFunctions.length + '](' + expr + ', ' + operators.quote(filter.value) + ')';\n operatorFunctions.push(operator);\n } else {\n filter = operators[(operator || 'eq').toLowerCase()](expr, filter.value, filter.ignoreCase !== undefined ? filter.ignoreCase : true, expression.accentFoldingFiltering);\n }\n }\n expressions.push(filter);\n }\n return {\n expression: '(' + expressions.join(logic[expression.logic]) + ')',\n fields: fieldFunctions,\n operators: operatorFunctions\n };\n };\n function normalizeSort(field, dir) {\n if (field) {\n var descriptor = typeof field === STRING ? {\n field: field,\n dir: dir\n } : field, descriptors = isArray(descriptor) ? descriptor : descriptor !== undefined ? [descriptor] : [];\n return grep(descriptors, function (d) {\n return !!d.dir;\n });\n }\n }\n function sortFields(sorts, dir) {\n var sortObject = {};\n if (sorts) {\n var descriptor = typeof sorts === STRING ? {\n field: sorts,\n dir: dir\n } : sorts, descriptors = isArray(descriptor) ? descriptor : descriptor !== undefined ? [descriptor] : [];\n for (var i = 0; i < descriptors.length; i++) {\n sortObject[descriptors[i].field] = {\n dir: descriptors[i].dir,\n index: i + 1\n };\n }\n }\n return sortObject;\n }\n var operatorMap = {\n '==': 'eq',\n equals: 'eq',\n isequalto: 'eq',\n equalto: 'eq',\n equal: 'eq',\n '!=': 'neq',\n ne: 'neq',\n notequals: 'neq',\n isnotequalto: 'neq',\n notequalto: 'neq',\n notequal: 'neq',\n '<': 'lt',\n islessthan: 'lt',\n lessthan: 'lt',\n less: 'lt',\n '<=': 'lte',\n le: 'lte',\n islessthanorequalto: 'lte',\n lessthanequal: 'lte',\n '>': 'gt',\n isgreaterthan: 'gt',\n greaterthan: 'gt',\n greater: 'gt',\n '>=': 'gte',\n isgreaterthanorequalto: 'gte',\n greaterthanequal: 'gte',\n ge: 'gte',\n notsubstringof: 'doesnotcontain',\n isnull: 'isnull',\n isempty: 'isempty',\n isnotempty: 'isnotempty'\n };\n function normalizeOperator(expression) {\n var idx, length, filter, operator, filters = expression.filters;\n if (filters) {\n for (idx = 0, length = filters.length; idx < length; idx++) {\n filter = filters[idx];\n operator = filter.operator;\n if (operator && typeof operator === STRING) {\n filter.operator = operatorMap[operator.toLowerCase()] || operator;\n }\n normalizeOperator(filter);\n }\n }\n }\n function normalizeFilter(expression) {\n if (expression && !isEmptyObject(expression)) {\n if (isArray(expression) || !expression.filters) {\n expression = {\n logic: 'and',\n filters: isArray(expression) ? expression : [expression]\n };\n }\n normalizeOperator(expression);\n return expression;\n }\n }\n Query.normalizeFilter = normalizeFilter;\n function compareDescriptor(f1, f2) {\n if (f1.logic || f2.logic) {\n return false;\n }\n return f1.field === f2.field && f1.value === f2.value && f1.operator === f2.operator;\n }\n function normalizeDescriptor(filter) {\n filter = filter || {};\n if (isEmptyObject(filter)) {\n return {\n logic: 'and',\n filters: []\n };\n }\n return normalizeFilter(filter);\n }\n function fieldComparer(a, b) {\n if (b.logic || a.field > b.field) {\n return 1;\n } else if (a.field < b.field) {\n return -1;\n } else {\n return 0;\n }\n }\n function compareFilters(expr1, expr2) {\n expr1 = normalizeDescriptor(expr1);\n expr2 = normalizeDescriptor(expr2);\n if (expr1.logic !== expr2.logic) {\n return false;\n }\n var f1, f2;\n var filters1 = (expr1.filters || []).slice();\n var filters2 = (expr2.filters || []).slice();\n if (filters1.length !== filters2.length) {\n return false;\n }\n filters1 = filters1.sort(fieldComparer);\n filters2 = filters2.sort(fieldComparer);\n for (var idx = 0; idx < filters1.length; idx++) {\n f1 = filters1[idx];\n f2 = filters2[idx];\n if (f1.logic && f2.logic) {\n if (!compareFilters(f1, f2)) {\n return false;\n }\n } else if (!compareDescriptor(f1, f2)) {\n return false;\n }\n }\n return true;\n }\n Query.compareFilters = compareFilters;\n function normalizeAggregate(expressions) {\n return isArray(expressions) ? expressions : [expressions];\n }\n function normalizeGroup(field, dir, compare, skipItemSorting) {\n var descriptor = typeof field === STRING ? {\n field: field,\n dir: dir,\n compare: compare,\n skipItemSorting: skipItemSorting\n } : field, descriptors = isArray(descriptor) ? descriptor : descriptor !== undefined ? [descriptor] : [];\n return map(descriptors, function (d) {\n return {\n field: d.field,\n dir: d.dir || 'asc',\n aggregates: d.aggregates,\n compare: d.compare,\n skipItemSorting: d.skipItemSorting\n };\n });\n }\n function normalizeGroupWithoutCompare(field, dir, compare) {\n var descriptors = normalizeGroup(field, dir, compare);\n for (var i = 0; i < descriptors.length; i++) {\n delete descriptors[i].compare;\n }\n return descriptors;\n }\n function anyGroupDescriptorHasCompare(groupDescriptors) {\n var descriptors = isArray(groupDescriptors) ? groupDescriptors : [groupDescriptors];\n for (var i = 0; i < descriptors.length; i++) {\n if (descriptors[i] && isFunction(descriptors[i].compare)) {\n return true;\n }\n }\n return false;\n }\n Query.prototype = {\n toArray: function () {\n return this.data;\n },\n range: function (index, count) {\n return new Query(this.data.slice(index, index + count));\n },\n skip: function (count) {\n return new Query(this.data.slice(count));\n },\n take: function (count) {\n return new Query(this.data.slice(0, count));\n },\n select: function (selector) {\n return new Query(map(this.data, selector));\n },\n order: function (selector, dir, inPlace) {\n var sort = { dir: dir };\n if (selector) {\n if (selector.compare) {\n sort.compare = selector.compare;\n } else {\n sort.field = selector;\n }\n }\n if (inPlace) {\n return new Query(this.data.sort(Comparer.create(sort)));\n }\n return new Query(this.data.slice(0).sort(Comparer.create(sort)));\n },\n orderBy: function (selector, inPlace) {\n return this.order(selector, 'asc', inPlace);\n },\n orderByDescending: function (selector, inPlace) {\n return this.order(selector, 'desc', inPlace);\n },\n sort: function (field, dir, comparer, inPlace) {\n var idx, length, descriptors = normalizeSort(field, dir), comparers = [];\n comparer = comparer || Comparer;\n if (descriptors.length) {\n for (idx = 0, length = descriptors.length; idx < length; idx++) {\n comparers.push(comparer.create(descriptors[idx]));\n }\n return this.orderBy({ compare: comparer.combine(comparers) }, inPlace);\n }\n return this;\n },\n filter: function (expressions) {\n var idx, current, length, compiled, predicate, data = this.data, fields, operators, result = [], filter;\n expressions = normalizeFilter(expressions);\n if (!expressions || expressions.filters.length === 0) {\n return this;\n }\n compiled = Query.filterExpr(expressions);\n fields = compiled.fields;\n operators = compiled.operators;\n predicate = filter = new Function('d, __f, __o', 'return ' + compiled.expression);\n if (fields.length || operators.length) {\n filter = function (d) {\n return predicate(d, fields, operators);\n };\n }\n for (idx = 0, length = data.length; idx < length; idx++) {\n current = data[idx];\n if (filter(current)) {\n result.push(current);\n }\n }\n return new Query(result);\n },\n group: function (descriptors, allData, options) {\n descriptors = normalizeGroup(descriptors || []);\n allData = allData || this.data;\n var that = this, result = new Query(that.data), descriptor;\n if (descriptors.length > 0) {\n descriptor = descriptors[0];\n if (options && options.groupPaging) {\n result = new Query(allData).groupAllData(descriptor, allData).select(function (group) {\n var data = new Query(allData).filter([{\n field: group.field,\n operator: 'eq',\n value: group.value,\n ignoreCase: false\n }]);\n var items = descriptors.length > 1 ? new Query(group.items).group(descriptors.slice(1), data.toArray(), options).toArray() : group.items;\n return {\n field: group.field,\n value: group.value,\n hasSubgroups: descriptors.length > 1,\n items: items,\n aggregates: data.aggregate(descriptor.aggregates),\n uid: kendo.guid(),\n itemCount: items.length,\n subgroupCount: items.length\n };\n });\n } else {\n result = result.groupBy(descriptor).select(function (group) {\n var data = new Query(allData).filter([{\n field: group.field,\n operator: 'eq',\n value: group.value,\n ignoreCase: false\n }]);\n return {\n field: group.field,\n value: group.value,\n items: descriptors.length > 1 ? new Query(group.items).group(descriptors.slice(1), data.toArray()).toArray() : group.items,\n hasSubgroups: descriptors.length > 1,\n aggregates: data.aggregate(descriptor.aggregates)\n };\n });\n }\n }\n return result;\n },\n groupBy: function (descriptor) {\n var that = this;\n if (isEmptyObject(descriptor) || !this.data.length) {\n return new Query([]);\n }\n var field = descriptor.field, sorted = descriptor.skipItemSorting ? this.data : this._sortForGrouping(field, descriptor.dir || 'asc'), accessor = kendo.accessor(field), item, groupValue = accessor.get(sorted[0], field), group = {\n field: field,\n value: groupValue,\n items: []\n }, currentValue, idx, len, result = [group];\n for (idx = 0, len = sorted.length; idx < len; idx++) {\n item = sorted[idx];\n currentValue = accessor.get(item, field);\n if (!groupValueComparer(groupValue, currentValue)) {\n groupValue = currentValue;\n group = {\n field: field,\n value: groupValue,\n items: []\n };\n result.push(group);\n }\n group.items.push(item);\n }\n result = that._sortGroups(result, descriptor);\n return new Query(result);\n },\n groupAllData: function (descriptor, allData) {\n if (isEmptyObject(descriptor) || this.data && !this.data.length) {\n return new Query([]);\n }\n var field = descriptor.field, sorted = descriptor.skipItemSorting ? allData : new Query(allData).sort(field, descriptor.dir || 'asc', StableComparer).toArray(), accessor = kendo.accessor(field), item, groupValue = accessor.get(sorted[0], field), group = {\n field: field,\n value: groupValue,\n items: []\n }, currentValue, idx, len, result = [group];\n for (idx = 0, len = sorted.length; idx < len; idx++) {\n item = sorted[idx];\n currentValue = accessor.get(item, field);\n if (!groupValueComparer(groupValue, currentValue)) {\n groupValue = currentValue;\n group = {\n field: field,\n value: groupValue,\n items: []\n };\n result.push(group);\n }\n group.items.push(item);\n }\n result = this._sortGroups(result, descriptor);\n return new Query(result);\n },\n _sortForGrouping: function (field, dir) {\n var idx, length, data = this.data;\n if (!stableSort) {\n for (idx = 0, length = data.length; idx < length; idx++) {\n data[idx].__position = idx;\n }\n data = new Query(data).sort(field, dir, StableComparer).toArray();\n for (idx = 0, length = data.length; idx < length; idx++) {\n delete data[idx].__position;\n }\n return data;\n }\n return this.sort(field, dir).toArray();\n },\n _sortGroups: function (groups, descriptor) {\n var result = groups;\n if (descriptor && isFunction(descriptor.compare)) {\n result = new Query(result).order({ compare: descriptor.compare }, descriptor.dir || ASCENDING).toArray();\n }\n return result;\n },\n aggregate: function (aggregates) {\n var idx, len, result = {}, state = {};\n if (aggregates && aggregates.length) {\n for (idx = 0, len = this.data.length; idx < len; idx++) {\n calculateAggregate(result, aggregates, this.data[idx], idx, len, state);\n }\n }\n return result;\n }\n };\n function groupValueComparer(a, b) {\n if (a && a.getTime && b && b.getTime) {\n return a.getTime() === b.getTime();\n }\n return a === b;\n }\n function calculateAggregate(accumulator, aggregates, item, index, length, state) {\n aggregates = aggregates || [];\n var idx, aggr, functionName, len = aggregates.length;\n for (idx = 0; idx < len; idx++) {\n aggr = aggregates[idx];\n functionName = aggr.aggregate;\n var field = aggr.field;\n accumulator[field] = accumulator[field] || {};\n state[field] = state[field] || {};\n state[field][functionName] = state[field][functionName] || {};\n accumulator[field][functionName] = functions[functionName.toLowerCase()](accumulator[field][functionName], item, kendo.accessor(field), index, length, state[field][functionName]);\n }\n }\n var functions = {\n sum: function (accumulator, item, accessor) {\n var value = accessor.get(item);\n if (!isNumber(accumulator)) {\n accumulator = value;\n } else if (isNumber(value)) {\n accumulator += value;\n }\n return accumulator;\n },\n count: function (accumulator) {\n return (accumulator || 0) + 1;\n },\n average: function (accumulator, item, accessor, index, length, state) {\n var value = accessor.get(item);\n if (state.count === undefined) {\n state.count = 0;\n }\n if (!isNumber(accumulator)) {\n accumulator = value;\n } else if (isNumber(value)) {\n accumulator += value;\n }\n if (isNumber(value)) {\n state.count++;\n }\n if (index == length - 1 && isNumber(accumulator)) {\n accumulator = accumulator / state.count;\n }\n return accumulator;\n },\n max: function (accumulator, item, accessor) {\n var value = accessor.get(item);\n if (!isNumber(accumulator) && !isDate(accumulator)) {\n accumulator = value;\n }\n if (accumulator < value && (isNumber(value) || isDate(value))) {\n accumulator = value;\n }\n return accumulator;\n },\n min: function (accumulator, item, accessor) {\n var value = accessor.get(item);\n if (!isNumber(accumulator) && !isDate(accumulator)) {\n accumulator = value;\n }\n if (accumulator > value && (isNumber(value) || isDate(value))) {\n accumulator = value;\n }\n return accumulator;\n }\n };\n function isNumber(val) {\n return typeof val === 'number' && !isNaN(val);\n }\n function isDate(val) {\n return val && val.getTime;\n }\n function toJSON(array) {\n var idx, length = array.length, result = new Array(length);\n for (idx = 0; idx < length; idx++) {\n result[idx] = array[idx].toJSON();\n }\n return result;\n }\n Query.normalizeGroup = normalizeGroup;\n Query.normalizeSort = normalizeSort;\n Query.process = function (data, options, inPlace) {\n options = options || {};\n var group = options.group;\n var customGroupSort = anyGroupDescriptorHasCompare(normalizeGroup(group || []));\n var query = new Query(data), groupDescriptorsWithoutCompare = normalizeGroupWithoutCompare(group || []), normalizedSort = normalizeSort(options.sort || []), sort = customGroupSort ? normalizedSort : groupDescriptorsWithoutCompare.concat(normalizedSort), groupDescriptorsWithoutSort, total, filterCallback = options.filterCallback, filter = options.filter, skip = options.skip, take = options.take;\n if (sort && inPlace) {\n query = query.sort(sort, undefined, undefined, inPlace);\n }\n if (filter) {\n query = query.filter(filter);\n if (filterCallback) {\n query = filterCallback(query);\n }\n total = query.toArray().length;\n }\n if (sort) {\n if (!inPlace) {\n query = query.sort(sort);\n }\n if (group) {\n data = query.toArray();\n }\n }\n if (customGroupSort) {\n query = query.group(group, data);\n if (skip !== undefined && take !== undefined) {\n query = new Query(flatGroups(query.toArray())).range(skip, take);\n groupDescriptorsWithoutSort = map(groupDescriptorsWithoutCompare, function (groupDescriptor) {\n return extend({}, groupDescriptor, { skipItemSorting: true });\n });\n query = query.group(groupDescriptorsWithoutSort, data);\n }\n } else {\n if (skip !== undefined && take !== undefined) {\n query = query.range(skip, take);\n }\n if (group) {\n query = query.group(group, data, options);\n }\n }\n return {\n total: total,\n data: query.toArray()\n };\n };\n var LocalTransport = Class.extend({\n init: function (options) {\n this.data = options.data;\n },\n read: function (options) {\n options.success(this.data);\n },\n update: function (options) {\n options.success(options.data);\n },\n create: function (options) {\n options.success(options.data);\n },\n destroy: function (options) {\n options.success(options.data);\n }\n });\n var RemoteTransport = Class.extend({\n init: function (options) {\n var that = this, parameterMap;\n options = that.options = extend({}, that.options, options);\n each(crud, function (index, type) {\n if (typeof options[type] === STRING) {\n options[type] = { url: options[type] };\n }\n });\n that.cache = options.cache ? Cache.create(options.cache) : {\n find: noop,\n add: noop\n };\n parameterMap = options.parameterMap;\n if (options.submit) {\n that.submit = options.submit;\n }\n if (isFunction(options.push)) {\n that.push = options.push;\n }\n if (!that.push) {\n that.push = identity;\n }\n that.parameterMap = isFunction(parameterMap) ? parameterMap : function (options) {\n var result = {};\n each(options, function (option, value) {\n if (option in parameterMap) {\n option = parameterMap[option];\n if (isPlainObject(option)) {\n value = option.value(value);\n option = option.key;\n }\n }\n result[option] = value;\n });\n return result;\n };\n },\n options: { parameterMap: identity },\n create: function (options) {\n return ajax(this.setup(options, CREATE));\n },\n read: function (options) {\n var that = this, success, error, result, cache = that.cache;\n options = that.setup(options, READ);\n success = options.success || noop;\n error = options.error || noop;\n result = cache.find(options.data);\n if (result !== undefined) {\n success(result);\n } else {\n options.success = function (result) {\n cache.add(options.data, result);\n success(result);\n };\n $.ajax(options);\n }\n },\n update: function (options) {\n return ajax(this.setup(options, UPDATE));\n },\n destroy: function (options) {\n return ajax(this.setup(options, DESTROY));\n },\n setup: function (options, type) {\n options = options || {};\n var that = this, parameters, operation = that.options[type], data = isFunction(operation.data) ? operation.data(options.data) : operation.data;\n options = extend(true, {}, operation, options);\n parameters = extend(true, {}, data, options.data);\n options.data = that.parameterMap(parameters, type);\n if (isFunction(options.url)) {\n options.url = options.url(parameters);\n }\n return options;\n }\n });\n var Cache = Class.extend({\n init: function () {\n this._store = {};\n },\n add: function (key, data) {\n if (key !== undefined) {\n this._store[stringify(key)] = data;\n }\n },\n find: function (key) {\n return this._store[stringify(key)];\n },\n clear: function () {\n this._store = {};\n },\n remove: function (key) {\n delete this._store[stringify(key)];\n }\n });\n Cache.create = function (options) {\n var store = {\n 'inmemory': function () {\n return new Cache();\n }\n };\n if (isPlainObject(options) && isFunction(options.find)) {\n return options;\n }\n if (options === true) {\n return new Cache();\n }\n return store[options]();\n };\n function serializeRecords(data, getters, modelInstance, originalFieldNames, fieldNames) {\n var record, getter, originalName, idx, setters = {}, length;\n for (idx = 0, length = data.length; idx < length; idx++) {\n record = data[idx];\n for (getter in getters) {\n originalName = fieldNames[getter];\n if (originalName && originalName !== getter) {\n if (!setters[originalName]) {\n setters[originalName] = kendo.setter(originalName);\n }\n setters[originalName](record, getters[getter](record));\n delete record[getter];\n }\n }\n }\n }\n function convertRecords(data, getters, modelInstance, originalFieldNames, fieldNames) {\n var record, getter, originalName, idx, length;\n for (idx = 0, length = data.length; idx < length; idx++) {\n record = data[idx];\n for (getter in getters) {\n record[getter] = modelInstance._parse(getter, getters[getter](record));\n originalName = fieldNames[getter];\n if (originalName && originalName !== getter) {\n delete record[originalName];\n }\n }\n }\n }\n function convertGroup(data, getters, modelInstance, originalFieldNames, fieldNames) {\n var record, idx, fieldName, length;\n for (idx = 0, length = data.length; idx < length; idx++) {\n record = data[idx];\n fieldName = originalFieldNames[record.field];\n if (fieldName && fieldName != record.field) {\n record.field = fieldName;\n }\n record.value = modelInstance._parse(record.field, record.value);\n if (record.items) {\n if (record.hasSubgroups) {\n convertGroup(record.items, getters, modelInstance, originalFieldNames, fieldNames);\n } else {\n convertRecords(record.items, getters, modelInstance, originalFieldNames, fieldNames);\n }\n }\n }\n }\n function wrapDataAccess(originalFunction, model, converter, getters, originalFieldNames, fieldNames) {\n return function (data) {\n data = originalFunction(data);\n return wrapDataAccessBase(model, converter, getters, originalFieldNames, fieldNames)(data);\n };\n }\n function wrapDataAccessBase(model, converter, getters, originalFieldNames, fieldNames) {\n return function (data) {\n if (data && !isEmptyObject(getters)) {\n if (toString.call(data) !== '[object Array]' && !(data instanceof ObservableArray)) {\n data = [data];\n }\n converter(data, getters, new model(), originalFieldNames, fieldNames);\n }\n return data || [];\n };\n }\n var DataReader = Class.extend({\n init: function (schema) {\n var that = this, member, get, model, base;\n schema = schema || {};\n for (member in schema) {\n get = schema[member];\n that[member] = typeof get === STRING ? getter(get) : get;\n }\n base = schema.modelBase || Model;\n if (isPlainObject(that.model)) {\n that.model = model = base.define(that.model);\n }\n var dataFunction = proxy(that.data, that);\n that._dataAccessFunction = dataFunction;\n if (that.model) {\n var groupsFunction = proxy(that.groups, that), serializeFunction = proxy(that.serialize, that), originalFieldNames = {}, getters = {}, serializeGetters = {}, fieldNames = {}, shouldSerialize = false, fieldName, name;\n model = that.model;\n if (model.fields) {\n each(model.fields, function (field, value) {\n var fromName;\n fieldName = field;\n if (isPlainObject(value) && value.field) {\n fieldName = value.field;\n } else if (typeof value === STRING) {\n fieldName = value;\n }\n if (isPlainObject(value) && value.from) {\n fromName = value.from;\n }\n shouldSerialize = shouldSerialize || fromName && fromName !== field || fieldName !== field;\n name = fromName || fieldName;\n getters[field] = name.indexOf('.') !== -1 ? getter(name, true) : getter(name);\n serializeGetters[field] = getter(field);\n originalFieldNames[fromName || fieldName] = field;\n fieldNames[field] = fromName || fieldName;\n });\n if (!schema.serialize && shouldSerialize) {\n that.serialize = wrapDataAccess(serializeFunction, model, serializeRecords, serializeGetters, originalFieldNames, fieldNames);\n }\n }\n that._dataAccessFunction = dataFunction;\n that._wrapDataAccessBase = wrapDataAccessBase(model, convertRecords, getters, originalFieldNames, fieldNames);\n that.data = wrapDataAccess(dataFunction, model, convertRecords, getters, originalFieldNames, fieldNames);\n that.groups = wrapDataAccess(groupsFunction, model, convertGroup, getters, originalFieldNames, fieldNames);\n }\n },\n errors: function (data) {\n return data ? data.errors : null;\n },\n parse: identity,\n data: identity,\n total: function (data) {\n return data.length;\n },\n groups: identity,\n aggregates: function () {\n return {};\n },\n serialize: function (data) {\n return data;\n }\n });\n function fillLastGroup(originalGroup, newGroup) {\n var currOriginal;\n var currentNew;\n if (newGroup.items && newGroup.items.length) {\n for (var i = 0; i < newGroup.items.length; i++) {\n currOriginal = originalGroup.items[i];\n currentNew = newGroup.items[i];\n if (currOriginal && currentNew) {\n if (currOriginal.hasSubgroups) {\n fillLastGroup(currOriginal, currentNew);\n } else if (currOriginal.field && currOriginal.value == currentNew.value) {\n currOriginal.items.push.apply(currOriginal.items, currentNew.items);\n } else {\n originalGroup.items.push.apply(originalGroup.items, [currentNew]);\n }\n } else if (currentNew) {\n originalGroup.items.push.apply(originalGroup.items, [currentNew]);\n }\n }\n }\n }\n function mergeGroups(target, dest, skip, take) {\n var group, idx = 0, items;\n while (dest.length && take) {\n group = dest[idx];\n items = group.items;\n var length = items.length;\n if (target && target.field === group.field && target.value === group.value) {\n if (target.hasSubgroups && target.items.length) {\n mergeGroups(target.items[target.items.length - 1], group.items, skip, take);\n } else {\n items = items.slice(skip, skip + take);\n target.items = target.items.concat(items);\n }\n dest.splice(idx--, 1);\n } else if (group.hasSubgroups && items.length) {\n mergeGroups(group, items, skip, take);\n if (!group.items.length) {\n dest.splice(idx--, 1);\n }\n } else {\n items = items.slice(skip, skip + take);\n group.items = items;\n if (!group.items.length) {\n dest.splice(idx--, 1);\n }\n }\n if (items.length === 0) {\n skip -= length;\n } else {\n skip = 0;\n take -= items.length;\n }\n if (++idx >= dest.length) {\n break;\n }\n }\n if (idx < dest.length) {\n dest.splice(idx, dest.length - idx);\n }\n }\n function flatGroups(groups, indexFunction) {\n var result = [];\n var groupsLength = (groups || []).length;\n var group;\n var items;\n var indexFn = isFunction(indexFunction) ? indexFunction : function (array, index) {\n return array[index];\n };\n for (var groupIndex = 0; groupIndex < groupsLength; groupIndex++) {\n group = indexFn(groups, groupIndex);\n if (group.hasSubgroups) {\n result = result.concat(flatGroups(group.items));\n } else {\n items = group.items;\n for (var itemIndex = 0; itemIndex < items.length; itemIndex++) {\n result.push(indexFn(items, itemIndex));\n }\n }\n }\n return result;\n }\n function flattenGroups(data) {\n var idx, result = [], length, items, itemIndex;\n for (idx = 0, length = data.length; idx < length; idx++) {\n var group = data.at(idx);\n if (group.items) {\n if (group.hasSubgroups) {\n result = result.concat(flattenGroups(group.items));\n } else {\n items = group.items;\n for (itemIndex = 0; itemIndex < items.length; itemIndex++) {\n result.push(items.at(itemIndex));\n }\n }\n }\n }\n return result;\n }\n function wrapGroupItems(data, model) {\n var idx, length, group;\n if (model) {\n for (idx = 0, length = data.length; idx < length; idx++) {\n group = data.at(idx);\n if (group.items) {\n if (group.hasSubgroups) {\n wrapGroupItems(group.items, model);\n } else {\n group.items = new LazyObservableArray(group.items, model, group.items._events);\n }\n }\n }\n }\n }\n function eachGroupItems(data, func) {\n for (var idx = 0; idx < data.length; idx++) {\n if (data[idx].hasSubgroups) {\n if (eachGroupItems(data[idx].items, func)) {\n return true;\n }\n } else if (func(data[idx].items, data[idx])) {\n return true;\n }\n }\n }\n function replaceInRanges(ranges, data, item, observable) {\n for (var idx = 0; idx < ranges.length; idx++) {\n if (ranges[idx].data === data) {\n break;\n }\n if (replaceInRange(ranges[idx].data, item, observable)) {\n break;\n }\n }\n }\n function replaceInRange(items, item, observable) {\n for (var idx = 0, length = items.length; idx < length; idx++) {\n if (items[idx] && items[idx].hasSubgroups) {\n return replaceInRange(items[idx].items, item, observable);\n } else if (items[idx] === item || items[idx] === observable) {\n items[idx] = observable;\n return true;\n }\n }\n }\n function replaceWithObservable(view, data, ranges, type, serverGrouping) {\n for (var viewIndex = 0, length = view.length; viewIndex < length; viewIndex++) {\n var item = view[viewIndex];\n if (!item || item instanceof type) {\n continue;\n }\n if (item.hasSubgroups !== undefined && !serverGrouping) {\n replaceWithObservable(item.items, data, ranges, type, serverGrouping);\n } else {\n for (var idx = 0; idx < data.length; idx++) {\n if (data[idx] === item) {\n view[viewIndex] = data.at(idx);\n replaceInRanges(ranges, data, item, view[viewIndex]);\n break;\n }\n }\n }\n }\n }\n function removeModel(data, model) {\n if (!data) {\n return;\n }\n var length = data.length;\n var dataItem;\n var idx;\n for (idx = 0; idx < length; idx++) {\n dataItem = data[idx];\n if (dataItem.uid && dataItem.uid == model.uid) {\n data.splice(idx, 1);\n return dataItem;\n }\n }\n }\n function indexOfPristineModel(data, model) {\n if (model) {\n return indexOf(data, function (item) {\n return item.uid && item.uid == model.uid || item[model.idField] === model.id && model.id !== model._defaultId;\n });\n }\n return -1;\n }\n function indexOfModel(data, model) {\n if (model) {\n return indexOf(data, function (item) {\n return item.uid == model.uid;\n });\n }\n return -1;\n }\n function indexOf(data, comparer) {\n var idx, length;\n if (!data) {\n return;\n }\n for (idx = 0, length = data.length; idx < length; idx++) {\n if (comparer(data[idx])) {\n return idx;\n }\n }\n return -1;\n }\n function fieldNameFromModel(fields, name) {\n if (fields && !isEmptyObject(fields)) {\n var descriptor = fields[name];\n var fieldName;\n if (isPlainObject(descriptor)) {\n fieldName = descriptor.from || descriptor.field || name;\n } else {\n fieldName = fields[name] || name;\n }\n if (isFunction(fieldName)) {\n return name;\n }\n return fieldName;\n }\n return name;\n }\n function convertFilterDescriptorsField(descriptor, model) {\n var idx, length, target = {};\n for (var field in descriptor) {\n if (field !== 'filters') {\n target[field] = descriptor[field];\n }\n }\n if (descriptor.filters) {\n target.filters = [];\n for (idx = 0, length = descriptor.filters.length; idx < length; idx++) {\n target.filters[idx] = convertFilterDescriptorsField(descriptor.filters[idx], model);\n }\n } else {\n target.field = fieldNameFromModel(model.fields, target.field);\n }\n return target;\n }\n function convertDescriptorsField(descriptors, model) {\n var idx, length, result = [], target, descriptor;\n for (idx = 0, length = descriptors.length; idx < length; idx++) {\n target = {};\n descriptor = descriptors[idx];\n for (var field in descriptor) {\n target[field] = descriptor[field];\n }\n target.field = fieldNameFromModel(model.fields, target.field);\n if (target.aggregates && isArray(target.aggregates)) {\n target.aggregates = convertDescriptorsField(target.aggregates, model);\n }\n result.push(target);\n }\n return result;\n }\n var DataSource = Observable.extend({\n init: function (options) {\n var that = this, model, data;\n if (options) {\n data = options.data;\n }\n options = that.options = extend({}, that.options, options);\n that._map = {};\n that._prefetch = {};\n that._data = [];\n that._pristineData = [];\n that._ranges = [];\n that._view = [];\n that._pristineTotal = 0;\n that._destroyed = [];\n that._pageSize = options.pageSize;\n that._page = options.page || (options.pageSize ? 1 : undefined);\n that._sort = normalizeSort(options.sort);\n that._sortFields = sortFields(options.sort);\n that._filter = normalizeFilter(options.filter);\n that._group = normalizeGroup(options.group);\n that._aggregate = options.aggregate;\n that._total = options.total;\n that._groupPaging = options.groupPaging;\n if (that._groupPaging) {\n that._groupsState = {};\n }\n that._shouldDetachObservableParents = true;\n Observable.fn.init.call(that);\n that.transport = Transport.create(options, data, that);\n if (isFunction(that.transport.push)) {\n that.transport.push({\n pushCreate: proxy(that._pushCreate, that),\n pushUpdate: proxy(that._pushUpdate, that),\n pushDestroy: proxy(that._pushDestroy, that)\n });\n }\n if (options.offlineStorage != null) {\n if (typeof options.offlineStorage == 'string') {\n var key = options.offlineStorage;\n that._storage = {\n getItem: function () {\n return JSON.parse(localStorage.getItem(key));\n },\n setItem: function (item) {\n localStorage.setItem(key, stringify(that.reader.serialize(item)));\n }\n };\n } else {\n that._storage = options.offlineStorage;\n }\n }\n that.reader = new kendo.data.readers[options.schema.type || 'json'](options.schema);\n model = that.reader.model || {};\n that._detachObservableParents();\n that._data = that._observe(that._data);\n that._online = true;\n that.bind([\n 'push',\n ERROR,\n CHANGE,\n REQUESTSTART,\n SYNC,\n REQUESTEND,\n PROGRESS\n ], options);\n },\n options: {\n data: null,\n schema: { modelBase: Model },\n offlineStorage: null,\n serverSorting: false,\n serverPaging: false,\n serverFiltering: false,\n serverGrouping: false,\n serverAggregates: false,\n batch: false,\n inPlaceSort: false\n },\n clone: function () {\n return this;\n },\n online: function (value) {\n if (value !== undefined) {\n if (this._online != value) {\n this._online = value;\n if (value) {\n return this.sync();\n }\n }\n return $.Deferred().resolve().promise();\n } else {\n return this._online;\n }\n },\n offlineData: function (state) {\n if (this.options.offlineStorage == null) {\n return null;\n }\n if (state !== undefined) {\n return this._storage.setItem(state);\n }\n return this._storage.getItem() || [];\n },\n _isServerGrouped: function () {\n var group = this.group() || [];\n return this.options.serverGrouping && group.length;\n },\n _isServerGroupPaged: function () {\n return this._isServerGrouped() && this._groupPaging;\n },\n _isGroupPaged: function () {\n var group = this._group || [];\n return this._groupPaging && group.length;\n },\n _pushCreate: function (result) {\n this._push(result, 'pushCreate');\n },\n _pushUpdate: function (result) {\n this._push(result, 'pushUpdate');\n },\n _pushDestroy: function (result) {\n this._push(result, 'pushDestroy');\n },\n _push: function (result, operation) {\n var data = this._readData(result);\n if (!data) {\n data = result;\n }\n this[operation](data);\n },\n _flatData: function (data, skip) {\n if (data) {\n if (this._isServerGrouped()) {\n return flattenGroups(data);\n }\n if (!skip) {\n for (var idx = 0; idx < data.length; idx++) {\n data.at(idx);\n }\n }\n }\n return data;\n },\n parent: noop,\n get: function (id) {\n var idx, length, data = this._flatData(this._data, this.options.useRanges);\n for (idx = 0, length = data.length; idx < length; idx++) {\n if (data[idx].id == id) {\n return data[idx];\n }\n }\n },\n getByUid: function (id) {\n return this._getByUid(id, this._data);\n },\n _getByUid: function (id, dataItems) {\n var idx, length, data = this._flatData(dataItems, this.options.useRanges);\n if (!data) {\n return;\n }\n for (idx = 0, length = data.length; idx < length; idx++) {\n if (data[idx].uid == id) {\n return data[idx];\n }\n }\n },\n indexOf: function (model) {\n return indexOfModel(this._data, model);\n },\n at: function (index) {\n return this._data.at(index);\n },\n data: function (value) {\n var that = this;\n if (value !== undefined) {\n that._detachObservableParents();\n that._data = this._observe(value);\n that._pristineData = value.slice(0);\n that._storeData();\n that._ranges = [];\n that.trigger('reset');\n that._addRange(that._data);\n that._total = that._data.length;\n that._pristineTotal = that._total;\n that._process(that._data);\n } else {\n if (that._data) {\n for (var idx = 0; idx < that._data.length; idx++) {\n that._data.at(idx);\n }\n }\n return that._data;\n }\n },\n view: function (value) {\n if (value === undefined) {\n return this._view;\n } else {\n this._view = this._observeView(value);\n }\n },\n _observeView: function (data) {\n var that = this;\n replaceWithObservable(data, that._data, that._ranges, that.reader.model || ObservableObject, that._isServerGrouped());\n var view = new LazyObservableArray(data, that.reader.model);\n view.parent = function () {\n return that.parent();\n };\n return view;\n },\n flatView: function () {\n var groups = this.group() || [];\n if (groups.length) {\n return flattenGroups(this._view);\n } else {\n return this._view;\n }\n },\n add: function (model) {\n return this.insert(this._data.length, model);\n },\n _createNewModel: function (model) {\n if (this.reader.model) {\n return new this.reader.model(model);\n }\n if (model instanceof ObservableObject) {\n return model;\n }\n return new ObservableObject(model);\n },\n insert: function (index, model) {\n if (!model) {\n model = index;\n index = 0;\n }\n if (!(model instanceof Model)) {\n model = this._createNewModel(model);\n }\n if (this._isServerGrouped()) {\n this._data.splice(index, 0, this._wrapInEmptyGroup(model));\n } else {\n this._data.splice(index, 0, model);\n }\n this._insertModelInRange(index, model);\n return model;\n },\n pushInsert: function (index, items) {\n var that = this;\n var rangeSpan = that._getCurrentRangeSpan();\n if (!items) {\n items = index;\n index = 0;\n }\n if (!isArray(items)) {\n items = [items];\n }\n var pushed = [];\n var autoSync = this.options.autoSync;\n this.options.autoSync = false;\n try {\n for (var idx = 0; idx < items.length; idx++) {\n var item = items[idx];\n var result = this.insert(index, item);\n pushed.push(result);\n var pristine = result.toJSON();\n if (this._isServerGrouped()) {\n pristine = this._wrapInEmptyGroup(pristine);\n }\n this._pristineData.push(pristine);\n if (rangeSpan && rangeSpan.length) {\n $(rangeSpan).last()[0].pristineData.push(pristine);\n }\n index++;\n }\n } finally {\n this.options.autoSync = autoSync;\n }\n if (pushed.length) {\n this.trigger('push', {\n type: 'create',\n items: pushed\n });\n }\n },\n pushCreate: function (items) {\n this.pushInsert(this._data.length, items);\n },\n pushUpdate: function (items) {\n if (!isArray(items)) {\n items = [items];\n }\n var pushed = [];\n for (var idx = 0; idx < items.length; idx++) {\n var item = items[idx];\n var model = this._createNewModel(item);\n var target = this.get(model.id);\n if (target) {\n pushed.push(target);\n target.accept(item);\n target.trigger(CHANGE);\n this._updatePristineForModel(target, item);\n } else {\n this.pushCreate(item);\n }\n }\n if (pushed.length) {\n this.trigger('push', {\n type: 'update',\n items: pushed\n });\n }\n },\n pushDestroy: function (items) {\n var pushed = this._removeItems(items);\n if (pushed.length) {\n this.trigger('push', {\n type: 'destroy',\n items: pushed\n });\n }\n },\n _removeItems: function (items, removePristine) {\n if (!isArray(items)) {\n items = [items];\n }\n var shouldRemovePristine = typeof removePristine !== 'undefined' ? removePristine : true;\n var destroyed = [];\n var autoSync = this.options.autoSync;\n this.options.autoSync = false;\n try {\n for (var idx = 0; idx < items.length; idx++) {\n var item = items[idx];\n var model = this._createNewModel(item);\n var found = false;\n this._eachItem(this._data, function (items) {\n for (var idx = 0; idx < items.length; idx++) {\n var item = items.at(idx);\n if (item.id === model.id) {\n destroyed.push(item);\n items.splice(idx, 1);\n found = true;\n break;\n }\n }\n });\n if (found && shouldRemovePristine) {\n this._removePristineForModel(model);\n this._destroyed.pop();\n }\n }\n } finally {\n this.options.autoSync = autoSync;\n }\n return destroyed;\n },\n remove: function (model) {\n var result, that = this, hasGroups = that._isServerGrouped();\n this._eachItem(that._data, function (items) {\n result = removeModel(items, model);\n if (result && hasGroups) {\n if (!result.isNew || !result.isNew()) {\n that._destroyed.push(result);\n }\n return true;\n }\n });\n this._removeModelFromRanges(model);\n return model;\n },\n destroyed: function () {\n return this._destroyed;\n },\n created: function () {\n var idx, length, result = [], data = this._flatData(this._data, this.options.useRanges);\n for (idx = 0, length = data.length; idx < length; idx++) {\n if (data[idx].isNew && data[idx].isNew()) {\n result.push(data[idx]);\n }\n }\n return result;\n },\n updated: function () {\n var idx, length, result = [], data = this._flatData(this._data, this.options.useRanges);\n for (idx = 0, length = data.length; idx < length; idx++) {\n if (data[idx].isNew && !data[idx].isNew() && data[idx].dirty) {\n result.push(data[idx]);\n }\n }\n return result;\n },\n sync: function () {\n var that = this, created = [], updated = [], destroyed = that._destroyed;\n var promise = $.Deferred().resolve().promise();\n if (that.online()) {\n if (!that.reader.model) {\n return promise;\n }\n created = that.created();\n updated = that.updated();\n var promises = [];\n if (that.options.batch && that.transport.submit) {\n promises = that._sendSubmit(created, updated, destroyed);\n } else {\n promises.push.apply(promises, that._send('create', created));\n promises.push.apply(promises, that._send('update', updated));\n promises.push.apply(promises, that._send('destroy', destroyed));\n }\n promise = $.when.apply(null, promises).then(function () {\n var idx, length;\n for (idx = 0, length = arguments.length; idx < length; idx++) {\n if (arguments[idx]) {\n that._accept(arguments[idx]);\n }\n }\n that._storeData(true);\n that._syncEnd();\n that._change({ action: 'sync' });\n that.trigger(SYNC);\n if (that._isServerGroupPaged()) {\n that.read();\n }\n });\n } else {\n that._storeData(true);\n that._syncEnd();\n that._change({ action: 'sync' });\n }\n return promise;\n },\n _syncEnd: noop,\n cancelChanges: function (model) {\n var that = this;\n if (model instanceof kendo.data.Model) {\n that._cancelModel(model);\n } else {\n that._destroyed = [];\n that._detachObservableParents();\n that._data = that._observe(that._pristineData);\n if (that.options.serverPaging) {\n that._total = that._pristineTotal;\n }\n that._ranges = [];\n that._addRange(that._data, 0);\n that._changesCanceled();\n that._change();\n that._markOfflineUpdatesAsDirty();\n if (that._isServerGrouped()) {\n that.read();\n }\n }\n },\n _changesCanceled: noop,\n _markOfflineUpdatesAsDirty: function () {\n var that = this;\n if (that.options.offlineStorage != null) {\n that._eachItem(that._data, function (items) {\n for (var idx = 0; idx < items.length; idx++) {\n var item = items.at(idx);\n if (item.__state__ == 'update' || item.__state__ == 'create') {\n item.dirty = true;\n }\n }\n });\n }\n },\n hasChanges: function () {\n var idx, length, data = this._flatData(this._data, this.options.useRanges);\n if (this._destroyed.length) {\n return true;\n }\n for (idx = 0, length = data.length; idx < length; idx++) {\n if (data[idx].isNew && data[idx].isNew() || data[idx].dirty) {\n return true;\n }\n }\n return false;\n },\n _accept: function (result) {\n var that = this, models = result.models, response = result.response, idx = 0, serverGroup = that._isServerGrouped(), pristine = that._pristineData, type = result.type, length;\n that.trigger(REQUESTEND, {\n response: response,\n type: type\n });\n if (response && !isEmptyObject(response)) {\n response = that.reader.parse(response);\n if (that._handleCustomErrors(response)) {\n return;\n }\n response = that.reader.data(response);\n if (!isArray(response)) {\n response = [response];\n }\n } else {\n response = $.map(models, function (model) {\n return model.toJSON();\n });\n }\n if (type === 'destroy') {\n that._destroyed = [];\n }\n for (idx = 0, length = models.length; idx < length; idx++) {\n if (type !== 'destroy') {\n models[idx].accept(response[idx]);\n if (type === 'create') {\n pristine.push(serverGroup ? that._wrapInEmptyGroup(models[idx].toJSON()) : response[idx]);\n } else if (type === 'update') {\n that._updatePristineForModel(models[idx], response[idx]);\n }\n } else {\n that._removePristineForModel(models[idx]);\n }\n }\n },\n _updatePristineForModel: function (model, values) {\n this._executeOnPristineForModel(model, function (index, items) {\n kendo.deepExtend(items[index], values);\n });\n },\n _executeOnPristineForModel: function (model, callback) {\n this._eachPristineItem(function (items) {\n var index = indexOfPristineModel(items, model);\n if (index > -1) {\n callback(index, items);\n return true;\n }\n });\n },\n _removePristineForModel: function (model) {\n this._executeOnPristineForModel(model, function (index, items) {\n items.splice(index, 1);\n });\n },\n _readData: function (data) {\n var read = !this._isServerGrouped() ? this.reader.data : this.reader.groups;\n return read.call(this.reader, data);\n },\n _eachPristineItem: function (callback) {\n var that = this;\n var options = that.options;\n var rangeSpan = that._getCurrentRangeSpan();\n that._eachItem(that._pristineData, callback);\n if (options.serverPaging && options.useRanges) {\n each(rangeSpan, function (i, range) {\n that._eachItem(range.pristineData, callback);\n });\n }\n },\n _eachItem: function (data, callback) {\n if (data && data.length) {\n if (this._isServerGrouped()) {\n eachGroupItems(data, callback);\n } else {\n callback(data);\n }\n }\n },\n _pristineForModel: function (model) {\n var pristine, idx, callback = function (items) {\n idx = indexOfPristineModel(items, model);\n if (idx > -1) {\n pristine = items[idx];\n return true;\n }\n };\n this._eachPristineItem(callback);\n return pristine;\n },\n _cancelModel: function (model) {\n var that = this;\n var pristine = this._pristineForModel(model);\n this._eachItem(this._data, function (items) {\n var idx = indexOfModel(items, model);\n if (idx >= 0) {\n if (pristine && (!model.isNew() || pristine.__state__)) {\n items[idx].accept(pristine);\n if (pristine.__state__ == 'update') {\n items[idx].dirty = true;\n }\n } else {\n that._modelCanceled(model);\n items.splice(idx, 1);\n that._removeModelFromRanges(model);\n }\n }\n });\n },\n _modelCanceled: noop,\n _submit: function (promises, data) {\n var that = this;\n that.trigger(REQUESTSTART, { type: 'submit' });\n that.trigger(PROGRESS);\n that.transport.submit(extend({\n success: function (response, type) {\n var promise = $.grep(promises, function (x) {\n return x.type == type;\n })[0];\n if (promise) {\n promise.resolve({\n response: response,\n models: promise.models,\n type: type\n });\n }\n },\n error: function (response, status, error) {\n for (var idx = 0; idx < promises.length; idx++) {\n promises[idx].reject(response);\n }\n that.error(response, status, error);\n }\n }, data));\n },\n _sendSubmit: function (created, updated, destroyed) {\n var that = this, promises = [];\n if (that.options.batch) {\n if (created.length) {\n promises.push($.Deferred(function (deferred) {\n deferred.type = 'create';\n deferred.models = created;\n }));\n }\n if (updated.length) {\n promises.push($.Deferred(function (deferred) {\n deferred.type = 'update';\n deferred.models = updated;\n }));\n }\n if (destroyed.length) {\n promises.push($.Deferred(function (deferred) {\n deferred.type = 'destroy';\n deferred.models = destroyed;\n }));\n }\n that._submit(promises, {\n data: {\n created: that.reader.serialize(toJSON(created)),\n updated: that.reader.serialize(toJSON(updated)),\n destroyed: that.reader.serialize(toJSON(destroyed))\n }\n });\n }\n return promises;\n },\n _promise: function (data, models, type) {\n var that = this;\n return $.Deferred(function (deferred) {\n that.trigger(REQUESTSTART, { type: type });\n that.trigger(PROGRESS);\n that.transport[type].call(that.transport, extend({\n success: function (response) {\n deferred.resolve({\n response: response,\n models: models,\n type: type\n });\n },\n error: function (response, status, error) {\n deferred.reject(response);\n that.error(response, status, error);\n }\n }, data));\n }).promise();\n },\n _send: function (method, data) {\n var that = this, idx, length, promises = [], converted = that.reader.serialize(toJSON(data));\n if (that.options.batch) {\n if (data.length) {\n promises.push(that._promise({ data: { models: converted } }, data, method));\n }\n } else {\n for (idx = 0, length = data.length; idx < length; idx++) {\n promises.push(that._promise({ data: converted[idx] }, [data[idx]], method));\n }\n }\n return promises;\n },\n read: function (data) {\n var that = this, params = that._params(data);\n var deferred = $.Deferred();\n that._queueRequest(params, function () {\n var isPrevented = that.trigger(REQUESTSTART, { type: 'read' });\n if (!isPrevented) {\n that.trigger(PROGRESS);\n that._ranges = [];\n that.trigger('reset');\n if (that.online()) {\n that.transport.read({\n data: params,\n success: function (data) {\n that._ranges = [];\n that.success(data, params);\n deferred.resolve();\n },\n error: function () {\n var args = slice.call(arguments);\n that.error.apply(that, args);\n deferred.reject.apply(deferred, args);\n }\n });\n } else if (that.options.offlineStorage != null) {\n that.success(that.offlineData(), params);\n deferred.resolve();\n }\n } else {\n that._dequeueRequest();\n deferred.resolve(isPrevented);\n }\n });\n return deferred.promise();\n },\n _readAggregates: function (data) {\n return this.reader.aggregates(data);\n },\n success: function (data) {\n var that = this, options = that.options, items, replaceSubset;\n that.trigger(REQUESTEND, {\n response: data,\n type: 'read'\n });\n if (that.online()) {\n data = that.reader.parse(data);\n if (that._handleCustomErrors(data)) {\n that._dequeueRequest();\n return;\n }\n that._total = that.reader.total(data);\n if (that._isServerGroupPaged()) {\n that._serverGroupsTotal = that._total;\n }\n if (that._pageSize > that._total) {\n that._pageSize = that._total;\n if (that.options.pageSize && that.options.pageSize > that._pageSize) {\n that._pageSize = that.options.pageSize;\n }\n }\n if (that._aggregate && options.serverAggregates) {\n that._aggregateResult = that._readAggregates(data);\n }\n data = that._readData(data);\n that._destroyed = [];\n } else {\n data = that._readData(data);\n items = [];\n var itemIds = {};\n var model = that.reader.model;\n var idField = model ? model.idField : 'id';\n var idx;\n for (idx = 0; idx < this._destroyed.length; idx++) {\n var id = this._destroyed[idx][idField];\n itemIds[id] = id;\n }\n for (idx = 0; idx < data.length; idx++) {\n var item = data[idx];\n var state = item.__state__;\n if (state == 'destroy') {\n if (!itemIds[item[idField]]) {\n this._destroyed.push(this._createNewModel(item));\n }\n } else {\n items.push(item);\n }\n }\n data = items;\n that._total = data.length;\n }\n that._pristineTotal = that._total;\n replaceSubset = that._skip && that._data.length && that._skip < that._data.length;\n if (that.options.endless) {\n if (replaceSubset) {\n that._pristineData.splice(that._skip, that._pristineData.length);\n }\n items = data.slice(0);\n for (var j = 0; j < items.length; j++) {\n that._pristineData.push(items[j]);\n }\n } else {\n that._pristineData = data.slice(0);\n }\n that._detachObservableParents();\n if (that.options.endless) {\n that._data.unbind(CHANGE, that._changeHandler);\n if (that._isServerGrouped() && that._data[that._data.length - 1].value === data[0].value) {\n fillLastGroup(that._data[that._data.length - 1], data[0]);\n data.shift();\n }\n data = that._observe(data);\n if (replaceSubset) {\n that._data.splice(that._skip, that._data.length);\n }\n for (var i = 0; i < data.length; i++) {\n that._data.push(data[i]);\n }\n that._data.bind(CHANGE, that._changeHandler);\n } else {\n that._data = that._observe(data);\n }\n that._markOfflineUpdatesAsDirty();\n that._storeData();\n that._addRange(that._data);\n that._process(that._data);\n that._dequeueRequest();\n },\n _detachObservableParents: function () {\n if (this._data && this._shouldDetachObservableParents) {\n for (var idx = 0; idx < this._data.length; idx++) {\n if (this._data[idx].parent) {\n this._data[idx].parent = noop;\n }\n }\n }\n },\n _storeData: function (updatePristine) {\n var serverGrouping = this._isServerGrouped();\n var model = this.reader.model;\n function items(data) {\n var state = [];\n for (var idx = 0; idx < data.length; idx++) {\n var dataItem = data.at(idx);\n var item = dataItem.toJSON();\n if (serverGrouping && dataItem.items) {\n item.items = items(dataItem.items);\n } else {\n item.uid = dataItem.uid;\n if (model) {\n if (dataItem.isNew()) {\n item.__state__ = 'create';\n } else if (dataItem.dirty) {\n item.__state__ = 'update';\n }\n }\n }\n state.push(item);\n }\n return state;\n }\n if (this.options.offlineStorage != null) {\n var state = items(this._data);\n var destroyed = [];\n for (var idx = 0; idx < this._destroyed.length; idx++) {\n var item = this._destroyed[idx].toJSON();\n item.__state__ = 'destroy';\n destroyed.push(item);\n }\n this.offlineData(state.concat(destroyed));\n if (updatePristine) {\n this._pristineData = this.reader.reader ? this.reader.reader._wrapDataAccessBase(state) : this.reader._wrapDataAccessBase(state);\n }\n }\n },\n _addRange: function (data, skip) {\n var that = this, start = typeof skip !== 'undefined' ? skip : that._skip || 0, end, range = {\n data: data,\n pristineData: data.toJSON(),\n timestamp: that._timeStamp()\n };\n if (this._isGroupPaged()) {\n end = start + data.length;\n range.outerStart = start;\n range.outerEnd = end;\n } else {\n end = start + that._flatData(data, true).length;\n }\n range.start = start;\n range.end = end;\n that._ranges.push(range);\n that._sortRanges();\n if (that._isGroupPaged()) {\n if (!that._groupsFlat) {\n that._groupsFlat = [];\n }\n that._appendToGroupsFlat(range.data);\n that._updateOuterRangesLength();\n }\n },\n _appendToGroupsFlat: function (data) {\n var length = data.length;\n for (var i = 0; i < length; i++) {\n this._groupsFlat.push(data[i]);\n }\n },\n _getGroupByUid: function (uid) {\n var length = this._groupsFlat.length;\n var group;\n for (var i = 0; i < length; i++) {\n group = this._groupsFlat[i];\n if (group.uid === uid) {\n return group;\n }\n }\n },\n _sortRanges: function () {\n this._ranges.sort(function (x, y) {\n return x.start - y.start;\n });\n },\n error: function (xhr, status, errorThrown) {\n this._dequeueRequest();\n this.trigger(REQUESTEND, {});\n this.trigger(ERROR, {\n xhr: xhr,\n status: status,\n errorThrown: errorThrown\n });\n },\n _params: function (data) {\n var that = this, options = extend({\n take: that.take(),\n skip: that.skip(),\n page: that.page(),\n pageSize: that.pageSize(),\n sort: that._sort,\n filter: that._filter,\n group: that._group,\n aggregate: that._aggregate,\n groupPaging: !!that._groupPaging\n }, data);\n if (!that.options.serverPaging) {\n delete options.take;\n delete options.skip;\n delete options.page;\n delete options.pageSize;\n }\n if (!that.options.serverGrouping) {\n delete options.group;\n } else if (that.reader.model && options.group) {\n options.group = convertDescriptorsField(options.group, that.reader.model);\n }\n if (!that.options.serverFiltering) {\n delete options.filter;\n } else if (that.reader.model && options.filter) {\n options.filter = convertFilterDescriptorsField(options.filter, that.reader.model);\n }\n if (!that.options.serverSorting) {\n delete options.sort;\n } else if (that.reader.model && options.sort) {\n options.sort = convertDescriptorsField(options.sort, that.reader.model);\n }\n if (!that.options.serverAggregates) {\n delete options.aggregate;\n } else if (that.reader.model && options.aggregate) {\n options.aggregate = convertDescriptorsField(options.aggregate, that.reader.model);\n }\n if (!that.options.groupPaging) {\n delete options.groupPaging;\n }\n return options;\n },\n _queueRequest: function (options, callback) {\n var that = this;\n if (!that._requestInProgress) {\n that._requestInProgress = true;\n that._pending = undefined;\n callback();\n } else {\n that._pending = {\n callback: proxy(callback, that),\n options: options\n };\n }\n },\n _dequeueRequest: function () {\n var that = this;\n that._requestInProgress = false;\n if (that._pending) {\n that._queueRequest(that._pending.options, that._pending.callback);\n }\n },\n _handleCustomErrors: function (response) {\n if (this.reader.errors) {\n var errors = this.reader.errors(response);\n if (errors) {\n this.trigger(ERROR, {\n xhr: null,\n status: 'customerror',\n errorThrown: 'custom error',\n errors: errors\n });\n return true;\n }\n }\n return false;\n },\n _shouldWrap: function (data) {\n var model = this.reader.model;\n if (model && data.length) {\n return !(data[0] instanceof model);\n }\n return false;\n },\n _observe: function (data) {\n var that = this, model = that.reader.model;\n that._shouldDetachObservableParents = true;\n if (data instanceof ObservableArray) {\n that._shouldDetachObservableParents = false;\n if (that._shouldWrap(data)) {\n data.type = that.reader.model;\n data.wrapAll(data, data);\n }\n } else {\n var arrayType = that.pageSize() && !that.options.serverPaging ? LazyObservableArray : ObservableArray;\n data = new arrayType(data, that.reader.model);\n data.parent = function () {\n return that.parent();\n };\n }\n if (that._isServerGrouped()) {\n wrapGroupItems(data, model);\n }\n if (that._changeHandler && that._data && that._data instanceof ObservableArray && !(that.options.useRanges && that.options.serverPaging)) {\n that._data.unbind(CHANGE, that._changeHandler);\n } else {\n that._changeHandler = proxy(that._change, that);\n }\n return data.bind(CHANGE, that._changeHandler);\n },\n _updateTotalForAction: function (action, items) {\n var that = this;\n var total = parseInt(that._total, 10);\n if (!isNumber(that._total)) {\n total = parseInt(that._pristineTotal, 10);\n }\n if (action === 'add') {\n total += items.length;\n } else if (action === 'remove') {\n total -= items.length;\n } else if (action !== 'itemchange' && action !== 'sync' && !that.options.serverPaging) {\n total = that._pristineTotal;\n } else if (action === 'sync') {\n total = that._pristineTotal = parseInt(that._total, 10);\n }\n that._total = total;\n },\n _change: function (e) {\n var that = this, idx, length, action = e ? e.action : '';\n if (action === 'remove') {\n for (idx = 0, length = e.items.length; idx < length; idx++) {\n if (!e.items[idx].isNew || !e.items[idx].isNew()) {\n that._destroyed.push(e.items[idx]);\n }\n }\n }\n if (that.options.autoSync && (action === 'add' || action === 'remove' || action === 'itemchange')) {\n var handler = function (args) {\n if (args.action === 'sync') {\n that.unbind('change', handler);\n that._updateTotalForAction(action, e.items);\n }\n };\n that.first('change', handler);\n that.sync();\n } else {\n that._updateTotalForAction(action, e ? e.items : []);\n that._process(that._data, e);\n }\n },\n _calculateAggregates: function (data, options) {\n options = options || {};\n var query = new Query(data), aggregates = options.aggregate, filter = options.filter;\n if (filter) {\n query = query.filter(filter);\n }\n return query.aggregate(aggregates);\n },\n _process: function (data, e) {\n var that = this, options = {}, result;\n if (that.options.serverPaging !== true) {\n options.skip = that._skip;\n options.take = that._take || that._pageSize;\n if (options.skip === undefined && that._page !== undefined && that._pageSize !== undefined) {\n options.skip = (that._page - 1) * that._pageSize;\n }\n if (that.options.useRanges) {\n options.skip = that.currentRangeStart();\n }\n }\n if (that.options.serverSorting !== true) {\n options.sort = that._sort;\n }\n if (that.options.serverFiltering !== true) {\n options.filter = that._filter;\n }\n if (that.options.serverGrouping !== true) {\n options.group = that._group;\n }\n if (that.options.serverAggregates !== true) {\n options.aggregate = that._aggregate;\n }\n if (that.options.serverGrouping) {\n that._clearEmptyGroups(data);\n }\n options.groupPaging = that._groupPaging;\n if (that._isGroupPaged() && e && (e.action === 'page' || e.action === 'expandGroup' || e.action === 'collapseGroup')) {\n result = that._queryProcess(data, { aggregate: that._aggregate });\n } else {\n result = that._queryProcess(data, options);\n }\n if (that.options.serverAggregates !== true) {\n that._aggregateResult = that._calculateAggregates(result.dataToAggregate || data, options);\n }\n that._setView(result, options, e);\n that._setFilterTotal(result.total, false);\n e = e || {};\n e.items = e.items || that._view;\n that.trigger(CHANGE, e);\n },\n _setView: function (result, options, e) {\n var that = this;\n if (that._isGroupPaged() && !that._isServerGrouped()) {\n if (e && (e.action === 'page' || e.action === 'expandGroup' || e.action === 'collapseGroup')) {\n that.view(result.data);\n that._updateOuterRangesLength();\n } else {\n that._ranges = [];\n var query = new Query(result.data);\n that._addRange(that._observe(result.data));\n if (options.skip + options.take > result.data.length) {\n options.skip = result.data.length - options.take;\n }\n that.view(query.range(options.skip, options.take).toArray());\n }\n } else {\n that.view(result.data);\n }\n },\n _clearEmptyGroups: function (data) {\n for (var idx = data.length - 1; idx >= 0; idx--) {\n var group = data[idx];\n if (group.hasSubgroups) {\n this._clearEmptyGroups(group.items);\n } else {\n if (group.items && !group.items.length) {\n splice.apply(group.parent(), [\n idx,\n 1\n ]);\n }\n }\n }\n },\n _queryProcess: function (data, options) {\n if (this.options.inPlaceSort) {\n return Query.process(data, options, this.options.inPlaceSort);\n } else {\n return Query.process(data, options);\n }\n },\n _mergeState: function (options) {\n var that = this;\n if (options !== undefined) {\n that._pageSize = options.pageSize;\n that._page = options.page;\n that._sort = options.sort;\n that._filter = options.filter;\n that._group = options.group;\n that._aggregate = options.aggregate;\n that._skip = that._currentRangeStart = options.skip;\n that._take = options.take;\n if (that._skip === undefined) {\n that._skip = that._currentRangeStart = that.skip();\n options.skip = that.skip();\n }\n if (that._take === undefined && that._pageSize !== undefined) {\n that._take = that._pageSize;\n options.take = that._take;\n }\n if (options.sort) {\n that._sort = options.sort = normalizeSort(options.sort);\n that._sortFields = sortFields(options.sort);\n }\n if (options.filter) {\n that._filter = options.filter = that.options.accentFoldingFiltering && !$.isEmptyObject(options.filter) ? $.extend({}, normalizeFilter(options.filter), { accentFoldingFiltering: that.options.accentFoldingFiltering }) : normalizeFilter(options.filter);\n }\n if (options.group) {\n that._group = options.group = normalizeGroup(options.group);\n }\n if (options.aggregate) {\n that._aggregate = options.aggregate = normalizeAggregate(options.aggregate);\n }\n }\n return options;\n },\n query: function (options) {\n var result;\n var remote = this.options.serverSorting || this.options.serverPaging || this.options.serverFiltering || this.options.serverGrouping || this.options.serverAggregates;\n if (remote || (this._data === undefined || this._data.length === 0) && !this._destroyed.length) {\n if (this.options.endless) {\n var moreItemsCount = options.pageSize - this.pageSize();\n if (moreItemsCount > 0) {\n moreItemsCount = this.pageSize();\n options.page = options.pageSize / moreItemsCount;\n options.pageSize = moreItemsCount;\n } else {\n options.page = 1;\n this.options.endless = false;\n }\n }\n return this.read(this._mergeState(options));\n }\n var isPrevented = this.trigger(REQUESTSTART, { type: 'read' });\n if (!isPrevented) {\n this.trigger(PROGRESS);\n if (options) {\n options.groupPaging = this._groupPaging;\n }\n result = this._queryProcess(this._data, this._mergeState(options));\n this._setFilterTotal(result.total, true);\n this._aggregateResult = this._calculateAggregates(result.dataToAggregate || this._data, options);\n this._setView(result, options);\n this.trigger(REQUESTEND, { type: 'read' });\n this.trigger(CHANGE, {\n items: result.data,\n action: options ? options.action : ''\n });\n }\n return $.Deferred().resolve(isPrevented).promise();\n },\n _hasExpandedSubGroups: function (group) {\n var result = false;\n var length = group.items ? group.items.length : 0;\n if (!group.hasSubgroups) {\n return false;\n }\n for (var i = 0; i < length; i++) {\n if (this._groupsState[group.items[i].uid]) {\n result = true;\n break;\n }\n }\n return result;\n },\n _findGroupedRange: function (data, result, options, parents, callback) {\n var that = this;\n var length = data.length;\n var group;\n var current;\n var itemsLength;\n var hasNotRequestedItems;\n var groupCount;\n var itemsToSkip;\n for (var i = 0; i < length; i++) {\n group = data[i];\n if (options.taken >= options.take) {\n break;\n }\n if (!that._getGroupByUid(group.uid)) {\n that._groupsFlat.push(group);\n }\n if (that._groupsState[group.uid]) {\n if (that._isServerGroupPaged()) {\n if (group.hasSubgroups && !group.subgroupCount) {\n that.getGroupSubGroupCount(group, options, parents, callback);\n that._fetchingGroupItems = true;\n return;\n }\n groupCount = (group.subgroupCount || group.itemCount) + 1;\n itemsToSkip = options.skip - options.skipped;\n hasNotRequestedItems = !group.items || group.items.length - itemsToSkip < options.take - options.taken;\n if (!that._hasExpandedSubGroups(group) && itemsToSkip > groupCount) {\n options.skipped += groupCount;\n continue;\n }\n if (group.hasSubgroups && (!group.items || hasNotRequestedItems && group.items.length < group.subgroupCount) || !group.hasSubgroups && (!group.items || hasNotRequestedItems && group.items.length < group.itemCount)) {\n that.getGroupItems(group, options, parents, callback);\n that._fetchingGroupItems = true;\n return;\n }\n }\n if (options.includeParents && options.skipped < options.skip) {\n options.skipped++;\n group.excludeHeader = true;\n } else if (options.includeParents) {\n options.taken++;\n }\n if (group.hasSubgroups && group.items && group.items.length) {\n group.currentItems = [];\n if (!parents) {\n parents = [];\n }\n parents.push(group);\n that._findGroupedRange(group.items, group.currentItems, options, parents, callback);\n parents.pop();\n if (group.currentItems.length || options.taken > 0) {\n result.push(group);\n } else {\n group.excludeHeader = false;\n }\n } else {\n current = [];\n itemsLength = group.items.length;\n for (var j = 0; j < itemsLength; j++) {\n if (options.skipped < options.skip) {\n options.skipped++;\n continue;\n }\n if (options.taken >= options.take) {\n break;\n }\n current.push(group.items[j]);\n options.taken++;\n }\n if (current.length || options.taken > 0) {\n group.currentItems = current;\n result.push(group);\n } else {\n group.excludeHeader = false;\n }\n }\n } else {\n if (options.skipped < options.skip) {\n options.skipped++;\n continue;\n }\n result.push(group);\n options.taken++;\n }\n }\n },\n getGroupItems: function (group, options, parents, callback) {\n var that = this;\n var skip;\n var take;\n var filter;\n var data;\n var subgroups;\n if (!group.items) {\n group.items = [];\n }\n skip = group.items.length;\n take = that.take();\n filter = this._composeItemsFilter(group, parents);\n data = {\n page: math.floor((skip || 0) / (take || 1)) || 1,\n pageSize: take,\n skip: skip,\n take: take,\n filter: filter,\n aggregate: that._aggregate,\n sort: that._sort\n };\n subgroups = that.findSubgroups(group);\n if (subgroups && subgroups.length) {\n data.group = subgroups;\n data.groupPaging = true;\n }\n clearTimeout(that._timeout);\n that._timeout = setTimeout(function () {\n that._queueRequest(data, function () {\n if (!that.trigger(REQUESTSTART, { type: 'read' })) {\n that.transport.read({\n data: data,\n success: that._groupItemsSuccessHandler(group, options.skip, that.take(), callback),\n error: function () {\n var args = slice.call(arguments);\n that.error.apply(that, args);\n }\n });\n } else {\n that._dequeueRequest();\n }\n });\n }, 100);\n },\n getGroupSubGroupCount: function (group, options, parents, callback) {\n var that = this;\n var filter;\n var groupIndex;\n var data;\n if (!group.items) {\n group.items = [];\n }\n filter = this._composeItemsFilter(group, parents);\n groupIndex = this._group.map(function (g) {\n return g.field;\n }).indexOf(group.field);\n data = {\n filter: filter,\n group: [that._group[groupIndex + 1]],\n groupPaging: true,\n includeSubGroupCount: true\n };\n clearTimeout(that._timeout);\n that._timeout = setTimeout(function () {\n that._queueRequest(data, function () {\n if (!that.trigger(REQUESTSTART, { type: 'read' })) {\n that.transport.read({\n data: data,\n success: that._subGroupCountSuccessHandler(group, options.skip, that.take(), callback),\n error: function () {\n var args = slice.call(arguments);\n that.error.apply(that, args);\n }\n });\n } else {\n that._dequeueRequest();\n }\n });\n }, 100);\n },\n _subGroupCountSuccessHandler: function (group, skip, take, callback) {\n var that = this;\n callback = isFunction(callback) ? callback : noop;\n var totalField = that.options.schema && that.options.schema.total ? that.options.schema.total : 'Total';\n return function (data) {\n that._dequeueRequest();\n that.trigger(REQUESTEND, {\n response: data,\n type: 'read'\n });\n that._fetchingGroupItems = false;\n if (isFunction(totalField)) {\n group.subgroupCount = totalField(data);\n } else {\n group.subgroupCount = data[totalField];\n }\n that.range(skip, take, callback, 'expandGroup');\n };\n },\n _groupItemsSuccessHandler: function (group, skip, take, callback) {\n var that = this;\n var timestamp = that._timeStamp();\n callback = isFunction(callback) ? callback : noop;\n return function (data) {\n var temp;\n var model = Model.define(that.options.schema.model);\n that._dequeueRequest();\n that.trigger(REQUESTEND, {\n response: data,\n type: 'read'\n });\n data = that.reader.parse(data);\n if (group.hasSubgroups) {\n temp = that.reader.groups(data);\n } else {\n temp = that.reader.data(data);\n temp = temp.map(function (item) {\n return new model(item);\n });\n }\n group.items.omitChangeEvent = true;\n for (var i = 0; i < temp.length; i++) {\n group.items.push(temp[i]);\n }\n group.items.omitChangeEvent = false;\n that._updateRangePristineData(group);\n that._fetchingGroupItems = false;\n that._serverGroupsTotal += temp.length;\n that.range(skip, take, callback, 'expandGroup');\n if (timestamp >= that._currentRequestTimeStamp || !that._skipRequestsInProgress) {\n that.trigger(CHANGE, {});\n }\n };\n },\n findSubgroups: function (group) {\n var indexOfCurrentGroup = this._group.map(function (g) {\n return g.field;\n }).indexOf(group.field);\n return this._group.slice(indexOfCurrentGroup + 1, this._group.length);\n },\n _composeItemsFilter: function (group, parents) {\n var filter = this.filter() || {\n logic: 'and',\n filters: []\n };\n filter = extend(true, {}, filter);\n filter.filters.push({\n field: group.field,\n operator: 'eq',\n value: group.value\n });\n if (parents) {\n for (var i = 0; i < parents.length; i++) {\n filter.filters.push({\n field: parents[i].field,\n operator: 'eq',\n value: parents[i].value\n });\n }\n }\n return filter;\n },\n _updateRangePristineData: function (group) {\n var that = this;\n var ranges = that._ranges;\n var rangesLength = ranges.length;\n var temp;\n var currentGroup;\n var range;\n var dataLength;\n var indexes;\n for (var i = 0; i < rangesLength; i++) {\n range = ranges[i];\n dataLength = range.data.length;\n indexes = [];\n for (var j = 0; j < dataLength; j++) {\n currentGroup = range.data[j];\n indexes.push(j);\n if (currentGroup.uid === group.uid || currentGroup.hasSubgroups && currentGroup.items.length && that._containsSubGroup(currentGroup, group, indexes)) {\n break;\n }\n indexes.pop();\n }\n if (indexes.length) {\n temp = ranges[i].pristineData;\n while (indexes.length > 1) {\n temp = temp[indexes.splice(0, 1)[0]].items;\n }\n temp[indexes[0]] = that._cloneGroup(group);\n break;\n }\n }\n },\n _containsSubGroup: function (group, subgroup, indexes) {\n var that = this;\n var length = group.items.length;\n var currentSubGroup;\n if (group.hasSubgroups && length) {\n for (var i = 0; i < length; i++) {\n currentSubGroup = group.items[i];\n indexes.push(i);\n if (currentSubGroup.uid === subgroup.uid) {\n return true;\n } else if (currentSubGroup.hasSubgroups && currentSubGroup.items.length) {\n return that._containsSubGroup(currentSubGroup, subgroup, indexes);\n }\n indexes.pop();\n }\n }\n },\n _cloneGroup: function (group) {\n var that = this;\n group = typeof group.toJSON == 'function' ? group.toJSON() : group;\n if (group.items && group.items.length) {\n group.items = group.items.map(function (item) {\n return that._cloneGroup(item);\n });\n }\n return group;\n },\n _setFilterTotal: function (filterTotal, setDefaultValue) {\n var that = this;\n if (!that.options.serverFiltering) {\n if (filterTotal !== undefined) {\n that._total = filterTotal;\n } else if (setDefaultValue) {\n that._total = that._data.length;\n }\n }\n },\n fetch: function (callback) {\n var that = this;\n var fn = function (isPrevented) {\n if (isPrevented !== true && isFunction(callback)) {\n callback.call(that);\n }\n };\n return this._query().done(fn);\n },\n _query: function (options) {\n var that = this;\n return that.query(extend({}, {\n page: that.page(),\n pageSize: that.pageSize(),\n sort: that.sort(),\n filter: that.filter(),\n group: that.group(),\n aggregate: that.aggregate()\n }, options));\n },\n next: function (options) {\n var that = this, page = that.page(), total = that.total();\n options = options || {};\n if (!page || total && page + 1 > that.totalPages()) {\n return;\n }\n that._skip = that._currentRangeStart = page * that.take();\n page += 1;\n options.page = page;\n that._query(options);\n return page;\n },\n prev: function (options) {\n var that = this, page = that.page();\n options = options || {};\n if (!page || page === 1) {\n return;\n }\n that._skip = that._currentRangeStart = that._skip - that.take();\n page -= 1;\n options.page = page;\n that._query(options);\n return page;\n },\n page: function (val) {\n var that = this, skip;\n if (val !== undefined) {\n val = math.max(math.min(math.max(val, 1), that.totalPages()), 1);\n var take = that.take();\n if (that._isGroupPaged()) {\n val -= 1;\n that.range(val * take, take, null, 'page');\n return;\n }\n that._query(that._pageableQueryOptions({ page: val }));\n return;\n }\n skip = that.skip();\n return skip !== undefined ? math.round((skip || 0) / (that.take() || 1)) + 1 : undefined;\n },\n pageSize: function (val) {\n var that = this;\n if (val !== undefined) {\n that._query(that._pageableQueryOptions({\n pageSize: val,\n page: 1\n }));\n return;\n }\n return that.take();\n },\n sort: function (val) {\n var that = this;\n if (val !== undefined) {\n that.trigger('sort');\n that._query({ sort: val });\n return;\n }\n return that._sort;\n },\n filter: function (val) {\n var that = this;\n if (val === undefined) {\n return that._filter;\n }\n that.trigger('reset');\n that._query({\n filter: val,\n page: 1\n });\n },\n group: function (val) {\n var that = this;\n var options = { group: val };\n if (that._groupPaging) {\n options.page = 1;\n }\n if (val !== undefined) {\n that._query(options);\n return;\n }\n return that._group;\n },\n getGroupsFlat: function (data) {\n var idx, result = [], length;\n for (idx = 0, length = data.length; idx < length; idx++) {\n var group = data[idx];\n if (group.hasSubgroups) {\n result = result.concat(this.getGroupsFlat(group.items));\n }\n result.push(group);\n }\n return result;\n },\n total: function () {\n return parseInt(this._total || 0, 10);\n },\n groupsTotal: function (includeExpanded) {\n var that = this;\n if (!that._group.length) {\n return that.total();\n }\n if (that._isServerGrouped()) {\n if (that._serverGroupsTotal) {\n return that._serverGroupsTotal;\n }\n that._serverGroupsTotal = that.total();\n return that._serverGroupsTotal;\n }\n return that._calculateGroupsTotal(that._ranges.length ? that._ranges[0].data : [], includeExpanded);\n },\n _calculateGroupsTotal: function (groups, includeExpanded, itemsField, ignoreState) {\n var that = this;\n itemsField = itemsField || 'items';\n var total;\n var length;\n if (that._group.length && groups) {\n total = 0;\n length = groups.length;\n for (var i = 0; i < length; i++) {\n total += that.groupCount(groups[i], includeExpanded, itemsField, ignoreState);\n }\n that._groupsTotal = total;\n return total;\n }\n that._groupsTotal = that._data.length;\n return that._groupsTotal;\n },\n groupCount: function (group, includeExpanded, itemsField, ignoreState) {\n var that = this;\n var total = 0;\n if (group.hasSubgroups && that._groupsState[group.uid]) {\n if (includeExpanded && !group.excludeHeader || ignoreState) {\n total += 1;\n }\n group[itemsField].forEach(function (subgroup) {\n total += that.groupCount(subgroup, includeExpanded, itemsField, ignoreState);\n });\n } else {\n if (that._groupsState[group.uid]) {\n if (includeExpanded && !group.excludeHeader || ignoreState) {\n total++;\n }\n total += group[itemsField] ? group[itemsField].length : 0;\n } else {\n total++;\n }\n }\n return total;\n },\n countGroupRange: function (range) {\n var total = 0;\n var length = range.length;\n for (var i = 0; i < length; i++) {\n total += this.groupCount(range[i], true);\n }\n return total;\n },\n aggregate: function (val) {\n var that = this;\n if (val !== undefined) {\n that._query({ aggregate: val });\n return;\n }\n return that._aggregate;\n },\n aggregates: function () {\n var result = this._aggregateResult;\n if (isEmptyObject(result)) {\n result = this._emptyAggregates(this.aggregate());\n }\n return result;\n },\n _emptyAggregates: function (aggregates) {\n var result = {};\n if (!isEmptyObject(aggregates)) {\n var aggregate = {};\n if (!isArray(aggregates)) {\n aggregates = [aggregates];\n }\n for (var idx = 0; idx < aggregates.length; idx++) {\n aggregate[aggregates[idx].aggregate] = 0;\n result[aggregates[idx].field] = aggregate;\n }\n }\n return result;\n },\n _pageableQueryOptions: function (options) {\n return options;\n },\n _wrapInEmptyGroup: function (model) {\n var groups = this.group(), parent, group, idx, length;\n for (idx = groups.length - 1, length = 0; idx >= length; idx--) {\n group = groups[idx];\n parent = {\n value: model.get ? model.get(group.field) : model[group.field],\n field: group.field,\n items: parent ? [parent] : [model],\n hasSubgroups: !!parent,\n aggregates: this._emptyAggregates(group.aggregates)\n };\n }\n return parent;\n },\n totalPages: function () {\n var that = this, pageSize = that.pageSize() || that.total(), total = that._isGroupPaged() ? that.groupsTotal(true) : that.total();\n return math.ceil((total || 0) / pageSize);\n },\n inRange: function (skip, take) {\n var that = this, end = math.min(skip + take, that.total());\n if (!that.options.serverPaging && that._data.length > 0) {\n return true;\n }\n return that._findRange(skip, end).length > 0;\n },\n lastRange: function () {\n var ranges = this._ranges;\n return ranges[ranges.length - 1] || {\n start: 0,\n end: 0,\n data: []\n };\n },\n firstItemUid: function () {\n var ranges = this._ranges;\n return ranges.length && ranges[0].data.length && ranges[0].data[0].uid;\n },\n enableRequestsInProgress: function () {\n this._skipRequestsInProgress = false;\n },\n _timeStamp: function () {\n return new Date().getTime();\n },\n range: function (skip, take, callback, action) {\n this._currentRequestTimeStamp = this._timeStamp();\n this._skipRequestsInProgress = true;\n var total = this._isGroupPaged() ? this.groupsTotal(true) : this.total();\n if (action === 'expandGroup' || action === 'collapseGroup') {\n this._updateOuterRangesLength();\n }\n skip = math.min(skip || 0, total);\n callback = isFunction(callback) ? callback : noop;\n var that = this, pageSkip = math.max(math.floor(skip / take), 0) * take, size = math.min(pageSkip + take, total), data;\n data = that._findRange(skip, math.min(skip + take, total), callback);\n if ((data.length || total === 0) && !that._fetchingGroupItems) {\n that._processRangeData(data, skip, take, that._originalPageSkip || pageSkip, that._originalSize || size, { action: action });\n that._originalPageSkip = null;\n that._originalSize = null;\n callback();\n return;\n }\n if (that._isGroupPaged()) {\n that._originalPageSkip = pageSkip;\n that._originalSize = size;\n pageSkip = math.max(math.floor(that._adjustPageSkip(skip, take) / take), 0) * take;\n size = math.min(pageSkip + take, total);\n }\n if (take !== undefined && !that._fetchingGroupItems) {\n if (that._isGroupPaged() && !that._groupRangeExists(pageSkip, take) || !that._rangeExists(pageSkip, size)) {\n that.prefetch(pageSkip, take, function () {\n if (skip > pageSkip && size < that.total() && !that._rangeExists(size, math.min(size + take, that.total()))) {\n that.prefetch(size, take, function () {\n that.range(skip, take, callback);\n });\n } else {\n that.range(skip, take, callback);\n }\n });\n } else if (pageSkip < skip) {\n that.prefetch(size, take, function () {\n that.range(skip, take, callback);\n });\n }\n }\n },\n _findRange: function (start, end, callback) {\n var that = this, ranges = that._ranges, range, data = [], skipIdx, takeIdx, startIndex, endIndex, rangeData, rangeEnd, processed, options = that.options, remote = options.serverSorting || options.serverPaging || options.serverFiltering || options.serverGrouping || options.serverAggregates, flatData, count, length, groupMapOptions = {\n take: end - start,\n skip: start,\n skipped: 0,\n taken: 0,\n includeParents: true\n }, prevRangeEnd, isGroupPaged = that._isGroupPaged(), startField = isGroupPaged ? 'outerStart' : 'start', endField = isGroupPaged ? 'outerEnd' : 'end', currentDataLength;\n for (skipIdx = 0, length = ranges.length; skipIdx < length; skipIdx++) {\n range = ranges[skipIdx];\n if (isGroupPaged) {\n if (range.outerStart >= end) {\n return [];\n }\n if (start > range.outerEnd) {\n groupMapOptions.skipped += range.outerEnd - (prevRangeEnd || 0);\n prevRangeEnd = range.outerEnd;\n continue;\n }\n if (typeof prevRangeEnd !== 'undefined' && prevRangeEnd != range.outerStart) {\n groupMapOptions.skipped += range.outerStart - prevRangeEnd;\n }\n if (groupMapOptions.skipped > groupMapOptions.skip) {\n return [];\n }\n if (typeof prevRangeEnd === 'undefined' && start > 0 && range.start > 0) {\n groupMapOptions.skipped = range.outerStart;\n }\n takeIdx = skipIdx;\n while (true) {\n this._findGroupedRange(range.data, data, groupMapOptions, null, callback);\n currentDataLength = that._calculateGroupsTotal(data, true, 'currentItems');\n if (currentDataLength >= groupMapOptions.take) {\n return data;\n }\n if (that._fetchingGroupItems) {\n return [];\n }\n takeIdx++;\n if (ranges[takeIdx] && ranges[takeIdx].outerStart === range.outerEnd) {\n range = ranges[takeIdx];\n } else {\n break;\n }\n }\n } else if (start >= range[startField] && start <= range[endField]) {\n count = 0;\n for (takeIdx = skipIdx; takeIdx < length; takeIdx++) {\n range = ranges[takeIdx];\n flatData = that._flatData(range.data, true);\n if (flatData.length && start + count >= range.start) {\n rangeData = range.data;\n rangeEnd = range.end;\n if (!remote) {\n if (options.inPlaceSort) {\n processed = that._queryProcess(range.data, { filter: that.filter() });\n } else {\n var sort = normalizeGroupWithoutCompare(that.group() || []).concat(normalizeSort(that.sort() || []));\n processed = that._queryProcess(range.data, {\n sort: sort,\n filter: that.filter()\n });\n }\n flatData = rangeData = processed.data;\n if (processed.total !== undefined) {\n rangeEnd = processed.total;\n }\n }\n startIndex = 0;\n if (start + count > range.start) {\n startIndex = start + count - range.start;\n }\n endIndex = flatData.length;\n if (rangeEnd > end) {\n endIndex = endIndex - (rangeEnd - end);\n }\n count += endIndex - startIndex;\n data = that._mergeGroups(data, rangeData, startIndex, endIndex);\n if (end <= range.end && count == end - start) {\n return data;\n }\n }\n }\n break;\n }\n prevRangeEnd = range.outerEnd;\n }\n return [];\n },\n _getRangesMismatch: function (pageSkip) {\n var that = this;\n var ranges = that._ranges;\n var mismatch = 0;\n var i = 0;\n while (true) {\n var range = ranges[i];\n if (!range || range.outerStart > pageSkip) {\n break;\n }\n if (range.outerEnd != range.end) {\n mismatch = range.outerEnd - range.end;\n }\n i++;\n }\n return mismatch;\n },\n _mergeGroups: function (data, range, skip, take) {\n if (this._isServerGrouped()) {\n var temp = range.toJSON(), prevGroup;\n if (data.length) {\n prevGroup = data[data.length - 1];\n }\n mergeGroups(prevGroup, temp, skip, take);\n return data.concat(temp);\n }\n return data.concat(range.slice(skip, take));\n },\n _processRangeData: function (data, skip, take, pageSkip, size, eventData) {\n var that = this;\n that._pending = undefined;\n that._skip = skip > that.skip() && !that._omitPrefetch ? math.min(size, (that.totalPages() - 1) * that.take()) : pageSkip;\n that._currentRangeStart = skip;\n that._take = take;\n var paging = that.options.serverPaging;\n var sorting = that.options.serverSorting;\n var filtering = that.options.serverFiltering;\n var aggregates = that.options.serverAggregates;\n try {\n that.options.serverPaging = true;\n if (!that._isServerGrouped() && !(that.group() && that.group().length)) {\n that.options.serverSorting = true;\n }\n that.options.serverFiltering = true;\n that.options.serverPaging = true;\n that.options.serverAggregates = true;\n if (paging) {\n that._detachObservableParents();\n that._data = data = that._observe(data);\n }\n that._process(data, eventData);\n } finally {\n that.options.serverPaging = paging;\n that.options.serverSorting = sorting;\n that.options.serverFiltering = filtering;\n that.options.serverAggregates = aggregates;\n }\n },\n skip: function () {\n var that = this;\n if (that._skip === undefined) {\n return that._page !== undefined ? (that._page - 1) * (that.take() || 1) : undefined;\n }\n return that._skip;\n },\n currentRangeStart: function () {\n return this._currentRangeStart || 0;\n },\n take: function () {\n return this._take || this._pageSize;\n },\n _prefetchSuccessHandler: function (skip, size, callback, force) {\n var that = this;\n var timestamp = that._timeStamp();\n return function (data) {\n var found = false, range = {\n start: skip,\n end: size,\n data: [],\n timestamp: that._timeStamp()\n }, idx, length, temp;\n that._dequeueRequest();\n that.trigger(REQUESTEND, {\n response: data,\n type: 'read'\n });\n data = that.reader.parse(data);\n temp = that._readData(data);\n if (temp.length) {\n for (idx = 0, length = that._ranges.length; idx < length; idx++) {\n if (that._ranges[idx].start === skip) {\n found = true;\n range = that._ranges[idx];\n if (!that._isGroupPaged()) {\n range.pristineData = temp;\n range.data = that._observe(temp);\n range.end = range.start + that._flatData(range.data, true).length;\n that._sortRanges();\n }\n break;\n }\n }\n if (!found) {\n that._addRange(that._observe(temp), skip);\n }\n }\n that._total = that.reader.total(data);\n if (force || (timestamp >= that._currentRequestTimeStamp || !that._skipRequestsInProgress)) {\n if (callback && temp.length) {\n callback();\n } else {\n that.trigger(CHANGE, {});\n }\n }\n };\n },\n prefetch: function (skip, take, callback) {\n var that = this, size = math.min(skip + take, that.total()), options = {\n take: take,\n skip: skip,\n page: skip / take + 1,\n pageSize: take,\n sort: that._sort,\n filter: that._filter,\n group: that._group,\n aggregate: that._aggregate\n };\n if (that._isGroupPaged() && !that._isServerGrouped() && that._groupRangeExists(skip, size)) {\n if (callback) {\n callback();\n }\n return;\n }\n if (that._isServerGroupPaged() && !that._groupRangeExists(skip, size) || !that._rangeExists(skip, size)) {\n clearTimeout(that._timeout);\n that._timeout = setTimeout(function () {\n that._queueRequest(options, function () {\n if (!that.trigger(REQUESTSTART, { type: 'read' })) {\n if (that._omitPrefetch) {\n that.trigger(PROGRESS);\n }\n that.transport.read({\n data: that._params(options),\n success: that._prefetchSuccessHandler(skip, size, callback),\n error: function () {\n var args = slice.call(arguments);\n that.error.apply(that, args);\n }\n });\n } else {\n that._dequeueRequest();\n }\n });\n }, 100);\n } else if (callback) {\n callback();\n }\n },\n _multiplePrefetch: function (skip, take, callback) {\n var that = this, size = math.min(skip + take, that.total()), options = {\n take: take,\n skip: skip,\n page: skip / take + 1,\n pageSize: take,\n sort: that._sort,\n filter: that._filter,\n group: that._group,\n aggregate: that._aggregate\n };\n if (!that._rangeExists(skip, size)) {\n if (!that.trigger(REQUESTSTART, { type: 'read' })) {\n that.transport.read({\n data: that._params(options),\n success: that._prefetchSuccessHandler(skip, size, callback, true)\n });\n }\n } else if (callback) {\n callback();\n }\n },\n _adjustPageSkip: function (start, take) {\n var that = this;\n var prevRange = that._getPrevRange(start);\n var result;\n var total = that.total();\n var mismatch;\n if (prevRange) {\n mismatch = that._getRangesMismatch(start);\n if (!mismatch) {\n return start;\n }\n start -= mismatch;\n }\n result = math.max(math.floor(start / take), 0) * take;\n if (result > total) {\n while (true) {\n result -= take;\n if (result < total) {\n break;\n }\n }\n }\n return result;\n },\n _getNextRange: function (end) {\n var that = this, ranges = that._ranges, idx, length;\n for (idx = 0, length = ranges.length; idx < length; idx++) {\n if (ranges[idx].start <= end && ranges[idx].end >= end) {\n return ranges[idx];\n }\n }\n },\n _getPrevRange: function (start) {\n var that = this, ranges = that._ranges, idx, range, length = ranges.length;\n for (idx = length - 1; idx >= 0; idx--) {\n if (ranges[idx].outerStart <= start) {\n range = ranges[idx];\n break;\n }\n }\n return range;\n },\n _rangeExists: function (start, end) {\n var that = this, ranges = that._ranges, idx, length;\n for (idx = 0, length = ranges.length; idx < length; idx++) {\n if (ranges[idx].start <= start && ranges[idx].end >= end) {\n return true;\n }\n }\n return false;\n },\n _groupRangeExists: function (start, end) {\n var that = this, ranges = that._ranges, idx, length, availableItemsCount = 0, total = that.groupsTotal(true);\n if (end > total && !that._isServerGrouped()) {\n end = total;\n }\n for (idx = 0, length = ranges.length; idx < length; idx++) {\n var range = ranges[idx];\n if (range.outerStart <= start && range.outerEnd >= start) {\n availableItemsCount += range.outerEnd - start;\n } else if (range.outerStart <= end && range.outerEnd >= end) {\n availableItemsCount += end - range.outerStart;\n }\n }\n return availableItemsCount >= end - start;\n },\n _getCurrentRangeSpan: function () {\n var that = this;\n var ranges = that._ranges;\n var start = that.currentRangeStart();\n var end = start + (that.take() || 0);\n var rangeSpan = [];\n var range;\n var idx;\n var length = ranges.length;\n for (idx = 0; idx < length; idx++) {\n range = ranges[idx];\n if (range.start <= start && range.end >= start || range.start >= start && range.start <= end) {\n rangeSpan.push(range);\n }\n }\n return rangeSpan;\n },\n _removeModelFromRanges: function (model) {\n var that = this;\n var range;\n for (var idx = 0, length = this._ranges.length; idx < length; idx++) {\n range = this._ranges[idx];\n that._removeModelFromRange(range, model);\n }\n that._updateRangesLength();\n },\n _removeModelFromRange: function (range, model) {\n this._eachItem(range.data, function (data) {\n if (!data) {\n return;\n }\n for (var idx = 0; idx < data.length; idx++) {\n var dataItem = data[idx];\n if (dataItem.uid && dataItem.uid == model.uid) {\n [].splice.call(data, idx, 1);\n break;\n }\n }\n });\n },\n _insertModelInRange: function (index, model) {\n var that = this;\n var ranges = that._ranges || [];\n var rangesLength = ranges.length;\n var range;\n var i;\n for (i = 0; i < rangesLength; i++) {\n range = ranges[i];\n if (range.start <= index && range.end >= index) {\n if (!that._getByUid(model.uid, range.data)) {\n if (that._isServerGrouped()) {\n range.data.splice(index, 0, that._wrapInEmptyGroup(model));\n } else {\n range.data.splice(index, 0, model);\n }\n }\n break;\n }\n }\n that._updateRangesLength();\n },\n _updateRangesLength: function () {\n var that = this;\n var ranges = that._ranges || [];\n var rangesLength = ranges.length;\n var mismatchFound = false;\n var mismatchLength = 0;\n var lengthDifference = 0;\n var rangeLength;\n var range;\n var i;\n for (i = 0; i < rangesLength; i++) {\n range = ranges[i];\n rangeLength = that._isGroupPaged() ? range.data.length : that._flatData(range.data, true).length;\n lengthDifference = rangeLength - math.abs(range.end - range.start);\n if (!mismatchFound && lengthDifference !== 0) {\n mismatchFound = true;\n mismatchLength = lengthDifference;\n range.end += mismatchLength;\n continue;\n }\n if (mismatchFound) {\n range.start += mismatchLength;\n range.end += mismatchLength;\n }\n }\n },\n _updateOuterRangesLength: function () {\n var that = this;\n var ranges = that._ranges || [];\n var rangesLength = ranges.length;\n var mismatchLength = 0;\n var range;\n var i;\n var prevRange;\n var rangeLength;\n for (i = 0; i < rangesLength; i++) {\n range = ranges[i];\n rangeLength = that._isGroupPaged() ? that._calculateGroupsTotal(range.data, true, 'items', true) : that._flatData(range.data, true).length;\n if (prevRange) {\n if (prevRange.end != range.start) {\n mismatchLength = range.start - prevRange.end;\n }\n range.outerStart = prevRange.outerEnd + mismatchLength;\n mismatchLength = 0;\n } else {\n range.outerStart = range.start;\n }\n range.outerEnd = range.outerStart + rangeLength;\n prevRange = range;\n }\n }\n });\n var Transport = {};\n Transport.create = function (options, data, dataSource) {\n var transport, transportOptions = options.transport ? $.extend({}, options.transport) : null;\n if (transportOptions) {\n transportOptions.read = typeof transportOptions.read === STRING ? { url: transportOptions.read } : transportOptions.read;\n if (options.type === 'jsdo') {\n transportOptions.dataSource = dataSource;\n }\n if (options.type) {\n kendo.data.transports = kendo.data.transports || {};\n kendo.data.schemas = kendo.data.schemas || {};\n if (!kendo.data.transports[options.type]) {\n kendo.logToConsole('Unknown DataSource transport type \\'' + options.type + '\\'.\\nVerify that registration scripts for this type are included after Kendo UI on the page.', 'warn');\n } else if (!isPlainObject(kendo.data.transports[options.type])) {\n transport = new kendo.data.transports[options.type](extend(transportOptions, { data: data }));\n } else {\n transportOptions = extend(true, {}, kendo.data.transports[options.type], transportOptions);\n }\n options.schema = extend(true, {}, kendo.data.schemas[options.type], options.schema);\n }\n if (!transport) {\n transport = isFunction(transportOptions.read) ? transportOptions : new RemoteTransport(transportOptions);\n }\n } else {\n transport = new LocalTransport({ data: options.data || [] });\n }\n return transport;\n };\n DataSource.create = function (options) {\n if (isArray(options) || options instanceof ObservableArray) {\n options = { data: options };\n }\n var dataSource = options || {}, data = dataSource.data, fields = dataSource.fields, table = dataSource.table, select = dataSource.select, idx, length, model = {}, field;\n if (!data && fields && !dataSource.transport) {\n if (table) {\n data = inferTable(table, fields);\n } else if (select) {\n data = inferSelect(select, fields);\n if (dataSource.group === undefined && data[0] && data[0].optgroup !== undefined) {\n dataSource.group = 'optgroup';\n }\n }\n }\n if (kendo.data.Model && fields && (!dataSource.schema || !dataSource.schema.model)) {\n for (idx = 0, length = fields.length; idx < length; idx++) {\n field = fields[idx];\n if (field.type) {\n model[field.field] = field;\n }\n }\n if (!isEmptyObject(model)) {\n dataSource.schema = extend(true, dataSource.schema, { model: { fields: model } });\n }\n }\n dataSource.data = data;\n select = null;\n dataSource.select = null;\n table = null;\n dataSource.table = null;\n return dataSource instanceof DataSource ? dataSource : new DataSource(dataSource);\n };\n function inferSelect(select, fields) {\n select = $(select)[0];\n var options = select.options;\n var firstField = fields[0];\n var secondField = fields[1];\n var data = [];\n var idx, length;\n var optgroup;\n var option;\n var record;\n var value;\n for (idx = 0, length = options.length; idx < length; idx++) {\n record = {};\n option = options[idx];\n optgroup = option.parentNode;\n if (optgroup === select) {\n optgroup = null;\n }\n if (option.disabled || optgroup && optgroup.disabled) {\n continue;\n }\n if (optgroup) {\n record.optgroup = optgroup.label;\n }\n record[firstField.field] = option.text;\n value = option.attributes.value;\n if (value && value.specified) {\n value = option.value;\n } else {\n value = option.text;\n }\n record[secondField.field] = value;\n data.push(record);\n }\n return data;\n }\n function inferTable(table, fields) {\n var tbody = $(table)[0].tBodies[0], rows = tbody ? tbody.rows : [], idx, length, fieldIndex, fieldCount = fields.length, data = [], cells, record, cell, empty;\n for (idx = 0, length = rows.length; idx < length; idx++) {\n record = {};\n empty = true;\n cells = rows[idx].cells;\n for (fieldIndex = 0; fieldIndex < fieldCount; fieldIndex++) {\n cell = cells[fieldIndex];\n if (cell.nodeName.toLowerCase() !== 'th') {\n empty = false;\n record[fields[fieldIndex].field] = cell.innerHTML;\n }\n }\n if (!empty) {\n data.push(record);\n }\n }\n return data;\n }\n var Node = Model.define({\n idField: 'id',\n init: function (value) {\n var that = this, hasChildren = that.hasChildren || value && value.hasChildren, childrenField = 'items', childrenOptions = {};\n kendo.data.Model.fn.init.call(that, value);\n if (typeof that.children === STRING) {\n childrenField = that.children;\n }\n childrenOptions = {\n schema: {\n data: childrenField,\n model: {\n hasChildren: hasChildren,\n id: that.idField,\n fields: that.fields\n }\n }\n };\n if (typeof that.children !== STRING) {\n extend(childrenOptions, that.children);\n }\n childrenOptions.data = value;\n if (!hasChildren) {\n hasChildren = childrenOptions.schema.data;\n }\n if (typeof hasChildren === STRING) {\n hasChildren = kendo.getter(hasChildren);\n }\n if (isFunction(hasChildren)) {\n var hasChildrenObject = hasChildren.call(that, that);\n if (hasChildrenObject && hasChildrenObject.length === 0) {\n that.hasChildren = false;\n } else {\n that.hasChildren = !!hasChildrenObject;\n }\n }\n that._childrenOptions = childrenOptions;\n if (that.hasChildren) {\n that._initChildren();\n }\n that._loaded = !!(value && value._loaded);\n },\n _initChildren: function () {\n var that = this;\n var children, transport, parameterMap;\n if (!(that.children instanceof HierarchicalDataSource)) {\n children = that.children = new HierarchicalDataSource(that._childrenOptions);\n transport = children.transport;\n parameterMap = transport.parameterMap;\n transport.parameterMap = function (data, type) {\n data[that.idField || 'id'] = that.id;\n if (parameterMap) {\n data = parameterMap.call(that, data, type);\n }\n return data;\n };\n children.parent = function () {\n return that;\n };\n children.bind(CHANGE, function (e) {\n e.node = e.node || that;\n that.trigger(CHANGE, e);\n });\n children.bind(ERROR, function (e) {\n var collection = that.parent();\n if (collection) {\n e.node = e.node || that;\n collection.trigger(ERROR, e);\n }\n });\n that._updateChildrenField();\n }\n },\n append: function (model) {\n this._initChildren();\n this.loaded(true);\n this.children.add(model);\n },\n hasChildren: false,\n level: function () {\n var parentNode = this.parentNode(), level = 0;\n while (parentNode && parentNode.parentNode) {\n level++;\n parentNode = parentNode.parentNode ? parentNode.parentNode() : null;\n }\n return level;\n },\n _updateChildrenField: function () {\n var fieldName = this._childrenOptions.schema.data;\n this[fieldName || 'items'] = this.children.data();\n },\n _childrenLoaded: function () {\n this._loaded = true;\n this._updateChildrenField();\n },\n load: function () {\n var options = {};\n var method = '_query';\n var children, promise;\n if (this.hasChildren) {\n this._initChildren();\n children = this.children;\n options[this.idField || 'id'] = this.id;\n if (!this._loaded) {\n children._data = undefined;\n method = 'read';\n }\n children.one(CHANGE, proxy(this._childrenLoaded, this));\n if (this._matchFilter) {\n options.filter = {\n field: '_matchFilter',\n operator: 'eq',\n value: true\n };\n }\n promise = children[method](options);\n } else {\n this.loaded(true);\n }\n return promise || $.Deferred().resolve().promise();\n },\n parentNode: function () {\n var array = this.parent();\n return array.parent();\n },\n loaded: function (value) {\n if (value !== undefined) {\n this._loaded = value;\n } else {\n return this._loaded;\n }\n },\n shouldSerialize: function (field) {\n return Model.fn.shouldSerialize.call(this, field) && field !== 'children' && field !== '_loaded' && field !== 'hasChildren' && field !== '_childrenOptions';\n }\n });\n function dataMethod(name) {\n return function () {\n var data = this._data, result = DataSource.fn[name].apply(this, slice.call(arguments));\n if (this._data != data) {\n this._attachBubbleHandlers();\n }\n return result;\n };\n }\n var HierarchicalDataSource = DataSource.extend({\n init: function (options) {\n var node = Node.define({ children: options });\n if (options.filter && !options.serverFiltering) {\n this._hierarchicalFilter = options.filter;\n options.filter = null;\n }\n DataSource.fn.init.call(this, extend(true, {}, {\n schema: {\n modelBase: node,\n model: node\n }\n }, options));\n this._attachBubbleHandlers();\n },\n _attachBubbleHandlers: function () {\n var that = this;\n that._data.bind(ERROR, function (e) {\n that.trigger(ERROR, e);\n });\n },\n read: function (data) {\n var result = DataSource.fn.read.call(this, data);\n if (this._hierarchicalFilter) {\n if (this._data && this._data.length > 0) {\n this.filter(this._hierarchicalFilter);\n } else {\n this.options.filter = this._hierarchicalFilter;\n this._filter = normalizeFilter(this.options.filter);\n this._hierarchicalFilter = null;\n }\n }\n return result;\n },\n remove: function (node) {\n var parentNode = node.parentNode(), dataSource = this, result;\n if (parentNode && parentNode._initChildren) {\n dataSource = parentNode.children;\n }\n result = DataSource.fn.remove.call(dataSource, node);\n if (parentNode && !dataSource.data().length) {\n parentNode.hasChildren = false;\n }\n return result;\n },\n success: dataMethod('success'),\n data: dataMethod('data'),\n insert: function (index, model) {\n var parentNode = this.parent();\n if (parentNode && parentNode._initChildren) {\n parentNode.hasChildren = true;\n parentNode._initChildren();\n }\n return DataSource.fn.insert.call(this, index, model);\n },\n filter: function (val) {\n if (val === undefined) {\n return this._filter;\n }\n if (!this.options.serverFiltering && this._markHierarchicalQuery(val)) {\n val = {\n logic: 'or',\n filters: [\n val,\n {\n field: '_matchFilter',\n operator: 'equals',\n value: true\n }\n ]\n };\n }\n this.trigger('reset');\n this._query({\n filter: val,\n page: 1\n });\n },\n _markHierarchicalQuery: function (expressions) {\n var compiled;\n var predicate;\n var fields;\n var operators;\n var filter;\n var accentFoldingFiltering = this.options.accentFoldingFiltering;\n expressions = accentFoldingFiltering ? $.extend({}, normalizeFilter(expressions), { accentFoldingFiltering: accentFoldingFiltering }) : normalizeFilter(expressions);\n if (!expressions || expressions.filters.length === 0) {\n this._updateHierarchicalFilter(function () {\n return true;\n });\n return false;\n }\n compiled = Query.filterExpr(expressions);\n fields = compiled.fields;\n operators = compiled.operators;\n predicate = filter = new Function('d, __f, __o', 'return ' + compiled.expression);\n if (fields.length || operators.length) {\n filter = function (d) {\n return predicate(d, fields, operators);\n };\n }\n this._updateHierarchicalFilter(filter);\n return true;\n },\n _updateHierarchicalFilter: function (filter) {\n var current;\n var data = this._data;\n var result = false;\n for (var idx = 0; idx < data.length; idx++) {\n current = data[idx];\n if (current.hasChildren) {\n current._matchFilter = current.children._updateHierarchicalFilter(filter);\n if (!current._matchFilter) {\n current._matchFilter = filter(current);\n }\n } else {\n current._matchFilter = filter(current);\n }\n if (current._matchFilter) {\n result = true;\n }\n }\n return result;\n },\n _find: function (method, value) {\n var idx, length, node, children;\n var data = this._data;\n if (!data) {\n return;\n }\n node = DataSource.fn[method].call(this, value);\n if (node) {\n return node;\n }\n data = this._flatData(this._data);\n for (idx = 0, length = data.length; idx < length; idx++) {\n children = data[idx].children;\n if (!(children instanceof HierarchicalDataSource)) {\n continue;\n }\n node = children[method](value);\n if (node) {\n return node;\n }\n }\n },\n get: function (id) {\n return this._find('get', id);\n },\n getByUid: function (uid) {\n return this._find('getByUid', uid);\n }\n });\n function inferList(list, fields) {\n var items = $(list).children(), idx, length, data = [], record, textField = fields[0].field, urlField = fields[1] && fields[1].field, spriteCssClassField = fields[2] && fields[2].field, imageUrlField = fields[3] && fields[3].field, item, id, textChild, className, children;\n function elements(collection, tagName) {\n return collection.filter(tagName).add(collection.find(tagName));\n }\n for (idx = 0, length = items.length; idx < length; idx++) {\n record = { _loaded: true };\n item = items.eq(idx);\n textChild = item[0].firstChild;\n children = item.children();\n list = children.filter('ul');\n children = children.filter(':not(ul)');\n id = item.attr('data-id');\n if (id) {\n record.id = id;\n }\n if (textChild) {\n record[textField] = textChild.nodeType == 3 ? textChild.nodeValue : children.text();\n }\n if (urlField) {\n record[urlField] = elements(children, 'a').attr('href');\n }\n if (imageUrlField) {\n record[imageUrlField] = elements(children, 'img').attr('src');\n }\n if (spriteCssClassField) {\n className = elements(children, '.k-sprite').prop('className');\n record[spriteCssClassField] = className && kendo.trim(className.replace('k-sprite', ''));\n }\n if (list.length) {\n record.items = inferList(list.eq(0), fields);\n }\n if (item.attr('data-hasChildren') == 'true') {\n record.hasChildren = true;\n }\n data.push(record);\n }\n return data;\n }\n HierarchicalDataSource.create = function (options) {\n options = options && options.push ? { data: options } : options;\n var dataSource = options || {}, data = dataSource.data, fields = dataSource.fields, list = dataSource.list;\n if (data && data._dataSource) {\n return data._dataSource;\n }\n if (!data && fields && !dataSource.transport) {\n if (list) {\n data = inferList(list, fields);\n }\n }\n dataSource.data = data;\n return dataSource instanceof HierarchicalDataSource ? dataSource : new HierarchicalDataSource(dataSource);\n };\n var Buffer = kendo.Observable.extend({\n init: function (dataSource, viewSize, disablePrefetch) {\n kendo.Observable.fn.init.call(this);\n this._prefetching = false;\n this.dataSource = dataSource;\n this.prefetch = !disablePrefetch;\n var buffer = this;\n dataSource.bind('change', function () {\n buffer._change();\n });\n dataSource.bind('reset', function () {\n buffer._reset();\n });\n this._syncWithDataSource();\n this.setViewSize(viewSize);\n },\n setViewSize: function (viewSize) {\n this.viewSize = viewSize;\n this._recalculate();\n },\n at: function (index) {\n var pageSize = this.pageSize, itemPresent = true;\n if (index >= this.total()) {\n this.trigger('endreached', { index: index });\n return null;\n }\n if (!this.useRanges) {\n return this.dataSource.view()[index];\n }\n if (this.useRanges) {\n if (index < this.dataOffset || index >= this.skip + pageSize) {\n itemPresent = this.range(Math.floor(index / pageSize) * pageSize);\n }\n if (index === this.prefetchThreshold) {\n this._prefetch();\n }\n if (index === this.midPageThreshold) {\n this.range(this.nextMidRange, true);\n } else if (index === this.nextPageThreshold) {\n this.range(this.nextFullRange);\n } else if (index === this.pullBackThreshold) {\n if (this.offset === this.skip) {\n this.range(this.previousMidRange);\n } else {\n this.range(this.previousFullRange);\n }\n }\n if (itemPresent) {\n return this.dataSource.at(index - this.dataOffset);\n } else {\n this.trigger('endreached', { index: index });\n return null;\n }\n }\n },\n indexOf: function (item) {\n return this.dataSource.data().indexOf(item) + this.dataOffset;\n },\n total: function () {\n return parseInt(this.dataSource.total(), 10);\n },\n next: function () {\n var buffer = this, pageSize = buffer.pageSize, offset = buffer.skip - buffer.viewSize + pageSize, pageSkip = math.max(math.floor(offset / pageSize), 0) * pageSize;\n this.offset = offset;\n this.dataSource.prefetch(pageSkip, pageSize, function () {\n buffer._goToRange(offset, true);\n });\n },\n range: function (offset, nextRange) {\n if (this.offset === offset) {\n return true;\n }\n var buffer = this, pageSize = this.pageSize, pageSkip = math.max(math.floor(offset / pageSize), 0) * pageSize, dataSource = this.dataSource;\n if (nextRange) {\n pageSkip += pageSize;\n }\n if (dataSource.inRange(offset, pageSize)) {\n this.offset = offset;\n this._recalculate();\n this._goToRange(offset);\n return true;\n } else if (this.prefetch) {\n dataSource.prefetch(pageSkip, pageSize, function () {\n buffer.offset = offset;\n buffer._recalculate();\n buffer._goToRange(offset, true);\n });\n return false;\n }\n return true;\n },\n syncDataSource: function () {\n var offset = this.offset;\n this.offset = null;\n this.range(offset);\n },\n destroy: function () {\n this.unbind();\n },\n _prefetch: function () {\n var buffer = this, pageSize = this.pageSize, prefetchOffset = this.skip + pageSize, dataSource = this.dataSource;\n if (!dataSource.inRange(prefetchOffset, pageSize) && !this._prefetching && this.prefetch) {\n this._prefetching = true;\n this.trigger('prefetching', {\n skip: prefetchOffset,\n take: pageSize\n });\n dataSource.prefetch(prefetchOffset, pageSize, function () {\n buffer._prefetching = false;\n buffer.trigger('prefetched', {\n skip: prefetchOffset,\n take: pageSize\n });\n });\n }\n },\n _goToRange: function (offset, expanding) {\n if (this.offset !== offset) {\n return;\n }\n this.dataOffset = offset;\n this._expanding = expanding;\n this.dataSource.range(offset, this.pageSize);\n this.dataSource.enableRequestsInProgress();\n },\n _reset: function () {\n this._syncPending = true;\n },\n _change: function () {\n var dataSource = this.dataSource;\n this.length = this.useRanges ? dataSource.lastRange().end : dataSource.view().length;\n if (this._syncPending) {\n this._syncWithDataSource();\n this._recalculate();\n this._syncPending = false;\n this.trigger('reset', { offset: this.offset });\n }\n this.trigger('resize');\n if (this._expanding) {\n this.trigger('expand');\n }\n delete this._expanding;\n },\n _syncWithDataSource: function () {\n var dataSource = this.dataSource;\n this._firstItemUid = dataSource.firstItemUid();\n this.dataOffset = this.offset = dataSource.skip() || 0;\n this.pageSize = dataSource.pageSize();\n this.useRanges = dataSource.options.serverPaging;\n },\n _recalculate: function () {\n var pageSize = this.pageSize, offset = this.offset, viewSize = this.viewSize, skip = Math.ceil(offset / pageSize) * pageSize;\n this.skip = skip;\n this.midPageThreshold = skip + pageSize - 1;\n this.nextPageThreshold = skip + viewSize - 1;\n this.prefetchThreshold = skip + Math.floor(pageSize / 3 * 2);\n this.pullBackThreshold = this.offset - 1;\n this.nextMidRange = skip + pageSize - viewSize;\n this.nextFullRange = skip;\n this.previousMidRange = offset - viewSize;\n this.previousFullRange = skip - pageSize;\n }\n });\n var BatchBuffer = kendo.Observable.extend({\n init: function (dataSource, batchSize) {\n var batchBuffer = this;\n kendo.Observable.fn.init.call(batchBuffer);\n this.dataSource = dataSource;\n this.batchSize = batchSize;\n this._total = 0;\n this.buffer = new Buffer(dataSource, batchSize * 3);\n this.buffer.bind({\n 'endreached': function (e) {\n batchBuffer.trigger('endreached', { index: e.index });\n },\n 'prefetching': function (e) {\n batchBuffer.trigger('prefetching', {\n skip: e.skip,\n take: e.take\n });\n },\n 'prefetched': function (e) {\n batchBuffer.trigger('prefetched', {\n skip: e.skip,\n take: e.take\n });\n },\n 'reset': function () {\n batchBuffer._total = 0;\n batchBuffer.trigger('reset');\n },\n 'resize': function () {\n batchBuffer._total = Math.ceil(this.length / batchBuffer.batchSize);\n batchBuffer.trigger('resize', {\n total: batchBuffer.total(),\n offset: this.offset\n });\n }\n });\n },\n syncDataSource: function () {\n this.buffer.syncDataSource();\n },\n at: function (index) {\n var buffer = this.buffer, skip = index * this.batchSize, take = this.batchSize, view = [], item;\n if (buffer.offset > skip) {\n buffer.at(buffer.offset - 1);\n }\n for (var i = 0; i < take; i++) {\n item = buffer.at(skip + i);\n if (item === null) {\n break;\n }\n view.push(item);\n }\n return view;\n },\n total: function () {\n return this._total;\n },\n destroy: function () {\n this.buffer.destroy();\n this.unbind();\n }\n });\n extend(true, kendo.data, {\n readers: { json: DataReader },\n Query: Query,\n DataSource: DataSource,\n HierarchicalDataSource: HierarchicalDataSource,\n Node: Node,\n Comparer: Comparer,\n ObservableObject: ObservableObject,\n ObservableArray: ObservableArray,\n LazyObservableArray: LazyObservableArray,\n LocalTransport: LocalTransport,\n RemoteTransport: RemoteTransport,\n Cache: Cache,\n DataReader: DataReader,\n Model: Model,\n Buffer: Buffer,\n BatchBuffer: BatchBuffer\n });\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.data.signalr', ['kendo.data'], f);\n}(function () {\n var __meta__ = {\n id: 'data.signalr',\n name: 'SignalR',\n category: 'framework',\n depends: ['data'],\n hidden: true\n };\n (function ($) {\n var kendo = window.kendo;\n var isFunction = kendo.isFunction;\n function isJQueryPromise(promise) {\n return promise && isFunction(promise.done) && isFunction(promise.fail);\n }\n function isNativePromise(promise) {\n return promise && isFunction(promise.then) && isFunction(promise.catch);\n }\n var transport = kendo.data.RemoteTransport.extend({\n init: function (options) {\n var signalr = options && options.signalr ? options.signalr : {};\n var promise = signalr.promise;\n if (!promise) {\n throw new Error('The \"promise\" option must be set.');\n }\n if (!isJQueryPromise(promise) && !isNativePromise(promise)) {\n throw new Error('The \"promise\" option must be a Promise.');\n }\n this.promise = promise;\n var hub = signalr.hub;\n if (!hub) {\n throw new Error('The \"hub\" option must be set.');\n }\n if (typeof hub.on != 'function' || typeof hub.invoke != 'function') {\n throw new Error('The \"hub\" option is not a valid SignalR hub proxy.');\n }\n this.hub = hub;\n kendo.data.RemoteTransport.fn.init.call(this, options);\n },\n push: function (callbacks) {\n var client = this.options.signalr.client || {};\n if (client.create) {\n this.hub.on(client.create, callbacks.pushCreate);\n }\n if (client.update) {\n this.hub.on(client.update, callbacks.pushUpdate);\n }\n if (client.destroy) {\n this.hub.on(client.destroy, callbacks.pushDestroy);\n }\n },\n _crud: function (options, type) {\n var hub = this.hub;\n var promise = this.promise;\n var server = this.options.signalr.server;\n if (!server || !server[type]) {\n throw new Error(kendo.format('The \"server.{0}\" option must be set.', type));\n }\n var args = [server[type]];\n var data = this.parameterMap(options.data, type);\n if (!$.isEmptyObject(data)) {\n args.push(data);\n }\n if (isJQueryPromise(promise)) {\n promise.done(function () {\n hub.invoke.apply(hub, args).done(options.success).fail(options.error);\n });\n } else if (isNativePromise(promise)) {\n promise.then(function () {\n hub.invoke.apply(hub, args).then(options.success).catch(options.error);\n });\n }\n },\n read: function (options) {\n this._crud(options, 'read');\n },\n create: function (options) {\n this._crud(options, 'create');\n },\n update: function (options) {\n this._crud(options, 'update');\n },\n destroy: function (options) {\n this._crud(options, 'destroy');\n }\n });\n $.extend(true, kendo.data, { transports: { signalr: transport } });\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.binder', [\n 'kendo.core',\n 'kendo.data'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'binder',\n name: 'MVVM',\n category: 'framework',\n description: 'Model View ViewModel (MVVM) is a design pattern which helps developers separate the Model (the data) from the View (the UI).',\n depends: [\n 'core',\n 'data'\n ]\n };\n (function ($, undefined) {\n var kendo = window.kendo, Observable = kendo.Observable, ObservableObject = kendo.data.ObservableObject, ObservableArray = kendo.data.ObservableArray, toString = {}.toString, binders = {}, Class = kendo.Class, proxy = $.proxy, VALUE = 'value', SOURCE = 'source', EVENTS = 'events', CHECKED = 'checked', CSS = 'css', deleteExpando = true, FUNCTION = 'function', CHANGE = 'change';\n (function () {\n var a = document.createElement('a');\n try {\n delete a.test;\n } catch (e) {\n deleteExpando = false;\n }\n }());\n var Binding = Observable.extend({\n init: function (parents, path) {\n var that = this;\n Observable.fn.init.call(that);\n that.source = parents[0];\n that.parents = parents;\n that.path = path;\n that.dependencies = {};\n that.dependencies[path] = true;\n that.observable = that.source instanceof Observable;\n that._access = function (e) {\n that.dependencies[e.field] = true;\n };\n if (that.observable) {\n that._change = function (e) {\n that.change(e);\n };\n that.source.bind(CHANGE, that._change);\n }\n },\n _parents: function () {\n var parents = this.parents;\n var value = this.get();\n if (value && typeof value.parent == 'function') {\n var parent = value.parent();\n if ($.inArray(parent, parents) < 0) {\n parents = [parent].concat(parents);\n }\n }\n return parents;\n },\n change: function (e) {\n var dependency, ch, field = e.field, that = this;\n if (that.path === 'this') {\n that.trigger(CHANGE, e);\n } else {\n for (dependency in that.dependencies) {\n if (dependency.indexOf(field) === 0) {\n ch = dependency.charAt(field.length);\n if (!ch || ch === '.' || ch === '[') {\n that.trigger(CHANGE, e);\n break;\n }\n }\n }\n }\n },\n start: function (source) {\n source.bind('get', this._access);\n },\n stop: function (source) {\n source.unbind('get', this._access);\n },\n get: function () {\n var that = this, source = that.source, index = 0, path = that.path, result = source;\n if (!that.observable) {\n return result;\n }\n that.start(that.source);\n result = source.get(path);\n while (result === undefined && source) {\n source = that.parents[++index];\n if (source instanceof ObservableObject) {\n result = source.get(path);\n }\n }\n if (result === undefined) {\n source = that.source;\n while (result === undefined && source) {\n source = source.parent();\n if (source instanceof ObservableObject) {\n result = source.get(path);\n }\n }\n }\n if (typeof result === 'function') {\n index = path.lastIndexOf('.');\n if (index > 0) {\n source = source.get(path.substring(0, index));\n }\n that.start(source);\n if (source !== that.source) {\n result = result.call(source, that.source);\n } else {\n result = result.call(source);\n }\n that.stop(source);\n }\n if (source && source !== that.source) {\n that.currentSource = source;\n source.unbind(CHANGE, that._change).bind(CHANGE, that._change);\n }\n that.stop(that.source);\n return result;\n },\n set: function (value) {\n var source = this.currentSource || this.source;\n var field = kendo.getter(this.path)(source);\n if (typeof field === 'function') {\n if (source !== this.source) {\n field.call(source, this.source, value);\n } else {\n field.call(source, value);\n }\n } else {\n source.set(this.path, value);\n }\n },\n destroy: function () {\n if (this.observable) {\n this.source.unbind(CHANGE, this._change);\n if (this.currentSource) {\n this.currentSource.unbind(CHANGE, this._change);\n }\n }\n this.unbind();\n }\n });\n var EventBinding = Binding.extend({\n get: function () {\n var source = this.source, path = this.path, index = 0, handler;\n handler = source.get(path);\n while (!handler && source) {\n source = this.parents[++index];\n if (source instanceof ObservableObject) {\n handler = source.get(path);\n }\n }\n return proxy(handler, source);\n }\n });\n var TemplateBinding = Binding.extend({\n init: function (source, path, template) {\n var that = this;\n Binding.fn.init.call(that, source, path);\n that.template = template;\n },\n render: function (value) {\n var html;\n this.start(this.source);\n html = kendo.render(this.template, value);\n this.stop(this.source);\n return html;\n }\n });\n var Binder = Class.extend({\n init: function (element, bindings, options) {\n this.element = element;\n this.bindings = bindings;\n this.options = options;\n },\n bind: function (binding, attribute) {\n var that = this;\n binding = attribute ? binding[attribute] : binding;\n binding.bind(CHANGE, function (e) {\n that.refresh(attribute || e);\n });\n that.refresh(attribute);\n },\n destroy: function () {\n }\n });\n var TypedBinder = Binder.extend({\n dataType: function () {\n var dataType = this.element.getAttribute('data-type') || this.element.type || 'text';\n return dataType.toLowerCase();\n },\n parsedValue: function () {\n return this._parseValue(this.element.value, this.dataType());\n },\n _parseValue: function (value, dataType) {\n if (dataType == 'date') {\n value = kendo.parseDate(value, 'yyyy-MM-dd');\n } else if (dataType == 'datetime-local') {\n value = kendo.parseDate(value, [\n 'yyyy-MM-ddTHH:mm:ss',\n 'yyyy-MM-ddTHH:mm'\n ]);\n } else if (dataType == 'number') {\n value = kendo.parseFloat(value);\n } else if (dataType == 'boolean') {\n value = value.toLowerCase();\n if (kendo.parseFloat(value) !== null) {\n value = Boolean(kendo.parseFloat(value));\n } else {\n value = value.toLowerCase() === 'true';\n }\n }\n return value;\n }\n });\n binders.attr = Binder.extend({\n refresh: function (key) {\n this.element.setAttribute(key, this.bindings.attr[key].get());\n }\n });\n binders.css = Binder.extend({\n init: function (element, bindings, options) {\n Binder.fn.init.call(this, element, bindings, options);\n this.classes = {};\n },\n refresh: function (className) {\n var element = $(this.element), binding = this.bindings.css[className], hasClass = this.classes[className] = binding.get();\n if (hasClass) {\n element.addClass(className);\n } else {\n element.removeClass(className);\n }\n }\n });\n binders.style = Binder.extend({\n refresh: function (key) {\n this.element.style[key] = this.bindings.style[key].get() || '';\n }\n });\n binders.enabled = Binder.extend({\n refresh: function () {\n if (this.bindings.enabled.get()) {\n this.element.removeAttribute('disabled');\n } else {\n this.element.setAttribute('disabled', 'disabled');\n }\n }\n });\n binders.readonly = Binder.extend({\n refresh: function () {\n if (this.bindings.readonly.get()) {\n this.element.setAttribute('readonly', 'readonly');\n } else {\n this.element.removeAttribute('readonly');\n }\n }\n });\n binders.disabled = Binder.extend({\n refresh: function () {\n if (this.bindings.disabled.get()) {\n this.element.setAttribute('disabled', 'disabled');\n } else {\n this.element.removeAttribute('disabled');\n }\n }\n });\n binders.events = Binder.extend({\n init: function (element, bindings, options) {\n Binder.fn.init.call(this, element, bindings, options);\n this.handlers = {};\n },\n refresh: function (key) {\n var element = $(this.element), binding = this.bindings.events[key], handler = this.handlers[key];\n if (handler) {\n element.off(key, handler);\n }\n handler = this.handlers[key] = binding.get();\n element.on(key, binding.source, handler);\n },\n destroy: function () {\n var element = $(this.element), handler;\n for (handler in this.handlers) {\n element.off(handler, this.handlers[handler]);\n }\n }\n });\n binders.text = Binder.extend({\n refresh: function () {\n var text = this.bindings.text.get();\n var dataFormat = this.element.getAttribute('data-format') || '';\n if (text == null) {\n text = '';\n }\n $(this.element).text(kendo.toString(text, dataFormat));\n }\n });\n binders.visible = Binder.extend({\n refresh: function () {\n if (this.bindings.visible.get()) {\n this.element.style.display = '';\n } else {\n this.element.style.display = 'none';\n }\n }\n });\n binders.invisible = Binder.extend({\n refresh: function () {\n if (!this.bindings.invisible.get()) {\n this.element.style.display = '';\n } else {\n this.element.style.display = 'none';\n }\n }\n });\n binders.html = Binder.extend({\n refresh: function () {\n this.element.innerHTML = this.bindings.html.get();\n }\n });\n binders.value = TypedBinder.extend({\n init: function (element, bindings, options) {\n TypedBinder.fn.init.call(this, element, bindings, options);\n this._change = proxy(this.change, this);\n this.eventName = options.valueUpdate || CHANGE;\n $(this.element).on(this.eventName, this._change);\n this._initChange = false;\n },\n change: function () {\n this._initChange = this.eventName != CHANGE;\n this.bindings[VALUE].set(this.parsedValue());\n this._initChange = false;\n },\n refresh: function () {\n if (!this._initChange) {\n var value = this.bindings[VALUE].get();\n if (value == null) {\n value = '';\n }\n var type = this.dataType();\n if (type == 'date') {\n value = kendo.toString(value, 'yyyy-MM-dd');\n } else if (type == 'datetime-local') {\n value = kendo.toString(value, 'yyyy-MM-ddTHH:mm:ss');\n }\n this.element.value = value;\n }\n this._initChange = false;\n },\n destroy: function () {\n $(this.element).off(this.eventName, this._change);\n }\n });\n binders.source = Binder.extend({\n init: function (element, bindings, options) {\n Binder.fn.init.call(this, element, bindings, options);\n var source = this.bindings.source.get();\n if (source instanceof kendo.data.DataSource && options.autoBind !== false) {\n source.fetch();\n }\n },\n refresh: function (e) {\n var that = this, source = that.bindings.source.get();\n if (source instanceof ObservableArray || source instanceof kendo.data.DataSource) {\n e = e || {};\n if (e.action == 'add') {\n that.add(e.index, e.items);\n } else if (e.action == 'remove') {\n that.remove(e.index, e.items);\n } else if (e.action != 'itemchange') {\n that.render();\n }\n } else {\n that.render();\n }\n },\n container: function () {\n var element = this.element;\n if (element.nodeName.toLowerCase() == 'table') {\n if (!element.tBodies[0]) {\n element.appendChild(document.createElement('tbody'));\n }\n element = element.tBodies[0];\n }\n return element;\n },\n template: function () {\n var options = this.options, template = options.template, nodeName = this.container().nodeName.toLowerCase();\n if (!template) {\n if (nodeName == 'select') {\n if (options.valueField || options.textField) {\n template = kendo.format('', options.valueField || options.textField, options.textField || options.valueField);\n } else {\n template = '';\n }\n } else if (nodeName == 'tbody') {\n template = '#:data#';\n } else if (nodeName == 'ul' || nodeName == 'ol') {\n template = '
  • #:data#
  • ';\n } else {\n template = '#:data#';\n }\n template = kendo.template(template);\n }\n return template;\n },\n add: function (index, items) {\n var element = this.container(), parents, idx, length, child, clone = element.cloneNode(false), reference = element.children[index];\n $(clone).html(kendo.render(this.template(), items));\n if (clone.children.length) {\n parents = this.bindings.source._parents();\n for (idx = 0, length = items.length; idx < length; idx++) {\n child = clone.children[0];\n element.insertBefore(child, reference || null);\n bindElement(child, items[idx], this.options.roles, [items[idx]].concat(parents));\n }\n }\n },\n remove: function (index, items) {\n var idx, element = this.container();\n for (idx = 0; idx < items.length; idx++) {\n var child = element.children[index];\n unbindElementTree(child, true);\n if (child.parentNode == element) {\n element.removeChild(child);\n }\n }\n },\n render: function () {\n var source = this.bindings.source.get(), parents, idx, length, element = this.container(), template = this.template();\n if (source == null) {\n return;\n }\n if (source instanceof kendo.data.DataSource) {\n source = source.view();\n }\n if (!(source instanceof ObservableArray) && toString.call(source) !== '[object Array]') {\n source = [source];\n }\n if (this.bindings.template) {\n unbindElementChildren(element, true);\n $(element).html(this.bindings.template.render(source));\n if (element.children.length) {\n parents = this.bindings.source._parents();\n for (idx = 0, length = source.length; idx < length; idx++) {\n bindElement(element.children[idx], source[idx], this.options.roles, [source[idx]].concat(parents));\n }\n }\n } else {\n $(element).html(kendo.render(template, source));\n }\n }\n });\n binders.input = {\n checked: TypedBinder.extend({\n init: function (element, bindings, options) {\n TypedBinder.fn.init.call(this, element, bindings, options);\n this._change = proxy(this.change, this);\n $(this.element).change(this._change);\n },\n change: function () {\n var element = this.element;\n var value = this.value();\n if (element.type == 'radio') {\n value = this.parsedValue();\n this.bindings[CHECKED].set(value);\n } else if (element.type == 'checkbox') {\n var source = this.bindings[CHECKED].get();\n var index;\n if (source instanceof ObservableArray) {\n value = this.parsedValue();\n if (value instanceof Date) {\n for (var i = 0; i < source.length; i++) {\n if (source[i] instanceof Date && +source[i] === +value) {\n index = i;\n break;\n }\n }\n } else {\n index = source.indexOf(value);\n }\n if (index > -1) {\n source.splice(index, 1);\n } else {\n source.push(value);\n }\n } else {\n this.bindings[CHECKED].set(value);\n }\n }\n },\n refresh: function () {\n var value = this.bindings[CHECKED].get(), source = value, type = this.dataType(), element = this.element;\n if (element.type == 'checkbox') {\n if (source instanceof ObservableArray) {\n var index = -1;\n value = this.parsedValue();\n if (value instanceof Date) {\n for (var i = 0; i < source.length; i++) {\n if (source[i] instanceof Date && +source[i] === +value) {\n index = i;\n break;\n }\n }\n } else {\n index = source.indexOf(value);\n }\n element.checked = index >= 0;\n } else {\n element.checked = source;\n }\n } else if (element.type == 'radio') {\n if (type == 'date') {\n value = kendo.toString(value, 'yyyy-MM-dd');\n } else if (type == 'datetime-local') {\n value = kendo.toString(value, 'yyyy-MM-ddTHH:mm:ss');\n }\n if (value !== null && typeof value !== 'undefined' && element.value === value.toString()) {\n element.checked = true;\n } else {\n element.checked = false;\n }\n }\n },\n value: function () {\n var element = this.element, value = element.value;\n if (element.type == 'checkbox') {\n value = element.checked;\n }\n return value;\n },\n destroy: function () {\n $(this.element).off(CHANGE, this._change);\n }\n })\n };\n binders.select = {\n source: binders.source.extend({\n refresh: function (e) {\n var that = this, source = that.bindings.source.get();\n if (source instanceof ObservableArray || source instanceof kendo.data.DataSource) {\n e = e || {};\n if (e.action == 'add') {\n that.add(e.index, e.items);\n } else if (e.action == 'remove') {\n that.remove(e.index, e.items);\n } else if (e.action == 'itemchange' || e.action === undefined) {\n that.render();\n if (that.bindings.value) {\n if (that.bindings.value) {\n var val = retrievePrimitiveValues(that.bindings.value.get(), $(that.element).data('valueField'));\n if (val === null) {\n that.element.selectedIndex = -1;\n } else {\n that.element.value = val;\n }\n }\n }\n }\n } else {\n that.render();\n }\n }\n }),\n value: TypedBinder.extend({\n init: function (target, bindings, options) {\n TypedBinder.fn.init.call(this, target, bindings, options);\n this._change = proxy(this.change, this);\n $(this.element).change(this._change);\n },\n parsedValue: function () {\n var dataType = this.dataType();\n var values = [];\n var value, option, idx, length;\n for (idx = 0, length = this.element.options.length; idx < length; idx++) {\n option = this.element.options[idx];\n if (option.selected) {\n value = option.attributes.value;\n if (value && value.specified) {\n value = option.value;\n } else {\n value = option.text;\n }\n values.push(this._parseValue(value, dataType));\n }\n }\n return values;\n },\n change: function () {\n var values = [], element = this.element, source, field = this.options.valueField || this.options.textField, valuePrimitive = this.options.valuePrimitive, option, valueIndex, value, idx, length;\n for (idx = 0, length = element.options.length; idx < length; idx++) {\n option = element.options[idx];\n if (option.selected) {\n value = option.attributes.value;\n if (value && value.specified) {\n value = option.value;\n } else {\n value = option.text;\n }\n if (field) {\n values.push(value);\n } else {\n values.push(this._parseValue(value, this.dataType()));\n }\n }\n }\n if (field) {\n source = this.bindings.source.get();\n if (source instanceof kendo.data.DataSource) {\n source = source.view();\n }\n for (valueIndex = 0; valueIndex < values.length; valueIndex++) {\n for (idx = 0, length = source.length; idx < length; idx++) {\n var sourceValue = source[idx].get(field);\n var match = String(sourceValue) === values[valueIndex];\n if (match) {\n values[valueIndex] = source[idx];\n break;\n }\n }\n }\n }\n value = this.bindings[VALUE].get();\n if (value instanceof ObservableArray) {\n value.splice.apply(value, [\n 0,\n value.length\n ].concat(values));\n } else if (!valuePrimitive && (value instanceof ObservableObject || value === null || value === undefined || !field)) {\n this.bindings[VALUE].set(values[0]);\n } else {\n this.bindings[VALUE].set(values[0].get(field));\n }\n },\n refresh: function () {\n var optionIndex, element = this.element, options = element.options, value = this.bindings[VALUE].get(), values = value, field = this.options.valueField || this.options.textField, found = false, type = this.dataType(), optionValue;\n if (!(values instanceof ObservableArray)) {\n values = new ObservableArray([value]);\n }\n element.selectedIndex = -1;\n for (var valueIndex = 0; valueIndex < values.length; valueIndex++) {\n value = values[valueIndex];\n if (field && value instanceof ObservableObject) {\n value = value.get(field);\n }\n if (type == 'date') {\n value = kendo.toString(values[valueIndex], 'yyyy-MM-dd');\n } else if (type == 'datetime-local') {\n value = kendo.toString(values[valueIndex], 'yyyy-MM-ddTHH:mm:ss');\n }\n for (optionIndex = 0; optionIndex < options.length; optionIndex++) {\n optionValue = options[optionIndex].value;\n if (optionValue === '' && value !== '') {\n optionValue = options[optionIndex].text;\n }\n if (value != null && optionValue == value.toString()) {\n options[optionIndex].selected = true;\n found = true;\n }\n }\n }\n },\n destroy: function () {\n $(this.element).off(CHANGE, this._change);\n }\n })\n };\n function dataSourceBinding(bindingName, fieldName, setter) {\n return Binder.extend({\n init: function (widget, bindings, options) {\n var that = this;\n Binder.fn.init.call(that, widget.element[0], bindings, options);\n that.widget = widget;\n that._dataBinding = proxy(that.dataBinding, that);\n that._dataBound = proxy(that.dataBound, that);\n that._itemChange = proxy(that.itemChange, that);\n },\n itemChange: function (e) {\n bindElement(e.item[0], e.data, this._ns(e.ns), [e.data].concat(this.bindings[bindingName]._parents()));\n },\n dataBinding: function (e) {\n var idx, length, widget = this.widget, items = e.removedItems || widget.items();\n for (idx = 0, length = items.length; idx < length; idx++) {\n unbindElementTree(items[idx], false);\n }\n },\n _ns: function (ns) {\n ns = ns || kendo.ui;\n var all = [\n kendo.ui,\n kendo.dataviz.ui,\n kendo.mobile.ui\n ];\n all.splice($.inArray(ns, all), 1);\n all.unshift(ns);\n return kendo.rolesFromNamespaces(all);\n },\n dataBound: function (e) {\n var idx, length, widget = this.widget, items = e.addedItems || widget.items(), dataSource = widget[fieldName], view, parents, hds = kendo.data.HierarchicalDataSource;\n if (hds && dataSource instanceof hds) {\n return;\n }\n if (items.length) {\n view = e.addedDataItems || dataSource.flatView();\n parents = this.bindings[bindingName]._parents();\n for (idx = 0, length = view.length; idx < length; idx++) {\n if (items[idx]) {\n bindElement(items[idx], view[idx], this._ns(e.ns), [view[idx]].concat(parents));\n }\n }\n }\n },\n refresh: function (e) {\n var that = this, source, widget = that.widget, select, multiselect, dropdowntree;\n e = e || {};\n if (!e.action) {\n that.destroy();\n widget.bind('dataBinding', that._dataBinding);\n widget.bind('dataBound', that._dataBound);\n widget.bind('itemChange', that._itemChange);\n source = that.bindings[bindingName].get();\n if (widget[fieldName] instanceof kendo.data.DataSource && widget[fieldName] != source) {\n if (source instanceof kendo.data.DataSource) {\n widget[setter](source);\n } else if (source && source._dataSource) {\n widget[setter](source._dataSource);\n } else {\n select = kendo.ui.Select && widget instanceof kendo.ui.Select;\n multiselect = kendo.ui.MultiSelect && widget instanceof kendo.ui.MultiSelect;\n dropdowntree = kendo.ui.DropDownTree && widget instanceof kendo.ui.DropDownTree;\n if (!dropdowntree) {\n widget[fieldName].data(source);\n } else {\n widget.treeview[fieldName].data(source);\n }\n if (that.bindings.value && (select || multiselect)) {\n widget.value(retrievePrimitiveValues(that.bindings.value.get(), widget.options.dataValueField));\n }\n }\n }\n }\n },\n destroy: function () {\n var widget = this.widget;\n widget.unbind('dataBinding', this._dataBinding);\n widget.unbind('dataBound', this._dataBound);\n widget.unbind('itemChange', this._itemChange);\n }\n });\n }\n binders.widget = {\n events: Binder.extend({\n init: function (widget, bindings, options) {\n Binder.fn.init.call(this, widget.element[0], bindings, options);\n this.widget = widget;\n this.handlers = {};\n },\n refresh: function (key) {\n var binding = this.bindings.events[key], handler = this.handlers[key];\n if (handler) {\n this.widget.unbind(key, handler);\n }\n handler = binding.get();\n this.handlers[key] = function (e) {\n e.data = binding.source;\n handler(e);\n if (e.data === binding.source) {\n delete e.data;\n }\n };\n this.widget.bind(key, this.handlers[key]);\n },\n destroy: function () {\n var handler;\n for (handler in this.handlers) {\n this.widget.unbind(handler, this.handlers[handler]);\n }\n }\n }),\n checked: Binder.extend({\n init: function (widget, bindings, options) {\n Binder.fn.init.call(this, widget.element[0], bindings, options);\n this.widget = widget;\n this._change = proxy(this.change, this);\n this.widget.bind(CHANGE, this._change);\n },\n change: function () {\n this.bindings[CHECKED].set(this.value());\n },\n refresh: function () {\n this.widget.check(this.bindings[CHECKED].get() === true);\n },\n value: function () {\n var element = this.element, value = element.value;\n if (value == 'on' || value == 'off' || this.element.type == 'checkbox') {\n value = element.checked;\n }\n return value;\n },\n destroy: function () {\n this.widget.unbind(CHANGE, this._change);\n }\n }),\n start: Binder.extend({\n init: function (widget, bindings, options) {\n Binder.fn.init.call(this, widget.element[0], bindings, options);\n this._change = proxy(this.change, this);\n this.widget = widget;\n this.widget.bind(CHANGE, this._change);\n },\n change: function () {\n this.bindings.start.set(this.widget.range().start);\n },\n refresh: function () {\n var that = this;\n var start = this.bindings.start.get();\n var end = that.widget._range ? that.widget._range.end : null;\n this.widget.range({\n start: start,\n end: end\n });\n },\n destroy: function () {\n this.widget.unbind(CHANGE, this._change);\n }\n }),\n end: Binder.extend({\n init: function (widget, bindings, options) {\n Binder.fn.init.call(this, widget.element[0], bindings, options);\n this._change = proxy(this.change, this);\n this.widget = widget;\n this.widget.bind(CHANGE, this._change);\n },\n change: function () {\n this.bindings.end.set(this.widget.range().end);\n },\n refresh: function () {\n var that = this;\n var end = this.bindings.end.get();\n var start = that.widget._range ? that.widget._range.start : null;\n this.widget.range({\n start: start,\n end: end\n });\n },\n destroy: function () {\n this.widget.unbind(CHANGE, this._change);\n }\n }),\n visible: Binder.extend({\n init: function (widget, bindings, options) {\n Binder.fn.init.call(this, widget.element[0], bindings, options);\n this.widget = widget;\n },\n refresh: function () {\n var visible = this.bindings.visible.get();\n this.widget.wrapper[0].style.display = visible ? '' : 'none';\n }\n }),\n invisible: Binder.extend({\n init: function (widget, bindings, options) {\n Binder.fn.init.call(this, widget.element[0], bindings, options);\n this.widget = widget;\n },\n refresh: function () {\n var invisible = this.bindings.invisible.get();\n this.widget.wrapper[0].style.display = invisible ? 'none' : '';\n }\n }),\n enabled: Binder.extend({\n init: function (widget, bindings, options) {\n Binder.fn.init.call(this, widget.element[0], bindings, options);\n this.widget = widget;\n },\n refresh: function () {\n if (this.widget.enable) {\n this.widget.enable(this.bindings.enabled.get());\n }\n }\n }),\n disabled: Binder.extend({\n init: function (widget, bindings, options) {\n Binder.fn.init.call(this, widget.element[0], bindings, options);\n this.widget = widget;\n },\n refresh: function () {\n if (this.widget.enable) {\n this.widget.enable(!this.bindings.disabled.get());\n }\n }\n }),\n source: dataSourceBinding('source', 'dataSource', 'setDataSource'),\n value: Binder.extend({\n init: function (widget, bindings, options) {\n Binder.fn.init.call(this, widget.element[0], bindings, options);\n this.widget = widget;\n this._change = $.proxy(this.change, this);\n this.widget.first(CHANGE, this._change);\n var value = this.bindings.value.get();\n this._valueIsObservableObject = !options.valuePrimitive && (value == null || value instanceof ObservableObject);\n this._valueIsObservableArray = value instanceof ObservableArray;\n this._initChange = false;\n },\n _source: function () {\n var source;\n if (this.widget.dataItem) {\n source = this.widget.dataItem();\n if (source && source instanceof ObservableObject) {\n return [source];\n }\n }\n if (this.bindings.source) {\n source = this.bindings.source.get();\n }\n if (!source || source instanceof kendo.data.DataSource) {\n source = this.widget.dataSource.flatView();\n }\n return source;\n },\n change: function () {\n var value = this.widget.value(), field = this.options.dataValueField || this.options.dataTextField, isArray = toString.call(value) === '[object Array]', isObservableObject = this._valueIsObservableObject, valueIndex, valueLength, values = [], sourceItem, sourceValue, idx, length, source;\n this._initChange = true;\n if (field) {\n if (value === '' && (isObservableObject || this.options.valuePrimitive)) {\n value = null;\n } else {\n source = this._source();\n if (isArray) {\n valueLength = value.length;\n values = value.slice(0);\n }\n for (idx = 0, length = source.length; idx < length; idx++) {\n sourceItem = source[idx];\n sourceValue = sourceItem.get(field);\n if (isArray) {\n for (valueIndex = 0; valueIndex < valueLength; valueIndex++) {\n if (sourceValue == values[valueIndex]) {\n values[valueIndex] = sourceItem;\n break;\n }\n }\n } else if (sourceValue == value) {\n value = isObservableObject ? sourceItem : sourceValue;\n break;\n }\n }\n if (values[0]) {\n if (this._valueIsObservableArray) {\n value = values;\n } else if (isObservableObject || !field) {\n value = values[0];\n } else {\n value = values[0].get(field);\n }\n }\n }\n }\n this.bindings.value.set(value);\n this._initChange = false;\n },\n refresh: function () {\n if (!this._initChange) {\n var widget = this.widget;\n var options = widget.options;\n var textField = options.dataTextField;\n var valueField = options.dataValueField || textField;\n var value = this.bindings.value.get();\n var text = options.text || '';\n var idx = 0, length;\n var values = [];\n if (value === undefined) {\n value = null;\n }\n if (valueField) {\n if (value instanceof ObservableArray) {\n for (length = value.length; idx < length; idx++) {\n values[idx] = value[idx].get(valueField);\n }\n value = values;\n } else if (value instanceof ObservableObject) {\n text = value.get(textField);\n value = value.get(valueField);\n }\n }\n if (options.autoBind === false && !options.cascadeFrom && widget.listView && !widget.listView.bound()) {\n if (textField === valueField && !text) {\n text = value;\n }\n if (!text && (value || value === 0) && options.valuePrimitive) {\n widget.value(value);\n } else {\n widget._preselect(value, text);\n }\n } else {\n widget.value(value);\n }\n }\n this._initChange = false;\n },\n destroy: function () {\n this.widget.unbind(CHANGE, this._change);\n }\n }),\n dropdowntree: {\n value: Binder.extend({\n init: function (widget, bindings, options) {\n Binder.fn.init.call(this, widget.element[0], bindings, options);\n this.widget = widget;\n this._change = $.proxy(this.change, this);\n this.widget.first(CHANGE, this._change);\n this._initChange = false;\n },\n change: function () {\n var that = this, oldValues = that.bindings[VALUE].get(), valuePrimitive = that.options.valuePrimitive, selectedNode = that.widget.treeview.select(), nonPrimitiveValues = that.widget._isMultipleSelection() ? that.widget._getAllChecked() : that.widget.treeview.dataItem(selectedNode) || that.widget.value(), newValues = valuePrimitive || that.widget.options.autoBind === false ? that.widget.value() : nonPrimitiveValues;\n var field = this.options.dataValueField || this.options.dataTextField;\n newValues = newValues.slice ? newValues.slice(0) : newValues;\n that._initChange = true;\n if (oldValues instanceof ObservableArray) {\n var remove = [];\n var newLength = newValues.length;\n var i = 0, j = 0;\n var old = oldValues[i];\n var same = false;\n var removeIndex;\n var newValue;\n var found;\n while (old !== undefined) {\n found = false;\n for (j = 0; j < newLength; j++) {\n if (valuePrimitive) {\n same = newValues[j] == old;\n } else {\n newValue = newValues[j];\n newValue = newValue.get ? newValue.get(field) : newValue;\n same = newValue == (old.get ? old.get(field) : old);\n }\n if (same) {\n newValues.splice(j, 1);\n newLength -= 1;\n found = true;\n break;\n }\n }\n if (!found) {\n remove.push(old);\n arraySplice(oldValues, i, 1);\n removeIndex = i;\n } else {\n i += 1;\n }\n old = oldValues[i];\n }\n arraySplice(oldValues, oldValues.length, 0, newValues);\n if (remove.length) {\n oldValues.trigger('change', {\n action: 'remove',\n items: remove,\n index: removeIndex\n });\n }\n if (newValues.length) {\n oldValues.trigger('change', {\n action: 'add',\n items: newValues,\n index: oldValues.length - 1\n });\n }\n } else {\n that.bindings[VALUE].set(newValues);\n }\n that._initChange = false;\n },\n refresh: function () {\n if (!this._initChange) {\n var options = this.options, widget = this.widget, field = options.dataValueField || options.dataTextField, value = this.bindings.value.get(), data = value, idx = 0, length, values = [], selectedValue;\n if (field) {\n if (value instanceof ObservableArray) {\n for (length = value.length; idx < length; idx++) {\n selectedValue = value[idx];\n values[idx] = selectedValue.get ? selectedValue.get(field) : selectedValue;\n }\n value = values;\n } else if (value instanceof ObservableObject) {\n value = value.get(field);\n }\n }\n if (options.autoBind === false && options.valuePrimitive !== true) {\n widget._preselect(data, value);\n } else {\n widget.value(value);\n }\n }\n },\n destroy: function () {\n this.widget.unbind(CHANGE, this._change);\n }\n })\n },\n gantt: { dependencies: dataSourceBinding('dependencies', 'dependencies', 'setDependenciesDataSource') },\n multiselect: {\n value: Binder.extend({\n init: function (widget, bindings, options) {\n Binder.fn.init.call(this, widget.element[0], bindings, options);\n this.widget = widget;\n this._change = $.proxy(this.change, this);\n this.widget.first(CHANGE, this._change);\n this._initChange = false;\n },\n change: function () {\n var that = this, oldValues = that.bindings[VALUE].get(), valuePrimitive = that.options.valuePrimitive, newValues = valuePrimitive ? that.widget.value() : that.widget.dataItems();\n var field = this.options.dataValueField || this.options.dataTextField;\n newValues = newValues.slice(0);\n that._initChange = true;\n if (oldValues instanceof ObservableArray) {\n var remove = [];\n var newLength = newValues.length;\n var i = 0, j = 0;\n var old = oldValues[i];\n var same = false;\n var removeIndex;\n var newValue;\n var found;\n while (old !== undefined) {\n found = false;\n for (j = 0; j < newLength; j++) {\n if (valuePrimitive) {\n same = newValues[j] == old;\n } else {\n newValue = newValues[j];\n newValue = newValue.get ? newValue.get(field) : newValue;\n same = newValue == (old.get ? old.get(field) : old);\n }\n if (same) {\n newValues.splice(j, 1);\n newLength -= 1;\n found = true;\n break;\n }\n }\n if (!found) {\n remove.push(old);\n arraySplice(oldValues, i, 1);\n removeIndex = i;\n } else {\n i += 1;\n }\n old = oldValues[i];\n }\n arraySplice(oldValues, oldValues.length, 0, newValues);\n if (remove.length) {\n oldValues.trigger('change', {\n action: 'remove',\n items: remove,\n index: removeIndex\n });\n }\n if (newValues.length) {\n oldValues.trigger('change', {\n action: 'add',\n items: newValues,\n index: oldValues.length - 1\n });\n }\n } else {\n that.bindings[VALUE].set(newValues);\n }\n that._initChange = false;\n },\n refresh: function () {\n if (!this._initChange) {\n var options = this.options, widget = this.widget, field = options.dataValueField || options.dataTextField, value = this.bindings.value.get(), data = value, idx = 0, length, values = [], selectedValue;\n if (value === undefined) {\n value = null;\n }\n if (field) {\n if (value instanceof ObservableArray) {\n for (length = value.length; idx < length; idx++) {\n selectedValue = value[idx];\n values[idx] = selectedValue.get ? selectedValue.get(field) : selectedValue;\n }\n value = values;\n } else if (value instanceof ObservableObject) {\n value = value.get(field);\n }\n }\n if (options.autoBind === false && options.valuePrimitive !== true && !widget._isBound()) {\n widget._preselect(data, value);\n } else {\n widget.value(value);\n }\n }\n },\n destroy: function () {\n this.widget.unbind(CHANGE, this._change);\n }\n })\n },\n scheduler: {\n source: dataSourceBinding('source', 'dataSource', 'setDataSource').extend({\n dataBound: function (e) {\n var idx;\n var length;\n var widget = this.widget;\n var elements = e.addedItems || widget.items();\n var data, parents;\n if (elements.length) {\n data = e.addedDataItems || widget.dataItems();\n parents = this.bindings.source._parents();\n for (idx = 0, length = data.length; idx < length; idx++) {\n bindElement(elements[idx], data[idx], this._ns(e.ns), [data[idx]].concat(parents));\n }\n }\n }\n })\n },\n grid: {\n source: dataSourceBinding('source', 'dataSource', 'setDataSource').extend({\n dataBound: function (e) {\n var idx, length, widget = this.widget, elements = e.addedItems || widget.items(), parents, data;\n if (elements.length) {\n data = e.addedDataItems || widget.dataItems();\n parents = this.bindings.source._parents();\n for (idx = 0, length = data.length; idx < length; idx++) {\n bindElement(elements[idx], data[idx], this._ns(e.ns), [data[idx]].concat(parents));\n }\n }\n }\n })\n }\n };\n var arraySplice = function (arr, idx, remove, add) {\n add = add || [];\n remove = remove || 0;\n var addLength = add.length;\n var oldLength = arr.length;\n var shifted = [].slice.call(arr, idx + remove);\n var shiftedLength = shifted.length;\n var index;\n if (addLength) {\n addLength = idx + addLength;\n index = 0;\n for (; idx < addLength; idx++) {\n arr[idx] = add[index];\n index++;\n }\n arr.length = addLength;\n } else if (remove) {\n arr.length = idx;\n remove += idx;\n while (idx < remove) {\n delete arr[--remove];\n }\n }\n if (shiftedLength) {\n shiftedLength = idx + shiftedLength;\n index = 0;\n for (; idx < shiftedLength; idx++) {\n arr[idx] = shifted[index];\n index++;\n }\n arr.length = shiftedLength;\n }\n idx = arr.length;\n while (idx < oldLength) {\n delete arr[idx];\n idx++;\n }\n };\n var BindingTarget = Class.extend({\n init: function (target, options) {\n this.target = target;\n this.options = options;\n this.toDestroy = [];\n },\n bind: function (bindings) {\n var key, hasValue, hasSource, hasEvents, hasChecked, hasCss, widgetBinding = this instanceof WidgetBindingTarget, specificBinders = this.binders();\n for (key in bindings) {\n if (key == VALUE) {\n hasValue = true;\n } else if (key == SOURCE) {\n hasSource = true;\n } else if (key == EVENTS && !widgetBinding) {\n hasEvents = true;\n } else if (key == CHECKED) {\n hasChecked = true;\n } else if (key == CSS) {\n hasCss = true;\n } else {\n this.applyBinding(key, bindings, specificBinders);\n }\n }\n if (hasSource) {\n this.applyBinding(SOURCE, bindings, specificBinders);\n }\n if (hasValue) {\n this.applyBinding(VALUE, bindings, specificBinders);\n }\n if (hasChecked) {\n this.applyBinding(CHECKED, bindings, specificBinders);\n }\n if (hasEvents && !widgetBinding) {\n this.applyBinding(EVENTS, bindings, specificBinders);\n }\n if (hasCss && !widgetBinding) {\n this.applyBinding(CSS, bindings, specificBinders);\n }\n },\n binders: function () {\n return binders[this.target.nodeName.toLowerCase()] || {};\n },\n applyBinding: function (name, bindings, specificBinders) {\n var binder = specificBinders[name] || binders[name], toDestroy = this.toDestroy, attribute, binding = bindings[name];\n if (binder) {\n binder = new binder(this.target, bindings, this.options);\n toDestroy.push(binder);\n if (binding instanceof Binding) {\n binder.bind(binding);\n toDestroy.push(binding);\n } else {\n for (attribute in binding) {\n binder.bind(binding, attribute);\n toDestroy.push(binding[attribute]);\n }\n }\n } else if (name !== 'template') {\n throw new Error('The ' + name + ' binding is not supported by the ' + this.target.nodeName.toLowerCase() + ' element');\n }\n },\n destroy: function () {\n var idx, length, toDestroy = this.toDestroy;\n for (idx = 0, length = toDestroy.length; idx < length; idx++) {\n toDestroy[idx].destroy();\n }\n }\n });\n var WidgetBindingTarget = BindingTarget.extend({\n binders: function () {\n return binders.widget[this.target.options.name.toLowerCase()] || {};\n },\n applyBinding: function (name, bindings, specificBinders) {\n var binder = specificBinders[name] || binders.widget[name], toDestroy = this.toDestroy, attribute, binding = bindings[name];\n if (binder) {\n binder = new binder(this.target, bindings, this.target.options);\n toDestroy.push(binder);\n if (binding instanceof Binding) {\n binder.bind(binding);\n toDestroy.push(binding);\n } else {\n for (attribute in binding) {\n binder.bind(binding, attribute);\n toDestroy.push(binding[attribute]);\n }\n }\n } else {\n throw new Error('The ' + name + ' binding is not supported by the ' + this.target.options.name + ' widget');\n }\n }\n });\n function bindingTargetForRole(element, roles) {\n var widget = kendo.initWidget(element, {}, roles);\n if (widget) {\n return new WidgetBindingTarget(widget);\n }\n }\n var keyValueRegExp = /[A-Za-z0-9_\\-]+:(\\{([^}]*)\\}|[^,}]+)/g, whiteSpaceRegExp = /\\s/g;\n function parseBindings(bind) {\n var result = {}, idx, length, token, colonIndex, key, value, tokens;\n tokens = bind.match(keyValueRegExp);\n for (idx = 0, length = tokens.length; idx < length; idx++) {\n token = tokens[idx];\n colonIndex = token.indexOf(':');\n key = token.substring(0, colonIndex);\n value = token.substring(colonIndex + 1);\n if (value.charAt(0) == '{') {\n value = parseBindings(value);\n }\n result[key] = value;\n }\n return result;\n }\n function createBindings(bindings, source, type) {\n var binding, result = {};\n for (binding in bindings) {\n result[binding] = new type(source, bindings[binding]);\n }\n return result;\n }\n function bindElement(element, source, roles, parents) {\n if (!element || element.getAttribute('data-' + kendo.ns + 'stop')) {\n return;\n }\n var role = element.getAttribute('data-' + kendo.ns + 'role'), idx, bind = element.getAttribute('data-' + kendo.ns + 'bind'), childrenCopy = [], deep = true, bindings, options = {}, target;\n parents = parents || [source];\n if (role || bind) {\n unbindElement(element, false);\n }\n if (role) {\n target = bindingTargetForRole(element, roles);\n }\n if (bind) {\n bind = parseBindings(bind.replace(whiteSpaceRegExp, ''));\n if (!target) {\n options = kendo.parseOptions(element, {\n textField: '',\n valueField: '',\n template: '',\n valueUpdate: CHANGE,\n valuePrimitive: false,\n autoBind: true\n }, source);\n options.roles = roles;\n target = new BindingTarget(element, options);\n }\n target.source = source;\n bindings = createBindings(bind, parents, Binding);\n if (options.template) {\n bindings.template = new TemplateBinding(parents, '', options.template);\n }\n if (bindings.click) {\n bind.events = bind.events || {};\n bind.events.click = bind.click;\n bindings.click.destroy();\n delete bindings.click;\n }\n if (bindings.source) {\n deep = false;\n }\n if (bind.attr) {\n bindings.attr = createBindings(bind.attr, parents, Binding);\n }\n if (bind.style) {\n bindings.style = createBindings(bind.style, parents, Binding);\n }\n if (bind.events) {\n bindings.events = createBindings(bind.events, parents, EventBinding);\n }\n if (bind.css) {\n bindings.css = createBindings(bind.css, parents, Binding);\n }\n target.bind(bindings);\n }\n if (target) {\n element.kendoBindingTarget = target;\n }\n var children = element.children;\n if (deep && children && !element.getAttribute('data-' + kendo.ns + 'stop')) {\n for (idx = 0; idx < children.length; idx++) {\n childrenCopy[idx] = children[idx];\n }\n for (idx = 0; idx < childrenCopy.length; idx++) {\n bindElement(childrenCopy[idx], source, roles, parents);\n }\n }\n }\n function bind(dom, object) {\n var idx, length, node, roles = kendo.rolesFromNamespaces([].slice.call(arguments, 2));\n object = kendo.observable(object);\n dom = $(dom);\n for (idx = 0, length = dom.length; idx < length; idx++) {\n node = dom[idx];\n if (node.nodeType === 1) {\n bindElement(node, object, roles);\n }\n }\n }\n function unbindElement(element, destroyWidget) {\n var bindingTarget = element.kendoBindingTarget;\n if (bindingTarget) {\n bindingTarget.destroy();\n if (deleteExpando) {\n delete element.kendoBindingTarget;\n } else if (element.removeAttribute) {\n element.removeAttribute('kendoBindingTarget');\n } else {\n element.kendoBindingTarget = null;\n }\n }\n if (destroyWidget) {\n var widget = kendo.widgetInstance($(element));\n if (widget && typeof widget.destroy === FUNCTION) {\n widget.destroy();\n }\n }\n }\n function unbindElementTree(element, destroyWidgets) {\n unbindElement(element, destroyWidgets);\n unbindElementChildren(element, destroyWidgets);\n }\n function unbindElementChildren(element, destroyWidgets) {\n var children = element.children;\n if (children) {\n for (var idx = 0, length = children.length; idx < length; idx++) {\n unbindElementTree(children[idx], destroyWidgets);\n }\n }\n }\n function unbind(dom) {\n var idx, length;\n dom = $(dom);\n for (idx = 0, length = dom.length; idx < length; idx++) {\n unbindElementTree(dom[idx], false);\n }\n }\n function notify(widget, namespace) {\n var element = widget.element, bindingTarget = element[0].kendoBindingTarget;\n if (bindingTarget) {\n bind(element, bindingTarget.source, namespace);\n }\n }\n function retrievePrimitiveValues(value, valueField) {\n var values = [];\n var idx = 0;\n var length;\n var item;\n if (!valueField) {\n return value;\n }\n if (value instanceof ObservableArray) {\n for (length = value.length; idx < length; idx++) {\n item = value[idx];\n values[idx] = item.get ? item.get(valueField) : item[valueField];\n }\n value = values;\n } else if (value instanceof ObservableObject) {\n value = value.get(valueField);\n }\n return value;\n }\n kendo.unbind = unbind;\n kendo.bind = bind;\n kendo.data.binders = binders;\n kendo.data.Binder = Binder;\n kendo.notify = notify;\n kendo.observable = function (object) {\n if (!(object instanceof ObservableObject)) {\n object = new ObservableObject(object);\n }\n return object;\n };\n kendo.observableHierarchy = function (array) {\n var dataSource = kendo.data.HierarchicalDataSource.create(array);\n function recursiveRead(data) {\n var i, children;\n for (i = 0; i < data.length; i++) {\n data[i]._initChildren();\n children = data[i].children;\n children.fetch();\n data[i].items = children.data();\n recursiveRead(data[i].items);\n }\n }\n dataSource.fetch();\n recursiveRead(dataSource.data());\n dataSource._data._dataSource = dataSource;\n return dataSource._data;\n };\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.validator', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'validator',\n name: 'Validator',\n category: 'web',\n description: 'The Validator offers an easy way to do a client-side form validation.',\n depends: ['core']\n };\n (function ($, undefined) {\n var kendo = window.kendo, Widget = kendo.ui.Widget, NS = '.kendoValidator', INVALIDMSG = 'k-invalid-msg', invalidMsgRegExp = new RegExp(INVALIDMSG, 'i'), INVALIDINPUT = 'k-invalid', VALIDINPUT = 'k-valid', VALIDATIONSUMMARY = 'k-validation-summary', INVALIDLABEL = 'k-text-error', MESSAGEBOX = 'k-messagebox k-messagebox-error', ARIAINVALID = 'aria-invalid', ARIADESCRIBEDBY = 'aria-describedby', emailRegExp = /^[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, urlRegExp = /^(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, INPUTSELECTOR = ':input:not(:button,[type=submit],[type=reset],[disabled],[readonly])', CHECKBOXSELECTOR = ':checkbox:not([disabled],[readonly])', NUMBERINPUTSELECTOR = '[type=number],[type=range]', BLUR = 'blur', NAME = 'name', FORM = 'form', NOVALIDATE = 'novalidate', VALIDATE = 'validate', CHANGE = 'change', VALIDATE_INPUT = 'validateInput', proxy = $.proxy, patternMatcher = function (value, pattern) {\n if (typeof pattern === 'string') {\n pattern = new RegExp('^(?:' + pattern + ')$');\n }\n return pattern.test(value);\n }, matcher = function (input, selector, pattern) {\n var value = input.val();\n if (input.filter(selector).length && value !== '') {\n return patternMatcher(value, pattern);\n }\n return true;\n }, hasAttribute = function (input, name) {\n if (input.length) {\n return input[0].attributes[name] != null;\n }\n return false;\n };\n if (!kendo.ui.validator) {\n kendo.ui.validator = {\n rules: {},\n messages: {},\n allowSubmit: $.noop,\n validateOnInit: $.noop\n };\n }\n function resolveRules(element) {\n var resolvers = kendo.ui.validator.ruleResolvers || {}, rules = {}, name;\n for (name in resolvers) {\n $.extend(true, rules, resolvers[name].resolve(element));\n }\n return rules;\n }\n function decode(value) {\n return value.replace(/&/g, '&').replace(/"/g, '\"').replace(/'/g, '\\'').replace(/</g, '<').replace(/>/g, '>');\n }\n function numberOfDecimalDigits(value) {\n value = (value + '').split('.');\n if (value.length > 1) {\n return value[1].length;\n }\n return 0;\n }\n function parseHtml(text) {\n if ($.parseHTML) {\n return $($.parseHTML(text));\n }\n return $(text);\n }\n function searchForMessageContainer(elements, fieldName) {\n var containers = $(), element, attr;\n for (var idx = 0, length = elements.length; idx < length; idx++) {\n element = elements[idx];\n if (invalidMsgRegExp.test(element.className)) {\n attr = element.getAttribute(kendo.attr('for'));\n if (attr === fieldName) {\n containers = containers.add(element);\n }\n }\n }\n return containers;\n }\n var SUMMARYTEMPLATE = '';\n var Validator = Widget.extend({\n init: function (element, options) {\n var that = this, resolved = resolveRules(element), validateAttributeSelector = '[' + kendo.attr('validate') + '!=false]';\n options = options || {};\n options.rules = $.extend({}, kendo.ui.validator.rules, resolved.rules, options.rules);\n options.messages = $.extend({}, kendo.ui.validator.messages, resolved.messages, options.messages);\n Widget.fn.init.call(that, element, options);\n that._errorTemplate = kendo.template(that.options.errorTemplate);\n that._summaryTemplate = kendo.template(that.options.validationSummary.template || SUMMARYTEMPLATE);\n if (that.element.is(FORM)) {\n that.element.attr(NOVALIDATE, NOVALIDATE);\n }\n that._inputSelector = INPUTSELECTOR + validateAttributeSelector;\n that._checkboxSelector = CHECKBOXSELECTOR + validateAttributeSelector;\n that._errors = {};\n that._attachEvents();\n that._isValidated = false;\n if (that._validateOnInit()) {\n that.validate();\n }\n },\n events: [\n VALIDATE,\n CHANGE,\n VALIDATE_INPUT\n ],\n options: {\n name: 'Validator',\n errorTemplate: '#= message #',\n messages: {\n required: '{0} is required',\n pattern: '{0} is not valid',\n min: '{0} should be greater than or equal to {1}',\n max: '{0} should be smaller than or equal to {1}',\n step: '{0} is not valid',\n email: '{0} is not valid email',\n url: '{0} is not valid URL',\n date: '{0} is not valid date',\n dateCompare: 'End date should be greater than or equal to the start date'\n },\n rules: {\n required: function (input) {\n var checkbox = input.filter('[type=checkbox]').length && !input.is(':checked'), value = input.val();\n return !(hasAttribute(input, 'required') && (!value || value === '' || value.length === 0 || checkbox));\n },\n pattern: function (input) {\n if (input.filter('[type=text],[type=email],[type=url],[type=tel],[type=search],[type=password]').filter('[pattern]').length && input.val() !== '') {\n return patternMatcher(input.val(), input.attr('pattern'));\n }\n return true;\n },\n min: function (input) {\n if (input.filter(NUMBERINPUTSELECTOR + ',[' + kendo.attr('type') + '=number]').filter('[min]').length && input.val() !== '') {\n var min = parseFloat(input.attr('min')) || 0, val = kendo.parseFloat(input.val());\n return min <= val;\n }\n return true;\n },\n max: function (input) {\n if (input.filter(NUMBERINPUTSELECTOR + ',[' + kendo.attr('type') + '=number]').filter('[max]').length && input.val() !== '') {\n var max = parseFloat(input.attr('max')) || 0, val = kendo.parseFloat(input.val());\n return max >= val;\n }\n return true;\n },\n step: function (input) {\n if (input.filter(NUMBERINPUTSELECTOR + ',[' + kendo.attr('type') + '=number]').filter('[step]').length && input.val() !== '') {\n var min = parseFloat(input.attr('min')) || 0, step = parseFloat(input.attr('step')) || 1, val = parseFloat(input.val()), decimals = numberOfDecimalDigits(step), raise;\n if (decimals) {\n raise = Math.pow(10, decimals);\n return Math.floor((val - min) * raise) % (step * raise) / Math.pow(100, decimals) === 0;\n }\n return (val - min) % step === 0;\n }\n return true;\n },\n email: function (input) {\n return matcher(input, '[type=email],[' + kendo.attr('type') + '=email]', emailRegExp);\n },\n url: function (input) {\n return matcher(input, '[type=url],[' + kendo.attr('type') + '=url]', urlRegExp);\n },\n date: function (input) {\n if (input.filter('[type^=date],[' + kendo.attr('type') + '=date]').length && input.val() !== '') {\n return kendo.parseDate(input.val(), input.attr(kendo.attr('format'))) !== null;\n }\n return true;\n }\n },\n validateOnBlur: true,\n validationSummary: false\n },\n _allowSubmit: function () {\n return kendo.ui.validator.allowSubmit(this.element, this.errors());\n },\n _validateOnInit: function () {\n return kendo.ui.validator.validateOnInit(this.element);\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n this.element.off(NS);\n if (this.validationSummary) {\n this.validationSummary.off(NS);\n this.validationSummary = null;\n }\n },\n value: function () {\n if (!this._isValidated) {\n return false;\n }\n return this.errors().length === 0;\n },\n _submit: function (e) {\n if (!this.validate() && !this._allowSubmit()) {\n e.stopPropagation();\n e.stopImmediatePropagation();\n e.preventDefault();\n return false;\n }\n return true;\n },\n _checkElement: function (element) {\n var state = this.value();\n this.validateInput(element);\n if (this.value() !== state) {\n this.trigger(CHANGE);\n }\n },\n _attachEvents: function () {\n var that = this;\n if (that.element.is(FORM)) {\n that.element.on('submit' + NS, proxy(that._submit, that));\n }\n if (that.options.validateOnBlur) {\n if (!that.element.is(INPUTSELECTOR)) {\n that.element.on(BLUR + NS, that._inputSelector, function () {\n that._checkElement($(this));\n });\n that.element.on('click' + NS, that._checkboxSelector, function () {\n that._checkElement($(this));\n });\n } else {\n that.element.on(BLUR + NS, function () {\n that._checkElement(that.element);\n });\n if (that.element.is(CHECKBOXSELECTOR)) {\n that.element.on('click' + NS, function () {\n that._checkElement(that.element);\n });\n }\n }\n }\n },\n validate: function () {\n var inputs;\n var idx;\n var result = false;\n var length;\n var isValid = this.value();\n this._errors = {};\n if (!this.element.is(INPUTSELECTOR)) {\n var invalid = false;\n inputs = this.element.find(this._inputSelector);\n for (idx = 0, length = inputs.length; idx < length; idx++) {\n if (!this.validateInput(inputs.eq(idx))) {\n invalid = true;\n }\n }\n result = !invalid;\n } else {\n result = this.validateInput(this.element);\n }\n if (this.options.validationSummary && !isValid) {\n this.showValidationSummary();\n }\n this.trigger(VALIDATE, {\n valid: result,\n errors: this.errors()\n });\n if (isValid !== result) {\n this.trigger(CHANGE);\n }\n return result;\n },\n validateInput: function (input) {\n input = $(input);\n this._isValidated = true;\n var that = this, template = that._errorTemplate, result = that._checkValidity(input), valid = result.valid, className = '.' + INVALIDMSG, fieldName = input.attr(NAME) || '', lbl = that._findMessageContainer(fieldName).add(input.next(className).filter(function () {\n var element = $(this);\n if (element.filter('[' + kendo.attr('for') + ']').length) {\n return element.attr(kendo.attr('for')) === fieldName;\n }\n return true;\n })).addClass('k-hidden'), messageText = !valid ? that._extractMessage(input, result.key) : '', messageLabel = !valid ? parseHtml(template({\n message: decode(messageText),\n field: fieldName\n })) : '', wasValid = !input.attr(ARIAINVALID);\n input.removeAttr(ARIAINVALID);\n if (!valid) {\n that._errors[fieldName] = messageText;\n var lblId = lbl.attr('id');\n that._decorateMessageContainer(messageLabel, fieldName);\n if (lblId) {\n messageLabel.attr('id', lblId);\n }\n if (lbl.length !== 0) {\n lbl.replaceWith(messageLabel);\n } else {\n var widgetInstance = kendo.widgetInstance(input);\n var parentElement = input.parent().get(0);\n var nextElement = input.next().get(0);\n if (parentElement && parentElement.nodeName === 'LABEL') {\n messageLabel.insertAfter(parentElement);\n } else if (nextElement && nextElement.nodeName === 'LABEL') {\n messageLabel.insertAfter(nextElement);\n } else if (widgetInstance && widgetInstance.wrapper) {\n messageLabel.insertAfter(widgetInstance.wrapper);\n } else {\n messageLabel.insertAfter(input);\n }\n }\n messageLabel.removeClass('k-hidden');\n input.attr(ARIAINVALID, true);\n } else {\n delete that._errors[fieldName];\n }\n if (wasValid !== valid) {\n this.trigger(VALIDATE_INPUT, {\n valid: valid,\n input: input,\n error: messageText,\n field: fieldName\n });\n }\n input.toggleClass(INVALIDINPUT, !valid);\n input.toggleClass(VALIDINPUT, valid);\n if (kendo.widgetInstance(input)) {\n var inputWrap = kendo.widgetInstance(input)._inputWrapper;\n var inputLabel = kendo.widgetInstance(input)._inputLabel;\n if (inputWrap) {\n inputWrap.toggleClass(INVALIDINPUT, !valid);\n inputWrap.toggleClass(VALIDINPUT, valid);\n }\n if (inputLabel) {\n inputLabel.toggleClass(INVALIDLABEL, !valid);\n }\n }\n if (wasValid !== valid) {\n var errorId = messageLabel ? messageLabel.attr('id') : lbl.attr('id');\n that._associateMessageContainer(input, errorId);\n if (this.options.validationSummary && this.options.validateOnBlur) {\n this.showValidationSummary();\n }\n }\n return valid;\n },\n hideMessages: function () {\n var that = this, className = '.' + INVALIDMSG, element = that.element;\n that._disassociateMessageContainers();\n if (!element.is(INPUTSELECTOR)) {\n element.find(className).addClass('k-hidden');\n } else {\n element.next(className).addClass('k-hidden');\n }\n },\n reset: function () {\n var that = this, inputs = that.element.find('.' + INVALIDINPUT), labels = that.element.find('.' + INVALIDLABEL);\n that._errors = [];\n that.hideMessages();\n that.hideValidationSummary();\n inputs.removeAttr(ARIAINVALID);\n inputs.removeClass(INVALIDINPUT);\n labels.removeClass(INVALIDLABEL);\n },\n _findMessageContainer: function (fieldName) {\n var locators = kendo.ui.validator.messageLocators, name, containers = $();\n for (var idx = 0, length = this.element.length; idx < length; idx++) {\n containers = containers.add(searchForMessageContainer(this.element[idx].getElementsByTagName('*'), fieldName));\n }\n for (name in locators) {\n containers = containers.add(locators[name].locate(this.element, fieldName));\n }\n return containers;\n },\n _decorateMessageContainer: function (container, fieldName) {\n var locators = kendo.ui.validator.messageLocators, name;\n container.addClass(INVALIDMSG).attr(kendo.attr('for'), fieldName || '');\n if (!container.attr('id')) {\n container.attr('id', fieldName + '-error');\n }\n for (name in locators) {\n locators[name].decorate(container, fieldName);\n }\n },\n _extractMessage: function (input, ruleKey) {\n var that = this, customMessage = that.options.messages[ruleKey], fieldName = input.attr(NAME), nonDefaultMessage;\n if (!kendo.ui.Validator.prototype.options.messages[ruleKey]) {\n nonDefaultMessage = kendo.isFunction(customMessage) ? customMessage(input) : customMessage;\n }\n customMessage = kendo.isFunction(customMessage) ? customMessage(input) : customMessage;\n return kendo.format(input.attr(kendo.attr(ruleKey + '-msg')) || input.attr('validationMessage') || nonDefaultMessage || customMessage || input.attr('title') || '', fieldName, input.attr(ruleKey) || input.attr(kendo.attr(ruleKey)));\n },\n _checkValidity: function (input) {\n var rules = this.options.rules, rule;\n for (rule in rules) {\n if (!rules[rule].call(this, input)) {\n return {\n valid: false,\n key: rule\n };\n }\n }\n return { valid: true };\n },\n errors: function () {\n var results = [], errors = this._errors, error;\n for (error in errors) {\n results.push(errors[error]);\n }\n return results;\n },\n setOptions: function (options) {\n if (options.validationSummary) {\n this.hideValidationSummary();\n }\n kendo.deepExtend(this.options, options);\n this.destroy();\n this.init(this.element, this.options);\n this._setEvents(this.options);\n },\n _getInputNames: function () {\n var that = this, inputs = that.element.find(that._inputSelector), sorted = [];\n for (var idx = 0, length = inputs.length; idx < length; idx++) {\n var input = $(inputs[idx]);\n if (hasAttribute(input, NAME)) {\n sorted.push(input.attr(NAME));\n }\n }\n return sorted;\n },\n _associateMessageContainer: function (input, errorId) {\n var nextFocusable = kendo.getWidgetFocusableElement(input);\n if (!nextFocusable || !errorId) {\n return;\n }\n kendo.toggleAttribute(nextFocusable, ARIADESCRIBEDBY, errorId);\n },\n _disassociateMessageContainers: function () {\n var that = this, inputs = that.element.find('.' + INVALIDINPUT).addBack(), input, errorId;\n for (var i = 0; i < inputs.length; i += 1) {\n input = $(inputs[i]);\n if (input.is('input')) {\n errorId = that._findMessageContainer(input.attr(NAME)).add(input.next('.' + INVALIDMSG)).attr('id');\n that._associateMessageContainer(input, errorId);\n }\n }\n },\n _errorsByName: function () {\n var that = this, inputNames = that._getInputNames(), sorted = [];\n for (var i = 0; i < inputNames.length; i += 1) {\n var name = inputNames[i];\n if (that._errors[name]) {\n sorted.push({\n field: name,\n message: that._errors[name]\n });\n }\n }\n return sorted;\n },\n _renderSummary: function () {\n var that = this, options = this.options.validationSummary, element = this.element, prevElement = element.prev(), container;\n if (options.container) {\n container = $(options.container);\n } else if (prevElement && prevElement.hasClass(VALIDATIONSUMMARY)) {\n container = prevElement;\n } else {\n container = $('
    ').insertBefore(that.element);\n }\n container.addClass([\n VALIDATIONSUMMARY,\n MESSAGEBOX\n ].join(' '));\n container.attr('role', 'alert');\n container.on('click' + NS, proxy(that._summaryClick, that));\n return container;\n },\n _summaryClick: function (e) {\n e.preventDefault();\n var that = this, link = $(e.target), target = that.element.find('[name=\\'' + link.data('field') + '\\']'), nextFocusable;\n if (!target.length) {\n return;\n }\n nextFocusable = kendo.getWidgetFocusableElement(target);\n if (nextFocusable) {\n nextFocusable.focus();\n }\n },\n showValidationSummary: function () {\n var that = this, summary = that.validationSummary, errors = that._errorsByName(), errorsList;\n if (!summary) {\n summary = that.validationSummary = that._renderSummary();\n }\n errorsList = parseHtml(that._summaryTemplate({ errors: errors }));\n summary.html(errorsList);\n summary.toggleClass('k-hidden', !errors.length);\n },\n hideValidationSummary: function () {\n var that = this, summary = that.validationSummary;\n if (!summary) {\n return;\n }\n summary.addClass('k-hidden');\n }\n });\n kendo.ui.plugin(Validator);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.router', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'router',\n name: 'Router',\n category: 'framework',\n description: 'The Router class is responsible for tracking the application state and navigating between the application states.',\n depends: ['core'],\n hidden: false\n };\n (function ($, undefined) {\n var kendo = window.kendo, CHANGE = 'change', BACK = 'back', SAME = 'same', support = kendo.support, location = window.location, history = window.history, CHECK_URL_INTERVAL = 50, BROKEN_BACK_NAV = kendo.support.browser.msie, hashStrip = /^#*/, document = window.document;\n function absoluteURL(path, pathPrefix) {\n if (!pathPrefix) {\n return path;\n }\n if (path + '/' === pathPrefix) {\n path = pathPrefix;\n }\n var regEx = new RegExp('^' + pathPrefix, 'i');\n if (!regEx.test(path)) {\n path = pathPrefix + '/' + path;\n }\n return location.protocol + '//' + (location.host + '/' + path).replace(/\\/\\/+/g, '/');\n }\n function hashDelimiter(bang) {\n return bang ? '#!' : '#';\n }\n function locationHash(hashDelimiter) {\n var href = location.href;\n if (hashDelimiter === '#!' && href.indexOf('#') > -1 && href.indexOf('#!') < 0) {\n return null;\n }\n return href.split(hashDelimiter)[1] || '';\n }\n function stripRoot(root, url) {\n if (url.indexOf(root) === 0) {\n return url.substr(root.length).replace(/\\/\\//g, '/');\n } else {\n return url;\n }\n }\n var HistoryAdapter = kendo.Class.extend({\n back: function () {\n if (BROKEN_BACK_NAV) {\n setTimeout(function () {\n history.back();\n });\n } else {\n history.back();\n }\n },\n forward: function () {\n if (BROKEN_BACK_NAV) {\n setTimeout(function () {\n history.forward();\n });\n } else {\n history.forward();\n }\n },\n length: function () {\n return history.length;\n },\n replaceLocation: function (url) {\n location.replace(url);\n }\n });\n var PushStateAdapter = HistoryAdapter.extend({\n init: function (root) {\n this.root = root;\n },\n navigate: function (to) {\n history.pushState({}, document.title, absoluteURL(to, this.root));\n },\n replace: function (to) {\n history.replaceState({}, document.title, absoluteURL(to, this.root));\n },\n normalize: function (url) {\n return stripRoot(this.root, url);\n },\n current: function () {\n var current = location.pathname;\n if (location.search) {\n current += location.search;\n }\n return stripRoot(this.root, current);\n },\n change: function (callback) {\n $(window).bind('popstate.kendo', callback);\n },\n stop: function () {\n $(window).unbind('popstate.kendo');\n },\n normalizeCurrent: function (options) {\n var fixedUrl, root = options.root, pathname = location.pathname, hash = locationHash(hashDelimiter(options.hashBang));\n if (root === pathname + '/') {\n fixedUrl = root;\n }\n if (root === pathname && hash) {\n fixedUrl = absoluteURL(hash.replace(hashStrip, ''), root);\n }\n if (fixedUrl) {\n history.pushState({}, document.title, fixedUrl);\n }\n }\n });\n function fixHash(url) {\n return url.replace(/^(#)?/, '#');\n }\n function fixBang(url) {\n return url.replace(/^(#(!)?)?/, '#!');\n }\n var HashAdapter = HistoryAdapter.extend({\n init: function (bang) {\n this._id = kendo.guid();\n this.prefix = hashDelimiter(bang);\n this.fix = bang ? fixBang : fixHash;\n },\n navigate: function (to) {\n location.hash = this.fix(to);\n },\n replace: function (to) {\n this.replaceLocation(this.fix(to));\n },\n normalize: function (url) {\n if (url.indexOf(this.prefix) < 0) {\n return url;\n } else {\n return url.split(this.prefix)[1];\n }\n },\n change: function (callback) {\n if (support.hashChange) {\n $(window).on('hashchange.' + this._id, callback);\n } else {\n this._interval = setInterval(callback, CHECK_URL_INTERVAL);\n }\n },\n stop: function () {\n $(window).off('hashchange.' + this._id);\n clearInterval(this._interval);\n },\n current: function () {\n return locationHash(this.prefix);\n },\n normalizeCurrent: function (options) {\n var pathname = location.pathname, root = options.root;\n if (options.pushState && root !== pathname) {\n this.replaceLocation(root + this.prefix + stripRoot(root, pathname));\n return true;\n }\n return false;\n }\n });\n var History = kendo.Observable.extend({\n start: function (options) {\n options = options || {};\n this.bind([\n CHANGE,\n BACK,\n SAME\n ], options);\n if (this._started) {\n return;\n }\n this._started = true;\n options.root = options.root || '/';\n var adapter = this.createAdapter(options), current;\n if (adapter.normalizeCurrent(options)) {\n return;\n }\n current = adapter.current();\n $.extend(this, {\n adapter: adapter,\n root: options.root,\n historyLength: adapter.length(),\n current: current,\n locations: [current]\n });\n adapter.change($.proxy(this, '_checkUrl'));\n },\n createAdapter: function (options) {\n return support.pushState && options.pushState ? new PushStateAdapter(options.root) : new HashAdapter(options.hashBang);\n },\n stop: function () {\n if (!this._started) {\n return;\n }\n this.adapter.stop();\n this.unbind(CHANGE);\n this._started = false;\n },\n change: function (callback) {\n this.bind(CHANGE, callback);\n },\n replace: function (to, silent) {\n this._navigate(to, silent, function (adapter) {\n adapter.replace(to);\n this.locations[this.locations.length - 1] = this.current;\n });\n },\n navigate: function (to, silent) {\n if (to === '#:back') {\n this.backCalled = true;\n this.adapter.back();\n return;\n }\n this._navigate(to, silent, function (adapter) {\n adapter.navigate(to);\n this.locations.push(this.current);\n });\n },\n _navigate: function (to, silent, callback) {\n var adapter = this.adapter;\n to = adapter.normalize(to);\n if (this.current === to || this.current === decodeURIComponent(to)) {\n this.trigger(SAME);\n return;\n }\n if (!silent) {\n if (this.trigger(CHANGE, {\n url: to,\n decode: false\n })) {\n return;\n }\n }\n this.current = to;\n callback.call(this, adapter);\n this.historyLength = adapter.length();\n },\n _checkUrl: function () {\n var adapter = this.adapter, current = adapter.current(), newLength = adapter.length(), navigatingInExisting = this.historyLength === newLength, back = current === this.locations[this.locations.length - 2] && navigatingInExisting, backCalled = this.backCalled, prev = this.current;\n if (current === null || this.current === current || this.current === decodeURIComponent(current)) {\n return true;\n }\n this.historyLength = newLength;\n this.backCalled = false;\n this.current = current;\n if (back && this.trigger('back', {\n url: prev,\n to: current\n })) {\n adapter.forward();\n this.current = prev;\n return;\n }\n if (this.trigger(CHANGE, {\n url: current,\n backButtonPressed: !backCalled\n })) {\n if (back) {\n adapter.forward();\n } else {\n adapter.back();\n this.historyLength--;\n }\n this.current = prev;\n return;\n }\n if (back) {\n this.locations.pop();\n } else {\n this.locations.push(current);\n }\n }\n });\n kendo.History = History;\n kendo.History.HistoryAdapter = HistoryAdapter;\n kendo.History.HashAdapter = HashAdapter;\n kendo.History.PushStateAdapter = PushStateAdapter;\n kendo.absoluteURL = absoluteURL;\n kendo.history = new History();\n }(window.kendo.jQuery));\n (function () {\n var kendo = window.kendo, history = kendo.history, Observable = kendo.Observable, INIT = 'init', ROUTE_MISSING = 'routeMissing', CHANGE = 'change', BACK = 'back', SAME = 'same', optionalParam = /\\((.*?)\\)/g, namedParam = /(\\(\\?)?:\\w+/g, splatParam = /\\*\\w+/g, escapeRegExp = /[\\-{}\\[\\]+?.,\\\\\\^$|#\\s]/g;\n function namedParamReplace(match, optional) {\n return optional ? match : '([^/]+)';\n }\n function routeToRegExp(route, ignoreCase) {\n return new RegExp('^' + route.replace(escapeRegExp, '\\\\$&').replace(optionalParam, '(?:$1)?').replace(namedParam, namedParamReplace).replace(splatParam, '(.*?)') + '$', ignoreCase ? 'i' : '');\n }\n function stripUrl(url) {\n return url.replace(/(\\?.*)|(#.*)/g, '');\n }\n var Route = kendo.Class.extend({\n init: function (route, callback, ignoreCase) {\n if (!(route instanceof RegExp)) {\n route = routeToRegExp(route, ignoreCase);\n }\n this.route = route;\n this._callback = callback;\n },\n callback: function (url, back, decode) {\n var params, idx = 0, length, queryStringParams = kendo.parseQueryStringParams(url);\n queryStringParams._back = back;\n url = stripUrl(url);\n params = this.route.exec(url).slice(1);\n length = params.length;\n if (decode) {\n for (; idx < length; idx++) {\n if (typeof params[idx] !== 'undefined') {\n params[idx] = decodeURIComponent(params[idx]);\n }\n }\n }\n params.push(queryStringParams);\n this._callback.apply(null, params);\n },\n worksWith: function (url, back, decode) {\n if (this.route.test(stripUrl(url))) {\n this.callback(url, back, decode);\n return true;\n } else {\n return false;\n }\n }\n });\n var Router = Observable.extend({\n init: function (options) {\n if (!options) {\n options = {};\n }\n Observable.fn.init.call(this);\n this.routes = [];\n this.pushState = options.pushState;\n this.hashBang = options.hashBang;\n this.root = options.root;\n this.ignoreCase = options.ignoreCase !== false;\n this.bind([\n INIT,\n ROUTE_MISSING,\n CHANGE,\n SAME,\n BACK\n ], options);\n },\n destroy: function () {\n history.unbind(CHANGE, this._urlChangedProxy);\n history.unbind(SAME, this._sameProxy);\n history.unbind(BACK, this._backProxy);\n this.unbind();\n },\n start: function () {\n var that = this, sameProxy = function () {\n that._same();\n }, backProxy = function (e) {\n that._back(e);\n }, urlChangedProxy = function (e) {\n that._urlChanged(e);\n };\n history.start({\n same: sameProxy,\n change: urlChangedProxy,\n back: backProxy,\n pushState: that.pushState,\n hashBang: that.hashBang,\n root: that.root\n });\n var initEventObject = {\n url: history.current || '/',\n preventDefault: $.noop\n };\n if (!that.trigger(INIT, initEventObject)) {\n that._urlChanged(initEventObject);\n }\n this._urlChangedProxy = urlChangedProxy;\n this._backProxy = backProxy;\n },\n route: function (route, callback) {\n this.routes.push(new Route(route, callback, this.ignoreCase));\n },\n navigate: function (url, silent) {\n kendo.history.navigate(url, silent);\n },\n replace: function (url, silent) {\n kendo.history.replace(url, silent);\n },\n _back: function (e) {\n if (this.trigger(BACK, {\n url: e.url,\n to: e.to\n })) {\n e.preventDefault();\n }\n },\n _same: function () {\n this.trigger(SAME);\n },\n _urlChanged: function (e) {\n var url = e.url;\n var decode = !!e.decode;\n var back = e.backButtonPressed;\n if (!url) {\n url = '/';\n }\n if (this.trigger(CHANGE, {\n url: e.url,\n params: kendo.parseQueryStringParams(e.url),\n backButtonPressed: back\n })) {\n e.preventDefault();\n return;\n }\n var idx = 0, routes = this.routes, route, length = routes.length;\n for (; idx < length; idx++) {\n route = routes[idx];\n if (route.worksWith(url, back, decode)) {\n return;\n }\n }\n if (this.trigger(ROUTE_MISSING, {\n url: url,\n params: kendo.parseQueryStringParams(url),\n backButtonPressed: back\n })) {\n e.preventDefault();\n }\n }\n });\n kendo.Router = Router;\n }());\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.view', [\n 'kendo.core',\n 'kendo.binder',\n 'kendo.fx'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'view',\n name: 'View',\n category: 'framework',\n description: 'The View class instantiates and handles the events of a certain screen from the application.',\n depends: [\n 'core',\n 'binder',\n 'fx'\n ],\n hidden: false\n };\n (function ($, undefined) {\n var kendo = window.kendo, attr = kendo.attr, ui = kendo.ui, attrValue = kendo.attrValue, directiveSelector = kendo.directiveSelector, Observable = kendo.Observable, Widget = kendo.ui.Widget, roleSelector = kendo.roleSelector, SCRIPT = 'SCRIPT', INIT = 'init', TRANSITION_START = 'transitionStart', TRANSITION_END = 'transitionEnd', SHOW = 'show', HIDE = 'hide', ATTACH = 'attach', DETACH = 'detach', sizzleErrorRegExp = /unrecognized expression/;\n var bodyRegExp = /]*>(([\\u000a\\u000d\\u2028\\u2029]|.)*)<\\/body>/i;\n var LOAD_START = 'loadStart';\n var LOAD_COMPLETE = 'loadComplete';\n var SHOW_START = 'showStart';\n var SAME_VIEW_REQUESTED = 'sameViewRequested';\n var VIEW_SHOW = 'viewShow';\n var VIEW_TYPE_DETERMINED = 'viewTypeDetermined';\n var AFTER = 'after';\n var classNames = {\n content: 'k-content',\n view: 'k-view',\n stretchedView: 'k-stretched-view',\n widget: 'k-widget',\n header: 'k-header',\n footer: 'k-footer'\n };\n var View = kendo.ui.Widget.extend({\n init: function (content, options) {\n var that = this;\n options = options || {};\n that.id = kendo.guid();\n Observable.fn.init.call(that);\n this.options = $.extend({}, this.options, options);\n that.content = content;\n if (that.options.renderOnInit) {\n Widget.fn.init.call(that, that._createElement(), options);\n }\n if (that.options.wrapInSections) {\n that._renderSections();\n }\n that.tagName = options.tagName || 'div';\n that.model = options.model;\n that._wrap = options.wrap !== false;\n this._evalTemplate = options.evalTemplate || false;\n that._fragments = {};\n that.bind([\n INIT,\n SHOW,\n HIDE,\n TRANSITION_START,\n TRANSITION_END\n ], options);\n },\n options: {\n name: 'View',\n renderOnInit: false,\n wrapInSections: false,\n detachOnHide: true,\n detachOnDestroy: true\n },\n render: function (container) {\n var that = this, notInitialized = !that.element;\n if (notInitialized) {\n that.element = that._createElement();\n }\n if (container) {\n $(container).append(that.element);\n }\n if (notInitialized) {\n kendo.bind(that.element, that.model);\n that.trigger(INIT);\n }\n if (container) {\n that._eachFragment(ATTACH);\n that.trigger(SHOW);\n }\n return that.element;\n },\n clone: function () {\n return new ViewClone(this);\n },\n triggerBeforeShow: function () {\n return true;\n },\n triggerBeforeHide: function () {\n return true;\n },\n showStart: function () {\n var that = this;\n var element = that.render();\n if (element) {\n element.css('display', '');\n }\n this.trigger(SHOW_START, { view: this });\n },\n showEnd: function () {\n },\n hideEnd: function () {\n this.hide();\n },\n beforeTransition: function (type) {\n this.trigger(TRANSITION_START, { type: type });\n },\n afterTransition: function (type) {\n this.trigger(TRANSITION_END, { type: type });\n },\n hide: function () {\n if (this.options.detachOnHide) {\n this._eachFragment(DETACH);\n $(this.element).detach();\n }\n this.trigger(HIDE);\n },\n destroy: function () {\n var that = this;\n var element = that.element;\n if (element) {\n Widget.fn.destroy.call(that);\n kendo.unbind(element);\n kendo.destroy(element);\n if (that.options.detachOnDestroy) {\n element.remove();\n }\n }\n },\n purge: function () {\n var that = this;\n that.destroy();\n $(that.element).add(that.content).add(that.wrapper).off().remove();\n },\n fragments: function (fragments) {\n $.extend(this._fragments, fragments);\n },\n _eachFragment: function (methodName) {\n for (var placeholder in this._fragments) {\n this._fragments[placeholder][methodName](this, placeholder);\n }\n },\n _createElement: function () {\n var that = this, wrapper = '<' + that.tagName + '>', element, content;\n try {\n content = $(document.getElementById(that.content) || that.content);\n if (content[0].tagName === SCRIPT) {\n content = content.html();\n }\n } catch (e) {\n if (sizzleErrorRegExp.test(e.message)) {\n content = that.content;\n }\n }\n if (typeof content === 'string') {\n content = content.replace(/^\\s+|\\s+$/g, '');\n if (that._evalTemplate) {\n content = kendo.template(content)(that.model || {});\n }\n element = $(wrapper).append(content);\n if (!that._wrap) {\n element = element.contents();\n }\n } else {\n element = content;\n if (that._evalTemplate) {\n var result = $(kendo.template($('
    ').append(element.clone(true)).html())(that.model || {}));\n if ($.contains(document, element[0])) {\n element.replaceWith(result);\n }\n element = result;\n }\n if (that._wrap) {\n element = element.wrapAll(wrapper).parent();\n }\n }\n return element;\n },\n _renderSections: function () {\n var that = this;\n if (that.options.wrapInSections) {\n that._wrapper();\n that._createContent();\n that._createHeader();\n that._createFooter();\n }\n },\n _wrapper: function () {\n var that = this;\n var content = that.content;\n if (content.is(roleSelector('view'))) {\n that.wrapper = that.content;\n } else {\n that.wrapper = content.wrap('
    ').parent();\n }\n var wrapper = that.wrapper;\n wrapper.attr('id', that.id);\n wrapper.addClass(classNames.view);\n wrapper.addClass(classNames.widget);\n wrapper.attr('role', 'view');\n },\n _createContent: function () {\n var that = this;\n var wrapper = $(that.wrapper);\n var contentSelector = roleSelector('content');\n if (!wrapper.children(contentSelector)[0]) {\n var ccontentElements = wrapper.children().filter(function () {\n var child = $(this);\n if (!child.is(roleSelector('header')) && !child.is(roleSelector('footer'))) {\n return child;\n }\n });\n ccontentElements.wrap('
    ');\n }\n this.contentElement = wrapper.children(roleSelector('content'));\n this.contentElement.addClass(classNames.stretchedView).addClass(classNames.content);\n },\n _createHeader: function () {\n var that = this;\n var wrapper = that.wrapper;\n this.header = wrapper.children(roleSelector('header')).addClass(classNames.header);\n },\n _createFooter: function () {\n var that = this;\n var wrapper = that.wrapper;\n this.footer = wrapper.children(roleSelector('footer')).addClass(classNames.footer);\n }\n });\n var ViewClone = kendo.Class.extend({\n init: function (view) {\n $.extend(this, {\n element: view.element.clone(true),\n transition: view.transition,\n id: view.id\n });\n view.element.parent().append(this.element);\n },\n hideEnd: function () {\n this.element.remove();\n },\n beforeTransition: $.noop,\n afterTransition: $.noop\n });\n var Layout = View.extend({\n init: function (content, options) {\n View.fn.init.call(this, content, options);\n this.containers = {};\n },\n container: function (selector) {\n var container = this.containers[selector];\n if (!container) {\n container = this._createContainer(selector);\n this.containers[selector] = container;\n }\n return container;\n },\n showIn: function (selector, view, transition) {\n this.container(selector).show(view, transition);\n },\n _createContainer: function (selector) {\n var root = this.render(), element = root.find(selector), container;\n if (!element.length && root.is(selector)) {\n if (root.is(selector)) {\n element = root;\n } else {\n throw new Error('can\\'t find a container with the specified ' + selector + ' selector');\n }\n }\n container = new ViewContainer(element);\n container.bind('accepted', function (e) {\n e.view.render(element);\n });\n return container;\n }\n });\n var Fragment = View.extend({\n attach: function (view, placeholder) {\n view.element.find(placeholder).replaceWith(this.render());\n },\n detach: function () {\n }\n });\n var transitionRegExp = /^(\\w+)(:(\\w+))?( (\\w+))?$/;\n function parseTransition(transition) {\n if (!transition) {\n return {};\n }\n var matches = transition.match(transitionRegExp) || [];\n return {\n type: matches[1],\n direction: matches[3],\n reverse: matches[5] === 'reverse'\n };\n }\n var ViewContainer = Observable.extend({\n init: function (container) {\n Observable.fn.init.call(this);\n this.container = container;\n this.history = [];\n this.view = null;\n this.running = false;\n },\n after: function () {\n this.running = false;\n this.trigger('complete', { view: this.view });\n this.trigger('after');\n },\n end: function () {\n this.view.showEnd();\n this.previous.hideEnd();\n this.after();\n },\n show: function (view, transition, locationID) {\n if (!view.triggerBeforeShow() || this.view && !this.view.triggerBeforeHide()) {\n this.trigger('after');\n return false;\n }\n locationID = locationID || view.id;\n var that = this, current = view === that.view ? view.clone() : that.view, history = that.history, previousEntry = history[history.length - 2] || {}, back = previousEntry.id === locationID, theTransition = transition || (back ? history[history.length - 1].transition : view.transition), transitionData = parseTransition(theTransition);\n if (that.running) {\n that.effect.stop();\n }\n if (theTransition === 'none') {\n theTransition = null;\n }\n that.trigger('accepted', { view: view });\n that.view = view;\n that.previous = current;\n that.running = true;\n if (!back) {\n history.push({\n id: locationID,\n transition: theTransition\n });\n } else {\n history.pop();\n }\n if (!current) {\n view.showStart();\n view.showEnd();\n that.after();\n return true;\n }\n if (!theTransition || !kendo.effects.enabled) {\n view.showStart();\n that.end();\n } else {\n view.element.addClass('k-fx-hidden');\n view.showStart();\n if (back && !transition) {\n transitionData.reverse = !transitionData.reverse;\n }\n that.effect = kendo.fx(view.element).replace(current.element, transitionData.type).beforeTransition(function () {\n view.beforeTransition('show');\n current.beforeTransition('hide');\n }).afterTransition(function () {\n view.afterTransition('show');\n current.afterTransition('hide');\n }).direction(transitionData.direction).setReverse(transitionData.reverse);\n that.effect.run().then(function () {\n that.end();\n });\n }\n return true;\n },\n destroy: function () {\n var that = this;\n var view = that.view;\n if (view && view.destroy) {\n view.destroy();\n }\n }\n });\n var ViewEngine = Observable.extend({\n init: function (options) {\n var that = this, views, container;\n Observable.fn.init.call(that);\n that.options = options;\n $.extend(that, options);\n that.sandbox = $('
    ');\n container = that.container;\n views = that._hideViews(container);\n that.rootView = views.first();\n that.layouts = {};\n that.viewContainer = new kendo.ViewContainer(that.container);\n that.viewContainer.bind('accepted', function (e) {\n e.view.params = that.params;\n });\n that.viewContainer.bind('complete', function (e) {\n that.trigger(VIEW_SHOW, { view: e.view });\n });\n that.viewContainer.bind(AFTER, function () {\n that.trigger(AFTER);\n });\n this.bind(this.events, options);\n },\n events: [\n SHOW_START,\n AFTER,\n VIEW_SHOW,\n LOAD_START,\n LOAD_COMPLETE,\n SAME_VIEW_REQUESTED,\n VIEW_TYPE_DETERMINED\n ],\n destroy: function () {\n var that = this;\n var viewContainer = that.viewContainer;\n kendo.destroy(that.container);\n for (var id in that.layouts) {\n this.layouts[id].destroy();\n }\n if (viewContainer) {\n viewContainer.destroy();\n }\n },\n view: function () {\n return this.viewContainer.view;\n },\n showView: function (url, transition, params) {\n url = url.replace(new RegExp('^' + this.remoteViewURLPrefix), '');\n if (url === '' && this.remoteViewURLPrefix) {\n url = '/';\n }\n if (url.replace(/^#/, '') === this.url) {\n this.trigger(SAME_VIEW_REQUESTED);\n return false;\n }\n this.trigger(SHOW_START);\n var that = this, element = that._findViewElement(url), view = kendo.widgetInstance(element);\n that.url = url.replace(/^#/, '');\n that.params = params;\n if (view && view.reload) {\n view.purge();\n element = [];\n }\n this.trigger(VIEW_TYPE_DETERMINED, {\n remote: element.length === 0,\n url: url\n });\n if (element[0]) {\n if (!view) {\n view = that._createView(element);\n }\n return that.viewContainer.show(view, transition, url);\n } else {\n return true;\n }\n },\n append: function (html, url) {\n var sandbox = this.sandbox, urlPath = (url || '').split('?')[0], container = this.container, views, view;\n if (bodyRegExp.test(html)) {\n html = RegExp.$1;\n }\n sandbox[0].innerHTML = html;\n container.append(sandbox.children('script, style'));\n views = this._hideViews(sandbox);\n view = views.first();\n if (!view.length) {\n views = view = sandbox.wrapInner('
    ').children();\n }\n if (urlPath) {\n view.hide().attr(attr('url'), urlPath);\n }\n container.append(views);\n return this._createView(view);\n },\n _locate: function (selectors) {\n return this.$angular ? directiveSelector(selectors) : roleSelector(selectors);\n },\n _findViewElement: function (url) {\n var element, urlPath = url.split('?')[0];\n if (!urlPath) {\n return this.rootView;\n }\n element = this.container.children('[' + attr('url') + '=\\'' + urlPath + '\\']');\n if (!element[0] && urlPath.indexOf('/') === -1) {\n element = this.container.children(urlPath.charAt(0) === '#' ? urlPath : '#' + urlPath);\n }\n if (!element[0]) {\n element = this._findViewElementById(url);\n }\n return element;\n },\n _findViewElementById: function (id) {\n var element = this.container.children('[id=\\'' + id + '\\']');\n return element;\n },\n _createView: function (element) {\n return this._createSpaView(element);\n },\n _createMobileView: function (element) {\n return kendo.initWidget(element, {\n defaultTransition: this.transition,\n loader: this.loader,\n container: this.container,\n getLayout: this.getLayoutProxy,\n modelScope: this.modelScope,\n reload: attrValue(element, 'reload')\n }, ui.roles);\n },\n _createSpaView: function (element) {\n var viewOptions = (this.options || {}).viewOptions || {};\n return new kendo.View(element, {\n renderOnInit: viewOptions.renderOnInit,\n wrap: viewOptions.wrap || false,\n wrapInSections: viewOptions.wrapInSections,\n detachOnHide: viewOptions.detachOnHide,\n detachOnDestroy: viewOptions.detachOnDestroy\n });\n },\n _hideViews: function (container) {\n return container.children(this._locate('view')).hide();\n }\n });\n kendo.ViewEngine = ViewEngine;\n kendo.ViewContainer = ViewContainer;\n kendo.Fragment = Fragment;\n kendo.Layout = Layout;\n kendo.View = View;\n kendo.ViewClone = ViewClone;\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.userevents', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'userevents',\n name: 'User Events',\n category: 'framework',\n depends: ['core'],\n hidden: true\n };\n (function ($, undefined) {\n var kendo = window.kendo, support = kendo.support, Class = kendo.Class, Observable = kendo.Observable, now = $.now, extend = $.extend, OS = support.mobileOS, invalidZeroEvents = OS && OS.android, DEFAULT_MIN_HOLD = 800, CLICK_DELAY = 300, DEFAULT_THRESHOLD = support.browser.msie ? 5 : 0, PRESS = 'press', HOLD = 'hold', SELECT = 'select', START = 'start', MOVE = 'move', END = 'end', CANCEL = 'cancel', TAP = 'tap', DOUBLETAP = 'doubleTap', RELEASE = 'release', GESTURESTART = 'gesturestart', GESTURECHANGE = 'gesturechange', GESTUREEND = 'gestureend', GESTURETAP = 'gesturetap';\n var THRESHOLD = {\n 'api': 0,\n 'touch': 0,\n 'mouse': 9,\n 'pointer': 9\n };\n var ENABLE_GLOBAL_SURFACE = !support.touch || support.mouseAndTouchPresent;\n function touchDelta(touch1, touch2) {\n var x1 = touch1.x.location, y1 = touch1.y.location, x2 = touch2.x.location, y2 = touch2.y.location, dx = x1 - x2, dy = y1 - y2;\n return {\n center: {\n x: (x1 + x2) / 2,\n y: (y1 + y2) / 2\n },\n distance: Math.sqrt(dx * dx + dy * dy)\n };\n }\n function getTouches(e) {\n var touches = [], originalEvent = e.originalEvent, currentTarget = e.currentTarget, idx = 0, length, changedTouches, touch;\n if (e.api) {\n touches.push({\n id: 2,\n event: e,\n target: e.target,\n currentTarget: e.target,\n location: e,\n type: 'api'\n });\n } else if (e.type.match(/touch/)) {\n changedTouches = originalEvent ? originalEvent.changedTouches : [];\n for (length = changedTouches.length; idx < length; idx++) {\n touch = changedTouches[idx];\n touches.push({\n location: touch,\n event: e,\n target: touch.target,\n currentTarget: currentTarget,\n id: touch.identifier,\n type: 'touch'\n });\n }\n } else if (support.pointers || support.msPointers) {\n touches.push({\n location: originalEvent,\n event: e,\n target: e.target,\n currentTarget: currentTarget,\n id: originalEvent.pointerId,\n type: 'pointer'\n });\n } else {\n touches.push({\n id: 1,\n event: e,\n target: e.target,\n currentTarget: currentTarget,\n location: e,\n type: 'mouse'\n });\n }\n return touches;\n }\n var TouchAxis = Class.extend({\n init: function (axis, location) {\n var that = this;\n that.axis = axis;\n that._updateLocationData(location);\n that.startLocation = that.location;\n that.velocity = that.delta = 0;\n that.timeStamp = now();\n },\n move: function (location) {\n var that = this, offset = location['page' + that.axis], timeStamp = now(), timeDelta = timeStamp - that.timeStamp || 1;\n if (!offset && invalidZeroEvents) {\n return;\n }\n that.delta = offset - that.location;\n that._updateLocationData(location);\n that.initialDelta = offset - that.startLocation;\n that.velocity = that.delta / timeDelta;\n that.timeStamp = timeStamp;\n },\n _updateLocationData: function (location) {\n var that = this, axis = that.axis;\n that.location = location['page' + axis];\n that.client = location['client' + axis];\n that.screen = location['screen' + axis];\n }\n });\n var Touch = Class.extend({\n init: function (userEvents, target, touchInfo) {\n extend(this, {\n x: new TouchAxis('X', touchInfo.location),\n y: new TouchAxis('Y', touchInfo.location),\n type: touchInfo.type,\n useClickAsTap: userEvents.useClickAsTap,\n threshold: userEvents.threshold || THRESHOLD[touchInfo.type],\n userEvents: userEvents,\n target: target,\n currentTarget: touchInfo.currentTarget,\n initialTouch: touchInfo.target,\n id: touchInfo.id,\n pressEvent: touchInfo,\n _clicks: userEvents._clicks,\n supportDoubleTap: userEvents.supportDoubleTap,\n _moved: false,\n _finished: false\n });\n },\n press: function () {\n this._holdTimeout = setTimeout($.proxy(this, '_hold'), this.userEvents.minHold);\n this._trigger(PRESS, this.pressEvent);\n },\n _tap: function (touchInfo) {\n var that = this;\n that.userEvents._clicks++;\n if (that.userEvents._clicks == 1) {\n that._clickTimeout = setTimeout(function () {\n if (that.userEvents._clicks == 1) {\n that._trigger(TAP, touchInfo);\n } else {\n that._trigger(DOUBLETAP, touchInfo);\n }\n that.userEvents._clicks = 0;\n }, CLICK_DELAY);\n }\n },\n _hold: function () {\n this._trigger(HOLD, this.pressEvent);\n },\n move: function (touchInfo) {\n var that = this;\n var preventMove = touchInfo.type !== 'api' && that.userEvents._shouldNotMove;\n if (that._finished || preventMove) {\n return;\n }\n that.x.move(touchInfo.location);\n that.y.move(touchInfo.location);\n if (!that._moved) {\n if (that._withinIgnoreThreshold()) {\n return;\n }\n if (!UserEvents.current || UserEvents.current === that.userEvents) {\n that._start(touchInfo);\n } else {\n return that.dispose();\n }\n }\n if (!that._finished) {\n that._trigger(MOVE, touchInfo);\n }\n },\n end: function (touchInfo) {\n this.endTime = now();\n if (this._finished) {\n return;\n }\n this._finished = true;\n this._trigger(RELEASE, touchInfo);\n if (this._moved) {\n this._trigger(END, touchInfo);\n } else {\n if (!this.useClickAsTap) {\n if (this.supportDoubleTap) {\n this._tap(touchInfo);\n } else {\n this._trigger(TAP, touchInfo);\n }\n }\n }\n clearTimeout(this._holdTimeout);\n this.dispose();\n },\n dispose: function () {\n var userEvents = this.userEvents, activeTouches = userEvents.touches;\n this._finished = true;\n this.pressEvent = null;\n clearTimeout(this._holdTimeout);\n activeTouches.splice($.inArray(this, activeTouches), 1);\n },\n skip: function () {\n this.dispose();\n },\n cancel: function () {\n this.dispose();\n },\n isMoved: function () {\n return this._moved;\n },\n _start: function (touchInfo) {\n clearTimeout(this._holdTimeout);\n this.startTime = now();\n this._moved = true;\n this._trigger(START, touchInfo);\n },\n _trigger: function (name, touchInfo) {\n var that = this, jQueryEvent = touchInfo.event, data = {\n touch: that,\n x: that.x,\n y: that.y,\n target: that.target,\n event: jQueryEvent\n };\n if (that.userEvents.notify(name, data)) {\n jQueryEvent.preventDefault();\n }\n },\n _withinIgnoreThreshold: function () {\n var xDelta = this.x.initialDelta, yDelta = this.y.initialDelta;\n return Math.sqrt(xDelta * xDelta + yDelta * yDelta) <= this.threshold;\n }\n });\n function withEachUpEvent(callback) {\n var downEvents = kendo.eventMap.up.split(' '), idx = 0, length = downEvents.length;\n for (; idx < length; idx++) {\n callback(downEvents[idx]);\n }\n }\n var UserEvents = Observable.extend({\n init: function (element, options) {\n var that = this, filter, ns = kendo.guid();\n options = options || {};\n filter = that.filter = options.filter;\n that.threshold = options.threshold || DEFAULT_THRESHOLD;\n that.minHold = options.minHold || DEFAULT_MIN_HOLD;\n that.touches = [];\n that._maxTouches = options.multiTouch ? 2 : 1;\n that.allowSelection = options.allowSelection;\n that.captureUpIfMoved = options.captureUpIfMoved;\n that.useClickAsTap = !options.fastTap && !support.delayedClick();\n that.eventNS = ns;\n that._clicks = 0;\n that.supportDoubleTap = options.supportDoubleTap;\n element = $(element).handler(that);\n Observable.fn.init.call(that);\n extend(that, {\n element: element,\n surface: options.global && ENABLE_GLOBAL_SURFACE ? $(element[0].ownerDocument.documentElement) : $(options.surface || element),\n stopPropagation: options.stopPropagation,\n pressed: false\n });\n that.surface.handler(that).on(kendo.applyEventMap('move', ns), '_move').on(kendo.applyEventMap('up cancel', ns), '_end');\n element.on(kendo.applyEventMap('down', ns), filter, '_start');\n if (that.useClickAsTap) {\n element.on(kendo.applyEventMap('click', ns), filter, '_click');\n }\n if (support.pointers || support.msPointers) {\n if (support.browser.version < 11) {\n var defaultAction = 'pinch-zoom double-tap-zoom';\n element.css('-ms-touch-action', options.touchAction && options.touchAction != 'none' ? defaultAction + ' ' + options.touchAction : defaultAction);\n } else {\n element.css('touch-action', options.touchAction || 'none');\n }\n }\n if (options.preventDragEvent) {\n element.on(kendo.applyEventMap('dragstart', ns), kendo.preventDefault);\n }\n element.on(kendo.applyEventMap('mousedown', ns), filter, { root: element }, '_select');\n if (that.captureUpIfMoved && support.eventCapture) {\n var surfaceElement = that.surface[0], preventIfMovingProxy = $.proxy(that.preventIfMoving, that);\n withEachUpEvent(function (eventName) {\n surfaceElement.addEventListener(eventName, preventIfMovingProxy, true);\n });\n }\n that.bind([\n PRESS,\n HOLD,\n TAP,\n DOUBLETAP,\n START,\n MOVE,\n END,\n RELEASE,\n CANCEL,\n GESTURESTART,\n GESTURECHANGE,\n GESTUREEND,\n GESTURETAP,\n SELECT\n ], options);\n },\n preventIfMoving: function (e) {\n if (this._isMoved()) {\n e.preventDefault();\n }\n },\n destroy: function () {\n var that = this;\n if (that._destroyed) {\n return;\n }\n that._destroyed = true;\n if (that.captureUpIfMoved && support.eventCapture) {\n var surfaceElement = that.surface[0];\n withEachUpEvent(function (eventName) {\n surfaceElement.removeEventListener(eventName, that.preventIfMoving);\n });\n }\n that.element.kendoDestroy(that.eventNS);\n that.surface.kendoDestroy(that.eventNS);\n that.element.removeData('handler');\n that.surface.removeData('handler');\n that._disposeAll();\n that.unbind();\n delete that.surface;\n delete that.element;\n delete that.currentTarget;\n },\n capture: function () {\n UserEvents.current = this;\n },\n cancel: function () {\n this._disposeAll();\n this.trigger(CANCEL);\n },\n notify: function (eventName, data) {\n var that = this, touches = that.touches;\n if (this._isMultiTouch()) {\n switch (eventName) {\n case MOVE:\n eventName = GESTURECHANGE;\n break;\n case END:\n eventName = GESTUREEND;\n break;\n case TAP:\n eventName = GESTURETAP;\n break;\n }\n extend(data, { touches: touches }, touchDelta(touches[0], touches[1]));\n }\n return this.trigger(eventName, extend(data, { type: eventName }));\n },\n press: function (x, y, target) {\n this._apiCall('_start', x, y, target);\n },\n move: function (x, y) {\n this._apiCall('_move', x, y);\n },\n end: function (x, y) {\n this._apiCall('_end', x, y);\n },\n _isMultiTouch: function () {\n return this.touches.length > 1;\n },\n _maxTouchesReached: function () {\n return this.touches.length >= this._maxTouches;\n },\n _disposeAll: function () {\n var touches = this.touches;\n while (touches.length > 0) {\n touches.pop().dispose();\n }\n },\n _isMoved: function () {\n return $.grep(this.touches, function (touch) {\n return touch.isMoved();\n }).length;\n },\n _select: function (e) {\n if (!this.allowSelection || this.trigger(SELECT, { event: e })) {\n e.preventDefault();\n }\n },\n _start: function (e) {\n var that = this, idx = 0, filter = that.filter, target, touches = getTouches(e), length = touches.length, touch, which = e.which;\n if (which && which > 1 || that._maxTouchesReached()) {\n return;\n }\n UserEvents.current = null;\n that.currentTarget = e.currentTarget;\n if (that.stopPropagation) {\n e.stopPropagation();\n }\n for (; idx < length; idx++) {\n if (that._maxTouchesReached()) {\n break;\n }\n touch = touches[idx];\n if (filter) {\n target = $(touch.currentTarget);\n } else {\n target = that.element;\n }\n if (!target.length) {\n continue;\n }\n touch = new Touch(that, target, touch);\n that.touches.push(touch);\n touch.press();\n if (that._isMultiTouch()) {\n that.notify('gesturestart', {});\n }\n }\n },\n _move: function (e) {\n this._eachTouch('move', e);\n },\n _end: function (e) {\n this._eachTouch('end', e);\n },\n _click: function (e) {\n var data = {\n touch: {\n initialTouch: e.target,\n target: $(e.currentTarget),\n endTime: now(),\n x: {\n location: e.pageX,\n client: e.clientX\n },\n y: {\n location: e.pageY,\n client: e.clientY\n }\n },\n x: e.pageX,\n y: e.pageY,\n target: $(e.currentTarget),\n event: e,\n type: 'tap'\n };\n if (this.trigger('tap', data)) {\n e.preventDefault();\n }\n },\n _eachTouch: function (methodName, e) {\n var that = this, dict = {}, touches = getTouches(e), activeTouches = that.touches, idx, touch, touchInfo, matchingTouch;\n for (idx = 0; idx < activeTouches.length; idx++) {\n touch = activeTouches[idx];\n dict[touch.id] = touch;\n }\n for (idx = 0; idx < touches.length; idx++) {\n touchInfo = touches[idx];\n matchingTouch = dict[touchInfo.id];\n if (matchingTouch) {\n matchingTouch[methodName](touchInfo);\n }\n }\n },\n _apiCall: function (type, x, y, target) {\n this[type]({\n api: true,\n pageX: x,\n pageY: y,\n clientX: x,\n clientY: y,\n target: $(target || this.element)[0],\n stopPropagation: $.noop,\n preventDefault: $.noop\n });\n }\n });\n UserEvents.defaultThreshold = function (value) {\n DEFAULT_THRESHOLD = value;\n };\n UserEvents.minHold = function (value) {\n DEFAULT_MIN_HOLD = value;\n };\n kendo.getTouches = getTouches;\n kendo.touchDelta = touchDelta;\n kendo.UserEvents = UserEvents;\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.draganddrop', [\n 'kendo.core',\n 'kendo.userevents'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'draganddrop',\n name: 'Drag & drop',\n category: 'framework',\n description: 'Drag & drop functionality for any DOM element.',\n depends: [\n 'core',\n 'userevents'\n ]\n };\n (function ($, undefined) {\n var kendo = window.kendo, support = kendo.support, document = window.document, $window = $(window), Class = kendo.Class, Widget = kendo.ui.Widget, Observable = kendo.Observable, UserEvents = kendo.UserEvents, proxy = $.proxy, extend = $.extend, getOffset = kendo.getOffset, draggables = {}, dropTargets = {}, dropAreas = {}, lastDropTarget, elementUnderCursor = kendo.elementUnderCursor, KEYUP = 'keyup', CHANGE = 'change', DRAGSTART = 'dragstart', HOLD = 'hold', DRAG = 'drag', DRAGEND = 'dragend', DRAGCANCEL = 'dragcancel', HINTDESTROYED = 'hintDestroyed', DRAGENTER = 'dragenter', DRAGLEAVE = 'dragleave', DROP = 'drop';\n function contains(parent, child) {\n try {\n return $.contains(parent, child) || parent == child;\n } catch (e) {\n return false;\n }\n }\n function numericCssPropery(element, property) {\n return parseInt(element.css(property), 10) || 0;\n }\n function within(value, range) {\n return Math.min(Math.max(value, range.min), range.max);\n }\n function containerBoundaries(container, element) {\n var offset = getOffset(container), outerWidth = kendo._outerWidth, outerHeight = kendo._outerHeight, minX = offset.left + numericCssPropery(container, 'borderLeftWidth') + numericCssPropery(container, 'paddingLeft'), minY = offset.top + numericCssPropery(container, 'borderTopWidth') + numericCssPropery(container, 'paddingTop'), maxX = minX + container.width() - outerWidth(element, true), maxY = minY + container.height() - outerHeight(element, true);\n return {\n x: {\n min: minX,\n max: maxX\n },\n y: {\n min: minY,\n max: maxY\n }\n };\n }\n function checkTarget(target, targets, areas) {\n var theTarget, theFilter, i = 0, targetLen = targets && targets.length, areaLen = areas && areas.length;\n while (target && target.parentNode) {\n for (i = 0; i < targetLen; i++) {\n theTarget = targets[i];\n if (theTarget.element[0] === target) {\n return {\n target: theTarget,\n targetElement: target\n };\n }\n }\n for (i = 0; i < areaLen; i++) {\n theFilter = areas[i];\n if ($.contains(theFilter.element[0], target) && support.matchesSelector.call(target, theFilter.options.filter)) {\n return {\n target: theFilter,\n targetElement: target\n };\n }\n }\n target = target.parentNode;\n }\n return undefined;\n }\n var TapCapture = Observable.extend({\n init: function (element, options) {\n var that = this, domElement = element[0];\n that.capture = false;\n if (domElement.addEventListener) {\n $.each(kendo.eventMap.down.split(' '), function () {\n domElement.addEventListener(this, proxy(that._press, that), true);\n });\n $.each(kendo.eventMap.up.split(' '), function () {\n domElement.addEventListener(this, proxy(that._release, that), true);\n });\n } else {\n $.each(kendo.eventMap.down.split(' '), function () {\n domElement.attachEvent(this, proxy(that._press, that));\n });\n $.each(kendo.eventMap.up.split(' '), function () {\n domElement.attachEvent(this, proxy(that._release, that));\n });\n }\n Observable.fn.init.call(that);\n that.bind([\n 'press',\n 'release'\n ], options || {});\n },\n captureNext: function () {\n this.capture = true;\n },\n cancelCapture: function () {\n this.capture = false;\n },\n _press: function (e) {\n var that = this;\n that.trigger('press');\n if (that.capture) {\n e.preventDefault();\n }\n },\n _release: function (e) {\n var that = this;\n that.trigger('release');\n if (that.capture) {\n e.preventDefault();\n that.cancelCapture();\n }\n }\n });\n var PaneDimension = Observable.extend({\n init: function (options) {\n var that = this;\n Observable.fn.init.call(that);\n that.forcedEnabled = false;\n $.extend(that, options);\n that.scale = 1;\n if (that.horizontal) {\n that.measure = 'offsetWidth';\n that.scrollSize = 'scrollWidth';\n that.axis = 'x';\n } else {\n that.measure = 'offsetHeight';\n that.scrollSize = 'scrollHeight';\n that.axis = 'y';\n }\n },\n makeVirtual: function () {\n $.extend(this, {\n virtual: true,\n forcedEnabled: true,\n _virtualMin: 0,\n _virtualMax: 0\n });\n },\n virtualSize: function (min, max) {\n if (this._virtualMin !== min || this._virtualMax !== max) {\n this._virtualMin = min;\n this._virtualMax = max;\n this.update();\n }\n },\n outOfBounds: function (offset) {\n return offset > this.max || offset < this.min;\n },\n forceEnabled: function () {\n this.forcedEnabled = true;\n },\n getSize: function () {\n return this.container[0][this.measure];\n },\n getTotal: function () {\n return this.element[0][this.scrollSize];\n },\n rescale: function (scale) {\n this.scale = scale;\n },\n update: function (silent) {\n var that = this, total = that.virtual ? that._virtualMax : that.getTotal(), scaledTotal = total * that.scale, size = that.getSize();\n if (total === 0 && !that.forcedEnabled) {\n return;\n }\n that.max = that.virtual ? -that._virtualMin : 0;\n that.size = size;\n that.total = scaledTotal;\n that.min = Math.min(that.max, size - scaledTotal);\n that.minScale = size / total;\n that.centerOffset = (scaledTotal - size) / 2;\n that.enabled = that.forcedEnabled || scaledTotal > size;\n if (!silent) {\n that.trigger(CHANGE, that);\n }\n }\n });\n var PaneDimensions = Observable.extend({\n init: function (options) {\n var that = this;\n Observable.fn.init.call(that);\n that.x = new PaneDimension(extend({ horizontal: true }, options));\n that.y = new PaneDimension(extend({ horizontal: false }, options));\n that.container = options.container;\n that.forcedMinScale = options.minScale;\n that.maxScale = options.maxScale || 100;\n that.bind(CHANGE, options);\n },\n rescale: function (newScale) {\n this.x.rescale(newScale);\n this.y.rescale(newScale);\n this.refresh();\n },\n centerCoordinates: function () {\n return {\n x: Math.min(0, -this.x.centerOffset),\n y: Math.min(0, -this.y.centerOffset)\n };\n },\n refresh: function () {\n var that = this;\n that.x.update();\n that.y.update();\n that.enabled = that.x.enabled || that.y.enabled;\n that.minScale = that.forcedMinScale || Math.min(that.x.minScale, that.y.minScale);\n that.fitScale = Math.max(that.x.minScale, that.y.minScale);\n that.trigger(CHANGE);\n }\n });\n var PaneAxis = Observable.extend({\n init: function (options) {\n var that = this;\n extend(that, options);\n Observable.fn.init.call(that);\n },\n outOfBounds: function () {\n return this.dimension.outOfBounds(this.movable[this.axis]);\n },\n dragMove: function (delta) {\n var that = this, dimension = that.dimension, axis = that.axis, movable = that.movable, position = movable[axis] + delta;\n if (!dimension.enabled) {\n return;\n }\n if (position < dimension.min && delta < 0 || position > dimension.max && delta > 0) {\n delta *= that.resistance;\n }\n movable.translateAxis(axis, delta);\n that.trigger(CHANGE, that);\n }\n });\n var Pane = Class.extend({\n init: function (options) {\n var that = this, x, y, resistance, movable;\n extend(that, { elastic: true }, options);\n resistance = that.elastic ? 0.5 : 0;\n movable = that.movable;\n that.x = x = new PaneAxis({\n axis: 'x',\n dimension: that.dimensions.x,\n resistance: resistance,\n movable: movable\n });\n that.y = y = new PaneAxis({\n axis: 'y',\n dimension: that.dimensions.y,\n resistance: resistance,\n movable: movable\n });\n that.userEvents.bind([\n 'press',\n 'move',\n 'end',\n 'gesturestart',\n 'gesturechange'\n ], {\n gesturestart: function (e) {\n that.gesture = e;\n that.offset = that.dimensions.container.offset();\n },\n press: function (e) {\n if ($(e.event.target).closest('a').is('[data-navigate-on-press=true]')) {\n e.sender.cancel();\n }\n },\n gesturechange: function (e) {\n var previousGesture = that.gesture, previousCenter = previousGesture.center, center = e.center, scaleDelta = e.distance / previousGesture.distance, minScale = that.dimensions.minScale, maxScale = that.dimensions.maxScale, coordinates;\n if (movable.scale <= minScale && scaleDelta < 1) {\n scaleDelta += (1 - scaleDelta) * 0.8;\n }\n if (movable.scale * scaleDelta >= maxScale) {\n scaleDelta = maxScale / movable.scale;\n }\n var offsetX = movable.x + that.offset.left, offsetY = movable.y + that.offset.top;\n coordinates = {\n x: (offsetX - previousCenter.x) * scaleDelta + center.x - offsetX,\n y: (offsetY - previousCenter.y) * scaleDelta + center.y - offsetY\n };\n movable.scaleWith(scaleDelta);\n x.dragMove(coordinates.x);\n y.dragMove(coordinates.y);\n that.dimensions.rescale(movable.scale);\n that.gesture = e;\n e.preventDefault();\n },\n move: function (e) {\n if (e.event.target.tagName.match(/textarea|input/i)) {\n return;\n }\n if (x.dimension.enabled || y.dimension.enabled) {\n x.dragMove(e.x.delta);\n y.dragMove(e.y.delta);\n e.preventDefault();\n } else {\n e.touch.skip();\n }\n },\n end: function (e) {\n e.preventDefault();\n }\n });\n }\n });\n var TRANSFORM_STYLE = support.transitions.prefix + 'Transform', translate;\n if (support.hasHW3D) {\n translate = function (x, y, scale) {\n return 'translate3d(' + x + 'px,' + y + 'px,0) scale(' + scale + ')';\n };\n } else {\n translate = function (x, y, scale) {\n return 'translate(' + x + 'px,' + y + 'px) scale(' + scale + ')';\n };\n }\n var Movable = Observable.extend({\n init: function (element) {\n var that = this;\n Observable.fn.init.call(that);\n that.element = $(element);\n that.element[0].style.webkitTransformOrigin = 'left top';\n that.x = 0;\n that.y = 0;\n that.scale = 1;\n that._saveCoordinates(translate(that.x, that.y, that.scale));\n },\n translateAxis: function (axis, by) {\n this[axis] += by;\n this.refresh();\n },\n scaleTo: function (scale) {\n this.scale = scale;\n this.refresh();\n },\n scaleWith: function (scaleDelta) {\n this.scale *= scaleDelta;\n this.refresh();\n },\n translate: function (coordinates) {\n this.x += coordinates.x;\n this.y += coordinates.y;\n this.refresh();\n },\n moveAxis: function (axis, value) {\n this[axis] = value;\n this.refresh();\n },\n moveTo: function (coordinates) {\n extend(this, coordinates);\n this.refresh();\n },\n refresh: function () {\n var that = this, x = that.x, y = that.y, newCoordinates;\n if (that.round) {\n x = Math.round(x);\n y = Math.round(y);\n }\n newCoordinates = translate(x, y, that.scale);\n if (newCoordinates != that.coordinates) {\n if (kendo.support.browser.msie && kendo.support.browser.version < 10) {\n that.element[0].style.position = 'absolute';\n that.element[0].style.left = that.x + 'px';\n that.element[0].style.top = that.y + 'px';\n } else {\n that.element[0].style[TRANSFORM_STYLE] = newCoordinates;\n }\n that._saveCoordinates(newCoordinates);\n that.trigger(CHANGE);\n }\n },\n _saveCoordinates: function (coordinates) {\n this.coordinates = coordinates;\n }\n });\n function destroyDroppable(collection, widget) {\n var groupName = widget.options.group, droppables = collection[groupName], i;\n Widget.fn.destroy.call(widget);\n if (droppables.length > 1) {\n for (i = 0; i < droppables.length; i++) {\n if (droppables[i] == widget) {\n droppables.splice(i, 1);\n break;\n }\n }\n } else {\n droppables.length = 0;\n delete collection[groupName];\n }\n }\n var DropTarget = Widget.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n var group = that.options.group;\n if (!(group in dropTargets)) {\n dropTargets[group] = [that];\n } else {\n dropTargets[group].push(that);\n }\n },\n events: [\n DRAGENTER,\n DRAGLEAVE,\n DROP\n ],\n options: {\n name: 'DropTarget',\n group: 'default'\n },\n destroy: function () {\n destroyDroppable(dropTargets, this);\n },\n _trigger: function (eventName, e) {\n var that = this, draggable = draggables[that.options.group];\n if (draggable) {\n return that.trigger(eventName, extend({}, e.event, {\n draggable: draggable,\n dropTarget: e.dropTarget\n }));\n }\n },\n _over: function (e) {\n this._trigger(DRAGENTER, e);\n },\n _out: function (e) {\n this._trigger(DRAGLEAVE, e);\n },\n _drop: function (e) {\n var that = this, draggable = draggables[that.options.group];\n if (draggable) {\n draggable.dropped = !that._trigger(DROP, e);\n }\n }\n });\n DropTarget.destroyGroup = function (groupName) {\n var group = dropTargets[groupName] || dropAreas[groupName], i;\n if (group) {\n for (i = 0; i < group.length; i++) {\n Widget.fn.destroy.call(group[i]);\n }\n group.length = 0;\n delete dropTargets[groupName];\n delete dropAreas[groupName];\n }\n };\n DropTarget._cache = dropTargets;\n var DropTargetArea = DropTarget.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n var group = that.options.group;\n if (!(group in dropAreas)) {\n dropAreas[group] = [that];\n } else {\n dropAreas[group].push(that);\n }\n },\n destroy: function () {\n destroyDroppable(dropAreas, this);\n },\n options: {\n name: 'DropTargetArea',\n group: 'default',\n filter: null\n }\n });\n var Draggable = Widget.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n that._activated = false;\n that.userEvents = new UserEvents(that.element, {\n global: true,\n allowSelection: true,\n filter: that.options.filter,\n threshold: that.options.distance,\n start: proxy(that._start, that),\n hold: proxy(that._hold, that),\n move: proxy(that._drag, that),\n end: proxy(that._end, that),\n cancel: proxy(that._cancel, that),\n select: proxy(that._select, that)\n });\n if (kendo.support.touch) {\n that.element.find(that.options.filter).css('touch-action', 'none');\n }\n that._afterEndHandler = proxy(that._afterEnd, that);\n that._captureEscape = proxy(that._captureEscape, that);\n },\n events: [\n HOLD,\n DRAGSTART,\n DRAG,\n DRAGEND,\n DRAGCANCEL,\n HINTDESTROYED\n ],\n options: {\n name: 'Draggable',\n distance: kendo.support.touch ? 0 : 5,\n group: 'default',\n cursorOffset: null,\n axis: null,\n container: null,\n filter: null,\n ignore: null,\n holdToDrag: false,\n autoScroll: false,\n dropped: false\n },\n cancelHold: function () {\n this._activated = false;\n },\n _captureEscape: function (e) {\n var that = this;\n if (e.keyCode === kendo.keys.ESC) {\n that._trigger(DRAGCANCEL, { event: e });\n that.userEvents.cancel();\n }\n },\n _updateHint: function (e) {\n var that = this, coordinates, options = that.options, boundaries = that.boundaries, axis = options.axis, cursorOffset = that.options.cursorOffset;\n if (cursorOffset) {\n coordinates = {\n left: e.x.location + cursorOffset.left,\n top: e.y.location + cursorOffset.top\n };\n } else {\n that.hintOffset.left += e.x.delta;\n that.hintOffset.top += e.y.delta;\n coordinates = $.extend({}, that.hintOffset);\n }\n if (boundaries) {\n coordinates.top = within(coordinates.top, boundaries.y);\n coordinates.left = within(coordinates.left, boundaries.x);\n }\n if (axis === 'x') {\n delete coordinates.top;\n } else if (axis === 'y') {\n delete coordinates.left;\n }\n that.hint.css(coordinates);\n },\n _shouldIgnoreTarget: function (target) {\n var ignoreSelector = this.options.ignore;\n return ignoreSelector && $(target).is(ignoreSelector);\n },\n _select: function (e) {\n if (!this._shouldIgnoreTarget(e.event.target)) {\n e.preventDefault();\n }\n },\n _start: function (e) {\n var that = this, options = that.options, container = options.container ? $(options.container) : null, hint = options.hint;\n if (this._shouldIgnoreTarget(e.touch.initialTouch) || options.holdToDrag && !that._activated) {\n that.userEvents.cancel();\n return;\n }\n that.currentTarget = e.target;\n that.currentTargetOffset = getOffset(that.currentTarget);\n if (hint) {\n if (that.hint) {\n that.hint.stop(true, true).remove();\n }\n that.hint = kendo.isFunction(hint) ? $(hint.call(that, that.currentTarget)) : hint;\n var offset = getOffset(that.currentTarget);\n that.hintOffset = offset;\n that.hint.css({\n position: 'absolute',\n zIndex: 20000,\n left: offset.left,\n top: offset.top\n }).appendTo(document.body);\n that.angular('compile', function () {\n that.hint.removeAttr('ng-repeat');\n var scopeTarget = $(e.target);\n while (!scopeTarget.data('$$kendoScope') && scopeTarget.length) {\n scopeTarget = scopeTarget.parent();\n }\n return {\n elements: that.hint.get(),\n scopeFrom: scopeTarget.data('$$kendoScope')\n };\n });\n }\n draggables[options.group] = that;\n that.dropped = false;\n if (container) {\n that.boundaries = containerBoundaries(container, that.hint);\n }\n $(document).on(KEYUP, that._captureEscape);\n if (that._trigger(DRAGSTART, e)) {\n that.userEvents.cancel();\n that._afterEnd();\n }\n that.userEvents.capture();\n },\n _hold: function (e) {\n this.currentTarget = e.target;\n if (this._trigger(HOLD, e)) {\n this.userEvents.cancel();\n } else {\n this._activated = true;\n }\n },\n _drag: function (e) {\n e.preventDefault();\n var cursorElement = this._elementUnderCursor(e);\n if (this.options.autoScroll && this._cursorElement !== cursorElement) {\n this._scrollableParent = findScrollableParent(cursorElement);\n this._cursorElement = cursorElement;\n }\n this._lastEvent = e;\n this._processMovement(e, cursorElement);\n if (this.options.autoScroll) {\n if (this._scrollableParent[0]) {\n var velocity = autoScrollVelocity(e.x.location, e.y.location, scrollableViewPort(this._scrollableParent));\n this._scrollCompenstation = $.extend({}, this.hintOffset);\n this._scrollVelocity = velocity;\n if (velocity.y === 0 && velocity.x === 0) {\n clearInterval(this._scrollInterval);\n this._scrollInterval = null;\n } else if (!this._scrollInterval) {\n this._scrollInterval = setInterval($.proxy(this, '_autoScroll'), 50);\n }\n }\n }\n if (this.hint) {\n this._updateHint(e);\n }\n },\n _processMovement: function (e, cursorElement) {\n this._withDropTarget(cursorElement, function (target, targetElement) {\n if (!target) {\n if (lastDropTarget) {\n lastDropTarget._trigger(DRAGLEAVE, extend(e, { dropTarget: $(lastDropTarget.targetElement) }));\n lastDropTarget = null;\n }\n return;\n }\n if (lastDropTarget) {\n if (targetElement === lastDropTarget.targetElement) {\n return;\n }\n lastDropTarget._trigger(DRAGLEAVE, extend(e, { dropTarget: $(lastDropTarget.targetElement) }));\n }\n target._trigger(DRAGENTER, extend(e, { dropTarget: $(targetElement) }));\n lastDropTarget = extend(target, { targetElement: targetElement });\n });\n this._trigger(DRAG, extend(e, {\n dropTarget: lastDropTarget,\n elementUnderCursor: cursorElement\n }));\n },\n _autoScroll: function () {\n var parent = this._scrollableParent[0], velocity = this._scrollVelocity, compensation = this._scrollCompenstation;\n if (!parent) {\n return;\n }\n var cursorElement = this._elementUnderCursor(this._lastEvent);\n this._processMovement(this._lastEvent, cursorElement);\n var yIsScrollable, xIsScrollable;\n var isRootNode = parent === scrollableRoot()[0];\n if (isRootNode) {\n yIsScrollable = document.body.scrollHeight > $window.height();\n xIsScrollable = document.body.scrollWidth > $window.width();\n } else {\n yIsScrollable = parent.offsetHeight <= parent.scrollHeight;\n xIsScrollable = parent.offsetWidth <= parent.scrollWidth;\n }\n var yDelta = parent.scrollTop + velocity.y;\n var yInBounds = yIsScrollable && yDelta > 0 && yDelta < parent.scrollHeight;\n var xDelta = parent.scrollLeft + velocity.x;\n var xInBounds = xIsScrollable && xDelta > 0 && xDelta < parent.scrollWidth;\n if (yInBounds) {\n parent.scrollTop += velocity.y;\n }\n if (xInBounds) {\n parent.scrollLeft += velocity.x;\n }\n if (this.hint && isRootNode && (xInBounds || yInBounds)) {\n if (yInBounds) {\n compensation.top += velocity.y;\n }\n if (xInBounds) {\n compensation.left += velocity.x;\n }\n this.hint.css(compensation);\n }\n },\n _end: function (e) {\n this._withDropTarget(this._elementUnderCursor(e), function (target, targetElement) {\n if (target) {\n target._drop(extend({}, e, { dropTarget: $(targetElement) }));\n lastDropTarget = null;\n }\n });\n this._cancel(this._trigger(DRAGEND, e));\n },\n _cancel: function (isDefaultPrevented) {\n var that = this;\n that._scrollableParent = null;\n this._cursorElement = null;\n clearInterval(this._scrollInterval);\n that._activated = false;\n if (that.hint && !that.dropped) {\n setTimeout(function () {\n that.hint.stop(true, true);\n if (isDefaultPrevented) {\n that._afterEndHandler();\n } else {\n that.hint.animate(that.currentTargetOffset, 'fast', that._afterEndHandler);\n }\n }, 0);\n } else {\n that._afterEnd();\n }\n },\n _trigger: function (eventName, e) {\n var that = this;\n return that.trigger(eventName, extend({}, e.event, {\n x: e.x,\n y: e.y,\n currentTarget: that.currentTarget,\n initialTarget: e.touch ? e.touch.initialTouch : null,\n dropTarget: e.dropTarget,\n elementUnderCursor: e.elementUnderCursor\n }));\n },\n _elementUnderCursor: function (e) {\n var target = elementUnderCursor(e), hint = this.hint;\n if (hint && contains(hint[0], target)) {\n hint.hide();\n target = elementUnderCursor(e);\n if (!target) {\n target = elementUnderCursor(e);\n }\n hint.show();\n }\n return target;\n },\n _withDropTarget: function (element, callback) {\n var result, group = this.options.group, targets = dropTargets[group], areas = dropAreas[group];\n if (targets && targets.length || areas && areas.length) {\n result = checkTarget(element, targets, areas);\n if (result) {\n callback(result.target, result.targetElement);\n } else {\n callback();\n }\n }\n },\n destroy: function () {\n var that = this;\n Widget.fn.destroy.call(that);\n that._afterEnd();\n that.userEvents.destroy();\n this._scrollableParent = null;\n this._cursorElement = null;\n clearInterval(this._scrollInterval);\n that.currentTarget = null;\n },\n _afterEnd: function () {\n var that = this;\n if (that.hint) {\n that.hint.remove();\n }\n delete draggables[that.options.group];\n that.trigger('destroy');\n that.trigger(HINTDESTROYED);\n $(document).off(KEYUP, that._captureEscape);\n }\n });\n kendo.ui.plugin(DropTarget);\n kendo.ui.plugin(DropTargetArea);\n kendo.ui.plugin(Draggable);\n kendo.TapCapture = TapCapture;\n kendo.containerBoundaries = containerBoundaries;\n extend(kendo.ui, {\n Pane: Pane,\n PaneDimensions: PaneDimensions,\n Movable: Movable\n });\n function scrollableViewPort(element) {\n var root = scrollableRoot()[0], offset, top, left;\n if (element[0] === root) {\n top = root.scrollTop;\n left = root.scrollLeft;\n return {\n top: top,\n left: left,\n bottom: top + $window.height(),\n right: left + $window.width()\n };\n } else {\n offset = element.offset();\n offset.bottom = offset.top + element.height();\n offset.right = offset.left + element.width();\n return offset;\n }\n }\n function scrollableRoot() {\n return $(kendo.support.browser.edge || kendo.support.browser.safari ? document.body : document.documentElement);\n }\n function findScrollableParent(element) {\n var root = scrollableRoot();\n if (!element || element === document.body || element === document.documentElement) {\n return root;\n }\n var parent = $(element)[0];\n while (parent && !kendo.isScrollable(parent) && parent !== document.body) {\n parent = parent.parentNode;\n }\n if (parent === document.body) {\n return root;\n }\n return $(parent);\n }\n function autoScrollVelocity(mouseX, mouseY, rect) {\n var velocity = {\n x: 0,\n y: 0\n };\n var AUTO_SCROLL_AREA = 50;\n if (mouseX - rect.left < AUTO_SCROLL_AREA) {\n velocity.x = -(AUTO_SCROLL_AREA - (mouseX - rect.left));\n } else if (rect.right - mouseX < AUTO_SCROLL_AREA) {\n velocity.x = AUTO_SCROLL_AREA - (rect.right - mouseX);\n }\n if (mouseY - rect.top < AUTO_SCROLL_AREA) {\n velocity.y = -(AUTO_SCROLL_AREA - (mouseY - rect.top));\n } else if (rect.bottom - mouseY < AUTO_SCROLL_AREA) {\n velocity.y = AUTO_SCROLL_AREA - (rect.bottom - mouseY);\n }\n return velocity;\n }\n kendo.ui.Draggable.utils = {\n autoScrollVelocity: autoScrollVelocity,\n scrollableViewPort: scrollableViewPort,\n findScrollableParent: findScrollableParent\n };\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.popup', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'popup',\n name: 'Pop-up',\n category: 'framework',\n depends: ['core'],\n advanced: true\n };\n (function ($, undefined) {\n var kendo = window.kendo, ui = kendo.ui, Widget = ui.Widget, Class = kendo.Class, support = kendo.support, getOffset = kendo.getOffset, outerWidth = kendo._outerWidth, outerHeight = kendo._outerHeight, OPEN = 'open', CLOSE = 'close', DEACTIVATE = 'deactivate', ACTIVATE = 'activate', CENTER = 'center', LEFT = 'left', RIGHT = 'right', TOP = 'top', BOTTOM = 'bottom', ABSOLUTE = 'absolute', HIDDEN = 'hidden', BODY = 'body', LOCATION = 'location', POSITION = 'position', VISIBLE = 'visible', EFFECTS = 'effects', ACTIVE = 'k-state-active', ACTIVEBORDER = 'k-state-border', ACTIVEBORDERREGEXP = /k-state-border-(\\w+)/, ACTIVECHILDREN = '.k-picker-wrap, .k-dropdown-wrap, .k-link', MOUSEDOWN = 'down', DOCUMENT_ELEMENT = $(document.documentElement), proxy = $.proxy, WINDOW = $(window), SCROLL = 'scroll', cssPrefix = support.transitions.css, TRANSFORM = cssPrefix + 'transform', extend = $.extend, NS = '.kendoPopup', styles = [\n 'font-size',\n 'font-family',\n 'font-stretch',\n 'font-style',\n 'font-weight',\n 'line-height'\n ];\n function contains(container, target) {\n if (!container || !target) {\n return false;\n }\n return container === target || $.contains(container, target);\n }\n var Popup = Widget.extend({\n init: function (element, options) {\n var that = this, parentPopup;\n options = options || {};\n if (options.isRtl) {\n options.origin = options.origin || BOTTOM + ' ' + RIGHT;\n options.position = options.position || TOP + ' ' + RIGHT;\n }\n Widget.fn.init.call(that, element, options);\n element = that.element;\n options = that.options;\n that.collisions = options.collision ? options.collision.split(' ') : [];\n that.downEvent = kendo.applyEventMap(MOUSEDOWN, kendo.guid());\n if (that.collisions.length === 1) {\n that.collisions.push(that.collisions[0]);\n }\n parentPopup = $(that.options.anchor).closest('.k-popup,.k-group').filter(':not([class^=km-])');\n options.appendTo = $($(options.appendTo)[0] || parentPopup[0] || document.body);\n that.element.hide().addClass('k-popup k-group k-reset').toggleClass('k-rtl', !!options.isRtl).css({ position: ABSOLUTE }).appendTo(options.appendTo).attr('aria-hidden', true).on('mouseenter' + NS, function () {\n that._hovered = true;\n }).on('wheel' + NS, function (e) {\n var list = $(e.target).find('.k-list');\n var scrollArea = list.parent();\n if (list.length && list.is(':visible') && (scrollArea.scrollTop() === 0 && e.originalEvent.deltaY < 0 || scrollArea.scrollTop() === scrollArea.prop('scrollHeight') - scrollArea.prop('offsetHeight') && e.originalEvent.deltaY > 0)) {\n e.preventDefault();\n }\n }).on('mouseleave' + NS, function () {\n that._hovered = false;\n });\n that.wrapper = $();\n if (options.animation === false) {\n options.animation = {\n open: { effects: {} },\n close: {\n hide: true,\n effects: {}\n }\n };\n }\n extend(options.animation.open, {\n complete: function () {\n that.wrapper.css({ overflow: VISIBLE });\n that._activated = true;\n that._trigger(ACTIVATE);\n }\n });\n extend(options.animation.close, {\n complete: function () {\n that._animationClose();\n }\n });\n that._mousedownProxy = function (e) {\n that._mousedown(e);\n };\n if (support.mobileOS.android) {\n that._resizeProxy = function (e) {\n setTimeout(function () {\n that._resize(e);\n }, 600);\n };\n } else {\n that._resizeProxy = function (e) {\n that._resize(e);\n };\n }\n if (options.toggleTarget) {\n $(options.toggleTarget).on(options.toggleEvent + NS, $.proxy(that.toggle, that));\n }\n },\n events: [\n OPEN,\n ACTIVATE,\n CLOSE,\n DEACTIVATE\n ],\n options: {\n name: 'Popup',\n toggleEvent: 'click',\n origin: BOTTOM + ' ' + LEFT,\n position: TOP + ' ' + LEFT,\n anchor: BODY,\n appendTo: null,\n collision: 'flip fit',\n viewport: window,\n copyAnchorStyles: true,\n autosize: false,\n modal: false,\n adjustSize: {\n width: 0,\n height: 0\n },\n animation: {\n open: {\n effects: 'slideIn:down',\n transition: true,\n duration: 200\n },\n close: {\n duration: 100,\n hide: true\n }\n }\n },\n _animationClose: function () {\n var that = this;\n var location = that.wrapper.data(LOCATION);\n that.wrapper.hide();\n if (location) {\n that.wrapper.css(location);\n }\n if (that.options.anchor != BODY) {\n that._hideDirClass();\n }\n that._closing = false;\n that._trigger(DEACTIVATE);\n },\n destroy: function () {\n var that = this, options = that.options, element = that.element.off(NS), parent;\n Widget.fn.destroy.call(that);\n if (options.toggleTarget) {\n $(options.toggleTarget).off(NS);\n }\n if (!options.modal) {\n DOCUMENT_ELEMENT.off(that.downEvent, that._mousedownProxy);\n that._toggleResize(false);\n }\n kendo.destroy(that.element.children());\n element.removeData();\n if (options.appendTo[0] === document.body) {\n parent = element.parent('.k-animation-container');\n if (parent[0]) {\n parent.remove();\n } else {\n element.remove();\n }\n }\n },\n open: function (x, y) {\n var that = this, fixed = {\n isFixed: !isNaN(parseInt(y, 10)),\n x: x,\n y: y\n }, element = that.element, options = that.options, animation, wrapper, anchor = $(options.anchor), mobile = element[0] && element.hasClass('km-widget');\n if (!that.visible()) {\n if (options.copyAnchorStyles) {\n if (mobile && styles[0] == 'font-size') {\n styles.shift();\n }\n element.css(kendo.getComputedStyles(anchor[0], styles));\n }\n if (element.data('animating') || that._trigger(OPEN)) {\n return;\n }\n that._activated = false;\n if (!options.modal) {\n DOCUMENT_ELEMENT.off(that.downEvent, that._mousedownProxy).on(that.downEvent, that._mousedownProxy);\n that._toggleResize(false);\n that._toggleResize(true);\n }\n that.wrapper = wrapper = kendo.wrap(element, options.autosize).css({\n overflow: HIDDEN,\n display: 'block',\n position: ABSOLUTE\n }).attr('aria-hidden', false);\n if (support.mobileOS.android) {\n wrapper.css(TRANSFORM, 'translatez(0)');\n }\n wrapper.css(POSITION);\n if ($(options.appendTo)[0] == document.body) {\n wrapper.css(TOP, '-10000px');\n }\n that.flipped = that._position(fixed);\n animation = that._openAnimation();\n if (options.anchor != BODY) {\n that._showDirClass(animation);\n }\n if (!element.is(':visible') && element.data('olddisplay') === undefined) {\n element.show();\n element.data('olddisplay', element.css('display'));\n element.hide();\n }\n element.data(EFFECTS, animation.effects).kendoStop(true).kendoAnimate(animation).attr('aria-hidden', false);\n }\n },\n _location: function (isFixed) {\n var that = this, element = that.element, options = that.options, wrapper, anchor = $(options.anchor), mobile = element[0] && element.hasClass('km-widget');\n if (options.copyAnchorStyles) {\n if (mobile && styles[0] == 'font-size') {\n styles.shift();\n }\n element.css(kendo.getComputedStyles(anchor[0], styles));\n }\n that.wrapper = wrapper = kendo.wrap(element, options.autosize).css({\n overflow: HIDDEN,\n display: 'block',\n position: ABSOLUTE\n });\n if (support.mobileOS.android) {\n wrapper.css(TRANSFORM, 'translatez(0)');\n }\n wrapper.css(POSITION);\n if ($(options.appendTo)[0] == document.body) {\n wrapper.css(TOP, '-10000px');\n }\n that._position(isFixed || {});\n var offset = wrapper.offset();\n return {\n width: kendo._outerWidth(wrapper),\n height: kendo._outerHeight(wrapper),\n left: offset.left,\n top: offset.top\n };\n },\n _openAnimation: function () {\n var animation = extend(true, {}, this.options.animation.open);\n animation.effects = kendo.parseEffects(animation.effects, this.flipped);\n return animation;\n },\n _hideDirClass: function () {\n var anchor = $(this.options.anchor);\n var direction = ((anchor.attr('class') || '').match(ACTIVEBORDERREGEXP) || [\n '',\n 'down'\n ])[1];\n var dirClass = ACTIVEBORDER + '-' + direction;\n anchor.removeClass(dirClass).children(ACTIVECHILDREN).removeClass(ACTIVE).removeClass(dirClass);\n this.element.removeClass(ACTIVEBORDER + '-' + kendo.directions[direction].reverse);\n },\n _showDirClass: function (animation) {\n var direction = animation.effects.slideIn ? animation.effects.slideIn.direction : 'down';\n var dirClass = ACTIVEBORDER + '-' + direction;\n $(this.options.anchor).addClass(dirClass).children(ACTIVECHILDREN).addClass(ACTIVE).addClass(dirClass);\n this.element.addClass(ACTIVEBORDER + '-' + kendo.directions[direction].reverse);\n },\n position: function () {\n if (this.visible()) {\n this.flipped = this._position();\n }\n },\n toggle: function () {\n var that = this;\n that[that.visible() ? CLOSE : OPEN]();\n },\n visible: function () {\n return this.element.is(':' + VISIBLE);\n },\n close: function (skipEffects) {\n var that = this, options = that.options, wrap, animation, openEffects, closeEffects;\n if (that.visible()) {\n wrap = that.wrapper[0] ? that.wrapper : kendo.wrap(that.element).hide();\n that._toggleResize(false);\n if (that._closing || that._trigger(CLOSE)) {\n that._toggleResize(true);\n return;\n }\n that.element.find('.k-popup').each(function () {\n var that = $(this), popup = that.data('kendoPopup');\n if (popup) {\n popup.close(skipEffects);\n }\n });\n DOCUMENT_ELEMENT.off(that.downEvent, that._mousedownProxy);\n if (skipEffects) {\n animation = {\n hide: true,\n effects: {}\n };\n } else {\n animation = extend(true, {}, options.animation.close);\n openEffects = that.element.data(EFFECTS);\n closeEffects = animation.effects;\n if (!closeEffects && !kendo.size(closeEffects) && openEffects && kendo.size(openEffects)) {\n animation.effects = openEffects;\n animation.reverse = true;\n }\n that._closing = true;\n }\n that.element.kendoStop(true).attr('aria-hidden', true);\n wrap.css({ overflow: HIDDEN }).attr('aria-hidden', true);\n that.element.kendoAnimate(animation);\n if (skipEffects) {\n that._animationClose();\n }\n }\n },\n _trigger: function (ev) {\n return this.trigger(ev, { type: ev });\n },\n _resize: function (e) {\n var that = this;\n if (support.resize.indexOf(e.type) !== -1) {\n clearTimeout(that._resizeTimeout);\n that._resizeTimeout = setTimeout(function () {\n that._position();\n that._resizeTimeout = null;\n }, 50);\n } else {\n if (!that._hovered || that._activated && that.element.hasClass('k-list-container')) {\n that.close();\n }\n }\n },\n _toggleResize: function (toggle) {\n var method = toggle ? 'on' : 'off';\n var eventNames = support.resize;\n if (!(support.mobileOS.ios || support.mobileOS.android || support.browser.safari)) {\n eventNames += ' ' + SCROLL;\n }\n if (toggle && !this.scrollableParents) {\n this.scrollableParents = this._scrollableParents();\n }\n if (this.scrollableParents && this.scrollableParents.length) {\n this.scrollableParents[method](SCROLL, this._resizeProxy);\n }\n WINDOW[method](eventNames, this._resizeProxy);\n },\n _mousedown: function (e) {\n var that = this, container = that.element[0], options = that.options, anchor = $(options.anchor)[0], toggleTarget = options.toggleTarget, target = kendo.eventTarget(e), popup = $(target).closest('.k-popup'), mobile = popup.parent().parent('.km-shim').length;\n popup = popup[0];\n if (!mobile && popup && popup !== that.element[0]) {\n return;\n }\n if ($(e.target).closest('a').data('rel') === 'popover') {\n return;\n }\n if (!contains(container, target) && !contains(anchor, target) && !(toggleTarget && contains($(toggleTarget)[0], target))) {\n that.close();\n }\n },\n _fit: function (position, size, viewPortSize) {\n var output = 0;\n if (position + size > viewPortSize) {\n output = viewPortSize - (position + size);\n }\n if (position < 0) {\n output = -position;\n }\n return output;\n },\n _flip: function (offset, size, anchorSize, viewPortSize, origin, position, boxSize) {\n var output = 0;\n boxSize = boxSize || size;\n if (position !== origin && position !== CENTER && origin !== CENTER) {\n if (offset + boxSize > viewPortSize) {\n output += -(anchorSize + size);\n }\n if (offset + output < 0) {\n output += anchorSize + size;\n }\n }\n return output;\n },\n _scrollableParents: function () {\n return $(this.options.anchor).parentsUntil('body').filter(function (index, element) {\n return kendo.isScrollable(element);\n });\n },\n _position: function (fixed) {\n var that = this, element = that.element, wrapper = that.wrapper, options = that.options, viewport = $(options.viewport), zoomLevel = support.zoomLevel(), isWindow = !!(viewport[0] == window && window.innerWidth && zoomLevel <= 1.02), anchor = $(options.anchor), origins = options.origin.toLowerCase().split(' '), positions = options.position.toLowerCase().split(' '), collisions = that.collisions, siblingContainer, parents, parentZIndex, zIndex = 10002, idx = 0, docEl = document.documentElement, length, viewportOffset, viewportWidth, viewportHeight;\n if (options.viewport === window) {\n viewportOffset = {\n top: window.pageYOffset || document.documentElement.scrollTop || 0,\n left: window.pageXOffset || document.documentElement.scrollLeft || 0\n };\n } else {\n viewportOffset = viewport.offset();\n }\n if (isWindow) {\n viewportWidth = window.innerWidth;\n viewportHeight = window.innerHeight;\n } else {\n viewportWidth = viewport.width();\n viewportHeight = viewport.height();\n }\n if (isWindow && docEl.scrollHeight - docEl.clientHeight > 0) {\n var sign = options.isRtl ? -1 : 1;\n viewportWidth -= sign * kendo.support.scrollbar();\n }\n siblingContainer = anchor.parents().filter(wrapper.siblings());\n if (siblingContainer[0]) {\n parentZIndex = Math.max(Number(siblingContainer.css('zIndex')), 0);\n if (parentZIndex) {\n zIndex = parentZIndex + 10;\n } else {\n parents = anchor.parentsUntil(siblingContainer);\n for (length = parents.length; idx < length; idx++) {\n parentZIndex = Number($(parents[idx]).css('zIndex'));\n if (parentZIndex && zIndex < parentZIndex) {\n zIndex = parentZIndex + 10;\n }\n }\n }\n }\n wrapper.css('zIndex', zIndex);\n if (fixed && fixed.isFixed) {\n wrapper.css({\n left: fixed.x,\n top: fixed.y\n });\n } else {\n wrapper.css(that._align(origins, positions));\n }\n var pos = getOffset(wrapper, POSITION, anchor[0] === wrapper.offsetParent()[0]), offset = getOffset(wrapper), anchorParent = anchor.offsetParent().parent('.k-animation-container,.k-popup,.k-group');\n if (anchorParent.length) {\n pos = getOffset(wrapper, POSITION, true);\n offset = getOffset(wrapper);\n }\n offset.top -= viewportOffset.top;\n offset.left -= viewportOffset.left;\n if (!that.wrapper.data(LOCATION)) {\n wrapper.data(LOCATION, extend({}, pos));\n }\n var offsets = extend({}, offset), location = extend({}, pos), adjustSize = options.adjustSize;\n if (collisions[0] === 'fit') {\n location.top += that._fit(offsets.top, outerHeight(wrapper) + adjustSize.height, viewportHeight / zoomLevel);\n }\n if (collisions[1] === 'fit') {\n location.left += that._fit(offsets.left, outerWidth(wrapper) + adjustSize.width, viewportWidth / zoomLevel);\n }\n var flipPos = extend({}, location);\n var elementHeight = outerHeight(element);\n var wrapperHeight = outerHeight(wrapper);\n if (!wrapper.height() && elementHeight) {\n wrapperHeight = wrapperHeight + elementHeight;\n }\n if (collisions[0] === 'flip') {\n location.top += that._flip(offsets.top, elementHeight, outerHeight(anchor), viewportHeight / zoomLevel, origins[0], positions[0], wrapperHeight);\n }\n if (collisions[1] === 'flip') {\n location.left += that._flip(offsets.left, outerWidth(element), outerWidth(anchor), viewportWidth / zoomLevel, origins[1], positions[1], outerWidth(wrapper));\n }\n element.css(POSITION, ABSOLUTE);\n wrapper.css(location);\n return location.left != flipPos.left || location.top != flipPos.top;\n },\n _align: function (origin, position) {\n var that = this, element = that.wrapper, anchor = $(that.options.anchor), verticalOrigin = origin[0], horizontalOrigin = origin[1], verticalPosition = position[0], horizontalPosition = position[1], anchorOffset = getOffset(anchor), appendTo = $(that.options.appendTo), appendToOffset, width = outerWidth(element), height = outerHeight(element) || outerHeight(element.children().first()), anchorWidth = outerWidth(anchor), anchorHeight = outerHeight(anchor), top = anchorOffset.top, left = anchorOffset.left, round = Math.round;\n if (appendTo[0] != document.body) {\n appendToOffset = getOffset(appendTo);\n top -= appendToOffset.top;\n left -= appendToOffset.left;\n }\n if (verticalOrigin === BOTTOM) {\n top += anchorHeight;\n }\n if (verticalOrigin === CENTER) {\n top += round(anchorHeight / 2);\n }\n if (verticalPosition === BOTTOM) {\n top -= height;\n }\n if (verticalPosition === CENTER) {\n top -= round(height / 2);\n }\n if (horizontalOrigin === RIGHT) {\n left += anchorWidth;\n }\n if (horizontalOrigin === CENTER) {\n left += round(anchorWidth / 2);\n }\n if (horizontalPosition === RIGHT) {\n left -= width;\n }\n if (horizontalPosition === CENTER) {\n left -= round(width / 2);\n }\n return {\n top: top,\n left: left\n };\n }\n });\n ui.plugin(Popup);\n var stableSort = kendo.support.stableSort;\n var tabKeyTrapNS = 'kendoTabKeyTrap';\n var focusableNodesSelector = 'a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), iframe, object, embed, [tabindex], *[contenteditable]';\n var TabKeyTrap = Class.extend({\n init: function (element) {\n this.element = $(element);\n this.element.autoApplyNS(tabKeyTrapNS);\n },\n trap: function () {\n this.element.on('keydown', proxy(this._keepInTrap, this));\n },\n removeTrap: function () {\n this.element.kendoDestroy(tabKeyTrapNS);\n },\n destroy: function () {\n this.element.kendoDestroy(tabKeyTrapNS);\n this.element = undefined;\n },\n shouldTrap: function () {\n return true;\n },\n _keepInTrap: function (e) {\n if (e.which !== 9 || !this.shouldTrap() || e.isDefaultPrevented()) {\n return;\n }\n var elements = this._focusableElements();\n var sortedElements = this._sortFocusableElements(elements);\n var next = this._nextFocusable(e, sortedElements);\n this._focus(next);\n e.preventDefault();\n },\n _focusableElements: function () {\n var elements = this.element.find(focusableNodesSelector).filter(function (i, item) {\n return item.tabIndex >= 0 && $(item).is(':visible') && !$(item).is('[disabled]');\n });\n if (this.element.is('[tabindex]')) {\n elements.push(this.element[0]);\n }\n return elements;\n },\n _sortFocusableElements: function (elements) {\n var sortedElements;\n if (stableSort) {\n sortedElements = elements.sort(function (prev, next) {\n return prev.tabIndex - next.tabIndex;\n });\n } else {\n var attrName = '__k_index';\n elements.each(function (i, item) {\n item.setAttribute(attrName, i);\n });\n sortedElements = elements.sort(function (prev, next) {\n return prev.tabIndex === next.tabIndex ? parseInt(prev.getAttribute(attrName), 10) - parseInt(next.getAttribute(attrName), 10) : prev.tabIndex - next.tabIndex;\n });\n elements.removeAttr(attrName);\n }\n return sortedElements;\n },\n _nextFocusable: function (e, elements) {\n var count = elements.length;\n var current = elements.index(e.target);\n return elements.get((current + (e.shiftKey ? -1 : 1)) % count);\n },\n _focus: function (element) {\n if (element.nodeName == 'IFRAME') {\n element.contentWindow.document.body.focus();\n return;\n }\n element.focus();\n if (element.nodeName == 'INPUT' && element.setSelectionRange && this._haveSelectionRange(element)) {\n element.setSelectionRange(0, element.value.length);\n }\n },\n _haveSelectionRange: function (element) {\n var elementType = element.type.toLowerCase();\n return elementType === 'text' || elementType === 'search' || elementType === 'url' || elementType === 'tel' || elementType === 'password';\n }\n });\n ui.Popup.TabKeyTrap = TabKeyTrap;\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.touch', [\n 'kendo.core',\n 'kendo.userevents'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'touch',\n name: 'Touch',\n category: 'mobile',\n description: 'The kendo Touch widget provides a cross-platform compatible API for handling user-initiated touch events, multi-touch gestures and event sequences (drag, swipe, etc.). ',\n depends: [\n 'core',\n 'userevents'\n ]\n };\n (function ($, undefined) {\n var kendo = window.kendo, Widget = kendo.ui.Widget, proxy = $.proxy, abs = Math.abs, MAX_DOUBLE_TAP_DISTANCE = 20;\n var Touch = Widget.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n options = that.options;\n element = that.element;\n that.wrapper = element;\n function eventProxy(name) {\n return function (e) {\n that._triggerTouch(name, e);\n };\n }\n function gestureEventProxy(name) {\n return function (e) {\n that.trigger(name, {\n touches: e.touches,\n distance: e.distance,\n center: e.center,\n event: e.event\n });\n };\n }\n that.events = new kendo.UserEvents(element, {\n filter: options.filter,\n surface: options.surface,\n minHold: options.minHold,\n multiTouch: options.multiTouch,\n allowSelection: true,\n fastTap: options.fastTap,\n press: eventProxy('touchstart'),\n hold: eventProxy('hold'),\n tap: proxy(that, '_tap'),\n gesturestart: gestureEventProxy('gesturestart'),\n gesturechange: gestureEventProxy('gesturechange'),\n gestureend: gestureEventProxy('gestureend')\n });\n if (options.enableSwipe) {\n that.events.bind('start', proxy(that, '_swipestart'));\n that.events.bind('move', proxy(that, '_swipemove'));\n } else {\n that.events.bind('start', proxy(that, '_dragstart'));\n that.events.bind('move', eventProxy('drag'));\n that.events.bind('end', eventProxy('dragend'));\n }\n kendo.notify(that);\n },\n events: [\n 'touchstart',\n 'dragstart',\n 'drag',\n 'dragend',\n 'tap',\n 'doubletap',\n 'hold',\n 'swipe',\n 'gesturestart',\n 'gesturechange',\n 'gestureend'\n ],\n options: {\n name: 'Touch',\n surface: null,\n global: false,\n fastTap: false,\n filter: null,\n multiTouch: false,\n enableSwipe: false,\n minXDelta: 30,\n maxYDelta: 20,\n maxDuration: 1000,\n minHold: 800,\n doubleTapTimeout: 800\n },\n cancel: function () {\n this.events.cancel();\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n this.events.destroy();\n },\n _triggerTouch: function (type, e) {\n if (this.trigger(type, {\n touch: e.touch,\n event: e.event\n })) {\n e.preventDefault();\n }\n },\n _tap: function (e) {\n var that = this, lastTap = that.lastTap, touch = e.touch;\n if (lastTap && touch.endTime - lastTap.endTime < that.options.doubleTapTimeout && kendo.touchDelta(touch, lastTap).distance < MAX_DOUBLE_TAP_DISTANCE) {\n that._triggerTouch('doubletap', e);\n that.lastTap = null;\n } else {\n that._triggerTouch('tap', e);\n that.lastTap = touch;\n }\n },\n _dragstart: function (e) {\n this._triggerTouch('dragstart', e);\n },\n _swipestart: function (e) {\n if (abs(e.x.velocity) * 2 >= abs(e.y.velocity)) {\n e.sender.capture();\n }\n },\n _swipemove: function (e) {\n var that = this, options = that.options, touch = e.touch, duration = e.event.timeStamp - touch.startTime, direction = touch.x.initialDelta > 0 ? 'right' : 'left';\n if (abs(touch.x.initialDelta) >= options.minXDelta && abs(touch.y.initialDelta) < options.maxYDelta && duration < options.maxDuration) {\n that.trigger('swipe', {\n direction: direction,\n touch: e.touch\n });\n touch.cancel();\n }\n }\n });\n kendo.ui.plugin(Touch);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.scroller', [\n 'kendo.fx',\n 'kendo.draganddrop'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.scroller',\n name: 'Scroller',\n category: 'mobile',\n description: 'The Kendo Mobile Scroller widget enables touch friendly kinetic scrolling for the contents of a given DOM element.',\n depends: [\n 'fx',\n 'draganddrop'\n ]\n };\n (function ($, undefined) {\n var kendo = window.kendo, mobile = kendo.mobile, fx = kendo.effects, ui = mobile.ui, proxy = $.proxy, extend = $.extend, Widget = ui.Widget, Class = kendo.Class, Movable = kendo.ui.Movable, Pane = kendo.ui.Pane, PaneDimensions = kendo.ui.PaneDimensions, Transition = fx.Transition, Animation = fx.Animation, abs = Math.abs, SNAPBACK_DURATION = 500, SCROLLBAR_OPACITY = 0.7, FRICTION = 0.96, VELOCITY_MULTIPLIER = 10, MAX_VELOCITY = 55, OUT_OF_BOUNDS_FRICTION = 0.5, ANIMATED_SCROLLER_PRECISION = 5, RELEASECLASS = 'km-scroller-release', REFRESHCLASS = 'km-scroller-refresh', PULL = 'pull', CHANGE = 'change', RESIZE = 'resize', SCROLL = 'scroll', MOUSE_WHEEL_ID = 2;\n var ZoomSnapBack = Animation.extend({\n init: function (options) {\n var that = this;\n Animation.fn.init.call(that);\n extend(that, options);\n that.userEvents.bind('gestureend', proxy(that.start, that));\n that.tapCapture.bind('press', proxy(that.cancel, that));\n },\n enabled: function () {\n return this.movable.scale < this.dimensions.minScale;\n },\n done: function () {\n return this.dimensions.minScale - this.movable.scale < 0.01;\n },\n tick: function () {\n var movable = this.movable;\n movable.scaleWith(1.1);\n this.dimensions.rescale(movable.scale);\n },\n onEnd: function () {\n var movable = this.movable;\n movable.scaleTo(this.dimensions.minScale);\n this.dimensions.rescale(movable.scale);\n }\n });\n var DragInertia = Animation.extend({\n init: function (options) {\n var that = this;\n Animation.fn.init.call(that);\n extend(that, options, {\n transition: new Transition({\n axis: options.axis,\n movable: options.movable,\n onEnd: function () {\n that._end();\n }\n })\n });\n that.tapCapture.bind('press', function () {\n that.cancel();\n });\n that.userEvents.bind('end', proxy(that.start, that));\n that.userEvents.bind('gestureend', proxy(that.start, that));\n that.userEvents.bind('tap', proxy(that.onEnd, that));\n },\n onCancel: function () {\n this.transition.cancel();\n },\n freeze: function (location) {\n var that = this;\n that.cancel();\n that._moveTo(location);\n },\n onEnd: function () {\n var that = this;\n if (that.paneAxis.outOfBounds()) {\n that._snapBack();\n } else {\n that._end();\n }\n },\n done: function () {\n return abs(this.velocity) < 1;\n },\n start: function (e) {\n var that = this, velocity;\n if (!that.dimension.enabled) {\n return;\n }\n if (that.paneAxis.outOfBounds()) {\n if (that.transition._started) {\n that.transition.cancel();\n that.velocity = Math.min(e.touch[that.axis].velocity * that.velocityMultiplier, MAX_VELOCITY);\n Animation.fn.start.call(that);\n } else {\n that._snapBack();\n }\n } else {\n velocity = e.touch.id === MOUSE_WHEEL_ID ? 0 : e.touch[that.axis].velocity;\n that.velocity = Math.max(Math.min(velocity * that.velocityMultiplier, MAX_VELOCITY), -MAX_VELOCITY);\n that.tapCapture.captureNext();\n Animation.fn.start.call(that);\n }\n },\n tick: function () {\n var that = this, dimension = that.dimension, friction = that.paneAxis.outOfBounds() ? OUT_OF_BOUNDS_FRICTION : that.friction, delta = that.velocity *= friction, location = that.movable[that.axis] + delta;\n if (!that.elastic && dimension.outOfBounds(location)) {\n location = Math.max(Math.min(location, dimension.max), dimension.min);\n that.velocity = 0;\n }\n that.movable.moveAxis(that.axis, location);\n },\n _end: function () {\n this.tapCapture.cancelCapture();\n this.end();\n },\n _snapBack: function () {\n var that = this, dimension = that.dimension, snapBack = that.movable[that.axis] > dimension.max ? dimension.max : dimension.min;\n that._moveTo(snapBack);\n },\n _moveTo: function (location) {\n this.transition.moveTo({\n location: location,\n duration: SNAPBACK_DURATION,\n ease: Transition.easeOutExpo\n });\n }\n });\n var AnimatedScroller = Animation.extend({\n init: function (options) {\n var that = this;\n kendo.effects.Animation.fn.init.call(this);\n extend(that, options, {\n origin: {},\n destination: {},\n offset: {}\n });\n },\n tick: function () {\n this._updateCoordinates();\n this.moveTo(this.origin);\n },\n done: function () {\n return abs(this.offset.y) < ANIMATED_SCROLLER_PRECISION && abs(this.offset.x) < ANIMATED_SCROLLER_PRECISION;\n },\n onEnd: function () {\n this.moveTo(this.destination);\n if (this.callback) {\n this.callback.call();\n }\n },\n setCoordinates: function (from, to) {\n this.offset = {};\n this.origin = from;\n this.destination = to;\n },\n setCallback: function (callback) {\n if (callback && kendo.isFunction(callback)) {\n this.callback = callback;\n } else {\n callback = undefined;\n }\n },\n _updateCoordinates: function () {\n this.offset = {\n x: (this.destination.x - this.origin.x) / 4,\n y: (this.destination.y - this.origin.y) / 4\n };\n this.origin = {\n y: this.origin.y + this.offset.y,\n x: this.origin.x + this.offset.x\n };\n }\n });\n var ScrollBar = Class.extend({\n init: function (options) {\n var that = this, horizontal = options.axis === 'x', element = $('
    ');\n extend(that, options, {\n element: element,\n elementSize: 0,\n movable: new Movable(element),\n scrollMovable: options.movable,\n alwaysVisible: options.alwaysVisible,\n size: horizontal ? 'width' : 'height'\n });\n that.scrollMovable.bind(CHANGE, proxy(that.refresh, that));\n that.container.append(element);\n if (options.alwaysVisible) {\n that.show();\n }\n },\n refresh: function () {\n var that = this, axis = that.axis, dimension = that.dimension, paneSize = dimension.size, scrollMovable = that.scrollMovable, sizeRatio = paneSize / dimension.total, position = Math.round(-scrollMovable[axis] * sizeRatio), size = Math.round(paneSize * sizeRatio);\n if (sizeRatio >= 1) {\n this.element.css('display', 'none');\n } else {\n this.element.css('display', '');\n }\n if (position + size > paneSize) {\n size = paneSize - position;\n } else if (position < 0) {\n size += position;\n position = 0;\n }\n if (that.elementSize != size) {\n that.element.css(that.size, size + 'px');\n that.elementSize = size;\n }\n that.movable.moveAxis(axis, position);\n },\n show: function () {\n this.element.css({\n opacity: SCROLLBAR_OPACITY,\n visibility: 'visible'\n });\n },\n hide: function () {\n if (!this.alwaysVisible) {\n this.element.css({ opacity: 0 });\n }\n }\n });\n var Scroller = Widget.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n element = that.element;\n that._native = that.options.useNative && kendo.support.hasNativeScrolling;\n if (that._native) {\n element.addClass('km-native-scroller').prepend('
    ');\n extend(that, {\n scrollElement: element,\n fixedContainer: element.children().first()\n });\n return;\n }\n element.css('overflow', 'hidden').addClass('km-scroll-wrapper').wrapInner('
    ').prepend('
    ');\n var inner = element.children().eq(1), tapCapture = new kendo.TapCapture(element), movable = new Movable(inner), dimensions = new PaneDimensions({\n element: inner,\n container: element,\n forcedEnabled: that.options.zoom\n }), avoidScrolling = this.options.avoidScrolling, userEvents = new kendo.UserEvents(element, {\n touchAction: 'pan-y',\n fastTap: true,\n allowSelection: true,\n preventDragEvent: true,\n captureUpIfMoved: true,\n multiTouch: that.options.zoom,\n supportDoubleTap: that.options.supportDoubleTap,\n start: function (e) {\n dimensions.refresh();\n var velocityX = abs(e.x.velocity), velocityY = abs(e.y.velocity), horizontalSwipe = velocityX * 2 >= velocityY, originatedFromFixedContainer = $.contains(that.fixedContainer[0], e.event.target), verticalSwipe = velocityY * 2 >= velocityX;\n if (!originatedFromFixedContainer && !avoidScrolling(e) && that.enabled && (dimensions.x.enabled && horizontalSwipe || dimensions.y.enabled && verticalSwipe)) {\n userEvents.capture();\n } else {\n userEvents.cancel();\n }\n }\n }), pane = new Pane({\n movable: movable,\n dimensions: dimensions,\n userEvents: userEvents,\n elastic: that.options.elastic\n }), zoomSnapBack = new ZoomSnapBack({\n movable: movable,\n dimensions: dimensions,\n userEvents: userEvents,\n tapCapture: tapCapture\n }), animatedScroller = new AnimatedScroller({\n moveTo: function (coordinates) {\n that.scrollTo(coordinates.x, coordinates.y);\n }\n });\n movable.bind(CHANGE, function () {\n that.scrollTop = -movable.y;\n that.scrollLeft = -movable.x;\n that.trigger(SCROLL, {\n scrollTop: that.scrollTop,\n scrollLeft: that.scrollLeft\n });\n });\n if (that.options.mousewheelScrolling) {\n element.on('DOMMouseScroll mousewheel', proxy(this, '_wheelScroll'));\n }\n extend(that, {\n movable: movable,\n dimensions: dimensions,\n zoomSnapBack: zoomSnapBack,\n animatedScroller: animatedScroller,\n userEvents: userEvents,\n pane: pane,\n tapCapture: tapCapture,\n pulled: false,\n enabled: true,\n scrollElement: inner,\n scrollTop: 0,\n scrollLeft: 0,\n fixedContainer: element.children().first()\n });\n that._initAxis('x');\n that._initAxis('y');\n that._wheelEnd = function () {\n that._wheel = false;\n that.userEvents.end(0, that._wheelY);\n };\n dimensions.refresh();\n if (that.options.pullToRefresh) {\n that._initPullToRefresh();\n }\n },\n _wheelScroll: function (e) {\n if (e.ctrlKey) {\n return;\n }\n if (!this._wheel) {\n this._wheel = true;\n this._wheelY = 0;\n this.userEvents.press(0, this._wheelY);\n }\n clearTimeout(this._wheelTimeout);\n this._wheelTimeout = setTimeout(this._wheelEnd, 50);\n var delta = kendo.wheelDeltaY(e);\n if (delta) {\n this._wheelY += delta;\n this.userEvents.move(0, this._wheelY);\n }\n e.preventDefault();\n },\n makeVirtual: function () {\n this.dimensions.y.makeVirtual();\n },\n virtualSize: function (min, max) {\n this.dimensions.y.virtualSize(min, max);\n },\n height: function () {\n return this.dimensions.y.size;\n },\n scrollHeight: function () {\n return this.scrollElement[0].scrollHeight;\n },\n scrollWidth: function () {\n return this.scrollElement[0].scrollWidth;\n },\n options: {\n name: 'Scroller',\n zoom: false,\n pullOffset: 140,\n visibleScrollHints: false,\n elastic: true,\n useNative: false,\n mousewheelScrolling: true,\n avoidScrolling: function () {\n return false;\n },\n pullToRefresh: false,\n messages: {\n pullTemplate: 'Pull to refresh',\n releaseTemplate: 'Release to refresh',\n refreshTemplate: 'Refreshing'\n }\n },\n events: [\n PULL,\n SCROLL,\n RESIZE\n ],\n _resize: function () {\n if (!this._native) {\n this.contentResized();\n }\n },\n setOptions: function (options) {\n var that = this;\n Widget.fn.setOptions.call(that, options);\n if (options.pullToRefresh) {\n that._initPullToRefresh();\n }\n },\n reset: function () {\n if (this._native) {\n this.scrollElement.scrollTop(0);\n } else {\n this.movable.moveTo({\n x: 0,\n y: 0\n });\n this._scale(1);\n }\n },\n contentResized: function () {\n this.dimensions.refresh();\n if (this.pane.x.outOfBounds()) {\n this.movable.moveAxis('x', this.dimensions.x.min);\n }\n if (this.pane.y.outOfBounds()) {\n this.movable.moveAxis('y', this.dimensions.y.min);\n }\n },\n zoomOut: function () {\n var dimensions = this.dimensions;\n dimensions.refresh();\n this._scale(dimensions.fitScale);\n this.movable.moveTo(dimensions.centerCoordinates());\n },\n enable: function () {\n this.enabled = true;\n },\n disable: function () {\n this.enabled = false;\n },\n scrollTo: function (x, y) {\n if (this._native) {\n this.scrollElement.scrollLeft(abs(x));\n this.scrollElement.scrollTop(abs(y));\n } else {\n this.dimensions.refresh();\n this.movable.moveTo({\n x: x,\n y: y\n });\n }\n },\n animatedScrollTo: function (x, y, callback) {\n var from, to;\n if (this._native) {\n this.scrollTo(x, y);\n } else {\n from = {\n x: this.movable.x,\n y: this.movable.y\n };\n to = {\n x: x,\n y: y\n };\n this.animatedScroller.setCoordinates(from, to);\n this.animatedScroller.setCallback(callback);\n this.animatedScroller.start();\n }\n },\n pullHandled: function () {\n var that = this;\n that.refreshHint.removeClass(REFRESHCLASS);\n that.hintContainer.html(that.pullTemplate({}));\n that.yinertia.onEnd();\n that.xinertia.onEnd();\n that.userEvents.cancel();\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n if (this.userEvents) {\n this.userEvents.destroy();\n }\n },\n _scale: function (scale) {\n this.dimensions.rescale(scale);\n this.movable.scaleTo(scale);\n },\n _initPullToRefresh: function () {\n var that = this;\n that.dimensions.y.forceEnabled();\n that.pullTemplate = kendo.template(that.options.messages.pullTemplate);\n that.releaseTemplate = kendo.template(that.options.messages.releaseTemplate);\n that.refreshTemplate = kendo.template(that.options.messages.refreshTemplate);\n that.scrollElement.prepend('' + that.pullTemplate({}) + '');\n that.refreshHint = that.scrollElement.children().first();\n that.hintContainer = that.refreshHint.children('.km-template');\n that.pane.y.bind('change', proxy(that._paneChange, that));\n that.userEvents.bind('end', proxy(that._dragEnd, that));\n },\n _dragEnd: function () {\n var that = this;\n if (!that.pulled) {\n return;\n }\n that.pulled = false;\n that.refreshHint.removeClass(RELEASECLASS).addClass(REFRESHCLASS);\n that.hintContainer.html(that.refreshTemplate({}));\n that.yinertia.freeze(that.options.pullOffset / 2);\n that.trigger('pull');\n },\n _paneChange: function () {\n var that = this;\n if (that.movable.y / OUT_OF_BOUNDS_FRICTION > that.options.pullOffset) {\n if (!that.pulled) {\n that.pulled = true;\n that.refreshHint.removeClass(REFRESHCLASS).addClass(RELEASECLASS);\n that.hintContainer.html(that.releaseTemplate({}));\n }\n } else if (that.pulled) {\n that.pulled = false;\n that.refreshHint.removeClass(RELEASECLASS);\n that.hintContainer.html(that.pullTemplate({}));\n }\n },\n _initAxis: function (axis) {\n var that = this, movable = that.movable, dimension = that.dimensions[axis], tapCapture = that.tapCapture, paneAxis = that.pane[axis], scrollBar = new ScrollBar({\n axis: axis,\n movable: movable,\n dimension: dimension,\n container: that.element,\n alwaysVisible: that.options.visibleScrollHints\n });\n dimension.bind(CHANGE, function () {\n scrollBar.refresh();\n });\n paneAxis.bind(CHANGE, function () {\n scrollBar.show();\n });\n that[axis + 'inertia'] = new DragInertia({\n axis: axis,\n paneAxis: paneAxis,\n movable: movable,\n tapCapture: tapCapture,\n userEvents: that.userEvents,\n dimension: dimension,\n elastic: that.options.elastic,\n friction: that.options.friction || FRICTION,\n velocityMultiplier: that.options.velocityMultiplier || VELOCITY_MULTIPLIER,\n end: function () {\n scrollBar.hide();\n that.trigger('scrollEnd', {\n axis: axis,\n scrollTop: that.scrollTop,\n scrollLeft: that.scrollLeft\n });\n }\n });\n }\n });\n ui.plugin(Scroller);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.view', [\n 'kendo.core',\n 'kendo.fx',\n 'kendo.mobile.scroller',\n 'kendo.view'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.view',\n name: 'View',\n category: 'mobile',\n description: 'Mobile View',\n depends: [\n 'core',\n 'fx',\n 'mobile.scroller',\n 'view'\n ],\n hidden: true\n };\n (function ($, undefined) {\n var kendo = window.kendo, mobile = kendo.mobile, ui = mobile.ui, attr = kendo.attr, Widget = ui.Widget, ViewClone = kendo.ViewClone, INIT = 'init', UI_OVERLAY = '
    ', BEFORE_SHOW = 'beforeShow', SHOW = 'show', AFTER_SHOW = 'afterShow', BEFORE_HIDE = 'beforeHide', TRANSITION_END = 'transitionEnd', TRANSITION_START = 'transitionStart', HIDE = 'hide', DESTROY = 'destroy', attrValue = kendo.attrValue, roleSelector = kendo.roleSelector, directiveSelector = kendo.directiveSelector, compileMobileDirective = kendo.compileMobileDirective;\n function initPopOvers(element) {\n var popovers = element.find(roleSelector('popover')), idx, length, roles = ui.roles;\n for (idx = 0, length = popovers.length; idx < length; idx++) {\n kendo.initWidget(popovers[idx], {}, roles);\n }\n }\n function preventScrollIfNotInput(e) {\n if (!kendo.triggeredByInput(e)) {\n e.preventDefault();\n }\n }\n var View = Widget.extend({\n init: function (element, options) {\n Widget.fn.init.call(this, element, options);\n this.params = {};\n $.extend(this, options);\n this.transition = this.transition || this.defaultTransition;\n this._id();\n if (!this.options.$angular) {\n this._layout();\n this._overlay();\n this._scroller();\n this._model();\n } else {\n this._overlay();\n }\n },\n events: [\n INIT,\n BEFORE_SHOW,\n SHOW,\n AFTER_SHOW,\n BEFORE_HIDE,\n HIDE,\n DESTROY,\n TRANSITION_START,\n TRANSITION_END\n ],\n options: {\n name: 'View',\n title: '',\n layout: null,\n getLayout: $.noop,\n reload: false,\n transition: '',\n defaultTransition: '',\n useNativeScrolling: false,\n stretch: false,\n zoom: false,\n model: null,\n modelScope: window,\n scroller: {},\n initWidgets: true\n },\n enable: function (enable) {\n if (typeof enable == 'undefined') {\n enable = true;\n }\n if (enable) {\n this.overlay.hide();\n } else {\n this.overlay.show();\n }\n },\n destroy: function () {\n if (this.layout) {\n this.layout.detach(this);\n }\n this.trigger(DESTROY);\n Widget.fn.destroy.call(this);\n if (this.scroller) {\n this.scroller.destroy();\n }\n if (this.options.$angular) {\n this.element.scope().$destroy();\n }\n kendo.destroy(this.element);\n },\n purge: function () {\n this.destroy();\n this.element.remove();\n },\n triggerBeforeShow: function () {\n if (this.trigger(BEFORE_SHOW, { view: this })) {\n return false;\n }\n return true;\n },\n triggerBeforeHide: function () {\n if (this.trigger(BEFORE_HIDE, { view: this })) {\n return false;\n }\n return true;\n },\n showStart: function () {\n var element = this.element;\n element.css('display', '');\n if (!this.inited) {\n this.inited = true;\n this.trigger(INIT, { view: this });\n } else {\n this._invokeNgController();\n }\n if (this.layout) {\n this.layout.attach(this);\n }\n this._padIfNativeScrolling();\n this.trigger(SHOW, { view: this });\n kendo.resize(element);\n },\n showEnd: function () {\n this.trigger(AFTER_SHOW, { view: this });\n this._padIfNativeScrolling();\n },\n hideEnd: function () {\n var that = this;\n that.element.hide();\n that.trigger(HIDE, { view: that });\n if (that.layout) {\n that.layout.trigger(HIDE, {\n view: that,\n layout: that.layout\n });\n }\n },\n beforeTransition: function (type) {\n this.trigger(TRANSITION_START, { type: type });\n },\n afterTransition: function (type) {\n this.trigger(TRANSITION_END, { type: type });\n },\n _padIfNativeScrolling: function () {\n if (mobile.appLevelNativeScrolling()) {\n var isAndroid = kendo.support.mobileOS && kendo.support.mobileOS.android, skin = mobile.application.skin() || '', isAndroidForced = mobile.application.os.android || skin.indexOf('android') > -1, hasPlatformIndependentSkin = skin === 'flat' || skin.indexOf('material') > -1, topContainer = (isAndroid || isAndroidForced) && !hasPlatformIndependentSkin ? 'footer' : 'header', bottomContainer = (isAndroid || isAndroidForced) && !hasPlatformIndependentSkin ? 'header' : 'footer';\n this.content.css({\n paddingTop: this[topContainer].height(),\n paddingBottom: this[bottomContainer].height()\n });\n }\n },\n contentElement: function () {\n var that = this;\n return that.options.stretch ? that.content : that.scrollerContent;\n },\n clone: function () {\n return new ViewClone(this);\n },\n _scroller: function () {\n var that = this;\n if (mobile.appLevelNativeScrolling()) {\n return;\n }\n if (that.options.stretch) {\n that.content.addClass('km-stretched-view');\n } else {\n that.content.kendoMobileScroller($.extend(that.options.scroller, {\n zoom: that.options.zoom,\n useNative: that.options.useNativeScrolling\n }));\n that.scroller = that.content.data('kendoMobileScroller');\n that.scrollerContent = that.scroller.scrollElement;\n }\n if (kendo.support.kineticScrollNeeded) {\n $(that.element).on('touchmove', '.km-header', preventScrollIfNotInput);\n if (!that.options.useNativeScrolling && !that.options.stretch) {\n $(that.element).on('touchmove', '.km-content', preventScrollIfNotInput);\n }\n }\n },\n _model: function () {\n var that = this, element = that.element, model = that.options.model;\n if (typeof model === 'string') {\n model = kendo.getter(model)(that.options.modelScope);\n }\n that.model = model;\n initPopOvers(element);\n that.element.css('display', '');\n if (that.options.initWidgets) {\n if (model) {\n kendo.bind(element, model, ui, kendo.ui, kendo.dataviz.ui);\n } else {\n mobile.init(element.children());\n }\n }\n that.element.css('display', 'none');\n },\n _id: function () {\n var element = this.element, idAttrValue = element.attr('id') || '';\n this.id = attrValue(element, 'url') || '#' + idAttrValue;\n if (this.id == '#') {\n this.id = kendo.guid();\n element.attr('id', this.id);\n }\n },\n _layout: function () {\n var contentSelector = roleSelector('content'), element = this.element;\n element.addClass('km-view');\n this.header = element.children(roleSelector('header')).addClass('km-header');\n this.footer = element.children(roleSelector('footer')).addClass('km-footer');\n if (!element.children(contentSelector)[0]) {\n element.wrapInner('
    ');\n }\n this.content = element.children(roleSelector('content')).addClass('km-content');\n this.element.prepend(this.header).append(this.footer);\n this.layout = this.options.getLayout(this.layout);\n if (this.layout) {\n this.layout.setup(this);\n }\n },\n _overlay: function () {\n this.overlay = $(UI_OVERLAY).appendTo(this.element);\n },\n _invokeNgController: function () {\n var controller, scope;\n if (this.options.$angular) {\n controller = this.element.controller();\n scope = this.options.$angular[0];\n if (controller) {\n var callback = $.proxy(this, '_callController', controller, scope);\n if (/^\\$(digest|apply)$/.test(scope.$$phase)) {\n callback();\n } else {\n scope.$apply(callback);\n }\n }\n }\n },\n _callController: function (controller, scope) {\n this.element.injector().invoke(controller.constructor, controller, { $scope: scope });\n }\n });\n function initWidgets(collection) {\n collection.each(function () {\n kendo.initWidget($(this), {}, ui.roles);\n });\n }\n var Layout = Widget.extend({\n init: function (element, options) {\n Widget.fn.init.call(this, element, options);\n element = this.element;\n this.header = element.children(this._locate('header')).addClass('km-header');\n this.footer = element.children(this._locate('footer')).addClass('km-footer');\n this.elements = this.header.add(this.footer);\n initPopOvers(element);\n if (!this.options.$angular) {\n kendo.mobile.init(this.element.children());\n }\n this.element.detach();\n this.trigger(INIT, { layout: this });\n },\n _locate: function (selectors) {\n return this.options.$angular ? directiveSelector(selectors) : roleSelector(selectors);\n },\n options: {\n name: 'Layout',\n id: null,\n platform: null\n },\n events: [\n INIT,\n SHOW,\n HIDE\n ],\n setup: function (view) {\n if (!view.header[0]) {\n view.header = this.header;\n }\n if (!view.footer[0]) {\n view.footer = this.footer;\n }\n },\n detach: function (view) {\n var that = this;\n if (view.header === that.header && that.header[0]) {\n view.element.prepend(that.header.detach()[0].cloneNode(true));\n }\n if (view.footer === that.footer && that.footer.length) {\n view.element.append(that.footer.detach()[0].cloneNode(true));\n }\n },\n attach: function (view) {\n var that = this, previousView = that.currentView;\n if (previousView) {\n that.detach(previousView);\n }\n if (view.header === that.header) {\n that.header.detach();\n view.element.children(roleSelector('header')).remove();\n view.element.prepend(that.header);\n }\n if (view.footer === that.footer) {\n that.footer.detach();\n view.element.children(roleSelector('footer')).remove();\n view.element.append(that.footer);\n }\n that.trigger(SHOW, {\n layout: that,\n view: view\n });\n that.currentView = view;\n }\n });\n var Observable = kendo.Observable, bodyRegExp = /]*>(([\\u000a\\u000d\\u2028\\u2029]|.)*)<\\/body>/i, LOAD_START = 'loadStart', LOAD_COMPLETE = 'loadComplete', SHOW_START = 'showStart', SAME_VIEW_REQUESTED = 'sameViewRequested', VIEW_SHOW = 'viewShow', VIEW_TYPE_DETERMINED = 'viewTypeDetermined', AFTER = 'after';\n var ViewEngine = Observable.extend({\n init: function (options) {\n var that = this, views, errorMessage, container, collection;\n Observable.fn.init.call(that);\n $.extend(that, options);\n that.sandbox = $('
    ');\n container = that.container;\n views = that._hideViews(container);\n that.rootView = views.first();\n if (!that.rootView[0] && options.rootNeeded) {\n if (container[0] == kendo.mobile.application.element[0]) {\n errorMessage = '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.';\n } else {\n errorMessage = 'Your pane element does not contain any direct child elements with data-role=\"view\" attribute set.';\n }\n throw new Error(errorMessage);\n }\n that.layouts = {};\n that.viewContainer = new kendo.ViewContainer(that.container);\n that.viewContainer.bind('accepted', function (e) {\n e.view.params = that.params;\n });\n that.viewContainer.bind('complete', function (e) {\n that.trigger(VIEW_SHOW, { view: e.view });\n });\n that.viewContainer.bind(AFTER, function () {\n that.trigger(AFTER);\n });\n this.getLayoutProxy = $.proxy(this, '_getLayout');\n that._setupLayouts(container);\n collection = container.children(that._locate('modalview drawer'));\n if (that.$angular) {\n that.$angular[0].viewOptions = {\n defaultTransition: that.transition,\n loader: that.loader,\n container: that.container,\n getLayout: that.getLayoutProxy\n };\n collection.each(function (idx, element) {\n compileMobileDirective($(element), options.$angular[0]);\n });\n } else {\n initWidgets(collection);\n }\n this.bind(this.events, options);\n },\n events: [\n SHOW_START,\n AFTER,\n VIEW_SHOW,\n LOAD_START,\n LOAD_COMPLETE,\n SAME_VIEW_REQUESTED,\n VIEW_TYPE_DETERMINED\n ],\n destroy: function () {\n kendo.destroy(this.container);\n for (var id in this.layouts) {\n this.layouts[id].destroy();\n }\n },\n view: function () {\n return this.viewContainer.view;\n },\n showView: function (url, transition, params) {\n url = url.replace(new RegExp('^' + this.remoteViewURLPrefix), '');\n if (url === '' && this.remoteViewURLPrefix) {\n url = '/';\n }\n if (url.replace(/^#/, '') === this.url) {\n this.trigger(SAME_VIEW_REQUESTED);\n return false;\n }\n this.trigger(SHOW_START);\n var that = this, showClosure = function (view) {\n return that.viewContainer.show(view, transition, url);\n }, element = that._findViewElement(url), view = kendo.widgetInstance(element);\n that.url = url.replace(/^#/, '');\n that.params = params;\n if (view && view.reload) {\n view.purge();\n element = [];\n }\n this.trigger(VIEW_TYPE_DETERMINED, {\n remote: element.length === 0,\n url: url\n });\n if (element[0]) {\n if (!view) {\n view = that._createView(element);\n }\n return showClosure(view);\n } else {\n if (this.serverNavigation) {\n location.href = url;\n } else {\n that._loadView(url, showClosure);\n }\n return true;\n }\n },\n append: function (html, url) {\n var sandbox = this.sandbox, urlPath = (url || '').split('?')[0], container = this.container, views, modalViews, view;\n if (bodyRegExp.test(html)) {\n html = RegExp.$1;\n }\n sandbox[0].innerHTML = html;\n container.append(sandbox.children('script, style'));\n views = this._hideViews(sandbox);\n view = views.first();\n if (!view.length) {\n views = view = sandbox.wrapInner('
    ').children();\n }\n if (urlPath) {\n view.hide().attr(attr('url'), urlPath);\n }\n this._setupLayouts(sandbox);\n modalViews = sandbox.children(this._locate('modalview drawer'));\n container.append(sandbox.children(this._locate('layout modalview drawer')).add(views));\n initWidgets(modalViews);\n return this._createView(view);\n },\n _locate: function (selectors) {\n return this.$angular ? directiveSelector(selectors) : roleSelector(selectors);\n },\n _findViewElement: function (url) {\n var element, urlPath = url.split('?')[0];\n if (!urlPath) {\n return this.rootView;\n }\n element = this.container.children('[' + attr('url') + '=\\'' + urlPath + '\\']');\n if (!element[0] && urlPath.indexOf('/') === -1) {\n element = this.container.children(urlPath.charAt(0) === '#' ? urlPath : '#' + urlPath);\n }\n return element;\n },\n _createView: function (element) {\n if (this.$angular) {\n return compileMobileDirective(element, this.$angular[0]);\n } else {\n return kendo.initWidget(element, {\n defaultTransition: this.transition,\n loader: this.loader,\n container: this.container,\n getLayout: this.getLayoutProxy,\n modelScope: this.modelScope,\n reload: attrValue(element, 'reload')\n }, ui.roles);\n }\n },\n _getLayout: function (name) {\n if (name === '') {\n return null;\n }\n return name ? this.layouts[name] : this.layouts[this.layout];\n },\n _loadView: function (url, callback) {\n if (this._xhr) {\n this._xhr.abort();\n }\n this.trigger(LOAD_START);\n this._xhr = $.get(kendo.absoluteURL(url, this.remoteViewURLPrefix), 'html').always($.proxy(this, '_xhrComplete', callback, url));\n },\n _xhrComplete: function (callback, url, response) {\n var success = true;\n if (typeof response === 'object') {\n if (response.status === 0) {\n if (response.responseText && response.responseText.length > 0) {\n success = true;\n response = response.responseText;\n } else {\n return;\n }\n }\n }\n this.trigger(LOAD_COMPLETE);\n if (success) {\n callback(this.append(response, url));\n }\n },\n _hideViews: function (container) {\n return container.children(this._locate('view splitview')).hide();\n },\n _setupLayouts: function (element) {\n var that = this, layout;\n element.children(that._locate('layout')).each(function () {\n if (that.$angular) {\n layout = compileMobileDirective($(this), that.$angular[0]);\n } else {\n layout = kendo.initWidget($(this), {}, ui.roles);\n }\n var platform = layout.options.platform;\n if (!platform || platform === mobile.application.os.name) {\n that.layouts[layout.options.id] = layout;\n } else {\n layout.destroy();\n }\n });\n }\n });\n kendo.mobile.ViewEngine = ViewEngine;\n ui.plugin(View);\n ui.plugin(Layout);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.loader', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.loader',\n name: 'Loader',\n category: 'mobile',\n description: 'Mobile Loader',\n depends: ['core'],\n hidden: true\n };\n (function ($, undefined) {\n var kendo = window.kendo, ui = kendo.mobile.ui, Widget = ui.Widget, CAPTURE_EVENTS = $.map(kendo.eventMap, function (value) {\n return value;\n }).join(' ').split(' ');\n var Loader = Widget.extend({\n init: function (container, options) {\n var that = this, element = $('
    ');\n Widget.fn.init.call(that, element, options);\n that.container = container;\n that.captureEvents = false;\n that._attachCapture();\n element.append(that.options.loading).hide().appendTo(container);\n },\n options: {\n name: 'Loader',\n loading: '

    Loading...

    ',\n timeout: 100\n },\n show: function () {\n var that = this;\n clearTimeout(that._loading);\n if (that.options.loading === false) {\n return;\n }\n that.captureEvents = true;\n that._loading = setTimeout(function () {\n that.element.show();\n }, that.options.timeout);\n },\n hide: function () {\n this.captureEvents = false;\n clearTimeout(this._loading);\n this.element.hide();\n },\n changeMessage: function (message) {\n this.options.loading = message;\n this.element.find('>h1').html(message);\n },\n transition: function () {\n this.captureEvents = true;\n this.container.css('pointer-events', 'none');\n },\n transitionDone: function () {\n this.captureEvents = false;\n this.container.css('pointer-events', '');\n },\n _attachCapture: function () {\n var that = this;\n that.captureEvents = false;\n function capture(e) {\n if (that.captureEvents) {\n e.preventDefault();\n }\n }\n for (var i = 0; i < CAPTURE_EVENTS.length; i++) {\n that.container[0].addEventListener(CAPTURE_EVENTS[i], capture, true);\n }\n }\n });\n ui.plugin(Loader);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.pane', [\n 'kendo.mobile.view',\n 'kendo.mobile.loader'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.pane',\n name: 'Pane',\n category: 'mobile',\n description: 'Mobile Pane',\n depends: [\n 'mobile.view',\n 'mobile.loader'\n ],\n hidden: true\n };\n (function ($, undefined) {\n var kendo = window.kendo, mobile = kendo.mobile, roleSelector = kendo.roleSelector, ui = mobile.ui, Widget = ui.Widget, ViewEngine = mobile.ViewEngine, View = ui.View, Loader = mobile.ui.Loader, EXTERNAL = 'external', HREF = 'href', DUMMY_HREF = '#!', NAVIGATE = 'navigate', VIEW_SHOW = 'viewShow', SAME_VIEW_REQUESTED = 'sameViewRequested', OS = kendo.support.mobileOS, SKIP_TRANSITION_ON_BACK_BUTTON = OS.ios && !OS.appMode && OS.flatVersion >= 700, WIDGET_RELS = /popover|actionsheet|modalview|drawer/, BACK = '#:back', attrValue = kendo.attrValue;\n var Pane = Widget.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n options = that.options;\n element = that.element;\n element.addClass('km-pane');\n if (that.options.collapsible) {\n element.addClass('km-collapsible-pane');\n }\n this.history = [];\n this.historyCallback = function (url, params, backButtonPressed) {\n var transition = that.transition;\n that.transition = null;\n if (SKIP_TRANSITION_ON_BACK_BUTTON && backButtonPressed) {\n transition = 'none';\n }\n return that.viewEngine.showView(url, transition, params);\n };\n this._historyNavigate = function (url) {\n if (url === BACK) {\n if (that.history.length === 1) {\n return;\n }\n that.history.pop();\n url = that.history[that.history.length - 1];\n } else {\n that.history.push(url);\n }\n that.historyCallback(url, kendo.parseQueryStringParams(url));\n };\n this._historyReplace = function (url) {\n var params = kendo.parseQueryStringParams(url);\n that.history[that.history.length - 1] = url;\n that.historyCallback(url, params);\n };\n that.loader = new Loader(element, { loading: that.options.loading });\n that.viewEngine = new ViewEngine({\n container: element,\n transition: options.transition,\n modelScope: options.modelScope,\n rootNeeded: !options.initial,\n serverNavigation: options.serverNavigation,\n remoteViewURLPrefix: options.root || '',\n layout: options.layout,\n $angular: options.$angular,\n loader: that.loader,\n showStart: function () {\n that.loader.transition();\n that.closeActiveDialogs();\n },\n after: function () {\n that.loader.transitionDone();\n },\n viewShow: function (e) {\n that.trigger(VIEW_SHOW, e);\n },\n loadStart: function () {\n that.loader.show();\n },\n loadComplete: function () {\n that.loader.hide();\n },\n sameViewRequested: function () {\n that.trigger(SAME_VIEW_REQUESTED);\n },\n viewTypeDetermined: function (e) {\n if (!e.remote || !that.options.serverNavigation) {\n that.trigger(NAVIGATE, { url: e.url });\n }\n }\n });\n this._setPortraitWidth();\n kendo.onResize(function () {\n that._setPortraitWidth();\n });\n that._setupAppLinks();\n },\n closeActiveDialogs: function () {\n var dialogs = this.element.find(roleSelector('actionsheet popover modalview')).filter(':visible');\n dialogs.each(function () {\n kendo.widgetInstance($(this), ui).close();\n });\n },\n navigateToInitial: function () {\n var initial = this.options.initial;\n if (initial) {\n this.navigate(initial);\n }\n return initial;\n },\n options: {\n name: 'Pane',\n portraitWidth: '',\n transition: '',\n layout: '',\n collapsible: false,\n initial: null,\n modelScope: window,\n loading: '

    Loading...

    '\n },\n events: [\n NAVIGATE,\n VIEW_SHOW,\n SAME_VIEW_REQUESTED\n ],\n append: function (html) {\n return this.viewEngine.append(html);\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n this.viewEngine.destroy();\n this.userEvents.destroy();\n },\n navigate: function (url, transition) {\n if (url instanceof View) {\n url = url.id;\n }\n this.transition = transition;\n this._historyNavigate(url);\n },\n replace: function (url, transition) {\n if (url instanceof View) {\n url = url.id;\n }\n this.transition = transition;\n this._historyReplace(url);\n },\n bindToRouter: function (router) {\n var that = this, history = this.history, viewEngine = this.viewEngine;\n router.bind('init', function (e) {\n var url = e.url, attrUrl = router.pushState ? url : '/';\n viewEngine.rootView.attr(kendo.attr('url'), attrUrl);\n var length = history.length;\n if (url === '/' && length) {\n router.navigate(history[length - 1], true);\n e.preventDefault();\n }\n });\n router.bind('routeMissing', function (e) {\n if (!that.historyCallback(e.url, e.params, e.backButtonPressed)) {\n e.preventDefault();\n }\n });\n router.bind('same', function () {\n that.trigger(SAME_VIEW_REQUESTED);\n });\n that._historyNavigate = function (url) {\n router.navigate(url);\n };\n that._historyReplace = function (url) {\n router.replace(url);\n };\n },\n hideLoading: function () {\n this.loader.hide();\n },\n showLoading: function () {\n this.loader.show();\n },\n changeLoadingMessage: function (message) {\n this.loader.changeMessage(message);\n },\n view: function () {\n return this.viewEngine.view();\n },\n _setPortraitWidth: function () {\n var width, portraitWidth = this.options.portraitWidth;\n if (portraitWidth) {\n width = kendo.mobile.application.element.is('.km-vertical') ? portraitWidth : 'auto';\n this.element.css('width', width);\n }\n },\n _setupAppLinks: function () {\n var that = this, linkRoles = 'tab', pressedButtonSelector = '[data-' + kendo.ns + 'navigate-on-press]', buttonSelectors = $.map([\n 'button',\n 'backbutton',\n 'detailbutton',\n 'listview-link'\n ], function (role) {\n return roleSelector(role) + ':not(' + pressedButtonSelector + ')';\n }).join(',');\n this.element.handler(this).on('down', roleSelector(linkRoles) + ',' + pressedButtonSelector, '_mouseup').on('click', roleSelector(linkRoles) + ',' + buttonSelectors + ',' + pressedButtonSelector, '_appLinkClick');\n this.userEvents = new kendo.UserEvents(this.element, {\n fastTap: true,\n filter: buttonSelectors,\n tap: function (e) {\n e.event.currentTarget = e.touch.currentTarget;\n that._mouseup(e.event);\n }\n });\n this.element.css('-ms-touch-action', '');\n },\n _appLinkClick: function (e) {\n var href = $(e.currentTarget).attr('href');\n var remote = href && href[0] !== '#' && this.options.serverNavigation;\n if (!remote && attrValue($(e.currentTarget), 'rel') != EXTERNAL) {\n e.preventDefault();\n }\n },\n _mouseup: function (e) {\n if (e.which > 1 || e.isDefaultPrevented()) {\n return;\n }\n var pane = this, link = $(e.currentTarget), transition = attrValue(link, 'transition'), rel = attrValue(link, 'rel') || '', target = attrValue(link, 'target'), href = link.attr(HREF), delayedTouchEnd = SKIP_TRANSITION_ON_BACK_BUTTON && link[0].offsetHeight === 0, remote = href && href[0] !== '#' && this.options.serverNavigation;\n if (delayedTouchEnd || remote || rel === EXTERNAL || typeof href === 'undefined' || href === DUMMY_HREF) {\n return;\n }\n link.attr(HREF, DUMMY_HREF);\n setTimeout(function () {\n link.attr(HREF, href);\n });\n if (rel.match(WIDGET_RELS)) {\n kendo.widgetInstance($(href), ui).openFor(link);\n if (rel === 'actionsheet' || rel === 'drawer') {\n e.stopPropagation();\n }\n } else {\n if (target === '_top') {\n pane = mobile.application.pane;\n } else if (target) {\n pane = $('#' + target).data('kendoMobilePane');\n }\n pane.navigate(href, transition);\n }\n e.preventDefault();\n }\n });\n Pane.wrap = function (element) {\n if (!element.is(roleSelector('view'))) {\n element = element.wrap('
    ').parent();\n }\n var paneContainer = element.wrap('
    ').parent(), pane = new Pane(paneContainer);\n pane.navigate('');\n return pane;\n };\n ui.plugin(Pane);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.popover', [\n 'kendo.popup',\n 'kendo.mobile.pane'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.popover',\n name: 'PopOver',\n category: 'mobile',\n description: 'The mobile PopOver widget represents a transient view which is displayed when the user taps on a navigational widget or area on the screen. ',\n depends: [\n 'popup',\n 'mobile.pane'\n ]\n };\n (function ($, undefined) {\n var kendo = window.kendo, mobile = kendo.mobile, ui = mobile.ui, HIDE = 'hide', OPEN = 'open', CLOSE = 'close', WRAPPER = '
    ', ARROW = '
    ', OVERLAY = '
    ', DIRECTION_CLASSES = 'km-up km-down km-left km-right', Widget = ui.Widget, DIRECTIONS = {\n 'down': {\n origin: 'bottom center',\n position: 'top center'\n },\n 'up': {\n origin: 'top center',\n position: 'bottom center'\n },\n 'left': {\n origin: 'center left',\n position: 'center right',\n collision: 'fit flip'\n },\n 'right': {\n origin: 'center right',\n position: 'center left',\n collision: 'fit flip'\n }\n }, ANIMATION = {\n animation: {\n open: {\n effects: 'fade:in',\n duration: 0\n },\n close: {\n effects: 'fade:out',\n duration: 400\n }\n }\n }, DIMENSIONS = {\n 'horizontal': {\n offset: 'top',\n size: 'height'\n },\n 'vertical': {\n offset: 'left',\n size: 'width'\n }\n }, REVERSE = {\n 'up': 'down',\n 'down': 'up',\n 'left': 'right',\n 'right': 'left'\n };\n var Popup = Widget.extend({\n init: function (element, options) {\n var that = this, containerPopup = element.closest('.km-modalview-wrapper'), viewport = element.closest('.km-root').children('.km-pane').first(), container = containerPopup[0] ? containerPopup : viewport, popupOptions, axis;\n if (options.viewport) {\n viewport = options.viewport;\n } else if (!viewport[0]) {\n viewport = window;\n }\n if (options.container) {\n container = options.container;\n } else if (!container[0]) {\n container = document.body;\n }\n popupOptions = {\n viewport: viewport,\n copyAnchorStyles: false,\n autosize: true,\n open: function () {\n that.overlay.show();\n },\n activate: $.proxy(that._activate, that),\n deactivate: function () {\n that.overlay.hide();\n if (!that._apiCall) {\n that.trigger(HIDE);\n }\n that._apiCall = false;\n }\n };\n Widget.fn.init.call(that, element, options);\n element = that.element;\n options = that.options;\n element.wrap(WRAPPER).addClass('km-popup').show();\n axis = that.options.direction.match(/left|right/) ? 'horizontal' : 'vertical';\n that.dimensions = DIMENSIONS[axis];\n that.wrapper = element.parent().css({\n width: options.width,\n height: options.height\n }).addClass('km-popup-wrapper km-' + options.direction).hide();\n that.arrow = $(ARROW).prependTo(that.wrapper).hide();\n that.overlay = $(OVERLAY).appendTo(container).hide();\n popupOptions.appendTo = that.overlay;\n if (options.className) {\n that.overlay.addClass(options.className);\n }\n that.popup = new kendo.ui.Popup(that.wrapper, $.extend(true, popupOptions, ANIMATION, DIRECTIONS[options.direction]));\n },\n options: {\n name: 'Popup',\n width: 240,\n height: '',\n direction: 'down',\n container: null,\n viewport: null\n },\n events: [HIDE],\n show: function (target) {\n this.popup.options.anchor = $(target);\n this.popup.open();\n },\n hide: function () {\n this._apiCall = true;\n this.popup.close();\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n this.popup.destroy();\n this.overlay.remove();\n },\n target: function () {\n return this.popup.options.anchor;\n },\n _activate: function () {\n var that = this, direction = that.options.direction, dimensions = that.dimensions, offset = dimensions.offset, popup = that.popup, anchor = popup.options.anchor, anchorOffset = $(anchor).offset(), elementOffset = $(popup.element).offset(), cssClass = popup.flipped ? REVERSE[direction] : direction, min = that.arrow[dimensions.size]() * 2, max = that.element[dimensions.size]() - that.arrow[dimensions.size](), size = $(anchor)[dimensions.size](), offsetAmount = anchorOffset[offset] - elementOffset[offset] + size / 2;\n if (offsetAmount < min) {\n offsetAmount = min;\n }\n if (offsetAmount > max) {\n offsetAmount = max;\n }\n that.wrapper.removeClass(DIRECTION_CLASSES).addClass('km-' + cssClass);\n that.arrow.css(offset, offsetAmount).show();\n }\n });\n var PopOver = Widget.extend({\n init: function (element, options) {\n var that = this, popupOptions;\n that.initialOpen = false;\n Widget.fn.init.call(that, element, options);\n popupOptions = $.extend({\n className: 'km-popover-root',\n hide: function () {\n that.trigger(CLOSE);\n }\n }, this.options.popup);\n that.popup = new Popup(that.element, popupOptions);\n that.popup.overlay.on('move', function (e) {\n if (e.target == that.popup.overlay[0]) {\n e.preventDefault();\n }\n });\n that.pane = new ui.Pane(that.element, $.extend(this.options.pane, { $angular: this.options.$angular }));\n kendo.notify(that, ui);\n },\n options: {\n name: 'PopOver',\n popup: {},\n pane: {}\n },\n events: [\n OPEN,\n CLOSE\n ],\n open: function (target) {\n this.popup.show(target);\n if (!this.initialOpen) {\n if (!this.pane.navigateToInitial()) {\n this.pane.navigate('');\n }\n this.popup.popup._position();\n this.initialOpen = true;\n } else {\n this.pane.view()._invokeNgController();\n }\n },\n openFor: function (target) {\n this.open(target);\n this.trigger(OPEN, { target: this.popup.target() });\n },\n close: function () {\n this.popup.hide();\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n this.pane.destroy();\n this.popup.destroy();\n kendo.destroy(this.element);\n }\n });\n ui.plugin(Popup);\n ui.plugin(PopOver);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.shim', ['kendo.popup'], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.shim',\n name: 'Shim',\n category: 'mobile',\n description: 'Mobile Shim',\n depends: ['popup'],\n hidden: true\n };\n (function ($, undefined) {\n var kendo = window.kendo, ui = kendo.mobile.ui, Popup = kendo.ui.Popup, SHIM = '
    ', HIDE = 'hide', Widget = ui.Widget;\n var Shim = Widget.extend({\n init: function (element, options) {\n var that = this, app = kendo.mobile.application, os = kendo.support.mobileOS, osname = app ? app.os.name : os ? os.name : 'ios', ioswp = osname === 'ios' || osname === 'wp' || (app ? app.os.skin : false), bb = osname === 'blackberry', align = options.align || (ioswp ? 'bottom center' : bb ? 'center right' : 'center center'), position = options.position || (ioswp ? 'bottom center' : bb ? 'center right' : 'center center'), effect = options.effect || (ioswp ? 'slideIn:up' : bb ? 'slideIn:left' : 'fade:in'), shim = $(SHIM).handler(that).hide();\n Widget.fn.init.call(that, element, options);\n that.shim = shim;\n element = that.element;\n options = that.options;\n if (options.className) {\n that.shim.addClass(options.className);\n }\n if (!options.modal) {\n that.shim.on('down', '_hide');\n }\n (app ? app.element : $(document.body)).append(shim);\n that.popup = new Popup(that.element, {\n anchor: shim,\n modal: true,\n appendTo: shim,\n origin: align,\n position: position,\n animation: {\n open: {\n effects: effect,\n duration: options.duration\n },\n close: { duration: options.duration }\n },\n close: function (e) {\n var prevented = false;\n if (!that._apiCall) {\n prevented = that.trigger(HIDE);\n }\n if (prevented) {\n e.preventDefault();\n }\n that._apiCall = false;\n },\n deactivate: function () {\n shim.hide();\n },\n open: function () {\n shim.show();\n }\n });\n kendo.notify(that);\n },\n events: [HIDE],\n options: {\n name: 'Shim',\n modal: false,\n align: undefined,\n position: undefined,\n effect: undefined,\n duration: 200\n },\n show: function () {\n this.popup.open();\n },\n hide: function () {\n this._apiCall = true;\n this.popup.close();\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n this.shim.kendoDestroy();\n this.popup.destroy();\n this.shim.remove();\n },\n _hide: function (e) {\n if (!e || !$.contains(this.shim.children().children('.k-popup')[0], e.target)) {\n this.popup.close();\n }\n }\n });\n ui.plugin(Shim);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.modalview', [\n 'kendo.mobile.shim',\n 'kendo.mobile.view'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.modalview',\n name: 'ModalView',\n category: 'mobile',\n description: 'The Kendo ModalView is used to present self-contained functionality in the context of the current task.',\n depends: [\n 'mobile.shim',\n 'mobile.view'\n ]\n };\n (function ($, undefined) {\n var kendo = window.kendo, ui = kendo.mobile.ui, Shim = ui.Shim, Widget = ui.Widget, BEFORE_OPEN = 'beforeOpen', OPEN = 'open', CLOSE = 'close', INIT = 'init', WRAP = '
    ';\n var ModalView = ui.View.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n that._id();\n that._wrap();\n that._shim();\n if (!this.options.$angular) {\n that._layout();\n that._scroller();\n that._model();\n }\n that.element.css('display', '');\n that.trigger(INIT);\n },\n events: [\n INIT,\n BEFORE_OPEN,\n OPEN,\n CLOSE\n ],\n options: {\n name: 'ModalView',\n modal: true,\n width: null,\n height: null\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n this.shim.destroy();\n },\n open: function (target) {\n var that = this;\n that.target = $(target);\n that.shim.show();\n that._invokeNgController();\n that.trigger('show', { view: that });\n },\n openFor: function (target) {\n if (!this.trigger(BEFORE_OPEN, { target: target })) {\n this.open(target);\n this.trigger(OPEN, { target: target });\n }\n },\n close: function () {\n if (this.element.is(':visible') && !this.trigger(CLOSE)) {\n this.shim.hide();\n }\n },\n _wrap: function () {\n var that = this, element = that.element, options = that.options, width, height;\n width = element[0].style.width || 'auto';\n height = element[0].style.height || 'auto';\n element.addClass('km-modalview').wrap(WRAP);\n that.wrapper = element.parent().css({\n width: options.width || width || 300,\n height: options.height || height || 300\n }).addClass(height == 'auto' ? ' km-auto-height' : '');\n element.css({\n width: '',\n height: ''\n });\n },\n _shim: function () {\n var that = this;\n that.shim = new Shim(that.wrapper, {\n modal: that.options.modal,\n position: 'center center',\n align: 'center center',\n effect: 'fade:in',\n className: 'km-modalview-root',\n hide: function (e) {\n if (that.trigger(CLOSE)) {\n e.preventDefault();\n }\n }\n });\n }\n });\n ui.plugin(ModalView);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.drawer', [\n 'kendo.mobile.view',\n 'kendo.userevents'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.drawer',\n name: 'Drawer',\n category: 'mobile',\n description: 'The Kendo Mobile Drawer widget provides slide to reveal global application toolbox',\n depends: [\n 'mobile.view',\n 'userevents'\n ]\n };\n (function ($, undefined) {\n var kendo = window.kendo, mobile = kendo.mobile, os = kendo.support.mobileOS, Transition = kendo.effects.Transition, roleSelector = kendo.roleSelector, AXIS = 'x', ui = mobile.ui, SWIPE_TO_OPEN = !(os.ios && os.majorVersion == 7 && !os.appMode), BEFORE_SHOW = 'beforeShow', INIT = 'init', SHOW = 'show', HIDE = 'hide', AFTER_HIDE = 'afterHide', NULL_VIEW = { enable: $.noop };\n var Drawer = ui.View.extend({\n init: function (element, options) {\n $(element).parent().prepend(element);\n mobile.ui.Widget.fn.init.call(this, element, options);\n if (!this.options.$angular) {\n this._layout();\n this._scroller();\n }\n this._model();\n var pane = this.element.closest(roleSelector('pane')).data('kendoMobilePane'), userEvents;\n if (pane) {\n this.pane = pane;\n this.pane.bind('viewShow', function (e) {\n drawer._viewShow(e);\n });\n this.pane.bind('sameViewRequested', function () {\n drawer.hide();\n });\n userEvents = this.userEvents = new kendo.UserEvents(pane.element, {\n fastTap: true,\n filter: roleSelector('view splitview'),\n allowSelection: true\n });\n } else {\n this.currentView = NULL_VIEW;\n var container = $(this.options.container);\n if (!container) {\n throw new Error('The drawer needs a container configuration option set.');\n }\n userEvents = this.userEvents = new kendo.UserEvents(container, {\n fastTap: true,\n allowSelection: true\n });\n this._attachTransition(container);\n }\n var drawer = this;\n var hide = function (e) {\n if (drawer.visible) {\n drawer.hide();\n e.preventDefault();\n }\n };\n if (this.options.swipeToOpen && SWIPE_TO_OPEN) {\n userEvents.bind('press', function () {\n drawer.transition.cancel();\n });\n userEvents.bind('start', function (e) {\n drawer._start(e);\n });\n userEvents.bind('move', function (e) {\n drawer._update(e);\n });\n userEvents.bind('end', function (e) {\n drawer._end(e);\n });\n userEvents.bind('tap', hide);\n } else {\n userEvents.bind('press', hide);\n }\n this.leftPositioned = this.options.position === 'left';\n this.visible = false;\n this.element.hide().addClass('km-drawer').addClass(this.leftPositioned ? 'km-left-drawer' : 'km-right-drawer');\n this.trigger(INIT);\n },\n options: {\n name: 'Drawer',\n position: 'left',\n views: [],\n swipeToOpenViews: [],\n swipeToOpen: true,\n title: '',\n container: null\n },\n events: [\n BEFORE_SHOW,\n HIDE,\n AFTER_HIDE,\n INIT,\n SHOW\n ],\n show: function () {\n if (this._activate()) {\n this._show();\n }\n },\n hide: function () {\n if (!this.currentView) {\n return;\n }\n this.currentView.enable();\n Drawer.current = null;\n this._moveViewTo(0);\n this.trigger(HIDE, { view: this });\n },\n openFor: function () {\n if (this.visible) {\n this.hide();\n } else {\n this.show();\n }\n },\n destroy: function () {\n ui.View.fn.destroy.call(this);\n this.userEvents.destroy();\n },\n _activate: function () {\n if (this.visible) {\n return true;\n }\n var visibleOnCurrentView = this._currentViewIncludedIn(this.options.views);\n if (!visibleOnCurrentView || this.trigger(BEFORE_SHOW, { view: this })) {\n return false;\n }\n this._setAsCurrent();\n this.element.show();\n this.trigger(SHOW, { view: this });\n this._invokeNgController();\n return true;\n },\n _currentViewIncludedIn: function (views) {\n if (!this.pane || !views.length) {\n return true;\n }\n var view = this.pane.view();\n return $.inArray(view.id.replace('#', ''), views) > -1 || $.inArray(view.element.attr('id'), views) > -1;\n },\n _show: function () {\n this.currentView.enable(false);\n this.visible = true;\n var offset = this.element.width();\n if (!this.leftPositioned) {\n offset = -offset;\n }\n this._moveViewTo(offset);\n },\n _setAsCurrent: function () {\n if (Drawer.last !== this) {\n if (Drawer.last) {\n Drawer.last.element.hide();\n }\n this.element.show();\n }\n Drawer.last = this;\n Drawer.current = this;\n },\n _moveViewTo: function (offset) {\n this.userEvents.cancel();\n this.transition.moveTo({\n location: offset,\n duration: 400,\n ease: Transition.easeOutExpo\n });\n },\n _viewShow: function (e) {\n if (this.currentView) {\n this.currentView.enable();\n }\n if (this.currentView === e.view) {\n this.hide();\n return;\n }\n this.currentView = e.view;\n this._attachTransition(e.view.element);\n },\n _attachTransition: function (element) {\n var that = this, movable = this.movable, currentOffset = movable && movable.x;\n if (this.transition) {\n this.transition.cancel();\n this.movable.moveAxis('x', 0);\n }\n movable = this.movable = new kendo.ui.Movable(element);\n this.transition = new Transition({\n axis: AXIS,\n movable: this.movable,\n onEnd: function () {\n if (movable[AXIS] === 0) {\n element[0].style.cssText = '';\n that.element.hide();\n that.trigger(AFTER_HIDE);\n that.visible = false;\n }\n }\n });\n if (currentOffset) {\n element.addClass('k-fx-hidden');\n kendo.animationFrame(function () {\n element.removeClass('k-fx-hidden');\n that.movable.moveAxis(AXIS, currentOffset);\n that.hide();\n });\n }\n },\n _start: function (e) {\n var userEvents = e.sender;\n if (Math.abs(e.x.velocity) < Math.abs(e.y.velocity) || kendo.triggeredByInput(e.event) || !this._currentViewIncludedIn(this.options.swipeToOpenViews)) {\n userEvents.cancel();\n return;\n }\n var leftPositioned = this.leftPositioned, visible = this.visible, canMoveLeft = leftPositioned && visible || !leftPositioned && !Drawer.current, canMoveRight = !leftPositioned && visible || leftPositioned && !Drawer.current, leftSwipe = e.x.velocity < 0;\n if (canMoveLeft && leftSwipe || canMoveRight && !leftSwipe) {\n if (this._activate()) {\n userEvents.capture();\n return;\n }\n }\n userEvents.cancel();\n },\n _update: function (e) {\n var movable = this.movable, newPosition = movable.x + e.x.delta, limitedPosition;\n if (this.leftPositioned) {\n limitedPosition = Math.min(Math.max(0, newPosition), this.element.width());\n } else {\n limitedPosition = Math.max(Math.min(0, newPosition), -this.element.width());\n }\n this.movable.moveAxis(AXIS, limitedPosition);\n e.event.preventDefault();\n e.event.stopPropagation();\n },\n _end: function (e) {\n var velocity = e.x.velocity, pastHalf = Math.abs(this.movable.x) > this.element.width() / 2, velocityThreshold = 0.8, shouldShow;\n if (this.leftPositioned) {\n shouldShow = velocity > -velocityThreshold && (velocity > velocityThreshold || pastHalf);\n } else {\n shouldShow = velocity < velocityThreshold && (velocity < -velocityThreshold || pastHalf);\n }\n if (shouldShow) {\n this._show();\n } else {\n this.hide();\n }\n }\n });\n ui.plugin(Drawer);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.splitview', ['kendo.mobile.pane'], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.splitview',\n name: 'SplitView',\n category: 'mobile',\n description: 'The mobile SplitView is a tablet-specific view that consists of two or more mobile Pane widgets.',\n depends: ['mobile.pane']\n };\n (function ($, undefined) {\n var kendo = window.kendo, ui = kendo.mobile.ui, Widget = ui.Widget, EXPANED_PANE_SHIM = '
    ', View = ui.View;\n var SplitView = View.extend({\n init: function (element, options) {\n var that = this, pane, modalViews;\n Widget.fn.init.call(that, element, options);\n element = that.element;\n $.extend(that, options);\n that._id();\n if (!that.options.$angular) {\n that._layout();\n that._overlay();\n } else {\n that._overlay();\n }\n that._style();\n modalViews = element.children(that._locate('modalview'));\n if (!that.options.$angular) {\n kendo.mobile.init(modalViews);\n } else {\n modalViews.each(function (idx, element) {\n kendo.compileMobileDirective($(element), options.$angular[0]);\n });\n }\n that.panes = [];\n that._paramsHistory = [];\n if (!that.options.$angular) {\n that.content.children(kendo.roleSelector('pane')).each(function () {\n pane = kendo.initWidget(this, {}, ui.roles);\n that.panes.push(pane);\n });\n } else {\n that.element.children(kendo.directiveSelector('pane')).each(function () {\n pane = kendo.compileMobileDirective($(this), options.$angular[0]);\n that.panes.push(pane);\n });\n that.element.children(kendo.directiveSelector('header footer')).each(function () {\n kendo.compileMobileDirective($(this), options.$angular[0]);\n });\n }\n that.expandedPaneShim = $(EXPANED_PANE_SHIM).appendTo(that.element);\n that._shimUserEvents = new kendo.UserEvents(that.expandedPaneShim, {\n fastTap: true,\n tap: function () {\n that.collapsePanes();\n }\n });\n },\n _locate: function (selectors) {\n return this.options.$angular ? kendo.directiveSelector(selectors) : kendo.roleSelector(selectors);\n },\n options: {\n name: 'SplitView',\n style: 'horizontal'\n },\n expandPanes: function () {\n this.element.addClass('km-expanded-splitview');\n },\n collapsePanes: function () {\n this.element.removeClass('km-expanded-splitview');\n },\n _layout: function () {\n var that = this, element = that.element;\n that.transition = kendo.attrValue(element, 'transition');\n kendo.mobile.ui.View.prototype._layout.call(this);\n kendo.mobile.init(this.header.add(this.footer));\n that.element.addClass('km-splitview');\n that.content.addClass('km-split-content');\n },\n _style: function () {\n var style = this.options.style, element = this.element, styles;\n if (style) {\n styles = style.split(' ');\n $.each(styles, function () {\n element.addClass('km-split-' + this);\n });\n }\n },\n showStart: function () {\n var that = this;\n that.element.css('display', '');\n if (!that.inited) {\n that.inited = true;\n $.each(that.panes, function () {\n if (this.options.initial) {\n this.navigateToInitial();\n } else {\n this.navigate('');\n }\n });\n that.trigger('init', { view: that });\n } else {\n this._invokeNgController();\n }\n that.trigger('show', { view: that });\n }\n });\n ui.plugin(SplitView);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.application', [\n 'kendo.mobile.pane',\n 'kendo.router'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.application',\n name: 'Application',\n category: 'mobile',\n description: 'The Mobile application provides a framework to build native looking web applications on mobile devices.',\n depends: [\n 'mobile.pane',\n 'router'\n ]\n };\n (function ($, undefined) {\n var kendo = window.kendo, mobile = kendo.mobile, support = kendo.support, Widget = mobile.ui.Widget, Pane = mobile.ui.Pane, DEFAULT_OS = 'ios7', OS = support.mobileOS, BERRYPHONEGAP = OS.device == 'blackberry' && OS.flatVersion >= 600 && OS.flatVersion < 1000 && OS.appMode, FONT_SIZE_COEF = 0.93, VERTICAL = 'km-vertical', CHROME = OS.browser === 'chrome', BROKEN_WEBVIEW_RESIZE = OS.ios && OS.flatVersion >= 700 && OS.flatVersion < 800 && (OS.appMode || CHROME), INITIALLY_HORIZONTAL = Math.abs(window.orientation) / 90 == 1, HORIZONTAL = 'km-horizontal', MOBILE_PLATFORMS = {\n ios7: {\n ios: true,\n browser: 'default',\n device: 'iphone',\n flatVersion: '700',\n majorVersion: '7',\n minorVersion: '0.0',\n name: 'ios',\n tablet: false\n },\n ios: {\n ios: true,\n browser: 'default',\n device: 'iphone',\n flatVersion: '612',\n majorVersion: '6',\n minorVersion: '1.2',\n name: 'ios',\n tablet: false\n },\n android: {\n android: true,\n browser: 'default',\n device: 'android',\n flatVersion: '442',\n majorVersion: '4',\n minorVersion: '4.2',\n name: 'android',\n tablet: false\n },\n blackberry: {\n blackberry: true,\n browser: 'default',\n device: 'blackberry',\n flatVersion: '710',\n majorVersion: '7',\n minorVersion: '1.0',\n name: 'blackberry',\n tablet: false\n },\n meego: {\n meego: true,\n browser: 'default',\n device: 'meego',\n flatVersion: '850',\n majorVersion: '8',\n minorVersion: '5.0',\n name: 'meego',\n tablet: false\n },\n wp: {\n wp: true,\n browser: 'default',\n device: 'wp',\n flatVersion: '800',\n majorVersion: '8',\n minorVersion: '0.0',\n name: 'wp',\n tablet: false\n }\n }, viewportTemplate = kendo.template('', { usedWithBlock: false }), systemMeta = kendo.template(' ' + ' ' + ' ', { usedWithBlock: false }), clipTemplate = kendo.template('', { usedWithBlock: false }), ENABLE_CLIP = OS.android && OS.browser != 'chrome' || OS.blackberry, iconMeta = kendo.template('', { usedWithBlock: false }), HIDEBAR = (OS.device == 'iphone' || OS.device == 'ipod') && OS.majorVersion < 7, SUPPORT_SWIPE_TO_GO_BACK = (OS.device == 'iphone' || OS.device == 'ipod') && OS.majorVersion >= 7, HISTORY_TRANSITION = SUPPORT_SWIPE_TO_GO_BACK ? 'none' : null, BARCOMPENSATION = OS.browser == 'mobilesafari' ? 60 : 0, STATUS_BAR_HEIGHT = 20, WINDOW = $(window), SCREEN = window.screen, HEAD = $('head'), INIT = 'init', proxy = $.proxy;\n function osCssClass(os, options) {\n var classes = [];\n if (OS) {\n classes.push('km-on-' + OS.name);\n }\n if (os.skin) {\n classes.push('km-' + os.skin);\n } else {\n if (os.name == 'ios' && os.majorVersion > 6) {\n classes.push('km-ios7');\n } else {\n classes.push('km-' + os.name);\n }\n }\n if (os.name == 'ios' && os.majorVersion < 7 || os.name != 'ios') {\n classes.push('km-' + os.name + os.majorVersion);\n }\n classes.push('km-' + os.majorVersion);\n classes.push('km-m' + (os.minorVersion ? os.minorVersion[0] : 0));\n if (os.variant && (os.skin && os.skin === os.name || !os.skin || os.setDefaultPlatform === false)) {\n classes.push('km-' + (os.skin ? os.skin : os.name) + '-' + os.variant);\n }\n if (os.cordova) {\n classes.push('km-cordova');\n }\n if (os.appMode) {\n classes.push('km-app');\n } else {\n classes.push('km-web');\n }\n if (options && options.statusBarStyle) {\n classes.push('km-' + options.statusBarStyle + '-status-bar');\n }\n return classes.join(' ');\n }\n function wp8Background(os) {\n return 'km-wp-' + (os.noVariantSet ? parseInt($('
    ').css('background-color').split(',')[1], 10) === 0 ? 'dark' : 'light' : os.variant + ' km-wp-' + os.variant + '-force');\n }\n function isOrientationHorizontal(element) {\n return OS.wp ? element.css('animation-name') == '-kendo-landscape' : Math.abs(window.orientation) / 90 == 1;\n }\n function getOrientationClass(element) {\n return isOrientationHorizontal(element) ? HORIZONTAL : VERTICAL;\n }\n function setMinimumHeight(pane) {\n pane.parent().addBack().css('min-height', window.innerHeight);\n }\n function applyViewportHeight() {\n $('meta[name=viewport]').remove();\n HEAD.append(viewportTemplate({ height: ', width=device-width' + (isOrientationHorizontal() ? ', height=' + window.innerHeight + 'px' : support.mobileOS.flatVersion >= 600 && support.mobileOS.flatVersion < 700 ? ', height=' + window.innerWidth + 'px' : ', height=device-height') }));\n }\n var Application = Widget.extend({\n init: function (element, options) {\n mobile.application = this;\n $($.proxy(this, 'bootstrap', element, options));\n },\n bootstrap: function (element, options) {\n element = $(element);\n if (!element[0]) {\n element = $(document.body);\n }\n Widget.fn.init.call(this, element, options);\n this.element.removeAttr('data-' + kendo.ns + 'role');\n this._setupPlatform();\n this._attachMeta();\n this._setupElementClass();\n this._attachHideBarHandlers();\n var paneOptions = $.extend({}, this.options);\n delete paneOptions.name;\n var that = this, startHistory = function () {\n that.pane = new Pane(that.element, paneOptions);\n that.pane.navigateToInitial();\n if (that.options.updateDocumentTitle) {\n that._setupDocumentTitle();\n }\n that._startHistory();\n that.trigger(INIT);\n };\n if (this.options.$angular) {\n setTimeout(startHistory);\n } else {\n startHistory();\n }\n },\n options: {\n name: 'Application',\n hideAddressBar: true,\n browserHistory: true,\n historyTransition: HISTORY_TRANSITION,\n modelScope: window,\n statusBarStyle: 'black',\n transition: '',\n retina: false,\n platform: null,\n skin: null,\n updateDocumentTitle: true,\n useNativeScrolling: false\n },\n events: [INIT],\n navigate: function (url, transition) {\n this.pane.navigate(url, transition);\n },\n replace: function (url, transition) {\n this.pane.replace(url, transition);\n },\n scroller: function () {\n return this.view().scroller;\n },\n hideLoading: function () {\n if (this.pane) {\n this.pane.hideLoading();\n } else {\n throw new Error('The mobile application instance is not fully instantiated. Please consider activating loading in the application init event handler.');\n }\n },\n showLoading: function () {\n if (this.pane) {\n this.pane.showLoading();\n } else {\n throw new Error('The mobile application instance is not fully instantiated. Please consider activating loading in the application init event handler.');\n }\n },\n changeLoadingMessage: function (message) {\n if (this.pane) {\n this.pane.changeLoadingMessage(message);\n } else {\n throw new Error('The mobile application instance is not fully instantiated. Please consider changing the message in the application init event handler.');\n }\n },\n view: function () {\n return this.pane.view();\n },\n skin: function (skin) {\n var that = this;\n if (!arguments.length) {\n return that.options.skin;\n }\n that.options.skin = skin || '';\n that.element[0].className = 'km-pane';\n that._setupPlatform();\n that._setupElementClass();\n return that.options.skin;\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n this.pane.destroy();\n if (this.options.browserHistory) {\n this.router.destroy();\n }\n },\n _setupPlatform: function () {\n var that = this, platform = that.options.platform, skin = that.options.skin, split = [], os = OS || MOBILE_PLATFORMS[DEFAULT_OS];\n if (platform) {\n os.setDefaultPlatform = true;\n if (typeof platform === 'string') {\n split = platform.split('-');\n os = $.extend({ variant: split[1] }, os, MOBILE_PLATFORMS[split[0]]);\n } else {\n os = platform;\n }\n }\n if (skin) {\n split = skin.split('-');\n if (!OS) {\n os.setDefaultPlatform = false;\n }\n os = $.extend({}, os, {\n skin: split[0],\n variant: split[1]\n });\n }\n if (!os.variant) {\n os.noVariantSet = true;\n os.variant = 'dark';\n }\n that.os = os;\n that.osCssClass = osCssClass(that.os, that.options);\n if (os.name == 'wp') {\n if (!that.refreshBackgroundColorProxy) {\n that.refreshBackgroundColorProxy = $.proxy(function () {\n if (that.os.variant && (that.os.skin && that.os.skin === that.os.name) || !that.os.skin) {\n that.element.removeClass('km-wp-dark km-wp-light km-wp-dark-force km-wp-light-force').addClass(wp8Background(that.os));\n }\n }, that);\n }\n $(document).off('visibilitychange', that.refreshBackgroundColorProxy);\n $(document).off('resume', that.refreshBackgroundColorProxy);\n if (!os.skin) {\n that.element.parent().css('overflow', 'hidden');\n $(document).on('visibilitychange', that.refreshBackgroundColorProxy);\n $(document).on('resume', that.refreshBackgroundColorProxy);\n that.refreshBackgroundColorProxy();\n }\n }\n },\n _startHistory: function () {\n if (this.options.browserHistory) {\n this.router = new kendo.Router({\n pushState: this.options.pushState,\n root: this.options.root,\n hashBang: this.options.hashBang\n });\n this.pane.bindToRouter(this.router);\n this.router.start();\n } else {\n if (!this.options.initial) {\n this.pane.navigate('');\n }\n }\n },\n _resizeToScreenHeight: function () {\n var includeStatusBar = $('meta[name=apple-mobile-web-app-status-bar-style]').attr('content').match(/black-translucent|hidden/), element = this.element, height;\n if (CHROME) {\n height = window.innerHeight;\n } else {\n if (isOrientationHorizontal(element)) {\n if (includeStatusBar) {\n if (INITIALLY_HORIZONTAL) {\n height = SCREEN.availWidth + STATUS_BAR_HEIGHT;\n } else {\n height = SCREEN.availWidth;\n }\n } else {\n if (INITIALLY_HORIZONTAL) {\n height = SCREEN.availWidth;\n } else {\n height = SCREEN.availWidth - STATUS_BAR_HEIGHT;\n }\n }\n } else {\n if (includeStatusBar) {\n if (INITIALLY_HORIZONTAL) {\n height = SCREEN.availHeight;\n } else {\n height = SCREEN.availHeight + STATUS_BAR_HEIGHT;\n }\n } else {\n if (INITIALLY_HORIZONTAL) {\n height = SCREEN.availHeight - STATUS_BAR_HEIGHT;\n } else {\n height = SCREEN.availHeight;\n }\n }\n }\n }\n element.height(height);\n },\n _setupElementClass: function () {\n var that = this, size, element = that.element;\n element.parent().addClass('km-root km-' + (that.os.tablet ? 'tablet' : 'phone'));\n element.addClass(that.osCssClass + ' ' + getOrientationClass(element));\n if (this.options.useNativeScrolling) {\n element.parent().addClass('km-native-scrolling');\n }\n if (CHROME) {\n element.addClass('km-ios-chrome');\n }\n if (support.wpDevicePixelRatio) {\n element.parent().css('font-size', support.wpDevicePixelRatio + 'em');\n }\n if (this.options.retina) {\n element.parent().addClass('km-retina');\n element.parent().css('font-size', support.devicePixelRatio * FONT_SIZE_COEF + 'em');\n }\n if (BERRYPHONEGAP) {\n applyViewportHeight();\n }\n if (that.options.useNativeScrolling) {\n element.parent().addClass('km-native-scrolling');\n } else if (ENABLE_CLIP) {\n size = (screen.availWidth > screen.availHeight ? screen.availWidth : screen.availHeight) + 200;\n $(clipTemplate({\n width: size,\n height: size\n })).appendTo(HEAD);\n }\n if (BROKEN_WEBVIEW_RESIZE) {\n that._resizeToScreenHeight();\n }\n kendo.onResize(function () {\n element.removeClass('km-horizontal km-vertical').addClass(getOrientationClass(element));\n if (that.options.useNativeScrolling) {\n setMinimumHeight(element);\n }\n if (BROKEN_WEBVIEW_RESIZE) {\n that._resizeToScreenHeight();\n }\n if (BERRYPHONEGAP) {\n applyViewportHeight();\n }\n kendo.resize(element);\n });\n },\n _clearExistingMeta: function () {\n HEAD.find('meta').filter('[name|=\\'apple-mobile-web-app\\'],[name|=\\'msapplication-tap\\'],[name=\\'viewport\\']').remove();\n },\n _attachMeta: function () {\n var options = this.options, icon = options.icon, size;\n this._clearExistingMeta();\n if (!BERRYPHONEGAP) {\n HEAD.prepend(viewportTemplate({\n height: '',\n scale: this.options.retina ? 1 / support.devicePixelRatio : '1.0'\n }));\n }\n HEAD.prepend(systemMeta(options));\n if (icon) {\n if (typeof icon === 'string') {\n icon = { '': icon };\n }\n for (size in icon) {\n HEAD.prepend(iconMeta({\n icon: icon[size],\n size: size\n }));\n }\n }\n if (options.useNativeScrolling) {\n setMinimumHeight(this.element);\n }\n },\n _attachHideBarHandlers: function () {\n var that = this, hideBar = proxy(that, '_hideBar');\n if (support.mobileOS.appMode || !that.options.hideAddressBar || !HIDEBAR || that.options.useNativeScrolling) {\n return;\n }\n that._initialHeight = {};\n WINDOW.on('load', hideBar);\n kendo.onResize(function () {\n setTimeout(window.scrollTo, 0, 0, 1);\n });\n },\n _setupDocumentTitle: function () {\n var that = this, defaultTitle = document.title;\n that.pane.bind('viewShow', function (e) {\n var title = e.view.title;\n document.title = title !== undefined ? title : defaultTitle;\n });\n },\n _hideBar: function () {\n var that = this, element = that.element;\n element.height(kendo.support.transforms.css + 'calc(100% + ' + BARCOMPENSATION + 'px)');\n $(window).trigger(kendo.support.resize);\n }\n });\n kendo.mobile.Application = Application;\n kendo.ui.plugin(Application, kendo.mobile, 'Mobile');\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.actionsheet', [\n 'kendo.mobile.popover',\n 'kendo.mobile.shim'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.actionsheet',\n name: 'ActionSheet',\n category: 'mobile',\n description: 'The mobile ActionSheet widget displays a set of choices related to a task the user initiates.',\n depends: [\n 'mobile.popover',\n 'mobile.shim'\n ]\n };\n (function ($, undefined) {\n var kendo = window.kendo, support = kendo.support, ui = kendo.mobile.ui, Shim = ui.Shim, Popup = ui.Popup, Widget = ui.Widget, OPEN = 'open', CLOSE = 'close', COMMAND = 'command', BUTTONS = 'li>a', CONTEXT_DATA = 'actionsheetContext', WRAP = '
    ', cancelTemplate = kendo.template('
  • #:cancel#
  • ');\n var ActionSheet = Widget.extend({\n init: function (element, options) {\n var that = this, ShimClass, tablet, type, os = support.mobileOS;\n Widget.fn.init.call(that, element, options);\n options = that.options;\n type = options.type;\n element = that.element;\n if (type === 'auto') {\n tablet = os && os.tablet;\n } else {\n tablet = type === 'tablet';\n }\n ShimClass = tablet ? Popup : Shim;\n if (options.cancelTemplate) {\n cancelTemplate = kendo.template(options.cancelTemplate);\n }\n element.addClass('km-actionsheet').append(cancelTemplate({ cancel: that.options.cancel })).wrap(WRAP).on('up', BUTTONS, '_click').on('click', BUTTONS, kendo.preventDefault);\n that.view().bind('destroy', function () {\n that.destroy();\n });\n that.wrapper = element.parent().addClass(type ? ' km-actionsheet-' + type : '');\n that.shim = new ShimClass(that.wrapper, $.extend({\n modal: os.ios && os.majorVersion < 7,\n className: 'km-actionsheet-root'\n }, that.options.popup));\n that._closeProxy = $.proxy(that, '_close');\n that._shimHideProxy = $.proxy(that, '_shimHide');\n that.shim.bind('hide', that._shimHideProxy);\n if (tablet) {\n kendo.onResize(that._closeProxy);\n }\n kendo.notify(that, ui);\n },\n events: [\n OPEN,\n CLOSE,\n COMMAND\n ],\n options: {\n name: 'ActionSheet',\n cancel: 'Cancel',\n type: 'auto',\n popup: { height: 'auto' }\n },\n open: function (target, context) {\n var that = this;\n that.target = $(target);\n that.context = context;\n that.shim.show(target);\n },\n close: function () {\n this.context = this.target = null;\n this.shim.hide();\n },\n openFor: function (target) {\n var that = this, context = target.data(CONTEXT_DATA);\n that.open(target, context);\n that.trigger(OPEN, {\n target: target,\n context: context\n });\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n kendo.unbindResize(this._closeProxy);\n this.shim.destroy();\n },\n _click: function (e) {\n if (e.isDefaultPrevented()) {\n return;\n }\n var currentTarget = $(e.currentTarget);\n var action = currentTarget.data('action');\n if (action) {\n var actionData = {\n target: this.target,\n context: this.context\n }, $angular = this.options.$angular;\n if ($angular) {\n this.element.injector().get('$parse')(action)($angular[0])(actionData);\n } else {\n kendo.getter(action)(window)(actionData);\n }\n }\n this.trigger(COMMAND, {\n target: this.target,\n context: this.context,\n currentTarget: currentTarget\n });\n e.preventDefault();\n this._close();\n },\n _shimHide: function (e) {\n if (!this.trigger(CLOSE)) {\n this.context = this.target = null;\n } else {\n e.preventDefault();\n }\n },\n _close: function (e) {\n if (!this.trigger(CLOSE)) {\n this.close();\n } else {\n e.preventDefault();\n }\n }\n });\n ui.plugin(ActionSheet);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.button', ['kendo.userevents'], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.button',\n name: 'Button',\n category: 'mobile',\n description: 'The Button widget navigates between mobile Application views when pressed.',\n depends: ['userevents']\n };\n (function ($, undefined) {\n var kendo = window.kendo, mobile = kendo.mobile, ui = mobile.ui, Widget = ui.Widget, support = kendo.support, os = support.mobileOS, ANDROID3UP = os.android && os.flatVersion >= 300, CLICK = 'click', DISABLED = 'disabled', DISABLEDSTATE = 'km-state-disabled';\n function highlightButton(widget, event, highlight) {\n $(event.target).closest('.km-button,.km-detail').toggleClass('km-state-active', highlight);\n if (ANDROID3UP && widget.deactivateTimeoutID) {\n clearTimeout(widget.deactivateTimeoutID);\n widget.deactivateTimeoutID = 0;\n }\n }\n function createBadge(value) {\n return $('' + value + '');\n }\n var Button = Widget.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n var useTap = that.options.clickOn === 'up';\n that._wrap();\n that._style();\n if (!useTap) {\n that.element.attr('data-navigate-on-press', true);\n }\n that.options.enable = that.options.enable && !that.element.attr(DISABLED);\n that.enable(that.options.enable);\n that._userEvents = new kendo.UserEvents(that.element, {\n allowSelection: !useTap,\n fastTap: true,\n press: function (e) {\n that._activate(e);\n },\n release: function (e) {\n highlightButton(that, e, false);\n if (!useTap) {\n e.event.stopPropagation();\n }\n }\n });\n that._userEvents.bind(useTap ? 'tap' : 'press', function (e) {\n that._release(e);\n });\n if (ANDROID3UP) {\n that.element.on('move', function (e) {\n that._timeoutDeactivate(e);\n });\n }\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n this._userEvents.destroy();\n },\n events: [CLICK],\n options: {\n name: 'Button',\n icon: '',\n style: '',\n badge: '',\n clickOn: 'up',\n enable: true\n },\n badge: function (value) {\n var badge = this.badgeElement = this.badgeElement || createBadge(value).appendTo(this.element);\n if (value || value === 0) {\n badge.html(value);\n return this;\n }\n if (value === false) {\n badge.empty().remove();\n this.badgeElement = false;\n return this;\n }\n return badge.html();\n },\n enable: function (enable) {\n var element = this.element;\n if (typeof enable == 'undefined') {\n enable = true;\n }\n this.options.enable = enable;\n if (enable) {\n element.removeAttr(DISABLED);\n } else {\n element.attr(DISABLED, DISABLED);\n }\n element.toggleClass(DISABLEDSTATE, !enable);\n },\n _timeoutDeactivate: function (e) {\n if (!this.deactivateTimeoutID) {\n this.deactivateTimeoutID = setTimeout(highlightButton, 500, this, e, false);\n }\n },\n _activate: function (e) {\n var activeElement = document.activeElement, nodeName = activeElement ? activeElement.nodeName : '';\n if (this.options.enable) {\n highlightButton(this, e, true);\n if (nodeName == 'INPUT' || nodeName == 'TEXTAREA') {\n activeElement.blur();\n }\n }\n },\n _release: function (e) {\n var that = this;\n if (e.which > 1) {\n return;\n }\n if (!that.options.enable) {\n e.preventDefault();\n return;\n }\n if (that.trigger(CLICK, {\n target: $(e.target),\n button: that.element\n })) {\n e.preventDefault();\n }\n },\n _style: function () {\n var style = this.options.style, element = this.element, styles;\n if (style) {\n styles = style.split(' ');\n $.each(styles, function () {\n element.addClass('km-' + this);\n });\n }\n },\n _wrap: function () {\n var that = this, icon = that.options.icon, badge = that.options.badge, iconSpan = '').children('span.km-text');\n }\n if (!image[0] && icon) {\n if (!span[0]) {\n iconSpan += ' km-notext';\n }\n that.iconElement = element.prepend($(iconSpan + '\" />'));\n }\n if (badge || badge === 0) {\n that.badgeElement = createBadge(badge).appendTo(element);\n }\n }\n });\n var BackButton = Button.extend({\n options: {\n name: 'BackButton',\n style: 'back'\n },\n init: function (element, options) {\n var that = this;\n Button.fn.init.call(that, element, options);\n if (typeof that.element.attr('href') === 'undefined') {\n that.element.attr('href', '#:back');\n }\n }\n });\n var DetailButton = Button.extend({\n options: {\n name: 'DetailButton',\n style: ''\n },\n init: function (element, options) {\n Button.fn.init.call(this, element, options);\n },\n _style: function () {\n var style = this.options.style + ' detail', element = this.element;\n if (style) {\n var styles = style.split(' ');\n $.each(styles, function () {\n element.addClass('km-' + this);\n });\n }\n },\n _wrap: function () {\n var that = this, icon = that.options.icon, iconSpan = ''));\n }\n }\n });\n ui.plugin(Button);\n ui.plugin(BackButton);\n ui.plugin(DetailButton);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.buttongroup', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.buttongroup',\n name: 'ButtonGroup',\n category: 'mobile',\n description: 'The Kendo mobile ButtonGroup widget is a linear set of grouped buttons.',\n depends: ['core']\n };\n (function ($, undefined) {\n var kendo = window.kendo, ui = kendo.mobile.ui, Widget = ui.Widget, ACTIVE = 'state-active', DISABLE = 'state-disabled', SELECT = 'select', SELECTOR = 'li:not(.km-' + ACTIVE + ')';\n function className(name) {\n return 'k-' + name + ' km-' + name;\n }\n function createBadge(value) {\n return $('' + value + '');\n }\n var ButtonGroup = Widget.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n that.element.addClass('km-buttongroup k-widget k-button-group').find('li').each(that._button);\n that.element.on(that.options.selectOn, SELECTOR, '_select');\n that._enable = true;\n that.select(that.options.index);\n if (!that.options.enable) {\n that._enable = false;\n that.wrapper.addClass(className(DISABLE));\n }\n },\n events: [SELECT],\n options: {\n name: 'ButtonGroup',\n selectOn: 'down',\n index: -1,\n enable: true\n },\n current: function () {\n return this.element.find('.km-' + ACTIVE);\n },\n select: function (li) {\n var that = this, index = -1;\n if (li === undefined || li === -1 || !that._enable || $(li).is('.km-' + DISABLE)) {\n return;\n }\n that.current().removeClass(className(ACTIVE));\n if (typeof li === 'number') {\n index = li;\n li = $(that.element[0].children[li]);\n } else if (li.nodeType) {\n li = $(li);\n index = li.index();\n }\n li.addClass(className(ACTIVE));\n that.selectedIndex = index;\n },\n badge: function (item, value) {\n var buttongroup = this.element, badge;\n if (!isNaN(item)) {\n item = buttongroup.children().get(item);\n }\n item = buttongroup.find(item);\n badge = $(item.children('.km-badge')[0] || createBadge(value).appendTo(item));\n if (value || value === 0) {\n badge.html(value);\n return this;\n }\n if (value === false) {\n badge.empty().remove();\n return this;\n }\n return badge.html();\n },\n enable: function (enable) {\n if (typeof enable == 'undefined') {\n enable = true;\n }\n this.wrapper.toggleClass(className(DISABLE), !enable);\n this._enable = this.options.enable = enable;\n },\n _button: function () {\n var button = $(this).addClass(className('button')), icon = kendo.attrValue(button, 'icon'), badge = kendo.attrValue(button, 'badge'), span = button.children('span'), image = button.find('img').addClass(className('image'));\n if (!span[0]) {\n span = button.wrapInner('').children('span');\n }\n span.addClass(className('text'));\n if (!image[0] && icon) {\n button.prepend($(''));\n }\n if (badge || badge === 0) {\n createBadge(badge).appendTo(button);\n }\n },\n _select: function (e) {\n if (e.which > 1 || e.isDefaultPrevented() || !this._enable) {\n return;\n }\n this.select(e.currentTarget);\n this.trigger(SELECT, { index: this.selectedIndex });\n }\n });\n ui.plugin(ButtonGroup);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.collapsible', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.collapsible',\n name: 'Collapsible',\n category: 'mobile',\n description: 'The Kendo mobile Collapsible widget provides ability for creating collapsible blocks of content.',\n depends: [\n 'core',\n 'userevents'\n ]\n };\n (function ($, undefined) {\n var kendo = window.kendo, ui = kendo.mobile.ui, Widget = ui.Widget, COLLAPSIBLE = 'km-collapsible', HEADER = 'km-collapsible-header', CONTENT = 'km-collapsible-content', INSET = 'km-collapsibleinset', HEADER_WRAPPER = '
    ', CONTENT_WRAPPER = '
    ', COLLAPSED = 'km-collapsed', EXPANDED = 'km-expanded', ANIMATED = 'km-animated', LEFT = 'left', EXAPND = 'expand', COLLAPSE = 'collapse';\n var Collapsible = Widget.extend({\n init: function (element, options) {\n var that = this, container = $(element);\n Widget.fn.init.call(that, container, options);\n container.addClass(COLLAPSIBLE);\n that._buildHeader();\n that.content = container.children().not(that.header).wrapAll(CONTENT_WRAPPER).parent();\n that._userEvents = new kendo.UserEvents(that.header, {\n fastTap: true,\n tap: function () {\n that.toggle();\n }\n });\n container.addClass(that.options.collapsed ? COLLAPSED : EXPANDED);\n if (that.options.inset) {\n container.addClass(INSET);\n }\n if (that.options.animation) {\n that.content.addClass(ANIMATED);\n that.content.height(0);\n if (that.options.collapsed) {\n that.content.hide();\n }\n } else if (that.options.collapsed) {\n that.content.hide();\n }\n },\n events: [\n EXAPND,\n COLLAPSE\n ],\n options: {\n name: 'Collapsible',\n collapsed: true,\n collapseIcon: 'arrow-n',\n expandIcon: 'arrow-s',\n iconPosition: LEFT,\n animation: true,\n inset: false\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n this._userEvents.destroy();\n },\n expand: function (instant) {\n var icon = this.options.collapseIcon, content = this.content, ios = kendo.support.mobileOS.ios;\n if (!this.trigger(EXAPND)) {\n if (icon) {\n this.header.find('.km-icon').removeClass().addClass('km-icon km-' + icon);\n }\n this.element.removeClass(COLLAPSED).addClass(EXPANDED);\n if (this.options.animation && !instant) {\n content.off('transitionend');\n content.show();\n if (ios) {\n content.removeClass(ANIMATED);\n }\n content.height(this._getContentHeight());\n if (ios) {\n content.addClass(ANIMATED);\n }\n kendo.resize(content);\n } else {\n content.show();\n }\n }\n },\n collapse: function (instant) {\n var icon = this.options.expandIcon, content = this.content;\n if (!this.trigger(COLLAPSE)) {\n if (icon) {\n this.header.find('.km-icon').removeClass().addClass('km-icon km-' + icon);\n }\n this.element.removeClass(EXPANDED).addClass(COLLAPSED);\n if (this.options.animation && !instant) {\n content.one('transitionend', function () {\n content.hide();\n });\n content.height(0);\n } else {\n content.hide();\n }\n }\n },\n toggle: function (instant) {\n if (this.isCollapsed()) {\n this.expand(instant);\n } else {\n this.collapse(instant);\n }\n },\n isCollapsed: function () {\n return this.element.hasClass(COLLAPSED);\n },\n resize: function () {\n if (!this.isCollapsed() && this.options.animation) {\n this.content.height(this._getContentHeight());\n }\n },\n _buildHeader: function () {\n var header = this.element.children(':header').wrapAll(HEADER_WRAPPER), iconSpan = $(''), icon = this.options.collapsed ? this.options.expandIcon : this.options.collapseIcon, iconPosition = this.options.iconPosition;\n if (icon) {\n header.prepend(iconSpan);\n iconSpan.addClass('km-' + icon);\n }\n this.header = header.parent();\n this.header.addClass('km-icon-' + iconPosition);\n },\n _getContentHeight: function () {\n var style = this.content.attr('style'), height;\n this.content.css({\n position: 'absolute',\n visibility: 'hidden',\n height: 'auto'\n });\n height = this.content.height();\n this.content.attr('style', style ? style : '');\n return height;\n }\n });\n ui.plugin(Collapsible);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.listview', [\n 'kendo.data',\n 'kendo.userevents',\n 'kendo.mobile.button'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.listview',\n name: 'ListView',\n category: 'mobile',\n description: 'The Kendo Mobile ListView widget is used to display flat or grouped list of items.',\n depends: [\n 'data',\n 'userevents',\n 'mobile.button'\n ]\n };\n (function ($, undefined) {\n var kendo = window.kendo, Node = window.Node, mobile = kendo.mobile, ui = mobile.ui, outerHeight = kendo._outerHeight, DataSource = kendo.data.DataSource, Widget = ui.DataBoundWidget, ITEM_SELECTOR = '.km-list > li, > li:not(.km-group-container)', HIGHLIGHT_SELECTOR = '.km-listview-link, .km-listview-label', ICON_SELECTOR = '[' + kendo.attr('icon') + ']', proxy = $.proxy, attrValue = kendo.attrValue, GROUP_CLASS = 'km-group-title', ACTIVE_CLASS = 'km-state-active', GROUP_WRAPPER = '
    ', GROUP_TEMPLATE = kendo.template('
  • #= this.headerTemplate(data) #
      #= kendo.render(this.template, data.items)#
  • '), WRAPPER = '
    ', SEARCH_TEMPLATE = kendo.template(''), NS = '.kendoMobileListView', STYLED = 'styled', DATABOUND = 'dataBound', DATABINDING = 'dataBinding', ITEM_CHANGE = 'itemChange', CLICK = 'click', CHANGE = 'change', PROGRESS = 'progress', FUNCTION = 'function', whitespaceRegExp = /^\\s+$/, buttonRegExp = /button/;\n function whitespace() {\n return this.nodeType === Node.TEXT_NODE && this.nodeValue.match(whitespaceRegExp);\n }\n function addIcon(item, icon) {\n if (icon && !item[0].querySelector('.km-icon')) {\n item.prepend('');\n }\n }\n function enhanceItem(item) {\n addIcon(item, attrValue(item, 'icon'));\n addIcon(item, attrValue(item.children(ICON_SELECTOR), 'icon'));\n }\n function enhanceLinkItem(item) {\n var parent = item.parent(), itemAndDetailButtons = item.add(parent.children(kendo.roleSelector('detailbutton'))), otherNodes = parent.contents().not(itemAndDetailButtons).not(whitespace);\n if (otherNodes.length) {\n return;\n }\n item.addClass('km-listview-link').attr(kendo.attr('role'), 'listview-link');\n addIcon(item, attrValue(parent, 'icon'));\n addIcon(item, attrValue(item, 'icon'));\n }\n function enhanceCheckBoxItem(label) {\n if (!label[0].querySelector('input[type=checkbox],input[type=radio]')) {\n return;\n }\n var item = label.parent();\n if (item.contents().not(label).not(function () {\n return this.nodeType == 3;\n })[0]) {\n return;\n }\n label.addClass('km-listview-label');\n label.children('[type=checkbox],[type=radio]').addClass('km-widget km-icon km-check');\n }\n function putAt(element, top) {\n $(element).css('transform', 'translate3d(0px, ' + top + 'px, 0px)');\n }\n var HeaderFixer = kendo.Class.extend({\n init: function (listView) {\n var scroller = listView.scroller();\n if (!scroller) {\n return;\n }\n this.options = listView.options;\n this.element = listView.element;\n this.scroller = listView.scroller();\n this._shouldFixHeaders();\n var headerFixer = this;\n var cacheHeaders = function () {\n headerFixer._cacheHeaders();\n };\n listView.bind('resize', cacheHeaders);\n listView.bind(STYLED, cacheHeaders);\n listView.bind(DATABOUND, cacheHeaders);\n this._scrollHandler = function (e) {\n headerFixer._fixHeader(e);\n };\n scroller.bind('scroll', this._scrollHandler);\n },\n destroy: function () {\n var that = this;\n if (that.scroller) {\n that.scroller.unbind('scroll', that._scrollHandler);\n }\n },\n _fixHeader: function (e) {\n if (!this.fixedHeaders) {\n return;\n }\n var i = 0, scroller = this.scroller, headers = this.headers, scrollTop = e.scrollTop, headerPair, offset, header;\n do {\n headerPair = headers[i++];\n if (!headerPair) {\n header = $('
    ');\n break;\n }\n offset = headerPair.offset;\n header = headerPair.header;\n } while (offset + 1 > scrollTop);\n if (this.currentHeader != i) {\n scroller.fixedContainer.html(header.clone());\n this.currentHeader = i;\n }\n },\n _shouldFixHeaders: function () {\n this.fixedHeaders = this.options.type === 'group' && this.options.fixedHeaders;\n },\n _cacheHeaders: function () {\n this._shouldFixHeaders();\n if (!this.fixedHeaders) {\n return;\n }\n var headers = [], offset = this.scroller.scrollTop;\n this.element.find('.' + GROUP_CLASS).each(function (_, header) {\n header = $(header);\n headers.unshift({\n offset: header.position().top + offset,\n header: header\n });\n });\n this.headers = headers;\n this._fixHeader({ scrollTop: offset });\n }\n });\n var DEFAULT_PULL_PARAMETERS = function () {\n return { page: 1 };\n };\n var RefreshHandler = kendo.Class.extend({\n init: function (listView) {\n var handler = this, options = listView.options, scroller = listView.scroller(), pullParameters = options.pullParameters || DEFAULT_PULL_PARAMETERS;\n this.listView = listView;\n this.scroller = scroller;\n listView.bind('_dataSource', function (e) {\n handler.setDataSource(e.dataSource);\n });\n scroller.setOptions({\n pullToRefresh: true,\n pull: function () {\n if (!handler._pulled) {\n handler._pulled = true;\n handler.dataSource.read(pullParameters.call(listView, handler._first));\n }\n },\n messages: {\n pullTemplate: options.messages.pullTemplate,\n releaseTemplate: options.messages.releaseTemplate,\n refreshTemplate: options.messages.refreshTemplate\n }\n });\n },\n setDataSource: function (dataSource) {\n var handler = this;\n this._first = dataSource.view()[0];\n this.dataSource = dataSource;\n dataSource.bind('change', function () {\n handler._change();\n });\n dataSource.bind('error', function () {\n handler._change();\n });\n },\n _change: function () {\n var scroller = this.scroller, dataSource = this.dataSource;\n if (this._pulled) {\n scroller.pullHandled();\n }\n if (this._pulled || !this._first) {\n var view = dataSource.view();\n if (view[0]) {\n this._first = view[0];\n }\n }\n this._pulled = false;\n }\n });\n var VirtualList = kendo.Observable.extend({\n init: function (options) {\n var list = this;\n kendo.Observable.fn.init.call(list);\n list.buffer = options.buffer;\n list.height = options.height;\n list.item = options.item;\n list.items = [];\n list.footer = options.footer;\n list.buffer.bind('reset', function () {\n list.refresh();\n });\n },\n refresh: function () {\n var buffer = this.buffer, items = this.items, endReached = false;\n while (items.length) {\n items.pop().destroy();\n }\n this.offset = buffer.offset;\n var itemConstructor = this.item, prevItem, item;\n for (var idx = 0; idx < buffer.viewSize; idx++) {\n if (idx === buffer.total()) {\n endReached = true;\n break;\n }\n item = itemConstructor(this.content(this.offset + items.length));\n item.below(prevItem);\n prevItem = item;\n items.push(item);\n }\n this.itemCount = items.length;\n this.trigger('reset');\n this._resize();\n if (endReached) {\n this.trigger('endReached');\n }\n },\n totalHeight: function () {\n if (!this.items[0]) {\n return 0;\n }\n var list = this, items = list.items, top = items[0].top, bottom = items[items.length - 1].bottom, averageItemHeight = (bottom - top) / list.itemCount, remainingItemsCount = list.buffer.length - list.offset - list.itemCount;\n return (this.footer ? this.footer.height : 0) + bottom + remainingItemsCount * averageItemHeight;\n },\n batchUpdate: function (top) {\n var height = this.height(), items = this.items, item, initialOffset = this.offset;\n if (!items[0]) {\n return;\n }\n if (this.lastDirection) {\n while (items[items.length - 1].bottom > top + height * 2) {\n if (this.offset === 0) {\n break;\n }\n this.offset--;\n item = items.pop();\n item.update(this.content(this.offset));\n item.above(items[0]);\n items.unshift(item);\n }\n } else {\n while (items[0].top < top - height) {\n var nextIndex = this.offset + this.itemCount;\n if (nextIndex === this.buffer.total()) {\n this.trigger('endReached');\n break;\n }\n if (nextIndex === this.buffer.length) {\n break;\n }\n item = items.shift();\n item.update(this.content(this.offset + this.itemCount));\n item.below(items[items.length - 1]);\n items.push(item);\n this.offset++;\n }\n }\n if (initialOffset !== this.offset) {\n this._resize();\n }\n },\n update: function (top) {\n var list = this, items = this.items, item, firstItem, lastItem, height = this.height(), itemCount = this.itemCount, padding = height / 2, up = (this.lastTop || 0) > top, topBorder = top - padding, bottomBorder = top + height + padding;\n if (!items[0]) {\n return;\n }\n this.lastTop = top;\n this.lastDirection = up;\n if (up) {\n if (items[0].top > topBorder && items[items.length - 1].bottom > bottomBorder + padding && this.offset > 0) {\n this.offset--;\n item = items.pop();\n firstItem = items[0];\n item.update(this.content(this.offset));\n items.unshift(item);\n item.above(firstItem);\n list._resize();\n }\n } else {\n if (items[items.length - 1].bottom < bottomBorder && items[0].top < topBorder - padding) {\n var nextIndex = this.offset + itemCount;\n if (nextIndex === this.buffer.total()) {\n this.trigger('endReached');\n } else if (nextIndex !== this.buffer.length) {\n item = items.shift();\n lastItem = items[items.length - 1];\n items.push(item);\n item.update(this.content(this.offset + this.itemCount));\n list.offset++;\n item.below(lastItem);\n list._resize();\n }\n }\n }\n },\n content: function (index) {\n return this.buffer.at(index);\n },\n destroy: function () {\n this.unbind();\n },\n _resize: function () {\n var items = this.items, top = 0, bottom = 0, firstItem = items[0], lastItem = items[items.length - 1];\n if (firstItem) {\n top = firstItem.top;\n bottom = lastItem.bottom;\n }\n this.trigger('resize', {\n top: top,\n bottom: bottom\n });\n if (this.footer) {\n this.footer.below(lastItem);\n }\n }\n });\n kendo.mobile.ui.VirtualList = VirtualList;\n var VirtualListViewItem = kendo.Class.extend({\n init: function (listView, dataItem) {\n var element = listView.append([dataItem], true)[0], height = element.offsetHeight;\n $.extend(this, {\n top: 0,\n element: element,\n listView: listView,\n height: height,\n bottom: height\n });\n },\n update: function (dataItem) {\n this.element = this.listView.setDataItem(this.element, dataItem);\n },\n above: function (item) {\n if (item) {\n this.height = this.element.offsetHeight;\n this.top = item.top - this.height;\n this.bottom = item.top;\n putAt(this.element, this.top);\n }\n },\n below: function (item) {\n if (item) {\n this.height = this.element.offsetHeight;\n this.top = item.bottom;\n this.bottom = this.top + this.height;\n putAt(this.element, this.top);\n }\n },\n destroy: function () {\n kendo.destroy(this.element);\n $(this.element).remove();\n }\n });\n var LOAD_ICON = '
    ';\n var VirtualListViewLoadingIndicator = kendo.Class.extend({\n init: function (listView) {\n this.element = $('
  • ').appendTo(listView.element);\n this._loadIcon = $(LOAD_ICON).appendTo(this.element);\n },\n enable: function () {\n this.element.show();\n this.height = outerHeight(this.element, true);\n },\n disable: function () {\n this.element.hide();\n this.height = 0;\n },\n below: function (item) {\n if (item) {\n this.top = item.bottom;\n this.bottom = this.height + this.top;\n putAt(this.element, this.top);\n }\n }\n });\n var VirtualListViewPressToLoadMore = VirtualListViewLoadingIndicator.extend({\n init: function (listView, buffer) {\n this._loadIcon = $(LOAD_ICON).hide();\n this._loadButton = $('' + listView.options.messages.loadMoreText + '').hide();\n this.element = $('
  • ').append(this._loadIcon).append(this._loadButton).appendTo(listView.element);\n var loadMore = this;\n this._loadButton.kendoMobileButton().data('kendoMobileButton').bind('click', function () {\n loadMore._hideShowButton();\n buffer.next();\n });\n buffer.bind('resize', function () {\n loadMore._showLoadButton();\n });\n this.height = outerHeight(this.element, true);\n this.disable();\n },\n _hideShowButton: function () {\n this._loadButton.hide();\n this.element.addClass('km-scroller-refresh');\n this._loadIcon.css('display', 'block');\n },\n _showLoadButton: function () {\n this._loadButton.show();\n this.element.removeClass('km-scroller-refresh');\n this._loadIcon.hide();\n }\n });\n var VirtualListViewItemBinder = kendo.Class.extend({\n init: function (listView) {\n var binder = this;\n this.chromeHeight = outerHeight(listView.wrapper.children().not(listView.element));\n this.listView = listView;\n this.scroller = listView.scroller();\n this.options = listView.options;\n listView.bind('_dataSource', function (e) {\n binder.setDataSource(e.dataSource, e.empty);\n });\n listView.bind('resize', function () {\n if (!binder.list.items.length) {\n return;\n }\n binder.scroller.reset();\n binder.buffer.range(0);\n binder.list.refresh();\n });\n this.scroller.makeVirtual();\n this._scroll = function (e) {\n binder.list.update(e.scrollTop);\n };\n this.scroller.bind('scroll', this._scroll);\n this._scrollEnd = function (e) {\n binder.list.batchUpdate(e.scrollTop);\n };\n this.scroller.bind('scrollEnd', this._scrollEnd);\n },\n destroy: function () {\n this.list.unbind();\n this.buffer.unbind();\n this.scroller.unbind('scroll', this._scroll);\n this.scroller.unbind('scrollEnd', this._scrollEnd);\n },\n setDataSource: function (dataSource, empty) {\n var binder = this, options = this.options, listView = this.listView, scroller = listView.scroller(), pressToLoadMore = options.loadMore, pageSize, buffer, footer;\n this.dataSource = dataSource;\n pageSize = dataSource.pageSize() || options.virtualViewSize;\n if (!pageSize && !empty) {\n throw new Error('the DataSource does not have page size configured. Page Size setting is mandatory for the mobile listview virtual scrolling to work as expected.');\n }\n if (this.buffer) {\n this.buffer.destroy();\n }\n buffer = new kendo.data.Buffer(dataSource, Math.floor(pageSize / 2), pressToLoadMore);\n if (pressToLoadMore) {\n footer = new VirtualListViewPressToLoadMore(listView, buffer);\n } else {\n footer = new VirtualListViewLoadingIndicator(listView);\n }\n if (this.list) {\n this.list.destroy();\n }\n var list = new VirtualList({\n buffer: buffer,\n footer: footer,\n item: function (dataItem) {\n return new VirtualListViewItem(listView, dataItem);\n },\n height: function () {\n return scroller.height();\n }\n });\n list.bind('resize', function () {\n binder.updateScrollerSize();\n listView.updateSize();\n });\n list.bind('reset', function () {\n binder.footer.enable();\n });\n list.bind('endReached', function () {\n footer.disable();\n binder.updateScrollerSize();\n });\n buffer.bind('expand', function () {\n list.lastDirection = false;\n list.batchUpdate(scroller.scrollTop);\n });\n $.extend(this, {\n buffer: buffer,\n scroller: scroller,\n list: list,\n footer: footer\n });\n },\n updateScrollerSize: function () {\n this.scroller.virtualSize(0, this.list.totalHeight() + this.chromeHeight);\n },\n refresh: function () {\n this.list.refresh();\n },\n reset: function () {\n this.buffer.range(0);\n this.list.refresh();\n }\n });\n var ListViewItemBinder = kendo.Class.extend({\n init: function (listView) {\n var binder = this;\n this.listView = listView;\n this.options = listView.options;\n var itemBinder = this;\n this._refreshHandler = function (e) {\n itemBinder.refresh(e);\n };\n this._progressHandler = function () {\n listView.showLoading();\n };\n listView.bind('_dataSource', function (e) {\n binder.setDataSource(e.dataSource);\n });\n },\n destroy: function () {\n this._unbindDataSource();\n },\n reset: function () {\n },\n refresh: function (e) {\n var action = e && e.action, dataItems = e && e.items, listView = this.listView, dataSource = this.dataSource, prependOnRefresh = this.options.appendOnRefresh, view = dataSource.view(), groups = dataSource.group(), groupedMode = groups && groups[0], item;\n if (action === 'itemchange') {\n if (!listView._hasBindingTarget()) {\n item = listView.findByDataItem(dataItems)[0];\n if (item) {\n listView.setDataItem(item, dataItems[0]);\n }\n }\n return;\n }\n var removedItems, addedItems, addedDataItems;\n var adding = action === 'add' && !groupedMode || prependOnRefresh && !listView._filter;\n var removing = action === 'remove' && !groupedMode;\n if (adding) {\n removedItems = [];\n } else if (removing) {\n removedItems = listView.findByDataItem(dataItems);\n }\n if (listView.trigger(DATABINDING, {\n action: action || 'rebind',\n items: dataItems,\n removedItems: removedItems,\n index: e && e.index\n })) {\n if (this._shouldShowLoading()) {\n listView.hideLoading();\n }\n return;\n }\n if (action === 'add' && !groupedMode) {\n var index = view.indexOf(dataItems[0]);\n if (index > -1) {\n addedItems = listView.insertAt(dataItems, index);\n addedDataItems = dataItems;\n }\n } else if (action === 'remove' && !groupedMode) {\n addedItems = [];\n listView.remove(dataItems);\n } else if (groupedMode) {\n listView.replaceGrouped(view);\n } else if (prependOnRefresh && !listView._filter) {\n addedItems = listView.prepend(view);\n addedDataItems = view;\n } else {\n listView.replace(view);\n }\n if (this._shouldShowLoading()) {\n listView.hideLoading();\n }\n listView.trigger(DATABOUND, {\n ns: ui,\n addedItems: addedItems,\n addedDataItems: addedDataItems\n });\n },\n setDataSource: function (dataSource) {\n if (this.dataSource) {\n this._unbindDataSource();\n }\n this.dataSource = dataSource;\n dataSource.bind(CHANGE, this._refreshHandler);\n if (this._shouldShowLoading()) {\n this.dataSource.bind(PROGRESS, this._progressHandler);\n }\n },\n _unbindDataSource: function () {\n this.dataSource.unbind(CHANGE, this._refreshHandler).unbind(PROGRESS, this._progressHandler);\n },\n _shouldShowLoading: function () {\n var options = this.options;\n return !options.pullToRefresh && !options.loadMore && !options.endlessScroll;\n }\n });\n var ListViewFilter = kendo.Class.extend({\n init: function (listView) {\n var filter = this, filterable = listView.options.filterable, events = 'change paste', that = this;\n this.listView = listView;\n this.options = filterable;\n listView.element.before(SEARCH_TEMPLATE({ placeholder: filterable.placeholder || 'Search...' }));\n if (filterable.autoFilter !== false) {\n events += ' keyup';\n }\n this.element = listView.wrapper.find('.km-search-form');\n this.searchInput = listView.wrapper.find('input[type=search]').closest('form').on('submit' + NS, function (e) {\n e.preventDefault();\n }).end().on('focus' + NS, function () {\n filter._oldFilter = filter.searchInput.val();\n }).on(events.split(' ').join(NS + ' ') + NS, proxy(this._filterChange, this));\n this.clearButton = listView.wrapper.find('.km-filter-reset').on(CLICK, proxy(this, '_clearFilter')).hide();\n this._dataSourceChange = $.proxy(this._refreshInput, this);\n listView.bind('_dataSource', function (e) {\n e.dataSource.bind('change', that._dataSourceChange);\n });\n },\n _refreshInput: function () {\n var appliedFilters = this.listView.dataSource.filter();\n var searchInput = this.listView._filter.searchInput;\n if (!appliedFilters || appliedFilters.filters[0].field !== this.listView.options.filterable.field) {\n searchInput.val('');\n } else {\n searchInput.val(appliedFilters.filters[0].value);\n }\n },\n _search: function (expr) {\n this._filter = true;\n this.clearButton[expr ? 'show' : 'hide']();\n this.listView.dataSource.filter(expr);\n },\n _filterChange: function (e) {\n var filter = this;\n if (e.type == 'paste' && this.options.autoFilter !== false) {\n setTimeout(function () {\n filter._applyFilter();\n }, 1);\n } else {\n this._applyFilter();\n }\n },\n _applyFilter: function () {\n var options = this.options, value = this.searchInput.val(), expr = value.length ? {\n field: options.field,\n operator: options.operator || 'startswith',\n ignoreCase: options.ignoreCase,\n value: value\n } : null;\n if (value === this._oldFilter) {\n return;\n }\n this._oldFilter = value;\n this._search(expr);\n },\n _clearFilter: function (e) {\n this.searchInput.val('');\n this._search(null);\n e.preventDefault();\n }\n });\n var ListView = Widget.extend({\n init: function (element, options) {\n var listView = this;\n Widget.fn.init.call(this, element, options);\n element = this.element;\n options = this.options;\n if (options.scrollTreshold) {\n options.scrollThreshold = options.scrollTreshold;\n }\n element.on('down', HIGHLIGHT_SELECTOR, '_highlight').on('move up cancel', HIGHLIGHT_SELECTOR, '_dim');\n this._userEvents = new kendo.UserEvents(element, {\n fastTap: true,\n filter: ITEM_SELECTOR,\n allowSelection: true,\n tap: function (e) {\n listView._click(e);\n }\n });\n element.css('-ms-touch-action', 'auto');\n element.wrap(WRAPPER);\n this.wrapper = this.element.parent();\n this._headerFixer = new HeaderFixer(this);\n this._itemsCache = {};\n this._templates();\n this.virtual = options.endlessScroll || options.loadMore;\n this._style();\n if (this.options.$angular && (this.virtual || this.options.pullToRefresh)) {\n setTimeout($.proxy(this, '_start'));\n } else {\n this._start();\n }\n },\n _start: function () {\n var options = this.options;\n if (this.options.filterable) {\n this._filter = new ListViewFilter(this);\n }\n if (this.virtual) {\n this._itemBinder = new VirtualListViewItemBinder(this);\n } else {\n this._itemBinder = new ListViewItemBinder(this);\n }\n if (this.options.pullToRefresh) {\n this._pullToRefreshHandler = new RefreshHandler(this);\n }\n this.setDataSource(options.dataSource);\n this._enhanceItems(this.items());\n kendo.notify(this, ui);\n },\n events: [\n CLICK,\n DATABINDING,\n DATABOUND,\n ITEM_CHANGE\n ],\n options: {\n name: 'ListView',\n style: '',\n type: 'flat',\n autoBind: true,\n fixedHeaders: false,\n template: '#:data#',\n headerTemplate: '#:value#',\n appendOnRefresh: false,\n loadMore: false,\n endlessScroll: false,\n scrollThreshold: 30,\n pullToRefresh: false,\n messages: {\n loadMoreText: 'Press to load more',\n pullTemplate: 'Pull to refresh',\n releaseTemplate: 'Release to refresh',\n refreshTemplate: 'Refreshing'\n },\n pullOffset: 140,\n filterable: false,\n virtualViewSize: null\n },\n refresh: function () {\n this._itemBinder.refresh();\n },\n reset: function () {\n this._itemBinder.reset();\n },\n setDataSource: function (dataSource) {\n var emptyDataSource = !dataSource;\n this.dataSource = DataSource.create(dataSource);\n this.trigger('_dataSource', {\n dataSource: this.dataSource,\n empty: emptyDataSource\n });\n if (this.options.autoBind && !emptyDataSource) {\n this.items().remove();\n this.dataSource.fetch();\n }\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n kendo.destroy(this.element);\n this._userEvents.destroy();\n if (this._itemBinder) {\n this._itemBinder.destroy();\n }\n if (this._headerFixer) {\n this._headerFixer.destroy();\n }\n this.element.unwrap();\n delete this.element;\n delete this.wrapper;\n delete this._userEvents;\n },\n items: function () {\n if (this.options.type === 'group') {\n return this.element.find('.km-list').children();\n } else {\n return this.element.children().not('.km-load-more');\n }\n },\n scroller: function () {\n if (!this._scrollerInstance) {\n this._scrollerInstance = this.element.closest('.km-scroll-wrapper').data('kendoMobileScroller');\n }\n return this._scrollerInstance;\n },\n showLoading: function () {\n var view = this.view();\n if (view && view.loader) {\n view.loader.show();\n }\n },\n hideLoading: function () {\n var view = this.view();\n if (view && view.loader) {\n view.loader.hide();\n }\n },\n insertAt: function (dataItems, index, triggerChange) {\n var listView = this;\n return listView._renderItems(dataItems, function (items) {\n if (index === 0) {\n listView.element.prepend(items);\n } else if (index === -1) {\n listView.element.append(items);\n } else {\n listView.items().eq(index - 1).after(items);\n }\n if (triggerChange) {\n for (var i = 0; i < items.length; i++) {\n listView.trigger(ITEM_CHANGE, {\n item: items.eq(i),\n data: dataItems[i],\n ns: ui\n });\n }\n }\n });\n },\n append: function (dataItems, triggerChange) {\n return this.insertAt(dataItems, -1, triggerChange);\n },\n prepend: function (dataItems, triggerChange) {\n return this.insertAt(dataItems, 0, triggerChange);\n },\n replace: function (dataItems) {\n this.options.type = 'flat';\n this._angularItems('cleanup');\n kendo.destroy(this.element.children());\n this.element.empty();\n this._userEvents.cancel();\n this._style();\n return this.insertAt(dataItems, 0);\n },\n replaceGrouped: function (groups) {\n this.options.type = 'group';\n this._angularItems('cleanup');\n this.element.empty();\n var items = $(kendo.render(this.groupTemplate, groups));\n this._enhanceItems(items.children('ul').children('li'));\n this.element.append(items);\n mobile.init(items);\n this._style();\n this._angularItems('compile');\n },\n remove: function (dataItems) {\n var items = this.findByDataItem(dataItems);\n this.angular('cleanup', function () {\n return { elements: items };\n });\n kendo.destroy(items);\n items.remove();\n },\n findByDataItem: function (dataItems) {\n var selectors = [];\n for (var idx = 0, length = dataItems.length; idx < length; idx++) {\n selectors[idx] = '[data-' + kendo.ns + 'uid=' + dataItems[idx].uid + ']';\n }\n return this.element.find(selectors.join(','));\n },\n setDataItem: function (item, dataItem) {\n var listView = this, replaceItem = function (items) {\n var newItem = $(items[0]);\n kendo.destroy(item);\n listView.angular('cleanup', function () {\n return { elements: [$(item)] };\n });\n $(item).replaceWith(newItem);\n listView.trigger(ITEM_CHANGE, {\n item: newItem,\n data: dataItem,\n ns: ui\n });\n };\n return this._renderItems([dataItem], replaceItem)[0];\n },\n updateSize: function () {\n this._size = this.getSize();\n },\n _renderItems: function (dataItems, callback) {\n var items = $(kendo.render(this.template, dataItems));\n callback(items);\n this.angular('compile', function () {\n return {\n elements: items,\n data: dataItems.map(function (data) {\n return { dataItem: data };\n })\n };\n });\n mobile.init(items);\n this._enhanceItems(items);\n return items;\n },\n _dim: function (e) {\n this._toggle(e, false);\n },\n _highlight: function (e) {\n this._toggle(e, true);\n },\n _toggle: function (e, highlight) {\n if (e.which > 1) {\n return;\n }\n var clicked = $(e.currentTarget), item = clicked.parent(), role = attrValue(clicked, 'role') || '', plainItem = !role.match(buttonRegExp), prevented = e.isDefaultPrevented();\n if (plainItem) {\n item.toggleClass(ACTIVE_CLASS, highlight && !prevented);\n }\n },\n _templates: function () {\n var template = this.options.template, headerTemplate = this.options.headerTemplate, dataIDAttribute = ' data-uid=\"#=arguments[0].uid || \"\"#\"', templateProxy = {}, groupTemplateProxy = {};\n if (typeof template === FUNCTION) {\n templateProxy.template = template;\n template = '#=this.template(data)#';\n }\n this.template = proxy(kendo.template('' + template + ''), templateProxy);\n groupTemplateProxy.template = this.template;\n if (typeof headerTemplate === FUNCTION) {\n groupTemplateProxy._headerTemplate = headerTemplate;\n headerTemplate = '#=this._headerTemplate(data)#';\n }\n groupTemplateProxy.headerTemplate = kendo.template(headerTemplate);\n this.groupTemplate = proxy(GROUP_TEMPLATE, groupTemplateProxy);\n },\n _click: function (e) {\n if (e.event.which > 1 || e.event.isDefaultPrevented()) {\n return;\n }\n var dataItem, item = e.target, target = $(e.event.target), buttonElement = target.closest(kendo.roleSelector('button', 'detailbutton', 'backbutton')), button = kendo.widgetInstance(buttonElement, ui), id = item.attr(kendo.attr('uid'));\n if (id) {\n dataItem = this.dataSource.getByUid(id);\n }\n if (this.trigger(CLICK, {\n target: target,\n item: item,\n dataItem: dataItem,\n button: button\n })) {\n e.preventDefault();\n }\n },\n _styleGroups: function () {\n var rootItems = this.element.children();\n rootItems.children('ul').addClass('km-list');\n rootItems.each(function () {\n var li = $(this), groupHeader = li.contents().first();\n li.addClass('km-group-container');\n if (!groupHeader.is('ul') && !groupHeader.is('div.' + GROUP_CLASS)) {\n groupHeader.wrap(GROUP_WRAPPER);\n }\n });\n },\n _style: function () {\n var options = this.options, grouped = options.type === 'group', element = this.element, inset = options.style === 'inset';\n element.addClass('km-listview').toggleClass('km-list', !grouped).toggleClass('km-virtual-list', this.virtual).toggleClass('km-listinset', !grouped && inset).toggleClass('km-listgroup', grouped && !inset).toggleClass('km-listgroupinset', grouped && inset);\n if (!element.parents('.km-listview')[0]) {\n element.closest('.km-content').toggleClass('km-insetcontent', inset);\n }\n if (grouped) {\n this._styleGroups();\n }\n this.trigger(STYLED);\n },\n _enhanceItems: function (items) {\n items.each(function () {\n var item = $(this), child, enhanced = false;\n item.children().each(function () {\n child = $(this);\n if (child.is('a')) {\n enhanceLinkItem(child);\n enhanced = true;\n } else if (child.is('label')) {\n enhanceCheckBoxItem(child);\n enhanced = true;\n }\n });\n if (!enhanced) {\n enhanceItem(item);\n }\n });\n }\n });\n ui.plugin(ListView);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.navbar', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.navbar',\n name: 'NavBar',\n category: 'mobile',\n description: 'The Kendo mobile NavBar widget is used inside a mobile View or Layout Header element to display an application navigation bar.',\n depends: ['core']\n };\n (function ($, undefined) {\n var kendo = window.kendo, mobile = kendo.mobile, ui = mobile.ui, Widget = ui.Widget;\n function createContainer(align, element) {\n var items = element.find('[' + kendo.attr('align') + '=' + align + ']');\n if (items[0]) {\n return $('
    ').append(items).prependTo(element);\n }\n }\n function toggleTitle(centerElement) {\n var siblings = centerElement.siblings(), noTitle = !!centerElement.children('ul')[0], showTitle = !!siblings[0] && kendo.trim(centerElement.text()) === '', android = !!(kendo.mobile.application && kendo.mobile.application.element.is('.km-android'));\n centerElement.prevAll().toggleClass('km-absolute', noTitle);\n centerElement.toggleClass('km-show-title', showTitle);\n centerElement.toggleClass('km-fill-title', showTitle && !kendo.trim(centerElement.html()));\n centerElement.toggleClass('km-no-title', noTitle);\n centerElement.toggleClass('km-hide-title', android && !siblings.children().is(':visible'));\n }\n var NavBar = Widget.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n element = that.element;\n that.container().bind('show', $.proxy(this, 'refresh'));\n element.addClass('km-navbar').wrapInner($('
    '));\n that.leftElement = createContainer('left', element);\n that.rightElement = createContainer('right', element);\n that.centerElement = element.find('.km-view-title');\n },\n options: { name: 'NavBar' },\n title: function (value) {\n this.element.find(kendo.roleSelector('view-title')).text(value);\n toggleTitle(this.centerElement);\n },\n refresh: function (e) {\n var view = e.view;\n this.title(view.options.title);\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n kendo.destroy(this.element);\n }\n });\n ui.plugin(NavBar);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.scrollview', [\n 'kendo.fx',\n 'kendo.data',\n 'kendo.draganddrop'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.scrollview',\n name: 'ScrollView',\n category: 'mobile',\n description: 'The Kendo Mobile ScrollView widget is used to scroll content wider than the device screen.',\n depends: [\n 'fx',\n 'data',\n 'draganddrop'\n ]\n };\n (function ($, undefined) {\n var kendo = window.kendo, mobile = kendo.mobile, ui = mobile.ui, proxy = $.proxy, Transition = kendo.effects.Transition, Pane = kendo.ui.Pane, PaneDimensions = kendo.ui.PaneDimensions, Widget = ui.DataBoundWidget, DataSource = kendo.data.DataSource, Buffer = kendo.data.Buffer, BatchBuffer = kendo.data.BatchBuffer, math = Math, abs = math.abs, ceil = math.ceil, round = math.round, max = math.max, min = math.min, floor = math.floor, CHANGE = 'change', CHANGING = 'changing', REFRESH = 'refresh', CURRENT_PAGE_CLASS = 'current-page', VIRTUAL_PAGE_CLASS = 'virtual-page', FUNCTION = 'function', ITEM_CHANGE = 'itemChange', CLEANUP = 'cleanup', VIRTUAL_PAGE_COUNT = 3, LEFT_PAGE = -1, CETER_PAGE = 0, RIGHT_PAGE = 1, LEFT_SWIPE = -1, NUDGE = 0, RIGHT_SWIPE = 1;\n function className(name) {\n return 'k-' + name + ' km-' + name;\n }\n var Pager = kendo.Class.extend({\n init: function (scrollView) {\n var that = this, element = $('
      ');\n scrollView.element.append(element);\n this._changeProxy = proxy(that, '_change');\n this._refreshProxy = proxy(that, '_refresh');\n scrollView.bind(CHANGE, this._changeProxy);\n scrollView.bind(REFRESH, this._refreshProxy);\n $.extend(that, {\n element: element,\n scrollView: scrollView\n });\n },\n items: function () {\n return this.element.children();\n },\n _refresh: function (e) {\n var pageHTML = '';\n for (var idx = 0; idx < e.pageCount; idx++) {\n pageHTML += '
    1. ';\n }\n this.element.html(pageHTML);\n this.items().eq(e.page).addClass(className(CURRENT_PAGE_CLASS));\n },\n _change: function (e) {\n this.items().removeClass(className(CURRENT_PAGE_CLASS)).eq(e.page).addClass(className(CURRENT_PAGE_CLASS));\n },\n destroy: function () {\n this.scrollView.unbind(CHANGE, this._changeProxy);\n this.scrollView.unbind(REFRESH, this._refreshProxy);\n this.element.remove();\n }\n });\n kendo.mobile.ui.ScrollViewPager = Pager;\n var TRANSITION_END = 'transitionEnd', DRAG_START = 'dragStart', DRAG_END = 'dragEnd';\n var ElasticPane = kendo.Observable.extend({\n init: function (element, options) {\n var that = this;\n kendo.Observable.fn.init.call(this);\n this.element = element;\n this.container = element.parent();\n var movable, transition, userEvents, dimensions, dimension, pane;\n movable = new kendo.ui.Movable(that.element);\n transition = new Transition({\n axis: 'x',\n movable: movable,\n onEnd: function () {\n that.trigger(TRANSITION_END);\n }\n });\n userEvents = new kendo.UserEvents(element, {\n fastTap: true,\n start: function (e) {\n if (abs(e.x.velocity) * 2 >= abs(e.y.velocity)) {\n userEvents.capture();\n } else {\n userEvents.cancel();\n }\n that.trigger(DRAG_START, e);\n transition.cancel();\n },\n allowSelection: true,\n end: function (e) {\n that.trigger(DRAG_END, e);\n }\n });\n dimensions = new PaneDimensions({\n element: that.element,\n container: that.container\n });\n dimension = dimensions.x;\n dimension.bind(CHANGE, function () {\n that.trigger(CHANGE);\n });\n pane = new Pane({\n dimensions: dimensions,\n userEvents: userEvents,\n movable: movable,\n elastic: true\n });\n $.extend(that, {\n duration: options && options.duration || 1,\n movable: movable,\n transition: transition,\n userEvents: userEvents,\n dimensions: dimensions,\n dimension: dimension,\n pane: pane\n });\n this.bind([\n TRANSITION_END,\n DRAG_START,\n DRAG_END,\n CHANGE\n ], options);\n },\n size: function () {\n return {\n width: this.dimensions.x.getSize(),\n height: this.dimensions.y.getSize()\n };\n },\n total: function () {\n return this.dimension.getTotal();\n },\n offset: function () {\n return -this.movable.x;\n },\n updateDimension: function () {\n this.dimension.update(true);\n },\n refresh: function () {\n this.dimensions.refresh();\n },\n moveTo: function (offset) {\n this.movable.moveAxis('x', -offset);\n },\n transitionTo: function (offset, ease, instant) {\n if (instant) {\n this.moveTo(-offset);\n } else {\n this.transition.moveTo({\n location: offset,\n duration: this.duration,\n ease: ease\n });\n }\n }\n });\n kendo.mobile.ui.ScrollViewElasticPane = ElasticPane;\n var ScrollViewContent = kendo.Observable.extend({\n init: function (element, pane, options) {\n var that = this;\n kendo.Observable.fn.init.call(this);\n that.element = element;\n that.pane = pane;\n that._getPages();\n this.page = 0;\n this.pageSize = options.pageSize || 1;\n this.contentHeight = options.contentHeight;\n this.enablePager = options.enablePager;\n this.pagerOverlay = options.pagerOverlay;\n },\n scrollTo: function (page, instant) {\n this.page = page;\n this.pane.transitionTo(-page * this.pane.size().width, Transition.easeOutExpo, instant);\n },\n paneMoved: function (swipeType, bounce, callback, instant) {\n var that = this, pane = that.pane, width = pane.size().width * that.pageSize, approx = round, ease = bounce ? Transition.easeOutBack : Transition.easeOutExpo, snap, nextPage;\n if (swipeType === LEFT_SWIPE) {\n approx = ceil;\n } else if (swipeType === RIGHT_SWIPE) {\n approx = floor;\n }\n nextPage = approx(pane.offset() / width);\n snap = max(that.minSnap, min(-nextPage * width, that.maxSnap));\n if (nextPage != that.page) {\n if (callback && callback({\n currentPage: that.page,\n nextPage: nextPage\n })) {\n snap = -that.page * pane.size().width;\n }\n }\n pane.transitionTo(snap, ease, instant);\n },\n updatePage: function () {\n var pane = this.pane, page = round(pane.offset() / pane.size().width);\n if (page != this.page) {\n this.page = page;\n return true;\n }\n return false;\n },\n forcePageUpdate: function () {\n return this.updatePage();\n },\n resizeTo: function (size) {\n var pane = this.pane, width = size.width;\n this.pageElements.width(width);\n if (this.contentHeight === '100%') {\n var containerHeight = this.element.parent().height();\n if (this.enablePager === true) {\n var pager = this.element.parent().find('ol.km-pages');\n if (!this.pagerOverlay && pager.length) {\n containerHeight -= kendo._outerHeight(pager, true);\n }\n }\n this.element.css('height', containerHeight);\n this.pageElements.css('height', containerHeight);\n }\n pane.updateDimension();\n if (!this._paged) {\n this.page = floor(pane.offset() / width);\n }\n this.scrollTo(this.page, true);\n this.pageCount = ceil(pane.total() / width);\n this.minSnap = -(this.pageCount - 1) * width;\n this.maxSnap = 0;\n },\n _getPages: function () {\n this.pageElements = this.element.find(kendo.roleSelector('page'));\n this._paged = this.pageElements.length > 0;\n }\n });\n kendo.mobile.ui.ScrollViewContent = ScrollViewContent;\n var VirtualScrollViewContent = kendo.Observable.extend({\n init: function (element, pane, options) {\n var that = this;\n kendo.Observable.fn.init.call(this);\n that.element = element;\n that.pane = pane;\n that.options = options;\n that._templates();\n that.page = options.page || 0;\n that.pages = [];\n that._initPages();\n that.resizeTo(that.pane.size());\n that.pane.dimension.forceEnabled();\n },\n setDataSource: function (dataSource) {\n this.dataSource = DataSource.create(dataSource);\n this._buffer();\n this._pendingPageRefresh = false;\n this._pendingWidgetRefresh = false;\n },\n _viewShow: function () {\n var that = this;\n if (that._pendingWidgetRefresh) {\n setTimeout(function () {\n that._resetPages();\n }, 0);\n that._pendingWidgetRefresh = false;\n }\n },\n _buffer: function () {\n var itemsPerPage = this.options.itemsPerPage;\n if (this.buffer) {\n this.buffer.destroy();\n }\n if (itemsPerPage > 1) {\n this.buffer = new BatchBuffer(this.dataSource, itemsPerPage);\n } else {\n this.buffer = new Buffer(this.dataSource, itemsPerPage * 3);\n }\n this._resizeProxy = proxy(this, '_onResize');\n this._resetProxy = proxy(this, '_onReset');\n this._endReachedProxy = proxy(this, '_onEndReached');\n this.buffer.bind({\n 'resize': this._resizeProxy,\n 'reset': this._resetProxy,\n 'endreached': this._endReachedProxy\n });\n },\n _templates: function () {\n var template = this.options.template, emptyTemplate = this.options.emptyTemplate, templateProxy = {}, emptyTemplateProxy = {};\n if (typeof template === FUNCTION) {\n templateProxy.template = template;\n template = '#=this.template(data)#';\n }\n this.template = proxy(kendo.template(template), templateProxy);\n if (typeof emptyTemplate === FUNCTION) {\n emptyTemplateProxy.emptyTemplate = emptyTemplate;\n emptyTemplate = '#=this.emptyTemplate(data)#';\n }\n this.emptyTemplate = proxy(kendo.template(emptyTemplate), emptyTemplateProxy);\n },\n _initPages: function () {\n var pages = this.pages, element = this.element, page;\n for (var i = 0; i < VIRTUAL_PAGE_COUNT; i++) {\n page = new Page(element);\n pages.push(page);\n }\n this.pane.updateDimension();\n },\n resizeTo: function (size) {\n var pages = this.pages, pane = this.pane;\n for (var i = 0; i < pages.length; i++) {\n pages[i].setWidth(size.width);\n }\n if (this.options.contentHeight === 'auto') {\n this.element.css('height', this.pages[1].element.height());\n } else if (this.options.contentHeight === '100%') {\n var containerHeight = this.element.parent().height();\n if (this.options.enablePager === true) {\n var pager = this.element.parent().find('ol.km-pages');\n if (!this.options.pagerOverlay && pager.length) {\n containerHeight -= kendo._outerHeight(pager, true);\n }\n }\n this.element.css('height', containerHeight);\n pages[0].element.css('height', containerHeight);\n pages[1].element.css('height', containerHeight);\n pages[2].element.css('height', containerHeight);\n }\n pane.updateDimension();\n this._repositionPages();\n this.width = size.width;\n },\n scrollTo: function (page) {\n var buffer = this.buffer, dataItem;\n buffer.syncDataSource();\n dataItem = buffer.at(page);\n if (!dataItem) {\n return;\n }\n this._updatePagesContent(page);\n this.page = page;\n },\n paneMoved: function (swipeType, bounce, callback, instant) {\n var that = this, pane = that.pane, width = pane.size().width, offset = pane.offset(), thresholdPassed = Math.abs(offset) >= width / 3, ease = bounce ? kendo.effects.Transition.easeOutBack : kendo.effects.Transition.easeOutExpo, isEndReached = that.page + 2 > that.buffer.total(), nextPage, delta = 0;\n if (swipeType === RIGHT_SWIPE) {\n if (that.page !== 0) {\n delta = -1;\n }\n } else if (swipeType === LEFT_SWIPE && !isEndReached) {\n delta = 1;\n } else if (offset > 0 && (thresholdPassed && !isEndReached)) {\n delta = 1;\n } else if (offset < 0 && thresholdPassed) {\n if (that.page !== 0) {\n delta = -1;\n }\n }\n nextPage = that.page;\n if (delta) {\n nextPage = delta > 0 ? nextPage + 1 : nextPage - 1;\n }\n if (callback && callback({\n currentPage: that.page,\n nextPage: nextPage\n })) {\n delta = 0;\n }\n if (delta === 0) {\n that._cancelMove(ease, instant);\n } else if (delta === -1) {\n that._moveBackward(instant);\n } else if (delta === 1) {\n that._moveForward(instant);\n }\n },\n updatePage: function () {\n var pages = this.pages;\n if (this.pane.offset() === 0) {\n return false;\n }\n if (this.pane.offset() > 0) {\n pages.push(this.pages.shift());\n this.page++;\n this.setPageContent(pages[2], this.page + 1);\n } else {\n pages.unshift(this.pages.pop());\n this.page--;\n this.setPageContent(pages[0], this.page - 1);\n }\n this._repositionPages();\n this._resetMovable();\n return true;\n },\n forcePageUpdate: function () {\n var offset = this.pane.offset(), threshold = this.pane.size().width * 3 / 4;\n if (abs(offset) > threshold) {\n return this.updatePage();\n }\n return false;\n },\n _resetMovable: function () {\n this.pane.moveTo(0);\n },\n _moveForward: function (instant) {\n this.pane.transitionTo(-this.width, kendo.effects.Transition.easeOutExpo, instant);\n },\n _moveBackward: function (instant) {\n this.pane.transitionTo(this.width, kendo.effects.Transition.easeOutExpo, instant);\n },\n _cancelMove: function (ease, instant) {\n this.pane.transitionTo(0, ease, instant);\n },\n _resetPages: function () {\n this.page = this.options.page || 0;\n this._updatePagesContent(this.page);\n this._repositionPages();\n this.trigger('reset');\n },\n _onResize: function () {\n this.pageCount = ceil(this.dataSource.total() / this.options.itemsPerPage);\n if (this._pendingPageRefresh) {\n this._updatePagesContent(this.page);\n this._pendingPageRefresh = false;\n }\n this.trigger('resize');\n },\n _onReset: function () {\n this.pageCount = ceil(this.dataSource.total() / this.options.itemsPerPage);\n this._resetPages();\n },\n _onEndReached: function () {\n this._pendingPageRefresh = true;\n },\n _repositionPages: function () {\n var pages = this.pages;\n pages[0].position(LEFT_PAGE);\n pages[1].position(CETER_PAGE);\n pages[2].position(RIGHT_PAGE);\n },\n _updatePagesContent: function (offset) {\n var pages = this.pages, currentPage = offset || 0;\n this.setPageContent(pages[0], currentPage - 1);\n this.setPageContent(pages[1], currentPage);\n this.setPageContent(pages[2], currentPage + 1);\n },\n setPageContent: function (page, index) {\n var buffer = this.buffer, template = this.template, emptyTemplate = this.emptyTemplate, view = null;\n if (index >= 0) {\n view = buffer.at(index);\n if ($.isArray(view) && !view.length) {\n view = null;\n }\n }\n this.trigger(CLEANUP, { item: page.element });\n if (view !== null) {\n page.content(template(view));\n } else {\n page.content(emptyTemplate({}));\n }\n kendo.mobile.init(page.element);\n this.trigger(ITEM_CHANGE, {\n item: page.element,\n data: view,\n ns: kendo.mobile.ui\n });\n }\n });\n kendo.mobile.ui.VirtualScrollViewContent = VirtualScrollViewContent;\n var Page = kendo.Class.extend({\n init: function (container) {\n this.element = $('
      ');\n this.width = container.width();\n this.element.width(this.width);\n container.append(this.element);\n },\n content: function (theContent) {\n this.element.html(theContent);\n },\n position: function (position) {\n this.element.css('transform', 'translate3d(' + this.width * position + 'px, 0, 0)');\n },\n setWidth: function (width) {\n this.width = width;\n this.element.width(width);\n }\n });\n kendo.mobile.ui.VirtualPage = Page;\n var ScrollView = Widget.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n options = that.options;\n element = that.element;\n kendo.stripWhitespace(element[0]);\n element.wrapInner('
      ').addClass('k-widget ' + className('scrollview'));\n if (this.options.enablePager) {\n this.pager = new Pager(this);\n if (this.options.pagerOverlay) {\n element.addClass(className('scrollview-overlay'));\n }\n }\n that.inner = element.children().first();\n that.page = 0;\n that.inner.css('height', options.contentHeight);\n that.pane = new ElasticPane(that.inner, {\n duration: this.options.duration,\n transitionEnd: proxy(this, '_transitionEnd'),\n dragStart: proxy(this, '_dragStart'),\n dragEnd: proxy(this, '_dragEnd'),\n change: proxy(this, REFRESH)\n });\n that.bind('resize', function () {\n that.pane.refresh();\n });\n that.page = options.page;\n var empty = this.inner.children().length === 0;\n var content = empty ? new VirtualScrollViewContent(that.inner, that.pane, options) : new ScrollViewContent(that.inner, that.pane, options);\n content.page = that.page;\n content.bind('reset', function () {\n this._pendingPageRefresh = false;\n that._syncWithContent();\n that.trigger(REFRESH, {\n pageCount: content.pageCount,\n page: content.page\n });\n });\n content.bind('resize', function () {\n that.trigger(REFRESH, {\n pageCount: content.pageCount,\n page: content.page\n });\n });\n content.bind(ITEM_CHANGE, function (e) {\n that.trigger(ITEM_CHANGE, e);\n that.angular('compile', function () {\n return {\n elements: e.item,\n data: [{ dataItem: e.data }]\n };\n });\n });\n content.bind(CLEANUP, function (e) {\n that.angular('cleanup', function () {\n return { elements: e.item };\n });\n });\n that._content = content;\n that.setDataSource(options.dataSource);\n var mobileContainer = that.container();\n if (mobileContainer.nullObject) {\n that.viewInit();\n that.viewShow();\n } else {\n mobileContainer.bind('show', proxy(this, 'viewShow')).bind('init', proxy(this, 'viewInit'));\n }\n },\n options: {\n name: 'ScrollView',\n page: 0,\n duration: 400,\n velocityThreshold: 0.8,\n contentHeight: 'auto',\n pageSize: 1,\n itemsPerPage: 1,\n bounceVelocityThreshold: 1.6,\n enablePager: true,\n pagerOverlay: false,\n autoBind: true,\n template: '',\n emptyTemplate: ''\n },\n events: [\n CHANGING,\n CHANGE,\n REFRESH\n ],\n destroy: function () {\n Widget.fn.destroy.call(this);\n kendo.destroy(this.element);\n },\n viewInit: function () {\n if (this.options.autoBind) {\n this._content.scrollTo(this._content.page, true);\n }\n },\n viewShow: function () {\n this.pane.refresh();\n },\n refresh: function () {\n var content = this._content;\n content.resizeTo(this.pane.size());\n this.page = content.page;\n this.trigger(REFRESH, {\n pageCount: content.pageCount,\n page: content.page\n });\n },\n content: function (html) {\n this.element.children().first().html(html);\n this._content._getPages();\n this.pane.refresh();\n },\n value: function (item) {\n var dataSource = this.dataSource;\n if (item) {\n this.scrollTo(dataSource.indexOf(item), true);\n } else {\n return dataSource.at(this.page);\n }\n },\n scrollTo: function (page, instant) {\n this._content.scrollTo(page, instant);\n this._syncWithContent();\n },\n prev: function () {\n var that = this, prevPage = that.page - 1;\n if (that._content instanceof VirtualScrollViewContent) {\n that._content.paneMoved(RIGHT_SWIPE, undefined, function (eventData) {\n return that.trigger(CHANGING, eventData);\n });\n } else if (prevPage > -1) {\n that.scrollTo(prevPage);\n }\n },\n next: function () {\n var that = this, nextPage = that.page + 1;\n if (that._content instanceof VirtualScrollViewContent) {\n that._content.paneMoved(LEFT_SWIPE, undefined, function (eventData) {\n return that.trigger(CHANGING, eventData);\n });\n } else if (nextPage < that._content.pageCount) {\n that.scrollTo(nextPage);\n }\n },\n setDataSource: function (dataSource) {\n if (!(this._content instanceof VirtualScrollViewContent)) {\n return;\n }\n var emptyDataSource = !dataSource;\n this.dataSource = DataSource.create(dataSource);\n this._content.setDataSource(this.dataSource);\n if (this.options.autoBind && !emptyDataSource) {\n this.dataSource.fetch();\n }\n },\n items: function () {\n return this.element.find('.km-' + VIRTUAL_PAGE_CLASS);\n },\n _syncWithContent: function () {\n var pages = this._content.pages, buffer = this._content.buffer, data, element;\n this.page = this._content.page;\n data = buffer ? buffer.at(this.page) : undefined;\n if (!(data instanceof Array)) {\n data = [data];\n }\n element = pages ? pages[1].element : undefined;\n this.trigger(CHANGE, {\n page: this.page,\n element: element,\n data: data\n });\n },\n _dragStart: function () {\n if (this._content.forcePageUpdate()) {\n this._syncWithContent();\n }\n },\n _dragEnd: function (e) {\n var that = this, velocity = e.x.velocity, velocityThreshold = this.options.velocityThreshold, swipeType = NUDGE, bounce = abs(velocity) > this.options.bounceVelocityThreshold;\n if (velocity > velocityThreshold) {\n swipeType = RIGHT_SWIPE;\n } else if (velocity < -velocityThreshold) {\n swipeType = LEFT_SWIPE;\n }\n this._content.paneMoved(swipeType, bounce, function (eventData) {\n return that.trigger(CHANGING, eventData);\n });\n },\n _transitionEnd: function () {\n if (this._content.updatePage()) {\n this._syncWithContent();\n }\n }\n });\n ui.plugin(ScrollView);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.switch', [\n 'kendo.fx',\n 'kendo.userevents'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.switch',\n name: 'Switch',\n category: 'mobile',\n description: 'The mobile Switch widget is used to display two exclusive choices.',\n depends: [\n 'fx',\n 'userevents'\n ]\n };\n (function ($, undefined) {\n var kendo = window.kendo, ui = kendo.mobile.ui, outerWidth = kendo._outerWidth, Widget = ui.Widget, support = kendo.support, CHANGE = 'change', SWITCHON = 'switch-on', SWITCHOFF = 'switch-off', MARGINLEFT = 'margin-left', ACTIVE_STATE = 'state-active', DISABLED_STATE = 'state-disabled', DISABLED = 'disabled', RESOLVEDPREFIX = support.transitions.css === undefined ? '' : support.transitions.css, TRANSFORMSTYLE = RESOLVEDPREFIX + 'transform', proxy = $.proxy;\n function className(name) {\n return 'km-' + name;\n }\n function limitValue(value, minLimit, maxLimit) {\n return Math.max(minLimit, Math.min(maxLimit, value));\n }\n var SWITCH_MARKUP = ' {0} {1} ';\n var Switch = Widget.extend({\n init: function (element, options) {\n var that = this, checked;\n Widget.fn.init.call(that, element, options);\n options = that.options;\n that.wrapper = $(kendo.format(SWITCH_MARKUP, options.onLabel, options.offLabel));\n that.handle = that.wrapper.find('.km-switch-handle');\n that.background = that.wrapper.find('.km-switch-background');\n that.wrapper.insertBefore(that.element).prepend(that.element);\n that._drag();\n that.origin = parseInt(that.background.css(MARGINLEFT), 10);\n that.constrain = 0;\n that.snapPoint = 0;\n element = that.element[0];\n element.type = 'checkbox';\n that._animateBackground = true;\n checked = that.options.checked;\n if (checked === null) {\n checked = element.checked;\n }\n that.check(checked);\n that.options.enable = that.options.enable && !that.element.attr(DISABLED);\n that.enable(that.options.enable);\n that.refresh();\n kendo.notify(that, kendo.mobile.ui);\n },\n refresh: function () {\n var that = this, handleWidth = outerWidth(that.handle, true);\n that.width = that.wrapper.width();\n that.constrain = that.width - handleWidth;\n that.snapPoint = that.constrain / 2;\n if (typeof that.origin != 'number') {\n that.origin = parseInt(that.background.css(MARGINLEFT), 10);\n }\n that.background.data('origin', that.origin);\n that.check(that.element[0].checked);\n },\n events: [CHANGE],\n options: {\n name: 'Switch',\n onLabel: 'on',\n offLabel: 'off',\n checked: null,\n enable: true\n },\n check: function (check) {\n var that = this, element = that.element[0];\n if (check === undefined) {\n return element.checked;\n }\n that._position(check ? that.constrain : 0);\n element.checked = check;\n that.wrapper.toggleClass(className(SWITCHON), check).toggleClass(className(SWITCHOFF), !check);\n },\n value: function () {\n return this.check.apply(this, arguments);\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n this.userEvents.destroy();\n },\n toggle: function () {\n var that = this;\n that.check(!that.element[0].checked);\n },\n enable: function (enable) {\n var element = this.element, wrapper = this.wrapper;\n if (typeof enable == 'undefined') {\n enable = true;\n }\n this.options.enable = enable;\n if (enable) {\n element.removeAttr(DISABLED);\n } else {\n element.attr(DISABLED, DISABLED);\n }\n wrapper.toggleClass(className(DISABLED_STATE), !enable);\n },\n _resize: function () {\n this.refresh();\n },\n _move: function (e) {\n var that = this;\n e.preventDefault();\n that._position(limitValue(that.position + e.x.delta, 0, that.width - outerWidth(that.handle, true)));\n },\n _position: function (position) {\n var that = this;\n that.position = position;\n that.handle.css(TRANSFORMSTYLE, 'translatex(' + position + 'px)');\n if (that._animateBackground) {\n that.background.css(MARGINLEFT, that.origin + position);\n }\n },\n _start: function () {\n if (!this.options.enable) {\n this.userEvents.cancel();\n } else {\n this.userEvents.capture();\n this.handle.addClass(className(ACTIVE_STATE));\n }\n },\n _stop: function () {\n var that = this;\n that.handle.removeClass(className(ACTIVE_STATE));\n that._toggle(that.position > that.snapPoint);\n },\n _toggle: function (checked) {\n var that = this, handle = that.handle, element = that.element[0], value = element.checked, duration = kendo.mobile.application && kendo.mobile.application.os.wp ? 100 : 200, distance;\n that.wrapper.toggleClass(className(SWITCHON), checked).toggleClass(className(SWITCHOFF), !checked);\n that.position = distance = checked * that.constrain;\n if (that._animateBackground) {\n that.background.kendoStop(true, true).kendoAnimate({\n effects: 'slideMargin',\n offset: distance,\n reset: true,\n reverse: !checked,\n axis: 'left',\n duration: duration\n });\n }\n handle.kendoStop(true, true).kendoAnimate({\n effects: 'slideTo',\n duration: duration,\n offset: distance + 'px,0',\n reset: true,\n complete: function () {\n if (value !== checked) {\n element.checked = checked;\n that.trigger(CHANGE, { checked: checked });\n }\n }\n });\n },\n _drag: function () {\n var that = this;\n that.userEvents = new kendo.UserEvents(that.wrapper, {\n fastTap: true,\n tap: function () {\n if (that.options.enable) {\n that._toggle(!that.element[0].checked);\n }\n },\n start: proxy(that._start, that),\n move: proxy(that._move, that),\n end: proxy(that._stop, that)\n });\n }\n });\n ui.plugin(Switch);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile.tabstrip', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'mobile.tabstrip',\n name: 'TabStrip',\n category: 'mobile',\n description: 'The mobile TabStrip widget is used inside a mobile view or layout footer element to display an application-wide group of navigation buttons.',\n depends: ['core']\n };\n (function ($, undefined) {\n var kendo = window.kendo, ui = kendo.mobile.ui, Widget = ui.Widget, ACTIVE_STATE_CLASS = 'km-state-active', SELECT = 'select';\n function createBadge(value) {\n return $('' + value + '');\n }\n var TabStrip = Widget.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n that.container().bind('show', $.proxy(this, 'refresh'));\n that.element.addClass('km-tabstrip').find('a').each(that._buildButton).eq(that.options.selectedIndex).addClass(ACTIVE_STATE_CLASS);\n that.element.on('down', 'a', '_release');\n },\n events: [SELECT],\n switchTo: function (url) {\n var tabs = this.element.find('a'), tab, path, idx = 0, length = tabs.length;\n if (isNaN(url)) {\n for (; idx < length; idx++) {\n tab = tabs[idx];\n path = tab.href.replace(/(\\#.+)(\\?.+)$/, '$1');\n if (path.indexOf(url, path.length - url.length) !== -1) {\n this._setActiveItem($(tab));\n return true;\n }\n }\n } else {\n this._setActiveItem(tabs.eq(url));\n return true;\n }\n return false;\n },\n switchByFullUrl: function (url) {\n var tab;\n tab = this.element.find('a[href$=\\'' + url + '\\']');\n this._setActiveItem(tab);\n },\n clear: function () {\n this.currentItem().removeClass(ACTIVE_STATE_CLASS);\n },\n currentItem: function () {\n return this.element.children('.' + ACTIVE_STATE_CLASS);\n },\n badge: function (item, value) {\n var tabstrip = this.element, badge;\n if (!isNaN(item)) {\n item = tabstrip.children().get(item);\n }\n item = tabstrip.find(item);\n badge = $(item.find('.km-badge')[0] || createBadge(value).insertAfter(item.children('.km-icon')));\n if (value || value === 0) {\n badge.html(value);\n return this;\n }\n if (value === false) {\n badge.empty().remove();\n return this;\n }\n return badge.html();\n },\n _release: function (e) {\n if (e.which > 1) {\n return;\n }\n var that = this, item = $(e.currentTarget);\n if (item[0] === that.currentItem()[0]) {\n return;\n }\n if (that.trigger(SELECT, { item: item })) {\n e.preventDefault();\n } else {\n that._setActiveItem(item);\n }\n },\n _setActiveItem: function (item) {\n if (!item[0]) {\n return;\n }\n this.clear();\n item.addClass(ACTIVE_STATE_CLASS);\n },\n _buildButton: function () {\n var button = $(this), icon = kendo.attrValue(button, 'icon'), badge = kendo.attrValue(button, 'badge'), image = button.find('img'), iconSpan = $('');\n button.addClass('km-button').attr(kendo.attr('role'), 'tab').contents().not(image).wrapAll('');\n if (image[0]) {\n image.addClass('km-image').prependTo(button);\n } else {\n button.prepend(iconSpan);\n if (icon) {\n iconSpan.addClass('km-' + icon);\n if (badge || badge === 0) {\n createBadge(badge).insertAfter(iconSpan);\n }\n }\n }\n },\n refresh: function (e) {\n var url = e.view.id;\n if (url && !this.switchTo(e.view.id)) {\n this.switchTo(url);\n }\n },\n options: {\n name: 'TabStrip',\n selectedIndex: 0,\n enable: true\n }\n });\n ui.plugin(TabStrip);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.angular', ['kendo.core'], f);\n}(function () {\n var __meta__ = {\n id: 'angular',\n name: 'AngularJS Directives',\n category: 'framework',\n description: 'Adds Kendo UI for AngularJS directives',\n depends: ['core'],\n defer: true\n };\n (function ($, angular, undefined) {\n 'use strict';\n if (!angular || !angular.injector) {\n return;\n }\n var module = angular.module('kendo.directives', []), $injector = angular.injector(['ng']), $parse = $injector.get('$parse'), $timeout = $injector.get('$timeout'), $defaultCompile, $log = $injector.get('$log');\n function withoutTimeout(f) {\n var save = $timeout;\n try {\n $timeout = function (f) {\n return f();\n };\n return f();\n } finally {\n $timeout = save;\n }\n }\n var OPTIONS_NOW;\n var createDataSource = function () {\n var types = {\n TreeList: 'TreeListDataSource',\n TreeView: 'HierarchicalDataSource',\n Scheduler: 'SchedulerDataSource',\n PivotGrid: 'PivotDataSource',\n PivotConfigurator: 'PivotDataSource',\n PanelBar: 'HierarchicalDataSource',\n Menu: '$PLAIN',\n ContextMenu: '$PLAIN'\n };\n var toDataSource = function (dataSource, type) {\n if (type == '$PLAIN') {\n return dataSource;\n }\n return kendo.data[type].create(dataSource);\n };\n return function (scope, element, role, source) {\n var type = types[role] || 'DataSource';\n var current = scope.$eval(source);\n var ds = toDataSource(current, type);\n scope.$watch(source, function (mew) {\n var widget = kendoWidgetInstance(element);\n if (widget && typeof widget.setDataSource == 'function') {\n if (mew !== current && mew !== widget.dataSource) {\n var ds = toDataSource(mew, type);\n widget.setDataSource(ds);\n current = mew;\n }\n }\n });\n return ds;\n };\n }();\n var ignoredAttributes = {\n kDataSource: true,\n kOptions: true,\n kRebind: true,\n kNgModel: true,\n kNgDelay: true\n };\n var ignoredOwnProperties = {\n name: true,\n title: true,\n style: true\n };\n function createWidget(scope, element, attrs, widget, origAttr, controllers) {\n if (!(element instanceof jQuery)) {\n throw new Error('The Kendo UI directives require jQuery to be available before AngularJS. Please include jquery before angular in the document.');\n }\n var kNgDelay = attrs.kNgDelay, delayValue = scope.$eval(kNgDelay);\n controllers = controllers || [];\n var ngModel = controllers[0], ngForm = controllers[1];\n var ctor = $(element)[widget];\n if (!ctor) {\n window.console.error('Could not find: ' + widget);\n return null;\n }\n var parsed = parseOptions(scope, element, attrs, widget, ctor);\n var options = parsed.options;\n if (parsed.unresolved.length) {\n var promises = [];\n for (var i = 0, len = parsed.unresolved.length; i < len; i++) {\n var unresolved = parsed.unresolved[i];\n var promise = $.Deferred(function (d) {\n var unwatch = scope.$watch(unresolved.path, function (newValue) {\n if (newValue !== undefined) {\n unwatch();\n d.resolve();\n }\n });\n }).promise();\n promises.push(promise);\n }\n $.when.apply(null, promises).then(createIt);\n return;\n }\n if (kNgDelay && !delayValue) {\n var root = scope.$root || scope;\n var register = function () {\n var unregister = scope.$watch(kNgDelay, function (newValue) {\n if (newValue !== undefined) {\n unregister();\n element.removeAttr(attrs.$attr.kNgDelay);\n kNgDelay = null;\n $timeout(createIt);\n }\n });\n };\n if (/^\\$(digest|apply)$/.test(root.$$phase)) {\n register();\n } else {\n scope.$apply(register);\n }\n return;\n } else {\n return createIt();\n }\n function createIt() {\n var originalElement;\n if (attrs.kRebind) {\n originalElement = $($(element)[0].cloneNode(true));\n }\n options = parseOptions(scope, element, attrs, widget, ctor).options;\n if (element.is('select')) {\n (function (options) {\n if (options.length > 0) {\n var first = $(options[0]);\n if (!/\\S/.test(first.text()) && /^\\?/.test(first.val())) {\n first.remove();\n }\n for (var i = 0; i < options.length; i++) {\n $(options[i]).off('$destroy');\n }\n }\n }(element[0].options));\n }\n var object = ctor.call(element, OPTIONS_NOW = options).data(widget);\n exposeWidget(object, scope, attrs, widget, origAttr);\n scope.$emit('kendoWidgetCreated', object);\n var destroyRegister = destroyWidgetOnScopeDestroy(scope, object);\n if (attrs.kRebind) {\n setupRebind(object, scope, element, originalElement, attrs.kRebind, destroyRegister, attrs);\n }\n if (attrs.kNgDisabled) {\n var kNgDisabled = attrs.kNgDisabled;\n var isDisabled = scope.$eval(kNgDisabled);\n if (isDisabled) {\n object.enable(!isDisabled);\n }\n bindToKNgDisabled(object, scope, element, kNgDisabled);\n }\n if (attrs.kNgReadonly) {\n var kNgReadonly = attrs.kNgReadonly;\n var isReadonly = scope.$eval(kNgReadonly);\n if (isReadonly) {\n object.readonly(isReadonly);\n }\n bindToKNgReadonly(object, scope, element, kNgReadonly);\n }\n if (attrs.kNgModel) {\n bindToKNgModel(object, scope, attrs.kNgModel);\n }\n if (ngModel) {\n bindToNgModel(object, scope, element, ngModel, ngForm);\n }\n if (object) {\n propagateClassToWidgetWrapper(object, element);\n }\n return object;\n }\n }\n function parseOptions(scope, element, attrs, widget, ctor) {\n var role = widget.replace(/^kendo/, '');\n var unresolved = [];\n var optionsPath = attrs.kOptions || attrs.options;\n var optionsValue = scope.$eval(optionsPath);\n if (optionsPath && optionsValue === undefined) {\n unresolved.push({\n option: 'options',\n path: optionsPath\n });\n }\n var options = angular.extend({}, attrs.defaultOptions, optionsValue);\n function addOption(name, value) {\n var scopeValue = angular.copy(scope.$eval(value));\n if (scopeValue === undefined) {\n unresolved.push({\n option: name,\n path: value\n });\n } else {\n options[name] = scopeValue;\n }\n }\n var widgetOptions = ctor.widget.prototype.options;\n var widgetEvents = ctor.widget.prototype.events;\n $.each(attrs, function (name, value) {\n if (name === 'source' || name === 'kDataSource' || name === 'kScopeField' || name === 'scopeField') {\n return;\n }\n var dataName = 'data' + name.charAt(0).toUpperCase() + name.slice(1);\n if (name.indexOf('on') === 0) {\n var eventKey = name.replace(/^on./, function (prefix) {\n return prefix.charAt(2).toLowerCase();\n });\n if (widgetEvents.indexOf(eventKey) > -1) {\n options[eventKey] = value;\n }\n }\n if (widgetOptions.hasOwnProperty(dataName)) {\n addOption(dataName, value);\n } else if (widgetOptions.hasOwnProperty(name) && !ignoredOwnProperties[name]) {\n addOption(name, value);\n } else if (!ignoredAttributes[name]) {\n var match = name.match(/^k(On)?([A-Z].*)/);\n if (match) {\n var optionName = match[2].charAt(0).toLowerCase() + match[2].slice(1);\n if (match[1] && name != 'kOnLabel') {\n options[optionName] = value;\n } else {\n if (name == 'kOnLabel') {\n optionName = 'onLabel';\n }\n addOption(optionName, value);\n }\n }\n }\n });\n var dataSource = attrs.kDataSource || attrs.source;\n if (dataSource) {\n options.dataSource = createDataSource(scope, element, role, dataSource);\n }\n options.$angular = [scope];\n return {\n options: options,\n unresolved: unresolved\n };\n }\n function bindToKNgDisabled(widget, scope, element, kNgDisabled) {\n if (kendo.ui.PanelBar && widget instanceof kendo.ui.PanelBar || kendo.ui.Menu && widget instanceof kendo.ui.Menu) {\n $log.warn('k-ng-disabled specified on a widget that does not have the enable() method: ' + widget.options.name);\n return;\n }\n scope.$watch(kNgDisabled, function (newValue, oldValue) {\n if (newValue != oldValue) {\n widget.enable(!newValue);\n }\n });\n }\n function bindToKNgReadonly(widget, scope, element, kNgReadonly) {\n if (typeof widget.readonly != 'function') {\n $log.warn('k-ng-readonly specified on a widget that does not have the readonly() method: ' + widget.options.name);\n return;\n }\n scope.$watch(kNgReadonly, function (newValue, oldValue) {\n if (newValue != oldValue) {\n widget.readonly(newValue);\n }\n });\n }\n function exposeWidget(widget, scope, attrs, kendoWidget, origAttr) {\n if (attrs[origAttr]) {\n var set = $parse(attrs[origAttr]).assign;\n if (set) {\n set(scope, widget);\n } else {\n throw new Error(origAttr + ' attribute used but expression in it is not assignable: ' + attrs[kendoWidget]);\n }\n }\n }\n function formValue(element) {\n if (/checkbox|radio/i.test(element.attr('type'))) {\n return element.prop('checked');\n }\n return element.val();\n }\n var formRegExp = /^(input|select|textarea)$/i;\n function isForm(element) {\n return formRegExp.test(element[0].tagName);\n }\n function bindToNgModel(widget, scope, element, ngModel, ngForm) {\n if (!widget.value) {\n return;\n }\n var value;\n var haveChangeOnElement = false;\n if (isForm(element)) {\n value = function () {\n return formValue(element);\n };\n } else {\n value = function () {\n return widget.value();\n };\n }\n var viewRender = function () {\n var val = ngModel.$viewValue;\n if (val === undefined) {\n val = ngModel.$modelValue;\n }\n if (val === undefined) {\n val = null;\n }\n haveChangeOnElement = true;\n setTimeout(function () {\n haveChangeOnElement = false;\n if (widget) {\n var kNgModel = scope[widget.element.attr('k-ng-model')];\n if (kNgModel) {\n val = kNgModel;\n }\n if (widget.options.autoBind === false && !widget.listView.bound()) {\n if (val) {\n widget.value(val);\n }\n } else {\n widget.value(val);\n }\n }\n }, 0);\n };\n ngModel.$render = viewRender;\n setTimeout(function () {\n if (ngModel.$render !== viewRender) {\n ngModel.$render = viewRender;\n ngModel.$render();\n }\n });\n if (isForm(element)) {\n element.on('change', function () {\n haveChangeOnElement = true;\n });\n }\n var onChange = function (pristine) {\n return function () {\n var formPristine;\n if (haveChangeOnElement && !element.is('select')) {\n return;\n }\n if (pristine && ngForm) {\n formPristine = ngForm.$pristine;\n }\n ngModel.$setViewValue(value());\n if (pristine) {\n ngModel.$setPristine();\n if (formPristine) {\n ngForm.$setPristine();\n }\n }\n digest(scope);\n };\n };\n widget.first('change', onChange(false));\n widget.first('spin', onChange(false));\n if (!(kendo.ui.AutoComplete && widget instanceof kendo.ui.AutoComplete)) {\n widget.first('dataBound', onChange(true));\n }\n var currentVal = value();\n if (!isNaN(ngModel.$viewValue) && currentVal != ngModel.$viewValue) {\n if (!ngModel.$isEmpty(ngModel.$viewValue)) {\n widget.value(ngModel.$viewValue);\n } else if (currentVal != null && currentVal !== '' && currentVal != ngModel.$viewValue) {\n ngModel.$setViewValue(currentVal);\n }\n }\n ngModel.$setPristine();\n }\n function bindToKNgModel(widget, scope, kNgModel) {\n if (kendo.ui.DateRangePicker && widget instanceof kendo.ui.DateRangePicker) {\n var rangePickerModels = kNgModel.split(',');\n var rangePickerStartModel = rangePickerModels[0].trim();\n var rangePickerEndModel;\n bindToKNgModel(widget._startDateInput, scope, rangePickerStartModel);\n if (rangePickerModels[1]) {\n rangePickerEndModel = rangePickerModels[1].trim();\n bindToKNgModel(widget._endDateInput, scope, rangePickerEndModel);\n widget.range({\n start: scope[rangePickerStartModel],\n end: scope[rangePickerEndModel]\n });\n } else {\n widget.range({\n start: scope[rangePickerStartModel],\n end: null\n });\n }\n return;\n }\n if (typeof widget.value != 'function') {\n $log.warn('k-ng-model specified on a widget that does not have the value() method: ' + widget.options.name);\n return;\n }\n var form = $(widget.element).parents('ng-form, form').first();\n var ngForm = kendo.getter(form.attr('name'), true)(scope);\n var getter = $parse(kNgModel);\n var setter = getter.assign;\n var updating = false;\n var valueIsCollection = kendo.ui.MultiSelect && widget instanceof kendo.ui.MultiSelect || kendo.ui.RangeSlider && widget instanceof kendo.ui.RangeSlider;\n var length = function (value) {\n return value && valueIsCollection ? value.length : 0;\n };\n var currentValueLength = length(getter(scope));\n widget.$angular_setLogicValue(getter(scope));\n var watchHandler = function (newValue, oldValue) {\n if (newValue === undefined) {\n newValue = null;\n }\n if (updating || newValue == oldValue && length(newValue) == currentValueLength) {\n return;\n }\n currentValueLength = length(newValue);\n widget.$angular_setLogicValue(newValue);\n };\n if (valueIsCollection) {\n scope.$watchCollection(kNgModel, watchHandler);\n } else {\n scope.$watch(kNgModel, watchHandler);\n }\n var changeHandler = function () {\n updating = true;\n if (ngForm && ngForm.$pristine) {\n ngForm.$setDirty();\n }\n digest(scope, function () {\n setter(scope, widget.$angular_getLogicValue());\n currentValueLength = length(getter(scope));\n });\n updating = false;\n };\n widget.first('change', changeHandler);\n widget.first('spin', changeHandler);\n }\n function destroyWidgetOnScopeDestroy(scope, widget) {\n var deregister = scope.$on('$destroy', function () {\n deregister();\n if (widget) {\n kendo.destroy(widget.element);\n widget = null;\n }\n });\n return deregister;\n }\n function propagateClassToWidgetWrapper(widget, element) {\n if (!(window.MutationObserver && widget.wrapper)) {\n return;\n }\n var prevClassList = [].slice.call($(element)[0].classList);\n var mo = new MutationObserver(function (changes) {\n suspend();\n if (!widget) {\n return;\n }\n changes.forEach(function (chg) {\n var w = $(widget.wrapper)[0];\n switch (chg.attributeName) {\n case 'class':\n var currClassList = [].slice.call(chg.target.classList);\n currClassList.forEach(function (cls) {\n if (prevClassList.indexOf(cls) < 0) {\n w.classList.add(cls);\n if (kendo.ui.ComboBox && widget instanceof kendo.ui.ComboBox) {\n widget.input[0].classList.add(cls);\n }\n }\n });\n prevClassList.forEach(function (cls) {\n if (currClassList.indexOf(cls) < 0) {\n w.classList.remove(cls);\n if (kendo.ui.ComboBox && widget instanceof kendo.ui.ComboBox) {\n widget.input[0].classList.remove(cls);\n }\n }\n });\n prevClassList = currClassList;\n break;\n case 'disabled':\n if (typeof widget.enable == 'function' && !widget.element.attr('readonly')) {\n widget.enable(!$(chg.target).attr('disabled'));\n }\n break;\n case 'readonly':\n if (typeof widget.readonly == 'function' && !widget.element.attr('disabled')) {\n widget.readonly(!!$(chg.target).attr('readonly'));\n }\n break;\n }\n });\n resume();\n });\n function suspend() {\n mo.disconnect();\n }\n function resume() {\n mo.observe($(element)[0], { attributes: true });\n }\n resume();\n widget.first('destroy', suspend);\n }\n function setupRebind(widget, scope, element, originalElement, rebindAttr, destroyRegister, attrs) {\n var unregister = scope.$watch(rebindAttr, function (newValue, oldValue) {\n if (!widget._muteRebind && newValue !== oldValue) {\n unregister();\n if (attrs._cleanUp) {\n attrs._cleanUp();\n }\n var templateOptions = WIDGET_TEMPLATE_OPTIONS[widget.options.name];\n if (templateOptions) {\n templateOptions.forEach(function (name) {\n var templateContents = scope.$eval(attrs['k' + name]);\n if (templateContents) {\n originalElement.append($(templateContents).attr(kendo.toHyphens('k' + name), ''));\n }\n });\n }\n var _wrapper = $(widget.wrapper)[0];\n var _element = $(widget.element)[0];\n var isUpload = widget.options.name === 'Upload';\n if (isUpload) {\n element = $(_element);\n }\n var compile = element.injector().get('$compile');\n widget._destroy();\n if (destroyRegister) {\n destroyRegister();\n }\n widget = null;\n if (_element) {\n if (_wrapper) {\n _wrapper.parentNode.replaceChild(_element, _wrapper);\n }\n $(element).replaceWith(originalElement);\n }\n compile(originalElement)(scope);\n }\n }, true);\n digest(scope);\n }\n function bind(f, obj) {\n return function (a, b) {\n return f.call(obj, a, b);\n };\n }\n function setTemplate(key, value) {\n this[key] = kendo.stringify(value);\n }\n module.factory('directiveFactory', [\n '$compile',\n function (compile) {\n var kendoRenderedTimeout;\n var RENDERED = false;\n $defaultCompile = compile;\n var create = function (role, origAttr) {\n return {\n restrict: 'AC',\n require: [\n '?ngModel',\n '^?form'\n ],\n scope: false,\n controller: [\n '$scope',\n '$attrs',\n '$element',\n function ($scope, $attrs) {\n this.template = bind(setTemplate, $attrs);\n $attrs._cleanUp = bind(function () {\n this.template = null;\n $attrs._cleanUp = null;\n }, this);\n }\n ],\n link: function (scope, element, attrs, controllers) {\n var $element = $(element);\n var roleattr = role.replace(/([A-Z])/g, '-$1');\n $element.attr(roleattr, $element.attr('data-' + roleattr));\n $element[0].removeAttribute('data-' + roleattr);\n var widget = createWidget(scope, element, attrs, role, origAttr, controllers);\n if (!widget) {\n return;\n }\n if (kendoRenderedTimeout) {\n clearTimeout(kendoRenderedTimeout);\n }\n kendoRenderedTimeout = setTimeout(function () {\n scope.$emit('kendoRendered');\n if (!RENDERED) {\n RENDERED = true;\n $('form').each(function () {\n var form = $(this).controller('form');\n if (form) {\n form.$setPristine();\n }\n });\n }\n });\n }\n };\n };\n return { create: create };\n }\n ]);\n var TAGNAMES = {\n Editor: 'textarea',\n NumericTextBox: 'input',\n DatePicker: 'input',\n DateTimePicker: 'input',\n TimePicker: 'input',\n AutoComplete: 'input',\n ColorPicker: 'input',\n MaskedTextBox: 'input',\n MultiSelect: 'input',\n Upload: 'input',\n Validator: 'form',\n Button: 'button',\n MobileButton: 'a',\n MobileBackButton: 'a',\n MobileDetailButton: 'a',\n ListView: 'ul',\n MobileListView: 'ul',\n ScrollView: 'div',\n PanelBar: 'ul',\n TreeView: 'ul',\n Menu: 'ul',\n ContextMenu: 'ul',\n ActionSheet: 'ul',\n Switch: 'input'\n };\n var SKIP_SHORTCUTS = [\n 'MobileView',\n 'MobileDrawer',\n 'MobileLayout',\n 'MobileSplitView',\n 'MobilePane',\n 'MobileModalView'\n ];\n var MANUAL_DIRECTIVES = [\n 'MobileApplication',\n 'MobileView',\n 'MobileModalView',\n 'MobileLayout',\n 'MobileActionSheet',\n 'MobileDrawer',\n 'MobileSplitView',\n 'MobilePane',\n 'MobileScrollView',\n 'MobilePopOver'\n ];\n angular.forEach([\n 'MobileNavBar',\n 'MobileButton',\n 'MobileBackButton',\n 'MobileDetailButton',\n 'MobileTabStrip',\n 'MobileScrollView',\n 'MobileScroller'\n ], function (widget) {\n MANUAL_DIRECTIVES.push(widget);\n widget = 'kendo' + widget;\n module.directive(widget, function () {\n return {\n restrict: 'A',\n link: function (scope, element, attrs) {\n createWidget(scope, element, attrs, widget, widget);\n }\n };\n });\n });\n function createDirectives(klass, isMobile) {\n function make(directiveName, widgetName) {\n module.directive(directiveName, [\n 'directiveFactory',\n function (directiveFactory) {\n return directiveFactory.create(widgetName, directiveName);\n }\n ]);\n }\n var name = isMobile ? 'Mobile' : '';\n name += klass.fn.options.name;\n var className = name;\n var shortcut = 'kendo' + name.charAt(0) + name.substr(1).toLowerCase();\n name = 'kendo' + name;\n var dashed = name.replace(/([A-Z])/g, '-$1');\n if (SKIP_SHORTCUTS.indexOf(name.replace('kendo', '')) == -1) {\n var names = name === shortcut ? [name] : [\n name,\n shortcut\n ];\n angular.forEach(names, function (directiveName) {\n module.directive(directiveName, function () {\n return {\n restrict: 'E',\n replace: true,\n template: function (element, attributes) {\n var tag = TAGNAMES[className] || 'div';\n var scopeField = attributes.kScopeField || attributes.scopeField;\n return '<' + tag + ' ' + dashed + (scopeField ? '=\"' + scopeField + '\"' : '') + '>' + element.html() + '';\n }\n };\n });\n });\n }\n if (MANUAL_DIRECTIVES.indexOf(name.replace('kendo', '')) > -1) {\n return;\n }\n make(name, name);\n if (shortcut != name) {\n make(shortcut, name);\n }\n }\n function kendoWidgetInstance(el) {\n el = $(el);\n return kendo.widgetInstance(el, kendo.ui) || kendo.widgetInstance(el, kendo.mobile.ui) || kendo.widgetInstance(el, kendo.dataviz.ui);\n }\n function digest(scope, func) {\n var root = scope.$root || scope;\n var isDigesting = /^\\$(digest|apply)$/.test(root.$$phase);\n if (func) {\n if (isDigesting) {\n func();\n } else {\n root.$apply(func);\n }\n } else if (!isDigesting) {\n root.$digest();\n }\n }\n function destroyScope(scope, el) {\n scope.$destroy();\n if (el) {\n $(el).removeData('$scope').removeData('$$kendoScope').removeData('$isolateScope').removeData('$isolateScopeNoTemplate').removeClass('ng-scope');\n }\n }\n var encode = kendo.htmlEncode;\n var open = /{{/g;\n var close = /}}/g;\n var encOpen = '{​{';\n var encClose = '}​}';\n kendo.htmlEncode = function (str) {\n return encode(str).replace(open, encOpen).replace(close, encClose);\n };\n var pendingPatches = [];\n function defadvice(klass, methodName, func) {\n if ($.isArray(klass)) {\n return angular.forEach(klass, function (klass) {\n defadvice(klass, methodName, func);\n });\n }\n if (typeof klass == 'string') {\n var a = klass.split('.');\n var x = kendo;\n while (x && a.length > 0) {\n x = x[a.shift()];\n }\n if (!x) {\n pendingPatches.push([\n klass,\n methodName,\n func\n ]);\n return false;\n }\n klass = x.prototype;\n }\n var origMethod = klass[methodName];\n klass[methodName] = function () {\n var self = this, args = arguments;\n return func.apply({\n self: self,\n next: function () {\n return origMethod.apply(self, arguments.length > 0 ? arguments : args);\n }\n }, args);\n };\n return true;\n }\n kendo.onWidgetRegistered(function (entry) {\n pendingPatches = $.grep(pendingPatches, function (args) {\n return !defadvice.apply(null, args);\n });\n createDirectives(entry.widget, entry.prefix == 'Mobile');\n });\n defadvice([\n 'ui.Widget',\n 'mobile.ui.Widget'\n ], 'angular', function (cmd, arg) {\n var self = this.self;\n if (cmd == 'init') {\n if (!arg && OPTIONS_NOW) {\n arg = OPTIONS_NOW;\n }\n OPTIONS_NOW = null;\n if (arg && arg.$angular) {\n self.$angular_scope = arg.$angular[0];\n self.$angular_init(self.element, arg);\n }\n return;\n }\n var scope = self.$angular_scope;\n if (scope) {\n withoutTimeout(function () {\n var x = arg(), elements = x.elements, data = x.data;\n if (elements.length > 0) {\n switch (cmd) {\n case 'cleanup':\n angular.forEach(elements, function (el) {\n var itemScope = $(el).data('$$kendoScope');\n if (itemScope && itemScope !== scope && itemScope.$$kendoScope) {\n destroyScope(itemScope, el);\n }\n });\n break;\n case 'compile':\n var injector = self.element.injector();\n var compile = injector ? injector.get('$compile') : $defaultCompile;\n angular.forEach(elements, function (el, i) {\n var itemScope;\n if (x.scopeFrom) {\n itemScope = x.scopeFrom;\n } else {\n var vars = data && data[i];\n if (vars !== undefined) {\n itemScope = $.extend(scope.$new(), vars);\n itemScope.$$kendoScope = true;\n } else {\n itemScope = scope;\n }\n }\n $(el).data('$$kendoScope', itemScope);\n compile(el)(itemScope);\n });\n digest(scope);\n break;\n }\n }\n });\n }\n });\n defadvice('ui.Widget', '$angular_getLogicValue', function () {\n return this.self.value();\n });\n defadvice('ui.Widget', '$angular_setLogicValue', function (val) {\n this.self.value(val);\n });\n defadvice('ui.Select', '$angular_getLogicValue', function () {\n var item = this.self.dataItem(), valueField = this.self.options.dataValueField;\n if (item) {\n if (this.self.options.valuePrimitive) {\n if (!!valueField) {\n return item[valueField];\n } else {\n return item;\n }\n } else {\n return item.toJSON();\n }\n } else {\n return null;\n }\n });\n defadvice('ui.Select', '$angular_setLogicValue', function (val) {\n var self = this.self;\n var options = self.options;\n var valueField = options.dataValueField;\n var text = options.text || '';\n if (val === undefined) {\n val = '';\n }\n if (valueField && !options.valuePrimitive && val) {\n text = val[options.dataTextField] || '';\n val = val[valueField || options.dataTextField];\n }\n if (self.options.autoBind === false && !self.listView.bound()) {\n if (!text && val && options.valuePrimitive) {\n self.value(val);\n } else {\n self._preselect(val, text);\n }\n } else {\n self.value(val);\n }\n });\n defadvice('ui.MultiSelect', '$angular_getLogicValue', function () {\n var value = this.self.dataItems().slice(0);\n var valueField = this.self.options.dataValueField;\n if (valueField && this.self.options.valuePrimitive) {\n value = $.map(value, function (item) {\n return item[valueField];\n });\n }\n return value;\n });\n defadvice('ui.MultiSelect', '$angular_setLogicValue', function (val) {\n if (val == null) {\n val = [];\n }\n var self = this.self;\n var options = self.options;\n var valueField = options.dataValueField;\n var data = val;\n if (valueField && !options.valuePrimitive) {\n val = $.map(val, function (item) {\n return item[valueField];\n });\n }\n if (options.autoBind === false && !options.valuePrimitive && !self.listView.bound()) {\n self._preselect(data, val);\n } else {\n self.value(val);\n }\n });\n defadvice('ui.Widget', '$angular_init', function (element, options) {\n var self = this.self;\n if (options && !$.isArray(options)) {\n var scope = self.$angular_scope;\n for (var i = self.events.length; --i >= 0;) {\n var event = self.events[i];\n var handler = options[event];\n if (handler && typeof handler == 'string') {\n options[event] = self.$angular_makeEventHandler(event, scope, handler);\n }\n }\n }\n });\n defadvice('ui.Widget', '$angular_makeEventHandler', function (event, scope, handler) {\n handler = $parse(handler);\n return function (e) {\n digest(scope, function () {\n handler(scope, { kendoEvent: e });\n });\n };\n });\n defadvice([\n 'ui.Grid',\n 'ui.ListView',\n 'ui.TreeView',\n 'ui.PanelBar'\n ], '$angular_makeEventHandler', function (event, scope, handler) {\n if (event != 'change') {\n return this.next();\n }\n handler = $parse(handler);\n return function (ev) {\n var widget = ev.sender;\n var options = widget.options;\n var cell, multiple, locals = { kendoEvent: ev }, elems, items, columns, colIdx;\n if (angular.isString(options.selectable)) {\n cell = options.selectable.indexOf('cell') !== -1;\n multiple = options.selectable.indexOf('multiple') !== -1;\n }\n if (widget._checkBoxSelection) {\n multiple = true;\n }\n elems = locals.selected = this.select();\n items = locals.data = [];\n columns = locals.columns = [];\n for (var i = 0; i < elems.length; i++) {\n var item = cell ? elems[i].parentNode : elems[i];\n var dataItem = widget.dataItem(item);\n if (cell) {\n if (angular.element.inArray(dataItem, items) < 0) {\n items.push(dataItem);\n }\n colIdx = angular.element(elems[i]).index();\n if (angular.element.inArray(colIdx, columns) < 0) {\n columns.push(colIdx);\n }\n } else {\n items.push(dataItem);\n }\n }\n if (!multiple) {\n locals.dataItem = locals.data = items[0];\n locals.angularDataItem = kendo.proxyModelSetters(locals.dataItem);\n locals.selected = elems[0];\n }\n digest(scope, function () {\n handler(scope, locals);\n });\n };\n });\n defadvice('ui.Grid', '$angular_init', function (element, options) {\n this.next();\n if (options.columns) {\n var settings = $.extend({}, kendo.Template, options.templateSettings);\n angular.forEach(options.columns, function (col) {\n if (col.field && !col.template && !col.format && !col.values && (col.encoded === undefined || col.encoded)) {\n col.template = '#: ' + kendo.expr(col.field, settings.paramName) + '#';\n }\n });\n }\n });\n {\n defadvice('mobile.ui.ButtonGroup', 'value', function (mew) {\n var self = this.self;\n if (mew != null) {\n self.select(self.element.children('li.km-button').eq(mew));\n self.trigger('change');\n self.trigger('select', { index: self.selectedIndex });\n }\n return self.selectedIndex;\n });\n defadvice('mobile.ui.ButtonGroup', '_select', function () {\n this.next();\n this.self.trigger('change');\n });\n }\n module.directive('kendoMobileApplication', function () {\n return {\n terminal: true,\n link: function (scope, element, attrs) {\n createWidget(scope, element, attrs, 'kendoMobileApplication', 'kendoMobileApplication');\n }\n };\n }).directive('kendoMobileView', function () {\n return {\n scope: true,\n link: {\n pre: function (scope, element, attrs) {\n attrs.defaultOptions = scope.viewOptions;\n attrs._instance = createWidget(scope, element, attrs, 'kendoMobileView', 'kendoMobileView');\n },\n post: function (scope, element, attrs) {\n attrs._instance._layout();\n attrs._instance._scroller();\n }\n }\n };\n }).directive('kendoMobileDrawer', function () {\n return {\n scope: true,\n link: {\n pre: function (scope, element, attrs) {\n attrs.defaultOptions = scope.viewOptions;\n attrs._instance = createWidget(scope, element, attrs, 'kendoMobileDrawer', 'kendoMobileDrawer');\n },\n post: function (scope, element, attrs) {\n attrs._instance._layout();\n attrs._instance._scroller();\n }\n }\n };\n }).directive('kendoMobileModalView', function () {\n return {\n scope: true,\n link: {\n pre: function (scope, element, attrs) {\n attrs.defaultOptions = scope.viewOptions;\n attrs._instance = createWidget(scope, element, attrs, 'kendoMobileModalView', 'kendoMobileModalView');\n },\n post: function (scope, element, attrs) {\n attrs._instance._layout();\n attrs._instance._scroller();\n }\n }\n };\n }).directive('kendoMobileSplitView', function () {\n return {\n terminal: true,\n link: {\n pre: function (scope, element, attrs) {\n attrs.defaultOptions = scope.viewOptions;\n attrs._instance = createWidget(scope, element, attrs, 'kendoMobileSplitView', 'kendoMobileSplitView');\n },\n post: function (scope, element, attrs) {\n attrs._instance._layout();\n }\n }\n };\n }).directive('kendoMobilePane', function () {\n return {\n terminal: true,\n link: {\n pre: function (scope, element, attrs) {\n attrs.defaultOptions = scope.viewOptions;\n createWidget(scope, element, attrs, 'kendoMobilePane', 'kendoMobilePane');\n }\n }\n };\n }).directive('kendoMobileLayout', function () {\n return {\n link: {\n pre: function (scope, element, attrs) {\n createWidget(scope, element, attrs, 'kendoMobileLayout', 'kendoMobileLayout');\n }\n }\n };\n }).directive('kendoMobileActionSheet', function () {\n return {\n restrict: 'A',\n link: function (scope, element, attrs) {\n element.find('a[k-action]').each(function () {\n $(this).attr('data-' + kendo.ns + 'action', $(this).attr('k-action'));\n });\n createWidget(scope, element, attrs, 'kendoMobileActionSheet', 'kendoMobileActionSheet');\n }\n };\n }).directive('kendoMobilePopOver', function () {\n return {\n terminal: true,\n link: {\n pre: function (scope, element, attrs) {\n attrs.defaultOptions = scope.viewOptions;\n createWidget(scope, element, attrs, 'kendoMobilePopOver', 'kendoMobilePopOver');\n }\n }\n };\n }).directive('kendoViewTitle', function () {\n return {\n restrict: 'E',\n replace: true,\n template: function (element) {\n return '' + element.html() + '';\n }\n };\n }).directive('kendoMobileHeader', function () {\n return {\n restrict: 'E',\n link: function (scope, element) {\n element.addClass('km-header').attr('data-role', 'header');\n }\n };\n }).directive('kendoMobileFooter', function () {\n return {\n restrict: 'E',\n link: function (scope, element) {\n element.addClass('km-footer').attr('data-role', 'footer');\n }\n };\n }).directive('kendoMobileScrollViewPage', function () {\n return {\n restrict: 'E',\n replace: true,\n template: function (element) {\n return '
      ' + element.html() + '
      ';\n }\n };\n });\n angular.forEach([\n 'align',\n 'icon',\n 'rel',\n 'transition',\n 'actionsheetContext'\n ], function (attr) {\n var kAttr = 'k' + attr.slice(0, 1).toUpperCase() + attr.slice(1);\n module.directive(kAttr, function () {\n return {\n restrict: 'A',\n priority: 2,\n link: function (scope, element, attrs) {\n element.attr(kendo.attr(kendo.toHyphens(attr)), scope.$eval(attrs[kAttr]));\n }\n };\n });\n });\n var WIDGET_TEMPLATE_OPTIONS = {\n 'TreeMap': ['Template'],\n 'MobileListView': [\n 'HeaderTemplate',\n 'Template'\n ],\n 'MobileScrollView': [\n 'EmptyTemplate',\n 'Template'\n ],\n 'Grid': [\n 'AltRowTemplate',\n 'DetailTemplate',\n 'RowTemplate'\n ],\n 'ListView': [\n 'EditTemplate',\n 'Template',\n 'AltTemplate'\n ],\n 'Pager': [\n 'SelectTemplate',\n 'LinkTemplate'\n ],\n 'PivotGrid': [\n 'ColumnHeaderTemplate',\n 'DataCellTemplate',\n 'RowHeaderTemplate'\n ],\n 'Scheduler': [\n 'AllDayEventTemplate',\n 'DateHeaderTemplate',\n 'EventTemplate',\n 'MajorTimeHeaderTemplate',\n 'MinorTimeHeaderTemplate'\n ],\n 'ScrollView': ['Template'],\n 'PanelBar': ['Template'],\n 'TreeView': ['Template'],\n 'Validator': ['ErrorTemplate']\n };\n (function () {\n var templateDirectives = {};\n angular.forEach(WIDGET_TEMPLATE_OPTIONS, function (templates, widget) {\n angular.forEach(templates, function (template) {\n if (!templateDirectives[template]) {\n templateDirectives[template] = [];\n }\n templateDirectives[template].push('?^^kendo' + widget);\n });\n });\n angular.forEach(templateDirectives, function (parents, directive) {\n var templateName = 'k' + directive;\n var attrName = kendo.toHyphens(templateName);\n module.directive(templateName, function () {\n return {\n restrict: 'A',\n require: parents,\n terminal: true,\n compile: function ($element, $attrs) {\n if ($attrs[templateName] !== '') {\n return;\n }\n $element.removeAttr(attrName);\n var template = $element[0].outerHTML;\n return function (scope, element, attrs, controllers) {\n var controller;\n while (!controller && controllers.length) {\n controller = controllers.shift();\n }\n if (!controller) {\n $log.warn(attrName + ' without a matching parent widget found. It can be one of the following: ' + parents.join(', '));\n } else {\n controller.template(templateName, template);\n element.remove();\n }\n };\n }\n };\n });\n });\n }());\n }(window.kendo.jQuery, window.angular));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));\n(function (f, define) {\n define('kendo.mobile', [\n 'kendo.core',\n 'kendo.fx',\n 'kendo.data.odata',\n 'kendo.data.xml',\n 'kendo.data',\n 'kendo.data.signalr',\n 'kendo.binder',\n 'kendo.validator',\n 'kendo.router',\n 'kendo.view',\n 'kendo.userevents',\n 'kendo.draganddrop',\n 'kendo.popup',\n 'kendo.touch',\n 'kendo.mobile.popover',\n 'kendo.mobile.loader',\n 'kendo.mobile.scroller',\n 'kendo.mobile.shim',\n 'kendo.mobile.view',\n 'kendo.mobile.modalview',\n 'kendo.mobile.drawer',\n 'kendo.mobile.splitview',\n 'kendo.mobile.pane',\n 'kendo.mobile.application',\n 'kendo.mobile.actionsheet',\n 'kendo.mobile.button',\n 'kendo.mobile.buttongroup',\n 'kendo.mobile.collapsible',\n 'kendo.mobile.listview',\n 'kendo.mobile.navbar',\n 'kendo.mobile.scrollview',\n 'kendo.mobile.switch',\n 'kendo.mobile.tabstrip',\n 'kendo.angular'\n ], f);\n}(function () {\n 'bundle all';\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));"]}