text: /**
   * Released on: 2016-3-9
   * =====================================================
   * Native v1.0.2 (http://docs.369cloud.com/engine/jssdk/JS-SDK)
   * =====================================================
   */
  var app=function(e){for(var t={version:"1.0.2"},n={},i=n.toString,o="Boolean Number String Function Array Date RegExp Object Error".split(" "),r=0;r<o.length;r++)name=o[r],n["[object "+name+"]"]=name.toLowerCase();var a=!!e.rd,c=function(e,t,n,i,o){var r=e;return app.log.error(r),r="Line: "+n,app.log.error(r),r="resource: "+t,app.log.error(r),r="column: "+i,app.log.error(r),!1},u=function(e){var t=new RegExp("(^|&)"+e+"=([^&]*)(&|$)","i"),n=window.location.search.substr(1).match(t);return null!=n?n[2]:null},s=function(n,i){var o=u("pageId");i||(i=function(){}),t.isFunction(n)&&((t.android||t.ios)&&a?setTimeout(function(){s.isReady?n.call(e,i):setTimeout(arguments.callee,1)},1):o?(t.debug(),setTimeout(function(){t.debug.isReady?n.call(e,i):setTimeout(arguments.callee,1)},1)):n.call(e,i))};e.onLoad=function(){if(window.onerror){var n=window.onerror;window.onerror=function(){n.call(e,arguments),c.apply(e,Array.prototype.slice.call(arguments))}}else window.onerror=c;s.isReady=!0,t.init()},e.domReady=s;var d="rd",f=e[d],l=0,p=0,v=11,w=41,h=300,g=53,S=!1,x="",m=!1,y=!0,b=!1,J=!1,N=11,F=40,A=300,C=53,E=function(e){S=!!e;var n=t.currentView();S?n.enableBounces():n.disableBounces()},O=function(e){m=!!e;var n=t.currentView();m?n.enableVScrollBar():n.disableVScrollBar()},P=function(e){y=!!e;var n=t.currentView();y?n.enableHScrollBar():n.disableHScrollBar()},k=function(e){b=!!e;var n=t.currentView();b?n.enableKeyboard():n.disableKeyboard()},T=function(e){J=!!e;var n=t.currentView();J?n.enableDragDismiss():n.disableDragDismiss()},j=function(e){x=e;var n=t.currentView();n.setBgcolor(x)},L=function(e){N=e;var n=t.currentView();n.setAnimationType(N)},D=function(e){F=e;var n=t.currentView();n.setAnimationDirection(F)},R=function(e){A=e;var n=t.currentView();n.setAnimationDuration(A)},B=function(e){C=e;var n=t.currentView();n.setAnimationCurve(C)},I=function(e){return null==e?String(e):n[i.call(e)]||"object"},$=function(e){return null!=e&&e==e.window},V=function(e){return"object"==I(e)},H=function(e){return"number"==typeof e.length};t.type=I,t.isPlainObject=function(e){return V(e)&&!$(e)&&Object.getPrototypeOf(e)==Object.prototype},t.isFunction=function(e){return"function"==I(e)},t.isString=function(e){return"string"==I(e)},t.isArray=Array.isArray||function(e){return e instanceof Array},t.android=function(){return"Android"==t.os.getName()},t.ios=function(){return"iOS"==t.os.getName()},t.each=function(e,t){var n,i;if(H(e)){for(n=0;n<e.length;n++)if(t.call(e[n],n,e[n])===!1)return e}else for(i in e)if(t.call(e[i],i,e[i])===!1)return e;return e},t.throwError=function(e){throw new Error(e)};var W=function(e){var n=f,i=f;return t.isArray(e)&&t.each(e,function(e,t){n&&t&&(i=n,n=n[t])}),{fun:n,callObj:i}};return t.executeNativeJS=function(){var e=Array.prototype.slice.call(arguments,1),n=W(arguments[0]);return t.isFunction(n.fun)?n.fun.apply(n.callObj,e):void 0},t.executeRequireJS=function(){var e=Array.prototype.slice.call(arguments);if(f){var n=f.require;if(t.isFunction(n))return n.apply(f,e)}},t.executeObjFunJS=function(){var e=Array.prototype.slice.call(arguments,1),n=arguments[0][0],i=n;return n&&(n=n[arguments[0][1]]),t.isFunction(n)?n.apply(i,e):void 0},t.executeConstantJS=function(){var e=W(arguments[0]);return"undefined"!=typeof e.fun?e.fun:void 0},t.executeObjConstantJS=function(){var e=arguments[0];return"undefined"!=typeof e?e[arguments[1]]:void 0},t.init=function(){var e=app.properties.open("app_property_setting","app_property"),t=e.get("propertys");if(t){var n=JSON.parse(t);this.config(n)}else{var n={};n.windowType=l,n.popoverType=p,n.windowAnimationType=v,n.windowAnimationDirection=w,n.windowAnimationDuration=h,n.windowAnimationCurve=g,n.viewBounces=S,n.viewBgcolor=x,n.viewVScrollBar=m,n.viewHScrollBar=y,n.viewKeyboard=b,n.viewDragDismiss=J,n.viewAnimationType=N,n.viewAnimationDirection=F,n.viewAnimationDuration=A,n.viewAnimationCurve=C,this.config(n)}},t.config=function(e){if(e){e.windowType&&(l=e.windowType),e.popoverType&&(p=e.popoverType),e.windowAnimationType&&(v=e.windowAnimationType),e.windowAnimationDirection&&(w=e.windowAnimationDirection),e.windowAnimationDuration&&(h=e.windowAnimationDuration),e.windowAnimationCurve&&(g=e.windowAnimationCurve),e.viewAnimationType&&L(e.viewAnimationType),e.viewAnimationDirection&&D(e.viewAnimationDirection),e.viewAnimationDuration&&R(e.viewAnimationDuration),e.viewAnimationCurve&&B(e.viewAnimationCurve),e.viewBgcolor&&j(e.viewBgcolor),E("undefined"==typeof e.viewBounces?S:e.viewBounces),O("undefined"==typeof e.viewVScrollBar?m:e.viewVScrollBar),P("undefined"==typeof e.viewHScrollBar?y:e.viewHScrollBar),k("undefined"==typeof e.viewKeyboard?b:e.viewKeyboard),T("undefined"==typeof e.viewDragDismiss?J:e.viewDragDismiss);var t=app.properties.open("app_property_setting","app_property");e=JSON.stringify(e),t.put("propertys",e),t.save()}},t.closeWindow=function(e,n){n||(n={});var i={type:n.animationType||N,direction:n.animationDirection||F,time:n.animationDuration||A,curve:n.animationCurve||C};t.executeNativeJS(["window","closeWindow"],e,i)},t.getWindowType=function(){return l},t.getPopoverType=function(){return p},t.getWindowAnimationType=function(){return v},t.getWindowAnimationDirection=function(){return w},t.getWindowAnimationDuration=function(){return h},t.getWindowAnimationCurve=function(){return g},t.getViewBounces=function(){return S},t.getViewBgcolor=function(){return x},t.getViewVScrollBar=function(){return m},t.getViewHScrollBar=function(){return y},t.getViewKeyboard=function(){return b},t.getViewDragDismiss=function(){return J},t.getViewAnimationType=function(){return N},t.getViewAnimationDirection=function(){return F},t.getViewAnimationDuration=function(){return A},t.getViewAnimationCurve=function(){return C},t.getViewAnimationCurve=function(){return C},t.addSlideDrawer=function(e,n,i){var o=/^[0-9]{1,20}$/;if("undefined"==typeof e)t.throwError("请传入有效的抽屉页面路径！");else if(t.isPlainObject(e)){var r=e.url;"undefined"==typeof r?t.throwError("请传入有效的抽屉页面路径！"):(n=e.type,i=e.edge,e=r)}if(o.test(i)||(i=50),"right"==n){var a={type:"right",leftEdge:i,rightEdge:i,rightPane:{name:e,url:e}};t.executeNativeJS(["window","setSlideLayout"],a)}else{var a={type:"left",leftEdge:i,rightEdge:i,leftPane:{name:e,url:e}};t.executeNativeJS(["window","setSlideLayout"],a)}},t.openLeftSlideDrawer=function(){var e={type:"left"};t.executeNativeJS(["window","openSlidePane"],e)},t.openRightSlideDrawer=function(){var e={type:"right"};t.executeNativeJS(["window","openSlidePane"],e)},t.closeSlideDrawer=function(){t.executeNativeJS(["window","closeSlidePane"])},t.evalScriptInComponent=function(e,n,i,o){"undefined"==typeof e?t.throwError("请传入有效的componentName！"):"undefined"==typeof n?t.throwError("请传入有效的windowName！"):"undefined"==typeof i&&t.throwError("请传入有效的JS语句！"),"undefined"==typeof o?t.executeNativeJS(["window","evaluateScript"],e,n,"",i):t.executeNativeJS(["window","evaluateScript"],e,n,o,i)},t.evalScriptInWindow=function(e,n){"undefined"==typeof e?t.throwError("请传入有效的JS语句！"):"undefined"==typeof n?t.executeNativeJS(["window","evaluateScript"],"","","",e):t.executeNativeJS(["window","evaluateScript"],"",n,"",e)},t.evalScriptInPop=function(e,n,i){"undefined"==typeof e?t.throwError("请传入有效的JS语句！"):"undefined"==typeof n?t.throwError("请传入有效的popoverName！"):"undefined"==typeof i?t.executeNativeJS(["window","evaluateScript"],"","",n,e):t.executeNativeJS(["window","evaluateScript"],"",i,n,e)},t.lockRotate=function(){t.executeNativeJS(["window","lockRotate"],!0)},t.unLockRotate=function(){t.executeNativeJS(["window","lockRotate"],!1)},t.alert=function(e,n,i,o){if("undefined"==typeof e)t.throwError("请传入有效消息内容！");else if(t.isPlainObject(e)){var r=e.message;"undefined"==typeof r?t.throwError("请传入有效消息内容！"):(n=e.title,i=e.btnCaption,o=e.callback,e=r)}else t.isFunction(n)?(o=n,n="消息提示",i="确定"):t.isFunction(i)&&(o=i,i="确定");var a={title:n||"消息提示",msg:e,buttons:[i||"确定"]};t.executeNativeJS(["window","alert"],a,function(){t.isFunction(o)&&o.call()})},t.confirm=function(n,i,o,r){if("undefined"==typeof n)t.throwError("请传入有效消息内容！");else if(t.isPlainObject(n)){var a=n.message;"undefined"==typeof a?t.throwError("请传入有效消息内容！"):(i=n.title,o=n.btnCaptions,r=n.callback,n=a)}else t.isFunction(i)?(r=i,i="消息提示",o=["确认","放弃","取消"]):t.isFunction(o)&&(r=o,o=["确认","放弃","取消"]);var c={title:i||"消息提示",msg:n,buttons:o||["确认","放弃","取消"]};t.executeNativeJS(["window","confirm"],c,function(n){t.isFunction(r)&&r.call(e,n.buttonIndex)})},t.prompt=function(n,i,o,r,a,c){if("undefined"==typeof n)t.throwError("请传入有效消息内容！");else if(t.isPlainObject(n)){var u=n.message;"undefined"==typeof u?t.throwError("请传入有效消息内容！"):(i=n.title,o=n.btnCaptions,r=n.inputValue,a=n.inputTpye,c=n.callback,n=u)}else t.isFunction(i)?(c=i,i="消息提示",o=["确认","放弃","取消"],r="",a="text"):t.isFunction(o)?(c=o,o=["确认","放弃","取消"],r="",a="text"):t.isFunction(r)?(c=r,r="",a="text"):t.isFunction(a)&&(c=a,a="text");var s={title:i||"消息提示",msg:n,text:r||"",type:a||"text",buttons:o||["确认","放弃","取消"]};t.executeNativeJS(["window","prompt"],s,function(n,i){t.isFunction(c)&&c.call(e,n.buttonIndex,n.text,i)})},t}(this);window.app=app,void 0===window.A&&(window.A=app),function(e,t){e.enableSlideBack=function(){var t=!0;e.executeNativeJS(["window","setAttr"],{slideBack:t})},e.disableSlideBack=function(){var t=!1;e.executeNativeJS(["window","setAttr"],{slideBack:t})},e.getPlatformName=function(){return e.executeConstantJS(["app","platformName"])},e.getPlatformVersion=function(){return e.executeConstantJS(["app","platformVersion"])},e.getDeviceModel=function(){return e.executeConstantJS(["app","deviceModel"])},e.getDeviceName=function(){return e.executeConstantJS(["app","deviceName"])},e.downloadFile=function(t){e.executeNativeJS(["app","downloadFile"],t)},e.exit=function(){e.executeNativeJS(["app","exit"])},e.statusBarFontColor=function(t){t||(t=0),e.executeNativeJS(["app","setStatusBarStyle"],t)},e.installApp=function(t){e.executeNativeJS(["app","installApp"],t)},e.getEngineVersion=function(){return e.executeNativeJS(["app","getEngineVersion"])},e.getApplicationInfo=function(){return e.executeNativeJS(["app","getApplicationInfo"])},e.openApp=function(n,i,o){e.executeNativeJS(["app","openApp"],n,function(n,r){1==n?e.isFunction(i)&&i.call(t,r):0==n&&e.isFunction(o)&&o.call(t)})},e.isAppInstalled=function(n,i){e.executeNativeJS(["app","isAppInstalled"],n,function(n){e.isFunction(i)&&i.call(t,n)})},e.isFullScreen=function(){return e.executeNativeJS(["app","isFullScreen"])},e.setStatusBarBackgroundColor=function(t){e.executeNativeJS(["app","setStatusBarBackgroundColor"],t)},e.cleanCache=function(){e.executeNativeJS(["app","cleanCache"])}}(app,this),function(e,t){e.openComponent=function(t,n){e.executeNativeJS(["window","openComponent"],t,"",n)},e.closeCurrentComponent=function(t){e.executeNativeJS(["component","closeComponent"],"",t)},e.closeComponent=function(t,n){"undefined"==typeof t&&e.throwError("请传入有效的componentName！"),e.executeNativeJS(["component","closeComponent"],t,n)},e.getMainComponentInfo=function(){return e.executeNativeJS(["component","getMainComponentInfo"])},e.getComponentInfoByName=function(t){return e.executeNativeJS(["component","getComponentInfoByName"],t)},e.getCurrentComponentInfo=function(){return e.executeNativeJS(["component","getCurrentComponentInfo"])}}(app,this),function(e,t){var n=function(){var t,n=e.getWindowType(),i=e.getWindowAnimationType(),o=e.getWindowAnimationDirection(),r=e.getWindowAnimationDuration(),a=e.getWindowAnimationCurve();this.open=function(c,u){"undefined"==typeof c&&e.throwError("请传入有效的url路径！"),t=u||c;var s={type:i,direction:o,time:r,curve:a};e.executeNativeJS(["window","openWindow"],t,n,c,s)},this.setType=function(e){n=e},this.setAnimationType=function(e){i=e},this.setAnimationDirection=function(e){o=e},this.setAnimationDuration=function(e){r=e},this.setAnimationCurve=function(e){a=e},this.evalScript=function(n){"undefined"==typeof n?e.throwError("请传入有效的JS语句！"):"undefined"==typeof t?e.throwError("无法在未打开的window窗口中执行JS语句！"):e.executeNativeJS(["window","evaluateScript"],"",t,"",n)},this.evalScriptInPop=function(n,i){"undefined"==typeof n?e.throwError("请传入有效的JS语句！"):"undefined"==typeof t?e.throwError("无法在未打开的window窗口中执行JS语句！"):"undefined"==typeof i?e.throwError("请传入有效的popoverName！"):e.executeNativeJS(["window","evaluateScript"],"",t,i,n)}};e.createWindow=function(){return new n}}(app,this),function(e,t){var n=function(){var t=e.getViewAnimationType(),n=e.getViewAnimationDirection(),i=e.getViewAnimationDuration(),o=e.getViewAnimationCurve(),r=!1,a=!1;this.enableBounces=function(){var t=!0;e.executeNativeJS(["window","setAttr"],{bounces:t})},this.disableBounces=function(){var t=!1;e.executeNativeJS(["window","setAttr"],{bounces:t})},this.setBgcolor=function(t){e.executeNativeJS(["window","setAttr"],{bgColor:t})},this.enableVScrollBar=function(){var t=!0;e.executeNativeJS(["window","setAttr"],{vScrollBarEnabled:t})},this.disableVScrollBar=function(){var t=!1;e.executeNativeJS(["window","setAttr"],{vScrollBarEnabled:t})},this.enableHScrollBar=function(){var t=!0;e.executeNativeJS(["window","setAttr"],{hScrollBarEnabled:t})},this.disableHScrollBar=function(){var t=!1;e.executeNativeJS(["window","setAttr"],{hScrollBarEnabled:t})},this.enableKeyboard=function(){var t=!0;e.executeNativeJS(["window","setAttr"],{keyboard:t})},this.disableKeyboard=function(){var t=!1;e.executeNativeJS(["window","setAttr"],{keyboard:t})},this.enableDragDismiss=function(){var t=!0;e.executeNativeJS(["window","setAttr"],{dragDismiss:t})},this.disableDragDismiss=function(){var t=!1;e.executeNativeJS(["window","setAttr"],{dragDismiss:t})},this.setAnimationType=function(e){t=e},this.setAnimationDirection=function(e){n=e},this.setAnimationDuration=function(e){i=e},this.setAnimationCurve=function(e){o=e},this.back=function(r){var a={type:t,direction:n,time:i,curve:o};"undefined"==typeof r?this.close():e.executeNativeJS(["window","backToWindow"],r,a)},this.getWidth=function(){return e.executeNativeJS(["window","getWidth"])},this.getHeight=function(){return e.executeNativeJS(["window","getHeight"])},this.addSlideIgnore=function(t,n,i,o){i=i||this.getWidth(),n=n||0,o?(o*=window.devicePixelRatio,n*=window.devicePixelRatio):(o=this.getHeight(),e.android()&&(n*=window.devicePixelRatio,o-=n));var r={x:t||0,y:n||0,width:i,height:o};e.executeNativeJS(["window","addIgnoreArea"],r)},this.addHeaderRefresh=function(t){r=!0;var n={contentdown:"下拉可以刷新",contentover:"释放立即刷新",contentrefresh:"正在刷新..."},i={statusLabel:{pullText:t.contentdown||n.contentdown,releaseText:t.contentover||n.contentover,refreshingText:t.contentrefresh||n.contentrefresh}},o=t.callback,a={setContentFontSize:function(t){r&&(i.statusLabel.font=t,e.executeNativeJS(["window","addHeaderRefreshing"],function(){e.isFunction(o)&&o.call()},i))},setContentFontColor:function(t){r&&(i.statusLabel.color=t,e.executeNativeJS(["window","addHeaderRefreshing"],function(){e.isFunction(o)&&o.call()},i))},setTimeFontSize:function(t){r&&(i.timeLabel=i.timeLabel||{},i.timeLabel.font=t,e.executeNativeJS(["window","addHeaderRefreshing"],function(){e.isFunction(o)&&o.call()},i))},setTimeFontColor:function(t){r&&(i.timeLabel=i.timeLabel||{},i.timeLabel.color=t,e.executeNativeJS(["window","addHeaderRefreshing"],function(){e.isFunction(o)&&o.call()},i))},setImagePath:function(t){r&&(i.image=t,e.executeNativeJS(["window","addHeaderRefreshing"],function(){e.isFunction(o)&&o.call()},i))},completeRefresh:function(){r&&e.executeNativeJS(["window","endHeaderRefresh"])}};return e.executeNativeJS(["window","addHeaderRefreshing"],function(){e.isFunction(o)&&o.call()},i),a},this.addFooterRefresh=function(t){a=!0;var n={contentdown:"上拉显示更多",contentover:"释放立即刷新",contentrefresh:"正在加载..."},i={statusLabel:{pullText:t.contentdown||n.contentdown,releaseText:t.contentover||n.contentover,refreshingText:t.contentrefresh||n.contentrefresh}},o=t.callback,r={setContentFontSize:function(t){a&&(i.statusLabel.font=t,e.executeNativeJS(["window","addFooterRefreshing"],function(){e.isFunction(o)&&o.call()},i))},setContentFontColor:function(t){a&&(i.statusLabel.color=t,e.executeNativeJS(["window","addFooterRefreshing"],function(){e.isFunction(o)&&o.call()},i))},setImagePath:function(t){a&&(i.image=t,e.executeNativeJS(["window","addFooterRefreshing"],function(){e.isFunction(o)&&o.call()},i))},completeRefresh:function(){a&&e.executeNativeJS(["window","endFooterRefresh"])}};return e.executeNativeJS(["window","addFooterRefreshing"],function(){e.isFunction(o)&&o.call()},i),r},this.removeFooterRefresh=function(){r=!1,e.executeNativeJS(["window","removeFooterRefreshing"])},this.removeHeaderRefresh=function(){a=!1,e.executeNativeJS(["window","removeHeaderRefreshing"])},this.setFrameSize=function(t,n,i,o){i=i||this.getWidth(),o=o||this.getHeight(),e.android()&&(n*=window.devicePixelRatio,o*=window.devicePixelRatio);var r={x:t||0,y:n||0,width:i,height:o};e.executeNativeJS(["window","setPopoverRect"],r)},this.closePopover=function(t){t&&e.executeNativeJS(["window","closePopover"],t)},this.close=function(){var r={type:t,direction:n,time:i,curve:o};e.executeNativeJS(["window","closeSelf"],r)}},i=new n;e.currentView=function(){return i}}(app,this),function(e,t){e.accelerometer={getCurrentAcceleration:function(n,i){e.executeNativeJS(["accelerometer","getCurrentAcceleration"],function(i){e.isFunction(n)&&n.call(t,i)},function(n){e.isFunction(i)&&i.call(t,n)})},watchAcceleration:function(n,i,o){"undefined"==typeof o&&(o={frequency:500}),e.executeNativeJS(["accelerometer","watchAcceleration"],function(i){e.isFunction(n)&&n.call(t,i)},function(n){e.isFunction(i)&&i.call(t,n)},o)},clearWatch:function(){e.executeNativeJS(["accelerometer","clearWatch"])}}}(app,this),function(e,t){e.actionSheet={show:function(n,i){e.executeNativeJS(["actionSheet","show"],n,function(n){e.isFunction(i)&&i.call(t,n)})}}}(app,this),function(e,t){var n=!1,i=!1;e.audio={getRecorder:function(o){var r=e.executeNativeJS(["audio","getRecorder"]);o=o||{};var a={filename:o.filename||"",samplerate:o.samplerate||8e3,format:o.format||"aac",duration:o.duration};return{record:function(o,c){n&&e.throwError("当前正在录音，请等待录音完成后再进行新的录音操作！"),e.executeObjFunJS([r,"record"],a,function(n){e.isFunction(o)&&o.call(t,n)},function(n){e.isFunction(c)&&c.call(t,n)}),n=!0,i=!1},getCurrentTime:function(){n||e.throwError("先执行录音操作后，才可获取当前录音时间！");var t=e.executeObjFunJS([r,"getCurrentTime"]);return t?t:0},getDuration:function(){var e=a.duration;return e?e:-1},addCalculateTimeCallback:function(n){e.executeObjFunJS([r,"addCalculateTimeCallback"],function(i){e.isFunction(n)&&n.call(t,i)})},addCountDownCallback:function(n){e.executeObjFunJS([r,"addCountDownCallback"],function(i){e.isFunction(n)&&n.call(t,i)})},addAveragePowerCallback:function(n){e.executeObjFunJS([r,"addAveragePowerCallback"],function(i){e.isFunction(n)&&n.call(t,i)})},playJustRecord:function(){i||e.throwError("先执行录音操作后，并录音完成后，才可执行播放录音操作！"),e.executeObjFunJS([r,"playJustRecord"])},stop:function(){n||e.throwError("先执行录音操作后，才可执行录音结束操作！"),e.executeObjFunJS([r,"stop"]),n=!1,i=!0}}},createPlayer:function(n){void 0===typeof n&&e.throwError("请传入有效的音频路径！");var i=e.executeNativeJS(["audio","createPlayer"],n);return{play:function(n,o){e.executeObjFunJS([i,"play"],function(){e.isFunction(n)&&n.call()},function(n){e.isFunction(o)&&o.call(t,n)})},pause:function(){e.executeObjFunJS([i,"pause"])},resume:function(){e.executeObjFunJS([i,"resume"])},stop:function(){e.executeObjFunJS([i,"stop"])},seekTo:function(t){void 0===typeof n&&e.throwError("请传入有效的播放时间戳！"),e.executeObjFunJS([i,"seekTo"],t)},getDuration:function(){return e.executeObjFunJS([i,"getDuration"])},getPosition:function(){return e.executeObjFunJS([i,"getPosition"])},setRoute:function(t){void 0===typeof t&&e.throwError("请传入有效的音频输出线路！"),t=1==t?e.executeConstantJS(["audio","ROUTE_EARPIECE"]):e.executeConstantJS(["audio","ROUTE_SPEAKER"]),e.executeObjFunJS([i,"setRoute"],t)},isPlaying:function(){return e.executeObjFunJS([i,"isPlaying"])},addFinishCallback:function(n){return e.executeObjFunJS([i,"addFinishCallback"],function(){e.isFunction(n)&&n.call(t)})}}}}}(app,this),function(e,t){var n=1,i=1,o=function(o,r,a){this.captureImage=function(i,c){var u=n++,s=o+"photo_"+u+".jpg",d={filename:s,resolution:r,index:a};e.executeNativeJS(["camera","captureImage"],function(n){e.isFunction(i)&&setTimeout(function(){i.call(t,n)},1e3)},function(n){e.isFunction(c)&&setTimeout(function(){c.call(t,n)},1e3)},d)},this.captureVideo=function(n,c){var u=i++,s=o+"video_"+u+".mov",d={filename:s,resolution:r,index:a};e.executeNativeJS(["camera","captureVideo"],function(i){e.isFunction(n)&&setTimeout(function(){n.call(t,i)},1e3)},function(n){e.isFunction(c)&&setTimeout(function(){c.call(t,n)},1e3)},d)}};e.camera={getCamera:function(t,n,i){e.android()&&"undefined"==typeof t&&e.throwError("请传入有效的文件保存的路径！");var r;return 0==n?r=e.executeConstantJS(["camera","ResolutionTypeHigh"]):1==n?r=e.executeConstantJS(["camera","ResolutionTypeMedium"]):2==n?r=e.executeConstantJS(["camera","ResolutionTypeLow"]):3==n?r=e.executeConstantJS(["camera","ResolutionTypeIFrame640x480"]):4==n?r=e.executeConstantJS(["camera","ResolutionTypeIFrame1280x720"]):5==n&&(r=e.executeConstantJS(["camera","ResolutionTypeIFrame960x540"])),new o(t,r,i)}}}(app,this),function(e,t){var n=function(n){n=1==n?e.executeConstantJS(["contacts","ADDRESSBOOK_SIM"]):e.executeConstantJS(["contacts","ADDRESSBOOK_PHONE"]),this.create=function(i,o){e.executeNativeJS(["contacts","getAddressBook"],n,function(n){e.isFunction(i)&&i.call(t,n.create())},function(n){e.isFunction(o)&&o.call(t,n)})},this.find=function(i,o,r){e.executeNativeJS(["contacts","getAddressBook"],n,function(n){n.find(function(n){e.isFunction(o)&&(n=n||[],o.call(t,n))},function(n){e.isFunction(r)&&r.call(t,n)},i)},function(n){e.isFunction(r)&&r.call(t,n)})}};e.contacts={getAddressBook:function(e){return 1!=e&&(e=0),new n(e)}}}(app,this),function(e,t){var n=function(t){var n=e.executeNativeJS(["dataBase","open"],t);this.executeSql=function(t){return void 0===typeof t&&e.throwError("请传入有效的sql语句！"),e.executeObjFunJS([n,"executeSql"],t)},this.close=function(){return e.executeObjFunJS([n,"close"])},this.deleteDataBase=function(){return e.executeObjFunJS([n,"deleteDataBase"])},this.selectAll=function(t){return void 0===typeof t&&e.throwError("请传入有效的sql语句！"),e.executeObjFunJS([n,"selectAll"],t)},this.beginTransaction=function(){e.executeObjFunJS([n,"beginTransaction"])},this.commit=function(){e.executeObjFunJS([n,"commit"])},this.rollback=function(){e.executeObjFunJS([n,"rollback"])}};e.dataBase={open:function(e){return new n(e)}}}(app,this),function(e,t){e.device={getImei:function(){return e.executeConstantJS(["device","imei"])},getImsi:function(){return e.executeConstantJS(["device","imsi"])},getModel:function(){return e.executeConstantJS(["device","model"])},getVendor:function(){return e.executeConstantJS(["device","vendor"])},getUuid:function(){return e.executeConstantJS(["device","uuid"])},dial:function(t,n){void 0===typeof t&&e.throwError("请传入有效的手机号码！"),n||(n=!1),e.executeNativeJS(["device","dial"],t,n)},beep:function(t){t||(t=1),e.executeNativeJS(["device","beep"],t)},vibrate:function(t){t||(t=500),e.executeNativeJS(["device","vibrate"],t)},setWakeUp:function(){e.executeNativeJS(["device","setWakelock"],!0)},setWakeOff:function(){e.executeNativeJS(["device","setWakelock"],!1)},isWakelock:function(){return e.executeNativeJS(["device","isWakelock"])},setVolume:function(t){e.executeNativeJS(["device","setVolume"],t)},getVolume:function(){return e.executeNativeJS(["device","getVolume"])}}}(app,this),function(e,t){var n=function(n,i,o){var r=this;o||(o=e.executeNativeJS(["downloader","createDownload"],n,i)),this.getId=function(){return o?o.id:void 0},this.getUrl=function(){return o?o.url:void 0},this.getPath=function(){return o?o.filePath:void 0},this.getState=function(){return o?o.state:void 0},this.getOptions=function(){return o?o.option:{method:void 0,filePath:void 0,timeout:void 0,retry:void 0}},this.getDownloadedSize=function(){return o?o.downloadedSize:void 0},this.getTotalSize=function(){return o?o.totalSize:void 0},this.start=function(){e.executeObjFunJS([o,"start"])},this.pause=function(){e.executeObjFunJS([o,"pause"])},this.resume=function(){e.executeObjFunJS([o,"resume"])},this.abort=function(){e.executeObjFunJS([o,"abort"])},this.addEventListener=function(n){e.executeObjFunJS([o,"addEventListener"],function(i,o){e.isFunction(n)&&n.call(t,r,o)})},this.removeEventListener=function(){e.executeObjFunJS([o,"removeEventListener"])},this.addCompletedListener=function(n){e.executeObjFunJS([o,"addCompletedListener"],function(i,o){e.isFunction(n)&&n.call(t,r,o)})},this.removeCompletedListener=function(){e.executeObjFunJS([o,"removeCompletedListener"])}};e.downloader={createDownload:function(e,t){return new n(e,t)},clear:function(t){t||(t=-1),e.executeNativeJS(["downloader","clear"],t)},enumerate:function(t){t||(t=-1);var n=e.executeNativeJS(["downloader","enumerate"],t);return n&&e.isArray(n)?n:[]},getDownLoaderById:function(t){t||e.throwError("请传入有效的下载任务ID！");var i=e.executeNativeJS(["downloader","enumerateById"],t);return new n("","",i)},remove:function(t){e.executeNativeJS(["downloader","remove"],t)},setMaxRunningSize:function(t){e.executeNativeJS(["downloader","setMaxRunningSize"],t)},setSpeed:function(t){e.executeNativeJS(["downloader","setSpeed"],t)},startAll:function(){e.executeNativeJS(["downloader","startAll"])}}}(app,this),function(e,t){e.event={addEvent:function(n,i){"network_state_changed"==n?this.addNetWorkChangeEvent(i):"battery_state_changed"==n?this.addBatteryChangeEvent(i):e.executeNativeJS(["eventListener","addEventListener"],n,function(n){e.isFunction(i)&&i.call(t,n)})},removeEvent:function(t){e.executeNativeJS(["eventListener","removeEventListener"],t)},sendEvent:function(t,n){e.executeNativeJS(["eventListener","sendEvent"],t,n)},addNetworkChangeEvent:function(n){e.executeNativeJS(["eventListener","addEventListener"],"network_state_changed",function(i){e.isFunction(n)&&n.call(t,i.state)})},removeNetworkChangeEvent:function(t){e.executeNativeJS(["eventListener","removeEventListener"],"network_state_changed")},addBatteryChangeEvent:function(n){e.executeNativeJS(["eventListener","addEventListener"],"battery_state_changed",function(i){e.isFunction(n)&&n.call(t,i.state)})},removeBatteryChangeEvent:function(t){e.executeNativeJS(["eventListener","addEventListener"],"battery_state_changed")}}}(app,this),function(e,t){e.gallery={pick:function(n,i,o){var r={filter:"image",multiple:!0};e.isPlainObject(i)&&(o=i),o&&(o.multiple||(r.multiple=!1),"video"==o.filter&&(r.filter="video"),"none"==o.filter&&(r.filter="none")),e.executeNativeJS(["gallery","pick"],function(i){e.isFunction(n)&&n.call(t,i)},function(n){e.isFunction(i)&&i.call(t,n)},r)},save:function(n,i,o){e.executeNativeJS(["gallery","save"],n,function(n){e.isFunction(i)&&i.call(t,n)},function(n){e.isFunction(o)&&o.call(t,n)})}}}(app,this),function(e,t){e.geolocation={getCurrentPosition:function(n,i,o){e.isPlainObject(i)&&(o=i),e.executeNativeJS(["geolocation","getCurrentPosition"],function(i){e.isFunction(n)&&n.call(t,i)},function(n){e.isFunction(i)&&i.call(t,n)},o)},watchPosition:function(n,i,o){e.isPlainObject(i)&&(o=i),e.executeNativeJS(["geolocation","watchPosition"],function(i){e.isFunction(n)&&n.call(t,i)},function(n){e.isFunction(i)&&i.call(t,n)},o)},clearWatch:function(){e.executeNativeJS(["geolocation","clearWatch"])}}}(app,this),function(e,t){var n=function(){var n=!1,i=!1,o={},r=this;o.offline="undefined",o.expires=0,o.bodyType="text",this.open=function(t,i,r){"undefined"==typeof t&&e.throwError("请传入有效的请求地址！"),o.method=i||"GET",o.url=t,o.timeout=r||3e4,n=!0},this.send=function(a,c){i=!1,n||e.throwError("执行send方法失败，请确保请求对象为OPENDE状态！"),a&&e.isPlainObject(a)?o.body=JSON.stringify(a):o.body=a,o.dataType=c||"json",e.executeNativeJS(["httpManager","sendRequest"],o,function(n,o){r.onSuccess&&e.isFunction(r.onSuccess)&&!i&&r.onSuccess.call(t,o,n)},function(n,o,a){r.onError&&e.isFunction(r.onError)&&!i&&r.onError.call(t,a,n,o)})},this.postForm=function(a,c,u){i=!1,n||e.throwError("执行postForm方法失败，请确保请求对象为OPENDE状态！");var s={};a&&("string"==typeof a&&(a=JSON.parse(a)),s.values=a),u&&(s.files=u),o.form=s,o.dataType=c||"json",e.executeNativeJS(["httpManager","sendRequest"],o,function(n,o){r.onSuccess&&e.isFunction(r.onSuccess)&&!i&&r.onSuccess.call(t,o,n)},function(n,o,a){r.onError&&e.isFunction(r.onError)&&!i&&r.onError.call(t,a,n,o)})},this.abort=function(){i=!0},this.setHeader=function(t,i){n||e.throwError("执行setHeader方法失败，请确保请求对象为OPENDE状态！"),o.HTTPHeader?t&&i&&(o.HTTPHeader[t.toLowerCase()]=i):(o.HTTPHeader={},t&&i&&(o.HTTPHeader[t.toLowerCase()]=i))},this.setOffline=function(t){n||e.throwError("执行setOffline方法失败，请确保请求对象为OPENDE状态！"),"true"==t?o.offline="true":"false"==t?o.offline="false":"none"==t&&(o.offline="undefined")},this.setExpires=function(t){n||e.throwError("执行setExpires方法失败，请确保请求对象为OPENDE状态！"),t&&(o.expires=t)},this.setCertificate=function(t,i){n||e.throwError("执行setCertificate方法失败，请确保请求对象为OPENDE状态！"),o.certificate?(t&&(o.certificate.path=t),i&&(o.certificate.password=i)):(o.certificate={},t&&(o.certificate.path=t),i&&(o.certificate.password=i))}};e.http={XMLHttpRequest:function(){return new n},ajax:function(e,i){var o=new n;if(i){if(o.open(e,i.type,i.timeout),i.headers)for(name in i.headers)o.setHeader(name,i.headers[name]);o.setOffline(i.offline),o.setExpires(i.expires),i.certificate&&o.setCertificate(i.certificate.path,i.certificate.password),i.success&&"function"==typeof i.success&&(o.onSuccess=function(e,n){i.success.call(t,e,n)}),i.error&&"function"==typeof i.error&&(o.onError=function(e,n,o){i.error.call(t,e,n,o)}),o.send(i.data,i.dataType)}else o.open(e),o.send();return o},get:function(e,t,n,i){return"function"==typeof t?this.ajax(e,{success:t}):"function"==typeof n?this.ajax(e,{data:t,success:n}):this.ajax(e,{data:t,dataType:n,success:i})},getJSON:function(e,t,n){return"function"==typeof t?this.ajax(e,{success:t}):this.ajax(e,{data:t,success:n})},fileUpload:function(e,i,o,r,a){var c=new n;return c.open(e,"POST"),"function"==typeof o?(a=o,o=void 0,r=void 0):"function"==typeof r&&(a=r,r=void 0),a&&"function"==typeof a&&(c.onSuccess=function(e,n){a.call(t,e,n)}),c.postForm(o,r,i),c}}}(app,this),function(e,t){e.log={info:function(t){e.executeNativeJS(["log","i"],t)},warning:function(t){e.executeNativeJS(["log","w"],t)},error:function(t){e.executeNativeJS(["log","e"],t)}}}(app,this),function(e,t){var n=function(n){var i=[];this.setRecipients=function(e){i=e},this.send=function(o,r,a){"undefined"==typeof o?e.throwError("请传入有效消息内容！"):"undefined"==typeof i?e.throwError("请設置有效的收件人信息！"):e.isArray(i)||e.throwError("收件人信息必須是數組對象！");var c=e.executeNativeJS(["message","createMessage"],n);c&&(c.to=i,c.body=o),e.executeNativeJS(["message","sendMessage"],c,function(){e.isFunction(r)&&r.call()},function(n){e.isFunction(a)&&a.call(t,n)})}};e.message={createMessage:function(e){return"undefined"==typeof e&&(e=1),new n(e)}}}(app,this),function(e,t){e.networkinfo={getCurrentType:function(t,n,i){return e.executeNativeJS(["networkinfo","getCurrentType"])}}}(app,this),function(e,t){e.os={getLanguage:function(){return e.executeConstantJS(["os","language"])},getVersion:function(){return e.executeConstantJS(["os","version"])},getName:function(){return e.executeConstantJS(["os","name"])},getVendor:function(){return e.executeConstantJS(["os","vendor"])}}}(app,this),function(e,t){var n=e.currentView(),i=function(t,n,i,o){var r,a=e.getPopoverType();t=t||0,n=n||0,o=o||0,i=i||0,e.android()&&(n*=window.devicePixelRatio,o*=window.devicePixelRatio),this.open=function(c,u){"undefined"==typeof c&&e.throwError("请传入有效的url路径！"),r=this.popovername=u||c;var s={x:t,y:n,width:i,height:o};e.executeNativeJS(["window","openPopover"],r,a,c,s)},this.setType=function(e){a=e},this.setAnimationType=function(e){},this.hide=function(){r&&e.executeNativeJS(["window","setPopoverVisible"],!1,r)},this.show=function(){r&&e.executeNativeJS(["window","setPopoverVisible"],!0,r);
  },this.front=function(){r&&e.executeNativeJS(["window","bringPopoverToFront"],r)},this.behind=function(){r&&e.executeNativeJS(["window","sendPopoverToBack"],r)},this.behindOf=function(t){"undefined"==typeof t&&e.throwError("请传入有效的popovr对象！");var n=t.popovername;"undefined"==typeof n&&e.throwError("无法操作未打开的popovr！"),r&&e.executeNativeJS(["window","bringPopoverBelow"],r,n)},this.frontOf=function(t){"undefined"==typeof t&&e.throwError("请传入有效的popovr对象！");var n=t.popovername;"undefined"==typeof n&&e.throwError("无法操作未打开的popovr！"),r&&e.executeNativeJS(["window","bringPopoverAbove"],r,n)},this.close=function(){r&&e.executeNativeJS(["window","closePopover"],r)},this.evalScript=function(t){"undefined"==typeof t?e.throwError("请传入有效的JS语句！"):"undefined"==typeof r?e.throwError("无法在未打开的popover中执行JS语句！"):e.executeNativeJS(["window","evaluateScript"],"",r,t)}};n.createPopover=function(e,t,n,o){return new i(e,t,n,o)}}(app,this),function(e,t){var n=0,i=1;e.progress={showProgress:function(t,o){o==n||o==i?e.executeNativeJS(["progress","showProgress"],o,t):e.executeNativeJS(["progress","showProgress"],t)},hideProgress:function(){e.executeNativeJS(["progress","hideProgress"])},showToast:function(t,n){e.executeNativeJS(["progress","showToast"],t,n)}}}(app,this),function(e,t){var n=function(t,n){var i=e.executeNativeJS(["properties","openProperties"],t,n);this.put=function(t,n){e.executeObjFunJS([i,"putProperty"],t,n)},this.get=function(t){return e.executeObjFunJS([i,"getProperty"],t)},this["delete"]=function(t){e.executeObjFunJS([i,"deleteProperty"],t)},this.clean=function(){e.executeObjFunJS([i,"clean"])},this.save=function(){return e.executeObjFunJS([i,"save"])}};e.properties={open:function(e,t){return new n(e,t)}}}(app,this),function(e,t){e.screen={getResolutionWidth:function(){return e.executeConstantJS(["screen","resolutionWidth"])},getResolutionHeight:function(){return e.executeConstantJS(["screen","resolutionHeight"])},getScale:function(){return e.executeConstantJS(["screen","scale"])},getDpiX:function(){return e.executeConstantJS(["screen","dpiX"])},getDpiY:function(){return e.executeConstantJS(["screen","dpiY"])},setBrightness:function(t){e.executeNativeJS(["screen","setBrightness"],t)},getBrightness:function(){return e.executeNativeJS(["screen","getBrightness"])},lockOrientation:function(){e.executeNativeJS(["screen","lockOrientation"])},unLockOrientation:function(){e.executeNativeJS(["screen","unlockOrientation"])}}}(app,this),function(e,t){var n=function(n,i){var o=e.executeNativeJS(["require"],"socketManager");e.executeObjFunJS([o,"createSocket"],n,function(n,o){e.isFunction(i)&&i.call(t,n,o)}),this.close=function(t,n){e.executeObjFunJS([o,"closeSocket"])},this.write=function(t,n){e.executeObjFunJS([o,"write"],t,n)}};e.socket={create:function(e,t){return new n(e,t)}}}(app,this),function(e,t){e.storage={getLength:function(){return e.executeNativeJS(["storage","getLength"])},get:function(t){return e.executeNativeJS(["storage","getItem"],t)},set:function(t,n){e.executeNativeJS(["storage","setItem"],t,n)},remove:function(t){e.executeNativeJS(["storage","removeItem"],t)},clear:function(){e.executeNativeJS(["storage","clear"])},key:function(t){return e.executeNativeJS(["storage","key"],t)}}}(app,this),function(e,t){e.zip={compress:function(n,i,o,r){e.executeNativeJS(["zip","compress"],n,i,function(){e.isFunction(o)&&o.call()},function(n){e.isFunction(r)&&r.call(t,n)})},decompress:function(n,i,o,r){e.executeNativeJS(["zip","decompress"],n,i,function(){e.isFunction(o)&&o.call()},function(n){e.isFunction(r)&&r.call(t,n)})}}}(app,this),function(e,t){e.require=function(t){return"tabMark"==t?e.require.tabMark():void 0}}(app,this),function(e,t){var n=function(){var t,n,i=!1,o="tabMark",r=e.executeRequireJS("tabMark");this.setDataSource=function(n){return"undefined"==typeof n&&e.throwError("请传入有效的dataSources！"),t=n,$.os.android&&n.btnHeight&&(n.btnHeight=n.btnHeight*window.devicePixelRatio),e.executeObjFunJS([r,"setDataSource"],n),this},this.setFrame=function(t,i,o,a){t=t||0,i=i||0,a=a||0,o=o||0,e.android()&&(i*=window.devicePixelRatio,a*=window.devicePixelRatio);var c={x:t,y:i,width:o,height:a};return n=c,e.executeObjFunJS([r,"setFrame"],c),this},this.show=function(){return"undefined"==typeof t&&e.throwError("请先调用setDataSource方法设置数据源！"),"undefined"==typeof n&&e.throwError("请先调用setFrame方法设置尺寸及位置！"),r?e.executeObjFunJS([r,"show"]):e.executeObjFunJS([o,"show"],t,n),i=!0,this},this.hide=function(){return i&&(r?e.executeObjFunJS([r,"hide"]):e.executeObjFunJS([o,"hide"])),this},this.remove=function(){return i&&(r?e.executeObjFunJS([r,"remove"]):e.executeObjFunJS([o,"remove"])),this},this.addEditCallback=function(t){return e.executeObjFunJS([r,"addEditCallback"],function(){e.isFunction(t)&&t.call()}),this},this.addScrollCallback=function(t){return e.executeObjFunJS([r,"addScrollCallback"],function(){e.isFunction(t)&&t.call()}),this},this.showContentAtIndex=function(n){if(i){var a=t.dataSource.length;n>=1&&a>=n&&(r?e.executeObjFunJS([r,"showContentAtIndex"],n):e.executeObjFunJS([o,"showContentAtIndex"],n))}return this},this.addIgnoreArea=function(t,n){return i&&e.executeObjFunJS([r,"addIgnoreArea"],t,n),this}};e.require.tabMark=function(){return new n}}(app,this),function($L,global){$L.debug=function(){document.body.style.cursor="-webkit-grab",$L.debug.uuid=0,$L.debug.xhr={},window.addEventListener("message",function(e){var origin=e.origin,res=JSON.parse(e.data),type=res.type;if("init"==type)$L.debug.isReady=!0;else if("evaluateScript"==type){var data=res.data;eval(data)}else if("ajax"==type){var token=res.token,success=$L.debug.xhr[token].success,error=$L.debug.xhr[token].error,data=res.data,dataType=$L.debug.xhr[token].dataType;if("json"==dataType){if($L.isFunction(success)){if(data)try{data=JSON.parse(data)}catch(e){alert(data)}else data={};success.call(global,{},data)}}else $L.isFunction(success)&&success.call(global,{},data);delete $L.debug.xhr[token]}},!1),$L.debug.getQueryString=function(e){var t=new RegExp("(^|&)"+e+"=([^&]*)(&|$)","i"),n=window.location.search.substr(1).match(t);return null!=n?n[2]:null},$L.debug.postMessage=function(e){window.parent.postMessage(e,"*")},$L.executeNativeJS=function(){var e;if("window"==arguments[0][0])var e=$L.debug.window.apply($L.debug,Array.prototype.slice.call(arguments));else if("httpManager"==arguments[0][0])var e=$L.debug.http.apply($L.debug,Array.prototype.slice.call(arguments));else if("storage"==arguments[0][0])var e=$L.debug.storage.apply($L.debug,Array.prototype.slice.call(arguments));else if("audio"==arguments[0][0])var e=$L.debug.audio.apply($L.debug,Array.prototype.slice.call(arguments));return"undefined"!=typeof e?e:void 0},$L.executeObjFunJS=function(){var e;if("tabMark"==arguments[0][0])var e=$L.debug.tabMark.apply($L.debug,Array.prototype.slice.call(arguments));return"undefined"!=typeof e?e:void 0},$L.executeConstantJS=function(){return"device"==arguments[0][0]?$L.debug.device.apply($L.debug,Array.prototype.slice.call(arguments)):"os"==arguments[0][0]?$L.debug.os.apply($L.debug,Array.prototype.slice.call(arguments)):"app"==arguments[0][0]?$L.debug.app.apply($L.debug,Array.prototype.slice.call(arguments)):void 0},window.$&&$L.debug.dom()}}(app,this),function(e,t){e.debug.device=function(){var e=arguments[0][1];return"imei"==e?"865743028006921":"imsi"==e?" ":"model"==e?"Che1-CL20":"vendor"==e?"IPHONE":"uuid"==e?"48a9511b-d23a-43c4-a868-0ed2ad80e75b":void 0}}(app,this),function(e,t){e.debug.os=function(){var e=arguments[0][1];return"language"==e?"zh":"version"==e?$.os.android||$.os.ios?$.os.version:"4.4.4":"name"==e?$.os.android?"Android":($.os.ios,"iOS"):"vendor"==e?$.os.android?"HUAWEI":($.os.ios,"IPHONE"):void 0}}(app,this),function(e,t){e.debug.app=function(){var e=arguments[0][1];return"platformName"==e?"Android":"platformVersion"==e?"4.4.4":"deviceModel"==e?"Che1-CL20":"deviceName"==e?"Che1":void 0}}(app,this),function(e,t){e.debug.dom=function(){var e=$.fn.on;$.fn.on=function(t,n,i,o,r){return"tap"==t&&(t="click"),e.call(this,t,n,i,o,r)};var t=$.fn.off;$.fn.off=function(e,n,i){return"tap"==e&&(e="click"),t.call(this,e,n,i)};var n=$.fn.trigger;$.fn.trigger=function(e,t){return"tap"==e&&(e="click"),n.call(this,e,t)};var i=$.fn.one;$.fn.one=function(e,t,n,o){return"tap"==e&&(e="click"),i.call(this,e,t,n,o)}}}(app,this),function(e,t){e.debug.window=function(){var e=Array.prototype.slice.call(arguments,1),t=arguments[0][1];if("openWindow"==t){var n=e[0],i=e[1],o=e[2];0==i&&(o=e[2]);var r="openWindow('"+n+"','"+o+"')";this.postMessage(r)}else if("closeSelf"==t){var a=this.getQueryString("pageId"),r="closeWindow('"+n+"','"+a+"')";this.postMessage(r)}else if("closeWindow"==t){var n=e[0],r="closeWindow('"+n+"','"+a+"')";this.postMessage(r)}else if("backToWindow"==t){var n=e[0],r="backToWindow('"+n+"')";this.postMessage(r)}else if("openPopover"==t){var c=e[0],o=e[2],u=JSON.stringify(e[3]),n=this.getQueryString("pageId"),r="openPopover('"+c+"','"+o+"','"+u+"','"+n+"')";this.postMessage(r)}else if("closePopover"==t){var c=e[0],a=this.getQueryString("pageId"),r="closePopover('"+c+"','"+a+"')";this.postMessage(r)}else if("bringPopoverToFront"==t){var c=e[0],r="openPopover('"+c+"')";this.postMessage(r)}else if("setSlideLayout"==t){var s=e[0],i=s.type;"left"==i?s.leftPane.url=s.leftPane.url:s.rightPane.url=s.rightPane.url;var s=JSON.stringify(e[0]),r="setSlideLayout('"+s+"')";this.postMessage(r)}else if("openSlidePane"==t){var s=JSON.stringify(e[0]),r="openSlidePane('"+s+"')";this.postMessage(r)}else if("closeSlidePane"==t){var r="closeSlidePane()";this.postMessage(r)}else{if("getWidth"==t){var d;return window.innerWidth?d=window.innerWidth:document.body&&document.body.clientWidth&&(d=document.body.clientWidth),d}if("getHeight"==t){var f;return window.innerHeight?f=window.innerHeight:document.body&&document.body.clientHeight&&(f=document.body.clientHeight),f}if("alert"==t)alert(e[0].msg);else if("confirm"==t)alert(e[0].msg);else if("evaluateScript"==t){var n=e[1],l=e[2],p=e[3],a=this.getQueryString("pageId"),r="evaluateScript('"+n+"','"+l+"','"+p+"','"+a+"')";this.postMessage(r)}}}}(app,this),function(e,t){var n=function(t,i,o){var r,a=e.isArray(i),c=e.isPlainObject(i);e.each(i,function(i,u){r=e.type(u),o&&(i=o+"["+(c||"object"==r||"array"==r?i:"")+"]"),!o&&a?t.add(u.name,u.value):"array"==r||"object"==r?n(t,u,i):t.add(i,u)})},i=encodeURIComponent,o=function(e,t){return""==t?e:(e+"&"+t).replace(/[&?]{1,2}/,"?")},r=function(t){var o=[];return o.add=function(t,n){e.isFunction(n)&&(n=n()),null==n&&(n=""),this.push(i(t)+"="+i(n))},n(o,t),o.join("&").replace(/%20/g,"+")},a=function(t){t.body&&"string"!=e.type(t.body)&&(t.body=r(t.body)),!t.body||t.method&&"GET"!=t.method.toUpperCase()||(t.url=o(t.url,t.body),t.body=void 0)};e.debug.http=function(){var t=Array.prototype.slice.call(arguments,1),n=arguments[0][1];if("sendRequest"==n){var i=t[0],o=i.body;o&&"string"==e.type(o)&&(i.body=JSON.parse(o)),a(i),i=JSON.stringify(i);var r=this.getQueryString("pageId"),c=this.uuid++;this.xhr[c]={success:t[1],error:t[2],dataType:t[0].dataType};var u="sendRequest('"+i+"','"+r+"','"+c+"')";this.postMessage(u)}}}(app,this),function(e,t){e.debug.storage=function(){var e=Array.prototype.slice.call(arguments,1),t=arguments[0][1];if("getLength"==t)return window.localStorage.length;if("getItem"==t)return window.localStorage.getItem(e[0]);if("setItem"==t)window.localStorage.setItem(e[0],e[1]);else if("removeItem"==t)window.localStorage.removeItem(e[0]);else if("clear"==t)window.localStorage.clear();else if("key"==t)return window.localStorage.key(e[0])}}(app,this),function(e,t){e.debug.screen=function(){var e=(Array.prototype.slice.call(arguments,1),arguments[0][1]);return"getResolutionWidth"==e?"720":"getResolutionHeight"==e?"1280":"getScale"==e?"2":"getDpiX"==e?"268.941":"getDpiY"==e?"68.694":"getBrightness"==e?"1":void 0}}(app,this),function(e,t){e.debug.audio=function(){}}(app,this),function(e,t){e.debug.tabMark=function(){var e=arguments[0][1];if("show"==e){var t=arguments[1],n=arguments[2];if(!t||!n)return;t=JSON.stringify(t),n=JSON.stringify(n);var i=this.getQueryString("pageId"),o="tabMarkShow('"+t+"','"+n+"','"+i+"')";this.postMessage(o)}else if("hide"==e){var i=this.getQueryString("pageId"),o="tabMarkHide('"+i+"')";this.postMessage(o)}else if("showContentAtIndex"==e){var r=arguments[1],i=this.getQueryString("pageId"),o="tabMarkShowIndex('"+i+"','"+r+"')";this.postMessage(o)}}}(app,this);