text: /*! 
  * DevExpress Mobile Widgets (part of PhoneJS)
  * Version: 13.2.7
  * Build date: Feb 10, 2014
  *
  * Copyright (c) 2012 - 2014 Developer Express Inc. ALL RIGHTS RESERVED
  * EULA: http://phonejs.devexpress.com/EULA
  */
  "use strict";if(!DevExpress.MOD_WIDGETS){if(!window.DevExpress)throw Error("Required module is not referenced: core");(function(n,t){var r=t.ui,e="dxScrollable",o="dx-scrollable",s="dx-scrollable-disabled",h="dx-scrollable-container",c="dx-scrollable-content",u="vertical",f="horizontal",l="both";r.registerComponent(e,r.Component.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{scrollAction:null,direction:u,showScrollbar:!0,useNative:!0,updateAction:null,useSimulatedScrollBar:!1,inertiaEnabled:!0,bounceEnabled:!0,startAction:null,endAction:null,bounceAction:null,stopAction:null})},_init:function(){this.callBase(),this._initMarkup(),this._attachWindowResizeCallback(),this._attachNativeScrollbarsCustomizationCss(),this._locked=!1},_initMarkup:function(){var t=this._element().addClass(o),i=this._$container=n("<div>").addClass(h),r=this._$content=n("<div>").addClass(c);r.append(t.contents()).appendTo(i),i.appendTo(t)},_attachWindowResizeCallback:function(){var n=this;n._windowResizeCallback=function(){n.update()},t.utils.windowResizeCallbacks.add(n._windowResizeCallback)},_attachNativeScrollbarsCustomizationCss:function(){navigator.platform.indexOf("Mac")>-1&&DevExpress.browser.webkit||this._element().addClass("dx-scrollable-customizable-scrollbars")},_render:function(){this.callBase(),this._renderDisabledState(),this._renderDirection(),this._createStrategy(),this._createActions(),this.update()},_renderDisabledState:function(){this._$element.toggleClass(s,this.option("disabled"))},_renderDirection:function(){this._element().removeClass("dx-scrollable-"+f).removeClass("dx-scrollable-"+u).removeClass("dx-scrollable-"+l).addClass("dx-scrollable-"+this.option("direction"))},_createStrategy:function(){this._strategy=this.option("useNative")||t.designMode?new r.NativeScrollableStrategy(this):new r.SimulatedScrollableStrategy(this),this._strategy.render()},_createActions:function(){this._strategy.createActions()},_clean:function(){this._strategy.dispose()},_dispose:function(){this._detachWindowResizeCallback(),this.callBase()},_detachWindowResizeCallback:function(){t.utils.windowResizeCallbacks.remove(this._windowResizeCallback)},_optionChanged:function(n){switch(n){case"disabled":this._renderDisabledState();break;case"startAction":case"endAction":case"stopAction":case"updateAction":case"scrollAction":case"bounceAction":this._createActions();break;case"direction":case"showScrollbar":case"useSimulatedScrollBar":this._invalidate();break;default:this.callBase.apply(this,arguments)}},_location:function(){return this._strategy.location()},_normalizeLocation:function(t){var i=this.option("direction");return{x:n.isPlainObject(t)?-t.x||0:i!==u?-t:0,y:n.isPlainObject(t)?-t.y||0:i!==f?-t:0}},_isLocked:function(){return this._locked},_lock:function(){this._locked=!0},_unlock:function(){this._locked=!1},content:function(){return this._$content},scrollOffset:function(){var n=this._location();return{top:-n.top,left:-n.left}},clientHeight:function(){return this._$container.height()},scrollHeight:function(){return this.content().height()},clientWidth:function(){return this._$container.width()},scrollWidth:function(){return this.content().width()},update:function(){return this._strategy.update(),n.Deferred().resolve().promise()},scrollBy:function(n){n=this._normalizeLocation(n),this._strategy.scrollBy(n)},scrollTo:function(n){n=this._normalizeLocation(n);var t=this._location();this.scrollBy({x:t.left-n.x,y:t.top-n.y})}}))})(jQuery,DevExpress),function(n,t){var r=t.ui,f="dxScrollbar",e="dx-scrollable-scrollbar",o="dx-scrollable-scroll",s="dx-scrollable-scrollbars-hidden",h="vertical",u="horizontal";r.registerComponent(f,r.Widget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{direction:null,visible:!1,activeStateEnabled:!1})},_renderThumb:function(){this._$thumb=n("<div>").addClass(o),this._element().addClass(e).append(this._$thumb)},_render:function(){this._renderThumb(),this.callBase();var n=this.option("direction");this._element().addClass("dx-scrollbar-"+n),this._dimension=n===u?"width":"height",this._prop=n===u?"left":"top"},_renderDimensions:function(){this._$thumb.height(this.option("height")),this._$thumb.width(this.option("width"))},_toggleVisibility:function(n){n=n&&this._containerToContentRatio<1,this._$thumb.toggleClass("dx-state-invisible",!n)},moveTo:function(i){n.isPlainObject(i)&&(i=i[this._prop]||0);var r={};r[this._prop]=this._calculateScrollBarPosition(i),t.translator.move(this._$thumb,r)},_calculateScrollBarPosition:function(n){return-n*this._containerToContentRatio},update:function(n,t){n=this._normalizeSize(n),t=this._normalizeSize(t),this._containerToContentRatio=n/t;var i=n*this._containerToContentRatio;this.option(this._dimension,i)},_normalizeSize:function(t){return n.isPlainObject(t)?t[this._dimension]||0:t}}))}(jQuery,DevExpress),function(n,t,i){var f=t.ui,u=f.events,y=t.devices,p=Math.abs,e="dxNativeScrollable",a="dx-scrollable-native",tt="dx-scrollable-scrollbar-simulated",it="dx-scrollable-scrollbars-hidden",o="vertical",h="horizontal",rt=500,w="dxGesture";f.NativeScrollableStrategy=t.Class.inherit({ctor:function(n){this._init(n),this._attachScrollHandler()},_init:function(t){this._component=t,this._$element=t._element(),this._$container=t._$container,this._$content=t._$content,this.option=n.proxy(t.option,t),this._createActionByOption=n.proxy(t._createActionByOption,t),this._useSimulatedScrollBar=t.option("useSimulatedScrollBar"),this._direction=t.option("direction"),this._isLocked=n.proxy(t._isLocked,t)},_attachScrollHandler:function(){n(this._$container).on(u.addNamespace("scroll",e),n.proxy(this._handleScroll,this))},render:function(){this._$element.addClass(a),this._$element.addClass(a+"-"+y.real.platform),this._renderScrollbar()},_renderScrollbar:function(){var t,i;(this._scrollbars={},this._$element.toggleClass(it,!this.option("showScrollbar")),this.option("showScrollbar"))&&this._useSimulatedScrollBar&&(this._direction!==h&&(t=n("<div>").dxScrollbar({direction:o,disable:this._useSimulatedScrollBar}).appendTo(this._$element),this._scrollbars[o]=t.dxScrollbar("instance")),this._direction!==o&&(i=n("<div>").dxScrollbar({direction:h,disable:this._useSimulatedScrollBar}).appendTo(this._$element),this._scrollbars[o]=i.dxScrollbar("instance")),this._hideScrollbarTimeout=0,this._$element.addClass(tt))},createActions:function(){var n={excludeValidators:["gesture"]};this._scrollAction=this._createActionByOption("scrollAction",n),this._updateAction=this._createActionByOption("updateAction",n)},_createActionArgs:function(){var n=this.location();return{jQueryEvent:k,scrollOffset:{top:-n.top,left:-n.left},reachedLeft:this._direction!==o?n.left>=0:i,reachedRight:this._direction!==o?n.left<=this._containerSize.width-this._contentSize.width:i,reachedTop:this._direction!==h?n.top>=0:i,reachedBottom:this._direction!==h?n.top<=this._containerSize.height-this._contentSize.height:i}},dispose:function(){this===r&&(r=null),n(this._$container).off(u.addNamespace("scroll",e)),this._removeScrollbars(),clearTimeout(this._gestureEndTimer)},_removeScrollbars:function(){n.each(this._scrollbars,function(){this._element().remove()})},_handleScroll:function(n){if(!this._isScrollLocationChanged()){n.stopImmediatePropagation();return}k=n,this._moveScrollbars(),this._scrollAction(this._createActionArgs()),this._treatNativeGesture(),this._lastLocation=this.location()},_isScrollLocationChanged:function(){var n=this.location(),t=this._lastLocation||{},i=t.top!==n.top,r=t.left!==n.left;return i||r},_moveScrollbars:function(){var t=this;n.each(t._scrollbars,function(){this.moveTo(t.location()),this.option("visible",!0)}),this._hideScrollbars()},_hideScrollbars:function(){var t=this;clearTimeout(t._hideScrollbarTimeout),t._hideScrollbarTimeout=setTimeout(function(){n.each(t._scrollbars,function(){this.option("visible",!1)})},rt)},_treatNativeGesture:function(){this._prepareGesture(),this._forgetGesture()},_prepareGesture:function(){this._gestureEndTimer?(clearTimeout(this._gestureEndTimer),this._gestureEndTimer=null):this._$element.data(w,!0),f.feedback.reset()},_forgetGesture:function(){this._gestureEndTimer=setTimeout(n.proxy(function(){this._$element.data(w,!1),this._gestureEndTimer=null},this),400)},location:function(){return{left:-this._$container.scrollLeft(),top:-this._$container.scrollTop()}},update:function(){this._updateDimensions(),this._updateAction(this._createActionArgs()),this._updateScrollbars()},_updateDimensions:function(){this._containerSize={height:this._$container.height(),width:this._$container.width()},this._contentSize={height:this._component.content().height(),width:this._component.content().width()}},_updateScrollbars:function(){if(this._useSimulatedScrollBar){var t=this,i=this._containerSize,r=this._contentSize;n.each(t._scrollbars,function(){this.update(i,r)})}},_handleStart:n.noop,_handleMove:n.noop,_handleEnd:n.noop,scrollBy:function(n){var t=this.location();this._$container.scrollTop(-t.top-n.y),this._$container.scrollLeft(-t.left-n.x)}});var b=0,v=1,ut=2,r,s=b,c,k,l=null,d=10,g=function(t){var i=n(t).closest("."+a),u,r;if(i.length)return u=i.data("dxComponents"),n.each(u,function(n,t){var u=f[t];if(u===f.dxScrollable||u.subclassOf(f.dxScrollable))return r=i.data(t),!1}),r&&r.option("disabled")?g(i.parent()):r._strategy},ft=function(){s=b,r=null},et=function(i){if(y.real.platform==="ios"){var u=n(":focus",r._$element).length,f=n(i.target).closest("textarea").length;u&&!f&&t.utils.resetActiveElement()}},ot=function(n){u.needSkipEvent(n)||(r=g(n.target),r&&(c=r._$element.parents().length,s=v,r._handleStart(n),l=u.eventData(n)))},st=function(n){if(r&&s==v&&n.originalEvent){var t=n.originalEvent.pointerMoveData||{},i=r.option("direction"),u=t[i];if(u&&u>c){nt();return}t[i]=c,n.originalEvent.pointerMoveData=t}},ht=function(n){var t,f,i;if(r){if(t=n.originalEvent.pointerMoveData,f=r.option("direction"),t&&t[f]!==c)return;if(n.originalEvent.isScrollingEvent=!0,r._isLocked()){n.preventDefault();return}s==v&&(et(n),s=ut),r._handleMove(n),l&&(i=u.eventDelta(l,u.eventData(n)),(p(i.x)>d||p(i.y)>d)&&(r._prepareGesture(),l=null))}},nt=function(n){r&&(r._handleEnd(n),r._forgetGesture(),ft())};n(function(){var i={context:f.dxScrollable,excludeValidators:["gesture","designMode"]},r=new t.Action(ot,i),o=new t.Action(ht,i),s=new t.Action(nt,i),h=new t.Action(st,i);n("body").on(u.addNamespace("dxpointermove",e),function(n){h.execute(n)});n(document).on(u.addNamespace("dxpointerdown",e),function(n){r.execute(n)}).on(u.addNamespace("dxpointermove",e),function(n){o.execute(n)}).on(u.addNamespace("dxpointerup dxpointercancel",e),function(n){s.execute(n)})})}(jQuery,DevExpress),function(n,t,i){var o=t.ui,u=o.events,f=Math,s="dxSimulatedScrollable",tt="dx-scrollable-simulated",fi="dxScrollbar",ei="dx-scrollable-scrollbar",oi="dx-scrollable-scroll",lt="dx-scrollable-scrollbars-hidden",k="vertical",h="horizontal",l=.92,it=.5,at=400,rt=1,vt=rt/5,d=f.round(1e3/60),yt=at/d,pt=(1-f.pow(l,yt))/(1-l),wt=it,ut="dxGesture",ft=t.Animator.inherit({ctor:function(n){this.callBase(),this.scroller=n},VELOCITY_LIMIT:rt,_isFinished:function(){return f.abs(this.scroller._velocity)<=this.VELOCITY_LIMIT},_step:function(){this.scroller._scrollStep(this.scroller._velocity),this.scroller._velocity*=this._acceleration()},_acceleration:function(){return this.scroller._inBounds()?l:it},_complete:function(){this.scroller._scrollComplete()},_stop:function(){this.scroller._handleStop()}}),bt=ft.inherit({VELOCITY_LIMIT:vt,_isFinished:function(){return this.scroller._crossBoundOnNextStep()||this.callBase()},_acceleration:function(){return l},_complete:function(){this.scroller._move(this.scroller._bounceLocation),this.callBase()}}),kt=o.Scroller=t.Class.inherit({ctor:function(n){this._initOptions(n),this._initAnimators(),this._initScrollbar(),this._initCallbacks(),this._topReached=!1,this._bottomReached=!1},_initOptions:function(t){var i=this;this._location=0,this._axis=t.direction===h?"x":"y",this._prop=t.direction===h?"left":"top",this._dimension=t.direction===h?"width":"height",this._scrollProp=t.direction===h?"scrollLeft":"scrollTop",n.each(t,function(n,t){i["_"+n]=t})},_initAnimators:function(){this._inertiaAnimator=new ft(this),this._bounceAnimator=new bt(this)},_initScrollbar:function(){this._$scrollbar=n("<div>").dxScrollbar({direction:this._direction}).appendTo(this._$container),this._scrollbar=this._$scrollbar.dxScrollbar("instance")},_initCallbacks:function(){this.topBouncedCallbacks=n.Callbacks(),this.bottomBouncedCallbacks=n.Callbacks()},_scrollStep:function(n){this._location=this._location+n,this._suppressBounce(),this._move(),this._scrollAction()},_move:function(n){this._location=n!==i?n:this._location,this._moveContent(),this._moveScrollbar()},_moveContent:function(){var n={};n[this._prop]=this._location,t.translator.move(this._$content,n)},_moveScrollbar:function(){this._scrollbar.moveTo(this._calculateScrollBarPosition())},_calculateScrollBarPosition:function(){return this._location},_suppressBounce:function(){this._bounceEnabled||this._inBounds(this._location)||(this._velocity=0,this._location=this._boundLocation())},_boundLocation:function(){var n=this._location;return n>this._maxOffset?n=this._maxOffset:n<this._minOffset&&(n=this._minOffset),n},_scrollComplete:function(){this._inBounds()&&(this._hideScrollbar(),this._roundLocation(),this._completeDeferred&&this._completeDeferred.resolve()),this._scrollToBounds()},_roundLocation:function(){this._location=f.round(this._location),this._move()},_scrollToBounds:function(){this._inBounds()||(this._bounceAction(),this._setupBounce(),this._bounceAnimator.start())},_setupBounce:function(){var n=this._bounceLocation=this._boundLocation(),t=n-this._location;this._velocity=t/pt},_inBounds:function(n){return n=n!==i?n:this._location,n>=this._minOffset&&n<=this._maxOffset},_crossBoundOnNextStep:function(){var n=this._location,t=n+this._velocity;return n<this._minOffset&&t>=this._minOffset||n>this._maxOffset&&t<=this._maxOffset},_handleStart:function(){return this._stopDeferred=n.Deferred(),this._stopScrolling(),this._update(),this._stopDeferred.promise()},_stopScrolling:function(){this._hideScrollbar(),this._inertiaAnimator.stop(),this._bounceAnimator.stop()},_handleStop:function(){this._stopDeferred&&this._stopDeferred.resolve()},_handleFirstMove:function(){this._showScrollbar()},_handleMove:function(n){n=n[this._axis],this._inBounds()||(n*=wt),this._scrollStep(n)},_handleMoveEnd:function(t){return this._completeDeferred=n.Deferred(),this._velocity=t[this._axis],this._suppressVelocity(),this._handleInertia(),this._completeDeferred.promise()},_suppressVelocity:function(){this._inertiaEnabled||(this._velocity=0)},_handleTapEnd:function(){this._scrollToBounds()},_handleInertia:function(){this._inertiaAnimator.start()},_handleDispose:function(){this._$scrollbar.remove()},_handleUpdate:function(){this._update(),this._moveToBounds()},_update:function(){this._stopScrolling(),this._updateLocation(),this._updateBounds(),this._updateScrollbar(),this._moveScrollbar()},_updateLocation:function(){this._location=t.translator.locate(this._$content)[this._prop]},_updateBounds:function(){this._maxOffset=0,this._minOffset=f.min(this._containerSize()-this._contentSize(),0)},_updateScrollbar:function(){this._scrollbar.update(this._containerSize(),this._contentSize())},_moveToBounds:function(){this._location=this._boundLocation(),this._move()},_handleCreateActions:function(n){this._scrollAction=n.scrollAction,this._bounceAction=n.bounceAction},_showScrollbar:function(){this._scrollbar.option("visible",this._scrollbarVisible)},_hideScrollbar:function(){this._scrollbar.option("visible",!1)},_containerSize:function(){return this._$container[this._dimension]()},_contentSize:function(){return this._$content[this._dimension]()},_validateTarget:function(n){return n.closest(this._$container)},_validateDirection:function(n){return f.abs(n[this._axis])>=f.abs(n[this._axis==="x"?"y":"x"])},_reachedMin:function(){return this._location<=this._minOffset},_reachedMax:function(){return this._location>=this._maxOffset}});o.SimulatedScrollableStrategy=t.Class.inherit({ctor:function(n){this._init(n),this._attachScrollHandler()},_init:function(t){this._component=t,this._$element=t._element(),this._$container=t._$container,this._$content=t._$content,this.option=n.proxy(t.option,t),this._createActionByOption=n.proxy(t._createActionByOption,t),this._isLocked=n.proxy(t._isLocked,t)},_attachScrollHandler:function(){n(this._$container).on(u.addNamespace("scroll",s),n.proxy(this._handleScroll,this))},_handleScroll:function(){var t={x:this._$container.scrollLeft(),y:this._$container.scrollTop()};this._$container.scrollLeft(-t.x),this._$container.scrollTop(-t.y),this.scrollBy(t)},render:function(){this._$element.addClass(tt),this._createScrollers()},_createScrollers:function(){var n=this.option("direction");this._scrollers={},n!==k&&this._createScroller(h),n!==h&&this._createScroller(k),this._$element.toggleClass(lt,!this.option("showScrollbar"))},_createScroller:function(n){this._scrollers[n]=new kt(this._scrollerOptions(n))},_scrollerOptions:function(n){return{direction:n,$content:this._$content,$container:this._$container,scrollbarVisible:this.option("showScrollbar"),bounceEnabled:this.option("bounceEnabled"),inertiaEnabled:this.option("inertiaEnabled")}},createActions:function(){this._startAction=this._createActionHandler("startAction"),this._stopAction=this._createActionHandler("stopAction"),this._endAction=this._createActionHandler("endAction"),this._updateAction=this._createActionHandler("updateAction"),this._createScrollerActions()},_createScrollerActions:function(){this._handleEvent("CreateActions",{scrollAction:this._createActionHandler("scrollAction"),bounceAction:this._createActionHandler("bounceAction")})},_createActionHandler:function(t){var i=this,r=i._createActionByOption(t,{excludeValidators:["gesture"]});return function(){r(n.extend(i._createActionArgs(),arguments))}},_createActionArgs:function(){var n=this._scrollers[h],t=this._scrollers[k];return{jQueryEvent:p,scrollOffset:{top:t&&-t._location,left:n&&-n._location},reachedLeft:n&&n._reachedMax(),reachedRight:n&&n._reachedMin(),reachedTop:t&&t._reachedMax(),reachedBottom:t&&t._reachedMin()}},dispose:function(){this===r&&(r=null),this._handleEvent("Dispose"),this._detachScrollHandler(),this._startAction=null,this._stopAction=null,this._endAction=null,this._updateAction=null,clearTimeout(this._gestureEndTimer)},_detachScrollHandler:function(){n(this._$container).off(u.addNamespace("scroll",s),this._handleScroll)},_handleEvent:function(t){var i=n.makeArray(arguments).slice(1),r=n.map(this._scrollers,function(n){return n["_handle"+t].apply(n,i)});return n.when.apply(n,r).promise()},_handleStart:function(t){this._handleEvent("Start",t).done(n.proxy(this._forgetGesture,this)).done(this._stopAction)},_handleFirstMove:function(){return this._handleEvent("FirstMove").done(this._startAction)},_prepareGesture:function(){clearTimeout(this._gestureEndTimer),this._$element.data(ut,!0),o.feedback.reset()},_handleMove:function(n){this._handleEvent("Move",n)},_handleMoveEnd:function(n){return this._handleEvent("MoveEnd",n).done(this._endAction)},_forgetGesture:function(){this._gestureEndTimer=setTimeout(n.proxy(function(){this._$element.data(ut,!1)},this),400)},_handleTapEnd:function(){this._handleEvent("TapEnd")},location:function(){return t.translator.locate(this._$content)},_validateTarget:function(t){if(this.option("disabled"))return!1;var i=!1;return n.each(this._scrollers,function(){i=i||this._validateTarget(t)}),i},_validateDirection:function(t){var i=!1;return n.each(this._scrollers,function(){i=i||this._validateDirection(t)}),i},update:function(){return this._handleEvent("Update").done(this._updateAction)},scrollBy:function(n){this._handleFirstMove(),this._handleMove(n),this._handleMoveEnd({x:0,y:0})}});var g=0,a=1,nt=2,dt=100,gt=200,r,v,e=g,c,y,p,w=null,et=10,ot=function(t){var i=n(t).closest("."+tt),u,r;if(i.length)return u=i.data("dxComponents"),n.each(u,function(n,t){var u=o[t];if(u===o.dxScrollable||u.subclassOf(o.dxScrollable))return r=i.data(t),!1}),r&&r.option("disabled")?ot(i.parent()):r._strategy},b=function(){e=g},ni=function(){t.utils.resetActiveElement()},si=function(n){n.preventDefault()},st=function(t){u.needSkipEvent(t)||(r=ot(t.target),r&&r._validateTarget(n(t.target))&&(v=r._$element.parents().length,p=t,w=c=y=u.eventData(t),e=a,r._handleStart(n(t.target))))},ht=function(n){var t,o,i,f;if(r){if(n.originalEvent&&(t=n.originalEvent.pointerMoveData,o=r.option("direction"),t&&t[o]!==v)){b();return}(p=n,e!==g)&&(i=u.eventData(n),f=u.eventDelta(c,i),e===a&&ti(f),e===nt&&ri(i,f))}},ti=function(t){if(!r._validateDirection(t)){b();return}n(":focus",r._$element).length&&ni(),r._handleFirstMove(),e=nt},ii=function(n){if(e===a&&n.originalEvent){var t=n.originalEvent.pointerMoveData||{},i=r.option("direction"),u=t[i];if(u&&u>v)return;t[i]=v,n.originalEvent.pointerMoveData=t}},ri=function(n,t){if(r._isLocked()){b();return}if(u.eventDelta(y,c).time>gt&&(y=c),c=n,w){var i=u.eventDelta(w,n);(f.abs(i.x)>et||f.abs(i.y)>et)&&(r._prepareGesture(),w=null)}r._handleMove(t)},ct=function(t){var i;if(r){if(p=t,e===nt){var o=u.eventData(t),s=u.eventDelta(c,o),f={x:0,y:0};s.time<dt&&(i=u.eventDelta(y,c),f={x:i.x*d/i.time,y:i.y*d/i.time}),r._handleMoveEnd(f).done(n.proxy(r._forgetGesture,r))}else e===a&&r._handleTapEnd();b()}},ui=function(n,t){st(n),n.pageY+=t,ht(n),ct(n)};n(function(){var i={context:o.dxScrollable,excludeValidators:["gesture"]},f=new t.Action(st,i),e=new t.Action(ht,i),h=new t.Action(ct,i),c=new t.Action(ii,i),r;n("body").on(u.addNamespace("dxpointermove",s),function(n){c.execute(n)});n(document).on(u.addNamespace("dxpointerdown",s),function(n){f.execute(n)}).on(u.addNamespace("dxpointermove",s),function(n){e.execute(n)}).on(u.addNamespace("dxpointerup dxpointercancel",s),function(n){h.execute(n)});if("mousewheel"in n.event.special){r=new t.Action(ui,i);n(document).on(u.addNamespace("mousewheel",s),function(n,t){r.execute(n,t)})}})}(jQuery,DevExpress),function(n,t,i){var r=t.ui,f="dx-scrollview",o="dx-scrollview-content",s="dx-scrollview-top-pocket",h="dx-scrollview-bottom-pocket",u=f+"-pull-down",a=u+"-image",v=u+"-indicator",y=u+"-text",e=f+"-scrollbottom",c=e+"-indicator",l=e+"-text";r.registerComponent("dxScrollView",r.dxScrollable.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{pullingDownText:Globalize.localize("dxScrollView-pullingDownText"),pulledDownText:Globalize.localize("dxScrollView-pulledDownText"),refreshingText:Globalize.localize("dxScrollView-refreshingText"),reachBottomText:Globalize.localize("dxScrollView-reachBottomText"),pullDownAction:null,reachBottomAction:null,refreshStrategy:"pullDown"})},_initMarkup:function(){this.callBase(),this._element().addClass(f),this._initContent(),this._initTopPocket(),this._initBottomPocket()},_initContent:function(){var t=n("<div>").addClass(o);this._$content.wrapInner(t)},_initTopPocket:function(){var t=this._$topPocket=n("<div>").addClass(s),i=this._$pullDown=n("<div>").addClass(u);t.append(i),this._$content.prepend(t)},_initBottomPocket:function(){var t=this._$bottomPocket=n("<div>").addClass(h),i=this._$reachBottom=n("<div>").addClass(e),r=n("<div>").addClass(c),u=n("<div>").dxLoadIndicator(),f=this._$reachBottomText=n("<div>").addClass(l);this._updateReachBottomText(),i.append(r.append(u)).append(f),t.append(i),this._$content.append(t)},_updateReachBottomText:function(){this._$reachBottomText.text(this.option("reachBottomText"))},_createStrategy:function(){var u=this.option("useNative")||t.designMode?this.option("refreshStrategy"):"simulated",i=r.scrollViewRefreshStrategies[u];if(!i)throw Error("Unknown dxScrollView refresh strategy "+this.option("refreshStrategy"));this._strategy=new i(this),this._strategy.pullDownCallbacks.add(n.proxy(this._handlePullDown,this)),this._strategy.releaseCallbacks.add(n.proxy(this._handleRelease,this)),this._strategy.reachBottomCallbacks.add(n.proxy(this._handleReachBottom,this)),this._strategy.render()},_createActions:function(){this.callBase(),this._pullDownAction=this._createActionByOption("pullDownAction",{excludeValidators:["gesture"]}),this._reachBottomAction=this._createActionByOption("reachBottomAction",{excludeValidators:["gesture"]}),this._pullDownEnable(!!this.option("pullDownAction")&&!t.designMode),this._reachBottomEnable(!!this.option("reachBottomAction")&&!t.designMode)},_pullDownEnable:function(n){this._$pullDown.toggle(n),this._strategy.pullDownEnable(n)},_reachBottomEnable:function(n){this._$reachBottom.toggle(n),this._strategy.reachBottomEnable(n)},_handlePullDown:function(){this._pullDownAction(),this._lock()},_handleRelease:function(){this._unlock()},_handleReachBottom:function(){this._reachBottomAction(),this._lock()},_optionChanged:function(n){switch(n){case"pullDownAction":case"reachBottomAction":this._createActions();break;case"pullingDownText":case"pulledDownText":case"refreshingText":this._invalidate();break;case"reachBottomText":this._updateReachBottomText();break;default:this.callBase.apply(this,arguments)}},content:function(){return this._$content.children().eq(1)},release:function(n){return n!==i&&this.toggleLoading(!n),this._strategy.release()},toggleLoading:function(n){this._reachBottomEnable(n)},isFull:function(){return this.content().height()>=this._$container.height()}})),r.scrollViewRefreshStrategies={}}(jQuery,DevExpress),function(n,t){var o=t.ui,y=Math,s="dx-scrollview-pull-down-loading",f="dx-scrollview-pull-down-ready",c="dx-scrollview-pull-down-image",l="dx-scrollview-pull-down-indicator",a="dx-scrollview-pull-down-text",e=0,r=1,u=2,h=3,v=o.NativeScrollableStrategy.inherit({_init:function(n){this.callBase(n),this._$topPocket=n._$topPocket,this._$pullDown=n._$pullDown,this._$bottomPocket=n._$bottomPocket,this._$refreshingText=n._$refreshingText,this._$scrollViewContent=n.content(),this._initCallbacks()},_initCallbacks:function(){this.pullDownCallbacks=n.Callbacks(),this.releaseCallbacks=n.Callbacks(),this.reachBottomCallbacks=n.Callbacks()},render:function(){this.callBase(),this._renderPullDown(),this._releaseState()},_renderPullDown:function(){var i=n("<div>").addClass(c),r=n("<div>").addClass(l),u=n("<div>").dxLoadIndicator(),t=this._$pullDownText=n("<div>").addClass(a);this._$pullingDownText=n("<div>").text(this.option("pullingDownText")).appendTo(t),this._$pulledDownText=n("<div>").text(this.option("pulledDownText")).appendTo(t),this._$refreshingText=n("<div>").text(this.option("refreshingText")).appendTo(t),this._$pullDown.empty().append(i).append(r.append(u)).append(t)},_releaseState:function(){this._state=e,this._refreshPullDownText()},_refreshPullDownText:function(){this._$pullingDownText.css("opacity",this._state===e?1:0),this._$pulledDownText.css("opacity",this._state===r?1:0),this._$refreshingText.css("opacity",this._state===u?1:0)},update:function(){this.callBase(),this._setTopPocketOffset()},_updateDimensions:function(){this.callBase(),this._topPocketSize=this._$topPocket.height(),this._bottomPocketSize=this._$bottomPocket.height(),this._scrollOffset=this._$container.height()-this._$content.height()},_setTopPocketOffset:function(){this._$topPocket.css({height:this._topPocketSize,top:-this._topPocketSize})},_handleEnd:function(){var n=this;n._state===r&&(n._setPullDownOffset(n._topPocketSize),setTimeout(function(){n._pullDownRefreshing()},400))},_setPullDownOffset:function(n){t.translator.move(this._$topPocket,{top:n},{cssTransform:!0}),t.translator.move(this._$scrollViewContent,{top:n},{cssTransform:!0})},_handleScroll:function(n){(this.callBase(n),this._state!==u)&&(this._location=this.location().top,this._isPullDown()?this._pullDownReady():this._isReachBottom()?this._reachBottom():this._stateReleased())},_isPullDown:function(){return this._pullDownEnabled&&this._location>=this._topPocketSize},_isReachBottom:function(){return this._reachBottomEnabled&&this._location<=this._scrollOffset+this._bottomPocketSize},_reachBottom:function(){this._state!==h&&(this._state=h,this.reachBottomCallbacks.fire())},_pullDownReady:function(){this._state!==r&&(this._state=r,this._$pullDown.addClass(f),this._refreshPullDownText())},_stateReleased:function(){this._state!==e&&(this._$pullDown.removeClass(s).removeClass(f),this._releaseState())},_pullDownRefreshing:function(){this._state!==u&&(this._state=u,this._$pullDown.addClass(s).removeClass(f),this._refreshPullDownText(),this.pullDownCallbacks.fire())},pullDownEnable:function(n){this._pullDownEnabled=n},reachBottomEnable:function(n){this._reachBottomEnabled=n},release:function(){var t=n.Deferred();return this._updateDimensions(),setTimeout(n.proxy(function(){this._setPullDownOffset(0),this._stateReleased(),this.releaseCallbacks.fire(),this._updateAction(),t.resolve()},this),400),t.promise()}});o.scrollViewRefreshStrategies.pullDown=v}(jQuery,DevExpress),function(n,t){var r=t.ui,s=r.events,h=Math,c="dx-scrollview-pull-down-loading",v="dx-scrollview-obsolete-android-browser",l=160,u=0,f=2,a=3,e=4,o=5,y=r.NativeScrollableStrategy.inherit({_init:function(n){this.callBase(n),this._$topPocket=n._$topPocket,this._$bottomPocket=n._$bottomPocket,this._$pullDown=n._$pullDown,this._$scrollViewContent=n.content(),this._initCallbacks(),this._initObsoleteBrowser(),this._releaseState(),this._location=0},_initCallbacks:function(){this.pullDownCallbacks=n.Callbacks(),this.releaseCallbacks=n.Callbacks(),this.reachBottomCallbacks=n.Callbacks()},_initObsoleteBrowser:function(){var n=DevExpress.devices.real,t=n.platform==="android"&&(n.version[0]<4||n.version[0]===4&&n.version[1]===0);this._$element.toggleClass(v,t)},render:function(){this.callBase(),this._renderPullDown()},_renderPullDown:function(){this._$pullDown.empty().append(n("<div class='dx-scrollview-pulldown-pointer1'>")).append(n("<div class='dx-scrollview-pulldown-pointer2'>")).append(n("<div class='dx-scrollview-pulldown-pointer3'>")).append(n("<div class='dx-scrollview-pulldown-pointer4'>"))},_releaseState:function(){this._state=u,this._$pullDown.css({width:"0%",opacity:0}),this._updateDimensions()},_updateDimensions:function(){this.callBase(),this._topPocketSize=this._$topPocket.height(),this._bottomPocketSize=this._$bottomPocket.height(),this._scrollOffset=this._$container.height()-this._$content.height()},_handleStart:function(n){this._state===u&&this._location===0&&(this._startClientY=s.eventData(n).y,this._state=e)},_handleMove:function(n){if(this._deltaY=s.eventData(n).y-this._startClientY,this._state===e&&(this._deltaY>0?(n.preventDefault(),this._state=o):this._handleEnd()),this._state===o){if(this._deltaY<0){this._handleEnd();return}this._$pullDown.css({opacity:1,width:h.min(h.abs(this._deltaY*100/l),100)+"%"}),this._isPullDown()&&this._pullDownRefreshing()}},_isPullDown:function(){return this._pullDownEnabled&&this._deltaY>=l},_handleEnd:function(){(this._state===e||this._state===o)&&this._releaseState()},_handleScroll:function(n){(this.callBase(n),this._state!==f)&&(this._location=this.location().top,this._isReachBottom()?this._reachBottom():this._stateReleased())},_isReachBottom:function(){return this._reachBottomEnabled&&this._location<=this._scrollOffset+this._bottomPocketSize},_reachBottom:function(){this._state!==a&&(this._state=a,this.reachBottomCallbacks.fire())},_stateReleased:function(){this._state!==u&&(this._$pullDown.removeClass(c),this._releaseState())},_pullDownRefreshing:function(){if(this._state!==f){this._state=f;var n=this;setTimeout(function(){n._$pullDown.addClass(c),n.pullDownCallbacks.fire()},400)}},pullDownEnable:function(n){this._$topPocket.toggle(n),this._pullDownEnabled=n},reachBottomEnable:function(n){this._reachBottomEnabled=n},release:function(){var t=this,i=n.Deferred();return setTimeout(function(){t._updateDimensions(),t._stateReleased(),t.releaseCallbacks.fire(),t._updateAction(),i.resolve()},800),i.promise()}});r.scrollViewRefreshStrategies.swipeDown=y}(jQuery,DevExpress),function(n,t){var u=t.ui,nt=Math,o=u.events,s="dxSlideDownNativeScrollViewStrategy",h="dx-scrollview-locked",c="dx-scrollview-pull-down-refreshing",l="dx-scrollview-pull-down-loading",tt="dx-scrollview-pull-down-ready",w="dx-scrollview-pull-down-image",b="dx-scrollview-pull-down-indicator",k="dx-scrollview-pull-down-text",a=0,f=1,r=2,v=3,y=4,it=80,e=4,p=t.Animator.inherit({ctor:function(n){this.callBase(),this.refreshStrategy=n,this._$content=n._$content},_isFinished:function(){return this._$content.scrollTop()===0},_step:function(){this._lock();var n=this._$content.scrollTop();n-=Math.min(n,2*e),this._$content.scrollTop(n)},_complete:function(){this._unlock()},_stop:function(){this._unlock()},_lock:function(){this.refreshStrategy._$container.addClass(h)},_unlock:function(){this.refreshStrategy._$container.removeClass(h)}}),d=p.inherit({_isFinished:function(){return this._currentPosition=this._$content.scrollTop(),this._currentPosition===this.refreshStrategy._topPocketSize},_step:function(){this._lock();var n=this._$content.scrollTop(),t=this.refreshStrategy._topPocketSize-n;n+=t<0?-Math.min(Math.abs(t),e):Math.min(t,e),this._$content.scrollTop(n)},_complete:function(){this.callBase(),this.refreshStrategy._releaseState()}}),g=u.NativeScrollableStrategy.inherit({_init:function(t){this.callBase(t),this._$topPocket=t._$topPocket,this._$pullDown=t._$pullDown,this._$bottomPocket=t._$bottomPocket,this._$refreshingText=t._$refreshingText,this._$content=t._$content,this._$scrollViewContent=t.content(),this._initCallbacks(),this._initAnimators();n(document).on("dx.viewchanged",n.proxy(this._hidePullDown,this))},_initCallbacks:function(){this.pullDownCallbacks=n.Callbacks(),this.releaseCallbacks=n.Callbacks(),this.reachBottomCallbacks=n.Callbacks()},_initAnimators:function(){this._slideDown=new d(this),this._slideUp=new p(this)},render:function(){this.callBase(),this._renderPullDown(),this._renderBottom(),this._releaseState(),this._updateDimensions(),this._hidePullDown()},_renderPullDown:function(){var i=n("<div>").addClass(w),r=n("<div>").addClass(b),u=n("<progress>"),t=this._$pullDownText=n("<div>").addClass(k);this._$pullingDownText=n("<div>").text(this.option("pullingDownText")).appendTo(t),this._$pulledDownText=n("<div>").text(this.option("pulledDownText")).appendTo(t),this._$refreshingText=n("<div>").text(this.option("refreshingText")).appendTo(t),this._$pullDown.empty().append(i).append(r.append(u)).append(t)},_renderBottom:function(){this._$bottomPocket.empty().append("<progress>")},_releaseState:function(){this._state=a,this._$container.removeClass(c).removeClass(l),this._refreshPullDownText()},_hidePullDown:function(){this._$content.scrollTop()<this._topPocketSize&&this._$content.scrollTop(this._topPocketSize)},_refreshPullDownText:function(){this._$pullingDownText.css("opacity",this._state===a?1:0),this._$pulledDownText.css("opacity",this._state===f?1:0),this._$refreshingText.css("opacity",this._state===r?1:0)},update:function(){this.callBase(),this._hidePullDown(),this._updateScrollbars()},_updateDimensions:function(){this._topPocketSize=this._$topPocket.height(),this._scrollOffset=this._$scrollViewContent.prop("scrollHeight")-this._$scrollViewContent.prop("clientHeight"),this._containerSize={height:this._$scrollViewContent.prop("clientHeight"),width:this._$scrollViewContent.prop("clientWidth")},this._contentSize={height:this._$scrollViewContent.prop("scrollHeight"),width:this._$scrollViewContent.prop("scrollWidth")}},_contentSize:function(){return{height:this._$scrollViewContent.prop("scrollHeight"),width:this._$scrollViewContent.prop("scrollWidth")}},location:function(){return{left:-this._$scrollViewContent.scrollLeft(),top:-this._$scrollViewContent.scrollTop()}},_attachScrollHandler:function(){this.callBase();n(this._$content).on(o.addNamespace("scroll",s),n.proxy(this._handleContentScroll,this));n(this._$scrollViewContent).on(o.addNamespace("scroll",s),n.proxy(this._handleScrollViewContentScroll,this))},_handleContentScroll:function(){var t=this._$content.scrollTop();this._isPullDown(t)?this._pullDownRefreshing():this._isReachBottom(t)?this._reachBottom():this._pullDownReady()},_isPullDown:function(n){return this._pullDownEnabled&&n===0},_pullDownRefreshing:function(){this._state!==r&&(this._state=r,this._stopAnimators(),this._refreshPullDownText(),this._$container.addClass(c),this.pullDownCallbacks.fire())},_isReachBottom:function(n){return this._scrollContent=this._$content.prop("scrollHeight")-this._$content.prop("clientHeight"),this._reachBottomEnabled&&n===this._scrollContent},_reachBottom:function(){this._state!==v&&this._reachBottomEnabled&&(this._state=v,this._stopAnimators(),this._$container.addClass(l),this.reachBottomCallbacks.fire())},_pullDownReady:function(){if(this._state!==f&&this._state!==y){if(this._state===r){this._slideUp.inProgress()||this._startUpAnimation();return}this._state=f,this._startDownAnimation()}},_startUpAnimation:function(){this._slideDown.stop(),this._slideUp.start()},_startDownAnimation:function(){this._slideUp.stop(),this._slideDown.start()},_stopAnimators:function(){this._slideDown.stop(),this._slideUp.stop()},_handleScrollViewContentScroll:function(n){this._handleScroll(n)},pullDownEnable:function(n){this._pullDownEnabled=n},reachBottomEnable:function(n){this._reachBottomEnabled=n,this._$bottomPocket.toggle(n)},release:function(){var t=n.Deferred();return this._updateDimensions(),this._updateScrollbars(),setTimeout(n.proxy(function(){this._state=y,this._startDownAnimation(),this.releaseCallbacks.fire(),this._updateAction(),t.resolve()},this),400),t.promise()},scrollBy:function(n){var t=this.location();this._component.content().scrollTop(-t.top-n.y),this._component.content().scrollLeft(-t.left-n.x)}});u.scrollViewRefreshStrategies.slideDown=g}(jQuery,DevExpress),function(n,t){var r=t.ui,h=Math,c="dx-scrollview-pull-down-loading",e="dx-scrollview-pull-down-ready",l="dx-scrollview-pull-down-image",a="dx-scrollview-pull-down-indicator",v="dx-scrollview-pull-down-text",u=0,f=1,o=2,s=3,y=r.ScrollViewScroller=r.Scroller.inherit({ctor:function(){this.callBase.apply(this,arguments),this._releaseState()},_releaseState:function(){this._state=u,this._refreshPullDownText()},_refreshPullDownText:function(){this._$pullingDownText.css("opacity",this._state===u?1:0),this._$pulledDownText.css("opacity",this._state===f?1:0),this._$refreshingText.css("opacity",this._state===o?1:0)},_initCallbacks:function(){this.callBase(),this.pullDownCallbacks=n.Callbacks(),this.releaseCallbacks=n.Callbacks(),this.reachBottomCallbacks=n.Callbacks()},_updateBounds:function(){var n=this._direction!=="horizontal";this._topPocketSize=n?this._$topPocket[this._dimension]():0,this._bottomPocketSize=n?this._$bottomPocket[this._dimension]():0,this._updateOffsets()},_updateOffsets:function(){this._minOffset=h.min(this._containerSize()-this._contentSize()+this._bottomPocketSize,-this._topPocketSize),this._maxOffset=-this._topPocketSize,this._bottomBound=this._minOffset-this._bottomPocketSize},_updateScrollbar:function(){this._scrollbar.update(this._containerSize(),this._contentSize()-this._topPocketSize-this._bottomPocketSize)},_calculateScrollBarPosition:function(){return this._topPocketSize+this._location},_moveContent:function(){this.callBase(),this._isPullDown()?this._pullDownReady():this._isReachBottom()?this._reachBottomReady():this._state!==u&&this._stateReleased()},_isPullDown:function(){return this._pullDownEnabled&&this._location>=0},_isReachBottom:function(){return this._reachBottomEnabled&&this._location<=this._bottomBound},_scrollComplete:function(){this._inBounds()&&this._state===f?this._pullDownRefreshing():this._inBounds()&&this._state===s?this._reachBottomLoading():this.callBase()},_reachBottomReady:function(){this._state!==s&&(this._state=s,this._minOffset=h.min(this._containerSize()-this._contentSize(),0))},_reachBottomLoading:function(){this.reachBottomCallbacks.fire()},_pullDownReady:function(){this._state!==f&&(this._state=f,this._maxOffset=0,this._$pullDown.addClass(e),this._refreshPullDownText())},_stateReleased:function(){this._state!==u&&(this._releaseState(),this._updateOffsets(),this._$pullDown.removeClass(c).removeClass(e),this.releaseCallbacks.fire())},_pullDownRefreshing:function(){this._state!==o&&(this._state=o,this._$pullDown.addClass(c).removeClass(e),this._refreshPullDownText(),this.pullDownCallbacks.fire())},_handleRelease:function(){return this._update(),t.utils.executeAsync(n.proxy(this._release,this))},_release:function(){this._stateReleased(),this._scrollComplete()},_handleReachBottomEnabling:function(n){this._reachBottomEnabled!==n&&(this._reachBottomEnabled=n,this._updateBounds())},_handlePullDownEnabling:function(n){this._pullDownEnabled!==n&&(this._pullDownEnabled=n,this._considerTopPocketChange(),this._handleUpdate())},_considerTopPocketChange:function(){this._location-=this._$topPocket.height()||-this._topPocketSize,this._move()}}),p=r.SimulatedScrollableStrategy.inherit({_init:function(n){this.callBase(n),this._$pullDown=n._$pullDown,this._$topPocket=n._$topPocket,this._$bottomPocket=n._$bottomPocket,this._initCallbacks()},_initCallbacks:function(){this.pullDownCallbacks=n.Callbacks(),this.releaseCallbacks=n.Callbacks(),this.reachBottomCallbacks=n.Callbacks()},render:function(){this._renderPullDown(),this.callBase()},_renderPullDown:function(){var i=n("<div>").addClass(l),r=n("<div>").addClass(a),u=n("<div>").dxLoadIndicator(),t=this._$pullDownText=n("<div>").addClass(v);this._$pullingDownText=n("<div>").text(this.option("pullingDownText")).appendTo(t),this._$pulledDownText=n("<div>").text(this.option("pulledDownText")).appendTo(t),this._$refreshingText=n("<div>").text(this.option("refreshingText")).appendTo(t),this._$pullDown.empty().append(i).append(r.append(u)).append(t)},pullDownEnable:function(n){this._handleEvent("PullDownEnabling",n)},reachBottomEnable:function(n){this._handleEvent("ReachBottomEnabling",n)},_createScroller:function(n){var t=this,i=t._scrollers[n]=new y(t._scrollerOptions(n));i.pullDownCallbacks.add(function(){t.pullDownCallbacks.fire()}),i.releaseCallbacks.add(function(){t.releaseCallbacks.fire()}),i.reachBottomCallbacks.add(function(){t.reachBottomCallbacks.fire()})},_scrollerOptions:function(t){return n.extend(this.callBase(t),{$topPocket:this._$topPocket,$bottomPocket:this._$bottomPocket,$pullDown:this._$pullDown,$pullDownText:this._$pullDownText,$pullingDownText:this._$pullingDownText,$pulledDownText:this._$pulledDownText,$refreshingText:this._$refreshingText})},release:function(){return this._handleEvent("Release").done(this._updateAction)}});r.scrollViewRefreshStrategies.simulated=p}(jQuery,DevExpress),function(n,t,i){var r=t.ui,o=r.events,l=t.utils,s=t.support.winJS,f;r.MapProvider=t.Class.inherit({_defaultRouteWeight:function(){return 5},_defaultRouteOpacity:function(){return.5},_defaultRouteColor:function(){return"#0000FF"},ctor:function(n,t){this._mapInstance=n,this._$container=t},load:n.noop,render:t.abstract,updateDimensions:t.abstract,updateMapType:t.abstract,updateLocation:t.abstract,updateZoom:t.abstract,updateControls:t.abstract,updateMarkers:t.abstract,addMarkers:t.abstract,updateRoutes:t.abstract,addRoutes:t.abstract,clean:t.abstract,cancelEvents:!1,map:function(){return this._map},mapRendered:function(){return!!this._map},_option:function(n,t){if(t===i)return this._mapInstance.option(n);this._mapInstance.setOptionSilent(n,t)},_key:function(n){var t=this._option("key");return t[n]===i?t:t[n]},_parseTooltipOptions:function(n){return{text:n.text||n,visible:n.isShown||!1}},_createAction:function(){return this._mapInstance._createAction.apply(this._mapInstance,n.makeArray(arguments))},_handleClickAction:function(){var t=this._createAction(this._option("clickAction")||n.noop);t()}}),f={},r.registerMapProvider=function(n,t){f[n]=t};var h="dx-map",c="dx-map-container",e="dx-map-shield",u=function(t){return n.isArray(t)?t:[t]};r.registerComponent("dxMap",r.Widget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{location:{lat:0,lng:0},width:300,height:300,zoom:1,type:"roadmap",provider:"google",markers:[],markerIconSrc:null,routes:[],key:{bing:"",google:"",googleStatic:""},controls:!1,readyAction:null,updateAction:null})},_init:function(){this.callBase(),this._initContainer(),this._grabEvents(),this._initProvider()},_initContainer:function(){this._$container=n("<div />").addClass(c),this._element().append(this._$container)},_grabEvents:function(){var t=o.addNamespace("dxpointerdown",this.NAME);this._element().on(t,n.proxy(this._cancelEvent,this))},_cancelEvent:function(n){var i=this._provider.cancelEvents&&!this.option("disabled");!t.designMode&&i&&n.stopPropagation()},_initProvider:function(){var n=this.option("provider");if(s&&this.option("provider")==="google")throw new Error("Google provider cannot be used in winJS application");this._provider&&this._provider.clean(),this._provider=new f[n](this,this._$container),this._mapLoader=this._provider.load()},_render:function(){this.callBase(),this._element().addClass(h),this._renderShield(),this._execAsyncProviderAction("render")},_renderShield:function(){var i;t.designMode||this.option("disabled")?(i=n("<div/>").addClass(e),this._element().append(i)):(i=this._element().find("."+e),i.remove())},_clean:function(){this._provider.clean()},_optionChanged:function(n){if(!this._cancelOptionChange)switch(n){case"disabled":this._renderShield(),this.callBase.apply(this,arguments);break;case"width":case"height":this.callBase.apply(this,arguments),this._execAsyncProviderAction("updateDimensions");break;case"type":this._execAsyncProviderAction("updateMapType");break;case"location":this._execAsyncProviderAction("updateLocation");break;case"zoom":this._execAsyncProviderAction("updateZoom");break;case"controls":this._execAsyncProviderAction("updateControls");break;case"markers":case"markerIcon":this._execAsyncProviderAction("updateMarkers");break;case"routes":this._execAsyncProviderAction("updateRoutes");break;case"key":throw new Error("Key option can not be modified after initialisation");case"provider":this._initProvider(),this._invalidate();break;case"readyAction":case"updateAction":break;default:this.callBase.apply(this,arguments)}},_execAsyncProviderAction:function(t){if(this._provider.mapRendered()||t==="render"){var i=n.Deferred(),r=this,u=n.makeArray(arguments).slice(1);return n.when(this._mapLoader).done(function(){var f=r._provider;f[t].apply(f,u).done(function(t){r._triggerUpdateAction(),t&&r._triggerReadyAction(),i.resolve.apply(i,n.makeArray(arguments).slice(1))})}),i.promise()}},_triggerReadyAction:function(){this._createActionByOption("readyAction")({originalMap:this._provider.map()})},_triggerUpdateAction:function(){this._createActionByOption("updateAction")()},setOptionSilent:function(n,t){this._cancelOptionChange=!0,this.option(n,t),this._cancelOptionChange=!1},addMarker:function(t){var r=n.Deferred(),e=this,f=this._options.markers,i=u(t);return f.push.apply(f,i),this._execAsyncProviderAction("addMarkers",i).done(function(n){r.resolveWith(e,i.length>1?[n]:n)}),r.promise()},removeMarker:function(t){var i=n.Deferred(),f=this,r=this._options.markers,e=u(t);return n.each(e,function(t,i){var u=n.isNumeric(i)?i:n.inArray(i,r);u!==-1&&r.splice(u,1)}),this._execAsyncProviderAction("updateMarkers").done(function(){i.resolveWith(f)}),i.promise()},addRoute:function(t){var r=n.Deferred(),e=this,f=this._options.routes,i=u(t);return f.push.apply(f,i),this._execAsyncProviderAction("addRoutes",i).done(function(n){r.resolveWith(e,i.length>1?[n]:n)}),r.promise()},removeRoute:function(t){var i=n.Deferred(),f=this,r=this._options.routes,e=u(t);return n.each(e,function(t,i){var u=n.isNumeric(i)?i:n.inArray(i,r);u!==-1&&r.splice(u,1)}),this._execAsyncProviderAction("updateRoutes").done(function(){i.resolveWith(f)}),i.promise()}}))}(jQuery,DevExpress),function(n,t,i){var f=t.ui,o=t.support.winJS,r="_bingScriptReady",s="https://ecn.dev.virtualearth.net/mapcontrol/mapcontrol.ashx?v=7.0&s=1&onScriptLoad="+r,h="ms-appx:///Bing.Maps.JavaScript/js/veapicore.js",c="ms-appx:///Bing.Maps.JavaScript/js/veapiModules.js",l="AhuxC0dQ1DBTNo8L-H9ToVMQStmizZzBJdraTSgCzDSWPsA1Qd8uIvFSflzxdaLH",e=1e-16,u;f.registerMapProvider("bing",f.MapProvider.inherit({_mapType:function(n){var t={roadmap:Microsoft.Maps.MapTypeId.road,hybrid:Microsoft.Maps.MapTypeId.aerial};return t[n]||t.roadmap},_movementMode:function(n){var t={driving:Microsoft.Maps.Directions.RouteMode.driving,walking:Microsoft.Maps.Directions.RouteMode.walking};return t[n]||t.driving},_resolveLocation:function(t){var i=n.Deferred(),r,u;return typeof t=="string"?(r=new Microsoft.Maps.Search.SearchManager(this._map),u={where:t,count:1,callback:function(n){var t=n.results[0].location;i.resolve(new Microsoft.Maps.Location(t.latitude,t.longitude))}},r.geocode(u)):n.isPlainObject(t)&&n.isNumeric(t.lat)&&n.isNumeric(t.lng)?i.resolve(new Microsoft.Maps.Location(t.lat,t.lng)):n.isArray(t)&&i.resolve(new Microsoft.Maps.Location(t[0],t[1])),i.promise()},_normalizeLocation:function(n){return{lat:n.latitude,lng:n.longitude}},load:function(){return u||(u=n.Deferred(),window[r]=n.proxy(this._mapReady,this),o?n.when(n.getScript(h),n.getScript(c)).done(function(){Microsoft.Maps.loadModule("Microsoft.Maps.Map",{callback:window[r]})}):n.getScript(s)),this._markers=[],this._routes=[],u},_mapReady:function(){try{delete window[r]}catch(e){window[r]=i}var t=n.Deferred(),f=n.Deferred();Microsoft.Maps.loadModule("Microsoft.Maps.Search",{callback:n.proxy(t.resolve,t)}),Microsoft.Maps.loadModule("Microsoft.Maps.Directions",{callback:n.proxy(f.resolve,f)}),n.when(t,f).done(function(){u.resolve()})},render:function(){var r=n.Deferred(),t=n.Deferred(),i=this._option("controls"),f={credentials:this._key("bing")||l,mapTypeId:this._mapType(this._option("type")),zoom:this._option("zoom"),showDashboard:i,showMapTypeSelector:i,showScalebar:i},u;this._map=new Microsoft.Maps.Map(this._$container[0],f),u=Microsoft.Maps.Events.addHandler(this._map,"tiledownloadcomplete",n.proxy(t.resolve,t)),this._viewChangeHandler=Microsoft.Maps.Events.addHandler(this._map,"viewchange",n.proxy(this._handleViewChange,this)),this._clickHandler=Microsoft.Maps.Events.addHandler(this._map,"click",n.proxy(this._handleClickAction,this));var e=this._renderLocation(),o=this._refreshMarkers(),s=this._renderRoutes();return n.when(t,e,o,s).done(function(){Microsoft.Maps.Events.removeHandler(u),r.resolve(!0)}),r.promise()},_handleViewChange:function(){var n=this._map.getCenter();this._option("location",this._normalizeLocation(n)),this._option("zoom",this._map.getZoom())},updateDimensions:function(){return n.Deferred().resolve().promise()},updateMapType:function(){return this._map.setView({mapTypeId:this._mapType(this._option("type"))}),n.Deferred().resolve().promise()},updateLocation:function(){return this._renderLocation()},_renderLocation:function(){var t=n.Deferred(),i=this;return this._resolveLocation(this._option("location")).done(function(n){i._map.setView({animate:!1,center:n}),t.resolve()}),t.promise()},updateZoom:function(){return this._map.setView({animate:!1,zoom:this._option("zoom")}),n.Deferred().resolve().promise()},updateControls:function(){return this.clean(),this.render()},_clearBounds:function(){this._bounds=null},_extendBounds:function(n){this._bounds=this._bounds?new Microsoft.Maps.LocationRect.fromLocations(this._bounds.getNorthwest(),this._bounds.getSoutheast(),n):new Microsoft.Maps.LocationRect(n,e,e)},_fitBounds:function(){this._bounds&&(this._bounds.height=this._bounds.height*1.1,this._bounds.width=this._bounds.width*1.1,this._map.setView({animate:!1,bounds:this._bounds}))},updateMarkers:function(){return this._refreshMarkers()},_refreshMarkers:function(){return this._clearMarkers(),this._renderMarkers()},_clearMarkers:function(){var t=this;this._clearBounds(),n.each(this._markers,function(n,i){t._map.entities.remove(i.pushpin),i.infobox&&t._map.entities.remove(i.infobox),i.handler&&Microsoft.Maps.Events.removeHandler(i.handler)}),this._markers=[]},addMarkers:function(n){return this._renderMarkers(n)},_renderMarkers:function(t){t=t||this._option("markers");var i=n.Deferred(),r=this,u=n.map(t,function(n){return r._addMarker(n)});return n.when.apply(n,u).done(function(){var t=n.map(n.makeArray(arguments),function(n){return n.pushpin});i.resolve(!1,t)}),i.done(function(){r._fitBounds()}),i.promise()},_addMarker:function(n){var t=this;return this._renderMarker(n).done(function(n){t._markers.push(n)})},_renderMarker:function(t){var r=n.Deferred(),i=this;return this._resolveLocation(t.location).done(function(u){var o=null,s=i._option("markerIconSrc"),f,e,h,c;s&&(o={icon:s}),t.iconSrc&&(o={icon:t.iconSrc}),f=new Microsoft.Maps.Pushpin(u,o),i._map.entities.push(f,null),e=i._renderTooltip(u,t.tooltip),(t.clickAction||t.tooltip)&&(c=i._createAction(t.clickAction||n.noop),h=Microsoft.Maps.Events.addHandler(f,"click",function(){c({location:i._normalizeLocation(u)}),e&&e.setOptions({visible:!0})})),i._extendBounds(u),r.resolve({pushpin:f,infobox:e,handler:h})}),r.promise()},_renderTooltip:function(n,t){if(t){t=this._parseTooltipOptions(t);var i=new Microsoft.Maps.Infobox(n,{description:t.text,offset:new Microsoft.Maps.Point(0,33),visible:t.visible});return this._map.entities.push(i,null),i}},updateRoutes:function(){return this._refreshRoutes()},addRoutes:function(n){return this._renderRoutes(n)},_refreshRoutes:function(){return this._clearRoutes(),this._renderRoutes()},_renderRoutes:function(t){t=t||this._option("routes");var i=n.Deferred(),r=this,u=n.map(t,function(n){return r._addRoute(n)});return n.when.apply(n,u).done(function(){i.resolve(!1,n.makeArray(arguments))}),i.promise()},_clearRoutes:function(){var t=this;n.each(this._routes,function(n,t){t.dispose()}),this._routes=[]},_addRoute:function(n){var t=this;return this._renderRoute(n).done(function(n){t._routes.push(n)})},_renderRoute:function(i){var u=n.Deferred(),r=this,f=n.map(i.locations,function(n){return r._resolveLocation(n)});return n.when.apply(n,f).done(function(){var s=n.makeArray(arguments),f=new Microsoft.Maps.Directions.DirectionsManager(r._map),h=new t.Color(i.color||r._defaultRouteColor()).toHex(),e=new Microsoft.Maps.Color.fromHex(h),o;e.a=(i.opacity||r._defaultRouteOpacity())*255,f.setRenderOptions({autoUpdateMapView:!1,displayRouteSelector:!1,waypointPushpinOptions:{visible:!1},drivingPolylineOptions:{strokeColor:e,strokeThickness:i.weight||r._defaultRouteWeight()},walkingPolylineOptions:{strokeColor:e,strokeThickness:i.weight||r._defaultRouteWeight()}}),f.setRequestOptions({routeMode:r._movementMode(i.mode),routeDraggable:!1}),n.each(s,function(n,t){var i=new Microsoft.Maps.Directions.Waypoint({location:t});f.addWaypoint(i)}),o=Microsoft.Maps.Events.addHandler(f,"directionsUpdated",function(){Microsoft.Maps.Events.removeHandler(o),u.resolve(f)}),f.calculateDirections()}),u.promise()},clean:function(){this._map&&(Microsoft.Maps.Events.removeHandler(this._viewChangeHandler),Microsoft.Maps.Events.removeHandler(this._clickHandler),this._clearMarkers(),this._clearRoutes(),this._map.dispose())},cancelEvents:!0}))}(jQuery,DevExpress),function(n,t,i){var f=t.ui,r="_googleScriptReady",e="https://maps.google.com/maps/api/js?v=3.9&sensor=false&callback="+r,u;f.registerMapProvider("google",f.MapProvider.inherit({_mapType:function(n){var t={hybrid:google.maps.MapTypeId.HYBRID,roadmap:google.maps.MapTypeId.ROADMAP};return t[n]||t.hybrid},_movementMode:function(n){var t={driving:google.maps.TravelMode.DRIVING,walking:google.maps.TravelMode.WALKING};return t[n]||t.driving},_resolveLocation:function(t){var i=n.Deferred(),r;return typeof t=="string"?(r=new google.maps.Geocoder,r.geocode({address:t},function(n,t){t===google.maps.GeocoderStatus.OK&&i.resolve(n[0].geometry.location)})):n.isArray(t)?i.resolve(new google.maps.LatLng(t[0],t[1])):n.isPlainObject(t)&&n.isNumeric(t.lat)&&n.isNumeric(t.lng)&&i.resolve(new google.maps.LatLng(t.lat,t.lng)),i.promise()},_normalizeLocation:function(n){return{lat:n.lat(),lng:n.lng()}},load:function(){if(!u){u=n.Deferred();var t=this._key("google");window[r]=n.proxy(this._mapReady,this),n.getScript(e+(t?"&key="+t:""))}return this._markers=[],this._routes=[],u.promise()},_mapReady:function(){try{delete window[r]}catch(n){window[r]=i}u.resolve()},render:function(){var r=n.Deferred(),i=n.Deferred(),t=this._option("controls"),f={zoom:this._option("zoom"),center:new google.maps.LatLng(0,0),mapTypeId:this._mapType(this._option("type")),panControl:t,zoomControl:t,mapTypeControl:t,streetViewControl:t},u;this._map=new google.maps.Map(this._$container[0],f),u=google.maps.event.addListener(this._map,"idle",n.proxy(i.resolve,i)),this._zoomChangeListener=google.maps.event.addListener(this._map,"zoom_changed",n.proxy(this._handleZoomChange,this)),this._centerChangeListener=google.maps.event.addListener(this._map,"center_changed",n.proxy(this._handleCenterChange,this)),this._clickListener=google.maps.event.addListener(this._map,"click",n.proxy(this._handleClickAction,this));var e=this._renderLocation(),o=this._refreshMarkers(),s=this._renderRoutes();return n.when(i,e,o,s).done(function(){google.maps.event.removeListener(u),r.resolve(!0)}),r.promise()},updateDimensions:function(){return google.maps.event.trigger(this._map,"resize"),n.Deferred().resolve().promise()},updateMapType:function(){return this._map.setMapTypeId(this._mapType(this._option("type"))),n.Deferred().resolve().promise()},updateLocation:function(){return this._renderLocation()},_handleCenterChange:function(){var n=this._map.getCenter();this._option("location",this._normalizeLocation(n))},_renderLocation:function(){var t=n.Deferred(),i=this;return this._resolveLocation(this._option("location")).done(function(n){i._map.setCenter(n),t.resolve()}),t.promise()},_handleZoomChange:function(){this._option("zoom",this._map.getZoom())},updateZoom:function(){return this._map.setZoom(this._option("zoom")),n.Deferred().resolve().promise()},updateControls:function(){var t=this._option("controls");return this._map.setOptions({panControl:t,zoomControl:t,mapTypeControl:t,streetViewControl:t}),n.Deferred().resolve().promise()},_clearBounds:function(){this._bounds=null},_extendBounds:function(n){this._bounds?this._bounds.extend(n):(this._bounds=new google.maps.LatLngBounds,this._bounds.extend(n))},_fitBounds:function(){this._bounds&&this._map.fitBounds(this._bounds)},updateMarkers:function(){return this._refreshMarkers()},_refreshMarkers:function(){return this._clearMarkers(),this._renderMarkers()},_clearMarkers:function(){var t=this;this._clearBounds(),n.each(this._markers,function(n,t){t.instance.setMap(null),t.listner&&google.maps.event.removeListener(t.listner)}),this._markers=[]},addMarkers:function(n){return this._renderMarkers(n)},_renderMarkers:function(t){t=t||this._option("markers");var i=n.Deferred(),r=this,u=n.map(t,function(n){return r._addMarker(n)});return n.when.apply(n,u).done(function(){var t=n.map(n.makeArray(arguments),function(n){return n.instance});i.resolve(!1,t)}),i.done(function(){r._fitBounds()}),i.promise()},_addMarker:function(n){var t=this;return this._renderMarker(n).done(function(n){t._markers.push(n)})},_renderMarker:function(t){var r=n.Deferred(),i=this;return this._resolveLocation(t.location).done(function(u){var f,e={position:u,map:i._map},s=i._option("markerIconSrc"),h,o,c;s&&(e.icon=s),t.iconSrc&&(e.icon=t.iconSrc),f=new google.maps.Marker(e),o=i._renderTooltip(f,t.tooltip),(t.clickAction||t.tooltip)&&(c=i._createAction(t.clickAction||n.noop),h=google.maps.event.addListener(f,"click",function(){c({location:i._normalizeLocation(u)}),o&&o.open(i._map,f)})),i._extendBounds(u),r.resolve({instance:f,listner:h})}),r.promise()},_renderTooltip:function(n,t){if(t){t=this._parseTooltipOptions(t);var i=new google.maps.InfoWindow({content:t.text});return t.visible&&i.open(this._map,n),i}},updateRoutes:function(){return this._refreshRoutes()},addRoutes:function(){return this._renderRoutes()},_refreshRoutes:function(){return this._clearRoutes(),this._renderRoutes()},_clearRoutes:function(){var t=this;n.each(this._routes,function(n,t){t.setMap(null)}),this._routes=[]},_renderRoutes:function(t){t=t||this._option("routes");var i=n.Deferred(),r=this,u=n.map(t,function(n){return r._addRoute(n)});return n.when.apply(n,u).done(function(){i.resolve(!1,n.makeArray(arguments))}),i.promise()},_addRoute:function(n){var t=this;return this._renderRoute(n).done(function(n){t._routes.push(n)})},_renderRoute:function(i){var u=n.Deferred(),r=this,f=new google.maps.DirectionsService,e=n.map(i.locations,function(n){return r._resolveLocation(n)});return n.when.apply(n,e).done(function(){var e=n.makeArray(arguments),o=e.shift(),s=e.pop(),h=n.map(e,function(n){return{location:n,stopover:!0}}),c={origin:o,destination:s,waypoints:h,optimizeWaypoints:!0,travelMode:r._movementMode(i.mode)};f.route(c,function(n,f){if(f===google.maps.DirectionsStatus.OK){var e=new t.Color(i.color||r._defaultRouteColor()).toHex(),o={directions:n,map:r._map,suppressMarkers:!0,preserveViewport:!0,polylineOptions:{strokeWeight:i.weight||r._defaultRouteWeight(),strokeOpacity:i.opacity||r._defaultRouteOpacity(),strokeColor:e}},s=new google.maps.DirectionsRenderer(o);u.resolve(s)}})}),u.promise()},clean:function(){this._map&&(google.maps.event.removeListener(this._zoomChangeListener),google.maps.event.removeListener(this._centerChangeListener),google.maps.event.removeListener(this._clickListener),this._clearMarkers(),this._clearRoutes(),delete this._map,this._$container.empty())},cancelEvents:!0}))}(jQuery,DevExpress),function(n,t){var r=t.ui,u="https://maps.google.com/maps/api/staticmap?";r.registerMapProvider("googleStatic",r.MapProvider.inherit({_locationToString:function(t){return n.isPlainObject(t)?t.lat+","+t.lng:t.toString().replace(/ /g,"+")},render:function(){return this._updateMap()},updateDimensions:function(){return this._updateMap()},updateMapType:function(){return this._updateMap()},updateLocation:function(){return this._updateMap()},updateZoom:function(){return this._updateMap()},updateControls:function(){return n.Deferred().resolve().promise()},updateMarkers:function(){return this._updateMap()},addMarkers:function(){return this._updateMap()},updateRoutes:function(){return this._updateMap()},addRoutes:function(){return this._updateMap()},clean:function(){this._$container.css("background-image","none")},mapRendered:function(){return!0},_updateMap:function(){var r=this._key("googleStatic"),t=["sensor=false","size="+this._option("width")+"x"+this._option("height"),"maptype="+this._option("type"),"center="+this._locationToString(this._option("location")),"zoom="+this._option("zoom"),this._markersSubstring()],i;return t.push.apply(t,this._routeSubstrings()),r&&t.push("key="+this._key("googleStatic")),i=u+t.join("&"),this._$container.css("background",'url("'+i+'") no-repeat 0 0'),n.Deferred().resolve(!0).promise()},_markersSubstring:function(){var r=this,t=[],i=this._option("markerIconSrc");return i&&t.push("icon:"+i),n.each(this._option("markers"),function(n,i){t.push(r._locationToString(i.location))}),"markers="+t.join("|")},_routeSubstrings:function(){var r=this,i=[];return n.each(this._option("routes"),function(u,f){var o=new t.Color(f.color||ROUTE_COLOR_DEFAULT).toHex().replace("#","0x"),s=Math.round((f.opacity||ROUTE_OPACITY_DEFAULT)*255).toString(16),h=f.weight||ROUTE_WEIGHT_DEFAULT,e=[];n.each(f.locations,function(n,t){e.push(r._locationToString(t))}),i.push("path=color:"+o+s+"|weight:"+h+"|"+e.join("|"))}),i}}))}(jQuery,DevExpress),function(n,t){var r=t.ui,f=r.events,u="dxSwipeable",e="dx-swipeable",o={startAction:"dxswipestart",updateAction:"dxswipe",endAction:"dxswipeend",cancelAction:"dxswipecancel"};r.registerComponent(u,r.Component.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{elastic:!0,direction:"horizontal",itemSizeFunc:null,startAction:null,updateAction:null,endAction:null,cancelAction:null})},_render:function(){this.callBase(),this._element().addClass(e),this._attachEventHandlers()},_attachEventHandlers:function(){if(!this.option("disabled")){var t=this.NAME;this._createEventData(),n.each(o,n.proxy(function(n,i){var r=this._createActionByOption(n,{context:this,excludeValidators:["gesture"]}),i=f.addNamespace(i,t);this._element().off(i).on(i,this._eventData,function(n){return r({jQueryEvent:n})})},this))}},_createEventData:function(){this._eventData={elastic:this.option("elastic"),itemSizeFunc:this.option("itemSizeFunc"),direction:this.option("direction")}},_detachEventHanlers:function(){this._element().off("."+u)},_optionChanged:function(n){switch(n){case"disabled":case"startAction":case"updateAction":case"endAction":case"cancelAction":case"elastic":case"itemSizeFunc":case"direction":this._detachEventHanlers(),this._attachEventHandlers();break;default:this.callBase.apply(this,arguments)}}}))}(jQuery,DevExpress),function(n,t){var r=t.ui,f="dx-button",e="dx-button-content",u=".dx-button-content",o="dx-button-text",s=".dx-button-text",h="dx-button-back-arrow",c="dx-icon",l=".dx-icon",a=100;r.registerComponent("dxButton",r.Widget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{type:"normal",text:"",icon:"",iconSrc:"",hoverStateEnabled:!0})},_init:function(){this.callBase(),this._feedbackHideTimeout=a},_render:function(){this.callBase(),this._element().addClass(f).append(n("<div />").addClass(e)),this._renderIcon(),this._renderType(),this._renderText()},_clean:function(){this.callBase(),this._removeTypesCss()},_removeTypesCss:function(){var n=this._element().attr("class");n=n.replace(/\bdx-button-[-a-z0-9]+\b/gi,""),this._element().attr("class",n)},_renderIcon:function(){var f=this._element().find(u),i=f.find(l),t=this.option("icon"),r=this.option("iconSrc");(i.remove(),this.option("type")!=="back"||t||(t="back"),t||r)&&(t?i=n("<span />").addClass("dx-icon-"+t):r&&(i=n("<img />").attr("src",r)),f.prepend(i.addClass(c)))},_renderType:function(){var t=this.option("type");t&&this._element().addClass("dx-button-"+t),t==="back"&&this._element().prepend(n("<span />").addClass(h))},_renderText:function(){var r=this.option("text"),f=this._element().find(u),e=this.option("type")==="back",i=f.find(s);if(!r&&!e){i.remove();return}i.length||(i=n("<span />").addClass(o).appendTo(f)),i.text(r||t.localization.localizeString("@Back"))},_optionChanged:function(n){switch(n){case"icon":case"iconSrc":this._renderIcon();break;case"text":this._renderText();break;case"type":this._invalidate();break;default:this.callBase.apply(this,arguments)}}}))}(jQuery,DevExpress),function(n,t){var r=t.ui,u=r.events,f="dx-checkbox",e="dx-checkbox-icon",o="dx-checkbox-checked",s=100;r.registerComponent("dxCheckBox",r.Widget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{checked:!1,hoverStateEnabled:!0})},_init:function(){this.callBase(),this._feedbackHideTimeout=s},_render:function(){this.callBase(),this._element().addClass(f),n("<span />").addClass(e).appendTo(this._element()),this._renderValue()},_renderClick:function(){var n=this,t=u.addNamespace("dxclick",this.NAME),i=this._createActionByOption("clickAction",{beforeExecute:function(){n.option("checked",!n.option("checked"))}});this._element().off(t).on(t,function(n){i({jQueryEvent:n})})},_renderValue:function(){this._element().toggleClass(o,Boolean(this.option("checked")))},_optionChanged:function(n){switch(n){case"checked":this._renderValue();break;default:this.callBase.apply(this,arguments)}}}))}(jQuery,DevExpress),function(n,t){var u=t.ui,e=u.events,f=t.fx,r="dx-switch",o=r+"-wrapper",s=r+"-inner",h=r+"-handle",c=r+"-on-value",l=r+"-on",a=r+"-off",v=100;u.registerComponent("dxSwitch",u.Widget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{onText:Globalize.localize("dxSwitch-onText"),offText:Globalize.localize("dxSwitch-offText"),value:!1,valueChangeAction:null})},_init:function(){this.callBase(),this._animating=!1,this._animationDuration=v},_render:function(){var t=this._element();this._$switchInner=n("<div />").addClass(s),this._$handle=n("<div />").addClass(h).appendTo(this._$switchInner),this._$labelOn=n("<div />").addClass(l).prependTo(this._$switchInner),this._$labelOff=n("<div />").addClass(a).appendTo(this._$switchInner),this._$switchWrapper=n("<div />").addClass(o).append(this._$switchInner),t.addClass(r).append(this._$switchWrapper),t.dxSwipeable({elastic:!1,startAction:n.proxy(this._handleSwipeStart,this),updateAction:n.proxy(this._handleSwipeUpdate,this),endAction:n.proxy(this._handleSwipeEnd,this)}),this._renderLabels(),this.callBase(),this._updateMarginBound(),this._renderValue(),this._renderValueChangeAction()},_renderValueChangeAction:function(){this._changeAction=this._createActionByOption("valueChangeAction")},_updateMarginBound:function(){this._marginBound=this._$switchWrapper.outerWidth(!0)-this._$handle.width()},_renderPosition:function(n,t){var i=n?1:0;this._$switchInner.css("marginLeft",this._marginBound*(i+t-1))},_validateValue:function(){var n=this.option("value");typeof n!="boolean"&&(this._options.value=!!n)},_renderClick:function(){this.callBase();var t=e.addNamespace("dxclick",this.NAME),i=this._createAction(n.proxy(this._handleClick,this));this._element().on(t,function(n){i({jQueryEvent:n})})},_handleClick:function(n){var t=n.component,i,r;t._animating||t._swiping||(t._animating=!0,i=t.option("value"),r=!i,f.animate(this._$switchInner,{from:{marginLeft:(Number(i)-1)*this._marginBound},to:{marginLeft:(Number(r)-1)*this._marginBound},duration:t._animationDuration,complete:function(){t._animating=!1,t.option("value",r)}}))},_handleSwipeStart:function(n){var t=this.option("value");n.jQueryEvent.maxLeftOffset=t?1:0,n.jQueryEvent.maxRightOffset=t?0:1,this._swiping=!0},_handleSwipeUpdate:function(n){this._renderPosition(this.option("value"),n.jQueryEvent.offset)},_handleSwipeEnd:function(n){var t=this;f.animate(this._$switchInner,{to:{marginLeft:this._marginBound*(t.option("value")+n.jQueryEvent.targetOffset-1)},duration:t._animationDuration,complete:function(){t._swiping=!1;var i=t.option("value")+n.jQueryEvent.targetOffset;t.option("value",Boolean(i))}})},_renderValue:function(){this._validateValue();var n=this.option("value");this._renderPosition(n,0),this._element().toggleClass(c,n)},_renderLabels:function(){this._$labelOn.text(this.option("onText")),this._$labelOff.text(this.option("offText"))},_optionChanged:function(n,t,i){switch(n){case"visible":case"width":this._refresh();break;case"value":this._renderValue(),this._changeAction(t);break;case"valueChangeAction":this._renderValueChangeAction();break;case"onText":case"offText":this._renderLabels();break;default:this.callBase(n,t,i)}},_feedbackOff:function(n){n||this.callBase.apply(this,arguments)}}))}(jQuery,DevExpress),function(n,t,i){var r=t.ui,u=r.events,h="dx-editbox",f="dx-editbox-input",c="."+f,l="dx-editbox-border",e="dx-placeholder",o=["focusIn","focusOut","keyDown","keyPress","keyUp","change"],s=function(){var n=document.createElement("input");return"placeholder"in n}();r.registerComponent("dxEditBox",r.Widget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{value:"",valueUpdateEvent:"change",valueUpdateAction:null,placeholder:"",readOnly:!1,focusInAction:null,focusOutAction:null,keyDownAction:null,keyPressAction:null,keyUpAction:null,changeAction:null,enterKeyAction:null,mode:"text"})},_input:function(){return this._element().find(c)},_render:function(){this._element().addClass(h),this._renderInput(),this._renderInputType(),this._renderValue(),this._renderProps(),this._renderPlaceholder(),this._renderEvents(),this._renderEnterKeyAction(),this.callBase()},_renderInput:function(){this._element().append(n("<input />").addClass(f)).append(n("<div />").addClass(l))},_renderValue:function(){this._input().val()!==this.option("value")&&this._input().val(this.option("value"))},_renderProps:function(){this._input().prop({placeholder:this.option("placeholder"),readOnly:this._readOnlyPropValue(),disabled:this.option("disabled")})},_readOnlyPropValue:function(){return this.option("readOnly")},_renderPlaceholder:function(){if(!s){var t=this,f=t.option("placeholder"),i=t._input(),r=n("<div />").addClass(e).addClass("dx-hide").attr("data-dx_placeholder",f),o=u.addNamespace("dxpointerdown",this.NAME);r.on(o,function(){i.focus()});i.wrap(r).on("focus.dxEditBox focusin.dxEditBox",function(){t._setStatePlaceholder.call(t,!0)}).on("blur.dxEditBox focusout.dxEditBox",function(){t._setStatePlaceholder.call(t,!1)});t._setStatePlaceholder()}},_renderEvents:function(){var t=this,i=t._input();n.each(o,function(n,r){var f=u.addNamespace(r.toLowerCase(),t.NAME),e=t._createActionByOption(r+"Action");i.off(f).on(f,function(n){e({jQueryEvent:n})})}),t._renderValueUpdateEvent()},_renderValueUpdateEvent:function(){var t=u.addNamespace(this.option("valueUpdateEvent"),this.NAME);this._input().off("."+this.NAME,this._handleValueChange).on(t,n.proxy(this._handleValueChange,this));this._changeAction=this._createActionByOption("valueUpdateAction")},_setStatePlaceholder:function(n){if(!s){var t=this._input(),r=t.parent("."+e);n===i&&(t.val()||t.prop("disabled")||!t.prop("placeholder")||(n=!1)),t.val()&&(n=!0),r.toggleClass("dx-hide",n)}},_handleValueChange:function(n){this._currentValueUpdateEvent=n,this.option("value",this._input().val()),this._currentValueUpdateEvent&&this._dispatchChangeAction()},_renderEnterKeyAction:function(){if(this.option("enterKeyAction")){this._enterKeyAction=this._createActionByOption("enterKeyAction");this._input().on("keyup.enterKey.dxEditBox",n.proxy(this._onKeyDownHandler,this))}else this._input().off("keyup.enterKey.dxEditBox"),this._enterKeyAction=i},_onKeyDownHandler:function(n){n.which===13&&this._enterKeyAction({jQueryEvent:n})},_toggleDisabledState:function(){this.callBase.apply(this,arguments),this._renderProps()},_dispatchChangeAction:function(){this._changeAction({actionValue:this.option("value"),jQueryEvent:this._currentValueUpdateEvent}),this._currentValueUpdateEvent=i},_updateValue:function(){this._renderValue(),this._setStatePlaceholder(),this._dispatchChangeAction()},_optionChanged:function(t){if(n.inArray(t.replace("Action",""),o)>-1){this._renderEvents();return}switch(t){case"value":this._updateValue();break;case"valueUpdateEvent":case"valueUpdateAction":this._renderValueUpdateEvent();break;case"readOnly":this._renderProps();break;case"mode":this._renderInputType();break;case"enterKeyAction":this._renderEnterKeyAction();break;case"placeholder":this._invalidate();break;default:this.callBase.apply(this,arguments)}},_renderInputType:function(){var n=this._input();try{n.prop("type",this.option("mode"))}catch(t){n.prop("type","text")}},focus:function(){this._input().trigger("focus")}}))}(jQuery,DevExpress),function(n,t){var r=t.ui,u=r.events,f="dx-textbox",e=[8,9,13,33,34,35,36,37,38,39,40,46];r.registerComponent("dxTextBox",r.dxEditBox.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{mode:"text",maxLength:null})},_render:function(){if(this.callBase(),this._element().addClass(f),this._isAndroid())this._input().on(u.addNamespace("keydown",this.NAME),n.proxy(this._onKeyDownAndroidHandler,this)).on(u.addNamespace("change",this.NAME),n.proxy(this._onChangeAndroidHandler,this))},_renderProps:function(){if(this.callBase(),!this._isAndroid()){var n=this.option("maxLength");n>0&&this._input().prop("maxLength",n)}},_optionChanged:function(n){switch(n){case"maxLength":this._renderProps();break;default:this.callBase.apply(this,arguments)}},_onKeyDownAndroidHandler:function(t){var r=this.option("maxLength"),i,u;return r?(i=n(t.target),u=t.keyCode,this._cutOffExtraChar(i),i.val().length<r||n.inArray(u,e)!==-1||window.getSelection().toString()!==""):!0},_onChangeAndroidHandler:function(t){var i=n(t.target);this.option("maxLength")&&this._cutOffExtraChar(i)},_cutOffExtraChar:function(n){var t=this.option("maxLength"),i=n.val();i.length>t&&n.val(i.substr(0,t))},_isAndroid:function(){var i=window.navigator.userAgent,n=t.devices.real.version.join(".");return t.devices.real.platform==="android"&&n&&/^(2\.|4\.0|4\.1)/.test(n)&&i.indexOf("Chrome")===-1}}))}(jQuery,DevExpress),function(n,t){var u=t.ui,r=u.events,f="dx-textarea",e="dx-editbox-input",o="dx-editbox-border";u.registerComponent("dxTextArea",u.dxTextBox.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{})},_render:function(){this.callBase(),this._element().addClass(f)},_renderInput:function(){this._element().append(n("<textarea>").addClass(e)).append(n("<div />").addClass(o)),this._renderScrollHandler()},_renderScrollHandler:function(){var n=this._input(),t=0;n.on(r.addNamespace("dxpointerdown",this.NAME),function(n){t=r.eventData(n).y});n.on(r.addNamespace("dxpointermove",this.NAME),function(i){var u=n.scrollTop(),f=n.prop("scrollHeight")-n.prop("clientHeight")-u;if(u!==0||f!==0){var e=r.eventData(i).y,o=u===0&&t>=e,s=f===0&&t<=e,h=u>0&&f>0;(o||s||h)&&(i.originalEvent.isScrollingEvent=!0),t=e}})},_renderInputType:n.noop,_renderDimensions:function(){this.callBase();var n=this.option("width"),t=this.option("height");this._input().width(n),this._input().height(t)}}))}(jQuery,DevExpress),function(n,t,i){var r=t.ui,u=Math,f=r.events;r.registerComponent("dxNumberBox",r.dxEditBox.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{value:0,min:-Number.MAX_VALUE,max:Number.MAX_VALUE,mode:"number"})},_render:function(){this.callBase(),this._element().addClass("dx-numberbox"),this._setInputInvalidHandler()},_renderProps:function(){this.callBase(),this._input().prop({min:this.option("min"),max:this.option("max")})},_setInputInvalidHandler:function(){var t=this,i=f.addNamespace(this.option("valueUpdateEvent"),this.NAME);this._input().on(i,function(){var n=t._input()[0];typeof n.checkValidity=="function"&&n.checkValidity()}).focusout(n.proxy(this._trimInputValue,this)).on("invalid",n.proxy(this._inputInvalidHandler,this))},_renderValue:function(){var n=this.option("value")?this.option("value").toString():this.option("value");this._input().val()!==n&&this._input().val(this.option("value"))},_trimInputValue:function(){var i=this._input(),t=n.trim(i.val());t[t.length-1]==="."&&(t=t.slice(0,-1)),this._forceRefreshInputValue(t)},_inputInvalidHandler:function(){var n=this._input(),t=n.val();if(this._oldValue){this.option("value",this._oldValue),n.val(this._oldValue),this._oldValue=null;return}(!t||/,/.test(t))&&(this.option("value",""),n.val(""))},_handleValueChange:function(){var i=this._input(),t=n.trim(i.val());(t=t.replace(",","."),this._validateValue(t))&&(t=this._parseValue(t),t||t===0)&&(this.option("value",t),i.val()!=t&&i.val(t))},_forceRefreshInputValue:function(n){var t=this._input();t.val("").val(n)},_validateValue:function(n){var i=f.addNamespace(this.option("valueUpdateEvent"),this.NAME),t=this._input();return(this._oldValue=null,this._hasCommaChar=null,!n)?(this._oldValue=this.option("value"),this.option("value",""),this._hasCommaChar&&t.trigger("invalid"),!1):n[n.length-1]==="."?!1:!0},_calcPointsCount:function(t){for(var i=0,r=-1;(r=n.inArray(".",t.split(""),r+1))>-1;)i++;return i},_parseValue:function(n){var t=Globalize.parseFloat(n,10,Globalize.cultures["default"].language);return isNaN(t)?(this._input().val(this.option("value")),i):(t=u.max(t,this.option("min")),t=u.min(t,this.option("max")))},_optionChanged:function(n){n==="min"||n==="max"?this._renderProps(arguments):this.callBase.apply(this,arguments)}}))}(jQuery,DevExpress),function(n,t){var u=t.ui,f=u.events,s=t.translator,e=t.utils,r="dx-slider",h=r+"-wrapper",o=r+"-handle",c="."+o,l=r+"-bar",a=r+"-range";u.registerComponent("dxSlider",u.Widget.inherit({_activeStateUnit:c,_defaultOptions:function(){return n.extend(this.callBase(),{min:0,max:100,step:1,value:50})},_init:function(){this.callBase(),e.windowResizeCallbacks.add(this._refreshHandler=n.proxy(this._refresh,this))},_dispose:function(){this.callBase(),e.windowResizeCallbacks.remove(this._refreshHandler)},_render:function(){this.callBase(),this._$wrapper=n("<div />").addClass(h),this._$bar=n("<div />").addClass(l).appendTo(this._$wrapper),this._$selectedRange=n("<div />").addClass(a).appendTo(this._$bar),this._$handle=n("<div />").addClass(o).appendTo(this._$bar),this._element().addClass(r).append(this._$wrapper),this._$wrapper.dxSwipeable({elastic:!1,startAction:n.proxy(this._handleSwipeStart,this),updateAction:n.proxy(this._handleSwipeUpdate,this),cancelAction:n.proxy(this._handleSwipeCancel,this),itemWidthFunc:n.proxy(this._itemWidthFunc,this)}),this._renderValue(),this._renderStartHandler()},_renderStartHandler:function(){var t=f.addNamespace("dxpointerdown",this.NAME),i=this._createAction(n.proxy(this._handleStart,this),{excludeValidators:["gesture"]});this._element().off(t).on(t,function(n){i({jQueryEvent:n})})},_itemWidthFunc:function(){return this._element().width()},_handleSwipeStart:function(n){this._startOffset=this._currentRatio,n.jQueryEvent.maxLeftOffset=this._startOffset,n.jQueryEvent.maxRightOffset=1-this._startOffset},_handleSwipeUpdate:function(n){this._handleValueChange(this._startOffset+n.jQueryEvent.offset)},_handleSwipeCancel:function(){this._feedbackOff()},_handleValueChange:function(n){var r=this.option("min"),e=this.option("max"),t=this.option("step"),o=n*(e-r),i=r+o,u,f;((!t||isNaN(t))&&(t=1),t=parseFloat(t.toFixed(5)),t===0&&(t=1e-5),t<0)||(i===e||i===r?this.option("value",i):(u=(t+"").split("."),f=u.length>1?u[1].length:f,i=Number((Math.round(o/t)*t+r).toFixed(f)),this.option("value",this._fitValue(i))))},_fitValue:function(n){return n=Math.min(n,this.option("max")),n=Math.max(n,this.option("min"))},_handleStart:function(n){var t=n.jQueryEvent;f.needSkipEvent(t)||(this._currentRatio=(u.events.eventData(t).x-this._$bar.offset().left)/this._$bar.width(),this._handleValueChange(this._currentRatio))},_renderValue:function(){var i=this.option("value"),n=this.option("min"),t=this.option("max");if(!(n>t)){if(i<n){this.option("value",n),this._currentRatio=0;return}if(i>t){this.option("value",t),this._currentRatio=1;return}var f=this._$handle.outerWidth(),u=this._$bar.width(),r=n===t?0:(i-n)/(t-n);this._$selectedRange.width(r*u),s.move(this._$handle,{left:r*u-f/2}),this._currentRatio=r}},_optionChanged:function(n){switch(n){case"min":case"max":case"step":case"value":this._renderValue();break;default:this.callBase.apply(this,arguments)}},_feedbackOff:function(n){n||this.callBase.apply(this,arguments)}}))}(jQuery,DevExpress),function(n,t){var r=t.ui,f=r.events,u=t.translator,e="dx-slider-handle";r.registerComponent("dxRangeSlider",r.dxSlider.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{start:40,end:60,value:50})},_render:function(){this._$handleRight=n("<div />").addClass(e),this.callBase(),this._$handleRight.appendTo(this._$bar)},_handleStart:function(n){var r=n.jQueryEvent,u=f.eventData(r).x-this._$bar.offset().left,t=this._$handle.position().left,i=this._$handleRight.position().left;this._$handlersDistance=Math.abs(t-i),this._capturedHandle=(t+i)/2>u?this._$handle:this._$handleRight,this.callBase(n)},_handleSwipeUpdate:function(n){Math.abs(this.option("start")-this.option("end"))===0&&this._$handlersDistance<this._$handle.outerWidth()&&(this._feedbackOff(!0),this._capturedHandle=n.jQueryEvent.offset<=0?this._$handle:this._$handleRight,this._feedbackOn(this._capturedHandle,!0)),this.callBase(n)},_handleValueChange:function(n){this.callBase(n);var f=this._capturedHandle===this._$handle?"start":"end",t=this.option("start"),u=this.option("end"),r=this.option("value"),i=this.option("max"),e=this.option("min");t>i&&(t=i,this.option("start",i)),t<e&&(t=e,this.option("start",e)),u>i&&(u=i,this.option("end",i)),r>u&&f==="start"&&(r=u),r<t&&f==="end"&&(r=t),this.option(f,r)},_renderValue:function(){var i=this.option("start"),r=this.option("end"),n=this.option("min"),t=this.option("max");i<n&&(i=n),i>t&&(i=t),r>t&&(r=t),r<i&&(r=i);var o=this._$handle.outerWidth(),f=this._$bar.width(),e=t===n?0:(i-n)/(t-n),s=t===n?0:(r-n)/(t-n);this._$selectedRange.width((s-e)*f),u.move(this._$selectedRange,{left:e*f}),u.move(this._$handle,{left:e*f-o/2}),u.move(this._$handleRight,{left:s*f-o/2})},_optionChanged:function(n){switch(n){case"start":case"end":this._renderValue();break;default:this.callBase.apply(this,arguments)}}}))}(jQuery,DevExpress),function(n,t,i){var r=t.ui,v=r.events,f="dx-radio-group",o="dx-radio-group-vertical",s="dx-radio-group-horizontal",e="dx-radio-button",u="."+e,h="dx-radio-button-value",c="dx-radio-value-container",y="dx-state-active",l="dxRadioButtonData",a=100;r.registerComponent("dxRadioGroup",r.SelectableCollectionWidget.inherit({_activeStateUnit:u,_defaultOptions:function(){return n.extend(this.callBase(),{layout:"vertical",value:i,valueExpr:null,hoverStateEnabled:!0})},_itemClass:function(){return e},_itemDataKey:function(){return l},_itemContainer:function(){return this._element()},_init:function(){this.callBase(),this._dataSource||this._itemsToDataSource(),this._feedbackHideTimeout=a},_itemsToDataSource:function(){this._dataSource=new DevExpress.data.DataSource(this.option("items"))},_render:function(){this._element().addClass(f),this._compileValueGetter(),this.callBase(),this._renderLayout(),this._renderValue()},_compileValueGetter:function(){this._valueGetter=t.data.utils.compileGetter(this._valueGetterExpr())},_valueGetterExpr:function(){return this.option("valueExpr")||this._dataSource&&this._dataSource._store._key||"this"},_renderLayout:function(){var n=this.option("layout");this._element().toggleClass(o,n==="vertical"),this._element().toggleClass(s,n==="horizontal")},_renderValue:function(){this.option("value")?this._setIndexByValue():this._setValueByIndex()},_setIndexByValue:function(n){var t=this;n=n===i?t.option("value"):n,t._searchValue(n).done(function(n){t._dataSource.isLoaded()?t._setIndexByItem(n):t._dataSource.load().done(function(){t._setIndexByItem(n)})})},_setIndexByItem:function(t){this.option("selectedIndex",n.inArray(t,this._dataSource.items()))},_searchValue:function(i){var r=this,u=r._dataSource.store(),e=r._valueGetterExpr(),f=n.Deferred();return e===u.key()||u instanceof t.data.CustomStore?u.byKey(i).done(function(n){f.resolveWith(r,[n])}):u.load({filter:[e,i]}).done(function(n){f.resolveWith(r,n)}),f.promise()},_setValueByIndex:function(){var n=this.option("selectedIndex"),u=this._itemElements(),t,r;if(n<0||n>=u.length)return i;t=this._selectedItemElement(n),r=this._getItemData(t),this.option("value",this._getItemValue(r))},_getItemValue:function(n){return this._valueGetter(n)||n.text},_renderSelectedIndex:function(n){var i=this._itemElements(),t,r;n>=0&&n<i.length&&(t=i.eq(n),r=t.closest("."+f),r.find(u).removeClass("checked"),t.closest(u).addClass("checked"))},_createItemByRenderer:function(n,t){var i=this.callBase.apply(this,arguments);return this._renderInput(i,t.item),i},_createItemByTemplate:function(n,t){var i=this.callBase.apply(this,arguments);return this._renderInput(i,t.item),i},_renderInput:function(t,i){if(!i.html){var r=n("<div>").addClass(h),u=n("<div>").append(r).addClass(c);t.prepend(u)}},_optionChanged:function(n,t){switch(n){case"value":this._setIndexByValue(t);break;case"selectedIndex":this.callBase.apply(this,arguments),this._setValueByIndex();break;case"layout":this._renderLayout();break;case"valueExpr":this._compileValueGetter(),this._setValueByIndex();break;default:this.callBase.apply(this,arguments)}}}))}(jQuery,DevExpress),function(n,t){var r=t.ui,v=r.events,e="dx-tabs",o="dx-indent-wrapper",s="dx-tab",h=".dx-tab",u="dx-tab-selected",c="dx-tab-text",f="dx-icon",l="dxTabData",a=100;r.registerComponent("dxTabs",r.SelectableCollectionWidget.inherit({_activeStateUnit:h,_defaultOptions:function(){return n.extend(this.callBase(),{})},_init:function(){this.callBase(),this._feedbackHideTimeout=a},_itemClass:function(){return s},_itemDataKey:function(){return l},_itemRenderDefault:function(t,i,r){if(this.callBase(t,i,r),!t.html){var s=t.text,e=t.icon,o=t.iconSrc,u;s&&r.wrapInner(n("<span />").addClass(c)),e?u=n("<span />").addClass(f+"-"+e):o&&(u=n("<img />").attr("src",o)),u&&u.addClass(f).prependTo(r)}},_render:function(){this.callBase(),this._element().addClass(e),this._renderWrapper()},_renderWrapper:function(){this._element().wrapInner(n("<div />").addClass(o))},_renderSelectedIndex:function(n,t){var i=this._itemElements();t>=0&&i.eq(t).removeClass(u),n>=0&&i.eq(n).addClass(u)}}))}(jQuery,DevExpress),function(n,t){var r=t.ui,u="dx-navbar",f="dx-nav-item",e="dx-nav-item-content";r.registerComponent("dxNavBar",r.dxTabs.inherit({_render:function(){this.callBase(),this._element().addClass(u)},_renderItem:function(t,i){var r=this.callBase(t,i);return r.addClass(f).wrapInner(n("<div />").addClass(e))}}))}(jQuery,DevExpress),function(n,t,i){var o=t.ui,f=t.fx,u=t.translator,s=o.events,v="dx-pivottabs",l="dx-pivottabs-tab",e="dx-pivottabs-tab-selected",a="dx-pivottabs-ghosttab",y="dxPivotTabData",h=200,c="cubic-bezier(.40, .80, .60, 1)",r={moveTo:function(n,t,i){return f.animate(n,{type:"slide",to:{left:t},duration:h,easing:c,complete:i})},slideAppear:function(n,t){return f.animate(n,{type:"slide",to:{left:t,opacity:1},duration:h,easing:c})},slideDisappear:function(n,t){return f.animate(n,{type:"slide",to:{left:t,opacity:0},duration:h,easing:c})}},p=function(t){t&&n.each(t,function(n,t){f.stop(t,!0)})};o.registerComponent("dxPivotTabs",o.SelectableCollectionWidget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{selectedIndex:0,prepareAction:null,updatePositionAction:null,rollbackAction:null,completeAction:null})},_itemClass:function(){return l},_itemDataKey:function(){return y},_itemContainer:function(){return this._element()},_init:function(){this.callBase(),this._initGhostTab(),this._initSwipeHandlers(),this._initActions()},_initGhostTab:function(){this._$ghostTab=n("<div>").addClass(a)},_initActions:function(){var n={excludeValidators:["gesture"]};this._updatePositionAction=this._createActionByOption("updatePositionAction",n),this._rollbackAction=this._createActionByOption("rollbackAction",n),this._completeAction=this._createActionByOption("completeAction",n),this._prepareAction=this._createActionByOption("prepareAction",n)},_render:function(){this._element().addClass(v),this.callBase(),this._renderGhostTab()},_renderGhostTab:function(){this._itemContainer().append(this._$ghostTab),this._toggleGhostTab(!1)},_toggleGhostTab:function(n){var t=this._$ghostTab;n?(this._updateGhostTabContent(),t.css("opacity",1)):t.css("opacity",0)},_isGhostTabVisible:function(){return this._$ghostTab.css("opacity")==1},_updateGhostTabContent:function(n){n=n===i?this._previousIndex():n;var t=this._$ghostTab,r=this._itemElements();t.html(r.eq(n).html())},_updateTabsPositions:function(n){var r=this._allTabElements(),n=this._applyOffsetBoundaries(n),t=n>0,i=this._calculateTabPositions(t?"replace":"append");this._moveTabs(i,n),this._toggleGhostTab(t)},_moveTabs:function(t,i){i=i||0;var r=this._allTabElements();r.each(function(r){u.move(n(this),{left:t[r]+i})})},_applyOffsetBoundaries:function(n){n=n||0;var t=n>0?this._maxRightOffset:this._maxLeftOffset;return n*t},_animateRollback:function(){var u=this,t=this._itemElements(),i=this._calculateTabPositions("prepend");this._isGhostTabVisible()&&(this._swapGhostWithTab(t.eq(this._previousIndex())),r.moveTo(this._$ghostTab,i[this._indexBoundary()],function(){u._toggleGhostTab(!1)})),t.each(function(t){r.moveTo(n(this),i[t])})},_animateComplete:function(n,t){var i=this,r=this._itemElements(),f=this._isGhostTabVisible(),u;r.eq(t).removeClass(e),u=f?this._animateIndexDecreasing(n):this._animateIndexIncreasing(n),r.eq(n).addClass(e),u.done(function(){i._indexChangeOnAnimation=!0,i.option("selectedIndex",n),i._indexChangeOnAnimation=!1})},_animateIndexDecreasing:function(t){var f=this._itemElements(),u=this._calculateTabPositions("append",t),i=[];return f.each(function(t){i.push(r.moveTo(n(this),u[t]))}),i.push(r.slideDisappear(this._$ghostTab,u[this._indexBoundary()])),n.when.apply(n,i)},_animateIndexIncreasing:function(t){var s=this,f=this._itemElements(),o=this._calculateTabPositions("prepend",t),i=this._previousIndex(t),h=u.locate(f.eq(i)).left<0,e=[];return h||this._moveTabs(this._calculateTabPositions("append",i)),this._updateGhostTabContent(i),this._swapGhostWithTab(f.eq(i)),f.each(function(t){var u=n(this),f=o[t];e.push(t===i?r.slideAppear(u,f):r.moveTo(u,f))}),e.push(r.moveTo(this._$ghostTab,o[this._indexBoundary()],function(){s._toggleGhostTab(!1)})),n.when.apply(n,e)},_swapGhostWithTab:function(n){var t=this._$ghostTab,i=u.locate(n).left,r=n.css("opacity");u.move(n,{left:u.locate(t).left}),n.css("opacity",t.css("opacity")),u.move(t,{left:i}),t.css("opacity",r)},_calculateTabPositions:function(n,t){t=t===i?this.option("selectedIndex"):t;var r=t+n;return this._calculetedPositionsMark!==r&&(this._calculetedPositions=this._calculateTabPositionsImpl(t,n),this._calculetedPositionsMark=r),this._calculetedPositions},_calculateTabPositionsImpl:function(t,i){var f=this._normalizeIndex(t-1),h=this._itemElements(),u=[],e=0,r=[],o,s;h.each(function(){u.push(n(this).outerWidth())}),o=function(n,t){r.splice(n,0,e),e+=t},n.each(u.slice(t),o),n.each(u.slice(0,t),o);switch(i){case"replace":s=r[f],r.splice(f,1,-u[f]),r.push(s);break;case"prepend":r.push(-u[f]);break;case"append":r.push(e)}return r},_allTabElements:function(){return this._itemContainer().find("."+l+", ."+a)},_initSwipeHandlers:function(){this._element().on(s.addNamespace("dxswipestart",this.NAME),n.proxy(this._swipeStartHandler,this)).on(s.addNamespace("dxswipe",this.NAME),n.proxy(this._swipeUpdateHandler,this)).on(s.addNamespace("dxswipeend",this.NAME),n.proxy(this._swipeEndHandler,this))},_swipeStartHandler:function(n){this._prepareAnimation(),this._prepareAction(),(this.option("disabled")||this._indexBoundary()<=1)&&(n.cancel=!0)},_prepareAnimation:function(){this._stopAnimation()},_stopAnimation:function(){p(this._allTabElements())},_swipeUpdateHandler:function(n){var t=n.offset;this._updatePositionAction({offset:t}),this._updateTabsPositions(t)},_swipeEndHandler:function(n){var i=this.option("selectedIndex"),r=n.targetOffset,t;r===0?(this._animateRollback(),this._rollbackAction()):(t=this._normalizeIndex(i-r),this._animateComplete(t,i),this._completeAction({newIndex:t}))},_previousIndex:function(n){return n=n===i?this.option("selectedIndex"):n,this._normalizeIndex(n-1)},_normalizeIndex:function(n){var t=this._indexBoundary();return n<0&&(n=t+n),n>=t&&(n=n-t),n},_indexBoundary:function(){return this.option("items").length},_onItemSelectAction:function(n){this._prepareAnimation(),this._prepareAction(),this._animateComplete(n,this.option("selectedIndex")),this._completeAction({newIndex:n})},_renderSelectedIndex:function(n,t){var i=this._itemElements();this._calculateMaxOffsets(n),this._indexChangeOnAnimation||(i.eq(t).removeClass(e),this._updateTabsPositions(),i.eq(n).addClass(e))},_calculateMaxOffsets:function(n){var t=this._itemElements();this._maxLeftOffset=t.eq(n).outerWidth(),this._maxRightOffset=t.eq(this._previousIndex(n)).outerWidth()},_itemRenderDefault:function(t,i,r){var u=n("<span>").text(t.title);r.html(u)},_optionChanged:function(n){n==="items"&&delete this._calculetedPositionsMark,this.callBase.apply(this,arguments)},prepare:function(){this._prepareAnimation()},updatePosition:function(n){this._updateTabsPositions(n)},rollback:function(){this._animateRollback()},complete:function(n){this._animateComplete(n,this.option("selectedIndex"))}}))}(jQuery,DevExpress),function(n,t,i){var u=t.ui,f=u.events,r=t.fx,e=t.translator,c="dx-pivot",l="dx-pivottabs-container",a="dx-pivot-itemcontainer",v="dx-pivot-itemwrapper",y="dx-pivot-item",o="dx-pivot-item-hidden",p="dxPivotItemData",w=200,b=50,k=250,d="cubic-bezier(.10, 1, 0, 1)",s={returnBack:function(n){r.animate(n,{type:"slide",to:{left:0},duration:w})},slideAway:function(n,t,i){r.animate(n,{type:"slide",to:{left:t},duration:b,complete:i})},slideBack:function(n){r.animate(n,{type:"slide",to:{left:0},easing:d,duration:k})}},h=function(n){r.stop(n,!0)};u.registerComponent("dxPivot",u.SelectableCollectionWidget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{selectedIndex:0})},_itemClass:function(){return y},_itemDataKey:function(){return p},_itemContainer:function(){return this._$itemWrapper},_init:function(){this.callBase(),this._initTabs(),this._initItemContainer(),this._clearItemsCache(),this._initSwipeHandlers()},_initItemContainer:function(){var t=n("<div>").addClass(a);this._element().append(t),this._$itemWrapper=n("<div>").addClass(v),t.append(this._$itemWrapper)},_clearItemsCache:function(){this._itemsCache=[]},_initTabs:function(){var t=this,i=n("<div>").addClass(l);this._element().append(i),i.dxPivotTabs({items:this.option("items"),selectedIndex:this.option("selectedIndex"),prepareAction:function(){t._prepareAnimation()},updatePositionAction:function(n){t._updateContentPosition(n.offset)},rollbackAction:function(){t._animateRollback()},completeAction:function(n){t._animateComplete(n.newIndex)}}),this._tabs=i.dxPivotTabs("instance")},_render:function(){this._element().addClass(c),this.callBase()},_renderCurrentContent:function(n,t){var i=this._itemsCache;i[t]=this._selectedItemElement(),i[t].addClass(o),i[n]?i[n].removeClass(o):this._renderContent()},_updateContentPosition:function(n){e.move(this._$itemWrapper,{left:this._calculatePixelOffset(n)})},_animateRollback:function(){s.returnBack(this._$itemWrapper)},_animateComplete:function(n){var t=this,i=this._$itemWrapper,u=this._isRightSwipeHandled(),r=u?this._itemWrapperWidth:-this._itemWrapperWidth;s.slideAway(i,r,function(){e.move(i,{left:-r}),t._indexChangeOnAnimation=!0,t.option("selectedIndex",n),t._indexChangeOnAnimation=!1,s.slideBack(i)})},_calculatePixelOffset:function(n){return n=n||0,n*this._itemWrapperWidth},_isRightSwipeHandled:function(){return e.locate(this._$itemWrapper).left>0},_initSwipeHandlers:function(){this._element().on(f.addNamespace("dxswipestart",this.NAME),n.proxy(this._swipeStartHandler,this)).on(f.addNamespace("dxswipe",this.NAME),n.proxy(this._swipeUpdateHandler,this)).on(f.addNamespace("dxswipeend",this.NAME),n.proxy(this._swipeEndHandler,this))},_swipeStartHandler:function(n){this._prepareAnimation(),this._tabs.prepare(),(this.option("disabled")||this._indexBoundary()<=1)&&(n.cancel=!0)},_prepareAnimation:function(){this._stopAnimation(),this._itemWrapperWidth=this._$itemWrapper.outerWidth()},_stopAnimation:function(){h(this._$itemWrapper),h(this._$itemWrapper)},_swipeUpdateHandler:function(n){var t=n.offset;this._updateContentPosition(t),this._tabs.updatePosition(t)},_swipeEndHandler:function(n){var i=this.option("selectedIndex"),r=n.targetOffset,t;r===0?(this._animateRollback(),this._tabs.rollback()):(t=this._normalizeIndex(i-r),this._animateComplete(t,i),this._tabs.complete(t))},_renderSelectedIndex:function(n,t){t!==i&&this._renderCurrentContent(n,t)},_normalizeIndex:function(n){var t=this._indexBoundary();return n<0&&(n=t+n),n>=t&&(n=n-t),n},_indexBoundary:function(){return this.option("items").length},_renderContentImpl:function(){var n=this.option("items"),t=this.option("selectedIndex");n.length&&this._renderItems([n[t]])},_selectedItemElement:function(){return this._$itemWrapper.children(":not(."+o+")")},_optionChanged:function(n,t){switch(n){case"selectedIndex":this._indexChangeOnAnimation||this._tabs.option("selectedIndex",t),this.callBase.apply(this,arguments);break;case"items":this._tabs.option("items",t),this._clearItemsCache(),this.callBase.apply(this,arguments);break;default:this.callBase.apply(this,arguments)}}}))}(jQuery,DevExpress),function(n,t){var f=t.ui,s=t.fx,r=t.utils,h=t.translator,c="dx-toolbar",l="dx-toolbar-bottom",a="dx-toolbar-mini",v="dx-toolbar-item",e="dx-toolbar-label",u="dx-toolbar-button",y="dx-toolbar-menu-container",p="dx-toolbar-menu-button",w="dx-toolbar-items-container",o="."+e,b="dxToolbarItemDataKey",k="easeOutCubic",d=200,g=400,nt=function(n,t,i){var r=i?g:d;s.animate(n,{type:"slide",to:{top:t},easing:k,duration:r})};f.registerComponent("dxToolbar",f.CollectionContainerWidget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{menuItemRender:null,menuItemTemplate:"item",submenuType:"dxDropDownMenu",renderAs:"topToolbar"})},_itemContainer:function(){return this._$toolbarItemsContainer.find(".dx-toolbar-left,.dx-toolbar-center,.dx-toolbar-right")},_itemClass:function(){return v},_itemDataKey:function(){return b},_itemRenderDefault:function(i,r,u){var f;if(this.callBase(i,r,u),f=i.widget,f){var e=n("<div>").appendTo(u),o=t.inflector.camelize("dx-"+f),s=i.options||{};e[o](s)}else i.text&&u.wrapInner("<div>")},_render:function(){this._renderToolbar(),this._renderSections(),this.callBase(),this._renderMenu(),this._arrangeTitle(),this._windowTitleResizeCallback=n.proxy(this._arrangeTitle,this),r.windowResizeCallbacks.add(this._windowTitleResizeCallback)},_renderToolbar:function(){this._element().addClass(c).toggleClass(l,this.option("renderAs")==="bottomToolbar"),this._$toolbarItemsContainer=n("<div>").appendTo(this._element()),this._$toolbarItemsContainer.addClass(w)},_renderSections:function(){var t=this._$toolbarItemsContainer,i=this;n.each(["left","center","right"],function(){var r="dx-toolbar-"+this,u=t.find("."+r);u.length||(i["_$"+this+"Section"]=u=n("<div>").addClass(r).appendTo(t))})},_arrangeTitle:function(){var h=this._$toolbarItemsContainer,t=this._$centerSection,i=t.children(o).eq(0),r,u;if(i.length!==0){var c=h.width(),f=this._$leftSection.outerWidth(),e=this._$rightSection.outerWidth(),s=10;t.children().not(o).each(function(){s+=n(this).outerWidth()}),r=c-f-e-s,u=i.width()>r,t.css({marginLeft:u?f:"",marginRight:u?e:""}),i.css("max-width",r)}},_renderItem:function(n,t){var r=t.location||t.align||"center",f=this._$toolbarItemsContainer.find(".dx-toolbar-"+r),i=this.callBase(n,t,f);return i.addClass(u),t.text&&i.addClass(e).removeClass(u),i},_hasVisibleMenuItems:function(){var i=this._getMenuItems(),t=!1,r=DevExpress.data.utils.compileGetter("visible");return n.each(i,function(n,i){var u=r(i,{functionsAsIs:!0});u!==!1&&(t=!0)}),t},_getToolbarItems:function(){return n.grep(this.option("items")||[],function(n){return n.location!=="menu"})},_getMenuItems:function(){return n.grep(this.option("items")||[],function(n){return n.location==="menu"})},_renderContentImpl:function(){var n=this._getToolbarItems();this._element().toggleClass(a,n.length===0),this._renderedItemsCount?this._renderItems(n.slice(this._renderedItemsCount)):this._renderItems(n)},_renderMenu:function(){var t=this,i=this._createActionByOption("itemClickAction"),n={itemRender:this.option("menuItemRender"),itemTemplate:this.option("menuItemTemplate"),itemClickAction:function(n){t._toggleMenuVisibility(!1,!0),i(n)}};this._menuType=this.option("submenuType"),this._menuType==="dxList"&&this.option("renderAs")==="topToolbar"&&(this._menuType="dxDropDownMenu");switch(this._menuType){case"dxActionSheet":this._renderActionSheet(n);break;case"dxDropDownMenu":this._renderDropDown(n);break;case"dxList":this._renderList(n)}},_renderMenuButton:function(t){var i=n.extend({clickAction:n.proxy(this._handleMenuButtonClick,this)},t);this._renderMenuButtonContainer(),this._$button=n("<div>").appendTo(this._$menuButtonContainer).addClass(p).dxButton(i)},_renderMenuButtonContainer:function(){var t=this._$rightSection;this._$menuButtonContainer=n("<div>").appendTo(t).addClass(u).addClass(y)},_renderDropDown:function(t){this._hasVisibleMenuItems()&&(this._renderMenuButtonContainer(),this._menu=n("<div>").appendTo(this._$menuButtonContainer).dxDropDownMenu(t).dxDropDownMenu("instance"),this._renderMenuItems())},_renderActionSheet:function(t){if(this._hasVisibleMenuItems()){this._renderMenuButton({icon:"overflow"});var i=n.extend({target:this._$button,showTitle:!1},t);this._menu=n("<div>").appendTo(this._element()).dxActionSheet(i).dxActionSheet("instance"),this._renderMenuItems()}},_renderList:function(t){this._renderMenuButton({activeStateEnabled:!1,text:"..."});var i=n.extend({width:"100%"},t);this._renderListOverlay(),this._renderContainerSwipe(),this._hasVisibleMenuItems()&&(this._menu=n("<div>").appendTo(this._listOverlay.content()).dxList(i).dxList("instance"),this._renderMenuItems()),this._changeListVisible(this.option("visible")),this._windowResizeCallback=n.proxy(this._toggleMenuVisibility,this),r.windowResizeCallbacks.add(this._windowResizeCallback)},_renderMenuItems:function(){this._menu.addExternalTemplate(this._templates),this._menu.option("items",this._getMenuItems())},_getListHeight:function(){var n=this._listOverlay.content().find(".dx-list").height(),t=this._$toolbarItemsContainer.height()-this._element().height();return n+t},_renderListOverlay:function(){var t=this._element();this._listOverlay=n("<div>").appendTo(t).dxOverlay({targetContainer:!1,deferRendering:!1,shading:!1,height:"auto",width:"100%",showTitle:!1,closeOnOutsideClick:n.proxy(this._handleListOutsideClick,this),position:null,animation:null,backButtonHandler:null}).dxOverlay("instance")},_backButtonHandler:function(){this._toggleMenuVisibility(!1,!0)},_toggleBackButtonCallback:function(){this._closeCallback&&t.backButtonCallback.remove(this._closeCallback),this._menuShown&&(this._closeCallback=n.proxy(this._backButtonHandler,this),t.backButtonCallback.add(this._closeCallback))},_renderContainerSwipe:function(){this._$toolbarItemsContainer.appendTo(this._listOverlay.content()).dxSwipeable({elastic:!1,startAction:n.proxy(this._handleSwipeStart,this),updateAction:n.proxy(this._handleSwipeUpdate,this),endAction:n.proxy(this._handleSwipeEnd,this),itemSizeFunc:n.proxy(this._getListHeight,this),direction:"vertical"})},_handleListOutsideClick:function(t){n(t.target).closest(this._listOverlay.content()).length||this._toggleMenuVisibility(!1,!0)},_calculatePixelOffset:function(n){n=(n||0)-1;var t=this._getListHeight();return n*t},_handleSwipeStart:function(n){n.jQueryEvent.maxTopOffset=this._menuShown?0:1,n.jQueryEvent.maxBottomOffset=this._menuShown?1:0},_handleSwipeUpdate:function(n){var t=this._menuShown?n.jQueryEvent.offset:1+n.jQueryEvent.offset;this._renderMenuPosition(t,!1)},_handleSwipeEnd:function(n){var t=n.jQueryEvent.targetOffset;t-=this._menuShown-1,this._toggleMenuVisibility(t===0,!0)},_renderMenuPosition:function(n,t){var i=this._calculatePixelOffset(n),r=this._listOverlay.content();t?nt(r,i,this._menuShown):h.move(r,{top:i})},_handleMenuButtonClick:function(){this._toggleMenuVisibility(!this._menuShown,!0)},_toggleMenuVisibility:function(n,t){this._menuShown=n;switch(this._menuType){case"dxList":this._toggleBackButtonCallback(),this._renderMenuPosition(this._menuShown?0:1,t);break;case"dxActionSheet":this._menu.toggle(this._menuShown),this._menuShown=!1}},_renderEmptyMessage:n.noop,_clean:function(){this._$toolbarItemsContainer.children().empty(),this._element().empty()},_changeMenuOption:function(n,t){this._menu&&this._menu.option(n,t)},_changeListVisible:function(n){this._listOverlay&&(this._listOverlay.option("visible",n),this._toggleMenuVisibility(!1,!1))},_optionChanged:function(n,t){switch(n){case"renderAs":case"submenuType":this._invalidate(),this.callBase.apply(this,arguments);break;case"visible":this._changeListVisible(t),this.callBase.apply(this,arguments);break;case"menuItemRender":this._changeMenuOption("itemRender",t);break;case"menuItemTemplate":this._changeMenuOption("itemTemplate",t);break;case"itemClickAction":this._changeMenuOption(n,t),this.callBase.apply(this,arguments);break;default:this.callBase.apply(this,arguments)}},_dispose:function(){this._windowResizeCallback&&r.windowResizeCallbacks.remove(this._windowResizeCallback),this._windowTitleResizeCallback&&r.windowResizeCallbacks.remove(this._windowTitleResizeCallback),this.callBase()}}))}(jQuery,DevExpress),function(n,t){var y=t.ui,r=y.events,p=t.translator,o=t.fx,nt=t.utils,w=[],b=function(n){w.push(n)};b("delete"),b("selection");var tt="dx-list-item-bag-container",it="dx-list-item-content",rt="dx-list-item-left-bag",ut="dx-list-item-right-bag",ft="leftBag",et="rightBag",ot="modifyElement",st=t.Class.inherit({ctor:function(n,t){this._list=n,this._config=t,this.isModifyingByDecorators()&&this._fetchRequiredDecorators()},dispose:function(){this._decorators&&this._decorators.length&&n.each(this._decorators,function(n,t){t.dispose()})},isModifyingByDecorators:function(){return!(this.isRenderingByRenderer()||this.isRenderingByTemplate())},isRenderingByRenderer:function(){return!!this.getItemRenderer()},getItemRenderer:function(){return this._config.itemRender},isRenderingByTemplate:function(){return!!this.getItemTemplateName()},getItemTemplateName:function(){return this._config.itemTemplate},_fetchRequiredDecorators:function(){var t=this;this._decorators=[],n.each(w,function(n,i){var u=i+"Enabled",f=i+"Mode",r;t._config[u]&&(r=t._createDecorator(i,t._config[f]),t._decorators.push(r))})},_createDecorator:function(n,t){var i=this._findDecorator(n,t);return new i(this._list)},_findDecorator:function(n,t){return e[n][t]},modifyItemElement:function(){var t=[this._modifyItemElementImpl,this];t.push.apply(t,arguments),nt.executeAsync(n.proxy.apply(n,t))},_modifyItemElementImpl:function(t){var i=n(t.itemElement),r;i.addClass(tt),this._wrapContent(i),r={$itemElement:i},this._prependLeftBags(i,r),this._appendRightBags(i,r),this._applyDecorators(ot,r)},_wrapContent:function(t){var i=n("<div />").addClass(it);t.wrapInner(i)},_prependLeftBags:function(n,t){var i=this._collectDecoratorsMarkup(ft,t,rt);n.prepend(i)},_appendRightBags:function(n,t){var i=this._collectDecoratorsMarkup(et,t,ut);n.append(i)},_collectDecoratorsMarkup:function(t,i,r){var u=n("<div />");return n.each(this._decorators,function(){var f=n("<div />").addClass(r);this[t](n.extend(i,{$container:f})),f.children().length&&u.append(f)}),u.children()},_applyDecorators:function(t,i){n.each(this._decorators,function(){this[t](i)})},_handlerExists:function(n){var i,r,t;if(!this._decorators)return!1;for(i=this._decorators,r=i.length,t=0;t<r;t++)if(i[t][n])return!0;return!1},_handleEvent:function(n,t){var i;if(!this._decorators)return!1;var r=!1,u=this._decorators,f=u.length;for(i=0;i<f;i++)if(r=u[i][n](t),r)break;return r},handleClick:function(n){return this._handleEvent("handleClick",n)},holdHandlerExists:function(){return this._handlerExists("handleHold")},handleHold:function(n){return this._handleEvent("handleHold",n)}}),e={},f=function(t,i,r){var u={};u[t]=e[t]?e[t]:{},u[t][i]=r,e=n.extend(e,u)},u="dxListEditDecorator",s=t.Class.inherit({ctor:function(n){this._list=n,this._init()},_init:n.noop,dispose:n.noop,modifyElement:n.noop,leftBag:n.noop,rightBag:n.noop,handleClick:n.noop,handleHold:n.noop}),l="dx-switchable-delete-ready",ht="dx-switchable-delete-button-container",ct="dx-switchable-delete-button-wrapper",lt="dx-switchable-delete-button-inner-wrapper",at="dx-switchable-delete-button",k=s.inherit({handleClick:function(){var i=this,t=this._list._element().find("."+l);return n.each(t,function(t,r){i._cancelDelete(n(r))}),t.length!==0},_isReadyToDelete:function(n){return n.hasClass(l)},_toggleDeleteReady:function(n,t){n.toggleClass(l,t)},_cancelDelete:function(n){this._toggleDeleteReady(n,!1)}}),d=k.inherit({modifyElement:function(t){var o=this,r=t.$itemElement,i=n("<div />").addClass(ht),u=n("<div />").addClass(ct),f=n("<div />").addClass(lt),e=n("<div />").addClass(at);e.dxButton({text:Globalize.localize("dxListEditDecorator-delete"),type:"danger",clickAction:function(n){o._list.deleteItem(r),n.jQueryEvent.stopPropagation()}}),i.append(u),u.append(f),f.append(e),r.append(i),this._bottonContainerWidth||(this._bottonContainerWidth=i.outerWidth()),i.css("right",-this._bottonContainerWidth)}}),vt="dx-toggle-delete-switch-container",yt="dx-toggle-delete-switch";f("delete","toggle",d.inherit({leftBag:function(t){var r=this,u=t.$itemElement,i=t.$container,f=n("<div />").dxButton({icon:"toggle-delete",clickAction:function(n){r._toggleDeleteReady(u),n.jQueryEvent.stopPropagation()}}).addClass(yt);i.addClass(vt),i.append(f)}})),f("delete","slideButton",d.inherit({modifyElement:function(n){this.callBase.apply(this,arguments);var i=this,t=n.$itemElement;t.on(r.addNamespace("dxswipeend",u),function(n){n.targetOffset!==0&&i._toggleDeleteReady(t)})}}));var pt="dx-slide-item-wrapper",h="dx-slide-item-content",c="dx-slide-item-delete-button-container",a="dx-slide-item-delete-button",ni="dx-slide-item-delete-button-hidden",wt="dx-slide-item-delete-button-content";f("delete","slideItem",k.inherit({modifyElement:function(t){var e=this,i=t.$itemElement,o=n("<div/>").addClass(wt).text(Globalize.localize("dxListEditDecorator-delete")),f=n("<div/>").addClass(a).append(o),s=n("<div/>").addClass(c).append(f);i.wrapInner(n("<div/>").addClass(h)).append(s).addClass(pt);f.on(r.addNamespace("dxclick",u),function(){e._list.deleteItem(i)});i.on(r.addNamespace("dxswipestart",u),n.proxy(this._handleSwipeStart,this)).on(r.addNamespace("dxswipe",u),n.proxy(this._handleSwipe,this)).on(r.addNamespace("dxswipeend",u),n.proxy(this._handleSwipeEnd,this))},_handleSwipeStart:function(t){var i=n(t.currentTarget);this._cachedItemWidth=i.width(),this._cacheButtonWidth(i)},_cacheButtonWidth:function(n){this._cachedButtonWidth=this._cachedButtonWidth||n.find("."+a).outerWidth()},_minBottonContainerLeftOffset:function(){return this._cachedItemWidth-this._cachedButtonWidth},_handleSwipe:function(t){var i=n(t.currentTarget),o=i.find("."+h),r=i.find("."+c),s=r.find("."+a),u=this._cachedItemWidth*t.offset,f=this._isReadyToDelete(i)?-this._cachedButtonWidth:0,e=u+f<0?u+f:0;p.move(o,{left:e}),r.css("left",Math.max(this._cachedItemWidth+e,this._minBottonContainerLeftOffset()))},_handleSwipeEnd:function(t){var i=n(t.currentTarget),r=this._cachedItemWidth*t.offset,u=!this._isReadyToDelete(i)&&-r>this._cachedButtonWidth*.8,f=t.targetOffset===-1||u;this._toggleDeleteState(i,f)},_toggleDeleteState:function(n,t){t?this._prepareToDelete(n):this._cancelDelete(n)},_prepareToDelete:function(t){var i=o.animate(t.find("."+h),{to:{left:-this._cachedButtonWidth},type:"slide",duration:200}),r=o.animate(t.find("."+c),{to:{left:this._minBottonContainerLeftOffset()},duration:200});n.when(i,r).done(n.proxy(this._toggleDeleteReady,this,t,!0))},_cancelDelete:function(n){this.callBase.apply(this,arguments),o.animate(n.find("."+h),{to:{left:0},type:"slide",duration:200});var t=n.find("."+c);o.animate(t,{to:{left:this._cachedItemWidth},duration:200,complete:function(){t.css("left","100%")}})}})),f("delete","swipe",s.inherit({modifyElement:function(t){var i=t.$itemElement;i.on(r.addNamespace("dxswipe",u),n.proxy(this._handleSwipe,this)).on(r.addNamespace("dxswipeend",u),n.proxy(this._handleSwipeEnd,this))},_renderItemPosition:function(t,i,r){var u=n.Deferred(),e=t.width(),f=i*e;return r?o.animate(t,{to:{left:f},type:"slide",complete:function(){u.resolve(t,i)}}):(p.move(t,{left:f}),u.resolve()),u.promise()},_handleSwipe:function(t){this._renderItemPosition(n(t.currentTarget),t.offset)},_handleSwipeEnd:function(t){var i=this,r=n(t.currentTarget),u=t.targetOffset;this._renderItemPosition(r,u,!0).done(function(n,t){Math.abs(t)&&i._list.deleteItem(n)})}}));var g="dx-holddelete-menu",bt="dx-holddelete-menucontent",kt="dx-holddelete-menuitem";f("delete","hold",s.inherit({_init:function(){var t=n("<div/>").addClass(g);this._list._element().append(t),this._overlay=this._renderOverlay(t)},_renderOverlay:function(t){var i=this;return t.dxOverlay({shading:!1,closeOnOutsideClick:function(t){return!n(t.target).closest("."+g).length},animation:{show:{type:"custom",duration:300,from:{height:0,opacity:1},to:{height:function(){return i._$menu.height()},opacity:1}},hide:{type:"custom",duration:0,from:{opacity:1},to:{opacity:0}},position:{my:"top",at:"bottom",of:function(){return i._$itemWithMenu},collision:"flip"},height:"auto"},contentReadyAction:n.proxy(this._renderMenu,this),height:function(){return i._$itemWithMenu}}).dxOverlay("instance")},_renderMenu:function(t){var f=n("<div/>").addClass(bt),i=n("<div/>").addClass(kt).text(Globalize.localize("dxListEditDecorator-delete"));i.on(r.addNamespace("dxclick",u),n.proxy(this._deleteItem,this));this._$menu=f.append(i),t.component.content().append(this._$menu)},_deleteItem:function(){this._overlay.hide(),this._list.deleteItem(this._$itemWithMenu)},dispose:function(){this._overlay._element().remove()},handleHold:function(n){var t=this._overlay;return t.beginUpdate(),t.option("position",{my:"top",at:"bottom",of:n,collision:"flip"}),t.option("width",function(){return n.width()}),t.endUpdate(),t.show(),this._$itemWithMenu=n,!0}}));var dt="dx-list-item-selected",gt="dx-select-checkbox-container",v="dx-select-checkbox";f("selection","control",s.inherit({leftBag:function(t){var f=this,i=t.$itemElement,r=t.$container,u=n("<div />").addClass(v);u.dxCheckBox({checked:this._isSelected(i),clickAction:function(n){f._processCheckedState(i,n.component.option("checked")),n.jQueryEvent.stopPropagation()}}),r.addClass(gt),r.append(u)},modifyElement:function(n){var i=this,t=n.$itemElement,r=t.find("."+v).dxCheckBox("instance");t.on("stateChanged",function(){r.option("checked",i._isSelected(t))})},_isSelected:function(n){return n.hasClass(dt)},_processCheckedState:function(n,t){t?this._list.selectItem(n):this._list.unselectItem(n)}})),f("selection","item",e.selection.control.inherit({handleClick:function(n){var t=!n.find("."+v).dxCheckBox("instance").option("checked");return this._processCheckedState(n,t),!0}})),y.ListEditProvider=st}(jQuery,DevExpress),function(n,t,i){var u=t.ui,f=u.events,et="dxPreventItemClickAction",c=t.Class.inherit({ctor:function(n){this._list=n},isItemIndex:t.abstract,getItemElementIndex:t.abstract,normalizeItemIndex:t.abstract,deleteItemAtIndex:t.abstract,updateSelectionAfterDelete:t.abstract,fetchSelectedItems:t.abstract,selectedItemIndecies:t.abstract,getItemByIndex:t.abstract}),p=c.inherit({isItemIndex:function(t){return n.isNumeric(t)},getItemElementIndex:function(n){return this._list._itemElements().index(n)},normalizeItemIndex:function(n){return n},deleteItemAtIndex:function(n){this._list.option("items").splice(n,1)},updateSelectionAfterDelete:function(t){var i=this._list._selectedItemIndices;n.each(i,function(n,r){r>t&&(i[n]-=1)})},fetchSelectedItems:function(){var i=this._list.option("items"),t=[];return n.each(this._list._selectedItemIndices,function(n,r){t.push(i[r])}),t},selectedItemIndecies:function(){var t=[],i=this._list.option("items"),r=this._list.option("selectedItems");return n.each(r,function(r,u){var f=n.inArray(u,i);f!==-1&&t.push(f)}),t},getItemByIndex:function(n){return this._list._itemElements().eq(n)}}),l=20,w=2303,e=function(n){return(n.group<<l)+n.item},r=function(n){return{group:n>>l,item:n&w}},a=function(t,i){var u=t.items,r={key:t.key,items:[]};return n.each(i,function(n,t){r.items.push(u[t])}),r},b=function(n,t){for(var r=n.length,i=0;i<r;i++)if(n[i].key===t)return n[i]},k=c.inherit({_groupElements:function(){return this._list._itemContainer().find("."+s)},_groupItemElements:function(n){return n.find("."+o)},isItemIndex:function(t){return n.isNumeric(t.group)&&n.isNumeric(t.item)},getItemElementIndex:function(t){var i=n(t),r=i.closest("."+s);return e({group:this._groupElements().index(r),item:this._groupItemElements(r).index(i)})},normalizeItemIndex:function(n){return e(n)},deleteItemAtIndex:function(n){var t=r(n),i=this._list.option("items")[t.group].items;i.splice(t.item,1)},updateSelectionAfterDelete:function(t){var i=r(t),u=this._list._selectedItemIndices;n.each(u,function(n,t){var f=r(t);f.group===i.group&&f.item>i.item&&(u[n]-=1)})},fetchSelectedItems:function(){var f=this._list.option("items"),e=this._list._selectedItemIndices,u=[],i,t;return e.sort(function(n,t){return n-t}),i=0,t=[],n.each(e,function(n,e){var o=r(e);o.group!==i&&t.length&&(u.push(a(f[i],t)),t.length=0),i=o.group,t.push(o.item)}),t.length&&u.push(a(f[i],t)),u},selectedItemIndecies:function(){var t=[],i=this._list.option("items"),r=this._list.option("selectedItems");return n.each(r,function(r,u){var f=b(i,u.key),o=n.inArray(f,i);n.each(u.items,function(i,r){var u=n.inArray(r,f.items);u!==-1&&t.push(e({group:o,item:u}))})}),t},getItemByIndex:function(n){var t=r(n),i=this._groupElements().eq(t.group);return this._groupItemElements(i).eq(t.item)}}),v=function(t,i){var r=[];return n.each(t,function(t,u){var f=n.inArray(u,i);f===-1&&r.push(u)}),r},d="dx-list",o="dx-list-item",g="."+o,s="dx-list-group",nt="dx-list-group-header",tt="dx-has-next",it="dx-list-next-button",rt="dx-list-editing",h="dx-list-item-selected",y="dx-list-item-response-wait",ut="dxListItemData",ft=70;u.registerComponent("dxList",u.CollectionContainerWidget.inherit({_activeStateUnit:g,_defaultOptions:function(){return n.extend(this.callBase(),{pullRefreshEnabled:!1,autoPagingEnabled:!0,scrollingEnabled:!0,showScrollbar:!0,useNativeScrolling:!0,pullingDownText:Globalize.localize("dxList-pullingDownText"),pulledDownText:Globalize.localize("dxList-pulledDownText"),refreshingText:Globalize.localize("dxList-refreshingText"),pageLoadingText:Globalize.localize("dxList-pageLoadingText"),scrollAction:null,pullRefreshAction:null,pageLoadingAction:null,showNextButton:!1,itemHoldAction:null,itemHoldTimeout:750,itemSwipeAction:null,grouped:!1,groupTemplate:"group",groupRender:null,editEnabled:!1,editConfig:{itemTemplate:null,itemRender:null,deleteEnabled:!1,deleteMode:"toggle",selectionEnabled:!1,selectionMode:"item"},itemDeleteAction:null,selectedItems:[],itemSelectAction:null,itemUnselectAction:null})},_itemClass:function(){return o},_itemDataKey:function(){return ut},_itemContainer:function(){return this._$container},_allowDinamicItemsAppend:function(){return!0},_init:function(){this.callBase(),this._$container=this._element(),this._initScrollView(),this._initEditProvider(),this._initEditStrategy(this.option("grouped")),this._initSelectedItems(),this._feedbackShowTimeout=ft},_initSelectedItems:function(){this._selectedItemIndices=this._editStrategy.selectedItemIndecies()},_clearSelectedItems:function(){this._selectedItemIndices=[],this._updateSelectedItems()},_dataSourceOptions:function(){return n.extend(this.callBase(),{paginate:!0})},_initScrollView:function(){var t=this.option("scrollingEnabled"),r=t&&this.option("pullRefreshEnabled"),i=t&&this.option("autoPagingEnabled")&&!!this._dataSource,u=this._element().dxScrollView({disabled:this.option("disabled")||!t,scrollAction:n.proxy(this._handleScroll,this),pullDownAction:r?n.proxy(this._handlePullDown,this):null,reachBottomAction:i?n.proxy(this._handleScrollBottom,this):null,showScrollbar:this.option("showScrollbar"),useNative:this.option("useNativeScrolling"),pullingDownText:this.option("pullingDownText"),pulledDownText:this.option("pulledDownText"),refreshingText:this.option("refreshingText"),reachBottomText:this.option("pageLoadingText")});this._scrollView=u.dxScrollView("instance"),this._scrollView.toggleLoading(i),this._$container=this._scrollView.content(),this._createScrollViewActions()},_createScrollViewActions:function(){this._scrollAction=this._createActionByOption("scrollAction",{excludeValidators:["gesture"]}),this._pullRefreshAction=this._createActionByOption("pullRefreshAction",{excludeValidators:["gesture"]}),this._pageLoadingAction=this._createActionByOption("pageLoadingAction",{excludeValidators:["gesture"]})},_handleScroll:function(n){this._scrollAction(n)},_afterItemsRendered:function(n){var r=this._isLastPage(),t=!n||r,u=this.option("autoPagingEnabled"),i=!u||t,f=this._scrollViewIsFull();i||f?(this._scrollView.release(i),this._shouldRenderNextButton()&&this._dataSource.isLoaded()&&this._toggleNextButton(!t)):this._infiniteDataLoading()},_isLastPage:function(){return!this._dataSource||this._dataSource.isLastPage()},_scrollViewIsFull:function(){return!this._scrollView||this._scrollView.isFull()},_handlePullDown:function(n){this._pullRefreshAction(n),this._dataSource&&!this._dataSource.isLoading()?(this._dataSource.pageIndex(0),this._dataSource.load()):this._afterItemsRendered()},_infiniteDataLoading:function(){var n=this._dataSource;this._scrollViewIsFull()||!n||n.isLoading()||this._isLastPage()||t.utils.executeAsync(this._loadNextPage,this)},_handleScrollBottom:function(n){this._pageLoadingAction(n);var t=this._dataSource;t&&!t.isLoading()?this._loadNextPage():this._afterItemsRendered()},_loadNextPage:function(){var n=this._dataSource;return this._expectNextPageLoading(),n.pageIndex(1+n.pageIndex()),n.load()},_renderItems:function(t){this.option("grouped")?(n.each(t,n.proxy(this._renderGroup,this)),this._renderEmptyMessage()):this.callBase.apply(this,arguments),this._afterItemsRendered(!0)},_handleDataSourceLoadError:function(){this.callBase.apply(this,arguments),this._initialized&&this._afterItemsRendered()},_initEditProvider:function(){this._editProvider&&this._editProvider.dispose(),this._editProvider=new u.ListEditProvider(this,this.option("editConfig"))},_initEditStrategy:function(n){var t=n?k:p;this._editStrategy=new t(this)},_render:function(){this._element().addClass(d),this._renderEditing(),this.callBase(),this._attachHoldEvent(),this._attachSwipeEvent()},_attachClickEvent:function(){var r=this,t=f.addNamespace("dxclick",this.NAME),i=this._itemSelector();this._itemContainer().off(t,i).on(t,i,n.proxy(this._handleItemClick,this))},_attachHoldEvent:function(){var t=this._element(),i=f.addNamespace("dxhold",this.NAME),r=this._itemSelector();if(t.off(i,r),this.option("itemHoldAction")||this._editProvider.holdHandlerExists())t.on(i,r,{timeout:this.option("itemHoldTimeout")},n.proxy(this._handleItemHold,this))},_attachSwipeEvent:function(){var t=this._element(),i=f.addNamespace("dxswipeend",this.NAME),r=this._itemSelector();if(t.off(i,r),this.option("itemSwipeAction"))t.on(i,r,n.proxy(this._handleItemSwipe,this))},_renderEditing:function(){this._element().toggleClass(rt,this.option("editEnabled"))},_shouldRenderNextButton:function(){return this.option("showNextButton")&&this._dataSource},_getNextButton:function(){return this._nextButton||(this._nextButton=this._createNextButton()),this._nextButton},_createNextButton:function(){var t=n("<div/>").addClass(it),i=n("<div/>").dxButton({text:"More",clickAction:n.proxy(this._handleNextButton,this)});return t.append(i)},_handleItemClick:function(n){this.option("editEnabled")&&this._editProvider.handleClick(this._closestItemElement(n.target))||this.callBase.apply(this,arguments)},_handleItemHold:function(n){this.option("editEnabled")&&this._editProvider.handleHold(this._closestItemElement(n.target))||this._handleItemJQueryEvent(n,"itemHoldAction")},_handleItemSwipe:function(n){this._handleItemJQueryEvent(n,"itemSwipeAction",{direction:n.offset<0?"left":"right"},{excludeValidators:["gesture"]})},_getItemRenderer:function(){return this.option("editEnabled")&&this._editProvider.isRenderingByRenderer()?this._editProvider.getItemRenderer():this.callBase()},_getItemTemplateName:function(){return this.option("editEnabled")&&this._editProvider.isRenderingByTemplate()?this._editProvider.getItemTemplateName():this.callBase()},_postprocessRenderItem:function(t){var i=n(t.itemElement);this.option("editEnabled")&&(this._isItemSelected(this._getItemIndex(i))&&i.addClass(h),this._editProvider.isModifyingByDecorators()&&this._editProvider.modifyItemElement(t))},_handleNextButton:function(){var n=this._dataSource;n&&!n.isLoading()&&(this._scrollView.toggleLoading(!0),this._expectNextPageLoading(),n.pageIndex(1+n.pageIndex()),n.load(),this._nextButton.detach())},_groupRenderDefault:function(n){return String(n.key||n)},_renderGroup:function(t,i){var r=this,e=n("<div />").addClass(s).appendTo(r._itemContainer()),o=r.option("groupRender"),c=r.option("groupTemplate"),h=r._getTemplate(i.template||c,t,i),u,f={index:t,group:i,container:e};u=o?r._createGroupByRenderer(o,f):h?r._createGroupByTemplate(h,f):r._createGroupByRenderer(r._groupRenderDefault,f),u.addClass(nt),this._renderingGroupIndex=t,n.each(i.items||[],function(n,t){r._renderItem(n,t,e)})},_createGroupByRenderer:function(t,i){var r=n("<div />").appendTo(i.container),u=t(i.group,i.index,r);return u&&r[0]!==u[0]&&r.append(u),r},_createGroupByTemplate:function(n,t){return n.render(t.container,t.group)},_clean:function(){this._toggleNextButton(!1),this.callBase.apply(this,arguments)},_dispose:function(){clearTimeout(this._holdTimer),this.callBase()},_toggleNextButton:function(n){var t=this._dataSource,i=this._getNextButton();this._element().toggleClass(tt,n),n&&t&&t.isLoaded()&&i.appendTo(this._itemContainer()),n||i.detach()},_optionChanged:function(n,t){switch(n){case"showNextButton":this._toggleNextButton(t);break;case"itemHoldAction":case"itemHoldTimeout":this._attachHoldEvent();break;case"dataSource":this.callBase.apply(this,arguments),this._initScrollView();break;case"showScrollbar":case"scrollingEnabled":case"pullRefreshEnabled":case"autoPagingEnabled":this._initScrollView();break;case"selectedItems":this._selectedItemsInternalChange||this._refreshSelectedItems();break;case"itemSwipeAction":this._attachSwipeEvent();break;case"scrollAction":case"pullRefresAction":case"pageLoadingAction":this._createScrollViewActions(),this._invalidate();break;case"grouped":this._clearSelectedItems(),delete this._renderingGroupIndex,this._initEditStrategy(t),this._invalidate();break;case"items":case"editEnabled":this._clearSelectedItems(),this._invalidate();break;case"editConfig":this._initEditProvider(),this._invalidate();break;default:this.callBase.apply(this,arguments)}},_getItemIndex:function(n){return this._editStrategy.isItemIndex(n)?this._editStrategy.normalizeItemIndex(n):this._editStrategy.getItemElementIndex(n)},_getItemElement:function(t){return this._editStrategy.isItemIndex(t)?this._editStrategy.getItemByIndex(this._editStrategy.normalizeItemIndex(t)):n(t)},_isItemSelected:function(t){return n.inArray(t,this._selectedItemIndices)>-1},_updateSelectedItems:function(){this._selectedItemsInternalChange=!0,this.option("selectedItems",this._editStrategy.fetchSelectedItems()),this._selectedItemsInternalChange=!1},_updateSelectionAfterDelete:function(t){var r=this,i=n.inArray(t,this._selectedItemIndices);i>-1&&this._selectedItemIndices.splice(i,1),this._editStrategy.updateSelectionAfterDelete(t),this._updateSelectedItems()},_selectItem:function(n){var t=this._getItemIndex(n);this.option("editEnabled")&&t>-1&&(n.addClass(h),this._selectedItemIndices.push(t),n.trigger("stateChanged"),this._updateSelectedItems(),this._handleItemEvent(n,"itemSelectAction"))},_unselectItem:function(t){var i=n.inArray(this._getItemIndex(t),this._selectedItemIndices);this.option("editEnabled")&&i>-1&&(t.removeClass(h),this._selectedItemIndices.splice(i,1),t.trigger("stateChanged"),this._updateSelectedItems(),this._handleItemEvent(t,"itemUnselectAction"))},_refreshSelectedItems:function(){var t=this,i=this._editStrategy.selectedItemIndecies(),u=v(this._selectedItemIndices,i),r;n.each(u,function(n,i){var r=t._editStrategy.getItemByIndex(i);t._unselectItem(r)}),r=v(i,this._selectedItemIndices),n.each(r,function(n,i){var r=t._editStrategy.getItemByIndex(i);t._selectItem(r)})},_deleteItemFromDS:function(t){var u=this,r=n.Deferred(),e=this.option("disabled"),f=this._dataSource.store();if(this.option("disabled",!0),!f.remove)throw new Error("You have to implement 'remove' method in dataStore used by dxList to be able to delete items");return f.remove(f.keyOf(this._getItemData(t))).done(function(n){n!==i?r.resolveWith(u):r.rejectWith(u)}).fail(function(){r.rejectWith(u)}),r.always(function(){u.option("disabled",e)}),r},_refreshLastPage:function(){return this._expectLastItemLoading(),this._dataSource.load()},deleteItem:function(t){var i=this,r=n.Deferred(),u=this._getItemElement(t),o=this._getItemIndex(t),f,e;return(this.option("editEnabled")&&o>-1?(u.addClass(y),this._dataSource?(f="dataSource",r=this._deleteItemFromDS(u)):(f="items",r.resolveWith(this))):r.rejectWith(this),r.done(function(){u.detach(),i._editStrategy.deleteItemAtIndex(o),i.optionChanged.fireWith(i,[f,i.option(f)]),i._updateSelectionAfterDelete(o),i._handleItemEvent(u,"itemDeleteAction",{},{excludeValidators:["gesture"]}),i._renderEmptyMessage()}).fail(function(){u.removeClass(y)}),this._isLastPage()||this.option("grouped"))?r.promise():(e=n.Deferred(),r.done(function(){i._refreshLastPage().done(function(){e.resolveWith(i)})}),r.fail(function(){e.rejectWith(i)}),e.promise())},isItemSelected:function(n){return this._isItemSelected(this._getItemIndex(n))},selectItem:function(n){this._selectItem(this._getItemElement(n))},unselectItem:function(n){this._unselectItem(this._getItemElement(n))},update:function(){var t=this,i=n.Deferred();return t._scrollView?t._scrollView.update().done(function(){i.resolveWith(t)}):i.resolveWith(t),i.promise()},scrollTop:function(){return this._scrollView.scrollOffset().top},clientHeight:function(){return this._scrollView.clientHeight()},scrollHeight:function(){return this._scrollView.scrollHeight()},scrollBy:function(n){this._scrollView.scrollBy(n)},scrollTo:function(n){this._scrollView.scrollTo(n)}}))}(jQuery,DevExpress),function(n,t){var r=t.ui,u=t.utils,e="dx-tileview",o="dx-tiles-wrapper",f="dx-tile",s="."+f,h="dxTileData";r.registerComponent("dxTileView",r.CollectionContainerWidget.inherit({_activeStateUnit:s,_defaultOptions:function(){return n.extend(this.callBase(),{items:null,showScrollbar:!1,listHeight:500,baseItemWidth:100,baseItemHeight:100,itemMargin:20})},_itemClass:function(){return f},_itemDataKey:function(){return h},_itemContainer:function(){return this._$wrapper},_init:function(){var n=this;n.callBase(),n._refreshHandler=function(){n._renderGeometry()},u.windowResizeCallbacks.add(n._refreshHandler)},_dispose:function(){this.callBase(),u.windowResizeCallbacks.remove(this._refreshHandler)},_render:function(){this.cellsPerColumn=1,this._element().addClass(e),this._renderListHeight(),this._$wrapper||this._renderWrapper(),this._initScrollable(),this.callBase(),this._renderGeometry(),this._fireContentReadyAction()},_renderListHeight:function(){this._element().height(this.option("listHeight"))},_renderContent:function(){this._renderContentImpl()},_renderWrapper:function(){this._$wrapper=n("<div />").addClass(o).appendTo(this._element())},_initScrollable:function(){this._scrollView=this._element().dxScrollable({direction:"horizontal",showScrollbar:this.option("showScrollbar"),disabled:this.option("disabled")}).data("dxScrollable")},_renderGeometry:function(){var t=this.option("items")||[],i=Math.max.apply(Math,n.map(t||[],function(n){return Math.round(n.heightRatio||1)}));this.cellsPerColumn=Math.floor(this._element().height()/(this.option("baseItemHeight")+this.option("itemMargin"))),this.cellsPerColumn=Math.max(this.cellsPerColumn,i),this.cells=[],this.cells.push(new Array(this.cellsPerColumn)),this._arrangeItems(t),this._$wrapper.width(this.cells.length*this.option("baseItemWidth")+(this.cells.length+1)*this.option("itemMargin"))},_arrangeItems:function(t){var i=this;n.each(t,function(n,t){var r={},f,u;r.widthRatio=t.widthRatio||1,r.heightRatio=t.heightRatio||1,r.text=t.text||"",r.widthRatio=r.widthRatio<=0?0:Math.round(r.widthRatio),r.heightRatio=r.heightRatio<=0?0:Math.round(r.heightRatio),f=i._itemElements().eq(n),u=i._getItemPosition(r),u.x===-1&&(u.x=i.cells.push(new Array(this.cellsPerColumn))-1),i._occupyCells(r,u),i._arrangeItem(f,r,u)})},_getItemPosition:function(n){for(var r={x:-1,y:0},i,t=0;t<this.cells.length;t++){for(i=0;i<this.cellsPerColumn;i++)if(this._itemFit(t,i,n)){r.x=t,r.y=i;break}if(r.x>-1)break}return r},_itemFit:function(n,t,i){var f=!0,r,u;if(t+i.heightRatio>this.cellsPerColumn)return!1;for(r=n;r<n+i.widthRatio;r++)for(u=t;u<t+i.heightRatio;u++)if(this.cells.length-1<r)this.cells.push(new Array(this.cellsPerColumn));else if(this.cells[r][u]){f=!1;break}return f},_occupyCells:function(n,t){for(var r,i=t.x;i<t.x+n.widthRatio;i++)for(r=t.y;r<t.y+n.heightRatio;r++)this.cells[i][r]=!0},_arrangeItem:function(n,t,i){var u=this.option("baseItemHeight"),f=this.option("baseItemWidth"),r=this.option("itemMargin");n.css({height:t.heightRatio*u+(t.heightRatio-1)*r,width:t.widthRatio*f+(t.widthRatio-1)*r,top:i.y*u+(i.y+1)*r,left:i.x*f+(i.x+1)*r,display:t.widthRatio<=0||t.heightRatio<=0?"none":""})},_optionChanged:function(n,t){switch(n){case"showScrollbar":this._initScrollable();break;case"disabled":this._scrollView.option("disabled",t);break;case"baseItemWidth":case"baseItemHeight":case"itemMargin":this._renderGeometry();break;case"listHeight":this._renderListHeight();break;default:this.callBase.apply(this,arguments)}}}))}(jQuery,DevExpress),function(n,t){var r=t.ui,c=t.utils,f=r.events,s=t.fx,l=t.translator,u="dx-gallery",a="dx-gallery-loop",b=u+"-wrapper",e=u+"-item",o=e+"-loop",k="."+e,v=e+"-selected",y=u+"-indicator",h=y+"-item",p="."+h,w=h+"-selected",d="dxGalleryItemData";r.registerComponent("dxGalleryNavButton",r.Widget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{direction:"next"})},_render:function(){this.callBase(),this._element().addClass(u+"-nav-button-"+this.option("direction"))}})),r.registerComponent("dxGallery",r.CollectionContainerWidget.inherit({_activeStateUnit:k,_defaultOptions:function(){return n.extend(this.callBase(),{animationDuration:400,loop:!1,swipeEnabled:!0,indicatorEnabled:!0,showIndicator:!0,selectedIndex:0,slideshowDelay:0,showNavButtons:!1})},_dataSourceOptions:function(){return{paginate:!1}},_itemContainer:function(){return this._$container},_itemClass:function(){return e},_itemDataKey:function(){return d},_itemWidth:function(){return this._itemElements().first().outerWidth()},_itemsCount:function(){return(this.option("items")||[]).length},_itemRenderDefault:function(t,i,r){this.callBase(t,i,r),n.isPlainObject(t)||r.append(n("<img />").attr("src",String(t)))},_render:function(){this._element().addClass(u),this._element().toggleClass(a,this.option("loop")),this._renderDragHandler(),this._renderItemContainer(),this.callBase(),this._renderContainerPosition(),this._renderItemPositions(),this._renderIndicator(),this._renderSelectedIndicatorItem(),this._renderUserInteraction(),this._renderNavButtons(),this._setupSlideShow(),this._reviseDimensions(),this._windowResizeCallback=n.proxy(this._handleResize,this),c.windowResizeCallbacks.add(this._windowResizeCallback)},_renderDragHandler:function(){var n=f.addNamespace("dragstart",this.NAME);this._element().off(n).on(n,"img",function(){return!1})},_renderItems:function(n){this.callBase(n),this._renderDuplicateItems()},_renderItemContainer:function(){this._$container||(this._$container=n("<div />").addClass(b).appendTo(this._element()))},_renderDuplicateItems:function(){var t=this.option("items")||[],i=t.length,r,u,n;if(i){for(this._element().find("."+o).remove(),r=this._element().width()/this._itemWidth(),u=Math.min(r,i),n=0;n<u;n++)this._renderItem(0,t[n]).addClass(o);this._renderItem(0,t[this._itemsCount()-1]).addClass(o)}},_handleResize:function(){this._renderDuplicateItems(),this._renderItemPositions(),this._renderContainerPosition()},_renderItemPositions:function(){var t=this._itemWidth(),i=this._element().find("."+o).length,r=this._itemsCount()+i-1;this._itemElements().each(function(i){var u=i;i===r&&(u=-1),l.move(n(this),{left:u*t})})},_renderContainerPosition:function(t,i){t=t||0;var o=this,r=this._itemWidth(),h=this.option("selectedIndex"),c=this.option("animationDuration"),u=t-h,f=n.Deferred(),e=[];return i?e.push(s.animate(this._$container,{type:"slide",to:{left:u*r},duration:c})):l.move(this._$container,{left:u*r}),n.when.apply(n,e).done(function(){f.resolveWith(o)}),f.promise()},_reviseDimensions:function(){var n=this,t=n._itemElements().first();t&&(n.option("height")||n.option("height",t.outerHeight()),n.option("width")||n.option("width",t.outerWidth()))},_renderIndicator:function(){if(!this.option("showIndicator")){this._cleanIndicators();return}var t=this._$indicator=n("<div />").addClass(y).appendTo(this._element());n.each(this.option("items")||[],function(){n("<div />").addClass(h).appendTo(t)})},_cleanIndicators:function(){this._$indicator&&this._$indicator.remove()},_renderSelectedIndicatorItem:function(){var n=this.option("selectedIndex");this._itemElements().removeClass(v).eq(n).addClass(v),this._element().find(p).removeClass(w).eq(n).addClass(w)},_renderUserInteraction:function(){var t=this,i=t._element(),r=t.option("swipeEnabled")&&this._itemsCount()>1,e=r?"pointer":"default",u;i.dxSwipeable({startAction:r?n.proxy(t._handleSwipeStart,t):function(n){n.jQueryEvent.cancel=!0},disabled:this.option("disabled"),updateAction:n.proxy(t._handleSwipeUpdate,t),endAction:n.proxy(t._handleSwipeEnd,t),itemWidthFunc:n.proxy(t._itemWidth,t)}),u=this._createAction(this._handleIndicatorSelect);i.find(p).css({cursor:e}).off(f.addNamespace("dxclick",this.NAME)).on(f.addNamespace("dxclick",this.NAME),function(n){u({jQueryEvent:n})})},_handleIndicatorSelect:function(t){var u=t.jQueryEvent,i=t.component,r;f.needSkipEvent(u)||i.option("indicatorEnabled")&&(r=n(u.target).index(),i._renderContainerPosition(i.option("selectedIndex")-r,!0).done(function(){this._suppressRenderItemPositions=!0,i.option("selectedIndex",r)}))},_renderNavButtons:function(){var t=this;if(!t.option("showNavButtons")){t._cleanNavButtons();return}t._prevNavButton=n("<div />").dxGalleryNavButton({direction:"prev",clickAction:function(){t.prevItem(!0)}}).appendTo(this._element()),t._nextNavButton=n("<div />").dxGalleryNavButton({direction:"next",clickAction:function(){t.nextItem(!0)}}).appendTo(this._element()),this._renderNavButtonsVisibility()},_cleanNavButtons:function(){this._prevNavButton&&this._prevNavButton.remove(),this._prevNavButton&&this._nextNavButton.remove()},_renderNavButtonsVisibility:function(){if(this.option("showNavButtons")){var n=this.option("selectedIndex"),t=this.option("loop"),i=this._itemsCount();(n<i&&n>0||t)&&(this._prevNavButton.show(),this._nextNavButton.show()),this._itemsCount()<2&&(this._prevNavButton.hide(),this._nextNavButton.hide()),t||(n<1&&this._prevNavButton.hide(),n===i-1&&this._nextNavButton.hide())}},_setupSlideShow:function(){var n=this,t=n.option("slideshowDelay");t&&(clearTimeout(n._slideshowTimer),n._slideshowTimer=setTimeout(function(){if(n._userInteraction){n._setupSlideShow();return}n.nextItem(!0).done(n._setupSlideShow)},t))},_handleSwipeStart:function(n){var i=this._itemsCount(),t;if(!i){n.jQueryEvent.cancel=!0;return}this._stopItemAnimations(),this._userInteraction=!0,this.option("loop")||(t=this.option("selectedIndex"),n.jQueryEvent.maxLeftOffset=i-t-1,n.jQueryEvent.maxRightOffset=t)},_stopItemAnimations:function(){s.animating(this._$container)&&s.stop(this._$container,!0)},_handleSwipeUpdate:function(n){this._renderContainerPosition(n.jQueryEvent.offset)},_handleSwipeEnd:function(n){this._renderContainerPosition(n.jQueryEvent.targetOffset,!0).done(function(){var t=this.option("selectedIndex"),i=this._fitIndex(t-n.jQueryEvent.targetOffset);this._suppressRenderItemPositions=!0,this.option("selectedIndex",i),this._renderContainerPosition(),this._userInteraction=!1,this._setupSlideShow()})},_flipIndex:function(n){if(!this.option("loop"))return n;var t=this._itemsCount();return n=n%t,n>(t+1)/2&&(n-=t),n<-(t-1)/2&&(n+=t),n},_fitIndex:function(n){if(!this.option("loop"))return n;var t=this._itemsCount();return n=n%t,n<0&&(n+=t),n},_clean:function(){this.callBase(),this._cleanIndicators(),this._cleanNavButtons()},_dispose:function(){c.windowResizeCallbacks.remove(this._windowResizeCallback),clearTimeout(this._slideshowTimer),this.callBase()},_handleSelectedIndexChanged:function(){this._suppressRenderItemPositions||this._renderContainerPosition(),this._suppressRenderItemPositions=!1,this._renderSelectedIndicatorItem(),this._renderNavButtonsVisibility()},_optionChanged:function(n,t,i){switch(n){case"width":this.callBase(n,t,i),this._handleResize();break;case"animationDuration":this._renderNavButtonsVisibility();break;case"loop":this._element().toggleClass(a,t),this._renderNavButtonsVisibility();return;case"selectedIndex":this._handleSelectedIndexChanged();return;case"showIndicator":this._renderIndicator();return;case"showNavButtons":this._renderNavButtons();return;case"slideshowDelay":this._setupSlideShow();return;case"swipeEnabled":case"indicatorEnabled":this._renderUserInteraction();return;default:this.callBase(n,t,i)}},goToItem:function(t,i){var r=new n.Deferred,u=this.option("selectedIndex"),f=this._itemsCount();return(t=this._fitIndex(t),t>f-1||t<0)?r.resolveWith(this).promise():(this._renderContainerPosition(u-t,i).done(function(){this._suppressRenderItemPositions=!0,this.option("selectedIndex",t),r.resolveWith(this)}),r.promise())},prevItem:function(n){return this.goToItem(this.option("selectedIndex")-1,n)},nextItem:function(n){return this.goToItem(this.option("selectedIndex")+1,n)}}))}(jQuery,DevExpress),function(n,t,i){var f=t.ui,o=t.utils,u=f.events,r="dx-overlay",h=r+"-wrapper",c=r+"-content",e=r+"-shader",l=r+"-modal",a=500,s=["showingAction","shownAction","hidingAction","hiddenAction","positioningAction","positionedAction"],v=1e3,y="dx-state-disabled";f.registerComponent("dxOverlay",f.ContainerWidget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{activeStateEnabled:!1,visible:!1,shading:!0,closeOnOutsideClick:!1,closeOnTargetScroll:!1,position:{my:"center",at:"center",of:window},animation:{show:{type:"pop",duration:400},hide:{type:"pop",duration:400,to:{opacity:0,scale:0},from:{opacity:1,scale:1}}},showingAction:null,shownAction:null,hidingAction:null,hiddenAction:null,width:function(){return n(window).width()*.8},height:function(){return n(window).height()*.8},deferRendering:!0,disabled:!1,targetContainer:i,positioningAction:null,positionedAction:null})},_optionsByReference:function(){return n.extend(this.callBase(),{animation:!0})},_wrapper:function(){return this._$wrapper},_clickEventContainer:function(){return this._$container},_init:function(){this.callBase(),this._actions={},this._deferredAnimate=i,this._attachCloseOnOutsideClickHandler(),this._windowResizeCallback=n.proxy(this._repaint,this),o.windowResizeCallbacks.add(this._windowResizeCallback),this._$wrapper=n("<div>").addClass(h)},_initOptions:function(n){this._setTargetContainer(n.targetContainer),this._backButtonHandler=n.backButtonHandler!==i?this.backButtonHandler:this._defaultBackButtonHandler,this.callBase(n)},_setTargetContainer:function(r){r=r===i?t.overlayTargetContainer():r;var f=this._element(),u=f.closest(r);u.length||(u=n(r).first()),this._$targetContainer=u.length?u:f.parent()},_closeOnOutsideClickHandler:function(t){var i=this.option("closeOnOutsideClick"),u=this.option("visible");if(n.isFunction(i)&&(i=i(t)),i&&u){var r=this._$container,f=!r.is(t.target)&&!n.contains(r.get(0),t.target),e=Math.abs(t.timeStamp-this._showTimestamp)<a;f&&!e&&this.hide()}},_attachCloseOnOutsideClickHandler:function(){var t=this,i=u.addNamespace("dxpointerdown",t.NAME);this._myCloseOnOutsideClickHandler=function(){return t._closeOnOutsideClickHandler.apply(t,arguments)};n(document).on(i,this._myCloseOnOutsideClickHandler)},_detachCloseOnOutsideClickHandler:function(){var t=u.addNamespace("dxpointerdown",this.NAME);n(document).off(t,this._myCloseOnOutsideClickHandler)},_render:function(){var t=this._element(),i=this.option("deferRendering");this._$container=n("<div>").addClass(c),this._$wrapper.addClass(t.attr("class")),this._renderActions(),this.callBase(),this._renderStyles(),t.addClass(r)},_renderStyles:function(){this._renderShader(),this._renderModalState(),this._renderDimensions(),this._renderVisibility()},_renderShader:function(){this._$wrapper.toggleClass(e,this.option("shading"))},_renderModalState:function(){this._$wrapper.toggleClass(l,this.option("shading")&&!this.option("targetContainer"))},_renderDimensions:function(){this._$container.width(this.option("width")).height(this.option("height"))},_renderVisibility:function(){var n=this.option("visible");t.fx.stop(this._$container,!0),n&&(this._renderContent(),this._renderPosition()),this._toggleVisibility(n)},_renderActions:function(){var t=this;n.each(s,function(n,i){t._actions[i]=t._createActionByOption(i)})},_renderContent:function(){this._contentAlreadyRendered||!this.option("visible")&&this.option("deferRendering")||(this._contentAlreadyRendered=!0,this._moveFromTargetContainer(),this.callBase())},_moveFromTargetContainer:function(){this._$container.appendTo(this._element()),this._detachWrapperToTargetContainer()},_detachWrapperToTargetContainer:function(){this._$wrapper.detach()},_renderContentImpl:function(n){this._renderInnerContent(n),this._moveToTargetContainer()},_renderInnerContent:function(n){var t=this._element();this._$container.append(t.contents()).appendTo(t),(n||this._templates.template).render(this.content())},_moveToTargetContainer:function(){this._attachWrapperToTargetContainer(),this._$container.appendTo(this._$wrapper)},_attachWrapperToTargetContainer:function(){var n=this._element();!this._$targetContainer||this._$targetContainer[0]===n.parent()[0]?this._$wrapper.appendTo(n):this._$wrapper.appendTo(this._$targetContainer)},_renderPosition:function(){var f=this.option("position"),r,i,u,e;this.option("shading")&&(r=this._$wrapper.show(),i=n(f.of),t.position(r,{my:"top left",at:"top left",of:i}),r.css({width:i.outerWidth(),height:i.outerHeight()})),this._$container.css("transform","none"),u=t.calculatePosition(this._$container,f),this._actions.positioningAction({position:u}),e=t.position(this._$container,u),this._actions.positionedAction({position:e})},_subscribeParentScroll:function(){var i=this,r=this.option("closeOnTargetScroll"),t=this.option("position");if(r&&t&&t.of)n(t.of).parents().on(u.addNamespace("scroll",i.NAME),function(n){n.overlayProcessed||(n.overlayProcessed=!0,i.hide())})},_unsubscribeParentScroll:function(){var i=this,r=this.option("closeOnTargetScroll"),t=this.option("position");r&&t&&t.of&&n(t.of).parents().off(u.addNamespace("scroll",i.NAME))},_clean:function(){delete this._contentAlreadyRendered},_refresh:function(){this._renderStyles()},_repaint:function(){this.option("visible")&&(this._renderDimensions(),this._renderPosition())},_dispose:function(){t.fx.stop(this._$container),o.windowResizeCallbacks.remove(this._windowResizeCallback),this.closeCallback&&t.backButtonCallback.remove(this.closeCallback),this._detachCloseOnOutsideClickHandler(),this._actions=null,this.callBase(),this._$wrapper.remove(),this._$container.remove()},_renderVisibilityAnimate:function(){var i=this.option("visible");i&&(this._showTimestamp=n.now()),t.fx.stop(this._$container,!0),i?this._makeVisible():this._makeHidden()},_makeVisible:function(){var t=this,i=t.option("animation")||{},r;this._$wrapper.css("z-index",++v),this._actions.showingAction(),this._toggleVisibility(!0),this._renderContent(),this._renderPosition(),i.show?(r=i.show.complete||n.noop,t._animate(n.extend({},i.show,{complete:function(){r.apply(this,arguments),t._notifyShowComplete()}}))):t._notifyShowComplete()},_notifyShowComplete:function(){this._actions.shownAction(),this._deferredAnimate&&this._deferredAnimate.resolveWith(this)},_makeHidden:function(){var t=this,i=this.option("animation")||{},r;this._actions.hidingAction(),this._$wrapper.toggleClass(e,!1),i.hide?(r=i.hide.complete||n.noop,t._animate(n.extend({},i.hide,{complete:function(){t._toggleVisibility(!1),r.apply(this,arguments),t._notifyHideComplete()}}))):(t._toggleVisibility(!1),t._notifyHideComplete())},_notifyHideComplete:function(){this._actions.hiddenAction(),this._deferredAnimate&&this._deferredAnimate.resolveWith(this)},_animate:function(i){n.isPlainObject(i)&&t.fx.animate(this._$container,i)},_toggleVisibility:function(n){n&&(this._moveToTargetContainer(),this._subscribeParentScroll()),this._$container.toggle(n),n||(this._moveFromTargetContainer(),this._unsubscribeParentScroll()),this._$wrapper.toggleClass(e,this.option("shading")&&n)},_defaultBackButtonHandler:function(){this.hide()},_toggleBackButtonCallback:function(){this._backButtonHandler&&(this.option("visible")?(this.closeCallback=n.proxy(this._backButtonHandler,this),t.backButtonCallback.add(this.closeCallback)):this.closeCallback&&t.backButtonCallback.remove(this.closeCallback))},_toggleDisabledState:function(n){this.callBase.apply(this,arguments),this._$container.toggleClass(y,n)},_optionChanged:function(t,i){if(n.inArray(t,s)>-1){this._renderActions();return}switch(t){case"position":this.option("visible")&&this._renderPosition();break;case"visible":this._toggleBackButtonCallback(),this._renderVisibilityAnimate();break;case"targetContainer":this._setTargetContainer(i),this._moveToTargetContainer(),this._renderStyles();break;case"closeOnOutsideClick":break;default:this.callBase.apply(this,arguments)}},toggle:function(t){return(t=t===i?!this.option("visible"):t,t===this.option("visible"))?n.Deferred().resolve().promise():(this._deferredAnimate=n.Deferred(),this.option("visible",t),this._deferredAnimate.promise())},show:function(){return this.toggle(!0)},hide:function(){return this.toggle(!1)},content:function(){return this._$container},repaint:function(){this._repaint()}}))}(jQuery,DevExpress),function(n,t){var u=t.ui,f="dx-toast",r=f+"-",e=r+"wrapper",o=r+"content",s=r+"message",h=r+"icon",c="dxToast",l=["info","warning","error","success"];u.registerComponent(c,u.dxOverlay.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{message:"",type:"info",displayTime:2e3,position:{my:"bottom center",at:"bottom center",of:window,offset:"0 -20"},animation:{show:{type:"fade",duration:400,from:0,to:1},hide:{type:"fade",duration:400,to:0}},shading:!1,disabled:!1,height:"auto"})},_renderContentImpl:function(){this.option("message")&&(this._message=n("<div>").addClass(s).text(this.option("message")).appendTo(this.content())),n.inArray(this.option("type").toLowerCase(),l)>-1&&this.content().prepend(n("<div>").addClass(h)),this.callBase()},_render:function(){this.callBase(),this._element().addClass(f),this._wrapper().addClass(e),this._$container.addClass(r+String(this.option("type")).toLowerCase()),this.content().addClass(o)},_notifyShowComplete:function(){this.callBase(),clearTimeout(this._hideTimeout),this._hideTimeout=setTimeout(n.proxy(function(){this.hide()},this),this.option("displayTime"))},_dispose:function(){clearTimeout(this._hideTimeout),this.callBase()},_optionChanged:function(n,t,i){switch(n){case"type":this._$container.removeClass(r+i),this._$container.addClass(r+String(t).toLowerCase());break;case"message":this._message&&this._message.text(t);break;default:this.callBase.apply(this,arguments)}}}))}(jQuery,DevExpress),function(n,t){var e=t.ui,r="dx-popup",c=r+"-wrapper",o=r+"-fullscreen",l=r+"-content",s=r+"-title",h="."+s,a="dx-closebutton",u="dx-popup-bottom",v="dx-toolbar-left",y="dx-toolbar-right",f=".dx-overlay-content",p=function(i){var e=t.devices.current(i),r={cancel:{subclass:"dx-popup-cancel"},clear:{subclass:"dx-popup-clear"},done:{subclass:"dx-popup-done"}};return e.ios&&(n.extend(r.cancel,{parent:h,wraperClass:v}),n.extend(r.clear,{parent:h,wraperClass:y}),n.extend(r.done,{parent:f,wraperClass:u})),(e.android||e.platform==="desktop"||e.win8||e.tizen||e.generic)&&(n.extend(r.cancel,{parent:f,wraperClass:u}),n.extend(r.clear,{parent:f,wraperClass:u}),n.extend(r.done,{parent:f,wraperClass:u})),r};e.registerComponent("dxPopup",e.dxOverlay.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{title:"",showTitle:!0,fullScreen:!1,cancelButton:null,doneButton:null,clearButton:null,closeButton:null})},_render:function(){this.callBase(),this._element().addClass(r),this._wrapper().addClass(c),this._setContentHeight()},_renderDimensions:function(){this.option("fullScreen")?(this._wrapper().css({width:"100%",height:"100%"}),this._$container.css({width:"100%",height:"100%"})):this.callBase()},_renderPosition:function(){this.option("fullScreen")?this._$container.position(0,0):this.callBase()},_renderContentImpl:function(){this._$container.toggleClass(o,this.option("fullScreen")),this._$content=this._$container.wrapInner(n("<div />").addClass(l)).children().eq(0),this.callBase(this._templates.content),this._renderTitle(),this._renderCloseButton(),this._renderCancelButton(),this._renderClearButton(),this._renderDoneButton()},_renderContent:function(){this.callBase(),this._setContentHeight()},_setContentHeight:function(){var t;if(this._$content){var n=this._$container.height(),i=this.option("cancelButton")||this.option("doneButton")||this.option("clearButton"),r=this._$wrapper.find(".dx-popup-bottom");this._$title&&(n-=this._$title.outerHeight(!0)||0),i&&(t=r.outerHeight(!0)||0,n-=t,this._$content.css("margin-bottom",t)),this.option("height")==="auto"?this._$content.css("height","auto"):n>0&&this._$content.css("height",n)}},_renderTitle:function(){if(this.option("showTitle")){this._$title=this._$title||n("<div />").addClass(s),this._element().append(this._$title);var t=this._templates.title;t?t.render(this._$title):this._defaultTitleRender(),this._$title.prependTo(this._$container)}else this._$title&&this._$title.detach()},_defaultTitleRender:function(){this._$title.text(this.option("title"))},_renderCloseButton:function(){if(!this._templates.title&&this.option("closeButton")&&this.option("showTitle")){var t=this._createButtonAction();n("<div/>").addClass(a).on(e.events.addNamespace("dxclick",this.NAME+"TitleCloseButton"),function(n){t({jQueryEvent:n})}).appendTo(this._$title)}},_renderCancelButton:function(){this._renderSpecificButton(this.option("cancelButton"),{type:"cancel",text:Globalize.localize("Cancel")})},_renderClearButton:function(){this._renderSpecificButton(this.option("clearButton"),{type:"clear",text:Globalize.localize("Clear")})},_renderDoneButton:function(){this._renderSpecificButton(this.option("doneButton"),{type:"done",text:Globalize.localize("Done")})},_renderSpecificButton:function(n,t){var u=this._getRenderButtonParams(t.type),i;(this._removeButton(u),this._wrapper().toggleClass(r+"-"+t.type+"-visible",!!n),n)&&(i=this.option(t.type+"Button"),this._renderButton({text:i.text||t.text,clickAction:this._createButtonAction(i.clickAction)},u))},_createButtonAction:function(n){return this._createAction(n,{afterExecute:function(n){n.component.hide()}})},_getRenderButtonParams:function(t){return n.extend({parent:this.content()},p()[t])},_renderButton:function(t,i){var f=n("<div/>").addClass(i.subclass).dxButton(t),e=this._wrapper().find(i.parent),r=this._wrapper().find("."+i.wraperClass);r.length||(r=n("<div/>").addClass(i.wraperClass).appendTo(e)),f.appendTo(r),this._wrapper().find("."+u).addClass(i.subclass)},_removeButton:function(n){var t="."+(n.subclass||n.wraperClass);this.content()&&this.content().removeClass(n.subclass),this._wrapper().find(t).remove()},_optionChanged:function(n,t){switch(n){case"showTitle":case"title":this._renderTitle(),this._renderCloseButton(),this._setContentHeight();break;case"cancelButton":this._renderCancelButton();break;case"clearButton":this._renderClearButton();break;case"doneButton":this._renderDoneButton();break;case"closeButton":this._renderCloseButton();break;case"height":this.callBase.apply(this,arguments),this._setContentHeight();break;case"fullScreen":this._$container.toggleClass(o,t),this._invalidate();break;default:this.callBase.apply(this,arguments)}},content:function(){return this._$content}}))}(jQuery,DevExpress),function(n,t){var r=t.ui,u="dx-popover",f="dx-popover-wrapper",e="dx-popover-arrow",o="dx-popover-arrow-flipped",s="dx-popover-without-title";r.registerComponent("dxPopover",r.dxPopup.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{target:window,shading:!1,position:{my:"top center",at:"bottom center",collision:"fit flip"},closeOnOutsideClick:n.proxy(this._isOutsideClick,this),animation:{show:{type:"fade",to:1},hide:{type:"fade",to:0}},showTitle:!1,width:"auto",height:"auto"})},_render:function(){this._$arrow=n("<div>").addClass(e),this.callBase(),this._element().addClass(u),this._wrapper().addClass(f),this._renderTarget()},_renderContentImpl:function(){this.callBase(),this._$arrow.appendTo(this._wrapper()),this._updateContentSize()},_updateContentSize:function(){if(this._$content){var t=this._$container.outerHeight(),r=t-this._$content.height(),u=n(this.option("target")).outerHeight(),i=(n(window).height()-u)*.5-this._$arrow.height()-r;t>i&&this._$content.height(+i)}},_isOutsideClick:function(t){return!n(t.target).closest(this.option("target")).length},_animate:function(i){this.callBase(i),n.isPlainObject(i)&&t.fx.animate(this._$arrow,i)},_renderTitle:function(){this._wrapper().toggleClass(s,!this.option("showTitle")),this.callBase()},_renderTarget:function(){this.option("position.of",this.option("target"))},_renderPosition:function(){var u;t.translator.move(this._$arrow,{left:0,top:0}),t.translator.move(this._$container,{left:0,top:0}),this._updateContentSize();var i=n.extend({},this.option("position")),f=n.extend({},i,{offset:"0 "+this._$arrow.height()}),e=t.calculatePosition(this._$container,f),r=e.v.flip;this._$arrow.toggleClass(o,r),r&&n.extend(i,{my:i.at,at:i.my}),t.position(this._$arrow,i),u={my:i.my,at:i.at,offset:r?"0 1":"0 -1",of:this._$arrow,collision:"fit"},t.position(this._$container,u)},_optionChanged:function(n){switch(n){case"target":this._renderTarget();break;default:this.callBase.apply(this,arguments)}}}))}(jQuery,DevExpress),function(n,t,i){var f=t.ui,w=f.events,b=t.support,o=Globalize,k="dx-datebox",d="dx-datepicker",g="dx-datepicker-wrapper",nt="dx-datepicker-rollers",tt="dx-datepicker-roller",it="dx-state-active",rt="dx-datepicker-roller-current",ut="dx-datepicker-item",ft="dx-datepicker-item-selected",et="dx-datepicker-item-selected-frame",ot="dx-datepicker-button-up",st="dx-datepicker-button-down",ht="datepicker-formatter-container",ct="datepicker-value-formatter",lt="datepicker-name-formatter",at=["date","time","datetime"],vt=function(n){return n},p=function(t,i){var r=n("<div />").addClass(ht);return n("<span>").text(t).addClass(ct).appendTo(r),n("<span>").text(i).addClass(lt).appendTo(r),r},e="year",s="month",u="day",c="hours",l="minutes",a="seconds",v="milliseconds",yt=31536e7,r={};r[e]={getter:"getFullYear",setter:"setFullYear",possibleFormats:["yy","yyyy"],formatter:vt,startValue:i,endValue:i},r[u]={getter:"getDate",setter:"setDate",possibleFormats:["d","dd"],formatter:function(n,t,i){if(!t)return n;var r=new Date(i.getTime());return r.setDate(n),p(n,o.culture().calendar.days.names[r.getDay()])},startValue:1,endValue:i},r[s]={getter:"getMonth",setter:"setMonth",possibleFormats:["M","MM","MMM","MMMM"],formatter:function(n,t){var i=o.culture().calendar.months.names[n];return t?p(n+1,i):i},startValue:0,endValue:11},r[c]={getter:"getHours",setter:"setHours",possibleFormats:["H","HH","h","hh"],formatter:function(n){return o.format(new Date(0,0,0,n),"HH")},startValue:0,endValue:23},r[l]={getter:"getMinutes",setter:"setMinutes",possibleFormats:["m","mm"],formatter:function(n){return o.format(new Date(0,0,0,0,n),"mm")},startValue:0,endValue:59},r[a]={getter:"getSeconds",setter:"setSeconds",possibleFormats:["s","ss"],formatter:function(n){return o.format(new Date(0,0,0,0,0,n),"ss")},startValue:0,endValue:59},r[v]={getter:"getMilliseconds",setter:"setMilliseconds",possibleFormats:["f","ff","fff"],formatter:function(n){return o.format(new Date(0,0,0,0,0,0,n),"fff")},startValue:0,endValue:999};var h={date:{standardPattern:"yyyy-MM-dd",components:[e,u,s]},datetime:{standardPattern:"yyyy'-'MM'-'dd'T'HH':'mm':'ss'Z'",components:[e,u,s,c,l,a,v]},datetimeAndroid:{standardPattern:"yyyy'-'MM'-'dd'T'HH':'mm'Z'",components:[e,u,s,c,l,a,v]},time:{standardPattern:"HH:mm",components:[c,l]}},pt=function(n,t){return Globalize.format(n,h[t].standardPattern)},wt=function(n){return Globalize.parseDate(n,h.datetime.standardPattern)||Globalize.parseDate(n,h.datetimeAndroid.standardPattern)||Globalize.parseDate(n,h.time.standardPattern)||Globalize.parseDate(n,h.date.standardPattern)},y=function(n,t){return new Date(n,t+1,0).getDate()},bt=function(t,u,f){if(!u)return i;var e=h[f];return n.each(e.components,function(){var n=r[this];t[n.setter](u[n.getter]())}),t};f.registerComponent("dxDatePickerRoller",f.dxScrollable.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{showScrollbar:!1,useNative:!1,selectedIndex:0,items:[]})},_init:function(){this.callBase(),this._renderSelectedItemFrame(),this._renderControlButtons()},_render:function(){this.callBase(),this._element().addClass(tt),this._renderItems(),this._renderSelectedValue()},_renderItems:function(){var i=this.option("items")||[],t=n();this._$content.empty(),n.each(i,function(){t=t.add(n("<div>").addClass(ut).append(this))}),this._$content.append(t),this._$items=t,this.update()},_renderSelectedItemFrame:function(){n("<div>").addClass(et).insertAfter(this._$container)},_renderControlButtons:function(){n("<div>").addClass(ot).insertAfter(this._$container).dxButton({clickAction:n.proxy(this._handleUpButtonClick,this)}),n("<div>").addClass(st).insertAfter(this._$container).dxButton({clickAction:n.proxy(this._handleDownButtonClick,this)})},_renderSelectedValue:function(n){n===i&&(n=this.option("selectedIndex")),n=this._fitIndex(n);var t=this._getItemPosition(n);this.option().selectedIndex=n,this._moveTo({y:t}),this._renderActiveStateItem()},_fitIndex:function(n){var i=this.option("items")||[],t=i.length;return n>=t?t-1:n<0?0:n},_renderActiveStateItem:function(){var t=this.option("selectedIndex");n.each(this._$items,function(i){n(this).toggleClass(ft,t===i)})},_handleUpButtonClick:function(){this._animation=!0,this.option("selectedIndex",this.option("selectedIndex")-1)},_handleDownButtonClick:function(){this._animation=!0,this.option("selectedIndex",this.option("selectedIndex")+1)},_getItemPosition:function(n){return this._itemHeight()*n},_moveTo:function(i){i=this._normalizeLocation(i);var f=this._location(),r,u={x:-(f.left-i.x),y:-(f.top-i.y)};this._isVisible()&&(u.x||u.y)&&(this._animation?(r=t.fx.animate(this._$content,{duration:200,type:"slide",to:{top:i.y}}),delete this._animation):(r=n.Deferred().resolve().promise(),this._strategy._handleMove(u)),r.done(n.proxy(function(){this._strategy.update(),this._strategy._handleMoveEnd({x:0,y:0})},this)))},_handleEndAction:function(){var n=-this._location().top/this._itemHeight(),t=Math.round(n);this._renderSelectedValue(t)},_itemHeight:function(){var n=this._$items.first();return n.outerHeight()+parseFloat(n.css("margin-top"))},_toggleActive:function(n){this._element().toggleClass(it,n)},_isVisible:function(){return this._$container.is(":visible")},_optionChanged:function(n){switch(n){case"selectedIndex":this._renderSelectedValue();break;case"items":this._renderItems(),this._renderSelectedValue();break;default:this.callBase.apply(this,arguments)}}})),f.registerComponent("dxDatePicker",f.dxPopup.inherit({_valueOption:function(){return new Date(this.option("value"))=="Invalid Date"?new Date:new Date(this.option("value"))},_defaultOptions:function(){return n.extend(this.callBase(),{minDate:new Date(1990,1,1),maxDate:new Date(n.now()+yt),format:"date",value:new Date,culture:Globalize.culture().name,showNames:!1,cancelButton:{text:"Cancel",icon:"close",clickAction:n.proxy(function(){this._value=this._valueOption()},this)},doneButton:{text:"Done",icon:"save",clickAction:n.proxy(function(){this.option("value",new Date(this._value)),this.hide()},this)}})},_render:function(){this.callBase(),this._element().addClass(d),this._wrapper().addClass(g),this._value=this._valueOption()},_renderContentImpl:function(){this.callBase(),this._value=this._valueOption(),this._renderRollers()},_renderRollers:function(){var t=this;t._$rollersContainer||(t._$rollersContainer=n("<div>").appendTo(t.content()).addClass(nt)),t._$rollersContainer.empty(),t._createRollerConfigs(),t._rollers={},n.each(t._rollerConfigs,function(){var i=this,r=n("<div>").appendTo(t._$rollersContainer).dxDatePickerRoller({items:i.displayItems,selectedIndex:i.selectedIndex,startAction:function(n){var r=n.component;r._toggleActive.call(r,!0),t._setActiveRoller.call(t,i,r.option("selectedIndex"))},endAction:function(n){var r=n.component;r._animation=!0,r._handleEndAction.apply(r,arguments),t._setRollerState.call(t,i,r.option("selectedIndex")),r._toggleActive.call(r,!1)}});t._rollers[i.type]=r.dxDatePickerRoller("instance")})},_setActiveRoller:function(t){var i=this._rollers[t.type];n.each(this._rollers,function(){this._$element.toggleClass(rt,this===i)})},_refreshRollers:function(){var t=this;n.each(this._rollers,function(n){var i=t._rollerConfigs[n].getIndex(t._value);this.update(),this._renderSelectedValue(i)})},_setRollerState:function(n,t){var f,o;if(t!==n.selectedIndex){var r=n.valueItems[t],h=n.setValue,i=this._value.getDate();n.type===s?(i=Math.min(i,y(this._value.getFullYear(),r)),this._value.setDate(i)):n.type===e&&(i=Math.min(i,y(r,this._value.getMonth())),this._value.setDate(i)),this._value[h](r),n.selectedIndex=t}f=this._rollers[u],(n.type===s||n.type===e)&&f&&(this._createRollerConfig(u),o=this._rollerConfigs[u],window.setTimeout(function(){f.option("items",o.displayItems)},100))},_createRollerConfigs:function(t){var i=this;t=t||i.option("format"),i._rollerConfigs={},n.each(i._getFormatPattern(t).split(/\W+/),function(t,u){n.each(r,function(t,r){n.inArray(u,r.possibleFormats)>-1&&i._createRollerConfig(t)})})},_getFormatPattern:function(n){var t=Globalize.culture(this.option("culture")),i="";return n==="date"?i=t.calendar.patterns.d:n==="time"?i=t.calendar.patterns.t:n==="datetime"&&(i=[t.calendar.patterns.d,t.calendar.patterns.t].join(" ")),i},_createRollerConfig:function(n){var i=r[n],o=i.startValue,s=i.endValue,h=i.formatter,c=this.option("showNames"),t,f;for(n===e&&(o=this.option("minDate").getFullYear(),s=this.option("maxDate").getFullYear()),n===u&&(s=y(this._value.getFullYear(),this._value.getMonth())),t={type:n,setValue:i.setter,valueItems:[],displayItems:[],getIndex:function(n){return n[i.getter]()-o}},f=o;f<=s;f++)t.valueItems.push(f),t.displayItems.push(h(f,c,this._value));t.selectedIndex=t.getIndex(this._value),this._rollerConfigs[n]=t},_optionChanged:function(n,t,i){switch(n){case"minDate":case"maxDate":case"culture":case"format":this._renderRollers();break;case"visible":this.callBase(n,t,i),t&&this._refreshRollers();break;case"value":this._clean(),this._invalidate();default:this.callBase(n,t,i)}}})),f.registerComponent("dxDateBox",f.dxEditBox.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{format:"date",value:new Date,useNativePicker:!0})},_init:function(){this.callBase(),n.inArray(this.option("format"),at)===-1&&this.option("format","date"),this.option("mode",this.option("format"))},_render:function(){this.callBase(),this._element().addClass(k),this._renderDatePicker()},_renderDatePicker:function(){var t,i;if(!this._usingNativeDatePicker()&&!this.option("readOnly"))if(t={value:this.option("value"),format:this.option("format")},this._datePicker)this._datePicker.option(t);else{this._datePicker=n("<div>").appendTo(this._element()).dxDatePicker(n.extend(t,{hidingAction:n.proxy(function(n){this.option("value",n.component.option("value"))},this)})).dxDatePicker("instance"),i=this._createAction(function(n){n.component._datePicker.show()});this._input().on(w.addNamespace("dxclick",this.NAME),function(n){return i({jQuery:n})})}},_usingNativeDatePicker:function(){return b.inputType(this.option("format"))||this.option("useNativePicker")},_readOnlyPropValue:function(){return this._usingNativeDatePicker()?this.callBase():!0},_handleValueChange:function(){var i=wt(this._input().val()),n=new Date(this.option("value")&&this.option("value").valueOf()),t=bt(n,i,this.option("format"));this.option({value:t}),t!==n&&this._renderValue()},_renderValue:function(){this._input().val(pt(this.option("value"),this.option("format")))},_renderProps:function(){this.callBase(),this._input().attr("autocomplete","off")},_optionChanged:function(n,t,i){switch(n){case"value":this._renderValue(),this._changeAction(t),this._renderDatePicker();break;case"format":this.option("mode",t),this._renderValue(),this._renderDatePicker();break;case"readOnly":case"useNativePicker":this._invalidate();break;default:this.callBase(n,t,i)}}}))}(jQuery,DevExpress),function(n,t){var u=t.ui,r="dx-loadindicator",s=r+"-wrapper",h=r+"-icon",f=r+"-segment",e=r+"-segment",c=r+"-win8-segment",l=r+"-win8-segment",a=r+"-win8-inner-segment",o=r+"-image",v=["small","medium","large"];u.registerComponent("dxLoadIndicator",u.Widget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{disabled:!1,visible:!0,size:""})},_render:function(){this.callBase(),this._element().addClass(r),this._setSize(),t.support.animation&&!this.option("viaImage")?this._renderMarkupForAnimation():this._renderMarkupForImage()},_renderMarkupForAnimation:function(){var i=n("<div>").addClass(h),t;for(i.append(n("<div>").addClass(f).addClass(e+"0")),t=15;t>0;--t)i.append(n("<div>").addClass(f).addClass(e+t));for(t=1;t<=5;++t)i.append(n("<div>").addClass(c).addClass(l+t).append(n("<div>").addClass(a)));n("<div>").addClass(s).append(i).appendTo(this._element())},_renderMarkupForImage:function(){var n=this.option("size");n==="small"||n==="large"?this._element().addClass(o+"-"+n):this._element().addClass(o)},_setSize:function(){var t=this.option("size");t&&n.inArray(t,v)!==-1&&this._element().addClass(r+"-"+t)},_optionChanged:function(n){switch(n){case"size":this._setSize();break;default:this.callBase.apply(this,arguments)}}}))}(jQuery,DevExpress),function(n,t){var u=t.ui,r="dx-loadpanel",o=r+"-wrapper",f=r+"-indicator",e=r+"-message",s=r+"-content",h=r+"-has-indicator";u.registerComponent("dxLoadPanel",u.dxOverlay.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{message:Globalize.localize("Loading"),width:200,height:70,animation:null,disabled:!1,showIndicator:!0})},_render:function(){this.callBase(),this._element().addClass(r),this._wrapper().addClass(o)},_renderContentImpl:function(){this.callBase(),this.content().addClass(s),this._cleanPreviousContent(),this._renderLoadIndicator(),this._renderMessage()},_cleanPreviousContent:function(){this.content().find("."+e).remove(),this.content().find("."+f).remove()},_renderMessage:function(){var t=n("<div>").addClass(e).toggleClass(h,this.option("showIndicator")).text(this.option("message"));this.content().append(t)},_renderLoadIndicator:function(){if(this.option("showIndicator")){var t=n("<div>").addClass(f);this.content().append(t),t.dxLoadIndicator()}},_clean:function(){this.callBase.apply(this,arguments),this.content().empty()},_optionChanged:function(n){switch(n){case"message":case"showIndicator":this._clean(),this._render();break;default:this.callBase.apply(this,arguments)}},_defaultBackButtonHandler:n.noop}))}(jQuery,DevExpress),function(n,t,i){var u=t.ui,c=t.utils,o=u.events,r="dx-lookup",f=r+"-selected",l=r+"-search",a=r+"-field",e=r+"-popup",v=e+"-wrapper",s=e+"-search",y=r+"-popover-mode",h=".dx-list-item",p="dxListItemData",w=200;u.registerComponent("dxLookup",u.ContainerWidget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{dataSource:null,value:i,displayValue:i,title:"",valueExpr:null,displayExpr:"this",placeholder:Globalize.localize("Select"),searchPlaceholder:Globalize.localize("Search"),searchEnabled:!0,noDataText:Globalize.localize("dxCollectionContainerWidget-noDataText"),searchTimeout:1e3,minFilterLength:0,fullScreen:!1,valueChangeAction:null,itemTemplate:null,itemRender:null,showCancelButton:!0,cancelButtonText:Globalize.localize("Cancel"),showClearButton:!1,clearButtonText:Globalize.localize("Clear"),showDoneButton:!1,doneButtonText:Globalize.localize("Done"),contentReadyAction:null,shownAction:null,hiddenAction:null,popupWidth:function(){return n(window).width()*.8},popupHeight:function(){return n(window).height()*.8},usePopover:!1})},_optionsByReference:function(){return n.extend(this.callBase(),{value:!0})},_init:function(){this.callBase(),this._initDataSource(),this._checkExceptions(),this._searchTimer=null,this._compileValueGetter(),this._compileDisplayGetter(),this._createEventActions(),this._dataSource||this._itemsToDataSource()},_checkExceptions:function(){if(this._dataSource&&this._dataSource._mapFunc)throw Error("Data source with enabled map is not allowed in the lookup");},_compileValueGetter:function(){this._valueGetter=t.data.utils.compileGetter(this._valueGetterExpr())},_valueGetterExpr:function(){return this.option("valueExpr")||this._dataSource&&this._dataSource._store._key||"this"},_compileDisplayGetter:function(){this._displayGetter=t.data.utils.compileGetter(this.option("displayExpr"))},_createEventActions:function(){this._valueChangeAction=this._createActionByOption("valueChangeAction")},_itemsToDataSource:function(){this._dataSource=new DevExpress.data.DataSource(this.option("items"))},_render:function(){this.callBase(),this._element().addClass(r).toggleClass(y,this.option("usePopover")),this._renderField(),this._needRenderContent=!0,this._calcSelectedItem(n.proxy(this._setFieldText,this))},_renderContent:n.noop,_renderField:function(){var t=this._createAction(this._handleFieldClick);this._$field=n("<div/>").addClass(a).appendTo(this._element()).on(o.addNamespace("dxclick",this.NAME),function(n){t({jQueryEvent:n})})},_handleFieldClick:function(n){var t=n.component;t._renderContentIfNeed(),t._setListDataSource(),t._refreshSelected(),t._popup.show();t._popup.content().on("MSPointerDown",function(){});t._lastSelectedItem=t._selectedItem},_renderContentIfNeed:function(){this._needRenderContent&&(this._renderPopup(),this._needRenderContent=!1)},_renderPopup:function(){var t=n("<div />").addClass(e).appendTo(this._element()),i={title:this.option("title"),contentReadyAction:n.proxy(this._popupContentReadyAction,this),width:this.option("popupWidth"),height:this.option("popupHeight"),cancelButton:this._getCancelButtonConfig(),doneButton:this._getDoneButtonConfig(),clearButton:this._getClearButtonConfig(),shownAction:this._createActionByOption("shownAction"),hiddenAction:this._createActionByOption("hiddenAction")};this._popup=this.option("usePopover")?this._createPopover(t,i):this._createPopup(t,i),this._popup._wrapper().addClass(v).toggleClass(s,this.option("searchEnabled"))},_createPopover:function(t,i){return t.dxPopover(n.extend(i,{showTitle:!0,target:this._element()})).dxPopover("instance")},_createPopup:function(t,i){return t.dxPopup(n.extend(i,{fullScreen:this.option("fullScreen"),shading:!this.option("fullScreen")})).dxPopup("instance")},_getCancelButtonConfig:function(){return this.option("showCancelButton")?{text:this.option("cancelButtonText")}:null},_getDoneButtonConfig:function(){return this.option("showDoneButton")?{text:this.option("doneButtonText"),clickAction:n.proxy(function(){this.option("value",this._valueGetter(this._lastSelectedItem))},this)}:null},_getClearButtonConfig:function(){return this.option("showClearButton")?{text:this.option("clearButtonText"),clickAction:n.proxy(function(){this.option("value","")},this)}:null},_renderCancelButton:function(){this._popup&&this._popup.option("cancelButton",this._getCancelButtonConfig())},_renderDoneButton:function(){this._popup&&this._popup.option("doneButton",this._getDoneButtonConfig())},_renderClearButton:function(){this._popup&&this._popup.option("clearButton",this._getClearButtonConfig())},_popupContentReadyAction:function(){this._renderSearch(),this._renderList(),this._setListDataSource()},_renderSearch:function(){this._$search=n("<div/>").addClass(l).dxTextBox({mode:"search",placeholder:this._getSearchPlaceholder(),valueUpdateEvent:"change input",valueUpdateAction:n.proxy(this._searchChangedHandler,this)}).toggle(this.option("searchEnabled")).appendTo(this._popup.content()),this._search=this._$search.dxTextBox("instance")},_getSearchPlaceholder:function(){var n=this.option("minFilterLength"),t=this.option("searchPlaceholder");return n&&t===Globalize.localize("Search")?c.stringFormat(Globalize.localize("dxLookup-searchPlaceholder"),n):t},_renderList:function(){this._list=n("<div/>").appendTo(this._popup.content()).dxList({dataSource:null,itemClickAction:n.proxy(function(n){this._toggleSelectedClass(n.jQueryEvent),this._updateOptions(n)},this),itemRenderedAction:n.proxy(function(n){this._setSelectedClass(n.itemElement,n.itemData)},this),contentReadyAction:this.option("contentReadyAction"),itemRender:this._getItemRender(),itemTemplate:this.option("itemTemplate"),noDataText:this.option("noDataText")}).data("dxList"),this._list.addExternalTemplate(this._templates),this._needSetItemRenderToList&&(this._updateListItemRender(),this._needSetItemRenderToList=!1)},_setListDataSource:function(n){if(this._list){var t=this._search.option("value").length>=this.option("minFilterLength"),r=!!this._list.option("dataSource"),u=t===r;(n||!u)&&(this._list.option("dataSource",t?this._dataSource:null),t||this._list.option("items",i))}},_refreshSelected:function(){var t=this;t._list&&n.each(this._list._element().find(h),function(){var i=n(this);t._setSelectedClass(i,i.data(p))})},_calcSelectedItem:function(n){function o(t){s._selectedItem=t,n()}var e=this._dataSource,r,u,s=this,f=this.option("value");if(!e||f===i){this._selectedItem=i,n();return}r=e.store(),u=this._valueGetterExpr(),u===r.key()||r instanceof t.data.CustomStore?r.byKey(f).done(o):r.load({filter:[u,f]}).done(function(n){o(n[0])})},_setFieldText:function(n){arguments.length||(n=this._getDisplayText()),this._$field.text(n),this.option("displayValue",n)},_getDisplayText:function(){return this.option("value")===i||!this._dataSource?this.option("placeholder"):this._displayGetter(this._selectedItem)||this.option("placeholder")},_searchChangedHandler:function(){if(this._search){var t=this._search.option("value"),i=t.length>=this.option("minFilterLength");if(clearTimeout(this._$searchTimer),this._search.option("placeholder",this._getSearchPlaceholder()),!i){this._setListDataSource();return}this.option("searchTimeout")?this._searchTimer=setTimeout(n.proxy(this._doSearch,this,t),this.option("searchTimeout")):this._doSearch(t)}},_doSearch:function(n){this._dataSource&&(arguments.length||(n=this.option("searchEnabled")?this._search.option("value"):""),this._filterStore(n),this._setListDataSource())},_filterStore:function(n){this._dataSource.searchExpr()||this._dataSource.searchExpr(this.option("displayExpr")),this._dataSource.searchValue(n),this._dataSource.pageIndex(0),this._dataSource.load()},_updateOptions:function(n){this._lastSelectedItem===n.itemData&&this._updateAndHidePopup(),this._lastSelectedItem=n.itemData,this.option("showDoneButton")||this._updateAndHidePopup()},_setSelectedClass:function(n,t){var i=this._valueGetter(t)===this.option("value");n.toggleClass(f,i)},_getItemRender:function(){if(!this.option("itemTemplate"))return this.option("itemRender")||n.proxy(this._displayGetter,this)},_toggleSelectedClass:function(t){var i=this._list._element().find("."+f);i.length&&i.removeClass(f),n(t.target).closest(h).addClass(f)},_hidePopup:function(){this._popup.content().off("MSPointerDown"),this._popup.hide()},_updateAndHidePopup:function(){this.option("value",this._valueGetter(this._lastSelectedItem)),clearTimeout(this._hidePopupTimer),this._hidePopupTimer=setTimeout(n.proxy(this._hidePopup,this),w),this._setFieldText(this._displayGetter(this._lastSelectedItem))},_updateListItemRender:function(){this._list?this._list.option("itemRender",this._getItemRender()):this._needSetItemRenderToList=!0},_updateListItemTemplate:function(){this._list&&this._list.option("itemTemplate",this.option("itemTemplate"))},_handleDataSourceChanged:function(){this._calcSelectedItem(n.proxy(this._setFieldText,this))},_clean:function(){this._popup&&this._popup._element().remove(),this._$field&&this._$field.remove(),this.callBase()},_dispose:function(){clearTimeout(this._searchTimer),clearTimeout(this._hidePopupTimer),n(window).off(o.addNamespace("popstate",this.NAME)),this.callBase()},_optionChanged:function(t,i){switch(t){case"valueExpr":case"value":this._calcSelectedItem(n.proxy(function(){t==="value"&&this._valueChangeAction({selectedItem:this._selectedItem}),this._compileValueGetter(),this._compileDisplayGetter(),this._refreshSelected(),this._setFieldText()},this));break;case"displayExpr":this._compileDisplayGetter(),this._updateListItemRender(),this._refreshSelected(),this._setFieldText();break;case"displayValue":break;case"itemRender":this._updateListItemRender();case"itemTemplate":this._updateListItemTemplate();break;case"items":case"dataSource":t==="items"?this._itemsToDataSource():this._initDataSource(),this._setListDataSource(!0),this._compileValueGetter(),this._calcSelectedItem(n.proxy(this._setFieldText,this));break;case"searchEnabled":this._$search.toggle(i),this._popup&&this._popup._wrapper().toggleClass(s,i);break;case"minFilterLength":this._setListDataSource(),this._setFieldText(),this._searchChangedHandler();break;case"placeholder":this._setFieldText();break;case"searchPlaceholder":this._$search&&this._$search.dxTextBox("instance").option("placeholder",i);break;case"title":case"fullScreen":this._popup&&this._popup.option(t,i);break;case"valueChangeAction":this._createEventActions();break;case"showClearButton":this._renderClearButton();break;case"showCancelButton":this._renderCancelButton();break;case"showDoneButton":this._renderDoneButton();break;case"contentReadyAction":this._list.option("contentReadyAction",i);break;case"popupWidth":this._popup&&this._popup.option("width",i);break;case"popupHeight":this._popup&&this._popup.option("height",i);break;default:this.callBase.apply(this,arguments)}this._checkExceptions()}}).include(u.DataHelperMixin))}(jQuery,DevExpress),function(n,t){var r=t.ui,u="dx-action-sheet",f="dx-action-sheet-container",e="dx-action-sheet-popup-wrapper",o="dx-action-sheet-popover-wrapper",s="dx-action-sheet-cancel",h="dx-action-sheet-item",c="dxActionSheetItemData",l="dx-action-sheet-without-title";r.registerComponent("dxActionSheet",r.CollectionContainerWidget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{usePopover:!1,target:null,title:"",showTitle:!0,cancelText:Globalize.localize("Cancel"),noDataText:"",visible:!1})},_render:function(){this._element().addClass(u),this._createItemContainer(),this._renderPopup()},_createItemContainer:function(){this._$itemContainer=n("<div/>").addClass(f),this._toggleDisabled(this.option("disabled"))},_renderClick:function(){this._popup.option("clickAction",this.option("clickAction"))},_renderPopup:function(){this._$popup=n("<div/>").appendTo(this._element()),this._popup=this._isPopoverMode()?this._createPopover(this._$popup):this._createPopup(this._$popup),this._togglePopupTitle(this.option("showTitle")),this._popup.option("visible",this.option("visible"))},_clean:function(){this._$popup&&this._$popup.remove(),this.callBase()},_togglePopupTitle:function(n){this._popup.option("showTitle",n),this._popup._wrapper().toggleClass(l,!n)},_isPopoverMode:function(){return this.option("usePopover")&&this.option("target")},_createPopover:function(t){var i=t.dxPopover({showTitle:!0,title:this.option("title"),width:200,height:"auto",target:this.option("target"),hiddenAction:n.proxy(this.hide,this),contentReadyAction:n.proxy(this._popupContentReadyAction,this)}).dxPopover("instance");return i._wrapper().addClass(o),i},_createPopup:function(t){var i=t.dxPopup({title:this.option("title"),width:"100%",height:"auto",contentReadyAction:n.proxy(this._popupContentReadyAction,this),position:{my:"bottom",at:"bottom",of:window},animation:{show:{type:"slide",duration:400,from:{position:{my:"top",at:"bottom",of:window}},to:{position:{my:"bottom",at:"bottom",of:window}}},hide:{type:"slide",duration:400,from:{position:{my:"bottom",at:"bottom",of:window}},to:{position:{my:"top",at:"bottom",of:window}}}}}).dxPopup("instance");return i._wrapper().addClass(e),i},_popupContentReadyAction:function(){this._popup.content().append(this._$itemContainer),this._attachClickEvent(),this._renderContent(),this._renderCancel()},_renderCancel:function(){this._isPopoverMode()||(this._cancelButton=n("<div/>").addClass(s).appendTo(this._popup.content()).dxButton({text:this.option("cancelText"),clickAction:n.proxy(this.hide,this)}).dxButton("instance"))},_handleItemClick:function(t){this.callBase(t);var i=n(t.target).closest(this._itemSelector()).data("dxButton");i.option("disabled")||this.option("disabled")||this.hide()},_itemRenderDefault:function(n,t,i){i.dxButton(n)},_itemContainer:function(){return this._$itemContainer},_itemClass:function(){return h},_itemDataKey:function(){return c},_toggleVisibility:n.noop,_toggleDisabled:function(n){this._$itemContainer.toggleClass("dx-state-disabled",n)},_optionChanged:function(n,t){switch(n){case"disabled":this._toggleDisabled(t);break;case"visible":case"title":this._popup.option(n,t);break;case"showTitle":this._togglePopupTitle(t);break;case"cancelText":this._cancelButton.option("text",t);break;case"items":this._attachClickEvent(),this._$itemContainer.empty(),this._renderContent(),this._popup.repaint();break;default:this.callBase.apply(this,arguments)}},toggle:function(t){var i=this,r=n.Deferred();return i._popup.toggle(t).done(function(){i.option("visible",t),r.resolveWith(i)}),r.promise()},show:function(){return this.toggle(!0)},hide:function(){return this.toggle(!1)}}))}(jQuery,DevExpress),function(n,t,i){var u=t.ui,f=t.utils,e=40,o=38,c=13,l=27,a=39,s=9,h="dx-autocomplete",v=h+"-popup-wrapper",r="dx-autocomplete-selected",y="."+r,p=".dx-list",w=".dx-editbox-input",b=".dx-list-item",k="dxListItemData",d=["startswith","contains","endwith","notcontains"];u.registerComponent("dxAutocomplete",u.ContainerWidget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{value:"",items:[],dataSource:null,itemTemplate:null,itemRender:null,minSearchLength:1,searchTimeout:0,placeholder:"",filterOperator:"contains",displayExpr:"this",valueUpdateAction:null,valueUpdateEvent:"change",maxLength:null})},_listElement:function(){return this._popup.content().find(p)},_listItemElement:function(){return this._popup.content().find(b)},_listSelectedItemElement:function(){return this._popup.content().find(y)},_inputElement:function(){return this._element().find(w)},_textboxElement:function(){return this._textbox._element()},_init:function(){this.callBase(),this._validateFilterOperator(),this._compileDisplayGetter(),this._initDataSource(),this._fillDataSourceFromItemsIfNeeded()},_fillDataSourceFromItemsIfNeeded:function(){!this.option("dataSource")&&this.option("items")&&this._itemsToDataSource()},_validateFilterOperator:function(){var i=this.option("filterOperator"),r=i.toLowerCase();if(!(n.inArray(r,d)>-1))throw Error(t.utils.stringFormat('Filter operator "{0}" is unavailable',i));},_compileDisplayGetter:function(){this._displayGetter=t.data.utils.compileGetter(this.option("displayExpr"))},_render:function(){this.callBase(),this._element().addClass(h),this._checkExceptions()},_renderContentImpl:function(){this._renderTextbox(),this._renderPopup(),this._renderValueUpdateEvent()},_renderTextbox:function(){this._textbox=n("<div />").dxTextBox({value:this.option("value"),placeholder:this.option("placeholder"),disabled:this.option("disabled"),maxLength:this.option("maxLength"),keyDownAction:n.proxy(this._handleTextboxKeyDown,this),keyUpAction:n.proxy(this._handleTextboxKeyUp,this),valueUpdateAction:n.proxy(this._updateValue,this),focusOutAction:n.proxy(function(){this._popup.hide()},this)}).appendTo(this._element()).data("dxTextBox"),this._caretPosition={start:0,end:0}},_renderValueUpdateEvent:function(){this._changeAction=this._createActionByOption("valueUpdateAction"),this._textboxOptionChange("valueUpdateEvent",this._getValueUpdateEvent())},_getValueUpdateEvent:function(){var n=this.option("valueUpdateEvent");return this._hasUpdateEvent("keyup")||(n+=" keyup"),this._hasUpdateEvent("change")||(n+=" change"),n},_hasUpdateEvent:function(n){return n&&this.option("valueUpdateEvent").indexOf(n)!==-1},_handleTextboxKeyDown:function(t){var i=this._listElement(),r=[s,o,e],u=t.jQueryEvent.which;i.is(":hidden")||n.inArray(u,r)>-1&&t.jQueryEvent.preventDefault()},_updateValue:function(n){var t=this._inputElement(),i;this.option("value",this._textbox.option("value")),t.prop("selectionStart",this._caretPosition.start),t.prop("selectionEnd",this._caretPosition.end),i=n.jQueryEvent&&this._hasUpdateEvent(n.jQueryEvent.type),(!n.jQueryEvent||i)&&this._changeAction(this.option("value"))},_handleTextboxKeyUp:function(n){var t=n.jQueryEvent.which;this._caretPosition={start:this._inputElement().prop("selectionStart"),end:this._inputElement().prop("selectionEnd")};switch(t){case e:this._handleTextboxDownKey();break;case o:this._handleTextboxUpKey();break;case c:this._handleTextboxEnterKey();break;case a:case s:this._handleTextboxCompleteKeys();break;case l:this._handleTextboxEscKey();break;default:return}},_handleTextboxDownKey:function(){var n=this._listSelectedItemElement(),t;n.length?(t=n.next(),t.addClass(r),n.removeClass(r)):this._listItemElement().first().addClass(r)},_handleTextboxUpKey:function(){var n=this._listSelectedItemElement(),t,i=this._listElement();if(!i.is(":hidden")){if(!n.length){this._listItemElement().last().addClass(r);return}n.removeClass(r),t=n.prev(),t.length&&t.addClass(r)}},_handleTextboxEnterKey:function(){var t=this._listSelectedItemElement(),n;if(!t.length){this._popup.hide();return}n=this._selectedItemDataGetter(),this._caretPosition={start:n.length,end:n.length},this.option("value",n),this._popup.hide(),this._inputElement().blur()},_handleTextboxCompleteKeys:function(){var i=this._listElement(),n,t;i.is(":hidden")||(t=this._selectedItemDataGetter(),n=t.length?t:this._dataSource.items()[0],this._caretPosition={start:n.length,end:n.length},n=this._displayGetter(n),this.option("value",n),this._popup.hide())},_selectedItemDataGetter:function(){var n=this._listSelectedItemElement();return n.length?this._displayGetter(n.data(k)):[]},_handleTextboxEscKey:function(){this._popup.hide()},_renderPopup:function(){var u=this._textboxElement(),e=u.width(),o=this._textbox._input(),i=0,r=0;t.devices.current().win8?i=-2:(t.devices.current().platform==="desktop"||t.devices.current().tizen)&&(i=-1),t.devices.current().platform==="desktop"&&(r=-1),this._popup=n("<div/>").appendTo(this._element()).dxPopup({shading:!1,closeOnOutsideClick:!0,closeOnTargetScroll:!0,showTitle:!1,width:e,shownAction:n.proxy(this._handlePopupShown,this),showingAction:n.proxy(this._handlePopupShowing,this),height:"auto",deferRendering:!1,position:{my:"left top",at:"left bottom",of:o,offset:{h:r,v:i},collision:"flip"},animation:{show:{type:"fade",duration:400,from:0,to:1},hide:{type:"fade",duration:400,from:1,to:0}}}).data("dxPopup"),this._popup._wrapper().addClass(v),this._renderList(),this._autocompleteResizeCallback=n.proxy(this._calculatePopupWidth,this),f.windowResizeCallbacks.add(this._autocompleteResizeCallback)},_handlePopupShown:function(){var t=n(window).height()*.5;this._popup.content().height()>t&&this._popup.option("height",t)},_handlePopupShowing:function(){this._calculatePopupWidth()},_calculatePopupWidth:function(){var n=this._textboxElement(),t=n.width();this._popup.option("width",t)},_renderList:function(){this._list=n("<div />").appendTo(this._popup.content()).dxList({itemClickAction:n.proxy(this._handleListItemClick,this),itemTemplate:this.option("itemTemplate"),itemRender:this._getItemRender(),noDataText:"",showNextButton:!1,autoPagingEnabled:!1,dataSource:this._dataSource}).data("dxList"),this._list.addExternalTemplate(this._templates)},_getItemRender:function(){if(!this.option("itemTemplate"))return this.option("itemRender")||n.proxy(this._displayGetter,this)},_handleListItemClick:function(n){var t=this._displayGetter(n.itemData);this._caretPosition={start:t.length,end:t.length},this.option("value",t),this._popup.hide(),this._inputElement().blur()},_itemsToDataSource:function(){return this._dataSource=new DevExpress.data.DataSource(this.option("items"))},_filterDataSource:function(){var n=this._textbox.option("value");this._reloadDataSource(n),this._clearSearchTimer()},_reloadDataSource:function(n,t){var i=this,r=i._dataSource;r.searchExpr(i.option("displayExpr")),r.searchOperation(t||i.option("filterOperator")),r.searchValue(n),i._dataSource.pageIndex(0),i._dataSource.load().done(function(){i._refreshVisibility()})},_refreshVisibility:function(){var i=this._textbox.option("value").length>=this.option("minSearchLength"),t=this._dataSource,n=t&&t.items(),r=n.length;i&&r?n.length===1&&this._displayGetter(n[0])===this.option("value")?this._popup.hide():this._displayGetter(n[0]).length<this.option("value").length?this._popup.hide():(this._popup._refresh(),this._popup.show()):this._popup.hide()},_dispose:function(){this._clearSearchTimer(),f.windowResizeCallbacks.remove(this._autocompleteResizeCallback),this.callBase()},_textboxOptionChange:function(n,t){this._textbox.option(n,t)},_optionChanged:function(n,t){switch(n){case"disabled":this.callBase(n,t),this._textboxOptionChange(n,t);break;case"value":this._checkExceptions(),this._textboxOptionChange(n,t),this._applyFilter();break;case"maxLength":case"placeholder":this._textboxOptionChange(n,t);break;case"items":case"dataSource":n==="items"?this._itemsToDataSource():this._initDataSource();case"itemTemplate":case"itemRender":this._list.option(n,t);break;case"filterOperator":this._validateFilterOperator();break;case"displayExpr":this._compileDisplayGetter(),this._list.option("itemRender",this._getItemRender());break;case"minSearchLength":case"searchTimeout":break;case"valueUpdateEvent":case"valueUpdateAction":this._renderValueUpdateEvent();break;default:this.callBase.apply(this,arguments)}},_applyFilter:function(){var t=this._textbox.option("value"),i=t.length>=this.option("minSearchLength");if(!i){this._clearSearchTimer(),this._popup.hide();return}this.option("searchTimeout")>0?this._searchTimer||(this._searchTimer=setTimeout(n.proxy(this._filterDataSource,this),this.option("searchTimeout"))):this._filterDataSource()},_clearSearchTimer:function(){clearTimeout(this._searchTimer),delete this._searchTimer},_checkExceptions:function(){if(this.option("value")===i)throw Error("Value option should not be undefined");},_clean:function(){this.callBase(),this._element().empty()}}).include(u.DataHelperMixin))}(jQuery,DevExpress),function(n,t){var r=t.ui,u=r.events,f="dx-dropdownmenu",e=f+"-popup-wrapper",o="dx-dropdownmenu-list",s="dx-dropdownmenu-button";r.registerComponent("dxDropDownMenu",r.ContainerWidget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{items:[],itemClickAction:null,dataSource:null,itemTemplate:"item",itemRender:null,buttonText:"",buttonIcon:null,buttonIconSrc:null,buttonClickAction:null,usePopover:!1})},_init:function(){this.callBase(),this._initDataSource(),this._initItemClickAction()},_initItemClickAction:function(){this._itemClickAction=this._createActionByOption("itemClickAction")},_render:function(){this._element().addClass(f),this._renderButton(),this.callBase()},_clean:function(){this.callBase(),this._popup._element().remove()},_renderContentImpl:function(){this._renderPopup()},_renderButton:function(){var t=this.option("buttonIconSrc"),n=this.option("buttonIcon");t||n||(n="overflow"),this._button=this._element().addClass(s).dxButton({text:this.option("buttonText"),icon:n,iconSrc:t,clickAction:this.option("buttonClickAction")}).dxButton("instance")},_renderClick:function(){this.callBase();var n=this._createAction(this._handleButtonClick);this._element().on(u.addNamespace("dxclick",this.NAME),function(t){n({jQueryEvent:t})});this._popup&&this._popup.option("clickAction",this.option("clickAction"))},_handleButtonClick:function(n){n.component._popup.toggle()},_renderList:function(t){var r=t.content(),i=this,u;i._list=r.addClass(o).dxList({autoPagingEnabled:!1,noDataText:"",itemRender:i.option("itemRender"),itemTemplate:i.option("itemTemplate"),itemClickAction:function(n){i._popup.hide(),i._itemClickAction(n)}}).data("dxList"),i._list.addExternalTemplate(i._templates),i._setListDataSource(),i._attachListClick(),u=n(window).height()*.5,r.height()>u&&r.height(u)},_toggleVisibility:function(n){this.callBase(n),this._button.option("visible",n)},_attachListClick:function(){var n=this._createAction(this._handleListClick);this._list._element().off("."+this.NAME).on(u.addNamespace("dxclick",this.NAME),function(t){n({jQueryEvent:t})})},_handleListClick:function(n){n.component._popup.hide()},_renderPopup:function(){var t=this._$popup=n("<div />").appendTo(this._element()),i={clickAction:this.option("clickAction"),contentReadyAction:n.proxy(this._popupContentReadyHandler,this),deferRendering:!1};this._popup=this.option("usePopover")?this._createPopover(t,i):this._createPopup(t,i),this._popup._wrapper().addClass(e)},_popupContentReadyHandler:function(){var n=this._$popup[this.option("usePopover")?"dxPopover":"dxPopup"]("instance");this._renderList(n)},_createPopover:function(t,i){return t.dxPopover(n.extend(i,{target:this._element()})).dxPopover("instance")},_createPopup:function(t,i){return t.dxPopup(n.extend(i,{showTitle:!1,width:"auto",height:"auto",shading:!1,closeOnOutsideClick:n.proxy(function(t){return!n(t.target).closest(this._button._element()).length},this),closeOnTargetScroll:!0,position:{my:"right top",at:"right bottom",of:this._element(),collision:"fit flip"},animation:{show:{type:"fade",to:1},hide:{type:"fade",to:0}}})).dxPopup("instance")},_setListDataSource:function(){this._list&&this._list.option("dataSource",this._dataSource||this.option("items"))},_optionChanged:function(n,t){if(/^button/.test(n)){this._renderButton();return}switch(n){case"items":case"dataSource":this._refreshDataSource(),this._setListDataSource();break;case"itemRender":case"itemTemplate":this._list&&this._list.option(n,t);break;case"itemClickAction":this._initItemClickAction();break;default:this.callBase.apply(this,arguments)}}}).include(r.DataHelperMixin))}(jQuery,DevExpress),function(n,t,i){var r=t.ui,f=r.events,e="dx-selectbox",o="dx-selectbox-popup",u="dx-selectbox-arrow-container",s="dx-selectbox-arrow";r.registerComponent("dxSelectBox",r.dxAutocomplete.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{items:[],value:i,valueChangeAction:null,placeholder:Globalize.localize("Select"),valueExpr:null,tooltipEnabled:!1})},_init:function(){this.callBase(),this._dataSource||this._itemsToDataSource()},_itemsToDataSource:function(){this._dataSource=new DevExpress.data.DataSource(this.option("items"))},_getValueWidth:function(t){var i=n("<div />").html(t).css({width:"auto",position:"fixed",top:"-3000px",left:"-3000px"}).appendTo("body");return i.width()},_setTooltip:function(n){this.option("tooltipEnabled")&&(this._$element.context.title=this._$element.context.scrollWidth<=this._getValueWidth(n)?n:"")},_render:function(){this._compileValueGetter(),this.callBase(),this._setTooltip(this.option("value")),this._setWidgetClasses(),this._renderArrowDown()},_renderPopup:function(){if(this.callBase(),t.devices.current().win8){var i=this._popup.option("position");n.extend(i,{at:"left top",offset:{h:0,v:2}}),this._popup.option("position",i)}},_renderValueUpdateEvent:function(){this._changeAction=this._createActionByOption("valueChangeAction")},_setWidgetClasses:function(){var n=this._element(),t=this._popup._element();n.addClass(e),t.addClass(o)},_renderArrowDown:function(){var t=this._createAction(function(n){n.component._popup.toggle()});n("<div />").addClass(u).appendTo(this._element()).on(f.addNamespace("dxclick",this.NAME),function(n){t({jQueryEvent:n})});n("<div />").addClass(s).appendTo(this._element().find("."+u))},_applyFilter:n.noop,_updateValue:n.noop,_renderTextbox:function(){this.callBase(),this._searchValue(this.option("value")).done(n.proxy(this._updateTextBox,this))},_updateTextBox:function(t){this._selectedItem=t,this._textbox.option({readOnly:!0,value:this._displayGetter(this._selectedItem),clickAction:n.proxy(function(){this._popup.toggle()},this)})},_compileValueGetter:function(){this._valueGetter=t.data.utils.compileGetter(this._valueGetterExpr())},_valueGetterExpr:function(){return this.option("valueExpr")||this._dataSource&&this._dataSource._store._key||"this"},_handleListItemClick:function(n){this.option("value",this._valueGetter(n.itemData)),this._popup.hide()},_searchValue:function(i){var f=this,r=this._dataSource.store(),e=this._valueGetterExpr(),u=n.Deferred();return e===r.key()||r instanceof t.data.CustomStore?r.byKey(i).done(function(n){u.resolveWith(f,[n])}):r.load({filter:[e,i]}).done(function(n){u.resolveWith(f,n)}),u.promise()},_changeValueExpr:function(){this._compileValueGetter(),this.option("value",this._valueGetter(this._selectedItem))},_changeValue:function(t){this._searchValue(t).done(n.proxy(this._handleSearchComplete,this)),this._setTooltip(t)},_handleSearchComplete:function(n){this._selectedItem=n,this._textboxOptionChange("value",this._displayGetter(n)),this._changeAction(this.option("value"))},_renderList:function(){this.callBase(),this._list.option("autoPagingEnabled",!0)},_optionChanged:function(n,t){switch(n){case"valueExpr":this._changeValueExpr();break;case"displayExpr":this._compileDisplayGetter(),this._refresh();break;case"value":this._changeValue(t);break;case"valueChangeAction":this._renderValueUpdateEvent();break;default:this.callBase.apply(this,arguments)}}}))}(jQuery,DevExpress),function(n,t){var o=t.ui,s=o.events,e=t.fx,c=t.translator,l=t.utils,w="dx-panorama",b="dx-panorama-title",k="dx-panorama-ghosttitle",d="dx-panorama-itemscontainer",a="dx-panorama-item",v="dx-panorama-ghostitem",g="dx-panorama-item-header",nt="dxPanoramaItemData",tt=.02,it=.02,rt=300,ut="cubic-bezier(.40, .80, .60, 1)",ft=300,et="cubic-bezier(.40, .80, .60, 1)",ot=300,st="cubic-bezier(.40, .80, .60, 1)",y=function(n,t){n.css("background-position",t+"px 0%")},f=function(n){return c.locate(n).left},r=function(n,t){c.move(n,{left:t})},u={backgroundMove:function(n,t,i){return e.animate(n,{to:{"background-position":t+"px 0%"},duration:rt,easing:ut,complete:i})},titleMove:function(n,t,i){return e.animate(n,{type:"slide",to:{left:t},duration:ft,easing:et,complete:i})},itemMove:function(n,t,i){return e.animate(n,{type:"slide",to:{left:t},duration:ot,easing:st,complete:i})}},p=function(t){t&&n.each(t,function(n,t){e.stop(t,!0)})},h=t.Class.inherit({ctor:function(n){this._panorama=n},init:n.noop,render:n.noop,allItemElements:function(){return this._panorama._itemElements()},updatePositions:t.abstract,animateRollback:t.abstract,detectBoundsTransition:t.abstract,animateComplete:t.abstract,_itemMargin:function(){return this._panorama._$itemsContainer.width()*tt},_indexBoundary:function(){return this._panorama._indexBoundary()},_normalizeIndex:function(n){return this._panorama._normalizeIndex(n)}}),ht=h.inherit({updatePositions:function(){var t=this._panorama._itemElements(),i=this._itemMargin();t.each(function(){r(n(this),i)})},animateRollback:n.noop,detectBoundsTransition:n.noop,animateComplete:n.noop}),ct=h.inherit({init:function(){this._initGhostItem()},render:function(){this._renderGhostItem()},_initGhostItem:function(){this._$ghostItem=n("<div>").addClass(v)},_renderGhostItem:function(){this._panorama._itemContainer().append(this._$ghostItem),this._toggleGhostItem(!1)},_toggleGhostItem:function(n){var t=this._$ghostItem;n?t.css("opacity",1):t.css("opacity",0)},_updateGhostItemContent:function(n){n!==!1&&n!==this._prevGhostIndex&&(this._$ghostItem.html(this._panorama._itemElements().eq(n).html()),this._prevGhostIndex=n)},_isGhostItemVisible:function(){return this._$ghostItem.css("opacity")==1},_swapGhostWithItem:function(n){var t=this._$ghostItem,i=f(n);r(n,f(t)),r(t,i)},allItemElements:function(){return this._panorama._itemContainer().find("."+a+", ."+v)},updatePositions:function(t){var e=this.allItemElements(),i=this._panorama.option("selectedIndex"),u=t>0&&i===0||t<0&&i===1,f=t<0&&i===0||t>0&&i===1,o=u&&"replaceLast"||f&&"replaceFirst",s=u&&1||f&&0,h=this._calculateItemPositions(i,o);this._updateGhostItemContent(s),this._toggleGhostItem(u||f),e.each(function(i){r(n(this),h[i]+t)})},animateRollback:function(t){var s=this,i=this._panorama._itemElements(),e=this._itemMargin(),h=f(i.eq(t))-e,r=f(this._$ghostItem)-e,o=this._calculateItemPositions(t,r>0?"prepend":"append"),c=t===0&&h>0&&r>0||t===1&&r<0;c?this._swapGhostWithItem(i.eq(1)):this._swapGhostWithItem(i.eq(0)),i.each(function(t){u.itemMove(n(this),o[t])}),u.itemMove(this._$ghostItem,o[2],function(){s._toggleGhostItem(!1)})},detectBoundsTransition:function(n,t){var i=f(this._$ghostItem),r=this._itemMargin();return n===0&&i<r?"left":t===0&&i>r?"right":void 0},animateComplete:function(t,i,r){var o=this,s=!t^!(r===0)?"prepend":"append",h=this._panorama._itemElements(),e=this._calculateItemPositions(i,s),f=[];return h.each(function(t){f.push(u.itemMove(n(this),e[t]))}),f.push(u.itemMove(this._$ghostItem,e[2],function(){o._toggleGhostItem(!1)})),n.when.apply(n,f)},_calculateItemPositions:function(n,t){var i=[],h=this._panorama._itemElements(),e=this._itemMargin(),o=h.eq(0).outerWidth(),s=o+e,u=n===0,f=-o,r=e;i.push(r),r+=s,u?i.push(r):i.splice(0,0,r),r+=s;switch(t){case"replaceFirst":i.push(i[0]),i[0]=u?r:f;break;case"replaceLast":u?i.splice(1,0,f):i.splice(1,0,r);break;case"prepend":i.push(f);break;case"append":i.push(r)}return i}}),lt=h.inherit({updatePositions:function(t){var i=this._panorama._itemElements(),u=this._calculateItemPositions(this._panorama.option("selectedIndex"),t<0);i.each(function(i){r(n(this),u[i]+t)})},animateRollback:function(){var i=this._panorama._itemElements(),t=this._panorama.option("selectedIndex"),e=this._calculateItemPositions(t),o=[t,this._normalizeIndex(t+1)];f(i.eq(t))>this._itemMargin()&&o.push(this._normalizeIndex(t-1)),i.each(function(t){var i=n(this);n.inArray(t,o)!==-1?u.itemMove(i,e[t]):r(i,e[t])})},detectBoundsTransition:function(n,t){var i=this._indexBoundary()-1;return t===i&&n===0?"left":t===0&&n===i?"right":void 0},animateComplete:function(t,i,f){var s=[],h=this._panorama._itemElements(),e=this._calculateItemPositions(i),o=this._normalizeIndex(f-1)===i,l=h.length===3&&o?this._normalizeIndex(f+1):null,a=e[this._indexBoundary()],c=[i,f],v=o?f:i;return o||c.push(this._normalizeIndex(v+1)),h.each(function(t){var i=n(this);if(n.inArray(t,c)===-1){r(i,e[t]);return}s.push(t!==l?u.itemMove(i,e[t]):u.itemMove(i,a,function(){r(i,e[t])}))}),n.when.apply(n,s)},_calculateItemPositions:function(n,t){for(var f=this._normalizeIndex(n-1),h=this._panorama._itemElements(),e=this._itemMargin(),o=h.eq(0).outerWidth(),s=o+e,i=[],c=-o,r=e,u=n;u!==f;u=this._normalizeIndex(u+1))i[u]=r,r+=s;return t?(i[f]=r,r+=s):i[f]=c,i.push(r),i}});o.registerComponent("dxPanorama",o.SelectableCollectionWidget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{selectedIndex:0,title:"panorama",backgroundImage:{url:null,width:0,height:0}})},_itemClass:function(){return a},_itemDataKey:function(){return nt},_itemContainer:function(){return this._$itemsContainer},_init:function(){this.callBase(),this._initItemsRenderStrategy(),this._initBackgroundImage(),this._initTitle(),this._initItemsContainer(),l.windowResizeCallbacks.add(this._windowResizeCallBack=n.proxy(this._handleWindowResize,this)),this._initSwipeHandlers()},_dispose:function(){this.callBase.apply(this,arguments),l.windowResizeCallbacks.remove(this._windowResizeCallBack)},_initItemsRenderStrategy:function(){var n;switch(this.option("items").length){case 0:case 1:n=ht;break;case 2:n=ct;break;default:n=lt}this._itemsRenderStrategy=new n(this),this._itemsRenderStrategy.init()},_initBackgroundImage:function(){var n=this.option("backgroundImage.url");n&&this._element().css("background-image","url("+n+")")},_initTitle:function(){this._$title=n("<div>").addClass(b),this._$ghostTitle=n("<div>").addClass(k),this._element().append(this._$title),this._element().append(this._$ghostTitle),this._updateTitle()},_updateTitle:function(){var n=this.option("title");this._$title.text(n),this._$ghostTitle.text(n),this._toggleGhostTitle(!1)},_toggleGhostTitle:function(n){var t=this._$ghostTitle;n?t.css("opacity",1):t.css("opacity",0)},_initItemsContainer:function(){this._$itemsContainer=n("<div>").addClass(d),this._element().append(this._$itemsContainer)},_handleWindowResize:function(){this._updatePositions()},_render:function(){this._element().addClass(w),this.callBase(),this._itemsRenderStrategy.render()},_updatePositions:function(n){n=n||0,this._updateBackgroundPosition(n*this._calculateBackgroundStep()),this._updateTitlePosition(n*this._calculateTitleStep()),this._itemsRenderStrategy.updatePositions(n*this._$itemsContainer.width())},_updateBackgroundPosition:function(n){y(this._element(),this._calculateBackgroundPosition(this.option("selectedIndex"))+n)},_updateTitlePosition:function(n){r(this._$title,this._calculateTitlePosition(this.option("selectedIndex"))+n)},_animateRollback:function(n){this._animateBackgroundMove(n),this._animateTitleMove(n),this._itemsRenderStrategy.animateRollback(n)},_animateBackgroundMove:function(n){return u.backgroundMove(this._element(),this._calculateBackgroundPosition(n))},_animateTitleMove:function(n){return u.titleMove(this._$title,this._calculateTitlePosition(n))},_animateComplete:function(t,i){var r=this,u=this._itemsRenderStrategy.detectBoundsTransition(t,i),f=this._performBackgroundAnimation(u,t),e=this._performTitleAnimation(u,t),o=this._itemsRenderStrategy.animateComplete(u,t,i);n.when(f,e,o).done(function(){r._indexChangeOnAnimation=!0,r.option("selectedIndex",t),r._indexChangeOnAnimation=!1})},_performBackgroundAnimation:function(n,t){return n?this._animateBackgroundBoundsTransition(n,t):this._animateBackgroundMove(t)},_animateBackgroundBoundsTransition:function(n,t){var r=this,f=n==="left",i=this._calculateBackgroundPosition(t),e=f?-this._calculateBackgroundScaledWidth():this._calculateBackgroundScaledWidth(),o=i+e;return u.backgroundMove(this._element(),o,function(){y(r._element(),i)})},_performTitleAnimation:function(n,t){return n?this._animateTitleBoundsTransition(n,t):this._animateTitleMove(t)},_animateTitleBoundsTransition:function(t,i){var l=this,f=this._$ghostTitle,o=f.outerWidth(),e=this._element().width(),s=t==="left",a=s?e:-o,v=s?-(e+o):e,h,c;return r(f,a),this._toggleGhostTitle(!0),this._swapGhostWithTitle(),h=u.titleMove(f,v,function(){l._toggleGhostTitle(!1)}),c=u.titleMove(this._$title,this._calculateTitlePosition(i)),n.when(h,c)},_swapGhostWithTitle:function(){var n=this._$ghostTitle,t=this._$title,i=f(t);r(t,f(n)),r(n,i)},_calculateTitlePosition:function(n){var t=this._element().width(),i=t*it;return i-n*this._calculateTitleStep()},_calculateTitleStep:function(){var i=this._element().width(),n=this._$title.outerWidth(),t=this._indexBoundary()||1;return Math.max((n-i)/t,n/t)},_calculateBackgroundPosition:function(n){return-(n*this._calculateBackgroundStep())},_calculateBackgroundStep:function(){var n=this._itemElements().eq(0).outerWidth(),t=this._calculateBackgroundScaledWidth();return Math.max((t-n)/(this._indexBoundary()||1),0)},_calculateBackgroundScaledWidth:function(){return this._element().height()*this.option("backgroundImage.width")/(this.option("backgroundImage.height")||1)},_initSwipeHandlers:function(){this._element().on(s.addNamespace("dxswipestart",this.NAME),n.proxy(this._swipeStartHandler,this)).on(s.addNamespace("dxswipe",this.NAME),n.proxy(this._swipeUpdateHandler,this)).on(s.addNamespace("dxswipeend",this.NAME),n.proxy(this._swipeEndHandler,this))},_swipeStartHandler:function(n){this._stopAnimations(),(this.option("disabled")||this._indexBoundary()<=1)&&(n.cancel=!0)},_stopAnimations:function(){p([this._element(),this._$ghostTitle,this._$title]),p(this._itemsRenderStrategy.allItemElements())},_swipeUpdateHandler:function(n){this._updatePositions(n.offset)},_swipeEndHandler:function(n){var t=this.option("selectedIndex"),i=n.targetOffset;i===0?this._animateRollback(t):this._animateComplete(this._normalizeIndex(t-i),t)},_renderSelectedIndex:function(){this._indexChangeOnAnimation||this._updatePositions()},_normalizeIndex:function(n){var t=this._indexBoundary();return n<0&&(n=t+n),n>=t&&(n=n-t),n},_indexBoundary:function(){return this.option("items").length},_optionChanged:function(n){switch(n){case"title":this._updateTitle();break;case"items":this._initItemsRenderStrategy(),this.callBase.apply(this,arguments);break;default:this.callBase.apply(this,arguments)}},_itemRenderDefault:function(t,i,r){if(this.callBase(t,i,r),t.header){var u=n("<div>").addClass(g).text(t.header);r.prepend(u)}}}))}(jQuery,DevExpress),function(n,t,i){var r=t.ui,y=r.events,e=t.fx,u=t.utils,o=t.translator,s="dx-slideout",h="dx-slideout-item-container",c="dx-slideout-menu",f="dx-slideout-item",l="dxSlideoutItemData",a=45,v=400;r.registerComponent("dxSlideOut",r.SelectableCollectionWidget.inherit({_defaultOptions:function(){return n.extend(this.callBase(),{menuItemRender:null,menuItemTemplate:"menuItem",swipeEnabled:!0,menuVisible:!1})},_itemClass:function(){return f},_itemDataKey:function(){return l},_init:function(){this.callBase(),this._deferredAnimate=i},_render:function(){this._$shield=n("<div />").addClass("dx-slideout-shield"),this._renderItemsContainer(),this._renderList(),this._initSwipeHandlers(),this._element().addClass(s),this.callBase(),this._initWindowResizeCallback(),this._renderPosition(this.option("menuVisible")?1:0,!1)},_initWindowResizeCallback:function(){var n=this;this._windowResizeCallback=function(){n._renderPosition(n.option("menuVisible")?1:0,!1)},u.windowResizeCallbacks.add(this._windowResizeCallback)},_renderItemsContainer:function(){this._$container=n("<div />").addClass(h).appendTo(this._element());this._$container.on("MSPointerDown",function(){})},_renderContentImpl:function(){var t=this.option("items"),i=this.option("selectedIndex");t.length&&i>-1&&this._renderItems([t[i]])},_renderList:function(){this._$list=n("<div />").addClass(c).prependTo(this._element()),this._renderItemClickAction();var t=this._$list.dxList().dxList("instance");t.addExternalTemplate(this._templates),this._$list.dxList({height:"100%",itemClickAction:n.proxy(this._handleListItemClick,this),items:this.option("items"),dataSource:this.option("dataSource"),itemRender:this.option("menuItemRender"),itemTemplate:this.option("menuItemTemplate")})},_handleListItemClick:function(n){var t=this._$list.find(".dx-list-item").index(n.itemElement);this.option("selectedIndex",t),this._itemClickAction(n)},_renderItemClickAction:function(){this._itemClickAction=this._createActionByOption("itemClickAction")},_renderItem:function(n,t){this._$container.find("."+f).remove(),this.callBase(n,t,this._$container)},_renderSelectedIndex:function(){this._renderContent()},_initSwipeHandlers:function(){this._$container.dxSwipeable({elastic:!1,itemSizeFunc:n.proxy(this._getListWidth,this),startAction:n.proxy(this.option("swipeEnabled")?this._handleSwipeStart:function(n){n.jQueryEvent.cancel=!0},this),updateAction:n.proxy(this._handleSwipeUpdate,this),endAction:n.proxy(this._handleSwipeEnd,this)})},_handleSwipeStart:function(n){this._$shield.detach(),n.jQueryEvent.maxLeftOffset=this.option("menuVisible")?1:0,n.jQueryEvent.maxRightOffset=this.option("menuVisible")?0:1},_handleSwipeUpdate:function(n){var t=this.option("menuVisible")?n.jQueryEvent.offset+1:n.jQueryEvent.offset;this._renderPosition(t,!1)},_handleSwipeEnd:function(n){var t=n.jQueryEvent.targetOffset+this.option("menuVisible"),i=t!==0;this.option("menuVisible")===i?this._renderPosition(this.option("menuVisible")?1:0,!0):this.option("menuVisible",t!==0)},_handleMenuButtonClick:function(){this.option("menuVisible",!this.option("menuVisible"))},_toggleMenuVisibility:function(n){this.option("menuVisible",n)},_renderPosition:function(t,i){var r=this._calculatePixelOffset(t);i?(this._$shield.detach(),e.animate(this._$container,{type:"slide",to:{left:r},duration:v,complete:n.proxy(this._handleAnimationComplete,this)})):o.move(this._$container,{left:r})},_calculatePixelOffset:function(n){var n=n||0,t=this._getListWidth();return n*t},_getListWidth:function(){var n=this._$list.width(),t=this._element().width()-a;return Math.min(t,n)},_changeMenuOption:function(n,t){this._$list.dxList("instance").option(n,t)},_optionChanged:function(n,t,i){switch(n){case"menuVisible":this._renderPosition(t?1:0,!0);break;case"swipeEnabled":this._initSwipeHandlers();break;case"menuItemRender":this._changeMenuOption("itemRender",t);break;case"menuItemTemplate":this._changeMenuOption("itemTemplate",t);break;case"items":case"dataSource":this._changeMenuOption(n,t);break;case"itemClickAction":this._renderItemClickAction();break;default:this.callBase(n,t,i)}},_handleAnimationComplete:function(){this._$shield.appendTo(this._$container),this._deferredAnimate&&this._deferredAnimate.resolveWith(this)},_dispose:function(){u.windowResizeCallbacks.remove(this._windowResizeCallback),this.callBase()},showMenu:function(){return this.toggleMenuVisibility(!0)},hideMenu:function(){return this.toggleMenuVisibility(!1)},toggleMenuVisibility:function(t){return t=t===i?!this.option("menuVisible"):t,this._deferredAnimate=n.Deferred(),this.option("menuVisible",t),this._deferredAnimate.promise()}}))}(jQuery,DevExpress),DevExpress.MOD_WIDGETS=!0}