UNPKG

iweb-tool

Version:
2 lines 259 kB
function implement(e){var t,i;for(t in e)i=e[t],Class.Mutators.hasOwnProperty(t)?Class.Mutators[t].call(this,i):this.prototype[t]=i}function classify(e){return e.extend=Class.extend,e.implement=implement,e}function Ctor(){}function mix(e,t,i){for(var n in t)if(t.hasOwnProperty(n)){if(i&&-1===indexOf(i,n))continue;"prototype"!==n&&(e[n]=t[n])}}function _findRegisteredClass(e,t){for(var i=0;i<CompMgr.registeredControls.length;i++)if(CompMgr.registeredControls[i].className===e)return"undefined"!=typeof t&&(CompMgr.registeredControls[i]=t),CompMgr.registeredControls[i];return!1}function _getUpgradedListOfElement(e){var t=e.getAttribute("data-upgraded");return null===t?[""]:t.split(",")}function _isElementUpgraded(e,t){var i=_getUpgradedListOfElement(e);return-1!=i.indexOf(t)}function _upgradeElement(e,t){if(!("object"==typeof e&&e instanceof Element))throw new Error("Invalid argument provided to upgrade MDL element.");var i=_getUpgradedListOfElement(e),n=[];if(t)_isElementUpgraded(e,t)||n.push(_findRegisteredClass(t));else for(var s=e.className,a=0;a<CompMgr.registeredControls.length;a++){var r=CompMgr.registeredControls[a];s.indexOf(r.cssClass)>-1&&-1===n.indexOf(r)&&!_isElementUpgraded(e,r.className)&&n.push(r)}for(var o,a=0,l=n.length;l>a;a++){if(o=n[a],!o)throw new Error("Unable to find a registered component for the given class.");if(!e[o.className]){i.push(o.className),e.setAttribute("data-upgraded",i.join(","));var u=new o.classConstructor(e);CompMgr.createdControls.push(u);for(var d=0,c=o.callbacks.length;c>d;d++)o.callbacks[d](e);e[o.className]=u}}}function _upgradeDomInternal(e,t,i){if("undefined"==typeof e&&"undefined"==typeof t)for(var n=0;n<CompMgr.registeredControls.length;n++)_upgradeDomInternal(CompMgr.registeredControls[n].className,registeredControls[n].cssClass,i);else{var s=e;if(!t){var a=_findRegisteredClass(s);a&&(t=a.cssClass)}for(var r=i?i:document,o=r.querySelectorAll("."+t),l=0;l<o.length;l++)_upgradeElement(o[l],s)}}function BarrettMu_modulo(e){var t=RSAUtils,i=t.biDivideByRadixPower(e,this.k-1),n=t.biMultiply(i,this.mu),s=t.biDivideByRadixPower(n,this.k+1),a=t.biModuloByRadixPower(e,this.k+1),r=t.biMultiply(s,this.modulus),o=t.biModuloByRadixPower(r,this.k+1),l=t.biSubtract(a,o);l.isNeg&&(l=t.biAdd(l,this.bkplus1));for(var u=t.biCompare(l,this.modulus)>=0;u;)l=t.biSubtract(l,this.modulus),u=t.biCompare(l,this.modulus)>=0;return l}function BarrettMu_multiplyMod(e,t){var i=RSAUtils.biMultiply(e,t);return this.modulo(i)}function BarrettMu_powMod(e,t){var i=new BigInt;i.digits[0]=1;for(var n=e,s=t;;){if(0!=(1&s.digits[0])&&(i=this.multiplyMod(i,n)),s=RSAUtils.biShiftRight(s,1),0==s.digits[0]&&0==RSAUtils.biHighIndex(s))break;n=this.multiplyMod(n,n)}return i}function AbstractMasker(){}function AbstractSplitMasker(){}function AddressMasker(e){this.update(e)}function NumberMasker(e){this.update(e)}function CurrencyMasker(e){this.update(e)}function DateTimeMasker(e){this.update(e)}function DateMasker(e){this.update(e)}function TimeMasker(e){this.update(e)}function PercentMasker(){}function toColorfulString(e){var t;return e?null==e.color?e.value:(t=e.color,'<font color="'+t+'">'+e.value+"</font>"):""}function StringElement(e){this.value=e}function FormatResult(e,t){this.value=e,this.color=t}function NumberFormater(e){this.precision=e}function DateFormater(e){this.pattern=e}function adjustDataType(e){var t=["integer","float","currency","percent","string","textarea"],i=e.type;e.dataType;-1!=t.indexOf(i)&&(e.dataType=i,e.type="originText")}function UNavLayoutTab(e,t,i,n){function s(){var s=e.href.split("#")[1],a=n._content.querySelector("#"+s);n._resetTabState(t),n._resetPanelState(i),u.addClass(e,n._CssClasses.IS_ACTIVE),u.addClass(a,n._CssClasses.IS_ACTIVE)}var a=document.createElement("span");u.addClass(a,"u-ripple"),e.appendChild(a),new URipple(e),e.addEventListener("click",function(t){"#"===e.getAttribute("href").charAt(0)&&(t.preventDefault(),s())}),e.show=s,e.addEventListener("click",function(s){s.preventDefault();var a=e.href.split("#")[1],r=n._content.querySelector("#"+a);n._resetTabState(t),n._resetPanelState(i),u.addClass(e,n._CssClasses.IS_ACTIVE),u.addClass(r,n._CssClasses.IS_ACTIVE)})}function _getBrowserInfo(){var e,t={},i=navigator.userAgent.toLowerCase();return(e=i.match(/rv:([\d.]+)\) like gecko/))?t.ie=parseInt(e[1]):(e=i.match(/msie ([\d.]+)/))?t.ie=e[1]:(e=i.match(/firefox\/([\d.]+)/))?t.firefox=e[1]:(e=i.match(/chrome\/([\d.]+)/))?t.chrome=e[1]:(e=i.match(/opera.([\d.]+)/))?t.opera=e[1]:(e=i.match(/version\/([\d.]+).*safari/))?t.safari=e[1]:0,t}function _showPage(e,t){u.addClass(e,".current"),t.browser.ie&&t.browser.ie<9||(e.style.transform="translate3d(0,0,0)")}function _hidePage(e,t,i){u.removeClass(e,"current"),t.browser.ie&&t.browser.ie<9||(e.style.transform="translate3d("+i+"px,0,0)")}function scrollend_update(e,t){var i=e.getAttribute("time-change"),n=e.querySelector(".current");t.pickerDate[i](n._value),t._updateDate()}function current_postion(e,t){e.style.transform="translateY("+(120-60*t)+"px)"}function Plugin(e){return this.each(function(){var t=$(this),i=t.data("u.pagination"),n="object"==typeof e&&e;i?i.update(n):t.data("u.pagination",i=new Pagination(this,n))})}function _updateDom(e,t){for(var i in t){var n=t[i];for(var e in n){var s=n[e];if("trigger"==e)u.trigger(e,s[0]);else if(u.isArray(s))u.each(s,function(t,i){e[t](i)});else try{e[i](n)}catch(a){e[i](n[i])}}}}var U_LANGUAGES="i_languages",U_THEME="u_theme",U_LOCALE="u_locale",U_USERCODE="u_usercode",enumerables=!0,enumerablesTest={toString:1},toString=Object.prototype.toString;for(var i in enumerablesTest)enumerables=null;enumerables&&(enumerables=["hasOwnProperty","valueOf","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","constructor"]),window.u=window.u||{};var u=window.u;if(u.enumerables=enumerables,u.extend=function(e,t){var i,n=arguments;if(n.length>1)for(var s=1;s<n.length;s++)if(i=n[s],e&&i&&"object"==typeof i){var a,r,o;for(a in i)e[a]=i[a];if(enumerables)for(r=enumerables.length;r--;)o=enumerables[r],i.hasOwnProperty(o)&&(e[o]=i[o])}return e},u.extend(u,{setCookie:function(e,t,i,n,s,a){var r=e+"="+encodeURIComponent(t);i&&(r+="; expires="+i.toGMTString()),n&&(r+="; path="+n),s&&(r+="; domain="+s),a&&(r+="; secure="+a),document.cookie=r},getCookie:function(e){var t="(?:; )?"+e+"=([^;]*);?",i=new RegExp(t);return i.test(document.cookie)?decodeURIComponent(RegExp.$1):null},createShellObject:function(e){var t=function(){};return t.prototype=e,new t},execIgnoreError:function(e,t,i){try{e.call(t,i)}catch(n){}},on:function(e,t,i,n){if(arguments.length<4)n=i,i=void 0;else var s=function(t){if(t){var s=e.querySelectorAll(i);s.forEach(function(e){e==t.target&&n.call(t.target,t)})}};e.uEvent||(e.uEvent={}),e.uEvent[t]?e.uEvent[t].push(i?s:n):(e.uEvent[t]=[i?s:n],e.uEvent[t+"fn"]=function(){var i=event?event:window.event;e.uEvent[t].forEach(function(t){t.call(e,i)})},e.addEventListener?e.addEventListener(t,e.uEvent[t+"fn"]):e.attachEvent?e.attachEvent("on"+t,e.uEvent[t+"fn"]):e["on"+t]=e.uEvent[t+"fn"])},off:function(e,t,i){var n=e.uEvent[t+"fn"];e.removeEventListener?e.removeEventListener(t,n):e.removeEvent?e.removeEvent("on"+t,n):delete e["on"+t],e.uEvent[t]=void 0,e.uEvent[t+"fn"]=void 0},trigger:function(e,t){e.uEvent&&e.uEvent[t]&&e.uEvent[t+"fn"]()},addClass:function(e,t){return"undefined"==typeof e.classList?u._addClass(e,t):e.classList.add(t),u},removeClass:function(e,t){return"undefined"==typeof e.classList?u._removeClass(e,t):e.classList.remove(t),u},hasClass:function(e,t){return"#text"===e.nodeName?!1:"undefined"==typeof e.classList?u._hasClass(e,t):e.classList.contains(t)},toggleClass:function(e,t){return"undefined"==typeof e.classList?u._toggleClass(e,t):e.classList.toggle(t)},css:function(e,t,i){if(t instanceof Object)for(var n in t){var s=t[n];["width","height","top","bottom","left","right"].indexOf(n)>-1&&u.isNumber(s)&&(s+="px"),e.style[n]=s}else arguments.length>2?e.style[t]=i:u.getStyle(e,t)},wrap:function(e,t){var i=u.makeDOM(t);e.parentNode.insertBefore(i,e),i.appendChild(e)},getStyle:function(e,t){var i;return i=window.getComputedStyle?window.getComputedStyle(e):e.currentStyle,void 0!==i[t]?i[t]:""},getZIndex:function(){return u.globalZIndex||(u.globalZIndex=1e3),u.globalZIndex++},makeDOM:function(e){var t=document.createElement("div");t.innerHTML=e;var i=t.children[0];return i},stopEvent:function(e){"undefined"!=typeof e&&(e.stopPropagation?e.stopPropagation():e.cancelBubble=!0)},getFunction:function(e,t){if(!t||"function"==typeof t)return t;if("function"==typeof e[t])return e[t];if("function"==typeof window[t])return window[t];if(-1!=t.indexOf(".")){var i=u.getJSObject(e,t);if("function"==typeof i)return i;if(i=u.getJSObject(window,t),"function"==typeof i)return i}return t},getJSObject:function(e,t){if(t){if("object"==typeof t)return t;for(var i=t.split("."),n=e,s=0;s<i.length;s++)if(n=n[i[s]],!n)return null;return n}},isDate:function(e){return"[object Date]"===Object.prototype.toString.call(e)||e instanceof Date},isNumber:function(e){return e===+e},isArray:Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},inArray:function(e,t){if(!t instanceof Array)throw"arguments is not Array";for(var i=0,n=t.length;n>i;i++)if(e==t[i])return!0;return!1},each:function(e,t){if(e.forEach)e.forEach(function(e,i){t(i,e)});else{if(!(e instanceof Object))return;for(var i in e)t(i,e[i])}}}),function(){var e={},t={},i={},n={},s={"float":{precision:2},datetime:{format:"YYYY-MM-DD hh:mm:ss",metaType:"DateTimeFormatMeta",speratorSymbol:"-"},time:{format:"hh:mm:ss"},date:{format:"YYYY-MM-DD"},currency:{precision:2,curSymbol:"¥"},percent:{}};n.getEnvironment=function(){return u.createShellObject(e)},n.getClientAttributes=function(){return u.createShellObject(t)},n.setContextPath=function(t){return e[IWEB_CONTEXT_PATH]=t},n.getContextPath=function(t){return e[IWEB_CONTEXT_PATH]},n.setClientAttribute=function(e,i){t[e]=i},n.getSessionAttributes=function(){return u.createShellObject(i)},n.setSessionAttribute=function(e,t){i[e]=t,setCookie("ISES_"+e,t)},n.removeClientAttribute=function(e){t[e]=null,execIgnoreError(function(){delete t[e]})},n.getLanguages=function(){return this.getEnvironment().languages},n.collectEnvironment=function(){var e=this.getEnvironment(),i=this.getSessionAttributes();for(var n in t)i[n]=t[n];return e.clientAttributes=i,e},n.setMaskerMeta=function(e,t){if("function"==typeof e)getMetaFunc=e;else if(s[e])if("object"!=typeof t)s[e]=t;else for(var i in t)s[e][i]=t[i];else s[e]=t},n.getMaskerMeta=function(e){if("function"==typeof getMetaFunc){var t=getMetaFunc.call(this);return t[e]}return u.extend({},s[e])},e.languages=u.getCookie(U_LANGUAGES)?u.getCookie(U_LANGUAGES).split(","):navigator.language,e.theme=u.getCookie(U_THEME),e.locale=u.getCookie(U_LOCALE),e.usercode=u.getCookie(U_USERCODE),document.cookie.replace(/ISES_(\w*)=([^;]*);?/gi,function(e,t,n){i[t]=n});var a=function(){};a.prototype=n,u.core=new a}(),u.extend(u,{isIE:!1,isFF:!1,isOpera:!1,isChrome:!1,isSafari:!1,isWebkit:!1,isIE8_BEFORE:!1,isIE8:!1,isIE8_CORE:!1,isIE9:!1,isIE9_CORE:!1,isIE10:!1,isIE10_ABOVE:!1,isIE11:!1,isIOS:!1,isIphone:!1,isIPAD:!1,isStandard:!1,version:0}),function(){var e,t,i=navigator.userAgent,n=/(msie\s|trident.*rv:)([\w.]+)/,s=/(firefox)\/([\w.]+)/,a=/(opera).+version\/([\w.]+)/,r=/(chrome)\/([\w.]+)/,o=/version\/([\w.]+).*(safari)/,l=i.toLowerCase(),d=null,c=n.exec(l);if(null!=c&&(d={browser:"IE",version:c[2]||"0"}),c=s.exec(l),null!=c&&(d={browser:c[1]||"",version:c[2]||"0"}),c=a.exec(l),null!=c&&(d={browser:c[1]||"",version:c[2]||"0"}),c=r.exec(l),null!=c&&(d={browser:c[1]||"",version:c[2]||"0"}),c=o.exec(l),null!=c&&(d={browser:c[2]||"",version:c[1]||"0"}),null!=c&&(d={browser:"",version:"0"}),(t=l.match(/opera.([\d.]+)/))?u.isOpera=!0:"IE"==d.browser&&11==d.version?(u.isIE11=!0,u.isIE=!0):(t=l.match(/chrome\/([\d.]+)/))?(u.isChrome=!0,u.isStandard=!0):(t=l.match(/version\/([\d.]+).*safari/))?(u.isSafari=!0,u.isStandard=!0):(t=l.match(/gecko/))?(u.isFF=!0,u.isStandard=!0):(t=l.match(/msie ([\d.]+)/))?u.isIE=!0:(t=l.match(/firefox\/([\d.]+)/))&&(u.isFF=!0,u.isStandard=!0),l.match(/webkit\/([\d.]+)/)&&(u.isWebkit=!0),l.match(/ipad/i)&&(u.isIOS=!0,u.isIPAD=!0,u.isStandard=!0),l.match(/iphone/i)&&(u.isIOS=!0,u.isIphone=!0),u.version=e&&d.version?d.version:0,u.isIE){var h=parseInt(u.version),p=document.documentMode;null==p?(6==h||7==h)&&(u.isIE8_BEFORE=!0):(7==p?u.isIE8_BEFORE=!0:8==p?u.isIE8=!0:9==p?(u.isIE9=!0,u.isSTANDARD=!0):10==p?(u.isIE10=!0,u.isSTANDARD=!0,u.isIE10_ABOVE=!0):u.isSTANDARD=!0,8==h?u.isIE8_CORE=!0:9==h?u.isIE9_CORE=!0:11==d.version&&(u.isIE11=!0))}}(),u.isIE8_BEFORE)throw alert("uui 不支持IE8以前的浏览器版本,请更新IE浏览器或使用其它浏览器!"),new Error("uui 不支持IE8以前的浏览器版本,请更新IE浏览器或使用其它浏览器!");if(u.isIE8&&u.polyfill!==!0)throw alert("IE8浏览器中使用uui 必须在u.js之前引入u-polyfill.js!"),new Error("IE8浏览器中使用uui 必须在uui之前引入u-polyfill.js!");window.iweb={},window.iweb.Core=u.core,window.iweb.browser={isIE:u.isIE,isFF:u.isFF,isOpera:u.isOpera,isChrome:u.isChrome,isSafari:u.isSafari,isWebkit:u.isWebkit,isIE8_BEFORE:u.isIE8_BEFORE,isIE8:u.isIE8,isIE8_CORE:u.isIE8_CORE,isIE9:u.isIE9,isIE9_CORE:u.isIE9_CORE,isIE10:u.isIE10,isIE10_ABOVE:u.isIE10_ABOVE,isIE11:u.isIE11,isIOS:u.isIOS,isIphone:u.isIphone,isIPAD:u.isIPAD,isStandard:u.isStandard,version:0},NodeList.prototype.forEach=Array.prototype.forEach,String.prototype.lengthb=function(){var e=this.replace(/[^\x00-\xff]/g,"**");return e.length},String.prototype.replaceAll=function(e,t){var i=new RegExp(e,"g");return this.replace(i,t)};var XmlHttp={get:"get",post:"post",reqCount:4,createXhr:function(){var e=null;return e=window.XMLHttpRequest?new XMLHttpRequest:new ActiveXObject("Microsoft.XMLHTTP")},ajax:function(e){var t=e.url,i=e.success,n=void 0==e.async?!0:e.async,s=e.error,a=e.data,r=(void 0==e.type?XmlHttp.post:e.type).toLowerCase();t=XmlHttp.serializeUrl(t),a=XmlHttp.serializeParams(a),r==XmlHttp.get&&null!=a&&(t+="&"+a,a=null);var o=XmlHttp.createXhr();o.open(r,t,n),r==XmlHttp.post&&o.setRequestHeader("Content-type","application/x-www-form-urlencoded;charset=UTF-8");var l=0;n?(o.onreadystatechange=function(){l++,l==XmlHttp.reqCount&&XmlHttp.execBack(o,i,s)},o.send(a)):(o.send(a),XmlHttp.execBack(o,i,s))},execBack:function(e,t,i){if(4!=e.readyState||200!=e.status&&304!=e.status)if(i)i(e.responseText,e.status,e);else{var n="no error callback function!";e.responseText&&(n=e.responseText),alert(n)}else t(e.responseText,e.status,e)},serializeUrl:function(e){var t="cache="+Math.random();return e+=e.indexOf("?")>0?"&"+t:"?"+t},serializeParams:function(e){var t=void 0;if(t==e||null==e||""==e)return null;if(e.constructor==Object){var i="";for(var n in e)i+=n+"="+e[n]+"&";return i.substring(0,i.length-1)}return e}};u.ajax=XmlHttp.ajax;var Class=function(e){return this instanceof Class||!isFunction(e)?void 0:classify(e)};Class.create=function(e,t){function i(){e.apply(this,arguments),this.constructor===i&&this.initialize&&this.initialize.apply(this,arguments)}return isFunction(e)||(t=e,e=null),t||(t={}),e||(e=t.Extends||Class),t.Extends=e,e!==Class&&mix(i,e,e.StaticsWhiteList),implement.call(i,t),classify(i)},Class.extend=function(e){return e||(e={}),e.Extends=this,Class.create(e)},Class.Mutators={Extends:function(e){var t=this.prototype,i=createProto(e.prototype);mix(i,t),i.constructor=this,this.prototype=i,this.superclass=e.prototype},Implements:function(e){isArray(e)||(e=[e]);for(var t,i=this.prototype;t=e.shift();)mix(i,t.prototype||t)},Statics:function(e){mix(this,e)}};var createProto=Object.__proto__?function(e){return{__proto__:e}}:function(e){return Ctor.prototype=e,new Ctor},toString=Object.prototype.toString,isArray=Array.isArray||function(e){return"[object Array]"===toString.call(e)},isFunction=function(e){return"[object Function]"===toString.call(e)},indexOf=Array.prototype.indexOf?function(e,t){return e.indexOf(t)}:function(e,t){for(var i=0,n=e.length;n>i;i++)if(e[i]===t)return i;return-1};u.Class=Class;var CompMgr={plugs:{},dataAdapters:{},registeredControls:[],createdControls:[],apply:function(e){if(e)var t=e.el||document.body,i=e.model;"string"==typeof t&&(t=document.body.querySelector(t)),(null==t||"object"!=typeof t)&&(t=document.body);var n=t.querySelectorAll("[u-meta]");n.forEach(function(e){if(!e.comp){var t=JSON.parse(e.getAttribute("u-meta"));if(t&&t.type){var n=CompMgr.createDataAdapter({el:e,options:t,model:i});n&&(e.adpt=n)}}})},addPlug:function(e){var t=e.plug,i=e.name;if(this.plugs||(this.plugs={}),this.plugs[i])throw new Error("plug has exist:"+i);t.compType=i,this.plugs[i]=t},addDataAdapter:function(e){var t=e.adapter,i=e.name;if(this.dataAdapters||(dataAdapters={}),this.dataAdapters[i])throw new Error("dataAdapter has exist:"+i);this.dataAdapters[i]=t},getDataAdapter:function(e){return e?(this.dataAdapters||(dataAdapters={}),this.dataAdapters[e]):void 0},createDataAdapter:function(e){var t=e.options,i=t.type,n=this.dataAdapters[i];if(!n)return null;var s=new n(e);return s.type=i,s},_createComp:function(e){var t=e.options,i=t.type,n=this.plugs[i];if(!n)return null;var s=new n(e);return s.type=i,s},regComp:function(e){for(var t={classConstructor:e.comp,className:e.compAsString||e.compAsString,cssClass:e.css||e.css,callbacks:[]},i=0;i<this.registeredControls.length;i++){var n=this.registeredControls[i];if(n.cssClass===t.cssClass)throw new Error("The provided cssClass has already been registered: "+n.cssClass);if(n.className===t.className)throw new Error("The provided className has already been registered")}this.registeredControls.push(t)},updateComp:function(e){for(var t=0;t<this.registeredControls.length;t++)_upgradeDomInternal(this.registeredControls[t].className,null,e)}};if(u.compMgr=CompMgr,u.on(window,"load",function(){"use strict";u.compMgr.updateComp()}),window.i18n){var scriptPath=getCurrentJsPath(),_temp=scriptPath.substr(0,scriptPath.lastIndexOf("/")),__FOLDER__=_temp.substr(0,_temp.lastIndexOf("/"));u.uuii18n=u.extend({},window.i18n),u.uuii18n.init({postAsync:!1,getAsync:!1,fallbackLng:!1,ns:{namespaces:["uui-trans"]},resGetPath:__FOLDER__+"/locales/__lng__/__ns__.json"})}window.trans=u.trans=function(e,t){return u.uuii18n?u.uuii18n.t("uui-trans:"+e):t},"undefined"==typeof u.RSAUtils&&(u.RSAUtils={});var RSAUtils=u.RSAUtils,biRadixBase=2,biRadixBits=16,bitsPerDigit=biRadixBits,biRadix=65536,biHalfRadix=biRadix>>>1,biRadixSquared=biRadix*biRadix,maxDigitVal=biRadix-1,maxInteger=9999999999999998,maxDigits,ZERO_ARRAY,bigZero,bigOne,BigInt=u.BigInt=function(e){"boolean"==typeof e&&1==e?this.digits=null:this.digits=ZERO_ARRAY.slice(0),this.isNeg=!1};RSAUtils.setMaxDigits=function(e){maxDigits=e,ZERO_ARRAY=new Array(maxDigits);for(var t=0;t<ZERO_ARRAY.length;t++)ZERO_ARRAY[t]=0;bigZero=new BigInt,bigOne=new BigInt,bigOne.digits[0]=1},RSAUtils.setMaxDigits(20);var dpl10=15;RSAUtils.biFromNumber=function(e){var t=new BigInt;t.isNeg=0>e,e=Math.abs(e);for(var i=0;e>0;)t.digits[i++]=e&maxDigitVal,e=Math.floor(e/biRadix);return t};var lr10=RSAUtils.biFromNumber(1e15);RSAUtils.biFromDecimal=function(e){for(var t,i="-"==e.charAt(0),n=i?1:0;n<e.length&&"0"==e.charAt(n);)++n;if(n==e.length)t=new BigInt;else{var s=e.length-n,a=s%dpl10;for(0==a&&(a=dpl10),t=RSAUtils.biFromNumber(Number(e.substr(n,a))),n+=a;n<e.length;)t=RSAUtils.biAdd(RSAUtils.biMultiply(t,lr10),RSAUtils.biFromNumber(Number(e.substr(n,dpl10)))),n+=dpl10;t.isNeg=i}return t},RSAUtils.biCopy=function(e){var t=new BigInt(!0);return t.digits=e.digits.slice(0),t.isNeg=e.isNeg,t},RSAUtils.reverseStr=function(e){for(var t="",i=e.length-1;i>-1;--i)t+=e.charAt(i);return t};var hexatrigesimalToChar=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"];RSAUtils.biToString=function(e,t){var i=new BigInt;i.digits[0]=t;for(var n=RSAUtils.biDivideModulo(e,i),s=hexatrigesimalToChar[n[1].digits[0]];1==RSAUtils.biCompare(n[0],bigZero);)n=RSAUtils.biDivideModulo(n[0],i),digit=n[1].digits[0],s+=hexatrigesimalToChar[n[1].digits[0]];return(e.isNeg?"-":"")+RSAUtils.reverseStr(s)},RSAUtils.biToDecimal=function(e){var t=new BigInt;t.digits[0]=10;for(var i=RSAUtils.biDivideModulo(e,t),n=String(i[1].digits[0]);1==RSAUtils.biCompare(i[0],bigZero);)i=RSAUtils.biDivideModulo(i[0],t),n+=String(i[1].digits[0]);return(e.isNeg?"-":"")+RSAUtils.reverseStr(n)};var hexToChar=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"];RSAUtils.digitToHex=function(e){for(var t=15,i="",n=0;4>n;++n)i+=hexToChar[e&t],e>>>=4;return RSAUtils.reverseStr(i)},RSAUtils.biToHex=function(e){for(var t="",i=(RSAUtils.biHighIndex(e),RSAUtils.biHighIndex(e));i>-1;--i)t+=RSAUtils.digitToHex(e.digits[i]);return t},RSAUtils.charToHex=function(e){var t,i=48,n=i+9,s=97,a=s+25,r=65,o=90;return t=e>=i&&n>=e?e-i:e>=r&&o>=e?10+e-r:e>=s&&a>=e?10+e-s:0},RSAUtils.hexToDigit=function(e){for(var t=0,i=Math.min(e.length,4),n=0;i>n;++n)t<<=4,t|=RSAUtils.charToHex(e.charCodeAt(n));return t},RSAUtils.biFromHex=function(e){for(var t=new BigInt,i=e.length,n=i,s=0;n>0;n-=4,++s)t.digits[s]=RSAUtils.hexToDigit(e.substr(Math.max(n-4,0),Math.min(n,4)));return t},RSAUtils.biFromString=function(e,t){var i="-"==e.charAt(0),n=i?1:0,s=new BigInt,a=new BigInt;a.digits[0]=1;for(var r=e.length-1;r>=n;r--){var o=e.charCodeAt(r),l=RSAUtils.charToHex(o),u=RSAUtils.biMultiplyDigit(a,l);s=RSAUtils.biAdd(s,u),a=RSAUtils.biMultiplyDigit(a,t)}return s.isNeg=i,s},RSAUtils.biDump=function(e){return(e.isNeg?"-":"")+e.digits.join(" ")},RSAUtils.biAdd=function(e,t){var i;if(e.isNeg!=t.isNeg)t.isNeg=!t.isNeg,i=RSAUtils.biSubtract(e,t),t.isNeg=!t.isNeg;else{i=new BigInt;for(var n,s=0,a=0;a<e.digits.length;++a)n=e.digits[a]+t.digits[a]+s,i.digits[a]=n%biRadix,s=Number(n>=biRadix);i.isNeg=e.isNeg}return i},RSAUtils.biSubtract=function(e,t){var i;if(e.isNeg!=t.isNeg)t.isNeg=!t.isNeg,i=RSAUtils.biAdd(e,t),t.isNeg=!t.isNeg;else{i=new BigInt;var n,s;s=0;for(var a=0;a<e.digits.length;++a)n=e.digits[a]-t.digits[a]+s,i.digits[a]=n%biRadix,i.digits[a]<0&&(i.digits[a]+=biRadix),s=0-Number(0>n);if(-1==s){s=0;for(var a=0;a<e.digits.length;++a)n=0-i.digits[a]+s,i.digits[a]=n%biRadix,i.digits[a]<0&&(i.digits[a]+=biRadix),s=0-Number(0>n);i.isNeg=!e.isNeg}else i.isNeg=e.isNeg}return i},RSAUtils.biHighIndex=function(e){for(var t=e.digits.length-1;t>0&&0==e.digits[t];)--t;return t},RSAUtils.biNumBits=function(e){var t,i=RSAUtils.biHighIndex(e),n=e.digits[i],s=(i+1)*bitsPerDigit;for(t=s;t>s-bitsPerDigit&&0==(32768&n);--t)n<<=1;return t},RSAUtils.biMultiply=function(e,t){for(var i,n,s,a=new BigInt,r=RSAUtils.biHighIndex(e),o=RSAUtils.biHighIndex(t),l=0;o>=l;++l){i=0,s=l;for(var u=0;r>=u;++u,++s)n=a.digits[s]+e.digits[u]*t.digits[l]+i,a.digits[s]=n&maxDigitVal,i=n>>>biRadixBits;a.digits[l+r+1]=i}return a.isNeg=e.isNeg!=t.isNeg,a},RSAUtils.biMultiplyDigit=function(e,t){var i,n,s,a=new BigInt;i=RSAUtils.biHighIndex(e),n=0;for(var r=0;i>=r;++r)s=a.digits[r]+e.digits[r]*t+n,a.digits[r]=s&maxDigitVal,n=s>>>biRadixBits;return a.digits[1+i]=n,a},RSAUtils.arrayCopy=function(e,t,i,n,s){for(var a=Math.min(t+s,e.length),r=t,o=n;a>r;++r,++o)i[o]=e[r]};var highBitMasks=[0,32768,49152,57344,61440,63488,64512,65024,65280,65408,65472,65504,65520,65528,65532,65534,65535];RSAUtils.biShiftLeft=function(e,t){var i=Math.floor(t/bitsPerDigit),n=new BigInt;RSAUtils.arrayCopy(e.digits,0,n.digits,i,n.digits.length-i);for(var s=t%bitsPerDigit,a=bitsPerDigit-s,r=n.digits.length-1,o=r-1;r>0;--r,--o)n.digits[r]=n.digits[r]<<s&maxDigitVal|(n.digits[o]&highBitMasks[s])>>>a;return n.digits[0]=n.digits[r]<<s&maxDigitVal,n.isNeg=e.isNeg,n};var lowBitMasks=[0,1,3,7,15,31,63,127,255,511,1023,2047,4095,8191,16383,32767,65535];RSAUtils.biShiftRight=function(e,t){var i=Math.floor(t/bitsPerDigit),n=new BigInt;RSAUtils.arrayCopy(e.digits,i,n.digits,0,e.digits.length-i);for(var s=t%bitsPerDigit,a=bitsPerDigit-s,r=0,o=r+1;r<n.digits.length-1;++r,++o)n.digits[r]=n.digits[r]>>>s|(n.digits[o]&lowBitMasks[s])<<a;return n.digits[n.digits.length-1]>>>=s,n.isNeg=e.isNeg,n},RSAUtils.biMultiplyByRadixPower=function(e,t){var i=new BigInt;return RSAUtils.arrayCopy(e.digits,0,i.digits,t,i.digits.length-t),i},RSAUtils.biDivideByRadixPower=function(e,t){var i=new BigInt;return RSAUtils.arrayCopy(e.digits,t,i.digits,0,i.digits.length-t),i},RSAUtils.biModuloByRadixPower=function(e,t){var i=new BigInt;return RSAUtils.arrayCopy(e.digits,0,i.digits,0,t),i},RSAUtils.biCompare=function(e,t){if(e.isNeg!=t.isNeg)return 1-2*Number(e.isNeg);for(var i=e.digits.length-1;i>=0;--i)if(e.digits[i]!=t.digits[i])return e.isNeg?1-2*Number(e.digits[i]>t.digits[i]):1-2*Number(e.digits[i]<t.digits[i]);return 0},RSAUtils.biDivideModulo=function(e,t){var i,n,s=RSAUtils.biNumBits(e),a=RSAUtils.biNumBits(t),r=t.isNeg;if(a>s)return e.isNeg?(i=RSAUtils.biCopy(bigOne),i.isNeg=!t.isNeg,e.isNeg=!1,t.isNeg=!1,n=biSubtract(t,e),e.isNeg=!0,t.isNeg=r):(i=new BigInt,n=RSAUtils.biCopy(e)),[i,n];i=new BigInt,n=e;for(var o=Math.ceil(a/bitsPerDigit)-1,l=0;t.digits[o]<biHalfRadix;)t=RSAUtils.biShiftLeft(t,1),++l,++a,o=Math.ceil(a/bitsPerDigit)-1;n=RSAUtils.biShiftLeft(n,l),s+=l;for(var u=Math.ceil(s/bitsPerDigit)-1,d=RSAUtils.biMultiplyByRadixPower(t,u-o);-1!=RSAUtils.biCompare(n,d);)++i.digits[u-o],n=RSAUtils.biSubtract(n,d);for(var c=u;c>o;--c){var h=c>=n.digits.length?0:n.digits[c],p=c-1>=n.digits.length?0:n.digits[c-1],m=c-2>=n.digits.length?0:n.digits[c-2],f=o>=t.digits.length?0:t.digits[o],g=o-1>=t.digits.length?0:t.digits[o-1];h==f?i.digits[c-o-1]=maxDigitVal:i.digits[c-o-1]=Math.floor((h*biRadix+p)/f);for(var v=i.digits[c-o-1]*(f*biRadix+g),b=h*biRadixSquared+(p*biRadix+m);v>b;)--i.digits[c-o-1],v=i.digits[c-o-1]*(f*biRadix|g),b=h*biRadix*biRadix+(p*biRadix+m);d=RSAUtils.biMultiplyByRadixPower(t,c-o-1),n=RSAUtils.biSubtract(n,RSAUtils.biMultiplyDigit(d,i.digits[c-o-1])),n.isNeg&&(n=RSAUtils.biAdd(n,d),--i.digits[c-o-1])}return n=RSAUtils.biShiftRight(n,l),i.isNeg=e.isNeg!=r,e.isNeg&&(i=r?RSAUtils.biAdd(i,bigOne):RSAUtils.biSubtract(i,bigOne),t=RSAUtils.biShiftRight(t,l),n=RSAUtils.biSubtract(t,n)),0==n.digits[0]&&0==RSAUtils.biHighIndex(n)&&(n.isNeg=!1),[i,n]},RSAUtils.biDivide=function(e,t){return RSAUtils.biDivideModulo(e,t)[0]},RSAUtils.biModulo=function(e,t){return RSAUtils.biDivideModulo(e,t)[1]},RSAUtils.biMultiplyMod=function(e,t,i){return RSAUtils.biModulo(RSAUtils.biMultiply(e,t),i)},RSAUtils.biPow=function(e,t){for(var i=bigOne,n=e;;){if(0!=(1&t)&&(i=RSAUtils.biMultiply(i,n)),t>>=1,0==t)break;n=RSAUtils.biMultiply(n,n)}return i},RSAUtils.biPowMod=function(e,t,i){for(var n=bigOne,s=e,a=t;;){if(0!=(1&a.digits[0])&&(n=RSAUtils.biMultiplyMod(n,s,i)),a=RSAUtils.biShiftRight(a,1),0==a.digits[0]&&0==RSAUtils.biHighIndex(a))break;s=RSAUtils.biMultiplyMod(s,s,i)}return n},u.BarrettMu=function(e){this.modulus=RSAUtils.biCopy(e),this.k=RSAUtils.biHighIndex(this.modulus)+1;var t=new BigInt;t.digits[2*this.k]=1,this.mu=RSAUtils.biDivide(t,this.modulus),this.bkplus1=new BigInt,this.bkplus1.digits[this.k+1]=1,this.modulo=BarrettMu_modulo,this.multiplyMod=BarrettMu_multiplyMod,this.powMod=BarrettMu_powMod};var RSAKeyPair=function(e,t,i){var n=RSAUtils;this.e=n.biFromHex(e),this.d=n.biFromHex(t),this.m=n.biFromHex(i),this.chunkSize=2*n.biHighIndex(this.m),this.radix=16,this.barrett=new u.BarrettMu(this.m)};RSAUtils.getKeyPair=function(e,t,i){return new RSAKeyPair(e,t,i)},"undefined"==typeof u.twoDigit&&(u.twoDigit=function(e){return(10>e?"0":"")+String(e)}),RSAUtils._encryptedString=function(e,t){for(var i=[],n=t.length,s=0;n>s;)i[s]=t.charCodeAt(s),s++;for(;i.length%e.chunkSize!=0;)i[s++]=0;var a,r,o,l=i.length,u="";for(s=0;l>s;s+=e.chunkSize){for(o=new BigInt,a=0,r=s;r<s+e.chunkSize;++a,r++)o.digits[a]=i[r],o.digits[a]+=i[r]<<8;var d=e.barrett.powMod(o,e.e),c=16==e.radix?RSAUtils.biToHex(d):RSAUtils.biToString(d,e.radix);u+=c+" "}return u.substring(0,u.length-1)},RSAUtils._decryptedString=function(e,t){var i,n,s,a=t.split(" "),r="";for(i=0;i<a.length;++i){var o;for(o=16==e.radix?RSAUtils.biFromHex(a[i]):RSAUtils.biFromString(a[i],e.radix),s=e.barrett.powMod(o,e.d),n=0;n<=RSAUtils.biHighIndex(s);++n)r+=String.fromCharCode(255&s.digits[n],s.digits[n]>>8)}return 0==r.charCodeAt(r.length-1)&&(r=r.substring(0,r.length-1)),r},RSAUtils.setMaxDigits(130),RSAUtils.encryptedString=function(e){var t=e.text;if(e.exponent&&e.modulus){var i=RSAUtils.getKeyPair(e.exponent,"",e.modulus);t=RSAUtils._encryptedString(i,e.text)}return t},RSAUtils.decryptedString=function(e){var t=e.text;if(e.exponent&&e.modulus){var i=RSAUtils.getKeyPair("",e.exponent,e.modulus);t=RSAUtils._decryptedString(i,e.text)}return t},AbstractMasker.prototype.format=function(e){if(null==e)return null;var t=this.formatArgument(e);return this.innerFormat(t)},AbstractMasker.prototype.formatArgument=function(e){},AbstractMasker.prototype.innerFormat=function(e){},AbstractSplitMasker.prototype=new AbstractMasker,AbstractSplitMasker.prototype.elements=new Array,AbstractSplitMasker.prototype.format=function(e){if(null==e)return null;var t=this.formatArgument(e);return this.innerFormat(t)},AbstractSplitMasker.prototype.formatArgument=function(e){return e},AbstractSplitMasker.prototype.innerFormat=function(e){if(null==e||""==e)return new FormatResult(e);this.doSplit();var t="";return t=this.getElementsValue(this.elements,e),new FormatResult(t)},AbstractSplitMasker.prototype.getElementsValue=function(e,t){var i="";if(e instanceof Array)for(var n=0;n<e.length;n++)i+=this.getElementsValue(e[n],t);else e.getValue&&(i=e.getValue(t));return i},AbstractSplitMasker.prototype.getExpress=function(){},AbstractSplitMasker.prototype.doSplit=function(){var e=this.getExpress();(null==this.elements||0==this.elements.length)&&(this.elements=this.doQuotation(e,this.getSeperators(),this.getReplaceds(),0))},AbstractSplitMasker.prototype.doQuotation=function(e,t,i,n){if(0==e.length)return null;var s,a=new Array,r=new RegExp('".*?"',"g"),o=0;do if(s=r.exec(e),null!=s){var l=s.index,u=r.lastIndex;if(l!=u&&l>o){var d=this.doSeperator(e.substring(o,l),t,i,n);null!=d&&d.length>0&&a.push(d)}a.push(new StringElement(e.substring(l+1,u-1))),o=u}while(null!=s);if(o<e.length){var d=this.doSeperator(e.substring(o,e.length),t,i,n);null!=d&&d.length>0&&a.push(d)}return a},AbstractSplitMasker.prototype.doSeperator=function(e,t,i,n){if(n>=t.length){var s=new Array;return s.push(this.getVarElement(e)),s}if(0==e.length)return null;var a,r=0,s=new Array,o=new RegExp(t[n],"g");do if(a=o.exec(e),null!=a){var l=a.index,u=o.lastIndex;if(l!=u){if(l>r){var d=this.doSeperator(e.substring(r,l),t,i,n+1);null!=d&&d.length>0&&s.push(d)}null!=i[n]?s.push(new StringElement(i[n])):s.push(new StringElement(e.substring(l,u))),r=u}}while(null!=a);if(r<e.length){var d=this.doSeperator(e.substring(r,e.length),t,i,n+1);null!=d&&d.length>0&&s.push(d)}return s},AddressMasker.prototype=new AbstractSplitMasker,AddressMasker.prototype.update=function(e){this.formatMeta=u.extend({},AddressMasker.DefaultFormatMeta,e)},AddressMasker.prototype.getExpress=function(){return this.formatMeta.express},AddressMasker.prototype.getReplaceds=function(){return[this.formatMeta.separator]},AddressMasker.prototype.getSeperators=function(){return["(\\s)+?"]},AddressMasker.prototype.getVarElement=function(e){var t={};return"C"==e&&(t.getValue=function(e){return e.country}),"S"==e&&(t.getValue=function(e){return e.state}),"T"==e&&(t.getValue=function(e){return e.city}),"D"==e&&(t.getValue=function(e){return e.section}),"R"==e&&(t.getValue=function(e){return e.road}),"P"==e&&(t.getValue=function(e){return e.postcode}),void 0==typeof t.getValue?new StringElement(e):t},AddressMasker.prototype.formatArgument=function(e){return e},NumberMasker.prototype=new AbstractMasker,NumberMasker.prototype.formatMeta=null,NumberMasker.prototype.update=function(e){this.formatMeta=u.extend({},NumberMasker.DefaultFormatMeta,e)},NumberMasker.prototype.innerFormat=function(e){var t,i,n,s;t=e.value,t>0?(i=this.formatMeta.positiveFormat,s=t+""):0>t?(i=this.formatMeta.negativeFormat, s=(t+"").substr(1,(t+"").length-1)):(i=this.formatMeta.positiveFormat,s=t+""),n=s.indexOf("."),s=this.setTheSeperator(s,n),s=this.setTheMark(s,n);var a=null;return 0>t&&this.formatMeta.isNegRed&&(a="FF0000"),new FormatResult(i.replaceAll("n",s),a)},NumberMasker.prototype.setTheMark=function(e,t){var i,n,s;if(!this.formatMeta.isMarkEnable)return e;for(0>=t&&(t=e.length),n=e.charCodeAt(0),i=0,45==n&&(i=1),s=t-3;s>i;)e=e.substr(0,s-0)+this.formatMeta.markSymbol+e.substr(s,e.length-s),s-=3;return e},NumberMasker.prototype.setTheSeperator=function(e,t){var i;return t>0&&(i=NumberMasker.toCharArray(e),i[t]=this.formatMeta.pointSymbol,e=i.join("")),e},NumberMasker.toCharArray=function(e){for(var e=e.split(""),t=new Array,i=0;i<e.length;i++)t.push(e[i]);return t},NumberMasker.prototype.formatArgument=function(e){var t={};return t.value=e,t},CurrencyMasker.prototype=new NumberMasker,CurrencyMasker.prototype.formatMeta=null,CurrencyMasker.prototype.update=function(e){this.formatMeta=u.extend({},CurrencyMasker.DefaultFormatMeta,e)},CurrencyMasker.prototype.innerFormat=function(e){if(!e.value)return{value:""};var t=new NumberMasker(this.formatMeta).innerFormat(e);return t.value=this.formatMeta.curSymbol+t.value,t},DateTimeMasker.prototype=new AbstractSplitMasker,DateTimeMasker.prototype.formatMeta=null,DateTimeMasker.prototype.update=function(e){this.formatMeta=u.extend({},DateTimeMasker.DefaultFormatMeta,e)},DateTimeMasker.enShortMonth=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],DateTimeMasker.enLongMonth=["January","February","March","April","May","June","July","August","September","October","November","December"],DateTimeMasker.prototype.doOne=function(e){if(0==e.length)return"";var t=new Object;return"yyyy"==e.toLowerCase()&&(t.getValue=function(e){return DateTimeMasker.getyyyy(e)}),"yy"==e.toLowerCase()&&(t.getValue=function(e){return DateTimeMasker.getyy(e)}),"MMMM"==e&&(t.getValue=function(e){return DateTimeMasker.getMMMM(e)}),"MMM"==e&&(t.getValue=function(e){return DateTimeMasker.getMMM(e)}),"MM"==e&&(t.getValue=function(e){return DateTimeMasker.getMM(e)}),"M"==e&&(t.getValue=function(e){return DateTimeMasker.getM(e)}),"dd"==e.toLowerCase()&&(t.getValue=function(e){return DateTimeMasker.getdd(e)}),"d"==e.toLowerCase()&&(t.getValue=function(e){return DateTimeMasker.getd(e)}),"hh"==e&&(t.getValue=function(e){return DateTimeMasker.gethh(e)}),"h"==e&&(t.getValue=function(e){return DateTimeMasker.geth(e)}),"mm"==e&&(t.getValue=function(e){return DateTimeMasker.getmm(e)}),"m"==e&&(t.getValue=function(e){return DateTimeMasker.getm(e)}),"ss"==e&&(t.getValue=function(e){return DateTimeMasker.getss(e)}),"s"==e&&(t.getValue=function(e){return DateTimeMasker.gets(e)}),"HH"==e&&(t.getValue=function(e){return DateTimeMasker.getHH(e)}),"H"==e&&(t.getValue=function(e){return DateTimeMasker.getH(e)}),"t"==e&&(t.getValue=function(e){return DateTimeMasker.gett(e)}),"st"==e&&(t.getValue=function(e){return DateTimeMasker.gets(e)+DateTimeMasker.gett(e)}),"mt"==e&&(t.getValue=function(e){return DateTimeMasker.getm(e)+DateTimeMasker.gett(e)}),"yyyyMMdd"==e&&(t.getValue=function(e){return DateTimeMasker.getyyyy(e)+DateTimeMasker.getMM(e)+DateTimeMasker.getdd(e)}),"undefined"==typeof t.getValue&&(t.getValue=function(e){return DateTimeMasker.getyyyy(e)+"-"+DateTimeMasker.getMM(e)+"-"+DateTimeMasker.getdd(e)}),t},DateTimeMasker.getyyyy=function(e){return e.getFullYear()},DateTimeMasker.getyy=function(e){return(""+e.getFullYear()).substring(2)},DateTimeMasker.getM=function(e){return""+(e.getMonth()+1)},DateTimeMasker.getMM=function(e){var t=e.getMonth()+1;return 10>t?"0"+t:t},DateTimeMasker.getMMM=function(e){return this.enShortMonth[e.getMonth()]},DateTimeMasker.getMMMM=function(e){return this.enLongMonth[e.getMonth()]},DateTimeMasker.getdd=function(e){var t=e.getDate();return 10>t?"0"+t:e.getDate()+""},DateTimeMasker.getd=function(e){return e.getDate()+""},DateTimeMasker.gethh=function(e){var t=e.getHours();return 10>t?"0"+t:e.getHours()+""},DateTimeMasker.geth=function(e){return e.getHours()+""},DateTimeMasker.getHH=function(e){var t=e.getHours();return t>=12&&(t-=12),10>t?"0"+t:t+""},DateTimeMasker.getH=function(e){var t=e.getHours();return t>=12&&(t-=12),t+""},DateTimeMasker.getmm=function(e){var t=e.getMinutes();return 10>t?"0"+t:e.getMinutes()+""},DateTimeMasker.getm=function(e){return""+e.getMinutes()},DateTimeMasker.getss=function(e){var t=e.getSeconds();return 10>t?"0"+t:t+""},DateTimeMasker.gets=function(e){return e.getSeconds()+""},DateTimeMasker.gett=function(e){var t=e.getHours();return 12>=t?"AM":"PM"},DateTimeMasker.prototype.getExpress=function(){return this.formatMeta.format},DateTimeMasker.prototype.getReplaceds=function(){return[" ",this.formatMeta.speratorSymbol,":"]},DateTimeMasker.prototype.getSeperators=function(){return["(\\s)+?","-",":"]},DateTimeMasker.prototype.getVarElement=function(e){return this.doOne(e)},DateTimeMasker.prototype.formatArgument=function(e){if(0==e)return"";if(null==e||""==e)return e;if("string"==typeof e){var t=e.split(" "),i=new Date;if(t.length>0)if(t[0].indexOf("-")>0){var n=t[0].split("-");if(i.setDate(1),i.setFullYear(parseInt(n[0],10)),i.setMonth(parseInt(n[1],10)-1),i.setDate(parseInt(n[2],10)),2==t.length&&void 0!=t[1]){var s=t[1].split(":");i.setHours(parseInt(s[0],10)),i.setMinutes(parseInt(s[1],10)),i.setSeconds(parseInt(s[2],10)),s.length>3&&i.setMilliseconds(parseInt(s[3],10))}}else{var s=t[0].split(":");i.setHours(parseInt(s[0],10)),i.setMinutes(parseInt(s[1],10)),i.setSeconds(parseInt(s[2],10)),s.length>3&&i.setMilliseconds(parseInt(s[3],10))}return i}return e},DateMasker.prototype=new DateTimeMasker,DateMasker.DefaultFormatMeta=u.extend({},DateTimeMasker.DefaultFormatMeta,{format:"yyyy-MM-dd"}),DateMasker.prototype.update=function(e){this.formatMeta=u.extend({},DateMasker.DefaultFormatMeta,e)},TimeMasker.prototype=new DateTimeMasker,TimeMasker.DefaultFormatMeta=u.extend({},DateTimeMasker.DefaultFormatMeta,{format:"hh:mm:ss"}),TimeMasker.prototype.update=function(e){this.formatMeta=u.extend({},TimeMasker.DefaultFormatMeta,e)},PercentMasker.prototype=new AbstractMasker,PercentMasker.prototype.formatArgument=function(e){return e},PercentMasker.prototype.innerFormat=function(e){var t="";if(""!=e){var i=String(e),n=i.length-i.indexOf(".")-1,s=n-2;0>s&&(s=0),t=100*parseFloat(e),t=(t*Math.pow(10,s)/Math.pow(10,s)).toFixed(s),t+="%"}return{value:t}},StringElement.prototype=new Object,StringElement.prototype.value="",StringElement.prototype.getValue=function(e){return this.value},FormatResult.prototype=new Object,NumberMasker.DefaultFormatMeta={isNegRed:!0,isMarkEnable:!0,markSymbol:",",pointSymbol:".",positiveFormat:"n",negativeFormat:"-n"},CurrencyMasker.DefaultFormatMeta=u.extend({},NumberMasker.DefaultFormatMeta,{positiveFormat:"n",negativeFormat:"-n"}),AddressMasker.defaultFormatMeta={express:"C S T R P",separator:" "},DateTimeMasker.DefaultFormatMeta={format:"yyyy-MM-dd hh:mm:ss",speratorSymbol:"-"},u.AddressMasker=AddressMasker,u.NumberMasker=NumberMasker,u.CurrencyMasker=CurrencyMasker,u.DateTimeMasker=DateTimeMasker,u.DateMasker=DateMasker,u.TimeMasker=TimeMasker,u.PercentMasker=PercentMasker,NumberFormater.prototype.update=function(e){this.precision=e},NumberFormater.prototype.format=function(e){if(!u.isNumber(e))return"";for(;"0"==(e+"").charAt(0)&&e.length>1;)e=e.substring(1);var t=e;if(u.isNumber(this.precision)){if(window.BigNumber)t=new BigNumber(e).toFixed(this.precision);else{var i=parseFloat(e);t=(Math.round(i*Math.pow(10,this.precision))/Math.pow(10,this.precision)).toFixed(this.precision)}if("NaN"==t)return""}return t},DateFormater.prototype.update=function(e){this.pattern=e},DateFormater.prototype.format=function(e){return moment(e).format(this.pattern)},u.NumberFormater=NumberFormater,u.DateFormater=DateFormater,u.date={_dateLocale:{"zh-CN":{months:"一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"),weekdaysShort:"周日_周一_周二_周三_周四_周五_周六".split("_"),weekdaysMin:"日_一_二_三_四_五_六".split("_")},"en-US":{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thurday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"S_M_T_W_T_F_S".split("_")}},_formattingTokens:/(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Q|YYYY|YY|e|E|a|A|hh?|HH?|mm?|ss?|S{1,4}|x|X|zz?|ZZ?|.)/g,leftZeroFill:function(e,t,i){for(var n=""+Math.abs(e),s=e>=0;n.length<t;)n="0"+n;return(s?i?"+":"":"-")+n},_formats:{YY:function(e){return u.date.leftZeroFill(e.getFullYear()%100,2)},YYYY:function(e){return e.getFullYear()},M:function(e){return e.getMonth()+1},MM:function(e){var t=u.date._formats.M(e);return u.date.leftZeroFill(t,2)},MMM:function(e,t){var i=e.getMonth();return u.date._dateLocale[t].monthsShort[i]},MMMM:function(e,t){var i=e.getMonth();return u.date._dateLocale[t].months[i]},D:function(e){return e.getDate()},DD:function(e){var t=u.date._formats.D(e);return u.date.leftZeroFill(t,2)},d:function(e){return e.getDay()},dd:function(e,t){var i=u.date._formats.d(e);return u.date._dateLocale[t].weekdaysMin[i]},ddd:function(e,t){var i=u.date._formats.d(e);return u.date._dateLocale[t].weekdaysShort[i]},dddd:function(e,t){var i=u.date._formats.d(e);return u.date._dateLocale[t].weekdays[i]},a:function(e){return e.getHours()>12?"pm":"am"},h:function(e){var t=e.getHours();return t=t>12?t-12:t},hh:function(e){var t=u.date._formats.h(e);return u.date.leftZeroFill(t,2)},H:function(e){return e.getHours()},HH:function(e){return u.date.leftZeroFill(e.getHours(),2)},m:function(e){return e.getMinutes()},mm:function(e){return u.date.leftZeroFill(e.getMinutes(),2)},s:function(e){return e.getSeconds()},ss:function(e){return u.date.leftZeroFill(e.getSeconds(),2)}},format:function(e,t,i){var n,s,a=t.match(u.date._formattingTokens),r="";for(i=i||u.core.getLanguages(),n=0,s=a.length;s>n;n++)r+=u.date._formats[a[n]]?u.date._formats[a[n]](e,i):a[n];return r},_addOrSubtract:function(e,t,i,n){var s=e.getTime(),a=e.getDate(),r=e.getMonth(),o=new Date(e);return"ms"===t?(s+=i*n,o.setTime(s)):"s"==t?(s+=1e3*i*n,o.setTime(s)):"m"==t?(s+=6e4*i*n,o.setTime(s)):"h"==t?(s+=36e5*i*n,o.setTime(s)):"d"==t?(a+=i*n,o.setDate(a)):"w"==t?(a+=7*i*n,o.setDate(a)):"M"==t?(r+=i*n,o.setMonth(a)):"y"==t&&(r+=12*i*n,o.setMonth(a)),o},add:function(e,t,i){return u.date._addOrSubtract(e,t,i,1)},sub:function(e,t,i){return u.date._addOrSubtract(e,t,i,-1)}},u.floatRender=function(e,t){var i=e;if("undefined"==typeof e||null===e)return e;"function"==typeof e&&(i=e());var n=u.Core.getMaskerMeta("float")||{};"number"==typeof t&&(n.precision=t);var s=new $.NumberFormater(n.precision),a=new NumberMasker(n);return a.format(s.format(i)).value},u.integerRender=function(e){var t=e;return"undefined"==typeof e||null===e?e:("function"==typeof e&&(t=e()),t)},u.dateRender=function(e,t){var i=e;if("undefined"==typeof e||null===e)return e;"function"==typeof e&&(i=e());var n=u.Core.getMaskerMeta("date")||{};"undefined"!=typeof t&&(n.format=t);var s=new DateMasker(n);return s.format(i).value},u.dateTimeRender=function(e,t){var i=e;if("undefined"==typeof e||null===e)return e;"function"==typeof e&&(i=e());var n=u.Core.getMaskerMeta("datetime")||{};"undefined"!=typeof t&&(n.format=t);var s=new DateTimeMasker(n);return s.format(i).value},u.timeRender=function(e,t){var i=e;if("undefined"==typeof e||null===e)return e;"function"==typeof e&&(i=e());var n=u.Core.getMaskerMeta("time")||{};"undefined"!=typeof t&&(n.format=t);var s=new TimeMasker(n);return s.format(i).value},u.percentRender=function(e){var t=e;if("undefined"==typeof e||null===e)return e;"function"==typeof e&&(t=e());var i=u.Core.getMaskerMeta("percent")||{},n=new PercentMasker(i);return n.format(t).value},u.dateToUTCString=function(e){if(!e)return"";e.indexOf("-")>-1&&(e=e.replace(/\-/g,"/"));var t=Date.parse(e);return isNaN(t)?"":t};var _hotkeys={};_hotkeys.special_keys={27:"esc",9:"tab",32:"space",13:"enter",8:"backspace",145:"scroll",20:"capslock",144:"numlock",19:"pause",45:"insert",36:"home",46:"del",35:"end",33:"pageup",34:"pagedown",37:"left",38:"up",39:"right",40:"down",112:"f1",113:"f2",114:"f3",115:"f4",116:"f5",117:"f6",118:"f7",119:"f8",120:"f9",121:"f10",122:"f11",123:"f12"},_hotkeys.shift_nums={"`":"~",1:"!",2:"@",3:"#",4:"$",5:"%",6:"^",7:"&",8:"*",9:"(",0:")","-":"_","=":"+",";":":","'":'"',",":"<",".":">","/":"?","\\":"|"},_hotkeys.add=function(e,t,i){u.isFunction(t)&&(i=t,t={});var n={},s={type:"keydown",propagate:!1,disableInInput:!1,target:document.body,checkParent:!0},a=this;n=u.extend(n,s,t||{}),e=e.toLowerCase();var r=function(e){var t=this;if(t=3==t.nodeType?t.parentNode:t,n.disableInInput){var i=t;if("INPUT"==i.tagName||"TEXTAREA"==i.tagName)return}var s=e.which,r=e.type,o=String.fromCharCode(s).toLowerCase(),l=a.special_keys[s],u=e.shiftKey,d=e.ctrlKey,c=e.altKey,h=null;if(n.checkParent)for(;!t["u.hotkeys"]&&t.parentNode;)t=t.parentNode;var p=t["u.hotkeys"].events[r].callbackMap;if(u||d||c){var m="";c&&(m+="alt+"),d&&(m+="ctrl+"),u&&(m+="shift+"),h=p[m+l]||p[m+o]||p[m+a.shift_nums[o]]}else h=p[l]||p[o];return h&&(h.cb(e),!h.propagate)?(e.stopPropagation(),e.preventDefault(),!1):void 0},o=n.target["u.hotkeys"];return o||(n.target["u.hotkeys"]=o={events:{}}),o.events[n.type]||(o.events[n.type]={callbackMap:{}},u.on(n.target,n.type,r)),o.events[n.type].callbackMap[e]={cb:i,propagate:n.propagate},u.hotkeys},_hotkeys.remove=function(e,t){t=t||{},target=t.target||document.body,type=t.type||"keydown",e=e.toLowerCase(),delete target["u.hotkeys"].events[type].callbackMap[e]},_hotkeys.scan=function(e,t){e=e||document.body,e.querySelectorAll("[u-enter]").forEach(function(i){var n=i.getAttribute("u-enter");if(n)if("#"==n.substring(0,1))u.hotkeys.add("enter",{target:this},function(){var t=e.querySelector(n);t&&t.focus()});else{t=t||window;var s=u.getFunction(t,n);u.hotkeys.add("enter",{target:this},function(){s.call(this)})}}),e.querySelectorAll("[u-hotkey]").forEach(function(e){var t=e.getAttribute("u-hotkey");t&&u.hotkeys.add(t,function(){e.click()})})},u.hotkeys=_hotkeys;var BaseComponent=u.Class.create({initialize:function(e){e instanceof HTMLElement?(this.element=e,this.options={}):(this.element=e.el,this.options=e),this.element.ucomp=this,this.compType=this.constructor.compType,this.init()},on:function(e,t){e=e.toLowerCase(),this._events||(this._events={});var i=this._events[e]||(this._events[e]=[]);return i.push({callback:t}),this},trigger:function(e){if(e=e.toLowerCase(),!this._events||!this._events[e])return this;for(var t=Array.prototype.slice.call(arguments,1),i=this._events[e],n=0,s=i.length;s>n;n++)i[n].callback.apply(this,t);return this},init:function(){},render:function(){},destroy:function(){delete this.element.comp,this.element.innerHTML=""},addDomEvent:function(e,t){return u.on(this.element,e,t),this},removeDomEvent:function(e,t){return u.off(this.element,e,t),this},setEnable:function(e){return this},isDomEvent:function(e){return void 0===this.element["on"+e]?!1:!0},createDateAdapter:function(e){var t=e.options,i=(e.model,u.compMgr.getDataAdapter(this.compType,t.dataType));i&&(this.dataAdapter=new i(this,e))},Statics:{compName:"",EVENT_VALUE_CHANGE:"valueChange",getName:function(){return this.compName}}});u.BaseComponent=BaseComponent;var URipple=function(e){u.isIE8||(this._element=e,this.init())};URipple.prototype._down=function(e){if(!this._rippleElement.style.width&&!this._rippleElement.style.height){var t=this._element.getBoundingClientRect();this.rippleSize_=2*Math.sqrt(t.width*t.width+t.height*t.height)+2,this._rippleElement.style.width=this.rippleSize_+"px",this._rippleElement.style.height=this.rippleSize_+"px"}if(u.addClass(this._rippleElement,"is-visible"),"mousedown"===e.type&&this._ignoringMouseDown)this._ignoringMouseDown=!1;else{"touchstart"===e.type&&(this._ignoringMouseDown=!0);var i=this.getFrameCount();if(i>0)return;this.setFrameCount(1);var n,s,a=e.currentTarget.getBoundingClientRect();if(0===e.clientX&&0===e.clientY)n=Math.round(a.width/2),s=Math.round(a.height/2);else{var r=e.clientX?e.clientX:e.touches[0].clientX,o=e.clientY?e.clientY:e.touches[0].clientY;n=Math.round(r-a.left),s=Math.round(o-a.top)}this.setRippleXY(n,s),this.setRippleStyles(!0),window.requestAnimationFrame(this.animFrameHandler.bind(this))}},URipple.prototype._up=function(e){var t=this;e&&2!==e.detail&&u.removeClass(this._rippleElement,"is-visible"),window.setTimeout(function(){u.removeClass(t._rippleElement,"is-visible")},0)},URipple.prototype.init=function(){var e=this;this._element&&(this._rippleElement=this._element.querySelector(".u-ripple"),this._rippleElement||(this._rippleElement=document.createElement("span"),u.addClass(this._rippleElement,"u-ripple"),this._element.appendChild(this._rippleElement),this._element.style.overflow="hidden",this._element.style.position="relative"),this.frameCount_=0,this.rippleSize_=0,this.x_=0,this.y_=0,this._ignoringMouseDown=!1,u.on(this._element,"mousedown",function(t){e._down(t)}),u.on(this._element,"touchstart",function(t){e._down(t)}),u.on(this._element,"mouseup",function(t){e._up(t)}),u.on(this._element,"mouseleave",function(t){e._up(t)}),u.on(this._element,"touchend",function(t){e._up(t)}),u.on(this._element,"blur",function(t){e._up(t)}),this.getFrameCount=function(){return this.frameCount_},this.setFrameCount=function(e){this.frameCount_=e},this.getRippleElement=function(){return this._rippleElement},this.setRippleXY=function(e,t){this.x_=e,this.y_=t},this.setRippleStyles=function(e){if(null!==this._rippleElement){var t,i,n,s="translate("+this.x_+"px, "+this.y_+"px)";e?(i="scale(0.0001, 0.0001)",n="1px"):(i="",n=this.rippleSize_+"px"),t="translate(-50%, -50%) "+s+i,this._rippleElement.style