fineui是帆软报表和BI产品线所使用的前端框架。
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

3 lines
1.9 MiB

/*! time: 2021-7-12 20:10:46 */
/*! For license information please see fineui.min.js.LICENSE.txt */
!function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}n.m=e,n.c=t,n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(i,r,function(t){return e[t]}.bind(null,r));return i},n.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=1194)}([function(e,t,n){var i=n(5),r=n(11),a=n(20),o=n(17),s=n(23),l=function(e,t,n){var u,c,h,p,d=e&l.F,f=e&l.G,g=e&l.S,m=e&l.P,I=e&l.B,B=f?i:g?i[t]||(i[t]={}):(i[t]||{}).prototype,_=f?r:r[t]||(r[t]={}),E=_.prototype||(_.prototype={});for(u in f&&(n=t),n)h=((c=!d&&B&&B[u]!==undefined)?B:n)[u],p=I&&c?s(h,i):m&&"function"==typeof h?s(Function.call,h):h,B&&o(B,u,h,e&l.U),_[u]!=h&&a(_,u,p),m&&E[u]!=h&&(E[u]=h)};i.core=r,l.F=1,l.G=2,l.S=4,l.P=8,l.B=16,l.W=32,l.U=64,l.R=128,e.exports=l},function(e,t,n){"use strict";n(29)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(2)},function(e,t){var n=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(e,t){e.exports=function(e){try{return!!e()}catch(t){return!0}}},function(e,t,n){var i=n(8);e.exports=function(e){if(!i(e))throw TypeError(e+" is not an object!");return e}},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t,n){var i=n(76)("wks"),r=n(37),a=n(5).Symbol,o="function"==typeof a;(e.exports=function(e){return i[e]||(i[e]=o&&a[e]||(o?a:r)("Symbol."+e))}).store=i},function(e,t,n){var i=n(25),r=Math.min;e.exports=function(e){return e>0?r(i(e),9007199254740991):0}},function(e,t){var n=e.exports={version:"2.6.11"};"number"==typeof __e&&(__e=n)},function(e,t,n){e.exports=!n(6)((function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}))},function(e,t,n){var i=n(7),r=n(883),a=n(34),o=Object.defineProperty;t.f=n(12)?Object.defineProperty:function(e,t,n){if(i(e),t=a(t,!0),i(n),r)try{return o(e,t,n)}catch(s){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},function(e,t,n){"use strict";function i(e){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var r;r=function(){return this}();try{r=r||new Function("return this")()}catch(a){"object"===("undefined"==typeof window?"undefined":i(window))&&(r=window)}e.exports=r},function(e,t,n){var i=n(32);e.exports=function(e){return Object(i(e))}},function(e,t,n){"use strict";n(1)},function(e,t,n){var i=n(5),r=n(20),a=n(19),o=n(37)("src"),s=n(939),l="toString",u=(""+s).split(l);n(11).inspectSource=function(e){return s.call(e)},(e.exports=function(e,t,n,s){var l="function"==typeof n;l&&(a(n,"name")||r(n,"name",t)),e[t]!==n&&(l&&(a(n,o)||r(n,o,e[t]?""+e[t]:u.join(String(t)))),e===i?e[t]=n:s?e[t]?e[t]=n:r(e,t,n):(delete e[t],r(e,t,n)))})(Function.prototype,l,(function(){return"function"==typeof this&&this[o]||s.call(this)}))},function(e,t,n){var i=n(0),r=n(6),a=n(32),o=/"/g,s=function(e,t,n,i){var r=String(a(e)),s="<"+t;return""!==n&&(s+=" "+n+'="'+String(i).replace(o,"&quot;")+'"'),s+">"+r+"</"+t+">"};e.exports=function(e,t){var n={};n[e]=t(s),i(i.P+i.F*r((function(){var t=""[e]('"');return t!==t.toLowerCase()||t.split('"').length>3})),"String",n)}},function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},function(e,t,n){var i=n(13),r=n(36);e.exports=n(12)?function(e,t,n){return i.f(e,t,r(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t,n){var i=n(62),r=n(32);e.exports=function(e){return i(r(e))}},function(e,t,n){"use strict";var i=n(6);e.exports=function(e,t){return!!e&&i((function(){t?e.call(null,(function(){}),1):e.call(null)}))}},function(e,t,n){var i=n(24);e.exports=function(e,t,n){if(i(e),t===undefined)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,i){return e.call(t,n,i)};case 3:return function(n,i,r){return e.call(t,n,i,r)}}return function(){return e.apply(t,arguments)}}},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t){var n=Math.ceil,i=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?i:n)(e)}},function(e,t,n){var i=n(63),r=n(36),a=n(21),o=n(34),s=n(19),l=n(883),u=Object.getOwnPropertyDescriptor;t.f=n(12)?u:function(e,t){if(e=a(e),t=o(t,!0),l)try{return u(e,t)}catch(n){}if(s(e,t))return r(!i.f.call(e,t),e[t])}},function(e,t,n){var i=n(0),r=n(11),a=n(6);e.exports=function(e,t){var n=(r.Object||{})[e]||Object[e],o={};o[e]=t(n),i(i.S+i.F*a((function(){n(1)})),"Object",o)}},function(e,t,n){var i=n(23),r=n(62),a=n(15),o=n(10),s=n(899);e.exports=function(e,t){var n=1==e,l=2==e,u=3==e,c=4==e,h=6==e,p=5==e||h,d=t||s;return function(t,s,f){for(var g,m,I=a(t),B=r(I),_=i(s,f,3),E=o(B.length),b=0,y=n?d(t,E):l?d(t,0):undefined;E>b;b++)if((p||b in B)&&(m=_(g=B[b],b,I),e))if(n)y[b]=m;else if(m)switch(e){case 3:return!0;case 5:return g;case 6:return b;case 2:y.push(g)}else if(c)return!1;return h?-1:u||c?c:y}}},function(e,t,n){},function(e,t,n){"use strict";n(1)},function(e,t){var n={}.toString;e.exports=function(e){return n.call(e).slice(8,-1)}},function(e,t){e.exports=function(e){if(e==undefined)throw TypeError("Can't call method on "+e);return e}},function(e,t,n){"use strict";if(n(12)){var i=n(38),r=n(5),a=n(6),o=n(0),s=n(87),l=n(198),u=n(23),c=n(58),h=n(36),p=n(20),d=n(59),f=n(25),g=n(10),m=n(910),I=n(40),B=n(34),_=n(19),E=n(64),b=n(8),y=n(15),v=n(190),T=n(41),C=n(43),N=n(42).f,V=n(192),S=n(37),x=n(9),w=n(28),A=n(77),L=n(65),k=n(194),D=n(56),M=n(80),P=n(57),R=n(193),H=n(901),O=n(13),F=n(26),Y=O.f,W=F.f,G=r.RangeError,j=r.TypeError,Z=r.Uint8Array,X="ArrayBuffer",U="SharedArrayBuffer",J="BYTES_PER_ELEMENT",K=Array.prototype,z=l.ArrayBuffer,Q=l.DataView,q=w(0),$=w(2),ee=w(3),te=w(4),ne=w(5),ie=w(6),re=A(!0),ae=A(!1),oe=k.values,se=k.keys,le=k.entries,ue=K.lastIndexOf,ce=K.reduce,he=K.reduceRight,pe=K.join,de=K.sort,fe=K.slice,ge=K.toString,me=K.toLocaleString,Ie=x("iterator"),Be=x("toStringTag"),_e=S("typed_constructor"),Ee=S("def_constructor"),be=s.CONSTR,ye=s.TYPED,ve=s.VIEW,Te="Wrong length!",Ce=w(1,(function(e,t){return we(L(e,e[Ee]),t)})),Ne=a((function(){return 1===new Z(new Uint16Array([1]).buffer)[0]})),Ve=!!Z&&!!Z.prototype.set&&a((function(){new Z(1).set({})})),Se=function(e,t){var n=f(e);if(n<0||n%t)throw G("Wrong offset!");return n},xe=function(e){if(b(e)&&ye in e)return e;throw j(e+" is not a typed array!")},we=function(e,t){if(!b(e)||!(_e in e))throw j("It is not a typed array constructor!");return new e(t)},Ae=function(e,t){return Le(L(e,e[Ee]),t)},Le=function(e,t){for(var n=0,i=t.length,r=we(e,i);i>n;)r[n]=t[n++];return r},ke=function(e,t,n){Y(e,t,{get:function(){return this._d[n]}})},De=function(e){var t,n,i,r,a,o,s=y(e),l=arguments.length,c=l>1?arguments[1]:undefined,h=c!==undefined,p=V(s);if(p!=undefined&&!v(p)){for(o=p.call(s),i=[],t=0;!(a=o.next()).done;t++)i.push(a.value);s=i}for(h&&l>2&&(c=u(c,arguments[2],2)),t=0,n=g(s.length),r=we(this,n);n>t;t++)r[t]=h?c(s[t],t):s[t];return r},Me=function(){for(var e=0,t=arguments.length,n=we(this,t);t>e;)n[e]=arguments[e++];return n},Pe=!!Z&&a((function(){me.call(new Z(1))})),Re=function(){return me.apply(Pe?fe.call(xe(this)):xe(this),arguments)},He={copyWithin:function(e,t){return H.call(xe(this),e,t,arguments.length>2?arguments[2]:undefined)},every:function(e){return te(xe(this),e,arguments.length>1?arguments[1]:undefined)},fill:function(e){return R.apply(xe(this),arguments)},filter:function(e){return Ae(this,$(xe(this),e,arguments.length>1?arguments[1]:undefined))},find:function(e){return ne(xe(this),e,arguments.length>1?arguments[1]:undefined)},findIndex:function(e){return ie(xe(this),e,arguments.length>1?arguments[1]:undefined)},forEach:function(e){q(xe(this),e,arguments.length>1?arguments[1]:undefined)},indexOf:function(e){return ae(xe(this),e,arguments.length>1?arguments[1]:undefined)},includes:function(e){return re(xe(this),e,arguments.length>1?arguments[1]:undefined)},join:function(e){return pe.apply(xe(this),arguments)},lastIndexOf:function(e){return ue.apply(xe(this),arguments)},map:function(e){return Ce(xe(this),e,arguments.length>1?arguments[1]:undefined)},reduce:function(e){return ce.apply(xe(this),arguments)},reduceRight:function(e){return he.apply(xe(this),arguments)},reverse:function(){for(var e,t=this,n=xe(t).length,i=Math.floor(n/2),r=0;r<i;)e=t[r],t[r++]=t[--n],t[n]=e;return t},some:function(e){return ee(xe(this),e,arguments.length>1?arguments[1]:undefined)},sort:function(e){return de.call(xe(this),e)},subarray:function(e,t){var n=xe(this),i=n.length,r=I(e,i);return new(L(n,n[Ee]))(n.buffer,n.byteOffset+r*n.BYTES_PER_ELEMENT,g((t===undefined?i:I(t,i))-r))}},Oe=function(e,t){return Ae(this,fe.call(xe(this),e,t))},Fe=function(e){xe(this);var t=Se(arguments[1],1),n=this.length,i=y(e),r=g(i.length),a=0;if(r+t>n)throw G(Te);for(;a<r;)this[t+a]=i[a++]},Ye={entries:function(){return le.call(xe(this))},keys:function(){return se.call(xe(this))},values:function(){return oe.call(xe(this))}},We=function(e,t){return b(e)&&e[ye]&&"symbol"!=typeof t&&t in e&&String(+t)==String(t)},Ge=function(e,t){return We(e,t=B(t,!0))?h(2,e[t]):W(e,t)},je=function(e,t,n){return!(We(e,t=B(t,!0))&&b(n)&&_(n,"value"))||_(n,"get")||_(n,"set")||n.configurable||_(n,"writable")&&!n.writable||_(n,"enumerable")&&!n.enumerable?Y(e,t,n):(e[t]=n.value,e)};be||(F.f=Ge,O.f=je),o(o.S+o.F*!be,"Object",{getOwnPropertyDescriptor:Ge,defineProperty:je}),a((function(){ge.call({})}))&&(ge=me=function(){return pe.call(this)});var Ze=d({},He);d(Ze,Ye),p(Ze,Ie,Ye.values),d(Ze,{slice:Oe,set:Fe,constructor:function(){},toString:ge,toLocaleString:Re}),ke(Ze,"buffer","b"),ke(Ze,"byteOffset","o"),ke(Ze,"byteLength","l"),ke(Ze,"length","e"),Y(Ze,Be,{get:function(){return this[ye]}}),e.exports=function(e,t,n,l){var u=e+((l=!!l)?"Clamped":"")+"Array",h="get"+e,d="set"+e,f=r[u],I=f||{},B=f&&C(f),_=!f||!s.ABV,y={},v=f&&f.prototype,V=function(e,n){Y(e,n,{get:function(){return function(e,n){var i=e._d;return i.v[h](n*t+i.o,Ne)}(this,n)},set:function(e){return function(e,n,i){var r=e._d;l&&(i=(i=Math.round(i))<0?0:i>255?255:255&i),r.v[d](n*t+r.o,i,Ne)}(this,n,e)},enumerable:!0})};_?(f=n((function(e,n,i,r){c(e,f,u,"_d");var a,o,s,l,h=0,d=0;if(b(n)){if(!(n instanceof z||(l=E(n))==X||l==U))return ye in n?Le(f,n):De.call(f,n);a=n,d=Se(i,t);var I=n.byteLength;if(r===undefined){if(I%t)throw G(Te);if((o=I-d)<0)throw G(Te)}else if((o=g(r)*t)+d>I)throw G(Te);s=o/t}else s=m(n),a=new z(o=s*t);for(p(e,"_d",{b:a,o:d,l:o,e:s,v:new Q(a)});h<s;)V(e,h++)})),v=f.prototype=T(Ze),p(v,"constructor",f)):a((function(){f(1)}))&&a((function(){new f(-1)}))&&M((function(e){new f,new f(null),new f(1.5),new f(e)}),!0)||(f=n((function(e,n,i,r){var a;return c(e,f,u),b(n)?n instanceof z||(a=E(n))==X||a==U?r!==undefined?new I(n,Se(i,t),r):i!==undefined?new I(n,Se(i,t)):new I(n):ye in n?Le(f,n):De.call(f,n):new I(m(n))})),q(B!==Function.prototype?N(I).concat(N(B)):N(I),(function(e){e in f||p(f,e,I[e])})),f.prototype=v,i||(v.constructor=f));var S=v[Ie],x=!!S&&("values"==S.name||S.name==undefined),w=Ye.values;p(f,_e,!0),p(v,ye,u),p(v,ve,!0),p(v,Ee,f),(l?new f(1)[Be]==u:Be in v)||Y(v,Be,{get:function(){return u}}),y[u]=f,o(o.G+o.W+o.F*(f!=I),y),o(o.S,u,{BYTES_PER_ELEMENT:t}),o(o.S+o.F*a((function(){I.of.call(f,1)})),u,{from:De,of:Me}),J in v||p(v,J,t),o(o.P,u,He),P(u),o(o.P+o.F*Ve,u,{set:Fe}),o(o.P+o.F*!x,u,Ye),i||v.toString==ge||(v.toString=ge),o(o.P+o.F*a((function(){new f(1).slice()})),u,{slice:Oe}),o(o.P+o.F*(a((function(){return[1,2].toLocaleString()!=new f([1,2]).toLocaleString()}))||!a((function(){v.toLocaleString.call([1,2])}))),u,{toLocaleString:Re}),D[u]=x?S:w,i||x||p(v,Ie,w)}}else e.exports=function(){}},function(e,t,n){var i=n(8);e.exports=function(e,t){if(!i(e))return e;var n,r;if(t&&"function"==typeof(n=e.toString)&&!i(r=n.call(e)))return r;if("function"==typeof(n=e.valueOf)&&!i(r=n.call(e)))return r;if(!t&&"function"==typeof(n=e.toString)&&!i(r=n.call(e)))return r;throw TypeError("Can't convert object to primitive value")}},function(e,t,n){var i=n(37)("meta"),r=n(8),a=n(19),o=n(13).f,s=0,l=Object.isExtensible||function(){return!0},u=!n(6)((function(){return l(Object.preventExtensions({}))})),c=function(e){o(e,i,{value:{i:"O"+ ++s,w:{}}})},h=e.exports={KEY:i,NEED:!1,fastKey:function(e,t){if(!r(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!a(e,i)){if(!l(e))return"F";if(!t)return"E";c(e)}return e[i].i},getWeak:function(e,t){if(!a(e,i)){if(!l(e))return!0;if(!t)return!1;c(e)}return e[i].w},onFreeze:function(e){return u&&h.NEED&&l(e)&&!a(e,i)&&c(e),e}}},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t){var n=0,i=Math.random();e.exports=function(e){return"Symbol(".concat(e===undefined?"":e,")_",(++n+i).toString(36))}},function(e,t){e.exports=!1},function(e,t,n){var i=n(885),r=n(177);e.exports=Object.keys||function(e){return i(e,r)}},function(e,t,n){var i=n(25),r=Math.max,a=Math.min;e.exports=function(e,t){return(e=i(e))<0?r(e+t,0):a(e,t)}},function(e,t,n){var i=n(7),r=n(886),a=n(177),o=n(176)("IE_PROTO"),s=function(){},l=function(){var e,t=n(174)("iframe"),i=a.length;for(t.style.display="none",n(178).appendChild(t),t.src="javascript:",(e=t.contentWindow.document).open(),e.write("<script>document.F=Object<\/script>"),e.close(),l=e.F;i--;)delete l.prototype[a[i]];return l()};e.exports=Object.create||function(e,t){var n;return null!==e?(s.prototype=i(e),n=new s,s.prototype=null,n[o]=e):n=l(),t===undefined?n:r(n,t)}},function(e,t,n){var i=n(885),r=n(177).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return i(e,r)}},function(e,t,n){var i=n(19),r=n(15),a=n(176)("IE_PROTO"),o=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=r(e),i(e,a)?e[a]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?o:null}},function(e,t,n){var i=n(9)("unscopables"),r=Array.prototype;r[i]==undefined&&n(20)(r,i,{}),e.exports=function(e){r[i][e]=!0}},function(e,t,n){var i=n(8);e.exports=function(e,t){if(!i(e)||e._t!==t)throw TypeError("Incompatible receiver, "+t+" required!");return e}},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(29)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(16)},function(e,t,n){"use strict";n(29)},function(e,t,n){var i=n(13).f,r=n(19),a=n(9)("toStringTag");e.exports=function(e,t,n){e&&!r(e=n?e:e.prototype,a)&&i(e,a,{configurable:!0,value:t})}},function(e,t,n){var i=n(0),r=n(32),a=n(6),o=n(180),s="["+o+"]",l=RegExp("^"+s+s+"*"),u=RegExp(s+s+"*$"),c=function(e,t,n){var r={},s=a((function(){return!!o[e]()||"…"!="…"[e]()})),l=r[e]=s?t(h):o[e];n&&(r[n]=l),i(i.P+i.F*s,"String",r)},h=c.trim=function(e,t){return e=String(r(e)),1&t&&(e=e.replace(l,"")),2&t&&(e=e.replace(u,"")),e};e.exports=c},function(e,t){e.exports={}},function(e,t,n){"use strict";var i=n(5),r=n(13),a=n(12),o=n(9)("species");e.exports=function(e){var t=i[e];a&&t&&!t[o]&&r.f(t,o,{configurable:!0,get:function(){return this}})}},function(e,t){e.exports=function(e,t,n,i){if(!(e instanceof t)||i!==undefined&&i in e)throw TypeError(n+": incorrect invocation!");return e}},function(e,t,n){var i=n(17);e.exports=function(e,t,n){for(var r in t)i(e,r,t[r],n);return e}},,function(e,t,n){"use strict";(function(e){var i=void 0!==e&&e||"undefined"!=typeof self&&self||window,r=Function.prototype.apply;function a(e,t){this._id=e,this._clearFn=t}t.setTimeout=function(){return new a(r.call(setTimeout,i,arguments),clearTimeout)},t.setInterval=function(){return new a(r.call(setInterval,i,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e&&e.close()},a.prototype.unref=a.prototype.ref=function(){},a.prototype.close=function(){this._clearFn.call(i,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout((function(){e._onTimeout&&e._onTimeout()}),t))},n(96),t.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==e&&e.setImmediate||void 0,t.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==e&&e.clearImmediate||void 0}).call(this,n(14))},function(e,t,n){var i=n(31);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==i(e)?e.split(""):Object(e)}},function(e,t){t.f={}.propertyIsEnumerable},function(e,t,n){var i=n(31),r=n(9)("toStringTag"),a="Arguments"==i(function(){return arguments}());e.exports=function(e){var t,n,o;return e===undefined?"Undefined":null===e?"Null":"string"==typeof(n=function(e,t){try{return e[t]}catch(n){}}(t=Object(e),r))?n:a?i(t):"Object"==(o=i(t))&&"function"==typeof t.callee?"Arguments":o}},function(e,t,n){var i=n(7),r=n(24),a=n(9)("species");e.exports=function(e,t){var n,o=i(e).constructor;return o===undefined||(n=i(o)[a])==undefined?t:r(n)}},,,function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(30)},function(e,t,n){"use strict";n(29)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(52)},function(e,t,n){"use strict";var i,r,a=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function l(e){if(i===setTimeout)return setTimeout(e,0);if((i===o||!i)&&setTimeout)return i=setTimeout,setTimeout(e,0);try{return i(e,0)}catch(t){try{return i.call(null,e,0)}catch(t){return i.call(this,e,0)}}}!function(){try{i="function"==typeof setTimeout?setTimeout:o}catch(e){i=o}try{r="function"==typeof clearTimeout?clearTimeout:s}catch(e){r=s}}();var u,c=[],h=!1,p=-1;function d(){h&&u&&(h=!1,u.length?c=u.concat(c):p=-1,c.length&&f())}function f(){if(!h){var e=l(d);h=!0;for(var t=c.length;t;){for(u=c,c=[];++p<t;)u&&u[p].run();p=-1,t=c.length}u=null,h=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===s||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function g(e,t){this.fun=e,this.array=t}function m(){}a.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];c.push(new g(e,t)),1!==c.length||h||l(f)},g.prototype.run=function(){this.fun.apply(null,this.array)},a.title="browser",a.browser=!0,a.env={},a.argv=[],a.version="",a.versions={},a.on=m,a.addListener=m,a.once=m,a.off=m,a.removeListener=m,a.removeAllListeners=m,a.emit=m,a.prependListener=m,a.prependOnceListener=m,a.listeners=function(e){return[]},a.binding=function(e){throw new Error("process.binding is not supported")},a.cwd=function(){return"/"},a.chdir=function(e){throw new Error("process.chdir is not supported")},a.umask=function(){return 0}},function(e,t,n){var i=n(11),r=n(5),a="__core-js_shared__",o=r[a]||(r[a]={});(e.exports=function(e,t){return o[e]||(o[e]=t!==undefined?t:{})})("versions",[]).push({version:i.version,mode:n(38)?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},function(e,t,n){var i=n(21),r=n(10),a=n(40);e.exports=function(e){return function(t,n,o){var s,l=i(t),u=r(l.length),c=a(o,u);if(e&&n!=n){for(;u>c;)if((s=l[c++])!=s)return!0}else for(;u>c;c++)if((e||c in l)&&l[c]===n)return e||c||0;return!e&&-1}}},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,n){var i=n(31);e.exports=Array.isArray||function(e){return"Array"==i(e)}},function(e,t,n){var i=n(9)("iterator"),r=!1;try{var a=[7][i]();a["return"]=function(){r=!0},Array.from(a,(function(){throw 2}))}catch(o){}e.exports=function(e,t){if(!t&&!r)return!1;var n=!1;try{var a=[7],s=a[i]();s.next=function(){return{done:n=!0}},a[i]=function(){return s},e(a)}catch(o){}return n}},function(e,t,n){"use strict";var i=n(7);e.exports=function(){var e=i(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},function(e,t,n){"use strict";var i=n(64),r=RegExp.prototype.exec;e.exports=function(e,t){var n=e.exec;if("function"==typeof n){var a=n.call(e,t);if("object"!=typeof a)throw new TypeError("RegExp exec method returned something other than an Object or null");return a}if("RegExp"!==i(e))throw new TypeError("RegExp#exec called on incompatible receiver");return r.call(e,t)}},function(e,t,n){"use strict";n(903);var i=n(17),r=n(20),a=n(6),o=n(32),s=n(9),l=n(195),u=s("species"),c=!a((function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$<a>")})),h=function(){var e=/(?:)/,t=e.exec;e.exec=function(){return t.apply(this,arguments)};var n="ab".split(e);return 2===n.length&&"a"===n[0]&&"b"===n[1]}();e.exports=function(e,t,n){var p=s(e),d=!a((function(){var t={};return t[p]=function(){return 7},7!=""[e](t)})),f=d?!a((function(){var t=!1,n=/a/;return n.exec=function(){return t=!0,null},"split"===e&&(n.constructor={},n.constructor[u]=function(){return n}),n[p](""),!t})):undefined;if(!d||!f||"replace"===e&&!c||"split"===e&&!h){var g=/./[p],m=n(o,p,""[e],(function(e,t,n,i,r){return t.exec===l?d&&!r?{done:!0,value:g.call(t,n,i)}:{done:!0,value:e.call(n,t,i)}:{done:!1}})),I=m[0],B=m[1];i(String.prototype,e,I),r(RegExp.prototype,p,2==t?function(e,t){return B.call(e,this,t)}:function(e){return B.call(e,this)})}}},function(e,t,n){var i=n(23),r=n(898),a=n(190),o=n(7),s=n(10),l=n(192),u={},c={};(t=e.exports=function(e,t,n,h,p){var d,f,g,m,I=p?function(){return e}:l(e),B=i(n,h,t?2:1),_=0;if("function"!=typeof I)throw TypeError(e+" is not iterable!");if(a(I)){for(d=s(e.length);d>_;_++)if((m=t?B(o(f=e[_])[0],f[1]):B(e[_]))===u||m===c)return m}else for(g=I.call(e);!(f=g.next()).done;)if((m=r(g,B,f.value,t))===u||m===c)return m}).BREAK=u,t.RETURN=c},function(e,t,n){var i=n(5).navigator;e.exports=i&&i.userAgent||""},function(e,t,n){"use strict";var i=n(5),r=n(0),a=n(17),o=n(59),s=n(35),l=n(84),u=n(58),c=n(8),h=n(6),p=n(80),d=n(54),f=n(181);e.exports=function(e,t,n,g,m,I){var B=i[e],_=B,E=m?"set":"add",b=_&&_.prototype,y={},v=function(e){var t=b[e];a(b,e,"delete"==e||"has"==e?function(e){return!(I&&!c(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return I&&!c(e)?undefined:t.call(this,0===e?0:e)}:"add"==e?function(e){return t.call(this,0===e?0:e),this}:function(e,n){return t.call(this,0===e?0:e,n),this})};if("function"==typeof _&&(I||b.forEach&&!h((function(){(new _).entries().next()})))){var T=new _,C=T[E](I?{}:-0,1)!=T,N=h((function(){T.has(1)})),V=p((function(e){new _(e)})),S=!I&&h((function(){for(var e=new _,t=5;t--;)e[E](t,t);return!e.has(-0)}));V||((_=t((function(t,n){u(t,_,e);var i=f(new B,t,_);return n!=undefined&&l(n,m,i[E],i),i}))).prototype=b,b.constructor=_),(N||S)&&(v("delete"),v("has"),m&&v("get")),(S||C)&&v(E),I&&b.clear&&delete b.clear}else _=g.getConstructor(t,e,m,E),o(_.prototype,n),s.NEED=!0;return d(_,e),y[e]=_,r(r.G+r.W+r.F*(_!=B),y),I||g.setStrong(_,e,m),_}},function(e,t,n){for(var i,r=n(5),a=n(20),o=n(37),s=o("typed_array"),l=o("view"),u=!(!r.ArrayBuffer||!r.DataView),c=u,h=0,p="Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array".split(",");h<9;)(i=r[p[h++]])?(a(i.prototype,s,!0),a(i.prototype,l,!0)):c=!1;e.exports={ABV:u,CONSTR:c,TYPED:s,VIEW:l}},,,,function(e,t,n){(function(e){_global=undefined,"undefined"!=typeof window?_global=window:void 0!==e?_global=e:"undefined"!=typeof self?_global=self:_global=this,null==_global.BI&&(_global.BI={prepares:[]}),null==_global.BI.prepares&&(_global.BI.prepares=[])}).call(this,n(14))},function(e,t,n){n(93)(n(94))},function(e,t){e.exports=function(e){function t(e){"undefined"!=typeof console&&(console.error||console.log)("[Script Loader]",e)}try{"undefined"!=typeof execScript&&"undefined"!=typeof attachEvent&&"undefined"==typeof addEventListener?execScript(e):"undefined"!=typeof eval?eval.call(null,e):t("EvalError: No eval function available")}catch(n){t(n)}}},function(e,t){e.exports="/**\r\n * @license\r\n * Lodash (Custom Build) <https://lodash.com/>\r\n * Build: `lodash core plus=\"debounce,throttle,get,set,findIndex,findLastIndex,findKey,findLastKey,isArrayLike,invert,invertBy,uniq,uniqBy,omit,omitBy,zip,unzip,rest,range,random,reject,intersection,drop,countBy,union,zipObject,initial,cloneDeep,clamp,isPlainObject,take,takeRight,without,difference,defaultsDeep,trim,merge,groupBy,uniqBy,before,after,unescape\"`\r\n * Copyright JS Foundation and other contributors <https://js.foundation/>\r\n * Released under MIT license <https://lodash.com/license>\r\n * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>\r\n * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\r\n */\r\n;(function() {\r\n\r\n /** Used as a safe reference for `undefined` in pre-ES5 environments. */\r\n var undefined;\r\n\r\n /** Used as the semantic version number. */\r\n var VERSION = '4.17.5';\r\n\r\n /** Used as the size to enable large array optimizations. */\r\n var LARGE_ARRAY_SIZE = 200;\r\n\r\n /** Error message constants. */\r\n var FUNC_ERROR_TEXT = 'Expected a function';\r\n\r\n /** Used to stand-in for `undefined` hash values. */\r\n var HASH_UNDEFINED = '__lodash_hash_undefined__';\r\n\r\n /** Used as the maximum memoize cache size. */\r\n var MAX_MEMOIZE_SIZE = 500;\r\n\r\n /** Used as the internal argument placeholder. */\r\n var PLACEHOLDER = '__lodash_placeholder__';\r\n\r\n /** Used to compose bitmasks for cloning. */\r\n var CLONE_DEEP_FLAG = 1,\r\n CLONE_FLAT_FLAG = 2,\r\n CLONE_SYMBOLS_FLAG = 4;\r\n\r\n /** Used to compose bitmasks for value comparisons. */\r\n var COMPARE_PARTIAL_FLAG = 1,\r\n COMPARE_UNORDERED_FLAG = 2;\r\n\r\n /** Used to compose bitmasks for function metadata. */\r\n var WRAP_BIND_FLAG = 1,\r\n WRAP_BIND_KEY_FLAG = 2,\r\n WRAP_CURRY_BOUND_FLAG = 4,\r\n WRAP_CURRY_FLAG = 8,\r\n WRAP_CURRY_RIGHT_FLAG = 16,\r\n WRAP_PARTIAL_FLAG = 32,\r\n WRAP_PARTIAL_RIGHT_FLAG = 64,\r\n WRAP_ARY_FLAG = 128,\r\n WRAP_REARG_FLAG = 256,\r\n WRAP_FLIP_FLAG = 512;\r\n\r\n /** Used to detect hot functions by number of calls within a span of milliseconds. */\r\n var HOT_COUNT = 800,\r\n HOT_SPAN = 16;\r\n\r\n /** Used to indicate the type of lazy iteratees. */\r\n var LAZY_FILTER_FLAG = 1,\r\n LAZY_MAP_FLAG = 2,\r\n LAZY_WHILE_FLAG = 3;\r\n\r\n /** Used as references for various `Number` constants. */\r\n var INFINITY = 1 / 0,\r\n MAX_SAFE_INTEGER = 9007199254740991,\r\n MAX_INTEGER = 1.7976931348623157e+308,\r\n NAN = 0 / 0;\r\n\r\n /** Used as references for the maximum length and index of an array. */\r\n var MAX_ARRAY_LENGTH = 4294967295;\r\n\r\n /** Used to associate wrap methods with their bit flags. */\r\n var wrapFlags = [\r\n ['ary', WRAP_ARY_FLAG],\r\n ['bind', WRAP_BIND_FLAG],\r\n ['bindKey', WRAP_BIND_KEY_FLAG],\r\n ['curry', WRAP_CURRY_FLAG],\r\n ['curryRight', WRAP_CURRY_RIGHT_FLAG],\r\n ['flip', WRAP_FLIP_FLAG],\r\n ['partial', WRAP_PARTIAL_FLAG],\r\n ['partialRight', WRAP_PARTIAL_RIGHT_FLAG],\r\n ['rearg', WRAP_REARG_FLAG]\r\n ];\r\n\r\n /** `Object#toString` result references. */\r\n var argsTag = '[object Arguments]',\r\n arrayTag = '[object Array]',\r\n asyncTag = '[object AsyncFunction]',\r\n boolTag = '[object Boolean]',\r\n dateTag = '[object Date]',\r\n errorTag = '[object Error]',\r\n funcTag = '[object Function]',\r\n genTag = '[object GeneratorFunction]',\r\n mapTag = '[object Map]',\r\n numberTag = '[object Number]',\r\n nullTag = '[object Null]',\r\n objectTag = '[object Object]',\r\n promiseTag = '[object Promise]',\r\n proxyTag = '[object Proxy]',\r\n regexpTag = '[object RegExp]',\r\n setTag = '[object Set]',\r\n stringTag = '[object String]',\r\n symbolTag = '[object Symbol]',\r\n undefinedTag = '[object Undefined]',\r\n weakMapTag = '[object WeakMap]';\r\n\r\n var arrayBufferTag = '[object ArrayBuffer]',\r\n dataViewTag = '[object DataView]',\r\n float32Tag = '[object Float32Array]',\r\n float64Tag = '[object Float64Array]',\r\n int8Tag = '[object Int8Array]',\r\n int16Tag = '[object Int16Array]',\r\n int32Tag = '[object Int32Array]',\r\n uint8Tag = '[object Uint8Array]',\r\n uint8ClampedTag = '[object Uint8ClampedArray]',\r\n uint16Tag = '[object Uint16Array]',\r\n uint32Tag = '[object Uint32Array]';\r\n\r\n /** Used to match HTML entities and HTML characters. */\r\n var reEscapedHtml = /&(?:amp|lt|gt|quot|#39);/g,\r\n reUnescapedHtml = /[&<>\"']/g,\r\n reHasEscapedHtml = RegExp(reEscapedHtml.source),\r\n reHasUnescapedHtml = RegExp(reUnescapedHtml.source);\r\n\r\n /** Used to match property names within property paths. */\r\n var reIsDeepProp = /\\.|\\[(?:[^[\\]]*|([\"'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,\r\n reIsPlainProp = /^\\w*$/,\r\n rePropName = /[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))/g;\r\n\r\n /**\r\n * Used to match `RegExp`\r\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\r\n */\r\n var reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\r\n\r\n /** Used to match leading and trailing whitespace. */\r\n var reTrim = /^\\s+|\\s+$/g;\r\n\r\n /** Used to match wrap detail comments. */\r\n var reWrapComment = /\\{(?:\\n\\/\\* \\[wrapped with .+\\] \\*\\/)?\\n?/,\r\n reWrapDetails = /\\{\\n\\/\\* \\[wrapped with (.+)\\] \\*/,\r\n reSplitDetails = /,? & /;\r\n\r\n /** Used to match backslashes in property paths. */\r\n var reEscapeChar = /\\\\(\\\\)?/g;\r\n\r\n /** Used to match `RegExp` flags from their coerced string values. */\r\n var reFlags = /\\w*$/;\r\n\r\n /** Used to detect bad signed hexadecimal string values. */\r\n var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;\r\n\r\n /** Used to detect binary string values. */\r\n var reIsBinary = /^0b[01]+$/i;\r\n\r\n /** Used to detect host constructors (Safari). */\r\n var reIsHostCtor = /^\\[object .+?Constructor\\]$/;\r\n\r\n /** Used to detect octal string values. */\r\n var reIsOctal = /^0o[0-7]+$/i;\r\n\r\n /** Used to detect unsigned integer values. */\r\n var reIsUint = /^(?:0|[1-9]\\d*)$/;\r\n\r\n /** Used to compose unicode character classes. */\r\n var rsAstralRange = '\\\\ud800-\\\\udfff',\r\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\r\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\r\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\r\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\r\n rsVarRange = '\\\\ufe0e\\\\ufe0f';\r\n\r\n /** Used to compose unicode capture groups. */\r\n var rsAstral = '[' + rsAstralRange + ']',\r\n rsCombo = '[' + rsComboRange + ']',\r\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\r\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\r\n rsNonAstral = '[^' + rsAstralRange + ']',\r\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\r\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\r\n rsZWJ = '\\\\u200d';\r\n\r\n /** Used to compose unicode regexes. */\r\n var reOptMod = rsModifier + '?',\r\n rsOptVar = '[' + rsVarRange + ']?',\r\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\r\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\r\n rsSymbol = '(?:' + [rsNonAstral + rsCombo + '?', rsCombo, rsRegional, rsSurrPair, rsAstral].join('|') + ')';\r\n\r\n /** Used to match [string symbols](https://mathiasbynens.be/notes/javascript-unicode). */\r\n var reUnicode = RegExp(rsFitz + '(?=' + rsFitz + ')|' + rsSymbol + rsSeq, 'g');\r\n\r\n /** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */\r\n var reHasUnicode = RegExp('[' + rsZWJ + rsAstralRange + rsComboRange + rsVarRange + ']');\r\n\r\n /** Used to identify `toStringTag` values of typed arrays. */\r\n var typedArrayTags = {};\r\n typedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\r\n typedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\r\n typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\r\n typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\r\n typedArrayTags[uint32Tag] = true;\r\n typedArrayTags[argsTag] = typedArrayTags[arrayTag] =\r\n typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\r\n typedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\r\n typedArrayTags[errorTag] = typedArrayTags[funcTag] =\r\n typedArrayTags[mapTag] = typedArrayTags[numberTag] =\r\n typedArrayTags[objectTag] = typedArrayTags[regexpTag] =\r\n typedArrayTags[setTag] = typedArrayTags[stringTag] =\r\n typedArrayTags[weakMapTag] = false;\r\n\r\n /** Used to identify `toStringTag` values supported by `_.clone`. */\r\n var cloneableTags = {};\r\n cloneableTags[argsTag] = cloneableTags[arrayTag] =\r\n cloneableTags[arrayBufferTag] = cloneableTags[dataViewTag] =\r\n cloneableTags[boolTag] = cloneableTags[dateTag] =\r\n cloneableTags[float32Tag] = cloneableTags[float64Tag] =\r\n cloneableTags[int8Tag] = cloneableTags[int16Tag] =\r\n cloneableTags[int32Tag] = cloneableTags[mapTag] =\r\n cloneableTags[numberTag] = cloneableTags[objectTag] =\r\n cloneableTags[regexpTag] = cloneableTags[setTag] =\r\n cloneableTags[stringTag] = cloneableTags[symbolTag] =\r\n cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] =\r\n cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true;\r\n cloneableTags[errorTag] = cloneableTags[funcTag] =\r\n cloneableTags[weakMapTag] = false;\r\n\r\n /** Used to map characters to HTML entities. */\r\n var htmlEscapes = {\r\n '&': '&amp;',\r\n '<': '&lt;',\r\n '>': '&gt;',\r\n '\"': '&quot;',\r\n \"'\": '&#39;'\r\n };\r\n\r\n /** Used to map HTML entities to characters. */\r\n var htmlUnescapes = {\r\n '&amp;': '&',\r\n '&lt;': '<',\r\n '&gt;': '>',\r\n '&quot;': '\"',\r\n '&#39;': \"'\"\r\n };\r\n\r\n /** Built-in method references without a dependency on `root`. */\r\n var freeParseFloat = parseFloat,\r\n freeParseInt = parseInt;\r\n\r\n /** Detect free variable `global` from Node.js. */\r\n var freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\r\n\r\n /** Detect free variable `self`. */\r\n var freeSelf = typeof self == 'object' && self && self.Object === Object && self;\r\n\r\n /** Used as a reference to the global object. */\r\n var root = freeGlobal || freeSelf || Function('return this')();\r\n\r\n /** Detect free variable `exports`. */\r\n var freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\r\n\r\n /** Detect free variable `module`. */\r\n var freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\r\n\r\n /** Detect the popular CommonJS extension `module.exports`. */\r\n var moduleExports = freeModule && freeModule.exports === freeExports;\r\n\r\n /** Detect free variable `process` from Node.js. */\r\n var freeProcess = moduleExports && freeGlobal.process;\r\n\r\n /** Used to access faster Node.js helpers. */\r\n var nodeUtil = (function() {\r\n try {\r\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\r\n } catch (e) {}\r\n }());\r\n\r\n /* Node.js helper references. */\r\n var nodeIsDate = nodeUtil && nodeUtil.isDate,\r\n nodeIsMap = nodeUtil && nodeUtil.isMap,\r\n nodeIsRegExp = nodeUtil && nodeUtil.isRegExp,\r\n nodeIsSet = nodeUtil && nodeUtil.isSet,\r\n nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\r\n\r\n /*--------------------------------------------------------------------------*/\r\n\r\n /**\r\n * A faster alternative to `Function#apply`, this function invokes `func`\r\n * with the `this` binding of `thisArg` and the arguments of `args`.\r\n *\r\n * @private\r\n * @param {Function} func The function to invoke.\r\n * @param {*} thisArg The `this` binding of `func`.\r\n * @param {Array} args The arguments to invoke `func` with.\r\n * @returns {*} Returns the result of `func`.\r\n */\r\n function apply(func, thisArg, args) {\r\n switch (args.length) {\r\n case 0: return func.call(thisArg);\r\n case 1: return func.call(thisArg, args[0]);\r\n case 2: return func.call(thisArg, args[0], args[1]);\r\n case 3: return func.call(thisArg, args[0], args[1], args[2]);\r\n }\r\n return func.apply(thisArg, args);\r\n }\r\n\r\n /**\r\n * A specialized version of `baseAggregator` for arrays.\r\n *\r\n * @private\r\n * @param {Array} [array] The array to iterate over.\r\n * @param {Function} setter The function to set `accumulator` values.\r\n * @param {Function} iteratee The iteratee to transform keys.\r\n * @param {Object} accumulator The initial aggregated object.\r\n * @returns {Function} Returns `accumulator`.\r\n */\r\n function arrayAggregator(array, setter, iteratee, accumulator) {\r\n var index = -1,\r\n length = array == null ? 0 : array.length;\r\n\r\n while (++index < length) {\r\n var value = array[index];\r\n setter(accumulator, value, iteratee(value), array);\r\n }\r\n return accumulator;\r\n }\r\n\r\n /**\r\n * A specialized version of `_.forEach` for arrays without support for\r\n * iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Array} [array] The array to iterate over.\r\n * @param {Function} iteratee The function invoked per iteration.\r\n * @returns {Array} Returns `array`.\r\n */\r\n function arrayEach(array, iteratee) {\r\n var index = -1,\r\n length = array == null ? 0 : array.length;\r\n\r\n while (++index < length) {\r\n if (iteratee(array[index], index, array) === false) {\r\n break;\r\n }\r\n }\r\n return array;\r\n }\r\n\r\n /**\r\n * A specialized version of `_.every` for arrays without support for\r\n * iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Array} [array] The array to iterate over.\r\n * @param {Function} predicate The function invoked per iteration.\r\n * @returns {boolean} Returns `true` if all elements pass the predicate check,\r\n * else `false`.\r\n */\r\n function arrayEvery(array, predicate) {\r\n var index = -1,\r\n length = array == null ? 0 : array.length;\r\n\r\n while (++index < length) {\r\n if (!predicate(array[index], index, array)) {\r\n return false;\r\n }\r\n }\r\n return true;\r\n }\r\n\r\n /**\r\n * A specialized version of `_.filter` for arrays without support for\r\n * iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Array} [array] The array to iterate over.\r\n * @param {Function} predicate The function invoked per iteration.\r\n * @returns {Array} Returns the new filtered array.\r\n */\r\n function arrayFilter(array, predicate) {\r\n var index = -1,\r\n length = array == null ? 0 : array.length,\r\n resIndex = 0,\r\n result = [];\r\n\r\n while (++index < length) {\r\n var value = array[index];\r\n if (predicate(value, index, array)) {\r\n result[resIndex++] = value;\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * A specialized version of `_.includes` for arrays without support for\r\n * specifying an index to search from.\r\n *\r\n * @private\r\n * @param {Array} [array] The array to inspect.\r\n * @param {*} target The value to search for.\r\n * @returns {boolean} Returns `true` if `target` is found, else `false`.\r\n */\r\n function arrayIncludes(array, value) {\r\n var length = array == null ? 0 : array.length;\r\n return !!length && baseIndexOf(array, value, 0) > -1;\r\n }\r\n\r\n /**\r\n * This function is like `arrayIncludes` except that it accepts a comparator.\r\n *\r\n * @private\r\n * @param {Array} [array] The array to inspect.\r\n * @param {*} target The value to search for.\r\n * @param {Function} comparator The comparator invoked per element.\r\n * @returns {boolean} Returns `true` if `target` is found, else `false`.\r\n */\r\n function arrayIncludesWith(array, value, comparator) {\r\n var index = -1,\r\n length = array == null ? 0 : array.length;\r\n\r\n while (++index < length) {\r\n if (comparator(value, array[index])) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n }\r\n\r\n /**\r\n * A specialized version of `_.map` for arrays without support for iteratee\r\n * shorthands.\r\n *\r\n * @private\r\n * @param {Array} [array] The array to iterate over.\r\n * @param {Function} iteratee The function invoked per iteration.\r\n * @returns {Array} Returns the new mapped array.\r\n */\r\n function arrayMap(array, iteratee) {\r\n var index = -1,\r\n length = array == null ? 0 : array.length,\r\n result = Array(length);\r\n\r\n while (++index < length) {\r\n result[index] = iteratee(array[index], index, array);\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Appends the elements of `values` to `array`.\r\n *\r\n * @private\r\n * @param {Array} array The array to modify.\r\n * @param {Array} values The values to append.\r\n * @returns {Array} Returns `array`.\r\n */\r\n function arrayPush(array, values) {\r\n var index = -1,\r\n length = values.length,\r\n offset = array.length;\r\n\r\n while (++index < length) {\r\n array[offset + index] = values[index];\r\n }\r\n return array;\r\n }\r\n\r\n /**\r\n * A specialized version of `_.reduce` for arrays without support for\r\n * iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Array} [array] The array to iterate over.\r\n * @param {Function} iteratee The function invoked per iteration.\r\n * @param {*} [accumulator] The initial value.\r\n * @param {boolean} [initAccum] Specify using the first element of `array` as\r\n * the initial value.\r\n * @returns {*} Returns the accumulated value.\r\n */\r\n function arrayReduce(array, iteratee, accumulator, initAccum) {\r\n var index = -1,\r\n length = array == null ? 0 : array.length;\r\n\r\n if (initAccum && length) {\r\n accumulator = array[++index];\r\n }\r\n while (++index < length) {\r\n accumulator = iteratee(accumulator, array[index], index, array);\r\n }\r\n return accumulator;\r\n }\r\n\r\n /**\r\n * A specialized version of `_.some` for arrays without support for iteratee\r\n * shorthands.\r\n *\r\n * @private\r\n * @param {Array} [array] The array to iterate over.\r\n * @param {Function} predicate The function invoked per iteration.\r\n * @returns {boolean} Returns `true` if any element passes the predicate check,\r\n * else `false`.\r\n */\r\n function arraySome(array, predicate) {\r\n var index = -1,\r\n length = array == null ? 0 : array.length;\r\n\r\n while (++index < length) {\r\n if (predicate(array[index], index, array)) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n }\r\n\r\n /**\r\n * Gets the size of an ASCII `string`.\r\n *\r\n * @private\r\n * @param {string} string The string inspect.\r\n * @returns {number} Returns the string size.\r\n */\r\n var asciiSize = baseProperty('length');\r\n\r\n /**\r\n * Converts an ASCII `string` to an array.\r\n *\r\n * @private\r\n * @param {string} string The string to convert.\r\n * @returns {Array} Returns the converted array.\r\n */\r\n function asciiToArray(string) {\r\n return string.split('');\r\n }\r\n\r\n /**\r\n * The base implementation of methods like `_.findKey` and `_.findLastKey`,\r\n * without support for iteratee shorthands, which iterates over `collection`\r\n * using `eachFunc`.\r\n *\r\n * @private\r\n * @param {Array|Object} collection The collection to inspect.\r\n * @param {Function} predicate The function invoked per iteration.\r\n * @param {Function} eachFunc The function to iterate over `collection`.\r\n * @returns {*} Returns the found element or its key, else `undefined`.\r\n */\r\n function baseFindKey(collection, predicate, eachFunc) {\r\n var result;\r\n eachFunc(collection, function(value, key, collection) {\r\n if (predicate(value, key, collection)) {\r\n result = key;\r\n return false;\r\n }\r\n });\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.findIndex` and `_.findLastIndex` without\r\n * support for iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Array} array The array to inspect.\r\n * @param {Function} predicate The function invoked per iteration.\r\n * @param {number} fromIndex The index to search from.\r\n * @param {boolean} [fromRight] Specify iterating from right to left.\r\n * @returns {number} Returns the index of the matched value, else `-1`.\r\n */\r\n function baseFindIndex(array, predicate, fromIndex, fromRight) {\r\n var length = array.length,\r\n index = fromIndex + (fromRight ? 1 : -1);\r\n\r\n while ((fromRight ? index-- : ++index < length)) {\r\n if (predicate(array[index], index, array)) {\r\n return index;\r\n }\r\n }\r\n return -1;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.indexOf` without `fromIndex` bounds checks.\r\n *\r\n * @private\r\n * @param {Array} array The array to inspect.\r\n * @param {*} value The value to search for.\r\n * @param {number} fromIndex The index to search from.\r\n * @returns {number} Returns the index of the matched value, else `-1`.\r\n */\r\n function baseIndexOf(array, value, fromIndex) {\r\n return value === value\r\n ? strictIndexOf(array, value, fromIndex)\r\n : baseFindIndex(array, baseIsNaN, fromIndex);\r\n }\r\n\r\n /**\r\n * The base implementation of `_.isNaN` without support for number objects.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`.\r\n */\r\n function baseIsNaN(value) {\r\n return value !== value;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.property` without support for deep paths.\r\n *\r\n * @private\r\n * @param {string} key The key of the property to get.\r\n * @returns {Function} Returns the new accessor function.\r\n */\r\n function baseProperty(key) {\r\n return function(object) {\r\n return object == null ? undefined : object[key];\r\n };\r\n }\r\n\r\n /**\r\n * The base implementation of `_.propertyOf` without support for deep paths.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @returns {Function} Returns the new accessor function.\r\n */\r\n function basePropertyOf(object) {\r\n return function(key) {\r\n return object == null ? undefined : object[key];\r\n };\r\n }\r\n\r\n /**\r\n * The base implementation of `_.reduce` and `_.reduceRight`, without support\r\n * for iteratee shorthands, which iterates over `collection` using `eachFunc`.\r\n *\r\n * @private\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} iteratee The function invoked per iteration.\r\n * @param {*} accumulator The initial value.\r\n * @param {boolean} initAccum Specify using the first or last element of\r\n * `collection` as the initial value.\r\n * @param {Function} eachFunc The function to iterate over `collection`.\r\n * @returns {*} Returns the accumulated value.\r\n */\r\n function baseReduce(collection, iteratee, accumulator, initAccum, eachFunc) {\r\n eachFunc(collection, function(value, index, collection) {\r\n accumulator = initAccum\r\n ? (initAccum = false, value)\r\n : iteratee(accumulator, value, index, collection);\r\n });\r\n return accumulator;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.sortBy` which uses `comparer` to define the\r\n * sort order of `array` and replaces criteria objects with their corresponding\r\n * values.\r\n *\r\n * @private\r\n * @param {Array} array The array to sort.\r\n * @param {Function} comparer The function to define sort order.\r\n * @returns {Array} Returns `array`.\r\n */\r\n function baseSortBy(array, comparer) {\r\n var length = array.length;\r\n\r\n array.sort(comparer);\r\n while (length--) {\r\n array[length] = array[length].value;\r\n }\r\n return array;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.times` without support for iteratee shorthands\r\n * or max array length checks.\r\n *\r\n * @private\r\n * @param {number} n The number of times to invoke `iteratee`.\r\n * @param {Function} iteratee The function invoked per iteration.\r\n * @returns {Array} Returns the array of results.\r\n */\r\n function baseTimes(n, iteratee) {\r\n var index = -1,\r\n result = Array(n);\r\n\r\n while (++index < n) {\r\n result[index] = iteratee(index);\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.unary` without support for storing metadata.\r\n *\r\n * @private\r\n * @param {Function} func The function to cap arguments for.\r\n * @returns {Function} Returns the new capped function.\r\n */\r\n function baseUnary(func) {\r\n return function(value) {\r\n return func(value);\r\n };\r\n }\r\n\r\n /**\r\n * The base implementation of `_.values` and `_.valuesIn` which creates an\r\n * array of `object` property values corresponding to the property names\r\n * of `props`.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @param {Array} props The property names to get values for.\r\n * @returns {Object} Returns the array of property values.\r\n */\r\n function baseValues(object, props) {\r\n return arrayMap(props, function(key) {\r\n return object[key];\r\n });\r\n }\r\n\r\n /**\r\n * Checks if a `cache` value for `key` exists.\r\n *\r\n * @private\r\n * @param {Object} cache The cache to query.\r\n * @param {string} key The key of the entry to check.\r\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\r\n */\r\n function cacheHas(cache, key) {\r\n return cache.has(key);\r\n }\r\n\r\n /**\r\n * Used by `_.trim` and `_.trimStart` to get the index of the first string symbol\r\n * that is not found in the character symbols.\r\n *\r\n * @private\r\n * @param {Array} strSymbols The string symbols to inspect.\r\n * @param {Array} chrSymbols The character symbols to find.\r\n * @returns {number} Returns the index of the first unmatched string symbol.\r\n */\r\n function charsStartIndex(strSymbols, chrSymbols) {\r\n var index = -1,\r\n length = strSymbols.length;\r\n\r\n while (++index < length && baseIndexOf(chrSymbols, strSymbols[index], 0) > -1) {}\r\n return index;\r\n }\r\n\r\n /**\r\n * Used by `_.trim` and `_.trimEnd` to get the index of the last string symbol\r\n * that is not found in the character symbols.\r\n *\r\n * @private\r\n * @param {Array} strSymbols The string symbols to inspect.\r\n * @param {Array} chrSymbols The character symbols to find.\r\n * @returns {number} Returns the index of the last unmatched string symbol.\r\n */\r\n function charsEndIndex(strSymbols, chrSymbols) {\r\n var index = strSymbols.length;\r\n\r\n while (index-- && baseIndexOf(chrSymbols, strSymbols[index], 0) > -1) {}\r\n return index;\r\n }\r\n\r\n /**\r\n * Gets the number of `placeholder` occurrences in `array`.\r\n *\r\n * @private\r\n * @param {Array} array The array to inspect.\r\n * @param {*} placeholder The placeholder to search for.\r\n * @returns {number} Returns the placeholder count.\r\n */\r\n function countHolders(array, placeholder) {\r\n var length = array.length,\r\n result = 0;\r\n\r\n while (length--) {\r\n if (array[length] === placeholder) {\r\n ++result;\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Used by `_.escape` to convert characters to HTML entities.\r\n *\r\n * @private\r\n * @param {string} chr The matched character to escape.\r\n * @returns {string} Returns the escaped character.\r\n */\r\n var escapeHtmlChar = basePropertyOf(htmlEscapes);\r\n\r\n /**\r\n * Gets the value at `key` of `object`.\r\n *\r\n * @private\r\n * @param {Object} [object] The object to query.\r\n * @param {string} key The key of the property to get.\r\n * @returns {*} Returns the property value.\r\n */\r\n function getValue(object, key) {\r\n return object == null ? undefined : object[key];\r\n }\r\n\r\n /**\r\n * Checks if `string` contains Unicode symbols.\r\n *\r\n * @private\r\n * @param {string} string The string to inspect.\r\n * @returns {boolean} Returns `true` if a symbol is found, else `false`.\r\n */\r\n function hasUnicode(string) {\r\n return reHasUnicode.test(string);\r\n }\r\n\r\n /**\r\n * Converts `iterator` to an array.\r\n *\r\n * @private\r\n * @param {Object} iterator The iterator to convert.\r\n * @returns {Array} Returns the converted array.\r\n */\r\n function iteratorToArray(iterator) {\r\n var data,\r\n result = [];\r\n\r\n while (!(data = iterator.next()).done) {\r\n result.push(data.value);\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Converts `map` to its key-value pairs.\r\n *\r\n * @private\r\n * @param {Object} map The map to convert.\r\n * @returns {Array} Returns the key-value pairs.\r\n */\r\n function mapToArray(map) {\r\n var index = -1,\r\n result = Array(map.size);\r\n\r\n map.forEach(function(value, key) {\r\n result[++index] = [key, value];\r\n });\r\n return result;\r\n }\r\n\r\n /**\r\n * Creates a unary function that invokes `func` with its argument transformed.\r\n *\r\n * @private\r\n * @param {Function} func The function to wrap.\r\n * @param {Function} transform The argument transform.\r\n * @returns {Function} Returns the new function.\r\n */\r\n function overArg(func, transform) {\r\n return function(arg) {\r\n return func(transform(arg));\r\n };\r\n }\r\n\r\n /**\r\n * Replaces all `placeholder` elements in `array` with an internal placeholder\r\n * and returns an array of their indexes.\r\n *\r\n * @private\r\n * @param {Array} array The array to modify.\r\n * @param {*} placeholder The placeholder to replace.\r\n * @returns {Array} Returns the new array of placeholder indexes.\r\n */\r\n function replaceHolders(array, placeholder) {\r\n var index = -1,\r\n length = array.length,\r\n resIndex = 0,\r\n result = [];\r\n\r\n while (++index < length) {\r\n var value = array[index];\r\n if (value === placeholder || value === PLACEHOLDER) {\r\n array[index] = PLACEHOLDER;\r\n result[resIndex++] = index;\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Gets the value at `key`, unless `key` is \"__proto__\".\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @param {string} key The key of the property to get.\r\n * @returns {*} Returns the property value.\r\n */\r\n function safeGet(object, key) {\r\n return key == '__proto__'\r\n ? undefined\r\n : object[key];\r\n }\r\n\r\n /**\r\n * Converts `set` to an array of its values.\r\n *\r\n * @private\r\n * @param {Object} set The set to convert.\r\n * @returns {Array} Returns the values.\r\n */\r\n function setToArray(set) {\r\n var index = -1,\r\n result = Array(set.size);\r\n\r\n set.forEach(function(value) {\r\n result[++index] = value;\r\n });\r\n return result;\r\n }\r\n\r\n /**\r\n * A specialized version of `_.indexOf` which performs strict equality\r\n * comparisons of values, i.e. `===`.\r\n *\r\n * @private\r\n * @param {Array} array The array to inspect.\r\n * @param {*} value The value to search for.\r\n * @param {number} fromIndex The index to search from.\r\n * @returns {number} Returns the index of the matched value, else `-1`.\r\n */\r\n function strictIndexOf(array, value, fromIndex) {\r\n var index = fromIndex - 1,\r\n length = array.length;\r\n\r\n while (++index < length) {\r\n if (array[index] === value) {\r\n return index;\r\n }\r\n }\r\n return -1;\r\n }\r\n\r\n /**\r\n * Gets the number of symbols in `string`.\r\n *\r\n * @private\r\n * @param {string} string The string to inspect.\r\n * @returns {number} Returns the string size.\r\n */\r\n function stringSize(string) {\r\n return hasUnicode(string)\r\n ? unicodeSize(string)\r\n : asciiSize(string);\r\n }\r\n\r\n /**\r\n * Converts `string` to an array.\r\n *\r\n * @private\r\n * @param {string} string The string to convert.\r\n * @returns {Array} Returns the converted array.\r\n */\r\n function stringToArray(string) {\r\n return hasUnicode(string)\r\n ? unicodeToArray(string)\r\n : asciiToArray(string);\r\n }\r\n\r\n /**\r\n * Used by `_.unescape` to convert HTML entities to characters.\r\n *\r\n * @private\r\n * @param {string} chr The matched character to unescape.\r\n * @returns {string} Returns the unescaped character.\r\n */\r\n var unescapeHtmlChar = basePropertyOf(htmlUnescapes);\r\n\r\n /**\r\n * Gets the size of a Unicode `string`.\r\n *\r\n * @private\r\n * @param {string} string The string inspect.\r\n * @returns {number} Returns the string size.\r\n */\r\n function unicodeSize(string) {\r\n var result = reUnicode.lastIndex = 0;\r\n while (reUnicode.test(string)) {\r\n ++result;\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Converts a Unicode `string` to an array.\r\n *\r\n * @private\r\n * @param {string} string The string to convert.\r\n * @returns {Array} Returns the converted array.\r\n */\r\n function unicodeToArray(string) {\r\n return string.match(reUnicode) || [];\r\n }\r\n\r\n /*--------------------------------------------------------------------------*/\r\n\r\n /** Used for built-in method references. */\r\n var arrayProto = Array.prototype,\r\n funcProto = Function.prototype,\r\n objectProto = Object.prototype;\r\n\r\n /** Used to detect overreaching core-js shims. */\r\n var coreJsData = root['__core-js_shared__'];\r\n\r\n /** Used to resolve the decompiled source of functions. */\r\n var funcToString = funcProto.toString;\r\n\r\n /** Used to check objects for own properties. */\r\n var hasOwnProperty = objectProto.hasOwnProperty;\r\n\r\n /** Used to generate unique IDs. */\r\n var idCounter = 0;\r\n\r\n /** Used to detect methods masquerading as native. */\r\n var maskSrcKey = (function() {\r\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\r\n return uid ? ('Symbol(src)_1.' + uid) : '';\r\n }());\r\n\r\n /**\r\n * Used to resolve the\r\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\r\n * of values.\r\n */\r\n var nativeObjectToString = objectProto.toString;\r\n\r\n /** Used to infer the `Object` constructor. */\r\n var objectCtorString = funcToString.call(Object);\r\n\r\n /** Used to restore the original `_` reference in `_.noConflict`. */\r\n var oldDash = root._;\r\n\r\n /** Used to detect if a method is native. */\r\n var reIsNative = RegExp('^' +\r\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\r\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\r\n );\r\n\r\n /** Built-in value references. */\r\n var Buffer = moduleExports ? root.Buffer : undefined,\r\n Symbol = root.Symbol,\r\n Uint8Array = root.Uint8Array,\r\n allocUnsafe = Buffer ? Buffer.allocUnsafe : undefined,\r\n getPrototype = overArg(Object.getPrototypeOf, Object),\r\n objectCreate = Object.create,\r\n propertyIsEnumerable = objectProto.propertyIsEnumerable,\r\n splice = arrayProto.splice,\r\n spreadableSymbol = Symbol ? Symbol.isConcatSpreadable : undefined,\r\n symIterator = Symbol ? Symbol.iterator : undefined,\r\n symToStringTag = Symbol ? Symbol.toStringTag : undefined;\r\n\r\n var defineProperty = (function() {\r\n try {\r\n var func = getNative(Object, 'defineProperty');\r\n func({}, '', {});\r\n return func;\r\n } catch (e) {}\r\n }());\r\n\r\n /* Built-in method references for those with the same name as other `lodash` methods. */\r\n var nativeCeil = Math.ceil,\r\n nativeFloor = Math.floor,\r\n nativeGetSymbols = Object.getOwnPropertySymbols,\r\n nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined,\r\n nativeIsFinite = root.isFinite,\r\n nativeKeys = overArg(Object.keys, Object),\r\n nativeMax = Math.max,\r\n nativeMin = Math.min,\r\n nativeNow = Date.now,\r\n nativeRandom = Math.random,\r\n nativeReverse = arrayProto.reverse;\r\n\r\n /* Built-in method references that are verified to be native. */\r\n var DataView = getNative(root, 'DataView'),\r\n Map = getNative(root, 'Map'),\r\n Promise = getNative(root, 'Promise'),\r\n Set = getNative(root, 'Set'),\r\n WeakMap = getNative(root, 'WeakMap'),\r\n nativeCreate = getNative(Object, 'create');\r\n\r\n /** Used to store function metadata. */\r\n var metaMap = WeakMap && new WeakMap;\r\n\r\n /** Used to lookup unminified function names. */\r\n var realNames = {};\r\n\r\n /** Used to detect maps, sets, and weakmaps. */\r\n var dataViewCtorString = toSource(DataView),\r\n mapCtorString = toSource(Map),\r\n promiseCtorString = toSource(Promise),\r\n setCtorString = toSource(Set),\r\n weakMapCtorString = toSource(WeakMap);\r\n\r\n /** Used to convert symbols to primitives and strings. */\r\n var symbolProto = Symbol ? Symbol.prototype : undefined,\r\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined,\r\n symbolToString = symbolProto ? symbolProto.toString : undefined;\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Creates a `lodash` object which wraps `value` to enable implicit method\r\n * chain sequences. Methods that operate on and return arrays, collections,\r\n * and functions can be chained together. Methods that retrieve a single value\r\n * or may return a primitive value will automatically end the chain sequence\r\n * and return the unwrapped value. Otherwise, the value must be unwrapped\r\n * with `_#value`.\r\n *\r\n * Explicit chain sequences, which must be unwrapped with `_#value`, may be\r\n * enabled using `_.chain`.\r\n *\r\n * The execution of chained methods is lazy, that is, it's deferred until\r\n * `_#value` is implicitly or explicitly called.\r\n *\r\n * Lazy evaluation allows several methods to support shortcut fusion.\r\n * Shortcut fusion is an optimization to merge iteratee calls; this avoids\r\n * the creation of intermediate arrays and can greatly reduce the number of\r\n * iteratee executions. Sections of a chain sequence qualify for shortcut\r\n * fusion if the section is applied to an array and iteratees accept only\r\n * one argument. The heuristic for whether a section qualifies for shortcut\r\n * fusion is subject to change.\r\n *\r\n * Chaining is supported in custom builds as long as the `_#value` method is\r\n * directly or indirectly included in the build.\r\n *\r\n * In addition to lodash methods, wrappers have `Array` and `String` methods.\r\n *\r\n * The wrapper `Array` methods are:\r\n * `concat`, `join`, `pop`, `push`, `shift`, `sort`, `splice`, and `unshift`\r\n *\r\n * The wrapper `String` methods are:\r\n * `replace` and `split`\r\n *\r\n * The wrapper methods that support shortcut fusion are:\r\n * `at`, `compact`, `drop`, `dropRight`, `dropWhile`, `filter`, `find`,\r\n * `findLast`, `head`, `initial`, `last`, `map`, `reject`, `reverse`, `slice`,\r\n * `tail`, `take`, `takeRight`, `takeRightWhile`, `takeWhile`, and `toArray`\r\n *\r\n * The chainable wrapper methods are:\r\n * `after`, `ary`, `assign`, `assignIn`, `assignInWith`, `assignWith`, `at`,\r\n * `before`, `bind`, `bindAll`, `bindKey`, `castArray`, `chain`, `chunk`,\r\n * `commit`, `compact`, `concat`, `conforms`, `constant`, `countBy`, `create`,\r\n * `curry`, `debounce`, `defaults`, `defaultsDeep`, `defer`, `delay`,\r\n * `difference`, `differenceBy`, `differenceWith`, `drop`, `dropRight`,\r\n * `dropRightWhile`, `dropWhile`, `extend`, `extendWith`, `fill`, `filter`,\r\n * `flatMap`, `flatMapDeep`, `flatMapDepth`, `flatten`, `flattenDeep`,\r\n * `flattenDepth`, `flip`, `flow`, `flowRight`, `fromPairs`, `functions`,\r\n * `functionsIn`, `groupBy`, `initial`, `intersection`, `intersectionBy`,\r\n * `intersectionWith`, `invert`, `invertBy`, `invokeMap`, `iteratee`, `keyBy`,\r\n * `keys`, `keysIn`, `map`, `mapKeys`, `mapValues`, `matches`, `matchesProperty`,\r\n * `memoize`, `merge`, `mergeWith`, `method`, `methodOf`, `mixin`, `negate`,\r\n * `nthArg`, `omit`, `omitBy`, `once`, `orderBy`, `over`, `overArgs`,\r\n * `overEvery`, `overSome`, `partial`, `partialRight`, `partition`, `pick`,\r\n * `pickBy`, `plant`, `property`, `propertyOf`, `pull`, `pullAll`, `pullAllBy`,\r\n * `pullAllWith`, `pullAt`, `push`, `range`, `rangeRight`, `rearg`, `reject`,\r\n * `remove`, `rest`, `reverse`, `sampleSize`, `set`, `setWith`, `shuffle`,\r\n * `slice`, `sort`, `sortBy`, `splice`, `spread`, `tail`, `take`, `takeRight`,\r\n * `takeRightWhile`, `takeWhile`, `tap`, `throttle`, `thru`, `toArray`,\r\n * `toPairs`, `toPairsIn`, `toPath`, `toPlainObject`, `transform`, `unary`,\r\n * `union`, `unionBy`, `unionWith`, `uniq`, `uniqBy`, `uniqWith`, `unset`,\r\n * `unshift`, `unzip`, `unzipWith`, `update`, `updateWith`, `values`,\r\n * `valuesIn`, `without`, `wrap`, `xor`, `xorBy`, `xorWith`, `zip`,\r\n * `zipObject`, `zipObjectDeep`, and `zipWith`\r\n *\r\n * The wrapper methods that are **not** chainable by default are:\r\n * `add`, `attempt`, `camelCase`, `capitalize`, `ceil`, `clamp`, `clone`,\r\n * `cloneDeep`, `cloneDeepWith`, `cloneWith`, `conformsTo`, `deburr`,\r\n * `defaultTo`, `divide`, `each`, `eachRight`, `endsWith`, `eq`, `escape`,\r\n * `escapeRegExp`, `every`, `find`, `findIndex`, `findKey`, `findLast`,\r\n * `findLastIndex`, `findLastKey`, `first`, `floor`, `forEach`, `forEachRight`,\r\n * `forIn`, `forInRight`, `forOwn`, `forOwnRight`, `get`, `gt`, `gte`, `has`,\r\n * `hasIn`, `head`, `identity`, `includes`, `indexOf`, `inRange`, `invoke`,\r\n * `isArguments`, `isArray`, `isArrayBuffer`, `isArrayLike`, `isArrayLikeObject`,\r\n * `isBoolean`, `isBuffer`, `isDate`, `isElement`, `isEmpty`, `isEqual`,\r\n * `isEqualWith`, `isError`, `isFinite`, `isFunction`, `isInteger`, `isLength`,\r\n * `isMap`, `isMatch`, `isMatchWith`, `isNaN`, `isNative`, `isNil`, `isNull`,\r\n * `isNumber`, `isObject`, `isObjectLike`, `isPlainObject`, `isRegExp`,\r\n * `isSafeInteger`, `isSet`, `isString`, `isUndefined`, `isTypedArray`,\r\n * `isWeakMap`, `isWeakSet`, `join`, `kebabCase`, `last`, `lastIndexOf`,\r\n * `lowerCase`, `lowerFirst`, `lt`, `lte`, `max`, `maxBy`, `mean`, `meanBy`,\r\n * `min`, `minBy`, `multiply`, `noConflict`, `noop`, `now`, `nth`, `pad`,\r\n * `padEnd`, `padStart`, `parseInt`, `pop`, `random`, `reduce`, `reduceRight`,\r\n * `repeat`, `result`, `round`, `runInContext`, `sample`, `shift`, `size`,\r\n * `snakeCase`, `some`, `sortedIndex`, `sortedIndexBy`, `sortedLastIndex`,\r\n * `sortedLastIndexBy`, `startCase`, `startsWith`, `stubArray`, `stubFalse`,\r\n * `stubObject`, `stubString`, `stubTrue`, `subtract`, `sum`, `sumBy`,\r\n * `template`, `times`, `toFinite`, `toInteger`, `toJSON`, `toLength`,\r\n * `toLower`, `toNumber`, `toSafeInteger`, `toString`, `toUpper`, `trim`,\r\n * `trimEnd`, `trimStart`, `truncate`, `unescape`, `uniqueId`, `upperCase`,\r\n * `upperFirst`, `value`, and `words`\r\n *\r\n * @name _\r\n * @constructor\r\n * @category Seq\r\n * @param {*} value The value to wrap in a `lodash` instance.\r\n * @returns {Object} Returns the new `lodash` wrapper instance.\r\n * @example\r\n *\r\n * function square(n) {\r\n * return n * n;\r\n * }\r\n *\r\n * var wrapped = _([1, 2, 3]);\r\n *\r\n * // Returns an unwrapped value.\r\n * wrapped.reduce(_.add);\r\n * // => 6\r\n *\r\n * // Returns a wrapped value.\r\n * var squares = wrapped.map(square);\r\n *\r\n * _.isArray(squares);\r\n * // => false\r\n *\r\n * _.isArray(squares.value());\r\n * // => true\r\n */\r\n function lodash(value) {\r\n if (isObjectLike(value) && !isArray(value) && !(value instanceof LazyWrapper)) {\r\n if (value instanceof LodashWrapper) {\r\n return value;\r\n }\r\n if (hasOwnProperty.call(value, '__wrapped__')) {\r\n return wrapperClone(value);\r\n }\r\n }\r\n return new LodashWrapper(value);\r\n }\r\n\r\n /**\r\n * The base implementation of `_.create` without support for assigning\r\n * properties to the created object.\r\n *\r\n * @private\r\n * @param {Object} proto The object to inherit from.\r\n * @returns {Object} Returns the new object.\r\n */\r\n var baseCreate = (function() {\r\n function object() {}\r\n return function(proto) {\r\n if (!isObject(proto)) {\r\n return {};\r\n }\r\n if (objectCreate) {\r\n return objectCreate(proto);\r\n }\r\n object.prototype = proto;\r\n var result = new object;\r\n object.prototype = undefined;\r\n return result;\r\n };\r\n }());\r\n\r\n /**\r\n * The function whose prototype chain sequence wrappers inherit from.\r\n *\r\n * @private\r\n */\r\n function baseLodash() {\r\n // No operation performed.\r\n }\r\n\r\n /**\r\n * The base constructor for creating `lodash` wrapper objects.\r\n *\r\n * @private\r\n * @param {*} value The value to wrap.\r\n * @param {boolean} [chainAll] Enable explicit method chain sequences.\r\n */\r\n function LodashWrapper(value, chainAll) {\r\n this.__wrapped__ = value;\r\n this.__actions__ = [];\r\n this.__chain__ = !!chainAll;\r\n this.__index__ = 0;\r\n this.__values__ = undefined;\r\n }\r\n\r\n // Ensure wrappers are instances of `baseLodash`.\r\n lodash.prototype = baseLodash.prototype;\r\n lodash.prototype.constructor = lodash;\r\n\r\n LodashWrapper.prototype = baseCreate(baseLodash.prototype);\r\n LodashWrapper.prototype.constructor = LodashWrapper;\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Creates a lazy wrapper object which wraps `value` to enable lazy evaluation.\r\n *\r\n * @private\r\n * @constructor\r\n * @param {*} value The value to wrap.\r\n */\r\n function LazyWrapper(value) {\r\n this.__wrapped__ = value;\r\n this.__actions__ = [];\r\n this.__dir__ = 1;\r\n this.__filtered__ = false;\r\n this.__iteratees__ = [];\r\n this.__takeCount__ = MAX_ARRAY_LENGTH;\r\n this.__views__ = [];\r\n }\r\n\r\n /**\r\n * Creates a clone of the lazy wrapper object.\r\n *\r\n * @private\r\n * @name clone\r\n * @memberOf LazyWrapper\r\n * @returns {Object} Returns the cloned `LazyWrapper` object.\r\n */\r\n function lazyClone() {\r\n var result = new LazyWrapper(this.__wrapped__);\r\n result.__actions__ = copyArray(this.__actions__);\r\n result.__dir__ = this.__dir__;\r\n result.__filtered__ = this.__filtered__;\r\n result.__iteratees__ = copyArray(this.__iteratees__);\r\n result.__takeCount__ = this.__takeCount__;\r\n result.__views__ = copyArray(this.__views__);\r\n return result;\r\n }\r\n\r\n /**\r\n * Reverses the direction of lazy iteration.\r\n *\r\n * @private\r\n * @name reverse\r\n * @memberOf LazyWrapper\r\n * @returns {Object} Returns the new reversed `LazyWrapper` object.\r\n */\r\n function lazyReverse() {\r\n if (this.__filtered__) {\r\n var result = new LazyWrapper(this);\r\n result.__dir__ = -1;\r\n result.__filtered__ = true;\r\n } else {\r\n result = this.clone();\r\n result.__dir__ *= -1;\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Extracts the unwrapped value from its lazy wrapper.\r\n *\r\n * @private\r\n * @name value\r\n * @memberOf LazyWrapper\r\n * @returns {*} Returns the unwrapped value.\r\n */\r\n function lazyValue() {\r\n var array = this.__wrapped__.value(),\r\n dir = this.__dir__,\r\n isArr = isArray(array),\r\n isRight = dir < 0,\r\n arrLength = isArr ? array.length : 0,\r\n view = getView(0, arrLength, this.__views__),\r\n start = view.start,\r\n end = view.end,\r\n length = end - start,\r\n index = isRight ? end : (start - 1),\r\n iteratees = this.__iteratees__,\r\n iterLength = iteratees.length,\r\n resIndex = 0,\r\n takeCount = nativeMin(length, this.__takeCount__);\r\n\r\n if (!isArr || (!isRight && arrLength == length && takeCount == length)) {\r\n return baseWrapperValue(array, this.__actions__);\r\n }\r\n var result = [];\r\n\r\n outer:\r\n while (length-- && resIndex < takeCount) {\r\n index += dir;\r\n\r\n var iterIndex = -1,\r\n value = array[index];\r\n\r\n while (++iterIndex < iterLength) {\r\n var data = iteratees[iterIndex],\r\n iteratee = data.iteratee,\r\n type = data.type,\r\n computed = iteratee(value);\r\n\r\n if (type == LAZY_MAP_FLAG) {\r\n value = computed;\r\n } else if (!computed) {\r\n if (type == LAZY_FILTER_FLAG) {\r\n continue outer;\r\n } else {\r\n break outer;\r\n }\r\n }\r\n }\r\n result[resIndex++] = value;\r\n }\r\n return result;\r\n }\r\n\r\n // Ensure `LazyWrapper` is an instance of `baseLodash`.\r\n LazyWrapper.prototype = baseCreate(baseLodash.prototype);\r\n LazyWrapper.prototype.constructor = LazyWrapper;\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Creates a hash object.\r\n *\r\n * @private\r\n * @constructor\r\n * @param {Array} [entries] The key-value pairs to cache.\r\n */\r\n function Hash(entries) {\r\n var index = -1,\r\n length = entries == null ? 0 : entries.length;\r\n\r\n this.clear();\r\n while (++index < length) {\r\n var entry = entries[index];\r\n this.set(entry[0], entry[1]);\r\n }\r\n }\r\n\r\n /**\r\n * Removes all key-value entries from the hash.\r\n *\r\n * @private\r\n * @name clear\r\n * @memberOf Hash\r\n */\r\n function hashClear() {\r\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\r\n this.size = 0;\r\n }\r\n\r\n /**\r\n * Removes `key` and its value from the hash.\r\n *\r\n * @private\r\n * @name delete\r\n * @memberOf Hash\r\n * @param {Object} hash The hash to modify.\r\n * @param {string} key The key of the value to remove.\r\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\r\n */\r\n function hashDelete(key) {\r\n var result = this.has(key) && delete this.__data__[key];\r\n this.size -= result ? 1 : 0;\r\n return result;\r\n }\r\n\r\n /**\r\n * Gets the hash value for `key`.\r\n *\r\n * @private\r\n * @name get\r\n * @memberOf Hash\r\n * @param {string} key The key of the value to get.\r\n * @returns {*} Returns the entry value.\r\n */\r\n function hashGet(key) {\r\n var data = this.__data__;\r\n if (nativeCreate) {\r\n var result = data[key];\r\n return result === HASH_UNDEFINED ? undefined : result;\r\n }\r\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\r\n }\r\n\r\n /**\r\n * Checks if a hash value for `key` exists.\r\n *\r\n * @private\r\n * @name has\r\n * @memberOf Hash\r\n * @param {string} key The key of the entry to check.\r\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\r\n */\r\n function hashHas(key) {\r\n var data = this.__data__;\r\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\r\n }\r\n\r\n /**\r\n * Sets the hash `key` to `value`.\r\n *\r\n * @private\r\n * @name set\r\n * @memberOf Hash\r\n * @param {string} key The key of the value to set.\r\n * @param {*} value The value to set.\r\n * @returns {Object} Returns the hash instance.\r\n */\r\n function hashSet(key, value) {\r\n var data = this.__data__;\r\n this.size += this.has(key) ? 0 : 1;\r\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\r\n return this;\r\n }\r\n\r\n // Add methods to `Hash`.\r\n Hash.prototype.clear = hashClear;\r\n Hash.prototype['delete'] = hashDelete;\r\n Hash.prototype.get = hashGet;\r\n Hash.prototype.has = hashHas;\r\n Hash.prototype.set = hashSet;\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Creates an list cache object.\r\n *\r\n * @private\r\n * @constructor\r\n * @param {Array} [entries] The key-value pairs to cache.\r\n */\r\n function ListCache(entries) {\r\n var index = -1,\r\n length = entries == null ? 0 : entries.length;\r\n\r\n this.clear();\r\n while (++index < length) {\r\n var entry = entries[index];\r\n this.set(entry[0], entry[1]);\r\n }\r\n }\r\n\r\n /**\r\n * Removes all key-value entries from the list cache.\r\n *\r\n * @private\r\n * @name clear\r\n * @memberOf ListCache\r\n */\r\n function listCacheClear() {\r\n this.__data__ = [];\r\n this.size = 0;\r\n }\r\n\r\n /**\r\n * Removes `key` and its value from the list cache.\r\n *\r\n * @private\r\n * @name delete\r\n * @memberOf ListCache\r\n * @param {string} key The key of the value to remove.\r\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\r\n */\r\n function listCacheDelete(key) {\r\n var data = this.__data__,\r\n index = assocIndexOf(data, key);\r\n\r\n if (index < 0) {\r\n return false;\r\n }\r\n var lastIndex = data.length - 1;\r\n if (index == lastIndex) {\r\n data.pop();\r\n } else {\r\n splice.call(data, index, 1);\r\n }\r\n --this.size;\r\n return true;\r\n }\r\n\r\n /**\r\n * Gets the list cache value for `key`.\r\n *\r\n * @private\r\n * @name get\r\n * @memberOf ListCache\r\n * @param {string} key The key of the value to get.\r\n * @returns {*} Returns the entry value.\r\n */\r\n function listCacheGet(key) {\r\n var data = this.__data__,\r\n index = assocIndexOf(data, key);\r\n\r\n return index < 0 ? undefined : data[index][1];\r\n }\r\n\r\n /**\r\n * Checks if a list cache value for `key` exists.\r\n *\r\n * @private\r\n * @name has\r\n * @memberOf ListCache\r\n * @param {string} key The key of the entry to check.\r\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\r\n */\r\n function listCacheHas(key) {\r\n return assocIndexOf(this.__data__, key) > -1;\r\n }\r\n\r\n /**\r\n * Sets the list cache `key` to `value`.\r\n *\r\n * @private\r\n * @name set\r\n * @memberOf ListCache\r\n * @param {string} key The key of the value to set.\r\n * @param {*} value The value to set.\r\n * @returns {Object} Returns the list cache instance.\r\n */\r\n function listCacheSet(key, value) {\r\n var data = this.__data__,\r\n index = assocIndexOf(data, key);\r\n\r\n if (index < 0) {\r\n ++this.size;\r\n data.push([key, value]);\r\n } else {\r\n data[index][1] = value;\r\n }\r\n return this;\r\n }\r\n\r\n // Add methods to `ListCache`.\r\n ListCache.prototype.clear = listCacheClear;\r\n ListCache.prototype['delete'] = listCacheDelete;\r\n ListCache.prototype.get = listCacheGet;\r\n ListCache.prototype.has = listCacheHas;\r\n ListCache.prototype.set = listCacheSet;\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Creates a map cache object to store key-value pairs.\r\n *\r\n * @private\r\n * @constructor\r\n * @param {Array} [entries] The key-value pairs to cache.\r\n */\r\n function MapCache(entries) {\r\n var index = -1,\r\n length = entries == null ? 0 : entries.length;\r\n\r\n this.clear();\r\n while (++index < length) {\r\n var entry = entries[index];\r\n this.set(entry[0], entry[1]);\r\n }\r\n }\r\n\r\n /**\r\n * Removes all key-value entries from the map.\r\n *\r\n * @private\r\n * @name clear\r\n * @memberOf MapCache\r\n */\r\n function mapCacheClear() {\r\n this.size = 0;\r\n this.__data__ = {\r\n 'hash': new Hash,\r\n 'map': new (Map || ListCache),\r\n 'string': new Hash\r\n };\r\n }\r\n\r\n /**\r\n * Removes `key` and its value from the map.\r\n *\r\n * @private\r\n * @name delete\r\n * @memberOf MapCache\r\n * @param {string} key The key of the value to remove.\r\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\r\n */\r\n function mapCacheDelete(key) {\r\n var result = getMapData(this, key)['delete'](key);\r\n this.size -= result ? 1 : 0;\r\n return result;\r\n }\r\n\r\n /**\r\n * Gets the map value for `key`.\r\n *\r\n * @private\r\n * @name get\r\n * @memberOf MapCache\r\n * @param {string} key The key of the value to get.\r\n * @returns {*} Returns the entry value.\r\n */\r\n function mapCacheGet(key) {\r\n return getMapData(this, key).get(key);\r\n }\r\n\r\n /**\r\n * Checks if a map value for `key` exists.\r\n *\r\n * @private\r\n * @name has\r\n * @memberOf MapCache\r\n * @param {string} key The key of the entry to check.\r\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\r\n */\r\n function mapCacheHas(key) {\r\n return getMapData(this, key).has(key);\r\n }\r\n\r\n /**\r\n * Sets the map `key` to `value`.\r\n *\r\n * @private\r\n * @name set\r\n * @memberOf MapCache\r\n * @param {string} key The key of the value to set.\r\n * @param {*} value The value to set.\r\n * @returns {Object} Returns the map cache instance.\r\n */\r\n function mapCacheSet(key, value) {\r\n var data = getMapData(this, key),\r\n size = data.size;\r\n\r\n data.set(key, value);\r\n this.size += data.size == size ? 0 : 1;\r\n return this;\r\n }\r\n\r\n // Add methods to `MapCache`.\r\n MapCache.prototype.clear = mapCacheClear;\r\n MapCache.prototype['delete'] = mapCacheDelete;\r\n MapCache.prototype.get = mapCacheGet;\r\n MapCache.prototype.has = mapCacheHas;\r\n MapCache.prototype.set = mapCacheSet;\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n *\r\n * Creates an array cache object to store unique values.\r\n *\r\n * @private\r\n * @constructor\r\n * @param {Array} [values] The values to cache.\r\n */\r\n function SetCache(values) {\r\n var index = -1,\r\n length = values == null ? 0 : values.length;\r\n\r\n this.__data__ = new MapCache;\r\n while (++index < length) {\r\n this.add(values[index]);\r\n }\r\n }\r\n\r\n /**\r\n * Adds `value` to the array cache.\r\n *\r\n * @private\r\n * @name add\r\n * @memberOf SetCache\r\n * @alias push\r\n * @param {*} value The value to cache.\r\n * @returns {Object} Returns the cache instance.\r\n */\r\n function setCacheAdd(value) {\r\n this.__data__.set(value, HASH_UNDEFINED);\r\n return this;\r\n }\r\n\r\n /**\r\n * Checks if `value` is in the array cache.\r\n *\r\n * @private\r\n * @name has\r\n * @memberOf SetCache\r\n * @param {*} value The value to search for.\r\n * @returns {number} Returns `true` if `value` is found, else `false`.\r\n */\r\n function setCacheHas(value) {\r\n return this.__data__.has(value);\r\n }\r\n\r\n // Add methods to `SetCache`.\r\n SetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\r\n SetCache.prototype.has = setCacheHas;\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Creates a stack cache object to store key-value pairs.\r\n *\r\n * @private\r\n * @constructor\r\n * @param {Array} [entries] The key-value pairs to cache.\r\n */\r\n function Stack(entries) {\r\n var data = this.__data__ = new ListCache(entries);\r\n this.size = data.size;\r\n }\r\n\r\n /**\r\n * Removes all key-value entries from the stack.\r\n *\r\n * @private\r\n * @name clear\r\n * @memberOf Stack\r\n */\r\n function stackClear() {\r\n this.__data__ = new ListCache;\r\n this.size = 0;\r\n }\r\n\r\n /**\r\n * Removes `key` and its value from the stack.\r\n *\r\n * @private\r\n * @name delete\r\n * @memberOf Stack\r\n * @param {string} key The key of the value to remove.\r\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\r\n */\r\n function stackDelete(key) {\r\n var data = this.__data__,\r\n result = data['delete'](key);\r\n\r\n this.size = data.size;\r\n return result;\r\n }\r\n\r\n /**\r\n * Gets the stack value for `key`.\r\n *\r\n * @private\r\n * @name get\r\n * @memberOf Stack\r\n * @param {string} key The key of the value to get.\r\n * @returns {*} Returns the entry value.\r\n */\r\n function stackGet(key) {\r\n return this.__data__.get(key);\r\n }\r\n\r\n /**\r\n * Checks if a stack value for `key` exists.\r\n *\r\n * @private\r\n * @name has\r\n * @memberOf Stack\r\n * @param {string} key The key of the entry to check.\r\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\r\n */\r\n function stackHas(key) {\r\n return this.__data__.has(key);\r\n }\r\n\r\n /**\r\n * Sets the stack `key` to `value`.\r\n *\r\n * @private\r\n * @name set\r\n * @memberOf Stack\r\n * @param {string} key The key of the value to set.\r\n * @param {*} value The value to set.\r\n * @returns {Object} Returns the stack cache instance.\r\n */\r\n function stackSet(key, value) {\r\n var data = this.__data__;\r\n if (data instanceof ListCache) {\r\n var pairs = data.__data__;\r\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\r\n pairs.push([key, value]);\r\n this.size = ++data.size;\r\n return this;\r\n }\r\n data = this.__data__ = new MapCache(pairs);\r\n }\r\n data.set(key, value);\r\n this.size = data.size;\r\n return this;\r\n }\r\n\r\n // Add methods to `Stack`.\r\n Stack.prototype.clear = stackClear;\r\n Stack.prototype['delete'] = stackDelete;\r\n Stack.prototype.get = stackGet;\r\n Stack.prototype.has = stackHas;\r\n Stack.prototype.set = stackSet;\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Creates an array of the enumerable property names of the array-like `value`.\r\n *\r\n * @private\r\n * @param {*} value The value to query.\r\n * @param {boolean} inherited Specify returning inherited property names.\r\n * @returns {Array} Returns the array of property names.\r\n */\r\n function arrayLikeKeys(value, inherited) {\r\n var isArr = isArray(value),\r\n isArg = !isArr && isArguments(value),\r\n isBuff = !isArr && !isArg && isBuffer(value),\r\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\r\n skipIndexes = isArr || isArg || isBuff || isType,\r\n result = skipIndexes ? baseTimes(value.length, String) : [],\r\n length = result.length;\r\n\r\n for (var key in value) {\r\n if ((inherited || hasOwnProperty.call(value, key)) &&\r\n !(skipIndexes && (\r\n // Safari 9 has enumerable `arguments.length` in strict mode.\r\n key == 'length' ||\r\n // Node.js 0.10 has enumerable non-index properties on buffers.\r\n (isBuff && (key == 'offset' || key == 'parent')) ||\r\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\r\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\r\n // Skip index properties.\r\n isIndex(key, length)\r\n ))) {\r\n result.push(key);\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * This function is like `assignValue` except that it doesn't assign\r\n * `undefined` values.\r\n *\r\n * @private\r\n * @param {Object} object The object to modify.\r\n * @param {string} key The key of the property to assign.\r\n * @param {*} value The value to assign.\r\n */\r\n function assignMergeValue(object, key, value) {\r\n if ((value !== undefined && !eq(object[key], value)) ||\r\n (value === undefined && !(key in object))) {\r\n baseAssignValue(object, key, value);\r\n }\r\n }\r\n\r\n /**\r\n * Assigns `value` to `key` of `object` if the existing value is not equivalent\r\n * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\r\n * for equality comparisons.\r\n *\r\n * @private\r\n * @param {Object} object The object to modify.\r\n * @param {string} key The key of the property to assign.\r\n * @param {*} value The value to assign.\r\n */\r\n function assignValue(object, key, value) {\r\n var objValue = object[key];\r\n if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) ||\r\n (value === undefined && !(key in object))) {\r\n baseAssignValue(object, key, value);\r\n }\r\n }\r\n\r\n /**\r\n * Gets the index at which the `key` is found in `array` of key-value pairs.\r\n *\r\n * @private\r\n * @param {Array} array The array to inspect.\r\n * @param {*} key The key to search for.\r\n * @returns {number} Returns the index of the matched value, else `-1`.\r\n */\r\n function assocIndexOf(array, key) {\r\n var length = array.length;\r\n while (length--) {\r\n if (eq(array[length][0], key)) {\r\n return length;\r\n }\r\n }\r\n return -1;\r\n }\r\n\r\n /**\r\n * Aggregates elements of `collection` on `accumulator` with keys transformed\r\n * by `iteratee` and values set by `setter`.\r\n *\r\n * @private\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} setter The function to set `accumulator` values.\r\n * @param {Function} iteratee The iteratee to transform keys.\r\n * @param {Object} accumulator The initial aggregated object.\r\n * @returns {Function} Returns `accumulator`.\r\n */\r\n function baseAggregator(collection, setter, iteratee, accumulator) {\r\n baseEach(collection, function(value, key, collection) {\r\n setter(accumulator, value, iteratee(value), collection);\r\n });\r\n return accumulator;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.assign` without support for multiple sources\r\n * or `customizer` functions.\r\n *\r\n * @private\r\n * @param {Object} object The destination object.\r\n * @param {Object} source The source object.\r\n * @returns {Object} Returns `object`.\r\n */\r\n function baseAssign(object, source) {\r\n return object && copyObject(source, keys(source), object);\r\n }\r\n\r\n /**\r\n * The base implementation of `_.assignIn` without support for multiple sources\r\n * or `customizer` functions.\r\n *\r\n * @private\r\n * @param {Object} object The destination object.\r\n * @param {Object} source The source object.\r\n * @returns {Object} Returns `object`.\r\n */\r\n function baseAssignIn(object, source) {\r\n return object && copyObject(source, keysIn(source), object);\r\n }\r\n\r\n /**\r\n * The base implementation of `assignValue` and `assignMergeValue` without\r\n * value checks.\r\n *\r\n * @private\r\n * @param {Object} object The object to modify.\r\n * @param {string} key The key of the property to assign.\r\n * @param {*} value The value to assign.\r\n */\r\n function baseAssignValue(object, key, value) {\r\n if (key == '__proto__' && defineProperty) {\r\n defineProperty(object, key, {\r\n 'configurable': true,\r\n 'enumerable': true,\r\n 'value': value,\r\n 'writable': true\r\n });\r\n } else {\r\n object[key] = value;\r\n }\r\n }\r\n\r\n /**\r\n * The base implementation of `_.at` without support for individual paths.\r\n *\r\n * @private\r\n * @param {Object} object The object to iterate over.\r\n * @param {string[]} paths The property paths to pick.\r\n * @returns {Array} Returns the picked elements.\r\n */\r\n function baseAt(object, paths) {\r\n var index = -1,\r\n length = paths.length,\r\n result = Array(length),\r\n skip = object == null;\r\n\r\n while (++index < length) {\r\n result[index] = skip ? undefined : get(object, paths[index]);\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.clamp` which doesn't coerce arguments.\r\n *\r\n * @private\r\n * @param {number} number The number to clamp.\r\n * @param {number} [lower] The lower bound.\r\n * @param {number} upper The upper bound.\r\n * @returns {number} Returns the clamped number.\r\n */\r\n function baseClamp(number, lower, upper) {\r\n if (number === number) {\r\n if (upper !== undefined) {\r\n number = number <= upper ? number : upper;\r\n }\r\n if (lower !== undefined) {\r\n number = number >= lower ? number : lower;\r\n }\r\n }\r\n return number;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.clone` and `_.cloneDeep` which tracks\r\n * traversed objects.\r\n *\r\n * @private\r\n * @param {*} value The value to clone.\r\n * @param {boolean} bitmask The bitmask flags.\r\n * 1 - Deep clone\r\n * 2 - Flatten inherited properties\r\n * 4 - Clone symbols\r\n * @param {Function} [customizer] The function to customize cloning.\r\n * @param {string} [key] The key of `value`.\r\n * @param {Object} [object] The parent object of `value`.\r\n * @param {Object} [stack] Tracks traversed objects and their clone counterparts.\r\n * @returns {*} Returns the cloned value.\r\n */\r\n function baseClone(value, bitmask, customizer, key, object, stack) {\r\n var result,\r\n isDeep = bitmask & CLONE_DEEP_FLAG,\r\n isFlat = bitmask & CLONE_FLAT_FLAG,\r\n isFull = bitmask & CLONE_SYMBOLS_FLAG;\r\n\r\n if (customizer) {\r\n result = object ? customizer(value, key, object, stack) : customizer(value);\r\n }\r\n if (result !== undefined) {\r\n return result;\r\n }\r\n if (!isObject(value)) {\r\n return value;\r\n }\r\n var isArr = isArray(value);\r\n if (isArr) {\r\n result = initCloneArray(value);\r\n if (!isDeep) {\r\n return copyArray(value, result);\r\n }\r\n } else {\r\n var tag = getTag(value),\r\n isFunc = tag == funcTag || tag == genTag;\r\n\r\n if (isBuffer(value)) {\r\n return cloneBuffer(value, isDeep);\r\n }\r\n if (tag == objectTag || tag == argsTag || (isFunc && !object)) {\r\n result = (isFlat || isFunc) ? {} : initCloneObject(value);\r\n if (!isDeep) {\r\n return isFlat\r\n ? copySymbolsIn(value, baseAssignIn(result, value))\r\n : copySymbols(value, baseAssign(result, value));\r\n }\r\n } else {\r\n if (!cloneableTags[tag]) {\r\n return object ? value : {};\r\n }\r\n result = initCloneByTag(value, tag, isDeep);\r\n }\r\n }\r\n // Check for circular references and return its corresponding clone.\r\n stack || (stack = new Stack);\r\n var stacked = stack.get(value);\r\n if (stacked) {\r\n return stacked;\r\n }\r\n stack.set(value, result);\r\n\r\n if (isSet(value)) {\r\n value.forEach(function(subValue) {\r\n result.add(baseClone(subValue, bitmask, customizer, subValue, value, stack));\r\n });\r\n\r\n return result;\r\n }\r\n\r\n if (isMap(value)) {\r\n value.forEach(function(subValue, key) {\r\n result.set(key, baseClone(subValue, bitmask, customizer, key, value, stack));\r\n });\r\n\r\n return result;\r\n }\r\n\r\n var keysFunc = isFull\r\n ? (isFlat ? getAllKeysIn : getAllKeys)\r\n : (isFlat ? keysIn : keys);\r\n\r\n var props = isArr ? undefined : keysFunc(value);\r\n arrayEach(props || value, function(subValue, key) {\r\n if (props) {\r\n key = subValue;\r\n subValue = value[key];\r\n }\r\n // Recursively populate clone (susceptible to call stack limits).\r\n assignValue(result, key, baseClone(subValue, bitmask, customizer, key, value, stack));\r\n });\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.delay` and `_.defer` which accepts `args`\r\n * to provide to `func`.\r\n *\r\n * @private\r\n * @param {Function} func The function to delay.\r\n * @param {number} wait The number of milliseconds to delay invocation.\r\n * @param {Array} args The arguments to provide to `func`.\r\n * @returns {number|Object} Returns the timer id or timeout object.\r\n */\r\n function baseDelay(func, wait, args) {\r\n if (typeof func != 'function') {\r\n throw new TypeError(FUNC_ERROR_TEXT);\r\n }\r\n return setTimeout(function() { func.apply(undefined, args); }, wait);\r\n }\r\n\r\n /**\r\n * The base implementation of methods like `_.difference` without support\r\n * for excluding multiple arrays or iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Array} array The array to inspect.\r\n * @param {Array} values The values to exclude.\r\n * @param {Function} [iteratee] The iteratee invoked per element.\r\n * @param {Function} [comparator] The comparator invoked per element.\r\n * @returns {Array} Returns the new array of filtered values.\r\n */\r\n function baseDifference(array, values, iteratee, comparator) {\r\n var index = -1,\r\n includes = arrayIncludes,\r\n isCommon = true,\r\n length = array.length,\r\n result = [],\r\n valuesLength = values.length;\r\n\r\n if (!length) {\r\n return result;\r\n }\r\n if (iteratee) {\r\n values = arrayMap(values, baseUnary(iteratee));\r\n }\r\n if (comparator) {\r\n includes = arrayIncludesWith;\r\n isCommon = false;\r\n }\r\n else if (values.length >= LARGE_ARRAY_SIZE) {\r\n includes = cacheHas;\r\n isCommon = false;\r\n values = new SetCache(values);\r\n }\r\n outer:\r\n while (++index < length) {\r\n var value = array[index],\r\n computed = iteratee == null ? value : iteratee(value);\r\n\r\n value = (comparator || value !== 0) ? value : 0;\r\n if (isCommon && computed === computed) {\r\n var valuesIndex = valuesLength;\r\n while (valuesIndex--) {\r\n if (values[valuesIndex] === computed) {\r\n continue outer;\r\n }\r\n }\r\n result.push(value);\r\n }\r\n else if (!includes(values, computed, comparator)) {\r\n result.push(value);\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.forEach` without support for iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} iteratee The function invoked per iteration.\r\n * @returns {Array|Object} Returns `collection`.\r\n */\r\n var baseEach = createBaseEach(baseForOwn);\r\n\r\n /**\r\n * The base implementation of `_.every` without support for iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} predicate The function invoked per iteration.\r\n * @returns {boolean} Returns `true` if all elements pass the predicate check,\r\n * else `false`\r\n */\r\n function baseEvery(collection, predicate) {\r\n var result = true;\r\n baseEach(collection, function(value, index, collection) {\r\n result = !!predicate(value, index, collection);\r\n return result;\r\n });\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of methods like `_.max` and `_.min` which accepts a\r\n * `comparator` to determine the extremum value.\r\n *\r\n * @private\r\n * @param {Array} array The array to iterate over.\r\n * @param {Function} iteratee The iteratee invoked per iteration.\r\n * @param {Function} comparator The comparator used to compare values.\r\n * @returns {*} Returns the extremum value.\r\n */\r\n function baseExtremum(array, iteratee, comparator) {\r\n var index = -1,\r\n length = array.length;\r\n\r\n while (++index < length) {\r\n var value = array[index],\r\n current = iteratee(value);\r\n\r\n if (current != null && (computed === undefined\r\n ? (current === current && !isSymbol(current))\r\n : comparator(current, computed)\r\n )) {\r\n var computed = current,\r\n result = value;\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.filter` without support for iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} predicate The function invoked per iteration.\r\n * @returns {Array} Returns the new filtered array.\r\n */\r\n function baseFilter(collection, predicate) {\r\n var result = [];\r\n baseEach(collection, function(value, index, collection) {\r\n if (predicate(value, index, collection)) {\r\n result.push(value);\r\n }\r\n });\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.flatten` with support for restricting flattening.\r\n *\r\n * @private\r\n * @param {Array} array The array to flatten.\r\n * @param {number} depth The maximum recursion depth.\r\n * @param {boolean} [predicate=isFlattenable] The function invoked per iteration.\r\n * @param {boolean} [isStrict] Restrict to values that pass `predicate` checks.\r\n * @param {Array} [result=[]] The initial result value.\r\n * @returns {Array} Returns the new flattened array.\r\n */\r\n function baseFlatten(array, depth, predicate, isStrict, result) {\r\n var index = -1,\r\n length = array.length;\r\n\r\n predicate || (predicate = isFlattenable);\r\n result || (result = []);\r\n\r\n while (++index < length) {\r\n var value = array[index];\r\n if (depth > 0 && predicate(value)) {\r\n if (depth > 1) {\r\n // Recursively flatten arrays (susceptible to call stack limits).\r\n baseFlatten(value, depth - 1, predicate, isStrict, result);\r\n } else {\r\n arrayPush(result, value);\r\n }\r\n } else if (!isStrict) {\r\n result[result.length] = value;\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `baseForOwn` which iterates over `object`\r\n * properties returned by `keysFunc` and invokes `iteratee` for each property.\r\n * Iteratee functions may exit iteration early by explicitly returning `false`.\r\n *\r\n * @private\r\n * @param {Object} object The object to iterate over.\r\n * @param {Function} iteratee The function invoked per iteration.\r\n * @param {Function} keysFunc The function to get the keys of `object`.\r\n * @returns {Object} Returns `object`.\r\n */\r\n var baseFor = createBaseFor();\r\n\r\n /**\r\n * This function is like `baseFor` except that it iterates over properties\r\n * in the opposite order.\r\n *\r\n * @private\r\n * @param {Object} object The object to iterate over.\r\n * @param {Function} iteratee The function invoked per iteration.\r\n * @param {Function} keysFunc The function to get the keys of `object`.\r\n * @returns {Object} Returns `object`.\r\n */\r\n var baseForRight = createBaseFor(true);\r\n\r\n /**\r\n * The base implementation of `_.forOwn` without support for iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Object} object The object to iterate over.\r\n * @param {Function} iteratee The function invoked per iteration.\r\n * @returns {Object} Returns `object`.\r\n */\r\n function baseForOwn(object, iteratee) {\r\n return object && baseFor(object, iteratee, keys);\r\n }\r\n\r\n /**\r\n * The base implementation of `_.forOwnRight` without support for iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Object} object The object to iterate over.\r\n * @param {Function} iteratee The function invoked per iteration.\r\n * @returns {Object} Returns `object`.\r\n */\r\n function baseForOwnRight(object, iteratee) {\r\n return object && baseForRight(object, iteratee, keys);\r\n }\r\n\r\n /**\r\n * The base implementation of `_.functions` which creates an array of\r\n * `object` function property names filtered from `props`.\r\n *\r\n * @private\r\n * @param {Object} object The object to inspect.\r\n * @param {Array} props The property names to filter.\r\n * @returns {Array} Returns the function names.\r\n */\r\n function baseFunctions(object, props) {\r\n return arrayFilter(props, function(key) {\r\n return isFunction(object[key]);\r\n });\r\n }\r\n\r\n /**\r\n * The base implementation of `_.get` without support for default values.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @param {Array|string} path The path of the property to get.\r\n * @returns {*} Returns the resolved value.\r\n */\r\n function baseGet(object, path) {\r\n path = castPath(path, object);\r\n\r\n var index = 0,\r\n length = path.length;\r\n\r\n while (object != null && index < length) {\r\n object = object[toKey(path[index++])];\r\n }\r\n return (index && index == length) ? object : undefined;\r\n }\r\n\r\n /**\r\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\r\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\r\n * symbols of `object`.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @param {Function} keysFunc The function to get the keys of `object`.\r\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\r\n * @returns {Array} Returns the array of property names and symbols.\r\n */\r\n function baseGetAllKeys(object, keysFunc, symbolsFunc) {\r\n var result = keysFunc(object);\r\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\r\n }\r\n\r\n /**\r\n * The base implementation of `getTag` without fallbacks for buggy environments.\r\n *\r\n * @private\r\n * @param {*} value The value to query.\r\n * @returns {string} Returns the `toStringTag`.\r\n */\r\n function baseGetTag(value) {\r\n if (value == null) {\r\n return value === undefined ? undefinedTag : nullTag;\r\n }\r\n return (symToStringTag && symToStringTag in Object(value))\r\n ? getRawTag(value)\r\n : objectToString(value);\r\n }\r\n\r\n /**\r\n * The base implementation of `_.gt` which doesn't coerce arguments.\r\n *\r\n * @private\r\n * @param {*} value The value to compare.\r\n * @param {*} other The other value to compare.\r\n * @returns {boolean} Returns `true` if `value` is greater than `other`,\r\n * else `false`.\r\n */\r\n function baseGt(value, other) {\r\n return value > other;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.has` without support for deep paths.\r\n *\r\n * @private\r\n * @param {Object} [object] The object to query.\r\n * @param {Array|string} key The key to check.\r\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\r\n */\r\n function baseHas(object, key) {\r\n return object != null && hasOwnProperty.call(object, key);\r\n }\r\n\r\n /**\r\n * The base implementation of `_.hasIn` without support for deep paths.\r\n *\r\n * @private\r\n * @param {Object} [object] The object to query.\r\n * @param {Array|string} key The key to check.\r\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\r\n */\r\n function baseHasIn(object, key) {\r\n return object != null && key in Object(object);\r\n }\r\n\r\n /**\r\n * The base implementation of methods like `_.intersection`, without support\r\n * for iteratee shorthands, that accepts an array of arrays to inspect.\r\n *\r\n * @private\r\n * @param {Array} arrays The arrays to inspect.\r\n * @param {Function} [iteratee] The iteratee invoked per element.\r\n * @param {Function} [comparator] The comparator invoked per element.\r\n * @returns {Array} Returns the new array of shared values.\r\n */\r\n function baseIntersection(arrays, iteratee, comparator) {\r\n var includes = comparator ? arrayIncludesWith : arrayIncludes,\r\n length = arrays[0].length,\r\n othLength = arrays.length,\r\n othIndex = othLength,\r\n caches = Array(othLength),\r\n maxLength = Infinity,\r\n result = [];\r\n\r\n while (othIndex--) {\r\n var array = arrays[othIndex];\r\n if (othIndex && iteratee) {\r\n array = arrayMap(array, baseUnary(iteratee));\r\n }\r\n maxLength = nativeMin(array.length, maxLength);\r\n caches[othIndex] = !comparator && (iteratee || (length >= 120 && array.length >= 120))\r\n ? new SetCache(othIndex && array)\r\n : undefined;\r\n }\r\n array = arrays[0];\r\n\r\n var index = -1,\r\n seen = caches[0];\r\n\r\n outer:\r\n while (++index < length && result.length < maxLength) {\r\n var value = array[index],\r\n computed = iteratee ? iteratee(value) : value;\r\n\r\n value = (comparator || value !== 0) ? value : 0;\r\n if (!(seen\r\n ? cacheHas(seen, computed)\r\n : includes(result, computed, comparator)\r\n )) {\r\n othIndex = othLength;\r\n while (--othIndex) {\r\n var cache = caches[othIndex];\r\n if (!(cache\r\n ? cacheHas(cache, computed)\r\n : includes(arrays[othIndex], computed, comparator))\r\n ) {\r\n continue outer;\r\n }\r\n }\r\n if (seen) {\r\n seen.push(computed);\r\n }\r\n result.push(value);\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.invert` and `_.invertBy` which inverts\r\n * `object` with values transformed by `iteratee` and set by `setter`.\r\n *\r\n * @private\r\n * @param {Object} object The object to iterate over.\r\n * @param {Function} setter The function to set `accumulator` values.\r\n * @param {Function} iteratee The iteratee to transform values.\r\n * @param {Object} accumulator The initial inverted object.\r\n * @returns {Function} Returns `accumulator`.\r\n */\r\n function baseInverter(object, setter, iteratee, accumulator) {\r\n baseForOwn(object, function(value, key, object) {\r\n setter(accumulator, iteratee(value), key, object);\r\n });\r\n return accumulator;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.invoke` without support for individual\r\n * method arguments.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @param {Array|string} path The path of the method to invoke.\r\n * @param {Array} args The arguments to invoke the method with.\r\n * @returns {*} Returns the result of the invoked method.\r\n */\r\n function baseInvoke(object, path, args) {\r\n path = castPath(path, object);\r\n object = parent(object, path);\r\n var func = object == null ? object : object[toKey(last(path))];\r\n return func == null ? undefined : apply(func, object, args);\r\n }\r\n\r\n /**\r\n * The base implementation of `_.isArguments`.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\r\n */\r\n function baseIsArguments(value) {\r\n return isObjectLike(value) && baseGetTag(value) == argsTag;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.isDate` without Node.js optimizations.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a date object, else `false`.\r\n */\r\n function baseIsDate(value) {\r\n return isObjectLike(value) && baseGetTag(value) == dateTag;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.isEqual` which supports partial comparisons\r\n * and tracks traversed objects.\r\n *\r\n * @private\r\n * @param {*} value The value to compare.\r\n * @param {*} other The other value to compare.\r\n * @param {boolean} bitmask The bitmask flags.\r\n * 1 - Unordered comparison\r\n * 2 - Partial comparison\r\n * @param {Function} [customizer] The function to customize comparisons.\r\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\r\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\r\n */\r\n function baseIsEqual(value, other, bitmask, customizer, stack) {\r\n if (value === other) {\r\n return true;\r\n }\r\n if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\r\n return value !== value && other !== other;\r\n }\r\n return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\r\n }\r\n\r\n /**\r\n * A specialized version of `baseIsEqual` for arrays and objects which performs\r\n * deep comparisons and tracks traversed objects enabling objects with circular\r\n * references to be compared.\r\n *\r\n * @private\r\n * @param {Object} object The object to compare.\r\n * @param {Object} other The other object to compare.\r\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\r\n * @param {Function} customizer The function to customize comparisons.\r\n * @param {Function} equalFunc The function to determine equivalents of values.\r\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\r\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\r\n */\r\n function baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\r\n var objIsArr = isArray(object),\r\n othIsArr = isArray(other),\r\n objTag = objIsArr ? arrayTag : getTag(object),\r\n othTag = othIsArr ? arrayTag : getTag(other);\r\n\r\n objTag = objTag == argsTag ? objectTag : objTag;\r\n othTag = othTag == argsTag ? objectTag : othTag;\r\n\r\n var objIsObj = objTag == objectTag,\r\n othIsObj = othTag == objectTag,\r\n isSameTag = objTag == othTag;\r\n\r\n if (isSameTag && isBuffer(object)) {\r\n if (!isBuffer(other)) {\r\n return false;\r\n }\r\n objIsArr = true;\r\n objIsObj = false;\r\n }\r\n if (isSameTag && !objIsObj) {\r\n stack || (stack = new Stack);\r\n return (objIsArr || isTypedArray(object))\r\n ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\r\n : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\r\n }\r\n if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\r\n var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\r\n othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\r\n\r\n if (objIsWrapped || othIsWrapped) {\r\n var objUnwrapped = objIsWrapped ? object.value() : object,\r\n othUnwrapped = othIsWrapped ? other.value() : other;\r\n\r\n stack || (stack = new Stack);\r\n return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\r\n }\r\n }\r\n if (!isSameTag) {\r\n return false;\r\n }\r\n stack || (stack = new Stack);\r\n return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\r\n }\r\n\r\n /**\r\n * The base implementation of `_.isMap` without Node.js optimizations.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a map, else `false`.\r\n */\r\n function baseIsMap(value) {\r\n return isObjectLike(value) && getTag(value) == mapTag;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.isMatch` without support for iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Object} object The object to inspect.\r\n * @param {Object} source The object of property values to match.\r\n * @param {Array} matchData The property names, values, and compare flags to match.\r\n * @param {Function} [customizer] The function to customize comparisons.\r\n * @returns {boolean} Returns `true` if `object` is a match, else `false`.\r\n */\r\n function baseIsMatch(object, source, matchData, customizer) {\r\n var index = matchData.length,\r\n length = index,\r\n noCustomizer = !customizer;\r\n\r\n if (object == null) {\r\n return !length;\r\n }\r\n object = Object(object);\r\n while (index--) {\r\n var data = matchData[index];\r\n if ((noCustomizer && data[2])\r\n ? data[1] !== object[data[0]]\r\n : !(data[0] in object)\r\n ) {\r\n return false;\r\n }\r\n }\r\n while (++index < length) {\r\n data = matchData[index];\r\n var key = data[0],\r\n objValue = object[key],\r\n srcValue = data[1];\r\n\r\n if (noCustomizer && data[2]) {\r\n if (objValue === undefined && !(key in object)) {\r\n return false;\r\n }\r\n } else {\r\n var stack = new Stack;\r\n if (customizer) {\r\n var result = customizer(objValue, srcValue, key, object, source, stack);\r\n }\r\n if (!(result === undefined\r\n ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack)\r\n : result\r\n )) {\r\n return false;\r\n }\r\n }\r\n }\r\n return true;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.isNative` without bad shim checks.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a native function,\r\n * else `false`.\r\n */\r\n function baseIsNative(value) {\r\n if (!isObject(value) || isMasked(value)) {\r\n return false;\r\n }\r\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\r\n return pattern.test(toSource(value));\r\n }\r\n\r\n /**\r\n * The base implementation of `_.isRegExp` without Node.js optimizations.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a regexp, else `false`.\r\n */\r\n function baseIsRegExp(value) {\r\n return isObjectLike(value) && baseGetTag(value) == regexpTag;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.isSet` without Node.js optimizations.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a set, else `false`.\r\n */\r\n function baseIsSet(value) {\r\n return isObjectLike(value) && getTag(value) == setTag;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\r\n */\r\n function baseIsTypedArray(value) {\r\n return isObjectLike(value) &&\r\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\r\n }\r\n\r\n /**\r\n * The base implementation of `_.iteratee`.\r\n *\r\n * @private\r\n * @param {*} [value=_.identity] The value to convert to an iteratee.\r\n * @returns {Function} Returns the iteratee.\r\n */\r\n function baseIteratee(value) {\r\n // Don't store the `typeof` result in a variable to avoid a JIT bug in Safari 9.\r\n // See https://bugs.webkit.org/show_bug.cgi?id=156034 for more details.\r\n if (typeof value == 'function') {\r\n return value;\r\n }\r\n if (value == null) {\r\n return identity;\r\n }\r\n if (typeof value == 'object') {\r\n return isArray(value)\r\n ? baseMatchesProperty(value[0], value[1])\r\n : baseMatches(value);\r\n }\r\n return property(value);\r\n }\r\n\r\n /**\r\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @returns {Array} Returns the array of property names.\r\n */\r\n function baseKeys(object) {\r\n if (!isPrototype(object)) {\r\n return nativeKeys(object);\r\n }\r\n var result = [];\r\n for (var key in Object(object)) {\r\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\r\n result.push(key);\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.keysIn` which doesn't treat sparse arrays as dense.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @returns {Array} Returns the array of property names.\r\n */\r\n function baseKeysIn(object) {\r\n if (!isObject(object)) {\r\n return nativeKeysIn(object);\r\n }\r\n var isProto = isPrototype(object),\r\n result = [];\r\n\r\n for (var key in object) {\r\n if (!(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) {\r\n result.push(key);\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.lt` which doesn't coerce arguments.\r\n *\r\n * @private\r\n * @param {*} value The value to compare.\r\n * @param {*} other The other value to compare.\r\n * @returns {boolean} Returns `true` if `value` is less than `other`,\r\n * else `false`.\r\n */\r\n function baseLt(value, other) {\r\n return value < other;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.map` without support for iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} iteratee The function invoked per iteration.\r\n * @returns {Array} Returns the new mapped array.\r\n */\r\n function baseMap(collection, iteratee) {\r\n var index = -1,\r\n result = isArrayLike(collection) ? Array(collection.length) : [];\r\n\r\n baseEach(collection, function(value, key, collection) {\r\n result[++index] = iteratee(value, key, collection);\r\n });\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.matches` which doesn't clone `source`.\r\n *\r\n * @private\r\n * @param {Object} source The object of property values to match.\r\n * @returns {Function} Returns the new spec function.\r\n */\r\n function baseMatches(source) {\r\n var matchData = getMatchData(source);\r\n if (matchData.length == 1 && matchData[0][2]) {\r\n return matchesStrictComparable(matchData[0][0], matchData[0][1]);\r\n }\r\n return function(object) {\r\n return object === source || baseIsMatch(object, source, matchData);\r\n };\r\n }\r\n\r\n /**\r\n * The base implementation of `_.matchesProperty` which doesn't clone `srcValue`.\r\n *\r\n * @private\r\n * @param {string} path The path of the property to get.\r\n * @param {*} srcValue The value to match.\r\n * @returns {Function} Returns the new spec function.\r\n */\r\n function baseMatchesProperty(path, srcValue) {\r\n if (isKey(path) && isStrictComparable(srcValue)) {\r\n return matchesStrictComparable(toKey(path), srcValue);\r\n }\r\n return function(object) {\r\n var objValue = get(object, path);\r\n return (objValue === undefined && objValue === srcValue)\r\n ? hasIn(object, path)\r\n : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);\r\n };\r\n }\r\n\r\n /**\r\n * The base implementation of `_.merge` without support for multiple sources.\r\n *\r\n * @private\r\n * @param {Object} object The destination object.\r\n * @param {Object} source The source object.\r\n * @param {number} srcIndex The index of `source`.\r\n * @param {Function} [customizer] The function to customize merged values.\r\n * @param {Object} [stack] Tracks traversed source values and their merged\r\n * counterparts.\r\n */\r\n function baseMerge(object, source, srcIndex, customizer, stack) {\r\n if (object === source) {\r\n return;\r\n }\r\n baseFor(source, function(srcValue, key) {\r\n if (isObject(srcValue)) {\r\n stack || (stack = new Stack);\r\n baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack);\r\n }\r\n else {\r\n var newValue = customizer\r\n ? customizer(safeGet(object, key), srcValue, (key + ''), object, source, stack)\r\n : undefined;\r\n\r\n if (newValue === undefined) {\r\n newValue = srcValue;\r\n }\r\n assignMergeValue(object, key, newValue);\r\n }\r\n }, keysIn);\r\n }\r\n\r\n /**\r\n * A specialized version of `baseMerge` for arrays and objects which performs\r\n * deep merges and tracks traversed objects enabling objects with circular\r\n * references to be merged.\r\n *\r\n * @private\r\n * @param {Object} object The destination object.\r\n * @param {Object} source The source object.\r\n * @param {string} key The key of the value to merge.\r\n * @param {number} srcIndex The index of `source`.\r\n * @param {Function} mergeFunc The function to merge values.\r\n * @param {Function} [customizer] The function to customize assigned values.\r\n * @param {Object} [stack] Tracks traversed source values and their merged\r\n * counterparts.\r\n */\r\n function baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) {\r\n var objValue = safeGet(object, key),\r\n srcValue = safeGet(source, key),\r\n stacked = stack.get(srcValue);\r\n\r\n if (stacked) {\r\n assignMergeValue(object, key, stacked);\r\n return;\r\n }\r\n var newValue = customizer\r\n ? customizer(objValue, srcValue, (key + ''), object, source, stack)\r\n : undefined;\r\n\r\n var isCommon = newValue === undefined;\r\n\r\n if (isCommon) {\r\n var isArr = isArray(srcValue),\r\n isBuff = !isArr && isBuffer(srcValue),\r\n isTyped = !isArr && !isBuff && isTypedArray(srcValue);\r\n\r\n newValue = srcValue;\r\n if (isArr || isBuff || isTyped) {\r\n if (isArray(objValue)) {\r\n newValue = objValue;\r\n }\r\n else if (isArrayLikeObject(objValue)) {\r\n newValue = copyArray(objValue);\r\n }\r\n else if (isBuff) {\r\n isCommon = false;\r\n newValue = cloneBuffer(srcValue, true);\r\n }\r\n else if (isTyped) {\r\n isCommon = false;\r\n newValue = cloneTypedArray(srcValue, true);\r\n }\r\n else {\r\n newValue = [];\r\n }\r\n }\r\n else if (isPlainObject(srcValue) || isArguments(srcValue)) {\r\n newValue = objValue;\r\n if (isArguments(objValue)) {\r\n newValue = toPlainObject(objValue);\r\n }\r\n else if (!isObject(objValue) || (srcIndex && isFunction(objValue))) {\r\n newValue = initCloneObject(srcValue);\r\n }\r\n }\r\n else {\r\n isCommon = false;\r\n }\r\n }\r\n if (isCommon) {\r\n // Recursively merge objects and arrays (susceptible to call stack limits).\r\n stack.set(srcValue, newValue);\r\n mergeFunc(newValue, srcValue, srcIndex, customizer, stack);\r\n stack['delete'](srcValue);\r\n }\r\n assignMergeValue(object, key, newValue);\r\n }\r\n\r\n /**\r\n * The base implementation of `_.orderBy` without param guards.\r\n *\r\n * @private\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function[]|Object[]|string[]} iteratees The iteratees to sort by.\r\n * @param {string[]} orders The sort orders of `iteratees`.\r\n * @returns {Array} Returns the new sorted array.\r\n */\r\n function baseOrderBy(collection, iteratees, orders) {\r\n var index = -1;\r\n iteratees = arrayMap(iteratees.length ? iteratees : [identity], baseUnary(baseIteratee));\r\n\r\n var result = baseMap(collection, function(value, key, collection) {\r\n var criteria = arrayMap(iteratees, function(iteratee) {\r\n return iteratee(value);\r\n });\r\n return { 'criteria': criteria, 'index': ++index, 'value': value };\r\n });\r\n\r\n return baseSortBy(result, function(object, other) {\r\n return compareMultiple(object, other, orders);\r\n });\r\n }\r\n\r\n /**\r\n * The base implementation of `_.pick` without support for individual\r\n * property identifiers.\r\n *\r\n * @private\r\n * @param {Object} object The source object.\r\n * @param {string[]} paths The property paths to pick.\r\n * @returns {Object} Returns the new object.\r\n */\r\n function basePick(object, paths) {\r\n return basePickBy(object, paths, function(value, path) {\r\n return hasIn(object, path);\r\n });\r\n }\r\n\r\n /**\r\n * The base implementation of `_.pickBy` without support for iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Object} object The source object.\r\n * @param {string[]} paths The property paths to pick.\r\n * @param {Function} predicate The function invoked per property.\r\n * @returns {Object} Returns the new object.\r\n */\r\n function basePickBy(object, paths, predicate) {\r\n var index = -1,\r\n length = paths.length,\r\n result = {};\r\n\r\n while (++index < length) {\r\n var path = paths[index],\r\n value = baseGet(object, path);\r\n\r\n if (predicate(value, path)) {\r\n baseSet(result, castPath(path, object), value);\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * A specialized version of `baseProperty` which supports deep paths.\r\n *\r\n * @private\r\n * @param {Array|string} path The path of the property to get.\r\n * @returns {Function} Returns the new accessor function.\r\n */\r\n function basePropertyDeep(path) {\r\n return function(object) {\r\n return baseGet(object, path);\r\n };\r\n }\r\n\r\n /**\r\n * The base implementation of `_.random` without support for returning\r\n * floating-point numbers.\r\n *\r\n * @private\r\n * @param {number} lower The lower bound.\r\n * @param {number} upper The upper bound.\r\n * @returns {number} Returns the random number.\r\n */\r\n function baseRandom(lower, upper) {\r\n return lower + nativeFloor(nativeRandom() * (upper - lower + 1));\r\n }\r\n\r\n /**\r\n * The base implementation of `_.range` and `_.rangeRight` which doesn't\r\n * coerce arguments.\r\n *\r\n * @private\r\n * @param {number} start The start of the range.\r\n * @param {number} end The end of the range.\r\n * @param {number} step The value to increment or decrement by.\r\n * @param {boolean} [fromRight] Specify iterating from right to left.\r\n * @returns {Array} Returns the range of numbers.\r\n */\r\n function baseRange(start, end, step, fromRight) {\r\n var index = -1,\r\n length = nativeMax(nativeCeil((end - start) / (step || 1)), 0),\r\n result = Array(length);\r\n\r\n while (length--) {\r\n result[fromRight ? length : ++index] = start;\r\n start += step;\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.rest` which doesn't validate or coerce arguments.\r\n *\r\n * @private\r\n * @param {Function} func The function to apply a rest parameter to.\r\n * @param {number} [start=func.length-1] The start position of the rest parameter.\r\n * @returns {Function} Returns the new function.\r\n */\r\n function baseRest(func, start) {\r\n return setToString(overRest(func, start, identity), func + '');\r\n }\r\n\r\n /**\r\n * The base implementation of `_.set`.\r\n *\r\n * @private\r\n * @param {Object} object The object to modify.\r\n * @param {Array|string} path The path of the property to set.\r\n * @param {*} value The value to set.\r\n * @param {Function} [customizer] The function to customize path creation.\r\n * @returns {Object} Returns `object`.\r\n */\r\n function baseSet(object, path, value, customizer) {\r\n if (!isObject(object)) {\r\n return object;\r\n }\r\n path = castPath(path, object);\r\n\r\n var index = -1,\r\n length = path.length,\r\n lastIndex = length - 1,\r\n nested = object;\r\n\r\n while (nested != null && ++index < length) {\r\n var key = toKey(path[index]),\r\n newValue = value;\r\n\r\n if (index != lastIndex) {\r\n var objValue = nested[key];\r\n newValue = customizer ? customizer(objValue, key, nested) : undefined;\r\n if (newValue === undefined) {\r\n newValue = isObject(objValue)\r\n ? objValue\r\n : (isIndex(path[index + 1]) ? [] : {});\r\n }\r\n }\r\n assignValue(nested, key, newValue);\r\n nested = nested[key];\r\n }\r\n return object;\r\n }\r\n\r\n /**\r\n * The base implementation of `setData` without support for hot loop shorting.\r\n *\r\n * @private\r\n * @param {Function} func The function to associate metadata with.\r\n * @param {*} data The metadata.\r\n * @returns {Function} Returns `func`.\r\n */\r\n var baseSetData = !metaMap ? identity : function(func, data) {\r\n metaMap.set(func, data);\r\n return func;\r\n };\r\n\r\n /**\r\n * The base implementation of `setToString` without support for hot loop shorting.\r\n *\r\n * @private\r\n * @param {Function} func The function to modify.\r\n * @param {Function} string The `toString` result.\r\n * @returns {Function} Returns `func`.\r\n */\r\n var baseSetToString = !defineProperty ? identity : function(func, string) {\r\n return defineProperty(func, 'toString', {\r\n 'configurable': true,\r\n 'enumerable': false,\r\n 'value': constant(string),\r\n 'writable': true\r\n });\r\n };\r\n\r\n /**\r\n * The base implementation of `_.slice` without an iteratee call guard.\r\n *\r\n * @private\r\n * @param {Array} array The array to slice.\r\n * @param {number} [start=0] The start position.\r\n * @param {number} [end=array.length] The end position.\r\n * @returns {Array} Returns the slice of `array`.\r\n */\r\n function baseSlice(array, start, end) {\r\n var index = -1,\r\n length = array.length;\r\n\r\n if (start < 0) {\r\n start = -start > length ? 0 : (length + start);\r\n }\r\n end = end > length ? length : end;\r\n if (end < 0) {\r\n end += length;\r\n }\r\n length = start > end ? 0 : ((end - start) >>> 0);\r\n start >>>= 0;\r\n\r\n var result = Array(length);\r\n while (++index < length) {\r\n result[index] = array[index + start];\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.some` without support for iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} predicate The function invoked per iteration.\r\n * @returns {boolean} Returns `true` if any element passes the predicate check,\r\n * else `false`.\r\n */\r\n function baseSome(collection, predicate) {\r\n var result;\r\n\r\n baseEach(collection, function(value, index, collection) {\r\n result = predicate(value, index, collection);\r\n return !result;\r\n });\r\n return !!result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.toString` which doesn't convert nullish\r\n * values to empty strings.\r\n *\r\n * @private\r\n * @param {*} value The value to process.\r\n * @returns {string} Returns the string.\r\n */\r\n function baseToString(value) {\r\n // Exit early for strings to avoid a performance hit in some environments.\r\n if (typeof value == 'string') {\r\n return value;\r\n }\r\n if (isArray(value)) {\r\n // Recursively convert values (susceptible to call stack limits).\r\n return arrayMap(value, baseToString) + '';\r\n }\r\n if (isSymbol(value)) {\r\n return symbolToString ? symbolToString.call(value) : '';\r\n }\r\n var result = (value + '');\r\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.uniqBy` without support for iteratee shorthands.\r\n *\r\n * @private\r\n * @param {Array} array The array to inspect.\r\n * @param {Function} [iteratee] The iteratee invoked per element.\r\n * @param {Function} [comparator] The comparator invoked per element.\r\n * @returns {Array} Returns the new duplicate free array.\r\n */\r\n function baseUniq(array, iteratee, comparator) {\r\n var index = -1,\r\n includes = arrayIncludes,\r\n length = array.length,\r\n isCommon = true,\r\n result = [],\r\n seen = result;\r\n\r\n if (comparator) {\r\n isCommon = false;\r\n includes = arrayIncludesWith;\r\n }\r\n else if (length >= LARGE_ARRAY_SIZE) {\r\n var set = iteratee ? null : createSet(array);\r\n if (set) {\r\n return setToArray(set);\r\n }\r\n isCommon = false;\r\n includes = cacheHas;\r\n seen = new SetCache;\r\n }\r\n else {\r\n seen = iteratee ? [] : result;\r\n }\r\n outer:\r\n while (++index < length) {\r\n var value = array[index],\r\n computed = iteratee ? iteratee(value) : value;\r\n\r\n value = (comparator || value !== 0) ? value : 0;\r\n if (isCommon && computed === computed) {\r\n var seenIndex = seen.length;\r\n while (seenIndex--) {\r\n if (seen[seenIndex] === computed) {\r\n continue outer;\r\n }\r\n }\r\n if (iteratee) {\r\n seen.push(computed);\r\n }\r\n result.push(value);\r\n }\r\n else if (!includes(seen, computed, comparator)) {\r\n if (seen !== result) {\r\n seen.push(computed);\r\n }\r\n result.push(value);\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * The base implementation of `_.unset`.\r\n *\r\n * @private\r\n * @param {Object} object The object to modify.\r\n * @param {Array|string} path The property path to unset.\r\n * @returns {boolean} Returns `true` if the property is deleted, else `false`.\r\n */\r\n function baseUnset(object, path) {\r\n path = castPath(path, object);\r\n object = parent(object, path);\r\n return object == null || delete object[toKey(last(path))];\r\n }\r\n\r\n /**\r\n * The base implementation of `wrapperValue` which returns the result of\r\n * performing a sequence of actions on the unwrapped `value`, where each\r\n * successive action is supplied the return value of the previous.\r\n *\r\n * @private\r\n * @param {*} value The unwrapped value.\r\n * @param {Array} actions Actions to perform to resolve the unwrapped value.\r\n * @returns {*} Returns the resolved value.\r\n */\r\n function baseWrapperValue(value, actions) {\r\n var result = value;\r\n if (result instanceof LazyWrapper) {\r\n result = result.value();\r\n }\r\n return arrayReduce(actions, function(result, action) {\r\n return action.func.apply(action.thisArg, arrayPush([result], action.args));\r\n }, result);\r\n }\r\n\r\n /**\r\n * This base implementation of `_.zipObject` which assigns values using `assignFunc`.\r\n *\r\n * @private\r\n * @param {Array} props The property identifiers.\r\n * @param {Array} values The property values.\r\n * @param {Function} assignFunc The function to assign values.\r\n * @returns {Object} Returns the new object.\r\n */\r\n function baseZipObject(props, values, assignFunc) {\r\n var index = -1,\r\n length = props.length,\r\n valsLength = values.length,\r\n result = {};\r\n\r\n while (++index < length) {\r\n var value = index < valsLength ? values[index] : undefined;\r\n assignFunc(result, props[index], value);\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Casts `value` to an empty array if it's not an array like object.\r\n *\r\n * @private\r\n * @param {*} value The value to inspect.\r\n * @returns {Array|Object} Returns the cast array-like object.\r\n */\r\n function castArrayLikeObject(value) {\r\n return isArrayLikeObject(value) ? value : [];\r\n }\r\n\r\n /**\r\n * Casts `value` to a path array if it's not one.\r\n *\r\n * @private\r\n * @param {*} value The value to inspect.\r\n * @param {Object} [object] The object to query keys on.\r\n * @returns {Array} Returns the cast property path array.\r\n */\r\n function castPath(value, object) {\r\n if (isArray(value)) {\r\n return value;\r\n }\r\n return isKey(value, object) ? [value] : stringToPath(toString(value));\r\n }\r\n\r\n /**\r\n * Casts `array` to a slice if it's needed.\r\n *\r\n * @private\r\n * @param {Array} array The array to inspect.\r\n * @param {number} start The start position.\r\n * @param {number} [end=array.length] The end position.\r\n * @returns {Array} Returns the cast slice.\r\n */\r\n function castSlice(array, start, end) {\r\n var length = array.length;\r\n end = end === undefined ? length : end;\r\n return (!start && end >= length) ? array : baseSlice(array, start, end);\r\n }\r\n\r\n /**\r\n * Creates a clone of `buffer`.\r\n *\r\n * @private\r\n * @param {Buffer} buffer The buffer to clone.\r\n * @param {boolean} [isDeep] Specify a deep clone.\r\n * @returns {Buffer} Returns the cloned buffer.\r\n */\r\n function cloneBuffer(buffer, isDeep) {\r\n if (isDeep) {\r\n return buffer.slice();\r\n }\r\n var length = buffer.length,\r\n result = allocUnsafe ? allocUnsafe(length) : new buffer.constructor(length);\r\n\r\n buffer.copy(result);\r\n return result;\r\n }\r\n\r\n /**\r\n * Creates a clone of `arrayBuffer`.\r\n *\r\n * @private\r\n * @param {ArrayBuffer} arrayBuffer The array buffer to clone.\r\n * @returns {ArrayBuffer} Returns the cloned array buffer.\r\n */\r\n function cloneArrayBuffer(arrayBuffer) {\r\n var result = new arrayBuffer.constructor(arrayBuffer.byteLength);\r\n new Uint8Array(result).set(new Uint8Array(arrayBuffer));\r\n return result;\r\n }\r\n\r\n /**\r\n * Creates a clone of `dataView`.\r\n *\r\n * @private\r\n * @param {Object} dataView The data view to clone.\r\n * @param {boolean} [isDeep] Specify a deep clone.\r\n * @returns {Object} Returns the cloned data view.\r\n */\r\n function cloneDataView(dataView, isDeep) {\r\n var buffer = isDeep ? cloneArrayBuffer(dataView.buffer) : dataView.buffer;\r\n return new dataView.constructor(buffer, dataView.byteOffset, dataView.byteLength);\r\n }\r\n\r\n /**\r\n * Creates a clone of `regexp`.\r\n *\r\n * @private\r\n * @param {Object} regexp The regexp to clone.\r\n * @returns {Object} Returns the cloned regexp.\r\n */\r\n function cloneRegExp(regexp) {\r\n var result = new regexp.constructor(regexp.source, reFlags.exec(regexp));\r\n result.lastIndex = regexp.lastIndex;\r\n return result;\r\n }\r\n\r\n /**\r\n * Creates a clone of the `symbol` object.\r\n *\r\n * @private\r\n * @param {Object} symbol The symbol object to clone.\r\n * @returns {Object} Returns the cloned symbol object.\r\n */\r\n function cloneSymbol(symbol) {\r\n return symbolValueOf ? Object(symbolValueOf.call(symbol)) : {};\r\n }\r\n\r\n /**\r\n * Creates a clone of `typedArray`.\r\n *\r\n * @private\r\n * @param {Object} typedArray The typed array to clone.\r\n * @param {boolean} [isDeep] Specify a deep clone.\r\n * @returns {Object} Returns the cloned typed array.\r\n */\r\n function cloneTypedArray(typedArray, isDeep) {\r\n var buffer = isDeep ? cloneArrayBuffer(typedArray.buffer) : typedArray.buffer;\r\n return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);\r\n }\r\n\r\n /**\r\n * Compares values to sort them in ascending order.\r\n *\r\n * @private\r\n * @param {*} value The value to compare.\r\n * @param {*} other The other value to compare.\r\n * @returns {number} Returns the sort order indicator for `value`.\r\n */\r\n function compareAscending(value, other) {\r\n if (value !== other) {\r\n var valIsDefined = value !== undefined,\r\n valIsNull = value === null,\r\n valIsReflexive = value === value,\r\n valIsSymbol = isSymbol(value);\r\n\r\n var othIsDefined = other !== undefined,\r\n othIsNull = other === null,\r\n othIsReflexive = other === other,\r\n othIsSymbol = isSymbol(other);\r\n\r\n if ((!othIsNull && !othIsSymbol && !valIsSymbol && value > other) ||\r\n (valIsSymbol && othIsDefined && othIsReflexive && !othIsNull && !othIsSymbol) ||\r\n (valIsNull && othIsDefined && othIsReflexive) ||\r\n (!valIsDefined && othIsReflexive) ||\r\n !valIsReflexive) {\r\n return 1;\r\n }\r\n if ((!valIsNull && !valIsSymbol && !othIsSymbol && value < other) ||\r\n (othIsSymbol && valIsDefined && valIsReflexive && !valIsNull && !valIsSymbol) ||\r\n (othIsNull && valIsDefined && valIsReflexive) ||\r\n (!othIsDefined && valIsReflexive) ||\r\n !othIsReflexive) {\r\n return -1;\r\n }\r\n }\r\n return 0;\r\n }\r\n\r\n /**\r\n * Used by `_.orderBy` to compare multiple properties of a value to another\r\n * and stable sort them.\r\n *\r\n * If `orders` is unspecified, all values are sorted in ascending order. Otherwise,\r\n * specify an order of \"desc\" for descending or \"asc\" for ascending sort order\r\n * of corresponding values.\r\n *\r\n * @private\r\n * @param {Object} object The object to compare.\r\n * @param {Object} other The other object to compare.\r\n * @param {boolean[]|string[]} orders The order to sort by for each property.\r\n * @returns {number} Returns the sort order indicator for `object`.\r\n */\r\n function compareMultiple(object, other, orders) {\r\n var index = -1,\r\n objCriteria = object.criteria,\r\n othCriteria = other.criteria,\r\n length = objCriteria.length,\r\n ordersLength = orders.length;\r\n\r\n while (++index < length) {\r\n var result = compareAscending(objCriteria[index], othCriteria[index]);\r\n if (result) {\r\n if (index >= ordersLength) {\r\n return result;\r\n }\r\n var order = orders[index];\r\n return result * (order == 'desc' ? -1 : 1);\r\n }\r\n }\r\n // Fixes an `Array#sort` bug in the JS engine embedded in Adobe applications\r\n // that causes it, under certain circumstances, to provide the same value for\r\n // `object` and `other`. See https://github.com/jashkenas/underscore/pull/1247\r\n // for more details.\r\n //\r\n // This also ensures a stable sort in V8 and other engines.\r\n // See https://bugs.chromium.org/p/v8/issues/detail?id=90 for more details.\r\n return object.index - other.index;\r\n }\r\n\r\n /**\r\n * Creates an array that is the composition of partially applied arguments,\r\n * placeholders, and provided arguments into a single array of arguments.\r\n *\r\n * @private\r\n * @param {Array} args The provided arguments.\r\n * @param {Array} partials The arguments to prepend to those provided.\r\n * @param {Array} holders The `partials` placeholder indexes.\r\n * @params {boolean} [isCurried] Specify composing for a curried function.\r\n * @returns {Array} Returns the new array of composed arguments.\r\n */\r\n function composeArgs(args, partials, holders, isCurried) {\r\n var argsIndex = -1,\r\n argsLength = args.length,\r\n holdersLength = holders.length,\r\n leftIndex = -1,\r\n leftLength = partials.length,\r\n rangeLength = nativeMax(argsLength - holdersLength, 0),\r\n result = Array(leftLength + rangeLength),\r\n isUncurried = !isCurried;\r\n\r\n while (++leftIndex < leftLength) {\r\n result[leftIndex] = partials[leftIndex];\r\n }\r\n while (++argsIndex < holdersLength) {\r\n if (isUncurried || argsIndex < argsLength) {\r\n result[holders[argsIndex]] = args[argsIndex];\r\n }\r\n }\r\n while (rangeLength--) {\r\n result[leftIndex++] = args[argsIndex++];\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * This function is like `composeArgs` except that the arguments composition\r\n * is tailored for `_.partialRight`.\r\n *\r\n * @private\r\n * @param {Array} args The provided arguments.\r\n * @param {Array} partials The arguments to append to those provided.\r\n * @param {Array} holders The `partials` placeholder indexes.\r\n * @params {boolean} [isCurried] Specify composing for a curried function.\r\n * @returns {Array} Returns the new array of composed arguments.\r\n */\r\n function composeArgsRight(args, partials, holders, isCurried) {\r\n var argsIndex = -1,\r\n argsLength = args.length,\r\n holdersIndex = -1,\r\n holdersLength = holders.length,\r\n rightIndex = -1,\r\n rightLength = partials.length,\r\n rangeLength = nativeMax(argsLength - holdersLength, 0),\r\n result = Array(rangeLength + rightLength),\r\n isUncurried = !isCurried;\r\n\r\n while (++argsIndex < rangeLength) {\r\n result[argsIndex] = args[argsIndex];\r\n }\r\n var offset = argsIndex;\r\n while (++rightIndex < rightLength) {\r\n result[offset + rightIndex] = partials[rightIndex];\r\n }\r\n while (++holdersIndex < holdersLength) {\r\n if (isUncurried || argsIndex < argsLength) {\r\n result[offset + holders[holdersIndex]] = args[argsIndex++];\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Copies the values of `source` to `array`.\r\n *\r\n * @private\r\n * @param {Array} source The array to copy values from.\r\n * @param {Array} [array=[]] The array to copy values to.\r\n * @returns {Array} Returns `array`.\r\n */\r\n function copyArray(source, array) {\r\n var index = -1,\r\n length = source.length;\r\n\r\n array || (array = Array(length));\r\n while (++index < length) {\r\n array[index] = source[index];\r\n }\r\n return array;\r\n }\r\n\r\n /**\r\n * Copies properties of `source` to `object`.\r\n *\r\n * @private\r\n * @param {Object} source The object to copy properties from.\r\n * @param {Array} props The property identifiers to copy.\r\n * @param {Object} [object={}] The object to copy properties to.\r\n * @param {Function} [customizer] The function to customize copied values.\r\n * @returns {Object} Returns `object`.\r\n */\r\n function copyObject(source, props, object, customizer) {\r\n var isNew = !object;\r\n object || (object = {});\r\n\r\n var index = -1,\r\n length = props.length;\r\n\r\n while (++index < length) {\r\n var key = props[index];\r\n\r\n var newValue = customizer\r\n ? customizer(object[key], source[key], key, object, source)\r\n : undefined;\r\n\r\n if (newValue === undefined) {\r\n newValue = source[key];\r\n }\r\n if (isNew) {\r\n baseAssignValue(object, key, newValue);\r\n } else {\r\n assignValue(object, key, newValue);\r\n }\r\n }\r\n return object;\r\n }\r\n\r\n /**\r\n * Copies own symbols of `source` to `object`.\r\n *\r\n * @private\r\n * @param {Object} source The object to copy symbols from.\r\n * @param {Object} [object={}] The object to copy symbols to.\r\n * @returns {Object} Returns `object`.\r\n */\r\n function copySymbols(source, object) {\r\n return copyObject(source, getSymbols(source), object);\r\n }\r\n\r\n /**\r\n * Copies own and inherited symbols of `source` to `object`.\r\n *\r\n * @private\r\n * @param {Object} source The object to copy symbols from.\r\n * @param {Object} [object={}] The object to copy symbols to.\r\n * @returns {Object} Returns `object`.\r\n */\r\n function copySymbolsIn(source, object) {\r\n return copyObject(source, getSymbolsIn(source), object);\r\n }\r\n\r\n /**\r\n * Creates a function like `_.groupBy`.\r\n *\r\n * @private\r\n * @param {Function} setter The function to set accumulator values.\r\n * @param {Function} [initializer] The accumulator object initializer.\r\n * @returns {Function} Returns the new aggregator function.\r\n */\r\n function createAggregator(setter, initializer) {\r\n return function(collection, iteratee) {\r\n var func = isArray(collection) ? arrayAggregator : baseAggregator,\r\n accumulator = initializer ? initializer() : {};\r\n\r\n return func(collection, setter, baseIteratee(iteratee, 2), accumulator);\r\n };\r\n }\r\n\r\n /**\r\n * Creates a function like `_.assign`.\r\n *\r\n * @private\r\n * @param {Function} assigner The function to assign values.\r\n * @returns {Function} Returns the new assigner function.\r\n */\r\n function createAssigner(assigner) {\r\n return baseRest(function(object, sources) {\r\n var index = -1,\r\n length = sources.length,\r\n customizer = length > 1 ? sources[length - 1] : undefined,\r\n guard = length > 2 ? sources[2] : undefined;\r\n\r\n customizer = (assigner.length > 3 && typeof customizer == 'function')\r\n ? (length--, customizer)\r\n : undefined;\r\n\r\n if (guard && isIterateeCall(sources[0], sources[1], guard)) {\r\n customizer = length < 3 ? undefined : customizer;\r\n length = 1;\r\n }\r\n object = Object(object);\r\n while (++index < length) {\r\n var source = sources[index];\r\n if (source) {\r\n assigner(object, source, index, customizer);\r\n }\r\n }\r\n return object;\r\n });\r\n }\r\n\r\n /**\r\n * Creates a `baseEach` or `baseEachRight` function.\r\n *\r\n * @private\r\n * @param {Function} eachFunc The function to iterate over a collection.\r\n * @param {boolean} [fromRight] Specify iterating from right to left.\r\n * @returns {Function} Returns the new base function.\r\n */\r\n function createBaseEach(eachFunc, fromRight) {\r\n return function(collection, iteratee) {\r\n if (collection == null) {\r\n return collection;\r\n }\r\n if (!isArrayLike(collection)) {\r\n return eachFunc(collection, iteratee);\r\n }\r\n var length = collection.length,\r\n index = fromRight ? length : -1,\r\n iterable = Object(collection);\r\n\r\n while ((fromRight ? index-- : ++index < length)) {\r\n if (iteratee(iterable[index], index, iterable) === false) {\r\n break;\r\n }\r\n }\r\n return collection;\r\n };\r\n }\r\n\r\n /**\r\n * Creates a base function for methods like `_.forIn` and `_.forOwn`.\r\n *\r\n * @private\r\n * @param {boolean} [fromRight] Specify iterating from right to left.\r\n * @returns {Function} Returns the new base function.\r\n */\r\n function createBaseFor(fromRight) {\r\n return function(object, iteratee, keysFunc) {\r\n var index = -1,\r\n iterable = Object(object),\r\n props = keysFunc(object),\r\n length = props.length;\r\n\r\n while (length--) {\r\n var key = props[fromRight ? length : ++index];\r\n if (iteratee(iterable[key], key, iterable) === false) {\r\n break;\r\n }\r\n }\r\n return object;\r\n };\r\n }\r\n\r\n /**\r\n * Creates a function that wraps `func` to invoke it with the optional `this`\r\n * binding of `thisArg`.\r\n *\r\n * @private\r\n * @param {Function} func The function to wrap.\r\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\r\n * @param {*} [thisArg] The `this` binding of `func`.\r\n * @returns {Function} Returns the new wrapped function.\r\n */\r\n function createBind(func, bitmask, thisArg) {\r\n var isBind = bitmask & WRAP_BIND_FLAG,\r\n Ctor = createCtor(func);\r\n\r\n function wrapper() {\r\n var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;\r\n return fn.apply(isBind ? thisArg : this, arguments);\r\n }\r\n return wrapper;\r\n }\r\n\r\n /**\r\n * Creates a function that produces an instance of `Ctor` regardless of\r\n * whether it was invoked as part of a `new` expression or by `call` or `apply`.\r\n *\r\n * @private\r\n * @param {Function} Ctor The constructor to wrap.\r\n * @returns {Function} Returns the new wrapped function.\r\n */\r\n function createCtor(Ctor) {\r\n return function() {\r\n // Use a `switch` statement to work with class constructors. See\r\n // http://ecma-international.org/ecma-262/7.0/#sec-ecmascript-function-objects-call-thisargument-argumentslist\r\n // for more details.\r\n var args = arguments;\r\n switch (args.length) {\r\n case 0: return new Ctor;\r\n case 1: return new Ctor(args[0]);\r\n case 2: return new Ctor(args[0], args[1]);\r\n case 3: return new Ctor(args[0], args[1], args[2]);\r\n case 4: return new Ctor(args[0], args[1], args[2], args[3]);\r\n case 5: return new Ctor(args[0], args[1], args[2], args[3], args[4]);\r\n case 6: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5]);\r\n case 7: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5], args[6]);\r\n }\r\n var thisBinding = baseCreate(Ctor.prototype),\r\n result = Ctor.apply(thisBinding, args);\r\n\r\n // Mimic the constructor's `return` behavior.\r\n // See https://es5.github.io/#x13.2.2 for more details.\r\n return isObject(result) ? result : thisBinding;\r\n };\r\n }\r\n\r\n /**\r\n * Creates a function that wraps `func` to enable currying.\r\n *\r\n * @private\r\n * @param {Function} func The function to wrap.\r\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\r\n * @param {number} arity The arity of `func`.\r\n * @returns {Function} Returns the new wrapped function.\r\n */\r\n function createCurry(func, bitmask, arity) {\r\n var Ctor = createCtor(func);\r\n\r\n function wrapper() {\r\n var length = arguments.length,\r\n args = Array(length),\r\n index = length,\r\n placeholder = getHolder(wrapper);\r\n\r\n while (index--) {\r\n args[index] = arguments[index];\r\n }\r\n var holders = (length < 3 && args[0] !== placeholder && args[length - 1] !== placeholder)\r\n ? []\r\n : replaceHolders(args, placeholder);\r\n\r\n length -= holders.length;\r\n if (length < arity) {\r\n return createRecurry(\r\n func, bitmask, createHybrid, wrapper.placeholder, undefined,\r\n args, holders, undefined, undefined, arity - length);\r\n }\r\n var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;\r\n return apply(fn, this, args);\r\n }\r\n return wrapper;\r\n }\r\n\r\n /**\r\n * Creates a `_.find` or `_.findLast` function.\r\n *\r\n * @private\r\n * @param {Function} findIndexFunc The function to find the collection index.\r\n * @returns {Function} Returns the new find function.\r\n */\r\n function createFind(findIndexFunc) {\r\n return function(collection, predicate, fromIndex) {\r\n var iterable = Object(collection);\r\n if (!isArrayLike(collection)) {\r\n var iteratee = baseIteratee(predicate, 3);\r\n collection = keys(collection);\r\n predicate = function(key) { return iteratee(iterable[key], key, iterable); };\r\n }\r\n var index = findIndexFunc(collection, predicate, fromIndex);\r\n return index > -1 ? iterable[iteratee ? collection[index] : index] : undefined;\r\n };\r\n }\r\n\r\n /**\r\n * Creates a function that wraps `func` to invoke it with optional `this`\r\n * binding of `thisArg`, partial application, and currying.\r\n *\r\n * @private\r\n * @param {Function|string} func The function or method name to wrap.\r\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\r\n * @param {*} [thisArg] The `this` binding of `func`.\r\n * @param {Array} [partials] The arguments to prepend to those provided to\r\n * the new function.\r\n * @param {Array} [holders] The `partials` placeholder indexes.\r\n * @param {Array} [partialsRight] The arguments to append to those provided\r\n * to the new function.\r\n * @param {Array} [holdersRight] The `partialsRight` placeholder indexes.\r\n * @param {Array} [argPos] The argument positions of the new function.\r\n * @param {number} [ary] The arity cap of `func`.\r\n * @param {number} [arity] The arity of `func`.\r\n * @returns {Function} Returns the new wrapped function.\r\n */\r\n function createHybrid(func, bitmask, thisArg, partials, holders, partialsRight, holdersRight, argPos, ary, arity) {\r\n var isAry = bitmask & WRAP_ARY_FLAG,\r\n isBind = bitmask & WRAP_BIND_FLAG,\r\n isBindKey = bitmask & WRAP_BIND_KEY_FLAG,\r\n isCurried = bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG),\r\n isFlip = bitmask & WRAP_FLIP_FLAG,\r\n Ctor = isBindKey ? undefined : createCtor(func);\r\n\r\n function wrapper() {\r\n var length = arguments.length,\r\n args = Array(length),\r\n index = length;\r\n\r\n while (index--) {\r\n args[index] = arguments[index];\r\n }\r\n if (isCurried) {\r\n var placeholder = getHolder(wrapper),\r\n holdersCount = countHolders(args, placeholder);\r\n }\r\n if (partials) {\r\n args = composeArgs(args, partials, holders, isCurried);\r\n }\r\n if (partialsRight) {\r\n args = composeArgsRight(args, partialsRight, holdersRight, isCurried);\r\n }\r\n length -= holdersCount;\r\n if (isCurried && length < arity) {\r\n var newHolders = replaceHolders(args, placeholder);\r\n return createRecurry(\r\n func, bitmask, createHybrid, wrapper.placeholder, thisArg,\r\n args, newHolders, argPos, ary, arity - length\r\n );\r\n }\r\n var thisBinding = isBind ? thisArg : this,\r\n fn = isBindKey ? thisBinding[func] : func;\r\n\r\n length = args.length;\r\n if (argPos) {\r\n args = reorder(args, argPos);\r\n } else if (isFlip && length > 1) {\r\n args.reverse();\r\n }\r\n if (isAry && ary < length) {\r\n args.length = ary;\r\n }\r\n if (this && this !== root && this instanceof wrapper) {\r\n fn = Ctor || createCtor(fn);\r\n }\r\n return fn.apply(thisBinding, args);\r\n }\r\n return wrapper;\r\n }\r\n\r\n /**\r\n * Creates a function like `_.invertBy`.\r\n *\r\n * @private\r\n * @param {Function} setter The function to set accumulator values.\r\n * @param {Function} toIteratee The function to resolve iteratees.\r\n * @returns {Function} Returns the new inverter function.\r\n */\r\n function createInverter(setter, toIteratee) {\r\n return function(object, iteratee) {\r\n return baseInverter(object, setter, toIteratee(iteratee), {});\r\n };\r\n }\r\n\r\n /**\r\n * Creates a function that wraps `func` to invoke it with the `this` binding\r\n * of `thisArg` and `partials` prepended to the arguments it receives.\r\n *\r\n * @private\r\n * @param {Function} func The function to wrap.\r\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\r\n * @param {*} thisArg The `this` binding of `func`.\r\n * @param {Array} partials The arguments to prepend to those provided to\r\n * the new function.\r\n * @returns {Function} Returns the new wrapped function.\r\n */\r\n function createPartial(func, bitmask, thisArg, partials) {\r\n var isBind = bitmask & WRAP_BIND_FLAG,\r\n Ctor = createCtor(func);\r\n\r\n function wrapper() {\r\n var argsIndex = -1,\r\n argsLength = arguments.length,\r\n leftIndex = -1,\r\n leftLength = partials.length,\r\n args = Array(leftLength + argsLength),\r\n fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;\r\n\r\n while (++leftIndex < leftLength) {\r\n args[leftIndex] = partials[leftIndex];\r\n }\r\n while (argsLength--) {\r\n args[leftIndex++] = arguments[++argsIndex];\r\n }\r\n return apply(fn, isBind ? thisArg : this, args);\r\n }\r\n return wrapper;\r\n }\r\n\r\n /**\r\n * Creates a `_.range` or `_.rangeRight` function.\r\n *\r\n * @private\r\n * @param {boolean} [fromRight] Specify iterating from right to left.\r\n * @returns {Function} Returns the new range function.\r\n */\r\n function createRange(fromRight) {\r\n return function(start, end, step) {\r\n if (step && typeof step != 'number' && isIterateeCall(start, end, step)) {\r\n end = step = undefined;\r\n }\r\n // Ensure the sign of `-0` is preserved.\r\n start = toFinite(start);\r\n if (end === undefined) {\r\n end = start;\r\n start = 0;\r\n } else {\r\n end = toFinite(end);\r\n }\r\n step = step === undefined ? (start < end ? 1 : -1) : toFinite(step);\r\n return baseRange(start, end, step, fromRight);\r\n };\r\n }\r\n\r\n /**\r\n * Creates a function that wraps `func` to continue currying.\r\n *\r\n * @private\r\n * @param {Function} func The function to wrap.\r\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\r\n * @param {Function} wrapFunc The function to create the `func` wrapper.\r\n * @param {*} placeholder The placeholder value.\r\n * @param {*} [thisArg] The `this` binding of `func`.\r\n * @param {Array} [partials] The arguments to prepend to those provided to\r\n * the new function.\r\n * @param {Array} [holders] The `partials` placeholder indexes.\r\n * @param {Array} [argPos] The argument positions of the new function.\r\n * @param {number} [ary] The arity cap of `func`.\r\n * @param {number} [arity] The arity of `func`.\r\n * @returns {Function} Returns the new wrapped function.\r\n */\r\n function createRecurry(func, bitmask, wrapFunc, placeholder, thisArg, partials, holders, argPos, ary, arity) {\r\n var isCurry = bitmask & WRAP_CURRY_FLAG,\r\n newHolders = isCurry ? holders : undefined,\r\n newHoldersRight = isCurry ? undefined : holders,\r\n newPartials = isCurry ? partials : undefined,\r\n newPartialsRight = isCurry ? undefined : partials;\r\n\r\n bitmask |= (isCurry ? WRAP_PARTIAL_FLAG : WRAP_PARTIAL_RIGHT_FLAG);\r\n bitmask &= ~(isCurry ? WRAP_PARTIAL_RIGHT_FLAG : WRAP_PARTIAL_FLAG);\r\n\r\n if (!(bitmask & WRAP_CURRY_BOUND_FLAG)) {\r\n bitmask &= ~(WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG);\r\n }\r\n var newData = [\r\n func, bitmask, thisArg, newPartials, newHolders, newPartialsRight,\r\n newHoldersRight, argPos, ary, arity\r\n ];\r\n\r\n var result = wrapFunc.apply(undefined, newData);\r\n if (isLaziable(func)) {\r\n setData(result, newData);\r\n }\r\n result.placeholder = placeholder;\r\n return setWrapToString(result, func, bitmask);\r\n }\r\n\r\n /**\r\n * Creates a set object of `values`.\r\n *\r\n * @private\r\n * @param {Array} values The values to add to the set.\r\n * @returns {Object} Returns the new set.\r\n */\r\n var createSet = !(Set && (1 / setToArray(new Set([,-0]))[1]) == INFINITY) ? noop : function(values) {\r\n return new Set(values);\r\n };\r\n\r\n /**\r\n * Creates a function that either curries or invokes `func` with optional\r\n * `this` binding and partially applied arguments.\r\n *\r\n * @private\r\n * @param {Function|string} func The function or method name to wrap.\r\n * @param {number} bitmask The bitmask flags.\r\n * 1 - `_.bind`\r\n * 2 - `_.bindKey`\r\n * 4 - `_.curry` or `_.curryRight` of a bound function\r\n * 8 - `_.curry`\r\n * 16 - `_.curryRight`\r\n * 32 - `_.partial`\r\n * 64 - `_.partialRight`\r\n * 128 - `_.rearg`\r\n * 256 - `_.ary`\r\n * 512 - `_.flip`\r\n * @param {*} [thisArg] The `this` binding of `func`.\r\n * @param {Array} [partials] The arguments to be partially applied.\r\n * @param {Array} [holders] The `partials` placeholder indexes.\r\n * @param {Array} [argPos] The argument positions of the new function.\r\n * @param {number} [ary] The arity cap of `func`.\r\n * @param {number} [arity] The arity of `func`.\r\n * @returns {Function} Returns the new wrapped function.\r\n */\r\n function createWrap(func, bitmask, thisArg, partials, holders, argPos, ary, arity) {\r\n var isBindKey = bitmask & WRAP_BIND_KEY_FLAG;\r\n if (!isBindKey && typeof func != 'function') {\r\n throw new TypeError(FUNC_ERROR_TEXT);\r\n }\r\n var length = partials ? partials.length : 0;\r\n if (!length) {\r\n bitmask &= ~(WRAP_PARTIAL_FLAG | WRAP_PARTIAL_RIGHT_FLAG);\r\n partials = holders = undefined;\r\n }\r\n ary = ary === undefined ? ary : nativeMax(toInteger(ary), 0);\r\n arity = arity === undefined ? arity : toInteger(arity);\r\n length -= holders ? holders.length : 0;\r\n\r\n if (bitmask & WRAP_PARTIAL_RIGHT_FLAG) {\r\n var partialsRight = partials,\r\n holdersRight = holders;\r\n\r\n partials = holders = undefined;\r\n }\r\n var data = isBindKey ? undefined : getData(func);\r\n\r\n var newData = [\r\n func, bitmask, thisArg, partials, holders, partialsRight, holdersRight,\r\n argPos, ary, arity\r\n ];\r\n\r\n if (data) {\r\n mergeData(newData, data);\r\n }\r\n func = newData[0];\r\n bitmask = newData[1];\r\n thisArg = newData[2];\r\n partials = newData[3];\r\n holders = newData[4];\r\n arity = newData[9] = newData[9] === undefined\r\n ? (isBindKey ? 0 : func.length)\r\n : nativeMax(newData[9] - length, 0);\r\n\r\n if (!arity && bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG)) {\r\n bitmask &= ~(WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG);\r\n }\r\n if (!bitmask || bitmask == WRAP_BIND_FLAG) {\r\n var result = createBind(func, bitmask, thisArg);\r\n } else if (bitmask == WRAP_CURRY_FLAG || bitmask == WRAP_CURRY_RIGHT_FLAG) {\r\n result = createCurry(func, bitmask, arity);\r\n } else if ((bitmask == WRAP_PARTIAL_FLAG || bitmask == (WRAP_BIND_FLAG | WRAP_PARTIAL_FLAG)) && !holders.length) {\r\n result = createPartial(func, bitmask, thisArg, partials);\r\n } else {\r\n result = createHybrid.apply(undefined, newData);\r\n }\r\n var setter = data ? baseSetData : setData;\r\n return setWrapToString(setter(result, newData), func, bitmask);\r\n }\r\n\r\n /**\r\n * Used by `_.defaultsDeep` to customize its `_.merge` use to merge source\r\n * objects into destination objects that are passed thru.\r\n *\r\n * @private\r\n * @param {*} objValue The destination value.\r\n * @param {*} srcValue The source value.\r\n * @param {string} key The key of the property to merge.\r\n * @param {Object} object The parent object of `objValue`.\r\n * @param {Object} source The parent object of `srcValue`.\r\n * @param {Object} [stack] Tracks traversed source values and their merged\r\n * counterparts.\r\n * @returns {*} Returns the value to assign.\r\n */\r\n function customDefaultsMerge(objValue, srcValue, key, object, source, stack) {\r\n if (isObject(objValue) && isObject(srcValue)) {\r\n // Recursively merge objects and arrays (susceptible to call stack limits).\r\n stack.set(srcValue, objValue);\r\n baseMerge(objValue, srcValue, undefined, customDefaultsMerge, stack);\r\n stack['delete'](srcValue);\r\n }\r\n return objValue;\r\n }\r\n\r\n /**\r\n * Used by `_.omit` to customize its `_.cloneDeep` use to only clone plain\r\n * objects.\r\n *\r\n * @private\r\n * @param {*} value The value to inspect.\r\n * @param {string} key The key of the property to inspect.\r\n * @returns {*} Returns the uncloned value or `undefined` to defer cloning to `_.cloneDeep`.\r\n */\r\n function customOmitClone(value) {\r\n return isPlainObject(value) ? undefined : value;\r\n }\r\n\r\n /**\r\n * A specialized version of `baseIsEqualDeep` for arrays with support for\r\n * partial deep comparisons.\r\n *\r\n * @private\r\n * @param {Array} array The array to compare.\r\n * @param {Array} other The other array to compare.\r\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\r\n * @param {Function} customizer The function to customize comparisons.\r\n * @param {Function} equalFunc The function to determine equivalents of values.\r\n * @param {Object} stack Tracks traversed `array` and `other` objects.\r\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\r\n */\r\n function equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\r\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\r\n arrLength = array.length,\r\n othLength = other.length;\r\n\r\n if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\r\n return false;\r\n }\r\n // Assume cyclic values are equal.\r\n var stacked = stack.get(array);\r\n if (stacked && stack.get(other)) {\r\n return stacked == other;\r\n }\r\n var index = -1,\r\n result = true,\r\n seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\r\n\r\n stack.set(array, other);\r\n stack.set(other, array);\r\n\r\n // Ignore non-index properties.\r\n while (++index < arrLength) {\r\n var arrValue = array[index],\r\n othValue = other[index];\r\n\r\n if (customizer) {\r\n var compared = isPartial\r\n ? customizer(othValue, arrValue, index, other, array, stack)\r\n : customizer(arrValue, othValue, index, array, other, stack);\r\n }\r\n if (compared !== undefined) {\r\n if (compared) {\r\n continue;\r\n }\r\n result = false;\r\n break;\r\n }\r\n // Recursively compare arrays (susceptible to call stack limits).\r\n if (seen) {\r\n if (!arraySome(other, function(othValue, othIndex) {\r\n if (!cacheHas(seen, othIndex) &&\r\n (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\r\n return seen.push(othIndex);\r\n }\r\n })) {\r\n result = false;\r\n break;\r\n }\r\n } else if (!(\r\n arrValue === othValue ||\r\n equalFunc(arrValue, othValue, bitmask, customizer, stack)\r\n )) {\r\n result = false;\r\n break;\r\n }\r\n }\r\n stack['delete'](array);\r\n stack['delete'](other);\r\n return result;\r\n }\r\n\r\n /**\r\n * A specialized version of `baseIsEqualDeep` for comparing objects of\r\n * the same `toStringTag`.\r\n *\r\n * **Note:** This function only supports comparing values with tags of\r\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\r\n *\r\n * @private\r\n * @param {Object} object The object to compare.\r\n * @param {Object} other The other object to compare.\r\n * @param {string} tag The `toStringTag` of the objects to compare.\r\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\r\n * @param {Function} customizer The function to customize comparisons.\r\n * @param {Function} equalFunc The function to determine equivalents of values.\r\n * @param {Object} stack Tracks traversed `object` and `other` objects.\r\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\r\n */\r\n function equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\r\n switch (tag) {\r\n case dataViewTag:\r\n if ((object.byteLength != other.byteLength) ||\r\n (object.byteOffset != other.byteOffset)) {\r\n return false;\r\n }\r\n object = object.buffer;\r\n other = other.buffer;\r\n\r\n case arrayBufferTag:\r\n if ((object.byteLength != other.byteLength) ||\r\n !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\r\n return false;\r\n }\r\n return true;\r\n\r\n case boolTag:\r\n case dateTag:\r\n case numberTag:\r\n // Coerce booleans to `1` or `0` and dates to milliseconds.\r\n // Invalid dates are coerced to `NaN`.\r\n return eq(+object, +other);\r\n\r\n case errorTag:\r\n return object.name == other.name && object.message == other.message;\r\n\r\n case regexpTag:\r\n case stringTag:\r\n // Coerce regexes to strings and treat strings, primitives and objects,\r\n // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\r\n // for more details.\r\n return object == (other + '');\r\n\r\n case mapTag:\r\n var convert = mapToArray;\r\n\r\n case setTag:\r\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\r\n convert || (convert = setToArray);\r\n\r\n if (object.size != other.size && !isPartial) {\r\n return false;\r\n }\r\n // Assume cyclic values are equal.\r\n var stacked = stack.get(object);\r\n if (stacked) {\r\n return stacked == other;\r\n }\r\n bitmask |= COMPARE_UNORDERED_FLAG;\r\n\r\n // Recursively compare objects (susceptible to call stack limits).\r\n stack.set(object, other);\r\n var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\r\n stack['delete'](object);\r\n return result;\r\n\r\n case symbolTag:\r\n if (symbolValueOf) {\r\n return symbolValueOf.call(object) == symbolValueOf.call(other);\r\n }\r\n }\r\n return false;\r\n }\r\n\r\n /**\r\n * A specialized version of `baseIsEqualDeep` for objects with support for\r\n * partial deep comparisons.\r\n *\r\n * @private\r\n * @param {Object} object The object to compare.\r\n * @param {Object} other The other object to compare.\r\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\r\n * @param {Function} customizer The function to customize comparisons.\r\n * @param {Function} equalFunc The function to determine equivalents of values.\r\n * @param {Object} stack Tracks traversed `object` and `other` objects.\r\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\r\n */\r\n function equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\r\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\r\n objProps = getAllKeys(object),\r\n objLength = objProps.length,\r\n othProps = getAllKeys(other),\r\n othLength = othProps.length;\r\n\r\n if (objLength != othLength && !isPartial) {\r\n return false;\r\n }\r\n var index = objLength;\r\n while (index--) {\r\n var key = objProps[index];\r\n if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\r\n return false;\r\n }\r\n }\r\n // Assume cyclic values are equal.\r\n var stacked = stack.get(object);\r\n if (stacked && stack.get(other)) {\r\n return stacked == other;\r\n }\r\n var result = true;\r\n stack.set(object, other);\r\n stack.set(other, object);\r\n\r\n var skipCtor = isPartial;\r\n while (++index < objLength) {\r\n key = objProps[index];\r\n var objValue = object[key],\r\n othValue = other[key];\r\n\r\n if (customizer) {\r\n var compared = isPartial\r\n ? customizer(othValue, objValue, key, other, object, stack)\r\n : customizer(objValue, othValue, key, object, other, stack);\r\n }\r\n // Recursively compare objects (susceptible to call stack limits).\r\n if (!(compared === undefined\r\n ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\r\n : compared\r\n )) {\r\n result = false;\r\n break;\r\n }\r\n skipCtor || (skipCtor = key == 'constructor');\r\n }\r\n if (result && !skipCtor) {\r\n var objCtor = object.constructor,\r\n othCtor = other.constructor;\r\n\r\n // Non `Object` object instances with different constructors are not equal.\r\n if (objCtor != othCtor &&\r\n ('constructor' in object && 'constructor' in other) &&\r\n !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\r\n typeof othCtor == 'function' && othCtor instanceof othCtor)) {\r\n result = false;\r\n }\r\n }\r\n stack['delete'](object);\r\n stack['delete'](other);\r\n return result;\r\n }\r\n\r\n /**\r\n * A specialized version of `baseRest` which flattens the rest array.\r\n *\r\n * @private\r\n * @param {Function} func The function to apply a rest parameter to.\r\n * @returns {Function} Returns the new function.\r\n */\r\n function flatRest(func) {\r\n return setToString(overRest(func, undefined, flatten), func + '');\r\n }\r\n\r\n /**\r\n * Creates an array of own enumerable property names and symbols of `object`.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @returns {Array} Returns the array of property names and symbols.\r\n */\r\n function getAllKeys(object) {\r\n return baseGetAllKeys(object, keys, getSymbols);\r\n }\r\n\r\n /**\r\n * Creates an array of own and inherited enumerable property names and\r\n * symbols of `object`.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @returns {Array} Returns the array of property names and symbols.\r\n */\r\n function getAllKeysIn(object) {\r\n return baseGetAllKeys(object, keysIn, getSymbolsIn);\r\n }\r\n\r\n /**\r\n * Gets metadata for `func`.\r\n *\r\n * @private\r\n * @param {Function} func The function to query.\r\n * @returns {*} Returns the metadata for `func`.\r\n */\r\n var getData = !metaMap ? noop : function(func) {\r\n return metaMap.get(func);\r\n };\r\n\r\n /**\r\n * Gets the name of `func`.\r\n *\r\n * @private\r\n * @param {Function} func The function to query.\r\n * @returns {string} Returns the function name.\r\n */\r\n function getFuncName(func) {\r\n var result = (func.name + ''),\r\n array = realNames[result],\r\n length = hasOwnProperty.call(realNames, result) ? array.length : 0;\r\n\r\n while (length--) {\r\n var data = array[length],\r\n otherFunc = data.func;\r\n if (otherFunc == null || otherFunc == func) {\r\n return data.name;\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Gets the argument placeholder value for `func`.\r\n *\r\n * @private\r\n * @param {Function} func The function to inspect.\r\n * @returns {*} Returns the placeholder value.\r\n */\r\n function getHolder(func) {\r\n var object = hasOwnProperty.call(lodash, 'placeholder') ? lodash : func;\r\n return object.placeholder;\r\n }\r\n\r\n /**\r\n * Gets the data for `map`.\r\n *\r\n * @private\r\n * @param {Object} map The map to query.\r\n * @param {string} key The reference key.\r\n * @returns {*} Returns the map data.\r\n */\r\n function getMapData(map, key) {\r\n var data = map.__data__;\r\n return isKeyable(key)\r\n ? data[typeof key == 'string' ? 'string' : 'hash']\r\n : data.map;\r\n }\r\n\r\n /**\r\n * Gets the property names, values, and compare flags of `object`.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @returns {Array} Returns the match data of `object`.\r\n */\r\n function getMatchData(object) {\r\n var result = keys(object),\r\n length = result.length;\r\n\r\n while (length--) {\r\n var key = result[length],\r\n value = object[key];\r\n\r\n result[length] = [key, value, isStrictComparable(value)];\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Gets the native function at `key` of `object`.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @param {string} key The key of the method to get.\r\n * @returns {*} Returns the function if it's native, else `undefined`.\r\n */\r\n function getNative(object, key) {\r\n var value = getValue(object, key);\r\n return baseIsNative(value) ? value : undefined;\r\n }\r\n\r\n /**\r\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\r\n *\r\n * @private\r\n * @param {*} value The value to query.\r\n * @returns {string} Returns the raw `toStringTag`.\r\n */\r\n function getRawTag(value) {\r\n var isOwn = hasOwnProperty.call(value, symToStringTag),\r\n tag = value[symToStringTag];\r\n\r\n try {\r\n value[symToStringTag] = undefined;\r\n var unmasked = true;\r\n } catch (e) {}\r\n\r\n var result = nativeObjectToString.call(value);\r\n if (unmasked) {\r\n if (isOwn) {\r\n value[symToStringTag] = tag;\r\n } else {\r\n delete value[symToStringTag];\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Creates an array of the own enumerable symbols of `object`.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @returns {Array} Returns the array of symbols.\r\n */\r\n var getSymbols = !nativeGetSymbols ? stubArray : function(object) {\r\n if (object == null) {\r\n return [];\r\n }\r\n object = Object(object);\r\n return arrayFilter(nativeGetSymbols(object), function(symbol) {\r\n return propertyIsEnumerable.call(object, symbol);\r\n });\r\n };\r\n\r\n /**\r\n * Creates an array of the own and inherited enumerable symbols of `object`.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @returns {Array} Returns the array of symbols.\r\n */\r\n var getSymbolsIn = !nativeGetSymbols ? stubArray : function(object) {\r\n var result = [];\r\n while (object) {\r\n arrayPush(result, getSymbols(object));\r\n object = getPrototype(object);\r\n }\r\n return result;\r\n };\r\n\r\n /**\r\n * Gets the `toStringTag` of `value`.\r\n *\r\n * @private\r\n * @param {*} value The value to query.\r\n * @returns {string} Returns the `toStringTag`.\r\n */\r\n var getTag = baseGetTag;\r\n\r\n // Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\r\n if ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\r\n (Map && getTag(new Map) != mapTag) ||\r\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\r\n (Set && getTag(new Set) != setTag) ||\r\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\r\n getTag = function(value) {\r\n var result = baseGetTag(value),\r\n Ctor = result == objectTag ? value.constructor : undefined,\r\n ctorString = Ctor ? toSource(Ctor) : '';\r\n\r\n if (ctorString) {\r\n switch (ctorString) {\r\n case dataViewCtorString: return dataViewTag;\r\n case mapCtorString: return mapTag;\r\n case promiseCtorString: return promiseTag;\r\n case setCtorString: return setTag;\r\n case weakMapCtorString: return weakMapTag;\r\n }\r\n }\r\n return result;\r\n };\r\n }\r\n\r\n /**\r\n * Gets the view, applying any `transforms` to the `start` and `end` positions.\r\n *\r\n * @private\r\n * @param {number} start The start of the view.\r\n * @param {number} end The end of the view.\r\n * @param {Array} transforms The transformations to apply to the view.\r\n * @returns {Object} Returns an object containing the `start` and `end`\r\n * positions of the view.\r\n */\r\n function getView(start, end, transforms) {\r\n var index = -1,\r\n length = transforms.length;\r\n\r\n while (++index < length) {\r\n var data = transforms[index],\r\n size = data.size;\r\n\r\n switch (data.type) {\r\n case 'drop': start += size; break;\r\n case 'dropRight': end -= size; break;\r\n case 'take': end = nativeMin(end, start + size); break;\r\n case 'takeRight': start = nativeMax(start, end - size); break;\r\n }\r\n }\r\n return { 'start': start, 'end': end };\r\n }\r\n\r\n /**\r\n * Extracts wrapper details from the `source` body comment.\r\n *\r\n * @private\r\n * @param {string} source The source to inspect.\r\n * @returns {Array} Returns the wrapper details.\r\n */\r\n function getWrapDetails(source) {\r\n var match = source.match(reWrapDetails);\r\n return match ? match[1].split(reSplitDetails) : [];\r\n }\r\n\r\n /**\r\n * Checks if `path` exists on `object`.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @param {Array|string} path The path to check.\r\n * @param {Function} hasFunc The function to check properties.\r\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\r\n */\r\n function hasPath(object, path, hasFunc) {\r\n path = castPath(path, object);\r\n\r\n var index = -1,\r\n length = path.length,\r\n result = false;\r\n\r\n while (++index < length) {\r\n var key = toKey(path[index]);\r\n if (!(result = object != null && hasFunc(object, key))) {\r\n break;\r\n }\r\n object = object[key];\r\n }\r\n if (result || ++index != length) {\r\n return result;\r\n }\r\n length = object == null ? 0 : object.length;\r\n return !!length && isLength(length) && isIndex(key, length) &&\r\n (isArray(object) || isArguments(object));\r\n }\r\n\r\n /**\r\n * Initializes an array clone.\r\n *\r\n * @private\r\n * @param {Array} array The array to clone.\r\n * @returns {Array} Returns the initialized clone.\r\n */\r\n function initCloneArray(array) {\r\n var length = array.length,\r\n result = new array.constructor(length);\r\n\r\n // Add properties assigned by `RegExp#exec`.\r\n if (length && typeof array[0] == 'string' && hasOwnProperty.call(array, 'index')) {\r\n result.index = array.index;\r\n result.input = array.input;\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Initializes an object clone.\r\n *\r\n * @private\r\n * @param {Object} object The object to clone.\r\n * @returns {Object} Returns the initialized clone.\r\n */\r\n function initCloneObject(object) {\r\n return (typeof object.constructor == 'function' && !isPrototype(object))\r\n ? baseCreate(getPrototype(object))\r\n : {};\r\n }\r\n\r\n /**\r\n * Initializes an object clone based on its `toStringTag`.\r\n *\r\n * **Note:** This function only supports cloning values with tags of\r\n * `Boolean`, `Date`, `Error`, `Map`, `Number`, `RegExp`, `Set`, or `String`.\r\n *\r\n * @private\r\n * @param {Object} object The object to clone.\r\n * @param {string} tag The `toStringTag` of the object to clone.\r\n * @param {boolean} [isDeep] Specify a deep clone.\r\n * @returns {Object} Returns the initialized clone.\r\n */\r\n function initCloneByTag(object, tag, isDeep) {\r\n var Ctor = object.constructor;\r\n switch (tag) {\r\n case arrayBufferTag:\r\n return cloneArrayBuffer(object);\r\n\r\n case boolTag:\r\n case dateTag:\r\n return new Ctor(+object);\r\n\r\n case dataViewTag:\r\n return cloneDataView(object, isDeep);\r\n\r\n case float32Tag: case float64Tag:\r\n case int8Tag: case int16Tag: case int32Tag:\r\n case uint8Tag: case uint8ClampedTag: case uint16Tag: case uint32Tag:\r\n return cloneTypedArray(object, isDeep);\r\n\r\n case mapTag:\r\n return new Ctor;\r\n\r\n case numberTag:\r\n case stringTag:\r\n return new Ctor(object);\r\n\r\n case regexpTag:\r\n return cloneRegExp(object);\r\n\r\n case setTag:\r\n return new Ctor;\r\n\r\n case symbolTag:\r\n return cloneSymbol(object);\r\n }\r\n }\r\n\r\n /**\r\n * Inserts wrapper `details` in a comment at the top of the `source` body.\r\n *\r\n * @private\r\n * @param {string} source The source to modify.\r\n * @returns {Array} details The details to insert.\r\n * @returns {string} Returns the modified source.\r\n */\r\n function insertWrapDetails(source, details) {\r\n var length = details.length;\r\n if (!length) {\r\n return source;\r\n }\r\n var lastIndex = length - 1;\r\n details[lastIndex] = (length > 1 ? '& ' : '') + details[lastIndex];\r\n details = details.join(length > 2 ? ', ' : ' ');\r\n return source.replace(reWrapComment, '{\\n/* [wrapped with ' + details + '] */\\n');\r\n }\r\n\r\n /**\r\n * Checks if `value` is a flattenable `arguments` object or array.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is flattenable, else `false`.\r\n */\r\n function isFlattenable(value) {\r\n return isArray(value) || isArguments(value) ||\r\n !!(spreadableSymbol && value && value[spreadableSymbol]);\r\n }\r\n\r\n /**\r\n * Checks if `value` is a valid array-like index.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\r\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\r\n */\r\n function isIndex(value, length) {\r\n var type = typeof value;\r\n length = length == null ? MAX_SAFE_INTEGER : length;\r\n\r\n return !!length &&\r\n (type == 'number' ||\r\n (type != 'symbol' && reIsUint.test(value))) &&\r\n (value > -1 && value % 1 == 0 && value < length);\r\n }\r\n\r\n /**\r\n * Checks if the given arguments are from an iteratee call.\r\n *\r\n * @private\r\n * @param {*} value The potential iteratee value argument.\r\n * @param {*} index The potential iteratee index or key argument.\r\n * @param {*} object The potential iteratee object argument.\r\n * @returns {boolean} Returns `true` if the arguments are from an iteratee call,\r\n * else `false`.\r\n */\r\n function isIterateeCall(value, index, object) {\r\n if (!isObject(object)) {\r\n return false;\r\n }\r\n var type = typeof index;\r\n if (type == 'number'\r\n ? (isArrayLike(object) && isIndex(index, object.length))\r\n : (type == 'string' && index in object)\r\n ) {\r\n return eq(object[index], value);\r\n }\r\n return false;\r\n }\r\n\r\n /**\r\n * Checks if `value` is a property name and not a property path.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @param {Object} [object] The object to query keys on.\r\n * @returns {boolean} Returns `true` if `value` is a property name, else `false`.\r\n */\r\n function isKey(value, object) {\r\n if (isArray(value)) {\r\n return false;\r\n }\r\n var type = typeof value;\r\n if (type == 'number' || type == 'symbol' || type == 'boolean' ||\r\n value == null || isSymbol(value)) {\r\n return true;\r\n }\r\n return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||\r\n (object != null && value in Object(object));\r\n }\r\n\r\n /**\r\n * Checks if `value` is suitable for use as unique object key.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\r\n */\r\n function isKeyable(value) {\r\n var type = typeof value;\r\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\r\n ? (value !== '__proto__')\r\n : (value === null);\r\n }\r\n\r\n /**\r\n * Checks if `func` has a lazy counterpart.\r\n *\r\n * @private\r\n * @param {Function} func The function to check.\r\n * @returns {boolean} Returns `true` if `func` has a lazy counterpart,\r\n * else `false`.\r\n */\r\n function isLaziable(func) {\r\n var funcName = getFuncName(func),\r\n other = lodash[funcName];\r\n\r\n if (typeof other != 'function' || !(funcName in LazyWrapper.prototype)) {\r\n return false;\r\n }\r\n if (func === other) {\r\n return true;\r\n }\r\n var data = getData(other);\r\n return !!data && func === data[0];\r\n }\r\n\r\n /**\r\n * Checks if `func` has its source masked.\r\n *\r\n * @private\r\n * @param {Function} func The function to check.\r\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\r\n */\r\n function isMasked(func) {\r\n return !!maskSrcKey && (maskSrcKey in func);\r\n }\r\n\r\n /**\r\n * Checks if `value` is likely a prototype object.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\r\n */\r\n function isPrototype(value) {\r\n var Ctor = value && value.constructor,\r\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\r\n\r\n return value === proto;\r\n }\r\n\r\n /**\r\n * Checks if `value` is suitable for strict equality comparisons, i.e. `===`.\r\n *\r\n * @private\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` if suitable for strict\r\n * equality comparisons, else `false`.\r\n */\r\n function isStrictComparable(value) {\r\n return value === value && !isObject(value);\r\n }\r\n\r\n /**\r\n * A specialized version of `matchesProperty` for source values suitable\r\n * for strict equality comparisons, i.e. `===`.\r\n *\r\n * @private\r\n * @param {string} key The key of the property to get.\r\n * @param {*} srcValue The value to match.\r\n * @returns {Function} Returns the new spec function.\r\n */\r\n function matchesStrictComparable(key, srcValue) {\r\n return function(object) {\r\n if (object == null) {\r\n return false;\r\n }\r\n return object[key] === srcValue &&\r\n (srcValue !== undefined || (key in Object(object)));\r\n };\r\n }\r\n\r\n /**\r\n * A specialized version of `_.memoize` which clears the memoized function's\r\n * cache when it exceeds `MAX_MEMOIZE_SIZE`.\r\n *\r\n * @private\r\n * @param {Function} func The function to have its output memoized.\r\n * @returns {Function} Returns the new memoized function.\r\n */\r\n function memoizeCapped(func) {\r\n var result = memoize(func, function(key) {\r\n if (cache.size === MAX_MEMOIZE_SIZE) {\r\n cache.clear();\r\n }\r\n return key;\r\n });\r\n\r\n var cache = result.cache;\r\n return result;\r\n }\r\n\r\n /**\r\n * Merges the function metadata of `source` into `data`.\r\n *\r\n * Merging metadata reduces the number of wrappers used to invoke a function.\r\n * This is possible because methods like `_.bind`, `_.curry`, and `_.partial`\r\n * may be applied regardless of execution order. Methods like `_.ary` and\r\n * `_.rearg` modify function arguments, making the order in which they are\r\n * executed important, preventing the merging of metadata. However, we make\r\n * an exception for a safe combined case where curried functions have `_.ary`\r\n * and or `_.rearg` applied.\r\n *\r\n * @private\r\n * @param {Array} data The destination metadata.\r\n * @param {Array} source The source metadata.\r\n * @returns {Array} Returns `data`.\r\n */\r\n function mergeData(data, source) {\r\n var bitmask = data[1],\r\n srcBitmask = source[1],\r\n newBitmask = bitmask | srcBitmask,\r\n isCommon = newBitmask < (WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG | WRAP_ARY_FLAG);\r\n\r\n var isCombo =\r\n ((srcBitmask == WRAP_ARY_FLAG) && (bitmask == WRAP_CURRY_FLAG)) ||\r\n ((srcBitmask == WRAP_ARY_FLAG) && (bitmask == WRAP_REARG_FLAG) && (data[7].length <= source[8])) ||\r\n ((srcBitmask == (WRAP_ARY_FLAG | WRAP_REARG_FLAG)) && (source[7].length <= source[8]) && (bitmask == WRAP_CURRY_FLAG));\r\n\r\n // Exit early if metadata can't be merged.\r\n if (!(isCommon || isCombo)) {\r\n return data;\r\n }\r\n // Use source `thisArg` if available.\r\n if (srcBitmask & WRAP_BIND_FLAG) {\r\n data[2] = source[2];\r\n // Set when currying a bound function.\r\n newBitmask |= bitmask & WRAP_BIND_FLAG ? 0 : WRAP_CURRY_BOUND_FLAG;\r\n }\r\n // Compose partial arguments.\r\n var value = source[3];\r\n if (value) {\r\n var partials = data[3];\r\n data[3] = partials ? composeArgs(partials, value, source[4]) : value;\r\n data[4] = partials ? replaceHolders(data[3], PLACEHOLDER) : source[4];\r\n }\r\n // Compose partial right arguments.\r\n value = source[5];\r\n if (value) {\r\n partials = data[5];\r\n data[5] = partials ? composeArgsRight(partials, value, source[6]) : value;\r\n data[6] = partials ? replaceHolders(data[5], PLACEHOLDER) : source[6];\r\n }\r\n // Use source `argPos` if available.\r\n value = source[7];\r\n if (value) {\r\n data[7] = value;\r\n }\r\n // Use source `ary` if it's smaller.\r\n if (srcBitmask & WRAP_ARY_FLAG) {\r\n data[8] = data[8] == null ? source[8] : nativeMin(data[8], source[8]);\r\n }\r\n // Use source `arity` if one is not provided.\r\n if (data[9] == null) {\r\n data[9] = source[9];\r\n }\r\n // Use source `func` and merge bitmasks.\r\n data[0] = source[0];\r\n data[1] = newBitmask;\r\n\r\n return data;\r\n }\r\n\r\n /**\r\n * This function is like\r\n * [`Object.keys`](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\r\n * except that it includes inherited enumerable properties.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @returns {Array} Returns the array of property names.\r\n */\r\n function nativeKeysIn(object) {\r\n var result = [];\r\n if (object != null) {\r\n for (var key in Object(object)) {\r\n result.push(key);\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Converts `value` to a string using `Object.prototype.toString`.\r\n *\r\n * @private\r\n * @param {*} value The value to convert.\r\n * @returns {string} Returns the converted string.\r\n */\r\n function objectToString(value) {\r\n return nativeObjectToString.call(value);\r\n }\r\n\r\n /**\r\n * A specialized version of `baseRest` which transforms the rest array.\r\n *\r\n * @private\r\n * @param {Function} func The function to apply a rest parameter to.\r\n * @param {number} [start=func.length-1] The start position of the rest parameter.\r\n * @param {Function} transform The rest array transform.\r\n * @returns {Function} Returns the new function.\r\n */\r\n function overRest(func, start, transform) {\r\n start = nativeMax(start === undefined ? (func.length - 1) : start, 0);\r\n return function() {\r\n var args = arguments,\r\n index = -1,\r\n length = nativeMax(args.length - start, 0),\r\n array = Array(length);\r\n\r\n while (++index < length) {\r\n array[index] = args[start + index];\r\n }\r\n index = -1;\r\n var otherArgs = Array(start + 1);\r\n while (++index < start) {\r\n otherArgs[index] = args[index];\r\n }\r\n otherArgs[start] = transform(array);\r\n return apply(func, this, otherArgs);\r\n };\r\n }\r\n\r\n /**\r\n * Gets the parent value at `path` of `object`.\r\n *\r\n * @private\r\n * @param {Object} object The object to query.\r\n * @param {Array} path The path to get the parent value of.\r\n * @returns {*} Returns the parent value.\r\n */\r\n function parent(object, path) {\r\n return path.length < 2 ? object : baseGet(object, baseSlice(path, 0, -1));\r\n }\r\n\r\n /**\r\n * Reorder `array` according to the specified indexes where the element at\r\n * the first index is assigned as the first element, the element at\r\n * the second index is assigned as the second element, and so on.\r\n *\r\n * @private\r\n * @param {Array} array The array to reorder.\r\n * @param {Array} indexes The arranged array indexes.\r\n * @returns {Array} Returns `array`.\r\n */\r\n function reorder(array, indexes) {\r\n var arrLength = array.length,\r\n length = nativeMin(indexes.length, arrLength),\r\n oldArray = copyArray(array);\r\n\r\n while (length--) {\r\n var index = indexes[length];\r\n array[length] = isIndex(index, arrLength) ? oldArray[index] : undefined;\r\n }\r\n return array;\r\n }\r\n\r\n /**\r\n * Sets metadata for `func`.\r\n *\r\n * **Note:** If this function becomes hot, i.e. is invoked a lot in a short\r\n * period of time, it will trip its breaker and transition to an identity\r\n * function to avoid garbage collection pauses in V8. See\r\n * [V8 issue 2070](https://bugs.chromium.org/p/v8/issues/detail?id=2070)\r\n * for more details.\r\n *\r\n * @private\r\n * @param {Function} func The function to associate metadata with.\r\n * @param {*} data The metadata.\r\n * @returns {Function} Returns `func`.\r\n */\r\n var setData = shortOut(baseSetData);\r\n\r\n /**\r\n * Sets the `toString` method of `func` to return `string`.\r\n *\r\n * @private\r\n * @param {Function} func The function to modify.\r\n * @param {Function} string The `toString` result.\r\n * @returns {Function} Returns `func`.\r\n */\r\n var setToString = shortOut(baseSetToString);\r\n\r\n /**\r\n * Sets the `toString` method of `wrapper` to mimic the source of `reference`\r\n * with wrapper details in a comment at the top of the source body.\r\n *\r\n * @private\r\n * @param {Function} wrapper The function to modify.\r\n * @param {Function} reference The reference function.\r\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\r\n * @returns {Function} Returns `wrapper`.\r\n */\r\n function setWrapToString(wrapper, reference, bitmask) {\r\n var source = (reference + '');\r\n return setToString(wrapper, insertWrapDetails(source, updateWrapDetails(getWrapDetails(source), bitmask)));\r\n }\r\n\r\n /**\r\n * Creates a function that'll short out and invoke `identity` instead\r\n * of `func` when it's called `HOT_COUNT` or more times in `HOT_SPAN`\r\n * milliseconds.\r\n *\r\n * @private\r\n * @param {Function} func The function to restrict.\r\n * @returns {Function} Returns the new shortable function.\r\n */\r\n function shortOut(func) {\r\n var count = 0,\r\n lastCalled = 0;\r\n\r\n return function() {\r\n var stamp = nativeNow(),\r\n remaining = HOT_SPAN - (stamp - lastCalled);\r\n\r\n lastCalled = stamp;\r\n if (remaining > 0) {\r\n if (++count >= HOT_COUNT) {\r\n return arguments[0];\r\n }\r\n } else {\r\n count = 0;\r\n }\r\n return func.apply(undefined, arguments);\r\n };\r\n }\r\n\r\n /**\r\n * Converts `string` to a property path array.\r\n *\r\n * @private\r\n * @param {string} string The string to convert.\r\n * @returns {Array} Returns the property path array.\r\n */\r\n var stringToPath = memoizeCapped(function(string) {\r\n var result = [];\r\n if (string.charCodeAt(0) === 46 /* . */) {\r\n result.push('');\r\n }\r\n string.replace(rePropName, function(match, number, quote, subString) {\r\n result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));\r\n });\r\n return result;\r\n });\r\n\r\n /**\r\n * Converts `value` to a string key if it's not a string or symbol.\r\n *\r\n * @private\r\n * @param {*} value The value to inspect.\r\n * @returns {string|symbol} Returns the key.\r\n */\r\n function toKey(value) {\r\n if (typeof value == 'string' || isSymbol(value)) {\r\n return value;\r\n }\r\n var result = (value + '');\r\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\r\n }\r\n\r\n /**\r\n * Converts `func` to its source code.\r\n *\r\n * @private\r\n * @param {Function} func The function to convert.\r\n * @returns {string} Returns the source code.\r\n */\r\n function toSource(func) {\r\n if (func != null) {\r\n try {\r\n return funcToString.call(func);\r\n } catch (e) {}\r\n try {\r\n return (func + '');\r\n } catch (e) {}\r\n }\r\n return '';\r\n }\r\n\r\n /**\r\n * Updates wrapper `details` based on `bitmask` flags.\r\n *\r\n * @private\r\n * @returns {Array} details The details to modify.\r\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\r\n * @returns {Array} Returns `details`.\r\n */\r\n function updateWrapDetails(details, bitmask) {\r\n arrayEach(wrapFlags, function(pair) {\r\n var value = '_.' + pair[0];\r\n if ((bitmask & pair[1]) && !arrayIncludes(details, value)) {\r\n details.push(value);\r\n }\r\n });\r\n return details.sort();\r\n }\r\n\r\n /**\r\n * Creates a clone of `wrapper`.\r\n *\r\n * @private\r\n * @param {Object} wrapper The wrapper to clone.\r\n * @returns {Object} Returns the cloned wrapper.\r\n */\r\n function wrapperClone(wrapper) {\r\n if (wrapper instanceof LazyWrapper) {\r\n return wrapper.clone();\r\n }\r\n var result = new LodashWrapper(wrapper.__wrapped__, wrapper.__chain__);\r\n result.__actions__ = copyArray(wrapper.__actions__);\r\n result.__index__ = wrapper.__index__;\r\n result.__values__ = wrapper.__values__;\r\n return result;\r\n }\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Creates an array with all falsey values removed. The values `false`, `null`,\r\n * `0`, `\"\"`, `undefined`, and `NaN` are falsey.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Array\r\n * @param {Array} array The array to compact.\r\n * @returns {Array} Returns the new array of filtered values.\r\n * @example\r\n *\r\n * _.compact([0, 1, false, 2, '', 3]);\r\n * // => [1, 2, 3]\r\n */\r\n function compact(array) {\r\n var index = -1,\r\n length = array == null ? 0 : array.length,\r\n resIndex = 0,\r\n result = [];\r\n\r\n while (++index < length) {\r\n var value = array[index];\r\n if (value) {\r\n result[resIndex++] = value;\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n /**\r\n * Creates a new array concatenating `array` with any additional arrays\r\n * and/or values.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Array\r\n * @param {Array} array The array to concatenate.\r\n * @param {...*} [values] The values to concatenate.\r\n * @returns {Array} Returns the new concatenated array.\r\n * @example\r\n *\r\n * var array = [1];\r\n * var other = _.concat(array, 2, [3], [[4]]);\r\n *\r\n * console.log(other);\r\n * // => [1, 2, 3, [4]]\r\n *\r\n * console.log(array);\r\n * // => [1]\r\n */\r\n function concat() {\r\n var length = arguments.length;\r\n if (!length) {\r\n return [];\r\n }\r\n var args = Array(length - 1),\r\n array = arguments[0],\r\n index = length;\r\n\r\n while (index--) {\r\n args[index - 1] = arguments[index];\r\n }\r\n return arrayPush(isArray(array) ? copyArray(array) : [array], baseFlatten(args, 1));\r\n }\r\n\r\n /**\r\n * Creates an array of `array` values not included in the other given arrays\r\n * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\r\n * for equality comparisons. The order and references of result values are\r\n * determined by the first array.\r\n *\r\n * **Note:** Unlike `_.pullAll`, this method returns a new array.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Array\r\n * @param {Array} array The array to inspect.\r\n * @param {...Array} [values] The values to exclude.\r\n * @returns {Array} Returns the new array of filtered values.\r\n * @see _.without, _.xor\r\n * @example\r\n *\r\n * _.difference([2, 1], [2, 3]);\r\n * // => [1]\r\n */\r\n var difference = baseRest(function(array, values) {\r\n return isArrayLikeObject(array)\r\n ? baseDifference(array, baseFlatten(values, 1, isArrayLikeObject, true))\r\n : [];\r\n });\r\n\r\n /**\r\n * Creates a slice of `array` with `n` elements dropped from the beginning.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.5.0\r\n * @category Array\r\n * @param {Array} array The array to query.\r\n * @param {number} [n=1] The number of elements to drop.\r\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\r\n * @returns {Array} Returns the slice of `array`.\r\n * @example\r\n *\r\n * _.drop([1, 2, 3]);\r\n * // => [2, 3]\r\n *\r\n * _.drop([1, 2, 3], 2);\r\n * // => [3]\r\n *\r\n * _.drop([1, 2, 3], 5);\r\n * // => []\r\n *\r\n * _.drop([1, 2, 3], 0);\r\n * // => [1, 2, 3]\r\n */\r\n function drop(array, n, guard) {\r\n var length = array == null ? 0 : array.length;\r\n if (!length) {\r\n return [];\r\n }\r\n n = (guard || n === undefined) ? 1 : toInteger(n);\r\n return baseSlice(array, n < 0 ? 0 : n, length);\r\n }\r\n\r\n /**\r\n * This method is like `_.find` except that it returns the index of the first\r\n * element `predicate` returns truthy for instead of the element itself.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 1.1.0\r\n * @category Array\r\n * @param {Array} array The array to inspect.\r\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\r\n * @param {number} [fromIndex=0] The index to search from.\r\n * @returns {number} Returns the index of the found element, else `-1`.\r\n * @example\r\n *\r\n * var users = [\r\n * { 'user': 'barney', 'active': false },\r\n * { 'user': 'fred', 'active': false },\r\n * { 'user': 'pebbles', 'active': true }\r\n * ];\r\n *\r\n * _.findIndex(users, function(o) { return o.user == 'barney'; });\r\n * // => 0\r\n *\r\n * // The `_.matches` iteratee shorthand.\r\n * _.findIndex(users, { 'user': 'fred', 'active': false });\r\n * // => 1\r\n *\r\n * // The `_.matchesProperty` iteratee shorthand.\r\n * _.findIndex(users, ['active', false]);\r\n * // => 0\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.findIndex(users, 'active');\r\n * // => 2\r\n */\r\n function findIndex(array, predicate, fromIndex) {\r\n var length = array == null ? 0 : array.length;\r\n if (!length) {\r\n return -1;\r\n }\r\n var index = fromIndex == null ? 0 : toInteger(fromIndex);\r\n if (index < 0) {\r\n index = nativeMax(length + index, 0);\r\n }\r\n return baseFindIndex(array, baseIteratee(predicate, 3), index);\r\n }\r\n\r\n /**\r\n * This method is like `_.findIndex` except that it iterates over elements\r\n * of `collection` from right to left.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 2.0.0\r\n * @category Array\r\n * @param {Array} array The array to inspect.\r\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\r\n * @param {number} [fromIndex=array.length-1] The index to search from.\r\n * @returns {number} Returns the index of the found element, else `-1`.\r\n * @example\r\n *\r\n * var users = [\r\n * { 'user': 'barney', 'active': true },\r\n * { 'user': 'fred', 'active': false },\r\n * { 'user': 'pebbles', 'active': false }\r\n * ];\r\n *\r\n * _.findLastIndex(users, function(o) { return o.user == 'pebbles'; });\r\n * // => 2\r\n *\r\n * // The `_.matches` iteratee shorthand.\r\n * _.findLastIndex(users, { 'user': 'barney', 'active': true });\r\n * // => 0\r\n *\r\n * // The `_.matchesProperty` iteratee shorthand.\r\n * _.findLastIndex(users, ['active', false]);\r\n * // => 2\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.findLastIndex(users, 'active');\r\n * // => 0\r\n */\r\n function findLastIndex(array, predicate, fromIndex) {\r\n var length = array == null ? 0 : array.length;\r\n if (!length) {\r\n return -1;\r\n }\r\n var index = length - 1;\r\n if (fromIndex !== undefined) {\r\n index = toInteger(fromIndex);\r\n index = fromIndex < 0\r\n ? nativeMax(length + index, 0)\r\n : nativeMin(index, length - 1);\r\n }\r\n return baseFindIndex(array, baseIteratee(predicate, 3), index, true);\r\n }\r\n\r\n /**\r\n * Flattens `array` a single level deep.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Array\r\n * @param {Array} array The array to flatten.\r\n * @returns {Array} Returns the new flattened array.\r\n * @example\r\n *\r\n * _.flatten([1, [2, [3, [4]], 5]]);\r\n * // => [1, 2, [3, [4]], 5]\r\n */\r\n function flatten(array) {\r\n var length = array == null ? 0 : array.length;\r\n return length ? baseFlatten(array, 1) : [];\r\n }\r\n\r\n /**\r\n * Recursively flattens `array`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.0.0\r\n * @category Array\r\n * @param {Array} array The array to flatten.\r\n * @returns {Array} Returns the new flattened array.\r\n * @example\r\n *\r\n * _.flattenDeep([1, [2, [3, [4]], 5]]);\r\n * // => [1, 2, 3, 4, 5]\r\n */\r\n function flattenDeep(array) {\r\n var length = array == null ? 0 : array.length;\r\n return length ? baseFlatten(array, INFINITY) : [];\r\n }\r\n\r\n /**\r\n * Gets the first element of `array`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @alias first\r\n * @category Array\r\n * @param {Array} array The array to query.\r\n * @returns {*} Returns the first element of `array`.\r\n * @example\r\n *\r\n * _.head([1, 2, 3]);\r\n * // => 1\r\n *\r\n * _.head([]);\r\n * // => undefined\r\n */\r\n function head(array) {\r\n return (array && array.length) ? array[0] : undefined;\r\n }\r\n\r\n /**\r\n * Gets the index at which the first occurrence of `value` is found in `array`\r\n * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\r\n * for equality comparisons. If `fromIndex` is negative, it's used as the\r\n * offset from the end of `array`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Array\r\n * @param {Array} array The array to inspect.\r\n * @param {*} value The value to search for.\r\n * @param {number} [fromIndex=0] The index to search from.\r\n * @returns {number} Returns the index of the matched value, else `-1`.\r\n * @example\r\n *\r\n * _.indexOf([1, 2, 1, 2], 2);\r\n * // => 1\r\n *\r\n * // Search from the `fromIndex`.\r\n * _.indexOf([1, 2, 1, 2], 2, 2);\r\n * // => 3\r\n */\r\n function indexOf(array, value, fromIndex) {\r\n var length = array == null ? 0 : array.length;\r\n if (!length) {\r\n return -1;\r\n }\r\n var index = fromIndex == null ? 0 : toInteger(fromIndex);\r\n if (index < 0) {\r\n index = nativeMax(length + index, 0);\r\n }\r\n return baseIndexOf(array, value, index);\r\n }\r\n\r\n /**\r\n * Gets all but the last element of `array`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Array\r\n * @param {Array} array The array to query.\r\n * @returns {Array} Returns the slice of `array`.\r\n * @example\r\n *\r\n * _.initial([1, 2, 3]);\r\n * // => [1, 2]\r\n */\r\n function initial(array) {\r\n var length = array == null ? 0 : array.length;\r\n return length ? baseSlice(array, 0, -1) : [];\r\n }\r\n\r\n /**\r\n * Creates an array of unique values that are included in all given arrays\r\n * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\r\n * for equality comparisons. The order and references of result values are\r\n * determined by the first array.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Array\r\n * @param {...Array} [arrays] The arrays to inspect.\r\n * @returns {Array} Returns the new array of intersecting values.\r\n * @example\r\n *\r\n * _.intersection([2, 1], [2, 3]);\r\n * // => [2]\r\n */\r\n var intersection = baseRest(function(arrays) {\r\n var mapped = arrayMap(arrays, castArrayLikeObject);\r\n return (mapped.length && mapped[0] === arrays[0])\r\n ? baseIntersection(mapped)\r\n : [];\r\n });\r\n\r\n /**\r\n * Gets the last element of `array`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Array\r\n * @param {Array} array The array to query.\r\n * @returns {*} Returns the last element of `array`.\r\n * @example\r\n *\r\n * _.last([1, 2, 3]);\r\n * // => 3\r\n */\r\n function last(array) {\r\n var length = array == null ? 0 : array.length;\r\n return length ? array[length - 1] : undefined;\r\n }\r\n\r\n /**\r\n * Reverses `array` so that the first element becomes the last, the second\r\n * element becomes the second to last, and so on.\r\n *\r\n * **Note:** This method mutates `array` and is based on\r\n * [`Array#reverse`](https://mdn.io/Array/reverse).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Array\r\n * @param {Array} array The array to modify.\r\n * @returns {Array} Returns `array`.\r\n * @example\r\n *\r\n * var array = [1, 2, 3];\r\n *\r\n * _.reverse(array);\r\n * // => [3, 2, 1]\r\n *\r\n * console.log(array);\r\n * // => [3, 2, 1]\r\n */\r\n function reverse(array) {\r\n return array == null ? array : nativeReverse.call(array);\r\n }\r\n\r\n /**\r\n * Creates a slice of `array` from `start` up to, but not including, `end`.\r\n *\r\n * **Note:** This method is used instead of\r\n * [`Array#slice`](https://mdn.io/Array/slice) to ensure dense arrays are\r\n * returned.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.0.0\r\n * @category Array\r\n * @param {Array} array The array to slice.\r\n * @param {number} [start=0] The start position.\r\n * @param {number} [end=array.length] The end position.\r\n * @returns {Array} Returns the slice of `array`.\r\n */\r\n function slice(array, start, end) {\r\n var length = array == null ? 0 : array.length;\r\n if (!length) {\r\n return [];\r\n }\r\n if (end && typeof end != 'number' && isIterateeCall(array, start, end)) {\r\n start = 0;\r\n end = length;\r\n }\r\n else {\r\n start = start == null ? 0 : toInteger(start);\r\n end = end === undefined ? length : toInteger(end);\r\n }\r\n return baseSlice(array, start, end);\r\n }\r\n\r\n /**\r\n * Creates a slice of `array` with `n` elements taken from the beginning.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Array\r\n * @param {Array} array The array to query.\r\n * @param {number} [n=1] The number of elements to take.\r\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\r\n * @returns {Array} Returns the slice of `array`.\r\n * @example\r\n *\r\n * _.take([1, 2, 3]);\r\n * // => [1]\r\n *\r\n * _.take([1, 2, 3], 2);\r\n * // => [1, 2]\r\n *\r\n * _.take([1, 2, 3], 5);\r\n * // => [1, 2, 3]\r\n *\r\n * _.take([1, 2, 3], 0);\r\n * // => []\r\n */\r\n function take(array, n, guard) {\r\n if (!(array && array.length)) {\r\n return [];\r\n }\r\n n = (guard || n === undefined) ? 1 : toInteger(n);\r\n return baseSlice(array, 0, n < 0 ? 0 : n);\r\n }\r\n\r\n /**\r\n * Creates a slice of `array` with `n` elements taken from the end.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.0.0\r\n * @category Array\r\n * @param {Array} array The array to query.\r\n * @param {number} [n=1] The number of elements to take.\r\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\r\n * @returns {Array} Returns the slice of `array`.\r\n * @example\r\n *\r\n * _.takeRight([1, 2, 3]);\r\n * // => [3]\r\n *\r\n * _.takeRight([1, 2, 3], 2);\r\n * // => [2, 3]\r\n *\r\n * _.takeRight([1, 2, 3], 5);\r\n * // => [1, 2, 3]\r\n *\r\n * _.takeRight([1, 2, 3], 0);\r\n * // => []\r\n */\r\n function takeRight(array, n, guard) {\r\n var length = array == null ? 0 : array.length;\r\n if (!length) {\r\n return [];\r\n }\r\n n = (guard || n === undefined) ? 1 : toInteger(n);\r\n n = length - n;\r\n return baseSlice(array, n < 0 ? 0 : n, length);\r\n }\r\n\r\n /**\r\n * Creates an array of unique values, in order, from all given arrays using\r\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\r\n * for equality comparisons.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Array\r\n * @param {...Array} [arrays] The arrays to inspect.\r\n * @returns {Array} Returns the new array of combined values.\r\n * @example\r\n *\r\n * _.union([2], [1, 2]);\r\n * // => [2, 1]\r\n */\r\n var union = baseRest(function(arrays) {\r\n return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true));\r\n });\r\n\r\n /**\r\n * Creates a duplicate-free version of an array, using\r\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\r\n * for equality comparisons, in which only the first occurrence of each element\r\n * is kept. The order of result values is determined by the order they occur\r\n * in the array.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Array\r\n * @param {Array} array The array to inspect.\r\n * @returns {Array} Returns the new duplicate free array.\r\n * @example\r\n *\r\n * _.uniq([2, 1, 2]);\r\n * // => [2, 1]\r\n */\r\n function uniq(array) {\r\n return (array && array.length) ? baseUniq(array) : [];\r\n }\r\n\r\n /**\r\n * This method is like `_.uniq` except that it accepts `iteratee` which is\r\n * invoked for each element in `array` to generate the criterion by which\r\n * uniqueness is computed. The order of result values is determined by the\r\n * order they occur in the array. The iteratee is invoked with one argument:\r\n * (value).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Array\r\n * @param {Array} array The array to inspect.\r\n * @param {Function} [iteratee=_.identity] The iteratee invoked per element.\r\n * @returns {Array} Returns the new duplicate free array.\r\n * @example\r\n *\r\n * _.uniqBy([2.1, 1.2, 2.3], Math.floor);\r\n * // => [2.1, 1.2]\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.uniqBy([{ 'x': 1 }, { 'x': 2 }, { 'x': 1 }], 'x');\r\n * // => [{ 'x': 1 }, { 'x': 2 }]\r\n */\r\n function uniqBy(array, iteratee) {\r\n return (array && array.length) ? baseUniq(array, baseIteratee(iteratee, 2)) : [];\r\n }\r\n\r\n /**\r\n * This method is like `_.zip` except that it accepts an array of grouped\r\n * elements and creates an array regrouping the elements to their pre-zip\r\n * configuration.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 1.2.0\r\n * @category Array\r\n * @param {Array} array The array of grouped elements to process.\r\n * @returns {Array} Returns the new array of regrouped elements.\r\n * @example\r\n *\r\n * var zipped = _.zip(['a', 'b'], [1, 2], [true, false]);\r\n * // => [['a', 1, true], ['b', 2, false]]\r\n *\r\n * _.unzip(zipped);\r\n * // => [['a', 'b'], [1, 2], [true, false]]\r\n */\r\n function unzip(array) {\r\n if (!(array && array.length)) {\r\n return [];\r\n }\r\n var length = 0;\r\n array = arrayFilter(array, function(group) {\r\n if (isArrayLikeObject(group)) {\r\n length = nativeMax(group.length, length);\r\n return true;\r\n }\r\n });\r\n return baseTimes(length, function(index) {\r\n return arrayMap(array, baseProperty(index));\r\n });\r\n }\r\n\r\n /**\r\n * Creates an array excluding all given values using\r\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\r\n * for equality comparisons.\r\n *\r\n * **Note:** Unlike `_.pull`, this method returns a new array.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Array\r\n * @param {Array} array The array to inspect.\r\n * @param {...*} [values] The values to exclude.\r\n * @returns {Array} Returns the new array of filtered values.\r\n * @see _.difference, _.xor\r\n * @example\r\n *\r\n * _.without([2, 1, 2, 3], 1, 2);\r\n * // => [3]\r\n */\r\n var without = baseRest(function(array, values) {\r\n return isArrayLikeObject(array)\r\n ? baseDifference(array, values)\r\n : [];\r\n });\r\n\r\n /**\r\n * Creates an array of grouped elements, the first of which contains the\r\n * first elements of the given arrays, the second of which contains the\r\n * second elements of the given arrays, and so on.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Array\r\n * @param {...Array} [arrays] The arrays to process.\r\n * @returns {Array} Returns the new array of grouped elements.\r\n * @example\r\n *\r\n * _.zip(['a', 'b'], [1, 2], [true, false]);\r\n * // => [['a', 1, true], ['b', 2, false]]\r\n */\r\n var zip = baseRest(unzip);\r\n\r\n /**\r\n * This method is like `_.fromPairs` except that it accepts two arrays,\r\n * one of property identifiers and one of corresponding values.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.4.0\r\n * @category Array\r\n * @param {Array} [props=[]] The property identifiers.\r\n * @param {Array} [values=[]] The property values.\r\n * @returns {Object} Returns the new object.\r\n * @example\r\n *\r\n * _.zipObject(['a', 'b'], [1, 2]);\r\n * // => { 'a': 1, 'b': 2 }\r\n */\r\n function zipObject(props, values) {\r\n return baseZipObject(props || [], values || [], assignValue);\r\n }\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Creates a `lodash` wrapper instance that wraps `value` with explicit method\r\n * chain sequences enabled. The result of such sequences must be unwrapped\r\n * with `_#value`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 1.3.0\r\n * @category Seq\r\n * @param {*} value The value to wrap.\r\n * @returns {Object} Returns the new `lodash` wrapper instance.\r\n * @example\r\n *\r\n * var users = [\r\n * { 'user': 'barney', 'age': 36 },\r\n * { 'user': 'fred', 'age': 40 },\r\n * { 'user': 'pebbles', 'age': 1 }\r\n * ];\r\n *\r\n * var youngest = _\r\n * .chain(users)\r\n * .sortBy('age')\r\n * .map(function(o) {\r\n * return o.user + ' is ' + o.age;\r\n * })\r\n * .head()\r\n * .value();\r\n * // => 'pebbles is 1'\r\n */\r\n function chain(value) {\r\n var result = lodash(value);\r\n result.__chain__ = true;\r\n return result;\r\n }\r\n\r\n /**\r\n * This method invokes `interceptor` and returns `value`. The interceptor\r\n * is invoked with one argument; (value). The purpose of this method is to\r\n * \"tap into\" a method chain sequence in order to modify intermediate results.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Seq\r\n * @param {*} value The value to provide to `interceptor`.\r\n * @param {Function} interceptor The function to invoke.\r\n * @returns {*} Returns `value`.\r\n * @example\r\n *\r\n * _([1, 2, 3])\r\n * .tap(function(array) {\r\n * // Mutate input array.\r\n * array.pop();\r\n * })\r\n * .reverse()\r\n * .value();\r\n * // => [2, 1]\r\n */\r\n function tap(value, interceptor) {\r\n interceptor(value);\r\n return value;\r\n }\r\n\r\n /**\r\n * This method is like `_.tap` except that it returns the result of `interceptor`.\r\n * The purpose of this method is to \"pass thru\" values replacing intermediate\r\n * results in a method chain sequence.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.0.0\r\n * @category Seq\r\n * @param {*} value The value to provide to `interceptor`.\r\n * @param {Function} interceptor The function to invoke.\r\n * @returns {*} Returns the result of `interceptor`.\r\n * @example\r\n *\r\n * _(' abc ')\r\n * .chain()\r\n * .trim()\r\n * .thru(function(value) {\r\n * return [value];\r\n * })\r\n * .value();\r\n * // => ['abc']\r\n */\r\n function thru(value, interceptor) {\r\n return interceptor(value);\r\n }\r\n\r\n /**\r\n * This method is the wrapper version of `_.at`.\r\n *\r\n * @name at\r\n * @memberOf _\r\n * @since 1.0.0\r\n * @category Seq\r\n * @param {...(string|string[])} [paths] The property paths to pick.\r\n * @returns {Object} Returns the new `lodash` wrapper instance.\r\n * @example\r\n *\r\n * var object = { 'a': [{ 'b': { 'c': 3 } }, 4] };\r\n *\r\n * _(object).at(['a[0].b.c', 'a[1]']).value();\r\n * // => [3, 4]\r\n */\r\n var wrapperAt = flatRest(function(paths) {\r\n var length = paths.length,\r\n start = length ? paths[0] : 0,\r\n value = this.__wrapped__,\r\n interceptor = function(object) { return baseAt(object, paths); };\r\n\r\n if (length > 1 || this.__actions__.length ||\r\n !(value instanceof LazyWrapper) || !isIndex(start)) {\r\n return this.thru(interceptor);\r\n }\r\n value = value.slice(start, +start + (length ? 1 : 0));\r\n value.__actions__.push({\r\n 'func': thru,\r\n 'args': [interceptor],\r\n 'thisArg': undefined\r\n });\r\n return new LodashWrapper(value, this.__chain__).thru(function(array) {\r\n if (length && !array.length) {\r\n array.push(undefined);\r\n }\r\n return array;\r\n });\r\n });\r\n\r\n /**\r\n * Creates a `lodash` wrapper instance with explicit method chain sequences enabled.\r\n *\r\n * @name chain\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Seq\r\n * @returns {Object} Returns the new `lodash` wrapper instance.\r\n * @example\r\n *\r\n * var users = [\r\n * { 'user': 'barney', 'age': 36 },\r\n * { 'user': 'fred', 'age': 40 }\r\n * ];\r\n *\r\n * // A sequence without explicit chaining.\r\n * _(users).head();\r\n * // => { 'user': 'barney', 'age': 36 }\r\n *\r\n * // A sequence with explicit chaining.\r\n * _(users)\r\n * .chain()\r\n * .head()\r\n * .pick('user')\r\n * .value();\r\n * // => { 'user': 'barney' }\r\n */\r\n function wrapperChain() {\r\n return chain(this);\r\n }\r\n\r\n /**\r\n * Executes the chain sequence and returns the wrapped result.\r\n *\r\n * @name commit\r\n * @memberOf _\r\n * @since 3.2.0\r\n * @category Seq\r\n * @returns {Object} Returns the new `lodash` wrapper instance.\r\n * @example\r\n *\r\n * var array = [1, 2];\r\n * var wrapped = _(array).push(3);\r\n *\r\n * console.log(array);\r\n * // => [1, 2]\r\n *\r\n * wrapped = wrapped.commit();\r\n * console.log(array);\r\n * // => [1, 2, 3]\r\n *\r\n * wrapped.last();\r\n * // => 3\r\n *\r\n * console.log(array);\r\n * // => [1, 2, 3]\r\n */\r\n function wrapperCommit() {\r\n return new LodashWrapper(this.value(), this.__chain__);\r\n }\r\n\r\n /**\r\n * Gets the next value on a wrapped object following the\r\n * [iterator protocol](https://mdn.io/iteration_protocols#iterator).\r\n *\r\n * @name next\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Seq\r\n * @returns {Object} Returns the next iterator value.\r\n * @example\r\n *\r\n * var wrapped = _([1, 2]);\r\n *\r\n * wrapped.next();\r\n * // => { 'done': false, 'value': 1 }\r\n *\r\n * wrapped.next();\r\n * // => { 'done': false, 'value': 2 }\r\n *\r\n * wrapped.next();\r\n * // => { 'done': true, 'value': undefined }\r\n */\r\n function wrapperNext() {\r\n if (this.__values__ === undefined) {\r\n this.__values__ = toArray(this.value());\r\n }\r\n var done = this.__index__ >= this.__values__.length,\r\n value = done ? undefined : this.__values__[this.__index__++];\r\n\r\n return { 'done': done, 'value': value };\r\n }\r\n\r\n /**\r\n * Enables the wrapper to be iterable.\r\n *\r\n * @name Symbol.iterator\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Seq\r\n * @returns {Object} Returns the wrapper object.\r\n * @example\r\n *\r\n * var wrapped = _([1, 2]);\r\n *\r\n * wrapped[Symbol.iterator]() === wrapped;\r\n * // => true\r\n *\r\n * Array.from(wrapped);\r\n * // => [1, 2]\r\n */\r\n function wrapperToIterator() {\r\n return this;\r\n }\r\n\r\n /**\r\n * Creates a clone of the chain sequence planting `value` as the wrapped value.\r\n *\r\n * @name plant\r\n * @memberOf _\r\n * @since 3.2.0\r\n * @category Seq\r\n * @param {*} value The value to plant.\r\n * @returns {Object} Returns the new `lodash` wrapper instance.\r\n * @example\r\n *\r\n * function square(n) {\r\n * return n * n;\r\n * }\r\n *\r\n * var wrapped = _([1, 2]).map(square);\r\n * var other = wrapped.plant([3, 4]);\r\n *\r\n * other.value();\r\n * // => [9, 16]\r\n *\r\n * wrapped.value();\r\n * // => [1, 4]\r\n */\r\n function wrapperPlant(value) {\r\n var result,\r\n parent = this;\r\n\r\n while (parent instanceof baseLodash) {\r\n var clone = wrapperClone(parent);\r\n clone.__index__ = 0;\r\n clone.__values__ = undefined;\r\n if (result) {\r\n previous.__wrapped__ = clone;\r\n } else {\r\n result = clone;\r\n }\r\n var previous = clone;\r\n parent = parent.__wrapped__;\r\n }\r\n previous.__wrapped__ = value;\r\n return result;\r\n }\r\n\r\n /**\r\n * This method is the wrapper version of `_.reverse`.\r\n *\r\n * **Note:** This method mutates the wrapped array.\r\n *\r\n * @name reverse\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Seq\r\n * @returns {Object} Returns the new `lodash` wrapper instance.\r\n * @example\r\n *\r\n * var array = [1, 2, 3];\r\n *\r\n * _(array).reverse().value()\r\n * // => [3, 2, 1]\r\n *\r\n * console.log(array);\r\n * // => [3, 2, 1]\r\n */\r\n function wrapperReverse() {\r\n var value = this.__wrapped__;\r\n if (value instanceof LazyWrapper) {\r\n var wrapped = value;\r\n if (this.__actions__.length) {\r\n wrapped = new LazyWrapper(this);\r\n }\r\n wrapped = wrapped.reverse();\r\n wrapped.__actions__.push({\r\n 'func': thru,\r\n 'args': [reverse],\r\n 'thisArg': undefined\r\n });\r\n return new LodashWrapper(wrapped, this.__chain__);\r\n }\r\n return this.thru(reverse);\r\n }\r\n\r\n /**\r\n * Executes the chain sequence to resolve the unwrapped value.\r\n *\r\n * @name value\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @alias toJSON, valueOf\r\n * @category Seq\r\n * @returns {*} Returns the resolved unwrapped value.\r\n * @example\r\n *\r\n * _([1, 2, 3]).value();\r\n * // => [1, 2, 3]\r\n */\r\n function wrapperValue() {\r\n return baseWrapperValue(this.__wrapped__, this.__actions__);\r\n }\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Creates an object composed of keys generated from the results of running\r\n * each element of `collection` thru `iteratee`. The corresponding value of\r\n * each key is the number of times the key was returned by `iteratee`. The\r\n * iteratee is invoked with one argument: (value).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.5.0\r\n * @category Collection\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} [iteratee=_.identity] The iteratee to transform keys.\r\n * @returns {Object} Returns the composed aggregate object.\r\n * @example\r\n *\r\n * _.countBy([6.1, 4.2, 6.3], Math.floor);\r\n * // => { '4': 1, '6': 2 }\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.countBy(['one', 'two', 'three'], 'length');\r\n * // => { '3': 2, '5': 1 }\r\n */\r\n var countBy = createAggregator(function(result, value, key) {\r\n if (hasOwnProperty.call(result, key)) {\r\n ++result[key];\r\n } else {\r\n baseAssignValue(result, key, 1);\r\n }\r\n });\r\n\r\n /**\r\n * Checks if `predicate` returns truthy for **all** elements of `collection`.\r\n * Iteration is stopped once `predicate` returns falsey. The predicate is\r\n * invoked with three arguments: (value, index|key, collection).\r\n *\r\n * **Note:** This method returns `true` for\r\n * [empty collections](https://en.wikipedia.org/wiki/Empty_set) because\r\n * [everything is true](https://en.wikipedia.org/wiki/Vacuous_truth) of\r\n * elements of empty collections.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Collection\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\r\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\r\n * @returns {boolean} Returns `true` if all elements pass the predicate check,\r\n * else `false`.\r\n * @example\r\n *\r\n * _.every([true, 1, null, 'yes'], Boolean);\r\n * // => false\r\n *\r\n * var users = [\r\n * { 'user': 'barney', 'age': 36, 'active': false },\r\n * { 'user': 'fred', 'age': 40, 'active': false }\r\n * ];\r\n *\r\n * // The `_.matches` iteratee shorthand.\r\n * _.every(users, { 'user': 'barney', 'active': false });\r\n * // => false\r\n *\r\n * // The `_.matchesProperty` iteratee shorthand.\r\n * _.every(users, ['active', false]);\r\n * // => true\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.every(users, 'active');\r\n * // => false\r\n */\r\n function every(collection, predicate, guard) {\r\n var func = isArray(collection) ? arrayEvery : baseEvery;\r\n if (guard && isIterateeCall(collection, predicate, guard)) {\r\n predicate = undefined;\r\n }\r\n return func(collection, baseIteratee(predicate, 3));\r\n }\r\n\r\n /**\r\n * Iterates over elements of `collection`, returning an array of all elements\r\n * `predicate` returns truthy for. The predicate is invoked with three\r\n * arguments: (value, index|key, collection).\r\n *\r\n * **Note:** Unlike `_.remove`, this method returns a new array.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Collection\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\r\n * @returns {Array} Returns the new filtered array.\r\n * @see _.reject\r\n * @example\r\n *\r\n * var users = [\r\n * { 'user': 'barney', 'age': 36, 'active': true },\r\n * { 'user': 'fred', 'age': 40, 'active': false }\r\n * ];\r\n *\r\n * _.filter(users, function(o) { return !o.active; });\r\n * // => objects for ['fred']\r\n *\r\n * // The `_.matches` iteratee shorthand.\r\n * _.filter(users, { 'age': 36, 'active': true });\r\n * // => objects for ['barney']\r\n *\r\n * // The `_.matchesProperty` iteratee shorthand.\r\n * _.filter(users, ['active', false]);\r\n * // => objects for ['fred']\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.filter(users, 'active');\r\n * // => objects for ['barney']\r\n */\r\n function filter(collection, predicate) {\r\n var func = isArray(collection) ? arrayFilter : baseFilter;\r\n return func(collection, baseIteratee(predicate, 3));\r\n }\r\n\r\n /**\r\n * Iterates over elements of `collection`, returning the first element\r\n * `predicate` returns truthy for. The predicate is invoked with three\r\n * arguments: (value, index|key, collection).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Collection\r\n * @param {Array|Object} collection The collection to inspect.\r\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\r\n * @param {number} [fromIndex=0] The index to search from.\r\n * @returns {*} Returns the matched element, else `undefined`.\r\n * @example\r\n *\r\n * var users = [\r\n * { 'user': 'barney', 'age': 36, 'active': true },\r\n * { 'user': 'fred', 'age': 40, 'active': false },\r\n * { 'user': 'pebbles', 'age': 1, 'active': true }\r\n * ];\r\n *\r\n * _.find(users, function(o) { return o.age < 40; });\r\n * // => object for 'barney'\r\n *\r\n * // The `_.matches` iteratee shorthand.\r\n * _.find(users, { 'age': 1, 'active': true });\r\n * // => object for 'pebbles'\r\n *\r\n * // The `_.matchesProperty` iteratee shorthand.\r\n * _.find(users, ['active', false]);\r\n * // => object for 'fred'\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.find(users, 'active');\r\n * // => object for 'barney'\r\n */\r\n var find = createFind(findIndex);\r\n\r\n /**\r\n * Iterates over elements of `collection` and invokes `iteratee` for each element.\r\n * The iteratee is invoked with three arguments: (value, index|key, collection).\r\n * Iteratee functions may exit iteration early by explicitly returning `false`.\r\n *\r\n * **Note:** As with other \"Collections\" methods, objects with a \"length\"\r\n * property are iterated like arrays. To avoid this behavior use `_.forIn`\r\n * or `_.forOwn` for object iteration.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @alias each\r\n * @category Collection\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\r\n * @returns {Array|Object} Returns `collection`.\r\n * @see _.forEachRight\r\n * @example\r\n *\r\n * _.forEach([1, 2], function(value) {\r\n * console.log(value);\r\n * });\r\n * // => Logs `1` then `2`.\r\n *\r\n * _.forEach({ 'a': 1, 'b': 2 }, function(value, key) {\r\n * console.log(key);\r\n * });\r\n * // => Logs 'a' then 'b' (iteration order is not guaranteed).\r\n */\r\n function forEach(collection, iteratee) {\r\n var func = isArray(collection) ? arrayEach : baseEach;\r\n return func(collection, baseIteratee(iteratee, 3));\r\n }\r\n\r\n /**\r\n * Creates an object composed of keys generated from the results of running\r\n * each element of `collection` thru `iteratee`. The order of grouped values\r\n * is determined by the order they occur in `collection`. The corresponding\r\n * value of each key is an array of elements responsible for generating the\r\n * key. The iteratee is invoked with one argument: (value).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Collection\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} [iteratee=_.identity] The iteratee to transform keys.\r\n * @returns {Object} Returns the composed aggregate object.\r\n * @example\r\n *\r\n * _.groupBy([6.1, 4.2, 6.3], Math.floor);\r\n * // => { '4': [4.2], '6': [6.1, 6.3] }\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.groupBy(['one', 'two', 'three'], 'length');\r\n * // => { '3': ['one', 'two'], '5': ['three'] }\r\n */\r\n var groupBy = createAggregator(function(result, value, key) {\r\n if (hasOwnProperty.call(result, key)) {\r\n result[key].push(value);\r\n } else {\r\n baseAssignValue(result, key, [value]);\r\n }\r\n });\r\n\r\n /**\r\n * Creates an array of values by running each element in `collection` thru\r\n * `iteratee`. The iteratee is invoked with three arguments:\r\n * (value, index|key, collection).\r\n *\r\n * Many lodash methods are guarded to work as iteratees for methods like\r\n * `_.every`, `_.filter`, `_.map`, `_.mapValues`, `_.reject`, and `_.some`.\r\n *\r\n * The guarded methods are:\r\n * `ary`, `chunk`, `curry`, `curryRight`, `drop`, `dropRight`, `every`,\r\n * `fill`, `invert`, `parseInt`, `random`, `range`, `rangeRight`, `repeat`,\r\n * `sampleSize`, `slice`, `some`, `sortBy`, `split`, `take`, `takeRight`,\r\n * `template`, `trim`, `trimEnd`, `trimStart`, and `words`\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Collection\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\r\n * @returns {Array} Returns the new mapped array.\r\n * @example\r\n *\r\n * function square(n) {\r\n * return n * n;\r\n * }\r\n *\r\n * _.map([4, 8], square);\r\n * // => [16, 64]\r\n *\r\n * _.map({ 'a': 4, 'b': 8 }, square);\r\n * // => [16, 64] (iteration order is not guaranteed)\r\n *\r\n * var users = [\r\n * { 'user': 'barney' },\r\n * { 'user': 'fred' }\r\n * ];\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.map(users, 'user');\r\n * // => ['barney', 'fred']\r\n */\r\n function map(collection, iteratee) {\r\n var func = isArray(collection) ? arrayMap : baseMap;\r\n return func(collection, baseIteratee(iteratee, 3));\r\n }\r\n\r\n /**\r\n * Reduces `collection` to a value which is the accumulated result of running\r\n * each element in `collection` thru `iteratee`, where each successive\r\n * invocation is supplied the return value of the previous. If `accumulator`\r\n * is not given, the first element of `collection` is used as the initial\r\n * value. The iteratee is invoked with four arguments:\r\n * (accumulator, value, index|key, collection).\r\n *\r\n * Many lodash methods are guarded to work as iteratees for methods like\r\n * `_.reduce`, `_.reduceRight`, and `_.transform`.\r\n *\r\n * The guarded methods are:\r\n * `assign`, `defaults`, `defaultsDeep`, `includes`, `merge`, `orderBy`,\r\n * and `sortBy`\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Collection\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\r\n * @param {*} [accumulator] The initial value.\r\n * @returns {*} Returns the accumulated value.\r\n * @see _.reduceRight\r\n * @example\r\n *\r\n * _.reduce([1, 2], function(sum, n) {\r\n * return sum + n;\r\n * }, 0);\r\n * // => 3\r\n *\r\n * _.reduce({ 'a': 1, 'b': 2, 'c': 1 }, function(result, value, key) {\r\n * (result[value] || (result[value] = [])).push(key);\r\n * return result;\r\n * }, {});\r\n * // => { '1': ['a', 'c'], '2': ['b'] } (iteration order is not guaranteed)\r\n */\r\n function reduce(collection, iteratee, accumulator) {\r\n var func = isArray(collection) ? arrayReduce : baseReduce,\r\n initAccum = arguments.length < 3;\r\n\r\n return func(collection, baseIteratee(iteratee, 4), accumulator, initAccum, baseEach);\r\n }\r\n\r\n /**\r\n * The opposite of `_.filter`; this method returns the elements of `collection`\r\n * that `predicate` does **not** return truthy for.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Collection\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\r\n * @returns {Array} Returns the new filtered array.\r\n * @see _.filter\r\n * @example\r\n *\r\n * var users = [\r\n * { 'user': 'barney', 'age': 36, 'active': false },\r\n * { 'user': 'fred', 'age': 40, 'active': true }\r\n * ];\r\n *\r\n * _.reject(users, function(o) { return !o.active; });\r\n * // => objects for ['fred']\r\n *\r\n * // The `_.matches` iteratee shorthand.\r\n * _.reject(users, { 'age': 40, 'active': true });\r\n * // => objects for ['barney']\r\n *\r\n * // The `_.matchesProperty` iteratee shorthand.\r\n * _.reject(users, ['active', false]);\r\n * // => objects for ['fred']\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.reject(users, 'active');\r\n * // => objects for ['barney']\r\n */\r\n function reject(collection, predicate) {\r\n var func = isArray(collection) ? arrayFilter : baseFilter;\r\n return func(collection, negate(baseIteratee(predicate, 3)));\r\n }\r\n\r\n /**\r\n * Gets the size of `collection` by returning its length for array-like\r\n * values or the number of own enumerable string keyed properties for objects.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Collection\r\n * @param {Array|Object|string} collection The collection to inspect.\r\n * @returns {number} Returns the collection size.\r\n * @example\r\n *\r\n * _.size([1, 2, 3]);\r\n * // => 3\r\n *\r\n * _.size({ 'a': 1, 'b': 2 });\r\n * // => 2\r\n *\r\n * _.size('pebbles');\r\n * // => 7\r\n */\r\n function size(collection) {\r\n if (collection == null) {\r\n return 0;\r\n }\r\n if (isArrayLike(collection)) {\r\n return isString(collection) ? stringSize(collection) : collection.length;\r\n }\r\n var tag = getTag(collection);\r\n if (tag == mapTag || tag == setTag) {\r\n return collection.size;\r\n }\r\n return baseKeys(collection).length;\r\n }\r\n\r\n /**\r\n * Checks if `predicate` returns truthy for **any** element of `collection`.\r\n * Iteration is stopped once `predicate` returns truthy. The predicate is\r\n * invoked with three arguments: (value, index|key, collection).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Collection\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\r\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\r\n * @returns {boolean} Returns `true` if any element passes the predicate check,\r\n * else `false`.\r\n * @example\r\n *\r\n * _.some([null, 0, 'yes', false], Boolean);\r\n * // => true\r\n *\r\n * var users = [\r\n * { 'user': 'barney', 'active': true },\r\n * { 'user': 'fred', 'active': false }\r\n * ];\r\n *\r\n * // The `_.matches` iteratee shorthand.\r\n * _.some(users, { 'user': 'barney', 'active': false });\r\n * // => false\r\n *\r\n * // The `_.matchesProperty` iteratee shorthand.\r\n * _.some(users, ['active', false]);\r\n * // => true\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.some(users, 'active');\r\n * // => true\r\n */\r\n function some(collection, predicate, guard) {\r\n var func = isArray(collection) ? arraySome : baseSome;\r\n if (guard && isIterateeCall(collection, predicate, guard)) {\r\n predicate = undefined;\r\n }\r\n return func(collection, baseIteratee(predicate, 3));\r\n }\r\n\r\n /**\r\n * Creates an array of elements, sorted in ascending order by the results of\r\n * running each element in a collection thru each iteratee. This method\r\n * performs a stable sort, that is, it preserves the original sort order of\r\n * equal elements. The iteratees are invoked with one argument: (value).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Collection\r\n * @param {Array|Object} collection The collection to iterate over.\r\n * @param {...(Function|Function[])} [iteratees=[_.identity]]\r\n * The iteratees to sort by.\r\n * @returns {Array} Returns the new sorted array.\r\n * @example\r\n *\r\n * var users = [\r\n * { 'user': 'fred', 'age': 48 },\r\n * { 'user': 'barney', 'age': 36 },\r\n * { 'user': 'fred', 'age': 40 },\r\n * { 'user': 'barney', 'age': 34 }\r\n * ];\r\n *\r\n * _.sortBy(users, [function(o) { return o.user; }]);\r\n * // => objects for [['barney', 36], ['barney', 34], ['fred', 48], ['fred', 40]]\r\n *\r\n * _.sortBy(users, ['user', 'age']);\r\n * // => objects for [['barney', 34], ['barney', 36], ['fred', 40], ['fred', 48]]\r\n */\r\n var sortBy = baseRest(function(collection, iteratees) {\r\n if (collection == null) {\r\n return [];\r\n }\r\n var length = iteratees.length;\r\n if (length > 1 && isIterateeCall(collection, iteratees[0], iteratees[1])) {\r\n iteratees = [];\r\n } else if (length > 2 && isIterateeCall(iteratees[0], iteratees[1], iteratees[2])) {\r\n iteratees = [iteratees[0]];\r\n }\r\n return baseOrderBy(collection, baseFlatten(iteratees, 1), []);\r\n });\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Gets the timestamp of the number of milliseconds that have elapsed since\r\n * the Unix epoch (1 January 1970 00:00:00 UTC).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 2.4.0\r\n * @category Date\r\n * @returns {number} Returns the timestamp.\r\n * @example\r\n *\r\n * _.defer(function(stamp) {\r\n * console.log(_.now() - stamp);\r\n * }, _.now());\r\n * // => Logs the number of milliseconds it took for the deferred invocation.\r\n */\r\n var now = function() {\r\n return root.Date.now();\r\n };\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * The opposite of `_.before`; this method creates a function that invokes\r\n * `func` once it's called `n` or more times.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Function\r\n * @param {number} n The number of calls before `func` is invoked.\r\n * @param {Function} func The function to restrict.\r\n * @returns {Function} Returns the new restricted function.\r\n * @example\r\n *\r\n * var saves = ['profile', 'settings'];\r\n *\r\n * var done = _.after(saves.length, function() {\r\n * console.log('done saving!');\r\n * });\r\n *\r\n * _.forEach(saves, function(type) {\r\n * asyncSave({ 'type': type, 'complete': done });\r\n * });\r\n * // => Logs 'done saving!' after the two async saves have completed.\r\n */\r\n function after(n, func) {\r\n if (typeof func != 'function') {\r\n throw new TypeError(FUNC_ERROR_TEXT);\r\n }\r\n n = toInteger(n);\r\n return function() {\r\n if (--n < 1) {\r\n return func.apply(this, arguments);\r\n }\r\n };\r\n }\r\n\r\n /**\r\n * Creates a function that invokes `func`, with the `this` binding and arguments\r\n * of the created function, while it's called less than `n` times. Subsequent\r\n * calls to the created function return the result of the last `func` invocation.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.0.0\r\n * @category Function\r\n * @param {number} n The number of calls at which `func` is no longer invoked.\r\n * @param {Function} func The function to restrict.\r\n * @returns {Function} Returns the new restricted function.\r\n * @example\r\n *\r\n * jQuery(element).on('click', _.before(5, addContactToList));\r\n * // => Allows adding up to 4 contacts to the list.\r\n */\r\n function before(n, func) {\r\n var result;\r\n if (typeof func != 'function') {\r\n throw new TypeError(FUNC_ERROR_TEXT);\r\n }\r\n n = toInteger(n);\r\n return function() {\r\n if (--n > 0) {\r\n result = func.apply(this, arguments);\r\n }\r\n if (n <= 1) {\r\n func = undefined;\r\n }\r\n return result;\r\n };\r\n }\r\n\r\n /**\r\n * Creates a function that invokes `func` with the `this` binding of `thisArg`\r\n * and `partials` prepended to the arguments it receives.\r\n *\r\n * The `_.bind.placeholder` value, which defaults to `_` in monolithic builds,\r\n * may be used as a placeholder for partially applied arguments.\r\n *\r\n * **Note:** Unlike native `Function#bind`, this method doesn't set the \"length\"\r\n * property of bound functions.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Function\r\n * @param {Function} func The function to bind.\r\n * @param {*} thisArg The `this` binding of `func`.\r\n * @param {...*} [partials] The arguments to be partially applied.\r\n * @returns {Function} Returns the new bound function.\r\n * @example\r\n *\r\n * function greet(greeting, punctuation) {\r\n * return greeting + ' ' + this.user + punctuation;\r\n * }\r\n *\r\n * var object = { 'user': 'fred' };\r\n *\r\n * var bound = _.bind(greet, object, 'hi');\r\n * bound('!');\r\n * // => 'hi fred!'\r\n *\r\n * // Bound with placeholders.\r\n * var bound = _.bind(greet, object, _, '!');\r\n * bound('hi');\r\n * // => 'hi fred!'\r\n */\r\n var bind = baseRest(function(func, thisArg, partials) {\r\n var bitmask = WRAP_BIND_FLAG;\r\n if (partials.length) {\r\n var holders = replaceHolders(partials, getHolder(bind));\r\n bitmask |= WRAP_PARTIAL_FLAG;\r\n }\r\n return createWrap(func, bitmask, thisArg, partials, holders);\r\n });\r\n\r\n /**\r\n * Creates a debounced function that delays invoking `func` until after `wait`\r\n * milliseconds have elapsed since the last time the debounced function was\r\n * invoked. The debounced function comes with a `cancel` method to cancel\r\n * delayed `func` invocations and a `flush` method to immediately invoke them.\r\n * Provide `options` to indicate whether `func` should be invoked on the\r\n * leading and/or trailing edge of the `wait` timeout. The `func` is invoked\r\n * with the last arguments provided to the debounced function. Subsequent\r\n * calls to the debounced function return the result of the last `func`\r\n * invocation.\r\n *\r\n * **Note:** If `leading` and `trailing` options are `true`, `func` is\r\n * invoked on the trailing edge of the timeout only if the debounced function\r\n * is invoked more than once during the `wait` timeout.\r\n *\r\n * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred\r\n * until to the next tick, similar to `setTimeout` with a timeout of `0`.\r\n *\r\n * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)\r\n * for details over the differences between `_.debounce` and `_.throttle`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Function\r\n * @param {Function} func The function to debounce.\r\n * @param {number} [wait=0] The number of milliseconds to delay.\r\n * @param {Object} [options={}] The options object.\r\n * @param {boolean} [options.leading=false]\r\n * Specify invoking on the leading edge of the timeout.\r\n * @param {number} [options.maxWait]\r\n * The maximum time `func` is allowed to be delayed before it's invoked.\r\n * @param {boolean} [options.trailing=true]\r\n * Specify invoking on the trailing edge of the timeout.\r\n * @returns {Function} Returns the new debounced function.\r\n * @example\r\n *\r\n * // Avoid costly calculations while the window size is in flux.\r\n * jQuery(window).on('resize', _.debounce(calculateLayout, 150));\r\n *\r\n * // Invoke `sendMail` when clicked, debouncing subsequent calls.\r\n * jQuery(element).on('click', _.debounce(sendMail, 300, {\r\n * 'leading': true,\r\n * 'trailing': false\r\n * }));\r\n *\r\n * // Ensure `batchLog` is invoked once after 1 second of debounced calls.\r\n * var debounced = _.debounce(batchLog, 250, { 'maxWait': 1000 });\r\n * var source = new EventSource('/stream');\r\n * jQuery(source).on('message', debounced);\r\n *\r\n * // Cancel the trailing debounced invocation.\r\n * jQuery(window).on('popstate', debounced.cancel);\r\n */\r\n function debounce(func, wait, options) {\r\n var lastArgs,\r\n lastThis,\r\n maxWait,\r\n result,\r\n timerId,\r\n lastCallTime,\r\n lastInvokeTime = 0,\r\n leading = false,\r\n maxing = false,\r\n trailing = true;\r\n\r\n if (typeof func != 'function') {\r\n throw new TypeError(FUNC_ERROR_TEXT);\r\n }\r\n wait = toNumber(wait) || 0;\r\n if (isObject(options)) {\r\n leading = !!options.leading;\r\n maxing = 'maxWait' in options;\r\n maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait;\r\n trailing = 'trailing' in options ? !!options.trailing : trailing;\r\n }\r\n\r\n function invokeFunc(time) {\r\n var args = lastArgs,\r\n thisArg = lastThis;\r\n\r\n lastArgs = lastThis = undefined;\r\n lastInvokeTime = time;\r\n result = func.apply(thisArg, args);\r\n return result;\r\n }\r\n\r\n function leadingEdge(time) {\r\n // Reset any `maxWait` timer.\r\n lastInvokeTime = time;\r\n // Start the timer for the trailing edge.\r\n timerId = setTimeout(timerExpired, wait);\r\n // Invoke the leading edge.\r\n return leading ? invokeFunc(time) : result;\r\n }\r\n\r\n function remainingWait(time) {\r\n var timeSinceLastCall = time - lastCallTime,\r\n timeSinceLastInvoke = time - lastInvokeTime,\r\n timeWaiting = wait - timeSinceLastCall;\r\n\r\n return maxing\r\n ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke)\r\n : timeWaiting;\r\n }\r\n\r\n function shouldInvoke(time) {\r\n var timeSinceLastCall = time - lastCallTime,\r\n timeSinceLastInvoke = time - lastInvokeTime;\r\n\r\n // Either this is the first call, activity has stopped and we're at the\r\n // trailing edge, the system time has gone backwards and we're treating\r\n // it as the trailing edge, or we've hit the `maxWait` limit.\r\n return (lastCallTime === undefined || (timeSinceLastCall >= wait) ||\r\n (timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait));\r\n }\r\n\r\n function timerExpired() {\r\n var time = now();\r\n if (shouldInvoke(time)) {\r\n return trailingEdge(time);\r\n }\r\n // Restart the timer.\r\n timerId = setTimeout(timerExpired, remainingWait(time));\r\n }\r\n\r\n function trailingEdge(time) {\r\n timerId = undefined;\r\n\r\n // Only invoke if we have `lastArgs` which means `func` has been\r\n // debounced at least once.\r\n if (trailing && lastArgs) {\r\n return invokeFunc(time);\r\n }\r\n lastArgs = lastThis = undefined;\r\n return result;\r\n }\r\n\r\n function cancel() {\r\n if (timerId !== undefined) {\r\n clearTimeout(timerId);\r\n }\r\n lastInvokeTime = 0;\r\n lastArgs = lastCallTime = lastThis = timerId = undefined;\r\n }\r\n\r\n function flush() {\r\n return timerId === undefined ? result : trailingEdge(now());\r\n }\r\n\r\n function debounced() {\r\n var time = now(),\r\n isInvoking = shouldInvoke(time);\r\n\r\n lastArgs = arguments;\r\n lastThis = this;\r\n lastCallTime = time;\r\n\r\n if (isInvoking) {\r\n if (timerId === undefined) {\r\n return leadingEdge(lastCallTime);\r\n }\r\n if (maxing) {\r\n // Handle invocations in a tight loop.\r\n timerId = setTimeout(timerExpired, wait);\r\n return invokeFunc(lastCallTime);\r\n }\r\n }\r\n if (timerId === undefined) {\r\n timerId = setTimeout(timerExpired, wait);\r\n }\r\n return result;\r\n }\r\n debounced.cancel = cancel;\r\n debounced.flush = flush;\r\n return debounced;\r\n }\r\n\r\n /**\r\n * Defers invoking the `func` until the current call stack has cleared. Any\r\n * additional arguments are provided to `func` when it's invoked.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Function\r\n * @param {Function} func The function to defer.\r\n * @param {...*} [args] The arguments to invoke `func` with.\r\n * @returns {number} Returns the timer id.\r\n * @example\r\n *\r\n * _.defer(function(text) {\r\n * console.log(text);\r\n * }, 'deferred');\r\n * // => Logs 'deferred' after one millisecond.\r\n */\r\n var defer = baseRest(function(func, args) {\r\n return baseDelay(func, 1, args);\r\n });\r\n\r\n /**\r\n * Invokes `func` after `wait` milliseconds. Any additional arguments are\r\n * provided to `func` when it's invoked.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Function\r\n * @param {Function} func The function to delay.\r\n * @param {number} wait The number of milliseconds to delay invocation.\r\n * @param {...*} [args] The arguments to invoke `func` with.\r\n * @returns {number} Returns the timer id.\r\n * @example\r\n *\r\n * _.delay(function(text) {\r\n * console.log(text);\r\n * }, 1000, 'later');\r\n * // => Logs 'later' after one second.\r\n */\r\n var delay = baseRest(function(func, wait, args) {\r\n return baseDelay(func, toNumber(wait) || 0, args);\r\n });\r\n\r\n /**\r\n * Creates a function that memoizes the result of `func`. If `resolver` is\r\n * provided, it determines the cache key for storing the result based on the\r\n * arguments provided to the memoized function. By default, the first argument\r\n * provided to the memoized function is used as the map cache key. The `func`\r\n * is invoked with the `this` binding of the memoized function.\r\n *\r\n * **Note:** The cache is exposed as the `cache` property on the memoized\r\n * function. Its creation may be customized by replacing the `_.memoize.Cache`\r\n * constructor with one whose instances implement the\r\n * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)\r\n * method interface of `clear`, `delete`, `get`, `has`, and `set`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Function\r\n * @param {Function} func The function to have its output memoized.\r\n * @param {Function} [resolver] The function to resolve the cache key.\r\n * @returns {Function} Returns the new memoized function.\r\n * @example\r\n *\r\n * var object = { 'a': 1, 'b': 2 };\r\n * var other = { 'c': 3, 'd': 4 };\r\n *\r\n * var values = _.memoize(_.values);\r\n * values(object);\r\n * // => [1, 2]\r\n *\r\n * values(other);\r\n * // => [3, 4]\r\n *\r\n * object.a = 2;\r\n * values(object);\r\n * // => [1, 2]\r\n *\r\n * // Modify the result cache.\r\n * values.cache.set(object, ['a', 'b']);\r\n * values(object);\r\n * // => ['a', 'b']\r\n *\r\n * // Replace `_.memoize.Cache`.\r\n * _.memoize.Cache = WeakMap;\r\n */\r\n function memoize(func, resolver) {\r\n if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {\r\n throw new TypeError(FUNC_ERROR_TEXT);\r\n }\r\n var memoized = function() {\r\n var args = arguments,\r\n key = resolver ? resolver.apply(this, args) : args[0],\r\n cache = memoized.cache;\r\n\r\n if (cache.has(key)) {\r\n return cache.get(key);\r\n }\r\n var result = func.apply(this, args);\r\n memoized.cache = cache.set(key, result) || cache;\r\n return result;\r\n };\r\n memoized.cache = new (memoize.Cache || MapCache);\r\n return memoized;\r\n }\r\n\r\n // Expose `MapCache`.\r\n memoize.Cache = MapCache;\r\n\r\n /**\r\n * Creates a function that negates the result of the predicate `func`. The\r\n * `func` predicate is invoked with the `this` binding and arguments of the\r\n * created function.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.0.0\r\n * @category Function\r\n * @param {Function} predicate The predicate to negate.\r\n * @returns {Function} Returns the new negated function.\r\n * @example\r\n *\r\n * function isEven(n) {\r\n * return n % 2 == 0;\r\n * }\r\n *\r\n * _.filter([1, 2, 3, 4, 5, 6], _.negate(isEven));\r\n * // => [1, 3, 5]\r\n */\r\n function negate(predicate) {\r\n if (typeof predicate != 'function') {\r\n throw new TypeError(FUNC_ERROR_TEXT);\r\n }\r\n return function() {\r\n var args = arguments;\r\n switch (args.length) {\r\n case 0: return !predicate.call(this);\r\n case 1: return !predicate.call(this, args[0]);\r\n case 2: return !predicate.call(this, args[0], args[1]);\r\n case 3: return !predicate.call(this, args[0], args[1], args[2]);\r\n }\r\n return !predicate.apply(this, args);\r\n };\r\n }\r\n\r\n /**\r\n * Creates a function that is restricted to invoking `func` once. Repeat calls\r\n * to the function return the value of the first invocation. The `func` is\r\n * invoked with the `this` binding and arguments of the created function.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Function\r\n * @param {Function} func The function to restrict.\r\n * @returns {Function} Returns the new restricted function.\r\n * @example\r\n *\r\n * var initialize = _.once(createApplication);\r\n * initialize();\r\n * initialize();\r\n * // => `createApplication` is invoked once\r\n */\r\n function once(func) {\r\n return before(2, func);\r\n }\r\n\r\n /**\r\n * Creates a function that invokes `func` with the `this` binding of the\r\n * created function and arguments from `start` and beyond provided as\r\n * an array.\r\n *\r\n * **Note:** This method is based on the\r\n * [rest parameter](https://mdn.io/rest_parameters).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Function\r\n * @param {Function} func The function to apply a rest parameter to.\r\n * @param {number} [start=func.length-1] The start position of the rest parameter.\r\n * @returns {Function} Returns the new function.\r\n * @example\r\n *\r\n * var say = _.rest(function(what, names) {\r\n * return what + ' ' + _.initial(names).join(', ') +\r\n * (_.size(names) > 1 ? ', & ' : '') + _.last(names);\r\n * });\r\n *\r\n * say('hello', 'fred', 'barney', 'pebbles');\r\n * // => 'hello fred, barney, & pebbles'\r\n */\r\n function rest(func, start) {\r\n if (typeof func != 'function') {\r\n throw new TypeError(FUNC_ERROR_TEXT);\r\n }\r\n start = start === undefined ? start : toInteger(start);\r\n return baseRest(func, start);\r\n }\r\n\r\n /**\r\n * Creates a throttled function that only invokes `func` at most once per\r\n * every `wait` milliseconds. The throttled function comes with a `cancel`\r\n * method to cancel delayed `func` invocations and a `flush` method to\r\n * immediately invoke them. Provide `options` to indicate whether `func`\r\n * should be invoked on the leading and/or trailing edge of the `wait`\r\n * timeout. The `func` is invoked with the last arguments provided to the\r\n * throttled function. Subsequent calls to the throttled function return the\r\n * result of the last `func` invocation.\r\n *\r\n * **Note:** If `leading` and `trailing` options are `true`, `func` is\r\n * invoked on the trailing edge of the timeout only if the throttled function\r\n * is invoked more than once during the `wait` timeout.\r\n *\r\n * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred\r\n * until to the next tick, similar to `setTimeout` with a timeout of `0`.\r\n *\r\n * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)\r\n * for details over the differences between `_.throttle` and `_.debounce`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Function\r\n * @param {Function} func The function to throttle.\r\n * @param {number} [wait=0] The number of milliseconds to throttle invocations to.\r\n * @param {Object} [options={}] The options object.\r\n * @param {boolean} [options.leading=true]\r\n * Specify invoking on the leading edge of the timeout.\r\n * @param {boolean} [options.trailing=true]\r\n * Specify invoking on the trailing edge of the timeout.\r\n * @returns {Function} Returns the new throttled function.\r\n * @example\r\n *\r\n * // Avoid excessively updating the position while scrolling.\r\n * jQuery(window).on('scroll', _.throttle(updatePosition, 100));\r\n *\r\n * // Invoke `renewToken` when the click event is fired, but not more than once every 5 minutes.\r\n * var throttled = _.throttle(renewToken, 300000, { 'trailing': false });\r\n * jQuery(element).on('click', throttled);\r\n *\r\n * // Cancel the trailing throttled invocation.\r\n * jQuery(window).on('popstate', throttled.cancel);\r\n */\r\n function throttle(func, wait, options) {\r\n var leading = true,\r\n trailing = true;\r\n\r\n if (typeof func != 'function') {\r\n throw new TypeError(FUNC_ERROR_TEXT);\r\n }\r\n if (isObject(options)) {\r\n leading = 'leading' in options ? !!options.leading : leading;\r\n trailing = 'trailing' in options ? !!options.trailing : trailing;\r\n }\r\n return debounce(func, wait, {\r\n 'leading': leading,\r\n 'maxWait': wait,\r\n 'trailing': trailing\r\n });\r\n }\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Creates a shallow clone of `value`.\r\n *\r\n * **Note:** This method is loosely based on the\r\n * [structured clone algorithm](https://mdn.io/Structured_clone_algorithm)\r\n * and supports cloning arrays, array buffers, booleans, date objects, maps,\r\n * numbers, `Object` objects, regexes, sets, strings, symbols, and typed\r\n * arrays. The own enumerable properties of `arguments` objects are cloned\r\n * as plain objects. An empty object is returned for uncloneable values such\r\n * as error objects, functions, DOM nodes, and WeakMaps.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to clone.\r\n * @returns {*} Returns the cloned value.\r\n * @see _.cloneDeep\r\n * @example\r\n *\r\n * var objects = [{ 'a': 1 }, { 'b': 2 }];\r\n *\r\n * var shallow = _.clone(objects);\r\n * console.log(shallow[0] === objects[0]);\r\n * // => true\r\n */\r\n function clone(value) {\r\n return baseClone(value, CLONE_SYMBOLS_FLAG);\r\n }\r\n\r\n /**\r\n * This method is like `_.clone` except that it recursively clones `value`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 1.0.0\r\n * @category Lang\r\n * @param {*} value The value to recursively clone.\r\n * @returns {*} Returns the deep cloned value.\r\n * @see _.clone\r\n * @example\r\n *\r\n * var objects = [{ 'a': 1 }, { 'b': 2 }];\r\n *\r\n * var deep = _.cloneDeep(objects);\r\n * console.log(deep[0] === objects[0]);\r\n * // => false\r\n */\r\n function cloneDeep(value) {\r\n return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG);\r\n }\r\n\r\n /**\r\n * Performs a\r\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\r\n * comparison between two values to determine if they are equivalent.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Lang\r\n * @param {*} value The value to compare.\r\n * @param {*} other The other value to compare.\r\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\r\n * @example\r\n *\r\n * var object = { 'a': 1 };\r\n * var other = { 'a': 1 };\r\n *\r\n * _.eq(object, object);\r\n * // => true\r\n *\r\n * _.eq(object, other);\r\n * // => false\r\n *\r\n * _.eq('a', 'a');\r\n * // => true\r\n *\r\n * _.eq('a', Object('a'));\r\n * // => false\r\n *\r\n * _.eq(NaN, NaN);\r\n * // => true\r\n */\r\n function eq(value, other) {\r\n return value === other || (value !== value && other !== other);\r\n }\r\n\r\n /**\r\n * Checks if `value` is likely an `arguments` object.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\r\n * else `false`.\r\n * @example\r\n *\r\n * _.isArguments(function() { return arguments; }());\r\n * // => true\r\n *\r\n * _.isArguments([1, 2, 3]);\r\n * // => false\r\n */\r\n var isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\r\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\r\n !propertyIsEnumerable.call(value, 'callee');\r\n };\r\n\r\n /**\r\n * Checks if `value` is classified as an `Array` object.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\r\n * @example\r\n *\r\n * _.isArray([1, 2, 3]);\r\n * // => true\r\n *\r\n * _.isArray(document.body.children);\r\n * // => false\r\n *\r\n * _.isArray('abc');\r\n * // => false\r\n *\r\n * _.isArray(_.noop);\r\n * // => false\r\n */\r\n var isArray = Array.isArray;\r\n\r\n /**\r\n * Checks if `value` is array-like. A value is considered array-like if it's\r\n * not a function and has a `value.length` that's an integer greater than or\r\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\r\n * @example\r\n *\r\n * _.isArrayLike([1, 2, 3]);\r\n * // => true\r\n *\r\n * _.isArrayLike(document.body.children);\r\n * // => true\r\n *\r\n * _.isArrayLike('abc');\r\n * // => true\r\n *\r\n * _.isArrayLike(_.noop);\r\n * // => false\r\n */\r\n function isArrayLike(value) {\r\n return value != null && isLength(value.length) && !isFunction(value);\r\n }\r\n\r\n /**\r\n * This method is like `_.isArrayLike` except that it also checks if `value`\r\n * is an object.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is an array-like object,\r\n * else `false`.\r\n * @example\r\n *\r\n * _.isArrayLikeObject([1, 2, 3]);\r\n * // => true\r\n *\r\n * _.isArrayLikeObject(document.body.children);\r\n * // => true\r\n *\r\n * _.isArrayLikeObject('abc');\r\n * // => false\r\n *\r\n * _.isArrayLikeObject(_.noop);\r\n * // => false\r\n */\r\n function isArrayLikeObject(value) {\r\n return isObjectLike(value) && isArrayLike(value);\r\n }\r\n\r\n /**\r\n * Checks if `value` is classified as a boolean primitive or object.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a boolean, else `false`.\r\n * @example\r\n *\r\n * _.isBoolean(false);\r\n * // => true\r\n *\r\n * _.isBoolean(null);\r\n * // => false\r\n */\r\n function isBoolean(value) {\r\n return value === true || value === false ||\r\n (isObjectLike(value) && baseGetTag(value) == boolTag);\r\n }\r\n\r\n /**\r\n * Checks if `value` is a buffer.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.3.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\r\n * @example\r\n *\r\n * _.isBuffer(new Buffer(2));\r\n * // => true\r\n *\r\n * _.isBuffer(new Uint8Array(2));\r\n * // => false\r\n */\r\n var isBuffer = nativeIsBuffer || stubFalse;\r\n\r\n /**\r\n * Checks if `value` is classified as a `Date` object.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a date object, else `false`.\r\n * @example\r\n *\r\n * _.isDate(new Date);\r\n * // => true\r\n *\r\n * _.isDate('Mon April 23 2012');\r\n * // => false\r\n */\r\n var isDate = nodeIsDate ? baseUnary(nodeIsDate) : baseIsDate;\r\n\r\n /**\r\n * Checks if `value` is an empty object, collection, map, or set.\r\n *\r\n * Objects are considered empty if they have no own enumerable string keyed\r\n * properties.\r\n *\r\n * Array-like values such as `arguments` objects, arrays, buffers, strings, or\r\n * jQuery-like collections are considered empty if they have a `length` of `0`.\r\n * Similarly, maps and sets are considered empty if they have a `size` of `0`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is empty, else `false`.\r\n * @example\r\n *\r\n * _.isEmpty(null);\r\n * // => true\r\n *\r\n * _.isEmpty(true);\r\n * // => true\r\n *\r\n * _.isEmpty(1);\r\n * // => true\r\n *\r\n * _.isEmpty([1, 2, 3]);\r\n * // => false\r\n *\r\n * _.isEmpty({ 'a': 1 });\r\n * // => false\r\n */\r\n function isEmpty(value) {\r\n if (value == null) {\r\n return true;\r\n }\r\n if (isArrayLike(value) &&\r\n (isArray(value) || typeof value == 'string' || typeof value.splice == 'function' ||\r\n isBuffer(value) || isTypedArray(value) || isArguments(value))) {\r\n return !value.length;\r\n }\r\n var tag = getTag(value);\r\n if (tag == mapTag || tag == setTag) {\r\n return !value.size;\r\n }\r\n if (isPrototype(value)) {\r\n return !baseKeys(value).length;\r\n }\r\n for (var key in value) {\r\n if (hasOwnProperty.call(value, key)) {\r\n return false;\r\n }\r\n }\r\n return true;\r\n }\r\n\r\n /**\r\n * Performs a deep comparison between two values to determine if they are\r\n * equivalent.\r\n *\r\n * **Note:** This method supports comparing arrays, array buffers, booleans,\r\n * date objects, error objects, maps, numbers, `Object` objects, regexes,\r\n * sets, strings, symbols, and typed arrays. `Object` objects are compared\r\n * by their own, not inherited, enumerable properties. Functions and DOM\r\n * nodes are compared by strict equality, i.e. `===`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to compare.\r\n * @param {*} other The other value to compare.\r\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\r\n * @example\r\n *\r\n * var object = { 'a': 1 };\r\n * var other = { 'a': 1 };\r\n *\r\n * _.isEqual(object, other);\r\n * // => true\r\n *\r\n * object === other;\r\n * // => false\r\n */\r\n function isEqual(value, other) {\r\n return baseIsEqual(value, other);\r\n }\r\n\r\n /**\r\n * Checks if `value` is a finite primitive number.\r\n *\r\n * **Note:** This method is based on\r\n * [`Number.isFinite`](https://mdn.io/Number/isFinite).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a finite number, else `false`.\r\n * @example\r\n *\r\n * _.isFinite(3);\r\n * // => true\r\n *\r\n * _.isFinite(Number.MIN_VALUE);\r\n * // => true\r\n *\r\n * _.isFinite(Infinity);\r\n * // => false\r\n *\r\n * _.isFinite('3');\r\n * // => false\r\n */\r\n function isFinite(value) {\r\n return typeof value == 'number' && nativeIsFinite(value);\r\n }\r\n\r\n /**\r\n * Checks if `value` is classified as a `Function` object.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\r\n * @example\r\n *\r\n * _.isFunction(_);\r\n * // => true\r\n *\r\n * _.isFunction(/abc/);\r\n * // => false\r\n */\r\n function isFunction(value) {\r\n if (!isObject(value)) {\r\n return false;\r\n }\r\n // The use of `Object#toString` avoids issues with the `typeof` operator\r\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\r\n var tag = baseGetTag(value);\r\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\r\n }\r\n\r\n /**\r\n * Checks if `value` is a valid array-like length.\r\n *\r\n * **Note:** This method is loosely based on\r\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\r\n * @example\r\n *\r\n * _.isLength(3);\r\n * // => true\r\n *\r\n * _.isLength(Number.MIN_VALUE);\r\n * // => false\r\n *\r\n * _.isLength(Infinity);\r\n * // => false\r\n *\r\n * _.isLength('3');\r\n * // => false\r\n */\r\n function isLength(value) {\r\n return typeof value == 'number' &&\r\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\r\n }\r\n\r\n /**\r\n * Checks if `value` is the\r\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\r\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\r\n * @example\r\n *\r\n * _.isObject({});\r\n * // => true\r\n *\r\n * _.isObject([1, 2, 3]);\r\n * // => true\r\n *\r\n * _.isObject(_.noop);\r\n * // => true\r\n *\r\n * _.isObject(null);\r\n * // => false\r\n */\r\n function isObject(value) {\r\n var type = typeof value;\r\n return value != null && (type == 'object' || type == 'function');\r\n }\r\n\r\n /**\r\n * Checks if `value` is object-like. A value is object-like if it's not `null`\r\n * and has a `typeof` result of \"object\".\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\r\n * @example\r\n *\r\n * _.isObjectLike({});\r\n * // => true\r\n *\r\n * _.isObjectLike([1, 2, 3]);\r\n * // => true\r\n *\r\n * _.isObjectLike(_.noop);\r\n * // => false\r\n *\r\n * _.isObjectLike(null);\r\n * // => false\r\n */\r\n function isObjectLike(value) {\r\n return value != null && typeof value == 'object';\r\n }\r\n\r\n /**\r\n * Checks if `value` is classified as a `Map` object.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.3.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a map, else `false`.\r\n * @example\r\n *\r\n * _.isMap(new Map);\r\n * // => true\r\n *\r\n * _.isMap(new WeakMap);\r\n * // => false\r\n */\r\n var isMap = nodeIsMap ? baseUnary(nodeIsMap) : baseIsMap;\r\n\r\n /**\r\n * Checks if `value` is `NaN`.\r\n *\r\n * **Note:** This method is based on\r\n * [`Number.isNaN`](https://mdn.io/Number/isNaN) and is not the same as\r\n * global [`isNaN`](https://mdn.io/isNaN) which returns `true` for\r\n * `undefined` and other non-number values.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`.\r\n * @example\r\n *\r\n * _.isNaN(NaN);\r\n * // => true\r\n *\r\n * _.isNaN(new Number(NaN));\r\n * // => true\r\n *\r\n * isNaN(undefined);\r\n * // => true\r\n *\r\n * _.isNaN(undefined);\r\n * // => false\r\n */\r\n function isNaN(value) {\r\n // An `NaN` primitive is the only value that is not equal to itself.\r\n // Perform the `toStringTag` check first to avoid errors with some\r\n // ActiveX objects in IE.\r\n return isNumber(value) && value != +value;\r\n }\r\n\r\n /**\r\n * Checks if `value` is `null`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is `null`, else `false`.\r\n * @example\r\n *\r\n * _.isNull(null);\r\n * // => true\r\n *\r\n * _.isNull(void 0);\r\n * // => false\r\n */\r\n function isNull(value) {\r\n return value === null;\r\n }\r\n\r\n /**\r\n * Checks if `value` is classified as a `Number` primitive or object.\r\n *\r\n * **Note:** To exclude `Infinity`, `-Infinity`, and `NaN`, which are\r\n * classified as numbers, use the `_.isFinite` method.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a number, else `false`.\r\n * @example\r\n *\r\n * _.isNumber(3);\r\n * // => true\r\n *\r\n * _.isNumber(Number.MIN_VALUE);\r\n * // => true\r\n *\r\n * _.isNumber(Infinity);\r\n * // => true\r\n *\r\n * _.isNumber('3');\r\n * // => false\r\n */\r\n function isNumber(value) {\r\n return typeof value == 'number' ||\r\n (isObjectLike(value) && baseGetTag(value) == numberTag);\r\n }\r\n\r\n /**\r\n * Checks if `value` is a plain object, that is, an object created by the\r\n * `Object` constructor or one with a `[[Prototype]]` of `null`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.8.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a plain object, else `false`.\r\n * @example\r\n *\r\n * function Foo() {\r\n * this.a = 1;\r\n * }\r\n *\r\n * _.isPlainObject(new Foo);\r\n * // => false\r\n *\r\n * _.isPlainObject([1, 2, 3]);\r\n * // => false\r\n *\r\n * _.isPlainObject({ 'x': 0, 'y': 0 });\r\n * // => true\r\n *\r\n * _.isPlainObject(Object.create(null));\r\n * // => true\r\n */\r\n function isPlainObject(value) {\r\n if (!isObjectLike(value) || baseGetTag(value) != objectTag) {\r\n return false;\r\n }\r\n var proto = getPrototype(value);\r\n if (proto === null) {\r\n return true;\r\n }\r\n var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor;\r\n return typeof Ctor == 'function' && Ctor instanceof Ctor &&\r\n funcToString.call(Ctor) == objectCtorString;\r\n }\r\n\r\n /**\r\n * Checks if `value` is classified as a `RegExp` object.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.1.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a regexp, else `false`.\r\n * @example\r\n *\r\n * _.isRegExp(/abc/);\r\n * // => true\r\n *\r\n * _.isRegExp('/abc/');\r\n * // => false\r\n */\r\n var isRegExp = nodeIsRegExp ? baseUnary(nodeIsRegExp) : baseIsRegExp;\r\n\r\n /**\r\n * Checks if `value` is classified as a `Set` object.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.3.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a set, else `false`.\r\n * @example\r\n *\r\n * _.isSet(new Set);\r\n * // => true\r\n *\r\n * _.isSet(new WeakSet);\r\n * // => false\r\n */\r\n var isSet = nodeIsSet ? baseUnary(nodeIsSet) : baseIsSet;\r\n\r\n /**\r\n * Checks if `value` is classified as a `String` primitive or object.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a string, else `false`.\r\n * @example\r\n *\r\n * _.isString('abc');\r\n * // => true\r\n *\r\n * _.isString(1);\r\n * // => false\r\n */\r\n function isString(value) {\r\n return typeof value == 'string' ||\r\n (!isArray(value) && isObjectLike(value) && baseGetTag(value) == stringTag);\r\n }\r\n\r\n /**\r\n * Checks if `value` is classified as a `Symbol` primitive or object.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\r\n * @example\r\n *\r\n * _.isSymbol(Symbol.iterator);\r\n * // => true\r\n *\r\n * _.isSymbol('abc');\r\n * // => false\r\n */\r\n function isSymbol(value) {\r\n return typeof value == 'symbol' ||\r\n (isObjectLike(value) && baseGetTag(value) == symbolTag);\r\n }\r\n\r\n /**\r\n * Checks if `value` is classified as a typed array.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.0.0\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\r\n * @example\r\n *\r\n * _.isTypedArray(new Uint8Array);\r\n * // => true\r\n *\r\n * _.isTypedArray([]);\r\n * // => false\r\n */\r\n var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\r\n\r\n /**\r\n * Checks if `value` is `undefined`.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Lang\r\n * @param {*} value The value to check.\r\n * @returns {boolean} Returns `true` if `value` is `undefined`, else `false`.\r\n * @example\r\n *\r\n * _.isUndefined(void 0);\r\n * // => true\r\n *\r\n * _.isUndefined(null);\r\n * // => false\r\n */\r\n function isUndefined(value) {\r\n return value === undefined;\r\n }\r\n\r\n /**\r\n * Converts `value` to an array.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Lang\r\n * @param {*} value The value to convert.\r\n * @returns {Array} Returns the converted array.\r\n * @example\r\n *\r\n * _.toArray({ 'a': 1, 'b': 2 });\r\n * // => [1, 2]\r\n *\r\n * _.toArray('abc');\r\n * // => ['a', 'b', 'c']\r\n *\r\n * _.toArray(1);\r\n * // => []\r\n *\r\n * _.toArray(null);\r\n * // => []\r\n */\r\n function toArray(value) {\r\n if (!value) {\r\n return [];\r\n }\r\n if (isArrayLike(value)) {\r\n return isString(value) ? stringToArray(value) : copyArray(value);\r\n }\r\n if (symIterator && value[symIterator]) {\r\n return iteratorToArray(value[symIterator]());\r\n }\r\n var tag = getTag(value),\r\n func = tag == mapTag ? mapToArray : (tag == setTag ? setToArray : values);\r\n\r\n return func(value);\r\n }\r\n\r\n /**\r\n * Converts `value` to a finite number.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.12.0\r\n * @category Lang\r\n * @param {*} value The value to convert.\r\n * @returns {number} Returns the converted number.\r\n * @example\r\n *\r\n * _.toFinite(3.2);\r\n * // => 3.2\r\n *\r\n * _.toFinite(Number.MIN_VALUE);\r\n * // => 5e-324\r\n *\r\n * _.toFinite(Infinity);\r\n * // => 1.7976931348623157e+308\r\n *\r\n * _.toFinite('3.2');\r\n * // => 3.2\r\n */\r\n function toFinite(value) {\r\n if (!value) {\r\n return value === 0 ? value : 0;\r\n }\r\n value = toNumber(value);\r\n if (value === INFINITY || value === -INFINITY) {\r\n var sign = (value < 0 ? -1 : 1);\r\n return sign * MAX_INTEGER;\r\n }\r\n return value === value ? value : 0;\r\n }\r\n\r\n /**\r\n * Converts `value` to an integer.\r\n *\r\n * **Note:** This method is loosely based on\r\n * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Lang\r\n * @param {*} value The value to convert.\r\n * @returns {number} Returns the converted integer.\r\n * @example\r\n *\r\n * _.toInteger(3.2);\r\n * // => 3\r\n *\r\n * _.toInteger(Number.MIN_VALUE);\r\n * // => 0\r\n *\r\n * _.toInteger(Infinity);\r\n * // => 1.7976931348623157e+308\r\n *\r\n * _.toInteger('3.2');\r\n * // => 3\r\n */\r\n function toInteger(value) {\r\n var result = toFinite(value),\r\n remainder = result % 1;\r\n\r\n return result === result ? (remainder ? result - remainder : result) : 0;\r\n }\r\n\r\n /**\r\n * Converts `value` to a number.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Lang\r\n * @param {*} value The value to process.\r\n * @returns {number} Returns the number.\r\n * @example\r\n *\r\n * _.toNumber(3.2);\r\n * // => 3.2\r\n *\r\n * _.toNumber(Number.MIN_VALUE);\r\n * // => 5e-324\r\n *\r\n * _.toNumber(Infinity);\r\n * // => Infinity\r\n *\r\n * _.toNumber('3.2');\r\n * // => 3.2\r\n */\r\n function toNumber(value) {\r\n if (typeof value == 'number') {\r\n return value;\r\n }\r\n if (isSymbol(value)) {\r\n return NAN;\r\n }\r\n if (isObject(value)) {\r\n var other = typeof value.valueOf == 'function' ? value.valueOf() : value;\r\n value = isObject(other) ? (other + '') : other;\r\n }\r\n if (typeof value != 'string') {\r\n return value === 0 ? value : +value;\r\n }\r\n value = value.replace(reTrim, '');\r\n var isBinary = reIsBinary.test(value);\r\n return (isBinary || reIsOctal.test(value))\r\n ? freeParseInt(value.slice(2), isBinary ? 2 : 8)\r\n : (reIsBadHex.test(value) ? NAN : +value);\r\n }\r\n\r\n /**\r\n * Converts `value` to a plain object flattening inherited enumerable string\r\n * keyed properties of `value` to own properties of the plain object.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.0.0\r\n * @category Lang\r\n * @param {*} value The value to convert.\r\n * @returns {Object} Returns the converted plain object.\r\n * @example\r\n *\r\n * function Foo() {\r\n * this.b = 2;\r\n * }\r\n *\r\n * Foo.prototype.c = 3;\r\n *\r\n * _.assign({ 'a': 1 }, new Foo);\r\n * // => { 'a': 1, 'b': 2 }\r\n *\r\n * _.assign({ 'a': 1 }, _.toPlainObject(new Foo));\r\n * // => { 'a': 1, 'b': 2, 'c': 3 }\r\n */\r\n function toPlainObject(value) {\r\n return copyObject(value, keysIn(value));\r\n }\r\n\r\n /**\r\n * Converts `value` to a string. An empty string is returned for `null`\r\n * and `undefined` values. The sign of `-0` is preserved.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Lang\r\n * @param {*} value The value to convert.\r\n * @returns {string} Returns the converted string.\r\n * @example\r\n *\r\n * _.toString(null);\r\n * // => ''\r\n *\r\n * _.toString(-0);\r\n * // => '-0'\r\n *\r\n * _.toString([1, 2, 3]);\r\n * // => '1,2,3'\r\n */\r\n function toString(value) {\r\n return value == null ? '' : baseToString(value);\r\n }\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * This method is like `_.assign` except that it iterates over own and\r\n * inherited source properties.\r\n *\r\n * **Note:** This method mutates `object`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @alias extend\r\n * @category Object\r\n * @param {Object} object The destination object.\r\n * @param {...Object} [sources] The source objects.\r\n * @returns {Object} Returns `object`.\r\n * @see _.assign\r\n * @example\r\n *\r\n * function Foo() {\r\n * this.a = 1;\r\n * }\r\n *\r\n * function Bar() {\r\n * this.c = 3;\r\n * }\r\n *\r\n * Foo.prototype.b = 2;\r\n * Bar.prototype.d = 4;\r\n *\r\n * _.assignIn({ 'a': 0 }, new Foo, new Bar);\r\n * // => { 'a': 1, 'b': 2, 'c': 3, 'd': 4 }\r\n */\r\n var assignIn = createAssigner(function(object, source) {\r\n copyObject(source, keysIn(source), object);\r\n });\r\n\r\n /**\r\n * Creates an object that inherits from the `prototype` object. If a\r\n * `properties` object is given, its own enumerable string keyed properties\r\n * are assigned to the created object.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 2.3.0\r\n * @category Object\r\n * @param {Object} prototype The object to inherit from.\r\n * @param {Object} [properties] The properties to assign to the object.\r\n * @returns {Object} Returns the new object.\r\n * @example\r\n *\r\n * function Shape() {\r\n * this.x = 0;\r\n * this.y = 0;\r\n * }\r\n *\r\n * function Circle() {\r\n * Shape.call(this);\r\n * }\r\n *\r\n * Circle.prototype = _.create(Shape.prototype, {\r\n * 'constructor': Circle\r\n * });\r\n *\r\n * var circle = new Circle;\r\n * circle instanceof Circle;\r\n * // => true\r\n *\r\n * circle instanceof Shape;\r\n * // => true\r\n */\r\n function create(prototype, properties) {\r\n var result = baseCreate(prototype);\r\n return properties == null ? result : baseAssign(result, properties);\r\n }\r\n\r\n /**\r\n * Assigns own and inherited enumerable string keyed properties of source\r\n * objects to the destination object for all destination properties that\r\n * resolve to `undefined`. Source objects are applied from left to right.\r\n * Once a property is set, additional values of the same property are ignored.\r\n *\r\n * **Note:** This method mutates `object`.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Object\r\n * @param {Object} object The destination object.\r\n * @param {...Object} [sources] The source objects.\r\n * @returns {Object} Returns `object`.\r\n * @see _.defaultsDeep\r\n * @example\r\n *\r\n * _.defaults({ 'a': 1 }, { 'b': 2 }, { 'a': 3 });\r\n * // => { 'a': 1, 'b': 2 }\r\n */\r\n var defaults = baseRest(function(object, sources) {\r\n object = Object(object);\r\n\r\n var index = -1;\r\n var length = sources.length;\r\n var guard = length > 2 ? sources[2] : undefined;\r\n\r\n if (guard && isIterateeCall(sources[0], sources[1], guard)) {\r\n length = 1;\r\n }\r\n\r\n while (++index < length) {\r\n var source = sources[index];\r\n var props = keysIn(source);\r\n var propsIndex = -1;\r\n var propsLength = props.length;\r\n\r\n while (++propsIndex < propsLength) {\r\n var key = props[propsIndex];\r\n var value = object[key];\r\n\r\n if (value === undefined ||\r\n (eq(value, objectProto[key]) && !hasOwnProperty.call(object, key))) {\r\n object[key] = source[key];\r\n }\r\n }\r\n }\r\n\r\n return object;\r\n });\r\n\r\n /**\r\n * This method is like `_.defaults` except that it recursively assigns\r\n * default properties.\r\n *\r\n * **Note:** This method mutates `object`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.10.0\r\n * @category Object\r\n * @param {Object} object The destination object.\r\n * @param {...Object} [sources] The source objects.\r\n * @returns {Object} Returns `object`.\r\n * @see _.defaults\r\n * @example\r\n *\r\n * _.defaultsDeep({ 'a': { 'b': 2 } }, { 'a': { 'b': 1, 'c': 3 } });\r\n * // => { 'a': { 'b': 2, 'c': 3 } }\r\n */\r\n var defaultsDeep = baseRest(function(args) {\r\n args.push(undefined, customDefaultsMerge);\r\n return apply(mergeWith, undefined, args);\r\n });\r\n\r\n /**\r\n * This method is like `_.find` except that it returns the key of the first\r\n * element `predicate` returns truthy for instead of the element itself.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 1.1.0\r\n * @category Object\r\n * @param {Object} object The object to inspect.\r\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\r\n * @returns {string|undefined} Returns the key of the matched element,\r\n * else `undefined`.\r\n * @example\r\n *\r\n * var users = {\r\n * 'barney': { 'age': 36, 'active': true },\r\n * 'fred': { 'age': 40, 'active': false },\r\n * 'pebbles': { 'age': 1, 'active': true }\r\n * };\r\n *\r\n * _.findKey(users, function(o) { return o.age < 40; });\r\n * // => 'barney' (iteration order is not guaranteed)\r\n *\r\n * // The `_.matches` iteratee shorthand.\r\n * _.findKey(users, { 'age': 1, 'active': true });\r\n * // => 'pebbles'\r\n *\r\n * // The `_.matchesProperty` iteratee shorthand.\r\n * _.findKey(users, ['active', false]);\r\n * // => 'fred'\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.findKey(users, 'active');\r\n * // => 'barney'\r\n */\r\n function findKey(object, predicate) {\r\n return baseFindKey(object, baseIteratee(predicate, 3), baseForOwn);\r\n }\r\n\r\n /**\r\n * This method is like `_.findKey` except that it iterates over elements of\r\n * a collection in the opposite order.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 2.0.0\r\n * @category Object\r\n * @param {Object} object The object to inspect.\r\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\r\n * @returns {string|undefined} Returns the key of the matched element,\r\n * else `undefined`.\r\n * @example\r\n *\r\n * var users = {\r\n * 'barney': { 'age': 36, 'active': true },\r\n * 'fred': { 'age': 40, 'active': false },\r\n * 'pebbles': { 'age': 1, 'active': true }\r\n * };\r\n *\r\n * _.findLastKey(users, function(o) { return o.age < 40; });\r\n * // => returns 'pebbles' assuming `_.findKey` returns 'barney'\r\n *\r\n * // The `_.matches` iteratee shorthand.\r\n * _.findLastKey(users, { 'age': 36, 'active': true });\r\n * // => 'barney'\r\n *\r\n * // The `_.matchesProperty` iteratee shorthand.\r\n * _.findLastKey(users, ['active', false]);\r\n * // => 'fred'\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.findLastKey(users, 'active');\r\n * // => 'pebbles'\r\n */\r\n function findLastKey(object, predicate) {\r\n return baseFindKey(object, baseIteratee(predicate, 3), baseForOwnRight);\r\n }\r\n\r\n /**\r\n * Gets the value at `path` of `object`. If the resolved value is\r\n * `undefined`, the `defaultValue` is returned in its place.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.7.0\r\n * @category Object\r\n * @param {Object} object The object to query.\r\n * @param {Array|string} path The path of the property to get.\r\n * @param {*} [defaultValue] The value returned for `undefined` resolved values.\r\n * @returns {*} Returns the resolved value.\r\n * @example\r\n *\r\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\r\n *\r\n * _.get(object, 'a[0].b.c');\r\n * // => 3\r\n *\r\n * _.get(object, ['a', '0', 'b', 'c']);\r\n * // => 3\r\n *\r\n * _.get(object, 'a.b.c', 'default');\r\n * // => 'default'\r\n */\r\n function get(object, path, defaultValue) {\r\n var result = object == null ? undefined : baseGet(object, path);\r\n return result === undefined ? defaultValue : result;\r\n }\r\n\r\n /**\r\n * Checks if `path` is a direct property of `object`.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Object\r\n * @param {Object} object The object to query.\r\n * @param {Array|string} path The path to check.\r\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\r\n * @example\r\n *\r\n * var object = { 'a': { 'b': 2 } };\r\n * var other = _.create({ 'a': _.create({ 'b': 2 }) });\r\n *\r\n * _.has(object, 'a');\r\n * // => true\r\n *\r\n * _.has(object, 'a.b');\r\n * // => true\r\n *\r\n * _.has(object, ['a', 'b']);\r\n * // => true\r\n *\r\n * _.has(other, 'a');\r\n * // => false\r\n */\r\n function has(object, path) {\r\n return object != null && hasPath(object, path, baseHas);\r\n }\r\n\r\n /**\r\n * Checks if `path` is a direct or inherited property of `object`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Object\r\n * @param {Object} object The object to query.\r\n * @param {Array|string} path The path to check.\r\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\r\n * @example\r\n *\r\n * var object = _.create({ 'a': _.create({ 'b': 2 }) });\r\n *\r\n * _.hasIn(object, 'a');\r\n * // => true\r\n *\r\n * _.hasIn(object, 'a.b');\r\n * // => true\r\n *\r\n * _.hasIn(object, ['a', 'b']);\r\n * // => true\r\n *\r\n * _.hasIn(object, 'b');\r\n * // => false\r\n */\r\n function hasIn(object, path) {\r\n return object != null && hasPath(object, path, baseHasIn);\r\n }\r\n\r\n /**\r\n * Creates an object composed of the inverted keys and values of `object`.\r\n * If `object` contains duplicate values, subsequent values overwrite\r\n * property assignments of previous values.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.7.0\r\n * @category Object\r\n * @param {Object} object The object to invert.\r\n * @returns {Object} Returns the new inverted object.\r\n * @example\r\n *\r\n * var object = { 'a': 1, 'b': 2, 'c': 1 };\r\n *\r\n * _.invert(object);\r\n * // => { '1': 'c', '2': 'b' }\r\n */\r\n var invert = createInverter(function(result, value, key) {\r\n if (value != null &&\r\n typeof value.toString != 'function') {\r\n value = nativeObjectToString.call(value);\r\n }\r\n\r\n result[value] = key;\r\n }, constant(identity));\r\n\r\n /**\r\n * This method is like `_.invert` except that the inverted object is generated\r\n * from the results of running each element of `object` thru `iteratee`. The\r\n * corresponding inverted value of each inverted key is an array of keys\r\n * responsible for generating the inverted value. The iteratee is invoked\r\n * with one argument: (value).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.1.0\r\n * @category Object\r\n * @param {Object} object The object to invert.\r\n * @param {Function} [iteratee=_.identity] The iteratee invoked per element.\r\n * @returns {Object} Returns the new inverted object.\r\n * @example\r\n *\r\n * var object = { 'a': 1, 'b': 2, 'c': 1 };\r\n *\r\n * _.invertBy(object);\r\n * // => { '1': ['a', 'c'], '2': ['b'] }\r\n *\r\n * _.invertBy(object, function(value) {\r\n * return 'group' + value;\r\n * });\r\n * // => { 'group1': ['a', 'c'], 'group2': ['b'] }\r\n */\r\n var invertBy = createInverter(function(result, value, key) {\r\n if (value != null &&\r\n typeof value.toString != 'function') {\r\n value = nativeObjectToString.call(value);\r\n }\r\n\r\n if (hasOwnProperty.call(result, value)) {\r\n result[value].push(key);\r\n } else {\r\n result[value] = [key];\r\n }\r\n }, baseIteratee);\r\n\r\n /**\r\n * Creates an array of the own enumerable property names of `object`.\r\n *\r\n * **Note:** Non-object values are coerced to objects. See the\r\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\r\n * for more details.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Object\r\n * @param {Object} object The object to query.\r\n * @returns {Array} Returns the array of property names.\r\n * @example\r\n *\r\n * function Foo() {\r\n * this.a = 1;\r\n * this.b = 2;\r\n * }\r\n *\r\n * Foo.prototype.c = 3;\r\n *\r\n * _.keys(new Foo);\r\n * // => ['a', 'b'] (iteration order is not guaranteed)\r\n *\r\n * _.keys('hi');\r\n * // => ['0', '1']\r\n */\r\n function keys(object) {\r\n return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\r\n }\r\n\r\n /**\r\n * Creates an array of the own and inherited enumerable property names of `object`.\r\n *\r\n * **Note:** Non-object values are coerced to objects.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.0.0\r\n * @category Object\r\n * @param {Object} object The object to query.\r\n * @returns {Array} Returns the array of property names.\r\n * @example\r\n *\r\n * function Foo() {\r\n * this.a = 1;\r\n * this.b = 2;\r\n * }\r\n *\r\n * Foo.prototype.c = 3;\r\n *\r\n * _.keysIn(new Foo);\r\n * // => ['a', 'b', 'c'] (iteration order is not guaranteed)\r\n */\r\n function keysIn(object) {\r\n return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object);\r\n }\r\n\r\n /**\r\n * This method is like `_.assign` except that it recursively merges own and\r\n * inherited enumerable string keyed properties of source objects into the\r\n * destination object. Source properties that resolve to `undefined` are\r\n * skipped if a destination value exists. Array and plain object properties\r\n * are merged recursively. Other objects and value types are overridden by\r\n * assignment. Source objects are applied from left to right. Subsequent\r\n * sources overwrite property assignments of previous sources.\r\n *\r\n * **Note:** This method mutates `object`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.5.0\r\n * @category Object\r\n * @param {Object} object The destination object.\r\n * @param {...Object} [sources] The source objects.\r\n * @returns {Object} Returns `object`.\r\n * @example\r\n *\r\n * var object = {\r\n * 'a': [{ 'b': 2 }, { 'd': 4 }]\r\n * };\r\n *\r\n * var other = {\r\n * 'a': [{ 'c': 3 }, { 'e': 5 }]\r\n * };\r\n *\r\n * _.merge(object, other);\r\n * // => { 'a': [{ 'b': 2, 'c': 3 }, { 'd': 4, 'e': 5 }] }\r\n */\r\n var merge = createAssigner(function(object, source, srcIndex) {\r\n baseMerge(object, source, srcIndex);\r\n });\r\n\r\n /**\r\n * This method is like `_.merge` except that it accepts `customizer` which\r\n * is invoked to produce the merged values of the destination and source\r\n * properties. If `customizer` returns `undefined`, merging is handled by the\r\n * method instead. The `customizer` is invoked with six arguments:\r\n * (objValue, srcValue, key, object, source, stack).\r\n *\r\n * **Note:** This method mutates `object`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Object\r\n * @param {Object} object The destination object.\r\n * @param {...Object} sources The source objects.\r\n * @param {Function} customizer The function to customize assigned values.\r\n * @returns {Object} Returns `object`.\r\n * @example\r\n *\r\n * function customizer(objValue, srcValue) {\r\n * if (_.isArray(objValue)) {\r\n * return objValue.concat(srcValue);\r\n * }\r\n * }\r\n *\r\n * var object = { 'a': [1], 'b': [2] };\r\n * var other = { 'a': [3], 'b': [4] };\r\n *\r\n * _.mergeWith(object, other, customizer);\r\n * // => { 'a': [1, 3], 'b': [2, 4] }\r\n */\r\n var mergeWith = createAssigner(function(object, source, srcIndex, customizer) {\r\n baseMerge(object, source, srcIndex, customizer);\r\n });\r\n\r\n /**\r\n * The opposite of `_.pick`; this method creates an object composed of the\r\n * own and inherited enumerable property paths of `object` that are not omitted.\r\n *\r\n * **Note:** This method is considerably slower than `_.pick`.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Object\r\n * @param {Object} object The source object.\r\n * @param {...(string|string[])} [paths] The property paths to omit.\r\n * @returns {Object} Returns the new object.\r\n * @example\r\n *\r\n * var object = { 'a': 1, 'b': '2', 'c': 3 };\r\n *\r\n * _.omit(object, ['a', 'c']);\r\n * // => { 'b': '2' }\r\n */\r\n var omit = flatRest(function(object, paths) {\r\n var result = {};\r\n if (object == null) {\r\n return result;\r\n }\r\n var isDeep = false;\r\n paths = arrayMap(paths, function(path) {\r\n path = castPath(path, object);\r\n isDeep || (isDeep = path.length > 1);\r\n return path;\r\n });\r\n copyObject(object, getAllKeysIn(object), result);\r\n if (isDeep) {\r\n result = baseClone(result, CLONE_DEEP_FLAG | CLONE_FLAT_FLAG | CLONE_SYMBOLS_FLAG, customOmitClone);\r\n }\r\n var length = paths.length;\r\n while (length--) {\r\n baseUnset(result, paths[length]);\r\n }\r\n return result;\r\n });\r\n\r\n /**\r\n * The opposite of `_.pickBy`; this method creates an object composed of\r\n * the own and inherited enumerable string keyed properties of `object` that\r\n * `predicate` doesn't return truthy for. The predicate is invoked with two\r\n * arguments: (value, key).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Object\r\n * @param {Object} object The source object.\r\n * @param {Function} [predicate=_.identity] The function invoked per property.\r\n * @returns {Object} Returns the new object.\r\n * @example\r\n *\r\n * var object = { 'a': 1, 'b': '2', 'c': 3 };\r\n *\r\n * _.omitBy(object, _.isNumber);\r\n * // => { 'b': '2' }\r\n */\r\n function omitBy(object, predicate) {\r\n return pickBy(object, negate(baseIteratee(predicate)));\r\n }\r\n\r\n /**\r\n * Creates an object composed of the picked `object` properties.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Object\r\n * @param {Object} object The source object.\r\n * @param {...(string|string[])} [paths] The property paths to pick.\r\n * @returns {Object} Returns the new object.\r\n * @example\r\n *\r\n * var object = { 'a': 1, 'b': '2', 'c': 3 };\r\n *\r\n * _.pick(object, ['a', 'c']);\r\n * // => { 'a': 1, 'c': 3 }\r\n */\r\n var pick = flatRest(function(object, paths) {\r\n return object == null ? {} : basePick(object, paths);\r\n });\r\n\r\n /**\r\n * Creates an object composed of the `object` properties `predicate` returns\r\n * truthy for. The predicate is invoked with two arguments: (value, key).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Object\r\n * @param {Object} object The source object.\r\n * @param {Function} [predicate=_.identity] The function invoked per property.\r\n * @returns {Object} Returns the new object.\r\n * @example\r\n *\r\n * var object = { 'a': 1, 'b': '2', 'c': 3 };\r\n *\r\n * _.pickBy(object, _.isNumber);\r\n * // => { 'a': 1, 'c': 3 }\r\n */\r\n function pickBy(object, predicate) {\r\n if (object == null) {\r\n return {};\r\n }\r\n var props = arrayMap(getAllKeysIn(object), function(prop) {\r\n return [prop];\r\n });\r\n predicate = baseIteratee(predicate);\r\n return basePickBy(object, props, function(value, path) {\r\n return predicate(value, path[0]);\r\n });\r\n }\r\n\r\n /**\r\n * This method is like `_.get` except that if the resolved value is a\r\n * function it's invoked with the `this` binding of its parent object and\r\n * its result is returned.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Object\r\n * @param {Object} object The object to query.\r\n * @param {Array|string} path The path of the property to resolve.\r\n * @param {*} [defaultValue] The value returned for `undefined` resolved values.\r\n * @returns {*} Returns the resolved value.\r\n * @example\r\n *\r\n * var object = { 'a': [{ 'b': { 'c1': 3, 'c2': _.constant(4) } }] };\r\n *\r\n * _.result(object, 'a[0].b.c1');\r\n * // => 3\r\n *\r\n * _.result(object, 'a[0].b.c2');\r\n * // => 4\r\n *\r\n * _.result(object, 'a[0].b.c3', 'default');\r\n * // => 'default'\r\n *\r\n * _.result(object, 'a[0].b.c3', _.constant('default'));\r\n * // => 'default'\r\n */\r\n function result(object, path, defaultValue) {\r\n path = castPath(path, object);\r\n\r\n var index = -1,\r\n length = path.length;\r\n\r\n // Ensure the loop is entered when path is empty.\r\n if (!length) {\r\n length = 1;\r\n object = undefined;\r\n }\r\n while (++index < length) {\r\n var value = object == null ? undefined : object[toKey(path[index])];\r\n if (value === undefined) {\r\n index = length;\r\n value = defaultValue;\r\n }\r\n object = isFunction(value) ? value.call(object) : value;\r\n }\r\n return object;\r\n }\r\n\r\n /**\r\n * Sets the value at `path` of `object`. If a portion of `path` doesn't exist,\r\n * it's created. Arrays are created for missing index properties while objects\r\n * are created for all other missing properties. Use `_.setWith` to customize\r\n * `path` creation.\r\n *\r\n * **Note:** This method mutates `object`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.7.0\r\n * @category Object\r\n * @param {Object} object The object to modify.\r\n * @param {Array|string} path The path of the property to set.\r\n * @param {*} value The value to set.\r\n * @returns {Object} Returns `object`.\r\n * @example\r\n *\r\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\r\n *\r\n * _.set(object, 'a[0].b.c', 4);\r\n * console.log(object.a[0].b.c);\r\n * // => 4\r\n *\r\n * _.set(object, ['x', '0', 'y', 'z'], 5);\r\n * console.log(object.x[0].y.z);\r\n * // => 5\r\n */\r\n function set(object, path, value) {\r\n return object == null ? object : baseSet(object, path, value);\r\n }\r\n\r\n /**\r\n * Creates an array of the own enumerable string keyed property values of `object`.\r\n *\r\n * **Note:** Non-object values are coerced to objects.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Object\r\n * @param {Object} object The object to query.\r\n * @returns {Array} Returns the array of property values.\r\n * @example\r\n *\r\n * function Foo() {\r\n * this.a = 1;\r\n * this.b = 2;\r\n * }\r\n *\r\n * Foo.prototype.c = 3;\r\n *\r\n * _.values(new Foo);\r\n * // => [1, 2] (iteration order is not guaranteed)\r\n *\r\n * _.values('hi');\r\n * // => ['h', 'i']\r\n */\r\n function values(object) {\r\n return object == null ? [] : baseValues(object, keys(object));\r\n }\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Clamps `number` within the inclusive `lower` and `upper` bounds.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.0.0\r\n * @category Number\r\n * @param {number} number The number to clamp.\r\n * @param {number} [lower] The lower bound.\r\n * @param {number} upper The upper bound.\r\n * @returns {number} Returns the clamped number.\r\n * @example\r\n *\r\n * _.clamp(-10, -5, 5);\r\n * // => -5\r\n *\r\n * _.clamp(10, -5, 5);\r\n * // => 5\r\n */\r\n function clamp(number, lower, upper) {\r\n if (upper === undefined) {\r\n upper = lower;\r\n lower = undefined;\r\n }\r\n if (upper !== undefined) {\r\n upper = toNumber(upper);\r\n upper = upper === upper ? upper : 0;\r\n }\r\n if (lower !== undefined) {\r\n lower = toNumber(lower);\r\n lower = lower === lower ? lower : 0;\r\n }\r\n return baseClamp(toNumber(number), lower, upper);\r\n }\r\n\r\n /**\r\n * Produces a random number between the inclusive `lower` and `upper` bounds.\r\n * If only one argument is provided a number between `0` and the given number\r\n * is returned. If `floating` is `true`, or either `lower` or `upper` are\r\n * floats, a floating-point number is returned instead of an integer.\r\n *\r\n * **Note:** JavaScript follows the IEEE-754 standard for resolving\r\n * floating-point values which can produce unexpected results.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.7.0\r\n * @category Number\r\n * @param {number} [lower=0] The lower bound.\r\n * @param {number} [upper=1] The upper bound.\r\n * @param {boolean} [floating] Specify returning a floating-point number.\r\n * @returns {number} Returns the random number.\r\n * @example\r\n *\r\n * _.random(0, 5);\r\n * // => an integer between 0 and 5\r\n *\r\n * _.random(5);\r\n * // => also an integer between 0 and 5\r\n *\r\n * _.random(5, true);\r\n * // => a floating-point number between 0 and 5\r\n *\r\n * _.random(1.2, 5.2);\r\n * // => a floating-point number between 1.2 and 5.2\r\n */\r\n function random(lower, upper, floating) {\r\n if (floating && typeof floating != 'boolean' && isIterateeCall(lower, upper, floating)) {\r\n upper = floating = undefined;\r\n }\r\n if (floating === undefined) {\r\n if (typeof upper == 'boolean') {\r\n floating = upper;\r\n upper = undefined;\r\n }\r\n else if (typeof lower == 'boolean') {\r\n floating = lower;\r\n lower = undefined;\r\n }\r\n }\r\n if (lower === undefined && upper === undefined) {\r\n lower = 0;\r\n upper = 1;\r\n }\r\n else {\r\n lower = toFinite(lower);\r\n if (upper === undefined) {\r\n upper = lower;\r\n lower = 0;\r\n } else {\r\n upper = toFinite(upper);\r\n }\r\n }\r\n if (lower > upper) {\r\n var temp = lower;\r\n lower = upper;\r\n upper = temp;\r\n }\r\n if (floating || lower % 1 || upper % 1) {\r\n var rand = nativeRandom();\r\n return nativeMin(lower + (rand * (upper - lower + freeParseFloat('1e-' + ((rand + '').length - 1)))), upper);\r\n }\r\n return baseRandom(lower, upper);\r\n }\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Converts the characters \"&\", \"<\", \">\", '\"', and \"'\" in `string` to their\r\n * corresponding HTML entities.\r\n *\r\n * **Note:** No other characters are escaped. To escape additional\r\n * characters use a third-party library like [_he_](https://mths.be/he).\r\n *\r\n * Though the \">\" character is escaped for symmetry, characters like\r\n * \">\" and \"/\" don't need escaping in HTML and have no special meaning\r\n * unless they're part of a tag or unquoted attribute value. See\r\n * [Mathias Bynens's article](https://mathiasbynens.be/notes/ambiguous-ampersands)\r\n * (under \"semi-related fun fact\") for more details.\r\n *\r\n * When working with HTML you should always\r\n * [quote attribute values](http://wonko.com/post/html-escaping) to reduce\r\n * XSS vectors.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category String\r\n * @param {string} [string=''] The string to escape.\r\n * @returns {string} Returns the escaped string.\r\n * @example\r\n *\r\n * _.escape('fred, barney, & pebbles');\r\n * // => 'fred, barney, &amp; pebbles'\r\n */\r\n function escape(string) {\r\n string = toString(string);\r\n return (string && reHasUnescapedHtml.test(string))\r\n ? string.replace(reUnescapedHtml, escapeHtmlChar)\r\n : string;\r\n }\r\n\r\n /**\r\n * Removes leading and trailing whitespace or specified characters from `string`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.0.0\r\n * @category String\r\n * @param {string} [string=''] The string to trim.\r\n * @param {string} [chars=whitespace] The characters to trim.\r\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\r\n * @returns {string} Returns the trimmed string.\r\n * @example\r\n *\r\n * _.trim(' abc ');\r\n * // => 'abc'\r\n *\r\n * _.trim('-_-abc-_-', '_-');\r\n * // => 'abc'\r\n *\r\n * _.map([' foo ', ' bar '], _.trim);\r\n * // => ['foo', 'bar']\r\n */\r\n function trim(string, chars, guard) {\r\n string = toString(string);\r\n if (string && (guard || chars === undefined)) {\r\n return string.replace(reTrim, '');\r\n }\r\n if (!string || !(chars = baseToString(chars))) {\r\n return string;\r\n }\r\n var strSymbols = stringToArray(string),\r\n chrSymbols = stringToArray(chars),\r\n start = charsStartIndex(strSymbols, chrSymbols),\r\n end = charsEndIndex(strSymbols, chrSymbols) + 1;\r\n\r\n return castSlice(strSymbols, start, end).join('');\r\n }\r\n\r\n /**\r\n * The inverse of `_.escape`; this method converts the HTML entities\r\n * `&amp;`, `&lt;`, `&gt;`, `&quot;`, and `&#39;` in `string` to\r\n * their corresponding characters.\r\n *\r\n * **Note:** No other HTML entities are unescaped. To unescape additional\r\n * HTML entities use a third-party library like [_he_](https://mths.be/he).\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 0.6.0\r\n * @category String\r\n * @param {string} [string=''] The string to unescape.\r\n * @returns {string} Returns the unescaped string.\r\n * @example\r\n *\r\n * _.unescape('fred, barney, &amp; pebbles');\r\n * // => 'fred, barney, & pebbles'\r\n */\r\n function unescape(string) {\r\n string = toString(string);\r\n return (string && reHasEscapedHtml.test(string))\r\n ? string.replace(reEscapedHtml, unescapeHtmlChar)\r\n : string;\r\n }\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Creates a function that returns `value`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 2.4.0\r\n * @category Util\r\n * @param {*} value The value to return from the new function.\r\n * @returns {Function} Returns the new constant function.\r\n * @example\r\n *\r\n * var objects = _.times(2, _.constant({ 'a': 1 }));\r\n *\r\n * console.log(objects);\r\n * // => [{ 'a': 1 }, { 'a': 1 }]\r\n *\r\n * console.log(objects[0] === objects[1]);\r\n * // => true\r\n */\r\n function constant(value) {\r\n return function() {\r\n return value;\r\n };\r\n }\r\n\r\n /**\r\n * This method returns the first argument it receives.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Util\r\n * @param {*} value Any value.\r\n * @returns {*} Returns `value`.\r\n * @example\r\n *\r\n * var object = { 'a': 1 };\r\n *\r\n * console.log(_.identity(object) === object);\r\n * // => true\r\n */\r\n function identity(value) {\r\n return value;\r\n }\r\n\r\n /**\r\n * Creates a function that invokes `func` with the arguments of the created\r\n * function. If `func` is a property name, the created function returns the\r\n * property value for a given element. If `func` is an array or object, the\r\n * created function returns `true` for elements that contain the equivalent\r\n * source properties, otherwise it returns `false`.\r\n *\r\n * @static\r\n * @since 4.0.0\r\n * @memberOf _\r\n * @category Util\r\n * @param {*} [func=_.identity] The value to convert to a callback.\r\n * @returns {Function} Returns the callback.\r\n * @example\r\n *\r\n * var users = [\r\n * { 'user': 'barney', 'age': 36, 'active': true },\r\n * { 'user': 'fred', 'age': 40, 'active': false }\r\n * ];\r\n *\r\n * // The `_.matches` iteratee shorthand.\r\n * _.filter(users, _.iteratee({ 'user': 'barney', 'active': true }));\r\n * // => [{ 'user': 'barney', 'age': 36, 'active': true }]\r\n *\r\n * // The `_.matchesProperty` iteratee shorthand.\r\n * _.filter(users, _.iteratee(['user', 'fred']));\r\n * // => [{ 'user': 'fred', 'age': 40 }]\r\n *\r\n * // The `_.property` iteratee shorthand.\r\n * _.map(users, _.iteratee('user'));\r\n * // => ['barney', 'fred']\r\n *\r\n * // Create custom iteratee shorthands.\r\n * _.iteratee = _.wrap(_.iteratee, function(iteratee, func) {\r\n * return !_.isRegExp(func) ? iteratee(func) : function(string) {\r\n * return func.test(string);\r\n * };\r\n * });\r\n *\r\n * _.filter(['abc', 'def'], /ef/);\r\n * // => ['def']\r\n */\r\n function iteratee(func) {\r\n return baseIteratee(typeof func == 'function' ? func : baseClone(func, CLONE_DEEP_FLAG));\r\n }\r\n\r\n /**\r\n * Creates a function that performs a partial deep comparison between a given\r\n * object and `source`, returning `true` if the given object has equivalent\r\n * property values, else `false`.\r\n *\r\n * **Note:** The created function is equivalent to `_.isMatch` with `source`\r\n * partially applied.\r\n *\r\n * Partial comparisons will match empty array and empty object `source`\r\n * values against any array or object value, respectively. See `_.isEqual`\r\n * for a list of supported value comparisons.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 3.0.0\r\n * @category Util\r\n * @param {Object} source The object of property values to match.\r\n * @returns {Function} Returns the new spec function.\r\n * @example\r\n *\r\n * var objects = [\r\n * { 'a': 1, 'b': 2, 'c': 3 },\r\n * { 'a': 4, 'b': 5, 'c': 6 }\r\n * ];\r\n *\r\n * _.filter(objects, _.matches({ 'a': 4, 'c': 6 }));\r\n * // => [{ 'a': 4, 'b': 5, 'c': 6 }]\r\n */\r\n function matches(source) {\r\n return baseMatches(baseClone(source, CLONE_DEEP_FLAG));\r\n }\r\n\r\n /**\r\n * Adds all own enumerable string keyed function properties of a source\r\n * object to the destination object. If `object` is a function, then methods\r\n * are added to its prototype as well.\r\n *\r\n * **Note:** Use `_.runInContext` to create a pristine `lodash` function to\r\n * avoid conflicts caused by modifying the original.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Util\r\n * @param {Function|Object} [object=lodash] The destination object.\r\n * @param {Object} source The object of functions to add.\r\n * @param {Object} [options={}] The options object.\r\n * @param {boolean} [options.chain=true] Specify whether mixins are chainable.\r\n * @returns {Function|Object} Returns `object`.\r\n * @example\r\n *\r\n * function vowels(string) {\r\n * return _.filter(string, function(v) {\r\n * return /[aeiou]/i.test(v);\r\n * });\r\n * }\r\n *\r\n * _.mixin({ 'vowels': vowels });\r\n * _.vowels('fred');\r\n * // => ['e']\r\n *\r\n * _('fred').vowels().value();\r\n * // => ['e']\r\n *\r\n * _.mixin({ 'vowels': vowels }, { 'chain': false });\r\n * _('fred').vowels();\r\n * // => ['e']\r\n */\r\n function mixin(object, source, options) {\r\n var props = keys(source),\r\n methodNames = baseFunctions(source, props);\r\n\r\n if (options == null &&\r\n !(isObject(source) && (methodNames.length || !props.length))) {\r\n options = source;\r\n source = object;\r\n object = this;\r\n methodNames = baseFunctions(source, keys(source));\r\n }\r\n var chain = !(isObject(options) && 'chain' in options) || !!options.chain,\r\n isFunc = isFunction(object);\r\n\r\n arrayEach(methodNames, function(methodName) {\r\n var func = source[methodName];\r\n object[methodName] = func;\r\n if (isFunc) {\r\n object.prototype[methodName] = function() {\r\n var chainAll = this.__chain__;\r\n if (chain || chainAll) {\r\n var result = object(this.__wrapped__),\r\n actions = result.__actions__ = copyArray(this.__actions__);\r\n\r\n actions.push({ 'func': func, 'args': arguments, 'thisArg': object });\r\n result.__chain__ = chainAll;\r\n return result;\r\n }\r\n return func.apply(object, arrayPush([this.value()], arguments));\r\n };\r\n }\r\n });\r\n\r\n return object;\r\n }\r\n\r\n /**\r\n * Reverts the `_` variable to its previous value and returns a reference to\r\n * the `lodash` function.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Util\r\n * @returns {Function} Returns the `lodash` function.\r\n * @example\r\n *\r\n * var lodash = _.noConflict();\r\n */\r\n function noConflict() {\r\n if (root._ === this) {\r\n root._ = oldDash;\r\n }\r\n return this;\r\n }\r\n\r\n /**\r\n * This method returns `undefined`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 2.3.0\r\n * @category Util\r\n * @example\r\n *\r\n * _.times(2, _.noop);\r\n * // => [undefined, undefined]\r\n */\r\n function noop() {\r\n // No operation performed.\r\n }\r\n\r\n /**\r\n * Creates a function that returns the value at `path` of a given object.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 2.4.0\r\n * @category Util\r\n * @param {Array|string} path The path of the property to get.\r\n * @returns {Function} Returns the new accessor function.\r\n * @example\r\n *\r\n * var objects = [\r\n * { 'a': { 'b': 2 } },\r\n * { 'a': { 'b': 1 } }\r\n * ];\r\n *\r\n * _.map(objects, _.property('a.b'));\r\n * // => [2, 1]\r\n *\r\n * _.map(_.sortBy(objects, _.property(['a', 'b'])), 'a.b');\r\n * // => [1, 2]\r\n */\r\n function property(path) {\r\n return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);\r\n }\r\n\r\n /**\r\n * Creates an array of numbers (positive and/or negative) progressing from\r\n * `start` up to, but not including, `end`. A step of `-1` is used if a negative\r\n * `start` is specified without an `end` or `step`. If `end` is not specified,\r\n * it's set to `start` with `start` then set to `0`.\r\n *\r\n * **Note:** JavaScript follows the IEEE-754 standard for resolving\r\n * floating-point values which can produce unexpected results.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Util\r\n * @param {number} [start=0] The start of the range.\r\n * @param {number} end The end of the range.\r\n * @param {number} [step=1] The value to increment or decrement by.\r\n * @returns {Array} Returns the range of numbers.\r\n * @see _.inRange, _.rangeRight\r\n * @example\r\n *\r\n * _.range(4);\r\n * // => [0, 1, 2, 3]\r\n *\r\n * _.range(-4);\r\n * // => [0, -1, -2, -3]\r\n *\r\n * _.range(1, 5);\r\n * // => [1, 2, 3, 4]\r\n *\r\n * _.range(0, 20, 5);\r\n * // => [0, 5, 10, 15]\r\n *\r\n * _.range(0, -4, -1);\r\n * // => [0, -1, -2, -3]\r\n *\r\n * _.range(1, 4, 0);\r\n * // => [1, 1, 1]\r\n *\r\n * _.range(0);\r\n * // => []\r\n */\r\n var range = createRange();\r\n\r\n /**\r\n * This method returns a new empty array.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.13.0\r\n * @category Util\r\n * @returns {Array} Returns the new empty array.\r\n * @example\r\n *\r\n * var arrays = _.times(2, _.stubArray);\r\n *\r\n * console.log(arrays);\r\n * // => [[], []]\r\n *\r\n * console.log(arrays[0] === arrays[1]);\r\n * // => false\r\n */\r\n function stubArray() {\r\n return [];\r\n }\r\n\r\n /**\r\n * This method returns `false`.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @since 4.13.0\r\n * @category Util\r\n * @returns {boolean} Returns `false`.\r\n * @example\r\n *\r\n * _.times(2, _.stubFalse);\r\n * // => [false, false]\r\n */\r\n function stubFalse() {\r\n return false;\r\n }\r\n\r\n /**\r\n * Generates a unique ID. If `prefix` is given, the ID is appended to it.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Util\r\n * @param {string} [prefix=''] The value to prefix the ID with.\r\n * @returns {string} Returns the unique ID.\r\n * @example\r\n *\r\n * _.uniqueId('contact_');\r\n * // => 'contact_104'\r\n *\r\n * _.uniqueId();\r\n * // => '105'\r\n */\r\n function uniqueId(prefix) {\r\n var id = ++idCounter;\r\n return toString(prefix) + id;\r\n }\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * Computes the maximum value of `array`. If `array` is empty or falsey,\r\n * `undefined` is returned.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Math\r\n * @param {Array} array The array to iterate over.\r\n * @returns {*} Returns the maximum value.\r\n * @example\r\n *\r\n * _.max([4, 2, 8, 6]);\r\n * // => 8\r\n *\r\n * _.max([]);\r\n * // => undefined\r\n */\r\n function max(array) {\r\n return (array && array.length)\r\n ? baseExtremum(array, identity, baseGt)\r\n : undefined;\r\n }\r\n\r\n /**\r\n * Computes the minimum value of `array`. If `array` is empty or falsey,\r\n * `undefined` is returned.\r\n *\r\n * @static\r\n * @since 0.1.0\r\n * @memberOf _\r\n * @category Math\r\n * @param {Array} array The array to iterate over.\r\n * @returns {*} Returns the minimum value.\r\n * @example\r\n *\r\n * _.min([4, 2, 8, 6]);\r\n * // => 2\r\n *\r\n * _.min([]);\r\n * // => undefined\r\n */\r\n function min(array) {\r\n return (array && array.length)\r\n ? baseExtremum(array, identity, baseLt)\r\n : undefined;\r\n }\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n // Add methods that return wrapped values in chain sequences.\r\n lodash.after = after;\r\n lodash.assignIn = assignIn;\r\n lodash.before = before;\r\n lodash.bind = bind;\r\n lodash.chain = chain;\r\n lodash.compact = compact;\r\n lodash.concat = concat;\r\n lodash.countBy = countBy;\r\n lodash.create = create;\r\n lodash.debounce = debounce;\r\n lodash.defaults = defaults;\r\n lodash.defaultsDeep = defaultsDeep;\r\n lodash.defer = defer;\r\n lodash.delay = delay;\r\n lodash.difference = difference;\r\n lodash.drop = drop;\r\n lodash.filter = filter;\r\n lodash.flatten = flatten;\r\n lodash.flattenDeep = flattenDeep;\r\n lodash.groupBy = groupBy;\r\n lodash.initial = initial;\r\n lodash.intersection = intersection;\r\n lodash.invert = invert;\r\n lodash.invertBy = invertBy;\r\n lodash.iteratee = iteratee;\r\n lodash.keys = keys;\r\n lodash.map = map;\r\n lodash.matches = matches;\r\n lodash.merge = merge;\r\n lodash.mixin = mixin;\r\n lodash.negate = negate;\r\n lodash.omit = omit;\r\n lodash.omitBy = omitBy;\r\n lodash.once = once;\r\n lodash.pick = pick;\r\n lodash.range = range;\r\n lodash.reject = reject;\r\n lodash.rest = rest;\r\n lodash.set = set;\r\n lodash.slice = slice;\r\n lodash.sortBy = sortBy;\r\n lodash.take = take;\r\n lodash.takeRight = takeRight;\r\n lodash.tap = tap;\r\n lodash.throttle = throttle;\r\n lodash.thru = thru;\r\n lodash.toArray = toArray;\r\n lodash.union = union;\r\n lodash.uniq = uniq;\r\n lodash.uniqBy = uniqBy;\r\n lodash.unzip = unzip;\r\n lodash.values = values;\r\n lodash.without = without;\r\n lodash.zip = zip;\r\n lodash.zipObject = zipObject;\r\n\r\n // Add aliases.\r\n lodash.extend = assignIn;\r\n\r\n // Add methods to `lodash.prototype`.\r\n mixin(lodash, lodash);\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n // Add methods that return unwrapped values in chain sequences.\r\n lodash.clamp = clamp;\r\n lodash.clone = clone;\r\n lodash.cloneDeep = cloneDeep;\r\n lodash.escape = escape;\r\n lodash.every = every;\r\n lodash.find = find;\r\n lodash.findIndex = findIndex;\r\n lodash.findKey = findKey;\r\n lodash.findLastIndex = findLastIndex;\r\n lodash.findLastKey = findLastKey;\r\n lodash.forEach = forEach;\r\n lodash.get = get;\r\n lodash.has = has;\r\n lodash.head = head;\r\n lodash.identity = identity;\r\n lodash.indexOf = indexOf;\r\n lodash.isArguments = isArguments;\r\n lodash.isArray = isArray;\r\n lodash.isArrayLike = isArrayLike;\r\n lodash.isBoolean = isBoolean;\r\n lodash.isDate = isDate;\r\n lodash.isEmpty = isEmpty;\r\n lodash.isEqual = isEqual;\r\n lodash.isFinite = isFinite;\r\n lodash.isFunction = isFunction;\r\n lodash.isNaN = isNaN;\r\n lodash.isNull = isNull;\r\n lodash.isNumber = isNumber;\r\n lodash.isObject = isObject;\r\n lodash.isPlainObject = isPlainObject;\r\n lodash.isRegExp = isRegExp;\r\n lodash.isString = isString;\r\n lodash.isUndefined = isUndefined;\r\n lodash.last = last;\r\n lodash.max = max;\r\n lodash.min = min;\r\n lodash.noConflict = noConflict;\r\n lodash.noop = noop;\r\n lodash.random = random;\r\n lodash.reduce = reduce;\r\n lodash.result = result;\r\n lodash.size = size;\r\n lodash.some = some;\r\n lodash.trim = trim;\r\n lodash.unescape = unescape;\r\n lodash.uniqueId = uniqueId;\r\n\r\n // Add aliases.\r\n lodash.each = forEach;\r\n lodash.first = head;\r\n\r\n mixin(lodash, (function() {\r\n var source = {};\r\n baseForOwn(lodash, function(func, methodName) {\r\n if (!hasOwnProperty.call(lodash.prototype, methodName)) {\r\n source[methodName] = func;\r\n }\r\n });\r\n return source;\r\n }()), { 'chain': false });\r\n\r\n /*------------------------------------------------------------------------*/\r\n\r\n /**\r\n * The semantic version number.\r\n *\r\n * @static\r\n * @memberOf _\r\n * @type {string}\r\n */\r\n lodash.VERSION = VERSION;\r\n\r\n // Add `LazyWrapper` methods for `_.drop` and `_.take` variants.\r\n arrayEach(['drop', 'take'], function(methodName, index) {\r\n LazyWrapper.prototype[methodName] = function(n) {\r\n n = n === undefined ? 1 : nativeMax(toInteger(n), 0);\r\n\r\n var result = (this.__filtered__ && !index)\r\n ? new LazyWrapper(this)\r\n : this.clone();\r\n\r\n if (result.__filtered__) {\r\n result.__takeCount__ = nativeMin(n, result.__takeCount__);\r\n } else {\r\n result.__views__.push({\r\n 'size': nativeMin(n, MAX_ARRAY_LENGTH),\r\n 'type': methodName + (result.__dir__ < 0 ? 'Right' : '')\r\n });\r\n }\r\n return result;\r\n };\r\n\r\n LazyWrapper.prototype[methodName + 'Right'] = function(n) {\r\n return this.reverse()[methodName](n).reverse();\r\n };\r\n });\r\n\r\n // Add `LazyWrapper` methods that accept an `iteratee` value.\r\n arrayEach(['filter', 'map', 'takeWhile'], function(methodName, index) {\r\n var type = index + 1,\r\n isFilter = type == LAZY_FILTER_FLAG || type == LAZY_WHILE_FLAG;\r\n\r\n LazyWrapper.prototype[methodName] = function(iteratee) {\r\n var result = this.clone();\r\n result.__iteratees__.push({\r\n 'iteratee': getIteratee(iteratee, 3),\r\n 'type': type\r\n });\r\n result.__filtered__ = result.__filtered__ || isFilter;\r\n return result;\r\n };\r\n });\r\n\r\n // Add `LazyWrapper` methods for `_.head` and `_.last`.\r\n arrayEach(['head', 'last'], function(methodName, index) {\r\n var takeName = 'take' + (index ? 'Right' : '');\r\n\r\n LazyWrapper.prototype[methodName] = function() {\r\n return this[takeName](1).value()[0];\r\n };\r\n });\r\n\r\n // Add `LazyWrapper` methods for `_.initial` and `_.tail`.\r\n arrayEach(['initial', 'tail'], function(methodName, index) {\r\n var dropName = 'drop' + (index ? '' : 'Right');\r\n\r\n LazyWrapper.prototype[methodName] = function() {\r\n return this.__filtered__ ? new LazyWrapper(this) : this[dropName](1);\r\n };\r\n });\r\n\r\n LazyWrapper.prototype.compact = function() {\r\n return this.filter(identity);\r\n };\r\n\r\n LazyWrapper.prototype.find = function(predicate) {\r\n return this.filter(predicate).head();\r\n };\r\n\r\n LazyWrapper.prototype.findLast = function(predicate) {\r\n return this.reverse().find(predicate);\r\n };\r\n\r\n LazyWrapper.prototype.invokeMap = baseRest(function(path, args) {\r\n if (typeof path == 'function') {\r\n return new LazyWrapper(this);\r\n }\r\n return this.map(function(value) {\r\n return baseInvoke(value, path, args);\r\n });\r\n });\r\n\r\n LazyWrapper.prototype.reject = function(predicate) {\r\n return this.filter(negate(getIteratee(predicate)));\r\n };\r\n\r\n LazyWrapper.prototype.slice = function(start, end) {\r\n start = toInteger(start);\r\n\r\n var result = this;\r\n if (result.__filtered__ && (start > 0 || end < 0)) {\r\n return new LazyWrapper(result);\r\n }\r\n if (start < 0) {\r\n result = result.takeRight(-start);\r\n } else if (start) {\r\n result = result.drop(start);\r\n }\r\n if (end !== undefined) {\r\n end = toInteger(end);\r\n result = end < 0 ? result.dropRight(-end) : result.take(end - start);\r\n }\r\n return result;\r\n };\r\n\r\n LazyWrapper.prototype.takeRightWhile = function(predicate) {\r\n return this.reverse().takeWhile(predicate).reverse();\r\n };\r\n\r\n LazyWrapper.prototype.toArray = function() {\r\n return this.take(MAX_ARRAY_LENGTH);\r\n };\r\n\r\n // Add `LazyWrapper` methods to `lodash.prototype`.\r\n baseForOwn(LazyWrapper.prototype, function(func, methodName) {\r\n var checkIteratee = /^(?:filter|find|map|reject)|While$/.test(methodName),\r\n isTaker = /^(?:head|last)$/.test(methodName),\r\n lodashFunc = lodash[isTaker ? ('take' + (methodName == 'last' ? 'Right' : '')) : methodName],\r\n retUnwrapped = isTaker || /^find/.test(methodName);\r\n\r\n if (!lodashFunc) {\r\n return;\r\n }\r\n lodash.prototype[methodName] = function() {\r\n var value = this.__wrapped__,\r\n args = isTaker ? [1] : arguments,\r\n isLazy = value instanceof LazyWrapper,\r\n iteratee = args[0],\r\n useLazy = isLazy || isArray(value);\r\n\r\n var interceptor = function(value) {\r\n var result = lodashFunc.apply(lodash, arrayPush([value], args));\r\n return (isTaker && chainAll) ? result[0] : result;\r\n };\r\n\r\n if (useLazy && checkIteratee && typeof iteratee == 'function' && iteratee.length != 1) {\r\n // Avoid lazy use if the iteratee has a \"length\" value other than `1`.\r\n isLazy = useLazy = false;\r\n }\r\n var chainAll = this.__chain__,\r\n isHybrid = !!this.__actions__.length,\r\n isUnwrapped = retUnwrapped && !chainAll,\r\n onlyLazy = isLazy && !isHybrid;\r\n\r\n if (!retUnwrapped && useLazy) {\r\n value = onlyLazy ? value : new LazyWrapper(this);\r\n var result = func.apply(value, args);\r\n result.__actions__.push({ 'func': thru, 'args': [interceptor], 'thisArg': undefined });\r\n return new LodashWrapper(result, chainAll);\r\n }\r\n if (isUnwrapped && onlyLazy) {\r\n return func.apply(this, args);\r\n }\r\n result = this.thru(interceptor);\r\n return isUnwrapped ? (isTaker ? result.value()[0] : result.value()) : result;\r\n };\r\n });\r\n\r\n // Add `Array` methods to `lodash.prototype`.\r\n arrayEach(['pop', 'push', 'shift', 'sort', 'splice', 'unshift'], function(methodName) {\r\n var func = arrayProto[methodName],\r\n chainName = /^(?:push|sort|unshift)$/.test(methodName) ? 'tap' : 'thru',\r\n retUnwrapped = /^(?:pop|shift)$/.test(methodName);\r\n\r\n lodash.prototype[methodName] = function() {\r\n var args = arguments;\r\n if (retUnwrapped && !this.__chain__) {\r\n var value = this.value();\r\n return func.apply(isArray(value) ? value : [], args);\r\n }\r\n return this[chainName](function(value) {\r\n return func.apply(isArray(value) ? value : [], args);\r\n });\r\n };\r\n });\r\n\r\n // Map minified method names to their real names.\r\n baseForOwn(LazyWrapper.prototype, function(func, methodName) {\r\n var lodashFunc = lodash[methodName];\r\n if (lodashFunc) {\r\n var key = (lodashFunc.name + ''),\r\n names = realNames[key] || (realNames[key] = []);\r\n\r\n names.push({ 'name': methodName, 'func': lodashFunc });\r\n }\r\n });\r\n\r\n realNames[createHybrid(undefined, WRAP_BIND_KEY_FLAG).name] = [{\r\n 'name': 'wrapper',\r\n 'func': undefined\r\n }];\r\n\r\n // Add methods to `LazyWrapper`.\r\n LazyWrapper.prototype.clone = lazyClone;\r\n LazyWrapper.prototype.reverse = lazyReverse;\r\n LazyWrapper.prototype.value = lazyValue;\r\n\r\n // Add lazy aliases.\r\n lodash.prototype.first = lodash.prototype.head;\r\n\r\n if (symIterator) {\r\n lodash.prototype[symIterator] = wrapperToIterator;\r\n }\r\n\r\n /*--------------------------------------------------------------------------*/\r\n\r\n // Some AMD build optimizers, like r.js, check for condition patterns like:\r\n if (typeof define == 'function' && typeof define.amd == 'object' && define.amd) {\r\n // Expose Lodash on the global object to prevent errors when Lodash is\r\n // loaded by a script tag in the presence of an AMD loader.\r\n // See http://requirejs.org/docs/errors.html#mismatch for more details.\r\n // Use `_.noConflict` to remove Lodash from the global object.\r\n root._ = lodash;\r\n\r\n // Define as an anonymous module so, through path mapping, it can be\r\n // referenced as the \"underscore\" module.\r\n define(function() {\r\n return lodash;\r\n });\r\n }\r\n // Check for `exports` after `define` in case a build optimizer adds it.\r\n else if (freeModule) {\r\n // Export for Node.js.\r\n (freeModule.exports = lodash)._ = lodash;\r\n // Export for CommonJS support.\r\n freeExports._ = lodash;\r\n }\r\n else {\r\n // Export to the global object.\r\n root._ = lodash;\r\n }\r\n}.call(this));\r\n"},function(e,t,n){(function(e,t){_global=undefined,"undefined"!=typeof window?_global=window:void 0!==e?_global=e:"undefined"!=typeof self?_global=self:_global=this,_global.BI||(_global.BI={}),function(e){var n=function(e,t){return function(n,i,r){return e.call(t,i,n,r)}},i=function(e){return function(){return _[e].apply(_,arguments)}},r=function(e){return function(){var t=Array.prototype.slice.call(arguments,0);return t[1]=_.isFunction(t[1])?n(t[1],t[2]):t[1],_[e].apply(_,t)}};_.extend(BI,{assert:function(e,t){if(this.isFunction(t)){if(t(e))return!0;throw new Error(e+" error")}if(this.isArray(t)||(t=[t]),!this.deepContains(t,e))throw new Error(e+" error");return!0},warn:function(e){console.warn(e)},UUID:function(){for(var e=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],t="",n=0;n<16;n++){t+=e[parseInt(e.length*Math.random(),10)]}return t},isWidget:function(e){return e instanceof BI.Widget},createWidgets:function(e,t,n){if(!BI.isArray(e))throw new Error("cannot create Widgets");return BI.isWidget(t)?(t,t={}):t||(t={}),BI.map(BI.flatten(e),(function(e,n){return BI.createWidget(n,BI.deepClone(t))}))},createItems:function(e,t,n){return t=BI.isArray(t)?t:BI.makeArray(BI.flatten(e).length,t||{}),n=BI.isArray(n)?n:BI.makeArray(BI.flatten(e).length,n||{}),BI.map(e,(function(e,i){return BI.isArray(i)?BI.createItems(i,t,n):i instanceof BI.Widget?BI.extend({},t.shift(),n.shift(),{type:null,el:i}):t[0]instanceof BI.Widget?(n.shift(),BI.extend({},i,{el:t.shift()})):i.el instanceof BI.Widget?(t.shift(),BI.extend({},n.shift(),{type:null},i)):i.el?BI.extend({},n.shift(),i,{el:BI.extend({},t.shift(),i.el)}):BI.extend({},n.shift(),{el:BI.extend({},t.shift(),i)})}))},packageItems:function(e,t){for(var n=t.length-1;n>=0;n--)e=BI.map(e,(function(e,i){return BI.extend({},t[n],{items:[BI.extend({},t[n].el,{el:i})]})}));return e},formatEL:function(e){return e&&!e.type&&e.el?e:{el:e}},stripEL:function(e){return e.type&&e||e.el||e},trans2Element:function(e){return BI.map(e,(function(e,t){return t.element}))}}),_.each(["where","findWhere","invoke","pluck","shuffle","sample","toArray","size"],(function(e){BI[e]=i(e)})),_.each(["get","set","each","map","reduce","reduceRight","find","filter","reject","every","all","some","any","max","min","sortBy","groupBy","indexBy","countBy","partition","clamp"],(function(e){BI[e]=r("any"===e?"some":e)})),_.extend(BI,{count:function(e,t,n){var i;if(n)for(i=e;i<t;i++)n(i);return t-e},inverse:function(e,t,n){return BI.count(t,e,n)},firstKey:function(t){var n=e;return BI.any(t,(function(e,t){return n=e,!0})),n},lastKey:function(t){var n=e;return BI.each(t,(function(e,t){return n=e,!0})),n},firstObject:function(t){var n=e;return BI.any(t,(function(e,t){return n=t,!0})),n},lastObject:function(t){var n=e;return BI.each(t,(function(e,t){return n=t,!0})),n},concat:function(e,t){return BI.isKey(e)?BI.map([].slice.apply(arguments),(function(e,t){return t})).join(""):BI.isArray(e)?_.concat.apply([],arguments):BI.isObject(e)?_.extend.apply({},arguments):void 0},backEach:function(e,t,n){t=BI.iteratee(t,n);for(var i=e.length-1;i>=0;i--)t(i,e[i],e);return!1},backAny:function(e,t,n){t=BI.iteratee(t,n);for(var i=e.length-1;i>=0;i--)if(t(i,e[i],e))return!0;return!1},backEvery:function(e,t,n){t=BI.iteratee(t,n);for(var i=e.length-1;i>=0;i--)if(!t(i,e[i],e))return!1;return!0},backFindKey:function(e,t,n){t=BI.iteratee(t,n);for(var i,r=_.keys(e),a=r.length-1;a>=0;a--)if(t(e[i=r[a]],i,e))return i},backFind:function(e,t,n){var i;if(void 0!==(i=BI.isArray(e)?BI.findLastIndex(e,t,n):BI.backFindKey(e,t,n))&&-1!==i)return e[i]},remove:function(e,t,n){var i,r=BI.isFunction(t);if(t=r||BI.isArray(t)?t:[t],BI.isArray(e))for(i=0;i<e.length;i++)(r&&!0===t.apply(n,[i,e[i]])||!r&&BI.contains(t,e[i]))&&e.splice(i--,1);else BI.each(e,(function(i,a){(r&&!0===t.apply(n,[i,e[i]])||!r&&BI.contains(t,e[i]))&&delete e[i]}))},removeAt:function(e,t){t=BI.isArray(t)?t:[t];var n,i=BI.isArray(e);for(n=0;n<t.length;n++)i?e[t[n]]="$deleteIndex":delete e[t[n]];i&&BI.remove(e,"$deleteIndex")},string2Array:function(e){return e.split("&-&")},array2String:function(e){return e.join("&-&")},abc2Int:function(e){for(var t=0,n=0,i=(e=e.toUpperCase()).length;n<i;++n)if((t=e.charAt(n).charCodeAt(0)-"A".charCodeAt(0)+26*t+1)>(2147483646-e.charAt(n).charCodeAt(0)+"A".charCodeAt(0))/26)return 0;return t},int2Abc:function(e){var t=["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"],n=e,i="";if(0===e)return"";for(;0!==n;){var r=n%26;0===r&&(r=26),i=t[r-1]+i,n=(n-r)/26}return i}}),_.each(["first","initial","last","rest","compact","flatten","without","union","intersection","difference","zip","unzip","object","indexOf","lastIndexOf","sortedIndex","range","take","takeRight","uniqBy"],(function(e){BI[e]=i(e)})),_.each(["findIndex","findLastIndex"],(function(e){BI[e]=r(e)})),_.extend(BI,{makeArray:function(e,t){for(var n=[],i=0;i<e;i++)BI.isNull(t)?n.push(i):n.push(BI.deepClone(t));return n},makeObject:function(e,t){for(var n={},i=0;i<e.length;i++)BI.isNull(t)?n[e[i]]=e[i]:BI.isFunction(t)?n[e[i]]=t(i,e[i]):n[e[i]]=BI.deepClone(t);return n},makeArrayByArray:function(e,t){var n=[];if(!e)return n;for(var i=0,r=e.length;i<r;i++)BI.isArray(e[i])?n.push(arguments.callee(e[i],t)):n.push(BI.deepClone(t));return n},uniq:function(e,t,i,r){return null==e?[]:(_.isBoolean(t)||(r=i,i=t,t=!1),i&&(i=n(i,r)),_.uniq.call(_,e,t,i,r))}}),_.each(["keys","allKeys","values","pairs","invert","create","functions","extend","extendOwn","defaults","clone","property","propertyOf","matcher","isEqual","isMatch","isEmpty","isElement","isNumber","isString","isArray","isObject","isPlainObject","isArguments","isFunction","isFinite","isBoolean","isDate","isRegExp","isError","isNaN","isUndefined","zipObject","cloneDeep"],(function(e){BI[e]=i(e)})),_.each(["mapObject","findKey","pick","omit","tap"],(function(e){BI[e]=r(e)})),_.extend(BI,{inherit:function(e,t){var n=function(){return e.apply(this,arguments)},i=function(){},r=e.prototype;return i.prototype=r,n.prototype=new i,n.superclass=r,_.extend(n.prototype,t,{superclass:e}),n},init:function(){for(;BI.prepares&&BI.prepares.length>0;)BI.prepares.shift()();for(;_global.___fineuiExposedFunction&&_global.___fineuiExposedFunction.length>0;)_global.___fineuiExposedFunction.shift()();BI.initialized=!0},has:function(e,t){return BI.isArray(t)?0!==t.length&&BI.every(t,(function(t,n){return _.has(e,n)})):_.has.apply(_,arguments)},freeze:function(e){return Object.freeze&&BI.isObject(e)?Object.freeze(e):e},isKey:function(e){return BI.isNumber(e)||BI.isString(e)&&e.length>0},isCapitalEqual:function(e,t){return e=BI.isNull(e)?e:(""+e).toLowerCase(),t=BI.isNull(t)?t:(""+t).toLowerCase(),BI.isEqual(e,t)},isWidthOrHeight:function(e){return"number"==typeof e?e>=0:"string"==typeof e?/^\d{1,3}(\.\d)?%$/.exec(e)||"auto"==e||/^\d+px$/.exec(e):void 0},isNotNull:function(e){return!BI.isNull(e)},isNull:function(e){return null==e},isEmptyArray:function(e){return BI.isArray(e)&&BI.isEmpty(e)},isNotEmptyArray:function(e){return BI.isArray(e)&&!BI.isEmpty(e)},isEmptyObject:function(e){return BI.isEqual(e,{})},isNotEmptyObject:function(e){return BI.isPlainObject(e)&&!BI.isEmptyObject(e)},isEmptyString:function(e){return BI.isString(e)&&0===e.length},isNotEmptyString:function(e){return BI.isString(e)&&!BI.isEmptyString(e)},isWindow:function(e){return null!=e&&e==e.window}}),_.extend(BI,{deepClone:_.cloneDeep,deepExtend:_.merge,isDeepMatch:function(e,t){var n=BI.keys(t),i=n.length;if(null==e)return!i;for(var r=Object(e),a=0;a<i;a++){var o=n[a];if(!BI.isEqual(t[o],r[o])||!(o in r))return!1}return!0},contains:function(e,t,n){return _.isArrayLike(e)||(e=_.values(e)),_.indexOf(e,t,"number"==typeof n&&n)>=0},deepContains:function(e,t){return BI.isObject(t)?BI.any(e,(function(e,n){if(BI.isEqual(n,t))return!0})):BI.contains(e,t)},deepIndexOf:function(e,t){for(var n=0;n<e.length;n++)if(BI.isEqual(t,e[n]))return n;return-1},deepRemove:function(e,t){var n,i=!1;if(BI.isArray(e))for(n=0;n<e.length;n++)BI.isEqual(t,e[n])&&(e.splice(n--,1),i=!0);else BI.each(e,(function(n,r){BI.isEqual(t,e[n])&&(delete e[n],i=!0)}));return i},deepWithout:function(e,t){if(BI.isArray(e)){for(var n=[],i=0;i<e.length;i++)BI.isEqual(t,e[i])||n.push(e[i]);return n}n={};return BI.each(e,(function(i,r){BI.isEqual(t,e[i])||(n[i]=r)})),n},deepUnique:function(e){var t=[];return BI.each(e,(function(e,n){BI.deepContains(t,n)||t.push(n)})),t},deepDiff:function(e,t){e||(e={}),t||(t={});var n=[],i=[];for(var r in e)this.has(e,r)&&(this.isEqual(e[r],t[r])||n.push(r),i.push(r));for(var r in t)this.has(t,r)&&!BI.contains(i,r)&&n.push(r);return n}}),_.each(["uniqueId","result","chain","iteratee","escape","unescape","before","after"],(function(e){BI[e]=function(){return _[e].apply(_,arguments)}})),_.each(["bind","once","partial","debounce","throttle","delay","defer","wrap"],(function(e){BI[e]=function(){return _[e].apply(_,arguments)}})),_.extend(BI,{nextTick:function(){var e=[],n=!1,i=void 0;function r(){n=!1;var t=e.slice(0);e.length=0;for(var i=0;i<t.length;i++)t[i]()}if("undefined"!=typeof Promise){var a=Promise.resolve();i=function(){a.then(r)}}else if("undefined"!=typeof MutationObserver){var o=1,s=new MutationObserver(r),l=document.createTextNode(String(o));s.observe(l,{characterData:!0}),i=function(){o=(o+1)%2,l.data=String(o)}}else i=void 0!==t?function(){t(r)}:function(){setTimeout(r,0)};return function(t){var r=void 0,a=[].slice.call(arguments,1);if(e.push((function(){if(t)try{t.apply(null,a)}catch(e){console.error(e)}else r&&r.apply(null,a)})),n||(n=!0,i()),!t&&"undefined"!=typeof Promise)return new Promise((function(e,t){r=e}))}}()}),_.each(["random"],(function(e){BI[e]=i(e)})),_.extend(BI,{getTime:function(){return _global.performance&&_global.performance.now?_global.performance.now():_global.performance&&_global.performance.webkitNow?_global.performance.webkitNow():Date.now?Date.now():BI.getDate().getTime()},parseInt:function(e){var t=10;/^0x/g.test(e)&&(t=16);try{return parseInt(e,t)}catch(n){throw new Error(e+"parse int error")}},parseSafeInt:function(e){var t=9007199254740991;return e?this.clamp(this.parseInt(e),-9007199254740991,t):0===e?e:0},parseFloat:function(e){try{return parseFloat(e)}catch(t){throw new Error(e+"parse float error")}},isNaturalNumber:function(e){return!!/^\d+$/.test(e)},isPositiveInteger:function(e){return!!/^\+?[1-9][0-9]*$/.test(e)},isNegativeInteger:function(e){return!!/^\-[1-9][0-9]*$/.test(e)},isInteger:function(e){return!!/^\-?\d+$/.test(e)},isNumeric:function(e){return!isNaN(parseFloat(e))&&isFinite(e)},isFloat:function(e){return!!/^([+-]?)\d*\.\d+$/.test(e)},isOdd:function(e){return!!BI.isInteger(e)&&1==(1&e)},isEven:function(e){return!!BI.isInteger(e)&&0==(1&e)},sum:function(e,t,n){var i=0;return BI.each(e,(function(e,r){i+=Number(t?t.apply(n,[e,r]):r)})),i},average:function(e,t,n){return BI.sum(e,t,n)/e.length}}),_.extend(BI,{trim:function(){return _.trim.apply(_,arguments)},toUpperCase:function(e){return(e+"").toLocaleUpperCase()},toLowerCase:function(e){return(e+"").toLocaleLowerCase()},isEndWithBlank:function(e){return/(\s|\u00A0)$/.test(e)},isLiteral:function(e){return/^\s?(true|false|-?[\d\.]+|'[^']*'|"[^"]*")\s?$/.test(e)},stripQuotes:function(e){var t=e.charCodeAt(0);return t!==e.charCodeAt(e.length-1)||34!==t&&39!==t?e:e.slice(1,-1)},camelize:function(e){return e.replace(/-(.)/g,(function(e,t){return t.toUpperCase()}))},hyphenate:function(e){return e.replace(/([A-Z])/g,"-$1").toLowerCase()},isNotEmptyString:function(e){return BI.isString(e)&&!BI.isEmpty(e)},isEmptyString:function(e){return BI.isString(e)&&BI.isEmpty(e)},encrypt:function(e,t,n){switch(e){case BI.CRYPT_TYPE.AES:default:return BI.aesEncrypt(t,n)}},decrypt:function(e,t,n){switch(e){case BI.CRYPT_TYPE.AES:default:return BI.aesDecrypt(t,n)}},escape:function(e){return e.replace(/('|\\)/g,"\\$1")},leftPad:function(e,t,n){var i=String(e);for(n||(n=" ");i.length<t;)i=n+i;return i.toString()},format:function(e){var t=Array.prototype.slice.call(arguments,1);return e.replace(/\{(\d+)\}/g,(function(e,n){return t[n]}))}}),_.extend(BI,{isLeapYear:function(e){return e%4==0&&e%100!=0||e%400==0},checkDateVoid:function(e,t,n,i,r){var a=[];return e|=0,t|=0,n|=0,i=BI.isString(i)?i.match(/\d+/g):i,r=BI.isString(r)?r.match(/\d+/g):r,e<i[0]?a=["y"]:e>r[0]?a=["y",1]:e>=i[0]&&e<=r[0]&&(e==i[0]&&(t<i[1]?a=["m"]:t==i[1]&&n<i[2]&&(a=["d"])),e==r[0]&&(t>r[1]?a=["m",1]:t==r[1]&&n>r[2]&&(a=["d",1]))),a},checkDateLegal:function(e){var t=e.match(/\d+/g),n=0|t[0],i=0|t[1],r=0|t[2];if(t.length<=1)return!0;if(t.length<=2)return i>=1&&i<=12;var a=BI.Date._MD.slice(0);return a[1]=BI.isLeapYear(n)?29:28,i>=1&&i<=12&&r<=a[i-1]},parseDateTime:function(e,t){var n=BI.getDate(),i=0,r=0,a=1,o=e.split(/\W+/);if("%y%x"==t.toLowerCase()||"%y%x%d"==t.toLowerCase()){o[0]=e.substring(0,4),o[1]=e.substring(4,6),o[2]=e.substring(6,8)}var s=t.match(/%./g),l=0,u=0,c=0,h=0,p=0;for(l=0;l<o.length;++l)switch(s[l]){case"%d":case"%e":a=parseInt(o[l],10);break;case"%X":case"%x":r=parseInt(o[l],10)-1;break;case"%Y":case"%y":(i=parseInt(o[l],10))<100&&(i+=i>29?1900:2e3);break;case"%b":case"%B":for(u=0;u<12;++u)if(BI.Date._MN[u].substr(0,o[l].length).toLowerCase()==o[l].toLowerCase()){r=u;break}break;case"%H":case"%I":case"%k":case"%l":c=parseInt(o[l],10);break;case"%P":case"%p":/pm/i.test(o[l])&&c<12?c+=12:/am/i.test(o[l])&&c>=12&&(c-=12);break;case"%Q":case"%q":r=3*(parseInt(o[l],10)-1);break;case"%M":h=parseInt(o[l],10);break;case"%S":p=parseInt(o[l],10)}if(isNaN(i)&&(i=n.getFullYear()),isNaN(r)&&(r=n.getMonth()),isNaN(a)&&(a=n.getDate()),isNaN(c)&&(c=n.getHours()),isNaN(h)&&(h=n.getMinutes()),isNaN(p)&&(p=n.getSeconds()),0!=i)return BI.getDate(i,r,a,c,h,p);for(i=0,r=-1,a=0,l=0;l<o.length;++l)if(-1!=o[l].search(/[a-zA-Z]+/)){var d=-1;for(u=0;u<12;++u)if(BI.Date._MN[u].substr(0,o[l].length).toLowerCase()==o[l].toLowerCase()){d=u;break}-1!=d&&(-1!=r&&(a=r+1),r=d)}else parseInt(o[l],10)<=12&&-1==r?r=o[l]-1:parseInt(o[l],10)>31&&0==i?(i=parseInt(o[l],10))<100&&(i+=i>29?1900:2e3):0==a&&(a=o[l]);return 0==i&&(i=n.getFullYear()),-1===r&&(r=n.getMonth()),-1!=r&&0!=a?BI.getDate(i,r,a,c,h,p):n},getDate:function(){var e,t=arguments.length,n=arguments;switch(t){case 0:e=new Date;break;case 1:e=new Date(n[0]);break;case 2:e=new Date(n[0],n[1]);break;case 3:e=new Date(n[0],n[1],n[2]);break;case 4:e=new Date(n[0],n[1],n[2],n[3]);break;case 5:e=new Date(n[0],n[1],n[2],n[3],n[4]);break;case 6:e=new Date(n[0],n[1],n[2],n[3],n[4],n[5]);break;case 7:e=new Date(n[0],n[1],n[2],n[3],n[4],n[5],n[6]);break;default:e=new Date}if(BI.isNotNull(BI.timeZone)&&(0===arguments.length||1===arguments.length&&BI.isNumber(arguments[0]))){var i=e.getTime(),r=6e4*e.getTimezoneOffset(),a=i+r;return new Date(a+BI.timeZone)}return e},getTime:function(){var e,t=arguments.length,n=arguments;switch(t){case 0:e=new Date;break;case 1:e=new Date(n[0]);break;case 2:e=new Date(n[0],n[1]);break;case 3:e=new Date(n[0],n[1],n[2]);break;case 4:e=new Date(n[0],n[1],n[2],n[3]);break;case 5:e=new Date(n[0],n[1],n[2],n[3],n[4]);break;case 6:e=new Date(n[0],n[1],n[2],n[3],n[4],n[5]);break;case 7:e=new Date(n[0],n[1],n[2],n[3],n[4],n[5],n[6]);break;default:e=new Date}return BI.isNotNull(BI.timeZone)?e.getTime()-BI.timeZone-6e4*(new Date).getTimezoneOffset():e.getTime()}})}()}).call(this,n(14),n(61).setImmediate)},function(e,t,n){"use strict";(function(e,t){!function(e,n){if(!e.setImmediate){var i,r,a,o,s,l=1,u={},c=!1,h=e.document,p=Object.getPrototypeOf&&Object.getPrototypeOf(e);p=p&&p.setTimeout?p:e,"[object process]"==={}.toString.call(e.process)?i=function(e){t.nextTick((function(){f(e)}))}:!function(){if(e.postMessage&&!e.importScripts){var t=!0,n=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=n,t}}()?e.MessageChannel?((a=new MessageChannel).port1.onmessage=function(e){f(e.data)},i=function(e){a.port2.postMessage(e)}):h&&"onreadystatechange"in h.createElement("script")?(r=h.documentElement,i=function(e){var t=h.createElement("script");t.onreadystatechange=function(){f(e),t.onreadystatechange=null,r.removeChild(t),t=null},r.appendChild(t)}):i=function(e){setTimeout(f,0,e)}:(o="setImmediate$"+Math.random()+"$",s=function(t){t.source===e&&"string"==typeof t.data&&0===t.data.indexOf(o)&&f(+t.data.slice(o.length))},e.addEventListener?e.addEventListener("message",s,!1):e.attachEvent("onmessage",s),i=function(t){e.postMessage(o+t,"*")}),p.setImmediate=function(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),n=0;n<t.length;n++)t[n]=arguments[n+1];var r={callback:e,args:t};return u[l]=r,i(l),l++},p.clearImmediate=d}function d(e){delete u[e]}function f(e){if(c)setTimeout(f,0,e);else{var t=u[e];if(t){c=!0;try{!function(e){var t=e.callback,n=e.args;switch(n.length){case 0:t();break;case 1:t(n[0]);break;case 2:t(n[0],n[1]);break;case 3:t(n[0],n[1],n[2]);break;default:t.apply(void 0,n)}}(t)}finally{d(e),c=!1}}}}}("undefined"==typeof self?void 0===e?void 0:e:self)}).call(this,n(14),n(75))},function(e,t){var n;n=function(e){this._constructor(e)},_.extend(n.prototype,{props:{},init:null,destroyed:null,_constructor:function(e){this._initProps(e),this._init(),this._initRef()},_defaultConfig:function(e){return{}},_initProps:function(e){var t=this.props;BI.isFunction(this.props)&&(t=this.props(e)),this.options=function(){for(var e,t,n,i=arguments[0]||{},r=arguments.length,a=1;a<r;a++)if(null!=(e=arguments[a]))for(t in e)i[t],i!==(n=e[t])&&n!==undefined&&(i[t]=n);return i}(this._defaultConfig(e),t,e)},_init:function(){this._initListeners(),this.init&&this.init()},_initListeners:function(){var e=this;null!=this.options.listeners&&(_.each(this.options.listeners,(function(t){(t.target?t.target:e)[t.once?"once":"on"](t.eventName,_.bind(t.action,e))})),delete this.options.listeners)},_initRef:function(){this.options.__ref&&this.options.__ref.call(this,this),this.options.ref&&this.options.ref.call(this,this)},_purgeRef:function(){this.options.__ref&&(this.options.__ref.call(null),this.options.__ref=null),this.options.ref&&(this.options.ref.call(null),this.options.ref=null)},_getEvents:function(){return _.isObject(this.events)||(this.events={}),this.events},on:function(e,t){var n=this;e=e.toLowerCase();var i=this._getEvents()[e];return _.isArray(i)||(i=[],this._getEvents()[e]=i),i.push(t),function(){n.un(e,t)}},once:function(e,t){var n=function(){t.apply(this,arguments),this.un(e,n)};this.on(e,n)},un:function(e,t){if(e=e.toLowerCase(),null==t)delete this._getEvents()[e];else{var n=this._getEvents()[e];if(_.isArray(n)){var i=[];_.each(n,(function(e){e!=t&&i.push(e)})),this._getEvents()[e]=i}}},purgeListeners:function(){this.events={}},fireEvent:function(){var e=arguments[0].toLowerCase(),t=this._getEvents()[e];if(BI.isArray(t))if(BI.isArguments(arguments[1])){for(var n=0;n<t.length;n++)if(!1===t[n].apply(this,arguments[1]))return!1}else{var i=Array.prototype.slice.call(arguments,1);for(n=0;n<t.length;n++)if(!1===t[n].apply(this,i))return!1}return!0},destroy:function(){this.destroyed&&this.destroyed(),this._purgeRef(),this.purgeListeners()}}),BI.OB=BI.OB||n},function(e,t){!function(){var e={};BI.module=BI.module||function(t,n){null!=e[t]&&_global.console&&console.error("module:["+t+"] has been registed"),e[t]=n};var t={};BI.constant=BI.constant||function(e,n){null!=t[e]&&_global.console&&console.error("constant:["+e+"] has been registed"),t[e]=n};var n={};BI.model=BI.model||function(e,t){null!=n[e]&&_global.console&&console.error("model:["+e+"] has been registed"),n[e]=t};var i={};BI.store=BI.store||function(e,t){null!=i[e]&&_global.console&&console.error("store:["+e+"] has been registed"),i[e]=t};var r={};BI.service=BI.service||function(e,t){null!=r[e]&&_global.console&&console.error("service:["+e+"] has been registed"),r[e]=t};var a={};BI.provider=BI.provider||function(e,t){null!=a[e]&&_global.console&&console.error("provider:["+e+"] has been registed"),a[e]=t};var o={};BI.config=BI.config||function(e,n,i){if(BI.initialized)return t[e]?t[e]=n(t[e]):a[e]?(d[e]||(d[e]=new a[e]),f[e]&&delete f[e],n(d[e])):BI.Plugin.configWidget(e,n,i);o[e]||(o[e]=[],BI.prepares.push((function(){for(var n=o[e],i=0;i<n.length;i++)t[e]?t[e]=n[i](t[e]):a[e]?(d[e]||(d[e]=new a[e]),f[e]&&delete f[e],n[i](d[e])):BI.Plugin.configWidget(e,n[i]);o[e]=null}))),o[e].push(n)},BI.getReference=BI.getReference||function(e,t){return BI.Plugin.registerObject(e,t)};var s={},l=[];BI.action=BI.action||function(e,t){return BI.isFunction(e)?(l.push(e),function(){BI.remove(l,(function(e){return l.indexOf(t)===e}))}):(s[e]||(s[e]=[]),s[e].push(t),function(){BI.remove(s[e],(function(n){return s[e].indexOf(t)===n})),0===s[e].length&&delete s[e]})};var u={};BI.point=BI.point||function(e,t,n,i){u[e]||(u[e]={}),u[e][t]||(u[e][t]={}),u[e][t][i?"after":"before"]||(u[e][t][i?"after":"before"]=[]),u[e][t][i?"after":"before"].push(n)},BI.Modules=BI.Modules||{getModule:function(t){return e[t]?e[t]:(_global.console&&console.error("module:["+t+"] does not exists"),!1)},getAllModules:function(){return e}},BI.Constants=BI.Constants||{getConstant:function(e){return t[e]}};var c=function(e,t){t=BI.isArray(t)?t:[t],BI.each(t,(function(t,n){if(u[n])for(var i in u[n]){var r=u[n][i].before;r&&BI.aspect.before(e,i,function(t){return function(){for(var n=0,i=t.length;n<i;n++)try{t[n].apply(e,arguments)}catch(r){_global.console&&console.error(r)}}}(r));var a=u[n][i].after;a&&BI.aspect.after(e,i,function(t){return function(){for(var n=0,i=t.length;n<i;n++)try{t[n].apply(e,arguments)}catch(r){_global.console&&console.error(r)}}}(a))}}))};BI.Models=BI.Models||{getModel:function(e,t){var i=new n[e](t);return i._constructor&&i._constructor(t),i.mixins&&c(i,i.mixins),c(i,e),i}};var h={};BI.Stores=BI.Stores||{getStore:function(e,t){if(h[e])return h[e];var n=h[e]=new i[e](t);return n._constructor&&n._constructor(t,(function(){delete h[e]})),c(n,e),n}};var p={};BI.Services=BI.Services||{getService:function(e,t){return p[e]||(p[e]=new r[e](t),c(p[e],e)),p[e]}};var d={},f={};BI.Providers=BI.Providers||{getProvider:function(e,t){return d[e]||(d[e]=new a[e]),f[e]||(f[e]=new(d[e].$get())(t)),f[e]}},BI.Actions=BI.Actions||{runAction:function(e,t,n){BI.each(s[e],(function(e,i){try{i(t,n)}catch(r){_global.console&&console.error(r)}}))},runGlobalAction:function(){var e=[].slice.call(arguments);BI.each(l,(function(t,n){try{n.apply(null,e)}catch(i){_global.console&&console.error(i)}}))}},BI.getResource=BI.getResource||function(e,o){return t[e]?BI.Constants.getConstant(e):n[e]?BI.Models.getModel(e,o):i[e]?BI.Stores.getStore(e,o):r[e]?BI.Services.getService(e,o):a[e]?BI.Providers.getProvider(e,o):void 0}}()},function(e,t){BI.prepares.push((function(){BI.Date=BI.Date||{},BI.Date._DN=[BI.i18nText("BI-Basic_Sunday"),BI.i18nText("BI-Basic_Monday"),BI.i18nText("BI-Basic_Tuesday"),BI.i18nText("BI-Basic_Wednesday"),BI.i18nText("BI-Basic_Thursday"),BI.i18nText("BI-Basic_Friday"),BI.i18nText("BI-Basic_Saturday"),BI.i18nText("BI-Basic_Sunday")],BI.Date._SDN=[BI.i18nText("BI-Basic_Simple_Sunday"),BI.i18nText("BI-Basic_Simple_Monday"),BI.i18nText("BI-Basic_Simple_Tuesday"),BI.i18nText("BI-Basic_Simple_Wednesday"),BI.i18nText("BI-Basic_Simple_Thursday"),BI.i18nText("BI-Basic_Simple_Friday"),BI.i18nText("BI-Basic_Simple_Saturday"),BI.i18nText("BI-Basic_Simple_Sunday")],BI.Date._FD=1,BI.Date._MN=[BI.i18nText("BI-Basic_January"),BI.i18nText("BI-Basic_February"),BI.i18nText("BI-Basic_March"),BI.i18nText("BI-Basic_April"),BI.i18nText("BI-Basic_May"),BI.i18nText("BI-Basic_June"),BI.i18nText("BI-Basic_July"),BI.i18nText("BI-Basic_August"),BI.i18nText("BI-Basic_September"),BI.i18nText("BI-Basic_October"),BI.i18nText("BI-Basic_November"),BI.i18nText("BI-Basic_December")],BI.Date._SMN=[0,1,2,3,4,5,6,7,8,9,10,11],BI.Date._QN=["",BI.i18nText("BI-Quarter_1"),BI.i18nText("BI-Quarter_2"),BI.i18nText("BI-Quarter_3"),BI.i18nText("BI-Quarter_4")],BI.Date._MD=[31,28,31,30,31,30,31,31,30,31,30,31],BI.Date._OFFSET=[0,-1,-2,-3,-4,-5,-6]}))},function(e,t){_.extend(BI,{Events:{KEYDOWN:"_KEYDOWN",BACKSPACE:"_BACKSPACE",SPACE:"_SPACE",ENTER:"_ENTER",CONFIRM:"_CONFIRM",ERROR:"_ERROR",PAUSE:"_PAUSE",DESTROY:"_DESTROY",MOUNT:"_MOUNT",UNMOUNT:"_UNMOUNT",CLEAR:"_CLEAR",ADD:"_ADD",EDITING:"_EDITING",EMPTY:"_EMPTY",VIEW:"_VIEW",RESIZE:"_RESIZE",BEFOREEDIT:"_BEFOREEDIT",AFTEREDIT:"_AFTEREDIT",STARTEDIT:"_STARTEDIT",STOPEDIT:"_STOPEDIT",CHANGE:"_CHANGE",EXPAND:"_EXPAND",COLLAPSE:"_COLLAPSE",CALLBACK:"_CALLBACK",CLICK:"_CLICK",STATECHANGE:"_STATECHANGE",BEFORESTATECHANGE:"_BEFORESTATECHANGE",INIT:"_INIT",AFTERINIT:"_AFTERINIT",SCROLL:"_SCROLL",STARTLOAD:"_STARTLOAD",AFTERLOAD:"_AFTERLOAD",BS:"beforesubmit",AS:"aftersubmit",SC:"submitcomplete",SF:"submitfailure",SS:"submitsuccess",BVW:"beforeverifywrite",AVW:"afterverifywrite",AV:"afterverify",BW:"beforewrite",AW:"afterwrite",WS:"writesuccess",WF:"writefailure",BA:"beforeappend",AA:"afterappend",BD:"beforedelete",AD:"beforedelete",UC:"unloadcheck",BTOPDF:"beforetopdf",ATOPDF:"aftertopdf",BTOEXCEL:"beforetoexcel",ATOEXCEL:"aftertoexcel",BTOWORD:"beforetoword",ATOWORD:"aftertoword",BTOIMAGE:"beforetoimage",ATOIMAGE:"aftertoimage",BTOHTML:"beforetohtml",ATOHTML:"aftertohtml",BIMEXCEL:"beforeimportexcel",AIMEXCEL:"afterimportexcel",BPDFPRINT:"beforepdfprint",APDFPRINT:"afterpdfprint",BFLASHPRINT:"beforeflashprint",AFLASHPRINT:"afterflashprint",BAPPLETPRINT:"beforeappletprint",AAPPLETPRINT:"afterappletprint",BSEVERPRINT:"beforeserverprint",ASERVERPRINT:"afterserverprint",BEMAIL:"beforeemail",AEMAIL:"afteremail"}})},function(e,t){_.extend(BI,{MAX:0x1000000000000000,MIN:-0x1000000000000000,EVENT_RESPONSE_TIME:200,zIndex_layer:1e5,zIndex_popover:1e6,zIndex_popup:1e7,zIndex_masker:1e8,zIndex_tip:1e9,emptyStr:"",pixUnit:"px",pixRatio:1,emptyFn:function(){},empty:null,Key:{48:"0",49:"1",50:"2",51:"3",52:"4",53:"5",54:"6",55:"7",56:"8",57:"9",65:"a",66:"b",67:"c",68:"d",69:"e",70:"f",71:"g",72:"h",73:"i",74:"j",75:"k",76:"l",77:"m",78:"n",79:"o",80:"p",81:"q",82:"r",83:"s",84:"t",85:"u",86:"v",87:"w",88:"x",89:"y",90:"z",96:"0",97:"1",98:"2",99:"3",100:"4",101:"5",102:"6",103:"7",104:"8",105:"9",106:"*",107:"+",109:"-",110:".",111:"/"},KeyCode:{BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38},Status:{SUCCESS:1,WRONG:2,START:3,END:4,WAITING:5,READY:6,RUNNING:7,OUTOFBOUNDS:8,NULL:-1},Direction:{Top:"top",Bottom:"bottom",Left:"left",Right:"right",Custom:"custom"},Axis:{Vertical:"vertical",Horizontal:"horizontal"},Selection:{Default:-2,None:-1,Single:0,Multi:1,All:2},HorizontalAlign:{Left:"left",Right:"right",Center:"center",Stretch:"stretch"},VerticalAlign:{Middle:"middle",Top:"top",Bottom:"bottom",Stretch:"stretch"},StartOfWeek:1,BlankSplitChar:" "})},function(module,exports,__webpack_require__){(function(global){(function(){var _global;function isEmpty(e){return""===e||null===e||e===undefined}function isInvalidDate(e){return"Invalid Date"==e||"NaN"==e}function _eFormat(e,t){return function(e,t){var n=e<0?(e*=-1,"-"):"",i="",r=Math[e>0&&e<1?"floor":"ceil"](Math.log(e)/Math.log(10));if(!isFinite(r))return t.replace(/#/gi,"").replace(/\.e/gi,"E");(e/=Math.pow(10,r))>0&&e<1&&(e*=10,r-=1);var a=function(e,t){if(!/e/gi.test(t))return 0;var n,i,r=t.split(/e/gi)[0].split(".")[0],a=r.length,o=0;for(n=0;n<a;n++)(0==(i=r.charAt(n))||"#"==i&&a-n<=e+1)&&o++;return o}(r,t);a>1&&(r-=a-1,e*=Math.pow(10,a-1)),r<0&&(i="-",r*=-1);var o=function(e){if(!/e/gi.test(e))return 0;var t=e.split(/e/gi)[0].split(".");return t.length>1?t[1].length:0}(t),s=function(e){var t=Math.round(e);return e=(e+"").split(".")[0],t=(t+"").split(".")[0],e.length!==t.length}(e);return e*=Math.pow(10,o),e=Math.round(e),s&&(e/=10,r+="-"===i?-1:1),e=(e/=Math.pow(10,o)).toFixed(o),r=function(e,t,n){if(t+="",!/e/gi.test(e))return t;e=e.split(/e/gi)[1];for(;t.length<e.length;)t="0"+t;for(var i=!0,r=0,a=t.length;r<a;r++)i&&(i="0"===t.charAt(r));return(n=i?"":n)+t}(t,r,i),n+e+"E"+r}(e=+e,t)}function _dealNumberPrecision(e,t){if(/[eE]/.test(e)){var n,i=0,r=0;/[%‰]$/.test(t)&&(i=/[%]$/.test(t)?2:3);for(var a=t.length;r<a;r++)"0"!=(n=t.charAt(r))&&"#"!=n||i++;return Number(e).toFixed(i)}return e}function _numberFormat(e,t){if(!/[0-9]/.test(e=e+"")||!t)return e;var n=t.indexOf(";");if(n>-1)return e>=0?_numberFormat(e+"",t.substring(0,n)):_numberFormat(-e+"",t.substr(n+1));if(+e<0&&"-"!==t.charAt(0))return _numberFormat(-e+"","-"+t);var i=t.split("."),r=i[0]||"",a=i[1]||"",o=(e=_dealNumberPrecision(e,a)).split("."),s=o[0]||"",l=o[1]||"";if(/[%‰]$/.test(t)){var u=/[%]$/.test(t)?"00":"000";s=(s+=(l+=u).substr(0,u.length)).replace(/^0+/gi,""),l=l.substr(u.length).replace(/0+$/gi,"")}var c=_dealWithRight(l,a);c.leftPlus&&(s=parseInt(s)+1+"",s=isNaN(s)?"1":s),c=c.num;var h=_dealWithLeft(s,r);return/[0-9]/.test(h)||(h+="0"),/[0-9]/.test(c)?h+"."+c:h+c}function _dealWithRight(e,t){for(var n="",i=0,r=0,a=t.length;r<a;r++){var o=t.charAt(r),s=e.charAt(i);switch(o){case"0":isEmpty(s)&&(s="0"),n+=s,i++;break;case"#":n+=s,i++;break;default:n+=o}}var l=e.substr(i),u={};if(!isEmpty(l)&&l.charAt(0)>4){u.leftPlus=!0;var c=n.match(/^[0-9]+/);if(c){var h=c[0],p=h.length,d=parseInt(h)+1+"";d.length>p?d=d.substr(1):(d=BI.leftPad(d,p,"0"),u.leftPlus=!1),n=n.replace(/^[0-9]+/,d)}}return u.num=n,u}function _dealWithLeft(e,t){for(var n="",i=e.length-1,r=-1,a=-1,o=t.length-1;o>=0;o--){var s=t.charAt(o),l=e.charAt(i);switch(s){case"0":isEmpty(l)&&(l="0"),a=-1,n=l+n,i--;break;case"#":a=o,n=l+n,i--;break;case",":if(!isEmpty(l)){var u=t.match(/,[#0]+/);u&&(r=u[0].length-1),n=","+n}break;default:n=s+n}}if(a>-1){var c=e.substr(0,i+1);n=n.substr(0,a)+c+n.substr(a)}if(r>0){var h=n.match(/[0-9]+,/);if(h){for(var p="",d=(h=h[0]).length-1-r;d>=0;d-=r)p=h.substr(d,r)+","+p;var f=h.substr(0,d+r);isEmpty(f)||(p=f+","+p)}n=n.replace(/[0-9]+,/,p)}return n}_global="undefined"!=typeof window?window:void 0!==global?global:"undefined"!=typeof self?self:this,_global.BI||(_global.BI={}),BI.cjkEncode=function(e){if("string"!=typeof e)return e;for(var t="",n=0;n<e.length;n++){var i=e.charCodeAt(n);t+=i>=128||91===i||93===i?"["+i.toString(16)+"]":e.charAt(n)}return t},BI.cjkDecode=function(text){if(null==text)return"";if(!isNaN(text)||-1==text.indexOf("["))return text;for(var newText="",i=0;i<text.length;i++){var ch=text.charAt(i);if("["==ch){var rightIdx=text.indexOf("]",i+1);if(rightIdx>i+1){var subText=text.substring(i+1,rightIdx);subText.length>0&&(ch=String.fromCharCode(eval("0x"+subText))),i=rightIdx}}newText+=ch}return newText};var SPECIAL_TAGS={"&":"&amp;",'"':"&quot;","<":"&lt;",">":"&gt;"," ":"&nbsp;"};BI.htmlEncode=function(e){return BI.isNull(e)?"":BI.replaceAll(e+"",'&|"|<|>|\\s',(function(e){return SPECIAL_TAGS[e]?SPECIAL_TAGS[e]:"&nbsp;"}))},BI.htmlDecode=function(e){return BI.isNull(e)?"":BI.replaceAll(e+"","&amp;|&quot;|&lt;|&gt;|&nbsp;",(function(e){switch(e){case"&amp;":return"&";case"&quot;":return'"';case"&lt;":return"<";case"&gt;":return">";case"&nbsp;":default:return" "}}))},BI.cjkEncodeDO=function(e){if(BI.isPlainObject(e)){var t={};return _.each(e,(function(e,n){"string"!=typeof e&&(e=BI.jsonEncode(e)),n=BI.cjkEncode(n),t[n]=BI.cjkEncode(e)})),t}return e},BI.jsonEncode=function(e){var t,n=!!{}.hasOwnProperty,i={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"};if(null==e)return"null";if(BI.isArray(e))return function(e){var t,n,i,r=["["],a=e.length;for(n=0;n<a;n+=1)switch(typeof(i=e[n])){case"undefined":case"function":case"unknown":break;default:t&&r.push(","),r.push(null===i?"null":BI.jsonEncode(i)),t=!0}return r.push("]"),r.join("")}(e);if(e instanceof Date)return BI.jsonEncode({__time__:e.getTime()});if("string"==typeof e)return/["\\\x00-\x1f]/.test(t=e)?'"'+t.replace(/([\x00-\x1f\\"])/g,(function(e,t){var n=i[t];return n||(n=t.charCodeAt(),"\\u00"+Math.floor(n/16).toString(16)+(n%16).toString(16))}))+'"':'"'+t+'"';if("number"==typeof e)return isFinite(e)?String(e):"null";if("boolean"==typeof e)return String(e);if(BI.isFunction(e))return String(e);var r,a,o,s=["{"];for(a in e)if(!n||e.hasOwnProperty(a))switch(typeof(o=e[a])){case"undefined":case"unknown":break;default:r&&s.push(","),s.push(BI.jsonEncode(a),":",null===o?"null":BI.jsonEncode(o)),r=!0}return s.push("}"),s.join("")},BI.jsonDecode=function(e){try{var t=BI.$?BI.$.parseJSON(e):_global.JSON.parse(e);null==t&&(t={})}catch(n){try{t=new Function("return "+e)()||{}}catch(n){}null==t&&(t=[])}if(!function(e){if(!e||"string"!=typeof e)return!1;return-1!=e.indexOf("__time__")}(e))return t;return function(e){if("string"==typeof e)return e;if(e&&null!=e.__time__)return new Date(e.__time__);for(var t in e){if(e[t]==e||"object"==typeof e[t]||_.isFunction(e[t]))break;e[t]=arguments.callee(e[t])}return e}(t)},BI.getEncodeURL=function(e,t){return BI.replaceAll(e,"\\{(.*?)\\}",(function(e,n){return BI.encodeURIComponent(BI.isObject(t)?t[n]:t)}))},BI.encodeURIComponent=function(e){return BI.specialCharsMap=BI.specialCharsMap||{},e=e||"",e=BI.replaceAll(e+"",BI.keys(BI.specialCharsMap||[]).join("|"),(function(e){switch(e){case"\\":return BI.specialCharsMap["\\\\"]||e;default:return BI.specialCharsMap[e]||e}})),_global.encodeURIComponent(e)},BI.decodeURIComponent=function(e){var t={};return BI.each(BI.specialCharsMap,(function(e,n){t[n]="\\\\"===e?"\\":e})),e=e||"",e=BI.replaceAll(e+"",BI.keys(t||[]).join("|"),(function(e){return t[e]||e})),_global.decodeURIComponent(e)},BI.contentFormat=function(e,t){if(isEmpty(e))return"";var n=e.toString();if(isEmpty(t))return n;if(t.match(/^T/))return n;if(t.match(/^D/)){if(e instanceof Date||(e="number"==typeof e?new Date(e):new Date(Date.parse((""+e).replace(/-|\./g,"/")))),!isInvalidDate(e)&&!BI.isNull(e)){var i=t.match(/^DT/);n=BI.date2Str(e,t.substring(i?2:1))}}else n=t.match(/E/)?_eFormat(n,t):_numberFormat(n,t);return n=n.replace(/¤/g,"¥")},BI.parseFmt=function(e){return e?(e=String(e).replace(/y{4,}/g,"%Y").replace(/y{2}/g,"%y").replace(/M{4,}/g,"%b").replace(/M{3}/g,"%B").replace(/M{2}/g,"%X").replace(/M{1}/g,"%x").replace(/a{1}/g,"%p"),e=new RegExp("d{2,}","g").test(e)?e.replace(/d{2,}/g,"%d"):e.replace(/d{1}/g,"%e"),e=new RegExp("h{2,}","g").test(e)?e.replace(/h{2,}/g,"%I"):e.replace(/h{1}/g,"%I"),e=(e=new RegExp("H{2,}","g").test(e)?e.replace(/H{2,}/g,"%H"):e.replace(/H{1}/g,"%H")).replace(/m{2,}/g,"%M").replace(/s{2,}/g,"%S")):""},BI.str2Date=function(e,t){if("string"!=typeof e||"string"!=typeof t)return null;var n=BI.parseFmt(t);return BI.parseDateTime(e,n)},BI.date2Str=function(e,t){if(!e)return"";var n=t.length,i="";if(n>0){for(var r=t.charAt(0),a=0,o=r,s=1;s<n;s++){var l=t.charAt(s);r!==l?(i+=u({char:r,str:o,len:s-a},e),a=s,o=r=l):o+=l}i+=u({char:r,str:o,len:n-a},e)}return i;function u(e,t){var n=e.str,i=e.len;switch(e.char){case"E":n=BI.Date._DN[t.getDay()];break;case"y":n=i<=3?(t.getFullYear()+"").slice(2,4):t.getFullYear();break;case"M":n=i>2?BI.Date._MN[t.getMonth()]:i<2?t.getMonth()+1:BI.leftPad(t.getMonth()+1+"",2,"0");break;case"d":n=i>1?BI.leftPad(t.getDate()+"",2,"0"):t.getDate();break;case"h":var r=t.getHours()%12;0===r&&(r=12),n=i>1?BI.leftPad(r+"",2,"0"):r;break;case"H":n=i>1?BI.leftPad(t.getHours()+"",2,"0"):t.getHours();break;case"m":n=i>1?BI.leftPad(t.getMinutes()+"",2,"0"):t.getMinutes();break;case"s":n=i>1?BI.leftPad(t.getSeconds()+"",2,"0"):t.getSeconds();break;case"a":n=t.getHours()<12?"am":"pm";break;case"z":n=BI.getTimezone(t);break;default:n=e.str}return n}},BI.object2Number=function(e){if(null==e)return 0;if("number"==typeof e)return e;var t=e+"";return-1===t.indexOf(".")?parseInt(t):parseFloat(t)},BI.object2Date=function(e){if(null==e)return new Date;if(e instanceof Date)return e;if("number"==typeof e)return new Date(e);var t=e+"";t=t.replace(/-/g,"/");var n=new Date(t);return isInvalidDate(n)?new Date:n},BI.object2Time=function(e){if(null==e)return new Date;if(e instanceof Date)return e;var t=e+"";t=t.replace(/-/g,"/");var n=new Date(t);return isInvalidDate(n)&&(-1!==t.indexOf("/")||-1===t.indexOf(":")||isInvalidDate(n=new Date("1970/01/01 "+t)))&&isInvalidDate(n=BI.parseDateTime(t,"HH:mm:ss"))?new Date:n}})()}).call(this,__webpack_require__(14))},function(e,t){_.extend(BI,{pushArray:function(e,t){for(var n=0;n<t.length;n++)e.push(t[n])},pushDistinct:function(e,t){BI.contains(e,t)||e.push(t)},pushDistinctArray:function(e,t){for(var n=0,i=t.length;n<i;n++)BI.pushDistinct(e,t[n])}})},function(e,t){BI.Date=BI.Date||{},BI.Date.SECOND=1e3,BI.Date.MINUTE=60*BI.Date.SECOND,BI.Date.HOUR=60*BI.Date.MINUTE,BI.Date.DAY=24*BI.Date.HOUR,BI.Date.WEEK=7*BI.Date.DAY,_.extend(BI,{getTimezone:function(e){return e.toString().replace(/^.* (?:\((.*)\)|([A-Z]{1,4})(?:[\-+][0-9]{4})?(?: -?\d+)?)$/,"$1$2").replace(/[^A-Z]/g,"")},getMonthDays:function(e,t){var n=e.getFullYear();return void 0===t&&(t=e.getMonth()),0!=n%4||0==n%100&&0!=n%400||1!=t?BI.Date._MD[t]:29},getLastDateOfMonth:function(e){return BI.getDate(e.getFullYear(),e.getMonth(),BI.getMonthDays(e))},getDayOfYear:function(e){var t=BI.getDate(e.getFullYear(),e.getMonth(),e.getDate(),0,0,0)-BI.getDate(e.getFullYear(),0,0,0,0,0);return Math.floor(t/BI.Date.DAY)},getWeekNumber:function(e){var t=BI.getDate(e.getFullYear(),e.getMonth(),e.getDate(),0,0,0),n=t.getDay(),i=BI.StartOfWeek%7,r=(i+3)%7,a=n<i?7+n-i:n-i,o=(r=r||7)<i?7+r-i:r-i;t.setDate(t.getDate()-a+o);var s=t.valueOf();return t.setMonth(0),t.setDate(1),Math.floor((s-t.valueOf())/6048e5)+1},getQuarter:function(e){return Math.floor(e.getMonth()/3)+1},getOffsetDate:function(e,t){return BI.getDate(BI.getTime(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds())+864e5*t)},getOffsetQuarter:function(e,t){var n=BI.getDate(BI.getTime(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds())),i=n.getDate(),r=BI.getMonthDays(BI.getDate(n.getFullYear(),n.getMonth()+3*BI.parseInt(t),1));return i>r&&(i=r),n.setDate(i),n.setMonth(n.getMonth()+3*parseInt(t)),n},getQuarterStartMonth:function(e){var t=0,n=e.getMonth();return n<3&&(t=0),2<n&&n<6&&(t=3),5<n&&n<9&&(t=6),n>8&&(t=9),t},getQuarterStartDate:function(e){return BI.getDate(e.getFullYear(),BI.getQuarterStartMonth(e),1)},getQuarterEndDate:function(e){var t=BI.getQuarterStartMonth(e)+2;return BI.getDate(e.getFullYear(),t,BI.getMonthDays(e,t))},getOffsetMonth:function(e,t){var n=BI.getDate(BI.getTime(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds())),i=n.getDate(),r=BI.getMonthDays(BI.getDate(n.getFullYear(),n.getMonth()+parseInt(t),1));return i>r&&(i=r),n.setDate(i),n.setMonth(n.getMonth()+parseInt(t)),n},getWeekStartDate:function(e){var t=e.getDay(),n=BI.StartOfWeek%7;return BI.getOffsetDate(e,BI.Date._OFFSET[t<n?7+t-n:t-n])},getWeekEndDate:function(e){var t=e.getDay(),n=BI.StartOfWeek%7;return BI.getOffsetDate(e,BI.Date._OFFSET[t<n?7+t-n:t-n]+6)},print:function(e,t){for(var n=e.getMonth(),i=e.getDate(),r=e.getFullYear(),a=r+"";a.length<4;)a="0"+a;var o=BI.getWeekNumber(e),s=BI.getQuarter(e),l=e.getDay(),u={},c=e.getHours(),h=c>=12,p=h?c-12:c,d=BI.getDayOfYear(e);0==p&&(p=12);var f=e.getMinutes(),g=e.getSeconds();u["%a"]=BI.Date._SDN[l],u["%A"]=BI.Date._DN[l],u["%b"]=BI.Date._SMN[n],u["%B"]=BI.Date._MN[n],u["%C"]=1+Math.floor(r/100),u["%d"]=i<10?"0"+i:i,u["%e"]=i,u["%H"]=c<10?"0"+c:c,u["%I"]=p<10?"0"+p:p,u["%j"]=d<100?d<10?"00"+d:"0"+d:d,u["%k"]=c+"",u["%l"]=p+"",u["%X"]=n<9?"0"+(1+n):1+n,u["%x"]=n+1,u["%M"]=f<10?"0"+f:f,u["%n"]="\n",u["%p"]=h?"PM":"AM",u["%P"]=h?"pm":"am",u["%s"]=Math.floor(e.getTime()/1e3),u["%S"]=g<10?"0"+g:g,u["%t"]="\t",u["%U"]=u["%W"]=u["%V"]=o<10?"0"+o:o,u["%u"]=l+1,u["%w"]=l,u["%y"]=a.substr(2,2),u["%Y"]=a,u["%%"]="%",u["%q"]="0"+s,u["%Q"]=s;var m=/%./g;if(BI.isKhtml=BI.isKhtml||function(){return!!_global.navigator&&/Konqueror|Safari|KHTML/i.test(navigator.userAgent)},!(-1===t.indexOf("%Y")&&-1===t.indexOf("%y")||-1===t.indexOf("%W")&&-1===t.indexOf("%U")&&-1===t.indexOf("%V")))switch(o){case 1:11===n&&(u["%y"]=parseInt(u["%y"])+1,u["%Y"]=parseInt(u["%Y"])+1);break;case 53:0===n&&(u["%y"]=parseInt(u["%y"])-1,u["%Y"]=parseInt(u["%Y"])-1)}if(!BI.isKhtml())return t.replace(m,(function(e){return u[e]||e}));for(var I=t.match(m),B=0;B<I.length;B++){var _=u[I[B]];_&&(m=new RegExp(I[B],"g"),t=t.replace(m,_))}return t}})},function(e,t){BI.Func=BI.Func||{},_.extend(BI.Func,{createDistinctName:function(e,t){var n=t,i=1;for(t=t||"";!BI.every(e,(function(e,n){return BI.isKey(n)?n!==t:n.name!==t}));)t=n+i++;return t},getGBWidth:function(e){return e=(e+="").replace(/[^\x00-\xff]/g,"xx"),Math.ceil(e.length/2)},getSearchResult:function(e,t,n,i){var r,a,o,s=BI.isArray(e);if(e=s?BI.flatten(e):e,n||(n="text"),BI.isNull(i)&&(i=!0),!BI.isKey(t))return{find:i?BI.deepClone(e):e,match:s?[]:{}};t=BI.toUpperCase(t);var l=s?[]:{},u=s?[]:{};return BI.each(e,(function(e,c){BI.isNull(c)||(i&&(c=BI.deepClone(c)),r=BI.stripEL(c),a=BI.find([r[n],r.text,r.value,r.name,r],(function(e,t){return BI.isNotNull(t)})),BI.isNull(a)||BI.isObject(a)||(o=BI.makeFirstPY(a,{splitChar:""}),a=BI.toUpperCase(a),o=BI.toUpperCase(o),a.indexOf(t)>-1?a===t?s?l.push(c):l[e]=c:s?u.push(c):u[e]=c:o.indexOf(t)>-1&&(a===t||t.length===a.length?s?l.push(c):l[e]=c:s?u.push(c):u[e]=c)))})),{match:l,find:u}},getSortedResult:function(e,t){var n=BI.isFunction(t)?t:function(e,t){return BI.isNotNull(t)?e[t]:BI.isNotNull(e.text)?e.text:BI.isNotNull(e.value)?e.value:e};return e.sort((function(e,i){var r=n(e,t),a=n(i,t);if(BI.isNull(r)&&BI.isNull(a))return 0;if(BI.isNull(r))return-1;if(BI.isNull(a))return 1;if(r===a)return 0;for(var o=r.length,s=a.length,l=0;l<o&&l<s;l++){var u=r[l],c=a[l];if(u!==c)return(BI.isNull(BI.CODE_INDEX[u])?BI.MAX:BI.CODE_INDEX[u])-(BI.isNull(BI.CODE_INDEX[c])?BI.MAX:BI.CODE_INDEX[c])}return o-s}))}}),_.extend(BI,{beforeFunc:function(e,t){var n=e;return function(){return!1!==t.apply(e,arguments)&&n.apply(e,arguments)}},afterFunc:function(e,t){var n=e;return function(){var i=n.apply(e,arguments);return!1!==i&&(t.apply(e,arguments),i)}}})},function(e,t){_.extend(BI,{add:function(e,t){return function(e,t){var n,i,r,a;try{n=e.toString().split(".")[1].length}catch(s){n=0}try{i=t.toString().split(".")[1].length}catch(s){i=0}if(a=Math.abs(n-i),r=Math.pow(10,Math.max(n,i)),a>0){var o=Math.pow(10,a);n>i?(e=Number(e.toString().replace(".","")),t=Number(t.toString().replace(".",""))*o):(e=Number(e.toString().replace(".",""))*o,t=Number(t.toString().replace(".","")))}else e=Number(e.toString().replace(".","")),t=Number(t.toString().replace(".",""));return(e+t)/r}(t,e)},sub:function(e,t){return function(e,t){var n,i,r;try{n=e.toString().split(".")[1].length}catch(a){n=0}try{i=t.toString().split(".")[1].length}catch(a){i=0}return r=Math.pow(10,Math.max(n,i)),((e*r-t*r)/r).toFixed(n>=i?n:i)}(e,t)},mul:function(e,t){return function(e,t){var n=0,i=e.toString(),r=t.toString();try{n+=i.split(".")[1].length}catch(a){}try{n+=r.split(".")[1].length}catch(a){}return Number(i.replace(".",""))*Number(r.replace(".",""))/Math.pow(10,n)}(t,e)},div:function(e,t){return function a(e,t){for(var o=[],s=2;s<arguments.length;s++)o[s-2]=arguments[s];if(o.length>0)return a.apply(void 0,[a(e,t),o[0]].concat(o.slice(1)));var l=i(e),u=i(t);return r(l/u,Math.pow(10,n(t)-n(e)))}(e,t);function n(e){var t=e.toString().split(/[eE]/),n=(t[0].split(".")[1]||"").length-+(t[1]||0);return n>0?n:0}function i(e){if(-1===e.toString().indexOf("e"))return Number(e.toString().replace(".",""));var t=n(e);return t>0?e*Math.pow(10,t):e}function r(e,t){for(var a=[],o=2;o<arguments.length;o++)a[o-2]=arguments[o];if(a.length>0)return r.apply(void 0,[r(e,t),a[0]].concat(a.slice(1)));var s=i(e),l=i(t),u=n(e)+n(t),c=s*l;return c/Math.pow(10,u)}}})},function(e,t){_.extend(BI,{startWith:function(e,t){return e=e||"",!(null==t||""==t||0===e.length||t.length>e.length)&&e.substr(0,t.length)==t},endWith:function(e,t){return!(null==t||""==t||0===e.length||t.length>e.length)&&e.substring(e.length-t.length)==t},getQuery:function(e,t){var n=new RegExp("(^|&)"+t+"=([^&]*)(&|$)"),i=e.substr(e.indexOf("?")+1).match(n);return i?unescape(i[2]):null},appendQuery:function(e,t){if(!t)return e;var n=e;return-1===n.indexOf("?")&&(n+="?"),!1!==BI.endWith(n,"?")||(n+="&"),_.each(t,(function(e,t){"string"==typeof t&&(n+=t+"="+e+"&")})),n=n.substr(0,n.length-1)},replaceAll:function(e,t,n){return BI.isString(e)?e.replace(new RegExp(t,"gm"),n):e},perfectStart:function(e,t){return BI.startWith(e,t)?e:t+e},allIndexOf:function(e,t){if("string"!=typeof t)return[];for(var n=[],i=0;e.length>0;){var r=e.indexOf(t);if(-1===r)break;n.push(i+r),e=e.substring(r+t.length,e.length),i+=r+t.length}return n}})},function(e,t){var n,i;n={19969:"DZ",19975:"WM",19988:"QJ",20048:"YL",20056:"SC",20060:"NM",20094:"QG",20127:"QJ",20167:"QC",20193:"YG",20250:"KH",20256:"ZC",20282:"SC",20285:"QJG",20291:"TD",20314:"YD",20315:"BF",20340:"NE",20375:"TD",20389:"YJ",20391:"CZ",20415:"PB",20446:"YS",20447:"SQ",20504:"TC",20608:"KG",20854:"QJ",20857:"ZC",20911:"PF",20985:"AW",21032:"PB",21048:"XQ",21049:"SC",21089:"YS",21119:"JC",21242:"SB",21273:"SC",21305:"YP",21306:"QO",21330:"ZC",21333:"SDC",21345:"QK",21378:"CA",21397:"SC",21414:"XS",21442:"SC",21477:"JG",21480:"TD",21484:"ZS",21494:"YX",21505:"YX",21512:"HG",21523:"XH",21537:"PB",21542:"PF",21549:"KH",21571:"E",21574:"DA",21588:"TD",21589:"O",21618:"ZC",21621:"KHA",21632:"ZJ",21654:"KG",21679:"LKG",21683:"KH",21710:"A",21719:"YH",21734:"WOE",21769:"A",21780:"WN",21804:"XH",21834:"A",21899:"ZD",21903:"RN",21908:"WO",21939:"ZC",21956:"SA",21964:"YA",21970:"TD",22003:"A",22031:"JG",22040:"XS",22060:"ZC",22066:"ZC",22079:"MH",22129:"XJ",22179:"XA",22237:"NJ",22244:"TD",22280:"JQ",22300:"YH",22313:"XW",22331:"YQ",22343:"YJ",22351:"PH",22395:"DC",22412:"TD",22484:"PB",22500:"PB",22534:"ZD",22549:"DH",22561:"PB",22612:"TD",22771:"KQ",22831:"HB",22841:"JG",22855:"QJ",22865:"XQ",23013:"ML",23081:"WM",23487:"SX",23558:"QJ",23561:"YW",23586:"YW",23614:"YW",23615:"SN",23631:"PB",23646:"ZS",23663:"ZT",23673:"YG",23762:"TD",23769:"ZS",23780:"QJ",23884:"QK",24055:"XH",24113:"DC",24162:"ZC",24191:"GA",24273:"QJ",24324:"NL",24377:"TD",24378:"QJ",24439:"PF",24554:"ZS",24683:"TD",24694:"WE",24733:"LK",24925:"TN",25094:"ZG",25100:"XQ",25103:"XH",25153:"PB",25170:"PB",25179:"KG",25203:"PB",25240:"ZS",25282:"FB",25303:"NA",25324:"KG",25341:"ZY",25373:"WZ",25375:"XJ",25384:"A",25457:"A",25528:"SD",25530:"SC",25552:"TD",25774:"ZC",25874:"ZC",26044:"YW",26080:"WM",26292:"PB",26333:"PB",26355:"ZY",26366:"CZ",26397:"ZC",26399:"QJ",26415:"ZS",26451:"SB",26526:"ZC",26552:"JG",26561:"TD",26588:"JG",26597:"CZ",26629:"ZS",26638:"YL",26646:"XQ",26653:"KG",26657:"XJ",26727:"HG",26894:"ZC",26937:"ZS",26946:"ZC",26999:"KJ",27099:"KJ",27449:"YQ",27481:"XS",27542:"ZS",27663:"ZS",27748:"TS",27784:"SC",27788:"ZD",27795:"TD",27812:"O",27850:"PB",27852:"MB",27895:"SL",27898:"PL",27973:"QJ",27981:"KH",27986:"HX",27994:"XJ",28044:"YC",28065:"WG",28177:"SM",28267:"QJ",28291:"KH",28337:"ZQ",28463:"TL",28548:"DC",28601:"TD",28689:"PB",28805:"JG",28820:"QG",28846:"PB",28952:"TD",28975:"ZC",29100:"A",29325:"QJ",29575:"SL",29602:"FB",30010:"TD",30044:"CX",30058:"PF",30091:"YSP",30111:"YN",30229:"XJ",30427:"SC",30465:"SX",30631:"YQ",30655:"QJ",30684:"QJG",30707:"SD",30729:"XH",30796:"LG",30917:"PB",31074:"NM",31085:"JZ",31109:"SC",31181:"ZC",31192:"MLB",31293:"JQ",31400:"YX",31584:"YJ",31896:"ZN",31909:"ZY",31995:"XJ",32321:"PF",32327:"ZY",32418:"HG",32420:"XQ",32421:"HG",32438:"LG",32473:"GJ",32488:"TD",32521:"QJ",32527:"PB",32562:"ZSQ",32564:"JZ",32735:"ZD",32793:"PB",33071:"PF",33098:"XL",33100:"YA",33152:"PB",33261:"CX",33324:"BP",33333:"TD",33406:"YA",33426:"WM",33432:"PB",33445:"JG",33486:"ZN",33493:"TS",33507:"QJ",33540:"QJ",33544:"ZC",33564:"XQ",33617:"YT",33632:"QJ",33636:"XH",33637:"YX",33694:"WG",33705:"PF",33728:"YW",33882:"SR",34067:"WM",34074:"YW",34121:"QJ",34255:"ZC",34259:"XL",34425:"JH",34430:"XH",34485:"KH",34503:"YS",34532:"HG",34552:"XS",34558:"YE",34593:"ZL",34660:"YQ",34892:"XH",34928:"SC",34999:"QJ",35048:"PB",35059:"SC",35098:"ZC",35203:"TQ",35265:"JX",35299:"JX",35782:"SZ",35828:"YS",35830:"E",35843:"TD",35895:"YG",35977:"MH",36158:"JG",36228:"QJ",36426:"XQ",36466:"DC",36710:"CJ",36711:"ZYG",36767:"PB",36866:"SK",36951:"YW",37034:"YX",37063:"XH",37218:"ZC",37325:"ZC",38063:"PB",38079:"TD",38085:"QY",38107:"DC",38116:"TD",38123:"YD",38224:"HG",38241:"XTC",38271:"ZC",38415:"YE",38426:"KH",38461:"YD",38463:"AE",38466:"PB",38477:"XJ",38518:"YT",38551:"WK",38585:"ZC",38704:"XS",38739:"LJ",38761:"GJ",38808:"SQ",39048:"JG",39049:"XJ",39052:"HG",39076:"CZ",39271:"XT",39534:"TD",39552:"TD",39584:"PB",39647:"SB",39730:"LG",39748:"TPB",40109:"ZQ",40479:"ND",40516:"HG",40536:"HG",40583:"QJ",40765:"YQ",40784:"QJ",40840:"YK",40863:"QJG"},i=function(e){var t=e.charCodeAt(0);return t>40869||t<19968?e:n[t]?n[t]:"YDYQSXMWZSSXJBYMGCCZQPSSQBYCDSCDQLDYLYBSSJGYZZJJFKCCLZDHWDWZJLJPFYYNWJJTMYHZWZHFLZPPQHGSCYYYNJQYXXGJHHSDSJNKKTMOMLCRXYPSNQSECCQZGGLLYJLMYZZSECYKYYHQWJSSGGYXYZYJWWKDJHYCHMYXJTLXJYQBYXZLDWRDJRWYSRLDZJPCBZJJBRCFTLECZSTZFXXZHTRQHYBDLYCZSSYMMRFMYQZPWWJJYFCRWFDFZQPYDDWYXKYJAWJFFXYPSFTZYHHYZYSWCJYXSCLCXXWZZXNBGNNXBXLZSZSBSGPYSYZDHMDZBQBZCWDZZYYTZHBTSYYBZGNTNXQYWQSKBPHHLXGYBFMJEBJHHGQTJCYSXSTKZHLYCKGLYSMZXYALMELDCCXGZYRJXSDLTYZCQKCNNJWHJTZZCQLJSTSTBNXBTYXCEQXGKWJYFLZQLYHYXSPSFXLMPBYSXXXYDJCZYLLLSJXFHJXPJBTFFYABYXBHZZBJYZLWLCZGGBTSSMDTJZXPTHYQTGLJSCQFZKJZJQNLZWLSLHDZBWJNCJZYZSQQYCQYRZCJJWYBRTWPYFTWEXCSKDZCTBZHYZZYYJXZCFFZZMJYXXSDZZOTTBZLQWFCKSZSXFYRLNYJMBDTHJXSQQCCSBXYYTSYFBXDZTGBCNSLCYZZPSAZYZZSCJCSHZQYDXLBPJLLMQXTYDZXSQJTZPXLCGLQTZWJBHCTSYJSFXYEJJTLBGXSXJMYJQQPFZASYJNTYDJXKJCDJSZCBARTDCLYJQMWNQNCLLLKBYBZZSYHQQLTWLCCXTXLLZNTYLNEWYZYXCZXXGRKRMTCNDNJTSYYSSDQDGHSDBJGHRWRQLYBGLXHLGTGXBQJDZPYJSJYJCTMRNYMGRZJCZGJMZMGXMPRYXKJNYMSGMZJYMKMFXMLDTGFBHCJHKYLPFMDXLQJJSMTQGZSJLQDLDGJYCALCMZCSDJLLNXDJFFFFJCZFMZFFPFKHKGDPSXKTACJDHHZDDCRRCFQYJKQCCWJDXHWJLYLLZGCFCQDSMLZPBJJPLSBCJGGDCKKDEZSQCCKJGCGKDJTJDLZYCXKLQSCGJCLTFPCQCZGWPJDQYZJJBYJHSJDZWGFSJGZKQCCZLLPSPKJGQJHZZLJPLGJGJJTHJJYJZCZMLZLYQBGJWMLJKXZDZNJQSYZMLJLLJKYWXMKJLHSKJGBMCLYYMKXJQLBMLLKMDXXKWYXYSLMLPSJQQJQXYXFJTJDXMXXLLCXQBSYJBGWYMBGGBCYXPJYGPEPFGDJGBHBNSQJYZJKJKHXQFGQZKFHYGKHDKLLSDJQXPQYKYBNQSXQNSZSWHBSXWHXWBZZXDMNSJBSBKBBZKLYLXGWXDRWYQZMYWSJQLCJXXJXKJEQXSCYETLZHLYYYSDZPAQYZCMTLSHTZCFYZYXYLJSDCJQAGYSLCQLYYYSHMRQQKLDXZSCSSSYDYCJYSFSJBFRSSZQSBXXPXJYSDRCKGJLGDKZJZBDKTCSYQPYHSTCLDJDHMXMCGXYZHJDDTMHLTXZXYLYMOHYJCLTYFBQQXPFBDFHHTKSQHZYYWCNXXCRWHOWGYJLEGWDQCWGFJYCSNTMYTOLBYGWQWESJPWNMLRYDZSZTXYQPZGCWXHNGPYXSHMYQJXZTDPPBFYHZHTJYFDZWKGKZBLDNTSXHQEEGZZYLZMMZYJZGXZXKHKSTXNXXWYLYAPSTHXDWHZYMPXAGKYDXBHNHXKDPJNMYHYLPMGOCSLNZHKXXLPZZLBMLSFBHHGYGYYGGBHSCYAQTYWLXTZQCEZYDQDQMMHTKLLSZHLSJZWFYHQSWSCWLQAZYNYTLSXTHAZNKZZSZZLAXXZWWCTGQQTDDYZTCCHYQZFLXPSLZYGPZSZNGLNDQTBDLXGTCTAJDKYWNSYZLJHHZZCWNYYZYWMHYCHHYXHJKZWSXHZYXLYSKQYSPSLYZWMYPPKBYGLKZHTYXAXQSYSHXASMCHKDSCRSWJPWXSGZJLWWSCHSJHSQNHCSEGNDAQTBAALZZMSSTDQJCJKTSCJAXPLGGXHHGXXZCXPDMMHLDGTYBYSJMXHMRCPXXJZCKZXSHMLQXXTTHXWZFKHCCZDYTCJYXQHLXDHYPJQXYLSYYDZOZJNYXQEZYSQYAYXWYPDGXDDXSPPYZNDLTWRHXYDXZZJHTCXMCZLHPYYYYMHZLLHNXMYLLLMDCPPXHMXDKYCYRDLTXJCHHZZXZLCCLYLNZSHZJZZLNNRLWHYQSNJHXYNTTTKYJPYCHHYEGKCTTWLGQRLGGTGTYGYHPYHYLQYQGCWYQKPYYYTTTTLHYHLLTYTTSPLKYZXGZWGPYDSSZZDQXSKCQNMJJZZBXYQMJRTFFBTKHZKBXLJJKDXJTLBWFZPPTKQTZTGPDGNTPJYFALQMKGXBDCLZFHZCLLLLADPMXDJHLCCLGYHDZFGYDDGCYYFGYDXKSSEBDHYKDKDKHNAXXYBPBYYHXZQGAFFQYJXDMLJCSQZLLPCHBSXGJYNDYBYQSPZWJLZKSDDTACTBXZDYZYPJZQSJNKKTKNJDJGYYPGTLFYQKASDNTCYHBLWDZHBBYDWJRYGKZYHEYYFJMSDTYFZJJHGCXPLXHLDWXXJKYTCYKSSSMTWCTTQZLPBSZDZWZXGZAGYKTYWXLHLSPBCLLOQMMZSSLCMBJCSZZKYDCZJGQQDSMCYTZQQLWZQZXSSFPTTFQMDDZDSHDTDWFHTDYZJYQJQKYPBDJYYXTLJHDRQXXXHAYDHRJLKLYTWHLLRLLRCXYLBWSRSZZSYMKZZHHKYHXKSMDSYDYCJPBZBSQLFCXXXNXKXWYWSDZYQOGGQMMYHCDZTTFJYYBGSTTTYBYKJDHKYXBELHTYPJQNFXFDYKZHQKZBYJTZBXHFDXKDASWTAWAJLDYJSFHBLDNNTNQJTJNCHXFJSRFWHZFMDRYJYJWZPDJKZYJYMPCYZNYNXFBYTFYFWYGDBNZZZDNYTXZEMMQBSQEHXFZMBMFLZZSRXYMJGSXWZJSPRYDJSJGXHJJGLJJYNZZJXHGXKYMLPYYYCXYTWQZSWHWLYRJLPXSLSXMFSWWKLCTNXNYNPSJSZHDZEPTXMYYWXYYSYWLXJQZQXZDCLEEELMCPJPCLWBXSQHFWWTFFJTNQJHJQDXHWLBYZNFJLALKYYJLDXHHYCSTYYWNRJYXYWTRMDRQHWQCMFJDYZMHMYYXJWMYZQZXTLMRSPWWCHAQBXYGZYPXYYRRCLMPYMGKSJSZYSRMYJSNXTPLNBAPPYPYLXYYZKYNLDZYJZCZNNLMZHHARQMPGWQTZMXXMLLHGDZXYHXKYXYCJMFFYYHJFSBSSQLXXNDYCANNMTCJCYPRRNYTYQNYYMBMSXNDLYLYSLJRLXYSXQMLLYZLZJJJKYZZCSFBZXXMSTBJGNXYZHLXNMCWSCYZYFZLXBRNNNYLBNRTGZQYSATSWRYHYJZMZDHZGZDWYBSSCSKXSYHYTXXGCQGXZZSHYXJSCRHMKKBXCZJYJYMKQHZJFNBHMQHYSNJNZYBKNQMCLGQHWLZNZSWXKHLJHYYBQLBFCDSXDLDSPFZPSKJYZWZXZDDXJSMMEGJSCSSMGCLXXKYYYLNYPWWWGYDKZJGGGZGGSYCKNJWNJPCXBJJTQTJWDSSPJXZXNZXUMELPXFSXTLLXCLJXJJLJZXCTPSWXLYDHLYQRWHSYCSQYYBYAYWJJJQFWQCQQCJQGXALDBZZYJGKGXPLTZYFXJLTPADKYQHPMATLCPDCKBMTXYBHKLENXDLEEGQDYMSAWHZMLJTWYGXLYQZLJEEYYBQQFFNLYXRDSCTGJGXYYNKLLYQKCCTLHJLQMKKZGCYYGLLLJDZGYDHZWXPYSJBZKDZGYZZHYWYFQYTYZSZYEZZLYMHJJHTSMQWYZLKYYWZCSRKQYTLTDXWCTYJKLWSQZWBDCQYNCJSRSZJLKCDCDTLZZZACQQZZDDXYPLXZBQJYLZLLLQDDZQJYJYJZYXNYYYNYJXKXDAZWYRDLJYYYRJLXLLDYXJCYWYWNQCCLDDNYYYNYCKCZHXXCCLGZQJGKWPPCQQJYSBZZXYJSQPXJPZBSBDSFNSFPZXHDWZTDWPPTFLZZBZDMYYPQJRSDZSQZSQXBDGCPZSWDWCSQZGMDHZXMWWFYBPDGPHTMJTHZSMMBGZMBZJCFZWFZBBZMQCFMBDMCJXLGPNJBBXGYHYYJGPTZGZMQBQTCGYXJXLWZKYDPDYMGCFTPFXYZTZXDZXTGKMTYBBCLBJASKYTSSQYYMSZXFJEWLXLLSZBQJJJAKLYLXLYCCTSXMCWFKKKBSXLLLLJYXTYLTJYYTDPJHNHNNKBYQNFQYYZBYYESSESSGDYHFHWTCJBSDZZTFDMXHCNJZYMQWSRYJDZJQPDQBBSTJGGFBKJBXTGQHNGWJXJGDLLTHZHHYYYYYYSXWTYYYCCBDBPYPZYCCZYJPZYWCBDLFWZCWJDXXHYHLHWZZXJTCZLCDPXUJCZZZLYXJJTXPHFXWPYWXZPTDZZBDZCYHJHMLXBQXSBYLRDTGJRRCTTTHYTCZWMXFYTWWZCWJWXJYWCSKYBZSCCTZQNHXNWXXKHKFHTSWOCCJYBCMPZZYKBNNZPBZHHZDLSYDDYTYFJPXYNGFXBYQXCBHXCPSXTYZDMKYSNXSXLHKMZXLYHDHKWHXXSSKQYHHCJYXGLHZXCSNHEKDTGZXQYPKDHEXTYKCNYMYYYPKQYYYKXZLTHJQTBYQHXBMYHSQCKWWYLLHCYYLNNEQXQWMCFBDCCMLJGGXDQKTLXKGNQCDGZJWYJJLYHHQTTTNWCHMXCXWHWSZJYDJCCDBQCDGDNYXZTHCQRXCBHZTQCBXWGQWYYBXHMBYMYQTYEXMQKYAQYRGYZSLFYKKQHYSSQYSHJGJCNXKZYCXSBXYXHYYLSTYCXQTHYSMGSCPMMGCCCCCMTZTASMGQZJHKLOSQYLSWTMXSYQKDZLJQQYPLSYCZTCQQPBBQJZCLPKHQZYYXXDTDDTSJCXFFLLCHQXMJLWCJCXTSPYCXNDTJSHJWXDQQJSKXYAMYLSJHMLALYKXCYYDMNMDQMXMCZNNCYBZKKYFLMCHCMLHXRCJJHSYLNMTJZGZGYWJXSRXCWJGJQHQZDQJDCJJZKJKGDZQGJJYJYLXZXXCDQHHHEYTMHLFSBDJSYYSHFYSTCZQLPBDRFRZTZYKYWHSZYQKWDQZRKMSYNBCRXQBJYFAZPZZEDZCJYWBCJWHYJBQSZYWRYSZPTDKZPFPBNZTKLQYHBBZPNPPTYZZYBQNYDCPJMMCYCQMCYFZZDCMNLFPBPLNGQJTBTTNJZPZBBZNJKLJQYLNBZQHKSJZNGGQSZZKYXSHPZSNBCGZKDDZQANZHJKDRTLZLSWJLJZLYWTJNDJZJHXYAYNCBGTZCSSQMNJPJYTYSWXZFKWJQTKHTZPLBHSNJZSYZBWZZZZLSYLSBJHDWWQPSLMMFBJDWAQYZTCJTBNNWZXQXCDSLQGDSDPDZHJTQQPSWLYYJZLGYXYZLCTCBJTKTYCZJTQKBSJLGMGZDMCSGPYNJZYQYYKNXRPWSZXMTNCSZZYXYBYHYZAXYWQCJTLLCKJJTJHGDXDXYQYZZBYWDLWQCGLZGJGQRQZCZSSBCRPCSKYDZNXJSQGXSSJMYDNSTZTPBDLTKZWXQWQTZEXNQCZGWEZKSSBYBRTSSSLCCGBPSZQSZLCCGLLLZXHZQTHCZMQGYZQZNMCOCSZJMMZSQPJYGQLJYJPPLDXRGZYXCCSXHSHGTZNLZWZKJCXTCFCJXLBMQBCZZWPQDNHXLJCTHYZLGYLNLSZZPCXDSCQQHJQKSXZPBAJYEMSMJTZDXLCJYRYYNWJBNGZZTMJXLTBSLYRZPYLSSCNXPHLLHYLLQQZQLXYMRSYCXZLMMCZLTZSDWTJJLLNZGGQXPFSKYGYGHBFZPDKMWGHCXMSGDXJMCJZDYCABXJDLNBCDQYGSKYDQTXDJJYXMSZQAZDZFSLQXYJSJZYLBTXXWXQQZBJZUFBBLYLWDSLJHXJYZJWTDJCZFQZQZZDZSXZZQLZCDZFJHYSPYMPQZMLPPLFFXJJNZZYLSJEYQZFPFZKSYWJJJHRDJZZXTXXGLGHYDXCSKYSWMMZCWYBAZBJKSHFHJCXMHFQHYXXYZFTSJYZFXYXPZLCHMZMBXHZZSXYFYMNCWDABAZLXKTCSHHXKXJJZJSTHYGXSXYYHHHJWXKZXSSBZZWHHHCWTZZZPJXSNXQQJGZYZYWLLCWXZFXXYXYHXMKYYSWSQMNLNAYCYSPMJKHWCQHYLAJJMZXHMMCNZHBHXCLXTJPLTXYJHDYYLTTXFSZHYXXSJBJYAYRSMXYPLCKDUYHLXRLNLLSTYZYYQYGYHHSCCSMZCTZQXKYQFPYYRPFFLKQUNTSZLLZMWWTCQQYZWTLLMLMPWMBZSSTZRBPDDTLQJJBXZCSRZQQYGWCSXFWZLXCCRSZDZMCYGGDZQSGTJSWLJMYMMZYHFBJDGYXCCPSHXNZCSBSJYJGJMPPWAFFYFNXHYZXZYLREMZGZCYZSSZDLLJCSQFNXZKPTXZGXJJGFMYYYSNBTYLBNLHPFZDCYFBMGQRRSSSZXYSGTZRNYDZZCDGPJAFJFZKNZBLCZSZPSGCYCJSZLMLRSZBZZLDLSLLYSXSQZQLYXZLSKKBRXBRBZCYCXZZZEEYFGKLZLYYHGZSGZLFJHGTGWKRAAJYZKZQTSSHJJXDCYZUYJLZYRZDQQHGJZXSSZBYKJPBFRTJXLLFQWJHYLQTYMBLPZDXTZYGBDHZZRBGXHWNJTJXLKSCFSMWLSDQYSJTXKZSCFWJLBXFTZLLJZLLQBLSQMQQCGCZFPBPHZCZJLPYYGGDTGWDCFCZQYYYQYSSCLXZSKLZZZGFFCQNWGLHQYZJJCZLQZZYJPJZZBPDCCMHJGXDQDGDLZQMFGPSYTSDYFWWDJZJYSXYYCZCYHZWPBYKXRYLYBHKJKSFXTZJMMCKHLLTNYYMSYXYZPYJQYCSYCWMTJJKQYRHLLQXPSGTLYYCLJSCPXJYZFNMLRGJJTYZBXYZMSJYJHHFZQMSYXRSZCWTLRTQZSSTKXGQKGSPTGCZNJSJCQCXHMXGGZTQYDJKZDLBZSXJLHYQGGGTHQSZPYHJHHGYYGKGGCWJZZYLCZLXQSFTGZSLLLMLJSKCTBLLZZSZMMNYTPZSXQHJCJYQXYZXZQZCPSHKZZYSXCDFGMWQRLLQXRFZTLYSTCTMJCXJJXHJNXTNRZTZFQYHQGLLGCXSZSJDJLJCYDSJTLNYXHSZXCGJZYQPYLFHDJSBPCCZHJJJQZJQDYBSSLLCMYTTMQTBHJQNNYGKYRQYQMZGCJKPDCGMYZHQLLSLLCLMHOLZGDYYFZSLJCQZLYLZQJESHNYLLJXGJXLYSYYYXNBZLJSSZCQQCJYLLZLTJYLLZLLBNYLGQCHXYYXOXCXQKYJXXXYKLXSXXYQXCYKQXQCSGYXXYQXYGYTQOHXHXPYXXXULCYEYCHZZCBWQBBWJQZSCSZSSLZYLKDESJZWMYMCYTSDSXXSCJPQQSQYLYYZYCMDJDZYWCBTJSYDJKCYDDJLBDJJSODZYSYXQQYXDHHGQQYQHDYXWGMMMAJDYBBBPPBCMUUPLJZSMTXERXJMHQNUTPJDCBSSMSSSTKJTSSMMTRCPLZSZMLQDSDMJMQPNQDXCFYNBFSDQXYXHYAYKQYDDLQYYYSSZBYDSLNTFQTZQPZMCHDHCZCWFDXTMYQSPHQYYXSRGJCWTJTZZQMGWJJTJHTQJBBHWZPXXHYQFXXQYWYYHYSCDYDHHQMNMTMWCPBSZPPZZGLMZFOLLCFWHMMSJZTTDHZZYFFYTZZGZYSKYJXQYJZQBHMBZZLYGHGFMSHPZFZSNCLPBQSNJXZSLXXFPMTYJYGBXLLDLXPZJYZJYHHZCYWHJYLSJEXFSZZYWXKZJLUYDTMLYMQJPWXYHXSKTQJEZRPXXZHHMHWQPWQLYJJQJJZSZCPHJLCHHNXJLQWZJHBMZYXBDHHYPZLHLHLGFWLCHYYTLHJXCJMSCPXSTKPNHQXSRTYXXTESYJCTLSSLSTDLLLWWYHDHRJZSFGXTSYCZYNYHTDHWJSLHTZDQDJZXXQHGYLTZPHCSQFCLNJTCLZPFSTPDYNYLGMJLLYCQHYSSHCHYLHQYQTMZYPBYWRFQYKQSYSLZDQJMPXYYSSRHZJNYWTQDFZBWWTWWRXCWHGYHXMKMYYYQMSMZHNGCEPMLQQMTCWCTMMPXJPJJHFXYYZSXZHTYBMSTSYJTTQQQYYLHYNPYQZLCYZHZWSMYLKFJXLWGXYPJYTYSYXYMZCKTTWLKSMZSYLMPWLZWXWQZSSAQSYXYRHSSNTSRAPXCPWCMGDXHXZDZYFJHGZTTSBJHGYZSZYSMYCLLLXBTYXHBBZJKSSDMALXHYCFYGMQYPJYCQXJLLLJGSLZGQLYCJCCZOTYXMTMTTLLWTGPXYMZMKLPSZZZXHKQYSXCTYJZYHXSHYXZKXLZWPSQPYHJWPJPWXQQYLXSDHMRSLZZYZWTTCYXYSZZSHBSCCSTPLWSSCJCHNLCGCHSSPHYLHFHHXJSXYLLNYLSZDHZXYLSXLWZYKCLDYAXZCMDDYSPJTQJZLNWQPSSSWCTSTSZLBLNXSMNYYMJQBQHRZWTYYDCHQLXKPZWBGQYBKFCMZWPZLLYYLSZYDWHXPSBCMLJBSCGBHXLQHYRLJXYSWXWXZSLDFHLSLYNJLZYFLYJYCDRJLFSYZFSLLCQYQFGJYHYXZLYLMSTDJCYHBZLLNWLXXYGYYHSMGDHXXHHLZZJZXCZZZCYQZFNGWPYLCPKPYYPMCLQKDGXZGGWQBDXZZKZFBXXLZXJTPJPTTBYTSZZDWSLCHZHSLTYXHQLHYXXXYYZYSWTXZKHLXZXZPYHGCHKCFSYHUTJRLXFJXPTZTWHPLYXFCRHXSHXKYXXYHZQDXQWULHYHMJTBFLKHTXCWHJFWJCFPQRYQXCYYYQYGRPYWSGSUNGWCHKZDXYFLXXHJJBYZWTSXXNCYJJYMSWZJQRMHXZWFQSYLZJZGBHYNSLBGTTCSYBYXXWXYHXYYXNSQYXMQYWRGYQLXBBZLJSYLPSYTJZYHYZAWLRORJMKSCZJXXXYXCHDYXRYXXJDTSQFXLYLTSFFYXLMTYJMJUYYYXLTZCSXQZQHZXLYYXZHDNBRXXXJCTYHLBRLMBRLLAXKYLLLJLYXXLYCRYLCJTGJCMTLZLLCYZZPZPCYAWHJJFYBDYYZSMPCKZDQYQPBPCJPDCYZMDPBCYYDYCNNPLMTMLRMFMMGWYZBSJGYGSMZQQQZTXMKQWGXLLPJGZBQCDJJJFPKJKCXBLJMSWMDTQJXLDLPPBXCWRCQFBFQJCZAHZGMYKPHYYHZYKNDKZMBPJYXPXYHLFPNYYGXJDBKXNXHJMZJXSTRSTLDXSKZYSYBZXJLXYSLBZYSLHXJPFXPQNBYLLJQKYGZMCYZZYMCCSLCLHZFWFWYXZMWSXTYNXJHPYYMCYSPMHYSMYDYSHQYZCHMJJMZCAAGCFJBBHPLYZYLXXSDJGXDHKXXTXXNBHRMLYJSLTXMRHNLXQJXYZLLYSWQGDLBJHDCGJYQYCMHWFMJYBMBYJYJWYMDPWHXQLDYGPDFXXBCGJSPCKRSSYZJMSLBZZJFLJJJLGXZGYXYXLSZQYXBEXYXHGCXBPLDYHWETTWWCJMBTXCHXYQXLLXFLYXLLJLSSFWDPZSMYJCLMWYTCZPCHQEKCQBWLCQYDPLQPPQZQFJQDJHYMMCXTXDRMJWRHXCJZYLQXDYYNHYYHRSLSRSYWWZJYMTLTLLGTQCJZYABTCKZCJYCCQLJZQXALMZYHYWLWDXZXQDLLQSHGPJFJLJHJABCQZDJGTKHSSTCYJLPSWZLXZXRWGLDLZRLZXTGSLLLLZLYXXWGDZYGBDPHZPBRLWSXQBPFDWOFMWHLYPCBJCCLDMBZPBZZLCYQXLDOMZBLZWPDWYYGDSTTHCSQSCCRSSSYSLFYBFNTYJSZDFNDPDHDZZMBBLSLCMYFFGTJJQWFTMTPJWFNLBZCMMJTGBDZLQLPYFHYYMJYLSDCHDZJWJCCTLJCLDTLJJCPDDSQDSSZYBNDBJLGGJZXSXNLYCYBJXQYCBYLZCFZPPGKCXZDZFZTJJFJSJXZBNZYJQTTYJYHTYCZHYMDJXTTMPXSPLZCDWSLSHXYPZGTFMLCJTYCBPMGDKWYCYZCDSZZYHFLYCTYGWHKJYYLSJCXGYWJCBLLCSNDDBTZBSCLYZCZZSSQDLLMQYYHFSLQLLXFTYHABXGWNYWYYPLLSDLDLLBJCYXJZMLHLJDXYYQYTDLLLBUGBFDFBBQJZZMDPJHGCLGMJJPGAEHHBWCQXAXHHHZCHXYPHJAXHLPHJPGPZJQCQZGJJZZUZDMQYYBZZPHYHYBWHAZYJHYKFGDPFQSDLZMLJXKXGALXZDAGLMDGXMWZQYXXDXXPFDMMSSYMPFMDMMKXKSYZYSHDZKXSYSMMZZZMSYDNZZCZXFPLSTMZDNMXCKJMZTYYMZMZZMSXHHDCZJEMXXKLJSTLWLSQLYJZLLZJSSDPPMHNLZJCZYHMXXHGZCJMDHXTKGRMXFWMCGMWKDTKSXQMMMFZZYDKMSCLCMPCGMHSPXQPZDSSLCXKYXTWLWJYAHZJGZQMCSNXYYMMPMLKJXMHLMLQMXCTKZMJQYSZJSYSZHSYJZJCDAJZYBSDQJZGWZQQXFKDMSDJLFWEHKZQKJPEYPZYSZCDWYJFFMZZYLTTDZZEFMZLBNPPLPLPEPSZALLTYLKCKQZKGENQLWAGYXYDPXLHSXQQWQCQXQCLHYXXMLYCCWLYMQYSKGCHLCJNSZKPYZKCQZQLJPDMDZHLASXLBYDWQLWDNBQCRYDDZTJYBKBWSZDXDTNPJDTCTQDFXQQMGNXECLTTBKPWSLCTYQLPWYZZKLPYGZCQQPLLKCCYLPQMZCZQCLJSLQZDJXLDDHPZQDLJJXZQDXYZQKZLJCYQDYJPPYPQYKJYRMPCBYMCXKLLZLLFQPYLLLMBSGLCYSSLRSYSQTMXYXZQZFDZUYSYZTFFMZZSMZQHZSSCCMLYXWTPZGXZJGZGSJSGKDDHTQGGZLLBJDZLCBCHYXYZHZFYWXYZYMSDBZZYJGTSMTFXQYXQSTDGSLNXDLRYZZLRYYLXQHTXSRTZNGZXBNQQZFMYKMZJBZYMKBPNLYZPBLMCNQYZZZSJZHJCTZKHYZZJRDYZHNPXGLFZTLKGJTCTSSYLLGZRZBBQZZKLPKLCZYSSUYXBJFPNJZZXCDWXZYJXZZDJJKGGRSRJKMSMZJLSJYWQSKYHQJSXPJZZZLSNSHRNYPZTWCHKLPSRZLZXYJQXQKYSJYCZTLQZYBBYBWZPQDWWYZCYTJCJXCKCWDKKZXSGKDZXWWYYJQYYTCYTDLLXWKCZKKLCCLZCQQDZLQLCSFQCHQHSFSMQZZLNBJJZBSJHTSZDYSJQJPDLZCDCWJKJZZLPYCGMZWDJJBSJQZSYZYHHXJPBJYDSSXDZNCGLQMBTSFSBPDZDLZNFGFJGFSMPXJQLMBLGQCYYXBQKDJJQYRFKZTJDHCZKLBSDZCFJTPLLJGXHYXZCSSZZXSTJYGKGCKGYOQXJPLZPBPGTGYJZGHZQZZLBJLSQFZGKQQJZGYCZBZQTLDXRJXBSXXPZXHYZYCLWDXJJHXMFDZPFZHQHQMQGKSLYHTYCGFRZGNQXCLPDLBZCSCZQLLJBLHBZCYPZZPPDYMZZSGYHCKCPZJGSLJLNSCDSLDLXBMSTLDDFJMKDJDHZLZXLSZQPQPGJLLYBDSZGQLBZLSLKYYHZTTNTJYQTZZPSZQZTLLJTYYLLQLLQYZQLBDZLSLYYZYMDFSZSNHLXZNCZQZPBWSKRFBSYZMTHBLGJPMCZZLSTLXSHTCSYZLZBLFEQHLXFLCJLYLJQCBZLZJHHSSTBRMHXZHJZCLXFNBGXGTQJCZTMSFZKJMSSNXLJKBHSJXNTNLZDNTLMSJXGZJYJCZXYJYJWRWWQNZTNFJSZPZSHZJFYRDJSFSZJZBJFZQZZHZLXFYSBZQLZSGYFTZDCSZXZJBQMSZKJRHYJZCKMJKHCHGTXKXQGLXPXFXTRTYLXJXHDTSJXHJZJXZWZLCQSBTXWXGXTXXHXFTSDKFJHZYJFJXRZSDLLLTQSQQZQWZXSYQTWGWBZCGZLLYZBCLMQQTZHZXZXLJFRMYZFLXYSQXXJKXRMQDZDMMYYBSQBHGZMWFWXGMXLZPYYTGZYCCDXYZXYWGSYJYZNBHPZJSQSYXSXRTFYZGRHZTXSZZTHCBFCLSYXZLZQMZLMPLMXZJXSFLBYZMYQHXJSXRXSQZZZSSLYFRCZJRCRXHHZXQYDYHXSJJHZCXZBTYNSYSXJBQLPXZQPYMLXZKYXLXCJLCYSXXZZLXDLLLJJYHZXGYJWKJRWYHCPSGNRZLFZWFZZNSXGXFLZSXZZZBFCSYJDBRJKRDHHGXJLJJTGXJXXSTJTJXLYXQFCSGSWMSBCTLQZZWLZZKXJMLTMJYHSDDBXGZHDLBMYJFRZFSGCLYJBPMLYSMSXLSZJQQHJZFXGFQFQBPXZGYYQXGZTCQWYLTLGWSGWHRLFSFGZJMGMGBGTJFSYZZGZYZAFLSSPMLPFLCWBJZCLJJMZLPJJLYMQDMYYYFBGYGYZMLYZDXQYXRQQQHSYYYQXYLJTYXFSFSLLGNQCYHYCWFHCCCFXPYLYPLLZYXXXXXKQHHXSHJZCFZSCZJXCPZWHHHHHAPYLQALPQAFYHXDYLUKMZQGGGDDESRNNZLTZGCHYPPYSQJJHCLLJTOLNJPZLJLHYMHEYDYDSQYCDDHGZUNDZCLZYZLLZNTNYZGSLHSLPJJBDGWXPCDUTJCKLKCLWKLLCASSTKZZDNQNTTLYYZSSYSSZZRYLJQKCQDHHCRXRZYDGRGCWCGZQFFFPPJFZYNAKRGYWYQPQXXFKJTSZZXSWZDDFBBXTBGTZKZNPZZPZXZPJSZBMQHKCYXYLDKLJNYPKYGHGDZJXXEAHPNZKZTZCMXCXMMJXNKSZQNMNLWBWWXJKYHCPSTMCSQTZJYXTPCTPDTNNPGLLLZSJLSPBLPLQHDTNJNLYYRSZFFJFQWDPHZDWMRZCCLODAXNSSNYZRESTYJWJYJDBCFXNMWTTBYLWSTSZGYBLJPXGLBOCLHPCBJLTMXZLJYLZXCLTPNCLCKXTPZJSWCYXSFYSZDKNTLBYJCYJLLSTGQCBXRYZXBXKLYLHZLQZLNZCXWJZLJZJNCJHXMNZZGJZZXTZJXYCYYCXXJYYXJJXSSSJSTSSTTPPGQTCSXWZDCSYFPTFBFHFBBLZJCLZZDBXGCXLQPXKFZFLSYLTUWBMQJHSZBMDDBCYSCCLDXYCDDQLYJJWMQLLCSGLJJSYFPYYCCYLTJANTJJPWYCMMGQYYSXDXQMZHSZXPFTWWZQSWQRFKJLZJQQYFBRXJHHFWJJZYQAZMYFRHCYYBYQWLPEXCCZSTYRLTTDMQLYKMBBGMYYJPRKZNPBSXYXBHYZDJDNGHPMFSGMWFZMFQMMBCMZZCJJLCNUXYQLMLRYGQZCYXZLWJGCJCGGMCJNFYZZJHYCPRRCMTZQZXHFQGTJXCCJEAQCRJYHPLQLSZDJRBCQHQDYRHYLYXJSYMHZYDWLDFRYHBPYDTSSCNWBXGLPZMLZZTQSSCPJMXXYCSJYTYCGHYCJWYRXXLFEMWJNMKLLSWTXHYYYNCMMCWJDQDJZGLLJWJRKHPZGGFLCCSCZMCBLTBHBQJXQDSPDJZZGHGLFQYWBZYZJLTSTDHQHCTCBCHFLQMPWDSHYYTQWCNZZJTLBYMBPDYYYXSQKXWYYFLXXNCWCXYPMAELYKKJMZZZBRXYYQJFLJPFHHHYTZZXSGQQMHSPGDZQWBWPJHZJDYSCQWZKTXXSQLZYYMYSDZGRXCKKUJLWPYSYSCSYZLRMLQSYLJXBCXTLWDQZPCYCYKPPPNSXFYZJJRCEMHSZMSXLXGLRWGCSTLRSXBZGBZGZTCPLUJLSLYLYMTXMTZPALZXPXJTJWTCYYZLBLXBZLQMYLXPGHDSLSSDMXMBDZZSXWHAMLCZCPJMCNHJYSNSYGCHSKQMZZQDLLKABLWJXSFMOCDXJRRLYQZKJMYBYQLYHETFJZFRFKSRYXFJTWDSXXSYSQJYSLYXWJHSNLXYYXHBHAWHHJZXWMYLJCSSLKYDZTXBZSYFDXGXZJKHSXXYBSSXDPYNZWRPTQZCZENYGCXQFJYKJBZMLJCMQQXUOXSLYXXLYLLJDZBTYMHPFSTTQQWLHOKYBLZZALZXQLHZWRRQHLSTMYPYXJJXMQSJFNBXYXYJXXYQYLTHYLQYFMLKLJTMLLHSZWKZHLJMLHLJKLJSTLQXYLMBHHLNLZXQJHXCFXXLHYHJJGBYZZKBXSCQDJQDSUJZYYHZHHMGSXCSYMXFEBCQWWRBPYYJQTYZCYQYQQZYHMWFFHGZFRJFCDPXNTQYZPDYKHJLFRZXPPXZDBBGZQSTLGDGYLCQMLCHHMFYWLZYXKJLYPQHSYWMQQGQZMLZJNSQXJQSYJYCBEHSXFSZPXZWFLLBCYYJDYTDTHWZSFJMQQYJLMQXXLLDTTKHHYBFPWTYYSQQWNQWLGWDEBZWCMYGCULKJXTMXMYJSXHYBRWFYMWFRXYQMXYSZTZZTFYKMLDHQDXWYYNLCRYJBLPSXCXYWLSPRRJWXHQYPHTYDNXHHMMYWYTZCSQMTSSCCDALWZTCPQPYJLLQZYJSWXMZZMMYLMXCLMXCZMXMZSQTZPPQQBLPGXQZHFLJJHYTJSRXWZXSCCDLXTYJDCQJXSLQYCLZXLZZXMXQRJMHRHZJBHMFLJLMLCLQNLDXZLLLPYPSYJYSXCQQDCMQJZZXHNPNXZMEKMXHYKYQLXSXTXJYYHWDCWDZHQYYBGYBCYSCFGPSJNZDYZZJZXRZRQJJYMCANYRJTLDPPYZBSTJKXXZYPFDWFGZZRPYMTNGXZQBYXNBUFNQKRJQZMJEGRZGYCLKXZDSKKNSXKCLJSPJYYZLQQJYBZSSQLLLKJXTBKTYLCCDDBLSPPFYLGYDTZJYQGGKQTTFZXBDKTYYHYBBFYTYYBCLPDYTGDHRYRNJSPTCSNYJQHKLLLZSLYDXXWBCJQSPXBPJZJCJDZFFXXBRMLAZHCSNDLBJDSZBLPRZTSWSBXBCLLXXLZDJZSJPYLYXXYFTFFFBHJJXGBYXJPMMMPSSJZJMTLYZJXSWXTYLEDQPJMYGQZJGDJLQJWJQLLSJGJGYGMSCLJJXDTYGJQJQJCJZCJGDZZSXQGSJGGCXHQXSNQLZZBXHSGZXCXYLJXYXYYDFQQJHJFXDHCTXJYRXYSQTJXYEFYYSSYYJXNCYZXFXMSYSZXYYSCHSHXZZZGZZZGFJDLTYLNPZGYJYZYYQZPBXQBDZTZCZYXXYHHSQXSHDHGQHJHGYWSZTMZMLHYXGEBTYLZKQWYTJZRCLEKYSTDBCYKQQSAYXCJXWWGSBHJYZYDHCSJKQCXSWXFLTYNYZPZCCZJQTZWJQDZZZQZLJJXLSBHPYXXPSXSHHEZTXFPTLQYZZXHYTXNCFZYYHXGNXMYWXTZSJPTHHGYMXMXQZXTSBCZYJYXXTYYZYPCQLMMSZMJZZLLZXGXZAAJZYXJMZXWDXZSXZDZXLEYJJZQBHZWZZZQTZPSXZTDSXJJJZNYAZPHXYYSRNQDTHZHYYKYJHDZXZLSWCLYBZYECWCYCRYLCXNHZYDZYDYJDFRJJHTRSQTXYXJRJHOJYNXELXSFSFJZGHPZSXZSZDZCQZBYYKLSGSJHCZSHDGQGXYZGXCHXZJWYQWGYHKSSEQZZNDZFKWYSSTCLZSTSYMCDHJXXYWEYXCZAYDMPXMDSXYBSQMJMZJMTZQLPJYQZCGQHXJHHLXXHLHDLDJQCLDWBSXFZZYYSCHTYTYYBHECXHYKGJPXHHYZJFXHWHBDZFYZBCAPNPGNYDMSXHMMMMAMYNBYJTMPXYYMCTHJBZYFCGTYHWPHFTWZZEZSBZEGPFMTSKFTYCMHFLLHGPZJXZJGZJYXZSBBQSCZZLZCCSTPGXMJSFTCCZJZDJXCYBZLFCJSYZFGSZLYBCWZZBYZDZYPSWYJZXZBDSYUXLZZBZFYGCZXBZHZFTPBGZGEJBSTGKDMFHYZZJHZLLZZGJQZLSFDJSSCBZGPDLFZFZSZYZYZSYGCXSNXXCHCZXTZZLJFZGQSQYXZJQDCCZTQCDXZJYQJQCHXZTDLGSCXZSYQJQTZWLQDQZTQCHQQJZYEZZZPBWKDJFCJPZTYPQYQTTYNLMBDKTJZPQZQZZFPZSBNJLGYJDXJDZZKZGQKXDLPZJTCJDQBXDJQJSTCKNXBXZMSLYJCQMTJQWWCJQNJNLLLHJCWQTBZQYDZCZPZZDZYDDCYZZZCCJTTJFZDPRRTZTJDCQTQZDTJNPLZBCLLCTZSXKJZQZPZLBZRBTJDCXFCZDBCCJJLTQQPLDCGZDBBZJCQDCJWYNLLZYZCCDWLLXWZLXRXNTQQCZXKQLSGDFQTDDGLRLAJJTKUYMKQLLTZYTDYYCZGJWYXDXFRSKSTQTENQMRKQZHHQKDLDAZFKYPBGGPZREBZZYKZZSPEGJXGYKQZZZSLYSYYYZWFQZYLZZLZHWCHKYPQGNPGBLPLRRJYXCCSYYHSFZFYBZYYTGZXYLXCZWXXZJZBLFFLGSKHYJZEYJHLPLLLLCZGXDRZELRHGKLZZYHZLYQSZZJZQLJZFLNBHGWLCZCFJYSPYXZLZLXGCCPZBLLCYBBBBUBBCBPCRNNZCZYRBFSRLDCGQYYQXYGMQZWTZYTYJXYFWTEHZZJYWLCCNTZYJJZDEDPZDZTSYQJHDYMBJNYJZLXTSSTPHNDJXXBYXQTZQDDTJTDYYTGWSCSZQFLSHLGLBCZPHDLYZJYCKWTYTYLBNYTSDSYCCTYSZYYEBHEXHQDTWNYGYCLXTSZYSTQMYGZAZCCSZZDSLZCLZRQXYYELJSBYMXSXZTEMBBLLYYLLYTDQYSHYMRQWKFKBFXNXSBYCHXBWJYHTQBPBSBWDZYLKGZSKYHXQZJXHXJXGNLJKZLYYCDXLFYFGHLJGJYBXQLYBXQPQGZTZPLNCYPXDJYQYDYMRBESJYYHKXXSTMXRCZZYWXYQYBMCLLYZHQYZWQXDBXBZWZMSLPDMYSKFMZKLZCYQYCZLQXFZZYDQZPZYGYJYZMZXDZFYFYTTQTZHGSPCZMLCCYTZXJCYTJMKSLPZHYSNZLLYTPZCTZZCKTXDHXXTQCYFKSMQCCYYAZHTJPCYLZLYJBJXTPNYLJYYNRXSYLMMNXJSMYBCSYSYLZYLXJJQYLDZLPQBFZZBLFNDXQKCZFYWHGQMRDSXYCYTXNQQJZYYPFZXDYZFPRXEJDGYQBXRCNFYYQPGHYJDYZXGRHTKYLNWDZNTSMPKLBTHBPYSZBZTJZSZZJTYYXZPHSSZZBZCZPTQFZMYFLYPYBBJQXZMXXDJMTSYSKKBJZXHJCKLPSMKYJZCXTMLJYXRZZQSLXXQPYZXMKYXXXJCLJPRMYYGADYSKQLSNDHYZKQXZYZTCGHZTLMLWZYBWSYCTBHJHJFCWZTXWYTKZLXQSHLYJZJXTMPLPYCGLTBZZTLZJCYJGDTCLKLPLLQPJMZPAPXYZLKKTKDZCZZBNZDYDYQZJYJGMCTXLTGXSZLMLHBGLKFWNWZHDXUHLFMKYSLGXDTWWFRJEJZTZHYDXYKSHWFZCQSHKTMQQHTZHYMJDJSKHXZJZBZZXYMPAGQMSTPXLSKLZYNWRTSQLSZBPSPSGZWYHTLKSSSWHZZLYYTNXJGMJSZSUFWNLSOZTXGXLSAMMLBWLDSZYLAKQCQCTMYCFJBSLXCLZZCLXXKSBZQCLHJPSQPLSXXCKSLNHPSFQQYTXYJZLQLDXZQJZDYYDJNZPTUZDSKJFSLJHYLZSQZLBTXYDGTQFDBYAZXDZHZJNHHQBYKNXJJQCZMLLJZKSPLDYCLBBLXKLELXJLBQYCXJXGCNLCQPLZLZYJTZLJGYZDZPLTQCSXFDMNYCXGBTJDCZNBGBQYQJWGKFHTNPYQZQGBKPBBYZMTJDYTBLSQMPSXTBNPDXKLEMYYCJYNZCTLDYKZZXDDXHQSHDGMZSJYCCTAYRZLPYLTLKXSLZCGGEXCLFXLKJRTLQJAQZNCMBYDKKCXGLCZJZXJHPTDJJMZQYKQSECQZDSHHADMLZFMMZBGNTJNNLGBYJBRBTMLBYJDZXLCJLPLDLPCQDHLXZLYCBLCXZZJADJLNZMMSSSMYBHBSQKBHRSXXJMXSDZNZPXLGBRHWGGFCXGMSKLLTSJYYCQLTSKYWYYHYWXBXQYWPYWYKQLSQPTNTKHQCWDQKTWPXXHCPTHTWUMSSYHBWCRWXHJMKMZNGWTMLKFGHKJYLSYYCXWHYECLQHKQHTTQKHFZLDXQWYZYYDESBPKYRZPJFYYZJCEQDZZDLATZBBFJLLCXDLMJSSXEGYGSJQXCWBXSSZPDYZCXDNYXPPZYDLYJCZPLTXLSXYZYRXCYYYDYLWWNZSAHJSYQYHGYWWAXTJZDAXYSRLTDPSSYYFNEJDXYZHLXLLLZQZSJNYQYQQXYJGHZGZCYJCHZLYCDSHWSHJZYJXCLLNXZJJYYXNFXMWFPYLCYLLABWDDHWDXJMCXZTZPMLQZHSFHZYNZTLLDYWLSLXHYMMYLMBWWKYXYADTXYLLDJPYBPWUXJMWMLLSAFDLLYFLBHHHBQQLTZJCQJLDJTFFKMMMBYTHYGDCQRDDWRQJXNBYSNWZDBYYTBJHPYBYTTJXAAHGQDQTMYSTQXKBTZPKJLZRBEQQSSMJJBDJOTGTBXPGBKTLHQXJJJCTHXQDWJLWRFWQGWSHCKRYSWGFTGYGBXSDWDWRFHWYTJJXXXJYZYSLPYYYPAYXHYDQKXSHXYXGSKQHYWFDDDPPLCJLQQEEWXKSYYKDYPLTJTHKJLTCYYHHJTTPLTZZCDLTHQKZXQYSTEEYWYYZYXXYYSTTJKLLPZMCYHQGXYHSRMBXPLLNQYDQHXSXXWGDQBSHYLLPJJJTHYJKYPPTHYYKTYEZYENMDSHLCRPQFDGFXZPSFTLJXXJBSWYYSKSFLXLPPLBBBLBSFXFYZBSJSSYLPBBFFFFSSCJDSTZSXZRYYSYFFSYZYZBJTBCTSBSDHRTJJBYTCXYJEYLXCBNEBJDSYXYKGSJZBXBYTFZWGENYHHTHZHHXFWGCSTBGXKLSXYWMTMBYXJSTZSCDYQRCYTWXZFHMYMCXLZNSDJTTTXRYCFYJSBSDYERXJLJXBBDEYNJGHXGCKGSCYMBLXJMSZNSKGXFBNBPTHFJAAFXYXFPXMYPQDTZCXZZPXRSYWZDLYBBKTYQPQJPZYPZJZNJPZJLZZFYSBTTSLMPTZRTDXQSJEHBZYLZDHLJSQMLHTXTJECXSLZZSPKTLZKQQYFSYGYWPCPQFHQHYTQXZKRSGTTSQCZLPTXCDYYZXSQZSLXLZMYCPCQBZYXHBSXLZDLTCDXTYLZJYYZPZYZLTXJSJXHLPMYTXCQRBLZSSFJZZTNJYTXMYJHLHPPLCYXQJQQKZZSCPZKSWALQSBLCCZJSXGWWWYGYKTJBBZTDKHXHKGTGPBKQYSLPXPJCKBMLLXDZSTBKLGGQKQLSBKKTFXRMDKBFTPZFRTBBRFERQGXYJPZSSTLBZTPSZQZSJDHLJQLZBPMSMMSXLQQNHKNBLRDDNXXDHDDJCYYGYLXGZLXSYGMQQGKHBPMXYXLYTQWLWGCPBMQXCYZYDRJBHTDJYHQSHTMJSBYPLWHLZFFNYPMHXXHPLTBQPFBJWQDBYGPNZTPFZJGSDDTQSHZEAWZZYLLTYYBWJKXXGHLFKXDJTMSZSQYNZGGSWQSPHTLSSKMCLZXYSZQZXNCJDQGZDLFNYKLJCJLLZLMZZNHYDSSHTHZZLZZBBHQZWWYCRZHLYQQJBEYFXXXWHSRXWQHWPSLMSSKZTTYGYQQWRSLALHMJTQJSMXQBJJZJXZYZKXBYQXBJXSHZTSFJLXMXZXFGHKZSZGGYLCLSARJYHSLLLMZXELGLXYDJYTLFBHBPNLYZFBBHPTGJKWETZHKJJXZXXGLLJLSTGSHJJYQLQZFKCGNNDJSSZFDBCTWWSEQFHQJBSAQTGYPQLBXBMMYWXGSLZHGLZGQYFLZBYFZJFRYSFMBYZHQGFWZSYFYJJPHZBYYZFFWODGRLMFTWLBZGYCQXCDJYGZYYYYTYTYDWEGAZYHXJLZYYHLRMGRXXZCLHNELJJTJTPWJYBJJBXJJTJTEEKHWSLJPLPSFYZPQQBDLQJJTYYQLYZKDKSQJYYQZLDQTGJQYZJSUCMRYQTHTEJMFCTYHYPKMHYZWJDQFHYYXWSHCTXRLJHQXHCCYYYJLTKTTYTMXGTCJTZAYYOCZLYLBSZYWJYTSJYHBYSHFJLYGJXXTMZYYLTXXYPZLXYJZYZYYPNHMYMDYYLBLHLSYYQQLLNJJYMSOYQBZGDLYXYLCQYXTSZEGXHZGLHWBLJHEYXTWQMAKBPQCGYSHHEGQCMWYYWLJYJHYYZLLJJYLHZYHMGSLJLJXCJJYCLYCJPCPZJZJMMYLCQLNQLJQJSXYJMLSZLJQLYCMMHCFMMFPQQMFYLQMCFFQMMMMHMZNFHHJGTTHHKHSLNCHHYQDXTMMQDCYZYXYQMYQYLTDCYYYZAZZCYMZYDLZFFFMMYCQZWZZMABTBYZTDMNZZGGDFTYPCGQYTTSSFFWFDTZQSSYSTWXJHXYTSXXYLBYQHWWKXHZXWZNNZZJZJJQJCCCHYYXBZXZCYZTLLCQXYNJYCYYCYNZZQYYYEWYCZDCJYCCHYJLBTZYYCQWMPWPYMLGKDLDLGKQQBGYCHJXY".charAt(t-19968)},_.extend(BI,{makeFirstPY:function(e,t){if(t=t||{},"string"!=typeof e)return""+e;for(var n=[],r=0,a=e.length;r<a;r++){var o=e.charAt(r);n.push(i(o))}return function(e,t){for(var n,i=t.ignoreMulti,r=t.splitChar,a=[""],o=0,s=0,l=e.length;s<l;s++){var u=e[s],c=u.length;if(1==c||o>14||i){var h=u.substring(0,1);for(n=0;n<a.length;n++)a[n]+=h}else{var p=a.slice(0);for(a=[],o++,n=0;n<c;n++){for(var d=p.slice(0),f=0;f<d.length;f++)d[f]+=u.charAt(n);a=a.concat(d)}}}return a.join(r||"").toLowerCase()}(n,t)}})},function(e,t){var n;n={},_.extend(BI,{addI18n:function(e){BI.extend(n,e)},i18nText:function(e){var t=n[e]||BI.i18n&&BI.i18n[e]||"";t||(t=e);var i=arguments.length;if(i>1){if(!(t.indexOf("{R1}")>-1)){var r=Array.prototype.slice.call(arguments),a=1;return BI.replaceAll(t,"\\{\\s*\\}",(function(){return r[a++]+""}))}for(var o=1;o<i;o++)e="{R"+o+"}",t=BI.replaceAll(t,e,arguments[o]+"")}return t}})},function(e,t){var n;n={},BI.BufferPool={put:function(e,t){if(BI.isNotNull(n[e]))throw new Error("Buffer Pool has the key already!");n[e]=t},get:function(e){return n[e]}}},function(e,t){var n;n={},BI.SharingPool={_Shared:n,put:function(e,t){n[e]=t},cat:function(){for(var e=Array.prototype.slice.call(arguments,0),t=n,i=0;i<e.length;i++)t=t&&t[e[i]];return t},get:function(){return BI.deepClone(this.cat.apply(this,arguments))},remove:function(e){delete n[e]}}},function(e,t){BI.Req={}},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},,function(e,t,n){var i=n(8),r=n(5).document,a=i(r)&&i(r.createElement);e.exports=function(e){return a?r.createElement(e):{}}},function(e,t,n){t.f=n(9)},function(e,t,n){var i=n(76)("keys"),r=n(37);e.exports=function(e){return i[e]||(i[e]=r(e))}},function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(e,t,n){var i=n(5).document;e.exports=i&&i.documentElement},function(e,t,n){var i=n(8),r=n(7),a=function(e,t){if(r(e),!i(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,t,i){try{(i=n(23)(Function.call,n(26).f(Object.prototype,"__proto__").set,2))(e,[]),t=!(e instanceof Array)}catch(r){t=!0}return function(e,n){return a(e,n),t?e.__proto__=n:i(e,n),e}}({},!1):undefined),check:a}},function(e,t){e.exports="\t\n\x0B\f\r    \u2028\u2029\ufeff"},function(e,t,n){var i=n(8),r=n(179).set;e.exports=function(e,t,n){var a,o=t.constructor;return o!==n&&"function"==typeof o&&(a=o.prototype)!==n.prototype&&i(a)&&r&&r(e,a),e}},function(e,t,n){"use strict";var i=n(25),r=n(32);e.exports=function(e){var t=String(r(this)),n="",a=i(e);if(a<0||a==Infinity)throw RangeError("Count can't be negative");for(;a>0;(a>>>=1)&&(t+=t))1&a&&(n+=t);return n}},function(e,t){e.exports=Math.sign||function(e){return 0==(e=+e)||e!=e?e:e<0?-1:1}},function(e,t){var n=Math.expm1;e.exports=!n||n(10)>22025.465794806718||n(10)<22025.465794806718||-2e-17!=n(-2e-17)?function(e){return 0==(e=+e)?e:e>-1e-6&&e<1e-6?e+e*e/2:Math.exp(e)-1}:n},function(e,t,n){var i=n(25),r=n(32);e.exports=function(e){return function(t,n){var a,o,s=String(r(t)),l=i(n),u=s.length;return l<0||l>=u?e?"":undefined:(a=s.charCodeAt(l))<55296||a>56319||l+1===u||(o=s.charCodeAt(l+1))<56320||o>57343?e?s.charAt(l):a:e?s.slice(l,l+2):o-56320+(a-55296<<10)+65536}}},function(e,t,n){"use strict";var i=n(38),r=n(0),a=n(17),o=n(20),s=n(56),l=n(897),u=n(54),c=n(43),h=n(9)("iterator"),p=!([].keys&&"next"in[].keys()),d="keys",f="values",g=function(){return this};e.exports=function(e,t,n,m,I,B,_){l(n,t,m);var E,b,y,v=function(e){if(!p&&e in V)return V[e];switch(e){case d:case f:return function(){return new n(this,e)}}return function(){return new n(this,e)}},T=t+" Iterator",C=I==f,N=!1,V=e.prototype,S=V[h]||V["@@iterator"]||I&&V[I],x=S||v(I),w=I?C?v("entries"):x:undefined,A="Array"==t&&V.entries||S;if(A&&(y=c(A.call(new e)))!==Object.prototype&&y.next&&(u(y,T,!0),i||"function"==typeof y[h]||o(y,h,g)),C&&S&&S.name!==f&&(N=!0,x=function(){return S.call(this)}),i&&!_||!p&&!N&&V[h]||o(V,h,x),s[t]=x,s[T]=g,I)if(E={values:C?x:v(f),keys:B?x:v(d),entries:w},_)for(b in E)b in V||a(V,b,E[b]);else r(r.P+r.F*(p||N),t,E);return E}},function(e,t,n){var i=n(188),r=n(32);e.exports=function(e,t,n){if(i(t))throw TypeError("String#"+n+" doesn't accept regex!");return String(r(e))}},function(e,t,n){var i=n(8),r=n(31),a=n(9)("match");e.exports=function(e){var t;return i(e)&&((t=e[a])!==undefined?!!t:"RegExp"==r(e))}},function(e,t,n){var i=n(9)("match");e.exports=function(e){var t=/./;try{"/./"[e](t)}catch(n){try{return t[i]=!1,!"/./"[e](t)}catch(r){}}return!0}},function(e,t,n){var i=n(56),r=n(9)("iterator"),a=Array.prototype;e.exports=function(e){return e!==undefined&&(i.Array===e||a[r]===e)}},function(e,t,n){"use strict";var i=n(13),r=n(36);e.exports=function(e,t,n){t in e?i.f(e,t,r(0,n)):e[t]=n}},function(e,t,n){var i=n(64),r=n(9)("iterator"),a=n(56);e.exports=n(11).getIteratorMethod=function(e){if(e!=undefined)return e[r]||e["@@iterator"]||a[i(e)]}},function(e,t,n){"use strict";var i=n(15),r=n(40),a=n(10);e.exports=function(e){for(var t=i(this),n=a(t.length),o=arguments.length,s=r(o>1?arguments[1]:undefined,n),l=o>2?arguments[2]:undefined,u=l===undefined?n:r(l,n);u>s;)t[s++]=e;return t}},function(e,t,n){"use strict";var i=n(44),r=n(902),a=n(56),o=n(21);e.exports=n(186)(Array,"Array",(function(e,t){this._t=o(e),this._i=0,this._k=t}),(function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=undefined,r(1)):r(0,"keys"==t?n:"values"==t?e[n]:[n,e[n]])}),"values"),a.Arguments=a.Array,i("keys"),i("values"),i("entries")},function(e,t,n){"use strict";var i,r,a=n(81),o=RegExp.prototype.exec,s=String.prototype.replace,l=o,u=(i=/a/,r=/b*/g,o.call(i,"a"),o.call(r,"a"),0!==i.lastIndex||0!==r.lastIndex),c=/()??/.exec("")[1]!==undefined;(u||c)&&(l=function(e){var t,n,i,r,l=this;return c&&(n=new RegExp("^"+l.source+"$(?!\\s)",a.call(l))),u&&(t=l.lastIndex),i=o.call(l,e),u&&i&&(l.lastIndex=l.global?i.index+i[0].length:t),c&&i&&i.length>1&&s.call(i[0],n,(function(){for(r=1;r<arguments.length-2;r++)arguments[r]===undefined&&(i[r]=undefined)})),i}),e.exports=l},function(e,t,n){"use strict";var i=n(185)(!0);e.exports=function(e,t,n){return t+(n?i(e,t).length:1)}},function(e,t,n){var i,r,a,o=n(23),s=n(891),l=n(178),u=n(174),c=n(5),h=c.process,p=c.setImmediate,d=c.clearImmediate,f=c.MessageChannel,g=c.Dispatch,m=0,I={},B="onreadystatechange",_=function(){var e=+this;if(I.hasOwnProperty(e)){var t=I[e];delete I[e],t()}},E=function(e){_.call(e.data)};p&&d||(p=function(e){for(var t=[],n=1;arguments.length>n;)t.push(arguments[n++]);return I[++m]=function(){s("function"==typeof e?e:Function(e),t)},i(m),m},d=function(e){delete I[e]},"process"==n(31)(h)?i=function(e){h.nextTick(o(_,e,1))}:g&&g.now?i=function(e){g.now(o(_,e,1))}:f?(a=(r=new f).port2,r.port1.onmessage=E,i=o(a.postMessage,a,1)):c.addEventListener&&"function"==typeof postMessage&&!c.importScripts?(i=function(e){c.postMessage(e+"","*")},c.addEventListener("message",E,!1)):i=B in u("script")?function(e){l.appendChild(u("script")).onreadystatechange=function(){l.removeChild(this),_.call(e)}}:function(e){setTimeout(o(_,e,1),0)}),e.exports={set:p,clear:d}},function(e,t,n){"use strict";var i=n(5),r=n(12),a=n(38),o=n(87),s=n(20),l=n(59),u=n(6),c=n(58),h=n(25),p=n(10),d=n(910),f=n(42).f,g=n(13).f,m=n(193),I=n(54),B="ArrayBuffer",_="DataView",E="Wrong index!",b=i.ArrayBuffer,y=i.DataView,v=i.Math,T=i.RangeError,C=i.Infinity,N=b,V=v.abs,S=v.pow,x=v.floor,w=v.log,A=v.LN2,L="buffer",k="byteLength",D="byteOffset",M=r?"_b":L,P=r?"_l":k,R=r?"_o":D;function H(e,t,n){var i,r,a,o=new Array(n),s=8*n-t-1,l=(1<<s)-1,u=l>>1,c=23===t?S(2,-24)-S(2,-77):0,h=0,p=e<0||0===e&&1/e<0?1:0;for((e=V(e))!=e||e===C?(r=e!=e?1:0,i=l):(i=x(w(e)/A),e*(a=S(2,-i))<1&&(i--,a*=2),(e+=i+u>=1?c/a:c*S(2,1-u))*a>=2&&(i++,a/=2),i+u>=l?(r=0,i=l):i+u>=1?(r=(e*a-1)*S(2,t),i+=u):(r=e*S(2,u-1)*S(2,t),i=0));t>=8;o[h++]=255&r,r/=256,t-=8);for(i=i<<t|r,s+=t;s>0;o[h++]=255&i,i/=256,s-=8);return o[--h]|=128*p,o}function O(e,t,n){var i,r=8*n-t-1,a=(1<<r)-1,o=a>>1,s=r-7,l=n-1,u=e[l--],c=127&u;for(u>>=7;s>0;c=256*c+e[l],l--,s-=8);for(i=c&(1<<-s)-1,c>>=-s,s+=t;s>0;i=256*i+e[l],l--,s-=8);if(0===c)c=1-o;else{if(c===a)return i?NaN:u?-C:C;i+=S(2,t),c-=o}return(u?-1:1)*i*S(2,c-t)}function F(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]}function Y(e){return[255&e]}function W(e){return[255&e,e>>8&255]}function G(e){return[255&e,e>>8&255,e>>16&255,e>>24&255]}function j(e){return H(e,52,8)}function Z(e){return H(e,23,4)}function X(e,t,n){g(e.prototype,t,{get:function(){return this[n]}})}function U(e,t,n,i){var r=d(+n);if(r+t>e[P])throw T(E);var a=e[M]._b,o=r+e[R],s=a.slice(o,o+t);return i?s:s.reverse()}function J(e,t,n,i,r,a){var o=d(+n);if(o+t>e[P])throw T(E);for(var s=e[M]._b,l=o+e[R],u=i(+r),c=0;c<t;c++)s[l+c]=u[a?c:t-c-1]}if(o.ABV){if(!u((function(){b(1)}))||!u((function(){new b(-1)}))||u((function(){return new b,new b(1.5),new b(NaN),b.name!=B}))){for(var K,z=(b=function(e){return c(this,b),new N(d(e))}).prototype=N.prototype,Q=f(N),q=0;Q.length>q;)(K=Q[q++])in b||s(b,K,N[K]);a||(z.constructor=b)}var $=new y(new b(2)),ee=y.prototype.setInt8;$.setInt8(0,2147483648),$.setInt8(1,2147483649),!$.getInt8(0)&&$.getInt8(1)||l(y.prototype,{setInt8:function(e,t){ee.call(this,e,t<<24>>24)},setUint8:function(e,t){ee.call(this,e,t<<24>>24)}},!0)}else b=function(e){c(this,b,B);var t=d(e);this._b=m.call(new Array(t),0),this[P]=t},y=function(e,t,n){c(this,y,_),c(e,b,_);var i=e[P],r=h(t);if(r<0||r>i)throw T("Wrong offset!");if(r+(n=n===undefined?i-r:p(n))>i)throw T("Wrong length!");this[M]=e,this[R]=r,this[P]=n},r&&(X(b,k,"_l"),X(y,L,"_b"),X(y,k,"_l"),X(y,D,"_o")),l(y.prototype,{getInt8:function(e){return U(this,1,e)[0]<<24>>24},getUint8:function(e){return U(this,1,e)[0]},getInt16:function(e){var t=U(this,2,e,arguments[1]);return(t[1]<<8|t[0])<<16>>16},getUint16:function(e){var t=U(this,2,e,arguments[1]);return t[1]<<8|t[0]},getInt32:function(e){return F(U(this,4,e,arguments[1]))},getUint32:function(e){return F(U(this,4,e,arguments[1]))>>>0},getFloat32:function(e){return O(U(this,4,e,arguments[1]),23,4)},getFloat64:function(e){return O(U(this,8,e,arguments[1]),52,8)},setInt8:function(e,t){J(this,1,e,Y,t)},setUint8:function(e,t){J(this,1,e,Y,t)},setInt16:function(e,t){J(this,2,e,W,t,arguments[2])},setUint16:function(e,t){J(this,2,e,W,t,arguments[2])},setInt32:function(e,t){J(this,4,e,G,t,arguments[2])},setUint32:function(e,t){J(this,4,e,G,t,arguments[2])},setFloat32:function(e,t){J(this,4,e,Z,t,arguments[2])},setFloat64:function(e,t){J(this,8,e,j,t,arguments[2])}});I(b,B),I(y,_),s(y.prototype,o.VIEW,!0),t.ArrayBuffer=b,t.DataView=y},function(e,t){var n=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t,n){e.exports=!n(915)((function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}))},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},,,,function(e,t){!function(){function e(e,t){var n,i=[];(n=e[t])&&(i=i.concat(BI.isArray(n)?n:[n])),(n=e.options[t])&&(i=i.concat(BI.isArray(n)?n:[n])),BI.each(i,(function(t,n){n.call(e)}))}BI.Widget=BI.Widget||BI.inherit(BI.OB,{_defaultConfig:function(){return BI.extend(BI.Widget.superclass._defaultConfig.apply(this),{root:!1,tagName:"div",attributes:null,data:null,key:null,tag:null,disabled:!1,invisible:!1,invalid:!1,baseCls:"",extraCls:"",cls:"",css:null,vdom:!1})},_constructor:function(){},_constructed:function(){this.setup&&(!function(e){n&&r.push(n);BI.Widget.current=n=e}(this),this.service=this.setup(this.options),this.render=BI.isPlainObject(this.service)?this.service.render:this.service,BI.Widget.current=n=r.pop())},_lazyConstructor:function(){this.__constructed||(this.__constructed=!0,this._init(),this._initRef())},beforeInit:null,beforeRender:null,beforeCreate:null,created:null,render:null,beforeMount:null,mounted:null,shouldUpdate:null,update:null,beforeUpdate:null,updated:null,beforeDestroy:null,destroyed:null,_init:function(){BI.Widget.superclass._init.apply(this,arguments),this._initElementWidth(),this._initElementHeight(),this._initVisual(),this._initState(),this._initRender()},_initRender:function(){var e=this;function t(){e.options.beforeRender||e.beforeRender?(e.__async=!0,(e.options.beforeRender||e.beforeRender).call(e,BI.bind(e._render,e))):e._render()}this.options.beforeInit||this.beforeInit?(this.__asking=!0,(this.options.beforeInit||this.beforeInit).call(this,t)):t()},_render:function(){this.__asking=!1,e(this,"beforeCreate"),this._initElement(),this._initEffects(),e(this,"created"),this.__async=!1},_initCurrent:function(){var e=this.options;(e._baseCls||e.baseCls||e.extraCls||e.cls)&&this.element.addClass((e._baseCls||"")+" "+(e.baseCls||"")+" "+(e.extraCls||"")+" "+(e.cls||"")),null!=e.key&&this.element.attr("key",e.key),e.attributes&&this.element.attr(e.attributes),e.data&&this.element.data(e.data),e.css&&this.element.css(e.css)},_initRoot:function(){var e=this.options;this.widgetName=e.widgetName||BI.uniqueId("widget"),this._isRoot=e.root,this._children={},BI.isWidget(e.element)?(this.element=this.options.element.element,this._parent=e.element,this._parent.addWidget(this.widgetName,this)):e.element?(this.element=BI.Widget._renderEngine.createElement(this),this._isRoot=!0):this.element=BI.Widget._renderEngine.createElement(this),this.element._isWidget=!0;var t=this.element.data("__widgets")||[];t.push(this),this.element.data("__widgets",t),this._initCurrent()},_initElementWidth:function(){var e=this.options;BI.isWidthOrHeight(e.width)&&this.element.css("width",BI.isNumber(e.width)?e.width/BI.pixRatio+BI.pixUnit:e.width)},_initElementHeight:function(){var e=this.options;BI.isWidthOrHeight(e.height)&&this.element.css("height",BI.isNumber(e.height)?e.height/BI.pixRatio+BI.pixUnit:e.height)},_initVisual:function(){this.options.invisible&&this.element.css("display","none")},_initEffects:function(){var e=this.options;(e.disabled||e.invalid)&&(this.options.disabled&&this.setEnable(!1),this.options.invalid&&this.setValid(!1))},_initState:function(){this._isMounted=!1},_initElement:function(){var t=this,n=this._isMounted;!0===this.__async&&n&&e(this,"beforeMount");var i=BI.isFunction(this.options.render)?this.options.render:this.render,r=i&&i.call(this);if(BI.isPlainObject(r)&&(r=[r]),BI.isArray(r))if(this.options.vdom){var a=document.createElement("div"),o=this.element;o.append(a),this.vnode=this._renderVNode(),BI.patchVNode(a,this.vnode),BI.DOM.hang([a]),o.attr("style",t.vnode.elm.getAttribute("style")),o.addClass(t.vnode.elm.getAttribute("class")),o.empty(),BI.each(BI.jQuery(t.vnode.elm).children(),(function(e,t){o.append(t)}))}else BI.each(r,(function(e,n){n&&BI._lazyCreateWidget(n,{element:t})}));this._mount(),!0===this.__async&&n&&(e(this,"mounted"),this.fireEvent(BI.Events.MOUNT))},_renderVNode:function(){var e=this,t=BI.isFunction(this.options.render)?this.options.render:this.render,n=t&&t.call(this);if(BI.isPlainObject(n)&&(n=[n]),BI.isArray(n)){var i=document.createElement("div");this._children={},BI.each(n,(function(t,n){if(n){var r=BI._lazyCreateWidget(n,{element:i});e.addWidget(r)}}))}return BI.Element2Vnode(i)},_setParent:function(e){this._parent=e},_mount:function(t,n,i,r,a){var o=this;if(!t&&(this._isMounted||!this.isVisible()||!0===this.__asking||!(!0===this._isRoot||this._parent&&!0===this._parent._isMounted)))return!1;for(var s in a=a||0,!1!==i&&!this.__async&&e(this,"beforeMount"),this._isMounted=!0,this._children){var l=this._children[s];0===a&&(!o.isEnabled()&&l._setEnable(!1),!o.isValid()&&l._setValid(!1)),l._mount&&l._mount(!!n&&t,n,i,r,a+1)}return this._mountChildren&&this._mountChildren(),0===a&&o.__afterMount(i,r),!0},__afterMount:function(t,n){if(this._isMounted){for(var i in this._children){var r=this._children[i];r.__afterMount&&r.__afterMount(t,n)}!1===t||this.__async||(e(this,"mounted"),this.fireEvent(BI.Events.MOUNT)),n&&n(this)}},_mountChildren:null,_update:function(t,n){this.options;if(e(this,"beforeUpdate"),n)var i=this.update&&this.update(t,n);return e(this,"updated"),i},isMounted:function(){return this._isMounted},setWidth:function(e){this.options.width=e,this._initElementWidth()},setHeight:function(e){this.options.height=e,this._initElementHeight()},_setEnable:function(e){!0===e?this.options.disabled=!1:!1===e&&(this.options.disabled=!0),BI.each(this._children,(function(t,n){!n._manualSetEnable&&n._setEnable&&n._setEnable(e)}))},_setValid:function(e){!0===e?this.options.invalid=!1:!1===e&&(this.options.invalid=!0),BI.each(this._children,(function(t,n){!n._manualSetValid&&n._setValid&&n._setValid(e)}))},_setVisible:function(e){!0===e?this.options.invisible=!1:!1===e&&(this.options.invisible=!0)},setEnable:function(e){this._manualSetEnable=!0,this._setEnable(e),!0===e?this.element.removeClass("base-disabled disabled"):!1===e&&this.element.addClass("base-disabled disabled")},setVisible:function(e){this._setVisible(e),!0===e?(this.element.css("display",""),this._mount()):!1===e&&this.element.css("display","none"),this.fireEvent(BI.Events.VIEW,e)},setValid:function(e){this._manualSetValid=!0,this._setValid(e),!0===e?this.element.removeClass("base-invalid invalid"):!1===e&&this.element.addClass("base-invalid invalid")},doBehavior:function(){var e=arguments;BI.each(this._children,(function(t,n){n.doBehavior&&n.doBehavior.apply(n,e)}))},getWidth:function(){return this.options.width},getHeight:function(){return this.options.height},isValid:function(){return!this.options.invalid},addWidget:function(e,t){var n=this;if(e instanceof BI.Widget&&(e=(t=e).getName()),BI.isKey(e)&&(e+=""),e=e||t.getName()||BI.uniqueId("widget"),this._children[e])throw new Error("name has already been existed");return t._setParent&&t._setParent(this),t.on(BI.Events.DESTROY,(function(){BI.remove(n._children,this)})),this._children[e]=t},getWidgetByName:function(e){if(!BI.isKey(e)||e===this.getName())return this;e+="";var t=void 0,n={};return BI.any(this._children,(function(i,r){if(i===e)return t=r,!0;n[i]=r})),t||BI.any(n,(function(e,n){return t=n.getWidgetByName(e)})),t},removeWidget:function(e){BI.isWidget(e)?BI.remove(this._children,e):delete this._children[e]},hasWidget:function(e){return null!=this._children[e]},getName:function(){return this.widgetName},setTag:function(e){this.options.tag=e},getTag:function(){return this.options.tag},attr:function(e,t){var n=this;if(!BI.isPlainObject(e))return BI.isNotNull(t)?this.options[e]=t:this.options[e];BI.each(e,(function(e,t){n.attr(e,t)}))},css:function(e,t){return this.element.css(e,t)},getText:function(){},setText:function(e){},getValue:function(){},setValue:function(e){},isEnabled:function(){return!this.options.disabled},isVisible:function(){return!this.options.invisible},disable:function(){this.setEnable(!1)},enable:function(){this.setEnable(!0)},valid:function(){this.setValid(!0)},invalid:function(){this.setValid(!1)},invisible:function(){this.setVisible(!1)},visible:function(){this.setVisible(!0)},__d:function(){e(this,"beforeDestroy"),this.beforeDestroy=null,BI.each(this._children,(function(e,t){t&&t._unMount&&t._unMount()})),this._children={},this._parent=null,this._isMounted=!1,e(this,"destroyed"),this.destroyed=null},_unMount:function(){this.__d(),this.fireEvent(BI.Events.UNMOUNT),this.purgeListeners()},_empty:function(){BI.each(this._children,(function(e,t){t&&t._unMount&&t._unMount()})),this._children={},this.element.empty()},isolate:function(){this._parent&&this._parent.removeWidget(this),BI.DOM.hang([this])},empty:function(){this._empty()},reset:function(){if(!0!==this.__async&&!0!==this.__asking){if(this.options.vdom){var e=this._renderVNode();return BI.patchVNode(this.vnode,e),void(this.vnode=e)}this._empty(),this.element.unbind(),this._initCurrent(),this._init(),this._mount()}},_destroy:function(){this.__d(),this.element.destroy(),this.purgeListeners()},destroy:function(){this.__d(),this.element.destroy(),this.fireEvent(BI.Events.UNMOUNT),this.fireEvent(BI.Events.DESTROY),this._purgeRef(),this.purgeListeners()}});var t=null,n=null,i=[],r=[];BI.Widget.pushContext=function(e){t&&i.push(t),BI.Widget.context=t=e},BI.Widget.popContext=function(){BI.Widget.context=t=i.pop()},BI.useStore=function(e){if(n&&n.store)return n.store;if(n&&n.$storeDelegate)return n.$storeDelegate;if(n){var t,i={};if(_global.Proxy){var r=new Proxy(i,{get:function(e,n){return Reflect.get(t,n)},set:function(e,n,i){return Reflect.set(t,n,i)}});return n._store=function(){return t=e.apply(this,arguments)},n.$storeDelegate=r}return n._store=function(){var t=e.apply(this,arguments);return BI.extend(i,t),t},n.$storeDelegate=i}},BI.watch=function(e,t){BI.Widget.current&&(BI.Widget.current.$watchDelayCallbacks||(BI.Widget.current.$watchDelayCallbacks=[]),BI.Widget.current.$watchDelayCallbacks.push([e,t]))},BI.onBeforeMount=function(e){n&&(n.beforeMount?BI.isArray(n.beforeMount)||(n.beforeMount=[n.beforeMount]):n.beforeMount=[],n.beforeMount.push(e))},BI.onMounted=function(e){n&&(n.mounted?BI.isArray(n.mounted)||(n.mounted=[n.mounted]):n.mounted=[],n.mounted.push(e))},BI.onBeforeUnmount=function(e){n&&(n.beforeDestroy?BI.isArray(n.beforeDestroy)||(n.beforeDestroy=[n.beforeDestroy]):n.beforeDestroy=[],n.beforeDestroy.push(e))},BI.onUnmounted=function(e){n&&(n.destroyed?BI.isArray(n.destroyed)||(n.destroyed=[n.destroyed]):n.destroyed=[],n.destroyed.push(e))},BI.Widget.registerRenderEngine=function(e){BI.Widget._renderEngine=e},BI.Widget.registerRenderEngine({createElement:function(e){if(BI.isWidget(e)){var t=e.options;return t.element?BI.$(t.element):t.tagName?BI.$(document.createElement(t.tagName)):BI.$(document.createDocumentFragment())}return BI.$(e)},createFragment:function(){return document.createDocumentFragment()}}),BI.mount=function(e,t,n,i){if(!0===i){e.element.data("__widgets",[e]);var r=e._mount(!0,!1,!1,(function(e){BI.each(e._children,(function(e,t){var n=t.element.data("__widgets");n||(n=[]),n.push(t),t.element.data("__widgets",n)})),n&&n.apply(this,arguments)})),a=BI.Widget._renderEngine.createElement;BI.DOM.patchProps(e.element,a(a(t).children()[0]));var o=function(e){e.beforeMount&&e.beforeMount(),e.mounted&&e.mounted(),BI.each(e._children,(function(e,t){o(t)}))};return o(e),r}return t&&BI.Widget._renderEngine.createElement(t).append(e.element),e._mount(!0,!1,!1,n)}}()},function(e,t){!function(){var e={};BI.shortcut=BI.component=BI.shortcut||function(t,n){null!=e[t]&&_global.console&&console.error("shortcut:["+t+"] has been registed"),n&&(n.xtype=t),e[t]=n};var t=function(t,n,i){var r=e[t.type];if(!r)throw new Error("组件"+t.type+"未定义");var a=!1,o=new r;return o._context=BI.Widget.context||n,!BI.Widget.context&&n&&(a=!0,BI.Widget.pushContext(n)),o._initProps(t),o._constructed(),o._initRoot(),o._lazyConstructor(),a&&BI.Widget.popContext(),o};BI.createWidget=BI.createWidget||function(e,n,i,r){var a,o;if(BI.init(),e||(e={}),BI.isWidget(n)?(i=n,n={}):n||(n={}),BI.isEmpty(e)&&BI.isEmpty(n))return BI.createWidget({type:"bi.layout"});if(BI.isWidget(e))return e;if(e.type||n.type)return a=BI.extend({},n,e),(o=BI.Plugin.getWidget(a.type,a)).type===a.type?(BI.Plugin.hasObject(a.type)&&(o.listeners=(o.listeners||[]).concat([{eventName:BI.Events.MOUNT,action:function(){BI.Plugin.getObject(a.type,this)}}])),t(o,i)):BI.createWidget(o,n,i,r);if(e.el&&(e.el.type||n.type))return a=BI.extend({},n,e.el),(o=BI.Plugin.getWidget(a.type,a)).type===a.type?(BI.Plugin.hasObject(a.type)&&(o.listeners=(o.listeners||[]).concat([{eventName:BI.Events.MOUNT,action:function(){BI.Plugin.getObject(a.type,this)}}])),t(o,i)):BI.createWidget(o,n,i,r);if(BI.isWidget(e.el))return e.el;throw new Error("无法根据item创建组件")},BI._lazyCreateWidget=BI._lazyCreateWidget||function(e,t,n){return BI.createWidget(e,t,n,!0)},BI.createElement=BI.createElement||function(){var e=BI.createWidget.apply(this,arguments);return e.element}}()},function(e,t){var n,i,r,a,o;BI.Plugin=BI.Plugin||{},n={},i={},r={},a=[],o=[],BI.defaults(BI.Plugin,{getWidget:function(e,t){if(a.length>0)for(var i=a.slice(0),o=i.length-1;o>=0;o--)i[o](e,t);var s;if(r[e])for(o=r[e].length-1;o>=0;o--)(s=r[e][o](t))&&(t=s);if(n[e])for(o=n[e].length-1;o>=0;o--)if(s=n[e][o](t))return s;return t},config:function(e,t){a=a.concat(_.isArray(e)?e:[e]),o=o.concat(_.isArray(t)?t:[t])},configWidget:function(e,t,n){(!r[e]||n&&n.single)&&(r[e]=[]),r[e].push(t)},registerWidget:function(e,t){n[e]||(n[e]=[]),n[e].length>0&&console.log("组件已经注册过了!"),n[e].push(t)},relieveWidget:function(e){delete n[e]},getObject:function(e,t){if(o.length>0)for(var n=o.slice(0),r=n.length-1;r>=0;r--)n[r](e,t);if(i[e]){r=0;for(var a,s=i[e].length;r<s;r++)(a=i[e][r](t))&&(t=a)}return a||t},hasObject:function(e){return o.length>0||!!i[e]},registerObject:function(e,t){i[e]||(i[e]=[]),i[e].length>0&&console.log("对象已经注册过了!"),i[e].push(t)},relieveObject:function(e){delete i[e]}})},function(e,t){!function(e){"use strict";function t(e){return document.createElement(e)}function n(e,t){return document.createElementNS(e,t)}function i(e){return document.createTextNode(e)}function r(e){return document.createComment(e)}function a(e,t,n){e.insertBefore(t,n)}function o(e,t){e.removeChild(t)}function s(e,t){e.appendChild(t)}function l(e){return e.parentNode}function u(e){return e.nextSibling}function c(e){return e.tagName}function h(e,t){e.textContent=t}function p(e){return e.textContent}function d(e){return 1===e.nodeType}function f(e){return 3===e.nodeType}function g(e){return 8===e.nodeType}var m={createElement:t,createElementNS:n,createTextNode:i,createComment:r,insertBefore:a,removeChild:o,appendChild:s,parentNode:l,nextSibling:u,tagName:c,setTextContent:h,getTextContent:p,isElement:d,isText:f,isComment:g};function I(e,t,n,i,r){return{sel:e,data:t,children:n,text:i,elm:r,key:t===undefined?undefined:t.key}}var B=Array.isArray;function _(e){return"string"==typeof e||"number"==typeof e}function E(e){return e===undefined}function b(e){return e!==undefined}var y=I("",{},[],undefined,undefined);function v(e,t){return e.key===t.key&&e.sel===t.sel}function T(e){return e.sel!==undefined}function C(e,t,n){for(var i,r={},a=t;a<=n;++a){var o=null===(i=e[a])||void 0===i?void 0:i.key;o!==undefined&&(r[o]=a)}return r}var N=["create","update","remove","destroy","pre","post"];function V(e,t){var n=void 0,i=void 0,r={create:[],update:[],remove:[],destroy:[],pre:[],post:[]},a=t!==undefined?t:m;for(n=0;n<N.length;++n)for(r[N[n]]=[],i=0;i<e.length;++i){var o=e[i][N[n]];o!==undefined&&r[N[n]].push(o)}function s(e){var t=e.id?"#"+e.id:"",n=e.className?"."+e.className.split(" ").join("."):"";return I(a.tagName(e).toLowerCase()+t+n,{},[],undefined,e)}function l(e,t){return function(){if(0==--t){var n=a.parentNode(e);a.removeChild(n,e)}}}function u(e,t){var n,i,o=void 0,s=e.data;if(s!==undefined){var l=null===(n=s.hook)||void 0===n?void 0:n.init;b(l)&&(l(e),s=e.data)}var c=e.children,h=e.sel;if("!"===h)E(e.text)&&(e.text=""),e.elm=a.createComment(e.text);else if(h!==undefined){var p=h.indexOf("#"),d=h.indexOf(".",p),f=p>0?p:h.length,g=d>0?d:h.length,m=-1!==p||-1!==d?h.slice(0,Math.min(f,g)):h,I=e.elm=b(s)&&b(o=s.ns)?a.createElementNS(o,m):a.createElement(m);for(f<g&&I.setAttribute("id",h.slice(f+1,g)),d>0&&I.setAttribute("class",h.slice(g+1).replace(/\./g," ")),o=0;o<r.create.length;++o)r.create[o](y,e);if(B(c))for(o=0;o<c.length;++o){var v=c[o];null!=v&&a.appendChild(I,u(v,t))}else _(e.text)&&a.appendChild(I,a.createTextNode(e.text));var T=e.data.hook;b(T)&&(null===(i=T.create)||void 0===i||i.call(T,y,e),T.insert&&t.push(e))}else e.elm=a.createTextNode(e.text);return e.elm}function c(e,t,n,i,r,o){for(;i<=r;++i){var s=n[i];null!=s&&a.insertBefore(e,u(s,o),t)}}function h(e){var t,n,i=e.data;if(i!==undefined){null===(n=null===(t=null==i?void 0:i.hook)||void 0===t?void 0:t.destroy)||void 0===n||n.call(t,e);for(var a=0;a<r.destroy.length;++a)r.destroy[a](e);if(e.children!==undefined)for(var o=0;o<e.children.length;++o){var s=e.children[o];null!=s&&"string"!=typeof s&&h(s)}}}function p(e,t,n,i){for(var o,s;n<=i;++n){var u=void 0,c=void 0,p=t[n];if(null!=p)if(b(p.sel)){h(p),u=r.remove.length+1,c=l(p.elm,u);for(var d=0;d<r.remove.length;++d)r.remove[d](p,c);var f=null===(s=null===(o=null==p?void 0:p.data)||void 0===o?void 0:o.hook)||void 0===s?void 0:s.remove;b(f)?f(p,c):c()}else a.removeChild(e,p.elm)}}function d(e,t,n,i){for(var r=0,o=0,s=t.length-1,l=t[0],h=t[s],d=n.length-1,g=n[0],m=n[d],I=void 0,B=void 0,_=void 0;r<=s&&o<=d;)null==l?l=t[++r]:null==h?h=t[--s]:null==g?g=n[++o]:null==m?m=n[--d]:v(l,g)?(f(l,g,i),l=t[++r],g=n[++o]):v(h,m)?(f(h,m,i),h=t[--s],m=n[--d]):v(l,m)?(f(l,m,i),a.insertBefore(e,l.elm,a.nextSibling(h.elm)),l=t[++r],m=n[--d]):v(h,g)?(f(h,g,i),a.insertBefore(e,h.elm,l.elm),h=t[--s],g=n[++o]):(I===undefined&&(I=C(t,r,s)),E(B=I[g.key])||(_=t[B]).sel!==g.sel?a.insertBefore(e,u(g,i),l.elm):(f(_,g,i),t[B]=undefined,a.insertBefore(e,_.elm,l.elm)),g=n[++o]);(r<=s||o<=d)&&(r>s?c(e,null==n[d+1]?null:n[d+1].elm,n,o,d,i):p(e,t,r,s))}function f(e,t,n){var i,o,s,l,u,h=null===(i=t.data)||void 0===i?void 0:i.hook;null===(o=null==h?void 0:h.prepatch)||void 0===o||o.call(h,e,t);var f=t.elm=e.elm,g=e.children,m=t.children;if(e!==t){if(t.data!==undefined){for(var I=0;I<r.update.length;++I)r.update[I](e,t);null===(l=null===(s=t.data.hook)||void 0===s?void 0:s.update)||void 0===l||l.call(s,e,t)}E(t.text)?b(g)&&b(m)?g!==m&&d(f,g,m,n):b(m)?(b(e.text)&&a.setTextContent(f,""),c(f,null,m,0,m.length-1,n)):b(g)?p(f,g,0,g.length-1):b(e.text)&&a.setTextContent(f,""):e.text!==t.text&&(b(g)&&p(f,g,0,g.length-1),a.setTextContent(f,t.text)),null===(u=null==h?void 0:h.postpatch)||void 0===u||u.call(h,e,t)}}return function(e,t){var n=void 0,i=void 0,o=void 0,l=[];for(n=0;n<r.pre.length;++n)r.pre[n]();for(T(e)||(e=s(e)),v(e,t)?f(e,t,l):(i=e.elm,o=a.parentNode(i),u(t,l),null!==o&&(a.insertBefore(o,t.elm,a.nextSibling(i)),p(o,[e],0,0))),n=0;n<l.length;++n)l[n].data.hook.insert(l[n]);for(n=0;n<r.post.length;++n)r.post[n]();return t}}function S(e,t,n){if(e.ns="http://www.w3.org/2000/svg","foreignObject"!==n&&t!==undefined)for(var i=0;i<t.length;++i){var r=t[i].data;r!==undefined&&S(r,t[i].children,t[i].sel)}}function x(e,t,n){var i={},r=void 0,a=void 0,o=void 0;if(n!==undefined?(null!==t&&(i=t),B(n)?r=n:_(n)?a=n:n&&n.sel&&(r=[n])):t!==undefined&&null!==t&&(B(t)?r=t:_(t)?a=t:t&&t.sel?r=[t]:i=t),r!==undefined)for(o=0;o<r.length;++o)_(r[o])&&(r[o]=I(undefined,undefined,undefined,r[o],undefined));return"s"!==e[0]||"v"!==e[1]||"g"!==e[2]||3!==e.length&&"."!==e[3]&&"#"!==e[3]||S(i,r,e),I(e,i,r,a,undefined)}function w(e,t){e.data.fn=t.data.fn,e.data.args=t.data.args,t.data=e.data,t.children=e.children,t.text=e.text,t.elm=e.elm}function A(e){var t=e.data;w(t.fn.apply(undefined,t.args),e)}function L(e,t){var n=void 0,i=e.data,r=t.data,a=i.args,o=r.args;if(i.fn===r.fn&&a.length===o.length){for(n=0;n<o.length;++n)if(a[n]!==o[n])return void w(r.fn.apply(undefined,o),t);w(e,t)}else w(r.fn.apply(undefined,o),t)}var k=function(e,t,n,i){return i===undefined&&(i=n,n=t,t=undefined),x(e,{key:t,hook:{init:A,prepatch:L},fn:n,args:i})};function D(e,t){var n=e.data.attachData;t.data.attachData.placeholder=n.placeholder,t.data.attachData.real=n.real,e.elm=e.data.attachData.real}function M(e,t){t.elm=t.data.attachData.placeholder}function P(e){e.elm!==undefined&&e.elm.parentNode.removeChild(e.elm),e.elm=e.data.attachData.real}function R(e,t){var n=t.elm,i=t.data.attachData,r=document.createElement("span");t.elm=r,i.target.appendChild(n),i.real=n,i.placeholder=r}function H(e,t){t.data===undefined&&(t.data={}),t.data.hook===undefined&&(t.data.hook={});var n=t.data,i=t.data.hook;return n.attachData={target:e,placeholder:undefined,real:undefined},i.create=R,i.prepatch=D,i.postpatch=M,i.destroy=P,t}function O(e,t){var n=t!==undefined?t:m,i=void 0;if(n.isElement(e)){var r=e.id?"#"+e.id:"",a=e.getAttribute("class"),o=a?"."+a.split(" ").join("."):"",s=n.tagName(e).toLowerCase()+r+o,l={},u=[],c=void 0,h=void 0,p=void 0,d=e.attributes,f=e.childNodes;for(h=0,p=d.length;h<p;h++)"id"!==(c=d[h].nodeName)&&"class"!==c&&(l[c]=d[h].nodeValue);for(h=0,p=f.length;h<p;h++)u.push(O(f[h],t));return I(s,{attrs:l},u,undefined,e)}return n.isText(e)?(i=n.getTextContent(e),I(undefined,undefined,undefined,i,e)):n.isComment(e)?I("!",{},[],i=n.getTextContent(e),e):I("",{},[],undefined,e)}var F="http://www.w3.org/1999/xlink",Y="http://www.w3.org/XML/1998/namespace",W=58,G=120;function j(e,t){var n=void 0,i=t.elm,r=e.data.attrs,a=t.data.attrs;if((r||a)&&r!==a){for(n in r=r||{},a=a||{}){var o=a[n];r[n]!==o&&(!0===o?i.setAttribute(n,""):!1===o?i.removeAttribute(n):n.charCodeAt(0)!==G?i.setAttribute(n,o):n.charCodeAt(3)===W?i.setAttributeNS(Y,n,o):n.charCodeAt(5)===W?i.setAttributeNS(F,n,o):i.setAttribute(n,o))}for(n in r)n in a||i.removeAttribute(n)}}var Z={create:j,update:j};function X(e,t){var n=void 0,i=void 0,r=t.elm,a=e.data["class"],o=t.data["class"];if((a||o)&&a!==o){for(i in o=o||{},a=a||{})a[i]&&!Object.prototype.hasOwnProperty.call(o,i)&&r.classList.remove(i);for(i in o)(n=o[i])!==a[i]&&r.classList[n?"add":"remove"](i)}}var U={create:X,update:X},J=/[A-Z]/g;function K(e,t){var n=t.elm,i=e.data.dataset,r=t.data.dataset,a=void 0;if((i||r)&&i!==r){i=i||{},r=r||{};var o=n.dataset;for(a in i)r[a]||(o?a in o&&delete o[a]:n.removeAttribute("data-"+a.replace(J,"-$&").toLowerCase()));for(a in r)i[a]!==r[a]&&(o?o[a]=r[a]:n.setAttribute("data-"+a.replace(J,"-$&").toLowerCase(),r[a]))}}var z={create:K,update:K};function Q(e,t,n){if("function"==typeof e)e.call(t,n,t);else if("object"==typeof e)for(var i=0;i<e.length;i++)Q(e[i],t,n)}function q(e,t){var n=e.type,i=t.data.on;i&&i[n]&&Q(i[n],t,e)}function $(){return function e(t){q(t,e.vnode)}}function ee(e,t){var n=e.data.on,i=e.listener,r=e.elm,a=t&&t.data.on,o=t&&t.elm,s=void 0;if(n!==a){if(n&&i)if(a)for(s in n)a[s]||r.removeEventListener(s,i,!1);else for(s in n)r.removeEventListener(s,i,!1);if(a){var l=t.listener=e.listener||$();if(l.vnode=t,n)for(s in a)n[s]||o.addEventListener(s,l,!1);else for(s in a)o.addEventListener(s,l,!1)}}}var te={create:ee,update:ee,destroy:ee},ne="undefined"!=typeof window&&window.requestAnimationFrame||setTimeout,ie=function(e){ne((function(){ne(e)}))};function re(e,t,n){ie((function(){e[t]=n}))}function ae(e){var t=void 0;if(document.createRange){var n=document.createRange();n.selectNodeContents(e),n.getBoundingClientRect&&(t=n.getBoundingClientRect())}return t}function oe(e,t,n){return e&&t?t.left+t.width/2-n.left+"px "+(t.top+t.height/2-n.top)+"px":"0 0"}function se(e,t){return e&&t?e.left+e.width/2-(t.left+t.width/2):0}function le(e,t){return e&&t?e.top+e.height/2-(t.top+t.height/2):0}function ue(e){return 1===e.childNodes.length&&3===e.childNodes[0].nodeType}var ce=void 0,he=void 0;function pe(){ce={},he=[]}function de(e,t){var n=t.data.hero;n&&n.id&&(he.push(n.id),he.push(t))}function fe(e){var t=e.data.hero;if(t&&t.id){var n=e.elm;e.isTextNode=ue(n),e.boundingRect=n.getBoundingClientRect(),e.textRect=e.isTextNode?ae(n.childNodes[0]):null;var i=window.getComputedStyle(n,undefined);e.savedStyle=JSON.parse(JSON.stringify(i)),ce[t.id]=e}}function ge(){var e=void 0,t=void 0,n=void 0,i=void 0,r=void 0,a=void 0,o=void 0,s=void 0,l=void 0,u=void 0,c=void 0,h=void 0,p=void 0,d=void 0,f=void 0,g=void 0,m=void 0,I=void 0,B=void 0;for(e=0;e<he.length;e+=2)if(t=he[e],n=he[e+1].elm,i=ce[t]){for(var _ in m=i.isTextNode&&ue(n),d=n.style,g=window.getComputedStyle(n,undefined),f=(r=i.elm).style,l=n.getBoundingClientRect(),s=i.boundingRect,m?(I=ae(n.childNodes[0]),u=se(B=i.textRect,I),c=le(B,I)):(u=s.left-l.left,c=s.top-l.top),a=l.height/Math.max(s.height,1),o=m?a:l.width/Math.max(s.width,1),h=d.transform,p=d.transition,"inline"===g.display&&(d.display="inline-block"),d.transition=p+"transform 0s",d.transformOrigin=oe(m,I,l),d.opacity="0",d.transform=h+"translate("+u+"px, "+c+"px) scale("+1/o+", "+1/a+")",re(d,"transition",p),re(d,"transform",h),re(d,"opacity","1"),i.savedStyle)if(String(parseInt(_))!==_){var E="ms"===_.substring(0,2),b="moz"===_.substring(0,3),y="webkit"===_.substring(0,6);E||b||y||(f[_]=i.savedStyle[_])}f.position="absolute",f.top=s.top+"px",f.left=s.left+"px",f.width=s.width+"px",f.height=s.height+"px",f.margin="0",f.transformOrigin=oe(m,B,s),f.transform="",f.opacity="1",document.body.appendChild(r),re(f,"transform","translate("+-u+"px, "+-c+"px) scale("+o+", "+a+")"),re(f,"opacity","0"),r.addEventListener("transitionend",(function(e){"transform"===e.propertyName&&document.body.removeChild(e.target)}))}ce=he=undefined}var me={pre:pe,create:de,destroy:fe,post:ge};function Ie(e,t){var n=void 0,i=void 0,r=t.elm,a=e.data.props,o=t.data.props;if((a||o)&&a!==o)for(n in a=a||{},o=o||{})i=o[n],a[n]===i||"value"===n&&r[n]===i||(r[n]=i)}var Be={create:Ie,update:Ie},_e="undefined"!=typeof window&&window.requestAnimationFrame.bind(window)||setTimeout,Ee=function(e){_e((function(){_e(e)}))},be=!1;function ye(e,t,n){Ee((function(){e[t]=n}))}function ve(e,t){var n=void 0,i=void 0,r=t.elm,a=e.data.style,o=t.data.style;if((a||o)&&a!==o){o=o||{};var s="delayed"in(a=a||{});for(i in a)o[i]||("-"===i[0]&&"-"===i[1]?r.style.removeProperty(i):r.style[i]="");for(i in o)if(n=o[i],"delayed"===i&&o.delayed)for(var l in o.delayed)n=o.delayed[l],s&&n===a.delayed[l]||ye(r.style,l,n);else"remove"!==i&&n!==a[i]&&("-"===i[0]&&"-"===i[1]?r.style.setProperty(i,n):r.style[i]=n)}}function Te(e){var t=void 0,n=void 0,i=e.elm,r=e.data.style;if(r&&(t=r.destroy))for(n in t)i.style[n]=t[n]}function Ce(e,t){var n=e.data.style;if(n&&n.remove){be||(e.elm.offsetLeft,be=!0);var i=void 0,r=e.elm,a=0,o=n.remove,s=0,l=[];for(i in o)l.push(i),r.style[i]=o[i];for(var u=getComputedStyle(r)["transition-property"].split(", ");a<u.length;++a)-1!==l.indexOf(u[a])&&s++;r.addEventListener("transitionend",(function(e){e.target===r&&--s,0===s&&t()}))}else t()}function Ne(){be=!1}var Ve={pre:Ne,create:ve,update:ve,destroy:Te,remove:Ce};e.array=B,e.attachTo=H,e.attributesModule=Z,e.classModule=U,e.datasetModule=z,e.eventListenersModule=te,e.h=x,e.heroModule=me,e.htmlDomApi=m,e.init=V,e.primitive=_,e.propsModule=Be,e.styleModule=Ve,e.thunk=k,e.toVNode=O,e.vnode=I,e.__esModule=!0}(BI.Snabbdom=BI.Snabbdom||{})},function(e,t){BI.Action=BI.inherit(BI.OB,{_defaultConfig:function(){return BI.extend(BI.Action.superclass._defaultConfig.apply(this,arguments),{src:null,tar:null})},_init:function(){BI.Action.superclass._init.apply(this,arguments)},actionPerformed:function(e,t,n){},actionBack:function(e,t,n){}}),BI.ActionFactory={createAction:function(e,t){var n;switch(e){case"show":n=BI.ShowAction}return new n(t)}}},function(e,t){BI.ShowAction=BI.inherit(BI.Action,{_defaultConfig:function(){return BI.extend(BI.ShowAction.superclass._defaultConfig.apply(this,arguments),{})},actionPerformed:function(e,t,n){(t=t||this.options.tar).setVisible(!0),n&&n()},actionBack:function(e,t,n){(e=e||this.options.tar).setVisible(!1),n&&n()}})},function(e,t){BI.BehaviorFactory={createBehavior:function(e,t){var n;switch(e){case"highlight":n=BI.HighlightBehavior;break;case"redmark":n=BI.RedMarkBehavior}return new n(t)}},BI.Behavior=BI.inherit(BI.OB,{_defaultConfig:function(){return BI.extend(BI.Behavior.superclass._defaultConfig.apply(this,arguments),{rule:function(){return!0}})},_init:function(){BI.Behavior.superclass._init.apply(this,arguments)},doBehavior:function(){}})},function(e,t){BI.HighlightBehavior=BI.inherit(BI.Behavior,{_defaultConfig:function(){return BI.extend(BI.HighlightBehavior.superclass._defaultConfig.apply(this,arguments),{})},_init:function(){BI.HighlightBehavior.superclass._init.apply(this,arguments)},doBehavior:function(e){var t=Array.prototype.slice.call(arguments,1),n=this.options;BI.each(e,(function(e,i){if(i instanceof BI.Single){var r=n.rule(i.getValue(),i);function a(e){!0===e?i.doHighLight&&i.doHighLight.apply(i,t):i.unHighLight&&i.unHighLight.apply(i,t)}BI.isFunction(r)?r(a):a(r)}else i.doBehavior&&i.doBehavior.apply(i,t)}))}})},function(e,t){BI.RedMarkBehavior=BI.inherit(BI.Behavior,{_defaultConfig:function(){return BI.extend(BI.RedMarkBehavior.superclass._defaultConfig.apply(this,arguments),{})},_init:function(){BI.RedMarkBehavior.superclass._init.apply(this,arguments)},doBehavior:function(e){var t=Array.prototype.slice.call(arguments,1),n=this.options;BI.each(e,(function(e,i){i instanceof BI.Single?n.rule(i.getValue(),i)?i.doRedMark&&i.doRedMark.apply(i,t):i.doRedMark&&i.unRedMark.apply(i,t):i.doBehavior&&i.doBehavior.apply(i,t)}))}})},function(e,t){BI.Controller=BI.inherit(BI.OB,{_defaultConfig:function(){return BI.extend(BI.Controller.superclass._defaultConfig.apply(this,arguments),{})}}),BI.Controller.EVENT_CHANGE="__EVENT_CHANGE__"},function(e,t){BI.BroadcastController=BI.inherit(BI.Controller,{_defaultConfig:function(){return BI.extend(BI.BroadcastController.superclass._defaultConfig.apply(this,arguments),{})},_init:function(){BI.BroadcastController.superclass._init.apply(this,arguments),this._broadcasts={}},on:function(e,t){var n=this;return this._broadcasts[e]||(this._broadcasts[e]=[]),this._broadcasts[e].push(t),function(){n.remove(e,t)}},send:function(e){var t=[].slice.call(arguments,1);BI.each(this._broadcasts[e],(function(e,n){n.apply(null,t)}))},remove:function(e,t){var n=this;return t?(BI.remove(this._broadcasts[e],(function(i){return n._broadcasts[e].indexOf(t)===i})),this._broadcasts[e].remove(t),0===this._broadcasts[e].length&&delete this._broadcasts[e]):delete this._broadcasts[e],this}})},function(e,t){BI.BubblesController=BI.inherit(BI.Controller,{_defaultConfig:function(){return BI.extend(BI.BubblesController.superclass._defaultConfig.apply(this,arguments),{})},_const:{bubbleHeight:18},_init:function(){BI.BubblesController.superclass._init.apply(this,arguments);var e=this;this.fixedBubblesManager={},this.fixedStoreBubbles={},this.bubblesManager={},this.storeBubbles={},BI.Resizers.add("bubbleController"+BI.uniqueId(),(function(){BI.each(e.fixedBubblesManager,(function(t){e.remove(t)})),e.fixedBubblesManager={},e.fixedStoreBubbles={}}))},_createBubble:function(e,t,n,i,r){return BI.createWidget({type:!1===r?"bi.bubble_view":"bi.bubble",text:t,level:n,height:i||18,direction:e})},_getOffsetLeft:function(e,t,n){var i=0;return"center"===n?((i=t.element.offset().left+(t.element.bounds().width-this.get(e).element.bounds().width)/2)<0&&(i=0),i):"right"===n?((i=t.element.offset().left+t.element.bounds().width-this.get(e).element.bounds().width)<0&&(i=0),i):t.element.offset().left},_getOffsetTop:function(e,t,n){var i=0;return"center"===n?((i=t.element.offset().top+(t.element.bounds().height-this.get(e).element.bounds().height)/2)<0&&(i=0),i):"right"===n?((i=t.element.offset().top+t.element.bounds().height-this.get(e).element.bounds().height)<0&&(i=0),i):t.element.offset().top},_getLeftPosition:function(e,t,n){var i=BI.DOM.getLeftPosition(t,this.get(e));return i.top=this._getOffsetTop(e,t,n),i},_getBottomPosition:function(e,t,n){var i=BI.DOM.getBottomPosition(t,this.get(e));return i.left=this._getOffsetLeft(e,t,n),i},_getTopPosition:function(e,t,n){var i=BI.DOM.getTopPosition(t,this.get(e));return i.left=this._getOffsetLeft(e,t,n),i},_getRightPosition:function(e,t,n){var i=BI.DOM.getRightPosition(t,this.get(e));return i.top=this._getOffsetTop(e,t,n),i},show:function(e,t,n,i){i||(i={});var r=i.container||n,a=i.offsetStyle||"left",o=i.level||"error",s=i.adjustYOffset||0,l=i.adjustXOffset||0,u=!1!==i.fixed;if(!1===u){this.storeBubbles[e]||(this.storeBubbles[e]={}),this.storeBubbles[e].top||(this.storeBubbles[e].top=this._createBubble("top",t,o,null,u)),BI.createWidget({type:"bi.absolute",element:r,items:[{el:this.storeBubbles[e].top}]}),this.set(e,this.storeBubbles[e].top);var c=this.storeBubbles[e].top,h=c.element.bounds();if(BI.DOM.isTopSpaceEnough(n,this.get(e),s)){var p=-(h.height+s);switch(a){case"center":c.element.css({left:(n.element.bounds().width-h.width)/2+l,top:p});break;case"right":c.element.css({right:l,top:p});break;default:c.element.css({left:l,top:p})}}else{var d=-(h.height+s);switch(a){case"center":c.element.css({left:(n.element.bounds().width-h.width)/2+l,bottom:d});break;case"right":c.element.css({right:l,bottom:d});break;default:c.element.css({left:l,bottom:d})}}}else{this.fixedStoreBubbles[e]||(this.fixedStoreBubbles[e]={}),this.fixedStoreBubbles[e].top||(this.fixedStoreBubbles[e].top=this._createBubble("top",t,o,null,u)),BI.createWidget({type:"bi.absolute",element:r,items:[{el:this.fixedStoreBubbles[e].top}]}),this.set(e,this.fixedStoreBubbles[e].top);var f=this._getTopPosition(e,n,a);if(this.get(e).element.css({left:f.left+l,top:f.top-s}),!BI.DOM.isTopSpaceEnough(n,this.get(e),s)){this.get(e).invisible(),this.fixedStoreBubbles[e].bottom||(this.fixedStoreBubbles[e].bottom=this._createBubble("bottom",t,o)),BI.createWidget({type:"bi.absolute",element:r,items:[{el:this.fixedStoreBubbles[e].bottom}]}),this.set(e,this.fixedStoreBubbles[e].bottom);f=this._getBottomPosition(e,n,a);if(this.get(e).element.css({left:f.left+l,top:f.top+s}),!BI.DOM.isBottomSpaceEnough(n,this.get(e),s)){this.get(e).invisible(),this.fixedStoreBubbles[e].right||(this.fixedStoreBubbles[e].right=this._createBubble("right",t,o)),BI.createWidget({type:"bi.absolute",element:r,items:[{el:this.fixedStoreBubbles[e].right}]}),this.set(e,this.fixedStoreBubbles[e].right);f=this._getRightPosition(e,n,a);if(this.get(e).element.css({left:f.left+l,top:f.top-s}),!BI.DOM.isRightSpaceEnough(n,this.get(e),l)){this.get(e).invisible(),this.fixedStoreBubbles[e].left||(this.fixedStoreBubbles[e].left=this._createBubble("left",t,o,30)),BI.createWidget({type:"bi.absolute",element:r,items:[{el:this.fixedStoreBubbles[e].left}]}),this.set(e,this.fixedStoreBubbles[e].left);f=this._getLeftPosition(e,n,a);this.get(e).element.css({left:f.left-l,top:f.top-s})}}}}return this.get(e).setText(t),this.get(e).visible(),this},hide:function(e){return this.has(e)?(this.get(e).invisible(),this):this},add:function(e,t){return this.has(e)||this.set(e,t),this},get:function(e){return this.fixedBubblesManager[e]||this.bubblesManager[e]},set:function(e,t,n){!1===n?this.bubblesManager[e]=t:this.fixedBubblesManager[e]=t},has:function(e){return null!=this.fixedBubblesManager[e]||null!=this.bubblesManager[e]},remove:function(e){return this.has(e)?(BI.each(this.fixedStoreBubbles[e],(function(e,t){t.destroy()})),delete this.fixedStoreBubbles[e],delete this.fixedBubblesManager[e],BI.each(this.storeBubbles[e],(function(e,t){t.destroy()})),delete this.storeBubbles[e],delete this.bubblesManager[e],this):this}})},function(e,t){BI.LayerController=BI.inherit(BI.Controller,{_defaultConfig:function(){return BI.extend(BI.LayerController.superclass._defaultConfig.apply(this,arguments),{render:"body"})},_init:function(){BI.LayerController.superclass._init.apply(this,arguments),this.layerManager={},this.layouts={},this.zindex=BI.zIndex_layer,BI.Resizers.add("layerController"+BI.uniqueId(),BI.bind(this._resize,this))},_resize:function(){BI.each(this.layouts,(function(e,t){t.element.is(":visible")&&t.element.trigger("__resize__")}))},make:function(e,t,n,i){return BI.isWidget(t)?(n=n||{}).container=t:(i=n,n=t),this.create(e,null,n,i)},create:function(e,t,n,i){if(this.has(e))return this.get(e);n||(n={});var r=n.offset||{},a=t;if(BI.isWidget(t)&&(a=t.element),BI.isNotEmptyString(a)&&(a=BI.Widget._renderEngine.createElement(a)),this.has(e))return this.get(e);var o=BI.createWidget(n.render||{},BI.extend({type:"bi.layout"},n),i),s=BI.createWidget({type:"bi.absolute",invisible:!0,items:[{el:o,left:0,right:0,top:0,bottom:0}]},i);return BI.createWidget({type:"bi.absolute",element:n.container||this.options.render,items:[{el:s,left:r.left||0,right:r.right||0,top:r.top||0,bottom:r.bottom||0}]}),a&&(s.element.addClass("bi-popup-view"),s.element.css({left:a.offset().left+(r.left||0),top:a.offset().top+(r.top||0),width:r.width||a.outerWidth()-(r.left||0)-(r.right||0)||"",height:r.height||a.outerHeight()-(r.top||0)-(r.bottom||0)||""}),s.element.on("__resize__",(function(){a.is(":visible")&&s.element.css({left:a.offset().left+(r.left||0),top:a.offset().top+(r.top||0),width:r.width||a.outerWidth()-(r.left||0)-(r.right||0)||"",height:r.height||a.outerHeight()-(r.top||0)-(r.bottom||0)||""})}))),this.add(e,o,s),o},hide:function(e,t){return this.has(e)?(this._getLayout(e).invisible(),this._getLayout(e).element.hide(0,t),this):this},show:function(e,t){return this.has(e)?(this._getLayout(e).visible(),this._getLayout(e).element.css("z-index",this.zindex++).show(0,t).trigger("__resize__"),this):this},isVisible:function(e){return this.has(e)&&this._getLayout(e).isVisible()},add:function(e,t,n){if(this.has(e))throw new Error("name is already exist");return n.setVisible(!1),this.layerManager[e]=t,this.layouts[e]=n,n.element.css("z-index",this.zindex++),this},_getLayout:function(e){return this.layouts[e]},get:function(e){return this.layerManager[e]},has:function(e){return null!=this.layerManager[e]},remove:function(e){return this.has(e)?(this.layerManager[e].destroy(),this.layouts[e].destroy(),delete this.layerManager[e],delete this.layouts[e],this):this},removeAll:function(){var e=this;return BI.each(BI.keys(this.layerManager),(function(t,n){e.layerManager[n].destroy(),e.layouts[n].destroy()})),this.layerManager={},this.layouts={},this}})},function(e,t){BI.MaskersController=BI.inherit(BI.LayerController,{_defaultConfig:function(){return BI.extend(BI.MaskersController.superclass._defaultConfig.apply(this,arguments),{})},_init:function(){BI.MaskersController.superclass._init.apply(this,arguments),this.zindex=BI.zIndex_masker}})},function(e,t){BI.PopoverController=BI.inherit(BI.Controller,{_defaultConfig:function(){return BI.extend(BI.PopoverController.superclass._defaultConfig.apply(this,arguments),{modal:!0,render:"body"})},_init:function(){BI.PopoverController.superclass._init.apply(this,arguments),this.modal=this.options.modal,this.floatManager={},this.floatLayer={},this.floatContainer={},this.floatOpened={},this.zindex=BI.zIndex_popover,this.zindexMap={}},_check:function(e){return BI.isNotNull(this.floatManager[e])},create:function(e,t,n){if(this._check(e))return this;var i=BI.createWidget(t||{},{type:"bi.popover"},n);return this.add(e,i,t,n),this},add:function(e,t,n,i){var r,a=this;return n||(n={}),this._check(e)||(this.floatContainer[e]=BI.createWidget({type:"bi.absolute",cls:"bi-popup-view",items:[{el:this.floatLayer[e]=BI.createWidget({type:"bi.absolute",items:[t]},i),left:0,right:0,top:0,bottom:0}]}),this.floatManager[e]=t,r=e,t.on(BI.Popover.EVENT_CLOSE,(function(){a.close(r)})),BI.createWidget({type:"bi.absolute",element:n.container||this.options.render,items:[{el:this.floatContainer[e],left:0,right:0,top:0,bottom:0}]})),this},open:function(e){if(!this._check(e))return this;if(!this.floatOpened[e]){this.floatOpened[e]=!0;var t=this.floatContainer[e];t.element.css("zIndex",this.zindex++),this.modal&&t.element.__hasZIndexMask__(this.zindexMap[e])&&t.element.__releaseZIndexMask__(this.zindexMap[e]),this.zindexMap[e]=this.zindex,this.modal&&t.element.__buildZIndexMask__(this.zindex++),this.get(e).setZindex(this.zindex++),this.floatContainer[e].visible();var n=this.get(e);n.show&&n.show();var i=BI.Widget._renderEngine.createElement(this.options.render).width(),r=BI.Widget._renderEngine.createElement(this.options.render).height(),a=(i-n.element.width())/2,o=(r-n.element.height())/2;a<0&&(a=0),o<0&&(o=0),n.element.css({left:a/BI.pixRatio+BI.pixUnit,top:o/BI.pixRatio+BI.pixUnit})}return this},close:function(e){return this._check(e)?(this.floatOpened[e]&&(delete this.floatOpened[e],this.floatContainer[e].invisible(),this.modal&&this.floatContainer[e].element.__releaseZIndexMask__(this.zindexMap[e])),this):this},get:function(e){return this.floatManager[e]},remove:function(e){return this._check(e)?(this.floatContainer[e].destroy(),this.modal&&this.floatContainer[e].element.__releaseZIndexMask__(this.zindexMap[e]),delete this.floatManager[e],delete this.floatLayer[e],delete this.zindexMap[e],delete this.floatContainer[e],delete this.floatOpened[e],this):this},removeAll:function(){var e=this;return BI.each(this.floatContainer,(function(t,n){n.destroy(),e.modal&&e.floatContainer[t].element.__releaseZIndexMask__(e.zindexMap[t])})),this.floatManager={},this.floatLayer={},this.floatContainer={},this.floatOpened={},this.zindexMap={},this}})},function(e,t){BI.ResizeController=BI.inherit(BI.Controller,{_defaultConfig:function(){return BI.extend(BI.ResizeController.superclass._defaultConfig.apply(this,arguments),{})},_init:function(){BI.ResizeController.superclass._init.apply(this,arguments);var e=this;this.resizerManger={};var t=BI.debounce((function(t){e._resize(t)}),30);"onorientationchange"in _global?_global.onorientationchange=t:BI.Widget._renderEngine.createElement(_global).resize(t)},_resize:function(e){BI.each(this.resizerManger,(function(t,n){n instanceof BI.$?n.is(":visible")&&n.trigger("__resize__"):n instanceof BI.Layout?n.resize():BI.isFunction(n)&&n(e)}))},add:function(e,t){var n=this;return this.has(e)?this:(this.resizerManger[e]=t,function(){n.remove(e)})},get:function(e){return this.resizerManger[e]},has:function(e){return null!=this.resizerManger[e]},remove:function(e){return this.has(e)?(delete this.resizerManger[e],this):this}})},function(e,t){BI.TooltipsController=BI.inherit(BI.Controller,{_defaultConfig:function(){return BI.extend(BI.TooltipsController.superclass._defaultConfig.apply(this,arguments),{})},_const:{height:18},_init:function(){BI.TooltipsController.superclass._init.apply(this,arguments),this.tooltipsManager={},this.showingTips={}},_createTooltip:function(e,t){return BI.createWidget({type:"bi.tooltip",text:e,level:t,stopEvent:!0})},hide:function(e,t){return this.has(e)?(delete this.showingTips[e],this.get(e).element.hide(0,t),this.get(e).invisible(),this):this},create:function(e,t,n,i){if(!this.has(e)){var r=this._createTooltip(t,n);this.add(e,r),BI.createWidget({type:"bi.absolute",element:i||"body",items:[{el:r}]}),r.invisible()}return this.get(e)},show:function(e,t,n,i,r,a){a||(a={});var o=this;if(BI.each(this.showingTips,(function(e,t){o.hide(e)})),this.showingTips={},this.has(t)||this.create(t,n,i,a.container||"body"),!a.belowMouse){var s=r.element.offset(),l=r.element.bounds();if(0===l.height||0===l.width)return;var u=s.top+l.height+5}var c=this.get(t);c.setText(n),c.element.css({left:"0px",top:"0px"}),c.visible(),c.element.height(c.element[0].scrollHeight),this.showingTips[t]=!0;var h=(e.pageX||e.clientX)+15,p=(e.pageY||e.clientY)+15;h+c.element.outerWidth()>BI.Widget._renderEngine.createElement("body").outerWidth()&&(h-=c.element.outerWidth()+15);var d=BI.Widget._renderEngine.createElement("body").outerHeight();return p+c.element.outerHeight()>d||u+c.element.outerHeight()>d?(p-=c.element.outerHeight()+15,!a.belowMouse&&(p=Math.min(p,s.top-c.element.outerHeight()-5))):!a.belowMouse&&(p=Math.max(p,u)),c.element.css({left:h<0?0:h/BI.pixRatio+BI.pixUnit,top:p<0?0:p/BI.pixRatio+BI.pixUnit}),c.element.hover((function(){o.remove(t),r.element.trigger("mouseleave.title"+r.getName())})),this},add:function(e,t){return this.has(e)||this.set(e,t),this},get:function(e){return this.tooltipsManager[e]},set:function(e,t){this.tooltipsManager[e]=t},has:function(e){return null!=this.tooltipsManager[e]},remove:function(e){return this.has(e)?(this.tooltipsManager[e].destroy(),delete this.tooltipsManager[e],this):this}})},function(e,t){var r;r=BI.Snabbdom.init([BI.Snabbdom.attributesModule,BI.Snabbdom.classModule,BI.Snabbdom.datasetModule,BI.Snabbdom.propsModule,BI.Snabbdom.styleModule,BI.Snabbdom.eventListenersModule]),BI.Element2Vnode=function(e){if(3===e.nodeType)return BI.Snabbdom.vnode(undefined,undefined,undefined,e.textContent,e);var t=BI.jQuery._data(e),r={};BI.each(t&&t.events,(function(e,t){r[e]=function(){var e=this,n=arguments;BI.each(t,(function(t,i){i.handler.apply(e,n)}))}}));var a={},o=e.attributes,s=e.childNodes,l=e.getAttribute("key");for(i=0,n=o.length;i<n;i++){var u=o[i].nodeName;"id"!==u&&"class"!==u&&(a[u]=o[i].nodeValue)}var c=BI.Snabbdom.vnode(e.nodeName,{"class":BI.makeObject(e.classList),attrs:a,key:l,on:r,hook:{create:function(){BI.each(BI.Widget._renderEngine.createElement(e).data("__widgets"),(function(e,t){t.element=BI.Widget._renderEngine.createElement(c.elm)}))}}},BI.map(s,(function(e,t){return BI.Element2Vnode(t)})),undefined,e);return c},BI.patchVNode=function(e,t){r(e,t)}},function(e,t){BI.Fragment=function(){},BI.h=function(e,t,n){if(null!=n?BI.isArray(n)||(n=[n]):n=[],arguments.length>3)for(var i=3;i<arguments.length;i++)BI.isArray(arguments[i])?n=n.concat(arguments[i]):n.push(arguments[i]);return e===BI.Fragment?n:(BI.isFunction(e)&&(e=e.xtype||e),"el"===e?BI.extend({el:n[0]},t):BI.extend({type:e},n.length>0?{items:n}:{},t))}},function(e,t){BI.ShowListener=BI.inherit(BI.OB,{_defaultConfig:function(){return BI.extend(BI.ShowListener.superclass._defaultConfig.apply(this,arguments),{eventObj:BI.createWidget(),cardLayout:null,cardNameCreator:function(e){return e},cardCreator:BI.emptyFn,afterCardCreated:BI.emptyFn,afterCardShow:BI.emptyFn})},_init:function(){BI.ShowListener.superclass._init.apply(this,arguments);var e=this,t=this.options;t.eventObj&&t.eventObj.on(BI.Controller.EVENT_CHANGE,(function(n,i,r){if(n===BI.Events.CLICK){if(i=i||t.eventObj.getValue(),i=BI.isArray(i)?i.length>1?i.toString():i[0]:i,BI.isNull(i))throw new Error("value cannot be null");var a=t.cardNameCreator(i);if(!t.cardLayout.isCardExisted(a)){var o=t.cardCreator(a);t.cardLayout.addCardByName(a,o),t.afterCardCreated(a)}t.cardLayout.showCardByName(a),BI.nextTick((function(){t.afterCardShow(a),e.fireEvent(BI.ShowListener.EVENT_CHANGE,a)}))}}))}}),BI.ShowListener.EVENT_CHANGE="EVENT_CHANGE"},function(e,t){BI.StyleLoaderManager=BI.inherit(BI.OB,{_defaultConfig:function(){return BI.extend(BI.StyleLoaderManager.superclass._defaultConfig.apply(this,arguments),{})},_init:function(){BI.StyleLoaderManager.superclass._init.apply(this,arguments),this.stylesManager={}},loadStyle:function(e,t){if(_global.document){var n=document,i=n.createElement("style");return n.getElementsByTagName("head")[0].appendChild(i),i.setAttribute("type","text/css"),i.styleSheet?i.styleSheet.cssText=t:i.appendChild(document.createTextNode(t)),this.stylesManager[e]=i,this}},get:function(e){return this.stylesManager[e]},has:function(e){return null!=this.stylesManager[e]},removeStyle:function(e){return this.has(e)?(this.stylesManager[e].parentNode.removeChild(this.stylesManager[e]),delete this.stylesManager[e],this):this}})},function(e,t){BI.Logic=BI.inherit(BI.OB,{createLogic:function(){return this.options||{}}}),BI.LogicFactory={Type:{Vertical:"vertical",Horizontal:"horizontal",Table:"table",HorizontalFill:"horizontal_fill"},createLogic:function(e,t){var n;switch(e){case BI.LogicFactory.Type.Vertical:n=BI.VerticalLayoutLogic;break;case BI.LogicFactory.Type.Horizontal:n=BI.HorizontalLayoutLogic;break;case BI.LogicFactory.Type.Table:n=BI.TableLayoutLogic;break;case BI.LogicFactory.Type.HorizontalFill:n=BI.HorizontalFillLayoutLogic;break;default:n=BI.Logic}return new n(t).createLogic()},createLogicTypeByDirection:function(e){switch(e){case BI.Direction.Top:case BI.Direction.Bottom:case BI.Direction.Custom:return BI.LogicFactory.Type.Vertical;case BI.Direction.Left:case BI.Direction.Right:return BI.LogicFactory.Type.Horizontal}},createLogicItemsByDirection:function(e){var t=Array.prototype.slice.call(arguments,1);switch(t=BI.map(t,(function(e,t){return BI.isWidget(t)?{el:t,width:t.options.width,height:t.options.height}:t})),e){case BI.Direction.Bottom:BI.LogicFactory.Type.Vertical,t.reverse();break;case BI.Direction.Right:BI.LogicFactory.Type.Horizontal,t.reverse();break;case BI.Direction.Custom:t=t.slice(1)}return t}}},function(e,t){BI.VerticalLayoutLogic=BI.inherit(BI.Logic,{_defaultConfig:function(){return BI.extend(BI.VerticalLayoutLogic.superclass._defaultConfig.apply(this,arguments),{dynamic:!1,scrollable:null,scrolly:!1,scrollx:!1,items:[],hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},createLogic:function(){var e=this.options;return{type:e.dynamic?"bi.vertical":"bi.vtape",scrollable:e.scrollable,scrolly:e.scrolly,scrollx:e.scrollx,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,items:e.items}}}),BI.HorizontalLayoutLogic=BI.inherit(BI.Logic,{_defaultConfig:function(){return BI.extend(BI.HorizontalLayoutLogic.superclass._defaultConfig.apply(this,arguments),{dynamic:!1,scrollable:null,scrolly:!1,scrollx:!1,items:[],hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},createLogic:function(){var e=this.options;return{type:e.dynamic?"bi.vertical_adapt":"bi.htape",scrollable:e.scrollable,scrolly:e.scrolly,scrollx:e.scrollx,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,items:e.items}}}),BI.TableLayoutLogic=BI.inherit(BI.Logic,{_defaultConfig:function(){return BI.extend(BI.TableLayoutLogic.superclass._defaultConfig.apply(this,arguments),{dynamic:!1,scrollable:null,scrolly:!1,scrollx:!1,columns:0,rows:0,columnSize:[],rowSize:[],hgap:0,vgap:0,items:[]})},createLogic:function(){var e=this.options;return{type:e.dynamic?"bi.table":"bi.window",scrollable:e.scrollable,scrolly:e.scrolly,scrollx:e.scrollx,columns:e.columns,rows:e.rows,columnSize:e.columnSize,rowSize:e.rowSize,hgap:e.hgap,vgap:e.vgap,items:e.items}}}),BI.HorizontalFillLayoutLogic=BI.inherit(BI.Logic,{_defaultConfig:function(){return BI.extend(BI.HorizontalFillLayoutLogic.superclass._defaultConfig.apply(this,arguments),{dynamic:!1,scrollable:null,scrolly:!1,scrollx:!1,items:[],hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},createLogic:function(){var e=this.options,t=[];return BI.each(e.items,(function(e,n){t.push(n.width||0)})),{type:e.dynamic?"bi.horizontal_adapt":"bi.htape",columnSize:t,scrollable:e.scrollable,scrolly:e.scrolly,scrollx:e.scrollx,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,items:e.items}}})},function(e,t){Number.prototype.toFixed&&"0.000"===8e-5.toFixed(3)&&"0"!==.9.toFixed(0)&&"1.25"===1.255.toFixed(2)&&"1000000000000000128"===(0xde0b6b3a7640080).toFixed(0)||function(){var e,t;function n(n,i){for(var r=-1;++r<6;)i+=n*t[r],t[r]=i%e,i=Math.floor(i/e)}function i(n){for(var i=6,r=0;--i>=0;)r+=t[i],t[i]=Math.floor(r/n),r=r%n*e}function r(){for(var e=6,n="";--e>=0;)if(""!==n||0===e||0!==t[e]){var i=String(t[e]);""===n?n=i:n+="0000000".slice(0,7-i.length)+i}return n}function a(e,t,n){return 0===t?n:t%2==1?a(e,t-1,n*e):a(e*e,t/2,n)}e=1e7,t=[0,0,0,0,0,0],Number.prototype.toFixed=function(e){var t,o,s,l,u,c,h,p;if((t=(t=Number(e))!=t?0:Math.floor(t))<0||t>20)throw new RangeError("Number.toFixed called with invalid number of decimals");if((o=Number(this))!=o)return"NaN";if(o<=-1e21||o>1e21)return String(o);if(s="",o<0&&(s="-",o=-o),l="0",o>1e-21)if(c=(u=function(e){for(var t=0;e>=4096;)t+=12,e/=4096;for(;e>=2;)t+=1,e/=2;return t}(o*a(2,69,1))-69)<0?o*a(2,-u,1):o/a(2,u,1),c*=4503599627370496,(u=52-u)>0){for(n(0,c),h=t;h>=7;)n(1e7,0),h-=7;for(n(a(10,h,1),0),h=u-1;h>=23;)i(1<<23),h-=23;i(1<<h),n(1,1),i(2),l=r()}else n(0,c),n(1<<-u,0),l=r()+"0.00000000000000000000".slice(2,2+t);return l=t>0?(p=l.length)<=t?s+"0.0000000000000000000".slice(0,t-p+2)+l:s+l.slice(0,p-t)+"."+l.slice(p-t):s+l}}()},function(e,t){!function(){BI.CRYPT_TYPE=BI.CRYPT_TYPE||{},BI.CRYPT_TYPE.AES="aes";var e,t,n,i=i||function(e,t){var n={},i=n.lib={},r=i.Base=function(){function e(){}return{extend:function(t){e.prototype=this;var n=new e;return t&&n.mixIn(t),n.hasOwnProperty("init")||(n.init=function(){n.$super.init.apply(this,arguments)}),n.init.prototype=n,n.$super=this,n},create:function(){var e=this.extend();return e.init.apply(e,arguments),e},init:function(){},mixIn:function(e){for(var t in e)e.hasOwnProperty(t)&&(this[t]=e[t]);e.hasOwnProperty("toString")&&(this.toString=e.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),a=i.WordArray=r.extend({init:function(e,t){e=this.words=e||[],this.sigBytes=null!=t?t:4*e.length},toString:function(e){return(e||s).stringify(this)},concat:function(e){var t=this.words,n=e.words,i=this.sigBytes,r=e.sigBytes;if(this.clamp(),i%4)for(var a=0;a<r;a++){var o=n[a>>>2]>>>24-a%4*8&255;t[i+a>>>2]|=o<<24-(i+a)%4*8}else if(n.length>65535)for(a=0;a<r;a+=4)t[i+a>>>2]=n[a>>>2];else t.push.apply(t,n);return this.sigBytes+=r,this},clamp:function(){var t=this.words,n=this.sigBytes;t[n>>>2]&=4294967295<<32-n%4*8,t.length=e.ceil(n/4)},clone:function(){var e=r.clone.call(this);return e.words=this.words.slice(0),e},random:function(t){for(var n=[],i=0;i<t;i+=4)n.push(4294967296*e.random()|0);return new a.init(n,t)}}),o=n.enc={},s=o.Hex={stringify:function(e){for(var t=e.words,n=e.sigBytes,i=[],r=0;r<n;r++){var a=t[r>>>2]>>>24-r%4*8&255;i.push((a>>>4).toString(16)),i.push((15&a).toString(16))}return i.join("")},parse:function(e){for(var t=e.length,n=[],i=0;i<t;i+=2)n[i>>>3]|=parseInt(e.substr(i,2),16)<<24-i%8*4;return new a.init(n,t/2)}},l=o.Latin1={stringify:function(e){for(var t=e.words,n=e.sigBytes,i=[],r=0;r<n;r++){var a=t[r>>>2]>>>24-r%4*8&255;i.push(String.fromCharCode(a))}return i.join("")},parse:function(e){for(var t=e.length,n=[],i=0;i<t;i++)n[i>>>2]|=(255&e.charCodeAt(i))<<24-i%4*8;return new a.init(n,t)}},u=o.Utf8={stringify:function(e){try{return decodeURIComponent(escape(l.stringify(e)))}catch(t){throw new Error("Malformed UTF-8 data")}},parse:function(e){return l.parse(unescape(encodeURIComponent(e)))}},c=i.BufferedBlockAlgorithm=r.extend({reset:function(){this._data=new a.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=u.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var n=this._data,i=n.words,r=n.sigBytes,o=this.blockSize,s=r/(4*o),l=(s=t?e.ceil(s):e.max((0|s)-this._minBufferSize,0))*o,u=e.min(4*l,r);if(l){for(var c=0;c<l;c+=o)this._doProcessBlock(i,c);var h=i.splice(0,l);n.sigBytes-=u}return new a.init(h,u)},clone:function(){var e=r.clone.call(this);return e._data=this._data.clone(),e},_minBufferSize:0}),h=(i.Hasher=c.extend({cfg:r.extend(),init:function(e){this.cfg=this.cfg.extend(e),this.reset()},reset:function(){c.reset.call(this),this._doReset()},update:function(e){return this._append(e),this._process(),this},finalize:function(e){return e&&this._append(e),this._doFinalize()},blockSize:16,_createHelper:function(e){return function(t,n){return new e.init(n).finalize(t)}},_createHmacHelper:function(e){return function(t,n){return new h.HMAC.init(e,n).finalize(t)}}}),n.algo={});return n}(Math);t=(e=i).lib.WordArray,e.enc.Base64={stringify:function(e){var t=e.words,n=e.sigBytes,i=this._map;e.clamp();for(var r=[],a=0;a<n;a+=3)for(var o=(t[a>>>2]>>>24-a%4*8&255)<<16|(t[a+1>>>2]>>>24-(a+1)%4*8&255)<<8|t[a+2>>>2]>>>24-(a+2)%4*8&255,s=0;s<4&&a+.75*s<n;s++)r.push(i.charAt(o>>>6*(3-s)&63));var l=i.charAt(64);if(l)for(;r.length%4;)r.push(l);return r.join("")},parse:function(e){var n=e.length,i=this._map,r=i.charAt(64);if(r){var a=e.indexOf(r);-1!=a&&(n=a)}for(var o=[],s=0,l=0;l<n;l++)if(l%4){var u=i.indexOf(e.charAt(l-1))<<l%4*2,c=i.indexOf(e.charAt(l))>>>6-l%4*2;o[s>>>2]|=(u|c)<<24-s%4*8,s++}return t.create(o,s)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="},function(e){var t=i,n=t.lib,r=n.WordArray,a=n.Hasher,o=t.algo,s=[];!function(){for(var t=0;t<64;t++)s[t]=4294967296*e.abs(e.sin(t+1))|0}();var l=o.MD5=a.extend({_doReset:function(){this._hash=new r.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(e,t){for(var n=0;n<16;n++){var i=t+n,r=e[i];e[i]=16711935&(r<<8|r>>>24)|4278255360&(r<<24|r>>>8)}var a=this._hash.words,o=e[t+0],l=e[t+1],d=e[t+2],f=e[t+3],g=e[t+4],m=e[t+5],I=e[t+6],B=e[t+7],_=e[t+8],E=e[t+9],b=e[t+10],y=e[t+11],v=e[t+12],T=e[t+13],C=e[t+14],N=e[t+15],V=a[0],S=a[1],x=a[2],w=a[3];V=u(V,S,x,w,o,7,s[0]),w=u(w,V,S,x,l,12,s[1]),x=u(x,w,V,S,d,17,s[2]),S=u(S,x,w,V,f,22,s[3]),V=u(V,S,x,w,g,7,s[4]),w=u(w,V,S,x,m,12,s[5]),x=u(x,w,V,S,I,17,s[6]),S=u(S,x,w,V,B,22,s[7]),V=u(V,S,x,w,_,7,s[8]),w=u(w,V,S,x,E,12,s[9]),x=u(x,w,V,S,b,17,s[10]),S=u(S,x,w,V,y,22,s[11]),V=u(V,S,x,w,v,7,s[12]),w=u(w,V,S,x,T,12,s[13]),x=u(x,w,V,S,C,17,s[14]),V=c(V,S=u(S,x,w,V,N,22,s[15]),x,w,l,5,s[16]),w=c(w,V,S,x,I,9,s[17]),x=c(x,w,V,S,y,14,s[18]),S=c(S,x,w,V,o,20,s[19]),V=c(V,S,x,w,m,5,s[20]),w=c(w,V,S,x,b,9,s[21]),x=c(x,w,V,S,N,14,s[22]),S=c(S,x,w,V,g,20,s[23]),V=c(V,S,x,w,E,5,s[24]),w=c(w,V,S,x,C,9,s[25]),x=c(x,w,V,S,f,14,s[26]),S=c(S,x,w,V,_,20,s[27]),V=c(V,S,x,w,T,5,s[28]),w=c(w,V,S,x,d,9,s[29]),x=c(x,w,V,S,B,14,s[30]),V=h(V,S=c(S,x,w,V,v,20,s[31]),x,w,m,4,s[32]),w=h(w,V,S,x,_,11,s[33]),x=h(x,w,V,S,y,16,s[34]),S=h(S,x,w,V,C,23,s[35]),V=h(V,S,x,w,l,4,s[36]),w=h(w,V,S,x,g,11,s[37]),x=h(x,w,V,S,B,16,s[38]),S=h(S,x,w,V,b,23,s[39]),V=h(V,S,x,w,T,4,s[40]),w=h(w,V,S,x,o,11,s[41]),x=h(x,w,V,S,f,16,s[42]),S=h(S,x,w,V,I,23,s[43]),V=h(V,S,x,w,E,4,s[44]),w=h(w,V,S,x,v,11,s[45]),x=h(x,w,V,S,N,16,s[46]),V=p(V,S=h(S,x,w,V,d,23,s[47]),x,w,o,6,s[48]),w=p(w,V,S,x,B,10,s[49]),x=p(x,w,V,S,C,15,s[50]),S=p(S,x,w,V,m,21,s[51]),V=p(V,S,x,w,v,6,s[52]),w=p(w,V,S,x,f,10,s[53]),x=p(x,w,V,S,b,15,s[54]),S=p(S,x,w,V,l,21,s[55]),V=p(V,S,x,w,_,6,s[56]),w=p(w,V,S,x,N,10,s[57]),x=p(x,w,V,S,I,15,s[58]),S=p(S,x,w,V,T,21,s[59]),V=p(V,S,x,w,g,6,s[60]),w=p(w,V,S,x,y,10,s[61]),x=p(x,w,V,S,d,15,s[62]),S=p(S,x,w,V,E,21,s[63]),a[0]=a[0]+V|0,a[1]=a[1]+S|0,a[2]=a[2]+x|0,a[3]=a[3]+w|0},_doFinalize:function(){var t=this._data,n=t.words,i=8*this._nDataBytes,r=8*t.sigBytes;n[r>>>5]|=128<<24-r%32;var a=e.floor(i/4294967296),o=i;n[15+(r+64>>>9<<4)]=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),n[14+(r+64>>>9<<4)]=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),t.sigBytes=4*(n.length+1),this._process();for(var s=this._hash,l=s.words,u=0;u<4;u++){var c=l[u];l[u]=16711935&(c<<8|c>>>24)|4278255360&(c<<24|c>>>8)}return s},clone:function(){var e=a.clone.call(this);return e._hash=this._hash.clone(),e}});function u(e,t,n,i,r,a,o){var s=e+(t&n|~t&i)+r+o;return(s<<a|s>>>32-a)+t}function c(e,t,n,i,r,a,o){var s=e+(t&i|n&~i)+r+o;return(s<<a|s>>>32-a)+t}function h(e,t,n,i,r,a,o){var s=e+(t^n^i)+r+o;return(s<<a|s>>>32-a)+t}function p(e,t,n,i,r,a,o){var s=e+(n^(t|~i))+r+o;return(s<<a|s>>>32-a)+t}t.MD5=a._createHelper(l),t.HmacMD5=a._createHmacHelper(l)}(Math),function(){var e=i,t=e.lib,n=t.Base,r=t.WordArray,a=e.algo,o=a.MD5,s=a.EvpKDF=n.extend({cfg:n.extend({keySize:4,hasher:o,iterations:1}),init:function(e){this.cfg=this.cfg.extend(e)},compute:function(e,t){for(var n=this.cfg,i=n.hasher.create(),a=r.create(),o=a.words,s=n.keySize,l=n.iterations;o.length<s;){u&&i.update(u);var u=i.update(e).finalize(t);i.reset();for(var c=1;c<l;c++)u=i.finalize(u),i.reset();a.concat(u)}return a.sigBytes=4*s,a}});e.EvpKDF=function(e,t,n){return s.create(n).compute(e,t)}}(),i.lib.Cipher||function(e){var t=i,n=t.lib,r=n.Base,a=n.WordArray,o=n.BufferedBlockAlgorithm,s=t.enc,l=(s.Utf8,s.Base64),u=t.algo.EvpKDF,c=n.Cipher=o.extend({cfg:r.extend(),createEncryptor:function(e,t){return this.create(this._ENC_XFORM_MODE,e,t)},createDecryptor:function(e,t){return this.create(this._DEC_XFORM_MODE,e,t)},init:function(e,t,n){this.cfg=this.cfg.extend(n),this._xformMode=e,this._key=t,this.reset()},reset:function(){o.reset.call(this),this._doReset()},process:function(e){return this._append(e),this._process()},finalize:function(e){return e&&this._append(e),this._doFinalize()},keySize:4,ivSize:4,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function e(e){return"string"==typeof e?_:I}return function(t){return{encrypt:function(n,i,r){return e(i).encrypt(t,n,i,r)},decrypt:function(n,i,r){return e(i).decrypt(t,n,i,r)}}}}()}),h=(n.StreamCipher=c.extend({_doFinalize:function(){return this._process(!0)},blockSize:1}),t.mode={}),p=n.BlockCipherMode=r.extend({createEncryptor:function(e,t){return this.Encryptor.create(e,t)},createDecryptor:function(e,t){return this.Decryptor.create(e,t)},init:function(e,t){this._cipher=e,this._iv=t}}),d=h.CBC=function(){var e=p.extend();function t(e,t,n){var i=this._iv;if(i){var r=i;this._iv=undefined}else r=this._prevBlock;for(var a=0;a<n;a++)e[t+a]^=r[a]}return e.Encryptor=e.extend({processBlock:function(e,n){var i=this._cipher,r=i.blockSize;t.call(this,e,n,r),i.encryptBlock(e,n),this._prevBlock=e.slice(n,n+r)}}),e.Decryptor=e.extend({processBlock:function(e,n){var i=this._cipher,r=i.blockSize,a=e.slice(n,n+r);i.decryptBlock(e,n),t.call(this,e,n,r),this._prevBlock=a}}),e}(),f=(t.pad={}).Pkcs7={pad:function(e,t){for(var n=4*t,i=n-e.sigBytes%n,r=i<<24|i<<16|i<<8|i,o=[],s=0;s<i;s+=4)o.push(r);var l=a.create(o,i);e.concat(l)},unpad:function(e){var t=255&e.words[e.sigBytes-1>>>2];e.sigBytes-=t}},g=(n.BlockCipher=c.extend({cfg:c.cfg.extend({mode:d,padding:f}),reset:function(){c.reset.call(this);var e=this.cfg,t=e.iv,n=e.mode;if(this._xformMode==this._ENC_XFORM_MODE)var i=n.createEncryptor;else{i=n.createDecryptor;this._minBufferSize=1}this._mode=i.call(n,this,t&&t.words)},_doProcessBlock:function(e,t){this._mode.processBlock(e,t)},_doFinalize:function(){var e=this.cfg.padding;if(this._xformMode==this._ENC_XFORM_MODE){e.pad(this._data,this.blockSize);var t=this._process(!0)}else{t=this._process(!0);e.unpad(t)}return t},blockSize:4}),n.CipherParams=r.extend({init:function(e){this.mixIn(e)},toString:function(e){return(e||this.formatter).stringify(this)}})),m=(t.format={}).OpenSSL={stringify:function(e){var t=e.ciphertext,n=e.salt;if(n)var i=a.create([1398893684,1701076831]).concat(n).concat(t);else i=t;return i.toString(l)},parse:function(e){var t=l.parse(e),n=t.words;if(1398893684==n[0]&&1701076831==n[1]){var i=a.create(n.slice(2,4));n.splice(0,4),t.sigBytes-=16}return g.create({ciphertext:t,salt:i})}},I=n.SerializableCipher=r.extend({cfg:r.extend({format:m}),encrypt:function(e,t,n,i){i=this.cfg.extend(i);var r=e.createEncryptor(n,i),a=r.finalize(t),o=r.cfg;return g.create({ciphertext:a,key:n,iv:o.iv,algorithm:e,mode:o.mode,padding:o.padding,blockSize:e.blockSize,formatter:i.format})},decrypt:function(e,t,n,i){return i=this.cfg.extend(i),t=this._parse(t,i.format),e.createDecryptor(n,i).finalize(t.ciphertext)},_parse:function(e,t){return"string"==typeof e?t.parse(e,this):e}}),B=(t.kdf={}).OpenSSL={execute:function(e,t,n,i){i||(i=a.random(8));var r=u.create({keySize:t+n}).compute(e,i),o=a.create(r.words.slice(t),4*n);return r.sigBytes=4*t,g.create({key:r,iv:o,salt:i})}},_=n.PasswordBasedCipher=I.extend({cfg:I.cfg.extend({kdf:B}),encrypt:function(e,t,n,i){var r=(i=this.cfg.extend(i)).kdf.execute(n,e.keySize,e.ivSize);i.iv=r.iv;var a=I.encrypt.call(this,e,t,r.key,i);return a.mixIn(r),a},decrypt:function(e,t,n,i){i=this.cfg.extend(i),t=this._parse(t,i.format);var r=i.kdf.execute(n,e.keySize,e.ivSize,t.salt);return i.iv=r.iv,I.decrypt.call(this,e,t,r.key,i)}})}(),i.mode.ECB=((n=i.lib.BlockCipherMode.extend()).Encryptor=n.extend({processBlock:function(e,t){this._cipher.encryptBlock(e,t)}}),n.Decryptor=n.extend({processBlock:function(e,t){this._cipher.decryptBlock(e,t)}}),n),function(){var e=i,t=e.lib.BlockCipher,n=e.algo,r=[],a=[],o=[],s=[],l=[],u=[],c=[],h=[],p=[],d=[];!function(){for(var e=[],t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;var n=0,i=0;for(t=0;t<256;t++){var f=i^i<<1^i<<2^i<<3^i<<4;f=f>>>8^255&f^99,r[n]=f,a[f]=n;var g=e[n],m=e[g],I=e[m],B=257*e[f]^16843008*f;o[n]=B<<24|B>>>8,s[n]=B<<16|B>>>16,l[n]=B<<8|B>>>24,u[n]=B;B=16843009*I^65537*m^257*g^16843008*n;c[f]=B<<24|B>>>8,h[f]=B<<16|B>>>16,p[f]=B<<8|B>>>24,d[f]=B,n?(n=g^e[e[e[I^g]]],i^=e[e[i]]):n=i=1}}();var f=[0,1,2,4,8,16,32,64,128,27,54],g=n.AES=t.extend({_doReset:function(){for(var e=this._key,t=e.words,n=e.sigBytes/4,i=4*((this._nRounds=n+6)+1),a=this._keySchedule=[],o=0;o<i;o++)if(o<n)a[o]=t[o];else{var s=a[o-1];o%n?n>6&&o%n==4&&(s=r[s>>>24]<<24|r[s>>>16&255]<<16|r[s>>>8&255]<<8|r[255&s]):(s=r[(s=s<<8|s>>>24)>>>24]<<24|r[s>>>16&255]<<16|r[s>>>8&255]<<8|r[255&s],s^=f[o/n|0]<<24),a[o]=a[o-n]^s}for(var l=this._invKeySchedule=[],u=0;u<i;u++){o=i-u;if(u%4)s=a[o];else s=a[o-4];l[u]=u<4||o<=4?s:c[r[s>>>24]]^h[r[s>>>16&255]]^p[r[s>>>8&255]]^d[r[255&s]]}},encryptBlock:function(e,t){this._doCryptBlock(e,t,this._keySchedule,o,s,l,u,r)},decryptBlock:function(e,t){var n=e[t+1];e[t+1]=e[t+3],e[t+3]=n,this._doCryptBlock(e,t,this._invKeySchedule,c,h,p,d,a);n=e[t+1];e[t+1]=e[t+3],e[t+3]=n},_doCryptBlock:function(e,t,n,i,r,a,o,s){for(var l=this._nRounds,u=e[t]^n[0],c=e[t+1]^n[1],h=e[t+2]^n[2],p=e[t+3]^n[3],d=4,f=1;f<l;f++){var g=i[u>>>24]^r[c>>>16&255]^a[h>>>8&255]^o[255&p]^n[d++],m=i[c>>>24]^r[h>>>16&255]^a[p>>>8&255]^o[255&u]^n[d++],I=i[h>>>24]^r[p>>>16&255]^a[u>>>8&255]^o[255&c]^n[d++],B=i[p>>>24]^r[u>>>16&255]^a[c>>>8&255]^o[255&h]^n[d++];u=g,c=m,h=I,p=B}g=(s[u>>>24]<<24|s[c>>>16&255]<<16|s[h>>>8&255]<<8|s[255&p])^n[d++],m=(s[c>>>24]<<24|s[h>>>16&255]<<16|s[p>>>8&255]<<8|s[255&u])^n[d++],I=(s[h>>>24]<<24|s[p>>>16&255]<<16|s[u>>>8&255]<<8|s[255&c])^n[d++],B=(s[p>>>24]<<24|s[u>>>16&255]<<16|s[c>>>8&255]<<8|s[255&h])^n[d++];e[t]=g,e[t+1]=m,e[t+2]=I,e[t+3]=B},keySize:8});e.AES=t._createHelper(g)}(),_.extend(BI,{aesEncrypt:function(e,t){return t=i.enc.Utf8.parse(t),i.AES.encrypt(e,t,{mode:i.mode.ECB,padding:i.pad.Pkcs7}).ciphertext.toString(i.enc.Base64)},aesDecrypt:function(e,t){t=i.enc.Utf8.parse(t);var n=i.AES.decrypt(e,t,{mode:i.mode.ECB,padding:i.pad.Pkcs7});return i.enc.Utf8.stringify(n)}})}()},function(e,t){!function(){function e(e){return function(t,n,i){var r,a=t[n];a&&a.target==t||((r=t[n]=function(){for(var e,t=r.before,n=arguments,i=t.length;i--;){if(!1===(e=t[i].advice.apply(this,n)))return!1;n=e||n}for(var a=r.method.apply(this,n),o=r.after,s=0,l=o.length;s<l;s++){if(e=o[s].advice.call(this,a,n),!1===a)return!1;n=e||n}return a}).before=[],r.after=[],a&&(r.method=a),r.target=t);var o=(r||a)[e],s={advice:i,_index:o.length,remove:function(){o.splice(this._index,1)}};return o.push(s),s}}BI.aspect={before:e("before"),after:e("after")},BI.aspect}()},function(e,t){var n;n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_.extend(BI,{encode:function(e){var t,i,r,a,o,s,l,u="",c=0;for(e=function(e){e=e.replace(/\r\n/g,"\n");for(var t="",n=0;n<e.length;n++){var i=e.charCodeAt(n);i<128?t+=String.fromCharCode(i):i>127&&i<2048?(t+=String.fromCharCode(i>>6|192),t+=String.fromCharCode(63&i|128)):(t+=String.fromCharCode(i>>12|224),t+=String.fromCharCode(i>>6&63|128),t+=String.fromCharCode(63&i|128))}return t}(e);c<e.length;)a=(t=e.charCodeAt(c++))>>2,o=(3&t)<<4|(i=e.charCodeAt(c++))>>4,s=(15&i)<<2|(r=e.charCodeAt(c++))>>6,l=63&r,isNaN(i)?s=l=64:isNaN(r)&&(l=64),u=u+n.charAt(a)+n.charAt(o)+n.charAt(s)+n.charAt(l);return u},decode:function(e){var t,i,r,a,o,s,l="",u=0;for(e=e.replace(/[^A-Za-z0-9\+\/\=]/g,"");u<e.length;)t=n.indexOf(e.charAt(u++))<<2|(a=n.indexOf(e.charAt(u++)))>>4,i=(15&a)<<4|(o=n.indexOf(e.charAt(u++)))>>2,r=(3&o)<<6|(s=n.indexOf(e.charAt(u++))),l+=String.fromCharCode(t),64!=o&&(l+=String.fromCharCode(i)),64!=s&&(l+=String.fromCharCode(r));return l=function(e){for(var t="",n=0,i=0,r=0,a=0;n<e.length;)(i=e.charCodeAt(n))<128?(t+=String.fromCharCode(i),n++):i>191&&i<224?(a=e.charCodeAt(n+1),t+=String.fromCharCode((31&i)<<6|63&a),n+=2):(a=e.charCodeAt(n+1),r=e.charCodeAt(n+2),t+=String.fromCharCode((15&i)<<12|(63&a)<<6|63&r),n+=3);return t}(l)}})},function(e,t){BI.Cache={_prefix:"bi",setUsername:function(e){localStorage.setItem(BI.Cache._prefix+".username",(e+""||"").toUpperCase())},getUsername:function(){return localStorage.getItem(BI.Cache._prefix+".username")||""},_getKeyPrefix:function(){return BI.Cache.getUsername()+"."+BI.Cache._prefix+"."},_generateKey:function(e){return BI.Cache._getKeyPrefix()+(e||"")},getItem:function(e){return localStorage.getItem(BI.Cache._generateKey(e))},setItem:function(e,t){localStorage.setItem(BI.Cache._generateKey(e),t)},removeItem:function(e){localStorage.removeItem(BI.Cache._generateKey(e))},clear:function(){for(var e=localStorage.length;e>=0;e--){var t=localStorage.key(e);t&&0===t.indexOf(BI.Cache._getKeyPrefix())&&localStorage.removeItem(t)}},keys:function(){for(var e=[],t=localStorage.length;t>=0;t--){var n=localStorage.key(t);if(n){var i=BI.Cache._getKeyPrefix();0===n.indexOf(i)&&(e[e.length]=n.substring(i.length))}}return e},addCookie:function(e,t,n,i){var r=e+"="+escape(t);if(i&&i>0){var a=new Date;a.setTime(a.getTime()+3600*i*1e3),r=r+"; expires="+a.toUTCString()}n&&(r=r+"; path="+n),document.cookie=r},getCookie:function(e){var t,n=new RegExp("(^| )"+e+"=([^;]*)(;|$)");return(t=document.cookie.match(n))?unescape(t[2]):null},deleteCookie:function(e,t){var n=new Date;n.setTime(n.getTime()-1e4);var i=e+"=v; expires="+n.toUTCString();t&&(i=i+"; path="+t),document.cookie=i}}},function(e,t){BI.CellSizeAndPositionManager=function(e,t,n){this._cellSizeGetter=t,this._cellCount=e,this._estimatedCellSize=n,this._cellSizeAndPositionData={},this._lastMeasuredIndex=-1},BI.CellSizeAndPositionManager.prototype={constructor:BI.CellSizeAndPositionManager,configure:function(e,t){this._cellCount=e,this._estimatedCellSize=t},getCellCount:function(){return this._cellCount},getEstimatedCellSize:function(){return this._estimatedCellSize},getLastMeasuredIndex:function(){return this._lastMeasuredIndex},getSizeAndPositionOfCell:function(e){if(!(e<0||e>=this._cellCount)){if(e>this._lastMeasuredIndex){for(var t=this.getSizeAndPositionOfLastMeasuredCell(),n=t.offset+t.size,i=this._lastMeasuredIndex+1;i<=e;i++){var r=this._cellSizeGetter(i);null==r||isNaN(r)||(this._cellSizeAndPositionData[i]={offset:n,size:r},n+=r)}this._lastMeasuredIndex=e}return this._cellSizeAndPositionData[e]}},getSizeAndPositionOfLastMeasuredCell:function(){return this._lastMeasuredIndex>=0?this._cellSizeAndPositionData[this._lastMeasuredIndex]:{offset:0,size:0}},getTotalSize:function(){var e=this.getSizeAndPositionOfLastMeasuredCell();return e.offset+e.size+(this._cellCount-this._lastMeasuredIndex-1)*this._estimatedCellSize},getUpdatedOffsetForIndex:function(e,t,n,i){var r,a=this.getSizeAndPositionOfCell(i),o=a.offset,s=o-t+a.size;switch(e){case"start":r=o;break;case"end":r=s;break;case"center":r=o-(t-a.size)/2;break;default:r=Math.max(s,Math.min(o,n))}var l=this.getTotalSize();return Math.max(0,Math.min(l-t,r))},getVisibleCellRange:function(e,t){if(0===this.getTotalSize())return{};var n=t+e,i=this._findNearestCell(t),r=this.getSizeAndPositionOfCell(i);t=r.offset+r.size;for(var a=i;t<n&&a<this._cellCount-1;)a++,t+=this.getSizeAndPositionOfCell(a).size;return{start:i,stop:a}},resetCell:function(e){this._lastMeasuredIndex=Math.min(this._lastMeasuredIndex,e-1)},_binarySearch:function(e,t,n){for(var i,r;t<=e;){if(i=t+Math.floor((e-t)/2),(r=this.getSizeAndPositionOfCell(i).offset)===n)return i;r<n?t=i+1:r>n&&(e=i-1)}if(t>0)return t-1},_exponentialSearch:function(e,t){for(var n=1;e<this._cellCount&&this.getSizeAndPositionOfCell(e).offset<t;)e+=n,n*=2;return this._binarySearch(Math.min(e,this._cellCount-1),Math.floor(e/2),t)},_findNearestCell:function(e){if(!isNaN(e)){e=Math.max(0,e);var t=this.getSizeAndPositionOfLastMeasuredCell(),n=Math.max(0,this._lastMeasuredIndex);return t.offset>=e?this._binarySearch(n,0,e):this._exponentialSearch(n,e)}}},BI.ScalingCellSizeAndPositionManager=function(e,t,n,i){this._cellSizeAndPositionManager=new BI.CellSizeAndPositionManager(e,t,n),this._maxScrollSize=i||1e7},BI.ScalingCellSizeAndPositionManager.prototype={constructor:BI.ScalingCellSizeAndPositionManager,configure:function(){this._cellSizeAndPositionManager.configure.apply(this._cellSizeAndPositionManager,arguments)},getCellCount:function(){return this._cellSizeAndPositionManager.getCellCount()},getEstimatedCellSize:function(){return this._cellSizeAndPositionManager.getEstimatedCellSize()},getLastMeasuredIndex:function(){return this._cellSizeAndPositionManager.getLastMeasuredIndex()},getOffsetAdjustment:function(e,t){var n=this._cellSizeAndPositionManager.getTotalSize(),i=this.getTotalSize(),r=this._getOffsetPercentage(e,t,i);return Math.round(r*(i-n))},getSizeAndPositionOfCell:function(e){return this._cellSizeAndPositionManager.getSizeAndPositionOfCell(e)},getSizeAndPositionOfLastMeasuredCell:function(){return this._cellSizeAndPositionManager.getSizeAndPositionOfLastMeasuredCell()},getTotalSize:function(){return Math.min(this._maxScrollSize,this._cellSizeAndPositionManager.getTotalSize())},getUpdatedOffsetForIndex:function(e,t,n,i){n=this._safeOffsetToOffset(t,n);var r=this._cellSizeAndPositionManager.getUpdatedOffsetForIndex(e,t,n,i);return this._offsetToSafeOffset(t,r)},getVisibleCellRange:function(e,t){return t=this._safeOffsetToOffset(e,t),this._cellSizeAndPositionManager.getVisibleCellRange(e,t)},resetCell:function(e){this._cellSizeAndPositionManager.resetCell(e)},_getOffsetPercentage:function(e,t,n){return n<=e?0:t/(n-e)},_offsetToSafeOffset:function(e,t){var n=this._cellSizeAndPositionManager.getTotalSize(),i=this.getTotalSize();if(n===i)return t;var r=this._getOffsetPercentage(e,t,n);return Math.round(r*(i-e))},_safeOffsetToOffset:function(e,t){var n=this._cellSizeAndPositionManager.getTotalSize(),i=this.getTotalSize();if(n===i)return t;var r=this._getOffsetPercentage(e,t,i);return Math.round(r*(n-e))}}},function(e,t){!function(){function e(e,t){return e<t}BI.Heap=function(t,n){this._items=t||[],this._size=this._items.length,this._comparator=n||e,this._heapify()},BI.Heap.prototype={constructor:BI.Heap,empty:function(){return 0===this._size},pop:function(){if(0!==this._size){var e=this._items[0],t=this._items.pop();return this._size--,this._size>0&&(this._items[0]=t,this._sinkDown(0)),e}},push:function(e){this._items[this._size++]=e,this._bubbleUp(this._size-1)},size:function(){return this._size},peek:function(){if(0!==this._size)return this._items[0]},_heapify:function(){for(var e=Math.floor((this._size+1)/2);e>=0;e--)this._sinkDown(e)},_bubbleUp:function(e){for(var t=this._items[e];e>0;){var n=Math.floor((e+1)/2)-1,i=this._items[n];if(this._comparator(i,t))return;this._items[n]=t,this._items[e]=i,e=n}},_sinkDown:function(e){for(var t=this._items[e];;){var n=2*(e+1)-1,i=2*(e+1),r=-1;if(n<this._size){var a=this._items[n];this._comparator(a,t)&&(r=n)}if(i<this._size){var o=this._items[i];this._comparator(o,t)&&(-1===r||this._comparator(o,this._items[r]))&&(r=i)}if(-1===r)return;this._items[e]=this._items[r],this._items[r]=t,e=r}}}}()},function(e,t){BI.LinkHashMap=function(){this.array=[],this.map={}},BI.LinkHashMap.prototype={constructor:BI.LinkHashMap,has:function(e){return e in this.map},add:function(e,t){void 0!==e&&(e in this.map||this.array.push(e),this.map[e]=t)},remove:function(e){if(e in this.map){delete this.map[e];for(var t=0;t<this.array.length;t++)if(this.array[t]==e){this.array.splice(t,1);break}}},size:function(){return this.array.length},each:function(e,t){if(t=t||window,null!=(e=e||null)&&"function"==typeof e)for(var n=0;n<this.array.length;n++){var i=this.array[n],r=this.map[i];if(0==e.call(t,i,r,n,this.array,this.map))break}},get:function(e){return this.map[e]},toArray:function(){var e=[];return this.each((function(t,n){e.push(n)})),e}}},function(e,t){!function(){BI.LRU=function(e){this.size=0,this.limit=e,this.head=this.tail=undefined,this._keymap={}};var e=BI.LRU.prototype;e.put=function(e,t){var n;this.size===this.limit&&(n=this.shift());var i=this.get(e,!0);return i||(i={key:e},this._keymap[e]=i,this.tail?(this.tail.newer=i,i.older=this.tail):this.head=i,this.tail=i,this.size++),i.value=t,n},e.shift=function(){var e=this.head;return e&&(this.head=this.head.newer,this.head.older=undefined,e.newer=e.older=undefined,this._keymap[e.key]=undefined,this.size--),e},e.get=function(e,t){var n=this._keymap[e];if(n!==undefined)return n===this.tail||(n.newer&&(n===this.head&&(this.head=n.newer),n.newer.older=n.older),n.older&&(n.older.newer=n.newer),n.newer=undefined,n.older=this.tail,this.tail&&(this.tail.newer=n),this.tail=n),t?n:n.value},e.has=function(e){return null!=this._keymap[e]}}()},function(e,t){var n,i;n=function(e){return Math.floor(e/2)},i=_global.Int32Array||function(e){for(var t=[],n=e-1;n>=0;--n)t[n]=0;return t},BI.PrefixIntervalTree=function(e){var t;for(this._size=e.length,this._half=function(e){for(var t=1;t<e;)t*=2;return t}(this._size),this._heap=new i(2*this._half),t=0;t<this._size;++t)this._heap[this._half+t]=e[t];for(t=this._half-1;t>0;--t)this._heap[t]=this._heap[2*t]+this._heap[2*t+1]},BI.PrefixIntervalTree.prototype={constructor:BI.PrefixIntervalTree,set:function(e,t){var i=this._half+e;for(this._heap[i]=t,i=n(i);0!==i;i=n(i))this._heap[i]=this._heap[2*i]+this._heap[2*i+1]},get:function(e){var t=this._half+e;return this._heap[t]},getSize:function(){return this._size},sumUntil:function(e){if(0===e)return 0;for(var t=this._half+e-1,i=this._heap[t];1!==t;t=n(t))t%2==1&&(i+=this._heap[t-1]);return i},sumTo:function(e){return this.sumUntil(e+1)},sum:function(e,t){return this.sumUntil(t)-this.sumUntil(e)},greatestLowerBound:function(e){if(e<0)return-1;var t=1;if(this._heap[t]<=e)return this._size;for(;t<this._half;){var n=this._heap[2*t];e<n?t*=2:(t=2*t+1,e-=n)}return t-this._half},greatestStrictLowerBound:function(e){if(e<=0)return-1;var t=1;if(this._heap[t]<e)return this._size;for(;t<this._half;){var n=this._heap[2*t];e<=n?t*=2:(t=2*t+1,e-=n)}return t-this._half},leastUpperBound:function(e){return this.greatestStrictLowerBound(e)+1},leastStrictUpperBound:function(e){return this.greatestLowerBound(e)+1}},BI.PrefixIntervalTree.uniform=function(e,t){for(var n=[],i=e-1;i>=0;--i)n[i]=t;return new BI.PrefixIntervalTree(n)},BI.PrefixIntervalTree.empty=function(e){return BI.PrefixIntervalTree.uniform(e,0)}},function(e,t){BI.Queue=function(e){this.capacity=e,this.array=[]},BI.Queue.prototype={constructor:BI.Queue,contains:function(e){return BI.contains(this.array,e)},indexOf:function(e){return BI.contains(this.array,e)},getElementByIndex:function(e){return this.array[e]},push:function(e){this.array.push(e),this.capacity&&this.array.length>this.capacity&&this.array.shift()},pop:function(){this.array.pop()},shift:function(){this.array.shift()},unshift:function(e){this.array.unshift(e),this.capacity&&this.array.length>this.capacity&&this.array.pop()},remove:function(e){BI.remove(this.array,e)},splice:function(){this.array.splice.apply(this.array,arguments)},slice:function(){this.array.slice.apply(this.array,arguments)},size:function(){return this.array.length},each:function(e,t){if(t=t||window,null!=(e=e||null)&&"function"==typeof e)for(var n=0;n<this.array.length&&0!=e.call(t,n,this.array[n],this.array);n++);},toArray:function(){return this.array},fromArray:function(e){var t=this;BI.each(e,(function(e,n){t.push(n)}))},clear:function(){this.array.length=0}}},function(e,t){!function(){var e=function(e,t,n,i){this.height=e,this.width=t,this.x=n,this.y=i,this._indexMap={},this._indices=[]};e.prototype={constructor:e,addCellIndex:function(e){this._indexMap[e]||(this._indexMap[e]=!0,this._indices.push(e))},getCellIndices:function(){return this._indices}};BI.SectionManager=function(e){this._sectionSize=e||100,this._cellMetadata=[],this._sections={}},BI.SectionManager.prototype={constructor:BI.SectionManager,getCellIndices:function(e,t,n,i){var r={};return BI.each(this.getSections(e,t,n,i),(function(e,t){BI.each(t.getCellIndices(),(function(e,t){r[t]=t}))})),BI.map(BI.keys(r),(function(e,t){return r[t]}))},getCellMetadata:function(e){return this._cellMetadata[e]},getSections:function(t,n,i,r){for(var a=Math.floor(i/this._sectionSize),o=Math.floor((i+n-1)/this._sectionSize),s=Math.floor(r/this._sectionSize),l=Math.floor((r+t-1)/this._sectionSize),u=[],c=a;c<=o;c++)for(var h=s;h<=l;h++){var p=c+"."+h;this._sections[p]||(this._sections[p]=new e(this._sectionSize,this._sectionSize,c*this._sectionSize,h*this._sectionSize)),u.push(this._sections[p])}return u},getTotalSectionCount:function(){return BI.size(this._sections)},registerCell:function(e,t){this._cellMetadata[t]=e,BI.each(this.getSections(e.height,e.width,e.x,e.y),(function(e,n){n.addCellIndex(t)}))}}}()},function(e,t){BI.Tree=function(){this.root=new BI.Node(BI.UUID())},BI.Tree.prototype={constructor:BI.Tree,addNode:function(e,t,n){BI.isNull(t)?this.root.addChild(e,n):BI.isNull(e)?this.root.addChild(t,n):e.addChild(t,n)},isRoot:function(e){return e===this.root},getRoot:function(){return this.root},clear:function(){this.root.clear()},initTree:function(e){var t=this;this.clear();var n=[];for(BI.each(e,(function(e,i){var r=new BI.Node(i);r.set("data",i),t.addNode(r),n.push(r)}));!BI.isEmpty(n);){var i=n.shift(),r=i.get("data");BI.each(r.children,(function(e,r){var a=new BI.Node(r);a.set("data",r),n.push(a),t.addNode(i,a)}))}},_toJSON:function(e){var t=this,n=[];return BI.each(e.getChildren(),(function(e,i){n.push(t._toJSON(i))})),BI.extend({id:e.id},BI.deepClone(e.get("data")),n.length>0?{children:n}:{})},toJSON:function(e){var t=this,n=[];return BI.each((e||this.root).getChildren(),(function(e,i){n.push(t._toJSON(i))})),n},_toJSONWithNode:function(e){var t=this,n=[];return BI.each(e.getChildren(),(function(e,i){n.push(t._toJSONWithNode(i))})),BI.extend({id:e.id},BI.deepClone(e.get("data")),{node:e},n.length>0?{children:n}:{})},toJSONWithNode:function(e){var t=this,n=[];return BI.each((e||this.root).getChildren(),(function(e,i){n.push(t._toJSONWithNode(i))})),n},search:function(e,t,n){if(!(e instanceof BI.Node))return arguments.callee.apply(this,[this.root,e,t]);var i=this,r=null;return BI.isNull(t)?null:BI.isEqual(e[n||"id"],t)?e:(BI.any(e.getChildren(),(function(e,a){if(null!==(r=i.search(a,t,n)))return!0})),r)},_traverse:function(e,t){var n=[];for(n.push(e);!BI.isEmpty(n);){var i=n.shift(),r=t&&t(i);if(!1===r)break;!0!==r&&null!=i&&(n=n.concat(i.getChildren()))}},traverse:function(e){this._traverse(this.root,e)},_recursion:function(e,t,n){var i=this;return BI.every(e.getChildren(),(function(e,r){var a=BI.clone(t);a.push(r.id);var o=n&&n(r,a);return!1!==o&&(!0===o||i._recursion(r,a,n))}))},recursion:function(e){this._recursion(this.root,[],e)},inOrderTraverse:function(e){this._inOrderTraverse(this.root,e)},_inOrderTraverse:function(e,t){null!=e&&(this._inOrderTraverse(e.getLeft()),t&&t(e),this._inOrderTraverse(e.getRight()))},nrInOrderTraverse:function(e){for(var t=[],n=this.root;null!=n||!BI.isEmpty(t);){for(;null!=n;)t.push(n),n=n.getLeft();n=t.pop(),e&&e(n),n=n.getRight()}},preOrderTraverse:function(e){this._preOrderTraverse(this.root,e)},_preOrderTraverse:function(e,t){null!=e&&(t&&t(e),this._preOrderTraverse(e.getLeft()),this._preOrderTraverse(e.getRight()))},nrPreOrderTraverse:function(e){for(var t=[],n=this.root;null!=n||!BI.isEmpty(t);){for(;null!=n;)e&&e(n),t.push(n),n=n.getLeft();n=(n=t.pop()).getRight()}},postOrderTraverse:function(e){this._postOrderTraverse(this.root,e)},_postOrderTraverse:function(e,t){null!=e&&(this._postOrderTraverse(e.getLeft()),this._postOrderTraverse(e.getRight()),t&&t(e))},nrPostOrderTraverse:function(e){for(var t=[],n=this.root,i=null;null!=n||!BI.isEmpty(t);){for(;null!=n;)t.push(n),n=n.getLeft();null==(n=BI.last(t)).getRight()||n.getRight()==i?(e&&e(n),i=n=t.pop(),n=null):n=n.getRight()}}},BI.Node=function(e){BI.isObject(e)?BI.extend(this,e):this.id=e,this.clear.apply(this,arguments)},BI.Node.prototype={constructor:BI.Node,set:function(e,t){BI.isObject(e)?BI.extend(this,e):this[e]=t},get:function(e){return this[e]},isLeaf:function(){return BI.isEmpty(this.children)},getChildren:function(){return this.children},getChildrenLength:function(){return this.children.length},getFirstChild:function(){return BI.first(this.children)},getLastChild:function(){return BI.last(this.children)},setLeft:function(e){this.left=e},getLeft:function(){return this.left},setRight:function(e){this.right=e},getRight:function(){return this.right},setParent:function(e){this.parent=e},getParent:function(){return this.parent},getChild:function(e){return this.children[e]},getChildIndex:function(e){return BI.findIndex(this.children,(function(t,n){return n.get("id")===e}))},removeChild:function(e){this.removeChildByIndex(this.getChildIndex(e))},removeChildByIndex:function(e){var t=this.getChild(e-1),n=this.getChild(e+1);null!=t&&t.setRight(n||null),null!=n&&n.setLeft(t||null),this.children.splice(e,1)},removeAllChilds:function(){this.children=[]},addChild:function(e,t){var n=null;n=BI.isUndefined(t)?this.children.length-1:t-1,e.setParent(this),n>=0&&(this.getChild(n)&&this.getChild(n).setRight(e),e.setLeft(this.getChild(n))),BI.isUndefined(t)?this.children.push(e):this.children.splice(t,0,e)},equals:function(e){return this===e||this.id===e.id},clear:function(){this.parent=null,this.left=null,this.right=null,this.children=[]}},BI.extend(BI.Tree,{transformToArrayFormat:function(e,t){if(!e)return[];var n=[];if(BI.isArray(e))for(var i=0,r=e.length;i<r;i++){var a=BI.clone(e[i]);a.pId=null==a.pId?t:a.pId,delete a.children,n.push(a),e[i].children&&(n=n.concat(BI.Tree.transformToArrayFormat(e[i].children,a.id)))}else{var o=BI.clone(e);o.pId=null==o.pId?t:o.pId,delete o.children,n.push(o),e.children&&(n=n.concat(BI.Tree.transformToArrayFormat(e.children,o.id)))}return n},arrayFormat:function(e,t){if(!e)return[];var n=[];if(BI.isArray(e))for(var i=0,r=e.length;i<r;i++){var a=e[i];a.pId=null==a.pId?t:a.pId,n.push(a),e[i].children&&(n=n.concat(BI.Tree.arrayFormat(e[i].children,a.id)))}else{var o=e;o.pId=null==o.pId?t:o.pId,n.push(o),e.children&&(n=n.concat(BI.Tree.arrayFormat(e.children,o.id)))}return n},transformToTreeFormat:function(e){var t,n;if(!e)return[];if(BI.isArray(e)){var i=[],r={};for(t=0,n=e.length;t<n;t++){if(BI.isNull(e[t].id))return e;r[e[t].id]=BI.clone(e[t])}for(t=0,n=e.length;t<n;t++)r[e[t].pId]&&e[t].id!==e[t].pId?(r[e[t].pId].children||(r[e[t].pId].children=[]),r[e[t].pId].children.push(r[e[t].id])):i.push(r[e[t].id]),delete r[e[t].id].pId;return i}return[e]},treeFormat:function(e){var t,n;if(!e)return[];if(BI.isArray(e)){var i=[],r={};for(t=0,n=e.length;t<n;t++){if(BI.isNull(e[t].id))return e;r[e[t].id]=e[t]}for(t=0,n=e.length;t<n;t++)r[e[t].pId]&&e[t].id!==e[t].pId?(r[e[t].pId].children||(r[e[t].pId].children=[]),r[e[t].pId].children.push(r[e[t].id])):i.push(r[e[t].id]);return i}return[e]},traversal:function(e,t,n){if(!BI.isNull(e)){var i=this;BI.some(e,(function(e,r){if(!1===t(e,r,n))return!0;i.traversal(r.children,t,r)}))}}})},function(e,t){BI.Vector=function(e,t){this.x=e,this.y=t},BI.Vector.prototype={constructor:BI.Vector,cross:function(e){return this.x*e.y-this.y*e.x},length:function(e){return Math.sqrt(this.x*e.x+this.y*e.y)}},BI.Region=function(e,t,n,i){this.x=e,this.y=t,this.w=n,this.h=i},BI.Region.prototype={constructor:BI.Region,isIntersects:function(e){if(this.isPointInside(e.x,e.y)||this.isPointInside(e.x+e.w,e.y)||this.isPointInside(e.x,e.y+e.h)||this.isPointInside(e.x+e.w,e.y+e.h))return!0;if(e.isPointInside(this.x,this.y)||e.isPointInside(this.x+this.w,this.y)||e.isPointInside(this.x,this.y+this.h)||e.isPointInside(this.x+this.w,this.y+this.h))return!0;if(null!=e.x&&null!=e.y){var t=new BI.Vector(this.w,this.h),n=new BI.Vector(e.x-this.x,e.y-this.y),i=new BI.Vector(n.x+e.w,n.y+e.h);if(t.cross(n)*t.cross(i)<0)return!0}return!1},isPointInside:function(e,t){return null!=this.x&&null!=this.y&&(e>=this.x&&e<=this.x+this.w&&t>=this.y&&t<=this.y+this.h)},getPosition:function(){var e=[];return e.push(this.x+this.w/2),e.push(this.y+this.h/2),e}}},function(e,t){var n;n={size:{TOOL_BAR_HEIGHT:24,LIST_ITEM_HEIGHT:24,TRIGGER_HEIGHT:24}},BI.provider("bi.provider.system",(function(){this.SYSTEM=n,this.setSize=function(e){BI.deepExtend(n,{size:e})},this.$get=function(){return BI.inherit(BI.OB,{getSize:function(){return n.size}})}})),BI.prepares.push((function(){BI.SIZE_CONSANTS=BI.Providers.getProvider("bi.provider.system").getSize()}))},function(e,t){BI.EventListener={listen:function(e,t,n){return e.addEventListener?(e.addEventListener(t,n,!1),{remove:function(){e.removeEventListener(t,n,!1)}}):e.attachEvent?(e.attachEvent("on"+t,n),{remove:function(){e.detachEvent("on"+t,n)}}):void 0},capture:function(e,t,n){return e.addEventListener?(e.addEventListener(t,n,!0),{remove:function(){e.removeEventListener(t,n,!0)}}):{remove:BI.emptyFn}},registerDefault:function(){}}},function(e,t){var n,i;n=_global.cancelAnimationFrame||_global.webkitCancelAnimationFrame||_global.mozCancelAnimationFrame||_global.oCancelAnimationFrame||_global.msCancelAnimationFrame||_global.clearTimeout,i=_global.requestAnimationFrame||_global.webkitRequestAnimationFrame||_global.mozRequestAnimationFrame||_global.oRequestAnimationFrame||_global.msRequestAnimationFrame||_global.setTimeout,BI.MouseMoveTracker=function(e,t,n){this._isDragging=!1,this._animationFrameID=null,this._domNode=n,this._onMove=e,this._onMoveEnd=t,this._onMouseMove=BI.bind(this._onMouseMove,this),this._onMouseUp=BI.bind(this._onMouseUp,this),this._didMouseMove=BI.bind(this._didMouseMove,this)},BI.MouseMoveTracker.prototype={constructor:BI.MouseMoveTracker,captureMouseMoves:function(e){this._eventMoveToken||this._eventUpToken||(this._eventMoveToken=BI.EventListener.listen(this._domNode,"mousemove",this._onMouseMove),this._eventUpToken=BI.EventListener.listen(this._domNode,"mouseup",this._onMouseUp)),this._isDragging||(this._deltaX=0,this._deltaY=0,this._isDragging=!0,this._x=e.clientX,this._y=e.clientY),e.preventDefault?e.preventDefault():e.returnValue=!1},releaseMouseMoves:function(){this._eventMoveToken&&this._eventUpToken&&(this._eventMoveToken.remove(),this._eventMoveToken=null,this._eventUpToken.remove(),this._eventUpToken=null),null!==this._animationFrameID&&(n(this._animationFrameID),this._animationFrameID=null),this._isDragging&&(this._isDragging=!1,this._x=null,this._y=null)},isDragging:function(){return this._isDragging},_onMouseMove:function(e){var t=e.clientX,n=e.clientY;this._deltaX+=t-this._x,this._deltaY+=n-this._y,null===this._animationFrameID&&(this._animationFrameID=i(this._didMouseMove)),this._x=t,this._y=n,e.preventDefault?e.preventDefault():e.returnValue=!1},_didMouseMove:function(){this._animationFrameID=null,this._onMove(this._deltaX,this._deltaY),this._deltaX=0,this._deltaY=0},_onMouseUp:function(){this._animationFrameID&&this._didMouseMove(),this._onMoveEnd()}}},function(e,t){var n;n=_global.requestAnimationFrame||_global.webkitRequestAnimationFrame||_global.mozRequestAnimationFrame||_global.oRequestAnimationFrame||_global.msRequestAnimationFrame||_global.setTimeout,BI.WheelHandler=function(e,t,n,i){this._animationFrameID=null,this._deltaX=0,this._deltaY=0,this._didWheel=BI.bind(this._didWheel,this),"function"!=typeof t&&(t=t?function(){return!0}:function(){return!1}),"function"!=typeof n&&(n=n?function(){return!0}:function(){return!1}),"function"!=typeof i&&(i=i?function(){return!0}:function(){return!1}),this._handleScrollX=t,this._handleScrollY=n,this._stopPropagation=i,this._onWheelCallback=e,this.onWheel=BI.bind(this.onWheel,this)},BI.WheelHandler.prototype={constructor:BI.WheelHandler,onWheel:function(e){var t,i=function(e){var t=0,n=0,i=0,r=0;return"detail"in e&&(n=e.detail),"wheelDelta"in e&&(n=-e.wheelDelta/120),"wheelDeltaY"in e&&(n=-e.wheelDeltaY/120),"wheelDeltaX"in e&&(t=-e.wheelDeltaX/120),"axis"in e&&e.axis===e.HORIZONTAL_AXIS&&(t=n,n=0),i=10*t,r=10*n,"deltaY"in e&&(r=e.deltaY),"deltaX"in e&&(i=e.deltaX),(i||r)&&e.deltaMode&&(1===e.deltaMode?(i*=40,r*=40):(i*=800,r*=800)),i&&!t&&(t=i<1?-1:1),r&&!n&&(n=r<1?-1:1),{spinX:t,spinY:n,pixelX:i,pixelY:r}}(e),r=this._deltaX+i.pixelX,a=this._deltaY+i.pixelY,o=this._handleScrollX(r,a),s=this._handleScrollY(a,r);(o||s)&&(this._deltaX+=o?i.pixelX:0,this._deltaY+=s?i.pixelY:0,e.preventDefault?e.preventDefault():e.returnValue=!1,0===this._deltaX&&0===this._deltaY||(this._stopPropagation()&&(e.stopPropagation?e.stopPropagation():e.cancelBubble=!0),t=!0),!0===t&&null===this._animationFrameID&&(this._animationFrameID=n(this._didWheel)))},_didWheel:function(){this._animationFrameID=null,this._onWheelCallback(this._deltaX,this._deltaY),this._deltaX=0,this._deltaY=0}}},function(e,t){BI.version="2.0"},function(e,t){BI.initWorker=function(){var e={},t={};addEventListener("message",(function(n){var i=n.data;switch(i.eventType){case"action":e[i.name][i.action].apply(e[i.name],i.args);break;case"destroy":BI.each(t[i.name],(function(e,t){t=BI.isArray(t)?t:[t],BI.each(t,(function(e,t){t()}))})),delete e[i.name],delete t[i.name];break;case"create":var r=e[i.name]=BI.Models.getModel(i.type,i.options);t[i.name]=[],BI.each(i.watches,(function(e,n){var a,o,s,l;t[i.name].push((a=r.model,o=n,s=function(e,t){postMessage(BI.extend({},i,{eventType:"watch",currentWatchType:n},{args:[e,t]}))},l=l||{},Fix.watch(a,o,s,BI.extend(l,{store:a}))))})),postMessage(BI.extend({},i,{eventType:"create"},{msg:r.model}))}}),!1)}},function(e,t){BI.Layout=BI.inherit(BI.Widget,{props:function(){return{scrollable:null,scrollx:!1,scrolly:!1,items:[]}},render:function(){this._init4Margin(),this._init4Scroll()},_init4Margin:function(){this.options.top&&this.element.css("top",BI.isNumber(this.options.top)?this.options.top/BI.pixRatio+BI.pixUnit:this.options.top),this.options.left&&this.element.css("left",BI.isNumber(this.options.left)?this.options.left/BI.pixRatio+BI.pixUnit:this.options.left),this.options.bottom&&this.element.css("bottom",BI.isNumber(this.options.bottom)?this.options.bottom/BI.pixRatio+BI.pixUnit:this.options.bottom),this.options.right&&this.element.css("right",BI.isNumber(this.options.right)?this.options.right/BI.pixRatio+BI.pixUnit:this.options.right)},_init4Scroll:function(){switch(this.options.scrollable){case!0:this.element.css("overflow","auto");break;case!1:this.element.css("overflow","hidden")}this.options.scrollx&&this.element.css({"overflow-x":"auto","overflow-y":"hidden"}),this.options.scrolly&&this.element.css({"overflow-x":"hidden","overflow-y":"auto"})},appendFragment:function(e){this.element.append(e)},_mountChildren:function(){var e=BI.Widget._renderEngine.createFragment(),t=!1;for(var n in this._children){var i=this._children[n];i.element!==this.element&&(e.appendChild(i.element[0]),t=!0)}!0===t&&this.appendFragment(e)},_getChildName:function(e){return""+e},_addElement:function(e,t,n){var i,r=this;return this.hasWidget(this._getChildName(e))?i=this.getWidgetByName(this._getChildName(e)):((i=BI._lazyCreateWidget(t,n)).on(BI.Events.DESTROY,(function(){BI.each(r._children,(function(e,t){t===i&&(BI.remove(r._children,t),r.removeItemAt(0|e))}))})),this.addWidget(this._getChildName(e),i)),i},_getOptions:function(e){return e instanceof BI.Widget&&(e=e.options),(e=BI.stripEL(e))instanceof BI.Widget&&(e=e.options),e},_compare:function(e,t){var n=this;return function i(e,t,r,a){if(e===t)return 0!==e||1/e==1/t;if(null==e||null==t)return e===t;var o=Object.prototype.toString.call(e);switch(o){case"[object RegExp]":case"[object String]":return""+e==""+t;case"[object Number]":return+e!=+e?+t!=+t:0==+e?1/+e==1/t:+e==+t;case"[object Date]":case"[object Boolean]":return+e==+t}var s="[object Array]"===o;if(!s){if(BI.isFunction(e)&&BI.isFunction(t))return!0;e=n._getOptions(e),t=n._getOptions(t)}a=a||[];var l=(r=r||[]).length;for(;l--;)if(r[l]===e)return a[l]===t;if(r.push(e),a.push(t),s){if((l=e.length)!==t.length)return!1;for(;l--;)if(!i(e[l],t[l],r,a))return!1}else{var u,c=_.keys(e);if(l=c.length,_.keys(t).length!==l)return!1;for(;l--;)if(u=c[l],!_.has(t,u)||!i(e[u],t[u],r,a))return!1}return r.pop(),a.pop(),!0}(e,t)},_getWrapper:function(){return this.element},_addItemAt:function(e,t){for(var n=this.options.items.length;n>e;n--)this._children[this._getChildName(n)]=this._children[this._getChildName(n-1)];delete this._children[this._getChildName(e)],this.options.items.splice(e,0,t)},_removeItemAt:function(e){for(var t=e;t<this.options.items.length-1;t++)this._children[this._getChildName(t)]=this._children[this._getChildName(t+1)];delete this._children[this._getChildName(this.options.items.length-1)],this.options.items.splice(e,1)},addItem:function(e){return this.addItemAt(this.options.items.length,e)},prependItem:function(e){return this.addItemAt(0,e)},addItemAt:function(e,t){if(!(e<0||e>this.options.items.length)){this._addItemAt(e,t);var n=this._addElement(e,t);return e>0?this._children[this._getChildName(e-1)].element.after(n.element):n.element.prependTo(this._getWrapper()),n._mount(),n}},removeItemAt:function(e){e=BI.isArray(e)?e:[e];for(var t=[],n=[],i={},r=0,a=this.options.items.length;r<a;r++){var o=this._children[this._getChildName(r)];BI.contains(e,r)?o&&t.push(o):(i[this._getChildName(n.length)]=o,n.push(this.options.items[r]))}this.options.items=n,this._children=i,BI.each(t,(function(e,t){t._destroy()}))},shouldUpdateItem:function(e,t){if(e<0||e>this.options.items.length-1)return!1;var n=this._children[this._getChildName(e)];return n.shouldUpdate?n.shouldUpdate(this._getOptions(t)):null},updateItemAt:function(e,t){if(!(e<0||e>this.options.items.length-1)){var n=this._children[this._getChildName(e)];delete this._children[this._getChildName(e)],this.options.items.splice(e,1);var i=this._addElement(e,t);this.options.items.splice(e,0,t),this._children[this._getChildName(e)]=i,e>0?this._children[this._getChildName(e-1)].element.after(i.element):i.element.prependTo(this._getWrapper()),n._destroy(),i._mount()}},addItems:function(e,t){var n=this,i=this.options,r=BI.Widget._renderEngine.createFragment(),a=[];BI.each(e,(function(e,o){var s=n._addElement(i.items.length,o,t);n._children[n._getChildName(i.items.length)]=s,i.items.push(o),a.push(s),r.appendChild(s.element[0])})),this._isMounted&&(this._getWrapper().append(r),BI.each(a,(function(e,t){t._mount()})))},prependItems:function(e,t){e=e||[];for(var n=BI.Widget._renderEngine.createFragment(),i=[],r=e.length-1;r>=0;r--){this._addItemAt(0,e[r]);var a=this._addElement(0,e[r],t);this._children[this._getChildName(0)]=a,this.options.items.unshift(e[r]),i.push(a),n.appendChild(a.element[0])}this._isMounted&&(this._getWrapper().prepend(n),BI.each(i,(function(e,t){t._mount()})))},getValue:function(){var e,t=this,n=[];return BI.each(this.options.items,(function(i){if(e=t._children[t._getChildName(i)]){var r=e.getValue();r=BI.isArray(r)?r:[r],n=n.concat(r)}})),n},setValue:function(e){var t,n=this;BI.each(this.options.items,(function(i){(t=n._children[n._getChildName(i)])&&t.setValue(e)}))},setText:function(e){var t,n=this;BI.each(this.options.items,(function(i){(t=n._children[n._getChildName(i)])&&t.setText(e)}))},patchItem:function(e,t,n){var i=this.shouldUpdateItem(n,t),r=this._children[this._getChildName(n)];return i?r._update(this._getOptions(t),i):null!==i||this._compare(e,t)?void 0:this.updateItemAt(n,t)},updateChildren:function(e,t){var n,i=this,r=0,a=0,o=e.length-1,s=e[0],l=e[o],u=t.length-1,c=t[0],h=t[u],p={};for(BI.each(e,(function(e,t){var n=null==(t=i._getOptions(t)).key?e:t.key;BI.isKey(n)&&(p[n]=i._children[i._getChildName(e)])}));r<=o&&a<=u;)if(BI.isNull(s))s=e[++r];else if(BI.isNull(l))l=e[--o];else if(f(s,c,r,a))n=this.patchItem(s,c,r)||n,p[null==s.key?r:s.key]=this._children[this._getChildName(r)],s=e[++r],c=t[++a];else if(f(l,h,o,u))n=this.patchItem(l,h,o)||n,p[null==l.key?o:l.key]=this._children[this._getChildName(o)],l=e[--o],h=t[--u];else if(f(s,h))n=this.patchItem(s,h,r)||n,p[null==s.key?r:s.key]=this._children[this._getChildName(r)],m(s,l,!0),s=e[++r],h=t[--u];else if(f(l,c))n=this.patchItem(l,c,o)||n,p[null==l.key?o:l.key]=this._children[this._getChildName(o)],m(l,s),l=e[--o],c=t[++a];else{var d=I(e,c,r,o);if(BI.isNull(d))m(g(c),s),c=t[++a];else BI.each(e,(function(t,r){r&&f(r,c)&&(n=i.patchItem(d,c,t)||n,p[null==d.key?t:d.key]=i._children[i._getChildName(t)],e[t]=undefined,m(d,s))})),c=t[++a]}function f(e,t,n,r){return e=i._getOptions(e),t=i._getOptions(t),BI.isKey(e.key)?e.key===t.key:n>=0?n===r:void 0}function g(e,t){var n=i._getOptions(e),r=null==n.key?t:n.key;return p[r]=i._addElement(r,e)}function m(e,t,n,r){e=i._getOptions(e),t=t&&i._getOptions(t);var a=BI.isKey(e.key)?e.key:r;if(t&&p[t.key]){var o,s=BI.isKey(t.key)?t.key:r;(o=n?p[s].element.next():p[s].element).length>0?o.before(p[a].element):i._getWrapper().append(p[a].element)}else i._getWrapper().append(p[a].element)}function I(e,t,n,i){var r,a;for(r=n;r<=i;++r)e[r]&&f(e[r],t)&&(a=e[r]);return a}return r>o?function(e,t,n,i){for(;n<=i;++n){m(g(t[n],n),e,!1,n)}}(BI.isNull(t[u+1])?null:t[u+1],t,a,u):a>u&&function(e,t,n){for(;t<=n;++t){var r=e[t];if(BI.isNotNull(r)){var a=i._getOptions(r),o=null==a.key?t:a.key;delete i._children[i._getChildName(o)],p[o]._destroy()}}}(e,r,o),this._children={},BI.each(t,(function(e,t){var n=i._getOptions(t),r=null==n.key?e:n.key;p[r]._mount(),i._children[i._getChildName(e)]=p[r]})),n},update:function(e){var t=this.options,n=e.items||[],i=this.updateChildren(t.items,n);return this.options.items=n,i},stroke:function(e){var t=this;BI.each(e,(function(e,n){n&&t._addElement(e,n)}))},removeWidget:function(e){var t;BI.isWidget(e)?BI.each(this._children,(function(n,i){i===e&&(t=n)})):t=e,t&&this._removeItemAt(0|t)},empty:function(){BI.Layout.superclass.empty.apply(this,arguments),this.options.items=[]},destroy:function(){BI.Layout.superclass.destroy.apply(this,arguments),this.options.items=[]},populate:function(e){this.options;e=e||[],this._isMounted?this.update({items:e}):(this.options.items=e,this.stroke(e))},resize:function(){}}),BI.shortcut("bi.layout",BI.Layout)},function(e,t){BI.AbsoluteCenterLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.AbsoluteCenterLayout.superclass.props.apply(this,arguments),{baseCls:"bi-abs-c-a",hgap:0,lgap:0,rgap:0,vgap:0,tgap:0,bgap:0})},render:function(){BI.AbsoluteCenterLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},_addElement:function(e,t){var n=this.options,i=BI.AbsoluteCenterLayout.superclass._addElement.apply(this,arguments);return i.element.css({position:"absolute",left:(n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit,right:(n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit,top:(n.vgap+n.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit,bottom:(n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit,margin:"auto"}),i},resize:function(){},populate:function(e){BI.AbsoluteCenterLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.absolute_center_adapt",BI.AbsoluteCenterLayout)},function(e,t){BI.AbsoluteHorizontalLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.AbsoluteHorizontalLayout.superclass.props.apply(this,arguments),{baseCls:"bi-abs-h-a",horizontalAlign:BI.HorizontalAlign.Center,rowSize:[],hgap:0,lgap:0,rgap:0,vgap:0,tgap:0,bgap:0})},render:function(){var e=this,t=this.options;return BI.AbsoluteHorizontalLayout.superclass.render.apply(this,arguments),{type:"bi.vtape",horizontalAlign:t.horizontalAlign,rowSize:t.rowSize,items:t.items,scrollx:t.scrollx,scrolly:t.scrolly,scrollable:t.scrollable,ref:function(t){e.layout=t},hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap}},resize:function(){},populate:function(e){this.layout.populate.apply(this,arguments)}}),BI.shortcut("bi.absolute_horizontal_adapt",BI.AbsoluteHorizontalLayout)},function(e,t){BI.AbsoluteLeftRightVerticalAdaptLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.AbsoluteLeftRightVerticalAdaptLayout.superclass.props.apply(this,arguments),{baseCls:"bi-abs-lr-v-a",verticalAlign:BI.VerticalAlign.Middle,items:{},llgap:0,lrgap:0,lhgap:0,ltgap:0,lbgap:0,lvgap:0,rlgap:0,rrgap:0,rhgap:0,rtgap:0,rbgap:0,rvgap:0})},render:function(){var e=this.options,t=this;return BI.AbsoluteLeftRightVerticalAdaptLayout.superclass.render.apply(this,arguments),{type:"bi.htape",ref:function(e){t.layout=e},verticalAlign:e.verticalAlign,items:this._formatItems(),scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable}},_formatItems:function(){var e=this.options,t=e.items.left||[],n=e.items.right||[];return t=BI.map(t,(function(t,n){var i={el:BI.stripEL(n),width:n.width};return e.lvgap+e.ltgap+(n.tgap||0)+(n.vgap||0)!==0&&(i.tgap=e.lvgap+e.ltgap+(n.tgap||0)+(n.vgap||0)),e.lhgap+e.llgap+(n.lgap||0)+(n.hgap||0)!==0&&(i.lgap=(0===t?e.lhgap:0)+e.llgap+(n.lgap||0)+(n.hgap||0)),e.lhgap+e.lrgap+(n.rgap||0)+(n.hgap||0)!==0&&(i.rgap=e.lhgap+e.lrgap+(n.rgap||0)+(n.hgap||0)),e.lvgap+e.lbgap+(n.bgap||0)+(n.vgap||0)!==0&&(i.bgap=e.lvgap+e.lbgap+(n.bgap||0)+(n.vgap||0)),i})),n=BI.map(n,(function(t,n){var i={el:BI.stripEL(n),width:n.width};return e.rvgap+e.rtgap+(n.tgap||0)+(n.vgap||0)!==0&&(i.tgap=e.rvgap+e.rtgap+(n.tgap||0)+(n.vgap||0)),e.rhgap+e.rlgap+(n.lgap||0)+(n.hgap||0)!==0&&(i.lgap=(0===t?e.rhgap:0)+e.rlgap+(n.lgap||0)+(n.hgap||0)),e.rhgap+e.rrgap+(n.rgap||0)+(n.hgap||0)!==0&&(i.rgap=e.rhgap+e.rrgap+(n.rgap||0)+(n.hgap||0)),e.rvgap+e.rbgap+(n.bgap||0)+(n.vgap||0)!==0&&(i.bgap=e.rvgap+e.rbgap+(n.bgap||0)+(n.vgap||0)),i})),t.concat({},n)},resize:function(){},addItem:function(){throw new Error("cannot be added")},populate:function(e){this.options.items=e,this.layout.populate(this._formatItems())}}),BI.shortcut("bi.absolute_left_right_vertical_adapt",BI.AbsoluteLeftRightVerticalAdaptLayout),BI.AbsoluteRightVerticalAdaptLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.AbsoluteRightVerticalAdaptLayout.superclass.props.apply(this,arguments),{baseCls:"bi-abs-r-v-a",verticalAlign:BI.VerticalAlign.Middle,items:[],lgap:0,rgap:0,hgap:0,tgap:0,bgap:0,vgap:0})},render:function(){var e=this.options,t=this;return BI.AbsoluteRightVerticalAdaptLayout.superclass.render.apply(this,arguments),{type:"bi.htape",ref:function(e){t.layout=e},verticalAlign:e.verticalAlign,items:[{}].concat(e.items),hgap:e.hgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,vgap:e.vgap,scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable}},resize:function(){},addItem:function(){throw new Error("cannot be added")},populate:function(e){this.layout.populate(e)}}),BI.shortcut("bi.absolute_right_vertical_adapt",BI.AbsoluteRightVerticalAdaptLayout)},function(e,t){BI.AbsoluteVerticalLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.AbsoluteVerticalLayout.superclass.props.apply(this,arguments),{baseCls:"bi-abs-v-a",verticalAlign:BI.VerticalAlign.Middle,columnSize:[],hgap:0,lgap:0,rgap:0,vgap:0,tgap:0,bgap:0})},render:function(){var e=this,t=this.options;return BI.AbsoluteVerticalLayout.superclass.render.apply(this,arguments),{type:"bi.htape",verticalAlign:t.verticalAlign,columnSize:t.columnSize,items:t.items,scrollx:t.scrollx,scrolly:t.scrolly,scrollable:t.scrollable,ref:function(t){e.layout=t},hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap}},resize:function(){},populate:function(e){this.layout.populate.apply(this,arguments)}}),BI.shortcut("bi.absolute_vertical_adapt",BI.AbsoluteVerticalLayout)},function(e,t){BI.CenterAdaptLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.CenterAdaptLayout.superclass.props.apply(this,arguments),{baseCls:"bi-c-a",horizontalAlign:BI.HorizontalAlign.Center,columnSize:[],scrollx:!1,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){var e=this.options,t=this;return BI.CenterAdaptLayout.superclass.render.apply(this,arguments),{type:"bi.horizontal",verticalAlign:BI.VerticalAlign.Middle,horizontalAlign:e.horizontalAlign,columnSize:e.columnSize,scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable,items:e.items,ref:function(e){t.layout=e},hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap}},resize:function(){},populate:function(e){this.layout.populate.apply(this,arguments)}}),BI.shortcut("bi.center_adapt",BI.CenterAdaptLayout)},function(e,t){BI.HorizontalAdaptLayout=function(){},BI.shortcut("bi.horizontal_adapt",BI.HorizontalAdaptLayout)},function(e,t){BI.LeftRightVerticalAdaptLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.LeftRightVerticalAdaptLayout.superclass.props.apply(this,arguments),{baseCls:"bi-lr-v-a",items:{},llgap:0,lrgap:0,lhgap:0,ltgap:0,lbgap:0,lvgap:0,rlgap:0,rrgap:0,rhgap:0,rtgap:0,rbgap:0,rvgap:0})},render:function(){var e=this.options,t=this;BI.LeftRightVerticalAdaptLayout.superclass.render.apply(this,arguments);var n=[];return"left"in e.items&&n.push({type:"bi.left",items:[{el:{type:"bi.vertical_adapt",ref:function(e){t.left=e},height:"100%",items:e.items.left,hgap:e.lhgap,lgap:e.llgap,rgap:e.lrgap,tgap:e.ltgap,bgap:e.lbgap,vgap:e.lvgap}}]}),"right"in e.items&&n.push({type:"bi.right",items:[{el:{type:"bi.vertical_adapt",ref:function(e){t.right=e},height:"100%",items:e.items.right,hgap:e.rhgap,lgap:e.rlgap,rgap:e.rrgap,tgap:e.rtgap,bgap:e.rbgap,vgap:e.rvgap}}]}),n},resize:function(){},addItem:function(){throw new Error("cannot be added")},populate:function(e){this.left.populate(e.left),this.right.populate(e.right)}}),BI.shortcut("bi.left_right_vertical_adapt",BI.LeftRightVerticalAdaptLayout),BI.LeftVerticalAdaptLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.LeftRightVerticalAdaptLayout.superclass.props.apply(this,arguments),{baseCls:"bi-l-v-a",items:[],lgap:0,rgap:0,hgap:0,tgap:0,bgap:0,vgap:0})},render:function(){var e=this.options,t=this;return BI.LeftVerticalAdaptLayout.superclass.render.apply(this,arguments),{type:"bi.vertical_adapt",ref:function(e){t.layout=e},items:e.items,hgap:e.hgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,vgap:e.vgap,scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable}},resize:function(){},addItem:function(){throw new Error("cannot be added")},populate:function(e){this.layout.populate.apply(this,arguments)}}),BI.shortcut("bi.left_vertical_adapt",BI.LeftVerticalAdaptLayout),BI.RightVerticalAdaptLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.RightVerticalAdaptLayout.superclass.props.apply(this,arguments),{baseCls:"bi-r-v-a",items:[],lgap:0,rgap:0,hgap:0,tgap:0,bgap:0,vgap:0})},render:function(){var e=this.options,t=this;return BI.RightVerticalAdaptLayout.superclass.render.apply(this,arguments),{type:"bi.vertical_adapt",ref:function(e){t.layout=e},horizontalAlign:BI.HorizontalAlign.Right,items:e.items,hgap:e.hgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,vgap:e.vgap,scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable}},resize:function(){},addItem:function(){throw new Error("cannot be added")},populate:function(e){this.layout.populate(e)}}),BI.shortcut("bi.right_vertical_adapt",BI.RightVerticalAdaptLayout)},function(e,t){BI.TableAdaptLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.TableAdaptLayout.superclass.props.apply(this,arguments),{baseCls:"bi-t-a",columnSize:[],verticalAlign:BI.VerticalAlign.Top,horizontalAlign:BI.HorizontalAlign.Left,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){var e=this.options;BI.TableAdaptLayout.superclass.render.apply(this,arguments),this.$table=BI.Widget._renderEngine.createElement("<div>").css({position:"relative",display:"table",width:e.horizontalAlign===BI.HorizontalAlign.Center||e.horizontalAlign===BI.HorizontalAlign.Stretch?"100%":"auto",height:e.verticalAlign!==BI.VerticalAlign.Top?"100%":"auto","white-space":"nowrap"}),this.populate(this.options.items)},_addElement:function(e,t){var n,i=this.options,r="",a=i.columnSize.length>0?i.columnSize[e]:t.width;if(a>0&&(r=a<1?(100*a).toFixed(1)+"%":a+(0===e?i.hgap:0)+i.hgap+i.lgap+i.rgap),""===a&&i.columnSize.indexOf("fill")>=0&&(r=2),this.hasWidget(this._getChildName(e)))(n=this.getWidgetByName(this._getChildName(e))).element.width(r);else{var o=BI._lazyCreateWidget(t);o.element.css({position:"relative",top:"0",left:"0",margin:"0px auto"}),n=BI._lazyCreateWidget({type:"bi.default",width:r,items:[o]}),this.addWidget(this._getChildName(e),n)}return a>0&&n.element.css({"max-width":a<1?r:r/BI.pixRatio+BI.pixUnit}),0===e&&n.element.addClass("first-element"),n.element.css({position:"relative",display:"table-cell","vertical-align":i.verticalAlign,height:"100%"}),i.vgap+i.tgap+(t.tgap||0)+(t.vgap||0)!==0&&o.element.css({"margin-top":(i.vgap+i.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.lgap+(t.lgap||0)+(t.hgap||0)!==0&&o.element.css({"margin-left":((0===e?i.hgap:0)+i.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.rgap+(t.rgap||0)+(t.hgap||0)!==0&&o.element.css({"margin-right":(i.hgap+i.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),i.vgap+i.bgap+(t.bgap||0)+(t.vgap||0)!==0&&o.element.css({"margin-bottom":(i.vgap+i.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n},appendFragment:function(e){this.$table.append(e),this.element.append(this.$table)},resize:function(){},populate:function(e){BI.TableAdaptLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.table_adapt",BI.TableAdaptLayout)},function(e,t){BI.VerticalAdaptLayout=BI.inherit(BI.Layout,{props:{baseCls:"bi-v-a",horizontalAlign:BI.HorizontalAlign.Left,verticalAlign:BI.VerticalAlign.Middle,columnSize:[],scrollx:!1,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0},render:function(){var e=this,t=this.options;return BI.VerticalAdaptLayout.superclass.render.apply(this,arguments),{type:"bi.horizontal",horizontalAlign:t.horizontalAlign,verticalAlign:t.verticalAlign,columnSize:t.columnSize,items:t.items,scrollx:t.scrollx,scrolly:t.scrolly,scrollable:t.scrollable,ref:function(t){e.layout=t},hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap}},resize:function(){},populate:function(e){this.layout.populate.apply(this,arguments)}}),BI.shortcut("bi.vertical_adapt",BI.VerticalAdaptLayout)},function(e,t){BI.HorizontalAutoLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.HorizontalAutoLayout.superclass.props.apply(this,arguments),{baseCls:"bi-h-o",hgap:0,lgap:0,rgap:0,vgap:0,tgap:0,bgap:0})},render:function(){BI.HorizontalAutoLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},_addElement:function(e,t){var n=this.options,i=BI.HorizontalAutoLayout.superclass._addElement.apply(this,arguments);return i.element.css({position:"relative",margin:"0px auto"}),n.vgap+n.tgap+(t.tgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-top":((0===e?n.vgap:0)+n.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-left":(n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-right":(n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-bottom":(n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i},resize:function(){},populate:function(e){BI.HorizontalAutoLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.horizontal_auto",BI.HorizontalAutoLayout)},function(e,t){BI.FloatHorizontalLayout=function(){},BI.shortcut("bi.horizontal_float",BI.FloatHorizontalLayout)},function(e,t){BI.InlineCenterAdaptLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.InlineCenterAdaptLayout.superclass.props.apply(this,arguments),{baseCls:"bi-i-c-a",horizontalAlign:BI.HorizontalAlign.Center,verticalAlign:BI.VerticalAlign.Middle,columnSize:[],hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){var e=this,t=this.options;return{type:"bi.inline",ref:function(t){e.layout=t},items:t.items,horizontalAlign:t.horizontalAlign,verticalAlign:t.verticalAlign,columnSize:t.columnSize,hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap}},populate:function(e){this.layout.populate.apply(this.layout,arguments)}}),BI.shortcut("bi.inline_center_adapt",BI.InlineCenterAdaptLayout)},function(e,t){BI.InlineHorizontalAdaptLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.InlineHorizontalAdaptLayout.superclass.props.apply(this,arguments),{baseCls:"bi-i-h-a",horizontalAlign:BI.HorizontalAlign.Center,verticalAlign:BI.VerticalAlign.Top,columnSize:[],hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){var e=this,t=this.options;return{type:"bi.inline",ref:function(t){e.layout=t},items:t.items,horizontalAlign:t.horizontalAlign,verticalAlign:t.verticalAlign,columnSize:t.columnSize,hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap}},populate:function(e){this.layout.populate.apply(this.layout,arguments)}}),BI.shortcut("bi.inline_horizontal_adapt",BI.InlineHorizontalAdaptLayout)},function(e,t){BI.InlineVerticalAdaptLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.InlineVerticalAdaptLayout.superclass.props.apply(this,arguments),{baseCls:"bi-i-v-a",horizontalAlign:BI.HorizontalAlign.Left,verticalAlign:BI.VerticalAlign.Middle,columnSize:[],hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){var e=this,t=this.options;return{type:"bi.inline",ref:function(t){e.layout=t},items:t.items,horizontalAlign:t.horizontalAlign,verticalAlign:t.verticalAlign,columnSize:t.columnSize,hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap}},populate:function(e){this.layout.populate.apply(this.layout,arguments)}}),BI.shortcut("bi.inline_vertical_adapt",BI.InlineVerticalAdaptLayout)},function(e,t){BI.FlexCenterLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FlexCenterLayout.superclass.props.apply(this,arguments),{baseCls:"bi-f-c",verticalAlign:BI.VerticalAlign.Middle,horizontalAlign:BI.HorizontalAlign.Center,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){var e=this,t=this.options;return{type:"bi.flex_horizontal",ref:function(t){e.wrapper=t},horizontalAlign:t.horizontalAlign,verticalAlign:t.verticalAlign,columnSize:t.columnSize,rowSize:t.rowSize,scrollx:t.scrollx,scrolly:t.scrolly,scrollable:t.scrollable,hgap:t.hgap,vgap:t.vgap,tgap:t.tgap,bgap:t.bgap,items:t.items}},resize:function(){},update:function(e){return this.wrapper.update(e)},populate:function(e){this.wrapper.populate(e)}}),BI.shortcut("bi.flex_center_adapt",BI.FlexCenterLayout)},function(e,t){BI.FlexHorizontalCenter=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FlexHorizontalCenter.superclass.props.apply(this,arguments),{baseCls:"bi-f-h-c",horizontalAlign:BI.HorizontalAlign.Center,verticalAlign:BI.VerticalAlign.Top,rowSize:[],scrolly:!1,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){var e=this,t=this.options;return{type:"bi.flex_vertical",ref:function(t){e.wrapper=t},horizontalAlign:t.horizontalAlign,verticalAlign:t.verticalAlign,columnSize:t.columnSize,rowSize:t.rowSize,scrollx:t.scrollx,scrolly:t.scrolly,scrollable:t.scrollable,hgap:t.hgap,vgap:t.vgap,tgap:t.tgap,bgap:t.bgap,items:t.items}},resize:function(){},update:function(e){return this.wrapper.update(e)},populate:function(e){this.wrapper.populate(e)}}),BI.shortcut("bi.flex_horizontal_adapt",BI.FlexHorizontalCenter),BI.shortcut("bi.flex_horizontal_center_adapt",BI.FlexHorizontalCenter)},function(e,t){BI.FlexHorizontalLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FlexHorizontalLayout.superclass.props.apply(this,arguments),{baseCls:"bi-f-h",verticalAlign:BI.VerticalAlign.Top,horizontalAlign:BI.HorizontalAlign.Left,columnSize:[],scrollx:!0,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){BI.FlexHorizontalLayout.superclass.render.apply(this,arguments);var e=this.options;this.element.addClass("v-"+e.verticalAlign).addClass("h-"+e.horizontalAlign),!0!==e.scrollable&&!0!==e.scrollx||this.element.addClass("f-scroll-x"),!0!==e.scrollable&&!0!==e.scrolly||this.element.addClass("f-scroll-y"),this.populate(this.options.items)},_addElement:function(e,t){var n=this.options,i=BI.FlexHorizontalLayout.superclass._addElement.apply(this,arguments),r=n.columnSize.length>0?n.columnSize[e]:t.width>=1?null:t.width;return n.columnSize.length>0&&t.width>=1&&n.columnSize[e]>=1&&n.columnSize[e]!==t.width&&(r=null),i.element.css({position:"relative"}),"auto"!==r&&("fill"===r||""===r?(n.horizontalAlign!==BI.HorizontalAlign.Stretch&&(!0!==n.scrollable&&!0!==n.scrollx||i.element.addClass("f-s-n")),""===r&&n.columnSize.indexOf("fill")>=0&&i.element.addClass("f-s-n")):i.element.addClass("f-s-n")),r>0&&i.element.width(r<1?(100*r).toFixed(1)+"%":r/BI.pixRatio+BI.pixUnit),"fill"===r&&i.element.addClass("f-f"),i.element.addClass("c-e"),0===e&&i.element.addClass("f-c"),e===n.items.length-1&&i.element.addClass("l-c"),n.vgap+n.tgap+(t.tgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-top":(n.vgap+n.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-left":((0===e?n.hgap:0)+n.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-right":(n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-bottom":(n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i},resize:function(){},populate:function(e){BI.FlexHorizontalLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.flex_horizontal",BI.FlexHorizontalLayout)},function(e,t){BI.FlexLeftRightVerticalAdaptLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FlexLeftRightVerticalAdaptLayout.superclass.props.apply(this,arguments),{baseCls:"bi-f-lr-v-c",items:{},llgap:0,lrgap:0,lhgap:0,ltgap:0,lbgap:0,lvgap:0,rlgap:0,rrgap:0,rhgap:0,rtgap:0,rbgap:0,rvgap:0})},render:function(){var e=this.options,t=this;return BI.FlexLeftRightVerticalAdaptLayout.superclass.render.apply(this,arguments),{type:"bi.flex_vertical_adapt",ref:function(e){t.layout=e},items:this._formatItems(),scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable}},_formatItems:function(){var e=this.options,t=e.items.left||[],n=e.items.right||[];return(t=BI.map(t,(function(t,n){var i={el:BI.stripEL(n)};return e.lvgap+e.ltgap+(n.tgap||0)+(n.vgap||0)!==0&&(i.tgap=e.lvgap+e.ltgap+(n.tgap||0)+(n.vgap||0)),e.lhgap+e.llgap+(n.lgap||0)+(n.hgap||0)!==0&&(i.lgap=(0===t?e.lhgap:0)+e.llgap+(n.lgap||0)+(n.hgap||0)),e.lhgap+e.lrgap+(n.rgap||0)+(n.hgap||0)!==0&&(i.rgap=e.lhgap+e.lrgap+(n.rgap||0)+(n.hgap||0)),e.lvgap+e.lbgap+(n.bgap||0)+(n.vgap||0)!==0&&(i.bgap=e.lvgap+e.lbgap+(n.bgap||0)+(n.vgap||0)),i}))).concat({el:{type:"bi.flex_vertical_adapt",cls:"flex-left-auto",hgap:e.rhgap,vgap:e.rvgap,lgap:e.rlgap,rgap:e.rrgap,tgap:e.rtgap,bgap:e.rbgap,items:n}})},resize:function(){},addItem:function(){throw new Error("cannot be added")},populate:function(e){this.options.items=e,this.layout.populate(this._formatItems())}}),BI.shortcut("bi.flex_left_right_vertical_adapt",BI.FlexLeftRightVerticalAdaptLayout)},function(e,t){BI.FlexVerticalCenter=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FlexVerticalCenter.superclass.props.apply(this,arguments),{baseCls:"bi-f-v-c",horizontalAlign:BI.HorizontalAlign.Left,verticalAlign:BI.VerticalAlign.Middle,columnSize:[],scrollx:!1,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){var e=this,t=this.options;return{type:"bi.flex_horizontal",ref:function(t){e.wrapper=t},verticalAlign:t.verticalAlign,horizontalAlign:t.horizontalAlign,columnSize:t.columnSize,rowSize:t.rowSize,scrollx:t.scrollx,scrolly:t.scrolly,scrollable:t.scrollable,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,hgap:t.hgap,items:t.items}},resize:function(){},update:function(e){return this.wrapper.update(e)},populate:function(e){this.wrapper.populate(e)}}),BI.shortcut("bi.flex_vertical_adapt",BI.FlexVerticalCenter),BI.shortcut("bi.flex_vertical_center_adapt",BI.FlexVerticalCenter)},function(e,t){BI.FlexVerticalLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FlexVerticalLayout.superclass.props.apply(this,arguments),{baseCls:"bi-f-v",horizontalAlign:BI.HorizontalAlign.Left,verticalAlign:BI.VerticalAlign.Top,rowSize:[],scrolly:!0,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){BI.FlexVerticalLayout.superclass.render.apply(this,arguments);var e=this.options;this.element.addClass("h-"+e.horizontalAlign).addClass("v-"+e.verticalAlign),!0!==e.scrollable&&!0!==e.scrollx||this.element.addClass("f-scroll-x"),!0!==e.scrollable&&!0!==e.scrolly||this.element.addClass("f-scroll-y"),this.populate(this.options.items)},_addElement:function(e,t){var n=this.options,i=BI.FlexVerticalLayout.superclass._addElement.apply(this,arguments),r=n.rowSize.length>0?n.rowSize[e]:t.height>=1?null:t.height;return n.rowSize.length>0&&t.height>=1&&n.rowSize[e]>=1&&n.rowSize[e]!==t.height&&(r=null),i.element.css({position:"relative"}),"auto"!==r&&("fill"===r||""===r?(n.verticalAlign!==BI.VerticalAlign.Stretch&&(!0!==n.scrollable&&!0!==n.scrolly||i.element.addClass("f-s-n")),""===r&&n.rowSize.indexOf("fill")>=0&&i.element.addClass("f-s-n")):i.element.addClass("f-s-n")),r>0&&i.element.height(r<1?(100*r).toFixed(1)+"%":r/BI.pixRatio+BI.pixUnit),"fill"===r&&i.element.addClass("f-f"),i.element.addClass("c-e"),0===e&&i.element.addClass("f-c"),e===n.items.length-1&&i.element.addClass("l-c"),n.vgap+n.tgap+(t.tgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-top":((0===e?n.vgap:0)+n.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-left":(n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-right":(n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-bottom":(n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i},resize:function(){},populate:function(e){BI.FlexVerticalLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.flex_vertical",BI.FlexVerticalLayout)},function(e,t){BI.FlexWrapperCenterLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FlexWrapperCenterLayout.superclass.props.apply(this,arguments),{baseCls:"bi-f-s-c",horizontalAlign:BI.HorizontalAlign.Center,verticalAlign:BI.VerticalAlign.Middle,columnSize:[],scrollx:!1,scrollable:!0,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){var e=this,t=this.options;return{type:"bi.flex_scrollable_horizontal",ref:function(t){e.wrapper=t},horizontalAlign:t.horizontalAlign,verticalAlign:t.verticalAlign,columnSize:t.columnSize,rowSize:t.rowSize,scrollx:t.scrollx,scrolly:t.scrolly,scrollable:t.scrollable,hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,items:t.items}},update:function(e){return this.wrapper.update(e)},populate:function(e){this.wrapper.populate(e)}}),BI.shortcut("bi.flex_scrollable_center_adapt",BI.FlexWrapperCenterLayout)},function(e,t){BI.FlexWrapperHorizontalCenter=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FlexWrapperHorizontalCenter.superclass.props.apply(this,arguments),{baseCls:"bi-f-s-v-c",horizontalAlign:BI.HorizontalAlign.Center,verticalAlign:BI.VerticalAlign.Top,rowSize:[],scrollable:!0,scrolly:!1,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){var e=this,t=this.options;return{type:"bi.flex_scrollable_vertical",ref:function(t){e.wrapper=t},horizontalAlign:t.horizontalAlign,verticalAlign:t.verticalAlign,columnSize:t.columnSize,rowSize:t.rowSize,scrollx:t.scrollx,scrolly:t.scrolly,scrollable:t.scrollable,hgap:t.hgap,vgap:t.vgap,tgap:t.tgap,bgap:t.bgap,items:t.items}},update:function(e){return this.wrapper.update(e)},populate:function(e){this.wrapper.populate(e)}}),BI.shortcut("bi.flex_scrollable_horizontal_adapt",BI.FlexWrapperHorizontalCenter),BI.shortcut("bi.flex_scrollable_horizontal_center_adapt",BI.FlexWrapperHorizontalCenter)},function(e,t){BI.FlexWrapperHorizontalLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FlexWrapperHorizontalLayout.superclass.props.apply(this,arguments),{baseCls:"bi-f-s-h",verticalAlign:BI.VerticalAlign.Top,horizontalAlign:BI.HorizontalAlign.Left,columnSize:[],scrollable:null,scrollx:!0,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){BI.FlexWrapperHorizontalLayout.superclass.render.apply(this,arguments);var e=this.options;this.element.addClass("v-"+e.verticalAlign).addClass("h-"+e.horizontalAlign),this.$wrapper=BI.Widget._renderEngine.createElement("<div>").addClass("f-s-h-w v-"+e.verticalAlign).addClass("h-"+e.horizontalAlign),this.populate(this.options.items)},_addElement:function(e,t){var n=this.options,i=BI.FlexWrapperHorizontalLayout.superclass._addElement.apply(this,arguments),r=n.columnSize.length>0?n.columnSize[e]:t.width>=1?null:t.width;return n.columnSize.length>0&&t.width>=1&&n.columnSize[e]>=1&&n.columnSize[e]!==t.width&&(r=null),i.element.css({position:"relative"}),"auto"!==r&&("fill"===r||""===r?(n.horizontalAlign!==BI.HorizontalAlign.Stretch&&(!0!==n.scrollable&&!0!==n.scrollx||i.element.addClass("f-s-n")),""===r&&n.columnSize.indexOf("fill")>=0&&i.element.addClass("f-s-n")):i.element.addClass("f-s-n")),r>0&&i.element.width(r<1?(100*r).toFixed(1)+"%":r/BI.pixRatio+BI.pixUnit),"fill"===r&&(i.element.addClass("f-f"),this.element.addClass("f-f")),i.element.addClass("c-e"),0===e&&i.element.addClass("f-c"),e===n.items.length-1&&i.element.addClass("l-c"),n.vgap+n.tgap+(t.tgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-top":(n.vgap+n.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-left":((0===e?n.hgap:0)+n.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-right":(n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-bottom":(n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i},appendFragment:function(e){this.$wrapper.append(e),this.element.append(this.$wrapper)},_getWrapper:function(){return this.$wrapper},resize:function(){},populate:function(e){BI.FlexWrapperHorizontalLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.flex_scrollable_horizontal",BI.FlexWrapperHorizontalLayout)},function(e,t){BI.FlexWrapperVerticalCenter=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FlexWrapperVerticalCenter.superclass.props.apply(this,arguments),{baseCls:"bi-f-s-v-c",horizontalAlign:BI.HorizontalAlign.Left,verticalAlign:BI.VerticalAlign.Middle,columnSize:[],scrollx:!1,scrollable:!0,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){var e=this,t=this.options;return{type:"bi.flex_scrollable_horizontal",ref:function(t){e.wrapper=t},verticalAlign:t.verticalAlign,horizontalAlign:t.horizontalAlign,columnSize:t.columnSize,rowSize:t.rowSize,scrollx:t.scrollx,scrolly:t.scrolly,scrollable:t.scrollable,hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,items:t.items}},update:function(e){return this.wrapper.update(e)},populate:function(e){this.wrapper.populate(e)}}),BI.shortcut("bi.flex_scrollable_vertical_adapt",BI.FlexWrapperVerticalCenter),BI.shortcut("bi.flex_scrollable_vertical_center_adapt",BI.FlexWrapperVerticalCenter)},function(e,t){BI.FlexWrapperVerticalLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FlexWrapperVerticalLayout.superclass.props.apply(this,arguments),{baseCls:"bi-f-s-v",horizontalAlign:BI.HorizontalAlign.Left,verticalAlign:BI.VerticalAlign.Top,rowSize:[],scrollable:null,scrolly:!0,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){BI.FlexWrapperVerticalLayout.superclass.render.apply(this,arguments);var e=this.options;this.element.addClass("v-"+e.verticalAlign).addClass("h-"+e.horizontalAlign),this.$wrapper=BI.Widget._renderEngine.createElement("<div>").addClass("f-s-v-w h-"+e.horizontalAlign).addClass("v-"+e.verticalAlign),this.populate(this.options.items)},_addElement:function(e,t){var n=this.options,i=BI.FlexWrapperVerticalLayout.superclass._addElement.apply(this,arguments),r=n.rowSize.length>0?n.rowSize[e]:t.height>=1?null:t.height;return n.rowSize.length>0&&t.height>=1&&n.rowSize[e]>=1&&n.rowSize[e]!==t.height&&(r=null),i.element.css({position:"relative"}),"auto"!==r&&("fill"===r||""===r?(n.verticalAlign!==BI.VerticalAlign.Stretch&&(!0!==n.scrollable&&!0!==n.scrolly||i.element.addClass("f-s-n")),""===r&&n.rowSize.indexOf("fill")>=0&&i.element.addClass("f-s-n")):i.element.addClass("f-s-n")),r>0&&i.element.height(r<1?(100*r).toFixed(1)+"%":r/BI.pixRatio+BI.pixUnit),"fill"===r&&(i.element.addClass("f-f"),this.element.addClass("f-f")),i.element.addClass("c-e"),0===e&&i.element.addClass("f-c"),e===n.items.length-1&&i.element.addClass("l-c"),n.vgap+n.tgap+(t.tgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-top":((0===e?n.vgap:0)+n.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-left":(n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-right":(n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-bottom":(n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i},appendFragment:function(e){this.$wrapper.append(e),this.element.append(this.$wrapper)},_getWrapper:function(){return this.$wrapper},resize:function(){},populate:function(e){BI.FlexWrapperVerticalLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.flex_scrollable_vertical",BI.FlexWrapperVerticalLayout)},function(e,t){BI.AbsoluteLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.AbsoluteLayout.superclass.props.apply(this,arguments),{baseCls:"bi-abs",hgap:null,vgap:null,lgap:null,rgap:null,tgap:null,bgap:null})},render:function(){BI.AbsoluteLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},_addElement:function(e,t){var n=this.options,i=BI.AbsoluteLayout.superclass._addElement.apply(this,arguments),r=0,a=0,o=0,s=0;return BI.isNotNull(t.left)&&(i.element.css({left:BI.isNumber(t.left)?t.left/BI.pixRatio+BI.pixUnit:t.left}),r+=t.left),BI.isNotNull(t.right)&&(i.element.css({right:BI.isNumber(t.right)?t.right/BI.pixRatio+BI.pixUnit:t.right}),a+=t.right),BI.isNotNull(t.top)&&(i.element.css({top:BI.isNumber(t.top)?t.top/BI.pixRatio+BI.pixUnit:t.top}),o+=t.top),BI.isNotNull(t.bottom)&&(i.element.css({bottom:BI.isNumber(t.bottom)?t.bottom/BI.pixRatio+BI.pixUnit:t.bottom}),s+=t.bottom),BI.isNotNull(n.hgap)&&(r+=n.hgap,i.element.css({left:r/BI.pixRatio+BI.pixUnit}),a+=n.hgap,i.element.css({right:a/BI.pixRatio+BI.pixUnit})),BI.isNotNull(n.vgap)&&(o+=n.vgap,i.element.css({top:o/BI.pixRatio+BI.pixUnit}),s+=n.vgap,i.element.css({bottom:s/BI.pixRatio+BI.pixUnit})),BI.isNotNull(n.lgap)&&(r+=n.lgap,i.element.css({left:r/BI.pixRatio+BI.pixUnit})),BI.isNotNull(n.rgap)&&(a+=n.rgap,i.element.css({right:a/BI.pixRatio+BI.pixUnit})),BI.isNotNull(n.tgap)&&(o+=n.tgap,i.element.css({top:o/BI.pixRatio+BI.pixUnit})),BI.isNotNull(n.bgap)&&(s+=n.bgap,i.element.css({bottom:s/BI.pixRatio+BI.pixUnit})),BI.isNotNull(t.width)&&i.element.css({width:BI.isNumber(t.width)?t.width/BI.pixRatio+BI.pixUnit:t.width}),BI.isNotNull(t.height)&&i.element.css({height:BI.isNumber(t.height)?t.height/BI.pixRatio+BI.pixUnit:t.height}),i.element.css({position:"absolute"}),i},resize:function(){this.stroke(this.options.items)},populate:function(e){BI.AbsoluteLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.absolute",BI.AbsoluteLayout)},function(e,t){BI.AdaptiveLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.AdaptiveLayout.superclass.props.apply(this,arguments),{baseCls:"bi-adaptive",hgap:null,vgap:null,lgap:null,rgap:null,tgap:null,bgap:null})},render:function(){BI.AdaptiveLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},_addElement:function(e,t){var n=this.options,i=BI.AdaptiveLayout.superclass._addElement.apply(this,arguments);i.element.css({position:"relative"});var r=0,a=0,o=0,s=0;return BI.isNotNull(t.left)&&i.element.css({left:BI.isNumber(t.left)?t.left/BI.pixRatio+BI.pixUnit:t.left}),BI.isNotNull(t.right)&&i.element.css({right:BI.isNumber(t.right)?t.right/BI.pixRatio+BI.pixUnit:t.right}),BI.isNotNull(t.top)&&i.element.css({top:BI.isNumber(t.top)?t.top/BI.pixRatio+BI.pixUnit:t.top}),BI.isNotNull(t.bottom)&&i.element.css({bottom:BI.isNumber(t.bottom)?t.bottom/BI.pixRatio+BI.pixUnit:t.bottom}),BI.isNotNull(n.hgap)&&(r+=n.hgap,i.element.css({"margin-left":r/BI.pixRatio+BI.pixUnit}),a+=n.hgap,i.element.css({"margin-right":a/BI.pixRatio+BI.pixUnit})),BI.isNotNull(n.vgap)&&(o+=n.vgap,i.element.css({"margin-top":o/BI.pixRatio+BI.pixUnit}),s+=n.vgap,i.element.css({"margin-bottom":s/BI.pixRatio+BI.pixUnit})),BI.isNotNull(n.lgap)&&(r+=n.lgap,i.element.css({"margin-left":r/BI.pixRatio+BI.pixUnit})),BI.isNotNull(n.rgap)&&(a+=n.rgap,i.element.css({"margin-right":a/BI.pixRatio+BI.pixUnit})),BI.isNotNull(n.tgap)&&(o+=n.tgap,i.element.css({"margin-top":o/BI.pixRatio+BI.pixUnit})),BI.isNotNull(n.bgap)&&(s+=n.bgap,i.element.css({"margin-bottom":s/BI.pixRatio+BI.pixUnit})),BI.isNotNull(t.width)&&i.element.css({width:BI.isNumber(t.width)?t.width/BI.pixRatio+BI.pixUnit:t.width}),BI.isNotNull(t.height)&&i.element.css({height:BI.isNumber(t.height)?t.height/BI.pixRatio+BI.pixUnit:t.height}),i},resize:function(){this.stroke(this.options.items)},populate:function(e){BI.AbsoluteLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.adaptive",BI.AdaptiveLayout)},function(e,t){BI.BorderLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.BorderLayout.superclass.props.apply(this,arguments),{baseCls:"bi-border-layout",items:{}})},render:function(){BI.BorderLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},resize:function(){this.stroke(this.options.items)},addItem:function(e){throw new Error("cannot be added")},stroke:function(e){var t,n=0,i=0,r=0,a=0;if("north"in e&&null!=(t=e.north)){if(t.el){if(!this.hasWidget(this._getChildName("north"))){var o=BI._lazyCreateWidget(t);this.addWidget(this._getChildName("north"),o)}this.getWidgetByName(this._getChildName("north")).element.height(t.height/BI.pixRatio+BI.pixUnit).css({position:"absolute",top:(t.top||0)/BI.pixRatio+BI.pixUnit,left:(t.left||0)/BI.pixRatio+BI.pixUnit,right:(t.right||0)/BI.pixRatio+BI.pixUnit,bottom:"initial"})}n=(t.height||0)+(t.top||0)+(t.bottom||0)}if("south"in e&&null!=(t=e.south)){if(t.el){if(!this.hasWidget(this._getChildName("south"))){o=BI._lazyCreateWidget(t);this.addWidget(this._getChildName("south"),o)}this.getWidgetByName(this._getChildName("south")).element.height(t.height/BI.pixRatio+BI.pixUnit).css({position:"absolute",bottom:(t.bottom||0)/BI.pixRatio+BI.pixUnit,left:(t.left||0)/BI.pixRatio+BI.pixUnit,right:(t.right||0)/BI.pixRatio+BI.pixUnit,top:"initial"})}i=(t.height||0)+(t.top||0)+(t.bottom||0)}if("west"in e&&null!=(t=e.west)){if(t.el){if(!this.hasWidget(this._getChildName("west"))){o=BI._lazyCreateWidget(t);this.addWidget(this._getChildName("west"),o)}this.getWidgetByName(this._getChildName("west")).element.width(t.width/BI.pixRatio+BI.pixUnit).css({position:"absolute",left:(t.left||0)/BI.pixRatio+BI.pixUnit,top:n/BI.pixRatio+BI.pixUnit,bottom:i/BI.pixRatio+BI.pixUnit,right:"initial"})}r=(t.width||0)+(t.left||0)+(t.right||0)}if("east"in e&&null!=(t=e.east)){if(t.el){if(!this.hasWidget(this._getChildName("east"))){o=BI._lazyCreateWidget(t);this.addWidget(this._getChildName("east"),o)}this.getWidgetByName(this._getChildName("east")).element.width(t.width/BI.pixRatio+BI.pixUnit).css({position:"absolute",right:(t.right||0)/BI.pixRatio+BI.pixUnit,top:n/BI.pixRatio+BI.pixUnit,bottom:i/BI.pixRatio+BI.pixUnit,left:"initial"})}a=(t.width||0)+(t.left||0)+(t.right||0)}if("center"in e&&null!=(t=e.center)){if(!this.hasWidget(this._getChildName("center"))){o=BI._lazyCreateWidget(t);this.addWidget(this._getChildName("center"),o)}this.getWidgetByName(this._getChildName("center")).element.css({position:"absolute",top:n/BI.pixRatio+BI.pixUnit,bottom:i/BI.pixRatio+BI.pixUnit,left:r/BI.pixRatio+BI.pixUnit,right:a/BI.pixRatio+BI.pixUnit})}},update:function(e){},populate:function(e){BI.BorderLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.border",BI.BorderLayout)},function(e,t){BI.CardLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.CardLayout.superclass.props.apply(this,arguments),{baseCls:"bi-card-layout",items:[]})},render:function(){BI.CardLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},resize:function(){},stroke:function(e){var t=this,n=this.options;this.showIndex=void 0,BI.each(e,(function(e,i){if(i){if(t.hasWidget(i.cardName))var r=t.getWidgetByName(t._getChildName(i.cardName));else(r=BI._lazyCreateWidget(i)).on(BI.Events.DESTROY,(function(){var e=BI.findIndex(n.items,(function(e,t){return t.cardName==i.cardName}));e>-1&&n.items.splice(e,1)})),t.addWidget(t._getChildName(i.cardName),r);r.element.css({position:"absolute",top:"0",right:"0",bottom:"0",left:"0"}),r.setVisible(!1)}}))},update:function(){},empty:function(){BI.CardLayout.superclass.empty.apply(this,arguments),this.options.items=[]},populate:function(e){BI.CardLayout.superclass.populate.apply(this,arguments),this._mount(),this.options.defaultShowName&&this.showCardByName(this.options.defaultShowName)},isCardExisted:function(e){return BI.some(this.options.items,(function(t,n){return n.cardName==e&&n.el}))},getCardByName:function(e){if(!this.isCardExisted(e))throw new Error("cardName is not exist");return this._children[this._getChildName(e)]},_deleteCardByName:function(e){delete this._children[this._getChildName(e)];var t=BI.findIndex(this.options.items,(function(t,n){return n.cardName==e}));t>-1&&this.options.items.splice(t,1)},deleteCardByName:function(e){if(!this.isCardExisted(e))throw new Error("cardName is not exist");var t=this._children[this._getChildName(e)];this._deleteCardByName(e),t&&t._destroy()},addCardByName:function(e,t){if(this.isCardExisted(e))throw new Error("cardName is already exist");var n=BI._lazyCreateWidget(t,this);return n.element.css({position:"relative",top:"0",left:"0",width:"100%",height:"100%"}).appendTo(this.element),n.invisible(),this.addWidget(this._getChildName(e),n),this.options.items.push({el:t,cardName:e}),n},showCardByName:function(e,t,n){var i=this,r=this.isCardExisted(e);null!=this.showIndex&&(this.lastShowIndex=this.showIndex),this.showIndex=e;var a=!1;BI.each(this.options.items,(function(o,s){var l=i._children[i._getChildName(s.cardName)];l&&(e!=s.cardName?!a&&!r&&BI.Action&&t instanceof BI.Action?(t.actionBack(l),a=!0):l.invisible():BI.Action&&t instanceof BI.Action?t.actionPerformed(void 0,l,n):(l.visible(),n&&n()))}))},showLastCard:function(){var e=this;this.showIndex=this.lastShowIndex,BI.each(this.options.items,(function(t,n){e._children[e._getChildName(n.cardName)].setVisible(e.showIndex==t)}))},setDefaultShowName:function(e){return this.options.defaultShowName=e,this},getDefaultShowName:function(){return this.options.defaultShowName},getAllCardNames:function(){return BI.map(this.options.items,(function(e,t){return t.cardName}))},getShowingCard:function(){if(BI.isKey(this.showIndex))return this.getWidgetByName(this._getChildName(this.showIndex))},deleteAllCard:function(){var e=this;BI.each(this.getAllCardNames(),(function(t,n){e.deleteCardByName(n)}))},hideAllCard:function(){var e=this;BI.each(this.options.items,(function(t,n){e._children[e._getChildName(n.cardName)].invisible()}))},isAllCardHide:function(){var e=this,t=!0;return BI.some(this.options.items,(function(n,i){if(e._children[e._getChildName(i.cardName)].isVisible())return t=!1,!1})),t},removeWidget:function(e){var t;BI.isWidget(e)?BI.each(this._children,(function(n,i){i===e&&(t=n)})):t=e,t&&this._deleteCardByName(t)}}),BI.shortcut("bi.card",BI.CardLayout)},function(e,t){BI.DefaultLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.DefaultLayout.superclass.props.apply(this,arguments),{hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0,items:[]})},render:function(){BI.DefaultLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},_addElement:function(e,t){var n=this.options,i=BI.DefaultLayout.superclass._addElement.apply(this,arguments);return n.vgap+n.tgap+(t.tgap||0)!==0&&i.element.css({"margin-top":(n.vgap+n.tgap+(t.tgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.lgap+(t.lgap||0)!==0&&i.element.css({"margin-left":(n.hgap+n.lgap+(t.lgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.rgap+(t.rgap||0)!==0&&i.element.css({"margin-right":(n.hgap+n.rgap+(t.rgap||0))/BI.pixRatio+BI.pixUnit}),n.vgap+n.bgap+(t.bgap||0)!==0&&i.element.css({"margin-bottom":(n.vgap+n.bgap+(t.bgap||0))/BI.pixRatio+BI.pixUnit}),i},resize:function(){},populate:function(e){BI.DefaultLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.default",BI.DefaultLayout)},function(e,t){BI.DivisionLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.DivisionLayout.superclass.props.apply(this,arguments),{baseCls:"bi-division",columns:null,rows:null,items:[]})},render:function(){BI.DivisionLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},resize:function(){this.stroke(this.opitons.items)},addItem:function(e){throw new Error("cannot be added")},stroke:function(e){var t,n,i,r=this.options,a=r.rows||r.items.length,o=r.columns||0|(r.items[0]&&r.items[0].length),s=BI.makeArray(a),l={},u={};function c(e,t,n){0===t&&e.addClass("first-row"),0===n&&e.addClass("first-col"),e.addClass(BI.isOdd(t+1)?"odd-row":"even-row"),e.addClass(BI.isOdd(n+1)?"odd-col":"even-col"),e.addClass("center-element")}function h(e,t,n){var i="";0===t&&(i+=" first-row"),0===n&&(i+=" first-col"),BI.isOdd(t+1)?i+=" odd-row":i+=" even-row",BI.isOdd(n+1)?i+=" odd-col":i+=" even-col",e.cls=(e.cls||"")+i+" center-element"}BI.each(s,(function(e){s[e]=BI.makeArray(o)})),BI.each(e,(function(e,t){BI.isArray(t)?BI.each(t,(function(n,i){l[e]=(l[e]||0)+t.width,u[n]=(u[n]||0)+t.height,s[e][n]=i})):(l[t.row]=(l[t.row]||0)+t.width,u[t.column]=(u[t.column]||0)+t.height,s[t.row][t.column]=t)}));for(var p=0;p<a;p++)for(var d=0,f=0;f<o;f++){if(!s[p][f])throw new Error("item be required");if(this.hasWidget(this._getChildName(p+"_"+f)))g=this.getWidgetByName(this._getChildName(p+"_"+f));else{var g=BI._lazyCreateWidget(s[p][f]);this.addWidget(this._getChildName(p+"_"+f),g)}var m=100*d/l[p];if(g.element.css({position:"absolute",left:m+"%"}),f>0)this.getWidgetByName(this._getChildName(p+"_"+(f-1))).element.css({right:100-m+"%"});f==r.columns-1&&g.element.css({right:"0%"}),n=p,i=f,(t=g)instanceof BI.Widget?c(t.element,n,i):t.el instanceof BI.Widget?c(t.el.element,n,i):t.el?h(t.el,n,i):h(t,n,i),d+=s[p][f].width}for(f=0;f<r.columns;f++){var I=0;for(p=0;p<r.rows;p++){g=this.getWidgetByName(this._getChildName(p+"_"+f));var B=100*I/u[f];if(g.element.css({top:B+"%"}),p>0)this.getWidgetByName(this._getChildName(p-1+"_"+f)).element.css({bottom:100-B+"%"});p==r.rows-1&&g.element.css({bottom:"0%"}),I+=s[p][f].height}}},update:function(){},populate:function(e){BI.DivisionLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.division",BI.DivisionLayout)},function(e,t){BI.FloatLeftLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FloatLeftLayout.superclass.props.apply(this,arguments),{baseCls:"bi-left clearfix",hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){BI.FloatLeftLayout.superclass.render.apply(this,arguments);this.options;this.populate(this.options.items)},_addElement:function(e,t){var n=this.options,i=BI.FloatLeftLayout.superclass._addElement.apply(this,arguments);return i.element.css({position:"relative",float:"left"}),BI.isNotNull(t.left)&&i.element.css({left:BI.isNumber(t.left)?t.left/BI.pixRatio+BI.pixUnit:t.left}),BI.isNotNull(t.right)&&i.element.css({right:BI.isNumber(t.right)?t.right/BI.pixRatio+BI.pixUnit:t.right}),BI.isNotNull(t.top)&&i.element.css({top:BI.isNumber(t.top)?t.top/BI.pixRatio+BI.pixUnit:t.top}),BI.isNotNull(t.bottom)&&i.element.css({bottom:BI.isNumber(t.bottom)?t.bottom/BI.pixRatio+BI.pixUnit:t.bottom}),n.vgap+n.tgap+(t.tgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-top":(n.vgap/2+n.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-left":(n.hgap/2+n.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-right":(n.hgap/2+n.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-bottom":(n.vgap/2+n.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i},resize:function(){this.stroke(this.options.items)},populate:function(e){BI.FloatLeftLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.left",BI.FloatLeftLayout),BI.FloatRightLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FloatRightLayout.superclass.props.apply(this,arguments),{baseCls:"bi-right clearfix",hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){BI.FloatRightLayout.superclass.render.apply(this,arguments);this.options;this.populate(this.options.items)},_addElement:function(e,t){var n=this.options,i=BI.FloatRightLayout.superclass._addElement.apply(this,arguments);return i.element.css({position:"relative",float:"right"}),BI.isNotNull(t.left)&&i.element.css({left:BI.isNumber(t.left)?t.left/BI.pixRatio+BI.pixUnit:t.left}),BI.isNotNull(t.right)&&i.element.css({right:BI.isNumber(t.right)?t.right/BI.pixRatio+BI.pixUnit:t.right}),BI.isNotNull(t.top)&&i.element.css({top:BI.isNumber(t.top)?t.top/BI.pixRatio+BI.pixUnit:t.top}),BI.isNotNull(t.bottom)&&i.element.css({bottom:BI.isNumber(t.bottom)?t.bottom/BI.pixRatio+BI.pixUnit:t.bottom}),n.vgap+n.tgap+(t.tgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-top":(n.vgap/2+n.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-left":(n.hgap/2+n.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-right":(n.hgap/2+n.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-bottom":(n.vgap/2+n.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i},resize:function(){this.stroke(this.options.items)},populate:function(e){BI.FloatRightLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.right",BI.FloatRightLayout)},function(e,t){BI.GridLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.GridLayout.superclass.props.apply(this,arguments),{baseCls:"bi-grid",columns:null,rows:null,items:[]})},render:function(){BI.GridLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},resize:function(){},addItem:function(){throw new Error("cannot be added")},stroke:function(e){for(var t,n,i,r=this.options,a=r.rows||r.items.length,o=r.columns||0|(r.items[0]&&r.items[0].length),s=100/o,l=100/a,u=[],c=0;c<a;c++)u[c]=[];function h(e,t,n){0===t&&e.addClass("first-row"),0===n&&e.addClass("first-col"),e.addClass(BI.isOdd(t+1)?"odd-row":"even-row"),e.addClass(BI.isOdd(n+1)?"odd-col":"even-col"),e.addClass("center-element")}function p(e,t,n){var i="";0===t&&(i+=" first-row"),0===n&&(i+=" first-col"),BI.isOdd(t+1)?i+=" odd-row":i+=" even-row",BI.isOdd(n+1)?i+=" odd-col":i+=" even-col",e.cls=(e.cls||"")+i+" center-element"}BI.each(e,(function(e,t){BI.isArray(t)?BI.each(t,(function(t,n){u[e][t]=BI._lazyCreateWidget(n)})):u[t.row][t.column]=BI._lazyCreateWidget(t)}));for(c=0;c<a;c++)for(var d=0;d<o;d++)u[c][d]||(u[c][d]=BI._lazyCreateWidget({type:"bi.layout"})),t=u[c][d],n=c,i=d,t instanceof BI.Widget?h(t.element,n,i):t.el instanceof BI.Widget?h(t.el.element,n,i):t.el?p(t.el,n,i):p(t,n,i),u[c][d].element.css({position:"absolute",top:l*c+"%",left:s*d+"%",right:100-s*(d+1)+"%",bottom:100-l*(c+1)+"%"}),this.addWidget(this._getChildName(c+"_"+d),u[c][d])},update:function(){},populate:function(e){BI.GridLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.grid",BI.GridLayout)},function(e,t){BI.HorizontalLayout=function(){},BI.shortcut("bi.horizontal",BI.HorizontalLayout)},function(e,t){BI.InlineLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.InlineLayout.superclass.props.apply(this,arguments),{baseCls:"bi-i",horizontalAlign:BI.HorizontalAlign.Left,verticalAlign:BI.VerticalAlign.Top,columnSize:[],hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){BI.InlineLayout.superclass.render.apply(this,arguments);var e=this.options;this.element.css({textAlign:e.horizontalAlign}),this.populate(e.items)},_addElement:function(e,t){var n=this.options,i=BI.InlineLayout.superclass._addElement.apply(this,arguments),r=n.columnSize.length>0?n.columnSize[e]:t.width>=1?null:t.width;if(n.columnSize.length>0&&t.width>=1&&n.columnSize[e]>=1&&n.columnSize[e]!==t.width&&(r=null),r>0&&i.element.width(r<1?(100*r).toFixed(1)+"%":r/BI.pixRatio+BI.pixUnit),i.element.css({position:"relative","vertical-align":n.verticalAlign}),i.element.addClass("i-item"),"fill"===r||""===r){for(var a=n.hgap+(t.lgap||0)+(t.hgap||0),o=n.hgap+(t.rgap||0)+(t.hgap||0),s=0;s<e;s++)a+=n.hgap+n.lgap+n.rgap+(n.columnSize[s]||n.items[s].width);for(s=e+1;s<n.columnSize.length;s++)o+=n.hgap+n.lgap+n.rgap+(n.columnSize[s]||n.items[s].width);"fill"===r&&i.element.css("min-width","calc(100% - "+((a+o)/BI.pixRatio+BI.pixUnit)+")"),(n.horizontalAlign===BI.HorizontalAlign.Stretch||!0!==n.scrollable&&!0!==n.scrollx)&&i.element.css("max-width","calc(100% - "+((a+o)/BI.pixRatio+BI.pixUnit)+")")}if(n.verticalAlign===BI.VerticalAlign.Stretch){var l=n.vgap+(t.tgap||0)+(t.vgap||0),u=n.vgap+(t.bgap||0)+(t.vgap||0);i.element.css("height","calc(100% - "+((l+u)/BI.pixRatio+BI.pixUnit)+")")}return n.vgap+n.tgap+(t.tgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-top":(n.vgap+n.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-left":((0===e?n.hgap:0)+n.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-right":(n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-bottom":(n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i},resize:function(){this.stroke(this.options.items)},addItem:function(e){throw new Error("不能添加元素")},populate:function(e){BI.InlineLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.inline",BI.InlineLayout)},function(e,t){BI.LatticeLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.LatticeLayout.superclass.props.apply(this,arguments),{baseCls:"bi-lattice clearfix"})},render:function(){BI.LatticeLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},_addElement:function(e,t){var n=this.options,i=BI.LatticeLayout.superclass._addElement.apply(this,arguments);if(n.columnSize&&n.columnSize[e])var r=n.columnSize[e]/BI.sum(n.columnSize)*100+"%";else r=1/this.options.items.length*100+"%";return i.element.css({position:"relative",float:"left",width:r}),i},addItem:function(e){var t=BI.LatticeLayout.superclass.addItem.apply(this,arguments);return this.resize(),t},addItemAt:function(e){var t=BI.LatticeLayout.superclass.addItemAt.apply(this,arguments);return this.resize(),t},resize:function(){this.stroke(this.options.items)},populate:function(e){BI.LatticeLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.lattice",BI.LatticeLayout)},function(e,t){BI.TableLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.TableLayout.superclass.props.apply(this,arguments),{baseCls:"bi-t",scrolly:!0,columnSize:[],rowSize:30,hgap:0,vgap:0,items:[]})},render:function(){BI.TableLayout.superclass.render.apply(this,arguments),this.rows=0,this.populate(this.options.items)},_addElement:function(e,t){var n,i,r=this.options,a=[],o=0,s=0;function l(e,t,n){0===t&&e.addClass("first-row"),0===n&&e.addClass("first-col"),e.addClass(BI.isOdd(t+1)?"odd-row":"even-row"),e.addClass(BI.isOdd(n+1)?"odd-col":"even-col"),e.addClass("center-element")}function u(e,t,n){var i="";0===t&&(i+=" first-row"),0===n&&(i+=" first-col"),BI.isOdd(t+1)?i+=" odd-row":i+=" even-row",BI.isOdd(n+1)?i+=" odd-col":i+=" even-col",e.cls=(e.cls||"")+i+" center-element"}function c(e,t,n){e instanceof BI.Widget?l(e.element,t,n):e.el instanceof BI.Widget?l(e.el.element,t,n):e.el?u(e.el,t,n):u(e,t,n)}for(n=0;n<t.length&&BI.isNumber(r.columnSize[n]);n++)c(t[n],this.rows,n),a.push(BI.extend({top:0,bottom:0,left:r.columnSize[n]<1?(100*o).toFixed(1)+"%":o,width:r.columnSize[n]<1?(100*r.columnSize[n]).toFixed(1)+"%":r.columnSize[n]},t[n])),o+=r.columnSize[n]+(r.columnSize[n]<1?0:r.hgap);for(i=t.length-1;i>n;i--){if(!BI.isNumber(r.columnSize[i]))throw new Error("item with fill can only be one");c(t[i],this.rows,i),a.push(BI.extend({top:0,bottom:0,right:r.columnSize[i]<1?(100*s).toFixed(1)+"%":s,width:r.columnSize[i]<1?(100*r.columnSize[i]).toFixed(1)+"%":r.columnSize[i]},t[i])),s+=r.columnSize[i]+(r.columnSize[i]<1?0:r.hgap)}n>=0&&n<t.length&&(c(t[n],this.rows,n),a.push(BI.extend({top:0,bottom:0,left:o<1?(100*o).toFixed(1)+"%":o,right:s<1?(100*s).toFixed(1)+"%":s},t[n])));var h=BI._lazyCreateWidget({type:"bi.absolute",height:BI.isArray(r.rowSize)?r.rowSize[this.rows]:r.rowSize,items:a});return this.rows>0&&this.getWidgetByName(this._getChildName(this.rows-1)).element.css({"margin-bottom":r.vgap/BI.pixRatio+BI.pixUnit}),h.element.css({position:"relative"}),this.addWidget(this._getChildName(this.rows++),h),h},resize:function(){},addItem:function(e){if(!BI.isArray(e))throw new Error("item must be array");return BI.TableLayout.superclass.addItem.apply(this,arguments)},update:function(){},populate:function(e){BI.TableLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.table",BI.TableLayout)},function(e,t){BI.HTapeLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.HTapeLayout.superclass.props.apply(this,arguments),{baseCls:"bi-h-tape",verticalAlign:BI.VerticalAlign.Top,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0,columnSize:[],items:[]})},render:function(){BI.HTapeLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},resize:function(){this.stroke(this.options.items)},addItem:function(e){throw new Error("cannot be added")},stroke:function(e){var t=this,n=this.options;e=BI.compact(e),BI.each(e,(function(e,i){if(!BI.isEmptyObject(i)){if(t.hasWidget(t._getChildName(e)))r=t.getWidgetByName(t._getChildName(e));else{var r=BI._lazyCreateWidget(i);t.addWidget(t._getChildName(e),r)}r.element.css({position:"absolute",top:((i.vgap||0)+(i.tgap||0)+n.vgap+n.tgap)/BI.pixRatio+BI.pixUnit,bottom:((i.bgap||0)+(i.vgap||0)+n.vgap+n.bgap)/BI.pixRatio+BI.pixUnit}),n.verticalAlign===BI.VerticalAlign.Middle?r.element.css({marginTop:"auto",marginBottom:"auto"}):n.verticalAlign===BI.VerticalAlign.Bottom&&r.element.css({marginTop:"auto"})}}));var i={},r={};i[0]=0,r[e.length-1]=0,BI.any(e,(function(r,a){if(BI.isEmptyObject(a))return!0;var o=t.getWidgetByName(t._getChildName(r)),s=n.columnSize.length>0?n.columnSize[r]:a.width;if(n.columnSize.length>0&&a.width>=1&&n.columnSize[r]>=1&&n.columnSize[r]!==a.width&&(s=a.width),BI.isNull(i[r])){var l=n.columnSize.length>0?n.columnSize[r-1]:e[r-1].width;i[r]=i[r-1]+l+(e[r-1].lgap||0)+(e[r-1].rgap||0)+2*(e[r-1].hgap||0)+n.hgap+n.lgap+n.rgap}return s<1&&s>0?o.element.css({left:(100*i[r]).toFixed(1)+"%",width:(100*s).toFixed(1)+"%"}):o.element.css({left:(i[r]+(a.lgap||0)+(a.hgap||0)+n.hgap+n.lgap)/BI.pixRatio+BI.pixUnit,width:BI.isNumber(s)?s/BI.pixRatio+BI.pixUnit:""}),""===s||"fill"===s||void 0})),BI.backAny(e,(function(i,a){if(BI.isEmptyObject(a))return!0;var o=t.getWidgetByName(t._getChildName(i)),s=n.columnSize.length>0?n.columnSize[i]:a.width;if(BI.isNull(r[i])){var l=n.columnSize.length>0?n.columnSize[i+1]:e[i+1].width;r[i]=r[i+1]+l+(e[i+1].lgap||0)+(e[i+1].rgap||0)+2*(e[i+1].hgap||0)+n.hgap+n.lgap+n.rgap}return s<1&&s>0?o.element.css({right:(100*r[i]).toFixed(1)+"%",width:(100*s).toFixed(1)+"%"}):o.element.css({right:(r[i]+(a.rgap||0)+(a.hgap||0)+n.hgap+n.rgap)/BI.pixRatio+BI.pixUnit,width:BI.isNumber(s)?s/BI.pixRatio+BI.pixUnit:""}),""===s||"fill"===s||void 0}))},update:function(){var e;return BI.each(this._children,(function(t,n){e=n.update()||e})),e},populate:function(e){BI.HTapeLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.htape",BI.HTapeLayout),BI.VTapeLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.VTapeLayout.superclass.props.apply(this,arguments),{baseCls:"bi-v-tape-layout",horizontalAlign:BI.HorizontalAlign.Left,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0,rowSize:[],items:[]})},render:function(){BI.VTapeLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},resize:function(){this.stroke(this.options.items)},addItem:function(e){throw new Error("cannot be added")},stroke:function(e){var t=this,n=this.options;e=BI.compact(e),BI.each(e,(function(e,i){if(!BI.isEmptyObject(i)){if(t.hasWidget(t._getChildName(e)))r=t.getWidgetByName(t._getChildName(e));else{var r=BI._lazyCreateWidget(i);t.addWidget(t._getChildName(e),r)}r.element.css({position:"absolute",left:((i.lgap||0)+(i.hgap||0)+n.hgap+n.lgap)/BI.pixRatio+BI.pixUnit,right:((i.hgap||0)+(i.rgap||0)+n.hgap+n.rgap)/BI.pixRatio+BI.pixUnit}),n.horizontalAlign===BI.HorizontalAlign.Center?r.element.css({marginLeft:"auto",marginRight:"auto"}):n.horizontalAlign===BI.HorizontalAlign.Right&&r.element.css({marginLeft:"auto"})}}));var i={},r={};i[0]=0,r[e.length-1]=0,BI.any(e,(function(r,a){if(BI.isEmptyObject(a))return!0;var o=t.getWidgetByName(t._getChildName(r)),s=n.rowSize.length>0?n.rowSize[r]:a.height;if(n.rowSize.length>0&&a.height>=1&&n.rowSize[r]>=1&&n.rowSize[r]!==a.height&&(s=a.height),BI.isNull(i[r])){var l=n.rowSize.length>0?n.rowSize[r-1]:e[r-1].height;i[r]=i[r-1]+l+(e[r-1].tgap||0)+(e[r-1].bgap||0)+2*(e[r-1].vgap||0)+n.vgap+n.tgap+n.bgap}return s<1&&s>0?o.element.css({top:(100*i[r]).toFixed(1)+"%",height:(100*s).toFixed(1)+"%"}):o.element.css({top:(i[r]+(a.vgap||0)+(a.tgap||0)+n.vgap+n.tgap)/BI.pixRatio+BI.pixUnit,height:BI.isNumber(s)?s/BI.pixRatio+BI.pixUnit:""}),""===s||"fill"===s||void 0})),BI.backAny(e,(function(i,a){if(BI.isEmptyObject(a))return!0;var o=t.getWidgetByName(t._getChildName(i)),s=n.rowSize.length>0?n.rowSize[i]:a.height;if(BI.isNull(r[i])){var l=n.rowSize.length>0?n.rowSize[i+1]:e[i+1].height;r[i]=r[i+1]+l+(e[i+1].tgap||0)+(e[i+1].bgap||0)+2*(e[i+1].vgap||0)+n.vgap+n.tgap+n.bgap}return s<1&&s>0?o.element.css({bottom:(100*r[i]).toFixed(1)+"%",height:(100*s).toFixed(1)+"%"}):o.element.css({bottom:(r[i]+(a.vgap||0)+(a.bgap||0)+n.vgap+n.bgap)/BI.pixRatio+BI.pixUnit,height:BI.isNumber(s)?s/BI.pixRatio+BI.pixUnit:""}),""===s||"fill"===s||void 0}))},update:function(){},populate:function(e){BI.VTapeLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.vtape",BI.VTapeLayout)},function(e,t){BI.TdLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.TdLayout.superclass.props.apply(this,arguments),{baseCls:"bi-td",columnSize:[],rowSize:[],verticalAlign:BI.VerticalAlign.Middle,horizontalAlign:BI.HorizontalAlign.Stretch,hgap:0,vgap:0,tgap:0,bgap:0,lgap:0,rgap:0,items:[]})},render:function(){BI.TdLayout.superclass.render.apply(this,arguments);var e=this.options;this.$table=BI.Widget._renderEngine.createElement("<table>").attr({cellspacing:0,cellpadding:0}).css({position:"relative",width:e.horizontalAlign===BI.HorizontalAlign.Center||e.horizontalAlign===BI.HorizontalAlign.Stretch?"100%":"auto",height:e.verticalAlign!==BI.VerticalAlign.Top?"100%":"auto","border-spacing":"0px",border:"none","border-collapse":"separate"}),this.rows=0,this.populate(this.options.items)},_addElement:function(e,t){var n=this.options;function i(e,t,n){0===t&&e.addClass("first-row"),0===n&&e.addClass("first-col"),e.addClass(BI.isOdd(t+1)?"odd-row":"even-row"),e.addClass(BI.isOdd(n+1)?"odd-col":"even-col"),e.addClass("center-element")}function r(e,t,n){var i="";0===t&&(i+=" first-row"),0===n&&(i+=" first-col"),BI.isOdd(t+1)?i+=" odd-row":i+=" even-row",BI.isOdd(n+1)?i+=" odd-col":i+=" even-col",e.cls=(e.cls||"")+i+" center-element"}function a(e,t,n){e instanceof BI.Widget?i(e.element,t,n):e.el instanceof BI.Widget?i(e.el.element,t,n):e.el?r(e.el,t,n):r(e,t,n)}for(var o=""===n.rowSize[e]?"":n.rowSize[e]<1?(100*n.rowSize[e]).toFixed(1)+"%":n.rowSize[e],s=BI._lazyCreateWidget({type:"bi.default",tagName:"tr",height:o,css:{"max-height":BI.isNumber(n.rowSize[e])?n.rowSize[e]<=1?o:o/BI.pixRatio+BI.pixUnit:o}}),l=0;l<t.length;l++){var u=BI._lazyCreateWidget(t[l]);u.element.css({position:"relative",top:"0",left:"0",margin:"0px auto"});var c=t[l];n.vgap+n.tgap+(c.tgap||0)+(c.vgap||0)!==0&&u.element.css({"margin-top":(n.vgap+n.tgap+(c.tgap||0)+(c.vgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.lgap+(c.lgap||0)+(c.hgap||0)!==0&&u.element.css({"margin-left":((0===l?n.hgap:0)+n.lgap+(c.lgap||0)+(c.hgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.rgap+(c.rgap||0)+(c.hgap||0)!==0&&u.element.css({"margin-right":(n.hgap+n.rgap+(c.rgap||0)+(c.hgap||0))/BI.pixRatio+BI.pixUnit}),n.vgap+n.bgap+(c.bgap||0)+(c.vgap||0)!==0&&u.element.css({"margin-bottom":(n.vgap+n.bgap+(c.bgap||0)+(c.vgap||0))/BI.pixRatio+BI.pixUnit}),a(u,this.rows++,l);var h="",p=n.columnSize.length>0?n.columnSize[l]:c.width;p>0&&(h=p<1?(100*p).toFixed(1)+"%":p+(0===l?n.hgap:0)+n.hgap+n.lgap+n.rgap),""===p&&n.columnSize.indexOf("fill")>=0&&(h=2);var d=BI._lazyCreateWidget({type:"bi.default",width:h,tagName:"td",items:[u]});p>0&&d.element.css({"max-width":p<1?h:h/BI.pixRatio+BI.pixUnit}),d.element.css({position:"relative","vertical-align":n.verticalAlign,margin:"0",padding:"0",border:"none"}),s.addItem(d)}return this.addWidget(this._getChildName(e),s),s},appendFragment:function(e){this.$table.append(e),this.element.append(this.$table)},resize:function(){},addItem:function(e){if(!BI.isArray(e))throw new Error("item must be array");return BI.TdLayout.superclass.addItem.apply(this,arguments)},update:function(){},populate:function(e){BI.TdLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.td",BI.TdLayout)},function(e,t){BI.VerticalLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.VerticalLayout.superclass.props.apply(this,arguments),{baseCls:"bi-v",horizontalAlign:BI.HorizontalAlign.Stretch,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0,scrolly:!0})},render:function(){BI.VerticalLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},_addElement:function(e,t){var n=this.options,i=BI.VerticalLayout.superclass._addElement.apply(this,arguments);return i.element.css({position:"relative"}),n.vgap+n.tgap+(t.tgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-top":((0===e?n.vgap:0)+n.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-left":(n.hgap+n.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0)!==0&&i.element.css({"margin-right":(n.hgap+n.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0)!==0&&i.element.css({"margin-bottom":(n.vgap+n.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n.horizontalAlign===BI.HorizontalAlign.Center?i.element.css({marginLeft:"auto",marginRight:"auto"}):n.horizontalAlign===BI.HorizontalAlign.Right&&i.element.css({marginLeft:"auto"}),i},resize:function(){this.stroke(this.options.items)},populate:function(e){BI.VerticalLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.vertical",BI.VerticalLayout)},function(e,t){BI.WindowLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.WindowLayout.superclass.props.apply(this,arguments),{baseCls:"bi-window",columns:3,rows:2,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0,columnSize:[],rowSize:[],items:[]})},render:function(){BI.WindowLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},resize:function(){this.stroke(this.options.items)},addItem:function(e){throw new Error("cannot be added")},stroke:function(e){var t=this.options;function n(e,t,n){0===t&&e.addClass("first-row"),0===n&&e.addClass("first-col"),e.addClass(BI.isOdd(t+1)?"odd-row":"even-row"),e.addClass(BI.isOdd(n+1)?"odd-col":"even-col"),e.addClass("center-element")}function i(e,t,n){var i="";0===t&&(i+=" first-row"),0===n&&(i+=" first-col"),BI.isOdd(t+1)?i+=" odd-row":i+=" even-row",BI.isOdd(n+1)?i+=" odd-col":i+=" even-col",e.cls=(e.cls||"")+i+" center-element"}function r(e,t,r){e instanceof BI.Widget?n(e.element,t,r):e.el instanceof BI.Widget?n(e.el.element,t,r):e.el?i(e.el,t,r):i(e,t,r)}BI.isNumber(t.rowSize)&&(t.rowSize=BI.makeArray(t.items.length,1/t.items.length)),BI.isNumber(t.columnSize)&&(t.columnSize=BI.makeArray(t.items[0].length,1/t.items[0].length));for(var a=0;a<t.rows;a++)for(var o=0;o<t.columns;o++){if(!t.items[a][o])throw new Error("item be required");if(!this.hasWidget(this._getChildName(a+"_"+o)))(m=BI._lazyCreateWidget(t.items[a][o])).element.css({position:"absolute"}),this.addWidget(this._getChildName(a+"_"+o),m)}var s={},l={},u={},c={};s[0]=0,u[0]=0,l[t.columns-1]=0,c[t.rows-1]=0;for(a=0;a<t.rows;a++){for(o=0;o<t.columns;o++){var h=this.getWidgetByName(this._getChildName(a+"_"+o));BI.isNull(u[a])&&(u[a]=u[a-1]+(t.rowSize[a-1]<1?t.rowSize[a-1]:t.rowSize[a-1]+t.vgap+t.bgap));var p=u[a]<=1?(100*u[a]).toFixed(1)+"%":(u[a]+t.vgap+t.tgap)/BI.pixRatio+BI.pixUnit,d="";BI.isNumber(t.rowSize[a])&&(d=t.rowSize[a]<=1?(100*t.rowSize[a]).toFixed(1)+"%":t.rowSize[a]/BI.pixRatio+BI.pixUnit),h.element.css({top:p,height:d}),r(h,a,o)}if(!BI.isNumber(t.rowSize[a]))break}for(a=t.rows-1;a>=0;a--){for(o=0;o<t.columns;o++){h=this.getWidgetByName(this._getChildName(a+"_"+o));BI.isNull(c[a])&&(c[a]=c[a+1]+(t.rowSize[a+1]<1?t.rowSize[a+1]:t.rowSize[a+1]+t.vgap+t.tgap));var f=c[a]<=1?(100*c[a]).toFixed(1)+"%":(c[a]+t.vgap+t.bgap)/BI.pixRatio+BI.pixUnit;d="";BI.isNumber(t.rowSize[a])&&(d=t.rowSize[a]<=1?(100*t.rowSize[a]).toFixed(1)+"%":t.rowSize[a]/BI.pixRatio+BI.pixUnit),h.element.css({bottom:f,height:d}),r(h,a,o)}if(!BI.isNumber(t.rowSize[a]))break}for(o=0;o<t.columns;o++){for(a=0;a<t.rows;a++){h=this.getWidgetByName(this._getChildName(a+"_"+o));BI.isNull(s[o])&&(s[o]=s[o-1]+(t.columnSize[o-1]<1?t.columnSize[o-1]:t.columnSize[o-1]+t.hgap+t.rgap));var g=s[o]<=1?(100*s[o]).toFixed(1)+"%":(s[o]+t.hgap+t.lgap)/BI.pixRatio+BI.pixUnit,m="";BI.isNumber(t.columnSize[o])&&(m=t.columnSize[o]<=1?(100*t.columnSize[o]).toFixed(1)+"%":t.columnSize[o]/BI.pixRatio+BI.pixUnit),h.element.css({left:g,width:m}),r(h,a,o)}if(!BI.isNumber(t.columnSize[o]))break}for(o=t.columns-1;o>=0;o--){for(a=0;a<t.rows;a++){h=this.getWidgetByName(this._getChildName(a+"_"+o));BI.isNull(l[o])&&(l[o]=l[o+1]+(t.columnSize[o+1]<1?t.columnSize[o+1]:t.columnSize[o+1]+t.hgap+t.lgap));var I=l[o]<=1?(100*l[o]).toFixed(1)+"%":(l[o]+t.hgap+t.rgap)/BI.pixRatio+BI.pixUnit;m="";BI.isNumber(t.columnSize[o])&&(m=t.columnSize[o]<=1?(100*t.columnSize[o]).toFixed(1)+"%":t.columnSize[o]/BI.pixRatio+BI.pixUnit),h.element.css({right:I,width:m}),r(h,a,o)}if(!BI.isNumber(t.columnSize[o]))break}},update:function(){},populate:function(e){BI.WindowLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.window",BI.WindowLayout)},function(e,t){BI.CenterLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.CenterLayout.superclass.props.apply(this,arguments),{baseCls:"bi-center",hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){BI.CenterLayout.superclass.render.apply(this,arguments);var e=this,t=this.options,n=[],i=t.items;return BI.each(i,(function(e){n.push({column:e,row:0,el:BI._lazyCreateWidget({type:"bi.default",cls:"center-element "+(0===e?"first-element ":"")+(e===i.length-1?"last-element":"")})})})),BI.each(i,(function(e,i){if(i){var r=BI._lazyCreateWidget(i);r.element.css({position:"absolute",left:(t.hgap+t.lgap)/BI.pixRatio+BI.pixUnit,right:(t.hgap+t.rgap)/BI.pixRatio+BI.pixUnit,top:(t.vgap+t.tgap)/BI.pixRatio+BI.pixUnit,bottom:(t.vgap+t.bgap)/BI.pixRatio+BI.pixUnit,width:"auto",height:"auto"}),n[e].el.addItem(r)}})),{type:"bi.grid",ref:function(t){e.wrapper=t},columns:n.length,rows:1,items:n}},resize:function(){},addItem:function(e){throw new Error("cannot be added")},update:function(e){return this.wrapper.update(e)},populate:function(e){this.wrapper.populate.apply(this.wrapper,arguments)}}),BI.shortcut("bi.center",BI.CenterLayout)},function(e,t){BI.FloatCenterLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.FloatCenterLayout.superclass.props.apply(this,arguments),{baseCls:"bi-float-center",hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){BI.FloatCenterLayout.superclass.render.apply(this,arguments);var e=this,t=this.options,n=t.items,i=[],r=100/n.length;return BI.each(n,(function(e){var t=BI._lazyCreateWidget({type:"bi.default"});t.element.addClass("center-element "+(0===e?"first-element ":"")+(e===n.length-1?"last-element":"")).css({width:r+"%",height:"100%"}),i.push({el:t})})),BI.each(n,(function(e,n){if(n){var r=BI._lazyCreateWidget(n);r.element.css({position:"absolute",left:(t.hgap+t.lgap)/BI.pixRatio+BI.pixUnit,right:(t.hgap+t.rgap)/BI.pixRatio+BI.pixUnit,top:(t.vgap+t.tgap)/BI.pixRatio+BI.pixUnit,bottom:(t.vgap+t.bgap)/BI.pixRatio+BI.pixUnit,width:"auto",height:"auto"}),i[e].el.addItem(r)}})),{type:"bi.left",ref:function(t){e.wrapper=t},items:i}},resize:function(){},addItem:function(e){throw new Error("cannot be added")},update:function(e){return this.wrapper.update(e)},populate:function(e){this.wrapper.populate.apply(this.wrapper,arguments)}}),BI.shortcut("bi.float_center",BI.FloatCenterLayout)},function(e,t){BI.HorizontalCenterLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.HorizontalCenterLayout.superclass.props.apply(this,arguments),{baseCls:"bi-h-center",hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){BI.HorizontalCenterLayout.superclass.render.apply(this,arguments);var e=this,t=this.options,n=t.items,i=[];return BI.each(n,(function(e){i.push({column:e,row:0,el:BI._lazyCreateWidget({type:"bi.default",cls:"center-element "+(0===e?"first-element ":"")+(e===n.length-1?"last-element":"")})})})),BI.each(n,(function(e,n){if(n){var r=BI._lazyCreateWidget(n);r.element.css({position:"absolute",left:(t.hgap+t.lgap)/BI.pixRatio+BI.pixUnit,right:(t.hgap+t.rgap)/BI.pixRatio+BI.pixUnit,top:(t.vgap+t.tgap)/BI.pixRatio+BI.pixUnit,bottom:(t.vgap+t.bgap)/BI.pixRatio+BI.pixUnit,width:"auto"}),i[e].el.addItem(r)}})),{type:"bi.grid",ref:function(t){e.wrapper=t},columns:i.length,rows:1,items:i}},resize:function(){},addItem:function(e){throw new Error("cannot be added")},update:function(e){return this.wrapper.update(e)},populate:function(e){this.wrapper.populate.apply(this.wrapper,arguments)}}),BI.shortcut("bi.horizontal_center",BI.HorizontalCenterLayout)},function(e,t){BI.VerticalCenterLayout=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.VerticalCenterLayout.superclass.props.apply(this,arguments),{baseCls:"bi-v-center",hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){BI.VerticalCenterLayout.superclass.render.apply(this,arguments);var e=this,t=this.options,n=t.items,i=[];return BI.each(n,(function(e){i.push({column:0,row:e,el:BI._lazyCreateWidget({type:"bi.default",cls:"center-element "+(0===e?"first-element ":"")+(e===n.length-1?"last-element":"")})})})),BI.each(n,(function(e,n){if(n){var r=BI._lazyCreateWidget(n);r.element.css({position:"absolute",left:(t.hgap+t.lgap)/BI.pixRatio+BI.pixUnit,right:(t.hgap+t.rgap)/BI.pixRatio+BI.pixUnit,top:(t.vgap+t.tgap)/BI.pixRatio+BI.pixUnit,bottom:(t.vgap+t.bgap)/BI.pixRatio+BI.pixUnit,height:"auto"}),i[e].el.addItem(r)}})),{type:"bi.grid",ref:function(t){e.wrapper=t},columns:1,rows:i.length,items:i}},resize:function(){},addItem:function(e){throw new Error("cannot be added")},update:function(e){return this.wrapper.update(e)},populate:function(e){this.wrapper.populate.apply(this.wrapper,arguments)}}),BI.shortcut("bi.vertical_center",BI.VerticalCenterLayout)},function(e,t){BI.prepares.push((function(){BI.Resizers=new BI.ResizeController,BI.Layers=new BI.LayerController,BI.Maskers=new BI.MaskersController,BI.Bubbles=new BI.BubblesController,BI.Tooltips=new BI.TooltipsController,BI.Popovers=new BI.PopoverController,BI.Broadcasts=new BI.BroadcastController,BI.StyleLoaders=new BI.StyleLoaderManager}))},function(e,t){BI.Pane=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.Pane.superclass._defaultConfig.apply(this,arguments),{_baseCls:"bi-pane",tipText:BI.i18nText("BI-No_Selected_Item"),loadingText:"",loadingSize:"small",overlap:!0,onLoaded:BI.emptyFn})},_assertTip:function(){var e=this,t=this.options;this._tipText||BI.createWidget({type:"bi.absolute_center_adapt",element:this,items:[{type:"bi.label",ref:function(t){e._tipText=t},cls:"bi-tips",text:t.tipText,height:25}]})},loading:function(){var e=this.options,t=BI.isIE(),n=BI.createWidget({type:"bi.horizontal",cls:"bi-loading-widget"+(t?" wave-loading hack":""),height:this._getSize(60),width:this._getSize(60),hgap:this._getSize(10),vgap:2.5,items:t?[]:[{type:"bi.layout",cls:"animate-rect rect1",height:this._getSize(50),width:this._getSize(5)},{type:"bi.layout",cls:"animate-rect rect2",height:this._getSize(50),width:this._getSize(5)},{type:"bi.layout",cls:"animate-rect rect3",height:this._getSize(50),width:this._getSize(5)}]});this.setTipVisible(!1),!0===e.overlap?(BI.Layers.has(this.getName())||BI.createWidget({type:"bi.center_adapt",cls:"loading-container",items:this._getLoadingTipItems(n),element:BI.Layers.make(this.getName(),this)}),BI.Layers.show(this.getName())):BI.isNull(this._loading)&&(n.element.css("zIndex",1),BI.createWidget({type:"bi.center_adapt",element:this,cls:"loading-container",items:this._getLoadingTipItems(n)})),this.fireEvent(BI.Pane.EVENT_LOADING),this.element.addClass("loading-status")},_getSize:function(e){return Math.ceil(e/("small"===this.options.loadingSize?2:1))},_getLoadingTipItems:function(e){var t=this,n=this.options,i=[{type:"bi.horizontal_adapt",items:[e]}];return BI.isNotEmptyString(n.loadingText)&&i.push({type:"bi.text",text:n.loadingText,tgap:this._getSize(10)}),[{type:"bi.vertical",ref:function(e){t._loading=e},items:i}]},loaded:function(){var e=this.options;BI.Layers.remove(this.getName()),this._loading&&this._loading.destroy(),e.onLoaded(),this.fireEvent(BI.Pane.EVENT_LOADED),this.element.removeClass("loading-status")},check:function(){this.setTipVisible(BI.isEmpty(this.options.items))},setTipVisible:function(e){!0===e?(this._assertTip(),this._tipText.setVisible(!0)):this._tipText&&this._tipText.setVisible(!1)},populate:function(e){this.options.items=e||[],this.check()}}),BI.Pane.EVENT_LOADED="EVENT_LOADED",BI.Pane.EVENT_LOADING="EVENT_LOADING"},function(e,t){BI.CollectionView=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.CollectionView.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-collection",overflowX:!0,overflowY:!0,cellSizeAndPositionGetter:BI.emptyFn,horizontalOverscanSize:0,verticalOverscanSize:0,scrollLeft:0,scrollTop:0,items:[]})},_init:function(){BI.CollectionView.superclass._init.apply(this,arguments);var e=this,t=this.options;this.renderedCells=[],this.renderedKeys=[],this.renderRange={},this._scrollLock=!1,this._debounceRelease=BI.debounce((function(){e._scrollLock=!1}),1e3/60),this.container=BI._lazyCreateWidget({type:"bi.absolute"}),this.element.scroll((function(){!0!==e._scrollLock&&(t.scrollLeft=e.element.scrollLeft(),t.scrollTop=e.element.scrollTop(),e._calculateChildrenToRender(),e.fireEvent(BI.CollectionView.EVENT_SCROLL,{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}))})),BI._lazyCreateWidget({type:"bi.vertical",element:this,scrollable:!0===t.overflowX&&!0===t.overflowY,scrolly:!1===t.overflowX&&!0===t.overflowY,scrollx:!0===t.overflowX&&!1===t.overflowY,items:[this.container]}),t.items.length>0&&(this._calculateSizeAndPositionData(),this._populate())},mounted:function(){var e=this.options;0===e.scrollLeft&&0===e.scrollTop||(this.element.scrollTop(e.scrollTop),this.element.scrollLeft(e.scrollLeft))},_calculateSizeAndPositionData:function(){for(var e=this.options,t=[],n=new BI.SectionManager,i=0,r=0,a=0,o=e.items.length;a<o;a++){var s=e.cellSizeAndPositionGetter(a);if(null==s.height||isNaN(s.height)||null==s.width||isNaN(s.width)||null==s.x||isNaN(s.x)||null==s.y||isNaN(s.y))throw Error();i=Math.max(i,s.y+s.height),r=Math.max(r,s.x+s.width),s.index=a,t[a]=s,n.registerCell(s,a)}this._cellMetadata=t,this._sectionManager=n,this._height=i,this._width=r},_cellRenderers:function(e,t,n,i){return this._lastRenderedCellIndices=this._sectionManager.getCellIndices(e,t,n,i),this._cellGroupRenderer()},_cellGroupRenderer:function(){var e=this,t=(this.options,[]);return BI.each(this._lastRenderedCellIndices,(function(n,i){var r=e._sectionManager.getCellMetadata(i);t.push(r)})),t},_calculateChildrenToRender:function(){var e=this,t=this.options,n=BI.clamp(t.scrollLeft,0,this._getMaxScrollLeft()),i=BI.clamp(t.scrollTop,0,this._getMaxScrollTop()),r=Math.max(0,n-t.horizontalOverscanSize),a=Math.max(0,i-t.verticalOverscanSize),o=Math.min(this._width,n+t.width+t.horizontalOverscanSize),s=Math.min(this._height,i+t.height+t.verticalOverscanSize);if(o>0&&s>0){if(a>=this.renderRange.minY&&s<=this.renderRange.maxY&&r>=this.renderRange.minX&&o<=this.renderRange.maxX)return;for(var l=this._cellRenderers(s-a,o-r,r,a),u=[],c={},h={},p={},d={},f=0,g=l.length;f<g;f++){p[(C=l[f]).x]=C.x,p[C.x+C.width]=C.x+C.width,d[C.y]=C.y,d[C.y+C.height]=C.y+C.height}p=BI.toArray(p),d=BI.toArray(d);var m=BI.invert(p),I=BI.invert(d),B={},_={},E={},b={},y=function(e,t){null==e[t]&&(e[t]=Number.MAX_VALUE)},v=function(e,t){null==e[t]&&(e[t]=0)};for(f=0,g=l.length;f<g;f++){var T,C=l[f],N=this.renderedKeys[C.index]&&this.renderedKeys[C.index][1];N>=0?(C.width!==this.renderedCells[N]._width&&(this.renderedCells[N]._width=C.width,this.renderedCells[N].el.setWidth(C.width)),C.height!==this.renderedCells[N]._height&&(this.renderedCells[N]._height=C.height,this.renderedCells[N].el.setHeight(C.height)),this.renderedCells[N]._left!==C.x&&this.renderedCells[N].el.element.css("left",C.x/BI.pixRatio+BI.pixUnit),this.renderedCells[N]._top!==C.y&&this.renderedCells[N].el.element.css("top",C.y/BI.pixRatio+BI.pixUnit),u.push(T=this.renderedCells[N])):(T=BI._lazyCreateWidget(BI.extend({type:"bi.label",width:C.width,height:C.height},t.items[C.index],{cls:(t.items[C.index].cls||"")+" collection-cell"+(0===C.y?" first-row":"")+(0===C.x?" first-col":""),_left:C.x,_top:C.y})),u.push({el:T,left:C.x,top:C.y,_left:C.x,_top:C.y,_width:C.width,_height:C.height}));for(var V=0|I[C.y],S=0|I[C.y+C.height],x=V;x<=S;x++){var w=d[x];y(B,w),v(_,w),B[w]=Math.min(B[w],C.x),_[w]=Math.max(_[w],C.x+C.width)}var A=0|m[C.x],L=0|m[C.x+C.width];for(x=A;x<=L;x++){var k=p[x];y(E,k),v(b,k),E[k]=Math.min(E[k],C.y),b[k]=Math.max(b[k],C.y+C.height)}c[C.index]=[C.index,f],h[f]=T}var D={},M={},P=[];BI.each(c,(function(t,n){e.renderedKeys[t]?D[t]=n:M[t]=n})),BI.each(this.renderedKeys,(function(e,t){D[e]||M[e]||P.push(t[1])})),BI.each(P,(function(t,n){e.renderedCells[n].el._destroy()}));var R=[];BI.each(M,(function(e,t){R.push(u[t[1]])})),this.container.addItems(R),this.container._children=h,this.container.attr("items",u),this.renderedCells=u,this.renderedKeys=c;var H=BI.min(B),O=BI.max(_),F=BI.max(E),Y=BI.min(b);this.renderRange={minX:H,minY:F,maxX:O,maxY:Y}}},_getMaxScrollLeft:function(){return Math.max(0,this._width-this.options.width+(this.options.overflowX?BI.DOM.getScrollWidth():0))},_getMaxScrollTop:function(){return Math.max(0,this._height-this.options.height+(this.options.overflowY?BI.DOM.getScrollWidth():0))},_populate:function(e){var t=this.options;if(this._reRange(),e&&e!==this.options.items&&(this.options.items=e,this._calculateSizeAndPositionData()),t.items.length>0){this.container.setWidth(this._width),this.container.setHeight(this._height),this._calculateChildrenToRender();try{this.element.scrollTop(t.scrollTop),this.element.scrollLeft(t.scrollLeft)}catch(n){}}},setScrollLeft:function(e){this.options.scrollLeft!==e&&(this._scrollLock=!0,this.options.scrollLeft=BI.clamp(e||0,0,this._getMaxScrollLeft()),this._debounceRelease(),this._calculateChildrenToRender(),this.element.scrollLeft(this.options.scrollLeft))},setScrollTop:function(e){this.options.scrollTop!==e&&(this._scrollLock=!0,this.options.scrollTop=BI.clamp(e||0,0,this._getMaxScrollTop()),this._debounceRelease(),this._calculateChildrenToRender(),this.element.scrollTop(this.options.scrollTop))},setOverflowX:function(e){var t=this;this.options.overflowX!==!!e&&(this.options.overflowX=!!e,BI.nextTick((function(){t.element.css({overflowX:e?"auto":"hidden"})})))},setOverflowY:function(e){var t=this;this.options.overflowY!==!!e&&(this.options.overflowY=!!e,BI.nextTick((function(){t.element.css({overflowY:e?"auto":"hidden"})})))},getScrollLeft:function(){return this.options.scrollLeft},getScrollTop:function(){return this.options.scrollTop},getMaxScrollLeft:function(){return this._getMaxScrollLeft()},getMaxScrollTop:function(){return this._getMaxScrollTop()},_reRange:function(){this.renderRange={}},_clearChildren:function(){this.container._children={},this.container.attr("items",[])},restore:function(){BI.each(this.renderedCells,(function(e,t){t.el._destroy()})),this._clearChildren(),this.renderedCells=[],this.renderedKeys=[],this.renderRange={},this._scrollLock=!1},populate:function(e){e&&e!==this.options.items&&this.restore(),this._populate(e)}}),BI.CollectionView.EVENT_SCROLL="EVENT_SCROLL",BI.shortcut("bi.collection_view",BI.CollectionView)},function(e,t){var n;n={},BI.Combo=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.Combo.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-combo"+(BI.isIE()?" hack":""),attributes:{tabIndex:-1},trigger:"click",toggle:!0,direction:"bottom",logic:{dynamic:!0},container:null,isDefaultInit:!1,destroyWhenHide:!1,hideWhenAnotherComboOpen:!1,isNeedAdjustHeight:!0,isNeedAdjustWidth:!0,stopEvent:!1,stopPropagation:!1,adjustLength:0,adjustXOffset:0,adjustYOffset:0,hideChecker:BI.emptyFn,offsetStyle:"left",el:{},popup:{},comboClass:"bi-combo-popup",hoverClass:"bi-combo-hover",belowMouse:!1})},_init:function(){BI.Combo.superclass._init.apply(this,arguments);var e=this,t=this.options;this._initCombo(),this._initPullDownAction(),this.combo.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){e.isEnabled()&&e.isValid()&&(t===BI.Events.EXPAND&&e._popupView(),t===BI.Events.COLLAPSE&&e._hideView(),t===BI.Events.EXPAND&&(e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e.fireEvent(BI.Combo.EVENT_EXPAND)),t===BI.Events.COLLAPSE&&(e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e.isViewVisible()&&e.fireEvent(BI.Combo.EVENT_COLLAPSE)),t===BI.Events.CLICK&&e.fireEvent(BI.Combo.EVENT_TRIGGER_CHANGE,i))})),e.element.on("mouseenter."+e.getName(),(function(n){e.isEnabled()&&e.isValid()&&e.combo.isEnabled()&&e.combo.isValid()&&e.element.addClass(t.hoverClass)})),e.element.on("mouseleave."+e.getName(),(function(n){e.isEnabled()&&e.isValid()&&e.combo.isEnabled()&&e.combo.isValid()&&e.element.removeClass(t.hoverClass)})),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("vertical",BI.extend(t.logic,{items:[{el:this.combo}]})))),t.isDefaultInit&&this._assertPopupView(),BI.Resizers.add(this.getName(),BI.bind((function(e){this.isViewVisible()&&(BI.isNotNull(e)?this._hideIf(e):this._hideView())}),this))},_toggle:function(e){this._assertPopupViewRender(),this.popupView.isVisible()?this._hideView(e):this.isEnabled()&&this._popupView(e)},_initPullDownAction:function(){var e=this,t=this.options,n=(this.options.trigger||"").split(","),i=function(e){t.stopEvent&&e.stopEvent(),t.stopPropagation&&e.stopPropagation()},r=!1;function a(n){e.isEnabled()&&e.isValid()&&e.combo.isEnabled()&&e.combo.isValid()&&!0===t.toggle&&(e._hideView(n),e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.COLLAPSE,"",e.combo),e.fireEvent(BI.Combo.EVENT_COLLAPSE)),e.popupView&&e.popupView.element.off("mouseenter."+e.getName()).off("mouseleave."+e.getName()),r=!1}BI.each(n,(function(n,o){switch(o){case"hover":e.element.on("mouseenter."+e.getName(),(function(t){e.isEnabled()&&e.isValid()&&e.combo.isEnabled()&&e.combo.isValid()&&(e._popupView(t),e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",e.combo),e.fireEvent(BI.Combo.EVENT_EXPAND))})),e.element.on("mouseleave."+e.getName(),(function(t){e.popupView&&(e.popupView.element.on("mouseenter."+e.getName(),(function(t){r=!0,e.popupView.element.on("mouseleave."+e.getName(),(function(e){a(e)})),e.popupView.element.off("mouseenter."+e.getName())})),BI.defer((function(){r||a(t)}),50))}));break;case"click":var s=BI.debounce((function(n){e.combo.element.__isMouseInBounds__(n)&&e.isEnabled()&&e.isValid()&&e.combo.isEnabled()&&e.combo.isValid()&&(t.toggle?e._toggle(n):e._popupView(n),e.isViewVisible()?(e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",e.combo),e.fireEvent(BI.Combo.EVENT_EXPAND)):(e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.COLLAPSE,"",e.combo),e.fireEvent(BI.Combo.EVENT_COLLAPSE)))}),BI.EVENT_RESPONSE_TIME,{leading:!0,trailing:!1});e.element.off(o+"."+e.getName()).on(o+"."+e.getName(),(function(e){s(e),i(e)}));break;case"click-hover":s=BI.debounce((function(t){e.combo.element.__isMouseInBounds__(t)&&e.isEnabled()&&e.isValid()&&e.combo.isEnabled()&&e.combo.isValid()&&(e._popupView(t),e.isViewVisible()&&(e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",e.combo),e.fireEvent(BI.Combo.EVENT_EXPAND)))}),BI.EVENT_RESPONSE_TIME,{leading:!0,trailing:!1}),e.element.off("click."+e.getName()).on("click."+e.getName(),(function(e){s(e),i(e)})),e.element.on("mouseleave."+e.getName(),(function(t){e.popupView&&(e.popupView.element.on("mouseenter."+e.getName(),(function(t){r=!0,e.popupView.element.on("mouseleave."+e.getName(),(function(e){a(e)})),e.popupView.element.off("mouseenter."+e.getName())})),BI.delay((function(){r||a(t)}),50))}))}}))},_initCombo:function(){this.combo=BI.createWidget(this.options.el,{value:this.options.value})},_assertPopupView:function(){var e=this,t=this.options;null==this.popupView&&(this.popupView=BI.createWidget(this.options.popup,{type:"bi.popup_view",value:t.value},this),this.popupView.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){t===BI.Events.CLICK&&(e.combo.setValue(e.getValue()),e.fireEvent(BI.Combo.EVENT_CHANGE,n,i)),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.popupView.setVisible(!1),BI.nextTick((function(){e.fireEvent(BI.Combo.EVENT_AFTER_INIT)})))},_assertPopupViewRender:function(){this._assertPopupView(),this._rendered||(BI.createWidget({type:"bi.vertical",scrolly:!1,element:this.options.container||this,items:[{el:this.popupView}]}),this._rendered=!0)},_hideIf:function(e,t){if(e&&(!0!==t&&this.element.find(e.target).length>0||this.popupView&&this.popupView.element.find(e.target).length>0||"CodeMirror-cursor"===e.target.className||BI.Widget._renderEngine.createElement(e.target).closest(".CodeMirror-hints").length>0)){var n=this.options.direction.split(",");(BI.contains(n,"innerLeft")||BI.contains(n,"innerRight"))&&(this.adjustWidth(),this.adjustHeight())}else if(!1!==this.options.hideChecker.apply(this,[e]))return this._hideView(),!0},_hideView:function(){this.fireEvent(BI.Combo.EVENT_BEFORE_HIDEVIEW),!0===this.options.destroyWhenHide?(this.popupView&&this.popupView.destroy(),this.popupView=null,this._rendered=!1):this.popupView&&this.popupView.invisible(),this.element.removeClass(this.options.comboClass),delete n[this.getName()],BI.Widget._renderEngine.createElement(document).unbind("mousedown."+this.getName()).unbind("mousewheel."+this.getName()),this.fireEvent(BI.Combo.EVENT_AFTER_HIDEVIEW)},_popupView:function(e){var t=this;this._assertPopupViewRender(),this.fireEvent(BI.Combo.EVENT_BEFORE_POPUPVIEW),this.popupView.css({left:-999999999,top:-99999999}),this.popupView.visible(),BI.each(n,(function(i,r){i!==t.getName()&&r&&!0===r._hideIf(e,!0)&&delete n[i]})),this.options.hideWhenAnotherComboOpen&&(n[this.getName()]=this),this.adjustWidth(e),this.adjustHeight(e),this.element.addClass(this.options.comboClass),BI.Widget._renderEngine.createElement(document).unbind("mousedown."+this.getName()).unbind("mousewheel."+this.getName()),BI.Widget._renderEngine.createElement(document).bind("mousedown."+this.getName(),BI.bind(this._hideIf,this)).bind("mousewheel."+this.getName(),BI.bind(this._hideIf,this)),this.fireEvent(BI.Combo.EVENT_AFTER_POPUPVIEW)},adjustWidth:function(e){var t=this.options;if(this.popupView&&!0===t.isNeedAdjustWidth){this.resetListWidth("");var n=this.popupView.element.outerWidth(),i=this.element.outerWidth()||t.width;n>i+80?i+=80:n>i&&(i=n),this.resetListWidth(i<100?100:i)}},adjustHeight:function(e){var t=this.options,n={};if(this.popupView){var i=this.popupView.isVisible();this.popupView.visible();var r=t.belowMouse&&BI.isNotNull(e)?{element:{offset:function(){return{left:e.pageX,top:e.pageY}},bounds:function(){return{x:e.offsetX,y:e.offsetY,width:0,height:24}},outerWidth:function(){return 0},outerHeight:function(){return 24}}}:this.combo;switch(t.direction){case"bottom":case"bottom,right":n=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset,t.adjustYOffset||t.adjustLength,t.isNeedAdjustHeight,["bottom","top","right","left"],t.offsetStyle);break;case"top":case"top,right":n=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset,t.adjustYOffset||t.adjustLength,t.isNeedAdjustHeight,["top","bottom","right","left"],t.offsetStyle);break;case"left":case"left,bottom":n=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset||t.adjustLength,t.adjustYOffset,t.isNeedAdjustHeight,["left","right","bottom","top"],t.offsetStyle);break;case"right":case"right,bottom":n=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset||t.adjustLength,t.adjustYOffset,t.isNeedAdjustHeight,["right","left","bottom","top"],t.offsetStyle);break;case"top,left":n=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset,t.adjustYOffset||t.adjustLength,t.isNeedAdjustHeight,["top","bottom","left","right"],t.offsetStyle);break;case"bottom,left":n=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset,t.adjustYOffset||t.adjustLength,t.isNeedAdjustHeight,["bottom","top","left","right"],t.offsetStyle);break;case"left,top":n=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset||t.adjustLength,t.adjustYOffset,t.isNeedAdjustHeight,["left","right","top","bottom"],t.offsetStyle);break;case"right,top":n=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset||t.adjustLength,t.adjustYOffset,t.isNeedAdjustHeight,["right","left","top","bottom"],t.offsetStyle);break;case"right,innerRight":n=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset||t.adjustLength,t.adjustYOffset,t.isNeedAdjustHeight,["right","left","innerRight","innerLeft","bottom","top"],t.offsetStyle);break;case"right,innerLeft":n=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset||t.adjustLength,t.adjustYOffset,t.isNeedAdjustHeight,["right","left","innerLeft","innerRight","bottom","top"],t.offsetStyle);break;case"innerRight":n=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset||t.adjustLength,t.adjustYOffset,t.isNeedAdjustHeight,["innerRight","innerLeft","right","left","bottom","top"],t.offsetStyle);break;case"innerLeft":n=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset||t.adjustLength,t.adjustYOffset,t.isNeedAdjustHeight,["innerLeft","innerRight","left","right","bottom","top"],t.offsetStyle);break;case"top,custom":case"custom,top":n=BI.DOM.getTopAdaptPosition(r,this.popupView,t.adjustYOffset||t.adjustLength,t.isNeedAdjustHeight);break;case"custom,bottom":case"bottom,custom":n=BI.DOM.getBottomAdaptPosition(r,this.popupView,t.adjustYOffset||t.adjustLength,t.isNeedAdjustHeight);break;case"left,custom":case"custom,left":delete(n=BI.DOM.getLeftAdaptPosition(r,this.popupView,t.adjustXOffset||t.adjustLength)).top,delete n.adaptHeight;break;case"custom,right":case"right,custom":delete(n=BI.DOM.getRightAdaptPosition(r,this.popupView,t.adjustXOffset||t.adjustLength)).top,delete n.adaptHeight}"adaptHeight"in n&&this.resetListHeight(n.adaptHeight),"left"in n&&this.popupView.element.css({left:n.left}),"top"in n&&this.popupView.element.css({top:n.top}),this.position=n,this.popupView.setVisible(i)}},resetListHeight:function(e){this._assertPopupView(),this.popupView.resetHeight&&this.popupView.resetHeight(e)},resetListWidth:function(e){this._assertPopupView(),this.popupView.resetWidth&&this.popupView.resetWidth(e)},populate:function(e){this._assertPopupView(),this.popupView.populate.apply(this.popupView,arguments),this.combo.populate&&this.combo.populate.apply(this.combo,arguments)},_setEnable:function(e){BI.Combo.superclass._setEnable.apply(this,arguments),!0===e?this.element.removeClass("base-disabled disabled"):!1===e&&this.element.addClass("base-disabled disabled"),!e&&this.element.removeClass(this.options.hoverClass),!e&&this.isViewVisible()&&this._hideView()},setValue:function(e){this.combo.setValue(e),BI.isNull(this.popupView)?this.options.popup.value=e:this.popupView.setValue(e)},getValue:function(){return BI.isNull(this.popupView)?this.options.popup.value:this.popupView.getValue()},isViewVisible:function(){return this.isEnabled()&&this.combo.isEnabled()&&!!this.popupView&&this.popupView.isVisible()},showView:function(e){this.isEnabled()&&this.combo.isEnabled()&&!this.isViewVisible()&&this._popupView(e)},hideView:function(){this._hideView()},getView:function(){return this.popupView},getPopupPosition:function(){return this.position},toggle:function(){this._toggle()},destroyed:function(){BI.Widget._renderEngine.createElement(document).unbind("click."+this.getName()).unbind("mousedown."+this.getName()).unbind("mousewheel."+this.getName()).unbind("mouseenter."+this.getName()).unbind("mousemove."+this.getName()).unbind("mouseleave."+this.getName()).unbind("blur."+this.getName()),BI.Resizers.remove(this.getName()),this.popupView&&this.popupView._destroy(),delete n[this.getName()]}}),BI.Combo.EVENT_TRIGGER_CHANGE="EVENT_TRIGGER_CHANGE",BI.Combo.EVENT_CHANGE="EVENT_CHANGE",BI.Combo.EVENT_EXPAND="EVENT_EXPAND",BI.Combo.EVENT_COLLAPSE="EVENT_COLLAPSE",BI.Combo.EVENT_AFTER_INIT="EVENT_AFTER_INIT",BI.Combo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.Combo.EVENT_AFTER_POPUPVIEW="EVENT_AFTER_POPUPVIEW",BI.Combo.EVENT_BEFORE_HIDEVIEW="EVENT_BEFORE_HIDEVIEW",BI.Combo.EVENT_AFTER_HIDEVIEW="EVENT_AFTER_HIDEVIEW",BI.shortcut("bi.combo",BI.Combo)},function(e,t){BI.Expander=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.Expander.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-expander",trigger:"click",toggle:!0,isDefaultInit:!1,el:{},popup:{},expanderClass:"bi-expander-popup",hoverClass:"bi-expander-hover"})},_init:function(){BI.Expander.superclass._init.apply(this,arguments);var e=this,t=this.options;this._expanded=!!t.el.open,this._initExpander(),this._initPullDownAction(),this.expander.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){e.isEnabled()&&e.isValid()&&(t===BI.Events.EXPAND&&e._popupView(),t===BI.Events.COLLAPSE&&e._hideView(),t===BI.Events.EXPAND&&(e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e.fireEvent(BI.Expander.EVENT_EXPAND)),t===BI.Events.COLLAPSE&&(e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e.isViewVisible()&&e.fireEvent(BI.Expander.EVENT_COLLAPSE)),t===BI.Events.CLICK&&e.fireEvent(BI.Expander.EVENT_TRIGGER_CHANGE,n,i))})),this.element.hover((function(){e.isEnabled()&&e.isValid()&&e.expander.isEnabled()&&e.expander.isValid()&&e.element.addClass(t.hoverClass)}),(function(){e.isEnabled()&&e.isValid()&&e.expander.isEnabled()&&e.expander.isValid()&&e.element.removeClass(t.hoverClass)})),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[{el:this.expander}]}),t.isDefaultInit&&this._assertPopupView(),!0===this.expander.isOpened()&&this._popupView()},_toggle:function(){this._assertPopupViewRender(),this.popupView.isVisible()?this._hideView():this.isEnabled()&&this._popupView()},_initPullDownAction:function(){var e=this,t=this.options,n=this.options.trigger.split(",");BI.each(n,(function(n,i){switch(i){case"hover":e.element[i]((function(t){e.isEnabled()&&e.isValid()&&e.expander.isEnabled()&&e.expander.isValid()&&(e._popupView(),e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",e.expander),e.fireEvent(BI.Expander.EVENT_EXPAND))}),(function(){e.isEnabled()&&e.isValid()&&e.expander.isEnabled()&&e.expander.isValid()&&t.toggle&&(e._hideView(),e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.COLLAPSE,"",e.expander),e.fireEvent(BI.Expander.EVENT_COLLAPSE))}));break;case"click":i&&e.element.off(i+"."+e.getName()).on(i+"."+e.getName(),BI.debounce((function(n){e.expander.element.__isMouseInBounds__(n)&&e.isEnabled()&&e.isValid()&&e.expander.isEnabled()&&e.expander.isValid()&&(t.toggle?e._toggle():e._popupView(),e.isExpanded()?(e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",e.expander),e.fireEvent(BI.Expander.EVENT_EXPAND)):(e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.COLLAPSE,"",e.expander),e.fireEvent(BI.Expander.EVENT_COLLAPSE)))}),BI.EVENT_RESPONSE_TIME,{leading:!0,trailing:!1}))}}))},_initExpander:function(){this.expander=BI.createWidget(this.options.el)},_assertPopupView:function(){var e=this,t=this.options;null==this.popupView&&(this.popupView=BI.createWidget(this.options.popup,{type:"bi.button_group",cls:"expander-popup",layouts:[{type:"bi.vertical",hgap:0,vgap:0}],value:t.value},this),this.popupView.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),t===BI.Events.CLICK&&e.fireEvent(BI.Expander.EVENT_CHANGE,n,i)})),this.popupView.setVisible(this.isExpanded()),BI.nextTick((function(){e.fireEvent(BI.Expander.EVENT_AFTER_INIT)})))},_assertPopupViewRender:function(){this._assertPopupView(),this._rendered||(BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[{el:this.popupView}]}),this._rendered=!0)},_hideView:function(){this.fireEvent(BI.Expander.EVENT_BEFORE_HIDEVIEW),this._expanded=!1,this.expander.setOpened(!1),this.popupView&&this.popupView.invisible(),this.element.removeClass(this.options.expanderClass),this.fireEvent(BI.Expander.EVENT_AFTER_HIDEVIEW)},_popupView:function(){this._assertPopupViewRender(),this.fireEvent(BI.Expander.EVENT_BEFORE_POPUPVIEW),this._expanded=!0,this.expander.setOpened(!0),this.popupView.visible(),this.element.addClass(this.options.expanderClass),this.fireEvent(BI.Expander.EVENT_AFTER_POPUPVIEW)},populate:function(e){this.popupView&&this.popupView.populate.apply(this.popupView,arguments),this.expander.populate&&this.expander.populate.apply(this.expander,arguments)},_setEnable:function(e){BI.Expander.superclass._setEnable.apply(this,arguments),!e&&this.element.removeClass(this.options.hoverClass),!e&&this.isViewVisible()&&this._hideView()},setValue:function(e){this.expander.setValue(e),BI.isNull(this.popupView)?this.options.popup.value=e:this.popupView.setValue(e)},getValue:function(){return BI.isNull(this.popupView)?this.options.popup.value:this.popupView.getValue()},isViewVisible:function(){return this.isEnabled()&&this.expander.isEnabled()&&!!this.popupView&&this.popupView.isVisible()},isExpanded:function(){return this._expanded},showView:function(){this.isEnabled()&&this.expander.isEnabled()&&this._popupView()},hideView:function(){this._hideView()},getView:function(){return this.popupView},getAllLeaves:function(){return this.popupView&&this.popupView.getAllLeaves()},getNodeById:function(e){return this.expander.options.id===e?this.expander:this.popupView&&this.popupView.getNodeById(e)},getNodeByValue:function(e){return this.expander.getValue()===e?this.expander:this.popupView&&this.popupView.getNodeByValue(e)},destroy:function(){BI.Expander.superclass.destroy.apply(this,arguments)}}),BI.Expander.EVENT_EXPAND="EVENT_EXPAND",BI.Expander.EVENT_COLLAPSE="EVENT_COLLAPSE",BI.Expander.EVENT_TRIGGER_CHANGE="EVENT_TRIGGER_CHANGE",BI.Expander.EVENT_CHANGE="EVENT_CHANGE",BI.Expander.EVENT_AFTER_INIT="EVENT_AFTER_INIT",BI.Expander.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.Expander.EVENT_AFTER_POPUPVIEW="EVENT_AFTER_POPUPVIEW",BI.Expander.EVENT_BEFORE_HIDEVIEW="EVENT_BEFORE_HIDEVIEW",BI.Expander.EVENT_AFTER_HIDEVIEW="EVENT_AFTER_HIDEVIEW",BI.shortcut("bi.expander",BI.Expander)},function(e,t){BI.ButtonGroup=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.ButtonGroup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-button-group",behaviors:{},items:[],value:"",chooseType:BI.Selection.Single,layouts:[{type:"bi.center",hgap:0,vgap:0}]})},_init:function(){BI.ButtonGroup.superclass._init.apply(this,arguments);var e=this.options,t={};BI.each(e.behaviors,(function(e,n){t[e]=BI.BehaviorFactory.createBehavior(e,{rule:n})})),this.behaviors=t,this.populate(e.items),(BI.isKey(e.value)||BI.isNotEmptyArray(e.value))&&this.setValue(e.value)},_createBtns:function(e){this.options;return BI.createWidgets(BI.createItems(e,{type:"bi.text_button"}))},_btnsCreator:function(e){var t=this,n=Array.prototype.slice.call(arguments),i=this.options,r=this._createBtns(e);return n[0]=r,BI.each(this.behaviors,(function(e,t){t.doBehavior.apply(t,n)})),BI.each(r,(function(e,n){n.on(BI.Controller.EVENT_CHANGE,(function(e,r,a){if(e===BI.Events.CLICK){switch(i.chooseType){case BI.ButtonGroup.CHOOSE_TYPE_SINGLE:t.setValue(n.getValue());break;case BI.ButtonGroup.CHOOSE_TYPE_NONE:t.setValue([])}t.fireEvent(BI.Controller.EVENT_CHANGE,arguments),t.fireEvent(BI.ButtonGroup.EVENT_CHANGE,r,a)}else t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),n.on(BI.Events.DESTROY,(function(){BI.remove(t.buttons,n)}))})),r},_packageBtns:function(e){for(var t=this.options,n=t.layouts.length-1;n>0;n--)e=BI.map(e,(function(e,i){return BI.extend({},t.layouts[n],{items:[BI.extend({},t.layouts[n].el,{el:i})]})}));return e},_packageSimpleItems:function(e){var t=this.options;return BI.map(t.items,(function(t,n){return BI.stripEL(n)===n?e[t]:BI.extend({},n,{el:e[t]})}))},_packageItems:function(e,t){return BI.createItems(BI.makeArrayByArray(e,{}),BI.clone(t))},_packageLayout:function(e){for(var t=this.options,n=BI.deepClone(t.layouts[0]),i=BI.formatEL(n).el;i&&i.items&&!BI.isEmpty(i.items);)i=BI.formatEL(i.items[0]).el;return i.items=e,n},_isSimpleLayout:function(){var e=this.options;return 1===e.layouts.length&&!BI.isArray(e.items[0])},doBehavior:function(){var e=Array.prototype.slice.call(arguments);e.unshift(this.buttons),BI.each(this.behaviors,(function(t,n){n.doBehavior.apply(n,e)}))},prependItems:function(e){this.options;var t=this._btnsCreator.apply(this,arguments);this.buttons=BI.concat(t,this.buttons),this._isSimpleLayout()&&this.layouts&&this.layouts.prependItems?this.layouts.prependItems(t):(e=this._packageItems(e,this._packageBtns(t)),this.layouts.prependItems(this._packageLayout(e).items))},addItems:function(e){this.options;var t=this._btnsCreator.apply(this,arguments);this.buttons=BI.concat(this.buttons,t),this._isSimpleLayout()&&this.layouts&&this.layouts.addItems?this.layouts.addItems(t):(e=this._packageItems(e,this._packageBtns(t)),this.layouts.addItems(this._packageLayout(e).items))},removeItemAt:function(e){BI.removeAt(this.buttons,e),this.layouts.removeItemAt(e)},removeItems:function(e){e=BI.isArray(e)?e:[e];var t=[];BI.each(this.buttons,(function(n,i){BI.deepContains(e,i.getValue())&&t.push(n)})),BI.removeAt(this.buttons,t),this.layouts.removeItemAt(t)},populate:function(e){e=e||[],this.empty(),this.options.items=e,this.buttons=this._btnsCreator.apply(this,arguments),e=this._isSimpleLayout()?this._packageSimpleItems(this.buttons):this._packageItems(e,this._packageBtns(this.buttons)),this.layouts=BI.createWidget(BI.extend({element:this},this._packageLayout(e)))},setNotSelectedValue:function(e){e=BI.isArray(e)?e:[e],BI.each(this.buttons,(function(t,n){BI.deepContains(e,n.getValue())?n.setSelected&&n.setSelected(!1):n.setSelected&&n.setSelected(!0)}))},setEnabledValue:function(e){e=BI.isArray(e)?e:[e],BI.each(this.buttons,(function(t,n){BI.deepContains(e,n.getValue())?n.setEnable(!0):n.setEnable(!1)}))},setValue:function(e){e=BI.isArray(e)?e:[e],BI.each(this.buttons,(function(t,n){BI.deepContains(e,n.getValue())?n.setSelected&&n.setSelected(!0):n.setSelected&&n.setSelected(!1)}))},getNotSelectedValue:function(){var e=[];return BI.each(this.buttons,(function(t,n){!n.isEnabled()||n.isSelected&&n.isSelected()||e.push(n.getValue())})),e},getValue:function(){var e=[];return BI.each(this.buttons,(function(t,n){n.isEnabled()&&n.isSelected&&n.isSelected()&&e.push(n.getValue())})),e},getAllButtons:function(){return this.buttons},getAllLeaves:function(){return this.buttons},getSelectedButtons:function(){var e=[];return BI.each(this.buttons,(function(t,n){n.isSelected&&n.isSelected()&&e.push(n)})),e},getNotSelectedButtons:function(){var e=[];return BI.each(this.buttons,(function(t,n){n.isSelected&&!n.isSelected()&&e.push(n)})),e},getIndexByValue:function(e){var t=-1;return BI.any(this.buttons,(function(n,i){if(i.isEnabled()&&i.getValue()===e)return t=n,!0})),t},getNodeById:function(e){var t;return BI.any(this.buttons,(function(n,i){if(i.isEnabled()&&i.options.id===e)return t=i,!0})),t},getNodeByValue:function(e){var t;return BI.any(this.buttons,(function(n,i){if(i.isEnabled()&&i.getValue()===e)return t=i,!0})),t},empty:function(){BI.ButtonGroup.superclass.empty.apply(this,arguments),this.options.items=[]},destroy:function(){BI.ButtonGroup.superclass.destroy.apply(this,arguments),this.options.items=[]}}),BI.extend(BI.ButtonGroup,{CHOOSE_TYPE_SINGLE:BI.Selection.Single,CHOOSE_TYPE_MULTI:BI.Selection.Multi,CHOOSE_TYPE_ALL:BI.Selection.All,CHOOSE_TYPE_NONE:BI.Selection.None,CHOOSE_TYPE_DEFAULT:BI.Selection.Default}),BI.ButtonGroup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.button_group",BI.ButtonGroup)},function(e,t){BI.ComboGroup=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.ComboGroup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-combo-group bi-list-item",trigger:"click,hover",direction:"right",adjustLength:0,isDefaultInit:!1,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,el:{type:"bi.text_button",text:"",value:""},children:[],popup:{el:{type:"bi.button_tree",chooseType:0,layouts:[{type:"bi.vertical"}]}}})},_init:function(){BI.ComboGroup.superclass._init.apply(this,arguments),this._populate(this.options.el)},_populate:function(e){var t=this,n=this.options,i=n.children;if(BI.isEmpty(i))throw new Error("ComboGroup构造错误");BI.each(i,(function(e,t){var i=BI.formatEL(t).el.children;t=BI.formatEL(t).el,BI.isEmpty(i)||(t.el=BI.clone(t),t.children=i,t.type="bi.combo_group",t.action=n.action,t.height=n.height,t.direction=n.direction,t.isDefaultInit=n.isDefaultInit,t.isNeedAdjustHeight=n.isNeedAdjustHeight,t.isNeedAdjustWidth=n.isNeedAdjustWidth,t.adjustLength=n.adjustLength,t.popup=n.popup)})),this.combo=BI.createWidget({type:"bi.combo",element:this,container:n.container,height:n.height,trigger:n.trigger,direction:n.direction,isDefaultInit:n.isDefaultInit,isNeedAdjustWidth:n.isNeedAdjustWidth,isNeedAdjustHeight:n.isNeedAdjustHeight,adjustLength:n.adjustLength,el:e,popup:BI.extend({},n.popup,{el:BI.extend({items:i},n.popup.el)})}),this.combo.on(BI.Controller.EVENT_CHANGE,(function(e,n,i){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&t.fireEvent(BI.ComboGroup.EVENT_CHANGE,i)}))},getValue:function(){return this.combo.getValue()},setValue:function(e){this.combo.setValue(e)}}),BI.ComboGroup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.combo_group",BI.ComboGroup)},function(e,t){BI.VirtualGroup=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.VirtualGroup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-virtual-group",items:[],layouts:[{type:"bi.center",hgap:0,vgap:0}]})},render:function(){var e=this.options;this.populate(e.items),BI.isKey(e.value)&&this.setValue(e.value)},_packageBtns:function(e){for(var t=this.options,n=this.buttonMap={},i=t.layouts.length-1;i>0;i--)e=BI.map(e,(function(e,r){var a=BI.stripEL(r);return BI.extend({},t.layouts[i],{items:[BI.extend({},t.layouts[i].el,{el:BI.extend({ref:function(e){BI.isKey(n[a.value])&&(n[a.value]=e)}},a)})]})}));return e},_packageLayout:function(e){for(var t=this.options,n=BI.deepClone(t.layouts[0]),i=BI.formatEL(n).el;i&&i.items&&!BI.isEmpty(i.items);)i=BI.formatEL(i.items[0]).el;return i.items=e,n},addItems:function(e){this.layouts.addItems(e)},prependItems:function(e){this.layouts.prependItems(e)},setValue:function(e){e=BI.isArray(e)?e:[e],BI.each(this.buttonMap,(function(t,n){n&&(e.deepContains(t)?n.setSelected&&n.setSelected(!0):n.setSelected&&n.setSelected(!1))}))},getNotSelectedValue:function(){var e=[];return BI.each(this.buttonMap,(function(t,n){n&&(!n.isEnabled()||n.isSelected&&n.isSelected()||e.push(n.getValue()))})),e},getValue:function(){var e=[];return BI.each(this.buttonMap,(function(t,n){n&&n.isEnabled()&&n.isSelected&&n.isSelected()&&e.push(n.getValue())})),e},populate:function(e){e=e||[],this.options.items=e,e=this._packageBtns(e),this.layouts?this.layouts.populate(e):this.layouts=BI.createWidget(BI.extend({element:this},this._packageLayout(e)))}}),BI.VirtualGroup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.virtual_group",BI.VirtualGroup)},function(e,t){BI.Loader=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.Loader.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-loader",direction:"top",isDefaultInit:!0,logic:{dynamic:!0,scrolly:!0},el:{type:"bi.button_group"},items:[],itemsCreator:BI.emptyFn,onLoaded:BI.emptyFn,count:!1,prev:!1,next:{},hasPrev:BI.emptyFn,hasNext:BI.emptyFn})},_prevLoad:function(){var e=this,t=this.options;this.prev.setLoading(),t.itemsCreator.apply(this,[{times:--this.times},function(){e.prev.setLoaded(),e.prependItems.apply(e,arguments)}])},_nextLoad:function(){var e=this,t=this.options;this.next.setLoading(),t.itemsCreator.apply(this,[{times:++this.times},function(){e.next.setLoaded(),e.addItems.apply(e,arguments)}])},_init:function(){BI.Loader.superclass._init.apply(this,arguments);var e=this,t=this.options;!1===t.itemsCreator&&(t.prev=!1,t.next=!1),!1!==t.prev&&(this.prev=BI.createWidget(BI.extend({type:"bi.loading_bar"},t.prev)),this.prev.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&e._prevLoad()}))),this.button_group=BI.createWidget(t.el,{type:"bi.button_group",chooseType:0,items:t.items,behaviors:{},layouts:[{type:"bi.vertical"}],value:t.value}),this.button_group.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),t===BI.Events.CLICK&&e.fireEvent(BI.Loader.EVENT_CHANGE,i)})),!1!==t.next&&(this.next=BI.createWidget(BI.extend({type:"bi.loading_bar"},t.next)),this.next.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&e._nextLoad()}))),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(t.direction),BI.extend({scrolly:!0},t.logic,{items:BI.LogicFactory.createLogicItemsByDirection(t.direction,this.prev,this.button_group,this.next)})))),t.isDefaultInit&&BI.isEmpty(t.items)&&BI.nextTick(BI.bind((function(){t.isDefaultInit&&BI.isEmpty(t.items)&&this._populate()}),this)),BI.isNotEmptyArray(t.items)&&this._populate(t.items)},hasPrev:function(){var e=this.options;return BI.isNumber(e.count)?this.count<e.count:!!e.hasPrev.apply(this,[{times:this.times,count:this.count}])},hasNext:function(){var e=this.options;return BI.isNumber(e.count)?this.count<e.count:!!e.hasNext.apply(this,[{times:this.times,count:this.count}])},prependItems:function(e){this.count+=e.length,!1!==this.next&&(this.hasPrev()?(this.options.items=this.options.items.concat(e),this.prev.setLoaded()):this.prev.setEnd()),this.button_group.prependItems.apply(this.button_group,arguments)},addItems:function(e){this.count+=e.length,BI.isObject(this.next)&&(this.hasNext()?(this.options.items=this.options.items.concat(e),this.next.setLoaded()):this.next.setEnd()),this.button_group.addItems.apply(this.button_group,arguments)},_populate:function(e){var t=this,n=this.options;return 0===arguments.length&&BI.isFunction(n.itemsCreator)?(n.itemsCreator.apply(this,[{times:1},function(){if(0===arguments.length)throw new Error("arguments can not be null!!!");t.populate.apply(t,arguments),n.onLoaded()}]),!1):(this.options.items=e,this.times=1,this.count=0,this.count+=e.length,BI.isObject(this.next)&&(this.hasNext()?this.next.setLoaded():this.next.invisible()),BI.isObject(this.prev)&&(this.hasPrev()?this.prev.setLoaded():this.prev.invisible()),!0)},populate:function(){this._populate.apply(this,arguments)&&this.button_group.populate.apply(this.button_group,arguments)},setNotSelectedValue:function(){this.button_group.setNotSelectedValue.apply(this.button_group,arguments)},getNotSelectedValue:function(){return this.button_group.getNotSelectedValue()},setValue:function(){this.button_group.setValue.apply(this.button_group,arguments)},getValue:function(){return this.button_group.getValue.apply(this.button_group,arguments)},getAllButtons:function(){return this.button_group.getAllButtons()},getAllLeaves:function(){return this.button_group.getAllLeaves()},getSelectedButtons:function(){return this.button_group.getSelectedButtons()},getNotSelectedButtons:function(){return this.button_group.getNotSelectedButtons()},getIndexByValue:function(e){return this.button_group.getIndexByValue(e)},getNodeById:function(e){return this.button_group.getNodeById(e)},getNodeByValue:function(e){return this.button_group.getNodeByValue(e)},empty:function(){this.button_group.empty(),BI.each([this.prev,this.next],(function(e,t){t&&t.setVisible(!1)}))},destroy:function(){BI.Loader.superclass.destroy.apply(this,arguments)}}),BI.Loader.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.loader",BI.Loader)},function(e,t){BI.Navigation=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.Navigation.superclass._defaultConfig.apply(this,arguments),{direction:"bottom",logic:{dynamic:!1},single:!1,showIndex:!1,tab:!1,cardCreator:function(e){return BI.createWidget()},afterCardCreated:BI.emptyFn,afterCardShow:BI.emptyFn})},render:function(){var e=this,t=this.options;this.tab=BI.createWidget(this.options.tab,{type:"bi.button_group"}),this.cardMap={},this.showIndex=0,this.layout=BI.createWidget({type:"bi.card"}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(t.direction),BI.extend({},t.logic,{items:BI.LogicFactory.createLogicItemsByDirection(t.direction,this.tab,this.layout)})))),new BI.ShowListener({eventObj:this.tab,cardLayout:this.layout,cardNameCreator:function(t){return e.showIndex+t},cardCreator:function(n){var i=t.cardCreator(n);return e.cardMap[n]=i,i},afterCardCreated:BI.bind(this.afterCardCreated,this),afterCardShow:BI.bind(this.afterCardShow,this)})},created:function(){var e=this.options;!1!==e.showIndex&&this.setSelect(e.showIndex)},_deleteOtherCards:function(e){var t=this;!0===this.options.single&&BI.each(this.cardMap,(function(n,i){n!==e+""&&(t.layout.deleteCardByName(n),delete t.cardMap[n])}))},afterCardCreated:function(e){var t=this;this.cardMap[e].on(BI.Controller.EVENT_CHANGE,(function(e,n,i){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&t.fireEvent(BI.Navigation.EVENT_CHANGE,i)})),this.options.afterCardCreated.apply(this,arguments)},afterCardShow:function(e){this.showIndex=e,this._deleteOtherCards(e),this.options.afterCardShow.apply(this,arguments)},populate:function(){var e=this.layout.getShowingCard();if(e)return e.populate.apply(e,arguments)},_assertCard:function(e){if(!this.layout.isCardExisted(e)){var t=this.options.cardCreator(e);this.cardMap[e]=t,this.layout.addCardByName(e,t),this.afterCardCreated(e)}},setSelect:function(e){this._assertCard(e),this.layout.showCardByName(e),this._deleteOtherCards(e),this.showIndex!==e&&(this.showIndex=e,BI.nextTick(BI.bind(this.afterCardShow,this,e)))},getSelect:function(){return this.showIndex},getSelectedCard:function(){if(BI.isKey(this.showIndex))return this.cardMap[this.showIndex]},getAllCard:function(){return BI.values(this.cardMap)},setValue:function(e){var t=this.layout.getShowingCard();t&&t.setValue(e)},getValue:function(){var e=this.layout.getShowingCard();if(e)return e.getValue()},empty:function(){this.layout.deleteAllCard(),this.cardMap={}},destroy:function(){BI.Navigation.superclass.destroy.apply(this,arguments)}}),BI.Navigation.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.navigation",BI.Navigation)},function(e,t){BI.Searcher=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.Searcher.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-searcher",lgap:0,rgap:0,tgap:0,bgap:0,vgap:0,hgap:0,isDefaultInit:!1,isAutoSearch:!0,isAutoSync:!0,chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,onSearch:function(e,t){t([])},el:{type:"bi.search_editor"},popup:{type:"bi.searcher_view"},adapter:null,masker:{offset:{}}})},_init:function(){BI.Searcher.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget(t.el,{type:"bi.search_editor"}),BI.createWidget({type:"bi.vertical",element:this,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap,vgap:t.vgap,hgap:t.hgap,items:[this.editor]}),t.isDefaultInit&&this._assertPopupView();var n=BI.debounce(BI.bind(this._search,this),BI.EVENT_RESPONSE_TIME,{leading:!0,trailing:!1});this.editor.on(BI.Controller.EVENT_CHANGE,(function(t){switch(t){case BI.Events.STARTEDIT:e._startSearch();break;case BI.Events.EMPTY:e._stopSearch();break;case BI.Events.CHANGE:n();break;case BI.Events.PAUSE:BI.endWith(this.getValue(),BI.BlankSplitChar)&&e._pauseSearch()}}))},_assertPopupView:function(){var e=this,t=this.options;(t.masker&&!BI.Maskers.has(this.getName())||!1===t.masker&&!this.popupView)&&(this.popupView=BI.createWidget(t.popup,{type:"bi.searcher_view",chooseType:t.chooseType}),this.popupView.on(BI.Controller.EVENT_CHANGE,(function(n,i,r){if(e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),n===BI.Events.CLICK){if(t.isAutoSync){var a=t.adapter&&t.adapter.getValue();switch(t.chooseType){case BI.ButtonGroup.CHOOSE_TYPE_SINGLE:t.adapter&&t.adapter.setValue([r.getValue()]);break;case BI.ButtonGroup.CHOOSE_TYPE_MULTI:r.isSelected()||t.adapter&&t.adapter.setValue(BI.deepWithout(a,r.getValue())),a.push(r.getValue()),t.adapter&&t.adapter.setValue(a)}}e.fireEvent(BI.Searcher.EVENT_CHANGE,i,r)}})),BI.nextTick((function(){e.fireEvent(BI.Searcher.EVENT_AFTER_INIT)}))),t.masker&&!BI.Maskers.has(this.getName())&&BI.Maskers.create(this.getName(),t.adapter,BI.extend({container:this,render:this.popupView},t.masker),this)},_startSearch:function(){this._assertPopupView(),this._stop=!1,this._isSearching=!0,this.fireEvent(BI.Searcher.EVENT_START),this.popupView.startSearch&&this.popupView.startSearch(),BI.nextTick((function(e){BI.Maskers.show(e)}),this.getName())},_pauseSearch:function(){this.options,this.getName();this._stop=!0,BI.nextTick((function(e){BI.Maskers.hide(e)}),this.getName()),!0===this._isSearching&&(this.popupView&&this.popupView.pauseSearch&&this.popupView.pauseSearch(),this.fireEvent(BI.Searcher.EVENT_PAUSE)),this._isSearching=!1},_stopSearch:function(){this.options;var e=this.getName();this._stop=!0,BI.Maskers.hide(e),!0===this._isSearching&&(this.popupView&&this.popupView.stopSearch&&this.popupView.stopSearch(),this.fireEvent(BI.Searcher.EVENT_STOP)),this._isSearching=!1},_search:function(){var e=this,t=this.options,n=this.editor.getValue();if(""!==n&&!this._stop){if(t.isAutoSearch){var i=t.adapter&&(t.adapter.getItems&&t.adapter.getItems()||t.adapter.attr("items"))||[],r=BI.Func.getSearchResult(i,n),a=r.match,o=r.find;return this.popupView.populate(o,a,n),t.isAutoSync&&t.adapter&&t.adapter.getValue&&this.popupView.setValue(t.adapter.getValue()),void e.fireEvent(BI.Searcher.EVENT_SEARCHING)}this.popupView.loading&&this.popupView.loading(),t.onSearch({times:1,keyword:n,selectedValues:t.adapter&&t.adapter.getValue()},(function(i,r){if(!e._stop){var a=[].slice.call(arguments);a.length>0&&a.push(n),BI.Maskers.show(e.getName()),e.popupView.populate.apply(e.popupView,a),t.isAutoSync&&t.adapter&&t.adapter.getValue&&e.popupView.setValue(t.adapter.getValue()),e.popupView.loaded&&e.popupView.loaded(),e.fireEvent(BI.Searcher.EVENT_SEARCHING)}}))}},_getLastSearchKeyword:function(){if(this.isValid()){var e=this.editor.getValue().split(/\u200b\s\u200b/);return BI.isEmptyString(e[e.length-1])&&(e=e.slice(0,e.length-1)),BI.isNull(e)?"":e[e.length-1]}},setAdapter:function(e){this.options.adapter=e,BI.Maskers.remove(this.getName())},doSearch:function(){this.isSearching()&&this._search()},stopSearch:function(){this._stopSearch();try{this.editor.blur()}catch(e){if(!this.editor.blur)throw new Error("editor没有实现blur方法")}finally{this.editor.setValue("")}},isSearching:function(){return this._isSearching},isViewVisible:function(){return this.editor.isEnabled()&&BI.Maskers.isVisible(this.getName())},getView:function(){return this.popupView},hasMatched:function(){return this._assertPopupView(),this.popupView.hasMatched()},adjustHeight:function(){BI.Maskers.has(this.getName())&&BI.Maskers.get(this.getName()).isVisible()&&BI.Maskers.show(this.getName())},adjustView:function(){this.isViewVisible()&&BI.Maskers.show(this.getName())},setValue:function(e){BI.isNull(this.popupView)?this.options.popup.value=e:this.popupView.setValue(e)},getKeyword:function(){return this._getLastSearchKeyword()},getKeywords:function(){return this.editor.getKeywords()},getValue:function(){var e=this.options;return e.isAutoSync&&e.adapter&&e.adapter.getValue?e.adapter.getValue():this.isSearching()?this.popupView.getValue():e.adapter&&e.adapter.getValue?e.adapter.getValue():BI.isNull(this.popupView)?e.popup.value:this.popupView.getValue()},populate:function(e,t,n){var i=this.options;this._assertPopupView(),this.popupView.populate.apply(this.popupView,arguments),i.isAutoSync&&i.adapter&&i.adapter.getValue&&this.popupView.setValue(i.adapter.getValue())},empty:function(){this.popupView&&this.popupView.empty()},destroyed:function(){BI.Maskers.remove(this.getName())}}),BI.Searcher.EVENT_CHANGE="EVENT_CHANGE",BI.Searcher.EVENT_START="EVENT_START",BI.Searcher.EVENT_STOP="EVENT_STOP",BI.Searcher.EVENT_PAUSE="EVENT_PAUSE",BI.Searcher.EVENT_SEARCHING="EVENT_SEARCHING",BI.Searcher.EVENT_AFTER_INIT="EVENT_AFTER_INIT",BI.shortcut("bi.searcher",BI.Searcher)},function(e,t){BI.Switcher=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.Switcher.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-switcher",direction:BI.Direction.Top,trigger:"click",toggle:!0,el:{},popup:{},adapter:null,masker:{},switcherClass:"bi-switcher-popup",hoverClass:"bi-switcher-hover"})},_init:function(){BI.Switcher.superclass._init.apply(this,arguments);var e=this,t=this.options;this._initSwitcher(),this._initPullDownAction(),this.switcher.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){e.isEnabled()&&e.isValid()&&(t===BI.Events.EXPAND&&e._popupView(),t===BI.Events.COLLAPSE&&e._hideView(),t===BI.Events.EXPAND&&(e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e.fireEvent(BI.Switcher.EVENT_EXPAND)),t===BI.Events.COLLAPSE&&(e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e.isViewVisible()&&e.fireEvent(BI.Switcher.EVENT_COLLAPSE)),t===BI.Events.CLICK&&e.fireEvent(BI.Switcher.EVENT_TRIGGER_CHANGE,n,i))})),this.element.hover((function(){e.isEnabled()&&e.switcher.isEnabled()&&e.element.addClass(t.hoverClass)}),(function(){e.isEnabled()&&e.switcher.isEnabled()&&e.element.removeClass(t.hoverClass)})),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[{el:this.switcher}]}),t.isDefaultInit&&this._assertPopupView()},_toggle:function(){this._assertPopupView(),this.isExpanded()?this._hideView():this.isEnabled()&&this._popupView()},_initPullDownAction:function(){var e=this,t=this.options,n=this.options.trigger.split(",");BI.each(n,(function(n,i){switch(i){case"hover":e.element[i]((function(t){e.isEnabled()&&e.switcher.isEnabled()&&(e._popupView(),e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",e.switcher),e.fireEvent(BI.Switcher.EVENT_EXPAND))}),(function(){e.isEnabled()&&e.switcher.isEnabled()&&t.toggle&&(e._hideView(),e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.COLLAPSE,"",e.switcher),e.fireEvent(BI.Switcher.EVENT_COLLAPSE))}));break;default:i&&e.element.off(i+"."+e.getName()).on(i+"."+e.getName(),BI.debounce((function(n){e.switcher.element.__isMouseInBounds__(n)&&e.isEnabled()&&e.switcher.isEnabled()&&(t.toggle?e._toggle():e._popupView(),e.isExpanded()?(e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",e.switcher),e.fireEvent(BI.Switcher.EVENT_EXPAND)):(e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.COLLAPSE,"",e.switcher),e.fireEvent(BI.Switcher.EVENT_COLLAPSE)))}),BI.EVENT_RESPONSE_TIME,{leading:!0,trailing:!1}))}}))},_initSwitcher:function(){this.switcher=BI.createWidget(this.options.el,{value:this.options.value})},_assertPopupView:function(){var e=this,t=this.options;this._created||(this.popupView=BI.createWidget(t.popup,{type:"bi.button_group",element:t.adapter&&BI.Maskers.create(this.getName(),t.adapter,BI.extend({container:this},t.masker)),cls:"switcher-popup",layouts:[{type:"bi.vertical",hgap:0,vgap:0}],value:t.value},this),this.popupView.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),t===BI.Events.CLICK&&e.fireEvent(BI.Switcher.EVENT_CHANGE,n,i)})),t.direction===BI.Direction.Custom||t.adapter||BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[{el:this.popupView}]}),this._created=!0,BI.nextTick((function(){e.fireEvent(BI.Switcher.EVENT_AFTER_INIT)})))},_hideView:function(){this.fireEvent(BI.Switcher.EVENT_BEFORE_HIDEVIEW);var e=this,t=this.options;t.adapter?BI.Maskers.hide(e.getName()):e.popupView&&e.popupView.setVisible(!1),BI.nextTick((function(){t.adapter?BI.Maskers.hide(e.getName()):e.popupView&&e.popupView.setVisible(!1),e.element.removeClass(t.switcherClass),e.fireEvent(BI.Switcher.EVENT_AFTER_HIDEVIEW)}))},_popupView:function(){var e=this,t=this.options;this._assertPopupView(),this.fireEvent(BI.Switcher.EVENT_BEFORE_POPUPVIEW),t.adapter?BI.Maskers.show(this.getName()):e.popupView.setVisible(!0),BI.nextTick((function(n){t.adapter?BI.Maskers.show(n):e.popupView.setVisible(!0),e.element.addClass(t.switcherClass),e.fireEvent(BI.Switcher.EVENT_AFTER_POPUPVIEW)}),this.getName())},_populate:function(){this._assertPopupView(),this.popupView.populate.apply(this.popupView,arguments)},populate:function(e){this._populate.apply(this,arguments),this.switcher.populate&&this.switcher.populate.apply(this.switcher,arguments)},_setEnable:function(e){BI.Switcher.superclass._setEnable.apply(this,arguments),!e&&this.isViewVisible()&&this._hideView()},setValue:function(e){this.switcher.setValue(e),BI.isNull(this.popupView)?this.options.popup.value=e:this.popupView.setValue(e)},getValue:function(){return BI.isNull(this.popupView)?this.options.popup.value:this.popupView.getValue()},setAdapter:function(e){this.options.adapter=e,BI.Maskers.remove(this.getName())},isViewVisible:function(){return this.isEnabled()&&this.switcher.isEnabled()&&(this.options.adapter?BI.Maskers.isVisible(this.getName()):this.popupView&&this.popupView.isVisible())},isExpanded:function(){return this.isViewVisible()},showView:function(){this.isEnabled()&&this.switcher.isEnabled()&&this._popupView()},hideView:function(){this._hideView()},getView:function(){return this.popupView},adjustView:function(){this.isViewVisible()&&BI.Maskers.show(this.getName())},getAllLeaves:function(){return this.popupView&&this.popupView.getAllLeaves()},getNodeById:function(e){return this.switcher.attr("id")===e?this.switcher:this.popupView&&this.popupView.getNodeById(e)},getNodeByValue:function(e){return this.switcher.getValue()===e?this.switcher:this.popupView&&this.popupView.getNodeByValue(e)},empty:function(){this.popupView&&this.popupView.empty()}}),BI.Switcher.EVENT_EXPAND="EVENT_EXPAND",BI.Switcher.EVENT_COLLAPSE="EVENT_COLLAPSE",BI.Switcher.EVENT_TRIGGER_CHANGE="EVENT_TRIGGER_CHANGE",BI.Switcher.EVENT_CHANGE="EVENT_CHANGE",BI.Switcher.EVENT_AFTER_INIT="EVENT_AFTER_INIT",BI.Switcher.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.Switcher.EVENT_AFTER_POPUPVIEW="EVENT_AFTER_POPUPVIEW",BI.Switcher.EVENT_BEFORE_HIDEVIEW="EVENT_BEFORE_HIDEVIEW",BI.Switcher.EVENT_AFTER_HIDEVIEW="EVENT_AFTER_HIDEVIEW",BI.shortcut("bi.switcher",BI.Switcher)},function(e,t){BI.Tab=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.Tab.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-tab",direction:"top",single:!1,logic:{dynamic:!1},showIndex:!1,tab:!1,cardCreator:function(e){return BI.createWidget()}})},render:function(){var e=this,t=this.options;BI.isObject(t.tab)&&(this.tab=BI.createWidget(this.options.tab,{type:"bi.button_group"}),this.tab.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}))),this.cardMap={},this.layout=BI.createWidget({type:"bi.card"}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(t.direction),BI.extend({},t.logic,{items:BI.LogicFactory.createLogicItemsByDirection(t.direction,this.tab,this.layout)})))),new BI.ShowListener({eventObj:this.tab,cardLayout:this.layout,cardCreator:function(n){var i=t.cardCreator.apply(e,arguments);return e.cardMap[n]=i,i},afterCardShow:function(t){e._deleteOtherCards(t),e.curr=t}}).on(BI.ShowListener.EVENT_CHANGE,(function(t){e.fireEvent(BI.Tab.EVENT_CHANGE,t,e)}))},_deleteOtherCards:function(e){var t=this;!0===this.options.single&&BI.each(this.cardMap,(function(n,i){n!==e+""&&(t.layout.deleteCardByName(n),delete t.cardMap[n])}))},_assertCard:function(e){if(!this.layout.isCardExisted(e)){var t=this.options.cardCreator(e);this.cardMap[e]=t,this.layout.addCardByName(e,t)}},created:function(){var e=this.options;!1!==e.showIndex&&this.setSelect(e.showIndex)},setSelect:function(e,t,n){this.tab&&this.tab.setValue(e),this._assertCard(e),this.layout.showCardByName(e,t,n),this._deleteOtherCards(e),this.curr!==e&&(this.curr=e)},removeTab:function(e){var t=this;this.options;BI.any(this.cardMap,(function(n,i){if(BI.isEqual(n,e+""))return t.layout.deleteCardByName(n),delete t.cardMap[n],!0}))},isCardExisted:function(e){return this.layout.isCardExisted(e)},getSelect:function(){return this.curr},getSelectedTab:function(){return this.layout.getShowingCard()},getTab:function(e){return this._assertCard(e),this.layout.getCardByName(e)},setValue:function(e){var t=this.layout.getShowingCard();t&&t.setValue(e)},getValue:function(){var e=this.layout.getShowingCard();if(e)return e.getValue()},populate:function(){var e=this.layout.getShowingCard();if(e)return e.populate&&e.populate.apply(e,arguments)},empty:function(){this.layout.deleteAllCard(),this.cardMap={}},destroy:function(){this.cardMap={},BI.Tab.superclass.destroy.apply(this,arguments)}}),BI.Tab.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.tab",BI.Tab)},function(e,t){BI.ButtonTree=BI.inherit(BI.ButtonGroup,{_defaultConfig:function(){return BI.extend(BI.ButtonTree.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-button-tree"})},_init:function(){BI.ButtonTree.superclass._init.apply(this,arguments)},setNotSelectedValue:function(e){e=BI.isArray(e)?e:[e],BI.each(this.buttons,(function(t,n){BI.isFunction(n.setSelected)?BI.deepContains(e,n.getValue())?n.setSelected(!1):n.setSelected(!0):n.setNotSelectedValue(e)}))},setEnabledValue:function(e){e=BI.isArray(e)?e:[e],BI.each(this.buttons,(function(t,n){BI.isFunction(n.setEnabledValue)?n.setEnabledValue(e):BI.deepContains(e,n.getValue())?n.setEnable(!0):n.setEnable(!1)}))},setValue:function(e){e=BI.isArray(e)?e:[e],BI.each(this.buttons,(function(t,n){BI.isFunction(n.setSelected)?BI.deepContains(e,n.getValue())?n.setSelected(!0):n.setSelected(!1):n.setValue(e)}))},getNotSelectedValue:function(){var e=[];return BI.each(this.buttons,(function(t,n){!n.isEnabled()||BI.isFunction(n.setSelected)?n.isEnabled()&&n.isSelected&&!n.isSelected()&&e.push(n.getValue()):e=BI.concat(e,n.getNotSelectedValue())})),e},getValue:function(){var e=[];return BI.each(this.buttons,(function(t,n){!n.isEnabled()||BI.isFunction(n.setSelected)?n.isEnabled()&&n.isSelected&&n.isSelected()&&e.push(n.getValue()):e=BI.concat(e,n.getValue())})),e},getSelectedButtons:function(){var e=[];return BI.each(this.buttons,(function(t,n){!n.isEnabled()||BI.isFunction(n.setSelected)?n.isSelected&&n.isSelected()&&e.push(n):e=e.concat(n.getSelectedButtons())})),e},getNotSelectedButtons:function(){var e=[];return BI.each(this.buttons,(function(t,n){!n.isEnabled()||BI.isFunction(n.setSelected)?n.isSelected&&!n.isSelected()&&e.push(n):e=e.concat(n.getNotSelectedButtons())})),e},getAllLeaves:function(){var e=[];return BI.each(this.buttons,(function(t,n){!n.isEnabled()||BI.isFunction(n.setSelected)?n.isEnabled()&&e.push(n):e=e.concat(n.getAllLeaves())})),e},getIndexByValue:function(e){var t=-1;return BI.any(this.buttons,(function(n,i){var r=i.getValue();if(i.isEnabled()&&(r===e||BI.contains(r,e)))return t=n,!0})),t},getNodeById:function(e){var t;return BI.any(this.buttons,(function(n,i){if(i.isEnabled()){if(i.attr("id")===e)return t=i,!0;if(BI.isFunction(i.getNodeById)&&(t=i.getNodeById(e)))return!0}})),t},getNodeByValue:function(e){var t;return BI.any(this.buttons,(function(n,i){if(i.isEnabled())if(BI.isFunction(i.getNodeByValue)){if(t=i.getNodeByValue(e))return!0}else if(i.attr("value")===e)return t=i,!0})),t}}),BI.ButtonTree.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.button_tree",BI.ButtonTree)},function(e,t){BI.EL=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.EL.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-el",el:{},layout:{}})},_init:function(){BI.EL.superclass._init.apply(this,arguments);var e=this,t=this.options;this.ele=BI.createWidget(t.el),BI.createWidget(t.layout,{type:"bi.adaptive",element:this,items:[this.ele]}),this.ele.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}))},setValue:function(e){this.ele.setValue(e)},getValue:function(){return this.ele.getValue()},populate:function(){this.ele.populate.apply(this,arguments)}}),BI.shortcut("bi.el",BI.EL)},function(e,t){var n,i,r,a;BI.Msg=(r=[],a=[],{alert:function(e,t,n){this._show(!1,e,t,n)},confirm:function(e,t,n){this._show(!0,e,t,n)},prompt:function(e,t,n,i,r){},toast:function(e,t,n){t=t||{},n=n||BI.Widget._renderEngine.createElement("body");var i=t.level||"common",r=!!BI.isNull(t.autoClose)||t.autoClose,o=BI.isFunction(t.callback)?t.callback:BI.emptyFn,s=BI.createWidget({type:"bi.toast",cls:"bi-message-animate bi-message-leave",level:i,autoClose:r,text:e,listeners:[{eventName:BI.Toast.EVENT_DESTORY,action:function(){BI.remove(a,s.element);var e=10;BI.each(a,(function(t,n){n.css({top:e}),e+=n.outerHeight()+10})),o()}}]}),l=10;BI.each(a,(function(e,t){l+=t.outerHeight()+10})),BI.createWidget({type:"bi.absolute",element:n,items:[{el:s,left:"50%",top:l}]}),a.push(s.element),s.element.css({"margin-left":-1*s.element.outerWidth()/2}),s.element.removeClass("bi-message-leave").addClass("bi-message-enter"),r&&BI.delay((function(){s.element.removeClass("bi-message-enter").addClass("bi-message-leave"),s.destroy()}),5e3)},_show:function(e,t,a,o){BI.isNull(n)&&(n=BI.Widget._renderEngine.createElement('<div class="bi-z-index-mask">').css({position:"absolute",zIndex:BI.zIndex_tip-2,top:0,left:0,right:0,bottom:0,opacity:.5}).appendTo("body")),i=BI.Widget._renderEngine.createElement('<div class="bi-message-depend">').css({position:"absolute",zIndex:BI.zIndex_tip-1,top:0,left:0,right:0,bottom:0}).appendTo("body");var s=function(){r[r.length-1].destroy(),r.pop(),0===r.length&&(n.remove(),n=null)},l=[];!0===e&&l.push({el:{type:"bi.button",text:BI.i18nText("BI-Basic_Cancel"),level:"ignore",handler:function(){s(),BI.isFunction(o)&&o.apply(null,[!1])}}}),l.push({el:{type:"bi.button",text:BI.i18nText("BI-Basic_OK"),handler:function(){s(),BI.isFunction(o)&&o.apply(null,[!0])}}});var u={element:i,type:"bi.center_adapt",items:[{type:"bi.border",cls:"bi-card",items:{north:{el:{type:"bi.border",cls:"bi-message-title bi-background",items:{center:{el:{type:"bi.label",cls:"bi-font-bold",text:t||BI.i18nText("BI-Basic_Prompt"),textAlign:"left",hgap:20,height:40}},east:{el:{type:"bi.icon_button",cls:"bi-message-close close-font",handler:function(){s(),BI.isFunction(o)&&o.apply(null,[!1])}},width:60}}},height:40},center:{el:{type:"bi.label",vgap:10,hgap:20,whiteSpace:"normal",text:a}},south:{el:{type:"bi.absolute",items:[{el:{type:"bi.right_vertical_adapt",lgap:10,items:l},top:0,left:20,right:20,bottom:0}]},height:44}},width:450,height:200}]};r[r.length]=BI.createWidget(u)}})},function(e,t){BI.GridView=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.GridView.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-grid-view",overflowX:!0,overflowY:!0,overscanColumnCount:0,overscanRowCount:0,rowHeightGetter:BI.emptyFn,columnWidthGetter:BI.emptyFn,scrollLeft:0,scrollTop:0,items:[]})},_init:function(){BI.GridView.superclass._init.apply(this,arguments);var e=this,t=this.options;this.renderedCells=[],this.renderedKeys=[],this.renderRange={},this._scrollLock=!1,this._debounceRelease=BI.debounce((function(){e._scrollLock=!1}),1e3/60),this.container=BI._lazyCreateWidget({type:"bi.absolute"}),this.element.scroll((function(){!0!==e._scrollLock&&(t.scrollLeft=e.element.scrollLeft(),t.scrollTop=e.element.scrollTop(),e._calculateChildrenToRender(),e.fireEvent(BI.GridView.EVENT_SCROLL,{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}))})),BI._lazyCreateWidget({type:"bi.vertical",element:this,scrollable:!0===t.overflowX&&!0===t.overflowY,scrolly:!1===t.overflowX&&!0===t.overflowY,scrollx:!0===t.overflowX&&!1===t.overflowY,items:[this.container]}),t.items.length>0&&this._populate()},mounted:function(){var e=this.options;0===e.scrollLeft&&0===e.scrollTop||(this.element.scrollTop(e.scrollTop),this.element.scrollLeft(e.scrollLeft))},_getOverscanIndices:function(e,t,n,i){return{overscanStartIndex:Math.max(0,n-t),overscanStopIndex:Math.min(e-1,i+t)}},_calculateChildrenToRender:function(){var e=this,t=this.options,n=t.width,i=t.height,r=BI.clamp(t.scrollLeft,0,this._getMaxScrollLeft()),a=BI.clamp(t.scrollTop,0,this._getMaxScrollTop()),o=t.overscanColumnCount,s=t.overscanRowCount;if(i>0&&n>0){var l=this._columnSizeAndPositionManager.getVisibleCellRange(n,r),u=this._rowSizeAndPositionManager.getVisibleCellRange(i,a);if(BI.isEmpty(l)||BI.isEmpty(u))return;var c=this._columnSizeAndPositionManager.getOffsetAdjustment(n,r),h=this._rowSizeAndPositionManager.getOffsetAdjustment(i,a);this._renderedColumnStartIndex=l.start,this._renderedColumnStopIndex=l.stop,this._renderedRowStartIndex=u.start,this._renderedRowStopIndex=u.stop;var p=this._getOverscanIndices(this.columnCount,o,this._renderedColumnStartIndex,this._renderedColumnStopIndex),d=this._getOverscanIndices(this.rowCount,s,this._renderedRowStartIndex,this._renderedRowStopIndex),f=p.overscanStartIndex,g=p.overscanStopIndex,m=d.overscanStartIndex,I=d.overscanStopIndex,B=this._rowSizeAndPositionManager.getSizeAndPositionOfCell(m),_=this._columnSizeAndPositionManager.getSizeAndPositionOfCell(f),E=this._rowSizeAndPositionManager.getSizeAndPositionOfCell(I),b=this._columnSizeAndPositionManager.getSizeAndPositionOfCell(g),y=B.offset+h,v=_.offset+c,T=E.offset+h+E.size,C=b.offset+c+b.size;if(y>=this.renderRange.minY&&T<=this.renderRange.maxY&&v>=this.renderRange.minX&&C<=this.renderRange.maxX)return;for(var N=[],V={},S={},x=this._getMaxScrollLeft(),w=this._getMaxScrollTop(),A=0,L=0,k=0,D=m;D<=I;D++)for(var M=this._rowSizeAndPositionManager.getSizeAndPositionOfCell(D),P=f;P<=g;P++){var R,H=D+"-"+P,O=this._columnSizeAndPositionManager.getSizeAndPositionOfCell(P),F=this.renderedKeys[H]&&this.renderedKeys[H][2];F>=0?(O.size!==this.renderedCells[F]._width&&(this.renderedCells[F]._width=O.size,this.renderedCells[F].el.setWidth(O.size)),M.size!==this.renderedCells[F]._height&&(this.renderedCells[F]._height=M.size,this.renderedCells[F].el.setHeight(M.size)),this.renderedCells[F]._left!==O.offset+c&&this.renderedCells[F].el.element.css("left",(O.offset+c)/BI.pixRatio+BI.pixUnit),this.renderedCells[F]._top!==M.offset+h&&this.renderedCells[F].el.element.css("top",(M.offset+h)/BI.pixRatio+BI.pixUnit),R=this.renderedCells[F].el,N.push(this.renderedCells[F])):(R=BI._lazyCreateWidget(BI.extend({type:"bi.label",width:O.size,height:M.size},t.items[D][P],{cls:(t.items[D][P].cls||"")+" grid-cell"+(0===D?" first-row":"")+(0===P?" first-col":""),_rowIndex:D,_columnIndex:P,_left:O.offset+c,_top:M.offset+h}),this),N.push({el:R,left:O.offset+c,top:M.offset+h,_left:O.offset+c,_top:M.offset+h,_width:O.size,_height:M.size})),x=Math.min(x,O.offset+c),A=Math.max(A,O.offset+c+O.size),w=Math.min(w,M.offset+h),L=Math.max(L,M.offset+h+M.size),V[H]=[D,P,k],S[k]=R,k++}var Y={},W={},G=[];BI.each(V,(function(t,n){e.renderedKeys[t]?Y[t]=n:W[t]=n})),BI.each(this.renderedKeys,(function(e,t){Y[e]||W[e]||G.push(t[2])})),BI.each(G,(function(t,n){e.renderedCells[n].el._destroy()}));var j=[];BI.each(W,(function(e,t){j.push(N[t[2]])})),this.container.addItems(j,this),this.container._children=S,this.container.attr("items",N),this.renderedCells=N,this.renderedKeys=V,this.renderRange={minX:x,minY:w,maxX:A,maxY:L}}},_getRealMaxScrollLeft:function(){var e=this.options,t=0;return BI.count(0,this.columnCount,(function(n){t+=e.columnWidthGetter(n)})),Math.max(0,t-this.options.width+(this.options.overflowX?BI.DOM.getScrollWidth():0))},_getMaxScrollLeft:function(){return Math.max(0,this._columnSizeAndPositionManager.getTotalSize()-this.options.width+(this.options.overflowX?BI.DOM.getScrollWidth():0))},_getMaxScrollTop:function(){return Math.max(0,this._rowSizeAndPositionManager.getTotalSize()-this.options.height+(this.options.overflowY?BI.DOM.getScrollWidth():0))},_populate:function(e){var t=this.options;this._reRange(),this.columnCount=0,this.rowCount=0,e&&e!==this.options.items&&(this.options.items=e),BI.isNumber(t.columnCount)?this.columnCount=t.columnCount:t.items.length>0&&(this.columnCount=t.items[0].length),BI.isNumber(t.rowCount)?this.rowCount=t.rowCount:this.rowCount=t.items.length,this.container.setWidth(this.columnCount*t.estimatedColumnSize),this.container.setHeight(this.rowCount*t.estimatedRowSize),this._columnSizeAndPositionManager=new BI.ScalingCellSizeAndPositionManager(this.columnCount,t.columnWidthGetter,t.estimatedColumnSize),this._rowSizeAndPositionManager=new BI.ScalingCellSizeAndPositionManager(this.rowCount,t.rowHeightGetter,t.estimatedRowSize),this._calculateChildrenToRender();try{this.element.scrollTop(t.scrollTop),this.element.scrollLeft(t.scrollLeft)}catch(n){}},setScrollLeft:function(e){this.options.scrollLeft!==e&&(this._scrollLock=!0,this.options.scrollLeft=BI.clamp(e||0,0,this._getRealMaxScrollLeft()),this._debounceRelease(),this._calculateChildrenToRender(),this.element.scrollLeft(this.options.scrollLeft))},setScrollTop:function(e){this.options.scrollTop!==e&&(this._scrollLock=!0,this.options.scrollTop=BI.clamp(e||0,0,this._getMaxScrollTop()),this._debounceRelease(),this._calculateChildrenToRender(),this.element.scrollTop(this.options.scrollTop))},setColumnCount:function(e){this.options.columnCount=e},setRowCount:function(e){this.options.rowCount=e},setOverflowX:function(e){var t=this;this.options.overflowX!==!!e&&(this.options.overflowX=!!e,BI.nextTick((function(){t.element.css({overflowX:e?"auto":"hidden"})})))},setOverflowY:function(e){var t=this;this.options.overflowY!==!!e&&(this.options.overflowY=!!e,BI.nextTick((function(){t.element.css({overflowY:e?"auto":"hidden"})})))},getScrollLeft:function(){return this.options.scrollLeft},getScrollTop:function(){return this.options.scrollTop},getMaxScrollLeft:function(){return this._getMaxScrollLeft()},getMaxScrollTop:function(){return this._getMaxScrollTop()},setEstimatedColumnSize:function(e){this.options.estimatedColumnSize=e},setEstimatedRowSize:function(e){this.options.estimatedRowSize=e},_reRange:function(){this.renderRange={}},_clearChildren:function(){this.container._children={},this.container.attr("items",[])},restore:function(){BI.each(this.renderedCells,(function(e,t){t.el._destroy()})),this._clearChildren(),this.renderedCells=[],this.renderedKeys=[],this.renderRange={},this._scrollLock=!1},populate:function(e){e&&e!==this.options.items&&this.restore(),this._populate(e)}}),BI.GridView.EVENT_SCROLL="EVENT_SCROLL",BI.shortcut("bi.grid_view",BI.GridView)},function(e,t){BI.Popover=BI.inherit(BI.Widget,{_constant:{SIZE:{SMALL:"small",NORMAL:"normal",BIG:"big"},MAX_HEIGHT:600},props:{baseCls:"bi-popover bi-card bi-border-radius",size:"normal",logic:{dynamic:!1},header:null,headerHeight:40,body:null,footer:null,footerHeight:44,closable:!0,bodyHgap:20,bodyTgap:10},render:function(){var e=this,t=this.options,n=this._constant;this.startX=0,this.startY=0;var i=this._calculateSize();this.tracker=new BI.MouseMoveTracker((function(t,n){var i=BI.Widget._renderEngine.createElement("body").width(),r=BI.Widget._renderEngine.createElement("body").height();e.startX+=t,e.startY+=n,e.element.css({left:BI.clamp(e.startX,0,i-e.element.width())+"px",top:BI.clamp(e.startY,0,r-e.element.height())+"px"}),BI.Resizers._resize({target:e.element[0]})}),(function(){e.tracker.releaseMouseMoves()}),_global);var r=[{el:{type:"bi.htape",cls:"bi-message-title bi-header-background",ref:function(t){e.dragger=t},items:[{type:"bi.absolute",items:[{el:BI.isPlainObject(t.header)?BI.extend({},t.header,{extraCls:"bi-font-bold"}):{type:"bi.label",cls:"bi-font-bold",height:t.headerHeight,text:t.header,title:t.header,textAlign:"left"},left:20,top:0,right:0,bottom:0}]},{el:t.closable?{type:"bi.icon_button",cls:"bi-message-close close-font",height:t.headerHeight,handler:function(){e.close()}}:{type:"bi.layout"},width:56}],height:t.headerHeight},height:t.headerHeight},t.logic.dynamic?{el:{type:"bi.vertical",scrolly:!0,cls:"popover-body",ref:function(){e.body=this},css:{"max-height":this._getSuitableBodyHeight(n.MAX_HEIGHT-t.headerHeight-(t.footer?t.footerHeight:0)-t.bodyTgap),"min-height":this._getSuitableBodyHeight(i.height-t.headerHeight-(t.footer?t.footerHeight:0)-t.bodyTgap)},items:[{el:t.body}]},hgap:t.bodyHgap,tgap:t.bodyTgap}:{el:{type:"bi.absolute",items:[{el:t.body,left:t.bodyHgap,top:t.bodyTgap,right:t.bodyHgap,bottom:0}]}}];return t.footer&&r.push({el:{type:"bi.absolute",items:[{el:t.footer,left:20,top:0,right:20,bottom:0}],height:t.footerHeight},height:t.footerHeight}),BI.extend({type:t.logic.dynamic?"bi.vertical":"bi.vtape",items:r,width:this._getSuitableWidth(i.width)},t.logic.dynamic?{type:"bi.vertical",scrolly:!1}:{type:"bi.vtape",height:this._getSuitableHeight(i.height)})},mounted:function(){var e=this;this.options;this.dragger.element.mousedown((function(t){var n=e.element.offset();e.startX=n.left,e.startY=n.top,e.tracker.captureMouseMoves(t)}))},_getSuitableBodyHeight:function(e){var t=this.options;this._constant;return BI.clamp(e,0,BI.Widget._renderEngine.createElement("body")[0].clientHeight-t.headerHeight-(t.footer?t.footerHeight:0)-t.bodyTgap)},_getSuitableHeight:function(e){return BI.clamp(e,0,BI.Widget._renderEngine.createElement("body")[0].clientHeight)},_getSuitableWidth:function(e){return BI.clamp(e,0,BI.Widget._renderEngine.createElement("body").width())},_calculateSize:function(){var e=this.options,t={};if(BI.isNotNull(e.size))switch(e.size){case this._constant.SIZE.SMALL:t.width=450,t.height=200,t.type="small";break;case this._constant.SIZE.BIG:t.width=900,t.height=500,t.type="big";break;default:t.width=550,t.height=500,t.type="default"}return{width:e.width||t.width,height:e.height||t.height,type:t.type||"default"}},hide:function(){},open:function(){this.show(),this.fireEvent(BI.Popover.EVENT_OPEN,arguments)},close:function(){this.hide(),this.fireEvent(BI.Popover.EVENT_CLOSE,arguments)},setZindex:function(e){this.element.css({"z-index":e})},destroyed:function(){}}),BI.shortcut("bi.popover",BI.Popover),BI.BarPopover=BI.inherit(BI.Popover,{_defaultConfig:function(){return BI.extend(BI.BarPopover.superclass._defaultConfig.apply(this,arguments),{btns:[BI.i18nText("BI-Basic_Sure"),BI.i18nText("BI-Basic_Cancel")]})},beforeCreate:function(){var e=this,t=this.options;t.footer||(t.footer={type:"bi.right_vertical_adapt",lgap:10,items:[{type:"bi.button",text:this.options.btns[1],value:1,level:"ignore",handler:function(t){e.fireEvent(BI.Popover.EVENT_CANCEL,t),e.close(t)}},{type:"bi.button",text:this.options.btns[0],warningTitle:t.warningTitle,value:0,handler:function(t){e.fireEvent(BI.Popover.EVENT_CONFIRM,t),e.close(t)}}]})}}),BI.shortcut("bi.bar_popover",BI.BarPopover),BI.Popover.EVENT_CLOSE="EVENT_CLOSE",BI.Popover.EVENT_OPEN="EVENT_OPEN",BI.Popover.EVENT_CANCEL="EVENT_CANCEL",BI.Popover.EVENT_CONFIRM="EVENT_CONFIRM"},function(e,t){BI.PopupView=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.PopupView.superclass._defaultConfig.apply(this,arguments),{_baseCls:"bi-popup-view",maxWidth:"auto",minWidth:100,minHeight:24,lgap:0,rgap:0,tgap:0,bgap:0,vgap:0,hgap:0,innerVGap:0,innerHGap:0,direction:BI.Direction.Top,stopEvent:!1,stopPropagation:!1,logic:{dynamic:!0},tool:!1,tabs:[],buttons:[],el:{type:"bi.button_group",items:[],chooseType:0,behaviors:{},layouts:[{type:"bi.vertical"}]}})},_init:function(){BI.PopupView.superclass._init.apply(this,arguments);var e=this,t=this.options,n=function(e){e.stopPropagation()},i=function(e){return e.stopEvent(),!1};this.element.css({"z-index":BI.zIndex_popup,"min-width":BI.isNumeric(t.minWidth)?t.minWidth/BI.pixRatio+BI.pixUnit:t.minWidth,"max-width":BI.isNumeric(t.maxWidth)?t.maxWidth/BI.pixRatio+BI.pixUnit:t.maxWidth}).bind({click:n}),this.element.bind("mousewheel",n),t.stopPropagation&&this.element.bind({mousedown:n,mouseup:n,mouseover:n}),t.stopEvent&&this.element.bind({mousedown:i,mouseup:i,mouseover:i}),this.tool=this._createTool(),this.tab=this._createTab(),this.view=this._createView(),this.toolbar=this._createToolBar(),this.view.on(BI.Controller.EVENT_CHANGE,(function(t){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),t===BI.Events.CLICK&&e.fireEvent(BI.PopupView.EVENT_CHANGE)})),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(t.direction),BI.extend({},t.logic,{scrolly:!1,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap,vgap:t.vgap,hgap:t.hgap,items:BI.LogicFactory.createLogicItemsByDirection(t.direction,BI.extend({cls:"list-view-outer bi-card list-view-shadow"},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(t.direction),BI.extend({},t.logic,{items:BI.LogicFactory.createLogicItemsByDirection(t.direction,this.tool,this.tab,this.view,this.toolbar)}))))}))))},_createView:function(){var e=this.options;return this.button_group=BI.createWidget(e.el,{type:"bi.button_group",value:e.value}),this.button_group.element.css({"min-height":BI.isNumeric(e.minHeight)?e.minHeight/BI.pixRatio+BI.pixUnit:e.minHeight,"padding-top":e.innerVGap/BI.pixRatio+BI.pixUnit,"padding-bottom":e.innerVGap/BI.pixRatio+BI.pixUnit,"padding-left":e.innerHGap/BI.pixRatio+BI.pixUnit,"padding-right":e.innerHGap/BI.pixRatio+BI.pixUnit}),this.button_group},_createTool:function(){var e=this.options;if(!1!==e.tool)return BI.createWidget(e.tool)},_createTab:function(){var e=this.options;if(0!==e.tabs.length)return BI.createWidget({type:"bi.center",cls:"list-view-tab",height:25,items:e.tabs,value:e.value})},_createToolBar:function(){var e=this.options;if(0!==e.buttons.length)return BI.createWidget({type:"bi.center",cls:"list-view-toolbar bi-high-light bi-split-top",height:24,items:BI.createItems(e.buttons,{once:!1,shadow:!0,isShadowShowingOnSelected:!0})})},getView:function(){return this.view},populate:function(e){this.view.populate.apply(this.view,arguments)},resetWidth:function(e){this.options.width=e,this.element.width(e)},resetHeight:function(e){var t=e-(this.toolbar?this.toolbar.attr("height")||24:0)-(this.tab?this.tab.attr("height")||24:0)-(this.tool&&this.tool.attr("height")||24)*(this.tool&&this.tool.isVisible()?1:0)-2*this.options.innerVGap;this.view.resetHeight?this.view.resetHeight(t):this.view.element.css({"max-height":t/BI.pixRatio+BI.pixUnit})},setValue:function(e){this.tab&&this.tab.setValue(e),this.view.setValue(e)},getValue:function(){return this.view.getValue()}}),BI.PopupView.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.popup_view",BI.PopupView)},function(e,t){BI.SearcherView=BI.inherit(BI.Pane,{_defaultConfig:function(){var e=BI.SearcherView.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-searcher-view bi-card",tipText:BI.i18nText("BI-No_Select"),chooseType:BI.Selection.Single,matcher:{type:"bi.button_group",behaviors:{redmark:function(){return!0}},items:[],layouts:[{type:"bi.vertical"}]},searcher:{type:"bi.button_group",behaviors:{redmark:function(){return!0}},items:[],layouts:[{type:"bi.vertical"}]}})},_init:function(){BI.SearcherView.superclass._init.apply(this,arguments);var e=this,t=this.options;this.matcher=BI.createWidget(t.matcher,{type:"bi.button_group",chooseType:t.chooseType,behaviors:{redmark:function(){return!0}},layouts:[{type:"bi.vertical"}],value:t.value}),this.matcher.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),t===BI.Events.CLICK&&e.fireEvent(BI.SearcherView.EVENT_CHANGE,n,i)})),this.spliter=BI.createWidget({type:"bi.vertical",height:1,hgap:10,items:[{type:"bi.layout",height:1,cls:"searcher-view-spliter bi-background"}]}),this.searcher=BI.createWidget(t.searcher,{type:"bi.button_group",chooseType:t.chooseType,behaviors:{redmark:function(){return!0}},layouts:[{type:"bi.vertical"}],value:t.value}),this.searcher.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),t===BI.Events.CLICK&&e.fireEvent(BI.SearcherView.EVENT_CHANGE,n,i)})),BI.createWidget({type:"bi.vertical",element:this,items:[this.matcher,this.spliter,this.searcher]})},startSearch:function(){},stopSearch:function(){},setValue:function(e){this.matcher.setValue(e),this.searcher.setValue(e)},getValue:function(){return this.matcher.getValue().concat(this.searcher.getValue())},populate:function(e,t,n){e||(e=[]),t||(t=[]),this.setTipVisible(e.length+t.length===0),this.spliter.setVisible(BI.isNotEmptyArray(t)&&BI.isNotEmptyArray(e)),this.matcher.populate(t,n),this.searcher.populate(e,n)},empty:function(){this.searcher.empty(),this.matcher.empty()},hasMatched:function(){return this.matcher.getAllButtons().length>0}}),BI.SearcherView.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.searcher_view",BI.SearcherView)},function(e,t){BI.ListView=BI.inherit(BI.Widget,{props:function(){return{baseCls:"bi-list-view",overscanHeight:100,blockSize:10,scrollTop:0,el:{},items:[]}},init:function(){this.renderedIndex=-1,this.cache={}},render:function(){var e=this,t=this.options;return{type:"bi.vertical",items:[BI.extend({type:"bi.vertical",scrolly:!1,ref:function(){e.container=this}},t.el)],element:this}},mounted:function(){var e=this,t=this.options;this._populate(),this.element.scroll((function(n){t.scrollTop=e.element.scrollTop(),e._calculateBlocksToRender()}));var n=this.element.width(),i=this.element.height();BI.ResizeDetector.addResizeListener(this,(function(){var t=e.element.width(),r=e.element.height();t===n&&r===i||(n=t,i=r,e._calculateBlocksToRender())}))},_renderMoreIf:function(){for(var e,t=this,n=this.options,i=this.element.height(),r=n.scrollTop+i+n.overscanHeight,a=this.cache[this.renderedIndex]&&this.cache[this.renderedIndex].index+n.blockSize||0,o=this.renderedIndex+1,s=function(){return t.container.element.height()};(e=s())<r&&a<n.items.length;){var l=n.items.slice(a,a+n.blockSize);this.container.addItems(l,this);var u=s()-e;this.cache[o]={index:a,scrollTop:e,height:u},this.renderedIndex=o,o++,a+=n.blockSize}},_calculateBlocksToRender:function(){this.options;this._renderMoreIf()},_populate:function(e){var t=this.options;e&&this.options.items!==e&&(this.options.items=e),this._calculateBlocksToRender(),this.element.scrollTop(t.scrollTop)},restore:function(){this.renderedIndex=-1,this.container.empty(),this.cache={}},populate:function(e){e&&this.options.items!==e&&this.restore(),this._populate(e)},destroyed:function(){this.restore()}}),BI.shortcut("bi.list_view",BI.ListView)},function(e,t){BI.VirtualList=BI.inherit(BI.Widget,{props:function(){return{baseCls:"bi-virtual-list",overscanHeight:100,blockSize:10,scrollTop:0,items:[]}},init:function(){this.renderedIndex=-1,this.cache={}},render:function(){var e=this;this.options;return{type:"bi.vertical",items:[{type:"bi.layout",ref:function(){e.topBlank=this}},{type:"bi.vertical",scrolly:!1,ref:function(){e.container=this}},{type:"bi.layout",ref:function(){e.bottomBlank=this}}],element:this}},mounted:function(){var e=this,t=this.options;this._populate(),this.element.scroll((function(n){t.scrollTop=e.element.scrollTop(),e._calculateBlocksToRender()})),BI.ResizeDetector.addResizeListener(this,(function(){e._calculateBlocksToRender()}))},_renderMoreIf:function(){for(var e,t=this,n=this.options,i=this.element.height(),r=n.scrollTop+i+n.overscanHeight,a=this.cache[this.renderedIndex]&&this.cache[this.renderedIndex].index+n.blockSize||0,o=this.renderedIndex+1,s=function(){return t.container.element.height()+t.topBlank.element.height()+t.bottomBlank.element.height()};(e=s())<r&&a<n.items.length;){var l=n.items.slice(a,a+n.blockSize);this.container.addItems(l,this);var u=s()-e;this.cache[o]={index:a,scrollTop:e,height:u},this.tree.set(o,u),this.renderedIndex=o,o++,a+=n.blockSize}},_calculateBlocksToRender:function(){var e=this.options;this._renderMoreIf();for(var t=this.element.height(),n=e.scrollTop-e.overscanHeight,i=e.scrollTop+t+e.overscanHeight,r=this.tree.greatestLowerBound(n),a=this.tree.leastUpperBound(i),o=[],s=0;s<r;s++){var l=this.cache[s].index;if(!this.cache[s].destroyed){for(var u=l;u<l+e.blockSize&&u<e.items.length;u++)o.push(this.container._children[u]),this.container._children[u]=null;this.cache[s].destroyed=!0}}for(s=a+1;s<=this.renderedIndex;s++){l=this.cache[s].index;if(!this.cache[s].destroyed){for(u=l;u<l+e.blockSize&&u<e.items.length;u++)o.push(this.container._children[u]),this.container._children[u]=null;this.cache[s].destroyed=!0}}var c=BI.Widget._renderEngine.createFragment(),h=BI.Widget._renderEngine.createFragment(),p=c;for(s=r<0?0:r;s<=a&&s<=this.renderedIndex;s++){l=this.cache[s].index;if(this.cache[s].destroyed||(p=h),!0===this.cache[s].destroyed){for(u=l;u<l+e.blockSize&&u<e.items.length;u++){var d=this.container._addElement(u,BI.extend({root:!0},BI.stripEL(e.items[u])),this);p.appendChild(d.element[0])}this.cache[s].destroyed=!1}}this.container.element.prepend(c),this.container.element.append(h),this.topBlank.setHeight(this.tree.sumTo(Math.max(-1,r-1))),this.bottomBlank.setHeight(this.tree.sumTo(this.renderedIndex)-this.tree.sumTo(Math.min(a,this.renderedIndex))),BI.each(o,(function(e,t){t&&t._destroy()}))},_populate:function(e){var t=this.options;e&&this.options.items!==e&&(this.options.items=e),this.tree=BI.PrefixIntervalTree.empty(Math.ceil(t.items.length/t.blockSize)),this._calculateBlocksToRender();try{this.element.scrollTop(t.scrollTop)}catch(n){}},_clearChildren:function(){BI.each(this.container._children,(function(e,t){t&&t._destroy()})),this.container._children={},this.container.attr("items",[])},restore:function(){this.renderedIndex=-1,this._clearChildren(),this.cache={},this.options.scrollTop=0,this.topBlank.setHeight(0),this.bottomBlank.setHeight(0)},populate:function(e){e&&this.options.items!==e&&this.restore(),this._populate(e)},destroyed:function(){this.restore()}}),BI.shortcut("bi.virtual_list",BI.VirtualList)},function(e,t){BI.Pager=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.Pager.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-pager",behaviors:{},layouts:[{type:"bi.horizontal",hgap:10,vgap:0}],dynamicShow:!0,dynamicShowFirstLast:!1,dynamicShowPrevNext:!1,pages:!1,curr:function(){return 1},groups:0,jump:BI.emptyFn,first:!1,last:!1,prev:"上一页",next:"下一页",firstPage:1,lastPage:function(){return 1},hasPrev:BI.emptyFn,hasNext:BI.emptyFn})},_init:function(){BI.Pager.superclass._init.apply(this,arguments);this.currPage=BI.result(this.options,"curr"),this._populate()},_populate:function(){var e=this,t=this.options,n=[],i={};this.empty();var r,a=BI.result(t,"pages"),o=BI.result(this,"currPage"),s=BI.result(t,"groups"),l=BI.result(t,"first"),u=BI.result(t,"last"),c=BI.result(t,"prev"),h=BI.result(t,"next");!1===a?(s=0,l=!1,u=!1):s>a&&(s=a),i.index=Math.ceil((o+(s>1&&s!==a?1:0))/(0===s?1:s)),(!t.dynamicShow&&!t.dynamicShowPrevNext||o>1)&&!1!==c&&(BI.isKey(c)?n.push({text:c,value:"prev",disabled:!1===a?!1===t.hasPrev(o):!(o>1&&!1!==c)}):n.push(BI.extend({disabled:!1===a?!1===t.hasPrev(o):!(o>1&&!1!==c)},c))),(!t.dynamicShow&&!t.dynamicShowFirstLast||i.index>1&&0!==s)&&l&&(n.push({text:l,value:"first",disabled:!(i.index>1&&0!==s)}),i.index>1&&0!==s&&n.push({type:"bi.label",cls:"page-ellipsis",text:"…"})),i.poor=Math.floor((s-1)/2),i.start=i.index>1?o-i.poor:1,i.end=i.index>1?(r=o+(s-i.poor-1))>a?a:r:s,i.end-i.start<s-1&&(i.start=i.end-s+1);var p=i.start,d=i.end;for(l&&u&&i.index>1&&0!==s&&a>s&&i.end<a&&0!==s&&(p++,d--);p<=d;p++)p===o?n.push({text:p,value:p,selected:!0}):n.push({text:p,value:p});(!t.dynamicShow&&!t.dynamicShowFirstLast||a>s&&i.end<a&&0!==s)&&u&&(a>s&&i.end<a&&0!==s&&n.push({type:"bi.label",cls:"page-ellipsis",text:"…"}),n.push({text:u,value:"last",disabled:!(a>s&&i.end<a&&0!==s)})),i.flow=!c&&0===s,(!t.dynamicShow&&!t.dynamicShowPrevNext&&h||o!==a&&h||i.flow)&&n.push(BI.isKey(h)?!1===a?{text:h,value:"next",disabled:!1===t.hasNext(o)}:i.flow&&o===a?{text:h,value:"next",disabled:!0}:{text:h,value:"next",disabled:!(o!==a&&h||i.flow)}:BI.extend({disabled:!1===a?!1===t.hasNext(o):!(o!==a&&h||i.flow)},h)),this.button_group=BI.createWidget({type:"bi.button_group",element:this,items:BI.createItems(n,{cls:"bi-list-item-select bi-border-radius",height:23,hgap:10,stopPropagation:!0}),behaviors:t.behaviors,layouts:t.layouts}),this.button_group.on(BI.Controller.EVENT_CHANGE,(function(n,i,r){if(n===BI.Events.CLICK){var o=e.button_group.getValue()[0];switch(o){case"first":e.currPage=1;break;case"last":e.currPage=a;break;case"prev":e.currPage--;break;case"next":e.currPage++;break;default:e.currPage=o}t.jump.apply(e,[{pages:a,curr:e.currPage}]),e._populate(),e.fireEvent(BI.Pager.EVENT_CHANGE,r)}e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.fireEvent(BI.Pager.EVENT_AFTER_POPULATE)},getCurrentPage:function(){return this.currPage},setAllPages:function(e){this.options.pages=e},hasPrev:function(e){e||(e=1);var t=this.options;return!1===this.options.pages?t.hasPrev(e):e>1},hasNext:function(e){e||(e=1);var t=this.options,n=this.options.pages;return!1===n?t.hasNext(e):e<n},setValue:function(e){var t=this.options;if(e=(e=e||0)<1?1:e,!1===t.pages){var n=BI.result(t,"lastPage"),i=1;this.currPage=e>n?n:e<(i=BI.result(t,"firstPage"))?i:e}else e=e>t.pages?t.pages:e,this.currPage=e;this._populate()},getValue:function(){var e=this.button_group.getValue()[0];switch(e){case"prev":return-1;case"next":return 1;case"first":return BI.MIN;case"last":return BI.MAX;default:return e}},attr:function(e,t){BI.Pager.superclass.attr.apply(this,arguments),"curr"===e&&(this.currPage=BI.result(this.options,"curr"))},populate:function(){this._populate()}}),BI.Pager.EVENT_CHANGE="EVENT_CHANGE",BI.Pager.EVENT_AFTER_POPULATE="EVENT_AFTER_POPULATE",BI.shortcut("bi.pager",BI.Pager)},function(e,t){BI.Single=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.Single.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{readonly:!1,title:null,warningTitle:null,tipType:null,value:null,belowMouse:!1})},_showToolTip:function(e,t){t||(t={});var n=this.options,i=this.getTipType()||(this.isEnabled()?"success":"warning"),r="success"===i?this.getTitle():this.getWarningTitle()||this.getTitle();BI.isKey(r)&&(BI.Tooltips.show(e,this.getName(),r,i,this,t),n.action&&BI.Actions.runAction(n.action,"hover",n,this),BI.Actions.runGlobalAction("hover",n,this))},_hideTooltip:function(){var e=this,t=BI.Tooltips.get(this.getName());BI.isNotNull(t)&&t.element.fadeOut(200,(function(){BI.Tooltips.remove(e.getName())}))},_init:function(){BI.Single.superclass._init.apply(this,arguments);var e=this.options;(BI.isKey(e.title)||BI.isKey(e.warningTitle)||BI.isFunction(e.title)||BI.isFunction(e.warningTitle))&&this.enableHover({belowMouse:e.belowMouse,container:e.container})},_clearTimeOut:function(){BI.isNotNull(this.showTimeout)&&(clearTimeout(this.showTimeout),this.showTimeout=null),BI.isNotNull(this.hideTimeout)&&(clearTimeout(this.hideTimeout),this.hideTimeout=null)},enableHover:function(e){e||(e={});var t=this;this._hoverBinded||(this.element.on("mouseenter.title"+this.getName(),(function(n){t._e=n,"warning"===t.getTipType()||BI.isKey(t.getWarningTitle())&&!t.isEnabled()?t.showTimeout=BI.delay((function(){BI.isNotNull(t.showTimeout)&&t._showToolTip(t._e||n,e)}),200):("success"===t.getTipType()||t.isEnabled())&&(t.showTimeout=BI.delay((function(){BI.isNotNull(t.showTimeout)&&t._showToolTip(t._e||n,e)}),500))})),this.element.on("mousemove.title"+this.getName(),(function(n){t._e=n,BI.isNotNull(t.showTimeout)&&(clearTimeout(t.showTimeout),t.showTimeout=null),BI.isNull(t.hideTimeout)&&(t.hideTimeout=BI.delay((function(){BI.isNotNull(t.hideTimeout)&&t._hideTooltip()}),500)),t.showTimeout=BI.delay((function(){BI.isNotNull(t.showTimeout)&&(BI.isNotNull(t.hideTimeout)&&(clearTimeout(t.hideTimeout),t.hideTimeout=null),t.element.__isMouseInBounds__(t._e||n)&&t._showToolTip(t._e||n,e))}),500)})),this.element.on("mouseleave.title"+this.getName(),(function(e){t._e=null,t._clearTimeOut(),t._hideTooltip()})),this._hoverBinded=!0)},disabledHover:function(){this._clearTimeOut(),this._hideTooltip(),this.element.unbind("mouseenter.title"+this.getName()).unbind("mousemove.title"+this.getName()).unbind("mouseleave.title"+this.getName()),this._hoverBinded=!1},setTitle:function(e,t){this.options.title=e,BI.isKey(e)||BI.isFunction(e)?this.enableHover(t):this.disabledHover()},setWarningTitle:function(e,t){this.options.warningTitle=e,BI.isKey(e)||BI.isFunction(e)?this.enableHover(t):this.disabledHover()},setTipType:function(e){this.options.tipType=e},getTipType:function(){return this.options.tipType},isReadOnly:function(){return!!this.options.readonly},getTitle:function(){var e=this.options.title;return BI.isFunction(e)?e():e},getWarningTitle:function(){var e=this.options.warningTitle;return BI.isFunction(e)?e():e},setValue:function(e){this.options.readonly||(this.options.value=e,this.options.setValue&&this.options.setValue(e))},getValue:function(){return this.options.value},destroyed:function(){BI.isNotNull(this.showTimeout)&&(clearTimeout(this.showTimeout),this.showTimeout=null),BI.Tooltips.remove(this.getName())}}),BI.shortcut("bi.single",BI.Single)},function(e,t){!function(){BI.Text=BI.inherit(BI.Single,{props:{baseCls:"bi-text",textAlign:"left",whiteSpace:"normal",lineHeight:null,handler:null,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0,py:"",highLight:!1},render:function(){var e=this,t=this.options;t.hgap+t.lgap>0&&this.element.css({"padding-left":(t.hgap+t.lgap)/BI.pixRatio+BI.pixUnit}),t.hgap+t.rgap>0&&this.element.css({"padding-right":(t.hgap+t.rgap)/BI.pixRatio+BI.pixUnit}),t.vgap+t.tgap>0&&this.element.css({"padding-top":(t.vgap+t.tgap)/BI.pixRatio+BI.pixUnit}),t.vgap+t.bgap>0&&this.element.css({"padding-bottom":(t.vgap+t.bgap)/BI.pixRatio+BI.pixUnit}),BI.isWidthOrHeight(t.height)&&this.element.css({lineHeight:BI.isNumber(t.height)?t.height/BI.pixRatio+BI.pixUnit:t.height}),BI.isWidthOrHeight(t.lineHeight)&&this.element.css({lineHeight:BI.isNumber(t.lineHeight)?t.lineHeight/BI.pixRatio+BI.pixUnit:t.lineHeight}),BI.isWidthOrHeight(t.maxWidth)&&this.element.css({maxWidth:BI.isNumber(t.maxWidth)?t.maxWidth/BI.pixRatio+BI.pixUnit:t.maxWidth}),this.element.css({textAlign:t.textAlign,whiteSpace:this._getTextWrap(),textOverflow:"nowrap"===t.whiteSpace?"ellipsis":"",overflow:"nowrap"===t.whiteSpace?"":BI.isWidthOrHeight(t.height)?"auto":""}),t.handler&&t.handler!==BI.emptyFn?(this.text=BI.createWidget({type:"bi.layout",tagName:"span"}),this.text.element.click((function(n){t.handler.call(e,e.getValue(),e,n)})),BI.createWidget({type:"bi.default",element:this,items:[this.text]})):this.text=this;var n=this._getShowText();BI.isUndefined(n)?BI.isKey(t.value)&&this.setText(t.value):this.setText(n),BI.isKey(t.keyword)&&this.doRedMark(t.keyword),t.highLight&&this.doHighLight()},_getTextWrap:function(){var e=this.options;switch(e.whiteSpace){case"nowrap":return"pre";case"normal":return"pre-wrap";default:return e.whiteSpace}},_getShowText:function(){var e=this.options,t=BI.isFunction(e.text)?e.text():e.text;return BI.isKey(t)?BI.Text.formatText(t+""):t},_doRedMark:function(e){var t=this.options;t.keyword=e,this.text.element.__textKeywordMarked__(this._getShowText(),e,t.py)},doRedMark:function(e){BI.isKey(e)&&this._doRedMark(e)},unRedMark:function(){var e=this.options;e.keyword="",this.text.element.__textKeywordMarked__(this._getShowText(),"",e.py)},doHighLight:function(){this.text.element.addClass("bi-high-light")},unHighLight:function(){this.text.element.removeClass("bi-high-light")},setValue:function(e){BI.Text.superclass.setValue.apply(this,arguments),this.isReadOnly()||this.setText(e)},setStyle:function(e){this.text.element.css(e)},setText:function(e){BI.Text.superclass.setText.apply(this,arguments),this.options.text=e,this._doRedMark(this.options.keyword)}});var e=[];BI.Text.addTextFormatter=function(t){e.push(t)},BI.Text.formatText=function(t){if(e.length>0)for(var n=0,i=e.length;n<i;n++)t=e[n](t);return t},BI.shortcut("bi.text",BI.Text)}()},function(e,t){BI.A=BI.inherit(BI.Text,{_defaultConfig:function(){var e=BI.A.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-a display-block",href:"",target:"_blank",el:null,tagName:"a"})},_init:function(){var e=this.options;BI.A.superclass._init.apply(this,arguments),this.element.attr({href:e.href,target:e.target}),e.el&&BI.createWidget(e.el,{element:this})}}),BI.shortcut("bi.a",BI.A)},function(e,t){BI.LoadingBar=BI.inherit(BI.Single,{_defaultConfig:function(){var e=BI.LoadingBar.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-loading-bar bi-tips",height:30,handler:BI.emptyFn})},_init:function(){BI.LoadingBar.superclass._init.apply(this,arguments);var e=this;this.loaded=BI.createWidget({type:"bi.text_button",cls:"loading-text bi-list-item-simple",text:BI.i18nText("BI-Load_More"),width:120,handler:this.options.handler}),this.loaded.on(BI.Controller.EVENT_CHANGE,(function(t){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.loading=BI.createWidget({type:"bi.layout",width:this.options.height,height:this.options.height,cls:"loading-background cursor-default"});var t=BI.createWidget({type:"bi.center_adapt",items:[this.loaded]}),n=BI.createWidget({type:"bi.center_adapt",items:[this.loading]});this.cardLayout=BI.createWidget({type:"bi.card",element:this,items:[{el:t,cardName:"loaded"},{el:n,cardName:"loading"}]}),this.invisible()},_reset:function(){this.visible(),this.loaded.setText(BI.i18nText("BI-Load_More")),this.loaded.enable()},setLoaded:function(){this._reset(),this.cardLayout.showCardByName("loaded")},setEnd:function(){this.setLoaded(),this.loaded.setText(BI.i18nText("BI-No_More_Data")),this.loaded.disable()},setLoading:function(){this._reset(),this.cardLayout.showCardByName("loading")}}),BI.shortcut("bi.loading_bar",BI.LoadingBar)},function(e,t){BI.BasicButton=BI.inherit(BI.Single,{_defaultConfig:function(){var e=BI.BasicButton.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{_baseCls:(e._baseCls||"")+" bi-basic-button"+(e.invalid?"":" cursor-pointer")+(BI.isIE()&&BI.getIEVersion()<10?" hack":""),value:"",stopEvent:!1,stopPropagation:!1,selected:!1,once:!1,forceSelected:!1,forceNotSelected:!1,disableSelected:!1,shadow:!1,isShadowShowingOnSelected:!1,trigger:null,handler:BI.emptyFn,bubble:null})},_init:function(){BI.BasicButton.superclass._init.apply(this,arguments);var e=this.options;!0===e.selected&&BI.nextTick(BI.bind((function(){this.setSelected(e.selected)}),this)),BI.nextTick(BI.bind(this.bindEvent,this)),e.shadow&&this._createShadow(),e.level&&this.element.addClass("button-"+e.level)},_createShadow:function(){var e=this,t=this.options,n=function(){e.$mask||(e.$mask=BI.createWidget(BI.isObject(t.shadow)?t.shadow:{},{type:"bi.layout",cls:"bi-button-mask"}),e.$mask.invisible(),BI.createWidget({type:"bi.absolute",element:e,items:[{el:e.$mask,left:0,right:0,top:0,bottom:0}]}))};this.element.mouseup((function(){e._hover||t.isShadowShowingOnSelected||(n(),e.$mask.invisible())})),this.element.on("mouseenter."+this.getName(),(function(i){e.element.__isMouseInBounds__(i)&&(!e.isEnabled()||e._hover||!t.isShadowShowingOnSelected&&e.isSelected()||(n(),e.$mask.visible()))})),this.element.on("mousemove."+this.getName(),(function(t){e.element.__isMouseInBounds__(t)||e.isEnabled()&&!e._hover&&(n(),e.$mask.invisible())})),this.element.on("mouseleave."+this.getName(),(function(){e.isEnabled()&&!e._hover&&(n(),e.$mask.invisible())}))},bindEvent:function(){var e=this,t=this.options,n=this.handle();if(n){n=n.element;var i=(t.trigger||"").split(",");BI.each(i,(function(i,r){switch(r){case"mouseup":var s=!1;n.mousedown((function(){s=!0})),n.mouseup((function(e){!0===s&&o(e),s=!1,a(e)}));break;case"mousedown":s=!1;var l=!1;n.mousedown((function(t){BI.Widget._renderEngine.createElement(document).bind("mouseup."+e.getName(),(function(t){!BI.DOM.isExist(e)||n.__isMouseInBounds__(t)||!0!==s||l||e._trigger(),s=!1,BI.Widget._renderEngine.createElement(document).unbind("mouseup."+e.getName())})),!0!==s&&(e.isSelected()?l=!0:o(t),s=!0,a(t))})),n.mouseup((function(t){BI.DOM.isExist(e)&&!0===s&&!0===l&&o(t),s=!1,l=!1,BI.Widget._renderEngine.createElement(document).unbind("mouseup."+e.getName())}));break;case"dblclick":n.dblclick(o);break;case"lclick":var u;s=!1;n.mousedown((function(t){BI.Widget._renderEngine.createElement(document).bind("mouseup."+e.getName(),(function(t){u&&clearInterval(u),u=null,s=!1,BI.Widget._renderEngine.createElement(document).unbind("mouseup."+e.getName())})),!0!==s&&(!e.isEnabled()||e.isOnce()&&e.isSelected()||(u=setInterval((function(){e.isEnabled()&&e.doClick()}),180),s=!0,a(t)))}));break;default:(t.stopEvent||t.stopPropagation)&&n.mousedown((function(e){a(e)})),n.click(o)}}));var r=BI.debounce(this._doClick,BI.EVENT_RESPONSE_TIME,{leading:!0,trailing:!1})}function a(e){t.stopEvent&&e.stopEvent(),t.stopPropagation&&e.stopPropagation()}function o(n){var i;(a(n),!e.isEnabled()||e.isOnce()&&e.isSelected())||(BI.isKey(t.bubble)||BI.isFunction(t.bubble)?(BI.isNull(e.combo)&&BI.createWidget({type:"bi.absolute",element:e,items:[{el:{type:"bi.bubble_combo",trigger:"",destroyWhenHide:!0,ref:function(){e.combo=this},el:{type:"bi.layout",height:"100%"},popup:{type:"bi.text_bubble_bar_popup_view",text:s(),ref:function(){i=this},listeners:[{eventName:BI.BubblePopupBarView.EVENT_CLICK_TOOLBAR_BUTTON,action:function(t){e.combo.hideView(),t&&r.apply(e,arguments)}}]},listeners:[{eventName:BI.BubbleCombo.EVENT_BEFORE_POPUPVIEW,action:function(){i.populate(s())}}]},left:0,right:0,bottom:0,top:0}]}),e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()):r.apply(e,arguments))}function s(){var t=e.options.bubble;return BI.isFunction(t)?t():t}},_trigger:function(e){var t=this.options;if(this.isEnabled()&&(this.isDisableSelected()||(this.isForceSelected()?this.setSelected(!0):this.isForceNotSelected()?this.setSelected(!1):this.setSelected(!this.isSelected())),this.isValid())){var n=this.getValue();t.handler.call(this,n,this,e),this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.CLICK,n,this,e),this.fireEvent(BI.BasicButton.EVENT_CHANGE,n,this),t.action&&BI.Actions.runAction(t.action,"click",t,this),BI.Actions.runGlobalAction("click",t,this)}},_doClick:function(e){this.isValid()&&this.beforeClick(e),this._trigger(e),this.isValid()&&this.doClick(e)},beforeClick:function(){},doClick:function(){},handle:function(){return this},hover:function(){this._hover=!0,this.handle().element.addClass("hover"),this.options.shadow&&this.$mask&&this.$mask.setVisible(!0)},dishover:function(){this._hover=!1,this.handle().element.removeClass("hover"),this.options.shadow&&this.$mask&&this.$mask.setVisible(!1)},setSelected:function(e){var t=this.options;t.selected=e,e?this.handle().element.addClass("active"):this.handle().element.removeClass("active"),t.shadow&&!t.isShadowShowingOnSelected&&this.$mask&&this.$mask.setVisible(!1),this.options.setSelected&&this.options.setSelected.call(this,e)},isSelected:function(){return this.options.selected},isOnce:function(){return this.options.once},isForceSelected:function(){return this.options.forceSelected},isForceNotSelected:function(){return this.options.forceNotSelected},isDisableSelected:function(){return this.options.disableSelected},setText:function(e){this.options.text=e,this.options.setText&&this.options.setText.call(this,e)},getText:function(){return this.options.text},_setEnable:function(e){BI.BasicButton.superclass._setEnable.apply(this,arguments),!0===e?this.element.removeClass("base-disabled disabled"):!1===e&&this.element.addClass("base-disabled disabled"),e||this.options.shadow&&this.$mask&&this.$mask.setVisible(!1)},empty:function(){BI.Widget._renderEngine.createElement(document).unbind("mouseup."+this.getName()),BI.BasicButton.superclass.empty.apply(this,arguments)}}),BI.BasicButton.EVENT_CHANGE="BasicButton.EVENT_CHANGE",BI.shortcut("bi.basic_button",BI.BasicButton)},function(e,t){BI.NodeButton=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.NodeButton.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{_baseCls:(e._baseCls||"")+" bi-node",open:!1})},_init:function(){BI.NodeButton.superclass._init.apply(this,arguments);var e=this;BI.nextTick((function(){e.setOpened(e.isOpened())}))},doClick:function(){BI.NodeButton.superclass.doClick.apply(this,arguments),this.setOpened(!this.isOpened())},isOnce:function(){return!1},isOpened:function(){return!!this.options.open},setOpened:function(e){this.options.open=!!e},triggerCollapse:function(){this.isOpened()&&(this.setOpened(!1),this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.COLLAPSE,this.getValue(),this))},triggerExpand:function(){this.isOpened()||(this.setOpened(!0),this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,this.getValue(),this))}})},function(e,t){BI.IconButton=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.IconButton.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{_baseCls:(e._baseCls||"")+" bi-icon-button horizon-center",iconWidth:null,iconHeight:null})},_init:function(){BI.IconButton.superclass._init.apply(this,arguments);var e=this.options;this.element.css({textAlign:"center"}),this.icon=BI.createWidget({type:"bi.icon",width:e.iconWidth,height:e.iconHeight}),BI.isNumber(e.height)&&e.height>0&&BI.isNull(e.iconWidth)&&BI.isNull(e.iconHeight)?(this.element.css("lineHeight",e.height/BI.pixRatio+BI.pixUnit),BI.createWidget({type:"bi.default",element:this,items:[this.icon]})):(this.element.css("lineHeight","1"),BI.createWidget({element:this,type:"bi.center_adapt",items:[this.icon]}))},doClick:function(){BI.IconButton.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.IconButton.EVENT_CHANGE,this)}}),BI.IconButton.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.icon_button",BI.IconButton)},function(e,t){BI.ImageButton=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.ImageButton.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-image-button",src:"",iconWidth:"100%",iconHeight:"100%"})},_init:function(){BI.ImageButton.superclass._init.apply(this,arguments);var e=this.options;this.image=BI.createWidget({type:"bi.img",width:e.iconWidth,height:e.iconHeight,src:e.src}),BI.isNumber(e.iconWidth)||BI.isNumber(e.iconHeight)?BI.createWidget({type:"bi.center_adapt",element:this,items:[this.image]}):BI.createWidget({type:"bi.adaptive",element:this,items:[this.image],scrollable:!1})},setWidth:function(e){BI.ImageButton.superclass.setWidth.apply(this,arguments),this.options.width=e},setHeight:function(e){BI.ImageButton.superclass.setHeight.apply(this,arguments),this.options.height=e},setImageWidth:function(e){this.image.setWidth(e)},setImageHeight:function(e){this.image.setHeight(e)},getImageWidth:function(){return this.image.element.width()},getImageHeight:function(){return this.image.element.height()},setSrc:function(e){this.options.src=e,this.image.setSrc(e)},getSrc:function(){return this.image.getSrc()},doClick:function(){BI.ImageButton.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.ImageButton.EVENT_CHANGE,this)}}),BI.ImageButton.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.image_button",BI.ImageButton)},function(e,t){BI.Button=BI.inherit(BI.BasicButton,{_const:{iconWidth:18},_defaultConfig:function(e){var t=BI.Button.superclass._defaultConfig.apply(this,arguments);return BI.extend(t,{baseCls:(t.baseCls||"")+" bi-button"+(BI.isIE()&&BI.isIE9Below()?" hack":""),minWidth:!0===e.block||!0===e.clear?0:80,height:24,shadow:!0!==e.clear,isShadowShowingOnSelected:!0,readonly:!0,iconCls:"",level:"common",block:!1,clear:!1,ghost:!1,textAlign:"center",whiteSpace:"nowrap",textWidth:null,textHeight:null,hgap:e.clear?0:10,vgap:0,tgap:0,bgap:0,lgap:0,rgap:0})},_init:function(){BI.Button.superclass._init.apply(this,arguments);var e=this.options;BI.isKey(e.iconCls)?(this.icon=BI.createWidget({type:"bi.icon_label",cls:e.iconCls,width:this._const.iconWidth,height:e.height-2,iconWidth:e.iconWidth,iconHeight:e.iconHeight}),this.text=BI.createWidget({type:"bi.label",text:e.text,textWidth:BI.isNotNull(e.textWidth)?e.textWidth-this._const.iconWidth:null,textHeight:e.textHeight,value:e.value,height:e.height-2}),BI.createWidget({type:"bi.center_adapt",element:this,hgap:e.hgap,vgap:e.vgap,items:[{type:"bi.horizontal",columnSize:["","fill"],items:[this.icon,this.text]}]})):this.text=BI.createWidget({type:"bi.label",height:e.height,textAlign:e.textAlign,whiteSpace:e.whiteSpace,textWidth:e.textWidth,textHeight:e.textHeight,hgap:e.hgap,vgap:e.vgap,tgap:e.tgap,bgap:e.bgap,lgap:e.lgap,rgap:e.rgap,element:this,text:e.text,value:e.value}),!BI.isNumber(e.height)||e.clear||e.block?e.clear||e.block?this.element.css({lineHeight:e.height/BI.pixRatio+BI.pixUnit}):this.element.css({lineHeight:(e.height-2)/BI.pixRatio+BI.pixUnit}):this.element.css({height:e.height/BI.pixRatio+BI.pixUnit,lineHeight:(e.height-2)/BI.pixRatio+BI.pixUnit}),!0===e.block&&this.element.addClass("block"),!0===e.clear&&this.element.addClass("clear"),!0===e.ghost&&this.element.addClass("ghost"),e.minWidth>0&&this.element.css({"min-width":e.minWidth/BI.pixRatio+BI.pixUnit})},doClick:function(){BI.Button.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.Button.EVENT_CHANGE,this)},setText:function(e){BI.Button.superclass.setText.apply(this,arguments),this.text.setText(e)},setValue:function(e){BI.Button.superclass.setValue.apply(this,arguments),this.isReadOnly()||this.text.setValue(e)},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)}}),BI.shortcut("bi.button",BI.Button),BI.Button.EVENT_CHANGE="EVENT_CHANGE"},function(e,t){BI.TextButton=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.TextButton.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-text-button",textAlign:"center",whiteSpace:"nowrap",textWidth:null,textHeight:null,hgap:0,lgap:0,rgap:0,vgap:0,py:""})},_init:function(){BI.TextButton.superclass._init.apply(this,arguments);var e=this.options;this.text=BI.createWidget({type:"bi.label",element:this,textAlign:e.textAlign,whiteSpace:e.whiteSpace,textWidth:e.textWidth,textHeight:e.textHeight,width:e.width,height:e.height,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword})},doClick:function(){BI.TextButton.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.TextButton.EVENT_CHANGE,this.getValue(),this)},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},setText:function(e){BI.TextButton.superclass.setText.apply(this,arguments),e=BI.isArray(e)?e.join(","):e,this.text.setText(e)},setStyle:function(e){this.text.setStyle(e)},setValue:function(e){BI.TextButton.superclass.setValue.apply(this,arguments),this.isReadOnly()||(e=BI.isArray(e)?e.join(","):e,this.text.setValue(e))}}),BI.TextButton.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.text_button",BI.TextButton)},function(e,t){BI.BlankIconIconTextItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.BlankIconIconTextItem.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-blank-icon-text-item",logic:{dynamic:!1},iconCls1:"close-ha-font",iconCls2:"close-ha-font",blankWidth:0,iconHeight:null,iconWidth:null,textHgap:0,textVgap:0,textLgap:0,textRgap:0})},_init:function(){BI.BlankIconIconTextItem.superclass._init.apply(this,arguments);var e=this.options,t=(this._const,BI.createWidget({type:"bi.layout",width:e.blankWidth,height:e.height}));this.text=BI.createWidget({type:"bi.label",cls:"list-item-text",textAlign:"left",hgap:e.textHgap,vgap:e.textVgap,lgap:e.textLgap,rgap:e.textRgap,text:e.text,value:e.value,keyword:e.keyword,height:e.height}),this.icon1=BI.createWidget({type:"bi.icon_button",cls:e.iconCls1,forceNotSelected:!0,width:e.height,height:e.height}),this.icon2=BI.createWidget({type:"bi.icon_button",cls:e.iconCls2,forceNotSelected:!0,width:e.height,height:e.height}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("horizontal",BI.extend(e.logic,{items:BI.LogicFactory.createLogicItemsByDirection("left",t,this.icon1,this.icon2,this.text)}))))},doClick:function(){BI.BlankIconIconTextItem.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.BlankIconIconTextItem.EVENT_CHANGE,this.getValue(),this)},setSelected:function(e){BI.BlankIconIconTextItem.superclass.setSelected.apply(this,arguments),this.icon1.setSelected(e),this.icon2.setSelected(e)},setValue:function(){this.isReadOnly()||this.text.setValue.apply(this.text,arguments)},getValue:function(){return this.text.getValue()},setText:function(){this.text.setText.apply(this.text,arguments)},getText:function(){return this.text.getText()},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)}}),BI.BlankIconIconTextItem.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.blank_icon_icon_text_item",BI.BlankIconIconTextItem)},function(e,t){BI.BlankIconTextIconItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.BlankIconTextIconItem.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-blank-icon-text-icon-item",logic:{dynamic:!1},iconCls1:"close-ha-font",iconCls2:"close-ha-font",blankWidth:0,iconHeight:null,iconWidth:null,textHgap:0,textVgap:0,textLgap:0,textRgap:0})},_init:function(){BI.BlankIconTextIconItem.superclass._init.apply(this,arguments);var e=this.options;this._const;this.text=BI.createWidget({type:"bi.label",textAlign:"left",hgap:e.textHgap,vgap:e.textVgap,lgap:e.textLgap,rgap:e.textRgap,text:e.text,value:e.value,keyword:e.keyword,height:e.height});var t=BI.createWidget({type:"bi.icon_label",cls:e.iconCls1,width:e.height,height:e.height,iconWidth:e.iconWidth,iconHeight:e.iconHeight});BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.icon_label",cls:e.iconCls2,width:e.height,height:e.height,iconWidth:e.iconWidth,iconHeight:e.iconHeight},top:0,bottom:0,right:0}]}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("horizontal",BI.extend(e.logic,{items:BI.LogicFactory.createLogicItemsByDirection("left",{type:"bi.layout",width:e.blankWidth},t,this.text,{type:"bi.layout",width:e.height})}))))},doClick:function(){BI.BlankIconTextIconItem.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.BlankIconTextIconItem.EVENT_CHANGE,this.getValue(),this)},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},setValue:function(){this.isReadOnly()||this.text.setValue.apply(this.text,arguments)},getValue:function(){return this.text.getValue()},setText:function(){this.text.setText.apply(this.text,arguments)},getText:function(){return this.text.getText()}}),BI.BlankIconTextIconItem.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.blank_icon_text_icon_item",BI.BlankIconTextIconItem)},function(e,t){BI.BlankIconTextItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.BlankIconTextItem.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-blank-icon-text-item",logic:{dynamic:!1},cls:"close-ha-font",blankWidth:0,iconHeight:null,iconWidth:null,textHgap:0,textVgap:0,textLgap:0,textRgap:0})},_init:function(){BI.BlankIconTextItem.superclass._init.apply(this,arguments);var e=this.options,t=(this._const,BI.createWidget({type:"bi.layout",width:e.blankWidth}));this.text=BI.createWidget({type:"bi.label",cls:"list-item-text",textAlign:"left",hgap:e.textHgap,vgap:e.textVgap,lgap:e.textLgap,rgap:e.textRgap,text:e.text,value:e.value,keyword:e.keyword,height:e.height}),this.icon=BI.createWidget({type:"bi.icon_label",width:e.height,height:e.height,iconWidth:e.iconWidth,iconHeight:e.iconHeight}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("horizontal",BI.extend(e.logic,{items:BI.LogicFactory.createLogicItemsByDirection("left",t,this.icon,this.text)}))))},doClick:function(){BI.BlankIconTextItem.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.BlankIconTextItem.EVENT_CHANGE,this.getValue(),this)},setValue:function(){this.isReadOnly()||this.text.setValue.apply(this.text,arguments)},getValue:function(){return this.text.getValue()},setText:function(){this.text.setText.apply(this.text,arguments)},getText:function(){return this.text.getText()},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)}}),BI.BlankIconTextItem.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.blank_icon_text_item",BI.BlankIconTextItem)},function(e,t){BI.IconTextIconItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.IconTextIconItem.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-icon-text-icon-item",logic:{dynamic:!1},iconCls1:"close-ha-font",iconCls2:"close-ha-font",iconHeight:null,iconWidth:null,textHgap:0,textVgap:0,textLgap:0,textRgap:0})},_init:function(){BI.IconTextIconItem.superclass._init.apply(this,arguments);var e=this.options;this._const;this.text=BI.createWidget({type:"bi.label",textAlign:"left",hgap:e.textHgap,vgap:e.textVgap,lgap:e.textLgap,rgap:e.textRgap,text:e.text,value:e.value,keyword:e.keyword,height:e.height});var t=BI.createWidget({type:"bi.icon_label",cls:e.iconCls1,width:e.leftIconWrapperWidth,height:e.height,iconWidth:e.iconWidth,iconHeight:e.iconHeight}),n=BI.createWidget({type:"bi.layout",width:e.height});BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.icon_label",cls:e.iconCls2,width:e.rightIconWrapperWidth,height:e.height,iconWidth:e.iconWidth,iconHeight:e.iconHeight},top:0,bottom:0,right:0}]}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("horizontal",BI.extend(e.logic,{items:BI.LogicFactory.createLogicItemsByDirection("left",t,this.text,n)}))))},doClick:function(){BI.IconTextIconItem.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.IconTextIconItem.EVENT_CHANGE,this.getValue(),this)},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},setValue:function(){this.isReadOnly()||this.text.setValue.apply(this.text,arguments)},getValue:function(){return this.text.getValue()},setText:function(){this.text.setText.apply(this.text,arguments)},getText:function(){return this.text.getText()}}),BI.IconTextIconItem.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.icon_text_icon_item",BI.IconTextIconItem)},function(e,t){BI.IconTextItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.IconTextItem.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-icon-text-item",direction:BI.Direction.Left,logic:{dynamic:!1},iconWrapperWidth:null,iconHeight:null,iconWidth:null,textHgap:0,textVgap:0,textLgap:0,textRgap:0})},_init:function(){BI.IconTextItem.superclass._init.apply(this,arguments);var e=this.options;this._const;this.text=BI.createWidget({type:"bi.label",cls:"list-item-text",textAlign:"left",hgap:e.textHgap,vgap:e.textVgap,lgap:e.textLgap,rgap:e.textRgap,text:e.text,value:e.value,keyword:e.keyword,height:e.height}),this.icon=BI.createWidget({type:"bi.icon_label",width:e.iconWrapperWidth||e.height,height:e.height,iconWidth:e.iconWidth,iconHeight:e.iconHeight}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(e.direction),BI.extend(e.logic,{items:BI.LogicFactory.createLogicItemsByDirection(e.direction,this.icon,this.text)}))))},setValue:function(){this.isReadOnly()||this.text.setValue.apply(this.text,arguments)},getValue:function(){return this.text.getValue()},setText:function(){this.text.setText.apply(this.text,arguments)},getText:function(){return this.text.getText()},doClick:function(){BI.IconTextItem.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.IconTextItem.EVENT_CHANGE,this.getValue(),this)},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)}}),BI.IconTextItem.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.icon_text_item",BI.IconTextItem)},function(e,t){BI.TextIconItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.TextIconItem.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-text-icon-item",logic:{dynamic:!1},cls:"close-ha-font",iconHeight:null,iconWidth:null,textHgap:0,textVgap:0,textLgap:0,textRgap:0})},_init:function(){BI.TextIconItem.superclass._init.apply(this,arguments);var e=this.options;this._const;this.text=BI.createWidget({type:"bi.label",cls:"list-item-text",textAlign:"left",hgap:e.textHgap,vgap:e.textVgap,lgap:e.textLgap,rgap:e.textRgap,text:e.text,value:e.value,keyword:e.keyword,height:e.height}),this.icon=BI.createWidget({type:"bi.icon_label",width:e.height,height:e.height,iconWidth:e.iconWidth,iconHeight:e.iconHeight}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("horizontal",BI.extend(e.logic,{items:BI.LogicFactory.createLogicItemsByDirection("left",this.text,this.icon)}))))},doClick:function(){BI.TextIconItem.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.TextIconItem.EVENT_CHANGE,this.getValue(),this)},setValue:function(){this.isReadOnly()||this.text.setValue.apply(this.text,arguments)},getValue:function(){return this.text.getValue()},setText:function(){this.text.setText.apply(this.text,arguments)},getText:function(){return this.text.getText()},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)}}),BI.TextIconItem.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.text_icon_item",BI.TextIconItem)},function(e,t){BI.TextItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.TextItem.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-text-item",textAlign:"left",whiteSpace:"nowrap",textHgap:0,textVgap:0,textLgap:0,textRgap:0})},_init:function(){BI.TextItem.superclass._init.apply(this,arguments);var e=this.options;this.text=BI.createWidget({type:"bi.label",element:this,textAlign:e.textAlign,whiteSpace:e.whiteSpace,textHeight:"nowrap"==e.whiteSpace?e.height:e.textHeight,height:e.height,hgap:e.textHgap,vgap:e.textVgap,lgap:e.textLgap,rgap:e.textRgap,text:e.text,value:e.value,keyword:e.keyword,py:e.py})},doClick:function(){BI.TextItem.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.TextItem.EVENT_CHANGE,this.getValue(),this)},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},setValue:function(){this.isReadOnly()||this.text.setValue.apply(this.text,arguments)},getValue:function(){return this.text.getValue()},setText:function(){this.text.setText.apply(this.text,arguments)},getText:function(){return this.text.getText()}}),BI.TextItem.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.text_item",BI.TextItem)},function(e,t){BI.IconTextIconNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.IconTextIconNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-icon-text-icon-node",logic:{dynamic:!1},iconCls1:"close-ha-font",iconCls2:"close-ha-font",iconHeight:null,iconWidth:null,textHgap:0,textVgap:0,textLgap:0,textRgap:0})},_init:function(){BI.IconTextIconNode.superclass._init.apply(this,arguments);var e=this.options;this._const;this.text=BI.createWidget({type:"bi.label",textAlign:"left",hgap:e.textHgap,vgap:e.textVgap,lgap:e.textLgap,rgap:e.textRgap,text:e.text,value:e.value,keyword:e.keyword,height:e.height});var t=BI.createWidget({type:"bi.icon_label",cls:e.iconCls1,width:e.height,height:e.height,iconWidth:e.iconWidth,iconHeight:e.iconHeight}),n=BI.createWidget({type:"bi.layout",width:e.height,height:e.height});BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.icon_label",cls:e.iconCls2,width:e.height,iconWidth:e.iconWidth,iconHeight:e.iconHeight},top:0,bottom:0,right:0}]}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("horizontal",BI.extend(e.logic,{items:BI.LogicFactory.createLogicItemsByDirection("left",t,this.text,n)}))))},doClick:function(){BI.IconTextIconNode.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.IconTextIconNode.EVENT_CHANGE,this.getValue(),this)},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},setValue:function(){this.isReadOnly()||this.text.setValue.apply(this.text,arguments)},getValue:function(){return this.text.getValue()},setText:function(){this.text.setText.apply(this.text,arguments)},getText:function(){return this.text.getText()}}),BI.IconTextIconNode.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.icon_text_icon_node",BI.IconTextIconNode)},function(e,t){BI.IconTextNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.IconTextNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-icon-text-node",logic:{dynamic:!1},cls:"close-ha-font",iconHeight:null,iconWidth:null,textHgap:0,textVgap:0,textLgap:0,textRgap:0})},_init:function(){BI.IconTextNode.superclass._init.apply(this,arguments);var e=this.options;this._const;this.text=BI.createWidget({type:"bi.label",cls:"list-item-text",textAlign:"left",hgap:e.textHgap,vgap:e.textVgap,lgap:e.textLgap,rgap:e.textRgap,text:e.text,value:e.value,keyword:e.keyword,height:e.height}),this.icon=BI.createWidget({type:"bi.icon_label",width:e.height,height:e.height,iconWidth:e.iconWidth,iconHeight:e.iconHeight}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("horizontal",BI.extend(e.logic,{items:BI.LogicFactory.createLogicItemsByDirection("left",this.icon,this.text)}))))},setValue:function(){this.isReadOnly()||this.text.setValue.apply(this.text,arguments)},getValue:function(){return this.text.getValue()},setText:function(){this.text.setText.apply(this.text,arguments)},getText:function(){return this.text.getText()},doClick:function(){BI.IconTextNode.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.IconTextNode.EVENT_CHANGE,this.getValue(),this)},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)}}),BI.IconTextNode.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.icon_text_node",BI.IconTextNode)},function(e,t){BI.TextIconNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.TextIconNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-text-icon-node",logic:{dynamic:!1},cls:"close-ha-font",iconHeight:null,iconWidth:null,textHgap:0,textVgap:0,textLgap:0,textRgap:0})},_init:function(){BI.TextIconNode.superclass._init.apply(this,arguments);var e=this.options;this._const;this.text=BI.createWidget({type:"bi.label",cls:"list-item-text",textAlign:"left",hgap:e.textHgap,vgap:e.textVgap,lgap:e.textLgap,rgap:e.textRgap,text:e.text,value:e.value,keyword:e.keyword,height:e.height}),this.icon=BI.createWidget({type:"bi.icon_label",width:e.height,height:e.height,iconWidth:e.iconWidth,iconHeight:e.iconHeight}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("horizontal",BI.extend(e.logic,{items:BI.LogicFactory.createLogicItemsByDirection("left",this.text,this.icon)}))))},doClick:function(){BI.TextIconNode.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.TextIconNode.EVENT_CHANGE,this.getValue(),this)},setValue:function(){this.isReadOnly()||this.text.setValue.apply(this.text,arguments)},getValue:function(){return this.text.getValue()},setText:function(){this.text.setText.apply(this.text,arguments)},getText:function(){return this.text.getText()},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)}}),BI.TextIconNode.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.text_icon_node",BI.TextIconNode)},function(e,t){BI.TextNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.TextNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-text-node",textAlign:"left",whiteSpace:"nowrap",textHgap:0,textVgap:0,textLgap:0,textRgap:0})},_init:function(){BI.TextNode.superclass._init.apply(this,arguments);var e=this.options;this.text=BI.createWidget({type:"bi.label",element:this,textAlign:e.textAlign,whiteSpace:e.whiteSpace,textHeight:"nowrap"==e.whiteSpace?e.height:e.textHeight,height:e.height,hgap:e.textHgap,vgap:e.textVgap,lgap:e.textLgap,rgap:e.textRgap,text:e.text,value:e.value,keyword:e.keyword,py:e.py})},doClick:function(){BI.TextNode.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.TextNode.EVENT_CHANGE,this.getValue(),this)},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},setValue:function(){this.isReadOnly()||this.text.setValue.apply(this.text,arguments)},getValue:function(){return this.text.getValue()},setText:function(){this.text.setText.apply(this.text,arguments)},getText:function(){return this.text.getText()}}),BI.TextNode.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.text_node",BI.TextNode)},function(e,t){BI.Editor=BI.inherit(BI.Single,{_defaultConfig:function(){var e=BI.Editor.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:"bi-editor bi-focus-shadow",hgap:4,vgap:2,lgap:0,rgap:0,tgap:0,bgap:0,tipType:"warning",inputType:"text",validationChecker:BI.emptyFn,quitChecker:BI.emptyFn,allowBlank:!1,watermark:"",errorText:""})},_init:function(){BI.Editor.superclass._init.apply(this,arguments);var e=this,t=this.options,n=t.autocomplete?" autocomplete="+t.autocomplete:"";this.editor=this.addWidget(BI.createWidget({type:"bi.input",element:"<input type='"+t.inputType+"'"+n+" />",root:!0,value:t.value,watermark:t.watermark,validationChecker:t.validationChecker,quitChecker:t.quitChecker,allowBlank:t.allowBlank})),this.editor.element.css({width:"100%",height:"100%",border:"none",outline:"none",padding:"0",margin:"0"});var i=[{el:{type:"bi.absolute",ref:function(t){e.contentWrapper=t},items:[{el:this.editor,left:0,right:0,top:0,bottom:0}]},left:t.hgap+t.lgap,right:t.hgap+t.rgap,top:t.vgap+t.tgap,bottom:t.vgap+t.bgap}];BI.createWidget({type:"bi.absolute",element:this,items:i}),this.setWaterMark(this.options.watermark),this.editor.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.editor.on(BI.Input.EVENT_FOCUS,(function(){e._checkError(),e.element.addClass("bi-editor-focus"),e.fireEvent(BI.Editor.EVENT_FOCUS,arguments)})),this.editor.on(BI.Input.EVENT_BLUR,(function(){e._setErrorVisible(!1),e.element.removeClass("bi-editor-focus"),e.fireEvent(BI.Editor.EVENT_BLUR,arguments)})),this.editor.on(BI.Input.EVENT_CLICK,(function(){e.fireEvent(BI.Editor.EVENT_CLICK,arguments)})),this.editor.on(BI.Input.EVENT_CHANGE,(function(){e.fireEvent(BI.Editor.EVENT_CHANGE,arguments)})),this.editor.on(BI.Input.EVENT_KEY_DOWN,(function(t){e.fireEvent(BI.Editor.EVENT_KEY_DOWN,arguments)})),this.editor.on(BI.Input.EVENT_QUICK_DOWN,(function(t){t.keyCode!==BI.KeyCode.TAB&&e.watermark&&e.watermark.invisible()})),this.editor.on(BI.Input.EVENT_VALID,(function(){e._checkWaterMark(),e._setErrorVisible(!1),e.fireEvent(BI.Editor.EVENT_VALID,arguments)})),this.editor.on(BI.Input.EVENT_ERROR,(function(){e._checkWaterMark(),e.fireEvent(BI.Editor.EVENT_ERROR,arguments),e._setErrorVisible(e.isEditing())})),this.editor.on(BI.Input.EVENT_RESTRICT,(function(){e._checkWaterMark();var t=e._setErrorVisible(!0);t&&t.element.fadeOut(100,(function(){t.element.fadeIn(100)})),e.fireEvent(BI.Editor.EVENT_RESTRICT,arguments)})),this.editor.on(BI.Input.EVENT_EMPTY,(function(){e._checkWaterMark(),e.fireEvent(BI.Editor.EVENT_EMPTY,arguments)})),this.editor.on(BI.Input.EVENT_ENTER,(function(){e.fireEvent(BI.Editor.EVENT_ENTER,arguments)})),this.editor.on(BI.Input.EVENT_SPACE,(function(){e.fireEvent(BI.Editor.EVENT_SPACE,arguments)})),this.editor.on(BI.Input.EVENT_BACKSPACE,(function(){e.fireEvent(BI.Editor.EVENT_BACKSPACE,arguments)})),this.editor.on(BI.Input.EVENT_REMOVE,(function(){e.fireEvent(BI.Editor.EVENT_REMOVE,arguments)})),this.editor.on(BI.Input.EVENT_START,(function(){e.fireEvent(BI.Editor.EVENT_START,arguments)})),this.editor.on(BI.Input.EVENT_PAUSE,(function(){e.fireEvent(BI.Editor.EVENT_PAUSE,arguments)})),this.editor.on(BI.Input.EVENT_STOP,(function(){e.fireEvent(BI.Editor.EVENT_STOP,arguments)})),this.editor.on(BI.Input.EVENT_CONFIRM,(function(){e.fireEvent(BI.Editor.EVENT_CONFIRM,arguments)})),this.editor.on(BI.Input.EVENT_CHANGE_CONFIRM,(function(){e.fireEvent(BI.Editor.EVENT_CHANGE_CONFIRM,arguments)})),this.element.click((function(e){return e.stopPropagation(),!1})),BI.isKey(this.options.value)||BI.isEmptyString(this.options.value)?(this._checkError(),this._checkWaterMark()):this._checkWaterMark()},_checkToolTip:function(){var e=this.options.errorText;BI.isFunction(e)&&(e=e(this.editor.getValue())),BI.isKey(e)&&(!this.isEnabled()||this.isValid()||BI.Bubbles.has(this.getName())&&BI.Bubbles.get(this.getName()).isVisible()?this.setTitle(""):this.setTitle(e))},_assertWaterMark:function(){var e=this,t=this.options;BI.isNull(this.watermark)&&(this.watermark=BI.createWidget({type:"bi.label",cls:"bi-water-mark",text:this.options.watermark,height:t.height-2*t.vgap-t.tgap,hgap:2,whiteSpace:"nowrap",textAlign:"left"}),this.watermark.element.bind({mousedown:function(t){e.isEnabled()?e.editor.isEditing()||e.editor.focus():e.editor.isEditing()&&e.editor.blur(),t.stopEvent()}}),this.watermark.element.bind("click",(function(t){e.isEnabled()?e.editor.isEditing()||e.editor.focus():e.editor.isEditing()&&e.editor.blur(),t.stopEvent()})))},_checkError:function(){this._setErrorVisible(this.isEnabled()&&!this.isValid()),this._checkToolTip()},_checkWaterMark:function(){var e=this.options;!this.disabledWaterMark&&""===this.editor.getValue()&&BI.isKey(e.watermark)?this.watermark&&this.watermark.visible():this.watermark&&this.watermark.invisible()},setErrorText:function(e){this.options.errorText=e},getErrorText:function(){return this.options.errorText},setWaterMark:function(e){BI.isKey(e)&&(this.options.watermark=e,BI.isNull(this.watermark)&&(this._assertWaterMark(),BI.createWidget({type:"bi.absolute",element:this.contentWrapper,items:[{el:this.watermark,left:0,right:0,top:0,bottom:0}]})),this.watermark.setText(e))},_setErrorVisible:function(e){var t=this.options.errorText;if(BI.isFunction(t)&&(t=t(BI.trim(this.editor.getValue()))),!this.disabledError&&BI.isKey(t))return BI.Bubbles[e?"show":"hide"](this.getName(),t,this,{adjustYOffset:2}),this._checkToolTip(),BI.Bubbles.get(this.getName())},disableError:function(){this.disabledError=!0,this._checkError()},enableError:function(){this.disabledError=!1,this._checkError()},disableWaterMark:function(){this.disabledWaterMark=!0,this._checkWaterMark()},enableWaterMark:function(){this.disabledWaterMark=!1,this._checkWaterMark()},focus:function(){this.element.addClass("text-editor-focus"),this.editor.focus()},blur:function(){this.element.removeClass("text-editor-focus"),this.editor.blur()},selectAll:function(){this.editor.selectAll()},onKeyDown:function(e){this.editor.onKeyDown(e)},setValue:function(e){BI.Editor.superclass.setValue.apply(this,arguments),this.editor.setValue(e),this._checkError(),this._checkWaterMark()},getLastValidValue:function(){return this.editor.getLastValidValue()},getLastChangedValue:function(){return this.editor.getLastChangedValue()},getValue:function(){return this.isValid()?BI.trim(this.editor.getValue()):BI.trim(this.editor.getLastValidValue())},isEditing:function(){return this.editor.isEditing()},isValid:function(){return this.editor.isValid()},destroyed:function(){BI.Bubbles.remove(this.getName())}}),BI.Editor.EVENT_CHANGE="EVENT_CHANGE",BI.Editor.EVENT_FOCUS="EVENT_FOCUS",BI.Editor.EVENT_BLUR="EVENT_BLUR",BI.Editor.EVENT_CLICK="EVENT_CLICK",BI.Editor.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.Editor.EVENT_SPACE="EVENT_SPACE",BI.Editor.EVENT_BACKSPACE="EVENT_BACKSPACE",BI.Editor.EVENT_START="EVENT_START",BI.Editor.EVENT_PAUSE="EVENT_PAUSE",BI.Editor.EVENT_STOP="EVENT_STOP",BI.Editor.EVENT_CONFIRM="EVENT_CONFIRM",BI.Editor.EVENT_CHANGE_CONFIRM="EVENT_CHANGE_CONFIRM",BI.Editor.EVENT_VALID="EVENT_VALID",BI.Editor.EVENT_ERROR="EVENT_ERROR",BI.Editor.EVENT_ENTER="EVENT_ENTER",BI.Editor.EVENT_RESTRICT="EVENT_RESTRICT",BI.Editor.EVENT_REMOVE="EVENT_REMOVE",BI.Editor.EVENT_EMPTY="EVENT_EMPTY",BI.shortcut("bi.editor",BI.Editor)},function(e,t){BI.MultifileEditor=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.MultifileEditor.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-multifile-editor",multiple:!1,maxSize:-1,accept:"",url:""})},_init:function(){var e=this,t=this.options;BI.MultifileEditor.superclass._init.apply(this,arguments),this.file=BI.createWidget({type:"bi.file",cls:"multifile-editor",width:"100%",height:"100%",name:t.name,url:t.url,multiple:t.multiple,accept:t.accept,maxSize:t.maxSize,maxLength:t.maxLength,title:t.title}),this.file.on(BI.File.EVENT_CHANGE,(function(){e.fireEvent(BI.MultifileEditor.EVENT_CHANGE,arguments)})),this.file.on(BI.File.EVENT_UPLOADSTART,(function(){e.fireEvent(BI.MultifileEditor.EVENT_UPLOADSTART,arguments)})),this.file.on(BI.File.EVENT_ERROR,(function(){e.fireEvent(BI.MultifileEditor.EVENT_ERROR,arguments)})),this.file.on(BI.File.EVENT_PROGRESS,(function(){e.fireEvent(BI.MultifileEditor.EVENT_PROGRESS,arguments)})),this.file.on(BI.File.EVENT_UPLOADED,(function(){e.fireEvent(BI.MultifileEditor.EVENT_UPLOADED,arguments)})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.adaptive",scrollable:!1,items:[this.file]},top:0,right:0,left:0,bottom:0}]})},_reset:function(){this.file.reset()},setMaxFileLength:function(e){this.file.setMaxFileLength(e)},select:function(){this.file.select()},getValue:function(){return this.file.getValue()},upload:function(){this._reset(),this.file.upload()},reset:function(){this._reset()}}),BI.MultifileEditor.EVENT_CHANGE="EVENT_CHANGE",BI.MultifileEditor.EVENT_UPLOADSTART="EVENT_UPLOADSTART",BI.MultifileEditor.EVENT_ERROR="EVENT_ERROR",BI.MultifileEditor.EVENT_PROGRESS="EVENT_PROGRESS",BI.MultifileEditor.EVENT_UPLOADED="EVENT_UPLOADED",BI.shortcut("bi.multifile_editor",BI.MultifileEditor)},function(e,t){BI.TextAreaEditor=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.TextAreaEditor.superclass._defaultConfig.apply(),{baseCls:"bi-textarea-editor",value:"",errorText:"",adjustYOffset:2,adjustXOffset:0,offsetStyle:"left",validationChecker:function(){return!0},scrolly:!0})},render:function(){var e=this.options,t=this;this.content=BI.createWidget({type:"bi.layout",tagName:"textarea",width:"100%",height:"100%",cls:"bi-textarea textarea-editor-content display-block",css:e.scrolly?null:{overflowY:"hidden"}}),this.content.element.css({resize:"none"}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.adaptive",items:[this.content]},left:4,right:4,top:2,bottom:2}]}),this.content.element.on("input propertychange",(function(e){t._checkError(),t._checkWaterMark(),t.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.CHANGE,t.getValue(),t),t.fireEvent(BI.TextAreaEditor.EVENT_CHANGE),BI.isEmptyString(t.getValue())&&t.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EMPTY,t.getValue(),t)})),this.content.element.focus((function(){t._checkError(),t._focus(),t.fireEvent(BI.TextAreaEditor.EVENT_FOCUS),BI.Widget._renderEngine.createElement(document).bind("mousedown."+t.getName(),(function(e){BI.DOM.isExist(t)&&!t.element.__isMouseInBounds__(e)&&(BI.Widget._renderEngine.createElement(document).unbind("mousedown."+t.getName()),t.content.element.blur())}))})),this.content.element.blur((function(){t._setErrorVisible(!1),t._blur(),t._isError()||t.fireEvent(BI.TextAreaEditor.EVENT_CONFIRM),t.fireEvent(BI.TextAreaEditor.EVENT_BLUR),BI.Widget._renderEngine.createElement(document).unbind("mousedown."+t.getName())})),this.content.element.keydown((function(){t._checkWaterMark()})),this.content.element.keyup((function(e){t.fireEvent(BI.TextAreaEditor.EVENT_KEY_DOWN,e.keyCode)})),this.content.element.click((function(e){e.stopPropagation()})),BI.isKey(e.value)&&this.setValue(e.value),BI.isNotNull(e.style)&&this.setStyle(e.style),this._checkWaterMark()},_checkWaterMark:function(){var e=this,t=this.options,n=this.getValue();BI.isNotEmptyString(n)?(this.watermark&&this.watermark.destroy(),this.watermark=null):BI.isNotEmptyString(t.watermark)&&(this.watermark?(this.watermark.setText(t.watermark),this.watermark.setValid(!t.invalid),this.watermark.setEnable(!t.disabled)):(this.watermark=BI.createWidget({type:"bi.label",cls:"bi-water-mark textarea-watermark",textAlign:"left",whiteSpace:t.scrolly?"normal":"nowrap",title:t.watermark,text:t.watermark,invalid:t.invalid,disabled:t.disabled,hgap:6,vgap:t.height>24?4:2,height:t.height>24?"":t.height}),this.watermark.element.bind({mousedown:function(t){e.isEnabled()?e.focus():e.blur(),t.stopEvent()},click:function(e){e.stopPropagation()}}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.watermark,left:0,top:0,right:0}]})))},_isError:function(){return this.isEnabled()&&!this.options.validationChecker(this.getValue())},_checkError:function(){this._setErrorVisible(this._isError())},_focus:function(){this.content.element.addClass("textarea-editor-focus"),this._checkWaterMark(),BI.isEmptyString(this.getValue())&&this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EMPTY,this.getValue(),this)},_blur:function(){this.content.element.removeClass("textarea-editor-focus"),this._checkWaterMark()},_setErrorVisible:function(e){var t=this.options,n=t.errorText;if(BI.isFunction(n)&&(n=n(BI.trim(this.getValue()))),!this.disabledError&&BI.isKey(n))return BI.Bubbles[e?"show":"hide"](this.getName(),n,this,{adjustYOffset:t.adjustYOffset,adjustXOffset:t.adjustXOffset,offsetStyle:t.offsetStyle}),BI.Bubbles.get(this.getName())},_defaultState:function(){BI.isEmptyString(this.getValue())&&(this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EMPTY,this.getValue(),this),this.fireEvent(BI.TextAreaEditor.EVENT_EMPTY))},focus:function(){this._focus(),this.content.element.focus()},blur:function(){this._blur(),this.content.element.blur()},getValue:function(){return this.content.element.val()},setValue:function(e){this.content.element.val(e),this._checkError(),this._checkWaterMark(),this._defaultState()},setStyle:function(e){this.style=e,this.element.css(e),this.content.element.css(BI.extend({},e,{color:e.color||BI.DOM.getContrastColor(BI.DOM.isRGBColor(e.backgroundColor)?BI.DOM.rgb2hex(e.backgroundColor):e.backgroundColor)}))},getStyle:function(){return this.style},setWatermark:function(e){this.options.watermark=e,this._checkWaterMark()},_setValid:function(e){BI.TextAreaEditor.superclass._setValid.apply(this,arguments)},_setEnable:function(e){BI.TextAreaEditor.superclass._setEnable.apply(this,[e]),this.content&&(this.content.element[0].disabled=!e)}}),BI.TextAreaEditor.EVENT_CHANGE="EVENT_CHANGE",BI.TextAreaEditor.EVENT_BLUR="EVENT_BLUR",BI.TextAreaEditor.EVENT_FOCUS="EVENT_FOCUS",BI.TextAreaEditor.EVENT_CONFIRM="EVENT_CONFIRM",BI.TextAreaEditor.EVENT_EMPTY="EVENT_EMPTY",BI.TextAreaEditor.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.shortcut("bi.textarea_editor",BI.TextAreaEditor)},function(e,t){BI.Html=BI.inherit(BI.Single,{props:{baseCls:"bi-html",textAlign:"left",whiteSpace:"normal",lineHeight:null,handler:null,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0,text:"",highLight:!1},render:function(){var e=this,t=this.options;t.hgap+t.lgap>0&&this.element.css({"padding-left":(t.hgap+t.lgap)/BI.pixRatio+BI.pixUnit}),t.hgap+t.rgap>0&&this.element.css({"padding-right":(t.hgap+t.rgap)/BI.pixRatio+BI.pixUnit}),t.vgap+t.tgap>0&&this.element.css({"padding-top":(t.vgap+t.tgap)/BI.pixRatio+BI.pixUnit}),t.vgap+t.bgap>0&&this.element.css({"padding-bottom":(t.vgap+t.bgap)/BI.pixRatio+BI.pixUnit}),BI.isNumber(t.height)&&this.element.css({lineHeight:t.height/BI.pixRatio+BI.pixUnit}),BI.isNumber(t.lineHeight)&&this.element.css({lineHeight:t.lineHeight/BI.pixRatio+BI.pixUnit}),BI.isWidthOrHeight(t.maxWidth)&&this.element.css({maxWidth:t.maxWidth}),this.element.css({textAlign:t.textAlign,whiteSpace:t.whiteSpace,textOverflow:"nowrap"===t.whiteSpace?"ellipsis":"",overflow:"nowrap"===t.whiteSpace?"":"auto"}),t.handler?(this.text=BI.createWidget({type:"bi.layout",tagName:"span"}),this.text.element.click((function(){t.handler(e.getValue())})),BI.createWidget({type:"bi.default",element:this,items:[this.text]})):this.text=this,BI.isKey(t.text)?this.setText(t.text):BI.isKey(t.value)&&this.setText(t.value),t.highLight&&this.doHighLight()},doHighLight:function(){this.text.element.addClass("bi-high-light")},unHighLight:function(){this.text.element.removeClass("bi-high-light")},setValue:function(e){BI.Html.superclass.setValue.apply(this,arguments),this.isReadOnly()||this.setText(e)},setStyle:function(e){this.text.element.css(e)},setText:function(e){BI.Html.superclass.setText.apply(this,arguments),this.options.text=e,this.text.element.html(e)}}),BI.shortcut("bi.html",BI.Html)},function(e,t){BI.Icon=BI.inherit(BI.Single,{_defaultConfig:function(){var e=BI.Icon.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{tagName:"i",baseCls:(e.baseCls||"")+" x-icon b-font horizon-center display-block"})},_init:function(){BI.Icon.superclass._init.apply(this,arguments),BI.isIE9Below&&BI.isIE9Below()&&this.element.addClass("hack")}}),BI.shortcut("bi.icon",BI.Icon)},function(e,t){BI.Iframe=BI.inherit(BI.Single,{_defaultConfig:function(e){var t=BI.Iframe.superclass._defaultConfig.apply(this,arguments);return BI.extend(t,{tagName:"iframe",baseCls:(t.baseCls||"")+" bi-iframe",src:"",name:"",attributes:{},width:"100%",height:"100%"})},_init:function(){var e=this;BI.Iframe.superclass._init.apply(this,arguments),this.element.on("load",(function(){e.fireEvent("EVENT_LOADED")}))},_initProps:function(){BI.Iframe.superclass._initProps.apply(this,arguments);var e=this.options;this.options.attributes=BI.extend({frameborder:0,src:e.src,name:e.name},this.options.attributes)},setSrc:function(e){this.options.src=e,this.element.attr("src",e)},getSrc:function(){return this.options.src},setName:function(e){this.options.name=e,this.element.attr("name",e)},getName:function(){return this.options.name}}),BI.shortcut("bi.iframe",BI.Iframe)},function(e,t){BI.Img=BI.inherit(BI.Single,{_defaultConfig:function(e){var t=BI.Img.superclass._defaultConfig.apply(this,arguments);return BI.extend(t,{tagName:"img",baseCls:(t.baseCls||"")+" bi-img display-block",src:"",attributes:e.src?{src:e.src}:{},width:"100%",height:"100%"})},_initProps:function(){BI.Img.superclass._initProps.apply(this,arguments);var e=this.options;this.options.attributes=BI.extend({src:e.src},this.options.attributes)},setSrc:function(e){this.options.src=e,this.element.attr("src",e)},getSrc:function(){return this.options.src}}),BI.shortcut("bi.img",BI.Img)},function(e,t){BI.ImageCheckbox=BI.inherit(BI.IconButton,{_defaultConfig:function(){var e=BI.ImageCheckbox.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-image-checkbox check-box-icon",selected:!1,handler:BI.emptyFn,width:16,height:16,iconWidth:16,iconHeight:16})}}),BI.ImageCheckbox.EVENT_CHANGE=BI.IconButton.EVENT_CHANGE,BI.shortcut("bi.image_checkbox",BI.ImageCheckbox)},function(e,t){BI.Checkbox=BI.inherit(BI.BasicButton,{props:{baseCls:"bi-checkbox",selected:!1,handler:BI.emptyFn,width:16,height:16,iconWidth:16,iconHeight:16},render:function(){var e=this,t=this.options;return{type:"bi.center_adapt",items:[{type:"bi.default",ref:function(t){e.checkbox=t},cls:"checkbox-content",width:t.iconWidth-2,height:t.iconHeight-2}]}},_setEnable:function(e){BI.Checkbox.superclass._setEnable.apply(this,arguments),!0===e?this.checkbox.element.removeClass("base-disabled disabled"):this.checkbox.element.addClass("base-disabled disabled")},doClick:function(){BI.Checkbox.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.Checkbox.EVENT_CHANGE)},setSelected:function(e){BI.Checkbox.superclass.setSelected.apply(this,arguments),e?this.checkbox.element.addClass("bi-high-light-background"):this.checkbox.element.removeClass("bi-high-light-background")}}),BI.Checkbox.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.checkbox",BI.Checkbox)},function(e,t){BI.Input=BI.inherit(BI.Single,{_defaultConfig:function(){var e=BI.Input.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-input display-block overflow-dot",tagName:"input",validationChecker:BI.emptyFn,quitChecker:BI.emptyFn,allowBlank:!1})},_init:function(){BI.Input.superclass._init.apply(this,arguments);var e=this,t=!1,n=null,i=!1,r=BI.debounce((function(n){e.onKeyDown(n,t),e._keydown_=!1}),300),a=BI.debounce(BI.bind(this._click,this),BI.EVENT_RESPONSE_TIME,{leading:!0,trailing:!1});this._focusDebounce=BI.debounce(BI.bind(this._focus,this),BI.EVENT_RESPONSE_TIME,{leading:!0,trailing:!1}),this._blurDebounce=BI.debounce(BI.bind(this._blur,this),BI.EVENT_RESPONSE_TIME,{leading:!0,trailing:!1}),this.element.keydown((function(r){i=!1,t=r.ctrlKey||r.metaKey,n=r.keyCode,e.fireEvent(BI.Input.EVENT_QUICK_DOWN,arguments)})).keyup((function(t){n=null,i&&t.keyCode===BI.KeyCode.ENTER||(e._keydown_=!0,r(t.keyCode))})).on("input propertychange",(function(t){var a=t.originalEvent;(BI.isNull(a.propertyName)||"value"===a.propertyName)&&(i=!0,e._keydown_=!0,r(n),n=null)})).click((function(e){e.stopPropagation(),a()})).mousedown((function(t){e.element.val(e.element.val())})).focus((function(t){e._focusDebounce()})).blur((function(t){e._blurDebounce()})),(BI.isKey(this.options.value)||BI.isEmptyString(this.options.value))&&this.setValue(this.options.value)},_focus:function(){this.element.addClass("bi-input-focus"),this._checkValidationOnValueChange(),this._isEditing=!0,""==this.getValue()&&(this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EMPTY,this.getValue(),this),this.fireEvent(BI.Input.EVENT_EMPTY)),this.fireEvent(BI.Input.EVENT_FOCUS)},_blur:function(){var e=this;function t(){if(e.isValid()||!1===e.options.quitChecker.apply(e,[BI.trim(e.getValue())])||(e.element.val(e._lastValidValue?e._lastValidValue:""),e._checkValidationOnValueChange(),e._defaultState()),e.element.removeClass("bi-input-focus"),e._isEditing=!1,e._start=!1,e.isValid()){var t=e._lastValidValue;e._lastValidValue=e.getValue(),e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.CONFIRM,e.getValue(),e),e.fireEvent(BI.Input.EVENT_CONFIRM),e._lastValidValue!==t&&e.fireEvent(BI.Input.EVENT_CHANGE_CONFIRM)}e.fireEvent(BI.Input.EVENT_BLUR)}!0===e._keydown_?BI.delay(t,300):t()},_click:function(){!0!==this._isEditing&&(this.selectAll(),this.fireEvent(BI.Input.EVENT_CLICK))},onClick:function(){this._click()},onKeyDown:function(e,t){this.isValid()&&BI.trim(this._lastChangedValue)===BI.trim(this.getValue())||this._checkValidationOnValueChange(),this.isValid()&&""!==BI.trim(this.getValue())&&((BI.trim(this.getValue())===this._lastValue||this._start&&null!=this._lastValue&&""!==this._lastValue)&&(!0!==this._pause||/(\s|\u00A0)$/.test(this.getValue()))||(this._start=!0,this._pause=!1,this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.STARTEDIT,this.getValue(),this),this.fireEvent(BI.Input.EVENT_START))),e==BI.KeyCode.ENTER&&(this.isValid()||!1!==this.options.quitChecker.apply(this,[BI.trim(this.getValue())])?(this.blur(),this.fireEvent(BI.Input.EVENT_ENTER)):this.fireEvent(BI.Input.EVENT_RESTRICT)),e==BI.KeyCode.SPACE&&this.fireEvent(BI.Input.EVENT_SPACE),e==BI.KeyCode.BACKSPACE&&""==this._lastValue&&this.fireEvent(BI.Input.EVENT_REMOVE),e!=BI.KeyCode.BACKSPACE&&e!=BI.KeyCode.DELETE||this.fireEvent(BI.Input.EVENT_BACKSPACE),this.fireEvent(BI.Input.EVENT_KEY_DOWN,arguments);var n=this._lastValue;BI.trim(this.getValue())!==BI.trim(this._lastValue||"")&&this._valueChange(),BI.isEndWithBlank(this.getValue())?(this._pause=!0,this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.PAUSE,"",this),this.fireEvent(BI.Input.EVENT_PAUSE),this._defaultState()):e!==BI.KeyCode.BACKSPACE&&e!==BI.KeyCode.DELETE||""!==BI.trim(this.getValue())||null===n||""===BI.trim(n)||(this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.STOPEDIT,this.getValue(),this),this.fireEvent(BI.Input.EVENT_STOP))},_defaultState:function(){""==this.getValue()&&(this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EMPTY,this.getValue(),this),this.fireEvent(BI.Input.EVENT_EMPTY)),this._lastValue=this.getValue(),this._lastSubmitValue=null},_valueChange:function(){this.isValid()&&BI.trim(this.getValue())!==this._lastSubmitValue&&(this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.CHANGE,this.getValue(),this),this.fireEvent(BI.Input.EVENT_CHANGE),this._lastSubmitValue=BI.trim(this.getValue())),""==this.getValue()&&(this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EMPTY,this.getValue(),this),this.fireEvent(BI.Input.EVENT_EMPTY)),this._lastValue=this.getValue()},_checkValidationOnValueChange:function(){var e=this.options,t=this.getValue();this.setValid(!0===e.allowBlank&&""==BI.trim(t)||BI.isNotEmptyString(BI.trim(t))&&!1!==e.validationChecker.apply(this,[BI.trim(t)]))},focus:function(){if(!this.element.is(":visible"))throw new Error("input输入框在不可见下不能focus");!0==!this._isEditing&&(this.element.focus(),this.selectAll())},blur:function(){if(!this.element.is(":visible"))throw new Error("input输入框在不可见下不能blur");!0===this._isEditing&&(this.element.blur(),this._blurDebounce())},selectAll:function(){if(!this.element.is(":visible"))throw new Error("input输入框在不可见下不能select");this.element.select(),this._isEditing=!0},setValue:function(e){this.element.val(e),BI.nextTick(BI.bind((function(){this._checkValidationOnValueChange(),this._defaultState(),this.isValid()&&(this._lastValidValue=this._lastSubmitValue=this.getValue())}),this))},getValue:function(){return this.element.val()||""},isEditing:function(){return this._isEditing},getLastValidValue:function(){return this._lastValidValue},getLastChangedValue:function(){return this._lastChangedValue},_setValid:function(){BI.Input.superclass._setValid.apply(this,arguments),this.isValid()?(this._lastChangedValue=this.getValue(),this.element.removeClass("bi-input-error"),this.fireEvent(BI.Input.EVENT_VALID,BI.trim(this.getValue()),this)):(this._lastChangedValue===this.getValue()&&(this._lastChangedValue=null),this.element.addClass("bi-input-error"),this.fireEvent(BI.Input.EVENT_ERROR,BI.trim(this.getValue()),this))},_setEnable:function(e){BI.Input.superclass._setEnable.apply(this,[e]),this.element[0].disabled=!e}}),BI.Input.EVENT_CHANGE="EVENT_CHANGE",BI.Input.EVENT_FOCUS="EVENT_FOCUS",BI.Input.EVENT_CLICK="EVENT_CLICK",BI.Input.EVENT_BLUR="EVENT_BLUR",BI.Input.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.Input.EVENT_QUICK_DOWN="EVENT_QUICK_DOWN",BI.Input.EVENT_SPACE="EVENT_SPACE",BI.Input.EVENT_BACKSPACE="EVENT_BACKSPACE",BI.Input.EVENT_START="EVENT_START",BI.Input.EVENT_PAUSE="EVENT_PAUSE",BI.Input.EVENT_STOP="EVENT_STOP",BI.Input.EVENT_CHANGE_CONFIRM="EVENT_CHANGE_CONFIRM",BI.Input.EVENT_CONFIRM="EVENT_CONFIRM",BI.Input.EVENT_REMOVE="EVENT_REMOVE",BI.Input.EVENT_EMPTY="EVENT_EMPTY",BI.Input.EVENT_VALID="EVENT_VALID",BI.Input.EVENT_ERROR="EVENT_ERROR",BI.Input.EVENT_ENTER="EVENT_ENTER",BI.Input.EVENT_RESTRICT="EVENT_RESTRICT",BI.shortcut("bi.input",BI.Input)},function(e,t){BI.ImageRadio=BI.inherit(BI.IconButton,{_defaultConfig:function(){var e=BI.ImageRadio.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-radio radio-icon",selected:!1,handler:BI.emptyFn,width:16,height:16,iconWidth:16,iconHeight:16})},_init:function(){BI.ImageRadio.superclass._init.apply(this,arguments)},doClick:function(){BI.ImageRadio.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.ImageRadio.EVENT_CHANGE)}}),BI.ImageRadio.EVENT_CHANGE=BI.IconButton.EVENT_CHANGE,BI.shortcut("bi.image_radio",BI.ImageRadio)},function(e,t){BI.Radio=BI.inherit(BI.BasicButton,{props:{baseCls:"bi-radio",selected:!1,handler:BI.emptyFn,width:16,height:16,iconWidth:14,iconHeight:14},render:function(){var e=this,t=this.options;return{type:"bi.center_adapt",element:this.element,items:[{type:"bi.layout",cls:"radio-content",ref:function(t){e.radio=t},width:t.iconWidth,height:t.iconHeight}]}},_setEnable:function(e){BI.Radio.superclass._setEnable.apply(this,arguments),!0===e?this.radio.element.removeClass("base-disabled disabled"):this.radio.element.addClass("base-disabled disabled")},doClick:function(){BI.Radio.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.Radio.EVENT_CHANGE)},setSelected:function(e){BI.Radio.superclass.setSelected.apply(this,arguments),e?this.radio.element.addClass("bi-high-light-background"):this.radio.element.removeClass("bi-high-light-background")}}),BI.Radio.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.radio",BI.Radio)},function(e,t){BI.AbstractLabel=BI.inherit(BI.Single,{_defaultConfig:function(e){var t=BI.AbstractLabel.superclass._defaultConfig.apply(this,arguments);return BI.extend(t,{textAlign:"center",whiteSpace:"nowrap",textWidth:null,textHeight:null,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0,highLight:!1,handler:null})},_createJson:function(){var e=this.options;return{type:"bi.text",textAlign:e.textAlign,whiteSpace:e.whiteSpace,lineHeight:e.textHeight,text:e.text,value:e.value,py:e.py,keyword:e.keyword,highLight:e.highLight,handler:e.handler}},_init:function(){BI.AbstractLabel.superclass._init.apply(this,arguments),"center"===this.options.textAlign?this._createCenterEl():this._createNotCenterEl()},_createCenterEl:function(){var e=this.options,t=this._createJson();return t.textAlign="left",BI.isNumber(e.width)&&e.width>0?BI.isNumber(e.textWidth)&&e.textWidth>0?(t.maxWidth=e.textWidth,BI.isNumber(e.height)&&e.height>0?void BI.createWidget({type:"bi.center_adapt",height:e.height,columnSize:["auto"],scrollable:"normal"===e.whiteSpace,element:this,items:[{el:this.text=BI.createWidget(t)}]}):void BI.createWidget({type:"bi.center_adapt",columnSize:["auto"],scrollable:"normal"===e.whiteSpace,element:this,items:[{el:this.text=BI.createWidget(t)}]})):"normal"===e.whiteSpace?(BI.extend(t,{hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap}),this.text=BI.createWidget(t),void BI.createWidget({type:"bi.center_adapt",columnSize:["auto"],scrollable:"normal"===e.whiteSpace,element:this,items:[this.text]})):BI.isNumber(e.height)&&e.height>0?(this.element.css({"line-height":e.height/BI.pixRatio+BI.pixUnit}),t.textAlign=e.textAlign,void(this.text=BI.createWidget(BI.extend(t,{element:this,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap})))):(BI.extend(t,{hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,maxWidth:"100%"}),this.text=BI.createWidget(t),void BI.createWidget({type:"bi.center_adapt",columnSize:["auto"],scrollable:"normal"===e.whiteSpace,element:this,items:[this.text]})):BI.isNumber(e.textWidth)&&e.textWidth>0?(t.maxWidth=e.textWidth,void BI.createWidget({type:"bi.center_adapt",columnSize:["auto"],scrollable:"normal"===e.whiteSpace,element:this,items:[{el:this.text=BI.createWidget(t)}]})):"normal"===e.whiteSpace?(BI.extend(t,{hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap}),this.text=BI.createWidget(t),void BI.createWidget({type:"bi.center_adapt",columnSize:["auto"],scrollable:!0,element:this,items:[this.text]})):BI.isNumber(e.height)&&e.height>0?(this.element.css({"line-height":e.height/BI.pixRatio+BI.pixUnit}),t.textAlign=e.textAlign,void(this.text=BI.createWidget(BI.extend(t,{element:this,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap})))):(BI.extend(t,{hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap}),this.text=BI.createWidget(BI.extend(t,{maxWidth:"100%"})),void BI.createWidget({type:"bi.center_adapt",columnSize:["auto"],element:this,items:[this.text]}))},_createNotCenterEl:function(){var e=this.options,t="bi.vertical_adapt",n=this._createJson();return BI.isNumber(e.width)&&e.width>0?BI.isNumber(e.textWidth)&&e.textWidth>0?(n.width=e.textWidth,BI.isNumber(e.height)&&e.height>0?void BI.createWidget({type:t,horizontalAlign:e.textAlign,columnSize:["auto"],height:e.height,scrollable:"normal"===e.whiteSpace,element:this,items:[{el:this.text=BI.createWidget(n)}]}):void BI.createWidget({type:t,horizontalAlign:e.textAlign,columnSize:["auto"],scrollable:"normal"===e.whiteSpace,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,element:this,items:[{el:this.text=BI.createWidget(n)}]})):BI.isNumber(e.height)&&e.height>0?(this.text=BI.createWidget(BI.extend(n,{element:this,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap})),void("normal"!==e.whiteSpace&&this.element.css({"line-height":(e.height-2*e.vgap)/BI.pixRatio+BI.pixUnit}))):(n.width=e.width-2*e.hgap-e.lgap-e.rgap,void BI.createWidget({type:t,horizontalAlign:e.textAlign,columnSize:["auto"],scrollable:"normal"===e.whiteSpace,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,element:this,items:[{el:this.text=BI.createWidget(n)}]})):BI.isNumber(e.textWidth)&&e.textWidth>0?(n.width=e.textWidth,void BI.createWidget({type:t,horizontalAlign:e.textAlign,columnSize:["auto"],scrollable:"normal"===e.whiteSpace,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,element:this,items:[{el:this.text=BI.createWidget(n)}]})):BI.isNumber(e.height)&&e.height>0?("normal"!==e.whiteSpace&&this.element.css({"line-height":(e.height-2*e.vgap)/BI.pixRatio+BI.pixUnit}),void(this.text=BI.createWidget(BI.extend(n,{element:this,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap})))):(BI.extend(n,{hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap}),this.text=BI.createWidget(BI.extend(n,{maxWidth:"100%"})),void BI.createWidget({type:t,horizontalAlign:e.textAlign,columnSize:["auto"],element:this,scrollable:"normal"===e.whiteSpace,items:[this.text]}))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},setText:function(e){this.options.text=e,this.text.setText(e)},getText:function(){return this.options.text},setStyle:function(e){this.text.setStyle(e)},setValue:function(e){BI.AbstractLabel.superclass.setValue.apply(this,arguments),this.isReadOnly()||this.text.setValue(e)}})},function(e,t){BI.HtmlLabel=BI.inherit(BI.AbstractLabel,{props:{baseCls:"bi-html-label"},_createJson:function(){var e=this.options;return{type:"bi.html",textAlign:e.textAlign,whiteSpace:e.whiteSpace,lineHeight:e.textHeight,text:e.text,value:e.value,handler:e.handler}}}),BI.shortcut("bi.html_label",BI.HtmlLabel)},function(e,t){BI.IconLabel=BI.inherit(BI.Single,{props:{baseCls:"bi-icon-label horizon-center",iconWidth:null,iconHeight:null},_init:function(){BI.IconLabel.superclass._init.apply(this,arguments);var e=this.options;this.element.css({textAlign:"center"}),this.icon=BI.createWidget({type:"bi.icon",width:e.iconWidth,height:e.iconHeight}),BI.isNumber(e.height)&&e.height>0&&BI.isNull(e.iconWidth)&&BI.isNull(e.iconHeight)?(this.element.css("lineHeight",e.height/BI.pixRatio+BI.pixUnit),BI.createWidget({type:"bi.default",element:this,items:[this.icon]})):(this.element.css("lineHeight","1"),BI.createWidget({element:this,type:"bi.center_adapt",items:[this.icon]}))}}),BI.shortcut("bi.icon_label",BI.IconLabel)},function(e,t){BI.Label=BI.inherit(BI.AbstractLabel,{props:{baseCls:"bi-label",py:"",keyword:""},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)}}),BI.shortcut("bi.label",BI.Label)},function(e,t){BI.Link=BI.inherit(BI.Label,{_defaultConfig:function(){var e=BI.Link.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-link display-block",tagName:"a",href:"",target:"_blank"})},_createJson:function(){var e=this.options;return{type:"bi.a",textAlign:e.textAlign,whiteSpace:e.whiteSpace,lineHeight:e.textHeight,text:e.text,keyword:e.keyword,value:e.value,py:e.py,href:e.href,target:e.target}}}),BI.shortcut("bi.link",BI.Link)},function(e,t){BI.PureText=BI.inherit(BI.Widget,{props:{tagName:null},render:function(){var e=this.options,t=this._getShowText();BI.isKey(t)?this.setText(t):BI.isKey(e.value)&&this.setText(e.value)},_getShowText:function(){var e=this.options,t=BI.isFunction(e.text)?e.text():e.text;return t=BI.isKey(t)?t:e.value,BI.isKey(t)?BI.Text.formatText(t+""):""},setValue:function(e){this.options.value=e,this.setText(e)},setText:function(e){this.options.text=BI.isNotNull(e)?e:"",this.element.__textKeywordMarked__(this._getShowText())}}),BI.shortcut("bi.pure_text",BI.PureText)},function(e,t){BI.Tip=BI.inherit(BI.Single,{_defaultConfig:function(){var e=BI.Tip.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{_baseCls:(e._baseCls||"")+" bi-tip",zIndex:BI.zIndex_tip})},_init:function(){BI.Tip.superclass._init.apply(this,arguments),this.element.css({zIndex:this.options.zIndex})}})},function(e,t){BI.Bubble=BI.inherit(BI.Tip,{_defaultConfig:function(){return BI.extend(BI.Bubble.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-bubble",direction:"top",text:"",level:"error",height:18})},_init:function(){BI.Bubble.superclass._init.apply(this,arguments);var e=function(e){return e.stopPropagation(),e.stopEvent(),!1};this.element.bind({click:e,mousedown:e,mouseup:e,mouseover:e,mouseenter:e,mouseleave:e,mousemove:e}),BI.createWidget({type:"bi.adaptive",element:this,items:[this["_"+this.options.direction]()]})},_createBubbleText:function(){var e=this.options;return this.text=BI.createWidget({type:"bi.label",cls:"bubble-text bubble-"+e.level,text:e.text,hgap:5,height:18})},_top:function(){return BI.createWidget({type:"bi.vertical",items:[{el:this._createBubbleText(),height:18},{el:{type:"bi.layout"},height:3}]})},_bottom:function(){return BI.createWidget({type:"bi.vertical",items:[{el:{type:"bi.layout"},height:3},{el:this._createBubbleText(),height:18}]})},_left:function(){return BI.createWidget({type:"bi.right",items:[{el:{type:"bi.layout",width:3,height:18}},{el:this._createBubbleText()}]})},_right:function(){return BI.createWidget({type:"bi.left",items:[{el:{type:"bi.layout",width:3,height:18}},{el:this._createBubbleText()}]})},setText:function(e){this.text.setText(e)}}),BI.shortcut("bi.bubble",BI.Bubble),BI.BubbleView=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.BubbleView.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-bubble",direction:"top",text:"",level:"error",height:18})},_init:function(){BI.BubbleView.superclass._init.apply(this,arguments);var e=function(e){return e.stopPropagation(),e.stopEvent(),!1};this.element.bind({click:e,mousedown:e,mouseup:e,mouseover:e,mouseenter:e,mouseleave:e,mousemove:e}),BI.createWidget({type:"bi.adaptive",element:this,items:[this["_"+this.options.direction]()]})},_createBubbleText:function(){var e=this.options;return this.text=BI.createWidget({type:"bi.label",cls:"bubble-text bubble-"+e.level,text:e.text,hgap:5,height:18})},_top:function(){return BI.createWidget({type:"bi.vertical",items:[{el:this._createBubbleText(),height:18},{el:{type:"bi.layout"},height:3}]})},_bottom:function(){return BI.createWidget({type:"bi.vertical",items:[{el:{type:"bi.layout"},height:3},{el:this._createBubbleText(),height:18}]})},_left:function(){return BI.createWidget({type:"bi.right",items:[{el:{type:"bi.layout",width:3,height:18}},{el:this._createBubbleText()}]})},_right:function(){return BI.createWidget({type:"bi.left",items:[{el:{type:"bi.layout",width:3,height:18}},{el:this._createBubbleText()}]})},setText:function(e){this.text.setText(e)}}),BI.shortcut("bi.bubble_view",BI.BubbleView)},function(e,t){BI.Toast=BI.inherit(BI.Tip,{_const:{minWidth:200,hgap:10},_defaultConfig:function(){return BI.extend(BI.Toast.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-toast",text:"",level:"success"})},_init:function(){BI.Toast.superclass._init.apply(this,arguments);var e=this,t=this.options;this.element.css({minWidth:this._const.minWidth/BI.pixRatio+BI.pixUnit}),this.element.addClass("toast-"+t.level);var n=function(e){return e.stopPropagation(),e.stopEvent(),!1};this.element.bind({click:n,mousedown:n,mouseup:n,mouseover:n,mouseenter:n,mouseleave:n,mousemove:n});var i="close-font";switch(t.level){case"success":i="toast-success-font";break;case"error":i="toast-error-font";break;case"warning":i="toast-warning-font";break;case"normal":default:i="toast-message-font"}var r=[{type:"bi.icon_label",cls:i+" toast-icon",width:36},{el:{type:"bi.label",whiteSpace:"normal",text:t.text,textHeight:16,textAlign:"left"},rgap:t.autoClose?this._const.hgap:0}],a=[36,"fill"];!1===t.autoClose&&(r.push({type:"bi.icon_button",cls:"close-font toast-icon",handler:function(){e.destroy()},width:36}),a.push(36)),this.text=BI.createWidget({type:"bi.horizontal",horizontalAlign:BI.HorizontalAlign.Stretch,element:this,items:r,vgap:7,columnSize:a})},setText:function(e){this.text.setText(e)},beforeDestroy:function(){this.fireEvent(BI.Toast.EVENT_DESTORY)}}),BI.Toast.EVENT_DESTORY="EVENT_DESTORY",BI.shortcut("bi.toast",BI.Toast)},function(e,t){BI.Tooltip=BI.inherit(BI.Tip,{_const:{hgap:5,vgap:3},_defaultConfig:function(){return BI.extend(BI.Tooltip.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-tooltip",text:"",level:"success",stopEvent:!1,stopPropagation:!1})},_init:function(){BI.Tooltip.superclass._init.apply(this,arguments);var e=this.options;this.element.addClass("tooltip-"+e.level);var t=function(t){e.stopPropagation&&t.stopPropagation(),e.stopEvent&&t.stopEvent()};this.element.bind({click:t,mousedown:t,mouseup:t,mouseover:t,mouseenter:t,mouseleave:t,mousemove:t});var n=(e.text+"").split("\n");n.length>1?BI.createWidget({type:"bi.vertical",element:this,hgap:this._const.hgap,items:BI.map(n,(function(e,t){return{type:"bi.label",textAlign:"left",whiteSpace:"normal",text:t,textHeight:18}}))}):this.text=BI.createWidget({type:"bi.label",element:this,textAlign:"left",whiteSpace:"normal",text:e.text,textHeight:18,hgap:this._const.hgap})},setWidth:function(e){this.element.width(e-2*this._const.hgap)},setText:function(e){this.text&&this.text.setText(e)},setLevel:function(e){this.element.removeClass("tooltip-success").removeClass("tooltip-warning"),this.element.addClass("tooltip-"+e)}}),BI.shortcut("bi.tooltip",BI.Tooltip)},function(e,t){BI.Trigger=BI.inherit(BI.Single,{_defaultConfig:function(){var e=BI.Trigger.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{_baseCls:(e._baseCls||"")+" bi-trigger cursor-pointer",height:24})},_init:function(){BI.Trigger.superclass._init.apply(this,arguments)},setKey:function(){},getKey:function(){}})},function(e,t){BI.CustomTree=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.CustomTree.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-custom-tree",expander:{el:{},popup:{type:"bi.custom_tree"}},items:[],itemsCreator:BI.emptyFn,el:{type:"bi.button_tree",chooseType:0,layouts:[{type:"bi.vertical"}]}})},_init:function(){BI.CustomTree.superclass._init.apply(this,arguments),this.initTree(this.options.items)},_formatItems:function(e){var t=this,n=this.options;e=BI.Tree.transformToTreeFormat(e);var i=[];return BI.each(e,(function(e,r){if(BI.isNotEmptyArray(r.children)||!0===r.isParent){var a=BI.extend({type:"bi.expander",el:{value:r.value},popup:{type:"bi.custom_tree"}},BI.deepClone(n.expander),{id:r.id,pId:r.pId}),o=BI.stripEL(r);BI.isWidget(o)?a.el=o:(delete(o=BI.clone(o)).children,BI.extend(a.el,o)),a.popup.expander=BI.deepClone(n.expander),a.items=a.popup.items=r.children,a.itemsCreator=a.popup.itemsCreator=function(e){if(BI.isNotNull(e.node))return n.itemsCreator.apply(t,arguments);var i=Array.prototype.slice.call(arguments,0);return i[0].node=r,n.itemsCreator.apply(t,i)},BI.isNull(a.popup.el)&&(a.popup.el=BI.deepClone(n.el)),i.push(a)}else i.push(r)})),i},initTree:function(e){var t=this,n=this.options;this.tree=BI.createWidget(n.el,{element:this,items:this._formatItems(e),itemsCreator:function(e,i){n.itemsCreator.apply(this,[e,function(e){var n=Array.prototype.slice.call(arguments,0);n[0]=t._formatItems(e),i.apply(null,n)}])},value:n.value}),this.tree.on(BI.Controller.EVENT_CHANGE,(function(e,n,i){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&t.fireEvent(BI.CustomTree.EVENT_CHANGE,n,i)}))},stroke:function(e){this.populate.apply(this,arguments)},populate:function(e){var t=Array.prototype.slice.call(arguments,0);arguments.length>0&&(t[0]=this._formatItems(e)),this.tree.populate.apply(this.tree,t)},setValue:function(e){this.tree&&this.tree.setValue(e)},getValue:function(){return this.tree?this.tree.getValue():[]},getAllButtons:function(){return this.tree?this.tree.getAllButtons():[]},getAllLeaves:function(){return this.tree?this.tree.getAllLeaves():[]},getNodeById:function(e){return this.tree&&this.tree.getNodeById(e)},getNodeByValue:function(e){return this.tree&&this.tree.getNodeByValue(e)},empty:function(){this.tree.empty()}}),BI.CustomTree.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.custom_tree",BI.CustomTree)},function(e,t){BI.IconChangeButton=BI.inherit(BI.Single,{_defaultConfig:function(){var e=BI.IconChangeButton.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:"bi-icon-change-button",iconCls:"",iconWidth:null,iconHeight:null,stopEvent:!1,stopPropagation:!1,selected:!1,once:!1,forceSelected:!1,forceNotSelected:!1,disableSelected:!1,shadow:!1,isShadowShowingOnSelected:!1,trigger:null,handler:BI.emptyFn})},_init:function(){BI.IconChangeButton.superclass._init.apply(this,arguments);var e=this,t=this.options;this.button=BI.createWidget({type:"bi.icon_button",element:this,cls:t.iconCls,height:t.height,iconWidth:t.iconWidth,iconHeight:t.iconHeight,stopEvent:t.stopEvent,stopPropagation:t.stopPropagation,selected:t.selected,once:t.once,forceSelected:t.forceSelected,forceNotSelected:t.forceNotSelected,disableSelected:t.disableSelected,shadow:t.shadow,isShadowShowingOnSelected:t.isShadowShowingOnSelected,trigger:t.trigger,handler:t.handler}),this.button.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.button.on(BI.IconButton.EVENT_CHANGE,(function(){e.fireEvent(BI.IconChangeButton.EVENT_CHANGE,arguments)}))},isSelected:function(){return this.button.isSelected()},setSelected:function(e){this.button.setSelected(e)},setIcon:function(e){var t=this.options;t.iconCls!==e&&(this.element.removeClass(t.iconCls).addClass(e),t.iconCls=e)}}),BI.IconChangeButton.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.icon_change_button",BI.IconChangeButton)},function(e,t){BI.TriggerIconButton=BI.inherit(BI.IconButton,{_defaultConfig:function(){var e=BI.TriggerIconButton.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-trigger-icon-button overflow-hidden",extraCls:"pull-down-font"})}}),BI.TriggerIconButton.EVENT_CHANGE=BI.IconButton.EVENT_CHANGE,BI.shortcut("bi.trigger_icon_button",BI.TriggerIconButton)},function(e,t){BI.HalfIconButton=BI.inherit(BI.IconButton,{_defaultConfig:function(){var e=BI.HalfIconButton.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-half-icon-button check-half-select-icon",height:16,width:16,iconWidth:16,iconHeight:16,selected:!1})}}),BI.HalfIconButton.EVENT_CHANGE=BI.IconButton.EVENT_CHANGE,BI.shortcut("bi.half_icon_button",BI.HalfIconButton)},function(e,t){BI.HalfButton=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.HalfIconButton.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-half-button bi-high-light-border",height:14,width:14,selected:!1})},_init:function(){BI.HalfButton.superclass._init.apply(this,arguments),BI.createWidget({type:"bi.center_adapt",element:this.element,items:[{type:"bi.layout",cls:"bi-high-light-background",width:8,height:8}]})},doClick:function(){BI.HalfButton.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.HalfButton.EVENT_CHANGE)}}),BI.HalfButton.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.half_button",BI.HalfButton)},function(e,t){BI.MultiSelectItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){return BI.extend(BI.MultiSelectItem.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-multi-select-item",height:24,logic:{dynamic:!1},iconWrapperWidth:26,textHgap:0,textLgap:0,textRgap:0})},_init:function(){BI.MultiSelectItem.superclass._init.apply(this,arguments);var e=this,t=this.options;this.checkbox=BI.createWidget({type:"bi.checkbox"}),this.text=BI.createWidget({type:"bi.label",cls:"list-item-text",textAlign:"left",whiteSpace:"nowrap",textHeight:t.height,height:t.height,hgap:t.hgap,rgap:t.rgap,lgap:t.textLgap,text:t.text,keyword:t.keyword,value:t.value,py:t.py}),this.checkbox.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&e.setSelected(e.isSelected())})),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("horizontal",BI.extend(t.logic,{items:BI.LogicFactory.createLogicItemsByDirection("left",{type:"bi.center_adapt",items:[this.checkbox],width:t.iconWrapperWidth},this.text)}))))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.MultiSelectItem.superclass.doClick.apply(this,arguments),this.checkbox.setSelected(this.isSelected()),this.isValid()&&this.fireEvent(BI.MultiSelectItem.EVENT_CHANGE,this.getValue(),this)},setSelected:function(e){BI.MultiSelectItem.superclass.setSelected.apply(this,arguments),this.checkbox.setSelected(e)}}),BI.MultiSelectItem.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_select_item",BI.MultiSelectItem)},function(e,t){BI.SingleSelectIconTextItem=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.SingleSelectIconTextItem.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-single-select-icon-text-item bi-list-item-active",iconCls:"",height:24})},_init:function(){BI.SingleSelectIconTextItem.superclass._init.apply(this,arguments);var e=this,t=this.options;this.text=BI.createWidget({type:"bi.icon_text_item",element:this,cls:t.iconCls,once:t.once,iconWrapperWidth:t.iconWrapperWidth,selected:t.selected,height:t.height,iconHeight:t.iconHeight,iconWidth:t.iconWidth,text:t.text,keyword:t.keyword,value:t.value,py:t.py}),this.text.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}))},isSelected:function(){return this.text.isSelected()},setSelected:function(e){this.text.setSelected(e)},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.SingleSelectIconTextItem.superclass.doClick.apply(this,arguments)}}),BI.shortcut("bi.single_select_icon_text_item",BI.SingleSelectIconTextItem)},function(e,t){BI.SingleSelectItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){return BI.extend(BI.SingleSelectItem.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-single-select-item bi-list-item-active",hgap:10,height:24,textAlign:"left"})},_init:function(){BI.SingleSelectItem.superclass._init.apply(this,arguments);var e=this.options;this.text=BI.createWidget({type:"bi.label",element:this,textAlign:e.textAlign,whiteSpace:"nowrap",textHeight:e.height,height:e.height,hgap:e.hgap,text:e.text,keyword:e.keyword,value:e.value,title:e.title||e.text,warningTitle:e.warningTitle,py:e.py})},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.SingleSelectItem.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.SingleSelectItem.EVENT_CHANGE,this.isSelected(),this)},setSelected:function(e){BI.SingleSelectItem.superclass.setSelected.apply(this,arguments)}}),BI.SingleSelectItem.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.single_select_item",BI.SingleSelectItem)},function(e,t){BI.SingleSelectRadioItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){return BI.extend(BI.SingleSelectRadioItem.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-single-select-radio-item",logic:{dynamic:!1},height:24,iconWrapperWidth:16,hgap:10,textHgap:0,textLgap:0,textRgap:0})},_init:function(){BI.SingleSelectRadioItem.superclass._init.apply(this,arguments);var e=this.options;this.radio=BI.createWidget({type:"bi.radio"}),this.text=BI.createWidget({type:"bi.label",cls:"list-item-text",textAlign:"left",whiteSpace:"nowrap",textHeight:e.height,height:e.height,hgap:e.hgap,rgap:e.textRgap,lgap:e.textLgap,text:e.text,keyword:e.keyword,value:e.value,py:e.py}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("horizontal",BI.extend(e.logic,{items:BI.LogicFactory.createLogicItemsByDirection("left",{type:"bi.center_adapt",items:[this.radio],width:e.iconWrapperWidth},this.text)}))))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.SingleSelectRadioItem.superclass.doClick.apply(this,arguments),this.radio.setSelected(this.isSelected()),this.isValid()&&this.fireEvent(BI.SingleSelectRadioItem.EVENT_CHANGE,this.isSelected(),this)},setSelected:function(e){BI.SingleSelectRadioItem.superclass.setSelected.apply(this,arguments),this.radio.setSelected(e)}}),BI.SingleSelectRadioItem.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.single_select_radio_item",BI.SingleSelectRadioItem)},function(e,t){BI.ArrowNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.ArrowNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-arrow-group-node bi-list-item",logic:{dynamic:!1},id:"",pId:"",open:!1,height:24,iconWrapperWidth:16})},_init:function(){var e=this,t=this.options;BI.ArrowNode.superclass._init.apply(this,arguments),this.checkbox=BI.createWidget({type:"bi.arrow_group_node_checkbox"}),this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:t.height,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword}),this.checkbox.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&e.setSelected(e.isSelected()),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}));var n=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),i=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:t.iconWrapperWidth,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(n,BI.extend(t.logic,{items:i}))))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.ArrowNode.superclass.doClick.apply(this,arguments),this.checkbox.setSelected(this.isOpened())},setText:function(e){BI.ArrowNode.superclass.setText.apply(this,arguments),this.text.setText(e)},setOpened:function(e){BI.ArrowNode.superclass.setOpened.apply(this,arguments),this.checkbox.setSelected(e)}}),BI.shortcut("bi.arrow_group_node",BI.ArrowNode)},function(e,t){BI.FirstPlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.FirstPlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-first-plus-group-node bi-list-item",logic:{dynamic:!1},id:"",pId:"",open:!1,height:24})},_init:function(){BI.FirstPlusGroupNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.checkbox=BI.createWidget({type:"bi.first_tree_node_checkbox",stopPropagation:!0}),this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:t.height,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword}),this.checkbox.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&(this.isSelected()?e.triggerExpand():e.triggerCollapse())}));var n=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),i=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(n,BI.extend(t.logic,{items:i}))))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.FirstPlusGroupNode.superclass.doClick.apply(this,arguments),this.checkbox.setSelected(this.isSelected())},setOpened:function(e){BI.FirstPlusGroupNode.superclass.setOpened.apply(this,arguments),BI.isNotNull(this.checkbox)&&this.checkbox.setSelected(e)}}),BI.shortcut("bi.first_plus_group_node",BI.FirstPlusGroupNode)},function(e,t){BI.IconArrowNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.IconArrowNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-icon-arrow-node bi-list-item",logic:{dynamic:!1},id:"",pId:"",open:!1,height:24,iconHeight:12,iconWidth:12,iconCls:"",iconWrapperWidth:16})},_init:function(){BI.IconArrowNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.checkbox=BI.createWidget({type:"bi.arrow_group_node_checkbox",width:24,stopPropagation:!0});var n=BI.createWidget({type:"bi.icon_label",width:24,cls:t.iconCls,iconWidth:t.iconWidth,iconHeight:t.iconHeight});this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:t.height,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword}),this.checkbox.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&(this.isSelected()?e.triggerExpand():e.triggerCollapse())}));var i=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),r=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:t.iconWrapperWidth,el:this.checkbox},{width:16,el:n},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(i,BI.extend(t.logic,{items:r,rgap:5}))))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.IconArrowNode.superclass.doClick.apply(this,arguments),this.checkbox.setSelected(this.isSelected())},setOpened:function(e){BI.IconArrowNode.superclass.setOpened.apply(this,arguments),BI.isNotNull(this.checkbox)&&this.checkbox.setSelected(e)}}),BI.shortcut("bi.icon_arrow_node",BI.IconArrowNode)},function(e,t){BI.LastPlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.LastPlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-last-plus-group-node bi-list-item",logic:{dynamic:!1},id:"",pId:"",open:!1,height:24})},_init:function(){BI.LastPlusGroupNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.checkbox=BI.createWidget({type:"bi.last_tree_node_checkbox",stopPropagation:!0}),this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:t.height,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword}),this.checkbox.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&(this.isSelected()?e.triggerExpand():e.triggerCollapse())}));var n=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),i=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(n,BI.extend(t.logic,{items:i}))))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.LastPlusGroupNode.superclass.doClick.apply(this,arguments),this.checkbox.setSelected(this.isSelected())},setOpened:function(e){BI.LastPlusGroupNode.superclass.setOpened.apply(this,arguments),BI.isNotNull(this.checkbox)&&this.checkbox.setSelected(e)}}),BI.shortcut("bi.last_plus_group_node",BI.LastPlusGroupNode)},function(e,t){BI.MidPlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.MidPlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-mid-plus-group-node bi-list-item",logic:{dynamic:!1},id:"",pId:"",open:!1,height:24})},_init:function(){BI.MidPlusGroupNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.checkbox=BI.createWidget({type:"bi.mid_tree_node_checkbox",stopPropagation:!0}),this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:t.height,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword}),this.checkbox.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&(this.isSelected()?e.triggerExpand():e.triggerCollapse())}));var n=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),i=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(n,BI.extend(t.logic,{items:i}))))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.MidPlusGroupNode.superclass.doClick.apply(this,arguments),this.checkbox.setSelected(this.isSelected())},setOpened:function(e){BI.MidPlusGroupNode.superclass.setOpened.apply(this,arguments),BI.isNotNull(this.checkbox)&&this.checkbox.setSelected(e)}}),BI.shortcut("bi.mid_plus_group_node",BI.MidPlusGroupNode)},function(e,t){BI.MultiLayerIconArrowNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.MultiLayerIconArrowNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-multilayer-icon-arrow-node bi-list-item",layer:0,id:"",pId:"",open:!1,height:24,iconHeight:16,iconWidth:16,iconCls:""})},_init:function(){BI.MultiLayerIconArrowNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.node=BI.createWidget({type:"bi.icon_arrow_node",iconCls:t.iconCls,cls:"bi-list-item-none",id:t.id,pId:t.pId,open:t.open,height:t.height,iconHeight:t.iconHeight,iconWidth:t.iconWidth,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword}),this.node.on(BI.Controller.EVENT_CHANGE,(function(t){e.setSelected(e.isSelected()),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}));var n=[];BI.count(0,t.layer,(function(){n.push({type:"bi.layout",width:15,height:t.height})})),n.push(this.node),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(t.layer,15),items:n})},isOnce:function(){return!0},doRedMark:function(){this.node.doRedMark.apply(this.node,arguments)},unRedMark:function(){this.node.unRedMark.apply(this.node,arguments)},isSelected:function(){return this.node.isSelected()},setSelected:function(e){BI.MultiLayerIconArrowNode.superclass.setSelected.apply(this,arguments),this.node.setSelected(e)},doClick:function(){BI.NodeButton.superclass.doClick.apply(this,arguments),this.node.setSelected(this.isSelected())},setOpened:function(e){BI.MultiLayerIconArrowNode.superclass.setOpened.apply(this,arguments),this.node.setOpened(e)}}),BI.shortcut("bi.multilayer_icon_arrow_node",BI.MultiLayerIconArrowNode)},function(e,t){BI.PlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.PlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-plus-group-node bi-list-item",logic:{dynamic:!1},id:"",pId:"",open:!1,height:24})},_init:function(){BI.PlusGroupNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.checkbox=BI.createWidget({type:"bi.tree_node_checkbox"}),this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:t.height,height:t.height,hgap:t.hgap,text:t.text,value:t.value,keyword:t.keyword,py:t.py}),this.checkbox.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&e.setSelected(e.isSelected()),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}));var n=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),i=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(n,BI.extend(t.logic,{items:i}))))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.PlusGroupNode.superclass.doClick.apply(this,arguments),this.checkbox.setSelected(this.isSelected())},setOpened:function(e){BI.PlusGroupNode.superclass.setOpened.apply(this,arguments),this.checkbox&&this.checkbox.setSelected(e)}}),BI.shortcut("bi.plus_group_node",BI.PlusGroupNode)},function(e,t){BI.Switch=BI.inherit(BI.BasicButton,{props:{extraCls:"bi-switch",height:22,width:44,logic:{dynamic:!1}},render:function(){var e=this;return{type:"bi.absolute",ref:function(){e.layout=this},items:[{el:{type:"bi.text_button",cls:"circle-button bi-card"},width:18,height:18,top:2,left:this.options.selected?24:2}]}},setSelected:function(e){BI.Switch.superclass.setSelected.apply(this,arguments),this.layout.attr("items")[0].left=e?24:2,this.layout.resize()},doClick:function(){BI.Switch.superclass.doClick.apply(this,arguments),this.fireEvent(BI.Switch.EVENT_CHANGE)}}),BI.Switch.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.switch",BI.Switch)},function(e,t){BI.FirstTreeLeafItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){return BI.extend(BI.FirstTreeLeafItem.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-first-tree-leaf-item bi-list-item-active",logic:{dynamic:!1},id:"",pId:"",layer:0,height:24})},_init:function(){BI.FirstTreeLeafItem.superclass._init.apply(this,arguments);var e=this.options;this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:e.height,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword});var t=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),n=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,0===e.layer?"":{width:12,el:{type:"bi.layout",cls:e.pNode&&e.pNode.isLastNode?"":"base-line-conn-background",width:12,height:e.height}},{width:24,el:{type:"bi.layout",cls:"first-line-conn-background",width:24,height:e.height}},{el:this.text});BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(t,BI.extend(e.logic,{items:n}))))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},getId:function(){return this.options.id},getPId:function(){return this.options.pId}}),BI.shortcut("bi.first_tree_leaf_item",BI.FirstTreeLeafItem)},function(e,t){BI.IconTreeLeafItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){return BI.extend(BI.IconTreeLeafItem.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-icon-tree-leaf-item bi-list-item-active",logic:{dynamic:!1},height:24,iconWidth:16,iconHeight:16,iconCls:""})},_init:function(){BI.IconTreeLeafItem.superclass._init.apply(this,arguments);var e=this.options,t=BI.createWidget({type:"bi.center_adapt",width:24,cls:e.iconCls,items:[{type:"bi.icon",width:e.iconWidth,height:e.iconHeight}]});this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:e.height,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword});var n=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),i=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:16,el:t},{el:this.text});BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(n,BI.extend(e.logic,{items:i,hgap:5}))))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},getId:function(){return this.options.id},getPId:function(){return this.options.pId}}),BI.shortcut("bi.icon_tree_leaf_item",BI.IconTreeLeafItem)},function(e,t){BI.LastTreeLeafItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){return BI.extend(BI.LastTreeLeafItem.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-last-tree-leaf-item bi-list-item-active",logic:{dynamic:!1},id:"",pId:"",layer:0,height:24})},_init:function(){BI.LastTreeLeafItem.superclass._init.apply(this,arguments);var e=this.options;this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:e.height,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword});var t=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),n=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,0===e.layer?"":{width:12,el:{type:"bi.layout",cls:e.pNode&&e.pNode.isLastNode?"":"base-line-conn-background",width:12,height:e.height}},{width:24,el:{type:"bi.layout",cls:"last-line-conn-background",width:24,height:e.height}},{el:this.text});BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(t,BI.extend(e.logic,{items:n}))))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},getId:function(){return this.options.id},getPId:function(){return this.options.pId}}),BI.shortcut("bi.last_tree_leaf_item",BI.LastTreeLeafItem)},function(e,t){BI.MidTreeLeafItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){return BI.extend(BI.MidTreeLeafItem.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-mid-tree-leaf-item bi-list-item-active",logic:{dynamic:!1},id:"",pId:"",layer:0,height:24})},_init:function(){BI.MidTreeLeafItem.superclass._init.apply(this,arguments);var e=this.options;this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:e.height,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword});var t=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),n=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,0===e.layer?"":{width:12,el:{type:"bi.layout",cls:e.pNode&&e.pNode.isLastNode?"":"base-line-conn-background",width:12,height:e.height}},{width:24,el:{type:"bi.layout",cls:"mid-line-conn-background",width:24,height:e.height}},{el:this.text});BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(t,BI.extend(e.logic,{items:n}))))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},getId:function(){return this.options.id},getPId:function(){return this.options.pId}}),BI.shortcut("bi.mid_tree_leaf_item",BI.MidTreeLeafItem)},function(e,t){BI.MultiLayerIconTreeLeafItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){return BI.extend(BI.MultiLayerIconTreeLeafItem.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-multilayer-icon-tree-leaf-item bi-list-item-active",layer:0,height:24,iconCls:"",iconHeight:16,iconWidth:16})},_init:function(){BI.MultiLayerIconTreeLeafItem.superclass._init.apply(this,arguments);var e=this,t=this.options;this.item=BI.createWidget({type:"bi.icon_tree_leaf_item",cls:"bi-list-item-none",iconCls:t.iconCls,id:t.id,pId:t.pId,isFront:!0,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword,iconWidth:t.iconWidth,iconHeight:t.iconHeight}),this.item.on(BI.Controller.EVENT_CHANGE,(function(t){t!==BI.Events.CLICK&&e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}));var n=[];BI.count(0,t.layer,(function(){n.push({type:"bi.layout",width:15,height:t.height})})),n.push(this.item),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(t.layer,15),items:n})},doRedMark:function(){this.item.doRedMark.apply(this.item,arguments)},unRedMark:function(){this.item.unRedMark.apply(this.item,arguments)},doHighLight:function(){this.item.doHighLight.apply(this.item,arguments)},unHighLight:function(){this.item.unHighLight.apply(this.item,arguments)},getId:function(){return this.options.id},getPId:function(){return this.options.pId},doClick:function(){BI.MultiLayerIconTreeLeafItem.superclass.doClick.apply(this,arguments),this.item.setSelected(this.isSelected())},setSelected:function(e){BI.MultiLayerIconTreeLeafItem.superclass.setSelected.apply(this,arguments),this.item.setSelected(e)},getValue:function(){return this.options.value}}),BI.shortcut("bi.multilayer_icon_tree_leaf_item",BI.MultiLayerIconTreeLeafItem)},function(e,t){BI.RootTreeLeafItem=BI.inherit(BI.BasicButton,{props:{baseCls:"bi-root-tree-leaf-item bi-list-item-active",logic:{dynamic:!1},id:"",pId:"",layer:0,height:24},render:function(){var e=this,t=this.options,n={type:"bi.label",ref:function(t){e.text=t},textAlign:"left",whiteSpace:"nowrap",textHeight:t.height,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword},i=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),r=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:{type:"bi.layout",width:24,height:t.height}},{el:n});return BI.LogicFactory.createLogic(i,BI.extend(t.logic,{items:r}))},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},getId:function(){return this.options.id},getPId:function(){return this.options.pId}}),BI.shortcut("bi.root_tree_leaf_item",BI.RootTreeLeafItem)},function(e,t){BI.TreeTextLeafItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){return BI.extend(BI.TreeTextLeafItem.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-tree-text-leaf-item bi-list-item-active",id:"",pId:"",height:24,hgap:0,lgap:0,rgap:0})},_init:function(){BI.TreeTextLeafItem.superclass._init.apply(this,arguments);var e=this.options;this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:e.height,height:e.height,hgap:e.hgap,lgap:e.lgap,rgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword}),BI.createWidget({type:"bi.htape",element:this,items:[{el:this.text}]})},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},getId:function(){return this.options.id},getPId:function(){return this.options.pId}}),BI.shortcut("bi.tree_text_leaf_item",BI.TreeTextLeafItem)},function(e,t){BI.CalendarDateItem=BI.inherit(BI.BasicButton,{render:function(){var e=this,t=this.options;return{type:"bi.absolute",items:[{el:{type:"bi.text_item",cls:"bi-list-item-select",textAlign:"center",whiteSpace:"normal",text:t.text,value:t.value,ref:function(){e.text=this}},left:t.lgap,right:t.rgap,top:0,bottom:0}]}},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},setValue:function(){this.isReadOnly()||this.text.setValue.apply(this.text,arguments)},setSelected:function(e){BI.CalendarDateItem.superclass.setSelected.apply(this,arguments),this.text.setSelected(e)},getValue:function(){return this.text.getValue()}}),BI.shortcut("bi.calendar_date_item",BI.CalendarDateItem)},function(e,t){BI.Calendar=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.Calendar.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:"bi-calendar",logic:{dynamic:!1},min:"1900-01-01",max:"2099-12-31",year:2015,month:8,day:25})},_dateCreator:function(e,t,n){var i=this.options,r={},a=BI.getDate(),o=i.min.match(/\d+/g),s=i.max.match(/\d+/g);a.setFullYear(e,t,n),r.ymd=[a.getFullYear(),a.getMonth(),a.getDate()];var l=BI.Date._MD.slice(0);l[1]=BI.isLeapYear(r.ymd[0])?29:28,a.setFullYear(r.ymd[0],r.ymd[1],1),r.FDay=a.getDay();var u=(7-BI.StartOfWeek+r.FDay)%7;r.PDay=l[0===t?11:t-1]-u+1,r.NDay=1;var c=[];return BI.each(BI.range(42),(function(e){var t,n={},i=r.ymd[0],a=r.ymd[1]+1;e<u?(n.lastMonth=!0,t=e+r.PDay,1===a&&(i-=1),a=1===a?12:a-1):e>=u&&e<u+l[r.ymd[1]]?(t=e-u+1,e-u+1===r.ymd[2]&&(n.currentDay=!0)):(n.nextMonth=!0,t=r.NDay++,12===a&&(i+=1),a=12===a?1:a+1),BI.checkDateVoid(i,a,t,o,s)[0]&&(n.disabled=!0),n.text=t,c.push(n)})),c},_init:function(){BI.Calendar.superclass._init.apply(this,arguments);var e=this,t=this.options,n=BI.map(this._getWeekLabel(),(function(e,t){return{type:"bi.label",height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,text:t}})),i=BI.createWidget({type:"bi.button_group",height:44,items:n,layouts:[{type:"bi.center",hgap:5,vgap:10}]});this.days=BI.createWidget({type:"bi.button_group",items:BI.createItems(this._getItems(),{}),layouts:[BI.LogicFactory.createLogic("table",BI.extend({},t.logic,{columns:7,rows:6,columnSize:[1/7,1/7,1/7,1/7,1/7,1/7,1/7],rowSize:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,vgap:10}))]}),this.days.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("vertical",BI.extend({},t.logic,{items:BI.LogicFactory.createLogicItemsByDirection("top",i,this.days)}))))},_getWeekLabel:function(){return BI.map(BI.range(0,7),(function(e,t){return BI.Date._SDN[(t+BI.StartOfWeek)%7]}))},isFrontDate:function(){var e=this.options,t=(this._const,e.year),n=e.month,i=BI.getDate(),r=i.getDay();t|=0,i.setFullYear(t,n,1);var a=BI.getOffsetDate(i,-1*(r+1));return!!BI.checkDateVoid(a.getFullYear(),a.getMonth(),a.getDate(),e.min,e.max)[0]},isFinalDate:function(){var e=this.options,t=(this._const,e.year),n=e.month,i=BI.getDate(),r=i.getDay();t|=0,i.setFullYear(t,n,1);var a=BI.getOffsetDate(i,42-r);return!!BI.checkDateVoid(a.getFullYear(),a.getMonth(),a.getDate(),e.min,e.max)[0]},_getItems:function(){var e=this.options,t=this._dateCreator(e.year,e.month-1,e.day),n=[];return n.push(t.slice(0,7)),n.push(t.slice(7,14)),n.push(t.slice(14,21)),n.push(t.slice(21,28)),n.push(t.slice(28,35)),n.push(t.slice(35,42)),BI.map(n,(function(t,n){return BI.map(n,(function(t,n){var i=n.lastMonth?e.month-1:n.nextMonth?e.month+1:e.month;return BI.extend(n,{type:"bi.calendar_date_item",textAlign:"center",whiteSpace:"normal",once:!1,forceSelected:!0,height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,value:e.year+"-"+i+"-"+n.text,disabled:n.lastMonth||n.nextMonth||n.disabled,lgap:5,rgap:5})}))}))},_populate:function(){this.days.populate(this._getItems())},setMinDate:function(e){var t=this.options;BI.isNotEmptyString(t.min)&&(t.min=e,this._populate())},setMaxDate:function(e){var t=this.options;BI.isNotEmptyString(t.max)&&(t.max=e,this._populate())},setValue:function(e){this.days.setValue([e.year+"-"+e.month+"-"+e.day])},getValue:function(){var e=this.days.getValue()[0].match(/\d+/g);return{year:0|e[0],month:0|e[1],day:0|e[2]}}}),BI.extend(BI.Calendar,{getPageByDateJSON:function(e){var t=BI.getDate().getFullYear(),n=BI.getDate().getMonth(),i=12*(e.year-t);return i+=e.month-1-n},getDateJSONByPage:function(e){var t=e;t+=BI.getDate().getMonth();var n=BI.parseInt(t/12);t<0&&t%12!=0&&n--;var i=t>=0?t%12:(12+t%12)%12;return{year:BI.getDate().getFullYear()+n,month:i+1}}}),BI.shortcut("bi.calendar",BI.Calendar)},function(e,t){BI.YearCalendar=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.YearCalendar.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:"bi-year-calendar",behaviors:{},logic:{dynamic:!1},min:"1900-01-01",max:"2099-12-31",year:null})},_yearCreator:function(e){var t=this.options;e|=0;var n=BI.YearCalendar.getStartYear(e),i=[],r=BI.parseDateTime(t.min,"%Y-%X-%d"),a=BI.parseDateTime(t.max,"%Y-%X-%d");return BI.each(BI.range(BI.YearCalendar.INTERVAL),(function(e){var t={};BI.checkDateVoid(n+e,1,1,BI.print(BI.getDate(r.getFullYear(),0,1),"%Y-%X-%d"),BI.print(BI.getDate(a.getFullYear(),0,1),"%Y-%X-%d"))[0]&&(t.disabled=!0),t.text=n+e,i.push(t)})),i},_init:function(){BI.YearCalendar.superclass._init.apply(this,arguments);var e=this,t=this.options;this.currentYear=BI.getDate().getFullYear(),this.years=BI.createWidget({type:"bi.button_group",behaviors:t.behaviors,items:BI.createItems(this._getItems(),{}),layouts:[BI.LogicFactory.createLogic("table",BI.extend({},t.logic,{columns:2,rows:6,columnSize:[.5,.5],rowSize:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT})),{type:"bi.center_adapt",vgap:1}]}),this.years.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("vertical",BI.extend({},t.logic,{items:BI.LogicFactory.createLogicItemsByDirection("top",this.years)}))))},isFrontYear:function(){var e=this.options,t=e.year;return t|=0,!!BI.checkDateVoid(BI.YearCalendar.getStartYear(t)-1,1,1,e.min,e.max)[0]},isFinalYear:function(){var e=this.options,t=(this._const,e.year);return t|=0,!!BI.checkDateVoid(BI.YearCalendar.getEndYear(t)+1,1,1,e.min,e.max)[0]},_getItems:function(){var e=this.options,t=this._yearCreator(e.year||this.currentYear),n=t.length,i=BI.makeArray(n,""),r=[0,6,1,7,2,8,3,9,4,10,5,11];BI.each(t,(function(e,n){i[e]=t[r[e]]}));var a=[];return a.push(i.slice(0,2)),a.push(i.slice(2,4)),a.push(i.slice(4,6)),a.push(i.slice(6,8)),a.push(i.slice(8,10)),a.push(i.slice(10,12)),BI.map(a,(function(e,t){return BI.map(t,(function(e,t){return BI.extend(t,{type:"bi.text_item",cls:"bi-list-item-select",textAlign:"center",whiteSpace:"normal",once:!1,forceSelected:!0,height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,width:45,value:t.text,disabled:t.disabled})}))}))},_populate:function(){this.years.populate(this._getItems())},setMinDate:function(e){var t=this.options;BI.isNotEmptyString(t.min)&&(t.min=e,this._populate())},setMaxDate:function(e){var t=this.options;BI.isNotEmptyString(this.options.max)&&(t.max=e,this._populate())},setValue:function(e){this.years.setValue([e])},getValue:function(){return this.years.getValue()[0]}}),BI.extend(BI.YearCalendar,{INTERVAL:12,getStartYear:function(e){return e-((e-BI.getDate().getFullYear()+3)%BI.YearCalendar.INTERVAL+12)%BI.YearCalendar.INTERVAL},getEndYear:function(e){return BI.YearCalendar.getStartYear(e)+BI.YearCalendar.INTERVAL-1},getPageByYear:function(e){var t=BI.getDate().getFullYear();return((e=BI.YearCalendar.getStartYear(e))-t+3)/BI.YearCalendar.INTERVAL}}),BI.shortcut("bi.year_calendar",BI.YearCalendar)},function(e,t){BI.ArrowTreeGroupNodeCheckbox=BI.inherit(BI.IconButton,{_defaultConfig:function(){return BI.extend(BI.ArrowTreeGroupNodeCheckbox.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-arrow-group-node-checkbox"})},setSelected:function(e){BI.ArrowTreeGroupNodeCheckbox.superclass.setSelected.apply(this,arguments),e?this.element.removeClass("expander-right-font").addClass("expander-down-font"):this.element.removeClass("expander-down-font").addClass("expander-right-font")}}),BI.shortcut("bi.arrow_group_node_checkbox",BI.ArrowTreeGroupNodeCheckbox)},function(e,t){BI.CheckingMarkNode=BI.inherit(BI.IconButton,{_defaultConfig:function(){return BI.extend(BI.CheckingMarkNode.superclass._defaultConfig.apply(this,arguments),{extraCls:"check-mark-font"})},_init:function(){BI.CheckingMarkNode.superclass._init.apply(this,arguments),this.setSelected(this.options.selected)},setSelected:function(e){BI.CheckingMarkNode.superclass.setSelected.apply(this,arguments),!0===e?this.element.addClass("check-mark-font"):this.element.removeClass("check-mark-font")}}),BI.shortcut("bi.checking_mark_node",BI.CheckingMarkNode)},function(e,t){BI.FirstTreeNodeCheckbox=BI.inherit(BI.IconButton,{_defaultConfig:function(){return BI.extend(BI.FirstTreeNodeCheckbox.superclass._defaultConfig.apply(this,arguments),{extraCls:"tree-collapse-icon-type2",iconWidth:24,iconHeight:24})},setSelected:function(e){BI.FirstTreeNodeCheckbox.superclass.setSelected.apply(this,arguments),!0===e?this.element.addClass("tree-expand-icon-type2"):this.element.removeClass("tree-expand-icon-type2")}}),BI.shortcut("bi.first_tree_node_checkbox",BI.FirstTreeNodeCheckbox)},function(e,t){BI.LastTreeNodeCheckbox=BI.inherit(BI.IconButton,{_defaultConfig:function(){return BI.extend(BI.LastTreeNodeCheckbox.superclass._defaultConfig.apply(this,arguments),{extraCls:"tree-collapse-icon-type4",iconWidth:24,iconHeight:24})},setSelected:function(e){BI.LastTreeNodeCheckbox.superclass.setSelected.apply(this,arguments),!0===e?this.element.addClass("tree-expand-icon-type4"):this.element.removeClass("tree-expand-icon-type4")}}),BI.shortcut("bi.last_tree_node_checkbox",BI.LastTreeNodeCheckbox)},function(e,t){BI.MidTreeNodeCheckbox=BI.inherit(BI.IconButton,{_defaultConfig:function(){return BI.extend(BI.MidTreeNodeCheckbox.superclass._defaultConfig.apply(this,arguments),{extraCls:"tree-collapse-icon-type3",iconWidth:24,iconHeight:24})},setSelected:function(e){BI.MidTreeNodeCheckbox.superclass.setSelected.apply(this,arguments),!0===e?this.element.addClass("tree-expand-icon-type3"):this.element.removeClass("tree-expand-icon-type3")}}),BI.shortcut("bi.mid_tree_node_checkbox",BI.MidTreeNodeCheckbox)},function(e,t){BI.TreeNodeCheckbox=BI.inherit(BI.IconButton,{_defaultConfig:function(){return BI.extend(BI.TreeNodeCheckbox.superclass._defaultConfig.apply(this,arguments),{extraCls:"tree-collapse-icon-type1",iconWidth:24,iconHeight:24})},setSelected:function(e){BI.TreeNodeCheckbox.superclass.setSelected.apply(this,arguments),e?this.element.addClass("tree-expand-icon-type1"):this.element.removeClass("tree-expand-icon-type1")}}),BI.shortcut("bi.tree_node_checkbox",BI.TreeNodeCheckbox)},function(e,t){BI.CustomColorChooser=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.CustomColorChooser.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-custom-color-chooser",width:292,height:265})},_init:function(){BI.CustomColorChooser.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget(t.editor,{type:"bi.simple_hex_color_picker_editor"}),this.editor.on(BI.ColorPickerEditor.EVENT_CHANGE,(function(){e.setValue(this.getValue())})),this.farbtastic=BI.createWidget({type:"bi.farbtastic"}),this.farbtastic.on(BI.Farbtastic.EVENT_CHANGE,(function(){e.setValue(this.getValue())})),BI.createWidget({type:"bi.vtape",element:this,items:[{type:"bi.absolute",items:[{el:this.editor,left:0,top:0,right:0}],height:50},{type:"bi.absolute",items:[{el:this.farbtastic,left:46,right:46,top:7}],height:215}]})},setValue:function(e){this.editor.setValue(e),this.farbtastic.setValue(e)},getValue:function(){return this.editor.getValue()}}),BI.CustomColorChooser.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.custom_color_chooser",BI.CustomColorChooser)},function(e,t){BI.ColorChooser=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.ColorChooser.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-color-chooser",value:"",height:24,el:{}})},_init:function(){var e=this,t=this.options;BI.ColorChooser.superclass._init.apply(this,arguments),t.value=t.value||"",this.combo=BI.createWidget({type:"bi.combo",element:this,container:t.container,adjustLength:1,isNeedAdjustWidth:!1,isNeedAdjustHeight:!1,el:BI.extend({type:t.width<=24?"bi.color_chooser_trigger":"bi.long_color_chooser_trigger",ref:function(t){e.trigger=t},width:t.el.type?t.width:t.width-2,height:t.el.type?t.height:t.height-2},t.el),popup:{el:BI.extend({type:"bi.hex_color_chooser_popup",ref:function(t){e.colorPicker=t},listeners:[{eventName:BI.ColorChooserPopup.EVENT_VALUE_CHANGE,action:function(){n(),e._isRGBColor(e.colorPicker.getValue())||e.combo.hideView()}},{eventName:BI.ColorChooserPopup.EVENT_CHANGE,action:function(){n(),e.combo.hideView()}}]},t.popup),value:t.value,width:292},value:t.value});var n=function(){var t=e.colorPicker.getValue();e.trigger.setValue(t)};this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,(function(){e.fireEvent(BI.ColorChooser.EVENT_CHANGE,arguments)}))},_isRGBColor:function(e){return BI.isNotEmptyString(e)&&"transparent"!==e},isViewVisible:function(){return this.combo.isViewVisible()},hideView:function(){this.combo.hideView()},showView:function(){this.combo.showView()},setValue:function(e){this.combo.setValue(e||"")},getValue:function(){return this.combo.getValue()}}),BI.ColorChooser.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.color_chooser",BI.ColorChooser)},function(e,t){BI.HexColorChooserPopup=BI.inherit(BI.Widget,{props:{baseCls:"bi-color-chooser-popup",width:292,height:195,simple:!1},render:function(){var e=this,t=this.options;return{type:"bi.absolute",items:[{el:{type:"bi.vtape",items:[{el:BI.extend({type:t.simple?"bi.simple_hex_color_picker_editor":"bi.hex_color_picker_editor",value:t.value,height:30,listeners:[{eventName:BI.ColorPickerEditor.EVENT_CHANGE,action:function(){e.setValue(this.getValue()),e._dealStoreColors(),e.fireEvent(BI.ColorChooserPopup.EVENT_VALUE_CHANGE,arguments)}}],ref:function(t){e.colorEditor=t}},t.editor),height:50},{el:{type:"bi.absolute",items:[{el:{type:"bi.color_picker",cls:"bi-border-bottom bi-border-right",items:[this._digestStoreColors(this._getStoreColors())],height:34,value:t.value,listeners:[{eventName:BI.ColorPicker.EVENT_CHANGE,action:function(){e.setValue(this.getValue()[0]),e._dealStoreColors(),e.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE,arguments)}}],ref:function(t){e.storeColors=t}},left:10,right:10,top:5}]},height:38},{el:{type:"bi.absolute",items:[{el:{type:"bi.color_picker",value:t.value,listeners:[{eventName:BI.ColorPicker.EVENT_CHANGE,action:function(){e.setValue(this.getValue()[0]),e._dealStoreColors(),e.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE,arguments)}}],ref:function(t){e.colorPicker=t}},left:10,right:10,top:5,bottom:10}]}},{el:{type:"bi.combo",cls:"bi-border-top",container:null,direction:"right,top",isNeedAdjustHeight:!1,el:{type:"bi.text_item",cls:"color-chooser-popup-more bi-list-item",textAlign:"center",height:24,textLgap:10,text:BI.i18nText("BI-Basic_More")+"..."},popup:{type:"bi.popup_panel",buttons:[BI.i18nText("BI-Basic_Cancel"),BI.i18nText("BI-Basic_Save")],title:BI.i18nText("BI-Custom_Color"),el:{type:"bi.custom_color_chooser",editor:t.editor,ref:function(t){e.customColorChooser=t}},stopPropagation:!1,bgap:-1,rgap:1,lgap:1,minWidth:227,listeners:[{eventName:BI.PopupPanel.EVENT_CLICK_TOOLBAR_BUTTON,action:function(t){switch(t){case 0:e.more.hideView();break;case 1:var n=e.customColorChooser.getValue();BI.isNotEmptyString(n)&&(e.setValue(n),e._dealStoreColors()),e.more.hideView(),e.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE,arguments)}}}]},listeners:[{eventName:BI.Combo.EVENT_AFTER_POPUPVIEW,action:function(){e.customColorChooser.setValue(e.getValue())}}],ref:function(t){e.more=t}},height:24}]},left:0,right:0,top:0,bottom:0},{el:{type:"bi.layout",cls:"disable-mask",invisible:!t.disabled,ref:function(){e.mask=this}},left:0,right:0,top:0,bottom:0}]}},mounted:function(){var e=this.options;BI.isNotNull(e.value)&&this.setValue(e.value)},_setEnable:function(e){BI.ColorChooserPopup.superclass._setEnable.apply(this,arguments),this.mask.setVisible(!e)},_dealStoreColors:function(){var e=this.getValue(),t=this._getStoreColors(),n=new BI.Queue(8);n.fromArray(t),n.remove(e),n.unshift(e);var i=n.toArray();BI.Cache.setItem("colors",BI.array2String(i)),this.setStoreColors(i)},_digestStoreColors:function(e){var t=BI.map(e,(function(e,t){return{value:t}}));return BI.count(e.length,8,(function(e){t.push({value:"",disabled:!0})})),t},_getStoreColors:function(){var e=this,t=this.options,n=BI.string2Array(BI.Cache.getItem("colors")||"");return BI.filter(n,(function(n,i){return!t.simple||e._isRGBColor(i)}))},_isRGBColor:function(e){return BI.isNotEmptyString(e)&&"transparent"!==e},setStoreColors:function(e){BI.isArray(e)&&(this.storeColors.populate([this._digestStoreColors(e)]),this.storeColors.setValue(this.getValue()))},setValue:function(e){this.colorEditor.setValue(e),this.colorPicker.setValue(e),this.storeColors.setValue(e)},getValue:function(){return this.colorEditor.getValue()}}),BI.HexColorChooserPopup.EVENT_VALUE_CHANGE="EVENT_VALUE_CHANGE",BI.HexColorChooserPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.hex_color_chooser_popup",BI.HexColorChooserPopup)},function(e,t){BI.SimpleHexColorChooserPopup=BI.inherit(BI.Widget,{props:{baseCls:"bi-color-chooser-popup"},render:function(){var e=this;return{type:"bi.hex_color_chooser_popup",value:this.options.value,simple:!0,listeners:[{eventName:BI.ColorChooserPopup.EVENT_CHANGE,action:function(){e.fireEvent(BI.SimpleColorChooserPopup.EVENT_CHANGE,arguments)}},{eventName:BI.ColorChooserPopup.EVENT_VALUE_CHANGE,action:function(){e.fireEvent(BI.SimpleColorChooserPopup.EVENT_VALUE_CHANGE,arguments)}}],ref:function(t){e.popup=t}}},setStoreColors:function(e){this.popup.setStoreColors(e)},setValue:function(e){this.popup.setValue(e)},getValue:function(){return this.popup.getValue()}}),BI.SimpleHexColorChooserPopup.EVENT_VALUE_CHANGE="EVENT_VALUE_CHANGE",BI.SimpleHexColorChooserPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.simple_hex_color_chooser_popup",BI.SimpleHexColorChooserPopup)},function(e,t){BI.ColorChooserPopup=BI.inherit(BI.Widget,{props:{baseCls:"bi-color-chooser-popup",width:230,height:145,simple:!1},render:function(){var e=this,t=this.options;this.colorEditor=BI.createWidget(t.editor,{type:t.simple?"bi.simple_color_picker_editor":"bi.color_picker_editor",value:t.value,cls:"bi-header-background bi-border-bottom",height:30}),this.colorEditor.on(BI.ColorPickerEditor.EVENT_CHANGE,(function(){e.setValue(this.getValue()),e._dealStoreColors(),e.fireEvent(BI.ColorChooserPopup.EVENT_VALUE_CHANGE,arguments)})),this.storeColors=BI.createWidget({type:"bi.color_picker",cls:"bi-border-bottom bi-border-right",items:[this._digestStoreColors(this._getStoreColors())],width:210,height:24,value:t.value}),this.storeColors.on(BI.ColorPicker.EVENT_CHANGE,(function(){e.setValue(this.getValue()[0]),e._dealStoreColors(),e.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE,arguments)})),this.colorPicker=BI.createWidget({type:"bi.color_picker",width:210,height:50,value:t.value}),this.colorPicker.on(BI.ColorPicker.EVENT_CHANGE,(function(){e.setValue(this.getValue()[0]),e._dealStoreColors(),e.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE,arguments)})),this.customColorChooser=BI.createWidget({type:"bi.custom_color_chooser",editor:t.editor});var n=BI.createWidget({type:"bi.popup_panel",buttons:[BI.i18nText("BI-Basic_Cancel"),BI.i18nText("BI-Basic_Save")],title:BI.i18nText("BI-Custom_Color"),el:this.customColorChooser,stopPropagation:!1,bgap:-1,rgap:1,lgap:1,minWidth:227});return this.more=BI.createWidget({type:"bi.combo",cls:"bi-border-top",container:null,direction:"right,top",isNeedAdjustHeight:!1,el:{type:"bi.text_item",cls:"color-chooser-popup-more bi-list-item",textAlign:"center",height:24,textLgap:10,text:BI.i18nText("BI-Basic_More")+"..."},popup:n}),this.more.on(BI.Combo.EVENT_AFTER_POPUPVIEW,(function(){e.customColorChooser.setValue(e.getValue())})),n.on(BI.PopupPanel.EVENT_CLICK_TOOLBAR_BUTTON,(function(t){switch(t){case 0:e.more.hideView();break;case 1:e.setValue(e.customColorChooser.getValue()),e._dealStoreColors(),e.more.hideView(),e.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE,arguments)}})),{type:"bi.absolute",items:[{el:{type:"bi.vtape",items:[this.colorEditor,{el:{type:"bi.absolute",items:[{el:this.storeColors,left:10,right:10,top:5}]},height:29},{el:{type:"bi.absolute",items:[{el:this.colorPicker,left:10,right:10,top:5,bottom:5}]},height:60},{el:this.more,height:24}]},left:0,right:0,top:0,bottom:0},{el:{type:"bi.layout",cls:"disable-mask",invisible:!t.disabled,ref:function(){e.mask=this}},left:0,right:0,top:0,bottom:0}]}},mounted:function(){var e=this.options;BI.isNotNull(e.value)&&this.setValue(e.value)},_setEnable:function(e){BI.ColorChooserPopup.superclass._setEnable.apply(this,arguments),this.mask.setVisible(!e)},_dealStoreColors:function(){var e=this.getValue(),t=this._getStoreColors(),n=new BI.Queue(8);n.fromArray(t),n.remove(e),n.unshift(e);var i=n.toArray();BI.Cache.setItem("colors",BI.array2String(i)),this.setStoreColors(i)},_digestStoreColors:function(e){var t=BI.map(e,(function(e,t){return{value:t}}));return BI.count(e.length,8,(function(e){t.push({value:"",disabled:!0})})),t},_getStoreColors:function(){var e=this,t=this.options,n=BI.string2Array(BI.Cache.getItem("colors")||"");return BI.filter(n,(function(n,i){return!t.simple||e._isRGBColor(i)}))},_isRGBColor:function(e){return BI.isNotEmptyString(e)&&"transparent"!==e},setStoreColors:function(e){BI.isArray(e)&&(this.storeColors.populate([this._digestStoreColors(e)]),this.storeColors.setValue(this.getValue()))},setValue:function(e){this.colorEditor.setValue(e),this.colorPicker.setValue(e),this.storeColors.setValue(e)},getValue:function(){return this.colorEditor.getValue()}}),BI.ColorChooserPopup.EVENT_VALUE_CHANGE="EVENT_VALUE_CHANGE",BI.ColorChooserPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.color_chooser_popup",BI.ColorChooserPopup)},function(e,t){BI.SimpleColorChooserPopup=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SimpleColorChooserPopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-color-chooser-popup"})},_init:function(){BI.SimpleColorChooserPopup.superclass._init.apply(this,arguments);var e=this,t=this.options;this.popup=BI.createWidget({type:t.hex?"bi.hex_color_chooser_popup":"bi.color_chooser_popup",value:t.value,element:this,simple:!0}),this.popup.on(BI.ColorChooserPopup.EVENT_CHANGE,(function(){e.fireEvent(BI.SimpleColorChooserPopup.EVENT_CHANGE,arguments)})),this.popup.on(BI.ColorChooserPopup.EVENT_VALUE_CHANGE,(function(){e.fireEvent(BI.SimpleColorChooserPopup.EVENT_VALUE_CHANGE,arguments)}))},setStoreColors:function(e){this.popup.setStoreColors(e)},setValue:function(e){this.popup.setValue(e)},getValue:function(){return this.popup.getValue()}}),BI.SimpleColorChooserPopup.EVENT_VALUE_CHANGE="EVENT_VALUE_CHANGE",BI.SimpleColorChooserPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.simple_color_chooser_popup",BI.SimpleColorChooserPopup)},function(e,t){BI.SimpleColorChooser=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SimpleColorChooser.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-simple-color-chooser",value:"#ffffff"})},_init:function(){BI.SimpleColorChooser.superclass._init.apply(this,arguments);var e=this,t=this.options;this.combo=BI.createWidget({type:"bi.color_chooser",element:this,container:t.container,value:t.value,width:t.width,height:t.height,popup:{type:"bi.simple_hex_color_chooser_popup"}}),this.combo.on(BI.ColorChooser.EVENT_CHANGE,(function(){e.fireEvent(BI.SimpleColorChooser.EVENT_CHANGE,arguments)}))},isViewVisible:function(){return this.combo.isViewVisible()},hideView:function(){this.combo.hideView()},showView:function(){this.combo.showView()},setValue:function(e){this.combo.setValue(e)},getValue:function(){return this.combo.getValue()}}),BI.SimpleColorChooser.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.simple_color_chooser",BI.SimpleColorChooser)},function(e,t){BI.ColorChooserTrigger=BI.inherit(BI.Trigger,{_defaultConfig:function(){var e=BI.ColorChooserTrigger.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-color-chooser-trigger bi-border bi-focus-shadow",height:22})},_init:function(){BI.ColorChooserTrigger.superclass._init.apply(this,arguments),this.colorContainer=BI.createWidget({type:"bi.layout",cls:"color-chooser-trigger-content"+(BI.isIE9Below&&BI.isIE9Below()?" hack":"")});var e=BI.createWidget({type:"bi.icon_button",disableSelected:!0,cls:"icon-combo-down-icon trigger-triangle-font icon-size-12",width:12,height:8});BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.colorContainer,left:2,right:2,top:2,bottom:2},{el:e,right:-1,bottom:1}]}),BI.isNotNull(this.options.value)&&this.setValue(this.options.value)},setValue:function(e){BI.ColorChooserTrigger.superclass.setValue.apply(this,arguments),""===e?this.colorContainer.element.css("background-color","").removeClass("trans-color-background").addClass("auto-color-background"):"transparent"===e?this.colorContainer.element.css("background-color","").removeClass("auto-color-background").addClass("trans-color-background"):this.colorContainer.element.css({"background-color":e}).removeClass("auto-color-background").removeClass("trans-color-background")}}),BI.ColorChooserTrigger.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.color_chooser_trigger",BI.ColorChooserTrigger)},function(e,t){BI.LongColorChooserTrigger=BI.inherit(BI.Trigger,{_defaultConfig:function(){var e=BI.LongColorChooserTrigger.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-color-chooser-trigger bi-border bi-focus-shadow",height:24})},_init:function(){BI.LongColorChooserTrigger.superclass._init.apply(this,arguments);var e=this;this.options;this.colorContainer=BI.createWidget({type:"bi.htape",cls:"color-chooser-trigger-content",items:[{type:"bi.icon_change_button",ref:function(t){e.changeIcon=t},disableSelected:!0,iconCls:"auto-color-icon",width:24,iconWidth:16,iconHeight:16},{el:{type:"bi.label",ref:function(t){e.label=t},textAlign:"left",hgap:5,height:18,text:BI.i18nText("BI-Basic_Auto")}}]});var t=BI.createWidget({type:"bi.icon_button",disableSelected:!0,cls:"icon-combo-down-icon trigger-triangle-font icon-size-12",width:12,height:8});BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.colorContainer,left:2,right:2,top:2,bottom:2},{el:t,right:3,bottom:3}]}),this.options.value&&this.setValue(this.options.value)},setValue:function(e){BI.LongColorChooserTrigger.superclass.setValue.apply(this,arguments),""===e?(this.colorContainer.element.css("background-color",""),this.changeIcon.setVisible(!0),this.label.setVisible(!0),this.changeIcon.setIcon("auto-color-icon"),this.label.setText(BI.i18nText("BI-Basic_Auto"))):"transparent"===e?(this.colorContainer.element.css("background-color",""),this.changeIcon.setVisible(!0),this.label.setVisible(!0),this.changeIcon.setIcon("trans-color-icon"),this.label.setText(BI.i18nText("BI-Transparent_Color"))):(this.colorContainer.element.css({"background-color":e}),this.changeIcon.setVisible(!1),this.label.setVisible(!1))}}),BI.LongColorChooserTrigger.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.long_color_chooser_trigger",BI.LongColorChooserTrigger)},function(e,t){BI.ColorPickerButton=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.ColorPickerButton.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-color-picker-button bi-background bi-border-top bi-border-left"})},_init:function(){BI.ColorPickerButton.superclass._init.apply(this,arguments);var e=this,t=this.options;if(t.value){this.element.css("background-color",t.value);var n=this.getName();this.element.hover((function(){e._createMask(),e.isEnabled()&&BI.Maskers.show(n)}),(function(){e.isSelected()||BI.Maskers.hide(n)}))}},_createMask:function(){var e=this.options,t=this.getName();this.isEnabled()&&!BI.Maskers.has(t)&&BI.Maskers.make(t,this,{offset:{left:-1,top:-1,right:-1,bottom:-1}}).element.addClass("color-picker-button-mask").css("background-color",e.value)},setSelected:function(e){BI.ColorPickerButton.superclass.setSelected.apply(this,arguments),e&&this._createMask(),BI.Maskers[e?"show":"hide"](this.getName())}}),BI.ColorPickerButton.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.color_picker_button",BI.ColorPickerButton)},function(e,t){BI.ColorPicker=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.ColorPicker.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-color-picker",items:null})},_items:[[{value:"#ffffff"},{value:"#f2f2f2"},{value:"#e5e5e5"},{value:"#d9d9d9"},{value:"#cccccc"},{value:"#bfbfbf"},{value:"#b2b2b2"},{value:"#a6a6a6"},{value:"#999999"},{value:"#8c8c8c"},{value:"#808080"},{value:"#737373"},{value:"#666666"},{value:"#4d4d4d"},{value:"#333333"},{value:"#000000"}],[{value:"#d8b5a6"},{value:"#ff9e9a"},{value:"#ffc17d"},{value:"#f5e56b"},{value:"#d8e698"},{value:"#e0ebaf"},{value:"#c3d825"},{value:"#bbe2e7"},{value:"#85d3cd"},{value:"#bde1e6"},{value:"#a0d8ef"},{value:"#89c3eb"},{value:"#bbc8e6"},{value:"#bbbcde"},{value:"#d6b4cc"},{value:"#fbc0d3"}],[{value:"#bb9581"},{value:"#f37d79"},{value:"#fba74f"},{value:"#ffdb4f"},{value:"#c7dc68"},{value:"#b0ca71"},{value:"#99ab4e"},{value:"#84b9cb"},{value:"#00a3af"},{value:"#2ca9e1"},{value:"#0095d9"},{value:"#4c6cb3"},{value:"#8491c3"},{value:"#a59aca"},{value:"#cc7eb1"},{value:"#e89bb4"}],[{value:"#9d775f"},{value:"#dd4b4b"},{value:"#ef8b07"},{value:"#fcc800"},{value:"#aacf53"},{value:"#82ae46"},{value:"#69821b"},{value:"#59b9c6"},{value:"#2a83a2"},{value:"#007bbb"},{value:"#19448e"},{value:"#274a78"},{value:"#4a488e"},{value:"#7058a3"},{value:"#884898"},{value:"#d47596"}]],_init:function(){BI.ColorPicker.superclass._init.apply(this,arguments);var e=this,t=this.options;this.colors=BI.createWidget({type:"bi.button_group",element:this,items:BI.createItems(t.items||this._items,{type:"bi.color_picker_button",once:!1}),layouts:[{type:"bi.grid"}],value:t.value}),this.colors.on(BI.ButtonGroup.EVENT_CHANGE,(function(){e.fireEvent(BI.ColorPicker.EVENT_CHANGE,arguments)}))},populate:function(e){var t=[].slice.call(arguments);t[0]=BI.createItems(e,{type:"bi.color_picker_button",once:!1}),this.colors.populate.apply(this.colors,t)},setValue:function(e){this.colors.setValue(e)},getValue:function(){return this.colors.getValue()}}),BI.ColorPicker.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.color_picker",BI.ColorPicker)},function(e,t){BI.HexColorPickerEditor=BI.inherit(BI.Widget,{constants:{RGB_WIDTH:32,HEX_WIDTH:70,HEX_PREFIX_POSITION:1},props:{baseCls:"bi-color-picker-editor",height:50},render:function(){var e=this,t=(this.options,this.constants);this.storeValue={};var n=BI.createItems([{text:"R"},{text:"G"},{text:"B"}],{type:"bi.label",cls:"color-picker-editor-label",height:20}),i=function(e){return BI.isNumeric(e)&&(0|e)>=0&&(0|e)<=255},r=BI.map(BI.range(0,3),(function(){return{type:"bi.small_text_editor",cls:"color-picker-editor-input",validationChecker:i,errorText:BI.i18nText("BI-Color_Picker_Error_Text"),allowBlank:!0,value:255,width:t.RGB_WIDTH,height:20,listeners:[{eventName:BI.TextEditor.EVENT_CHANGE,action:function(){e._checkEditors(),i(e.storeValue.r)&&i(e.storeValue.g)&&i(e.storeValue.b)&&(e.colorShow.element.css("background-color",e.getValue()),e.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE))}}]}}));return{type:"bi.absolute",items:[{el:{type:"bi.vertical",tgap:5,items:[{type:"bi.vertical_adapt",rgap:5,items:[{el:{type:"bi.layout",cls:"color-picker-editor-display bi-card bi-border",height:16,width:16,ref:function(t){e.colorShow=t}},width:16},{type:"bi.label",text:"#",width:10},{type:"bi.small_text_editor",ref:function(t){e.hexEditor=t},cls:"color-picker-editor-input",validationChecker:this._hexChecker,allowBlank:!0,errorText:BI.i18nText("BI-Color_Picker_Error_Text_Hex"),width:t.HEX_WIDTH,height:20,listeners:[{eventName:"EVENT_CHANGE",action:function(){e._checkHexEditor(),i(e.storeValue.r)&&i(e.storeValue.g)&&i(e.storeValue.b)&&(e.colorShow.element.css("background-color",e.getValue()),e.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE))}}]},{el:BI.extend(r[0],{ref:function(t){e.R=t}}),width:t.RGB_WIDTH},{el:BI.extend(r[1],{ref:function(t){e.G=t}}),width:t.RGB_WIDTH},{el:BI.extend(r[2],{ref:function(t){e.B=t}}),width:t.RGB_WIDTH},{el:{type:"bi.icon_button",cls:"trans-color-icon",width:16,height:16,iconWidth:16,iconHeight:16,title:BI.i18nText("BI-Transparent_Color"),listeners:[{eventName:BI.IconButton.EVENT_CHANGE,action:function(){this.isSelected()?(e.lastColor=e.getValue(),e.setValue("transparent")):("transparent"===e.lastColor&&(e.lastColor=""),e.setValue(e.lastColor||"#ffffff")),(e.R.isValid()&&e.G.isValid()&&e.B.isValid()||e._isEmptyRGB())&&(e.colorShow.element.css("background-color",e.getValue()),e.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE))}}],ref:function(t){e.transparent=t}},width:16,lgap:5},{el:{type:"bi.icon_button",cls:"auto-color-icon",width:16,height:16,iconWidth:16,iconHeight:16,title:BI.i18nText("BI-Basic_Auto"),listeners:[{eventName:BI.IconButton.EVENT_CHANGE,action:function(){this.isSelected()?(e.lastColor=e.getValue(),e.setValue("")):e.setValue(e.lastColor||"#ffffff"),(e.R.isValid()&&e.G.isValid()&&e.B.isValid()||e._isEmptyRGB())&&(e.colorShow.element.css("background-color",e.getValue()),e.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE))}}],ref:function(t){e.none=t}},width:16,lgap:5}]},{type:"bi.vertical_adapt",items:[{el:{type:"bi.label",cls:"color-picker-editor-label",height:20,text:"HEX"},lgap:60},{el:n[0].el,lgap:44},{el:n[1].el,lgap:28},{el:n[2].el,lgap:28}]}]},left:10,right:10,top:0,bottom:0}]}},_hexChecker:function(e){return/^[0-9a-fA-F]{6}$/.test(e)},_checkEditors:function(){BI.isEmptyString(this.R.getValue())&&this.R.setValue(0),BI.isEmptyString(this.G.getValue())&&this.G.setValue(0),BI.isEmptyString(this.B.getValue())&&this.B.setValue(0),this.storeValue={r:this.R.getValue()||0,g:this.G.getValue()||0,b:this.B.getValue()||0},this.hexEditor.setValue(this.getValue().slice(this.constants.HEX_PREFIX_POSITION))},_isEmptyRGB:function(){return BI.isEmptyString(this.storeValue.r)&&BI.isEmptyString(this.storeValue.g)&&BI.isEmptyString(this.storeValue.b)},_checkHexEditor:function(){BI.isEmptyString(this.hexEditor.getValue())&&this.hexEditor.setValue("000000");var e=BI.DOM.rgb2json(BI.DOM.hex2rgb("#"+this.hexEditor.getValue()));this.storeValue={r:e.r||0,g:e.g||0,b:e.b||0},this.R.setValue(this.storeValue.r),this.G.setValue(this.storeValue.g),this.B.setValue(this.storeValue.b)},_showPreColor:function(e){""===e?this.colorShow.element.css("background-color","").removeClass("trans-color-background").addClass("auto-color-normal-background"):"transparent"===e?this.colorShow.element.css("background-color","").removeClass("auto-color-normal-background").addClass("trans-color-background"):this.colorShow.element.css({"background-color":e}).removeClass("auto-color-normal-background").removeClass("trans-color-background")},_setEnable:function(e){BI.ColorPickerEditor.superclass._setEnable.apply(this,arguments),!0===e?this.element.removeClass("base-disabled disabled"):!1===e&&this.element.addClass("base-disabled disabled")},setValue:function(e){if("transparent"===e)return this.transparent.setSelected(!0),this.none.setSelected(!1),this._showPreColor("transparent"),this.R.setValue(""),this.G.setValue(""),this.B.setValue(""),this.hexEditor.setValue(""),void(this.storeValue={r:"",g:"",b:""});e?this.none.setSelected(!1):(e="",this.none.setSelected(!0)),this.transparent.setSelected(!1),this._showPreColor(e);var t=BI.DOM.rgb2json(BI.DOM.hex2rgb(e));this.storeValue={r:BI.isNull(t.r)?"":t.r,g:BI.isNull(t.g)?"":t.g,b:BI.isNull(t.b)?"":t.b},this.R.setValue(this.storeValue.r),this.G.setValue(this.storeValue.g),this.B.setValue(this.storeValue.b),this.hexEditor.setValue(e.slice(this.constants.HEX_PREFIX_POSITION))},getValue:function(){return this._isEmptyRGB()&&this.transparent.isSelected()?"transparent":BI.DOM.rgb2hex(BI.DOM.json2rgb({r:this.storeValue.r,g:this.storeValue.g,b:this.storeValue.b}))}}),BI.HexColorPickerEditor.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.hex_color_picker_editor",BI.HexColorPickerEditor)},function(e,t){BI.SimpleHexColorPickerEditor=BI.inherit(BI.Widget,{constants:{RGB_WIDTH:40,HEX_WIDTH:70,HEX_PREFIX_POSITION:1},props:{baseCls:"bi-color-picker-editor",height:50},render:function(){var e=this,t=(this.options,this.constants),n=BI.createItems([{text:"R"},{text:"G"},{text:"B"}],{type:"bi.label",cls:"color-picker-editor-label",height:20}),i=function(e){return BI.isNumeric(e)&&(0|e)>=0&&(0|e)<=255},r=BI.map(BI.range(0,3),(function(){return{type:"bi.small_text_editor",cls:"color-picker-editor-input",validationChecker:i,errorText:BI.i18nText("BI-Color_Picker_Error_Text"),allowBlank:!0,value:255,width:t.RGB_WIDTH,height:20,listeners:[{eventName:BI.TextEditor.EVENT_CHANGE,action:function(){e._checkEditors(),e.R.isValid()&&e.G.isValid()&&e.B.isValid()&&(e.colorShow.element.css("background-color",e.getValue()),e.fireEvent(BI.SimpleColorPickerEditor.EVENT_CHANGE))}}]}}));return{type:"bi.vertical",tgap:5,items:[{type:"bi.vertical_adapt",rgap:10,items:[{el:{type:"bi.layout",cls:"color-picker-editor-display bi-card bi-border",height:16,width:16,ref:function(t){e.colorShow=t}},width:16,lgap:10,rgap:5},{type:"bi.label",text:"#",width:10},{type:"bi.small_text_editor",ref:function(t){e.hexEditor=t},cls:"color-picker-editor-input",validationChecker:this._hexChecker,allowBlank:!0,errorText:BI.i18nText("BI-Color_Picker_Error_Text_Hex"),width:t.HEX_WIDTH,height:20,listeners:[{eventName:"EVENT_CHANGE",action:function(){e._checkHexEditor(),i(e.storeValue.r)&&i(e.storeValue.g)&&i(e.storeValue.b)&&(e.colorShow.element.css("background-color",e.getValue()),e.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE))}}]},{el:BI.extend(r[0],{ref:function(t){e.R=t}}),width:t.RGB_WIDTH},{el:BI.extend(r[1],{ref:function(t){e.G=t}}),width:t.RGB_WIDTH},{el:BI.extend(r[2],{ref:function(t){e.B=t}}),width:t.RGB_WIDTH}]},{type:"bi.vertical_adapt",items:[{el:{type:"bi.label",cls:"color-picker-editor-label",height:20,text:"HEX"},lgap:86},{el:n[0].el,lgap:50},{el:n[1].el,lgap:40},{el:n[2].el,lgap:40}]}]}},_hexChecker:function(e){return/^[0-9a-fA-F]{6}$/.test(e)},_checkEditors:function(){BI.isEmptyString(this.R.getValue())&&this.R.setValue(0),BI.isEmptyString(this.G.getValue())&&this.G.setValue(0),BI.isEmptyString(this.B.getValue())&&this.B.setValue(0),this.hexEditor.setValue(this.getValue().slice(this.constants.HEX_PREFIX_POSITION))},_checkHexEditor:function(){BI.isEmptyString(this.hexEditor.getValue())&&this.hexEditor.setValue("000000");var e=BI.DOM.rgb2json(BI.DOM.hex2rgb("#"+this.hexEditor.getValue()));this.storeValue={r:e.r||0,g:e.g||0,b:e.b||0},this.R.setValue(this.storeValue.r),this.G.setValue(this.storeValue.g),this.B.setValue(this.storeValue.b)},setValue:function(e){this.colorShow.element.css({"background-color":e});var t=BI.DOM.rgb2json(BI.DOM.hex2rgb(e));this.R.setValue(BI.isNull(t.r)?"":t.r),this.G.setValue(BI.isNull(t.g)?"":t.g),this.B.setValue(BI.isNull(t.b)?"":t.b),this.hexEditor.setValue(BI.isEmptyObject(t)?"":e.slice(this.constants.HEX_PREFIX_POSITION))},getValue:function(){return BI.DOM.rgb2hex(BI.DOM.json2rgb({r:this.R.getValue(),g:this.G.getValue(),b:this.B.getValue()}))}}),BI.SimpleHexColorPickerEditor.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.simple_hex_color_picker_editor",BI.SimpleHexColorPickerEditor)},function(e,t){BI.ColorPickerEditor=BI.inherit(BI.Widget,{constants:{RGB_WIDTH:32},_defaultConfig:function(){return BI.extend(BI.ColorPickerEditor.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-color-picker-editor",height:30})},_init:function(){BI.ColorPickerEditor.superclass._init.apply(this,arguments);var e=this,t=(this.options,this.constants);this.storeValue={},this.colorShow=BI.createWidget({type:"bi.layout",cls:"color-picker-editor-display bi-card bi-border",height:16,width:16});var n=BI.createWidgets(BI.createItems([{text:"R"},{text:"G"},{text:"B"}],{type:"bi.label",cls:"color-picker-editor-label",width:20,height:20})),i=function(e){return BI.isNumeric(e)&&(0|e)>=0&&(0|e)<=255},r=BI.createWidgets([{},{},{}],{type:"bi.small_text_editor",cls:"color-picker-editor-input",validationChecker:i,errorText:BI.i18nText("BI-Color_Picker_Error_Text"),allowBlank:!0,value:255,width:t.RGB_WIDTH,height:20});BI.each(r,(function(t,n){n.on(BI.TextEditor.EVENT_CHANGE,(function(){e._checkEditors(),i(e.storeValue.r)&&i(e.storeValue.g)&&i(e.storeValue.b)&&(e.colorShow.element.css("background-color",e.getValue()),e.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE))}))})),this.R=r[0],this.G=r[1],this.B=r[2],this.none=BI.createWidget({type:"bi.icon_button",cls:"auto-color-icon",width:16,height:16,iconWidth:16,iconHeight:16,title:BI.i18nText("BI-Basic_Auto")}),this.none.on(BI.IconButton.EVENT_CHANGE,(function(){this.isSelected()?(e.lastColor=e.getValue(),e.setValue("")):e.setValue(e.lastColor||"#ffffff"),(e.R.isValid()&&e.G.isValid()&&e.B.isValid()||e._isEmptyRGB())&&(e.colorShow.element.css("background-color",e.getValue()),e.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE))})),this.transparent=BI.createWidget({type:"bi.icon_button",cls:"trans-color-icon",width:16,height:16,iconWidth:16,iconHeight:16,title:BI.i18nText("BI-Transparent_Color")}),this.transparent.on(BI.IconButton.EVENT_CHANGE,(function(){this.isSelected()?(e.lastColor=e.getValue(),e.setValue("transparent")):("transparent"===e.lastColor&&(e.lastColor=""),e.setValue(e.lastColor||"#ffffff")),(e.R.isValid()&&e.G.isValid()&&e.B.isValid()||e._isEmptyRGB())&&(e.colorShow.element.css("background-color",e.getValue()),e.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE))})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.vertical_adapt",items:[{el:this.colorShow,width:16},{el:n[0],width:20},{el:this.R,width:t.RGB_WIDTH},{el:n[1],width:20},{el:this.G,width:t.RGB_WIDTH},{el:n[2],width:20},{el:this.B,width:t.RGB_WIDTH},{el:this.transparent,width:16,lgap:5},{el:this.none,width:16,lgap:5}]},left:10,right:10,top:0,bottom:0}]})},_checkEditors:function(){BI.isEmptyString(this.R.getValue())&&this.R.setValue(0),BI.isEmptyString(this.G.getValue())&&this.G.setValue(0),BI.isEmptyString(this.B.getValue())&&this.B.setValue(0),this.storeValue={r:this.R.getValue()||0,g:this.G.getValue()||0,b:this.B.getValue()||0}},_isEmptyRGB:function(){return BI.isEmptyString(this.storeValue.r)&&BI.isEmptyString(this.storeValue.g)&&BI.isEmptyString(this.storeValue.b)},_showPreColor:function(e){""===e?this.colorShow.element.css("background-color","").removeClass("trans-color-background").addClass("auto-color-normal-background"):"transparent"===e?this.colorShow.element.css("background-color","").removeClass("auto-color-normal-background").addClass("trans-color-background"):this.colorShow.element.css({"background-color":e}).removeClass("auto-color-normal-background").removeClass("trans-color-background")},_setEnable:function(e){BI.ColorPickerEditor.superclass._setEnable.apply(this,arguments),!0===e?this.element.removeClass("base-disabled disabled"):!1===e&&this.element.addClass("base-disabled disabled")},setValue:function(e){if("transparent"===e)return this.transparent.setSelected(!0),this.none.setSelected(!1),this._showPreColor("transparent"),this.R.setValue(""),this.G.setValue(""),this.B.setValue(""),void(this.storeValue={r:"",g:"",b:""});e?this.none.setSelected(!1):(e="",this.none.setSelected(!0)),this.transparent.setSelected(!1),this._showPreColor(e);var t=BI.DOM.rgb2json(BI.DOM.hex2rgb(e));this.storeValue={r:BI.isNull(t.r)?"":t.r,g:BI.isNull(t.g)?"":t.g,b:BI.isNull(t.b)?"":t.b},this.R.setValue(this.storeValue.r),this.G.setValue(this.storeValue.g),this.B.setValue(this.storeValue.b)},getValue:function(){return this._isEmptyRGB()&&this.transparent.isSelected()?"transparent":BI.DOM.rgb2hex(BI.DOM.json2rgb({r:this.storeValue.r,g:this.storeValue.g,b:this.storeValue.b}))}}),BI.ColorPickerEditor.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.color_picker_editor",BI.ColorPickerEditor)},function(e,t){BI.SimpleColorPickerEditor=BI.inherit(BI.Widget,{constants:{RGB_WIDTH:32},_defaultConfig:function(){return BI.extend(BI.SimpleColorPickerEditor.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-color-picker-editor",height:30})},_init:function(){BI.SimpleColorPickerEditor.superclass._init.apply(this,arguments);var e=this,t=(this.options,this.constants);this.colorShow=BI.createWidget({type:"bi.layout",cls:"color-picker-editor-display bi-card bi-border",height:16,width:16});var n=BI.createWidgets(BI.createItems([{text:"R"},{text:"G"},{text:"B"}],{type:"bi.label",cls:"color-picker-editor-label",width:20,height:20})),i=function(e){return BI.isNumeric(e)&&(0|e)>=0&&(0|e)<=255},r=BI.createWidgets([{},{},{}],{type:"bi.small_text_editor",cls:"color-picker-editor-input",validationChecker:i,errorText:BI.i18nText("BI-Color_Picker_Error_Text"),allowBlank:!0,value:255,width:t.RGB_WIDTH,height:20});BI.each(r,(function(t,n){n.on(BI.TextEditor.EVENT_CHANGE,(function(){e._checkEditors(),e.R.isValid()&&e.G.isValid()&&e.B.isValid()&&(e.colorShow.element.css("background-color",e.getValue()),e.fireEvent(BI.SimpleColorPickerEditor.EVENT_CHANGE))}))})),this.R=r[0],this.G=r[1],this.B=r[2],BI.createWidget({type:"bi.vertical_adapt",element:this,items:[{el:this.colorShow,width:16,lgap:20,rgap:15},{el:n[0],width:20},{el:this.R,width:t.RGB_WIDTH},{el:n[1],width:20},{el:this.G,width:t.RGB_WIDTH},{el:n[2],width:20},{el:this.B,width:t.RGB_WIDTH}]})},_checkEditors:function(){BI.isEmptyString(this.R.getValue())&&this.R.setValue(0),BI.isEmptyString(this.G.getValue())&&this.G.setValue(0),BI.isEmptyString(this.B.getValue())&&this.B.setValue(0)},setValue:function(e){this.colorShow.element.css({"background-color":e});var t=BI.DOM.rgb2json(BI.DOM.hex2rgb(e));this.R.setValue(BI.isNull(t.r)?"":t.r),this.G.setValue(BI.isNull(t.g)?"":t.g),this.B.setValue(BI.isNull(t.b)?"":t.b)},getValue:function(){return BI.DOM.rgb2hex(BI.DOM.json2rgb({r:this.R.getValue(),g:this.G.getValue(),b:this.B.getValue()}))}}),BI.SimpleColorPickerEditor.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.simple_color_picker_editor",BI.SimpleColorPickerEditor)},function(e,t){BI.Farbtastic=BI.inherit(BI.BasicButton,{constants:{RADIUS:84,SQUARE:100,WIDTH:194},props:{baseCls:"bi-farbtastic",width:195,height:195,stopPropagation:!0,value:"#000000"},render:function(){var e=this;return{type:"bi.absolute",items:[{el:{type:"bi.layout",cls:"",ref:function(t){e.colorWrapper=t}},top:47,left:47,width:101,height:101},{el:{type:"bi.layout",cls:"wheel",ref:function(t){e.wheel=t}},left:0,right:0,top:0,bottom:0},{el:{type:"bi.layout",cls:"overlay",ref:function(t){e.overlay=t}},top:47,left:47,width:101,height:101},{el:{type:"bi.layout",cls:"marker",ref:function(t){e.hMarker=t},scrollable:!1,width:17,height:17}},{el:{type:"bi.layout",cls:"marker",ref:function(t){e.slMarker=t},scrollable:!1,width:17,height:17}}]}},created:function(){var e=this.options;BI.isKey(e.value)&&this.setValue(e.value)},_unpack:function(e){return 7===e.length?[parseInt("0x"+e.substring(1,3))/255,parseInt("0x"+e.substring(3,5))/255,parseInt("0x"+e.substring(5,7))/255]:4===e.length?[parseInt("0x"+e.substring(1,2))/15,parseInt("0x"+e.substring(2,3))/15,parseInt("0x"+e.substring(3,4))/15]:void 0},_pack:function(e){var t=Math.round(255*e[0]),n=Math.round(255*e[1]),i=Math.round(255*e[2]);return"#"+(t<16?"0":"")+t.toString(16)+(n<16?"0":"")+n.toString(16)+(i<16?"0":"")+i.toString(16)},_setColor:function(e){var t=this._unpack(e);this.value!==e&&t&&(this.value=e,this.rgb=t,this.hsl=this._RGBToHSL(this.rgb),this._updateDisplay())},_setHSL:function(e){return this.hsl=e,this.rgb=this._HSLToRGB(e),this.value=this._pack(this.rgb),this._updateDisplay(),this},_HSLToRGB:function(e){var t,n,i=e[0],r=e[1],a=e[2];return t=2*a-(n=a<=.5?a*(r+1):a+r-a*r),[this._hueToRGB(t,n,i+.33333),this._hueToRGB(t,n,i),this._hueToRGB(t,n,i-.33333)]},_hueToRGB:function(e,t,n){return 6*(n=n<0?n+1:n>1?n-1:n)<1?e+(t-e)*n*6:2*n<1?t:3*n<2?e+(t-e)*(.66666-n)*6:e},_RGBToHSL:function(e){var t,n,i,r,a,o,s=e[0],l=e[1],u=e[2];return t=Math.min(s,Math.min(l,u)),i=(n=Math.max(s,Math.max(l,u)))-t,a=0,(o=(t+n)/2)>0&&o<1&&(a=i/(o<.5?2*o:2-2*o)),r=0,i>0&&(n==s&&n!=l&&(r+=(l-u)/i),n==l&&n!=u&&(r+=2+(u-s)/i),n==u&&n!=s&&(r+=4+(s-l)/i),r/=6),[r,a,o]},_updateDisplay:function(){var e=6.28*this.hsl[0];this.hMarker.element.css({left:Math.round(Math.sin(e)*this.constants.RADIUS+this.constants.WIDTH/2)+"px",top:Math.round(-Math.cos(e)*this.constants.RADIUS+this.constants.WIDTH/2)+"px"}),this.slMarker.element.css({left:Math.round(this.constants.SQUARE*(.5-this.hsl[1])+this.constants.WIDTH/2)+"px",top:Math.round(this.constants.SQUARE*(.5-this.hsl[2])+this.constants.WIDTH/2)+"px"}),this.colorWrapper.element.css("backgroundColor",this._pack(this._HSLToRGB([this.hsl[0],1,.5])))},_absolutePosition:function(e){var t={x:e.offsetLeft,y:e.offsetTop};if(e.offsetParent){var n=this._absolutePosition(e.offsetParent);t.x+=n.x,t.y+=n.y}return t},_widgetCoords:function(e){var t,n,i=e.target||e.srcElement,r=this.wheel.element[0];if("undefined"!=typeof e.offsetX){for(var a={x:e.offsetX,y:e.offsetY},o=i;o;)o.mouseX=a.x,o.mouseY=a.y,a.x+=o.offsetLeft,a.y+=o.offsetTop,o=o.offsetParent;o=r;for(var s={x:0,y:0};o;){if("undefined"!=typeof o.mouseX){t=o.mouseX-s.x,n=o.mouseY-s.y;break}s.x+=o.offsetLeft,s.y+=o.offsetTop,o=o.offsetParent}for(o=i;o;)o.mouseX=undefined,o.mouseY=undefined,o=o.offsetParent}else{a=this._absolutePosition(r);t=(e.pageX||0)-a.x,n=(e.pageY||0)-a.y}return{x:t-this.constants.WIDTH/2,y:n-this.constants.WIDTH/2}},_doMouseMove:function(e){var t=this._widgetCoords(e);if(this.circleDrag){var n=Math.atan2(t.x,-t.y)/6.28;n<0&&(n+=1),this._setHSL([n,this.hsl[1],this.hsl[2]])}else{var i=Math.max(0,Math.min(1,-t.x/this.constants.SQUARE+.5)),r=Math.max(0,Math.min(1,-t.y/this.constants.SQUARE+.5));this._setHSL([this.hsl[0],i,r])}this.fireEvent(BI.Farbtastic.EVENT_CHANGE,this.getValue(),this)},doClick:function(e){var t=this._widgetCoords(e);return this.circleDrag=2*Math.max(Math.abs(t.x),Math.abs(t.y))>this.constants.SQUARE,this._doMouseMove(e),!1},setValue:function(e){this._setColor(e)},getValue:function(){return this.value}}),BI.Farbtastic.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.farbtastic",BI.Farbtastic)},function(e,t){BI.BubbleCombo=BI.inherit(BI.Widget,{_const:{TRIANGLE_LENGTH:9},_defaultConfig:function(){return BI.extend(BI.BubbleCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-bubble-combo",trigger:"click",toggle:!0,direction:"bottom,left",isDefaultInit:!1,destroyWhenHide:!1,isNeedAdjustHeight:!0,isNeedAdjustWidth:!0,stopPropagation:!1,adjustLength:0,hideChecker:BI.emptyFn,offsetStyle:"left",el:{},popup:{}})},_init:function(){BI.BubbleCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;this.combo=BI.createWidget({type:"bi.combo",element:this,trigger:t.trigger,toggle:t.toggle,container:t.container,direction:t.direction,isDefaultInit:t.isDefaultInit,destroyWhenHide:t.destroyWhenHide,hideWhenAnotherComboOpen:t.hideWhenAnotherComboOpen,isNeedAdjustHeight:t.isNeedAdjustHeight,isNeedAdjustWidth:t.isNeedAdjustWidth,adjustLength:this._getAdjustLength(),stopPropagation:t.stopPropagation,adjustXOffset:0,adjustYOffset:0,hideChecker:t.hideChecker,offsetStyle:t.offsetStyle,el:t.el,popup:BI.extend({type:"bi.bubble_popup_view"},t.popup)}),this.combo.on(BI.Combo.EVENT_TRIGGER_CHANGE,(function(){e.fireEvent(BI.BubbleCombo.EVENT_TRIGGER_CHANGE,arguments)})),this.combo.on(BI.Combo.EVENT_CHANGE,(function(){e.fireEvent(BI.BubbleCombo.EVENT_CHANGE,arguments)})),this.combo.on(BI.Combo.EVENT_EXPAND,(function(){e.fireEvent(BI.BubbleCombo.EVENT_EXPAND,arguments)})),this.combo.on(BI.Combo.EVENT_COLLAPSE,(function(){e.fireEvent(BI.BubbleCombo.EVENT_COLLAPSE,arguments)})),this.combo.on(BI.Combo.EVENT_AFTER_INIT,(function(){e.fireEvent(BI.BubbleCombo.EVENT_AFTER_INIT,arguments)})),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){e.fireEvent(BI.BubbleCombo.EVENT_BEFORE_POPUPVIEW,arguments)})),this.combo.on(BI.Combo.EVENT_AFTER_POPUPVIEW,(function(){e._showTriangle(),e.fireEvent(BI.BubbleCombo.EVENT_AFTER_POPUPVIEW,arguments)})),this.combo.on(BI.Combo.EVENT_BEFORE_HIDEVIEW,(function(){e._hideTriangle(),e.fireEvent(BI.BubbleCombo.EVENT_BEFORE_HIDEVIEW,arguments)})),this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,(function(){e.fireEvent(BI.BubbleCombo.EVENT_AFTER_HIDEVIEW,arguments)}))},_getAdjustLength:function(){return this._const.TRIANGLE_LENGTH+this.options.adjustLength},_createTriangle:function(e){var t={},n={},i=this.options.adjustLength,r=this.element.offset(),a=r.left,o=r.left+this.element.outerWidth(),s=r.top,l=r.top+this.element.outerHeight();switch(e){case"left":t={top:s,height:this.element.outerHeight(),left:a-i-this._const.TRIANGLE_LENGTH},n={width:this._const.TRIANGLE_LENGTH};break;case"right":t={top:s,height:this.element.outerHeight(),left:o+i},n={width:this._const.TRIANGLE_LENGTH};break;case"top":t={left:a,width:this.element.outerWidth(),top:s-i-this._const.TRIANGLE_LENGTH},n={height:this._const.TRIANGLE_LENGTH};break;case"bottom":t={left:a,width:this.element.outerWidth(),top:l+i},n={height:this._const.TRIANGLE_LENGTH}}this.triangle&&this.triangle.destroy(),this.triangle=BI.createWidget(n,{type:"bi.center_adapt",cls:"button-combo-triangle-wrapper",items:[{type:"bi.layout",cls:"bubble-combo-triangle-"+e}]}),t.el=this.triangle,BI.createWidget({type:"bi.absolute",element:this,items:[t]})},_createLeftTriangle:function(){this._createTriangle("left")},_createRightTriangle:function(){this._createTriangle("right")},_createTopTriangle:function(){this._createTriangle("top")},_createBottomTriangle:function(){this._createTriangle("bottom")},_showTriangle:function(){switch(this.combo.getPopupPosition().dir){case"left,top":case"left,bottom":this._createLeftTriangle();break;case"right,top":case"right,bottom":this._createRightTriangle();break;case"top,left":case"top,right":this._createTopTriangle();break;case"bottom,left":case"bottom,right":this._createBottomTriangle()}},_hideTriangle:function(){this.triangle&&this.triangle.destroy(),this.triangle=null},hideView:function(){this._hideTriangle(),this.combo&&this.combo.hideView()},showView:function(){this.combo&&this.combo.showView()},isViewVisible:function(){return this.combo.isViewVisible()}}),BI.BubbleCombo.EVENT_TRIGGER_CHANGE="EVENT_TRIGGER_CHANGE",BI.BubbleCombo.EVENT_CHANGE="EVENT_CHANGE",BI.BubbleCombo.EVENT_EXPAND="EVENT_EXPAND",BI.BubbleCombo.EVENT_COLLAPSE="EVENT_COLLAPSE",BI.BubbleCombo.EVENT_AFTER_INIT="EVENT_AFTER_INIT",BI.BubbleCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.BubbleCombo.EVENT_AFTER_POPUPVIEW="EVENT_AFTER_POPUPVIEW",BI.BubbleCombo.EVENT_BEFORE_HIDEVIEW="EVENT_BEFORE_HIDEVIEW",BI.BubbleCombo.EVENT_AFTER_HIDEVIEW="EVENT_AFTER_HIDEVIEW",BI.shortcut("bi.bubble_combo",BI.BubbleCombo)},function(e,t){BI.BubblePopupView=BI.inherit(BI.PopupView,{_defaultConfig:function(){var e=BI.BubblePopupView.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:e.baseCls+" bi-bubble-popup-view",minWidth:220,maxWidth:300,minHeight:90})},_init:function(){BI.BubblePopupView.superclass._init.apply(this,arguments)}}),BI.shortcut("bi.bubble_popup_view",BI.BubblePopupView),BI.BubblePopupBarView=BI.inherit(BI.BubblePopupView,{_defaultConfig:function(){return BI.extend(BI.BubblePopupBarView.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-bubble-bar-popup-view",buttons:[{value:!1,text:BI.i18nText("BI-Basic_Cancel"),ghost:!0},{text:BI.i18nText(BI.i18nText("BI-Basic_Sure")),value:!0}]})},_init:function(){BI.BubblePopupBarView.superclass._init.apply(this,arguments)},_createToolBar:function(){var e=this.options,t=this,n=[];return BI.each(e.buttons,(function(e,i){BI.isWidget(i)?n.push(i):n.push(BI.extend({type:"bi.button",height:24,handler:function(e){t.fireEvent(BI.BubblePopupBarView.EVENT_CLICK_TOOLBAR_BUTTON,e)}},i))})),BI.createWidget({type:"bi.center",height:44,rgap:15,items:[{type:"bi.right_vertical_adapt",lgap:10,items:n}]})},_createView:function(){var e=this.options,t=BI.createWidget({type:"bi.button_group",items:[e.el],layouts:[{type:"bi.vertical",cls:"bar-popup-container",hgap:15,tgap:10}]});return t.element.css("min-height",e.minHeight-44),t}}),BI.BubblePopupBarView.EVENT_CLICK_TOOLBAR_BUTTON="EVENT_CLICK_TOOLBAR_BUTTON",BI.shortcut("bi.bubble_bar_popup_view",BI.BubblePopupBarView),BI.TextBubblePopupBarView=BI.inherit(BI.Widget,{props:function(){return{baseCls:"bi-text-bubble-bar-popup-view",text:"",buttons:[{level:"ignore",value:!1,stopPropagation:!0,text:BI.i18nText("BI-Basic_Cancel")},{value:!0,stopPropagation:!0,text:BI.i18nText("BI-Basic_Sure")}]}},render:function(){var e=this,t=this.options,n=BI.map(t.buttons,(function(t,n){return BI.isWidget(n)?n:BI.extend({type:"bi.button",height:24,handler:function(t){e.fireEvent(BI.TextBubblePopupBarView.EVENT_CHANGE,t)}},n)}));return{type:"bi.bubble_bar_popup_view",minWidth:t.minWidth,maxWidth:t.maxWidth,minHeight:t.minHeight,ref:function(){e.popup=this},el:{type:"bi.label",text:t.text,whiteSpace:"normal",textAlign:"left",ref:function(){e.text=this}},buttons:n}},populate:function(e){this.text.setText(e||this.options.text)}}),BI.TextBubblePopupBarView.EVENT_CHANGE="EVENT_CLICK_TOOLBAR_BUTTON",BI.shortcut("bi.text_bubble_bar_popup_view",BI.TextBubblePopupBarView)},function(e,t){BI.EditorIconCheckCombo=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.EditorIconCheckCombo.superclass._defaultConfig.apply(this,arguments),{baseClass:"bi-check-editor-combo",width:100,height:24,chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,validationChecker:BI.emptyFn,quitChecker:BI.emptyFn,allowBlank:!0,watermark:"",errorText:""})},_init:function(){BI.EditorIconCheckCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;this.trigger=BI.createWidget({type:"bi.editor_trigger",items:t.items,height:t.height,validationChecker:t.validationChecker,quitChecker:t.quitChecker,allowBlank:t.allowBlank,watermark:t.watermark,errorText:t.errorText,value:t.value}),this.trigger.on(BI.EditorTrigger.EVENT_CHANGE,(function(){e.popup.setValue(this.getValue()),e.fireEvent(BI.EditorIconCheckCombo.EVENT_CHANGE,arguments)})),this.trigger.on(BI.EditorTrigger.EVENT_FOCUS,(function(){e.fireEvent(BI.EditorIconCheckCombo.EVENT_FOCUS,arguments)})),this.trigger.on(BI.EditorTrigger.EVENT_EMPTY,(function(){e.fireEvent(BI.EditorIconCheckCombo.EVENT_EMPTY,arguments)})),this.trigger.on(BI.EditorTrigger.EVENT_VALID,(function(){e.fireEvent(BI.EditorIconCheckCombo.EVENT_VALID,arguments)})),this.trigger.on(BI.EditorTrigger.EVENT_ERROR,(function(){e.fireEvent(BI.EditorIconCheckCombo.EVENT_ERROR,arguments)})),this.popup=BI.createWidget({type:"bi.text_value_check_combo_popup",chooseType:t.chooseType,items:t.items,value:t.value}),this.popup.on(BI.TextValueCheckComboPopup.EVENT_CHANGE,(function(){e.setValue(e.popup.getValue()),e.editorIconCheckCombo.hideView(),e.fireEvent(BI.EditorIconCheckCombo.EVENT_CHANGE)})),this.popup.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.editorIconCheckCombo=BI.createWidget({type:"bi.combo",container:t.container,element:this,adjustLength:2,el:this.trigger,popup:{el:this.popup,maxHeight:300}})},setValue:function(e){this.editorIconCheckCombo.setValue(e)},getValue:function(){return this.trigger.getValue()},populate:function(e){this.options.items=e,this.editorIconCheckCombo.populate(e)}}),BI.EditorIconCheckCombo.EVENT_CHANGE="EVENT_CHANGE",BI.EditorIconCheckCombo.EVENT_FOCUS="EVENT_FOCUS",BI.EditorIconCheckCombo.EVENT_EMPTY="EVENT_EMPTY",BI.EditorIconCheckCombo.EVENT_VALID="EVENT_VALID",BI.EditorIconCheckCombo.EVENT_ERROR="EVENT_ERROR",BI.shortcut("bi.editor_icon_check_combo",BI.EditorIconCheckCombo)},function(e,t){BI.IconCombo=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.IconCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-icon-combo",width:24,height:24,el:{},popup:{},minWidth:100,maxWidth:"auto",maxHeight:300,direction:"bottom",adjustLength:3,adjustXOffset:0,adjustYOffset:0,offsetStyle:"left",chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE})},_init:function(){BI.IconCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;this.trigger=BI.createWidget(t.el,{type:"bi.icon_combo_trigger",iconCls:t.iconCls,title:t.title,items:t.items,width:t.width,height:t.height,iconWidth:t.iconWidth,iconHeight:t.iconHeight,value:t.value}),this.popup=BI.createWidget(t.popup,{type:"bi.icon_combo_popup",chooseType:t.chooseType,items:t.items,value:t.value}),this.popup.on(BI.IconComboPopup.EVENT_CHANGE,(function(){e.setValue(e.popup.getValue()),e.iconCombo.hideView(),e.fireEvent(BI.IconCombo.EVENT_CHANGE)})),this.popup.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.iconCombo=BI.createWidget({type:"bi.combo",element:this,direction:t.direction,trigger:t.trigger,container:t.container,adjustLength:t.adjustLength,adjustXOffset:t.adjustXOffset,adjustYOffset:t.adjustYOffset,offsetStyle:t.offsetStyle,el:this.trigger,popup:{el:this.popup,maxWidth:t.maxWidth,maxHeight:t.maxHeight,minWidth:t.minWidth}})},showView:function(){this.iconCombo.showView()},hideView:function(){this.iconCombo.hideView()},setValue:function(e){this.trigger.setValue(e),this.popup.setValue(e)},getValue:function(){var e=this.popup.getValue();return BI.isNull(e)?[]:BI.isArray(e)?e:[e]},populate:function(e){this.options.items=e,this.iconCombo.populate(e)}}),BI.IconCombo.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.icon_combo",BI.IconCombo)},function(e,t){BI.IconComboPopup=BI.inherit(BI.Pane,{_defaultConfig:function(){return BI.extend(BI.IconComboPopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi.icon-combo-popup",chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE})},_init:function(){BI.IconComboPopup.superclass._init.apply(this,arguments);var e=this.options,t=this;this.popup=BI.createWidget({type:"bi.button_group",items:BI.createItems(e.items,{type:"bi.single_select_icon_text_item",height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT}),chooseType:e.chooseType,layouts:[{type:"bi.vertical"}],value:e.value}),this.popup.on(BI.Controller.EVENT_CHANGE,(function(e,n,i){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&t.fireEvent(BI.IconComboPopup.EVENT_CHANGE,n,i)})),BI.createWidget({type:"bi.vertical",element:this,vgap:5,items:[this.popup]})},populate:function(e){BI.IconComboPopup.superclass.populate.apply(this,arguments),e=BI.createItems(e,{type:"bi.single_select_icon_text_item",height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT}),this.popup.populate(e)},getValue:function(){return this.popup.getValue()},setValue:function(e){this.popup.setValue(e)}}),BI.IconComboPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.icon_combo_popup",BI.IconComboPopup)},function(e,t){BI.IconComboTrigger=BI.inherit(BI.Trigger,{_defaultConfig:function(){return BI.extend(BI.IconComboTrigger.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-icon-combo-trigger",el:{},items:[],iconCls:"",width:24,height:24,isShowDown:!0,value:""})},_init:function(){BI.IconComboTrigger.superclass._init.apply(this,arguments);var e=this.options,t="";BI.isKey(e.value)&&(t=this._digest(e.value,e.items)),this.button=BI.createWidget(e.el,{type:"bi.icon_change_button",cls:"icon-combo-trigger-icon",iconCls:t,disableSelected:!0,width:e.isShowDown?e.width-12:e.width,height:e.height,iconWidth:e.iconWidth,iconHeight:e.iconHeight,selected:BI.isNotEmptyString(t)}),this.down=BI.createWidget({type:"bi.icon_button",disableSelected:!0,cls:"icon-combo-down-icon trigger-triangle-font font-size-12",width:12,height:8,selected:BI.isNotEmptyString(t)}),this.down.setVisible(e.isShowDown),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.button,left:0,right:0,top:0,bottom:0},{el:this.down,right:3,bottom:0}]})},_digest:function(e,t){var n="";return e=BI.isArray(e)?e[0]:e,BI.any(t,(function(t,i){if(e===i.value)return n=i.iconCls,!0})),n},populate:function(e){var t=this.options;this.options.items=e||[],this.button.setIcon(t.iconCls),this.button.setSelected(!1),this.down.setSelected(!1)},setValue:function(e){BI.IconComboTrigger.superclass.setValue.apply(this,arguments);var t=this.options,n=this._digest(e,this.options.items);e=BI.isArray(e)?e[0]:e,BI.isNotEmptyString(n)?(this.button.setIcon(n),this.button.setSelected(!0),this.down.setSelected(!0)):(this.button.setIcon(t.iconCls),this.button.setSelected(!1),this.down.setSelected(!1))}}),BI.IconComboTrigger.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.icon_combo_trigger",BI.IconComboTrigger)},function(e,t){BI.IconTextValueCombo=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.IconTextValueCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-icon-text-value-combo bi-border bi-border-radius",height:24,iconHeight:null,iconWidth:null,value:""})},_init:function(){var e=this,t=this.options;t.height-=2,BI.isNumeric(t.width)&&(t.width-=2),BI.IconTextValueCombo.superclass._init.apply(this,arguments),this.trigger=BI.createWidget({type:"bi.select_icon_text_trigger",cls:"icon-text-value-trigger",items:t.items,height:t.height,text:t.text,iconCls:t.iconCls,value:t.value,iconHeight:t.iconHeight,iconWidth:t.iconWidth,iconWrapperWidth:t.iconWrapperWidth,title:t.title,warningTitle:t.warningTitle}),this.popup=BI.createWidget({type:"bi.icon_text_value_combo_popup",items:t.items,value:t.value,iconHeight:t.iconHeight,iconWidth:t.iconWidth,iconWrapperWidth:t.iconWrapperWidth}),this.popup.on(BI.IconTextValueComboPopup.EVENT_CHANGE,(function(){e.setValue(e.popup.getValue()),e.textIconCombo.hideView(),e.fireEvent(BI.IconTextValueCombo.EVENT_CHANGE,arguments)})),this.popup.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.textIconCombo=BI.createWidget({type:"bi.combo",element:this,container:t.container,adjustLength:2,el:this.trigger,popup:{el:this.popup,maxHeight:240,minHeight:25}}),BI.isKey(t.value)&&this.setValue(t.value)},_checkError:function(e){if(BI.isNull(e)||BI.isEmptyArray(e)||BI.isEmptyString(e))this.trigger.options.tipType="success",this.element.removeClass("combo-error");else{e=BI.isArray(e)?e:[e];var t=BI.find(this.options.items,(function(t,n){return BI.contains(e,n.value)}));BI.isNull(t)?(this.trigger.options.tipType="warning",this.element.removeClass("combo-error").addClass("combo-error")):(this.trigger.options.tipType="success",this.element.removeClass("combo-error"))}},setValue:function(e){this.trigger.setValue(e),this.popup.setValue(e),this._checkError(e)},getValue:function(){var e=this.popup.getValue();return BI.isNull(e)?[]:BI.isArray(e)?e:[e]},populate:function(e){this.options.items=e,this.textIconCombo.populate(e)}}),BI.IconTextValueCombo.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.icon_text_value_combo",BI.IconTextValueCombo)},function(e,t){BI.IconTextValueComboPopup=BI.inherit(BI.Pane,{_defaultConfig:function(){return BI.extend(BI.IconTextValueComboPopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-icon-text-icon-popup",behaviors:{redmark:function(){return!0}}})},_init:function(){BI.IconTextValueComboPopup.superclass._init.apply(this,arguments);var e=this.options,t=this;this.popup=BI.createWidget({type:"bi.button_group",items:BI.createItems(e.items,{type:"bi.single_select_icon_text_item",height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,iconHeight:e.iconHeight,iconWidth:e.iconWidth,iconWrapperWidth:e.iconWrapperWidth}),chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,layouts:[{type:"bi.vertical"}],behaviors:e.behaviors,value:e.value}),this.popup.on(BI.Controller.EVENT_CHANGE,(function(e,n,i){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&t.fireEvent(BI.IconTextValueComboPopup.EVENT_CHANGE,n,i)})),this.check(),BI.createWidget({type:"bi.vertical",element:this,vgap:5,items:[this.popup]})},populate:function(e,t){BI.IconTextValueComboPopup.superclass.populate.apply(this,arguments);var n=this.options;e=BI.createItems(e,{type:"bi.single_select_icon_text_item",height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,iconWrapperWidth:n.iconWrapperWidth,iconHeight:n.iconHeight,iconWidth:n.iconWidth}),this.popup.populate(e,t)},getValue:function(){return this.popup.getValue()},setValue:function(e){this.popup.setValue(e)}}),BI.IconTextValueComboPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.icon_text_value_combo_popup",BI.IconTextValueComboPopup)},function(e,t){BI.SearchTextValueCombo=BI.inherit(BI.Widget,{props:{baseCls:"bi-search-text-value-combo",height:24,text:"",items:[],tipType:"",warningTitle:""},render:function(){var e=this,t=this.options;return{type:"bi.absolute",items:[{el:{type:"bi.combo",cls:"bi-border bi-focus-shadow",container:t.container,adjustLength:2,toggle:!1,ref:function(){e.combo=this},el:{type:"bi.search_text_value_trigger",cls:"search-text-value-trigger",watermark:t.watermark,ref:function(){e.trigger=this},items:t.items,height:t.height-2,text:t.text,value:t.value,tipType:t.tipType,warningTitle:t.warningTitle,title:t.title,listeners:[{eventName:BI.SearchTextValueTrigger.EVENT_CHANGE,action:function(){e.setValue(this.getValue()),e.combo.hideView(),e.fireEvent(BI.SearchTextValueCombo.EVENT_CHANGE)}}]},popup:{el:{type:"bi.text_value_combo_popup",chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,value:t.value,items:t.items,ref:function(){e.popup=this,e.trigger.getSearcher().setAdapter(e.popup)},listeners:[{eventName:BI.TextValueComboPopup.EVENT_CHANGE,action:function(){e.setValue(this.getValue()),e.combo.hideView(),e.fireEvent(BI.SearchTextValueCombo.EVENT_CHANGE)}}]},value:t.value,maxHeight:252,minHeight:25},listeners:[{eventName:BI.Combo.EVENT_AFTER_HIDEVIEW,action:function(){e.trigger.stopEditing()}},{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){e.fireEvent(BI.SearchTextValueCombo.EVENT_BEFORE_POPUPVIEW)}}],hideChecker:function(t){return 0===e.triggerBtn.element.find(t.target).length}},left:0,right:0,bottom:0,top:0},{el:{type:"bi.trigger_icon_button",cls:"trigger-icon-button",ref:function(){e.triggerBtn=this},width:t.height,height:t.height,handler:function(){e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()}},right:0,bottom:0,top:0}]}},created:function(){var e=this.options;BI.isKey(e.value)&&this._checkError(e.value)},_checkError:function(e){if(BI.isNull(e)||BI.isEmptyArray(e)||BI.isEmptyString(e))this.trigger.options.tipType="success",this.element.removeClass("combo-error");else{e=BI.isArray(e)?e:[e];var t=BI.find(this.options.items,(function(t,n){return BI.contains(e,n.value)}));BI.isNull(t)?(this.element.removeClass("combo-error").addClass("combo-error"),this.trigger.attr("tipType","warning")):(this.element.removeClass("combo-error"),this.trigger.attr("tipType","success"))}},populate:function(e){this.options.items=e,this.combo.populate(e)},setValue:function(e){this.combo.setValue(e),this._checkError(e)},getValue:function(){var e=this.combo.getValue();return BI.isNull(e)?[]:BI.isArray(e)?e:[e]}}),BI.SearchTextValueCombo.EVENT_CHANGE="EVENT_CHANGE",BI.SearchTextValueCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.search_text_value_combo",BI.SearchTextValueCombo)},function(e,t){BI.SearchTextValueComboPopup=BI.inherit(BI.Pane,{props:{baseCls:"bi-search-text-value-popup"},render:function(){var e=this,t=this.options;return{type:"bi.vertical",vgap:5,items:[{type:"bi.button_group",ref:function(){e.popup=this},items:BI.createItems(t.items,{type:"bi.single_select_item",textAlign:t.textAlign,height:24}),chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,layouts:[{type:"bi.vertical"}],behaviors:{redmark:function(){return!0}},value:t.value,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(t,n,i){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),t===BI.Events.CLICK&&e.fireEvent(BI.SearchTextValueComboPopup.EVENT_CHANGE,n,i)}}]}]}},mounted:function(){this.check()},populate:function(e,t,n){var i=BI.concat(e,t);BI.SearchTextValueComboPopup.superclass.populate.apply(this,i),i=BI.createItems(i,{type:"bi.single_select_item",height:24}),this.popup.populate(i,n)},getValue:function(){return this.popup.getValue()},setValue:function(e){this.popup.setValue(e)}}),BI.SearchTextValueComboPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.search_text_value_combo_popup",BI.SearchTextValueComboPopup)},function(e,t){BI.SearchTextValueTrigger=BI.inherit(BI.Trigger,{props:function(){return{extraCls:"bi-search-text-value-trigger",height:24,watermark:BI.i18nText("BI-Basic_Search")}},render:function(){var e=this,t=this.options;return{type:"bi.htape",items:[{el:{type:"bi.searcher",ref:function(){e.searcher=this},isAutoSearch:!1,el:{type:"bi.state_editor",ref:function(){e.editor=this},watermark:t.watermark,defaultText:t.text,text:this._digest(t.value,t.items),value:t.value,height:t.height,tipText:""},popup:{type:"bi.search_text_value_combo_popup",cls:"bi-card",chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,tipText:BI.i18nText("BI-No_Select")},onSearch:function(e,n){var i=e.keyword,r=BI.Func.getSearchResult(t.items,i);n(r.match,r.find)},listeners:[{eventName:BI.Searcher.EVENT_CHANGE,action:function(){e.fireEvent(BI.SearchTextValueTrigger.EVENT_CHANGE)}}]}},{el:{type:"bi.layout",width:24},width:24}]}},_setState:function(e){this.editor.setState(e)},_digest:function(e,t){var n=this.options;e=BI.isArray(e)?e:[e];var i=[],r=BI.Tree.transformToArrayFormat(t);return BI.each(r,(function(t,n){BI.deepContains(e,n.value)&&!BI.contains(i,n.text||n.value)&&i.push(n.text||n.value)})),i.length>0?i.join(","):BI.isFunction(n.text)?n.text():n.text},stopEditing:function(){this.searcher.stopSearch()},getSearcher:function(){return this.searcher},populate:function(e){this.options.items=e},setValue:function(e){this._setState(this._digest(e,this.options.items))},getValue:function(){return this.searcher.getValue()}}),BI.SearchTextValueTrigger.EVENT_SEARCHING="EVENT_SEARCHING",BI.SearchTextValueTrigger.EVENT_STOP="EVENT_STOP",BI.SearchTextValueTrigger.EVENT_START="EVENT_START",BI.SearchTextValueTrigger.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.search_text_value_trigger",BI.SearchTextValueTrigger)},function(e,t){BI.TextValueCheckCombo=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.TextValueCheckCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-text-value-check-combo bi-border",width:100,height:24,chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,value:""})},_init:function(){var e=this,t=this.options;t.height-=2,BI.isNumeric(t.width)&&(t.width-=2),BI.TextValueCheckCombo.superclass._init.apply(this,arguments),this.trigger=BI.createWidget({type:"bi.select_text_trigger",cls:"text-value-trigger",items:t.items,height:t.height,text:t.text,value:t.value}),this.popup=BI.createWidget({type:"bi.text_value_check_combo_popup",chooseType:t.chooseType,items:t.items,value:t.value}),this.popup.on(BI.TextValueCheckComboPopup.EVENT_CHANGE,(function(){e.setValue(e.popup.getValue()),e.textIconCheckCombo.hideView(),e.fireEvent(BI.TextValueCheckCombo.EVENT_CHANGE)})),this.popup.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.textIconCheckCombo=BI.createWidget({type:"bi.combo",container:t.container,element:this,adjustLength:2,el:this.trigger,popup:{el:this.popup,maxHeight:300}}),BI.isKey(t.value)&&this.setValue(t.value)},setTitle:function(e){this.trigger.setTitle(e)},setValue:function(e){this.trigger.setValue(e),this.popup.setValue(e)},setWarningTitle:function(e){this.trigger.setWarningTitle(e)},getValue:function(){var e=this.popup.getValue();return BI.isNull(e)?[]:BI.isArray(e)?e:[e]},populate:function(e){this.options.items=e,this.textIconCheckCombo.populate(e)}}),BI.TextValueCheckCombo.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.text_value_check_combo",BI.TextValueCheckCombo)},function(e,t){BI.TextValueCheckComboPopup=BI.inherit(BI.Pane,{_defaultConfig:function(){return BI.extend(BI.TextValueCheckComboPopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-text-icon-popup",chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE})},_init:function(){BI.TextValueCheckComboPopup.superclass._init.apply(this,arguments);var e=this.options,t=this;this.popup=BI.createWidget({type:"bi.button_group",items:this._formatItems(e.items),chooseType:e.chooseType,layouts:[{type:"bi.vertical"}],value:e.value}),this.popup.on(BI.Controller.EVENT_CHANGE,(function(e,n,i){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&t.fireEvent(BI.TextValueCheckComboPopup.EVENT_CHANGE,n,i)})),BI.createWidget({type:"bi.vertical",element:this,vgap:5,items:[this.popup]})},_formatItems:function(e){return BI.map(e,(function(e,t){return BI.extend({type:"bi.single_select_item",cls:"bi-list-item",height:24},t)}))},populate:function(e){BI.TextValueCheckComboPopup.superclass.populate.apply(this,arguments),this.popup.populate(this._formatItems(e))},getValue:function(){return this.popup.getValue()},setValue:function(e){this.popup.setValue(e)}}),BI.TextValueCheckComboPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.text_value_check_combo_popup",BI.TextValueCheckComboPopup)},function(e,t){BI.TextValueCombo=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.TextValueCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-text-value-combo bi-border",height:24,chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,text:"",value:""})},_init:function(){var e=this,t=this.options;t.height-=2,BI.isNumeric(t.width)&&(t.width-=2),BI.TextValueCombo.superclass._init.apply(this,arguments),this.trigger=BI.createWidget({type:"bi.select_text_trigger",cls:"text-value-trigger",items:t.items,height:t.height,text:t.text,value:t.value,warningTitle:t.warningTitle}),this.popup=BI.createWidget({type:"bi.text_value_combo_popup",chooseType:t.chooseType,value:t.value,items:t.items}),this.popup.on(BI.TextValueComboPopup.EVENT_CHANGE,(function(){e.setValue(e.popup.getValue()),e.textIconCombo.hideView(),e.fireEvent(BI.TextValueCombo.EVENT_CHANGE,arguments)})),this.popup.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.textIconCombo=BI.createWidget({type:"bi.combo",container:t.container,element:this,adjustLength:2,el:this.trigger,popup:{el:this.popup,maxHeight:240,minHeight:25}}),BI.isKey(t.value)&&this._checkError(t.value)},_checkError:function(e){if(BI.isNull(e)||BI.isEmptyArray(e)||BI.isEmptyString(e))this.trigger.options.tipType="success",this.element.removeClass("combo-error");else{e=BI.isArray(e)?e:[e];var t=BI.find(this.options.items,(function(t,n){return BI.contains(e,n.value)}));BI.isNull(t)?(this.trigger.setTipType("warning"),this.element.removeClass("combo-error").addClass("combo-error")):(this.trigger.setTipType("success"),this.element.removeClass("combo-error"))}},setValue:function(e){this.trigger.setValue(e),this.popup.setValue(e),this._checkError(e)},getValue:function(){var e=this.popup.getValue();return BI.isNull(e)?[]:BI.isArray(e)?e:[e]},populate:function(e){this.options.items=e,this.textIconCombo.populate(e)}}),BI.TextValueCombo.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.text_value_combo",BI.TextValueCombo)},function(e,t){BI.SmallTextValueCombo=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SmallTextValueCombo.superclass._defaultConfig.apply(this,arguments),{width:100,height:20,chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,el:{},text:""})},_init:function(){BI.SmallTextValueCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;this.trigger=BI.createWidget(t.el,{type:"bi.small_select_text_trigger",items:t.items,height:t.height,text:t.text}),this.popup=BI.createWidget({type:"bi.text_value_combo_popup",chooseType:t.chooseType,items:t.items}),this.popup.on(BI.TextValueComboPopup.EVENT_CHANGE,(function(){e.setValue(e.popup.getValue()),e.SmallTextValueCombo.hideView(),e.fireEvent(BI.SmallTextValueCombo.EVENT_CHANGE)})),this.popup.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.SmallTextValueCombo=BI.createWidget({type:"bi.combo",element:this,container:t.container,adjustLength:2,el:this.trigger,popup:{el:this.popup,maxHeight:240,minHeight:25}})},setValue:function(e){this.trigger.setValue(e),this.popup.setValue(e)},getValue:function(){return this.popup.getValue()},populate:function(e){this.options.items=e,this.SmallTextValueCombo.populate(e)}}),BI.SmallTextValueCombo.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.small_text_value_combo",BI.SmallTextValueCombo)},function(e,t){BI.TextValueComboPopup=BI.inherit(BI.Pane,{_defaultConfig:function(){return BI.extend(BI.TextValueComboPopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-text-icon-popup",chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE})},_init:function(){BI.TextValueComboPopup.superclass._init.apply(this,arguments);var e=this.options,t=this;this.popup=BI.createWidget({type:"bi.button_group",items:BI.createItems(e.items,{type:"bi.single_select_item",textAlign:e.textAlign,height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT}),chooseType:e.chooseType,layouts:[{type:"bi.vertical"}],value:e.value}),this.popup.on(BI.Controller.EVENT_CHANGE,(function(e,n,i){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&t.fireEvent(BI.TextValueComboPopup.EVENT_CHANGE,n,i)})),this.check(),BI.createWidget({type:"bi.vertical",element:this,vgap:5,items:[this.popup]})},populate:function(e){BI.TextValueComboPopup.superclass.populate.apply(this,arguments),e=BI.createItems(e,{type:"bi.single_select_item",height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT}),this.popup.populate(e)},getValue:function(){return this.popup.getValue()},setValue:function(e){this.popup.setValue(e)}}),BI.TextValueComboPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.text_value_combo_popup",BI.TextValueComboPopup)},function(e,t){BI.ClearEditor=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.ClearEditor.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:"bi-clear-editor",height:24,errorText:"",watermark:"",validationChecker:BI.emptyFn,quitChecker:BI.emptyFn})},_init:function(){BI.ClearEditor.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget({type:"bi.editor",height:t.height,watermark:t.watermark,allowBlank:!0,errorText:t.errorText,validationChecker:t.validationChecker,quitChecker:t.quitChecker,value:t.value}),this.clear=BI.createWidget({type:"bi.icon_button",stopEvent:!0,cls:"search-close-h-font"}),this.clear.on(BI.IconButton.EVENT_CHANGE,(function(){e.setValue(""),e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.STOPEDIT),e.fireEvent(BI.ClearEditor.EVENT_CLEAR)})),BI.createWidget({element:this,type:"bi.htape",items:[{el:this.editor},{el:this.clear,width:24}]}),this.editor.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.editor.on(BI.Editor.EVENT_FOCUS,(function(){e.fireEvent(BI.ClearEditor.EVENT_FOCUS)})),this.editor.on(BI.Editor.EVENT_BLUR,(function(){e.fireEvent(BI.ClearEditor.EVENT_BLUR)})),this.editor.on(BI.Editor.EVENT_CLICK,(function(){e.fireEvent(BI.ClearEditor.EVENT_CLICK)})),this.editor.on(BI.Editor.EVENT_CHANGE,(function(){e._checkClear(),e.fireEvent(BI.ClearEditor.EVENT_CHANGE)})),this.editor.on(BI.Editor.EVENT_KEY_DOWN,(function(t){e.fireEvent(BI.ClearEditor.EVENT_KEY_DOWN,t)})),this.editor.on(BI.Editor.EVENT_SPACE,(function(){e.fireEvent(BI.ClearEditor.EVENT_SPACE)})),this.editor.on(BI.Editor.EVENT_BACKSPACE,(function(){e.fireEvent(BI.ClearEditor.EVENT_BACKSPACE)})),this.editor.on(BI.Editor.EVENT_VALID,(function(){e.fireEvent(BI.ClearEditor.EVENT_VALID)})),this.editor.on(BI.Editor.EVENT_ERROR,(function(){e.fireEvent(BI.ClearEditor.EVENT_ERROR)})),this.editor.on(BI.Editor.EVENT_ENTER,(function(){e.fireEvent(BI.ClearEditor.EVENT_ENTER)})),this.editor.on(BI.Editor.EVENT_RESTRICT,(function(){e.fireEvent(BI.ClearEditor.EVENT_RESTRICT)})),this.editor.on(BI.Editor.EVENT_EMPTY,(function(){e._checkClear(),e.fireEvent(BI.ClearEditor.EVENT_EMPTY)})),this.editor.on(BI.Editor.EVENT_REMOVE,(function(){e.fireEvent(BI.ClearEditor.EVENT_REMOVE)})),this.editor.on(BI.Editor.EVENT_CONFIRM,(function(){e.fireEvent(BI.ClearEditor.EVENT_CONFIRM)})),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,(function(){e.fireEvent(BI.ClearEditor.EVENT_CHANGE_CONFIRM)})),this.editor.on(BI.Editor.EVENT_START,(function(){e.fireEvent(BI.ClearEditor.EVENT_START)})),this.editor.on(BI.Editor.EVENT_PAUSE,(function(){e.fireEvent(BI.ClearEditor.EVENT_PAUSE)})),this.editor.on(BI.Editor.EVENT_STOP,(function(){e.fireEvent(BI.ClearEditor.EVENT_STOP)})),BI.isKey(t.value)?this.clear.visible():this.clear.invisible()},_checkClear:function(){this.getValue()?this.clear.visible():this.clear.invisible()},setWaterMark:function(e){this.options.watermark=e,this.editor.setWaterMark(e)},focus:function(){this.editor.focus()},blur:function(){this.editor.blur()},getValue:function(){if(this.isValid())return this.editor.getValue()},setValue:function(e){this.editor.setValue(e),BI.isKey(e)&&this.clear.visible()},isValid:function(){return this.editor.isValid()}}),BI.ClearEditor.EVENT_CHANGE="EVENT_CHANGE",BI.ClearEditor.EVENT_FOCUS="EVENT_FOCUS",BI.ClearEditor.EVENT_BLUR="EVENT_BLUR",BI.ClearEditor.EVENT_CLICK="EVENT_CLICK",BI.ClearEditor.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.ClearEditor.EVENT_SPACE="EVENT_SPACE",BI.ClearEditor.EVENT_BACKSPACE="EVENT_BACKSPACE",BI.ClearEditor.EVENT_CLEAR="EVENT_CLEAR",BI.ClearEditor.EVENT_START="EVENT_START",BI.ClearEditor.EVENT_PAUSE="EVENT_PAUSE",BI.ClearEditor.EVENT_STOP="EVENT_STOP",BI.ClearEditor.EVENT_CONFIRM="EVENT_CONFIRM",BI.ClearEditor.EVENT_CHANGE_CONFIRM="EVENT_CHANGE_CONFIRM",BI.ClearEditor.EVENT_VALID="EVENT_VALID",BI.ClearEditor.EVENT_ERROR="EVENT_ERROR",BI.ClearEditor.EVENT_ENTER="EVENT_ENTER",BI.ClearEditor.EVENT_RESTRICT="EVENT_RESTRICT",BI.ClearEditor.EVENT_REMOVE="EVENT_REMOVE",BI.ClearEditor.EVENT_EMPTY="EVENT_EMPTY",BI.shortcut("bi.clear_editor",BI.ClearEditor)},function(e,t){BI.ShelterEditor=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.ShelterEditor.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-shelter-editor",hgap:4,vgap:2,lgap:0,rgap:0,tgap:0,bgap:0,validationChecker:BI.emptyFn,quitChecker:BI.emptyFn,allowBlank:!0,watermark:"",errorText:"",height:24,textAlign:"left"})},_init:function(){BI.ShelterEditor.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget({type:"bi.editor",height:t.height,hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap,value:t.value,validationChecker:t.validationChecker,quitChecker:t.quitChecker,allowBlank:t.allowBlank,watermark:t.watermark,errorText:t.errorText}),this.text=BI.createWidget({type:"bi.text_button",cls:"shelter-editor-text",title:t.title,warningTitle:t.warningTitle,tipType:t.tipType,textAlign:t.textAlign,height:t.height,hgap:t.hgap+2}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.text,left:0,right:0,top:0,bottom:0}]}),this.text.on(BI.Controller.EVENT_CHANGE,(function(){arguments[2]=e,e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.text.on(BI.TextButton.EVENT_CHANGE,(function(){e.fireEvent(BI.ShelterEditor.EVENT_CLICK_LABEL)})),this.editor.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.editor.on(BI.Editor.EVENT_FOCUS,(function(){e.fireEvent(BI.ShelterEditor.EVENT_FOCUS,arguments)})),this.editor.on(BI.Editor.EVENT_BLUR,(function(){e.fireEvent(BI.ShelterEditor.EVENT_BLUR,arguments)})),this.editor.on(BI.Editor.EVENT_CLICK,(function(){e.fireEvent(BI.ShelterEditor.EVENT_CLICK,arguments)})),this.editor.on(BI.Editor.EVENT_CHANGE,(function(){e.fireEvent(BI.ShelterEditor.EVENT_CHANGE,arguments)})),this.editor.on(BI.Editor.EVENT_KEY_DOWN,(function(t){e.fireEvent(BI.ShelterEditor.EVENT_KEY_DOWN,arguments)})),this.editor.on(BI.Editor.EVENT_VALID,(function(){e.fireEvent(BI.ShelterEditor.EVENT_VALID,arguments)})),this.editor.on(BI.Editor.EVENT_CONFIRM,(function(){e._showHint(),e._checkText(),e.fireEvent(BI.ShelterEditor.EVENT_CONFIRM,arguments)})),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,(function(){e._showHint(),e._checkText(),e.fireEvent(BI.ShelterEditor.EVENT_CHANGE_CONFIRM,arguments)})),this.editor.on(BI.Editor.EVENT_START,(function(){e.fireEvent(BI.ShelterEditor.EVENT_START,arguments)})),this.editor.on(BI.Editor.EVENT_PAUSE,(function(){e.fireEvent(BI.ShelterEditor.EVENT_PAUSE,arguments)})),this.editor.on(BI.Editor.EVENT_STOP,(function(){e.fireEvent(BI.ShelterEditor.EVENT_STOP,arguments)})),this.editor.on(BI.Editor.EVENT_SPACE,(function(){e.fireEvent(BI.ShelterEditor.EVENT_SPACE,arguments)})),this.editor.on(BI.Editor.EVENT_ERROR,(function(){e._checkText(),e.fireEvent(BI.ShelterEditor.EVENT_ERROR,arguments)})),this.editor.on(BI.Editor.EVENT_ENTER,(function(){e.fireEvent(BI.ShelterEditor.EVENT_ENTER,arguments)})),this.editor.on(BI.Editor.EVENT_RESTRICT,(function(){e.fireEvent(BI.ShelterEditor.EVENT_RESTRICT,arguments)})),this.editor.on(BI.Editor.EVENT_EMPTY,(function(){e.fireEvent(BI.ShelterEditor.EVENT_EMPTY,arguments)})),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[this.editor]}),this._showHint(),e._checkText()},_checkText:function(){var e=this.options;""===this.editor.getValue()?(this.text.setValue(e.watermark||""),this.text.element.addClass("bi-water-mark")):(this.text.setValue(this.editor.getValue()),this.text.element.removeClass("bi-water-mark")),BI.isKey(e.keyword)&&this.text.doRedMark(e.keyword)},_showInput:function(){this.editor.visible(),this.text.invisible()},_showHint:function(){this.editor.invisible(),this.text.visible()},setWaterMark:function(e){this.options.watermark=e,this.editor.setWaterMark(e)},setTitle:function(e){this.text.setTitle(e)},setWarningTitle:function(e){this.text.setWarningTitle(e)},focus:function(){this._showInput(),this.editor.focus()},blur:function(){this.editor.blur(),this._showHint(),this._checkText()},doRedMark:function(){""===this.editor.getValue()&&BI.isKey(this.options.watermark)||this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){""===this.editor.getValue()&&BI.isKey(this.options.watermark)||this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},isValid:function(){return this.editor.isValid()},setErrorText:function(e){this.editor.setErrorText(e)},getErrorText:function(){return this.editor.getErrorText()},isEditing:function(){return this.editor.isEditing()},getLastValidValue:function(){return this.editor.getLastValidValue()},getLastChangedValue:function(){return this.editor.getLastChangedValue()},setTextStyle:function(e){this.text.setStyle(e)},setValue:function(e){this.options;this.editor.setValue(e),this._checkText()},getValue:function(){return this.editor.getValue()},getState:function(){return this.text.getValue()},setState:function(e){this._showHint(),this.text.setValue(e)}}),BI.ShelterEditor.EVENT_CHANGE="EVENT_CHANGE",BI.ShelterEditor.EVENT_FOCUS="EVENT_FOCUS",BI.ShelterEditor.EVENT_BLUR="EVENT_BLUR",BI.ShelterEditor.EVENT_CLICK="EVENT_CLICK",BI.ShelterEditor.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.ShelterEditor.EVENT_CLICK_LABEL="EVENT_CLICK_LABEL",BI.ShelterEditor.EVENT_START="EVENT_START",BI.ShelterEditor.EVENT_PAUSE="EVENT_PAUSE",BI.ShelterEditor.EVENT_STOP="EVENT_STOP",BI.ShelterEditor.EVENT_CONFIRM="EVENT_CONFIRM",BI.ShelterEditor.EVENT_CHANGE_CONFIRM="EVENT_CHANGE_CONFIRM",BI.ShelterEditor.EVENT_VALID="EVENT_VALID",BI.ShelterEditor.EVENT_ERROR="EVENT_ERROR",BI.ShelterEditor.EVENT_ENTER="EVENT_ENTER",BI.ShelterEditor.EVENT_RESTRICT="EVENT_RESTRICT",BI.ShelterEditor.EVENT_SPACE="EVENT_SPACE",BI.ShelterEditor.EVENT_EMPTY="EVENT_EMPTY",BI.shortcut("bi.shelter_editor",BI.ShelterEditor)},function(e,t){BI.SignEditor=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.SignEditor.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-sign-editor",hgap:4,vgap:2,lgap:0,rgap:0,tgap:0,bgap:0,validationChecker:BI.emptyFn,quitChecker:BI.emptyFn,allowBlank:!0,watermark:"",errorText:"",textAlign:"left",height:24})},_init:function(){BI.SignEditor.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget({type:"bi.editor",height:t.height,hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap,value:t.value,validationChecker:t.validationChecker,quitChecker:t.quitChecker,allowBlank:t.allowBlank,watermark:t.watermark,errorText:t.errorText}),this.text=BI.createWidget({type:"bi.text_button",cls:"sign-editor-text",title:t.title,warningTitle:t.warningTitle,tipType:t.tipType,textAlign:t.textAlign,height:t.height,hgap:t.hgap+2,handler:function(){e._showInput(),e.editor.focus(),e.editor.selectAll()}}),this.text.on(BI.TextButton.EVENT_CHANGE,(function(){BI.nextTick((function(){e.fireEvent(BI.SignEditor.EVENT_CLICK_LABEL)}))})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.text,left:0,right:0,top:0,bottom:0}]}),this.editor.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.editor.on(BI.Editor.EVENT_FOCUS,(function(){e.fireEvent(BI.SignEditor.EVENT_FOCUS,arguments)})),this.editor.on(BI.Editor.EVENT_BLUR,(function(){e.fireEvent(BI.SignEditor.EVENT_BLUR,arguments)})),this.editor.on(BI.Editor.EVENT_CLICK,(function(){e.fireEvent(BI.SignEditor.EVENT_CLICK,arguments)})),this.editor.on(BI.Editor.EVENT_CHANGE,(function(){e.fireEvent(BI.SignEditor.EVENT_CHANGE,arguments)})),this.editor.on(BI.Editor.EVENT_KEY_DOWN,(function(t){e.fireEvent(BI.SignEditor.EVENT_KEY_DOWN,arguments)})),this.editor.on(BI.Editor.EVENT_VALID,(function(){e.fireEvent(BI.SignEditor.EVENT_VALID,arguments)})),this.editor.on(BI.Editor.EVENT_CONFIRM,(function(){e._showHint(),e._checkText(),e.fireEvent(BI.SignEditor.EVENT_CONFIRM,arguments)})),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,(function(){e._showHint(),e._checkText(),e.fireEvent(BI.SignEditor.EVENT_CHANGE_CONFIRM,arguments)})),this.editor.on(BI.Editor.EVENT_START,(function(){e.fireEvent(BI.SignEditor.EVENT_START,arguments)})),this.editor.on(BI.Editor.EVENT_PAUSE,(function(){e.fireEvent(BI.SignEditor.EVENT_PAUSE,arguments)})),this.editor.on(BI.Editor.EVENT_STOP,(function(){e.fireEvent(BI.SignEditor.EVENT_STOP,arguments)})),this.editor.on(BI.Editor.EVENT_SPACE,(function(){e.fireEvent(BI.SignEditor.EVENT_SPACE,arguments)})),this.editor.on(BI.Editor.EVENT_ERROR,(function(){e._checkText(),e.fireEvent(BI.SignEditor.EVENT_ERROR,arguments)})),this.editor.on(BI.Editor.EVENT_ENTER,(function(){e.fireEvent(BI.SignEditor.EVENT_ENTER,arguments)})),this.editor.on(BI.Editor.EVENT_RESTRICT,(function(){e.fireEvent(BI.SignEditor.EVENT_RESTRICT,arguments)})),this.editor.on(BI.Editor.EVENT_EMPTY,(function(){e.fireEvent(BI.SignEditor.EVENT_EMPTY,arguments)})),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[this.editor]}),this._showHint(),e._checkText()},_checkText:function(){var e=this.options;BI.nextTick(BI.bind((function(){""===this.editor.getValue()?(this.text.setValue(e.watermark||""),this.text.element.addClass("bi-water-mark")):(this.text.setValue(this.editor.getValue()),this.text.element.removeClass("bi-water-mark"),BI.isKey(e.keyword)&&this.text.doRedMark(e.keyword))}),this))},_showInput:function(){this.editor.visible(),this.text.invisible()},_showHint:function(){this.editor.invisible(),this.text.visible()},setTitle:function(e){this.text.setTitle(e)},setWarningTitle:function(e){this.text.setWarningTitle(e)},setWaterMark:function(e){this.options.watermark=e,this.editor.setWaterMark(e)},focus:function(){this._showInput(),this.editor.focus()},blur:function(){this.editor.blur(),this._showHint(),this._checkText()},doRedMark:function(){""===this.editor.getValue()&&BI.isKey(this.options.watermark)||this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){""===this.editor.getValue()&&BI.isKey(this.options.watermark)||this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},isValid:function(){return this.editor.isValid()},setErrorText:function(e){this.editor.setErrorText(e)},getErrorText:function(){return this.editor.getErrorText()},isEditing:function(){return this.editor.isEditing()},getLastValidValue:function(){return this.editor.getLastValidValue()},getLastChangedValue:function(){return this.editor.getLastChangedValue()},setValue:function(e){this.editor.setValue(e),this._checkText()},getValue:function(){return this.editor.getValue()},getState:function(){return this.text.getValue()},setState:function(e){this._showHint(),this.text.setValue(e)}}),BI.SignEditor.EVENT_CHANGE="EVENT_CHANGE",BI.SignEditor.EVENT_FOCUS="EVENT_FOCUS",BI.SignEditor.EVENT_BLUR="EVENT_BLUR",BI.SignEditor.EVENT_CLICK="EVENT_CLICK",BI.SignEditor.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.SignEditor.EVENT_CLICK_LABEL="EVENT_CLICK_LABEL",BI.SignEditor.EVENT_START="EVENT_START",BI.SignEditor.EVENT_PAUSE="EVENT_PAUSE",BI.SignEditor.EVENT_STOP="EVENT_STOP",BI.SignEditor.EVENT_CONFIRM="EVENT_CONFIRM",BI.SignEditor.EVENT_CHANGE_CONFIRM="EVENT_CHANGE_CONFIRM",BI.SignEditor.EVENT_VALID="EVENT_VALID",BI.SignEditor.EVENT_ERROR="EVENT_ERROR",BI.SignEditor.EVENT_ENTER="EVENT_ENTER",BI.SignEditor.EVENT_RESTRICT="EVENT_RESTRICT",BI.SignEditor.EVENT_SPACE="EVENT_SPACE",BI.SignEditor.EVENT_EMPTY="EVENT_EMPTY",BI.shortcut("bi.sign_editor",BI.SignEditor)},function(e,t){BI.StateEditor=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.StateEditor.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-state-editor",hgap:4,vgap:2,lgap:0,rgap:0,tgap:0,bgap:0,validationChecker:BI.emptyFn,quitChecker:BI.emptyFn,allowBlank:!0,watermark:"",errorText:"",height:24,defaultText:"",text:BI.i18nText("BI-Basic_Unrestricted"),el:{}})},_init:function(){BI.StateEditor.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget(t.el,{type:"bi.editor",height:t.height,hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap,value:t.value,validationChecker:t.validationChecker,quitChecker:t.quitChecker,allowBlank:t.allowBlank,watermark:t.watermark,errorText:t.errorText}),this.text=BI.createWidget({type:"bi.text_button",cls:"bi-water-mark tip-text-style",textAlign:"left",height:t.height,text:t.text,hgap:t.hgap+2,handler:function(){e._showInput(),e.editor.focus(),e.editor.setValue("")},title:BI.isNotNull(t.tipText)?t.tipText:function(){var t="";return BI.isString(e.stateValue)&&(t=e.stateValue),BI.isArray(e.stateValue)&&1===e.stateValue.length&&(t=e.stateValue[0]),t},warningTitle:t.warningTitle,tipType:t.tipType}),this.text.on(BI.TextButton.EVENT_CHANGE,(function(){BI.nextTick((function(){e.fireEvent(BI.StateEditor.EVENT_CLICK_LABEL)}))})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.text,left:0,right:0,top:0,bottom:0}]}),this.editor.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.editor.on(BI.Editor.EVENT_FOCUS,(function(){e.fireEvent(BI.StateEditor.EVENT_FOCUS,arguments)})),this.editor.on(BI.Editor.EVENT_BLUR,(function(){e.fireEvent(BI.StateEditor.EVENT_BLUR,arguments)})),this.editor.on(BI.Editor.EVENT_CLICK,(function(){e.fireEvent(BI.StateEditor.EVENT_CLICK,arguments)})),this.editor.on(BI.Editor.EVENT_CHANGE,(function(){e.fireEvent(BI.StateEditor.EVENT_CHANGE,arguments)})),this.editor.on(BI.Editor.EVENT_KEY_DOWN,(function(t){e.fireEvent(BI.StateEditor.EVENT_KEY_DOWN,arguments)})),this.editor.on(BI.Editor.EVENT_VALID,(function(){e.fireEvent(BI.StateEditor.EVENT_VALID,arguments)})),this.editor.on(BI.Editor.EVENT_CONFIRM,(function(){e._showHint(),e.fireEvent(BI.StateEditor.EVENT_CONFIRM,arguments)})),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,(function(){e._showHint(),e.fireEvent(BI.StateEditor.EVENT_CHANGE_CONFIRM,arguments)})),this.editor.on(BI.Editor.EVENT_START,(function(){e.fireEvent(BI.StateEditor.EVENT_START,arguments)})),this.editor.on(BI.Editor.EVENT_PAUSE,(function(){e.fireEvent(BI.StateEditor.EVENT_PAUSE,arguments)})),this.editor.on(BI.Editor.EVENT_STOP,(function(){e.fireEvent(BI.StateEditor.EVENT_STOP,arguments)})),this.editor.on(BI.Editor.EVENT_SPACE,(function(){e.fireEvent(BI.StateEditor.EVENT_SPACE,arguments)})),this.editor.on(BI.Editor.EVENT_ERROR,(function(){e.fireEvent(BI.StateEditor.EVENT_ERROR,arguments)})),this.editor.on(BI.Editor.EVENT_ENTER,(function(){e.fireEvent(BI.StateEditor.EVENT_ENTER,arguments)})),this.editor.on(BI.Editor.EVENT_RESTRICT,(function(){e.fireEvent(BI.StateEditor.EVENT_RESTRICT,arguments)})),this.editor.on(BI.Editor.EVENT_EMPTY,(function(){e.fireEvent(BI.StateEditor.EVENT_EMPTY,arguments)})),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[this.editor]}),this._showHint(),BI.isNotNull(t.text)&&this.setState(t.text)},setWaterMark:function(e){this.options.watermark=e,this.editor.setWaterMark(e)},doRedMark:function(){""===this.editor.getValue()&&BI.isKey(this.options.watermark)||this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){""===this.editor.getValue()&&BI.isKey(this.options.watermark)||this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},focus:function(){!1===this.options.disabled&&(this._showInput(),this.editor.focus())},blur:function(){this.editor.blur(),this._showHint()},_showInput:function(){this.editor.visible(),this.text.invisible()},_showHint:function(){this.editor.invisible(),this.text.visible()},_setText:function(e){this.text.setText(e),this.text.setTitle(e)},isValid:function(){return this.editor.isValid()},setErrorText:function(e){this.editor.setErrorText(e)},getErrorText:function(){return this.editor.getErrorText()},isEditing:function(){return this.editor.isEditing()},getLastValidValue:function(){return this.editor.getLastValidValue()},getLastChangedValue:function(){return this.editor.getLastChangedValue()},setValue:function(e){this.editor.setValue(e)},getValue:function(){return this.editor.getValue()},getState:function(){return this.editor.getValue().match(/[^\s]+/g)},setState:function(e){var t=this.options,n=BI.isFunction(t.defaultText)?t.defaultText():t.defaultText;if(BI.StateEditor.superclass.setValue.apply(this,arguments),this.stateValue=e,!BI.isNumber(e))return BI.isString(e)?(this._setText(e),void(BI.isKey(n)&&n===e?this.text.element.addClass("bi-water-mark"):this.text.element.removeClass("bi-water-mark"))):void(BI.isArray(e)&&(BI.isEmpty(e)?(this._setText(BI.isKey(n)?n:t.text),BI.isKey(n)?this.text.element.addClass("bi-water-mark"):this.text.element.removeClass("bi-water-mark")):1===e.length?(this._setText(e[0]),this.text.element.removeClass("bi-water-mark")):(this._setText(BI.i18nText("BI-Select_Part")),this.text.element.removeClass("bi-water-mark"))));e===BI.Selection.All?(this._setText(BI.i18nText("BI-Select_All")),this.text.element.removeClass("bi-water-mark")):e===BI.Selection.Multi?(this._setText(BI.i18nText("BI-Select_Part")),this.text.element.removeClass("bi-water-mark")):(this._setText(BI.isKey(n)?n:t.text),BI.isKey(n)?this.text.element.addClass("bi-water-mark"):this.text.element.removeClass("bi-water-mark"))},setTipType:function(e){this.text.options.tipType=e},getText:function(){return this.text.getText()}}),BI.StateEditor.EVENT_CHANGE="EVENT_CHANGE",BI.StateEditor.EVENT_FOCUS="EVENT_FOCUS",BI.StateEditor.EVENT_BLUR="EVENT_BLUR",BI.StateEditor.EVENT_CLICK="EVENT_CLICK",BI.StateEditor.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.StateEditor.EVENT_CLICK_LABEL="EVENT_CLICK_LABEL",BI.StateEditor.EVENT_START="EVENT_START",BI.StateEditor.EVENT_PAUSE="EVENT_PAUSE",BI.StateEditor.EVENT_STOP="EVENT_STOP",BI.StateEditor.EVENT_CONFIRM="EVENT_CONFIRM",BI.StateEditor.EVENT_CHANGE_CONFIRM="EVENT_CHANGE_CONFIRM",BI.StateEditor.EVENT_VALID="EVENT_VALID",BI.StateEditor.EVENT_ERROR="EVENT_ERROR",BI.StateEditor.EVENT_ENTER="EVENT_ENTER",BI.StateEditor.EVENT_RESTRICT="EVENT_RESTRICT",BI.StateEditor.EVENT_SPACE="EVENT_SPACE",BI.StateEditor.EVENT_EMPTY="EVENT_EMPTY",BI.shortcut("bi.state_editor",BI.StateEditor)},function(e,t){BI.SimpleStateEditor=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.SimpleStateEditor.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-simple-state-editor",hgap:4,vgap:2,lgap:0,rgap:0,tgap:0,bgap:0,validationChecker:BI.emptyFn,quitChecker:BI.emptyFn,mouseOut:!1,allowBlank:!0,watermark:"",errorText:"",height:24,text:BI.i18nText("BI-Basic_Unrestricted")})},_init:function(){BI.SimpleStateEditor.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget({type:"bi.editor",height:t.height,hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap,value:t.value,validationChecker:t.validationChecker,quitChecker:t.quitChecker,allowBlank:t.allowBlank,watermark:t.watermark,errorText:t.errorText}),this.text=BI.createWidget({type:"bi.text_button",cls:"bi-water-mark",textAlign:"left",text:t.text,height:t.height,hgap:t.hgap+2,handler:function(){e._showInput(),e.editor.focus(),e.editor.setValue("")}}),this.text.on(BI.TextButton.EVENT_CHANGE,(function(){BI.nextTick((function(){e.fireEvent(BI.SimpleStateEditor.EVENT_CLICK_LABEL)}))})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.text,left:0,right:0,top:0,bottom:0}]}),this.editor.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.editor.on(BI.Editor.EVENT_FOCUS,(function(){e.fireEvent(BI.SimpleStateEditor.EVENT_FOCUS,arguments)})),this.editor.on(BI.Editor.EVENT_BLUR,(function(){e.fireEvent(BI.SimpleStateEditor.EVENT_BLUR,arguments)})),this.editor.on(BI.Editor.EVENT_CLICK,(function(){e.fireEvent(BI.SimpleStateEditor.EVENT_CLICK,arguments)})),this.editor.on(BI.Editor.EVENT_CHANGE,(function(){e.fireEvent(BI.SimpleStateEditor.EVENT_CHANGE,arguments)})),this.editor.on(BI.Editor.EVENT_KEY_DOWN,(function(t){e.fireEvent(BI.SimpleStateEditor.EVENT_KEY_DOWN,arguments)})),this.editor.on(BI.Editor.EVENT_VALID,(function(){e.fireEvent(BI.SimpleStateEditor.EVENT_VALID,arguments)})),this.editor.on(BI.Editor.EVENT_CONFIRM,(function(){e._showHint(),e.fireEvent(BI.SimpleStateEditor.EVENT_CONFIRM,arguments)})),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,(function(){e._showHint(),e.fireEvent(BI.SimpleStateEditor.EVENT_CHANGE_CONFIRM,arguments)})),this.editor.on(BI.Editor.EVENT_START,(function(){e.fireEvent(BI.SimpleStateEditor.EVENT_START,arguments)})),this.editor.on(BI.Editor.EVENT_PAUSE,(function(){e.fireEvent(BI.SimpleStateEditor.EVENT_PAUSE,arguments)})),this.editor.on(BI.Editor.EVENT_STOP,(function(){e.fireEvent(BI.SimpleStateEditor.EVENT_STOP,arguments)})),this.editor.on(BI.Editor.EVENT_SPACE,(function(){e.fireEvent(BI.SimpleStateEditor.EVENT_SPACE,arguments)})),this.editor.on(BI.Editor.EVENT_ERROR,(function(){e.fireEvent(BI.SimpleStateEditor.EVENT_ERROR,arguments)})),this.editor.on(BI.Editor.EVENT_ENTER,(function(){e.fireEvent(BI.SimpleStateEditor.EVENT_ENTER,arguments)})),this.editor.on(BI.Editor.EVENT_RESTRICT,(function(){e.fireEvent(BI.SimpleStateEditor.EVENT_RESTRICT,arguments)})),this.editor.on(BI.Editor.EVENT_EMPTY,(function(){e.fireEvent(BI.SimpleStateEditor.EVENT_EMPTY,arguments)})),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[this.editor]}),this._showHint(),BI.isNotNull(t.text)&&this.setState(t.text)},setWaterMark:function(e){this.options.watermark=e,this.editor.setWaterMark(e)},doRedMark:function(){""===this.editor.getValue()&&BI.isKey(this.options.watermark)||this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){""===this.editor.getValue()&&BI.isKey(this.options.watermark)||this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},focus:function(){this._showInput(),this.editor.focus()},blur:function(){this.editor.blur(),this._showHint()},_showInput:function(){this.editor.visible(),this.text.invisible()},_showHint:function(){this.editor.invisible(),this.text.visible()},_setText:function(e){this.text.setText(e),this.text.setTitle(e)},isValid:function(){return this.editor.isValid()},setErrorText:function(e){this.editor.setErrorText(e)},getErrorText:function(){return this.editor.getErrorText()},isEditing:function(){return this.editor.isEditing()},getLastValidValue:function(){return this.editor.getLastValidValue()},getLastChangedValue:function(){return this.editor.getLastChangedValue()},setValue:function(e){this.editor.setValue(e)},getValue:function(){return this.editor.getValue()},getState:function(){return this.editor.getValue().match(/[^\s]+/g)},setState:function(e){var t=this.options;BI.SimpleStateEditor.superclass.setValue.apply(this,arguments),BI.isNumber(e)?e===BI.Selection.All||e===BI.Selection.Multi?(this._setText(BI.i18nText("BI-Already_Selected")),this.text.element.removeClass("bi-water-mark")):(this._setText(t.text),this.text.element.addClass("bi-water-mark")):BI.isArray(e)&&1!==e.length?BI.isEmpty(e)?(this._setText(t.text),this.text.element.addClass("bi-water-mark")):(this._setText(BI.i18nText("BI-Already_Selected")),this.text.element.removeClass("bi-water-mark")):(this._setText(e),this.text.element.removeClass("bi-water-mark"))},getText:function(){return this.text.getText()}}),BI.SimpleStateEditor.EVENT_CHANGE="EVENT_CHANGE",BI.SimpleStateEditor.EVENT_FOCUS="EVENT_FOCUS",BI.SimpleStateEditor.EVENT_BLUR="EVENT_BLUR",BI.SimpleStateEditor.EVENT_CLICK="EVENT_CLICK",BI.SimpleStateEditor.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.SimpleStateEditor.EVENT_CLICK_LABEL="EVENT_CLICK_LABEL",BI.SimpleStateEditor.EVENT_START="EVENT_START",BI.SimpleStateEditor.EVENT_PAUSE="EVENT_PAUSE",BI.SimpleStateEditor.EVENT_STOP="EVENT_STOP",BI.SimpleStateEditor.EVENT_CONFIRM="EVENT_CONFIRM",BI.SimpleStateEditor.EVENT_CHANGE_CONFIRM="EVENT_CHANGE_CONFIRM",BI.SimpleStateEditor.EVENT_VALID="EVENT_VALID",BI.SimpleStateEditor.EVENT_ERROR="EVENT_ERROR",BI.SimpleStateEditor.EVENT_ENTER="EVENT_ENTER",BI.SimpleStateEditor.EVENT_RESTRICT="EVENT_RESTRICT",BI.SimpleStateEditor.EVENT_SPACE="EVENT_SPACE",BI.SimpleStateEditor.EVENT_EMPTY="EVENT_EMPTY",BI.shortcut("bi.simple_state_editor",BI.SimpleStateEditor)},function(e,t){BI.MultiPopupView=BI.inherit(BI.PopupView,{_defaultConfig:function(){var e=BI.MultiPopupView.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{_baseCls:(e._baseCls||"")+" bi-multi-list-view",buttons:[BI.i18nText("BI-Basic_Sure")]})},_createToolBar:function(){var e=this.options,t=this;if(0!==e.buttons.length){var n=[];return BI.each(e.buttons,(function(e,t){n.push({text:t,value:e})})),this.buttongroup=BI.createWidget({type:"bi.button_group",cls:"list-view-toolbar bi-high-light bi-split-top",height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,items:BI.createItems(n,{type:"bi.text_button",once:!1,shadow:!0,isShadowShowingOnSelected:!0}),layouts:[{type:"bi.center",hgap:0,vgap:0}]}),this.buttongroup.on(BI.ButtonGroup.EVENT_CHANGE,(function(e,n){t.fireEvent(BI.MultiPopupView.EVENT_CLICK_TOOLBAR_BUTTON,e,n)})),this.buttongroup}}}),BI.MultiPopupView.EVENT_CHANGE="EVENT_CHANGE",BI.MultiPopupView.EVENT_CLICK_TOOLBAR_BUTTON="EVENT_CLICK_TOOLBAR_BUTTON",BI.shortcut("bi.multi_popup_view",BI.MultiPopupView)},function(e,t){BI.PopupPanel=BI.inherit(BI.MultiPopupView,{_defaultConfig:function(){var e=BI.PopupPanel.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-popup-panel",title:""})},_createTool:function(){var e=this,t=this.options,n=BI.createWidget({type:"bi.icon_button",cls:"close-h-font",width:25,height:25});return n.on(BI.IconButton.EVENT_CHANGE,(function(){e.setVisible(!1),e.fireEvent(BI.PopupPanel.EVENT_CLOSE)})),BI.createWidget({type:"bi.htape",cls:"popup-panel-title bi-header-background",height:25,items:[{el:{type:"bi.label",textAlign:"left",text:t.title,height:25,lgap:10}},{el:n,width:25}]})}}),BI.PopupPanel.EVENT_CHANGE="EVENT_CHANGE",BI.PopupPanel.EVENT_CLOSE="EVENT_CLOSE",BI.PopupPanel.EVENT_CLICK_TOOLBAR_BUTTON="EVENT_CLICK_TOOLBAR_BUTTON",BI.shortcut("bi.popup_panel",BI.PopupPanel)},function(e,t){BI.ListPane=BI.inherit(BI.Pane,{_defaultConfig:function(){var e=BI.ListPane.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-list-pane",logic:{dynamic:!0},lgap:0,rgap:0,tgap:0,bgap:0,vgap:0,hgap:0,items:[],itemsCreator:BI.emptyFn,hasNext:BI.emptyFn,onLoaded:BI.emptyFn,el:{type:"bi.button_group"}})},_init:function(){BI.ListPane.superclass._init.apply(this,arguments);var e=this,t=this.options;this.button_group=BI.createWidget(t.el,{type:"bi.button_group",chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,behaviors:{},items:t.items,itemsCreator:function(n,i){1===n.times&&(e.empty(),BI.nextTick((function(){e.loading()}))),t.itemsCreator(n,(function(){i.apply(e,arguments),1===n.times&&BI.nextTick((function(){e.loaded(),e.check()}))}))},hasNext:t.hasNext,layouts:[{type:"bi.vertical"}]}),this.button_group.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),t===BI.Events.CLICK&&e.fireEvent(BI.ListPane.EVENT_CHANGE,n,i)})),this.check(),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Top),BI.extend({scrolly:!0,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap,vgap:t.vgap,hgap:t.hgap},t.logic,{items:BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Top,this.button_group)}))))},hasPrev:function(){return this.button_group.hasPrev&&this.button_group.hasPrev()},hasNext:function(){return this.button_group.hasNext&&this.button_group.hasNext()},prependItems:function(e){this.options.items=e.concat(this.options.items),this.button_group.prependItems.apply(this.button_group,arguments),this.check()},addItems:function(e){this.options.items=this.options.items.concat(e),this.button_group.addItems.apply(this.button_group,arguments),this.check()},removeItemAt:function(e){e=BI.isNull(e)?[]:e,BI.removeAt(this.options.items,e),this.button_group.removeItemAt.apply(this.button_group,arguments),this.check()},populate:function(e){var t=this;this.options;0===arguments.length&&BI.isFunction(this.button_group.attr("itemsCreator"))?this.button_group.attr("itemsCreator").apply(this,[{times:1},function(){if(0===arguments.length)throw new Error("参数不能为空");t.populate.apply(t,arguments)}]):(BI.ListPane.superclass.populate.apply(this,arguments),this.button_group.populate.apply(this.button_group,arguments))},empty:function(){this.button_group.empty()},setNotSelectedValue:function(){this.button_group.setNotSelectedValue.apply(this.button_group,arguments)},getNotSelectedValue:function(){return this.button_group.getNotSelectedValue()},setValue:function(){this.button_group.setValue.apply(this.button_group,arguments)},getValue:function(){return this.button_group.getValue.apply(this.button_group,arguments)},getAllButtons:function(){return this.button_group.getAllButtons()},getAllLeaves:function(){return this.button_group.getAllLeaves()},getSelectedButtons:function(){return this.button_group.getSelectedButtons()},getNotSelectedButtons:function(){return this.button_group.getNotSelectedButtons()},getIndexByValue:function(e){return this.button_group.getIndexByValue(e)},getNodeById:function(e){return this.button_group.getNodeById(e)},getNodeByValue:function(e){return this.button_group.getNodeByValue(e)}}),BI.ListPane.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.list_pane",BI.ListPane)},function(e,t){BI.Panel=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.Panel.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-panel bi-border",title:"",titleButtons:[],el:{},logic:{dynamic:!1}})},_init:function(){BI.Panel.superclass._init.apply(this,arguments);var e=this.options;BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("vertical",BI.extend(e.logic,{items:BI.LogicFactory.createLogicItemsByDirection("top",this._createTitle(),this.options.el)}))))},_createTitle:function(){var e=this,t=this.options;return this.text=BI.createWidget({type:"bi.label",cls:"panel-title-text",text:t.title,height:30}),this.button_group=BI.createWidget({type:"bi.button_group",items:t.titleButtons,layouts:[{type:"bi.center_adapt",lgap:10}]}),this.button_group.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.button_group.on(BI.ButtonGroup.EVENT_CHANGE,(function(t,n){e.fireEvent(BI.Panel.EVENT_CHANGE,t,n)})),{el:{type:"bi.left_right_vertical_adapt",cls:"panel-title bi-header-background bi-border-bottom",height:29,items:{left:[this.text],right:[this.button_group]},lhgap:10,rhgap:10},height:29}},setTitle:function(e){this.text.setValue(e)}}),BI.Panel.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.panel",BI.Panel)},function(e,t){BI.LinearSegmentButton=BI.inherit(BI.BasicButton,{props:{extraCls:"bi-line-segment-button bi-list-item-effect",once:!0,readonly:!0,hgap:10,height:25},render:function(){var e=this,t=this.options;return[{type:"bi.label",text:t.text,height:t.height,value:t.value,hgap:t.hgap,ref:function(){e.text=this}},{type:"bi.absolute",items:[{el:{type:"bi.layout",cls:"line-segment-button-line",height:2,ref:function(){e.line=this}},left:0,right:0,bottom:0}]}]},setSelected:function(e){BI.LinearSegmentButton.superclass.setSelected.apply(this,arguments),e?this.line.element.addClass("bi-high-light-background"):this.line.element.removeClass("bi-high-light-background")},setText:function(e){this.text.setText(e)}}),BI.shortcut("bi.linear_segment_button",BI.LinearSegmentButton)},function(e,t){BI.LinearSegment=BI.inherit(BI.Widget,{props:{baseCls:"bi-linear-segment",items:[],layouts:[{type:"bi.center"}],height:29},render:function(){var e=this,t=this.options;return{type:"bi.button_group",items:BI.createItems(t.items,{type:"bi.linear_segment_button",height:t.height-1}),layouts:t.layouts,listeners:[{eventName:"__EVENT_CHANGE__",action:function(){e.fireEvent("__EVENT_CHANGE__",arguments)}},{eventName:"EVENT_CHANGE",action:function(){e.fireEvent("EVENT_CHANGE")}}],ref:function(){e.buttonGroup=this}}},setValue:function(e){this.buttonGroup.setValue(e)},setEnabledValue:function(e){this.buttonGroup.setEnabledValue(e)},getValue:function(){return this.buttonGroup.getValue()}}),BI.shortcut("bi.linear_segment",BI.LinearSegment)},function(e,t){BI.SelectList=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SelectList.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-select-list",direction:BI.Direction.Top,logic:{dynamic:!0},items:[],itemsCreator:BI.emptyFn,hasNext:BI.emptyFn,onLoaded:BI.emptyFn,toolbar:{type:"bi.multi_select_bar",iconWrapperWidth:36},el:{type:"bi.list_pane"}})},_init:function(){BI.SelectList.superclass._init.apply(this,arguments);var e=this,t=this.options;this.toolbar=BI.createWidget(t.toolbar),this.allSelected=!1,this.toolbar.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){e.allSelected=this.isSelected(),t===BI.Events.CLICK&&(e.setAllSelected(e.allSelected),e.fireEvent(BI.SelectList.EVENT_CHANGE,n,i)),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.list=BI.createWidget(t.el,{type:"bi.list_pane",items:t.items,itemsCreator:function(n,i){1===n.times&&e.toolbar.setVisible(!1),t.itemsCreator(n,(function(t){i.apply(e,arguments),1===n.times&&(e.toolbar.setVisible(t&&t.length>0),e.toolbar.setEnable(e.isEnabled()&&t&&t.length>0)),e._checkAllSelected()}))},onLoaded:t.onLoaded,hasNext:t.hasNext}),this.list.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){t===BI.Events.CLICK&&(e._checkAllSelected(),e.fireEvent(BI.SelectList.EVENT_CHANGE,n,i)),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(t.direction),BI.extend({scrolly:!0},t.logic,{items:BI.LogicFactory.createLogicItemsByDirection(t.direction,this.toolbar,this.list)})))),t.items.length<=0&&(this.toolbar.setVisible(!1),this.toolbar.setEnable(!1)),BI.isNotNull(t.value)&&this.setValue(t.value)},_checkAllSelected:function(){var e=this.list.getValue().length,t=this.getAllLeaves().length-e,n=this.list.hasNext(),i=this.toolbar.isSelected(),r=e>0&&(t>0||!i&&n);r=r||t>0&&n&&i,this.toolbar.setHalfSelected(r),!r&&this.toolbar.setSelected(e>0&&t<=0&&(!n||i))},setAllSelected:function(e){BI.each(this.getAllButtons(),(function(t,n){(n.setSelected||n.setAllSelected).apply(n,[e])})),this.allSelected=!!e,this.toolbar.setSelected(e),this.toolbar.setHalfSelected(!1)},setToolBarVisible:function(e){this.toolbar.setVisible(e)},isAllSelected:function(){return this.allSelected},hasPrev:function(){return this.list.hasPrev()},hasNext:function(){return this.list.hasNext()},prependItems:function(e){this.list.prependItems.apply(this.list,arguments)},addItems:function(e){this.list.addItems.apply(this.list,arguments)},setValue:function(e){var t=e.type===BI.ButtonGroup.CHOOSE_TYPE_ALL;this.setAllSelected(t),this.list[t?"setNotSelectedValue":"setValue"](e.value),this._checkAllSelected()},getValue:function(){return!1===this.isAllSelected()?{type:BI.ButtonGroup.CHOOSE_TYPE_MULTI,value:this.list.getValue(),assist:this.list.getNotSelectedValue()}:{type:BI.ButtonGroup.CHOOSE_TYPE_ALL,value:this.list.getNotSelectedValue(),assist:this.list.getValue()}},empty:function(){this.list.empty()},populate:function(e){this.toolbar.setVisible(!BI.isEmptyArray(e)),this.toolbar.setEnable(this.isEnabled()&&!BI.isEmptyArray(e)),this.list.populate.apply(this.list,arguments),this._checkAllSelected()},_setEnable:function(e){BI.SelectList.superclass._setEnable.apply(this,arguments),this.toolbar.setEnable(e)},resetHeight:function(e){var t=(this.toolbar.element.outerHeight()||25)*(this.toolbar.isVisible()?1:0);this.list.resetHeight?this.list.resetHeight(e-t):this.list.element.css({"max-height":(e-t)/BI.pixRatio+BI.pixUnit})},setNotSelectedValue:function(){this.list.setNotSelectedValue.apply(this.list,arguments),this._checkAllSelected()},getNotSelectedValue:function(){return this.list.getNotSelectedValue()},getAllButtons:function(){return this.list.getAllButtons()},getAllLeaves:function(){return this.list.getAllLeaves()},getSelectedButtons:function(){return this.list.getSelectedButtons()},getNotSelectedButtons:function(){return this.list.getNotSelectedButtons()},getIndexByValue:function(e){return this.list.getIndexByValue(e)},getNodeById:function(e){return this.list.getNodeById(e)},getNodeByValue:function(e){return this.list.getNodeByValue(e)}}),BI.SelectList.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.select_list",BI.SelectList)},function(e,t){BI.LazyLoader=BI.inherit(BI.Widget,{_const:{PAGE:100},_defaultConfig:function(){return BI.extend(BI.LazyLoader.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-lazy-loader",el:{},items:[]})},_init:function(){var e=this,t=this.options;BI.LazyLoader.superclass._init.apply(this,arguments);var n=t.items.length;this.loader=BI.createWidget({type:"bi.loader",element:this,el:t.el,itemsCreator:function(t,n){n(e._getNextItems(t))},hasNext:function(e){return e.count<n}}),this.loader.on(BI.Loader.EVENT_CHANGE,(function(t){e.fireEvent(BI.LazyLoader.EVENT_CHANGE,t)}))},_getNextItems:function(e){var t=this.options,n=t.items.length-this._const.PAGE*(e.times-1),i=BI.takeRight(t.items,n);return BI.take(i,this._const.PAGE)},populate:function(e){this.loader.populate(e)},addItems:function(e){this.loader.addItems(e)},empty:function(){this.loader.empty()},setNotSelectedValue:function(){this.loader.setNotSelectedValue.apply(this.loader,arguments)},getNotSelectedValue:function(){return this.loader.getNotSelectedValue()},setValue:function(){this.loader.setValue.apply(this.loader,arguments)},getValue:function(){return this.loader.getValue.apply(this.loader,arguments)},getAllButtons:function(){return this.loader.getAllButtons()},getAllLeaves:function(){return this.loader.getAllLeaves()},getSelectedButtons:function(){return this.loader.getSelectedButtons()},getNotSelectedButtons:function(){return this.loader.getNotSelectedButtons()},getIndexByValue:function(e){return this.loader.getIndexByValue(e)},getNodeById:function(e){return this.loader.getNodeById(e)},getNodeByValue:function(e){return this.loader.getNodeByValue(e)}}),BI.LazyLoader.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.lazy_loader",BI.LazyLoader)},function(e,t){BI.ListLoader=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.ListLoader.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-list-loader",isDefaultInit:!0,el:{type:"bi.button_group"},items:[],itemsCreator:BI.emptyFn,onLoaded:BI.emptyFn,count:!1,next:{},hasNext:BI.emptyFn})},_nextLoad:function(){var e=this,t=this.options;this.next.setLoading(),t.itemsCreator.apply(this,[{times:++this.times},function(){e.next.setLoaded(),e.addItems.apply(e,arguments)}])},_init:function(){BI.ListLoader.superclass._init.apply(this,arguments);var e=this,t=this.options;!1===t.itemsCreator&&(t.next=!1),this.button_group=BI.createWidget(t.el,{type:"bi.button_group",element:this,chooseType:0,items:t.items,behaviors:{},layouts:[{type:"bi.vertical"}]}),this.button_group.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),t===BI.Events.CLICK&&e.fireEvent(BI.ListLoader.EVENT_CHANGE,i)})),!1!==t.next&&(this.next=BI.createWidget(BI.extend({type:"bi.loading_bar"},t.next)),this.next.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&e._nextLoad()}))),BI.createWidget({type:"bi.vertical",element:this,items:[this.next]}),t.isDefaultInit&&BI.isEmpty(t.items)&&BI.nextTick(BI.bind((function(){this.populate()}),this)),BI.isNotEmptyArray(t.items)&&this.populate(t.items)},hasNext:function(){var e=this.options;return BI.isNumber(e.count)?this.count<e.count:!!e.hasNext.apply(this,[{times:this.times,count:this.count}])},addItems:function(e){this.count+=e.length,BI.isObject(this.next)&&(this.options.items=this.options.items.concat(e),this.hasNext()?this.next.setLoaded():this.next.setEnd()),this.button_group.addItems.apply(this.button_group,arguments),this.next.element.appendTo(this.element)},populate:function(e){var t=this,n=this.options;0===arguments.length&&BI.isFunction(n.itemsCreator)?n.itemsCreator.apply(this,[{times:1},function(){if(0===arguments.length)throw new Error("参数不能为空");t.populate.apply(t,arguments),n.onLoaded()}]):(this.options.items=e,this.times=1,this.count=0,this.count+=e.length,BI.isObject(this.next)&&(this.hasNext()?this.next.setLoaded():this.next.invisible()),BI.DOM.hang([this.next]),this.button_group.populate.apply(this.button_group,arguments),this.next.element.appendTo(this.element))},empty:function(){BI.DOM.hang([this.next]),this.button_group.empty(),this.next.element.appendTo(this.element),BI.each([this.next],(function(e,t){t&&t.setVisible(!1)}))},setNotSelectedValue:function(){this.button_group.setNotSelectedValue.apply(this.button_group,arguments)},getNotSelectedValue:function(){return this.button_group.getNotSelectedValue()},setValue:function(){this.button_group.setValue.apply(this.button_group,arguments)},getValue:function(){return this.button_group.getValue.apply(this.button_group,arguments)},getAllButtons:function(){return this.button_group.getAllButtons()},getAllLeaves:function(){return this.button_group.getAllLeaves()},getSelectedButtons:function(){return this.button_group.getSelectedButtons()},getNotSelectedButtons:function(){return this.button_group.getNotSelectedButtons()},getIndexByValue:function(e){return this.button_group.getIndexByValue(e)},getNodeById:function(e){return this.button_group.getNodeById(e)},getNodeByValue:function(e){return this.button_group.getNodeByValue(e)}}),BI.ListLoader.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.list_loader",BI.ListLoader)},function(e,t){BI.SortList=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SortList.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-sort-list",isDefaultInit:!0,el:{type:"bi.button_group"},items:[],itemsCreator:BI.emptyFn,onLoaded:BI.emptyFn,count:!1,next:{},hasNext:BI.emptyFn})},_init:function(){BI.SortList.superclass._init.apply(this,arguments);var e=this,t=this.options;this.loader=BI.createWidget({type:"bi.list_loader",element:this,isDefaultInit:t.isDefaultInit,el:t.el,items:this._formatItems(t.items),itemsCreator:function(n,i){t.itemsCreator(n,(function(t){i(e._formatItems(t))}))},onLoaded:t.onLoaded,count:t.count,next:t.next,hasNext:t.hasNext}),this.loader.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),t===BI.Events.CLICK&&e.fireEvent(BI.SortList.EVENT_CHANGE,n,i)})),this.loader.element.sortable({containment:t.containment||this.element,connectWith:t.connectWith||".bi-sort-list",items:".sort-item",cursor:t.cursor||"drag",tolerance:t.tolerance||"intersect",placeholder:{element:function(e){var t=BI.createWidget({type:"bi.layout",cls:"bi-sortable-holder",height:e.outerHeight()});return t.element.css({"margin-left":e.css("margin-left"),"margin-right":e.css("margin-right"),"margin-top":e.css("margin-top"),"margin-bottom":e.css("margin-bottom"),margin:e.css("margin")}),t.element},update:function(){}},start:function(e,t){},stop:function(t,n){e.fireEvent(BI.SortList.EVENT_CHANGE)},over:function(e,t){}})},_formatItems:function(e){return BI.each(e,(function(e,t){(t=BI.stripEL(t)).cls=t.cls?t.cls+" sort-item":"sort-item",t.attributes={sorted:t.value}})),e},hasNext:function(){return this.loader.hasNext()},addItems:function(e){this.loader.addItems(e)},populate:function(e){e&&(arguments[0]=this._formatItems(e)),this.loader.populate.apply(this.loader,arguments)},empty:function(){this.loader.empty()},setNotSelectedValue:function(){this.loader.setNotSelectedValue.apply(this.loader,arguments)},getNotSelectedValue:function(){return this.loader.getNotSelectedValue()},setValue:function(){this.loader.setValue.apply(this.loader,arguments)},getValue:function(){return this.loader.getValue()},getAllButtons:function(){return this.loader.getAllButtons()},getAllLeaves:function(){return this.loader.getAllLeaves()},getSelectedButtons:function(){return this.loader.getSelectedButtons()},getNotSelectedButtons:function(){return this.loader.getNotSelectedButtons()},getIndexByValue:function(e){return this.loader.getIndexByValue(e)},getNodeById:function(e){return this.loader.getNodeById(e)},getNodeByValue:function(e){return this.loader.getNodeByValue(e)},getSortedValues:function(){return this.loader.element.sortable("toArray",{attribute:"sorted"})}}),BI.SortList.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.sort_list",BI.SortList)},function(e,t){BI.LoadingPane=BI.inherit(BI.Pane,{_mount:function(){var e=BI.Pane.superclass._mount.apply(this,arguments);e&&this.beforeInit&&(this.__asking=!0,this.loading(),this.beforeInit(BI.bind(this.__loaded,this)))},_initRender:function(){this.beforeInit?this.__async=!0:this._render()},__loaded:function(){this.__asking=!1,this.loaded(),this._render()}})},function(e,t){BI.AllCountPager=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.AllCountPager.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-all-count-pager",pagerDirection:"vertical",height:24,pages:1,curr:1,count:1,rowInfoObject:null,showRowCount:!0,showRowInfo:!0})},_init:function(){BI.AllCountPager.superclass._init.apply(this,arguments);var e=this,t=this.options,n=this._getPagerIconCls();this.editor=BI.createWidget({type:"bi.small_text_editor",cls:"pager-editor bi-border-radius",validationChecker:function(e){return 0===t.pages&&"0"===e||BI.isPositiveInteger(e)},hgap:4,vgap:0,value:t.curr,errorText:BI.i18nText("BI-Please_Input_Positive_Integer"),width:40,height:24,invisible:t.pages<=1}),this.pager=BI.createWidget({type:"bi.pager",width:58,layouts:[{type:"bi.horizontal",lgap:5}],dynamicShow:!1,pages:t.pages,curr:t.curr,groups:0,first:!1,last:!1,prev:{type:"bi.icon_button",value:"prev",title:BI.i18nText("BI-Previous_Page"),warningTitle:BI.i18nText("BI-Current_Is_First_Page"),height:22,width:22,cls:"bi-border bi-border-radius all-pager-prev bi-list-item-select2 "+n.preCls},next:{type:"bi.icon_button",value:"next",title:BI.i18nText("BI-Next_Page"),warningTitle:BI.i18nText("BI-Current_Is_Last_Page"),height:22,width:22,cls:"bi-border bi-border-radius all-pager-next bi-list-item-select2 "+n.nextCls},hasPrev:t.hasPrev,hasNext:t.hasNext,firstPage:t.firstPage,lastPage:t.lastPage,invisible:t.pages<=1}),this.editor.on(BI.TextEditor.EVENT_CONFIRM,(function(){e.pager.setValue(BI.parseInt(e.editor.getValue())),e.fireEvent(BI.AllCountPager.EVENT_CHANGE)})),this.pager.on(BI.Pager.EVENT_CHANGE,(function(){e.fireEvent(BI.AllCountPager.EVENT_CHANGE)})),this.pager.on(BI.Pager.EVENT_AFTER_POPULATE,(function(){e.editor.setValue(e.pager.getCurrentPage())})),this.allPages=BI.createWidget({type:"bi.label",title:t.pages,text:"/"+t.pages,lgap:5,invisible:t.pages<=1}),BI.createWidget(t.showRowCount?{type:"bi.vertical_adapt",columnSize:["fill",""],element:this,scrollx:!1,items:[this._getRowCountObject(),this.editor,this.allPages,this.pager]}:{type:"bi.vertical_adapt",element:this,items:[this.editor,this.allPages,this.pager]})},_getPagerIconCls:function(){switch(this.options.pagerDirection){case"horizontal":return{preCls:"row-pre-page-h-font ",nextCls:"row-next-page-h-font "};case"vertical":default:return{preCls:"column-pre-page-h-font ",nextCls:"column-next-page-h-font "}}},_getRowCountObject:function(){var e=this,t=this.options;return{type:"bi.left",height:t.height,scrollable:!1,ref:function(t){e.rowCountObject=t},items:[{type:"bi.label",height:t.height,text:BI.i18nText("BI-Basic_Total"),ref:function(t){e.prevText=t}},{el:{type:"bi.label",ref:function(t){e.rowCount=t},cls:"row-count",height:t.height,text:t.count,title:t.count},hgap:5},{type:"bi.label",height:t.height,text:BI.i18nText("BI-Tiao_Data"),textAlign:"left"},BI.isNotEmptyObject(t.rowInfoObject)?t.rowInfoObject:null]}},setAllPages:function(e){this.allPages.setText("/"+e),this.allPages.setTitle(e),this.options.pages=e,this.pager.setAllPages(e),this.editor.setEnable(e>=1),this.setPagerVisible(e>1)},setShowRowInfo:function(e){this.options.showRowInfo=e,this.rowCountObject.setVisible(e)},setValue:function(e){this.pager.setValue(e)},setVPage:function(e){this.pager.setValue(e)},setCount:function(e){this.options.showRowCount&&(this.rowCount.setText(e),this.rowCount.setTitle(e))},setCountPrevText:function(e){this.options.showRowCount&&this.prevText.setText(e)},getCurrentPage:function(){return this.pager.getCurrentPage()},hasPrev:function(){return this.pager.hasPrev()},hasNext:function(){return this.pager.hasNext()},isShowPager:function(){return this.options.showRowInfo||this.options.pages>1},setPagerVisible:function(e){this.editor.setVisible(e),this.allPages.setVisible(e),this.pager.setVisible(e)},populate:function(){this.pager.populate(),this.setPagerVisible(this.options.pages>1)}}),BI.AllCountPager.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.all_count_pager",BI.AllCountPager)},function(e,t){BI.DirectionPager=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.DirectionPager.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-direction-pager",height:24,horizontal:{pages:!1,curr:1,hasPrev:BI.emptyFn,hasNext:BI.emptyFn,firstPage:1,lastPage:BI.emptyFn},vertical:{pages:!1,curr:1,hasPrev:BI.emptyFn,hasNext:BI.emptyFn,firstPage:1,lastPage:BI.emptyFn}})},_init:function(){BI.DirectionPager.superclass._init.apply(this,arguments);var e=this.options;e.vertical,e.horizontal;this._createVPager(),this._createHPager(),this.layout=BI.createWidget({type:"bi.absolute",scrollable:!1,element:this,items:[{el:this.vpager,top:0,right:86},{el:this.vlabel,top:0,right:110},{el:this.hpager,top:0,right:0},{el:this.hlabel,top:0,right:24}]})},_createVPager:function(){var e=this,t=this.options.vertical;this.vlabel=BI.createWidget({type:"bi.label",width:24,height:24,value:t.curr,title:t.curr,invisible:!0}),this.vpager=BI.createWidget({type:"bi.pager",width:72,layouts:[{type:"bi.horizontal",scrollx:!1,rgap:24}],invisible:!0,dynamicShow:!1,pages:t.pages,curr:t.curr,groups:0,first:!1,last:!1,prev:{type:"bi.icon_button",value:"prev",title:BI.i18nText("BI-Up_Page"),warningTitle:BI.i18nText("BI-Current_Is_First_Page"),height:22,width:22,cls:"bi-border bi-border-radius direction-pager-prev column-pre-page-h-font bi-list-item-select2"},next:{type:"bi.icon_button",value:"next",title:BI.i18nText("BI-Down_Page"),warningTitle:BI.i18nText("BI-Current_Is_Last_Page"),height:22,width:22,cls:"bi-border bi-border-radius direction-pager-next column-next-page-h-font bi-list-item-select2"},hasPrev:t.hasPrev,hasNext:t.hasNext,firstPage:t.firstPage,lastPage:t.lastPage}),this.vpager.on(BI.Pager.EVENT_CHANGE,(function(){e.fireEvent(BI.DirectionPager.EVENT_CHANGE)})),this.vpager.on(BI.Pager.EVENT_AFTER_POPULATE,(function(){e.vlabel.setValue(this.getCurrentPage()),e.vlabel.setTitle(this.getCurrentPage())}))},_createHPager:function(){var e=this,t=this.options.horizontal;this.hlabel=BI.createWidget({type:"bi.label",width:24,height:24,value:t.curr,title:t.curr,invisible:!0}),this.hpager=BI.createWidget({type:"bi.pager",width:72,layouts:[{type:"bi.horizontal",scrollx:!1,rgap:24}],invisible:!0,dynamicShow:!1,pages:t.pages,curr:t.curr,groups:0,first:!1,last:!1,prev:{type:"bi.icon_button",value:"prev",title:BI.i18nText("BI-Left_Page"),warningTitle:BI.i18nText("BI-Current_Is_First_Page"),height:22,width:22,cls:"bi-border bi-border-radius direction-pager-prev row-pre-page-h-font bi-list-item-select2"},next:{type:"bi.icon_button",value:"next",title:BI.i18nText("BI-Right_Page"),warningTitle:BI.i18nText("BI-Current_Is_Last_Page"),height:22,width:22,cls:"bi-border bi-border-radius direction-pager-next row-next-page-h-font bi-list-item-select2"},hasPrev:t.hasPrev,hasNext:t.hasNext,firstPage:t.firstPage,lastPage:t.lastPage}),this.hpager.on(BI.Pager.EVENT_CHANGE,(function(){e.fireEvent(BI.DirectionPager.EVENT_CHANGE)})),this.hpager.on(BI.Pager.EVENT_AFTER_POPULATE,(function(){e.hlabel.setValue(this.getCurrentPage()),e.hlabel.setTitle(this.getCurrentPage())}))},getVPage:function(){return this.vpager.getCurrentPage()},getHPage:function(){return this.hpager.getCurrentPage()},setVPage:function(e){this.vpager.setValue(e),this.vlabel.setValue(e),this.vlabel.setTitle(e)},setHPage:function(e){this.hpager.setValue(e),this.hlabel.setValue(e),this.hlabel.setTitle(e)},hasVNext:function(){return this.vpager.hasNext()},hasHNext:function(){return this.hpager.hasNext()},hasVPrev:function(){return this.vpager.hasPrev()},hasHPrev:function(){return this.hpager.hasPrev()},setHPagerVisible:function(e){this.hpager.setVisible(e),this.hlabel.setVisible(e)},setVPagerVisible:function(e){this.vpager.setVisible(e),this.vlabel.setVisible(e)},populate:function(){this.vpager.populate(),this.hpager.populate();var e=!1,t=!1;this.hasHNext()||this.hasHPrev()?(this.setHPagerVisible(!0),t=!0):this.setHPagerVisible(!1),this.hasVNext()||this.hasVPrev()?(this.setVPagerVisible(!0),e=!0):this.setVPagerVisible(!1),this.setVisible(t||e);var n=[86,110,0,24],i=this.layout.attr("items");!0===e&&!0===t?(i[0].right=n[0],i[1].right=n[1],i[2].right=n[2],i[3].right=n[3]):!0===e?(i[0].right=n[2],i[1].right=n[3]):!0===t&&(i[2].right=n[2],i[3].right=n[3]),this.layout.attr("items",i),this.layout.resize()},clear:function(){this.vpager.attr("curr",1),this.hpager.attr("curr",1)}}),BI.DirectionPager.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.direction_pager",BI.DirectionPager)},function(e,t){BI.DetailPager=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.DetailPager.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-detail-pager",behaviors:{},layouts:[{type:"bi.horizontal",hgap:10,vgap:0}],dynamicShow:!0,dynamicShowFirstLast:!1,dynamicShowPrevNext:!1,pages:!1,curr:function(){return 1},groups:0,jump:BI.emptyFn,first:!1,last:!1,prev:"上一页",next:"下一页",firstPage:1,lastPage:function(){return 1},hasPrev:BI.emptyFn,hasNext:BI.emptyFn})},_init:function(){BI.DetailPager.superclass._init.apply(this,arguments);var e=this;this.currPage=BI.result(this.options,"curr"),this._lock=!1,this._debouce=BI.debounce((function(){e._lock=!1}),300),this._populate()},_populate:function(){var e=this,t=this.options,n=[],i={};this.empty();var r,a=BI.result(t,"pages"),o=BI.result(this,"currPage"),s=BI.result(t,"groups"),l=BI.result(t,"first"),u=BI.result(t,"last"),c=BI.result(t,"prev"),h=BI.result(t,"next");!1===a?(s=0,l=!1,u=!1):s>a&&(s=a),i.index=Math.ceil((o+(s>1&&s!==a?1:0))/(0===s?1:s)),(!t.dynamicShow&&!t.dynamicShowPrevNext||o>1)&&!1!==c&&(BI.isKey(c)?n.push({text:c,value:"prev",disabled:!1===a?!1===t.hasPrev(o):!(o>1&&!1!==c)}):n.push(BI.extend({disabled:!1===a?!1===t.hasPrev(o):!(o>1&&!1!==c)},c))),(!t.dynamicShow&&!t.dynamicShowFirstLast||i.index>1&&0!==s)&&l&&(n.push({text:l,value:"first",disabled:!(i.index>1&&0!==s)}),i.index>1&&0!==s&&n.push({type:"bi.label",cls:"page-ellipsis",text:"…"})),i.poor=Math.floor((s-1)/2),i.start=i.index>1?o-i.poor:1,i.end=i.index>1?(r=o+(s-i.poor-1))>a?a:r:s,i.end-i.start<s-1&&(i.start=i.end-s+1);var p=i.start,d=i.end;for(l&&u&&i.index>1&&0!==s&&a>s&&i.end<a&&0!==s&&(p++,d--);p<=d;p++)p===o?n.push({text:p,value:p,selected:!0}):n.push({text:p,value:p});(!t.dynamicShow&&!t.dynamicShowFirstLast||a>s&&i.end<a&&0!==s)&&u&&(a>s&&i.end<a&&0!==s&&n.push({type:"bi.label",cls:"page-ellipsis",text:"…"}),n.push({text:u,value:"last",disabled:!(a>s&&i.end<a&&0!==s)})),i.flow=!c&&0===s,(!t.dynamicShow&&!t.dynamicShowPrevNext&&h||o!==a&&h||i.flow)&&n.push(BI.isKey(h)?!1===a?{text:h,value:"next",disabled:!1===t.hasNext(o)}:i.flow&&o===a?{text:h,value:"next",disabled:!0}:{text:h,value:"next",disabled:!(o!==a&&h||i.flow)}:BI.extend({disabled:!1===a?!1===t.hasNext(o):!(o!==a&&h||i.flow)},h)),this.button_group=BI.createWidget({type:"bi.button_group",element:this,items:BI.createItems(n,{cls:"page-item bi-border bi-list-item-active",height:23,hgap:10}),behaviors:t.behaviors,layouts:t.layouts}),this.button_group.on(BI.Controller.EVENT_CHANGE,(function(n,i,r){if(!0!==e._lock){if(e._lock=!0,e._debouce(),n===BI.Events.CLICK){var o=e.button_group.getValue()[0];switch(o){case"first":e.currPage=1;break;case"last":e.currPage=a;break;case"prev":e.currPage--;break;case"next":e.currPage++;break;default:e.currPage=o}t.jump.apply(e,[{pages:a,curr:e.currPage}]),e._populate(),e.fireEvent(BI.DetailPager.EVENT_CHANGE,r)}e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}})),this.fireEvent(BI.DetailPager.EVENT_AFTER_POPULATE)},getCurrentPage:function(){return this.currPage},setAllPages:function(e){this.options.pages=e},hasPrev:function(e){e||(e=1);var t=this.options;return!1===this.options.pages?t.hasPrev(e):e>1},hasNext:function(e){e||(e=1);var t=this.options,n=this.options.pages;return!1===n?t.hasNext(e):e<n},setValue:function(e){var t=this.options;if(e=(e=e||0)<1?1:e,!1===t.pages){var n=BI.result(t,"lastPage"),i=1;this.currPage=e>n?n:e<(i=BI.result(t,"firstPage"))?i:e}else e=e>t.pages?t.pages:e,this.currPage=e;this._populate()},getValue:function(){var e=this.button_group.getValue()[0];switch(e){case"prev":return-1;case"next":return 1;case"first":return BI.MIN;case"last":return BI.MAX;default:return e}},attr:function(e,t){BI.DetailPager.superclass.attr.apply(this,arguments),"curr"===e&&(this.currPage=BI.result(this.options,"curr"))},populate:function(){this._populate()}}),BI.DetailPager.EVENT_CHANGE="EVENT_CHANGE",BI.DetailPager.EVENT_AFTER_POPULATE="EVENT_AFTER_POPULATE",BI.shortcut("bi.detail_pager",BI.DetailPager)},function(e,t){BI.SegmentButton=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.SegmentButton.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-segment-button bi-list-item-select",shadow:!0,readonly:!0,hgap:5})},_init:function(){BI.SegmentButton.superclass._init.apply(this,arguments);var e=this.options;this.text=BI.createWidget({type:"bi.label",element:this,textHeight:e.height,whiteSpace:e.whiteSpace,text:e.text,value:e.value,hgap:e.hgap})},setSelected:function(){BI.SegmentButton.superclass.setSelected.apply(this,arguments)},setText:function(e){BI.SegmentButton.superclass.setText.apply(this,arguments),this.text.setText(e)}}),BI.shortcut("bi.segment_button",BI.SegmentButton)},function(e,t){BI.Segment=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.Segment.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-segment",items:[],height:24})},_init:function(){BI.Segment.superclass._init.apply(this,arguments);var e=this,t=this.options;this.buttonGroup=BI.createWidget({element:this,type:"bi.button_group",value:t.value,items:BI.createItems(t.items,{type:"bi.segment_button",height:t.height-2,whiteSpace:t.whiteSpace}),layout:[{type:"bi.center"}]}),this.buttonGroup.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.buttonGroup.on(BI.ButtonGroup.EVENT_CHANGE,(function(t,n){e.fireEvent(BI.Segment.EVENT_CHANGE,t,n)}))},_setEnable:function(e){BI.Segment.superclass._setEnable.apply(this,arguments),!0===e?this.element.removeClass("base-disabled disabled"):!1===e&&this.element.addClass("base-disabled disabled")},setValue:function(e){this.buttonGroup.setValue(e)},setEnabledValue:function(e){this.buttonGroup.setEnabledValue(e)},getValue:function(){return this.buttonGroup.getValue()}}),BI.Segment.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.segment",BI.Segment)},function(e,t){BI.MultiSelectBar=BI.inherit(BI.BasicButton,{_defaultConfig:function(){return BI.extend(BI.MultiSelectBar.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-multi-select-bar",height:25,text:BI.i18nText("BI-Select_All"),isAllCheckedBySelectedValue:BI.emptyFn,disableSelected:!0,isHalfCheckedBySelectedValue:function(e){return e.length>0},halfSelected:!1,iconWrapperWidth:26,iconWidth:16,iconHeight:16})},_init:function(){BI.MultiSelectBar.superclass._init.apply(this,arguments);var e=this,t=this.options,n=!0===t.selected,i=!t.selected&&t.halfSelected;this.checkbox=BI.createWidget({type:"bi.checkbox",stopPropagation:!0,handler:function(){e.setSelected(e.isSelected())},selected:n,invisible:i,iconWidth:t.iconWidth,iconHeight:t.iconHeight}),this.half=BI.createWidget({type:"bi.half_icon_button",stopPropagation:!0,handler:function(){e.setSelected(!0)},invisible:n||!i,iconWidth:t.iconWidth,iconHeight:t.iconHeight}),this.checkbox.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.CLICK,e.isSelected(),e)})),this.checkbox.on(BI.Checkbox.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectBar.EVENT_CHANGE,e.isSelected(),e)})),this.half.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.CLICK,e.isSelected(),e)})),this.half.on(BI.HalfIconButton.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectBar.EVENT_CHANGE,e.isSelected(),e)})),this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:t.height,height:t.height,hgap:t.hgap,text:t.text,keyword:t.keyword,value:t.value,py:t.py}),BI.createWidget({type:"bi.htape",element:this,items:[{width:t.iconWrapperWidth,el:{type:"bi.center_adapt",items:[this.checkbox,this.half]}},{el:this.text}]})},_setSelected:function(e){this.checkbox.setSelected(!!e)},beforeClick:function(){var e=this.isHalfSelected(),t=this.isSelected();!0===e?this.setSelected(!0):this.setSelected(!t)},setSelected:function(e){this.checkbox.setSelected(e),this.setHalfSelected(!1)},setHalfSelected:function(e){this.halfSelected=!!e,!0===e?(this.checkbox.setSelected(!1),this.half.visible(),this.checkbox.invisible()):(this.half.invisible(),this.checkbox.visible())},isHalfSelected:function(){return!this.isSelected()&&!!this.halfSelected},isSelected:function(){return this.checkbox.isSelected()},setValue:function(e){BI.MultiSelectBar.superclass.setValue.apply(this,arguments);var t=this.options.isAllCheckedBySelectedValue.apply(this,arguments);this._setSelected(t),!t&&this.setHalfSelected(this.options.isHalfCheckedBySelectedValue.apply(this,arguments))},doClick:function(){BI.MultiSelectBar.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.MultiSelectBar.EVENT_CHANGE,this.isSelected(),this)}}),BI.MultiSelectBar.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_select_bar",BI.MultiSelectBar)},function(e,t){BI.LevelTree=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.LevelTree.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-level-tree",el:{chooseType:0},expander:{},items:[],value:""})},_init:function(){BI.LevelTree.superclass._init.apply(this,arguments),this.initTree(this.options.items)},_formatItems:function(e,t,n){var i=this;return BI.each(e,(function(r,a){var o={layer:t};BI.isKey(a.id)||(a.id=BI.UUID()),o.pNode=n,!0===a.isParent||!0===a.parent||BI.isNotEmptyArray(a.children)?(o.type="bi.mid_plus_group_node",r===e.length-1&&(o.type="bi.last_plus_group_node",o.isLastNode=!0),0!==r||n||(o.type="bi.first_plus_group_node"),0===r&&r===e.length-1&&(o.type="bi.plus_group_node"),BI.defaults(a,o),i._formatItems(a.children,t+1,a)):(o.type="bi.mid_tree_leaf_item",0!==r||n||(o.type="bi.first_tree_leaf_item"),r===e.length-1&&(o.type="bi.last_tree_leaf_item"),BI.defaults(a,o))})),e},_assertId:function(e){BI.each(e,(function(e,t){BI.isKey(t.id)||(t.id=BI.UUID())}))},initTree:function(e){var t=this,n=this.options;this.empty(),this._assertId(e),this.tree=BI.createWidget({type:"bi.custom_tree",element:this,expander:BI.extend({el:{},popup:{type:"bi.custom_tree"}},n.expander),items:this._formatItems(BI.Tree.transformToTreeFormat(e),0),value:n.value,el:BI.extend({type:"bi.button_tree",chooseType:0,layouts:[{type:"bi.vertical"}]},n.el)}),this.tree.on(BI.Controller.EVENT_CHANGE,(function(e,n,i){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&t.fireEvent(BI.LevelTree.EVENT_CHANGE,n,i)}))},stroke:function(e){this.tree.stroke.apply(this.tree,arguments)},populate:function(e,t){e=this._formatItems(BI.Tree.transformToTreeFormat(e),0),this.tree.populate(e,t)},setValue:function(e){this.tree.setValue(e)},getValue:function(){return this.tree.getValue()},getAllLeaves:function(){return this.tree.getAllLeaves()},getNodeById:function(e){return this.tree.getNodeById(e)},getNodeByValue:function(e){return this.tree.getNodeByValue(e)}}),BI.LevelTree.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.level_tree",BI.LevelTree)},function(e,t){var n;n=BI.inherit(BI.Widget,{props:{baseCls:"bi-tree-expander",layer:0,isLastNode:!1,isFirstNode:!1,selectable:!1},render:function(){var e=this,t=this.options;return this.trigger=BI.createWidget(t.el,{forceNotSelected:!t.selectable}),this.trigger.on(BI.Controller.EVENT_CHANGE,(function(n){t.selectable&&e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),{type:"bi.expander",ref:function(t){e.expander=t},trigger:t.selectable?"":"click",el:this.trigger,isDefaultInit:t.isDefaultInit,popup:{type:"bi.tree_expander.popup",layer:t.layer||t.el.layer,isLastNode:t.isLastNode||t.el.isLastNode,isFirstNode:t.isFirstNode||t.el.isFirstNode,el:t.popup},value:t.value,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(t){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}}]}},setValue:function(e){BI.contains(e,this.trigger.getValue())?(this.trigger.setSelected(!0),this.expander.setValue([])):(this.trigger.setSelected(!1),this.expander.setValue(e))},getValue:function(){return this.trigger.isSelected()?[this.trigger.getValue()]:this.expander.getValue()},populate:function(e){this.expander.populate(e)},getAllLeaves:function(){return this.expander&&this.expander.getAllLeaves()}}),BI.shortcut("bi.tree_expander",n)},function(e,t){var n;n=BI.inherit(BI.Widget,{props:{baseCls:"bi-tree-expander-popup",layer:0,el:{},isLastNode:!1},render:function(){var e=this,t=this.options;return this.popupView=BI.createWidget(BI.extend(t.el,{value:t.value}),this),this.popupView.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.popupView.element.css("margin-left",-12*t.layer),this.element.css("margin-left",12*t.layer),{type:"bi.vertical",cls:t.isLastNode?"":"line",scrolly:null,items:[this.popupView]}},setValue:function(e){this.popupView.setValue(e)},getValue:function(){return this.popupview.getValue()},populate:function(e){this.popupview.populate(e)},getAllLeaves:function(){return this.popupView&&this.popupView.getAllLeaves()}}),BI.shortcut("bi.tree_expander.popup",n)},function(e,t){BI.EditorTrigger=BI.inherit(BI.Trigger,{_const:{hgap:4},_defaultConfig:function(){var e=BI.EditorTrigger.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-editor-trigger bi-border bi-border-radius",height:24,validationChecker:BI.emptyFn,quitChecker:BI.emptyFn,allowBlank:!1,watermark:"",errorText:""})},_init:function(){this.options.height-=2,BI.EditorTrigger.superclass._init.apply(this,arguments);var e=this,t=this.options;this._const;this.editor=BI.createWidget({type:"bi.sign_editor",height:t.height,value:t.value,validationChecker:t.validationChecker,quitChecker:t.quitChecker,allowBlank:t.allowBlank,watermark:t.watermark,errorText:t.errorText,title:function(){return e.getValue()}}),this.editor.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.editor.on(BI.SignEditor.EVENT_CHANGE,(function(){e.fireEvent(BI.EditorTrigger.EVENT_CHANGE,arguments)})),this.editor.on(BI.SignEditor.EVENT_FOCUS,(function(){e.fireEvent(BI.EditorTrigger.EVENT_FOCUS,arguments)})),this.editor.on(BI.SignEditor.EVENT_EMPTY,(function(){e.fireEvent(BI.EditorTrigger.EVENT_EMPTY,arguments)})),this.editor.on(BI.SignEditor.EVENT_VALID,(function(){e.fireEvent(BI.EditorTrigger.EVENT_VALID,arguments)})),this.editor.on(BI.SignEditor.EVENT_ERROR,(function(){e.fireEvent(BI.EditorTrigger.EVENT_ERROR,arguments)})),BI.createWidget({element:this,type:"bi.htape",items:[{el:this.editor},{el:{type:"bi.trigger_icon_button",width:t.triggerWidth||t.height},width:t.triggerWidth||t.height}]})},getValue:function(){return this.editor.getValue()},setValue:function(e){this.editor.setValue(e)},setText:function(e){this.editor.setState(e)}}),BI.EditorTrigger.EVENT_CHANGE="EVENT_CHANGE",BI.EditorTrigger.EVENT_FOCUS="EVENT_FOCUS",BI.EditorTrigger.EVENT_EMPTY="EVENT_EMPTY",BI.EditorTrigger.EVENT_VALID="EVENT_VALID",BI.EditorTrigger.EVENT_ERROR="EVENT_ERROR",BI.shortcut("bi.editor_trigger",BI.EditorTrigger)},function(e,t){BI.IconTrigger=BI.inherit(BI.Trigger,{_defaultConfig:function(){return BI.extend(BI.IconTrigger.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-icon-trigger",extraCls:"pull-down-font",el:{},height:24})},_init:function(){var e=this.options;BI.IconTrigger.superclass._init.apply(this,arguments),this.iconButton=BI.createWidget(e.el,{type:"bi.trigger_icon_button",element:this,width:e.width,height:e.height,extraCls:e.extraCls})}}),BI.shortcut("bi.icon_trigger",BI.IconTrigger)},function(e,t){BI.IconTextTrigger=BI.inherit(BI.Trigger,{_const:{hgap:4},_defaultConfig:function(){var e=BI.IconTextTrigger.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-text-trigger",height:24,iconHeight:null,iconWidth:null,textCls:""})},_init:function(){BI.IconTextTrigger.superclass._init.apply(this,arguments);var e=this,t=this.options;this._const;this.text=BI.createWidget({type:"bi.label",cls:"select-text-label"+(BI.isKey(t.textCls)?" "+t.textCls:""),textAlign:"left",height:t.height,text:t.text}),this.trigerButton=BI.createWidget({type:"bi.trigger_icon_button",width:t.triggerWidth||t.height}),BI.createWidget({element:this,type:"bi.htape",ref:function(t){e.wrapper=t},items:[{el:{type:"bi.icon_change_button",cls:"icon-combo-trigger-icon",iconCls:t.iconCls,ref:function(t){e.icon=t},iconHeight:t.iconHeight,iconWidth:t.iconWidth,disableSelected:!0},width:BI.isEmptyString(t.iconCls)?0:t.iconWrapperWidth||t.height},{el:this.text,lgap:BI.isEmptyString(t.iconCls)?5:0},{el:this.trigerButton,width:t.triggerWidth||t.height}]})},setValue:function(e){this.text.setValue(e)},setIcon:function(e){var t=this.options;this.icon.setIcon(e);var n=this.wrapper.attr("items")[0],i=this.wrapper.attr("items")[1];BI.isNull(e)||BI.isEmptyString(e)?0!==n.width&&(n.width=0,i.lgap=5,this.wrapper.resize()):n.width!==(t.iconWrapperWidth||t.height)&&(n.width=t.iconWrapperWidth||t.height,i.lgap=0,this.wrapper.resize())},setTextCls:function(e){var t=this.options,n=t.textCls;t.textCls=e,this.text.element.removeClass(n).addClass(e)},setText:function(e){this.text.setText(e)}}),BI.shortcut("bi.icon_text_trigger",BI.IconTextTrigger)},function(e,t){BI.SelectIconTextTrigger=BI.inherit(BI.Trigger,{_defaultConfig:function(){return BI.extend(BI.SelectIconTextTrigger.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-select-text-trigger",height:24,iconHeight:null,iconWidth:null,iconCls:""})},_init:function(){BI.SelectIconTextTrigger.superclass._init.apply(this,arguments);var e=this.options,t=this._digist(e.value,e.items);this.trigger=BI.createWidget({type:"bi.icon_text_trigger",element:this,text:t.text,textCls:t.textCls,iconCls:t.iconCls,height:e.height,iconHeight:e.iconHeight,iconWidth:e.iconWidth,iconWrapperWidth:e.iconWrapperWidth})},_digist:function(e,t){var n,i=this.options;e=BI.isArray(e)?e:[e];var r=BI.Tree.transformToArrayFormat(t);return BI.any(r,(function(t,i){if(BI.deepContains(e,i.value))return n={text:i.text||i.value,iconCls:i.iconCls},!0})),BI.isNotNull(n)?{text:n.text,textCls:"",iconCls:n.iconCls}:{text:BI.isFunction(i.text)?i.text():i.text,textCls:"bi-water-mark",iconCls:i.iconCls}},setValue:function(e){var t=this._digist(e,this.options.items);this.trigger.setText(t.text),this.trigger.setIcon(t.iconCls),this.trigger.setTextCls(t.textCls)},populate:function(e){this.options.items=e}}),BI.shortcut("bi.select_icon_text_trigger",BI.SelectIconTextTrigger)},function(e,t){BI.TextTrigger=BI.inherit(BI.Trigger,{_const:{hgap:6},_defaultConfig:function(){var e=BI.TextTrigger.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-text-trigger",height:24,textCls:""})},_init:function(){BI.TextTrigger.superclass._init.apply(this,arguments);var e=this,t=this.options,n=this._const;this.text=BI.createWidget({type:"bi.label",cls:"select-text-label"+(BI.isKey(t.textCls)?" "+t.textCls:""),textAlign:"left",height:t.height,text:t.text,title:function(){return e.text.getText()},tipType:t.tipType,warningTitle:t.warningTitle,hgap:n.hgap,readonly:t.readonly}),this.trigerButton=BI.createWidget({type:"bi.trigger_icon_button",width:t.triggerWidth||t.height}),BI.createWidget({element:this,type:"bi.htape",items:[{el:this.text},{el:this.trigerButton,width:t.triggerWidth||t.height}]})},getTextor:function(){return this.text},setTextCls:function(e){var t=this.options,n=t.textCls;t.textCls=e,this.text.element.removeClass(n).addClass(e)},setText:function(e){this.text.setText(e)},setTipType:function(e){this.text.options.tipType=e}}),BI.shortcut("bi.text_trigger",BI.TextTrigger)},function(e,t){BI.SelectTextTrigger=BI.inherit(BI.Trigger,{_defaultConfig:function(){return BI.extend(BI.SelectTextTrigger.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-select-text-trigger",height:24})},_init:function(){BI.SelectTextTrigger.superclass._init.apply(this,arguments);var e=this.options,t=this._digest(e.value,e.items);this.trigger=BI.createWidget({type:"bi.text_trigger",element:this,height:e.height,readonly:e.readonly,text:t.text,textCls:t.textCls,tipType:e.tipType,warningTitle:e.warningTitle})},_digest:function(e,t){var n=this.options;e=BI.isArray(e)?e:[e];var i=[],r=BI.Tree.transformToArrayFormat(t);return BI.each(r,(function(t,n){BI.deepContains(e,n.value)&&!BI.contains(i,n.text||n.value)&&i.push(n.text||n.value)})),i.length>0?{textCls:"",text:i.join(",")}:{textCls:"bi-water-mark",text:BI.isFunction(n.text)?n.text():n.text}},setValue:function(e){var t=this._digest(e,this.options.items);this.trigger.setTextCls(t.textCls),this.trigger.setText(t.text)},setTipType:function(e){this.trigger.setTipType(e)},getTextor:function(){return this.trigger.getTextor()},populate:function(e){this.options.items=e}}),BI.shortcut("bi.select_text_trigger",BI.SelectTextTrigger)},function(e,t){BI.SmallSelectTextTrigger=BI.inherit(BI.Trigger,{_defaultConfig:function(){return BI.extend(BI.SmallSelectTextTrigger.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-small-select-text-trigger bi-border",height:20})},_init:function(){this.options.height-=2,BI.SmallSelectTextTrigger.superclass._init.apply(this,arguments);var e=this.options,t=this._digest(e.value,e.items);this.trigger=BI.createWidget({type:"bi.small_text_trigger",element:this,height:e.height,text:t.text,cls:t.cls})},_digest:function(e,t){var n=this.options;e=BI.isArray(e)?e:[e];var i=[],r=BI.Tree.transformToArrayFormat(t);return BI.each(r,(function(t,n){BI.deepContains(e,n.value)&&!BI.contains(i,n.text||n.value)&&i.push(n.text||n.value)})),i.length>0?{cls:"",text:i.join(",")}:{cls:"bi-water-mark",text:n.text}},setValue:function(e){var t=this._digest(e,this.options.items);this.trigger.element.removeClass("bi-water-mark").addClass(t.cls),this.trigger.setText(t.text)},populate:function(e){this.options.items=e}}),BI.shortcut("bi.small_select_text_trigger",BI.SmallSelectTextTrigger)},function(e,t){BI.SmallTextTrigger=BI.inherit(BI.Trigger,{_const:{hgap:6},_defaultConfig:function(){var e=BI.SmallTextTrigger.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-text-trigger",height:20})},_init:function(){BI.SmallTextTrigger.superclass._init.apply(this,arguments);var e=this.options,t=this._const;this.text=BI.createWidget({type:"bi.label",textAlign:"left",height:e.height,text:e.text,hgap:t.hgap}),this.trigerButton=BI.createWidget({type:"bi.trigger_icon_button",width:e.triggerWidth||e.height}),BI.createWidget({element:this,type:"bi.htape",items:[{el:this.text},{el:this.trigerButton,width:e.triggerWidth||e.height}]})},setValue:function(e){this.text.setValue(e)},setText:function(e){this.text.setText(e)}}),BI.shortcut("bi.small_text_trigger",BI.SmallTextTrigger)},function(e,t){BI.MonthDateCombo=BI.inherit(BI.Trigger,{_defaultConfig:function(){return BI.extend(BI.MonthDateCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-month-combo",height:24,container:null})},_init:function(){BI.MonthDateCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;this.trigger=BI.createWidget({type:"bi.date_triangle_trigger"}),this.popup=BI.createWidget({type:"bi.month_popup",allowMonths:t.allowMonths,behaviors:t.behaviors}),this.popup.on(BI.YearPopup.EVENT_CHANGE,(function(){e.setValue(e.popup.getValue())})),this.combo=BI.createWidget({type:"bi.combo",offsetStyle:"center",container:t.container,element:this,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,el:this.trigger,popup:{minWidth:85,stopPropagation:!1,el:this.popup}}),this.combo.on(BI.Combo.EVENT_CHANGE,(function(){e.combo.hideView(),e.fireEvent(BI.MonthDateCombo.EVENT_CHANGE)})),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){e.doBehavior()}))},populate:function(){this.combo.populate.apply(this.combo,arguments)},setValue:function(e){this.trigger.setValue(e),this.popup.setValue(e)},getValue:function(){return this.popup.getValue()}}),BI.MonthDateCombo.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.month_date_combo",BI.MonthDateCombo)},function(e,t){BI.YearDateCombo=BI.inherit(BI.Trigger,{_defaultConfig:function(){return BI.extend(BI.YearDateCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-year-combo",min:"1900-01-01",max:"2099-12-31",behaviors:{},height:24,container:null})},_init:function(){BI.YearDateCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;this.trigger=BI.createWidget({type:"bi.date_triangle_trigger"}),this.popup=BI.createWidget({type:"bi.year_popup",behaviors:t.behaviors,min:t.min,max:t.max}),this.popup.on(BI.YearPopup.EVENT_CHANGE,(function(){e.setValue(e.popup.getValue()),e.combo.hideView(),e.fireEvent(BI.YearDateCombo.EVENT_CHANGE)})),this.combo=BI.createWidget({type:"bi.combo",offsetStyle:"center",element:this,container:t.container,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,el:this.trigger,popup:{minWidth:100,stopPropagation:!1,el:this.popup}}),this.combo.on(BI.Combo.EVENT_CHANGE,(function(){e.fireEvent(BI.YearDateCombo.EVENT_CHANGE)})),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){e.doBehavior(),e.fireEvent(BI.YearDateCombo.EVENT_BEFORE_POPUPVIEW)}))},setMinDate:function(e){this.popup.setMinDate(e)},setMaxDate:function(e){this.popup.setMaxDate(e)},setValue:function(e){this.trigger.setValue(e),this.popup.setValue(e)},getValue:function(){return this.popup.getValue()}}),BI.YearDateCombo.EVENT_CHANGE="EVENT_CHANGE",BI.YearDateCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.year_date_combo",BI.YearDateCombo)},function(e,t){BI.DatePicker=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.DatePicker.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:"bi-date-picker",height:40,min:"1900-01-01",max:"2099-12-31"})},_init:function(){BI.DatePicker.superclass._init.apply(this,arguments);var e=this,t=this.options;this._year=BI.getDate().getFullYear(),this._month=BI.getDate().getMonth()+1,this.left=BI.createWidget({type:"bi.icon_button",cls:"pre-page-h-font",width:24,height:24}),this.left.on(BI.IconButton.EVENT_CHANGE,(function(){1===e._month?e.setValue({year:e.year.getValue()-1||BI.getDate().getFullYear()-1,month:12}):e.setValue({year:e.year.getValue()||BI.getDate().getFullYear(),month:e.month.getValue()-1||BI.getDate().getMonth()}),e.fireEvent(BI.DatePicker.EVENT_CHANGE)})),this.right=BI.createWidget({type:"bi.icon_button",cls:"next-page-h-font",width:24,height:24}),this.right.on(BI.IconButton.EVENT_CHANGE,(function(){12===e._month?e.setValue({year:e.year.getValue()+1||BI.getDate().getFullYear()+1,month:1}):e.setValue({year:e.year.getValue()||BI.getDate().getFullYear(),month:e.month.getValue()+1||BI.getDate().getMonth()+2}),e.fireEvent(BI.DatePicker.EVENT_CHANGE)})),this.year=BI.createWidget({type:"bi.year_date_combo",behaviors:t.behaviors,min:t.min,max:t.max}),this.year.on(BI.YearDateCombo.EVENT_CHANGE,(function(){e.setValue({year:e.year.getValue(),month:e._refreshMonth()}),e.fireEvent(BI.DatePicker.EVENT_CHANGE)})),this.year.on(BI.YearDateCombo.EVENT_BEFORE_POPUPVIEW,(function(){e.fireEvent(BI.DatePicker.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)})),this.month=BI.createWidget({type:"bi.month_date_combo",behaviors:t.behaviors,allowMonths:this._getAllowMonths()}),this.month.on(BI.MonthDateCombo.EVENT_CHANGE,(function(){e.setValue({year:e.year.getValue()||e._year,month:e.month.getValue()}),e.fireEvent(BI.DatePicker.EVENT_CHANGE)})),this.month.on(BI.YearDateCombo.EVENT_BEFORE_POPUPVIEW,(function(){e.fireEvent(BI.DatePicker.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)})),BI.createWidget({type:"bi.htape",element:this,items:[{el:{type:"bi.center_adapt",items:[this.left]},width:24},{type:"bi.center_adapt",items:[{el:{type:"bi.horizontal",width:120,rgap:10,items:[{el:this.year,lgap:10},this.month]}}]},{el:{type:"bi.center_adapt",items:[this.right]},width:24}]}),this.setValue({year:this._year,month:this._month})},_refreshMonth:function(e){var t=this.month.getValue();this.month.populate(this._getAllowMonths());var n=this._getAllowMonths();return BI.contains(n,t)||(t=e||n[0]),this.month.setValue(t),t},_getAllowMonths:function(){var e=this._getCheckMinMaxDate(),t=this.year.getValue()||this._year;return BI.filter(BI.range(1,13),(function(n,i){return!BI.checkDateVoid(t,i,1,e.min,e.max)[0]}))},_checkLeftValid:function(){var e=this._getCheckMinMaxDate(),t=1===this._month?this._year-1:this._year,n=1===this._month?12:this._month-1,i=BI.isNull(BI.checkDateVoid(t,n,1,e.min,e.max)[0]);return this.left.setEnable(i),i},_checkRightValid:function(){var e=this._getCheckMinMaxDate(),t=12===this._month?this._year+1:this._year,n=12===this._month?1:this._month+1,i=BI.isNull(BI.checkDateVoid(t,n,1,e.min,e.max)[0]);return this.right.setEnable(i),i},_getCheckMinMaxDate:function(){var e=this.options,t=BI.parseDateTime(e.min,"%Y-%X-%d"),n=BI.parseDateTime(e.max,"%Y-%X-%d");return t.setDate(1),n.setDate(1),{min:BI.print(t,"%Y-%X-%d"),max:BI.print(n,"%Y-%X-%d")}},setMinDate:function(e){this.options.min=e,this.year.setMinDate(e),this._refreshMonth(this._month)},setMaxDate:function(e){this.options.max=e,this.year.setMaxDate(e),this._refreshMonth(this._month)},setValue:function(e){this._year=BI.parseInt(e.year),this._month=BI.parseInt(e.month),this.year.setValue(e.year),this._refreshMonth(this._month),this.month.setValue(e.month)},getValue:function(){return{year:this.year.getValue(),month:this.month.getValue()}}}),BI.DatePicker.EVENT_CHANGE="EVENT_CHANGE",BI.DatePicker.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW="EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",BI.shortcut("bi.date_picker",BI.DatePicker)},function(e,t){BI.YearPicker=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.YearPicker.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:"bi-year-picker",behaviors:{},height:40,min:"1900-01-01",max:"2099-12-31"})},_init:function(){BI.YearPicker.superclass._init.apply(this,arguments);var e=this,t=this.options;this._year=BI.getDate().getFullYear(),this.left=BI.createWidget({type:"bi.icon_button",cls:"pre-page-h-font",width:25,height:25}),this.left.on(BI.IconButton.EVENT_CHANGE,(function(){e.setValue(e.year.getValue()-1),e.fireEvent(BI.YearPicker.EVENT_CHANGE)})),this.right=BI.createWidget({type:"bi.icon_button",cls:"next-page-h-font",width:25,height:25}),this.right.on(BI.IconButton.EVENT_CHANGE,(function(){e.setValue(e.year.getValue()+1),e.fireEvent(BI.YearPicker.EVENT_CHANGE)})),this.year=BI.createWidget({type:"bi.year_date_combo",min:t.min,behaviors:t.behaviors,max:t.max,width:50}),this.year.on(BI.YearDateCombo.EVENT_CHANGE,(function(){e.setValue(e.year.getValue()),e.fireEvent(BI.YearPicker.EVENT_CHANGE)})),this.year.on(BI.YearDateCombo.EVENT_BEFORE_POPUPVIEW,(function(){e.fireEvent(BI.YearPicker.EVENT_BEFORE_POPUPVIEW)})),BI.createWidget({type:"bi.htape",element:this,items:[{el:{type:"bi.center_adapt",items:[this.left]},width:25},{type:"bi.center_adapt",items:[{el:this.year}]},{el:{type:"bi.center_adapt",items:[this.right]},width:25}]}),this.setValue(this._year)},_checkLeftValid:function(){var e=this.options,t=this._year>BI.parseDateTime(e.min,"%Y-%X-%d").getFullYear();return this.left.setEnable(t),t},_checkRightValid:function(){var e=this.options,t=this._year<BI.parseDateTime(e.max,"%Y-%X-%d").getFullYear();return this.right.setEnable(t),t},setMinDate:function(e){this.options.min=e,this.year.setMinDate(e)},setMaxDate:function(e){this.options.max=e,this.year.setMaxDate(e)},setValue:function(e){this._year=e,this.year.setValue(e)},getValue:function(){return this.year.getValue()}}),BI.YearPicker.EVENT_CHANGE="EVENT_CHANGE",BI.YearPicker.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.year_picker",BI.YearPicker)},function(e,t){BI.DateCalendarPopup=BI.inherit(BI.Widget,{props:{baseCls:"bi-date-calendar-popup",min:"1900-01-01",max:"2099-12-31",selectedTime:null},_createNav:function(e){var t=BI.Calendar.getDateJSONByPage(e);return BI.createWidget({type:"bi.calendar",logic:{dynamic:!0},min:this.options.min,max:this.options.max,year:t.year,month:t.month,day:1})},render:function(){var e=this,t=this.options;return this.today=BI.getDate(),this._year=this.today.getFullYear(),this._month=this.today.getMonth()+1,this._day=this.today.getDate(),this.selectedTime=t.selectedTime||{year:this._year,month:this._month,day:this._day},this.datePicker=BI.createWidget({type:"bi.date_picker",behaviors:t.behaviors,min:t.min,max:t.max}),this.calendar=BI.createWidget({direction:"top",logic:{dynamic:!0},type:"bi.navigation",tab:this.datePicker,cardCreator:BI.bind(this._createNav,this),afterCardCreated:function(){},afterCardShow:function(){this.setValue(e.selectedTime)}}),this.datePicker.on(BI.DatePicker.EVENT_CHANGE,(function(){e.selectedTime=e.datePicker.getValue(),e.selectedTime.day=1,e.calendar.setSelect(BI.Calendar.getPageByDateJSON(e.selectedTime))})),this.datePicker.on(BI.DatePicker.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,(function(){e.fireEvent(BI.DateCalendarPopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)})),this.calendar.on(BI.Navigation.EVENT_CHANGE,(function(){e.selectedTime=e.calendar.getValue(),e.setValue(e.selectedTime),e.fireEvent(BI.DateCalendarPopup.EVENT_CHANGE)})),[{type:"bi.vertical",items:[{el:this.calendar,hgap:5,bgap:12}]},{type:"bi.absolute",items:[{el:{type:"bi.layout",cls:"bi-split-top"},height:1,top:40,left:0,right:0}]}]},_checkMin:function(){var e=this.options;BI.each(this.calendar.getAllCard(),(function(t,n){n.setMinDate(e.min)}))},_checkMax:function(){var e=this.options;BI.each(this.calendar.getAllCard(),(function(t,n){n.setMaxDate(e.max)}))},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e,this.datePicker.setMinDate(e),this._checkMin())},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e,this.datePicker.setMaxDate(e),this._checkMax())},setValue:function(e){this.datePicker.setValue(e),this.calendar.setSelect(BI.Calendar.getPageByDateJSON(e)),this.calendar.setValue(e),this.selectedTime=e},getValue:function(){return this.selectedTime}}),BI.DateCalendarPopup.EVENT_CHANGE="EVENT_CHANGE",BI.DateCalendarPopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW="EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",BI.shortcut("bi.date_calendar_popup",BI.DateCalendarPopup)},function(e,t){BI.MonthPopup=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MonthPopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-month-popup",behaviors:{}})},_init:function(){BI.MonthPopup.superclass._init.apply(this,arguments);var e=this,t=this.options;this.selectedMonth=BI.getDate().getMonth()+1,this.month=BI.createWidget({type:"bi.button_group",element:this,behaviors:t.behaviors,items:BI.createItems(this._getItems(t.allowMonths),{}),layouts:[BI.LogicFactory.createLogic("table",BI.extend({dynamic:!0},{columns:2,rows:6,columnSize:[.5,.5],rowSize:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT+1})),{type:"bi.center_adapt",vgap:1,hgap:2}],value:t.value}),this.month.on(BI.Controller.EVENT_CHANGE,(function(t,n){e.selectedMonth=n,e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),t===BI.Events.CLICK&&e.fireEvent(BI.MonthPopup.EVENT_CHANGE)}))},_getItems:function(e){var t=[1,7,2,8,3,9,4,10,5,11,6,12],n=[];return n.push(t.slice(0,2)),n.push(t.slice(2,4)),n.push(t.slice(4,6)),n.push(t.slice(6,8)),n.push(t.slice(8,10)),n.push(t.slice(10,12)),n=BI.map(n,(function(t,n){return BI.map(n,(function(t,n){return{type:"bi.text_item",cls:"bi-list-item-select",textAlign:"center",whiteSpace:"nowrap",once:!1,forceSelected:!0,height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT-1,width:38,value:n,text:n,disabled:!BI.contains(e,n)}}))}))},populate:function(e){this.month.populate(this._getItems(e))},getValue:function(){return this.selectedMonth},setValue:function(e){e=BI.parseInt(e),this.selectedMonth=e,this.month.setValue([e])}}),BI.MonthPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.month_popup",BI.MonthPopup)},function(e,t){BI.YearPopup=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.YearPopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-year-popup",behaviors:{},min:"1900-01-01",max:"2099-12-31"})},_createYearCalendar:function(e){var t=this.options,n=this._year,i=BI.createWidget({type:"bi.year_calendar",behaviors:t.behaviors,min:t.min,max:t.max,logic:{dynamic:!0},year:n+12*e});return i.setValue(this._year),i},_init:function(){BI.YearPopup.superclass._init.apply(this,arguments);var e=this,t=this.options;this.selectedYear=this._year=BI.getDate().getFullYear(),this.backBtn=BI.createWidget({type:"bi.icon_button",cls:"pre-page-h-font",width:24,height:24,value:-1}),this.preBtn=BI.createWidget({type:"bi.icon_button",cls:"next-page-h-font",width:24,height:24,value:1}),this.navigation=BI.createWidget({type:"bi.navigation",element:this,single:!0,logic:{dynamic:!0},tab:{cls:"year-popup-navigation bi-high-light bi-split-top",height:24,items:[this.backBtn,this.preBtn]},cardCreator:BI.bind(this._createYearCalendar,this),afterCardCreated:function(){this.setValue(e.selectedYear)}}),this.navigation.on(BI.Navigation.EVENT_CHANGE,(function(){e.selectedYear=this.getValue(),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e.fireEvent(BI.YearPopup.EVENT_CHANGE,e.selectedYear)})),BI.isKey(t.value)&&this.setValue(t.value)},_checkMin:function(){var e=this.navigation.getSelectedCard();BI.isNotNull(e)&&e.setMinDate(this.options.min)},_checkMax:function(){var e=this.navigation.getSelectedCard();BI.isNotNull(e)&&e.setMaxDate(this.options.max)},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e,this._checkMin())},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e,this._checkMax())},getValue:function(){return this.selectedYear},setValue:function(e){this.options;e=BI.parseInt(e),this.selectedYear=e,this.navigation.setSelect(BI.YearCalendar.getPageByYear(e)),this.navigation.setValue(e)}}),BI.YearPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.year_popup",BI.YearPopup)},function(e,t){BI.DateTriangleTrigger=BI.inherit(BI.Trigger,{_const:{height:24,iconWidth:12,iconHeight:12},_defaultConfig:function(){return BI.extend(BI.DateTriangleTrigger.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-date-triangle-trigger pull-down-ha-font cursor-pointer",height:24})},_init:function(){BI.DateTriangleTrigger.superclass._init.apply(this,arguments);var e=this.options,t=this._const;this.text=BI.createWidget({type:"bi.label",cls:"list-item-text",textAlign:"right",text:e.text,value:e.value,height:t.height}),BI.createWidget({type:"bi.vertical_adapt",element:this,items:[{el:this.text,rgap:5},{type:"bi.icon_label",width:16}]})},setValue:function(e){this.text.setValue(e)},getValue:function(){return this.text.getValue()},setText:function(e){this.text.setText(e)},getText:function(){return this.item.getText()},getKey:function(){}}),BI.shortcut("bi.date_triangle_trigger",BI.DateTriangleTrigger)},function(e,t){BI.StaticDatePaneCard=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.StaticDatePaneCard.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:"bi-date-pane",min:"1900-01-01",max:"2099-12-31",selectedTime:null})},_init:function(){BI.StaticDatePaneCard.superclass._init.apply(this,arguments);var e=this,t=this.options;this.today=BI.getDate(),this._year=this.today.getFullYear(),this._month=this.today.getMonth()+1,this.selectedTime=t.selectedTime||{year:this._year,month:this._month},this.datePicker=BI.createWidget({type:"bi.date_picker",behaviors:t.behaviors,min:t.min,max:t.max}),this.datePicker.on(BI.DatePicker.EVENT_CHANGE,(function(){var t=e.datePicker.getValue(),n=BI.getMonthDays(BI.getDate(t.year,t.month-1,1)),i=e.selectedTime.day||0;i>n&&(i=n),e.selectedTime={year:t.year,month:t.month},0!==i&&(e.selectedTime.day=i),e.calendar.setSelect(BI.Calendar.getPageByDateJSON(e.selectedTime)),e.calendar.setValue(e.selectedTime),0!==i&&e.fireEvent(BI.DateCalendarPopup.EVENT_CHANGE)})),this.datePicker.on(BI.DatePicker.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,(function(){e.fireEvent(BI.StaticDatePaneCard.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)})),this.calendar=BI.createWidget({direction:"custom",type:"bi.navigation",tab:this.datePicker,cardCreator:BI.bind(this._createNav,this)}),this.calendar.on(BI.Navigation.EVENT_CHANGE,(function(){e.selectedTime=e.calendar.getValue(),e.calendar.empty(),e.setValue(e.selectedTime),e.fireEvent(BI.DateCalendarPopup.EVENT_CHANGE)})),this.setValue(t.selectedTime),BI.createWidget({type:"bi.vtape",element:this,items:[{el:this.datePicker,height:40},this.calendar],hgap:10}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.layout",cls:"bi-split-top"},height:1,top:40,left:0,right:0}]})},_createNav:function(e){var t=BI.Calendar.getDateJSONByPage(e);return BI.createWidget({type:"bi.calendar",logic:{dynamic:!1},min:this.options.min,max:this.options.max,year:t.year,month:t.month,day:this.selectedTime.day})},_getNewCurrentDate:function(){var e=BI.getDate();return{year:e.getFullYear(),month:e.getMonth()+1}},_setCalenderValue:function(e){this.calendar.setSelect(BI.Calendar.getPageByDateJSON(e)),this.calendar.setValue(e),this.selectedTime=e},_setDatePicker:function(e){BI.isNull(e)||BI.isNull(e.year)||BI.isNull(e.month)?this.datePicker.setValue(this._getNewCurrentDate()):this.datePicker.setValue(e)},_setCalendar:function(e){BI.isNull(e)||BI.isNull(e.day)?(this.calendar.empty(),this._setCalenderValue(this._getNewCurrentDate())):this._setCalenderValue(e)},_checkMin:function(){var e=this.options;BI.each(this.calendar.getAllCard(),(function(t,n){n.setMinDate(e.min)}))},_checkMax:function(){var e=this.options;BI.each(this.calendar.getAllCard(),(function(t,n){n.setMaxDate(e.max)}))},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e,this.datePicker.setMinDate(e),this._checkMin())},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e,this.datePicker.setMaxDate(e),this._checkMax())},setValue:function(e){this._setDatePicker(e),this._setCalendar(e)},getValue:function(){return this.selectedTime}}),BI.StaticDatePaneCard.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW="EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",BI.shortcut("bi.static_date_pane_card",BI.StaticDatePaneCard)},function(e,t){BI.DynamicDatePane=BI.inherit(BI.Widget,{props:{baseCls:"bi-dynamic-date-pane",minDate:"1900-01-01",maxDate:"2099-12-31",supportDynamic:!0},render:function(){var e=this,t=this.options;return{type:"bi.vtape",items:[{el:{type:"bi.linear_segment",invisible:!t.supportDynamic,cls:"bi-split-bottom",height:30,items:BI.createItems([{text:BI.i18nText("BI-Multi_Date_YMD"),value:BI.DynamicDatePane.Static},{text:BI.i18nText("BI-Basic_Dynamic_Title"),value:BI.DynamicDatePane.Dynamic}],{textAlign:"center"}),listeners:[{eventName:BI.ButtonGroup.EVENT_CHANGE,action:function(){var t=this.getValue()[0];switch(e.dateTab.setSelect(t),t){case BI.DynamicDatePane.Static:var n=BI.DynamicDateHelper.getCalculation(e.dynamicPane.getValue());e.ymd.setValue({year:n.getFullYear(),month:n.getMonth()+1,day:n.getDate()});break;case BI.DynamicDatePane.Dynamic:e.dynamicPane.setValue({year:0})}e.fireEvent(BI.DynamicDatePane.EVENT_CHANGE)}}],ref:function(){e.switcher=this}},height:t.supportDynamic?30:0},{type:"bi.tab",ref:function(){e.dateTab=this},showIndex:BI.DynamicDatePane.Static,cardCreator:function(n){switch(n){case BI.DynamicDatePane.Static:return{type:"bi.static_date_pane_card",min:t.minDate,max:t.maxDate,behaviors:t.behaviors,listeners:[{eventName:"EVENT_CHANGE",action:function(){e.fireEvent(BI.DynamicDatePane.EVENT_CHANGE)}},{eventName:"EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",action:function(){e.fireEvent(BI.DynamicDatePane.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}],ref:function(){e.ymd=this}};case BI.DynamicDatePane.Dynamic:default:return{type:"bi.vtape",items:[{type:"bi.dynamic_date_card",min:t.minDate,max:t.maxDate,ref:function(){e.dynamicPane=this}},{el:{type:"bi.center",items:[{type:"bi.text_button",cls:"bi-high-light bi-border-top",shadow:!0,text:BI.i18nText("BI-Basic_Clear"),textHeight:23,listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.setValue(),e.fireEvent(BI.DynamicDatePane.EVENT_CHANGE)}}]},{type:"bi.text_button",cls:"bi-border-left bi-high-light bi-border-top",textHeight:23,shadow:!0,text:BI.i18nText("BI-Basic_OK"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.dateTab.getSelect()===BI.DynamicDateCombo.Dynamic?e.dynamicPane.checkValidation(!0)&&e.fireEvent(BI.DynamicDatePopup.EVENT_CHANGE):e.fireEvent(BI.DynamicDatePane.EVENT_CHANGE)}}]}]},height:24}]}}}}]}},created:function(){this.setValue(this.options.value)},_checkValueValid:function(e){return BI.isNull(e)||BI.isEmptyObject(e)||BI.isEmptyString(e)},_checkValue:function(e){switch(e.type){case BI.DynamicDateCombo.Dynamic:return BI.isNotEmptyObject(e.value);case BI.DynamicDateCombo.Static:default:return!0}},setMinDate:function(e){this.options.minDate!==e&&(this.options.minDate=e,this.ymd.setMinDate(e))},setMaxDate:function(e){this.options.maxDate!==e&&(this.options.maxDate=e,this.ymd.setMaxDate(e))},setValue:function(e){var t=(e=e||{}).type||BI.DynamicDateCombo.Static,n=e.value||e;switch(this.switcher.setValue(t),this.dateTab.setSelect(t),t){case BI.DynamicDateCombo.Dynamic:this.dynamicPane.setValue(n);break;case BI.DynamicDateCombo.Static:default:if(this._checkValueValid(n)){var i=BI.getDate();this.ymd.setValue({year:i.getFullYear(),month:i.getMonth()+1})}else this.ymd.setValue(n)}},getValue:function(){var e=this.dateTab.getSelect();return{type:e,value:e===BI.DynamicDatePane.Static?this.dateTab.getValue():this.dynamicPane.getValue()}}}),BI.DynamicDatePane.EVENT_CHANGE="EVENT_CHANGE",BI.DynamicDatePane.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW="EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",BI.shortcut("bi.dynamic_date_pane",BI.DynamicDatePane),BI.extend(BI.DynamicDatePane,{Static:1,Dynamic:2})},function(e,t){BI.DateTimeCombo=BI.inherit(BI.Single,{constants:{popupHeight:290,popupWidth:270,comboAdjustHeight:1,border:1},_defaultConfig:function(){return BI.extend(BI.DateTimeCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-date-time-combo bi-border bi-border-radius",width:200,height:24,minDate:"1900-01-01",maxDate:"2099-12-31"})},_init:function(){BI.DateTimeCombo.superclass._init.apply(this,arguments);var e=this,t=this.options,n=BI.getDate();this.storeValue=BI.isNotNull(t.value)?t.value:{year:n.getFullYear(),month:n.getMonth()+1,day:n.getDate(),hour:n.getHours(),minute:n.getMinutes(),second:n.getSeconds()},this.trigger=BI.createWidget({type:"bi.date_time_trigger",height:t.height,min:t.minDate,max:t.maxDate,value:t.value}),this.popup=BI.createWidget({type:"bi.date_time_popup",behaviors:t.behaviors,min:t.minDate,max:t.maxDate,value:t.value}),e.setValue(this.storeValue),this.popup.on(BI.DateTimePopup.BUTTON_CANCEL_EVENT_CHANGE,(function(){e.setValue(e.storeValue),e.hidePopupView(),e.fireEvent(BI.DateTimeCombo.EVENT_CANCEL)})),this.popup.on(BI.DateTimePopup.BUTTON_OK_EVENT_CHANGE,(function(){e.storeValue=e.popup.getValue(),e.setValue(e.storeValue),e.hidePopupView(),e.fireEvent(BI.DateTimeCombo.EVENT_CONFIRM)})),this.combo=BI.createWidget({type:"bi.combo",container:t.container,toggle:!1,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,el:this.trigger,adjustLength:this.constants.comboAdjustHeight,popup:{el:this.popup,width:this.constants.popupWidth,stopPropagation:!1},hideChecker:function(e){return 0===i.element.find(e.target).length}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){e.popup.setValue(e.storeValue),e.fireEvent(BI.DateTimeCombo.EVENT_BEFORE_POPUPVIEW)}));var i=BI.createWidget({type:"bi.icon_button",cls:"bi-trigger-icon-button date-font",width:t.height,height:t.height});i.on(BI.IconButton.EVENT_CHANGE,(function(){e.combo.isViewVisible()||e.combo.showView()})),BI.createWidget({type:"bi.htape",element:this,items:[{type:"bi.absolute",items:[{el:this.combo,top:0,left:0,right:0,bottom:0},{el:i,top:0,right:0}]}]})},setValue:function(e){this.storeValue=e,this.popup.setValue(e),this.trigger.setValue(e)},getValue:function(){return this.storeValue},hidePopupView:function(){this.combo.hideView()}}),BI.DateTimeCombo.EVENT_CANCEL="EVENT_CANCEL",BI.DateTimeCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.DateTimeCombo.EVENT_CHANGE="EVENT_CHANGE",BI.DateTimeCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.date_time_combo",BI.DateTimeCombo)},function(e,t){BI.DateTimePopup=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.DateTimePopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-date-time-popup",width:268,height:374})},_init:function(){BI.DateTimePopup.superclass._init.apply(this,arguments);var e=this,t=this.options;this.cancelButton=BI.createWidget({type:"bi.text_button",cls:"multidate-popup-button bi-border-top bi-border-right",shadow:!0,text:BI.i18nText("BI-Basic_Cancel")}),this.cancelButton.on(BI.TextButton.EVENT_CHANGE,(function(){e.fireEvent(BI.DateTimePopup.BUTTON_CANCEL_EVENT_CHANGE)})),this.okButton=BI.createWidget({type:"bi.text_button",cls:"multidate-popup-button bi-border-top",shadow:!0,text:BI.i18nText("BI-Basic_OK")}),this.okButton.on(BI.TextButton.EVENT_CHANGE,(function(){e.fireEvent(BI.DateTimePopup.BUTTON_OK_EVENT_CHANGE)})),this.dateCombo=BI.createWidget({type:"bi.date_calendar_popup",behaviors:t.behaviors,min:e.options.min,max:e.options.max}),e.dateCombo.on(BI.DateCalendarPopup.EVENT_CHANGE,(function(){e.fireEvent(BI.DateTimePopup.CALENDAR_EVENT_CHANGE)})),this.dateButton=BI.createWidget({type:"bi.grid",items:[[this.cancelButton,this.okButton]]}),BI.createWidget({element:this,type:"bi.vtape",items:[{el:this.dateCombo},{el:{type:"bi.center_adapt",cls:"bi-split-top",items:[{type:"bi.dynamic_date_time_select",ref:function(t){e.timeSelect=t}}]},height:50},{el:this.dateButton,height:30}]}),this.setValue(t.value)},setValue:function(e){var t,n=e;BI.isNull(n)?(t=BI.getDate(),this.dateCombo.setValue({year:t.getFullYear(),month:t.getMonth()+1,day:t.getDate()}),this.timeSelect.setValue({hour:t.getHours(),minute:t.getMinutes(),second:t.getSeconds()})):(this.dateCombo.setValue({year:n.year,month:n.month,day:n.day}),this.timeSelect.setValue({hour:n.hour,minute:n.minute,second:n.second}))},getValue:function(){return BI.extend({year:this.dateCombo.getValue().year,month:this.dateCombo.getValue().month,day:this.dateCombo.getValue().day},this.timeSelect.getValue())}}),BI.DateTimePopup.BUTTON_OK_EVENT_CHANGE="BUTTON_OK_EVENT_CHANGE",BI.DateTimePopup.BUTTON_CANCEL_EVENT_CHANGE="BUTTON_CANCEL_EVENT_CHANGE",BI.DateTimePopup.CALENDAR_EVENT_CHANGE="CALENDAR_EVENT_CHANGE",BI.shortcut("bi.date_time_popup",BI.DateTimePopup)},function(e,t){BI.DateTimeTrigger=BI.inherit(BI.Trigger,{_const:{hgap:4},_defaultConfig:function(){return BI.extend(BI.DateTimeTrigger.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-date-time-trigger",min:"1900-01-01",max:"2099-12-31",height:24,width:200})},_init:function(){BI.DateTimeTrigger.superclass._init.apply(this,arguments);var e=this.options,t=this._const;this.text=BI.createWidget({type:"bi.label",textAlign:"left",height:e.height,width:e.width,hgap:t.hgap}),BI.createWidget({type:"bi.htape",element:this,items:[{el:this.text},{el:BI.createWidget(),width:e.height}]}),this.setValue(e.value)},_printTime:function(e){return e<10?"0"+e:e},setValue:function(e){var t,n=e;if(BI.isNull(n))n=BI.getDate(),t=BI.print(n,"%Y-%X-%d %H:%M:%S");else{var i=BI.getDate(n.year,n.month-1,n.day,n.hour,n.minute,n.second);t=BI.print(i,"%Y-%X-%d %H:%M:%S")}this.text.setText(t),this.text.setTitle(t)}}),BI.shortcut("bi.date_time_trigger",BI.DateTimeTrigger)},function(e,t){BI.StaticDateTimePaneCard=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.StaticDateTimePaneCard.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:"bi-date-time-pane",min:"1900-01-01",max:"2099-12-31",selectedTime:null})},_init:function(){BI.StaticDateTimePaneCard.superclass._init.apply(this,arguments);var e=this,t=this.options;this.today=BI.getDate(),this._year=this.today.getFullYear(),this._month=this.today.getMonth()+1,this.selectedTime=t.selectedTime||{year:this._year,month:this._month},this.datePicker=BI.createWidget({type:"bi.date_picker",behaviors:t.behaviors,min:t.min,max:t.max}),this.datePicker.on(BI.DatePicker.EVENT_CHANGE,(function(){var t=e.datePicker.getValue(),n=BI.getMonthDays(BI.getDate(t.year,t.month-1,1)),i=e.selectedTime.day||0;i>n&&(i=n),e.selectedTime=BI.extend(e.selectedTime,{year:t.year,month:t.month}),0!==i&&(e.selectedTime.day=i),e.calendar.setSelect(BI.Calendar.getPageByDateJSON(e.selectedTime)),e.calendar.setValue(e.selectedTime),0!==i&&e.fireEvent(BI.DateCalendarPopup.EVENT_CHANGE)})),this.datePicker.on(BI.DatePicker.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,(function(){e.fireEvent(BI.StaticDateTimePaneCard.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)})),this.calendar=BI.createWidget({direction:"custom",type:"bi.navigation",tab:this.datePicker,cardCreator:BI.bind(this._createNav,this)}),this.calendar.on(BI.Navigation.EVENT_CHANGE,(function(){e.selectedTime=BI.extend(e.calendar.getValue(),e.timeSelect.getValue()),e.calendar.empty(),e.setValue(e.selectedTime),e.fireEvent(BI.DateCalendarPopup.EVENT_CHANGE)})),BI.createWidget({type:"bi.vtape",element:this,hgap:10,items:[{el:this.datePicker,height:40},this.calendar,{el:{type:"bi.dynamic_date_time_select",cls:"bi-split-top",ref:function(){e.timeSelect=this},listeners:[{eventName:BI.DynamicDateTimeSelect.EVENT_CONFIRM,action:function(){e.selectedTime=BI.extend(e.calendar.getValue(),e.timeSelect.getValue()),e.fireEvent("EVENT_CHANGE")}}]},height:40}]}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.layout",cls:"bi-split-top"},height:1,top:40,left:0,right:0}]}),this.setValue(t.selectedTime)},_createNav:function(e){var t=BI.Calendar.getDateJSONByPage(e);return BI.createWidget({type:"bi.calendar",logic:{dynamic:!1},min:this.options.min,max:this.options.max,year:t.year,month:t.month,day:this.selectedTime.day})},_getNewCurrentDate:function(){var e=BI.getDate();return{year:e.getFullYear(),month:e.getMonth()+1}},_setCalenderValue:function(e){this.calendar.setSelect(BI.Calendar.getPageByDateJSON(e)),this.calendar.setValue(e),this.selectedTime=BI.extend({},this.timeSelect.getValue(),e)},_setDatePicker:function(e){BI.isNull(e)||BI.isNull(e.year)||BI.isNull(e.month)?this.datePicker.setValue(this._getNewCurrentDate()):this.datePicker.setValue(e)},_setCalendar:function(e){BI.isNull(e)||BI.isNull(e.day)?(this.calendar.empty(),this._setCalenderValue(this._getNewCurrentDate())):this._setCalenderValue(e)},_checkMin:function(){var e=this.options;BI.each(this.calendar.getAllCard(),(function(t,n){n.setMinDate(e.min)}))},_checkMax:function(){var e=this.options;BI.each(this.calendar.getAllCard(),(function(t,n){n.setMaxDate(e.max)}))},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e,this.datePicker.setMinDate(e),this._checkMin())},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e,this.datePicker.setMaxDate(e),this._checkMax())},setValue:function(e){e=e||{},this._setDatePicker(e),this._setCalendar(e),this.timeSelect.setValue({hour:e.hour,minute:e.minute,second:e.second})},getValue:function(){return this.selectedTime}}),BI.StaticDateTimePaneCard.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW="EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",BI.shortcut("bi.static_date_time_pane_card",BI.StaticDateTimePaneCard)},function(e,t){BI.DynamicDateTimePane=BI.inherit(BI.Widget,{props:{baseCls:"bi-dynamic-date-pane",minDate:"1900-01-01",maxDate:"2099-12-31",supportDynamic:!0},render:function(){var e=this,t=this.options;return{type:"bi.vtape",items:[{el:{type:"bi.linear_segment",invisible:!t.supportDynamic,cls:"bi-split-bottom",height:30,items:BI.createItems([{text:BI.i18nText("BI-Multi_Date_YMD"),value:BI.DynamicDateTimePane.Static},{text:BI.i18nText("BI-Basic_Dynamic_Title"),value:BI.DynamicDateTimePane.Dynamic}],{textAlign:"center"}),listeners:[{eventName:BI.ButtonGroup.EVENT_CHANGE,action:function(){var t=this.getValue()[0];switch(e.dateTab.setSelect(t),t){case BI.DynamicDateTimePane.Static:var n=BI.DynamicDateHelper.getCalculation(e.dynamicPane.getValue());e.ymd.setValue({year:n.getFullYear(),month:n.getMonth()+1,day:n.getDate()});break;case BI.DynamicDateTimePane.Dynamic:e.dynamicPane.setValue({year:0})}e.fireEvent(BI.DynamicDateTimePane.EVENT_CHANGE)}}],ref:function(){e.switcher=this}},height:t.supportDynamic?30:0},{type:"bi.tab",ref:function(){e.dateTab=this},showIndex:BI.DynamicDateTimePane.Static,cardCreator:function(n){switch(n){case BI.DynamicDateTimePane.Static:return{type:"bi.static_date_time_pane_card",min:t.minDate,max:t.maxDate,behaviors:t.behaviors,listeners:[{eventName:"EVENT_CHANGE",action:function(){e.fireEvent(BI.DynamicDateTimePane.EVENT_CHANGE)}},{eventName:"EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",action:function(){e.fireEvent(BI.DynamicDateTimePane.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}],ref:function(){e.ymd=this}};case BI.DynamicDateTimePane.Dynamic:default:return{type:"bi.vtape",items:[{type:"bi.dynamic_date_card",min:t.minDate,max:t.maxDate,ref:function(){e.dynamicPane=this}},{el:{type:"bi.center",items:[{type:"bi.text_button",cls:"bi-high-light bi-border-top",shadow:!0,text:BI.i18nText("BI-Basic_Clear"),textHeight:23,listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.setValue(),e.fireEvent(BI.DynamicDatePane.EVENT_CHANGE)}}]},{type:"bi.text_button",cls:"bi-border-left bi-high-light bi-border-top",textHeight:23,shadow:!0,text:BI.i18nText("BI-Basic_OK"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.dateTab.getSelect()===BI.DynamicDateCombo.Dynamic?e.dynamicPane.checkValidation(!0)&&e.fireEvent(BI.DynamicDatePane.EVENT_CHANGE):e.fireEvent(BI.DynamicDatePane.EVENT_CHANGE)}}]}]},height:24}]}}}}]}},created:function(){this.setValue(this.options.value)},_checkValueValid:function(e){return BI.isNull(e)||BI.isEmptyObject(e)||BI.isEmptyString(e)},_checkValue:function(e){switch(e.type){case BI.DynamicDateCombo.Dynamic:return BI.isNotEmptyObject(e.value);case BI.DynamicDateCombo.Static:default:return!0}},setMinDate:function(e){this.options.minDate!==e&&(this.options.minDate=e,this.ymd.setMinDate(e))},setMaxDate:function(e){this.options.maxDate!==e&&(this.options.maxDate=e,this.ymd.setMaxDate(e))},setValue:function(e){var t=(e=e||{}).type||BI.DynamicDateTimePane.Static,n=e.value||e;switch(this.switcher.setValue(t),this.dateTab.setSelect(t),t){case BI.DynamicDateTimePane.Dynamic:this.dynamicPane.setValue(n);break;case BI.DynamicDateTimePane.Static:default:if(this._checkValueValid(n)){var i=BI.getDate();this.ymd.setValue({year:i.getFullYear(),month:i.getMonth()+1})}else this.ymd.setValue(n)}},getValue:function(){return{type:this.dateTab.getSelect(),value:this.dateTab.getValue()}}}),BI.DynamicDateTimePane.EVENT_CHANGE="EVENT_CHANGE",BI.DynamicDateTimePane.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW="EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",BI.shortcut("bi.dynamic_date_time_pane",BI.DynamicDateTimePane),BI.extend(BI.DynamicDateTimePane,{Static:1,Dynamic:2})},function(e,t){BI.DownListCombo=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.DownListCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-down-list-combo",height:24,items:[],adjustLength:0,direction:"bottom",trigger:"click",container:null,stopPropagation:!1,el:{},minWidth:140,maxHeight:1e3})},_init:function(){BI.DownListCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;this.popupview=BI.createWidget({type:"bi.down_list_popup",items:t.items,chooseType:t.chooseType,value:t.value}),this.popupview.on(BI.DownListPopup.EVENT_CHANGE,(function(t){e.fireEvent(BI.DownListCombo.EVENT_CHANGE,t),e.downlistcombo.hideView()})),this.popupview.on(BI.DownListPopup.EVENT_SON_VALUE_CHANGE,(function(t,n){e.fireEvent(BI.DownListCombo.EVENT_SON_VALUE_CHANGE,t,n),e.downlistcombo.hideView()})),this.downlistcombo=BI.createWidget({element:this,type:"bi.combo",trigger:t.trigger,isNeedAdjustWidth:!1,container:t.container,adjustLength:t.adjustLength,direction:t.direction,belowMouse:t.belowMouse,stopPropagation:t.stopPropagation,el:BI.createWidget(t.el,{type:"bi.icon_trigger",extraCls:t.iconCls,width:t.width,height:t.height}),popup:{el:this.popupview,stopPropagation:t.stopPropagation,maxHeight:t.maxHeight,minWidth:t.minWidth}}),this.downlistcombo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){e.fireEvent(BI.DownListCombo.EVENT_BEFORE_POPUPVIEW)}))},hideView:function(){this.downlistcombo.hideView()},showView:function(e){this.downlistcombo.showView(e)},populate:function(e){this.popupview.populate(e)},setValue:function(e){this.popupview.setValue(e)},getValue:function(){return this.popupview.getValue()}}),BI.DownListCombo.EVENT_CHANGE="EVENT_CHANGE",BI.DownListCombo.EVENT_SON_VALUE_CHANGE="EVENT_SON_VALUE_CHANGE",BI.DownListCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.down_list_combo",BI.DownListCombo)},function(e,t){BI.DownListGroup=BI.inherit(BI.Widget,{constants:{iconCls:"check-mark-ha-font"},_defaultConfig:function(){return BI.extend(BI.DownListGroup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-down-list-group",items:[{el:{}}]})},_init:function(){BI.DownListGroup.superclass._init.apply(this,arguments);var e=this.options,t=this;this.downlistgroup=BI.createWidget({element:this,type:"bi.button_tree",items:e.items,chooseType:0,layouts:[{type:"bi.vertical",hgap:0,vgap:0}],value:e.value}),this.downlistgroup.on(BI.Controller.EVENT_CHANGE,(function(e){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&t.fireEvent(BI.DownListGroup.EVENT_CHANGE,arguments)}))},getValue:function(){return this.downlistgroup.getValue()},setValue:function(e){this.downlistgroup.setValue(e)}}),BI.DownListGroup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.down_list_group",BI.DownListGroup)},function(e,t){BI.DownListItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.DownListItem.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:"bi-down-list-item bi-list-item-active",cls:"",height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,logic:{dynamic:!0},selected:!1,iconHeight:null,iconWidth:null,textHgap:0,textVgap:0,textLgap:0,textRgap:0})},_init:function(){BI.DownListItem.superclass._init.apply(this,arguments);var e=this.options;this.text=BI.createWidget({type:"bi.label",cls:"list-item-text",textAlign:"left",hgap:e.textHgap,vgap:e.textVgap,lgap:e.textLgap,rgap:e.textRgap,text:e.text,value:e.value,keyword:e.keyword,height:e.height}),this.icon=BI.createWidget({type:"bi.center_adapt",width:36,height:e.height,items:[{el:{type:"bi.icon",width:e.iconWidth,height:e.iconHeight}}]}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),BI.extend(e.logic,{items:BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,this.icon,this.text)}))))},setValue:function(){this.isReadOnly()||this.text.setValue.apply(this.text,arguments)},getValue:function(){return this.text.getValue()},setText:function(){this.text.setText.apply(this.text,arguments)},getText:function(){return this.text.getText()},doClick:function(){BI.DownListItem.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.DownListItem.EVENT_CHANGE,this.getValue(),this)},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)}}),BI.DownListItem.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.down_list_item",BI.DownListItem)},function(e,t){BI.DownListGroupItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){var e=BI.DownListGroupItem.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-down-list-group-item",logic:{dynamic:!1},iconCls1:"dot-e-font",iconCls2:"pull-right-e-font"})},_init:function(){BI.DownListGroupItem.superclass._init.apply(this,arguments);var e=this.options,t=this;this.text=BI.createWidget({type:"bi.label",cls:"list-group-item-text",textAlign:"left",text:e.text,value:e.value,height:e.height}),this.icon1=BI.createWidget({type:"bi.icon_button",cls:e.iconCls1,width:36,disableSelected:!0,selected:this._digest(e.value)}),this.icon2=BI.createWidget({type:"bi.icon_button",cls:e.iconCls2,width:24,forceNotSelected:!0});var n=BI.createWidget({type:"bi.layout",width:24});BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.icon2,top:0,bottom:0,right:0}]}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic("horizontal",BI.extend(e.logic,{items:BI.LogicFactory.createLogicItemsByDirection("left",this.icon1,this.text,n)})))),this.element.hover((function(){t.isEnabled()&&t.hover()}),(function(){t.isEnabled()&&t.dishover()}))},_getLevel:function(){var e=BI.first(this.options.childValues);return BI.isNotNull(e)?(e+"").split(BI.BlankSplitChar).length:0},_digest:function(e){var t=this.options;e=BI.isArray(e)?e:[e];var n=this._getLevel();return BI.any(e,(function(e,i){return BI.contains(t.childValues,(i+"").split(BI.BlankSplitChar).slice(0,n).join(BI.BlankSplitChar))}))},hover:function(){BI.DownListGroupItem.superclass.hover.apply(this,arguments),this.icon1.element.addClass("hover"),this.icon2.element.addClass("hover")},dishover:function(){BI.DownListGroupItem.superclass.dishover.apply(this,arguments),this.icon1.element.removeClass("hover"),this.icon2.element.removeClass("hover")},doClick:function(){BI.DownListGroupItem.superclass.doClick.apply(this,arguments),this.isValid()&&this.fireEvent(BI.DownListGroupItem.EVENT_CHANGE,this.getValue())},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},setValue:function(e){this.icon1.setSelected(this._digest(e))}}),BI.DownListGroupItem.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.down_list_group_item",BI.DownListGroupItem)},function(e,t){BI.DownListPopup=BI.inherit(BI.Pane,{constants:{nextIcon:"pull-right-e-font",height:24,iconHeight:12,iconWidth:12,hgap:0,vgap:0,border:1},_defaultConfig:function(){var e=BI.DownListPopup.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:"bi-down-list-popup",items:[],chooseType:BI.Selection.Multi})},_init:function(){BI.DownListPopup.superclass._init.apply(this,arguments),this.singleValues=[],this.childValueMap={},this.fatherValueMap={},this.items=BI.deepClone(this.options.items);var e=this,t=this.options,n=this._createChildren(this.items);this.popup=BI.createWidget({type:"bi.button_tree",items:BI.createItems(n,{},{adjustLength:-2}),layouts:[{type:"bi.vertical",hgap:this.constants.hgap,vgap:this.constants.vgap}],value:this._digest(t.value),chooseType:t.chooseType}),this.popup.on(BI.ButtonTree.EVENT_CHANGE,(function(t,n){var i=t;if(BI.isNotNull(e.childValueMap[t])?(i=e.childValueMap[t],e.fireEvent(BI.DownListPopup.EVENT_SON_VALUE_CHANGE,i,e.fatherValueMap[t])):e.fireEvent(BI.DownListPopup.EVENT_CHANGE,i,n),!BI.contains(e.singleValues,i)){var r=e.getValue(),a=[];BI.each(r,(function(e,t){t.value!=i&&a.push(t)})),e.setValue(a)}})),BI.createWidget({type:"bi.vertical",element:this,items:[this.popup],vgap:5})},_createChildren:function(e){var t=this,n=[];return BI.each(e,(function(i,r){var a={type:"bi.down_list_group",items:[]};if(BI.each(r,(function(e,n){BI.isNotEmptyArray(n.children)&&!BI.isEmpty(n.el)?(n.type="bi.combo_group",n.isDefaultInit=!0,n.cls="down-list-group",n.trigger="hover",n.isNeedAdjustWidth=!1,n.el.title=n.el.title||n.el.text,n.el.type="bi.down_list_group_item",n.el.logic={dynamic:!0},n.el.height=n.el.height||BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,n.el.iconCls2=t.constants.nextIcon,n.popup={lgap:1,el:{type:"bi.button_tree",chooseType:0,layouts:[{type:"bi.vertical"}]},innerVGap:5,maxHeight:378},n.el.childValues=[],BI.each(n.children,(function(e,i){var r=BI.deepClone(n.el.value),a=BI.deepClone(i.value);t.singleValues.push(i.value),i.type=i.type||"bi.down_list_item",i.extraCls=" child-down-list-item",i.title=i.title||i.text,i.textRgap=10,i.isNeedAdjustWidth=!1,i.logic={dynamic:!0},i.father=r,t.fatherValueMap[t._createChildValue(r,a)]=r,t.childValueMap[t._createChildValue(r,a)]=a,i.value=t._createChildValue(r,a),n.el.childValues.push(i.value)}))):(n.type=n.type||"bi.down_list_item",n.title=n.title||n.text,n.textRgap=10,n.isNeedAdjustWidth=!1,n.logic={dynamic:!0});var i={};i.el=n,a.items.push(i)})),t._isGroup(a.items)&&BI.each(a.items,(function(e,n){t.singleValues.push(n.el.value)})),n.push(a),t._needSpliter(i,e.length)){var o=BI.createWidget({type:"bi.vertical",items:[{el:{type:"bi.layout",cls:"bi-down-list-spliter bi-split-top cursor-pointer",height:0}}],cls:"bi-down-list-spliter-container cursor-pointer",vgap:5,lgap:10,rgap:0});n.push(o)}})),n},_isGroup:function(e){return e.length>1},_needSpliter:function(e,t){return e<t-1},_createChildValue:function(e,t){return e+BI.BlankSplitChar+t},_digest:function(e){var t=this,n=[];return BI.each(e,(function(e,i){var r;r=BI.isNotNull(i.childValue)?t._createChildValue(i.value,i.childValue):i.value,n.push(r)})),n},_checkValues:function(e){var t=[];return BI.each(this.items,(function(n,i){BI.each(i,(function(i,r){if(BI.isNotNull(r.children)){var a=function(e,t){var n="";return BI.some(e,(function(e,i){return BI.some(t,(function(e,t){if(i===t)return n=i,!0}))})),n}(BI.map(r.children,"value"),e[n]);BI.isNotEmptyString(a)&&t.push(a)}else r.value===e[n][0]&&t.push(e[n][0])}))})),t},populate:function(e){BI.DownListPopup.superclass.populate.apply(this,arguments),this.items=BI.deepClone(e),this.childValueMap={},this.fatherValueMap={},this.singleValues=[];var t=this._createChildren(this.items),n=BI.createItems(t,{},{adjustLength:-2});this.popup.populate(n)},setValue:function(e){this.popup.setValue(this._digest(e))},_getValue:function(){var e=[];return BI.each(this.popup.getAllButtons(),(function(t,n){t%2==0&&e.push(n.getValue())})),e},getValue:function(){var e=this,t=[],n=this._checkValues(this._getValue());return BI.each(n,(function(n,i){var r={};if(BI.isNotNull(e.childValueMap[i])){var a=e.fatherValueMap[i];r.childValue=e.childValueMap[i],r.value=a}else r.value=i;t.push(r)})),t}}),BI.DownListPopup.EVENT_CHANGE="EVENT_CHANGE",BI.DownListPopup.EVENT_SON_VALUE_CHANGE="EVENT_SON_VALUE_CHANGE",BI.shortcut("bi.down_list_popup",BI.DownListPopup)},function(e,t){BI.DynamicDateHelper={},BI.extend(BI.DynamicDateHelper,{getCalculation:function(e){var t=BI.getDate();return this.getCalculationByDate(t,e)},getDescription:function(e){var t="",n="";return BI.isNotNull(e.year)&&(0!==BI.parseInt(e.year)&&(t+=Math.abs(e.year)+BI.i18nText("BI-Basic_Year")+(e.year<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),n=i(BI.i18nText("BI-Basic_Year"),e.position)),BI.isNotNull(e.quarter)&&(0!==BI.parseInt(e.quarter)&&(t+=Math.abs(e.quarter)+BI.i18nText("BI-Basic_Single_Quarter")+(e.quarter<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),n=i(BI.i18nText("BI-Basic_Single_Quarter"),e.position)),BI.isNotNull(e.month)&&(0!==BI.parseInt(e.month)&&(t+=Math.abs(e.month)+BI.i18nText("BI-Basic_Month")+(e.month<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),n=i(BI.i18nText("BI-Basic_Month"),e.position)),BI.isNotNull(e.week)&&(0!==BI.parseInt(e.week)&&(t+=Math.abs(e.week)+BI.i18nText("BI-Basic_Week")+(e.week<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),n=i(BI.i18nText("BI-Basic_Week"),e.position)),BI.isNotNull(e.day)&&(0!==BI.parseInt(e.day)&&(t+=Math.abs(e.day)+BI.i18nText("BI-Basic_Day")+(e.day<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),n=1===BI.size(e)?i(BI.i18nText("BI-Basic_Month"),e.position):""),BI.isNotNull(e.workDay)&&0!==BI.parseInt(e.workDay)&&(t+=Math.abs(e.workDay)+BI.i18nText("BI-Basic_Work_Day")+(e.workDay<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),t+n;function i(e,t){switch(t){case BI.DynamicDateCard.OFFSET.BEGIN:return e+BI.i18nText("BI-Basic_Begin_Start");case BI.DynamicDateCard.OFFSET.END:return e+BI.i18nText("BI-Basic_End_Stop");case BI.DynamicDateCard.OFFSET.CURRENT:default:return BI.i18nText("BI-Basic_Current_Day")}}},getCalculationByDate:function(e,t){if(BI.isNotNull(t.year)&&(e=BI.getDate(e.getFullYear()+BI.parseInt(t.year),e.getMonth(),e.getDate())),BI.isNotNull(t.quarter)&&(e=BI.getOffsetQuarter(e,BI.parseInt(t.quarter))),BI.isNotNull(t.month)&&(e=BI.getOffsetMonth(e,BI.parseInt(t.month))),BI.isNotNull(t.week)&&(e=BI.getOffsetDate(e,7*BI.parseInt(t.week))),BI.isNotNull(t.day)&&(e=BI.getOffsetDate(e,BI.parseInt(t.day))),BI.isNotNull(t.workDay))if(BI.isNotNull(BI.holidays))for(var n=Math.abs(t.workDay),i=0;i<n;i++)e=BI.getOffsetDate(e,t.workDay<0?-1:1),BI.isNotNull(BI.holidays[BI.print(e,"%Y-%X-%d")])&&i--;else e=BI.getOffsetDate(e,BI.parseInt(t.workDay));return BI.isNotNull(t.position)&&t.position!==BI.DynamicDateCard.OFFSET.CURRENT&&(e=this.getBeginDate(e,t)),BI.getDate(e.getFullYear(),e.getMonth(),e.getDate())},getBeginDate:function(e,t){return BI.isNotNull(t.day)?t.position===BI.DynamicDateCard.OFFSET.BEGIN?BI.getDate(e.getFullYear(),e.getMonth(),1):BI.getDate(e.getFullYear(),e.getMonth(),BI.getLastDateOfMonth(e).getDate()):BI.isNotNull(t.week)?t.position===BI.DynamicDateCard.OFFSET.BEGIN?BI.getWeekStartDate(e):BI.getWeekEndDate(e):BI.isNotNull(t.month)?t.position===BI.DynamicDateCard.OFFSET.BEGIN?BI.getDate(e.getFullYear(),e.getMonth(),1):BI.getDate(e.getFullYear(),e.getMonth(),BI.getLastDateOfMonth(e).getDate()):BI.isNotNull(t.quarter)?t.position===BI.DynamicDateCard.OFFSET.BEGIN?BI.getQuarterStartDate(e):BI.getQuarterEndDate(e):BI.isNotNull(t.year)?t.position===BI.DynamicDateCard.OFFSET.BEGIN?BI.getDate(e.getFullYear(),0,1):BI.getDate(e.getFullYear(),11,31):e}})},function(e,t){BI.DynamicDateCard=BI.inherit(BI.Widget,{props:{baseCls:"bi-dynamic-date-card"},render:function(){var e=this;return this.position=BI.DynamicDateCard.OFFSET.CURRENT,{type:"bi.vertical",items:[{el:{type:"bi.label",text:BI.i18nText("BI-Multi_Date_Relative_Current_Time"),textAlign:"left",height:12,lgap:10},tgap:10,bgap:5},{type:"bi.button_group",ref:function(){e.checkgroup=this},chooseType:BI.ButtonGroup.CHOOSE_TYPE_MULTI,lgap:4,value:[BI.DynamicDateCard.TYPE.YEAR],items:BI.createItems([{text:BI.i18nText("BI-Basic_Year"),value:BI.DynamicDateCard.TYPE.YEAR},{text:BI.i18nText("BI-Basic_Single_Quarter"),value:BI.DynamicDateCard.TYPE.QUARTER},{text:BI.i18nText("BI-Basic_Month"),value:BI.DynamicDateCard.TYPE.MONTH},{text:BI.i18nText("BI-Basic_Week"),value:BI.DynamicDateCard.TYPE.WEEK},{text:BI.i18nText("BI-Basic_Day"),value:BI.DynamicDateCard.TYPE.DAY}],{type:"bi.multi_select_item",logic:{dynamic:!0},iconWrapperWidth:26}),layouts:[{type:"bi.left",rgap:4}],listeners:[{eventName:BI.ButtonGroup.EVENT_CHANGE,action:function(){0!==e.checkgroup.getValue().length&&e.workDayBox.setSelected(!1);var t={};BI.each(e.resultPane.getAllButtons(),(function(e,n){var i=n.getValue();BI.isNotNull(i.dateType)&&(t[i.dateType]={value:i.value,offset:i.offset})})),e.resultPane.populate(e._getParamJson(BI.map(e.checkgroup.getValue(),(function(e,n){var i={dateType:n};return BI.has(t,n)&&(i.value=t[n].value,i.offset=t[n].offset),i})))),e.position=BI.DynamicDateCard.OFFSET.CURRENT,e.fireEvent("EVENT_CHANGE")}}]},{type:"bi.vertical_adapt",lgap:2,items:[{el:{type:"bi.multi_select_item",iconWrapperWidth:26,ref:function(){e.workDayBox=this},logic:{dynamic:!0},text:BI.i18nText("BI-Basic_Work_Day"),value:BI.DynamicDateCard.TYPE.WORK_DAY,listeners:[{eventName:BI.MultiSelectItem.EVENT_CHANGE,action:function(){this.isSelected()&&e.checkgroup.setValue(),e.resultPane.populate(this.isSelected()?e._getParamJson([{dateType:BI.DynamicDateCard.TYPE.WORK_DAY}]):[]),e.position=BI.DynamicDateCard.OFFSET.CURRENT,e.fireEvent("EVENT_CHANGE")}}]}}],ref:function(){e.workDay=this}},{type:"bi.button_group",items:this._getParamJson([{dateType:BI.DynamicDateCard.TYPE.YEAR}]),ref:function(){e.resultPane=this},layouts:[{type:"bi.vertical",bgap:10,hgap:10}]}]}},_getParamJson:function(e,t){var n=this,i=(this.options,BI.map(e,(function(e,t){return{el:{type:"bi.dynamic_date_param_item",validationChecker:BI.bind(n._checkDate,n),dateType:t.dateType,value:t.value,offset:t.offset,listeners:[{eventName:"EVENT_CHANGE",action:function(){n.fireEvent("EVENT_CHANGE")}},{eventName:"EVENT_INPUT_CHANGE",action:function(){BI.Bubbles.hide("dynamic-date-error")}}]},tgap:0===e?5:0}})));if(1===e.length&&e[0].dateType===BI.DynamicDateCard.TYPE.DAY){var r=this._getText(BI.DynamicDateCard.TYPE.MONTH);r[0].text=BI.i18nText("BI-Basic_Empty"),i.push({type:"bi.text_value_combo",height:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT,items:r,container:null,value:t||BI.DynamicDateCard.OFFSET.CURRENT,listeners:[{eventName:"EVENT_CHANGE",action:function(){n.position=this.getValue()[0],this.setValue(n.position),n.fireEvent("EVENT_CHANGE")}}]})}else 0!==e.length&&BI.last(e).dateType!==BI.DynamicDateCard.TYPE.DAY&&BI.last(e).dateType!==BI.DynamicDateCard.TYPE.WORK_DAY&&i.push({type:"bi.text_value_combo",height:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT,container:null,items:this._getText(BI.last(e).dateType),value:t||BI.DynamicDateCard.OFFSET.CURRENT,listeners:[{eventName:"EVENT_CHANGE",action:function(){n.position=this.getValue()[0],this.setValue(n.position),n.fireEvent("EVENT_CHANGE")}}]});return i},_checkDate:function(e){var t=this.options,n=BI.DynamicDateHelper.getCalculation(BI.extend(this._getValue(),this._digestDateTypeValue(e)));return!BI.checkDateVoid(n.getFullYear(),n.getMonth()+1,n.getDate(),t.min,t.max)[0]},_getText:function(e){switch(e){case BI.DynamicDateCard.TYPE.YEAR:return[{text:BI.i18nText("BI-Basic_Current_Day"),value:BI.DynamicDateCard.OFFSET.CURRENT},{text:BI.i18nText("BI-Basic_Year_Begin"),value:BI.DynamicDateCard.OFFSET.BEGIN},{text:BI.i18nText("BI-Basic_Year_End"),value:BI.DynamicDateCard.OFFSET.END}];case BI.DynamicDateCard.TYPE.QUARTER:return[{text:BI.i18nText("BI-Basic_Current_Day"),value:BI.DynamicDateCard.OFFSET.CURRENT},{text:BI.i18nText("BI-Basic_Quarter_Begin"),value:BI.DynamicDateCard.OFFSET.BEGIN},{text:BI.i18nText("BI-Basic_Quarter_End"),value:BI.DynamicDateCard.OFFSET.END}];case BI.DynamicDateCard.TYPE.MONTH:return[{text:BI.i18nText("BI-Basic_Current_Day"),value:BI.DynamicDateCard.OFFSET.CURRENT},{text:BI.i18nText("BI-Basic_Month_Begin"),value:BI.DynamicDateCard.OFFSET.BEGIN},{text:BI.i18nText("BI-Basic_Month_End"),value:BI.DynamicDateCard.OFFSET.END}];case BI.DynamicDateCard.TYPE.WEEK:default:return[{text:BI.i18nText("BI-Basic_Current_Day"),value:BI.DynamicDateCard.OFFSET.CURRENT},{text:BI.i18nText("BI-Basic_Week_Begin"),value:BI.DynamicDateCard.OFFSET.BEGIN},{text:BI.i18nText("BI-Basic_Week_End"),value:BI.DynamicDateCard.OFFSET.END}]}},_createValue:function(e,t){return{dateType:e,value:Math.abs(t),offset:t>0?1:0}},_digestDateTypeValue:function(e){var t={};switch(e.dateType){case BI.DynamicDateCard.TYPE.YEAR:t.year=0===e.offset?-e.value:+e.value;break;case BI.DynamicDateCard.TYPE.QUARTER:t.quarter=0===e.offset?-e.value:+e.value;break;case BI.DynamicDateCard.TYPE.MONTH:t.month=0===e.offset?-e.value:+e.value;break;case BI.DynamicDateCard.TYPE.WEEK:t.week=0===e.offset?-e.value:+e.value;break;case BI.DynamicDateCard.TYPE.DAY:t.day=0===e.offset?-e.value:+e.value;break;case BI.DynamicDateCard.TYPE.WORK_DAY:t.workDay=0===e.offset?-e.value:+e.value}return BI.isNull(e.dateType)&&(t.position=this.position||BI.DynamicDateCard.OFFSET.CURRENT),t},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e)},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e)},setValue:function(e){e=e||{},this.position=e.position||BI.DynamicDateCard.OFFSET.CURRENT;var t=[],n=[];BI.isNotNull(e.year)&&(t.push(BI.DynamicDateCard.TYPE.YEAR),n.push(this._createValue(BI.DynamicDateCard.TYPE.YEAR,e.year))),BI.isNotNull(e.quarter)&&(t.push(BI.DynamicDateCard.TYPE.QUARTER),n.push(this._createValue(BI.DynamicDateCard.TYPE.QUARTER,e.quarter))),BI.isNotNull(e.month)&&(t.push(BI.DynamicDateCard.TYPE.MONTH),n.push(this._createValue(BI.DynamicDateCard.TYPE.MONTH,e.month))),BI.isNotNull(e.week)&&(t.push(BI.DynamicDateCard.TYPE.WEEK),n.push(this._createValue(BI.DynamicDateCard.TYPE.WEEK,e.week))),BI.isNotNull(e.day)&&(t.push(BI.DynamicDateCard.TYPE.DAY),n.push(this._createValue(BI.DynamicDateCard.TYPE.DAY,e.day))),BI.isNotNull(e.workDay)&&(t.push(BI.DynamicDateCard.TYPE.WORK_DAY),n.push(this._createValue(BI.DynamicDateCard.TYPE.WORK_DAY,e.workDay))),this.checkgroup.setValue(t),this.workDayBox.setSelected(BI.isNotNull(e.workDay)),this.resultPane.populate(this._getParamJson(n,e.position))},_getValue:function(){var e=this,t={},n=this.checkgroup.getValue(),i=this.resultPane.getAllButtons();if(0!==n.length&&BI.each(i,(function(n,i){var r=i.getValue();BI.extend(t,e._digestDateTypeValue(r))})),this.workDayBox.isSelected()){var r=i[0].getValue();t.workDay=0===r.offset?-r.value:+r.value}return t},_getErrorText:function(){var e=this.options,t=BI.parseDateTime(e.min,"%Y-%X-%d"),n=BI.parseDateTime(e.max,"%Y-%X-%d");return BI.i18nText("BI-Basic_Date_Range_Error",t.getFullYear(),t.getMonth()+1,t.getDate(),n.getFullYear(),n.getMonth()+1,n.getDate())},getValue:function(){return this.checkValidation()?this._getValue():{}},getInputValue:function(){return this._getValue()},checkValidation:function(e){var t,n=this.resultPane.getAllButtons(),i=BI.any(n,(function(e,t){return t.checkValidation&&!t.checkValidation()}));return i?t=BI.i18nText("BI-Please_Input_Natural_Number"):(i=!this._checkDate(this._getValue()),t=this._getErrorText()),i&&e&&BI.Bubbles.show("dynamic-date-error",t,this.resultPane),!i}}),BI.shortcut("bi.dynamic_date_card",BI.DynamicDateCard),BI.extend(BI.DynamicDateCard,{TYPE:{YEAR:1,QUARTER:2,MONTH:3,WEEK:4,DAY:5,WORK_DAY:6},OFFSET:{CURRENT:1,BEGIN:2,END:3}})},function(e,t){BI.DynamicDateCombo=BI.inherit(BI.Single,{constants:{popupHeight:259,popupWidth:270,comboAdjustHeight:1,border:1},props:{baseCls:"bi-dynamic-date-combo bi-border bi-focus-shadow bi-border-radius",height:24,minDate:"1900-01-01",maxDate:"2099-12-31",format:"",allowEdit:!0,supportDynamic:!0,attributes:{tabIndex:-1}},_init:function(){var e=this.options;e.height-=2,BI.DynamicDateCombo.superclass._init.apply(this,arguments)},render:function(){var e=this,t=this.options;this.storeTriggerValue="";var n=BI.getDate();return this.storeValue=t.value,{type:"bi.htape",items:[{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button date-change-h-font",width:t.height,height:t.height,ref:function(){e.changeIcon=this}},width:t.height},{type:"bi.absolute",items:[{el:{type:"bi.combo",container:t.container,ref:function(){e.combo=this},toggle:!1,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,destroyWhenHide:!0,el:{type:"bi.dynamic_date_trigger",min:t.minDate,max:t.maxDate,format:t.format,allowEdit:t.allowEdit,watermark:t.watermark,height:t.height,value:t.value,ref:function(){e.trigger=this},listeners:[{eventName:BI.DynamicDateTrigger.EVENT_KEY_DOWN,action:function(){e.combo.isViewVisible()&&e.combo.hideView(),e.fireEvent(BI.DynamicDateCombo.EVENT_KEY_DOWN,arguments)}},{eventName:BI.DynamicDateTrigger.EVENT_STOP,action:function(){e.combo.isViewVisible()||e.combo.showView()}},{eventName:BI.DynamicDateTrigger.EVENT_FOCUS,action:function(){e.storeTriggerValue=e.trigger.getKey(),e.combo.isViewVisible()||e.combo.showView(),e.fireEvent(BI.DynamicDateCombo.EVENT_FOCUS)}},{eventName:BI.DynamicDateTrigger.EVENT_BLUR,action:function(){e.fireEvent(BI.DynamicDateCombo.EVENT_BLUR)}},{eventName:BI.DynamicDateTrigger.EVENT_ERROR,action:function(){e.storeValue={type:BI.DynamicDateCombo.Static,value:{year:n.getFullYear(),month:n.getMonth()+1}},e.fireEvent(BI.DynamicDateCombo.EVENT_ERROR)}},{eventName:BI.DynamicDateTrigger.EVENT_VALID,action:function(){e.fireEvent(BI.DynamicDateCombo.EVENT_VALID)}},{eventName:BI.DynamicDateTrigger.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicDateCombo.EVENT_CHANGE)}},{eventName:BI.DynamicDateTrigger.EVENT_CONFIRM,action:function(){var t=e.storeTriggerValue,n=e.trigger.getKey();e.combo.isViewVisible()||BI.isEqual(n,t)||(BI.isNotEmptyString(n)&&!BI.isEqual(n,t)?(e.storeValue=e.trigger.getValue(),e.setValue(e.trigger.getValue())):BI.isEmptyString(n)&&(e.storeValue=null,e.trigger.setValue()),e._checkDynamicValue(e.storeValue),e.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM))}}]},adjustLength:this.constants.comboAdjustHeight,popup:{el:{type:"bi.dynamic_date_popup",supportDynamic:t.supportDynamic,behaviors:t.behaviors,min:t.minDate,max:t.maxDate,ref:function(){e.popup=this},listeners:[{eventName:BI.DynamicDatePopup.BUTTON_CLEAR_EVENT_CHANGE,action:function(){e.setValue(),e.combo.hideView(),e.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDatePopup.BUTTON_lABEL_EVENT_CHANGE,action:function(){var t=BI.getDate();e.setValue({type:BI.DynamicDateCombo.Static,value:{year:t.getFullYear(),month:t.getMonth()+1,day:t.getDate()}}),e.combo.hideView(),e.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDatePopup.BUTTON_OK_EVENT_CHANGE,action:function(){var t=e.popup.getValue();e._checkValue(t)&&e.setValue(t),e.combo.hideView(),e.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDatePopup.EVENT_CHANGE,action:function(){e.setValue(e.popup.getValue()),e.combo.hideView(),e.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDatePopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,action:function(){e.fireEvent(BI.DynamicDateCombo.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}]},stopPropagation:!1},hideChecker:function(t){return 0===e.triggerBtn.element.find(t.target).length},listeners:[{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){e.popup.setMinDate(t.minDate),e.popup.setMaxDate(t.maxDate),e.popup.setValue(e.storeValue),e.fireEvent(BI.DynamicDateCombo.EVENT_BEFORE_POPUPVIEW)}}]},top:0,left:0,right:0,bottom:0},{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button date-font",width:t.height,height:t.height,listeners:[{eventName:BI.IconButton.EVENT_CHANGE,action:function(){e.combo.isViewVisible()||e.combo.showView()}}],ref:function(){e.triggerBtn=this}},top:0,right:0}]}],ref:function(t){e.comboWrapper=t}}},created:function(){this._checkDynamicValue(this.storeValue)},_checkDynamicValue:function(e){var t=this.options,n=null;switch(BI.isNotNull(e)&&(n=e.type),n){case BI.DynamicDateCombo.Dynamic:this.changeIcon.setVisible(!0),this.comboWrapper.attr("items")[0].width=t.height,this.comboWrapper.resize();break;default:this.comboWrapper.attr("items")[0].width=0,this.comboWrapper.resize(),this.changeIcon.setVisible(!1)}},_checkValue:function(e){var t=this.options;switch(e.type){case BI.DynamicDateCombo.Dynamic:return BI.isNotEmptyObject(e.value);case BI.DynamicDateCombo.Static:var n=e.value||{};return!BI.checkDateVoid(n.year,n.month,n.day,t.minDate,t.maxDate)[0];default:return!0}},_defaultState:function(){},setMinDate:function(e){this.options.minDate=e,this.trigger.setMinDate(e),this.popup&&this.popup.setMinDate(e)},setMaxDate:function(e){this.options.maxDate=e,this.trigger.setMaxDate(e),this.popup&&this.popup.setMaxDate(e)},setValue:function(e){this.storeValue=e,this.trigger.setValue(e),this._checkDynamicValue(e)},getValue:function(){return this.storeValue},getKey:function(){return this.trigger.getKey()},hidePopupView:function(){this.combo.hideView()}}),BI.DynamicDateCombo.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.DynamicDateCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.DynamicDateCombo.EVENT_FOCUS="EVENT_FOCUS",BI.DynamicDateCombo.EVENT_BLUR="EVENT_BLUR",BI.DynamicDateCombo.EVENT_CHANGE="EVENT_CHANGE",BI.DynamicDateCombo.EVENT_VALID="EVENT_VALID",BI.DynamicDateCombo.EVENT_ERROR="EVENT_ERROR",BI.DynamicDateCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.DynamicDateCombo.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW="EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",BI.shortcut("bi.dynamic_date_combo",BI.DynamicDateCombo),BI.extend(BI.DynamicDateCombo,{Static:1,Dynamic:2})},function(e,t){BI.DynamicDateParamItem=BI.inherit(BI.Widget,{props:function(){return{baseCls:"bi-dynamic-date-param-item",dateType:BI.DynamicDateCard.TYPE.YEAR,validationChecker:function(){return!0},value:0,offset:0,height:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT}},render:function(){var e=this,t=this.options;return{type:"bi.htape",items:[{el:{type:"bi.sign_editor",cls:"bi-border",height:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-2,validationChecker:function(e){return BI.isNaturalNumber(e)},value:t.value,ref:function(){e.editor=this},errorText:function(){return BI.i18nText("BI-Please_Input_Natural_Number")},allowBlank:!1,listeners:[{eventName:BI.SignEditor.EVENT_CONFIRM,action:function(){e.fireEvent(BI.DynamicDateParamItem.EVENT_CHANGE)}},{eventName:BI.SignEditor.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicDateParamItem.EVENT_INPUT_CHANGE)}}]},width:60},{el:{type:"bi.label",height:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT,text:this._getText()},width:t.dateType===BI.DynamicDateCard.TYPE.WORK_DAY?60:20},{type:"bi.text_value_combo",height:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT,items:[{text:BI.i18nText("BI-Basic_Front"),value:0},{text:BI.i18nText("BI-Basic_Behind"),value:1}],ref:function(){e.offsetCombo=this},container:null,value:t.offset,listeners:[{eventName:BI.TextValueCombo.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicDateParamItem.EVENT_CHANGE)}}]}]}},_getText:function(){var e="";switch(this.options.dateType){case BI.DynamicDateCard.TYPE.YEAR:e=BI.i18nText("BI-Basic_Year");break;case BI.DynamicDateCard.TYPE.QUARTER:e=BI.i18nText("BI-Basic_Single_Quarter");break;case BI.DynamicDateCard.TYPE.MONTH:e=BI.i18nText("BI-Basic_Month");break;case BI.DynamicDateCard.TYPE.WEEK:e=BI.i18nText("BI-Basic_Week");break;case BI.DynamicDateCard.TYPE.DAY:e=BI.i18nText("BI-Basic_Day");break;case BI.DynamicDateCard.TYPE.WORK_DAY:default:e=BI.i18nText("BI-Basic_Work_Day")}return e},checkValidation:function(){return BI.isNaturalNumber(this.editor.getValue())},setValue:function(e){(e=e||{}).value=e.value||0,e.offset=e.offset||0,this.editor.setValue(e.value),this.offsetCombo.setValue(e.offset)},getValue:function(){return{dateType:this.options.dateType,value:this.editor.getValue(),offset:this.offsetCombo.getValue()[0]}}}),BI.DynamicDateParamItem.EVENT_CHANGE="EVENT_CHANGE",BI.DynamicDateParamItem.EVENT_INPUT_CHANGE="EVENT_INPUT_CHANGE",BI.shortcut("bi.dynamic_date_param_item",BI.DynamicDateParamItem)},function(e,t){BI.DynamicDatePopup=BI.inherit(BI.Widget,{constants:{tabHeight:30},props:{baseCls:"bi-dynamic-date-popup",width:248,supportDynamic:!0},_init:function(){BI.DynamicDatePopup.superclass._init.apply(this,arguments);var e=this,t=this.options;this.constants;this.storeValue={type:BI.DynamicDateCombo.Static},BI.createWidget({element:this,type:"bi.vertical",items:[{el:this._getTabJson()},{el:{type:"bi.grid",items:[[{type:"bi.text_button",cls:"bi-high-light bi-split-top",shadow:!0,text:BI.i18nText("BI-Basic_Clear"),textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicDatePopup.BUTTON_CLEAR_EVENT_CHANGE)}}]},{type:"bi.text_button",cls:"bi-split-left bi-split-right bi-high-light bi-split-top",shadow:!0,textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,text:BI.i18nText("BI-Multi_Date_Today"),disabled:this._checkTodayValid(),ref:function(){e.todayButton=this},listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicDatePopup.BUTTON_lABEL_EVENT_CHANGE)}}]},{type:"bi.text_button",cls:"bi-high-light bi-split-top",textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,shadow:!0,text:BI.i18nText("BI-Basic_OK"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.dateTab.getSelect()===BI.DynamicDateCombo.Dynamic?e.dynamicPane.checkValidation(!0)&&e.fireEvent(BI.DynamicDatePopup.BUTTON_OK_EVENT_CHANGE):e.fireEvent(BI.DynamicDatePopup.BUTTON_OK_EVENT_CHANGE)}}]}]],height:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT}}]}),this.setValue(t.value)},_getTabJson:function(){var e=this,t=this.options;return{type:"bi.tab",logic:{dynamic:!0},ref:function(){e.dateTab=this},tab:{type:"bi.linear_segment",invisible:!t.supportDynamic,cls:"bi-split-bottom",height:this.constants.tabHeight,items:BI.createItems([{text:BI.i18nText("BI-Multi_Date_YMD"),value:BI.DynamicDateCombo.Static},{text:BI.i18nText("BI-Basic_Dynamic_Title"),value:BI.DynamicDateCombo.Dynamic}],{textAlign:"center"})},cardCreator:function(n){switch(n){case BI.DynamicDateCombo.Dynamic:return{type:"bi.dynamic_date_card",cls:"dynamic-date-pane",listeners:[{eventName:"EVENT_CHANGE",action:function(){e._setInnerValue(e.year,n)}}],min:e.options.min,max:e.options.max,ref:function(){e.dynamicPane=this}};case BI.DynamicDateCombo.Static:default:return{type:"bi.date_calendar_popup",behaviors:t.behaviors,min:e.options.min,max:e.options.max,listeners:[{eventName:BI.DateCalendarPopup.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicDatePopup.EVENT_CHANGE)}},{eventName:BI.DateCalendarPopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,action:function(){e.fireEvent(BI.DynamicDatePopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}],ref:function(){e.ymd=this}}}},listeners:[{eventName:BI.Tab.EVENT_CHANGE,action:function(){switch(e.dateTab.getSelect()){case BI.DynamicDateCombo.Static:var t=BI.DynamicDateHelper.getCalculation(e.dynamicPane.getValue());e.ymd.setValue({year:t.getFullYear(),month:t.getMonth()+1,day:t.getDate()}),e._setInnerValue();break;case BI.DynamicDateCombo.Dynamic:default:e.storeValue&&e.storeValue.type===BI.DynamicDateCombo.Dynamic?e.dynamicPane.setValue(e.storeValue.value):e.dynamicPane.setValue({year:0}),e._setInnerValue()}}}]}},_setInnerValue:function(){if(this.dateTab.getSelect()===BI.DynamicDateCombo.Static)this.todayButton.setValue(BI.i18nText("BI-Multi_Date_Today")),this.todayButton.setEnable(!this._checkTodayValid());else{var e=BI.DynamicDateHelper.getCalculation(this.dynamicPane.getInputValue());e=BI.print(e,"%Y-%X-%d"),this.todayButton.setValue(e),this.todayButton.setEnable(!1)}},_checkValueValid:function(e){return BI.isNull(e)||BI.isEmptyObject(e)||BI.isEmptyString(e)},_checkTodayValid:function(){var e=this.options,t=BI.getDate();return!!BI.checkDateVoid(t.getFullYear(),t.getMonth()+1,t.getDate(),e.min,e.max)[0]},setMinDate:function(e){this.options.min!==e&&(this.options.min=e,this.ymd&&this.ymd.setMinDate(e),this.dynamicPane&&this.dynamicPane.setMinDate(e))},setMaxDate:function(e){this.options.max!==e&&(this.options.max=e,this.ymd&&this.ymd.setMaxDate(e),this.dynamicPane&&this.dynamicPane.setMaxDate(e))},setValue:function(e){this.storeValue=e;var t,n;switch(t=(e=e||{}).type||BI.DynamicDateCombo.Static,n=e.value||e,this.dateTab.setSelect(t),t){case BI.DynamicDateCombo.Dynamic:this.dynamicPane.setValue(n),this._setInnerValue();break;case BI.DynamicDateCombo.Static:default:if(this._checkValueValid(n)){var i=BI.getDate();this.ymd.setValue({year:i.getFullYear(),month:i.getMonth()+1,day:i.getDate()}),this.todayButton.setValue(BI.i18nText("BI-Multi_Date_Today"))}else this.ymd.setValue(n),this.todayButton.setValue(BI.i18nText("BI-Multi_Date_Today"));this.todayButton.setEnable(!this._checkTodayValid())}},getValue:function(){return{type:this.dateTab.getSelect(),value:this.dateTab.getValue()}}}),BI.DynamicDatePopup.EVENT_CHANGE="EVENT_CHANGE",BI.DynamicDatePopup.BUTTON_OK_EVENT_CHANGE="BUTTON_OK_EVENT_CHANGE",BI.DynamicDatePopup.BUTTON_lABEL_EVENT_CHANGE="BUTTON_lABEL_EVENT_CHANGE",BI.DynamicDatePopup.BUTTON_CLEAR_EVENT_CHANGE="BUTTON_CLEAR_EVENT_CHANGE",BI.DynamicDatePopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW="EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",BI.shortcut("bi.dynamic_date_popup",BI.DynamicDatePopup)},function(e,t){BI.DynamicDateTrigger=BI.inherit(BI.Trigger,{_const:{hgap:4,vgap:2,yearLength:4,yearMonthLength:6,yearFullMonthLength:7,compareFormat:"%Y-%X-%d"},props:{extraCls:"bi-date-trigger",min:"1900-01-01",max:"2099-12-31",height:24,format:"",allowEdit:!0,watermark:""},_init:function(){BI.DynamicDateTrigger.superclass._init.apply(this,arguments);var e=this,t=this.options,n=this._const;this.storeTriggerValue="",this.editor=BI.createWidget({type:"bi.sign_editor",height:t.height,validationChecker:function(n){var i=e._getStandardDateStr(n),r=i.match(/\d+/g);return!BI.isKey(t.format)&&e._autoAppend(n,r),e._dateCheck(i)&&BI.checkDateLegal(i)&&e._checkVoid({year:0|r[0],month:0|r[1],day:0|r[2]})},quitChecker:function(){return!1},hgap:n.hgap,vgap:n.vgap,allowBlank:!0,watermark:BI.isKey(t.watermark)?t.watermark:BI.i18nText("BI-Basic_Unrestricted"),errorText:function(n){var i="";if(!BI.isKey(t.format))if(e._dateCheck(n)){var r=BI.parseDateTime(t.min,"%Y-%X-%d"),a=BI.parseDateTime(t.max,"%Y-%X-%d");i=BI.i18nText("BI-Basic_Date_Range_Error",r.getFullYear(),r.getMonth()+1,r.getDate(),a.getFullYear(),a.getMonth()+1,a.getDate())}else i=e.editor.isEditing()?BI.i18nText("BI-Date_Trigger_Error_Text"):BI.i18nText("BI-Year_Trigger_Invalid_Text");return i},title:BI.bind(this._getTitle,this)}),this.editor.on(BI.SignEditor.EVENT_KEY_DOWN,(function(){e.fireEvent(BI.DynamicDateTrigger.EVENT_KEY_DOWN,arguments)})),this.editor.on(BI.SignEditor.EVENT_FOCUS,(function(){e.storeTriggerValue=e.getKey(),e.fireEvent(BI.DynamicDateTrigger.EVENT_FOCUS)})),this.editor.on(BI.SignEditor.EVENT_BLUR,(function(){e.fireEvent(BI.DynamicDateTrigger.EVENT_BLUR)})),this.editor.on(BI.SignEditor.EVENT_STOP,(function(){e.fireEvent(BI.DynamicDateTrigger.EVENT_STOP)})),this.editor.on(BI.SignEditor.EVENT_VALID,(function(){e.fireEvent(BI.DynamicDateTrigger.EVENT_VALID)})),this.editor.on(BI.SignEditor.EVENT_ERROR,(function(){e.fireEvent(BI.DynamicDateTrigger.EVENT_ERROR)})),this.editor.on(BI.SignEditor.EVENT_CONFIRM,(function(){var t=e.editor.getValue();if(BI.isNotNull(t)&&e.editor.setState(t),BI.isNotEmptyString(t)&&!BI.isEqual(e.storeTriggerValue,e.getKey())){var n=e._getStandardDateStr(t).match(/\d+/g);e.storeValue={type:BI.DynamicDateCombo.Static,value:{year:0|n[0],month:0|n[1],day:0|n[2]}}}e.fireEvent(BI.DynamicDateTrigger.EVENT_CONFIRM)})),this.editor.on(BI.SignEditor.EVENT_SPACE,(function(){e.editor.isValid()&&e.editor.blur()})),this.editor.on(BI.SignEditor.EVENT_START,(function(){e.fireEvent(BI.DynamicDateTrigger.EVENT_START)})),this.editor.on(BI.SignEditor.EVENT_CHANGE,(function(){e.fireEvent(BI.DynamicDateTrigger.EVENT_CHANGE)})),BI.createWidget({type:"bi.htape",element:this,items:[{el:this.editor},{el:BI.createWidget(),width:24}]}),!t.allowEdit&&BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.text",title:BI.bind(this._getTitle,this)},left:0,right:24,top:0,bottom:0}]}),this.setValue(t.value)},_getTitle:function(){var e=this.storeValue||{},t=e.type||BI.DynamicDateCombo.Static,n=e.value;switch(t){case BI.DynamicDateCombo.Dynamic:var i=this._getText(n),r=BI.getDate();r=BI.DynamicDateHelper.getCalculation(n);var a=BI.print(r,this._getFormatString());return BI.isEmptyString(i)?a:i+":"+a;case BI.DynamicDateCombo.Static:default:return BI.isNull(n)||BI.isNull(n.day)?"":BI.print(BI.getDate(n.year,n.month-1,n.day),this._getFormatString())}},_getStandardDateStr:function(e){var t=this._const,n=[0,1,2],i=this._getFormatString().match(/%./g);BI.each(i,(function(e,t){switch(t){case"%Y":case"%y":n[0]=e;break;case"%X":case"%x":n[1]=e;break;case"%d":case"%e":default:n[2]=e}}));var r=BI.parseDateTime(e,this._getFormatString());BI.print(r,this._getFormatString())===e&&(e=BI.print(r,t.compareFormat),n=[0,1,2]);var a=e.match(/\d+/g),o=[];return BI.each(a,(function(e){o[e]=a[n[e]]})),o.length===n.length&&2===o[0].length?BI.print(BI.parseDateTime(o.join("-"),t.compareFormat),t.compareFormat):o.join("-")},_getFormatString:function(){return this.options.format||this._const.compareFormat},_dateCheck:function(e){return BI.print(BI.parseDateTime(e,"%Y-%x-%d"),"%Y-%x-%d")===e||BI.print(BI.parseDateTime(e,"%Y-%X-%d"),"%Y-%X-%d")===e||BI.print(BI.parseDateTime(e,"%Y-%x-%e"),"%Y-%x-%e")===e||BI.print(BI.parseDateTime(e,"%Y-%X-%e"),"%Y-%X-%e")===e},_checkVoid:function(e){return!BI.checkDateVoid(e.year,e.month,e.day,this.options.min,this.options.max)[0]},_autoAppend:function(e,t){if(BI.isNotNull(t)&&BI.checkDateLegal(e))switch(e.length){case this._const.yearLength:this._yearCheck(e)&&this.editor.setValue(e+"-");break;case this._const.yearMonthLength:case this._const.yearFullMonthLength:var n=e.split("-")[1];(BI.isNotNull(n)&&2===n.length||this._monthCheck(e))&&this.editor.setValue(e+"-")}},_yearCheck:function(e){var t=BI.print(BI.parseDateTime(e,this._getFormatString()),this._const.compareFormat);return BI.print(BI.parseDateTime(e,"%Y"),"%Y")===e&&t>=this.options.min&&t<=this.options.max},_monthCheck:function(e){var t=BI.parseDateTime(e,this._getFormatString()),n=BI.print(t,this._const.compareFormat);return t.getMonth()>=0&&(BI.print(BI.parseDateTime(e,"%Y-%X"),"%Y-%X")===e||BI.print(BI.parseDateTime(e,"%Y-%x"),"%Y-%x")===e)&&n>=this.options.min&&n<=this.options.max},_setInnerValue:function(e){var t=BI.print(e,this._getFormatString());this.editor.setState(t),this.editor.setValue(t)},_getText:function(e){return BI.DynamicDateHelper.getDescription(e)},setValue:function(e){var t,n,i=BI.getDate();switch(this.storeValue=e,BI.isNotNull(e)&&(t=e.type||BI.DynamicDateCombo.Static,n=e.value||e),t){case BI.DynamicDateCombo.Dynamic:var r=this._getText(n);i=BI.DynamicDateHelper.getCalculation(n),this._setInnerValue(i,r);break;case BI.DynamicDateCombo.Static:default:if(BI.isNull(n)||BI.isNull(n.day))this.editor.setState(""),this.editor.setValue("");else{var a=BI.print(BI.getDate(n.year,n.month-1,n.day),this._getFormatString());this.editor.setState(a),this.editor.setValue(a)}}},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e)},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e)},getKey:function(){return this.editor.getValue()},getValue:function(){return this.storeValue}}),BI.DynamicDateTrigger.EVENT_BLUR="EVENT_BLUR",BI.DynamicDateTrigger.EVENT_FOCUS="EVENT_FOCUS",BI.DynamicDateTrigger.EVENT_START="EVENT_START",BI.DynamicDateTrigger.EVENT_STOP="EVENT_STOP",BI.DynamicDateTrigger.EVENT_CONFIRM="EVENT_CONFIRM",BI.DynamicDateTrigger.EVENT_CHANGE="EVENT_CHANGE",BI.DynamicDateTrigger.EVENT_VALID="EVENT_VALID",BI.DynamicDateTrigger.EVENT_ERROR="EVENT_ERROR",BI.DynamicDateTrigger.EVENT_TRIGGER_CLICK="EVENT_TRIGGER_CLICK",BI.DynamicDateTrigger.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.shortcut("bi.dynamic_date_trigger",BI.DynamicDateTrigger)},function(e,t){BI.DynamicDateTimeCombo=BI.inherit(BI.Single,{constants:{popupHeight:259,popupWidth:270,comboAdjustHeight:1,border:1},props:{baseCls:"bi-dynamic-date-combo bi-border bi-focus-shadow bi-border-radius",height:24,minDate:"1900-01-01",maxDate:"2099-12-31",format:"",allowEdit:!0,supportDynamic:!0,attributes:{tabIndex:-1}},_init:function(){var e=this.options;e.height-=2,BI.DynamicDateTimeCombo.superclass._init.apply(this,arguments)},render:function(){var e=this,t=this.options;this.storeTriggerValue="";var n=BI.getDate();return this.storeValue=t.value,{type:"bi.htape",items:[{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button date-change-h-font",width:t.height,height:t.height,ref:function(){e.changeIcon=this}},width:t.height},{type:"bi.absolute",items:[{el:{type:"bi.combo",destroyWhenHide:!0,container:t.container,ref:function(){e.combo=this},toggle:!1,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,el:{type:"bi.dynamic_date_time_trigger",min:t.minDate,max:t.maxDate,allowEdit:t.allowEdit,watermark:t.watermark,format:t.format,height:t.height,value:t.value,ref:function(){e.trigger=this},listeners:[{eventName:BI.DynamicDateTimeTrigger.EVENT_KEY_DOWN,action:function(){e.combo.isViewVisible()&&e.combo.hideView(),e.fireEvent(BI.DynamicDateTimeCombo.EVENT_KEY_DOWN,arguments)}},{eventName:BI.DynamicDateTimeTrigger.EVENT_STOP,action:function(){e.combo.isViewVisible()||e.combo.showView()}},{eventName:BI.DynamicDateTimeTrigger.EVENT_TRIGGER_CLICK,action:function(){e.combo.toggle()}},{eventName:BI.DynamicDateTimeTrigger.EVENT_FOCUS,action:function(){e.storeTriggerValue=e.trigger.getKey(),e.combo.isViewVisible()||e.combo.showView(),e.fireEvent(BI.DynamicDateTimeCombo.EVENT_FOCUS)}},{eventName:BI.DynamicDateTimeTrigger.EVENT_BLUR,action:function(){e.fireEvent(BI.DynamicDateTimeCombo.EVENT_BLUR)}},{eventName:BI.DynamicDateTimeTrigger.EVENT_ERROR,action:function(){e.storeValue={type:BI.DynamicDateTimeCombo.Static,value:{year:n.getFullYear(),month:n.getMonth()+1}},e.fireEvent(BI.DynamicDateTimeCombo.EVENT_ERROR)}},{eventName:BI.DynamicDateTimeTrigger.EVENT_VALID,action:function(){e.fireEvent(BI.DynamicDateTimeCombo.EVENT_VALID)}},{eventName:BI.DynamicDateTimeTrigger.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicDateTimeCombo.EVENT_CHANGE)}},{eventName:BI.DynamicDateTimeTrigger.EVENT_CONFIRM,action:function(){var t=e.storeTriggerValue,n=e.trigger.getKey();e.combo.isViewVisible()||BI.isEqual(n,t)||(BI.isNotEmptyString(n)&&!BI.isEqual(n,t)?(e.storeValue=e.trigger.getValue(),e.setValue(e.trigger.getValue())):BI.isEmptyString(n)&&(e.storeValue=null,e.trigger.setValue()),e._checkDynamicValue(e.storeValue),e.fireEvent(BI.DynamicDateTimeCombo.EVENT_CONFIRM))}}]},adjustLength:this.constants.comboAdjustHeight,popup:{el:{type:"bi.dynamic_date_time_popup",supportDynamic:t.supportDynamic,behaviors:t.behaviors,min:t.minDate,max:t.maxDate,ref:function(){e.popup=this},listeners:[{eventName:BI.DynamicDateTimePopup.BUTTON_CLEAR_EVENT_CHANGE,action:function(){e.setValue(),e.combo.hideView(),e.fireEvent(BI.DynamicDateTimeCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDateTimePopup.BUTTON_lABEL_EVENT_CHANGE,action:function(){var t=BI.getDate();e.setValue({type:BI.DynamicDateTimeCombo.Static,value:{year:t.getFullYear(),month:t.getMonth()+1,day:t.getDate(),hour:0,minute:0,second:0}}),e.combo.hideView(),e.fireEvent(BI.DynamicDateTimeCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDateTimePopup.BUTTON_OK_EVENT_CHANGE,action:function(){var t=e.popup.getValue();e._checkValue(t)&&e.setValue(t),e.combo.hideView(),e.fireEvent(BI.DynamicDateTimeCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDateTimePopup.EVENT_CHANGE,action:function(){e.setValue(e.popup.getValue()),e.combo.hideView(),e.fireEvent(BI.DynamicDateTimeCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDateTimePopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,action:function(){e.fireEvent(BI.DynamicDateTimeCombo.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}]},stopPropagation:!1},listeners:[{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){e.popup.setMinDate(t.minDate),e.popup.setMaxDate(t.maxDate),e.popup.setValue(e.storeValue),e.fireEvent(BI.DynamicDateTimeCombo.EVENT_BEFORE_POPUPVIEW)}}],hideChecker:function(t){return 0===e.triggerBtn.element.find(t.target).length}},top:0,left:0,right:0,bottom:0},{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button date-font",width:t.height,height:t.height,listeners:[{eventName:BI.IconButton.EVENT_CHANGE,action:function(){e.combo.isViewVisible()||e.combo.showView()}}],ref:function(){e.triggerBtn=this}},top:0,right:0}]}],ref:function(t){e.comboWrapper=t}}},created:function(){this._checkDynamicValue(this.storeValue)},_checkDynamicValue:function(e){var t=this.options,n=null;switch(BI.isNotNull(e)&&(n=e.type),n){case BI.DynamicDateTimeCombo.Dynamic:this.changeIcon.setVisible(!0),this.comboWrapper.attr("items")[0].width=t.height,this.comboWrapper.resize();break;default:this.comboWrapper.attr("items")[0].width=0,this.comboWrapper.resize(),this.changeIcon.setVisible(!1)}},_checkValue:function(e){var t=this.options;switch(e.type){case BI.DynamicDateCombo.Dynamic:return BI.isNotEmptyObject(e.value);case BI.DynamicDateCombo.Static:var n=e.value||{};return!BI.checkDateVoid(n.year,n.month,n.day,t.minDate,t.maxDate)[0];default:return!0}},setMinDate:function(e){this.options.minDate=e,this.trigger.setMinDate(e),this.popup&&this.popup.setMinDate(e)},setMaxDate:function(e){this.options.maxDate=e,this.trigger.setMaxDate(e),this.popup&&this.popup.setMaxDate(e)},setValue:function(e){this.storeValue=e,this.trigger.setValue(e),this._checkDynamicValue(e)},getValue:function(){return this.storeValue},getKey:function(){return this.trigger.getKey()},hidePopupView:function(){this.combo.hideView()},isValid:function(){return this.trigger.isValid()}}),BI.DynamicDateTimeCombo.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.DynamicDateTimeCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.DynamicDateTimeCombo.EVENT_FOCUS="EVENT_FOCUS",BI.DynamicDateTimeCombo.EVENT_BLUR="EVENT_BLUR",BI.DynamicDateTimeCombo.EVENT_CHANGE="EVENT_CHANGE",BI.DynamicDateTimeCombo.EVENT_VALID="EVENT_VALID",BI.DynamicDateTimeCombo.EVENT_ERROR="EVENT_ERROR",BI.DynamicDateTimeCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.DynamicDateTimeCombo.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW="EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",BI.shortcut("bi.dynamic_date_time_combo",BI.DynamicDateTimeCombo),BI.extend(BI.DynamicDateTimeCombo,{Static:1,Dynamic:2})},function(e,t){BI.DynamicDateTimePopup=BI.inherit(BI.Widget,{constants:{tabHeight:30,buttonHeight:24},props:{baseCls:"bi-dynamic-date-time-popup",width:248,supportDynamic:!0},_init:function(){BI.DynamicDateTimePopup.superclass._init.apply(this,arguments);var e=this,t=this.options;this.constants;this.storeValue={type:BI.DynamicDateCombo.Static},BI.createWidget({element:this,type:"bi.vertical",items:[{el:this._getTabJson()},{el:{type:"bi.grid",items:[[{type:"bi.text_button",cls:"bi-high-light bi-split-top",textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,shadow:!0,text:BI.i18nText("BI-Basic_Clear"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicDateTimePopup.BUTTON_CLEAR_EVENT_CHANGE)}}]},{type:"bi.text_button",cls:"bi-split-left bi-split-right bi-high-light bi-split-top",textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,shadow:!0,text:BI.i18nText("BI-Multi_Date_Today"),disabled:this._checkTodayValid(),ref:function(){e.todayButton=this},listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicDateTimePopup.BUTTON_lABEL_EVENT_CHANGE)}}]},{type:"bi.text_button",cls:"bi-high-light bi-split-top",textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,shadow:!0,text:BI.i18nText("BI-Basic_OK"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicDateTimePopup.BUTTON_OK_EVENT_CHANGE)}}]}]],height:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT}}]}),this.setValue(t.value)},_getTabJson:function(){var e=this,t=this.options;return{type:"bi.tab",logic:{dynamic:!0},ref:function(){e.dateTab=this},tab:{type:"bi.linear_segment",invisible:!t.supportDynamic,cls:"bi-split-bottom",height:this.constants.tabHeight,items:BI.createItems([{text:BI.i18nText("BI-Multi_Date_YMD"),value:BI.DynamicDateCombo.Static},{text:BI.i18nText("BI-Basic_Dynamic_Title"),value:BI.DynamicDateCombo.Dynamic}],{textAlign:"center"})},cardCreator:function(n){switch(n){case BI.DynamicDateCombo.Dynamic:return{type:"bi.dynamic_date_card",cls:"dynamic-date-pane",listeners:[{eventName:"EVENT_CHANGE",action:function(){e._setInnerValue(e.year,n)}}],ref:function(){e.dynamicPane=this},min:e.options.min,max:e.options.max};case BI.DynamicDateCombo.Static:default:return{type:"bi.vertical",items:[{type:"bi.date_calendar_popup",behaviors:t.behaviors,min:e.options.min,max:e.options.max,ref:function(){e.ymd=this},listeners:[{eventName:BI.DateCalendarPopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,action:function(){e.fireEvent(BI.DynamicDateTimePopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}]},{el:{type:"bi.dynamic_date_time_select",cls:"bi-split-top",ref:function(){e.timeSelect=this},height:40}}]}}},listeners:[{eventName:BI.Tab.EVENT_CHANGE,action:function(){switch(e.dateTab.getSelect()){case BI.DynamicDateCombo.Static:var t=BI.DynamicDateHelper.getCalculation(e.dynamicPane.getValue());e.ymd.setValue({year:t.getFullYear(),month:t.getMonth()+1,day:t.getDate()}),e.timeSelect.setValue(),e._setInnerValue();break;case BI.DynamicDateCombo.Dynamic:default:e.storeValue&&e.storeValue.type===BI.DynamicDateCombo.Dynamic?e.dynamicPane.setValue(e.storeValue.value):e.dynamicPane.setValue({year:0}),e._setInnerValue()}}}]}},_setInnerValue:function(){if(this.dateTab.getSelect()===BI.DynamicDateCombo.Static)this.todayButton.setValue(BI.i18nText("BI-Multi_Date_Today")),this.todayButton.setEnable(!this._checkTodayValid());else{var e=BI.DynamicDateHelper.getCalculation(this.dynamicPane.getInputValue());e=BI.print(e,"%Y-%X-%d"),this.todayButton.setValue(e),this.todayButton.setEnable(!1)}},_checkValueValid:function(e){return BI.isNull(e)||BI.isEmptyObject(e)||BI.isEmptyString(e)},_checkTodayValid:function(){var e=this.options,t=BI.getDate();return!!BI.checkDateVoid(t.getFullYear(),t.getMonth()+1,t.getDate(),e.min,e.max)[0]},setMinDate:function(e){this.options.min!==e&&(this.options.min=e,this.ymd.setMinDate(e))},setMaxDate:function(e){this.options.max!==e&&(this.options.max=e,this.ymd.setMaxDate(e))},setValue:function(e){this.storeValue=e;var t,n;switch(t=(e=e||{}).type||BI.DynamicDateCombo.Static,n=e.value||e,this.dateTab.setSelect(t),t){case BI.DynamicDateCombo.Dynamic:this.dynamicPane.setValue(n),this._setInnerValue();break;case BI.DynamicDateCombo.Static:default:if(this._checkValueValid(n)){var i=BI.getDate();this.ymd.setValue({year:i.getFullYear(),month:i.getMonth()+1,day:i.getDate()}),this.timeSelect.setValue(),this.todayButton.setValue(BI.i18nText("BI-Multi_Date_Today"))}else this.ymd.setValue(n),this.timeSelect.setValue({hour:n.hour,minute:n.minute,second:n.second}),this.todayButton.setValue(BI.i18nText("BI-Multi_Date_Today"));this.todayButton.setEnable(!this._checkTodayValid())}},getValue:function(){var e=this.dateTab.getSelect();return{type:e,value:e===BI.DynamicDateTimeCombo.Static?BI.extend(this.ymd.getValue(),this.timeSelect.getValue()):this.dynamicPane.getValue()}}}),BI.DynamicDateTimePopup.EVENT_CHANGE="EVENT_CHANGE",BI.DynamicDateTimePopup.BUTTON_OK_EVENT_CHANGE="BUTTON_OK_EVENT_CHANGE",BI.DynamicDateTimePopup.BUTTON_lABEL_EVENT_CHANGE="BUTTON_lABEL_EVENT_CHANGE",BI.DynamicDateTimePopup.BUTTON_CLEAR_EVENT_CHANGE="BUTTON_CLEAR_EVENT_CHANGE",BI.DynamicDateTimePopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW="EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",BI.shortcut("bi.dynamic_date_time_popup",BI.DynamicDateTimePopup)},function(e,t){BI.DynamicDateTimeSelect=BI.inherit(BI.Widget,{props:{baseCls:"bi-date-time-select"},render:function(){var e=this;return{type:"bi.center_adapt",items:[{type:"bi.vertical_adapt",items:[{el:{type:"bi.number_editor",ref:function(){e.hour=this},validationChecker:function(e){return BI.isNaturalNumber(e)&&BI.parseInt(e)<24},errorText:function(e){return BI.isNumeric(e)?BI.i18nText("BI-Basic_Input_From_To_Number",'"00-23"'):BI.i18nText("BI-Numerical_Interval_Input_Data")},listeners:[{eventName:BI.SignEditor.EVENT_CONFIRM,action:function(){var t=this.getValue();e._checkHour(t),this.setValue(e._formatValueToDoubleDigit(t)),e.fireEvent(BI.DynamicDateTimeSelect.EVENT_CONFIRM)}},{eventName:BI.SignEditor.EVENT_CHANGE,action:function(){var t=e._autoSwitch(this.getValue(),BI.DynamicDateTimeSelect.HOUR);this.setValue(t)}}],width:60,height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT}},{type:"bi.label",text:":",width:20},{type:"bi.number_editor",ref:function(){e.minute=this},validationChecker:function(e){return BI.isNaturalNumber(e)&&BI.parseInt(e)<60},errorText:function(e){return BI.isNumeric(e)?BI.i18nText("BI-Basic_Input_From_To_Number",'"00-59"'):BI.i18nText("BI-Numerical_Interval_Input_Data")},listeners:[{eventName:BI.SignEditor.EVENT_CONFIRM,action:function(){var t=this.getValue();e._checkMinute(t),this.setValue(e._formatValueToDoubleDigit(t),BI.DynamicDateTimeSelect.MINUTE),e.fireEvent(BI.DynamicDateTimeSelect.EVENT_CONFIRM)}},{eventName:BI.SignEditor.EVENT_CHANGE,action:function(){var t=e._autoSwitch(this.getValue(),BI.DynamicDateTimeSelect.MINUTE);this.setValue(t)}}],width:60,height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT},{type:"bi.label",text:":",width:20},{type:"bi.number_editor",ref:function(){e.second=this},validationChecker:function(e){return BI.isNaturalNumber(e)&&BI.parseInt(e)<60},errorText:function(e){return BI.isNumeric(e)?BI.i18nText("BI-Basic_Input_From_To_Number",'"00-59"'):BI.i18nText("BI-Numerical_Interval_Input_Data")},listeners:[{eventName:BI.SignEditor.EVENT_CONFIRM,action:function(){var t=this.getValue();e._checkSecond(t),this.setValue(e._formatValueToDoubleDigit(t)),e.fireEvent(BI.DynamicDateTimeSelect.EVENT_CONFIRM)}}],width:60,height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT}]}]}},_checkBorder:function(e){e=e||{},this._checkHour(e.hour),this._checkMinute(e.minute),this._checkSecond(e.second)},_checkHour:function(e){this.hour.setDownEnable(BI.parseInt(e)>0),this.hour.setUpEnable(BI.parseInt(e)<23)},_checkMinute:function(e){this.minute.setDownEnable(BI.parseInt(e)>0),this.minute.setUpEnable(BI.parseInt(e)<59)},_checkSecond:function(e){this.second.setDownEnable(BI.parseInt(e)>0),this.second.setUpEnable(BI.parseInt(e)<59)},_autoSwitch:function(e,t){var n=0,i=e+"";switch(t){case BI.DynamicDateTimeSelect.HOUR:n=2;break;case BI.DynamicDateTimeSelect.MINUTE:n=5}if(1===i.length&&BI.parseInt(i)>n&&(i="0"+i),2===i.length)switch(t){case BI.DynamicDateTimeSelect.HOUR:this.hour.isEditing()&&this.minute.focus();break;case BI.DynamicDateTimeSelect.MINUTE:this.minute.isEditing()&&this.second.focus();break;case BI.DynamicDateTimeSelect.SECOND:}return i},_formatValueToDoubleDigit:function(e){(BI.isNull(e)||BI.isEmptyString(e))&&(e=0);var t=BI.parseInt(e);return t<10&&(t="0"+t),t},_assertValue:function(e){return(e=e||{}).hour=this._formatValueToDoubleDigit(e.hour)||"00",e.minute=this._formatValueToDoubleDigit(e.minute)||"00",e.second=this._formatValueToDoubleDigit(e.second)||"00",e},getValue:function(){return{hour:BI.parseInt(this.hour.getValue()),minute:BI.parseInt(this.minute.getValue()),second:BI.parseInt(this.second.getValue())}},setValue:function(e){e=this._assertValue(e),this.hour.setValue(e.hour),this.minute.setValue(e.minute),this.second.setValue(e.second),this._checkBorder(e)}}),BI.DynamicDateTimeSelect.EVENT_CONFIRM="EVENT_CONFIRM",BI.shortcut("bi.dynamic_date_time_select",BI.DynamicDateTimeSelect),BI.extend(BI.DynamicDateTimeSelect,{HOUR:1,MINUTE:2,SECOND:3})},function(e,t){BI.DynamicDateTimeTrigger=BI.inherit(BI.Trigger,{_const:{hgap:4,vgap:2,yearLength:4,yearMonthLength:6,yearFullMonthLength:7,compareFormat:"%Y-%X-%d %H:%M:%S"},props:{extraCls:"bi-date-time-trigger",min:"1900-01-01",max:"2099-12-31",height:24,format:"",allowEdit:!0,watermark:""},_init:function(){BI.DynamicDateTimeTrigger.superclass._init.apply(this,arguments);var e=this,t=this.options,n=this._const;this.storeTriggerValue="",this.editor=BI.createWidget({type:"bi.sign_editor",height:t.height,validationChecker:function(n){var i=e._getStandardDateStr(n),r=i.match(/\d+/g);return!BI.isKey(t.format)&&e._autoAppend(n,r),e._dateCheck(i)&&BI.checkDateLegal(i)&&e._checkVoid({year:0|r[0],month:0|r[1],day:0|r[2]})},quitChecker:function(){return!1},hgap:n.hgap,vgap:n.vgap,allowBlank:!0,watermark:BI.isKey(t.watermark)?t.watermark:BI.i18nText("BI-Basic_Unrestricted"),errorText:function(n){var i="";if(!BI.isKey(t.format))if(e._dateCheck(n)){var r=BI.parseDateTime(t.min,"%Y-%X-%d"),a=BI.parseDateTime(t.max,"%Y-%X-%d");i=BI.i18nText("BI-Basic_Date_Range_Error",r.getFullYear(),r.getMonth()+1,r.getDate(),a.getFullYear(),a.getMonth()+1,a.getDate())}else i=e.editor.isEditing()?BI.i18nText("BI-Date_Trigger_Error_Text"):BI.i18nText("BI-Year_Trigger_Invalid_Text");return i},title:BI.bind(this._getTitle,this)}),this.editor.on(BI.SignEditor.EVENT_KEY_DOWN,(function(){e.fireEvent(BI.DynamicDateTimeTrigger.EVENT_KEY_DOWN,arguments)})),this.editor.on(BI.SignEditor.EVENT_FOCUS,(function(){e.storeTriggerValue=e.getKey(),e.fireEvent(BI.DynamicDateTimeTrigger.EVENT_FOCUS)})),this.editor.on(BI.SignEditor.EVENT_BLUR,(function(){e.fireEvent(BI.DynamicDateTimeTrigger.EVENT_BLUR)})),this.editor.on(BI.SignEditor.EVENT_STOP,(function(){e.fireEvent(BI.DynamicDateTimeTrigger.EVENT_STOP)})),this.editor.on(BI.SignEditor.EVENT_VALID,(function(){e.fireEvent(BI.DynamicDateTimeTrigger.EVENT_VALID)})),this.editor.on(BI.SignEditor.EVENT_ERROR,(function(){e.fireEvent(BI.DynamicDateTimeTrigger.EVENT_ERROR)})),this.editor.on(BI.SignEditor.EVENT_CONFIRM,(function(){var t=e.editor.getValue();if(BI.isNotNull(t)&&e.editor.setState(t),BI.isNotEmptyString(t)&&!BI.isEqual(e.storeTriggerValue,e.getKey())){var n=e._getStandardDateStr(t).match(/\d+/g);e.storeValue={type:BI.DynamicDateCombo.Static,value:{year:0|n[0],month:0|n[1],day:0|n[2],hour:0|n[3],minute:0|n[4],second:0|n[5]}}}e.fireEvent(BI.DynamicDateTimeTrigger.EVENT_CONFIRM)})),this.editor.on(BI.SignEditor.EVENT_START,(function(){e.fireEvent(BI.DynamicDateTimeTrigger.EVENT_START)})),this.editor.on(BI.SignEditor.EVENT_CHANGE,(function(){e.fireEvent(BI.DynamicDateTimeTrigger.EVENT_CHANGE)})),BI.createWidget({type:"bi.htape",element:this,items:[{el:this.editor},{el:BI.createWidget(),width:24}]}),!t.allowEdit&&BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.text",title:BI.bind(this._getTitle,this)},left:0,right:24,top:0,bottom:0}]}),this.setValue(t.value)},_getTitle:function(){var e=this.storeValue||{},t=e.type||BI.DynamicDateCombo.Static,n=e.value;switch(t){case BI.DynamicDateCombo.Dynamic:var i=this._getText(n),r=BI.DynamicDateHelper.getCalculation(n),a=BI.print(r,this._getFormatString());return BI.isEmptyString(i)?a:i+":"+a;case BI.DynamicDateCombo.Static:default:return BI.isNull(n)||BI.isNull(n.day)?"":BI.print(BI.getDate(n.year,n.month-1,n.day,n.hour||0,n.minute||0,n.second||0),this._getFormatString())}},_getStandardDateStr:function(e){var t=this._const,n=[],i=!1,r=this._getFormatString().match(/%./g);BI.each(r,(function(e,t){switch(t){case"%Y":case"%y":n[0]=e;break;case"%X":case"%x":n[1]=e;break;case"%d":case"%e":n[2]=e;break;case"%S":i=!0}}));var a=BI.parseDateTime(e,this._getFormatString());BI.print(a,this._getFormatString())===e&&(e=BI.print(a,t.compareFormat),n=[0,1,2]);var o=e.match(/\d+/g)||[],s=[];BI.each(o.slice(0,3),(function(e){s[e]=o[n[e]]}));var l=o.slice(3);BI.each(l,(function(e,t){BI.isNumeric(t)&&1===t.length&&(l[e]="0"+t)})),2!==l.length||i||l.push("00");var u=l.join(":"),c=s.slice(0,3).join("-");return BI.isNotEmptyString(u)&&(c+=" "+u),c},_getFormatString:function(){return this.options.format||this._const.compareFormat},_dateCheck:function(e){return BI.print(BI.parseDateTime(e,"%Y-%x-%d %H:%M:%S"),"%Y-%x-%d %H:%M:%S")===e||BI.print(BI.parseDateTime(e,"%Y-%X-%d %H:%M:%S"),"%Y-%X-%d %H:%M:%S")===e||BI.print(BI.parseDateTime(e,"%Y-%x-%e %H:%M:%S"),"%Y-%x-%e %H:%M:%S")===e||BI.print(BI.parseDateTime(e,"%Y-%X-%e %H:%M:%S"),"%Y-%X-%e %H:%M:%S")===e||BI.print(BI.parseDateTime(e,"%Y-%x-%d"),"%Y-%x-%d")===e||BI.print(BI.parseDateTime(e,"%Y-%X-%d"),"%Y-%X-%d")===e||BI.print(BI.parseDateTime(e,"%Y-%x-%e"),"%Y-%x-%e")===e||BI.print(BI.parseDateTime(e,"%Y-%X-%e"),"%Y-%X-%e")===e},_checkVoid:function(e){return!BI.checkDateVoid(e.year,e.month,e.day,this.options.min,this.options.max)[0]},_autoAppend:function(e,t){if(BI.isNotNull(t)&&BI.checkDateLegal(e))switch(e.length){case this._const.yearLength:this._yearCheck(e)&&this.editor.setValue(e+"-");break;case this._const.yearMonthLength:case this._const.yearFullMonthLength:var n=e.split("-")[1];(BI.isNotNull(n)&&2===n.length||this._monthCheck(e))&&this.editor.setValue(e+"-")}},_yearCheck:function(e){var t=BI.print(BI.parseDateTime(e,"%Y-%X-%d"),"%Y-%X-%d");return BI.print(BI.parseDateTime(e,"%Y"),"%Y")===e&&t>=this.options.min&&t<=this.options.max},_monthCheck:function(e){var t=BI.parseDateTime(e,"%Y-%X-%d"),n=BI.print(t,"%Y-%X-%d");return t.getMonth()>0&&(BI.print(BI.parseDateTime(e,"%Y-%X"),"%Y-%X")===e||BI.print(BI.parseDateTime(e,"%Y-%x"),"%Y-%x")===e)&&n>=this.options.min&&n<=this.options.max},_setInnerValue:function(e){var t=BI.print(e,this._getFormatString());this.editor.setState(t),this.editor.setValue(t)},_getText:function(e){var t="",n="";return BI.isNotNull(e.year)&&(0!==BI.parseInt(e.year)&&(t+=Math.abs(e.year)+BI.i18nText("BI-Basic_Year")+(e.year<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),n=i(BI.i18nText("BI-Basic_Year"),e.position)),BI.isNotNull(e.quarter)&&(0!==BI.parseInt(e.quarter)&&(t+=Math.abs(e.quarter)+BI.i18nText("BI-Basic_Single_Quarter")+(e.quarter<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),n=i(BI.i18nText("BI-Basic_Single_Quarter"),e.position)),BI.isNotNull(e.month)&&(0!==BI.parseInt(e.month)&&(t+=Math.abs(e.month)+BI.i18nText("BI-Basic_Month")+(e.month<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),n=i(BI.i18nText("BI-Basic_Month"),e.position)),BI.isNotNull(e.week)&&(0!==BI.parseInt(e.week)&&(t+=Math.abs(e.week)+BI.i18nText("BI-Basic_Week")+(e.week<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),n=i(BI.i18nText("BI-Basic_Week"),e.position)),BI.isNotNull(e.day)&&(0!==BI.parseInt(e.day)&&(t+=Math.abs(e.day)+BI.i18nText("BI-Basic_Day")+(e.day<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),n=1===BI.size(e)?i(BI.i18nText("BI-Basic_Month"),e.position):""),BI.isNotNull(e.workDay)&&0!==BI.parseInt(e.workDay)&&(t+=Math.abs(e.workDay)+BI.i18nText("BI-Basic_Work_Day")+(e.workDay<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),t+n;function i(e,t){switch(t){case BI.DynamicDateCard.OFFSET.BEGIN:return e+BI.i18nText("BI-Basic_Begin_Start");case BI.DynamicDateCard.OFFSET.END:return e+BI.i18nText("BI-Basic_End_Stop");case BI.DynamicDateCard.OFFSET.CURRENT:default:return BI.i18nText("BI-Basic_Current_Day")}}},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e)},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e)},setValue:function(e){var t,n,i=BI.getDate();switch(this.storeValue=e,BI.isNotNull(e)&&(t=e.type||BI.DynamicDateCombo.Static,n=e.value||e),t){case BI.DynamicDateCombo.Dynamic:var r=this._getText(n);i=BI.DynamicDateHelper.getCalculation(n),this._setInnerValue(i,r);break;case BI.DynamicDateCombo.Static:default:if(BI.isNull(n)||BI.isNull(n.day))this.editor.setState(""),this.editor.setValue("");else{var a=BI.print(BI.getDate(n.year,n.month-1,n.day,n.hour||0,n.minute||0,n.second||0),this._getFormatString());this.editor.setState(a),this.editor.setValue(a)}}},getKey:function(){return this.editor.getValue()},getValue:function(){return this.storeValue},isValid:function(){return this.editor.isValid()}}),BI.DynamicDateTimeTrigger.EVENT_BLUR="EVENT_BLUR",BI.DynamicDateTimeTrigger.EVENT_FOCUS="EVENT_FOCUS",BI.DynamicDateTimeTrigger.EVENT_START="EVENT_START",BI.DynamicDateTimeTrigger.EVENT_STOP="EVENT_STOP",BI.DynamicDateTimeTrigger.EVENT_CONFIRM="EVENT_CONFIRM",BI.DynamicDateTimeTrigger.EVENT_CHANGE="EVENT_CHANGE",BI.DynamicDateTimeTrigger.EVENT_VALID="EVENT_VALID",BI.DynamicDateTimeTrigger.EVENT_ERROR="EVENT_ERROR",BI.DynamicDateTimeTrigger.EVENT_TRIGGER_CLICK="EVENT_TRIGGER_CLICK",BI.DynamicDateTimeTrigger.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.shortcut("bi.dynamic_date_time_trigger",BI.DynamicDateTimeTrigger)},function(e,t){BI.SearchEditor=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.SearchEditor.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:"bi-search-editor bi-border bi-focus-shadow",height:24,errorText:"",watermark:BI.i18nText("BI-Basic_Search"),validationChecker:BI.emptyFn,quitChecker:BI.emptyFn})},_init:function(){this.options.height-=2,BI.SearchEditor.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget(t.el,{type:"bi.editor",height:t.height,watermark:t.watermark,allowBlank:!0,hgap:1,errorText:t.errorText,validationChecker:t.validationChecker,quitChecker:t.quitChecker,value:t.value}),this.clear=BI.createWidget({type:"bi.icon_button",stopEvent:!0,cls:"close-font"}),this.clear.on(BI.IconButton.EVENT_CHANGE,(function(){e.setValue(""),e.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.STOPEDIT,e.getValue()),e.fireEvent(BI.SearchEditor.EVENT_CHANGE),e.fireEvent(BI.SearchEditor.EVENT_CLEAR)})),BI.createWidget({element:this,type:"bi.htape",items:[{el:{type:"bi.icon_label",cls:"search-font"},width:24},{el:e.editor},{el:this.clear,width:24}]}),this.editor.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.editor.on(BI.Editor.EVENT_FOCUS,(function(){e.fireEvent(BI.SearchEditor.EVENT_FOCUS)})),this.editor.on(BI.Editor.EVENT_BLUR,(function(){e.fireEvent(BI.SearchEditor.EVENT_BLUR)})),this.editor.on(BI.Editor.EVENT_CLICK,(function(){e.fireEvent(BI.SearchEditor.EVENT_CLICK)})),this.editor.on(BI.Editor.EVENT_CHANGE,(function(){e._checkClear(),e.fireEvent(BI.SearchEditor.EVENT_CHANGE)})),this.editor.on(BI.Editor.EVENT_KEY_DOWN,(function(t){e.fireEvent(BI.SearchEditor.EVENT_KEY_DOWN,t)})),this.editor.on(BI.Editor.EVENT_SPACE,(function(){e.fireEvent(BI.SearchEditor.EVENT_SPACE)})),this.editor.on(BI.Editor.EVENT_BACKSPACE,(function(){e.fireEvent(BI.SearchEditor.EVENT_BACKSPACE)})),this.editor.on(BI.Editor.EVENT_VALID,(function(){e.fireEvent(BI.SearchEditor.EVENT_VALID)})),this.editor.on(BI.Editor.EVENT_ERROR,(function(){e.fireEvent(BI.SearchEditor.EVENT_ERROR)})),this.editor.on(BI.Editor.EVENT_ENTER,(function(){e.fireEvent(BI.SearchEditor.EVENT_ENTER)})),this.editor.on(BI.Editor.EVENT_RESTRICT,(function(){e.fireEvent(BI.SearchEditor.EVENT_RESTRICT)})),this.editor.on(BI.Editor.EVENT_EMPTY,(function(){e._checkClear(),e.fireEvent(BI.SearchEditor.EVENT_EMPTY)})),this.editor.on(BI.Editor.EVENT_REMOVE,(function(){e.fireEvent(BI.SearchEditor.EVENT_REMOVE)})),this.editor.on(BI.Editor.EVENT_CONFIRM,(function(){e.fireEvent(BI.SearchEditor.EVENT_CONFIRM)})),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,(function(){e.fireEvent(BI.SearchEditor.EVENT_CHANGE_CONFIRM)})),this.editor.on(BI.Editor.EVENT_START,(function(){e.fireEvent(BI.SearchEditor.EVENT_START)})),this.editor.on(BI.Editor.EVENT_PAUSE,(function(){e.fireEvent(BI.SearchEditor.EVENT_PAUSE)})),this.editor.on(BI.Editor.EVENT_STOP,(function(){e.fireEvent(BI.SearchEditor.EVENT_STOP)})),this.clear.invisible()},_checkClear:function(){this.getValue()?this.clear.visible():this.clear.invisible()},setWaterMark:function(e){this.options.watermark=e,this.editor.setWaterMark(e)},focus:function(){this.editor.focus()},blur:function(){this.editor.blur()},getValue:function(){if(this.isValid())return this.editor.getValue()},getKeywords:function(){var e=this.editor.getLastChangedValue(),t=e.match(/[\S]+/g);return BI.isEndWithBlank(e)?t.concat([" "]):t},getLastValidValue:function(){return this.editor.getLastValidValue()},getLastChangedValue:function(){return this.editor.getLastChangedValue()},setValue:function(e){this.editor.setValue(e),BI.isKey(e)&&this.clear.visible()},isEditing:function(){return this.editor.isEditing()},isValid:function(){return this.editor.isValid()},showClearIcon:function(){this.clear.visible()},hideClearIcon:function(){this.clear.invisible()}}),BI.SearchEditor.EVENT_CHANGE="EVENT_CHANGE",BI.SearchEditor.EVENT_FOCUS="EVENT_FOCUS",BI.SearchEditor.EVENT_BLUR="EVENT_BLUR",BI.SearchEditor.EVENT_CLICK="EVENT_CLICK",BI.SearchEditor.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.SearchEditor.EVENT_SPACE="EVENT_SPACE",BI.SearchEditor.EVENT_BACKSPACE="EVENT_BACKSPACE",BI.SearchEditor.EVENT_CLEAR="EVENT_CLEAR",BI.SearchEditor.EVENT_START="EVENT_START",BI.SearchEditor.EVENT_PAUSE="EVENT_PAUSE",BI.SearchEditor.EVENT_STOP="EVENT_STOP",BI.SearchEditor.EVENT_CONFIRM="EVENT_CONFIRM",BI.SearchEditor.EVENT_CHANGE_CONFIRM="EVENT_CHANGE_CONFIRM",BI.SearchEditor.EVENT_VALID="EVENT_VALID",BI.SearchEditor.EVENT_ERROR="EVENT_ERROR",BI.SearchEditor.EVENT_ENTER="EVENT_ENTER",BI.SearchEditor.EVENT_RESTRICT="EVENT_RESTRICT",BI.SearchEditor.EVENT_REMOVE="EVENT_REMOVE",BI.SearchEditor.EVENT_EMPTY="EVENT_EMPTY",BI.shortcut("bi.search_editor",BI.SearchEditor)},function(e,t){BI.SmallSearchEditor=BI.inherit(BI.SearchEditor,{_defaultConfig:function(){var e=BI.SmallSearchEditor.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-small-search-editor",height:20})},_init:function(){BI.SmallSearchEditor.superclass._init.apply(this,arguments)}}),BI.shortcut("bi.small_search_editor",BI.SmallSearchEditor)},function(e,t){BI.TextEditor=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.TextEditor.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-text-editor bi-border bi-focus-shadow",hgap:4,vgap:2,lgap:0,rgap:0,tgap:0,bgap:0,validationChecker:BI.emptyFn,quitChecker:BI.emptyFn,allowBlank:!1,watermark:"",errorText:"",height:24})},_init:function(){BI.TextEditor.superclass._init.apply(this,arguments);var e=this,t=this.options;BI.isNumber(t.height)&&this.element.css({height:t.height-2}),BI.isNumber(t.width)&&this.element.css({width:t.width-2}),this.editor=BI.createWidget({type:"bi.editor",height:t.height-2,hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap,value:t.value,title:t.title,tipType:t.tipType,validationChecker:t.validationChecker,quitChecker:t.quitChecker,allowBlank:t.allowBlank,watermark:t.watermark,errorText:t.errorText}),this.editor.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.editor.on(BI.Editor.EVENT_FOCUS,(function(){e.fireEvent(BI.TextEditor.EVENT_FOCUS)})),this.editor.on(BI.Editor.EVENT_BLUR,(function(){e.fireEvent(BI.TextEditor.EVENT_BLUR)})),this.editor.on(BI.Editor.EVENT_CLICK,(function(){e.fireEvent(BI.TextEditor.EVENT_CLICK)})),this.editor.on(BI.Editor.EVENT_CHANGE,(function(){e.fireEvent(BI.TextEditor.EVENT_CHANGE)})),this.editor.on(BI.Editor.EVENT_KEY_DOWN,(function(t){e.fireEvent(BI.TextEditor.EVENT_KEY_DOWN)})),this.editor.on(BI.Editor.EVENT_SPACE,(function(t){e.fireEvent(BI.TextEditor.EVENT_SPACE)})),this.editor.on(BI.Editor.EVENT_BACKSPACE,(function(t){e.fireEvent(BI.TextEditor.EVENT_BACKSPACE)})),this.editor.on(BI.Editor.EVENT_VALID,(function(){e.fireEvent(BI.TextEditor.EVENT_VALID)})),this.editor.on(BI.Editor.EVENT_CONFIRM,(function(){e.fireEvent(BI.TextEditor.EVENT_CONFIRM)})),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,(function(){e.fireEvent(BI.TextEditor.EVENT_CHANGE_CONFIRM)})),this.editor.on(BI.Editor.EVENT_REMOVE,(function(t){e.fireEvent(BI.TextEditor.EVENT_REMOVE)})),this.editor.on(BI.Editor.EVENT_START,(function(){e.fireEvent(BI.TextEditor.EVENT_START)})),this.editor.on(BI.Editor.EVENT_PAUSE,(function(){e.fireEvent(BI.TextEditor.EVENT_PAUSE)})),this.editor.on(BI.Editor.EVENT_STOP,(function(){e.fireEvent(BI.TextEditor.EVENT_STOP)})),this.editor.on(BI.Editor.EVENT_ERROR,(function(){e.fireEvent(BI.TextEditor.EVENT_ERROR,arguments)})),this.editor.on(BI.Editor.EVENT_ENTER,(function(){e.fireEvent(BI.TextEditor.EVENT_ENTER)})),this.editor.on(BI.Editor.EVENT_RESTRICT,(function(){e.fireEvent(BI.TextEditor.EVENT_RESTRICT)})),this.editor.on(BI.Editor.EVENT_EMPTY,(function(){e.fireEvent(BI.TextEditor.EVENT_EMPTY)})),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[this.editor]})},setWaterMark:function(e){this.options.watermark=e,this.editor.setWaterMark(e)},focus:function(){this.editor.focus()},blur:function(){this.editor.blur()},setErrorText:function(e){this.editor.setErrorText(e)},getErrorText:function(){return this.editor.getErrorText()},isValid:function(){return this.editor.isValid()},setValue:function(e){this.editor.setValue(e)},getValue:function(){return this.editor.getValue()}}),BI.TextEditor.EVENT_CHANGE="EVENT_CHANGE",BI.TextEditor.EVENT_FOCUS="EVENT_FOCUS",BI.TextEditor.EVENT_BLUR="EVENT_BLUR",BI.TextEditor.EVENT_CLICK="EVENT_CLICK",BI.TextEditor.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.TextEditor.EVENT_SPACE="EVENT_SPACE",BI.TextEditor.EVENT_BACKSPACE="EVENT_BACKSPACE",BI.TextEditor.EVENT_START="EVENT_START",BI.TextEditor.EVENT_PAUSE="EVENT_PAUSE",BI.TextEditor.EVENT_STOP="EVENT_STOP",BI.TextEditor.EVENT_CONFIRM="EVENT_CONFIRM",BI.TextEditor.EVENT_CHANGE_CONFIRM="EVENT_CHANGE_CONFIRM",BI.TextEditor.EVENT_VALID="EVENT_VALID",BI.TextEditor.EVENT_ERROR="EVENT_ERROR",BI.TextEditor.EVENT_ENTER="EVENT_ENTER",BI.TextEditor.EVENT_RESTRICT="EVENT_RESTRICT",BI.TextEditor.EVENT_REMOVE="EVENT_REMOVE",BI.TextEditor.EVENT_EMPTY="EVENT_EMPTY",BI.shortcut("bi.text_editor",BI.TextEditor)},function(e,t){BI.SmallTextEditor=BI.inherit(BI.TextEditor,{_defaultConfig:function(){var e=BI.SmallTextEditor.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-small-text-editor",height:20})},_init:function(){BI.SmallTextEditor.superclass._init.apply(this,arguments)}}),BI.shortcut("bi.small_text_editor",BI.SmallTextEditor)},function(e,t){BI.IntervalSlider=BI.inherit(BI.Single,{_constant:{EDITOR_WIDTH:58,EDITOR_R_GAP:60,EDITOR_HEIGHT:30,SLIDER_WIDTH_HALF:15,SLIDER_WIDTH:30,SLIDER_HEIGHT:30,TRACK_HEIGHT:24},props:{baseCls:"bi-interval-slider bi-slider-track",digit:!1,unit:""},render:function(){var e=this,t=this._constant;return this.enable=!1,this.valueOne="",this.valueTwo="",this.calculation=new BI.AccurateCalculationModel,this.grayTrack=BI.createWidget({type:"bi.layout",cls:"gray-track",height:6}),this.blueTrack=BI.createWidget({type:"bi.layout",cls:"blue-track bi-high-light-background",height:6}),this.track=this._createTrackWrapper(),this.labelOne=BI.createWidget({type:"bi.sign_text_editor",cls:"slider-editor-button",text:this.options.unit,allowBlank:!1,width:t.EDITOR_WIDTH,validationChecker:function(t){return e._checkValidation(t)}}),this.labelOne.element.hover((function(){e.labelOne.element.removeClass("bi-border").addClass("bi-border")}),(function(){e.labelOne.element.removeClass("bi-border")})),this.labelOne.on(BI.Editor.EVENT_CONFIRM,(function(){var t=e.valueOne,n=BI.parseFloat(this.getValue());e.valueOne=n;var i=e._getPercentByValue(n),r=BI.parseFloat(i.toFixed(1));e._setSliderOnePosition(r),e._setBlueTrack(),e._checkLabelPosition(t,e.valueTwo,e.valueOne,e.valueTwo),e.fireEvent(BI.IntervalSlider.EVENT_CHANGE)})),this.labelTwo=BI.createWidget({type:"bi.sign_text_editor",cls:"slider-editor-button",text:this.options.unit,allowBlank:!1,width:t.EDITOR_WIDTH,validationChecker:function(t){return e._checkValidation(t)}}),this.labelTwo.element.hover((function(){e.labelTwo.element.removeClass("bi-border").addClass("bi-border")}),(function(){e.labelTwo.element.removeClass("bi-border")})),this.labelTwo.on(BI.Editor.EVENT_CONFIRM,(function(){var t=e.valueTwo,n=BI.parseFloat(this.getValue());e.valueTwo=n;var i=e._getPercentByValue(n),r=BI.parseFloat(i.toFixed(1));e._setSliderTwoPosition(r),e._setBlueTrack(),e._checkLabelPosition(e.valueOne,t,e.valueOne,e.valueTwo),e.fireEvent(BI.IntervalSlider.EVENT_CHANGE)})),this.sliderOne=BI.createWidget({type:"bi.single_slider_button"}),this.sliderTwo=BI.createWidget({type:"bi.single_slider_button"}),this._draggable(this.sliderOne,!0),this._draggable(this.sliderTwo,!1),this._setVisible(!1),{type:"bi.absolute",element:this,items:[{el:{type:"bi.vertical",items:[{type:"bi.absolute",items:[{el:this.track,width:"100%",height:t.TRACK_HEIGHT}]}],hgap:7,height:t.TRACK_HEIGHT},top:23,left:0,width:"100%"},this._createLabelWrapper(),this._createSliderWrapper()]}},_rePosBySizeAfterMove:function(e,t){var n=this.options,i=100*e/this._getGrayTrackLength(),r=BI.parseFloat(i.toFixed(1)),a=this._getValueByPercent(r);a=this._assertValue(a),a=!1===n.digit?a:a.toFixed(n.digit);var o=this.valueOne,s=this.valueTwo;t?(this._setSliderOnePosition(r),this.labelOne.setValue(a),this.valueOne=a,this._checkLabelPosition(o,s,a,this.valueTwo)):(this._setSliderTwoPosition(r),this.labelTwo.setValue(a),this.valueTwo=a,this._checkLabelPosition(o,s,this.valueOne,a)),this._setBlueTrack()},_rePosBySizeAfterStop:function(e,t){var n=100*e/this._getGrayTrackLength(),i=BI.parseFloat(n.toFixed(1));t?this._setSliderOnePosition(i):this._setSliderTwoPosition(i)},_draggable:function(e,t){var n=this,i=(this.options,!1),r=0,a=0,o=0,s=new BI.MouseMoveTracker((function(u){s.isDragging()&&(i=!0,r=l(o+(a+=u)),e.element.addClass("dragging"),n._rePosBySizeAfterMove(r,t))}),(function(){!0===i&&(r=l(r),n._rePosBySizeAfterStop(r,t),a=0,o=r=0,i=!1),e.element.removeClass("dragging"),s.releaseMouseMoves(),n.fireEvent(BI.IntervalSlider.EVENT_CHANGE)}),window);function l(e){return BI.clamp(e,0,n._getGrayTrackLength())}e.element.on("mousedown",(function(t){e.isEnabled()&&(l(o=this.offsetLeft),s.captureMouseMoves(t))}))},_createLabelWrapper:function(){var e=this._constant;return{el:{type:"bi.vertical",items:[{type:"bi.absolute",items:[{el:this.labelOne,top:0,left:"0%"}]},{type:"bi.absolute",items:[{el:this.labelTwo,top:0,left:"100%"}]}],rgap:e.EDITOR_R_GAP,height:e.SLIDER_HEIGHT},top:0,left:0,width:"100%"}},_createSliderWrapper:function(){var e=this._constant;return{el:{type:"bi.vertical",items:[{type:"bi.absolute",items:[{el:this.sliderOne,top:0,left:"0%"}]},{type:"bi.absolute",items:[{el:this.sliderTwo,top:0,left:"100%"}]}],hgap:e.SLIDER_WIDTH_HALF,height:e.SLIDER_HEIGHT},top:20,left:0,width:"100%"}},_createTrackWrapper:function(){return BI.createWidget({type:"bi.absolute",items:[{el:{type:"bi.vertical",items:[{type:"bi.absolute",items:[{el:this.grayTrack,top:0,left:0,width:"100%"},{el:this.blueTrack,top:0,left:0,width:"0%"}]}],hgap:8,height:8},top:8,left:0,width:"100%"}]})},_checkValidation:function(e){var t=this.options,n=!1,i=(e+"").split(".")[1];return BI.isEmptyString(i)||BI.isNumeric(e)&&!(BI.isNull(e)||e<this.min||e>this.max)&&(n=!(!1!==t.digit&&!BI.isInteger(e))||(i=i||"").length===t.digit),n},_checkOverlap:function(){var e=this.labelOne.element[0].offsetLeft,t=this.labelTwo.element[0].offsetLeft;e<=t?t-e<90?this.labelTwo.element.css({top:40}):this.labelTwo.element.css({top:0}):e-t<90?this.labelTwo.element.css({top:40}):this.labelTwo.element.css({top:0})},_checkLabelPosition:function(e,t,n,i,r){if(e=BI.parseFloat(e),t=BI.parseFloat(t),n=BI.parseFloat(n),i=BI.parseFloat(i),e<=t&&n>i||e>=t&&n<i){var a=BI.parseFloat(this.labelOne.getValue())<BI.parseFloat(this.labelTwo.getValue());this._resetLabelPosition(!a)}},_resetLabelPosition:function(e){this.labelOne.element.css({left:e?"100%":"0%"}),this.labelTwo.element.css({left:e?"0%":"100%"})},_setSliderOnePosition:function(e){this.sliderOne.element.css({left:e+"%"})},_setSliderTwoPosition:function(e){this.sliderTwo.element.css({left:e+"%"})},_setBlueTrackLeft:function(e){this.blueTrack.element.css({left:e+"%"})},_setBlueTrackWidth:function(e){this.blueTrack.element.css({width:e+"%"})},_setBlueTrack:function(){var e=this._getPercentByValue(this.labelOne.getValue()),t=this._getPercentByValue(this.labelTwo.getValue());e<=t?(this._setBlueTrackLeft(e),this._setBlueTrackWidth(t-e)):(this._setBlueTrackLeft(t),this._setBlueTrackWidth(e-t))},_setAllPosition:function(e,t){this._setSliderOnePosition(e),this._setSliderTwoPosition(t),this._setBlueTrack()},_setVisible:function(e){this.sliderOne.setVisible(e),this.sliderTwo.setVisible(e),this.labelOne.setVisible(e),this.labelTwo.setVisible(e)},_setErrorText:function(){var e=BI.i18nText("BI-Basic_Please_Enter_Number_Between",this.min,this.max);this.labelOne.setErrorText(e),this.labelTwo.setErrorText(e)},_getGrayTrackLength:function(){return this.grayTrack.element[0].scrollWidth},_getValueByPercent:function(e){if(0===e)return this.min;if(100===e)return this.max;var t=this.calculation.accurateSubtraction(this.max,this.min),n=this.calculation.accurateMultiplication(t,e),i=this.calculation.accurateDivisionTenExponent(n,2);if(this.precision<0){var r=BI.parseFloat(this.calculation.accurateAddition(i,this.min)),a=Math.round(this.calculation.accurateDivisionTenExponent(r,-this.precision));return this.calculation.accurateMultiplication(a,Math.pow(10,-this.precision))}return BI.parseFloat(this.calculation.accurateAddition(i,this.min).toFixed(this.precision))},_getPercentByValue:function(e){return 100*(e-this.min)/(this.max-this.min)},_getPrecision:function(){var e=this.calculation.accurateSubtraction(this.max,this.min).toPrecision(4),t=[];return e.indexOf("e")>-1?(t=e.split("e"),BI.size(t[0].split(".")[1])-BI.parseInt(t[1].substring(1))):(t=e.split(".")).length>1?t[1].length:0},_assertValue:function(e){return e<=this.min?this.min:e>=this.max?this.max:e},_setEnable:function(e){BI.IntervalSlider.superclass._setEnable.apply(this,[e]),e?this.blueTrack.element.removeClass("disabled-blue-track").addClass("blue-track"):this.blueTrack.element.removeClass("blue-track").addClass("disabled-blue-track")},getValue:function(){return this.valueOne<=this.valueTwo?{min:this.valueOne,max:this.valueTwo}:{min:this.valueTwo,max:this.valueOne}},setMinAndMax:function(e){var t=BI.parseFloat(e.min),n=BI.parseFloat(e.max);!isNaN(t)&&!isNaN(n)&&n>=t&&(this.min=t,this.max=n,this.valueOne=t,this.valueTwo=n,this.precision=this._getPrecision(),this.setEnable(!0)),n===t&&this.setEnable(!1)},setValue:function(e){var t=this.options,n=BI.parseFloat(e.min),i=BI.parseFloat(e.max);n=!1===t.digit?n:BI.parseFloat(n.toFixed(t.digit)),i=!1===t.digit?i:BI.parseFloat(i.toFixed(t.digit)),isNaN(n)||isNaN(i)||(this._checkValidation(n)&&(this.valueOne=this.valueOne<=this.valueTwo?n:i),this._checkValidation(i)&&(this.valueTwo=this.valueOne<=this.valueTwo?i:n),n<this.min&&(this.valueOne=this.min),i>this.max&&(this.valueTwo=this.max))},reset:function(){this._setVisible(!1),this.enable=!1,this.valueOne="",this.valueTwo="",this.min=NaN,this.max=NaN,this._setBlueTrackWidth(0)},populate:function(){var e=this.options;isNaN(this.min)||isNaN(this.max)||(this.enable=!0,this._setVisible(!0),this._setErrorText(),(BI.isNumeric(this.valueOne)||BI.isNotEmptyString(this.valueOne))&&(BI.isNumeric(this.valueTwo)||BI.isNotEmptyString(this.valueTwo))?(this.labelOne.setValue(!1===e.digit?this.valueOne:BI.parseFloat(this.valueOne).toFixed(e.digit)),this.labelTwo.setValue(!1===e.digit?this.valueTwo:BI.parseFloat(this.valueTwo).toFixed(e.digit)),this._setAllPosition(this._getPercentByValue(this.valueOne),this._getPercentByValue(this.valueTwo))):(this.labelOne.setValue(this.min),this.labelTwo.setValue(this.max),this._setAllPosition(0,100)),this._resetLabelPosition(this.valueOne>this.valueTwo))}}),BI.IntervalSlider.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.interval_slider",BI.IntervalSlider)},function(e,t){BI.AccurateCalculationModel=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.AccurateCalculationModel.superclass._defaultConfig.apply(this,arguments),{baseCls:""})},_init:function(){BI.AccurateCalculationModel.superclass._init.apply(this,arguments)},_getMagnitude:function(e){for(var t="1",n=0;n<e;n++)t+="0";return BI.parseInt(t)},_formatDecimal:function(e,t){if(e.numDecimalLength!==t.numDecimalLength){var n=e.numDecimalLength-t.numDecimalLength;if(n>0)var i=t;else{i=e;n=0-n}for(var r=0;r<n;r++)"0"===i.numDecimal&&0===r||(i.numDecimal+="0")}},_stringNumberFactory:function(e){var t=e.toString().split("."),n=t[0];if(1===t.length)var i="0",r=0;else i=t[1],r=t[1].length;return{numInteger:n,numDecimal:i,numDecimalLength:r}},_accurateSubtraction:function(e,t){var n=this._stringNumberFactory(e),i=this._stringNumberFactory(t),r=BI.parseInt(n.numInteger)-BI.parseInt(i.numInteger);this._formatDecimal(n,i);var a=function(e,t){if(e.numDecimal.length>=t.numDecimal.length)return e.numDecimal.length;return t.numDecimal.length}(n,i);if(BI.parseInt(n.numDecimal)>=BI.parseInt(i.numDecimal))var o=l((BI.parseInt(n.numDecimal)-BI.parseInt(i.numDecimal)).toString(),a);else{r--;o=l((this._getMagnitude(a)+BI.parseInt(n.numDecimal)-BI.parseInt(i.numDecimal)).toString(),a)}var s=r+"."+o;return BI.parseFloat(s);function l(e,t){for(var n=t-e.length,i=0;i<n;i++)e="0"+e;return e}},_accurateAddition:function(e,t){var n=this._stringNumberFactory(e),i=this._stringNumberFactory(t),r=BI.parseInt(n.numInteger)+BI.parseInt(i.numInteger);this._formatDecimal(n,i);var a=(BI.parseInt(n.numDecimal)+BI.parseInt(i.numDecimal)).toString();"0"!==a&&(a.length<=n.numDecimal.length?a=function(e,t){for(var n=t-e.length,i=0;i<n;i++)e="0"+e;return e}(a,n.numDecimal.length):(r++,a=a.slice(1)));var o=r+"."+a;return BI.parseFloat(o)},_accurateMultiplication:function(e,t){var n=this._stringNumberFactory(e),i=this._stringNumberFactory(t),r=BI.parseInt(n.numInteger)*BI.parseInt(i.numInteger),a=this._accurateDivisionTenExponent(BI.parseInt(n.numDecimal)*BI.parseInt(i.numInteger),n.numDecimalLength),o=this._accurateDivisionTenExponent(BI.parseInt(n.numInteger)*BI.parseInt(i.numDecimal),i.numDecimalLength),s=this._accurateDivisionTenExponent(BI.parseInt(n.numDecimal)*BI.parseInt(i.numDecimal),n.numDecimalLength+i.numDecimalLength);return this._accurateAddition(this._accurateAddition(this._accurateAddition(r,a),o),s)},_accurateDivisionTenExponent:function(e,t){var n=this._stringNumberFactory(e);if(n.numInteger.length>t)var i=n.numInteger.slice(0,n.numInteger.length-t),r=n.numInteger.slice(-t);else i="0",r=function(e,t){for(var n=t-e.length,i=0;i<n;i++)e="0"+e;return e}(n.numInteger,t);var a=i+"."+r+n.numDecimal;return BI.parseFloat(a)},accurateSubtraction:function(e,t){return e>=0&&t>=0?e>=t?this._accurateSubtraction(e,t):-this._accurateSubtraction(t,e):e>=0&&t<0?this._accurateAddition(e,-t):e<0&&t>=0?-this._accurateAddition(-e,t):e<0&&t<0?e>=t?this._accurateSubtraction(-t,-e):this._accurateSubtraction(-e,-t):void 0},accurateAddition:function(e,t){return e>=0&&t>=0?this._accurateAddition(e,t):e>=0&&t<0?this.accurateSubtraction(e,-t):e<0&&t>=0?this.accurateSubtraction(t,-e):e<0&&t<0?-this._accurateAddition(-e,-t):void 0},accurateMultiplication:function(e,t){return e>=0&&t>=0?this._accurateMultiplication(e,t):e>=0&&t<0?-this._accurateMultiplication(e,-t):e<0&&t>=0?-this._accurateMultiplication(-e,t):e<0&&t<0?this._accurateMultiplication(-e,-t):void 0},accurateDivisionTenExponent:function(e,t){return e>=0?this._accurateDivisionTenExponent(e,t):-this._accurateDivisionTenExponent(-e,t)}})},function(e,t){BI.MultiLayerDownListCombo=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiLayerDownListCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multilayer-down-list-combo",height:24,items:[],adjustLength:0,direction:"bottom",trigger:"click",container:null,stopPropagation:!1,el:{}})},_init:function(){BI.MultiLayerDownListCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;this.popupview=BI.createWidget({type:"bi.multi_layer_down_list_popup",items:t.items,chooseType:t.chooseType,value:t.value}),this.popupview.on(BI.MultiLayerDownListPopup.EVENT_CHANGE,(function(t){e.fireEvent(BI.MultiLayerDownListCombo.EVENT_CHANGE,t),e.downlistcombo.hideView()})),this.popupview.on(BI.MultiLayerDownListPopup.EVENT_SON_VALUE_CHANGE,(function(t,n){e.fireEvent(BI.MultiLayerDownListCombo.EVENT_SON_VALUE_CHANGE,t,n),e.downlistcombo.hideView()})),this.downlistcombo=BI.createWidget({element:this,type:"bi.combo",trigger:t.trigger,isNeedAdjustWidth:!1,container:t.container,adjustLength:t.adjustLength,direction:t.direction,stopPropagation:t.stopPropagation,el:BI.createWidget(t.el,{type:"bi.icon_trigger",extraCls:t.iconCls?t.iconCls:"pull-down-font",width:t.width,height:t.height}),popup:{el:this.popupview,stopPropagation:t.stopPropagation,maxHeight:1e3}}),this.downlistcombo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){e.fireEvent(BI.MultiLayerDownListCombo.EVENT_BEFORE_POPUPVIEW)}))},hideView:function(){this.downlistcombo.hideView()},showView:function(e){this.downlistcombo.showView(e)},populate:function(e){this.popupview.populate(e)},setValue:function(e){this.popupview.setValue(e)},getValue:function(){return this.popupview.getValue()}}),BI.MultiLayerDownListCombo.EVENT_CHANGE="EVENT_CHANGE",BI.MultiLayerDownListCombo.EVENT_SON_VALUE_CHANGE="EVENT_SON_VALUE_CHANGE",BI.MultiLayerDownListCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.multi_layer_down_list_combo",BI.MultiLayerDownListCombo)},function(e,t){BI.MultiLayerDownListPopup=BI.inherit(BI.Pane,{constants:{nextIcon:"pull-right-e-font",height:25,iconHeight:12,iconWidth:12,hgap:0,vgap:0,border:1},_defaultConfig:function(){var e=BI.MultiLayerDownListPopup.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:"bi-down-list-popup",items:[],chooseType:BI.Selection.Multi})},_init:function(){BI.MultiLayerDownListPopup.superclass._init.apply(this,arguments),this.singleValues=[],this.childValueMap={},this.fatherValueMap={};var e=this,t=this.options,n=this._createPopupItems(t.items);this.popup=BI.createWidget({type:"bi.button_tree",items:BI.createItems(n,{},{adjustLength:-2}),layouts:[{type:"bi.vertical",hgap:this.constants.hgap,vgap:this.constants.vgap}],value:this._digest(t.value),chooseType:t.chooseType}),this.popup.on(BI.ButtonTree.EVENT_CHANGE,(function(t,n){var i=t;if(BI.isNotNull(e.childValueMap[t])){i=e.childValueMap[t];var r=e.fatherValueMap[t],a=(r+"").split("_");e.fireEvent(BI.MultiLayerDownListPopup.EVENT_SON_VALUE_CHANGE,i,a.length>1?a:r)}else e.fireEvent(BI.MultiLayerDownListPopup.EVENT_CHANGE,i,n);if(!BI.contains(e.singleValues,i)){var o=e.getValue(),s=[];BI.each(o,(function(e,t){t.value!=i&&s.push(t)})),e.setValue(s)}})),BI.createWidget({type:"bi.vertical",element:this,items:[this.popup],vgap:5})},_createPopupItems:function(e){var t=this,n=[];return BI.each(e,(function(i,r){var a={type:"bi.down_list_group",items:[]};if(BI.each(r,(function(e,n){BI.isNotEmptyArray(n.children)&&!BI.isEmpty(n.el)?(n.type="bi.combo_group",n.cls="down-list-group",n.trigger="hover",n.isNeedAdjustWidth=!1,n.el.title=n.el.title||n.el.text,n.el.type="bi.down_list_group_item",n.el.logic={dynamic:!0},n.el.height=n.el.height||t.constants.height,n.el.iconCls2=t.constants.nextIcon,n.popup={lgap:1,el:{type:"bi.button_tree",chooseType:0,layouts:[{type:"bi.vertical"}]},innerVGap:5},t._createChildren(n)):(n.type=n.type||"bi.down_list_item",n.title=n.title||n.text,n.textRgap=10,n.isNeedAdjustWidth=!1,n.logic={dynamic:!0});var i={};i.el=n,a.items.push(i)})),t._isGroup(a.items)&&BI.each(a.items,(function(e,n){t.singleValues.push(n.el.value)})),n.push(a),t._needSpliter(i,e.length)){var o=BI.createWidget({type:"bi.vertical",items:[{el:{type:"bi.layout",cls:"bi-down-list-spliter bi-border-top cursor-pointer",height:0}}],cls:"bi-down-list-spliter-container cursor-pointer",vgap:5,lgap:10});n.push(o)}})),n},_createChildren:function(e){var t=this;this._formatEL(e).el.childValues=[],BI.each(e.children,(function(n,i){i=i.el?BI.extend(i.el,{children:i.children}):i;var r=BI.deepClone(t._formatEL(e).el.value),a=BI.deepClone(i.value);t.singleValues.push(i.value),i.type=i.type||"bi.down_list_item",i.extraCls=" child-down-list-item",i.title=i.title||i.text,i.textRgap=10,i.isNeedAdjustWidth=!1,i.logic={dynamic:!0},i.father=r,t.fatherValueMap[t._createChildValue(r,a)]=r,t.childValueMap[t._createChildValue(r,a)]=a,i.value=t._createChildValue(r,a),t._formatEL(e).el.childValues.push(i.value),BI.isNotEmptyArray(i.children)&&(i.type="bi.down_list_group_item",i.iconCls2=t.constants.nextIcon,i.height=i.height||t.constants.height,t._createChildren(i))}))},_formatEL:function(e){return e&&e.el?e:{el:e}},_isGroup:function(e){return e.length>1},_needSpliter:function(e,t){return e<t-1},_createChildValue:function(e,t){var n=e;return BI.isArray(e)&&(n=e.join("_")),n+"_"+t},_digest:function(e){var t=this,n=[];return BI.each(e,(function(e,i){var r;r=BI.isNotNull(i.childValue)?t._createChildValue(i.value,i.childValue):i.value,n.push(r)})),n},_checkValues:function(e){var t=this.options,n=[];return BI.each(t.items,(function(t,r){BI.each(r,(function(r,a){if(BI.isNotNull(a.children)){var o=function(e,t){var n="";return BI.some(e,(function(e,i){return BI.some(t,(function(e,t){if(i===t)return n=i,!0}))})),n}(i(a),e[t]);BI.isNotEmptyString(o)&&n.push(o)}else a.value===e[t][0]&&n.push(e[t][0])}))})),n;function i(e){var t=[];return BI.isNotNull(e.children)?BI.each(e.children,(function(e,n){t=BI.concat(t,i(n))})):t.push(e.value),t}},populate:function(e){BI.MultiLayerDownListPopup.superclass.populate.apply(this,arguments);var t=this;t.childValueMap={},t.fatherValueMap={},t.singleValues=[];var n=t._createPopupItems(e),i=BI.createItems(n,{},{adjustLength:-2});t.popup.populate(i)},setValue:function(e){this.popup.setValue(this._digest(e))},_getValue:function(){var e=[];return BI.each(this.popup.getAllButtons(),(function(t,n){t%2==0&&e.push(n.getValue())})),e},getValue:function(){var e=this,t=[],n=this._checkValues(this._getValue());return BI.each(n,(function(n,i){var r={};if(BI.isNotNull(e.childValueMap[i])){var a=e.fatherValueMap[i];r.childValue=e.childValueMap[i];var o=(a+"").split("_");r.value=o.length>1?o:a}else r.value=i;t.push(r)})),t}}),BI.MultiLayerDownListPopup.EVENT_CHANGE="EVENT_CHANGE",BI.MultiLayerDownListPopup.EVENT_SON_VALUE_CHANGE="EVENT_SON_VALUE_CHANGE",BI.shortcut("bi.multi_layer_down_list_popup",BI.MultiLayerDownListPopup)},function(e,t){BI.MultiLayerSelectTreeCombo=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiLayerSelectTreeCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multilayer-select-tree-combo",isDefaultInit:!1,height:24,text:"",itemsCreator:BI.emptyFn,items:[],value:"",allowEdit:!1,allowSearchValue:!1,allowInsertValue:!1,isNeedAdjustWidth:!0})},_init:function(){var e=this.options;this._shouldWrapper()&&(e.height-=2,BI.isNumeric(e.width)&&(e.width-=2)),BI.MultiLayerSelectTreeCombo.superclass._init.apply(this,arguments)},render:function(){var e=this,t=this.options,n=t.itemsCreator===BI.emptyFn?this._getSyncConfig():this._getAsyncConfig();return this._shouldWrapper()?n:{type:"bi.absolute",items:[{el:n,left:0,right:0,top:0,bottom:0},{el:{type:"bi.trigger_icon_button",cls:"trigger-icon-button",ref:function(t){e.triggerBtn=t},width:t.height,height:t.height,handler:function(){e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()}},right:0,bottom:0,top:0}]}},_shouldWrapper:function(){var e=this.options;return!e.allowEdit&&e.itemsCreator===BI.emptyFn},_getBaseConfig:function(){var e=this,t=this.options;return{type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",container:t.container,destroyWhenHide:t.destroyWhenHide,adjustLength:2,ref:function(t){e.combo=t},popup:{el:{type:"bi.multilayer_select_tree_popup",isDefaultInit:t.isDefaultInit,itemsCreator:t.itemsCreator,items:t.items,ref:function(t){e.trigger&&e.trigger.getSearcher().setAdapter(t)},listeners:[{eventName:BI.MultiLayerSelectTreePopup.EVENT_CHANGE,action:function(){e.setValue(this.getValue()),e.combo.hideView(),e.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_CHANGE)}}],onLoaded:function(){BI.nextTick((function(){e.combo.adjustWidth(),e.combo.adjustHeight()}))}},value:t.value,maxHeight:400,maxWidth:t.isNeedAdjustWidth?"auto":500,minHeight:240},isNeedAdjustWidth:t.isNeedAdjustWidth,listeners:[{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){e.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_BEFORE_POPUPVIEW)}}]}},_getSearchConfig:function(){var e=this,t=this.options;return{el:{type:"bi.multilayer_select_tree_trigger",container:t.container,allowInsertValue:t.allowInsertValue,allowSearchValue:t.allowSearchValue,allowEdit:t.allowEdit,cls:"multilayer-select-tree-trigger",ref:function(t){e.trigger=t},items:t.items,itemsCreator:t.itemsCreator,valueFormatter:t.valueFormatter,watermark:t.watermark,height:t.height-2,text:t.text,value:t.value,tipType:t.tipType,warningTitle:t.warningTitle,title:t.title,listeners:[{eventName:BI.MultiLayerSelectTreeTrigger.EVENT_CHANGE,action:function(){e.setValue(this.getValue()),e.combo.hideView(),e.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_CHANGE)}},{eventName:BI.MultiLayerSelectTreeTrigger.EVENT_FOCUS,action:function(){e.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_FOCUS)}},{eventName:BI.MultiLayerSelectTreeTrigger.EVENT_BLUR,action:function(){e.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_BLUR)}},{eventName:BI.MultiLayerSelectTreeTrigger.EVENT_SEARCHING,action:function(){e.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_SEARCHING)}},{eventName:BI.MultiLayerSelectTreeTrigger.EVENT_ADD_ITEM,action:function(){var t=e.trigger.getSearcher().getKeyword();e.combo.setValue([t]),e.combo.hideView()}}]},toggle:!t.allowEdit,hideChecker:function(n){return!(t.container&&e.trigger.getSearcher().isSearching()&&e.trigger.getSearcher().getView().element.find(n.target).length>0)&&0===e.triggerBtn.element.find(n.target).length},listeners:[{eventName:BI.Combo.EVENT_AFTER_HIDEVIEW,action:function(){e.trigger.stopEditing()}},{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){e.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_BEFORE_POPUPVIEW)}}]}},_getSyncConfig:function(){var e=this.options,t=this,n=this._getBaseConfig();return BI.extend(n,e.allowEdit?this._getSearchConfig():{el:{type:"bi.single_tree_trigger",ref:function(e){t.textTrigger=e},text:e.text,height:e.height,items:e.items,value:e.value}})},_getAsyncConfig:function(){var e=this._getBaseConfig();return BI.extend(e,this._getSearchConfig())},setValue:function(e){e=BI.isArray(e)?e:[e],this.combo.setValue(e)},getValue:function(){return this.combo.getValue()},getSearcher:function(){return this.trigger?this.trigger.getSearcher():this.textTrigger.getTextor()},populate:function(e){this.combo.populate(e)}}),BI.MultiLayerSelectTreeCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiLayerSelectTreeCombo.EVENT_BLUR="EVENT_BLUR",BI.MultiLayerSelectTreeCombo.EVENT_FOCUS="EVENT_FOCUS",BI.MultiLayerSelectTreeCombo.EVENT_CHANGE="EVENT_CHANGE",BI.MultiLayerSelectTreeCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.multilayer_select_tree_combo",BI.MultiLayerSelectTreeCombo)},function(e,t){BI.MultiLayerSelectTreeInsertSearchPane=BI.inherit(BI.Widget,{props:function(){return{baseCls:"bi-multilayer-select-tree-popup",tipText:BI.i18nText("BI-No_Selected_Item"),isDefaultInit:!1,itemsCreator:BI.emptyFn,items:[],value:""}},render:function(){var e=this,t=this.options;return this.tree=BI.createWidget({type:"bi.multilayer_select_level_tree",isDefaultInit:t.isDefaultInit,items:t.items,itemsCreator:t.itemsCreator===BI.emptyFn?BI.emptyFn:function(n,i){t.itemsCreator(n,(function(n){i(n),e.setKeyword(t.keywordGetter())}))},keywordGetter:t.keywordGetter,value:t.value,scrollable:null,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}},{eventName:BI.MultiLayerSelectLevelTree.EVENT_CHANGE,action:function(){e.fireEvent(BI.MultiLayerSelectTreeInsertSearchPane.EVENT_CHANGE)}}]}),{type:"bi.vertical",scrolly:!1,scrollable:!0,vgap:5,items:[{type:"bi.text_button",invisible:!0,text:BI.i18nText("BI-Basic_Click_To_Add_Text",""),height:24,cls:"bi-high-light",hgap:5,ref:function(t){e.addNotMatchTip=t},handler:function(){e.fireEvent(BI.MultiLayerSelectTreeInsertSearchPane.EVENT_ADD_ITEM,t.keywordGetter())}},this.tree]}},setKeyword:function(e){var t=BI.isEmptyArray(this.tree.getAllLeaves());this.addNotMatchTip.setVisible(t),t&&this.addNotMatchTip.setText(BI.i18nText("BI-Basic_Click_To_Add_Text",e))},getValue:function(){return this.tree.getValue()},setValue:function(e){e=BI.isArray(e)?e:[e],this.tree.setValue(e)},populate:function(e){this.tree.populate(e)}}),BI.MultiLayerSelectTreeInsertSearchPane.EVENT_ADD_ITEM="EVENT_ADD_ITEM",BI.MultiLayerSelectTreeInsertSearchPane.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multilayer_select_tree_insert_search_pane",BI.MultiLayerSelectTreeInsertSearchPane)},function(e,t){BI.MultiLayerSelectLevelTree=BI.inherit(BI.Pane,{_defaultConfig:function(){return BI.extend(BI.MultiLayerSelectLevelTree.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multilayer-select-level-tree",isDefaultInit:!1,items:[],itemsCreator:BI.emptyFn,keywordGetter:BI.emptyFn,value:"",scrollable:!0})},_init:function(){var e=this.options;BI.MultiLayerSelectLevelTree.superclass._init.apply(this,arguments),this.storeValue=e.value,this.initTree(this.options.items),this.check()},_formatItems:function(e,t,n){var i=this,r=this.options.keywordGetter();return BI.each(e,(function(a,o){var s={isFirstNode:0===a,isLastNode:a===e.length-1};o.layer=t,BI.isKey(o.id)||(o.id=BI.UUID()),o.keyword=o.keyword||r,s.pNode=n,!0===o.isParent||!0===o.parent||BI.isNotEmptyArray(o.children)?(0===t&&s.isFirstNode&&s.isLastNode?s.type="bi.multilayer_select_tree_plus_group_node":0===t&&s.isFirstNode?s.type="bi.multilayer_select_tree_first_plus_group_node":s.isLastNode?s.type="bi.multilayer_select_tree_last_plus_group_node":s.type="bi.multilayer_select_tree_mid_plus_group_node",BI.defaults(o,s),i._formatItems(o.children,t+1,o)):(0===t&&s.isFirstNode&&s.isLastNode?s.type="bi.root_tree_leaf_item":0===t&&s.isFirstNode?s.type="bi.multilayer_single_tree_first_tree_leaf_item":s.isLastNode?s.type="bi.multilayer_single_tree_last_tree_leaf_item":s.type="bi.multilayer_single_tree_mid_tree_leaf_item",BI.defaults(o,s))})),e},_assertId:function(e){BI.each(e,(function(e,t){t.id=t.id||BI.UUID()}))},initTree:function(e){var t=this,n=this.options,i=!1;this.empty(),this._assertId(e),this.tree=BI.createWidget({type:"bi.custom_tree",cls:"tree-view display-table",expander:{type:"bi.tree_expander",selectable:!0,isDefaultInit:n.isDefaultInit,el:{},popup:{type:"bi.custom_tree"}},items:this._formatItems(BI.Tree.transformToTreeFormat(e),0),itemsCreator:function(e,r){1===e.times&&!e.node&&BI.nextTick((function(){t.loading()})),n.itemsCreator(e,(function(n){i=n.hasNext,1===e.times&&!e.node&&t._populate(n.items),r(t._formatItems(BI.Tree.transformToTreeFormat(n.items),e.node?e.node.layer+1:0,e.node)),t.setValue(t.storeValue),1===e.times&&!e.node&&BI.nextTick((function(){t.loaded()}))}))},value:n.value,el:{type:"bi.loader",isDefaultInit:n.itemsCreator!==BI.emptyFn,el:{type:"bi.button_tree",chooseType:n.chooseType===BI.Selection.None?BI.Selection.None:BI.Selection.Default,behaviors:n.behaviors,layouts:[{type:"bi.vertical"}]},hasNext:function(){return i}}}),this.tree.on(BI.Controller.EVENT_CHANGE,(function(e,n){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&(t.setValue(n),t.fireEvent(BI.MultiLayerSelectLevelTree.EVENT_CHANGE,arguments))})),BI.createWidget({type:"bi.adaptive",element:this,scrollable:n.scrollable,items:[this.tree]})},_populate:function(){BI.MultiLayerSelectLevelTree.superclass.populate.apply(this,arguments)},populate:function(e){this._populate(e),BI.isNull(e)?this.tree.populate():this.tree.populate(this._formatItems(BI.Tree.transformToTreeFormat(e),0))},setValue:function(e){this.options.chooseType===BI.Selection.None||(this.storeValue=e,this.tree.setValue(e))},getValue:function(){return BI.isArray(this.storeValue)?this.storeValue:BI.isNull(this.storeValue)?[]:[this.storeValue]},getAllLeaves:function(){return this.tree.getAllLeaves()},getNodeById:function(e){return this.tree.getNodeById(e)},getNodeByValue:function(e){return this.tree.getNodeByValue(e)}}),BI.MultiLayerSelectLevelTree.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multilayer_select_level_tree",BI.MultiLayerSelectLevelTree)},function(e,t){BI.MultiLayerSelectTreePopup=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiLayerSelectTreePopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multilayer-select-tree-popup",tipText:BI.i18nText("BI-No_Selected_Item"),isDefaultInit:!1,itemsCreator:BI.emptyFn,items:[],value:"",onLoaded:BI.emptyFn,minHeight:240})},_init:function(){BI.MultiLayerSelectTreePopup.superclass._init.apply(this,arguments);var e=this,t=this.options;this.tree=BI.createWidget({type:"bi.multilayer_select_level_tree",isDefaultInit:t.isDefaultInit,items:t.items,itemsCreator:t.itemsCreator,keywordGetter:t.keywordGetter,value:t.value,scrollable:null,onLoaded:function(){e.tree.check(),t.onLoaded()}}),BI.createWidget({type:"bi.vertical",scrolly:!1,scrollable:!0,element:this,vgap:5,items:[this.tree]}),this.tree.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.tree.on(BI.MultiLayerSelectLevelTree.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiLayerSelectTreePopup.EVENT_CHANGE)})),this.tree.css("min-height",t.minHeight-10)},getValue:function(){return this.tree.getValue()},setValue:function(e){e=BI.isArray(e)?e:[e],this.tree.setValue(e)},populate:function(e){this.tree.populate(e)}}),BI.MultiLayerSelectTreePopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multilayer_select_tree_popup",BI.MultiLayerSelectTreePopup)},function(e,t){BI.MultiLayerSelectTreeTrigger=BI.inherit(BI.Trigger,{props:function(){return{extraCls:"bi-multi-layer-select-tree-trigger",height:24,itemsCreator:BI.emptyFn,watermark:BI.i18nText("BI-Basic_Search"),allowSearchValue:!1,title:BI.bind(this._getShowText,this)}},render:function(){var e=this,t=this.options;t.itemsCreator===BI.emptyFn&&this._initData();var n={type:"bi.htape",items:[{el:{type:"bi.searcher",ref:function(){e.searcher=this},masker:BI.isNotNull(t.container)?{offset:{},container:t.container}:{offset:{}},isAutoSearch:!1,el:{type:"bi.state_editor",ref:function(){e.editor=this},defaultText:t.text,text:this._digest(t.value),value:t.value,height:t.height,tipText:"",watermark:t.watermark,listeners:[{eventName:BI.StateEditor.EVENT_FOCUS,action:function(){e.fireEvent(BI.MultiLayerSelectTreeTrigger.EVENT_FOCUS)}},{eventName:BI.StateEditor.EVENT_BLUR,action:function(){e.fireEvent(BI.MultiLayerSelectTreeTrigger.EVENT_BLUR)}},{eventName:BI.StateEditor.EVENT_CHANGE,action:function(){e.fireEvent(BI.MultiLayerSelectTreeTrigger.EVENT_SEARCHING)}}]},popup:{type:t.allowInsertValue?"bi.multilayer_select_tree_insert_search_pane":"bi.multilayer_select_tree_popup",itemsCreator:t.itemsCreator===BI.emptyFn?BI.emptyFn:function(n,i){n.keyword=e.editor.getValue(),t.itemsCreator(n,i)},keywordGetter:function(){return e.editor.getValue()},cls:"bi-card",listeners:[{eventName:BI.MultiLayerSelectTreeInsertSearchPane.EVENT_ADD_ITEM,action:function(){e.options.text=e.getSearcher().getKeyword(),e.fireEvent(BI.MultiLayerSelectTreeTrigger.EVENT_ADD_ITEM)}}],ref:function(t){e.popup=t}},onSearch:function(n,i){var r=n.keyword;t.itemsCreator===BI.emptyFn?(i(e._getSearchItems(r)),t.allowInsertValue&&e.popup.setKeyword(r)):i()},listeners:[{eventName:BI.Searcher.EVENT_CHANGE,action:function(){e.fireEvent(BI.MultiLayerSelectTreeTrigger.EVENT_CHANGE)}}]}},{el:{type:"bi.layout",width:24},width:24}]};return t.allowEdit?n:{type:"bi.absolute",items:[{el:n,left:0,right:0,top:0,bottom:0},{el:{type:"bi.layout"},left:0,right:24,top:0,bottom:0}]}},_initData:function(){var e=this.options;this.tree=new BI.Tree,this.nodes=BI.Tree.treeFormat(BI.deepClone(e.items)),this.tree.initTree(this.nodes)},_getSearchItems:function(e){var t=this,n=this.options,i=[];return this.tree.traverse((function(r){var a=BI.Func.getSearchResult(t.tree.isRoot(r)?[]:BI.concat([r.text],n.allowSearchValue?[r.value]:[]),e);if(a.find.length>0||a.match.length>0)return i.push(r),!0})),this._fillTreeStructure4Search(i,"id")},_createJson:function(e,t){return{id:e.id,pId:e.pId,text:e.text,value:e.value,isParent:BI.isNotEmptyArray(e.children),open:t}},_getChildren:function(e){var t=this;e.children=e.children||[];var n=[];return BI.each(e.children,(function(e,i){var r=t._getChildren(i);n=n.concat(r)})),e.children.concat(n)},_fillTreeStructure4Search:function(e){var t=this,n=[],i=[];for(BI.each(e,(function(e,r){i.push({pId:r.pId}),n.push(r),n=n.concat(t._getChildren(r))}));BI.isNotEmptyArray(i);){var r=i.pop(),a=this.tree.search(this.tree.getRoot(),r.pId,"id");null!=a&&(a.open=!0,i.push({pId:a.pId}),n.push(a))}return BI.uniqBy(BI.map(n,(function(e,n){return t._createJson(n,n.open)})),"id")},_digest:function(e){var t=this.options;if(BI.isFunction(t.valueFormatter))return t.valueFormatter(e);if(t.itemsCreator===BI.emptyFn){var n=BI.find(t.items,(function(t,n){return n.value===e}));return BI.isNotNull(n)?n.text:t.text}return e},_getShowText:function(){return this.editor.getText()},stopEditing:function(){this.searcher.stopSearch()},getSearcher:function(){return this.searcher},populate:function(e){this.options.items=e,this._initData(e)},setValue:function(e){this.editor.setState(this._digest(e[0]))},getValue:function(){return this.searcher.getValue()}}),BI.MultiLayerSelectTreeTrigger.EVENT_FOCUS="EVENT_FOCUS",BI.MultiLayerSelectTreeTrigger.EVENT_BLUR="EVENT_BLUR",BI.MultiLayerSelectTreeTrigger.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiLayerSelectTreeTrigger.EVENT_STOP="EVENT_STOP",BI.MultiLayerSelectTreeTrigger.EVENT_START="EVENT_START",BI.MultiLayerSelectTreeTrigger.EVENT_CHANGE="EVENT_CHANGE",BI.MultiLayerSelectTreeTrigger.EVENT_ADD_ITEM="EVENT_ADD_ITEM",BI.shortcut("bi.multilayer_select_tree_trigger",BI.MultiLayerSelectTreeTrigger)},function(e,t){BI.MultiLayerSelectTreeFirstPlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.MultiLayerSelectTreeFirstPlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-multilayer-select-tree-first-plus-group-node bi-list-item-active",layer:0,id:"",pId:"",readonly:!0,open:!1,height:24})},_init:function(){BI.MultiLayerSelectTreeFirstPlusGroupNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.node=BI.createWidget({type:"bi.select_tree_first_plus_group_node",cls:"bi-list-item-none",stopPropagation:!0,logic:{dynamic:!0},id:t.id,pId:t.pId,keyword:t.keyword,open:t.open,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py}),this.node.on(BI.Controller.EVENT_CHANGE,(function(t){e.setSelected(e.isSelected()),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}));var n=[];n.push({el:this.node,lgap:12*t.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(t.layer,12),items:n})},isOnce:function(){return!0},doRedMark:function(){this.node.doRedMark.apply(this.node,arguments)},unRedMark:function(){this.node.unRedMark.apply(this.node,arguments)},isSelected:function(){return this.node.isSelected()},setSelected:function(e){BI.MultiLayerSelectTreeFirstPlusGroupNode.superclass.setSelected.apply(this,arguments),this.node.setSelected(e)},doClick:function(){BI.NodeButton.superclass.doClick.apply(this,arguments),this.node.setSelected(this.isSelected())},setOpened:function(e){BI.MultiLayerSelectTreeFirstPlusGroupNode.superclass.setOpened.apply(this,arguments),this.node.setOpened(e)}}),BI.shortcut("bi.multilayer_select_tree_first_plus_group_node",BI.MultiLayerSelectTreeFirstPlusGroupNode)},function(e,t){BI.MultiLayerSelectTreeLastPlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.MultiLayerSelectTreeLastPlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-multilayer-select-tree-last-plus-group-node bi-list-item-active",layer:0,id:"",pId:"",readonly:!0,open:!1,height:24})},_init:function(){BI.MultiLayerSelectTreeLastPlusGroupNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.node=BI.createWidget({type:"bi.select_tree_last_plus_group_node",cls:"bi-list-item-none",stopPropagation:!0,logic:{dynamic:!0},id:t.id,pId:t.pId,keyword:t.keyword,open:t.open,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py}),this.node.on(BI.Controller.EVENT_CHANGE,(function(t){e.setSelected(e.isSelected()),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}));var n=[];n.push({el:this.node,lgap:12*t.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(t.layer,12),items:n})},doRedMark:function(){this.node.doRedMark.apply(this.node,arguments)},unRedMark:function(){this.node.unRedMark.apply(this.node,arguments)},isSelected:function(){return this.node.isSelected()},setSelected:function(e){BI.MultiLayerSelectTreeLastPlusGroupNode.superclass.setSelected.apply(this,arguments),this.node.setSelected(e)},doClick:function(){BI.MultiLayerSelectTreeLastPlusGroupNode.superclass.doClick.apply(this,arguments),this.node.setSelected(this.isSelected())},setOpened:function(e){BI.MultiLayerSelectTreeLastPlusGroupNode.superclass.setOpened.apply(this,arguments),this.node.setOpened(e)}}),BI.shortcut("bi.multilayer_select_tree_last_plus_group_node",BI.MultiLayerSelectTreeLastPlusGroupNode)},function(e,t){BI.MultiLayerSelectTreeMidPlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.MultiLayerSelectTreeMidPlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-multilayer-select-tree-mid-plus-group-node bi-list-item-active",layer:0,id:"",pId:"",readonly:!0,open:!1,height:24})},_init:function(){BI.MultiLayerSelectTreeMidPlusGroupNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.node=BI.createWidget({type:"bi.select_tree_mid_plus_group_node",cls:"bi-list-item-none",stopPropagation:!0,logic:{dynamic:!0},id:t.id,pId:t.pId,keyword:t.keyword,open:t.open,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py}),this.node.on(BI.Controller.EVENT_CHANGE,(function(t){e.setSelected(e.isSelected()),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}));var n=[];n.push({el:this.node,lgap:12*t.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(t.layer,12),items:n})},doRedMark:function(){this.node.doRedMark.apply(this.node,arguments)},unRedMark:function(){this.node.unRedMark.apply(this.node,arguments)},isSelected:function(){return this.node.isSelected()},setSelected:function(e){BI.MultiLayerSelectTreeMidPlusGroupNode.superclass.setSelected.apply(this,arguments),this.node.setSelected(e)},doClick:function(){BI.MultiLayerSelectTreeMidPlusGroupNode.superclass.doClick.apply(this,arguments),this.node.setSelected(this.isSelected())},setOpened:function(e){BI.MultiLayerSelectTreeMidPlusGroupNode.superclass.setOpened.apply(this,arguments),this.node.setOpened(e)}}),BI.shortcut("bi.multilayer_select_tree_mid_plus_group_node",BI.MultiLayerSelectTreeMidPlusGroupNode)},function(e,t){BI.MultiLayerSelectTreePlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.MultiLayerSelectTreePlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-multilayer-select-tree-first-plus-group-node bi-list-item-active",layer:0,id:"",pId:"",readonly:!0,open:!1,height:24})},_init:function(){BI.MultiLayerSelectTreePlusGroupNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.node=BI.createWidget({type:"bi.select_tree_plus_group_node",cls:"bi-list-item-none",stopPropagation:!0,logic:{dynamic:!0},id:t.id,pId:t.pId,keyword:t.keyword,open:t.open,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py}),this.node.on(BI.Controller.EVENT_CHANGE,(function(t){e.setSelected(e.isSelected()),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}));var n=[];n.push({el:this.node,lgap:12*t.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(t.layer,12),items:n})},isOnce:function(){return!0},doRedMark:function(){this.node.doRedMark.apply(this.node,arguments)},unRedMark:function(){this.node.unRedMark.apply(this.node,arguments)},isSelected:function(){return this.node.isSelected()},setSelected:function(e){BI.MultiLayerSelectTreePlusGroupNode.superclass.setSelected.apply(this,arguments),this.node.setSelected(e)},doClick:function(){BI.NodeButton.superclass.doClick.apply(this,arguments),this.node.setSelected(this.isSelected())},setOpened:function(e){BI.MultiLayerSelectTreePlusGroupNode.superclass.setOpened.apply(this,arguments),this.node.setOpened(e)}}),BI.shortcut("bi.multilayer_select_tree_plus_group_node",BI.MultiLayerSelectTreePlusGroupNode)},function(e,t){BI.MultiLayerSingleTreeCombo=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiLayerSingleTreeCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multilayer-single-tree-combo",isDefaultInit:!1,height:24,text:"",itemsCreator:BI.emptyFn,items:[],value:"",allowEdit:!1,allowSearchValue:!1,allowInsertValue:!1,isNeedAdjustWidth:!0})},_init:function(){var e=this.options;this._shouldWrapper()&&(e.height-=2,BI.isNumeric(e.width)&&(e.width-=2)),BI.MultiLayerSingleTreeCombo.superclass._init.apply(this,arguments)},render:function(){var e=this,t=this.options,n=t.itemsCreator===BI.emptyFn?this._getSyncConfig():this._getAsyncConfig();return this._shouldWrapper()?n:{type:"bi.absolute",height:t.height-2,items:[{el:n,left:0,right:0,top:0,bottom:0},{el:{type:"bi.trigger_icon_button",cls:"trigger-icon-button",ref:function(t){e.triggerBtn=t},width:t.height,height:t.height,handler:function(){e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()}},right:0,bottom:0,top:0}]}},_shouldWrapper:function(){var e=this.options;return!e.allowEdit&&e.itemsCreator===BI.emptyFn},_getBaseConfig:function(){var e=this,t=this.options;return{type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",container:t.container,destroyWhenHide:t.destroyWhenHide,adjustLength:2,ref:function(t){e.combo=t},popup:{el:{type:"bi.multilayer_single_tree_popup",isDefaultInit:t.isDefaultInit,itemsCreator:t.itemsCreator,items:t.items,ref:function(t){e.trigger&&e.trigger.getSearcher().setAdapter(t)},listeners:[{eventName:BI.MultiLayerSingleTreePopup.EVENT_CHANGE,action:function(){e.setValue(this.getValue()),e.combo.hideView(),e.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_CHANGE)}}],onLoaded:function(){BI.nextTick((function(){e.combo.adjustWidth(),e.combo.adjustHeight()}))}},value:t.value,maxHeight:400,maxWidth:t.isNeedAdjustWidth?"auto":500,minHeight:240},isNeedAdjustWidth:t.isNeedAdjustWidth,listeners:[{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){e.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_BEFORE_POPUPVIEW)}}]}},_getSearchConfig:function(){var e=this,t=this.options;return{el:{type:"bi.multilayer_single_tree_trigger",container:t.container,allowInsertValue:t.allowInsertValue,allowSearchValue:t.allowSearchValue,allowEdit:t.allowEdit,cls:"multilayer-single-tree-trigger",ref:function(t){e.trigger=t},watermark:t.watermark,items:t.items,itemsCreator:t.itemsCreator,valueFormatter:t.valueFormatter,height:t.height-2,text:t.text,value:t.value,tipType:t.tipType,warningTitle:t.warningTitle,title:t.title,listeners:[{eventName:BI.MultiLayerSingleTreeTrigger.EVENT_CHANGE,action:function(){e.setValue(this.getValue()),e.combo.hideView(),e.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_CHANGE)}},{eventName:BI.MultiLayerSingleTreeTrigger.EVENT_FOCUS,action:function(){e.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_FOCUS)}},{eventName:BI.MultiLayerSingleTreeTrigger.EVENT_BLUR,action:function(){e.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_BLUR)}},{eventName:BI.MultiLayerSingleTreeTrigger.EVENT_SEARCHING,action:function(){e.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_SEARCHING)}},{eventName:BI.MultiLayerSingleTreeTrigger.EVENT_ADD_ITEM,action:function(){var t=e.trigger.getSearcher().getKeyword();e.combo.setValue([t]),e.combo.hideView()}}]},toggle:!t.allowEdit,hideChecker:function(n){return!(t.container&&e.trigger.getSearcher().isSearching()&&e.trigger.getSearcher().getView().element.find(n.target).length>0)&&0===e.triggerBtn.element.find(n.target).length},listeners:[{eventName:BI.Combo.EVENT_AFTER_HIDEVIEW,action:function(){e.trigger.stopEditing()}},{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){e.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_BEFORE_POPUPVIEW)}}]}},_getSyncConfig:function(){var e=this.options,t=this,n=this._getBaseConfig();return BI.extend(n,e.allowEdit?this._getSearchConfig():{el:{type:"bi.single_tree_trigger",ref:function(e){t.textTrigger=e},text:e.text,height:e.height,items:e.items,value:e.value}})},_getAsyncConfig:function(){var e=this._getBaseConfig();return BI.extend(e,this._getSearchConfig())},getSearcher:function(){return this.trigger?this.trigger.getSearcher():this.textTrigger.getTextor()},setValue:function(e){e=BI.isArray(e)?e:[e],this.combo.setValue(e)},getValue:function(){return this.combo.getValue()},populate:function(e){this.combo.populate(e)}}),BI.MultiLayerSingleTreeCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiLayerSingleTreeCombo.EVENT_BLUR="EVENT_BLUR",BI.MultiLayerSingleTreeCombo.EVENT_FOCUS="EVENT_FOCUS",BI.MultiLayerSingleTreeCombo.EVENT_CHANGE="EVENT_CHANGE",BI.MultiLayerSingleTreeCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.multilayer_single_tree_combo",BI.MultiLayerSingleTreeCombo)},function(e,t){BI.MultiLayerSingleTreeInsertSearchPane=BI.inherit(BI.Widget,{props:function(){return{baseCls:"bi-multilayer-single-tree-popup",tipText:BI.i18nText("BI-No_Selected_Item"),isDefaultInit:!1,itemsCreator:BI.emptyFn,items:[],value:""}},render:function(){var e=this,t=this.options;return this.tree=BI.createWidget({type:"bi.multilayer_single_level_tree",isDefaultInit:t.isDefaultInit,items:t.items,itemsCreator:t.itemsCreator===BI.emptyFn?BI.emptyFn:function(n,i){t.itemsCreator(n,(function(n){i(n),e.setKeyword(t.keywordGetter())}))},keywordGetter:t.keywordGetter,value:t.value,scrollable:null,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}},{eventName:BI.MultiLayerSelectLevelTree.EVENT_CHANGE,action:function(){e.fireEvent(BI.MultiLayerSingleTreeInsertSearchPane.EVENT_CHANGE)}}]}),{type:"bi.vertical",scrolly:!1,scrollable:!0,vgap:5,items:[{type:"bi.text_button",invisible:!0,text:BI.i18nText("BI-Basic_Click_To_Add_Text",""),height:24,cls:"bi-high-light",hgap:5,ref:function(t){e.addNotMatchTip=t},handler:function(){e.fireEvent(BI.MultiLayerSingleTreeInsertSearchPane.EVENT_ADD_ITEM,t.keywordGetter())}},this.tree]}},setKeyword:function(e){var t=BI.isEmptyArray(this.tree.getAllLeaves());this.addNotMatchTip.setVisible(t),t&&this.addNotMatchTip.setText(BI.i18nText("BI-Basic_Click_To_Add_Text",e))},getValue:function(){return this.tree.getValue()},setValue:function(e){e=BI.isArray(e)?e:[e],this.tree.setValue(e)},populate:function(e){this.tree.populate(e)}}),BI.MultiLayerSingleTreeInsertSearchPane.EVENT_ADD_ITEM="EVENT_ADD_ITEM",BI.MultiLayerSingleTreeInsertSearchPane.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multilayer_single_tree_insert_search_pane",BI.MultiLayerSingleTreeInsertSearchPane)},function(e,t){BI.MultiLayerSingleLevelTree=BI.inherit(BI.Pane,{_defaultConfig:function(){return BI.extend(BI.MultiLayerSingleLevelTree.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multilayer-single-level-tree",isDefaultInit:!1,items:[],itemsCreator:BI.emptyFn,keywordGetter:BI.emptyFn,chooseType:BI.Selection.Single,scrollable:!0})},_init:function(){var e=this.options;BI.MultiLayerSingleLevelTree.superclass._init.apply(this,arguments),this.storeValue=e.value,this.initTree(this.options.items),this.check()},_formatItems:function(e,t,n){var i=this,r=this.options.keywordGetter();return BI.each(e,(function(a,o){var s={isFirstNode:0===a,isLastNode:a===e.length-1};o.layer=t,BI.isKey(o.id)||(o.id=BI.UUID()),o.keyword=o.keyword||r,s.pNode=n,!0===o.isParent||!0===o.parent||BI.isNotEmptyArray(o.children)?(0===t&&s.isFirstNode&&s.isLastNode?s.type="bi.multilayer_single_tree_plus_group_node":0===t&&s.isFirstNode?s.type="bi.multilayer_single_tree_first_plus_group_node":s.isLastNode?s.type="bi.multilayer_single_tree_last_plus_group_node":s.type="bi.multilayer_single_tree_mid_plus_group_node",BI.defaults(o,s),i._formatItems(o.children,t+1,o)):(0===t&&s.isFirstNode&&s.isLastNode?s.type="bi.root_tree_leaf_item":0===t&&s.isFirstNode?s.type="bi.multilayer_single_tree_first_tree_leaf_item":s.isLastNode?s.type="bi.multilayer_single_tree_last_tree_leaf_item":s.type="bi.multilayer_single_tree_mid_tree_leaf_item",BI.defaults(o,s))})),e},_assertId:function(e){BI.each(e,(function(e,t){t.id=t.id||BI.UUID()}))},initTree:function(e){var t=this,n=this.options,i=!1;this.empty(),this._assertId(e),this.tree=BI.createWidget({type:"bi.custom_tree",cls:"tree-view display-table",expander:{type:"bi.tree_expander",isDefaultInit:n.isDefaultInit,el:{},popup:{type:"bi.custom_tree"}},items:this._formatItems(BI.Tree.transformToTreeFormat(e),0),value:n.value,itemsCreator:function(e,r){1===e.times&&!e.node&&BI.nextTick((function(){t.loading()})),n.itemsCreator(e,(function(n){i=n.hasNext,1===e.times&&!e.node&&t._populate(n.items),r(t._formatItems(BI.Tree.transformToTreeFormat(n.items),e.node?e.node.layer+1:0,e.node)),t.setValue(t.storeValue),1===e.times&&!e.node&&BI.nextTick((function(){t.loaded()}))}))},el:{type:"bi.loader",isDefaultInit:n.itemsCreator!==BI.emptyFn,el:{type:"bi.button_tree",chooseType:n.chooseType===BI.Selection.None?BI.Selection.None:BI.Selection.Default,behaviors:n.behaviors,layouts:[{type:"bi.vertical"}]},hasNext:function(){return i}}}),this.tree.on(BI.Controller.EVENT_CHANGE,(function(e,n){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&(t.setValue(n),t.fireEvent(BI.MultiLayerSingleLevelTree.EVENT_CHANGE,n))})),BI.createWidget({type:"bi.adaptive",element:this,scrollable:n.scrollable,items:[this.tree]})},_populate:function(){BI.MultiLayerSelectLevelTree.superclass.populate.apply(this,arguments)},populate:function(e){this._populate(e),BI.isNull(e)?this.tree.populate():this.tree.populate(this._formatItems(BI.Tree.transformToTreeFormat(e),0))},setValue:function(e){this.options.chooseType===BI.Selection.None||(this.storeValue=e,this.tree.setValue(e))},getValue:function(){return BI.isArray(this.storeValue)?this.storeValue:BI.isNull(this.storeValue)?[]:[this.storeValue]},getAllLeaves:function(){return this.tree.getAllLeaves()},getNodeById:function(e){return this.tree.getNodeById(e)},getNodeByValue:function(e){return this.tree.getNodeByValue(e)}}),BI.MultiLayerSingleLevelTree.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multilayer_single_level_tree",BI.MultiLayerSingleLevelTree)},function(e,t){BI.MultiLayerSingleTreePopup=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiLayerSingleTreePopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multilayer-singletree-popup",tipText:BI.i18nText("BI-No_Selected_Item"),isDefaultInit:!1,itemsCreator:BI.emptyFn,items:[],onLoaded:BI.emptyFn,minHeight:240})},_init:function(){BI.MultiLayerSingleTreePopup.superclass._init.apply(this,arguments);var e=this,t=this.options;this.tree=BI.createWidget({type:"bi.multilayer_single_level_tree",isDefaultInit:t.isDefaultInit,items:t.items,itemsCreator:t.itemsCreator,keywordGetter:t.keywordGetter,value:t.value,scrollable:null,onLoaded:function(){e.tree.check(),t.onLoaded()}}),BI.createWidget({type:"bi.vertical",scrolly:!1,scrollable:!0,element:this,vgap:5,items:[this.tree]}),this.tree.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.tree.on(BI.MultiLayerSingleLevelTree.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiLayerSingleTreePopup.EVENT_CHANGE)})),this.tree.css("min-height",t.minHeight-10)},getValue:function(){return this.tree.getValue()},setValue:function(e){e=BI.isArray(e)?e:[e],this.tree.setValue(e)},populate:function(e){this.tree.populate(e)}}),BI.MultiLayerSingleTreePopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multilayer_single_tree_popup",BI.MultiLayerSingleTreePopup)},function(e,t){BI.MultiLayerSingleTreeTrigger=BI.inherit(BI.Trigger,{props:function(){return{extraCls:"bi-multi-layer-single-tree-trigger",height:24,itemsCreator:BI.emptyFn,watermark:BI.i18nText("BI-Basic_Search"),allowSearchValue:!1,title:BI.bind(this._getShowText,this)}},render:function(){var e=this,t=this.options;t.itemsCreator===BI.emptyFn&&this._initData();var n={type:"bi.htape",items:[{el:{type:"bi.searcher",ref:function(){e.searcher=this},masker:BI.isNotNull(t.container)?{offset:{},container:t.container}:{offset:{}},isAutoSearch:!1,el:{type:"bi.state_editor",ref:function(){e.editor=this},defaultText:t.text,text:this._digest(t.value),value:t.value,height:t.height,tipText:"",watermark:t.watermark,listeners:[{eventName:BI.StateEditor.EVENT_FOCUS,action:function(){e.fireEvent(BI.MultiLayerSingleTreeTrigger.EVENT_FOCUS)}},{eventName:BI.StateEditor.EVENT_BLUR,action:function(){e.fireEvent(BI.MultiLayerSingleTreeTrigger.EVENT_BLUR)}},{eventName:BI.StateEditor.EVENT_CHANGE,action:function(){e.fireEvent(BI.MultiLayerSingleTreeTrigger.EVENT_SEARCHING)}}]},popup:{type:t.allowInsertValue?"bi.multilayer_single_tree_insert_search_pane":"bi.multilayer_single_tree_popup",itemsCreator:t.itemsCreator===BI.emptyFn?BI.emptyFn:function(n,i){n.keyword=e.editor.getValue(),t.itemsCreator(n,i)},keywordGetter:function(){return e.editor.getValue()},cls:"bi-card",listeners:[{eventName:BI.MultiLayerSingleTreeInsertSearchPane.EVENT_ADD_ITEM,action:function(){e.options.text=e.getSearcher().getKeyword(),e.fireEvent(BI.MultiLayerSingleTreeTrigger.EVENT_ADD_ITEM)}}],ref:function(t){e.popup=t}},onSearch:function(n,i){var r=n.keyword;t.itemsCreator===BI.emptyFn?(i(e._getSearchItems(r)),t.allowInsertValue&&e.popup.setKeyword(r)):i()},listeners:[{eventName:BI.Searcher.EVENT_CHANGE,action:function(){e.fireEvent(BI.MultiLayerSingleTreeTrigger.EVENT_CHANGE)}}]}},{el:{type:"bi.layout",width:24},width:24}]};return t.allowEdit?n:{type:"bi.absolute",items:[{el:n,left:0,right:0,top:0,bottom:0},{el:{type:"bi.layout"},left:0,right:24,top:0,bottom:0}]}},_initData:function(){var e=this.options;this.tree=new BI.Tree,this.nodes=BI.Tree.treeFormat(BI.deepClone(e.items)),this.tree.initTree(this.nodes)},_getSearchItems:function(e){var t=this,n=this.options,i=[];return this.tree.traverse((function(r){var a=BI.Func.getSearchResult(t.tree.isRoot(r)?[]:BI.concat([r.text],n.allowSearchValue?[r.value]:[]),e);if(a.find.length>0||a.match.length>0)return i.push(r),!0})),this._fillTreeStructure4Search(i,"id")},_createJson:function(e,t){return{id:e.id,pId:e.pId,text:e.text,value:e.value,isParent:BI.isNotEmptyArray(e.children),open:t}},_getChildren:function(e){var t=this;e.children=e.children||[];var n=[];return BI.each(e.children,(function(e,i){var r=t._getChildren(i);n=n.concat(r)})),e.children.concat(n)},_fillTreeStructure4Search:function(e){var t=this,n=[],i=[];for(BI.each(e,(function(e,r){i.push({pId:r.pId}),n.push(r),n=n.concat(t._getChildren(r))}));BI.isNotEmptyArray(i);){var r=i.pop(),a=this.tree.search(this.tree.getRoot(),r.pId,"id");null!=a&&(a.open=!0,i.push({pId:a.pId}),n.push(a))}return BI.uniqBy(BI.map(n,(function(e,n){return t._createJson(n,n.open)})),"id")},_digest:function(e){var t=this.options;if(BI.isFunction(t.valueFormatter))return t.valueFormatter(e);if(t.itemsCreator===BI.emptyFn){var n=BI.find(t.items,(function(t,n){return n.value===e}));return BI.isNotNull(n)?n.text:t.text}return e},_getShowText:function(){return this.editor.getText()},stopEditing:function(){this.searcher.stopSearch()},getSearcher:function(){return this.searcher},populate:function(e){this.options.items=e,this._initData()},setValue:function(e){this.editor.setState(this._digest(e[0]))},getValue:function(){return this.searcher.getValue()}}),BI.MultiLayerSingleTreeTrigger.EVENT_FOCUS="EVENT_FOCUS",BI.MultiLayerSingleTreeTrigger.EVENT_BLUR="EVENT_BLUR",BI.MultiLayerSingleTreeTrigger.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiLayerSingleTreeTrigger.EVENT_STOP="EVENT_STOP",BI.MultiLayerSingleTreeTrigger.EVENT_START="EVENT_START",BI.MultiLayerSingleTreeTrigger.EVENT_CHANGE="EVENT_CHANGE",BI.MultiLayerSingleTreeTrigger.EVENT_ADD_ITEM="EVENT_ADD_ITEM",BI.shortcut("bi.multilayer_single_tree_trigger",BI.MultiLayerSingleTreeTrigger)},function(e,t){BI.MultiLayerSingleTreeFirstPlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.MultiLayerSingleTreeFirstPlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-multilayer-single-tree-first-plus-group-node bi-list-item",layer:0,id:"",pId:"",open:!1,height:24})},_init:function(){BI.MultiLayerSingleTreeFirstPlusGroupNode.superclass._init.apply(this,arguments);var e=this.options;this.node=this._createNode();var t=[];t.push({el:this.node,lgap:12*e.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(e.layer,12),items:t})},doRedMark:function(){this.node.doRedMark.apply(this.node,arguments)},unRedMark:function(){this.node.unRedMark.apply(this.node,arguments)},doClick:function(){BI.MultiLayerSingleTreeFirstPlusGroupNode.superclass.doClick.apply(this,arguments),this.node.setSelected(this.isSelected())},setOpened:function(e){BI.MultiLayerSingleTreeFirstPlusGroupNode.superclass.setOpened.apply(this,arguments),BI.isNotNull(this.node)&&this.node.setOpened(e)},_createNode:function(){var e=this,t=this.options;return BI.createWidget({type:"bi.first_plus_group_node",cls:"bi-list-item-none",logic:{dynamic:!0},id:t.id,pId:t.pId,open:t.open,isLastNode:t.isLastNode,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(t){t!==BI.Events.CLICK&&e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}}]})}}),BI.shortcut("bi.multilayer_single_tree_first_plus_group_node",BI.MultiLayerSingleTreeFirstPlusGroupNode)},function(e,t){BI.MultiLayerSingleTreeLastPlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.MultiLayerSingleTreeLastPlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-multilayer-single-tree-last-plus-group-node bi-list-item",layer:0,id:"",pId:"",open:!1,height:24})},_init:function(){BI.MultiLayerSingleTreeLastPlusGroupNode.superclass._init.apply(this,arguments);var e=this.options;this.node=this._createNode();var t=[];t.push({el:this.node,lgap:12*e.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(e.layer,12),items:t})},doRedMark:function(){this.node.doRedMark.apply(this.node,arguments)},unRedMark:function(){this.node.unRedMark.apply(this.node,arguments)},doClick:function(){BI.MultiLayerSingleTreeLastPlusGroupNode.superclass.doClick.apply(this,arguments),this.node.setSelected(this.isSelected())},setOpened:function(e){BI.MultiLayerSingleTreeLastPlusGroupNode.superclass.setOpened.apply(this,arguments),BI.isNotNull(this.node)&&this.node.setOpened(e)},_createNode:function(){var e=this,t=this.options;return BI.createWidget({type:"bi.last_plus_group_node",cls:"bi-list-item-none",logic:{dynamic:!0},id:t.id,pId:t.pId,open:t.open,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(t){t!==BI.Events.CLICK&&e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}}]})}}),BI.shortcut("bi.multilayer_single_tree_last_plus_group_node",BI.MultiLayerSingleTreeLastPlusGroupNode)},function(e,t){BI.MultiLayerSingleTreeMidPlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.MultiLayerSingleTreeMidPlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-multilayer-single-tree-mid-plus-group-node bi-list-item",layer:0,id:"",pId:"",open:!1,height:24})},_init:function(){BI.MultiLayerSingleTreeMidPlusGroupNode.superclass._init.apply(this,arguments);var e=this.options;this.node=this._createNode();var t=[];t.push({el:this.node,lgap:12*e.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(e.layer,12),items:t})},doRedMark:function(){this.node.doRedMark.apply(this.node,arguments)},unRedMark:function(){this.node.unRedMark.apply(this.node,arguments)},doClick:function(){BI.MultiLayerSingleTreeMidPlusGroupNode.superclass.doClick.apply(this,arguments),this.node.setSelected(this.isSelected())},setOpened:function(e){BI.MultiLayerSingleTreeMidPlusGroupNode.superclass.setOpened.apply(this,arguments),BI.isNotNull(this.node)&&this.node.setOpened(e)},_createNode:function(){var e=this,t=this.options;return BI.createWidget({type:"bi.mid_plus_group_node",cls:"bi-list-item-none",logic:{dynamic:!0},id:t.id,pId:t.pId,open:t.open,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(t){t!==BI.Events.CLICK&&e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}}]})}}),BI.shortcut("bi.multilayer_single_tree_mid_plus_group_node",BI.MultiLayerSingleTreeMidPlusGroupNode)},function(e,t){BI.MultiLayerSingleTreePlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.MultiLayerSingleTreePlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-multilayer-single-tree-plus-group-node bi-list-item",layer:0,id:"",pId:"",open:!1,height:24})},_init:function(){BI.MultiLayerSingleTreePlusGroupNode.superclass._init.apply(this,arguments);var e=this.options;this.node=this._createNode();for(var t=[],n=e.pNode;n;)n.isLastNode&&t.push(n.layer),n=n.pNode;var i=[];BI.count(0,e.layer,(function(n){i.push({type:"bi.layout",cls:BI.contains(t,n)?"":"base-line-conn-background",width:12,height:e.height})})),i.push(this.node),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(e.layer,12),items:i})},doRedMark:function(){this.node.doRedMark.apply(this.node,arguments)},unRedMark:function(){this.node.unRedMark.apply(this.node,arguments)},doClick:function(){BI.MultiLayerSingleTreePlusGroupNode.superclass.doClick.apply(this,arguments),this.node.setSelected(this.isSelected())},setOpened:function(e){BI.MultiLayerSingleTreePlusGroupNode.superclass.setOpened.apply(this,arguments),BI.isNotNull(this.node)&&this.node.setOpened(e)},_createNode:function(){var e=this,t=this.options;return BI.createWidget({type:"bi.plus_group_node",cls:"bi-list-item-none",logic:{dynamic:!0},id:t.id,pId:t.pId,open:t.open,isLastNode:t.isLastNode,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(t){t!==BI.Events.CLICK&&e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}}]})}}),BI.shortcut("bi.multilayer_single_tree_plus_group_node",BI.MultiLayerSingleTreePlusGroupNode)},function(e,t){BI.MultiLayerSingleTreeFirstTreeLeafItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){return BI.extend(BI.MultiLayerSingleTreeFirstTreeLeafItem.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-multilayer-single-tree-first-tree-leaf-item bi-list-item-active",logic:{dynamic:!1},layer:0,id:"",pId:"",height:24})},_init:function(){BI.MultiLayerSingleTreeFirstTreeLeafItem.superclass._init.apply(this,arguments);var e=this,t=this.options;this.item=BI.createWidget({type:"bi.first_tree_leaf_item",cls:"bi-list-item-none",logic:{dynamic:!0},id:t.id,pId:t.pId,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword}),this.item.on(BI.Controller.EVENT_CHANGE,(function(t){t!==BI.Events.CLICK&&e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}));var n=[];n.push({el:this.item,lgap:12*t.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(t.layer,12),items:n})},doHighLight:function(){this.item.doHighLight.apply(this.item,arguments)},unHighLight:function(){this.item.unHighLight.apply(this.item,arguments)},getId:function(){return this.options.id},getPId:function(){return this.options.pId},doClick:function(){BI.MultiLayerSingleTreeFirstTreeLeafItem.superclass.doClick.apply(this,arguments),this.item.setSelected(this.isSelected())},setSelected:function(e){BI.MultiLayerSingleTreeFirstTreeLeafItem.superclass.setSelected.apply(this,arguments),this.item.setSelected(e)}}),BI.shortcut("bi.multilayer_single_tree_first_tree_leaf_item",BI.MultiLayerSingleTreeFirstTreeLeafItem)},function(e,t){BI.MultiLayerSingleTreeLastTreeLeafItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){return BI.extend(BI.MultiLayerSingleTreeLastTreeLeafItem.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-multilayer-single-tree-last-tree-leaf-item bi-list-item-active",logic:{dynamic:!1},layer:0,id:"",pId:"",height:24})},_init:function(){BI.MultiLayerSingleTreeLastTreeLeafItem.superclass._init.apply(this,arguments);var e=this,t=this.options;this.item=BI.createWidget({type:"bi.last_tree_leaf_item",cls:"bi-list-item-none",logic:{dynamic:!0},id:t.id,pId:t.pId,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword}),this.item.on(BI.Controller.EVENT_CHANGE,(function(t){t!==BI.Events.CLICK&&e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}));var n=[];n.push({el:this.item,lgap:12*t.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(t.layer,12),items:n})},doHighLight:function(){this.item.doHighLight.apply(this.item,arguments)},unHighLight:function(){this.item.unHighLight.apply(this.item,arguments)},getId:function(){return this.options.id},getPId:function(){return this.options.pId},doClick:function(){BI.MultiLayerSingleTreeLastTreeLeafItem.superclass.doClick.apply(this,arguments),this.item.setSelected(this.isSelected())},setSelected:function(e){BI.MultiLayerSingleTreeLastTreeLeafItem.superclass.setSelected.apply(this,arguments),this.item.setSelected(e)}}),BI.shortcut("bi.multilayer_single_tree_last_tree_leaf_item",BI.MultiLayerSingleTreeLastTreeLeafItem)},function(e,t){BI.MultiLayerSingleTreeMidTreeLeafItem=BI.inherit(BI.BasicButton,{_defaultConfig:function(){return BI.extend(BI.MultiLayerSingleTreeMidTreeLeafItem.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-multilayer-single-tree-mid-tree-leaf-item bi-list-item-active",logic:{dynamic:!1},layer:0,id:"",pId:"",height:24})},_init:function(){BI.MultiLayerSingleTreeMidTreeLeafItem.superclass._init.apply(this,arguments);var e=this,t=this.options;this.item=BI.createWidget({type:"bi.mid_tree_leaf_item",cls:"bi-list-item-none",logic:{dynamic:!0},id:t.id,pId:t.pId,height:t.height,hgap:t.hgap,text:t.text,value:t.value,py:t.py,keyword:t.keyword}),this.item.on(BI.Controller.EVENT_CHANGE,(function(t){t!==BI.Events.CLICK&&e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}));var n=[];n.push({el:this.item,lgap:12*t.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(t.layer,12),items:n})},doHighLight:function(){this.item.doHighLight.apply(this.item,arguments)},unHighLight:function(){this.item.unHighLight.apply(this.item,arguments)},getId:function(){return this.options.id},getPId:function(){return this.options.pId},doClick:function(){BI.MultiLayerSingleTreeMidTreeLeafItem.superclass.doClick.apply(this,arguments),this.item.setSelected(this.isSelected())},setSelected:function(e){BI.MultiLayerSingleTreeMidTreeLeafItem.superclass.setSelected.apply(this,arguments),this.item.setSelected(e)}}),BI.shortcut("bi.multilayer_single_tree_mid_tree_leaf_item",BI.MultiLayerSingleTreeMidTreeLeafItem)},function(e,t){BI.MultiSelectCheckPane=BI.inherit(BI.Widget,{constants:{height:12,lgap:10,tgap:10,bgap:5},_defaultConfig:function(){return BI.extend(BI.MultiSelectCheckPane.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-check-pane bi-background",items:[],itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,onClickContinueSelect:BI.emptyFn})},_init:function(){BI.MultiSelectCheckPane.superclass._init.apply(this,arguments);var e=this,t=this.options;this.storeValue=t.value||{},this.display=BI.createWidget({type:"bi.display_selected_list",items:t.items,itemsCreator:function(n,i){n=BI.extend(n||{},{selectedValues:e.storeValue.value}),e.storeValue.type!==BI.Selection.Multi?t.itemsCreator(n,i):i({items:BI.map(e.storeValue.value,(function(e,n){var i=t.valueFormatter(n)||n;return{text:i,value:n,title:i}}))})}}),this.continueSelect=BI.createWidget({type:"bi.text_button",text:BI.i18nText("BI-Continue_Select"),cls:"multi-select-check-selected bi-high-light"}),this.continueSelect.on(BI.TextButton.EVENT_CHANGE,(function(){t.onClickContinueSelect()})),BI.createWidget({type:"bi.vtape",element:this,items:[{height:this.constants.height,el:{type:"bi.vertical_adapt",cls:"multi-select-continue-select",items:[{el:{type:"bi.label",text:BI.i18nText("BI-Selected_Data")},lgap:this.constants.lgap},{el:this.continueSelect,lgap:this.constants.lgap}]},tgap:this.constants.tgap},{height:"fill",el:this.display,tgap:this.constants.bgap}]})},setValue:function(e){this.storeValue=e||{}},empty:function(){this.display.empty()},populate:function(){this.display.populate.apply(this.display,arguments)}}),BI.shortcut("bi.multi_select_check_pane",BI.MultiSelectCheckPane)},function(e,t){BI.DisplaySelectedList=BI.inherit(BI.Pane,{constants:{height:24,lgap:10},_defaultConfig:function(){return BI.extend(BI.DisplaySelectedList.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-display-list",itemsCreator:BI.emptyFn,items:[]})},_init:function(){BI.DisplaySelectedList.superclass._init.apply(this,arguments);var e=this,t=this.options;this.hasNext=!1,this.button_group=BI.createWidget({type:"bi.list_pane",element:this,el:{type:"bi.loader",isDefaultInit:!1,logic:{dynamic:!0,scrolly:!0},items:this._createItems(t.items),chooseType:BI.ButtonGroup.CHOOSE_TYPE_MULTI,layouts:[{type:"bi.vertical",lgap:10}]},itemsCreator:function(n,i){t.itemsCreator(n,(function(t){e.hasNext=!!t.hasNext,i(e._createItems(t.items))}))},hasNext:function(){return e.hasNext}})},_createItems:function(e){return BI.createItems(e,{type:"bi.icon_text_item",cls:"cursor-default check-font icon-size-12 display-list-item bi-tips",once:!0,invalid:!0,selected:!0,height:this.constants.height,logic:{dynamic:!0}})},empty:function(){this.button_group.empty()},populate:function(e){0===arguments.length?this.button_group.populate():this.button_group.populate(this._createItems(e))}}),BI.shortcut("bi.display_selected_list",BI.DisplaySelectedList)},function(e,t){BI.MultiSelectCombo=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.MultiSelectCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-combo",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,itemHeight:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,height:24,allowEdit:!0})},_init:function(){var e=this,t=this.options;BI.MultiSelectCombo.superclass._init.apply(this,arguments);var n=function(){BI.isKey(e._startValue)&&(e.storeValue.type===BI.Selection.All?(BI.remove(e.storeValue.value,e._startValue),e.storeValue.assist=e.storeValue.assist||[],e.storeValue.assist.pushDistinct(e._startValue)):(BI.pushDistinct(e.storeValue.value,e._startValue),BI.remove(e.storeValue.assist,e._startValue))),e.trigger.getSearcher().setState(e.storeValue),e.numberCounter.setButtonChecked(e.storeValue)};this.storeValue=t.value||{},this._assertValue(this.storeValue),this.requesting=!1,this.trigger=BI.createWidget({type:"bi.multi_select_trigger",allowEdit:t.allowEdit,height:t.height-2,text:t.text,masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:t.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),itemHeight:t.itemHeight,value:this.storeValue}),this.trigger.on(BI.MultiSelectTrigger.EVENT_FOCUS,(function(){e.fireEvent(BI.MultiSelectCombo.EVENT_FOCUS)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_BLUR,(function(){e.fireEvent(BI.MultiSelectCombo.EVENT_BLUR)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_START,(function(){e._setStartValue(""),this.getSearcher().setValue(e.storeValue)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_STOP,(function(){e._setStartValue(""),e.fireEvent(BI.MultiSelectCombo.EVENT_STOP)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_SEARCHING,(function(t){var i=BI.last(t);(t=BI.initial(t||[])).length>0&&e._joinKeywords(t,(function(){BI.endWith(i,BI.BlankSplitChar)?(e.combo.setValue(e.storeValue),n(),e.combo.populate(),e._setStartValue("")):(e.combo.setValue(e.storeValue),n()),e._dataChange=!0})),e.fireEvent(BI.MultiSelectCombo.EVENT_SEARCHING)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_CHANGE,(function(t,i){i instanceof BI.MultiSelectBar?e._joinAll(this.getValue(),(function(){n()})):e._join(this.getValue(),(function(){n()})),e._dataChange=!0,e.fireEvent(BI.MultiSelectCombo.EVENT_CLICK_ITEM)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW,(function(){e.numberCounter.updateSelectedValue(e.storeValue)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_COUNTER_CLICK,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!t.allowEdit,container:t.container,el:this.trigger,adjustLength:1,popup:{type:"bi.multi_select_popup_view",ref:function(){e.popup=this,e.trigger.setAdapter(this),e.numberCounter.setAdapter(this)},listeners:[{eventName:BI.MultiSelectPopupView.EVENT_CHANGE,action:function(){e._dataChange=!0,e.storeValue=this.getValue(),e._adjust((function(){n()})),e.fireEvent(BI.MultiSelectCombo.EVENT_CLICK_ITEM)}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CONFIRM,action:function(){e._defaultState()}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CLEAR,action:function(){e._dataChange=!0,e.setValue(),e._defaultState()}}],itemsCreator:t.itemsCreator,itemsHeight:t.itemsHeight,valueFormatter:t.valueFormatter,onLoaded:function(){BI.nextTick((function(){e.combo.adjustWidth(),e.combo.adjustHeight(),e.numberCounter.adjustView(),e.trigger.getSearcher().adjustView()}))}},value:t.value,hideChecker:function(t){return 0===i.element.find(t.target).length&&0===e.numberCounter.element.find(t.target).length}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){this.isViewVisible()||(e._dataChange=!1),this.setValue(e.storeValue),BI.nextTick((function(){e._populate()}))})),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,(function(){e._stopEditing(),!0===e.requesting?e.wants2Quit=!0:e._dataChange&&e.fireEvent(BI.MultiSelectCombo.EVENT_CONFIRM)}));var i=BI.createWidget({type:"bi.trigger_icon_button",width:t.height,height:t.height,cls:"multi-select-trigger-icon-button"});i.on(BI.TriggerIconButton.EVENT_CHANGE,(function(){e.numberCounter.hideView(),e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()})),this.numberCounter=BI.createWidget({type:"bi.multi_select_check_selected_switcher",masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:t.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),value:this.storeValue}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,(function(){this.updateSelectedValue(e.storeValue)})),this.numberCounter.on(BI.Events.VIEW,(function(t){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(!0===t?e.numberCounter.element.outerWidth()+8:0)}))})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,(function(){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(0)}))})),this.trigger.element.click((function(t){e.trigger.element.find(t.target).length>0&&e.numberCounter.hideView()})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:i,right:0,top:0,bottom:0},{el:{type:"bi.vertical_adapt",items:[this.numberCounter]},right:t.height,top:0,height:t.height}]})},_itemsCreator4Trigger:function(e,t){var n=this;this.options.itemsCreator(e,(function(i){1===e.times&&BI.isNotNull(e.keywords)&&n.trigger.setValue(BI.deepClone(n.getValue())),t.apply(n,arguments)}))},_stopEditing:function(){this.trigger.stopEditing(),this.numberCounter.hideView()},_defaultState:function(){this._stopEditing(),this.combo.hideView()},_assertValue:function(e){e||(e={}),e.type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(e,t){var n=this,i=this.options;this._assertValue(this.storeValue),this.requesting=!0,i.itemsCreator({type:BI.MultiSelectCombo.REQ_GET_ALL_DATA,keywords:e},(function(i){var r,a,o=BI.map(i.items,"value");r=o,a=n._makeMap(r),BI.each(e,(function(e,t){BI.isNotNull(a[t])&&(n.storeValue.type===BI.Selection.Multi?BI.pushDistinct(n.storeValue.value,t):BI.remove(n.storeValue.value,t))})),n._adjust(t)}))},_joinAll:function(e,t){var n=this,i=this.options;this._assertValue(e),this.requesting=!0,i.itemsCreator({type:BI.MultiSelectCombo.REQ_GET_ALL_DATA,keywords:[this.trigger.getKey()]},(function(i){var r=BI.map(i.items,"value");if(n.storeValue.type===e.type){var a=!1,o=n._makeMap(n.storeValue.value);return BI.each(r,(function(e,t){BI.isNotNull(o[t])&&(a=!0,n.storeValue.assist&&n.storeValue.assist.push(o[t]),delete o[t])})),a&&(n.storeValue.value=BI.values(o)),void n._adjust(t)}var s=n._makeMap(n.storeValue.value),l=n._makeMap(e.value),u=[];BI.each(r,(function(e,t){BI.isNotNull(s[r[e]])&&(n.storeValue.assist&&n.storeValue.assist.push(s[r[e]]),delete s[r[e]]),BI.isNull(l[r[e]])&&(BI.remove(n.storeValue.assist,t),u.push(t))})),n.storeValue.value=u.concat(BI.values(s)),n._adjust(t)}))},_adjust:function(e){var t=this;this.options;!function(){!0===t.wants2Quit&&(t._dataChange&&t.fireEvent(BI.MultiSelectCombo.EVENT_CONFIRM),t.wants2Quit=!1);t.requesting=!1}(),e()},_join:function(e,t){var n=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var i=this._makeMap(this.storeValue.value);BI.each(e.value,(function(e,t){i[t]||(BI.pushDistinct(n.storeValue.value,t),BI.remove(n.storeValue.assist,t),i[t]=t)}));var r=!1;return BI.each(e.assist,(function(e,t){BI.isNotNull(i[t])&&(r=!0,n.storeValue.assist&&n.storeValue.assist.push(i[t]),delete i[t])})),r&&(this.storeValue.value=BI.values(i)),void n._adjust(t)}this._joinAll(e,t)},_setStartValue:function(e){this._startValue=e,this.popup.setStartValue(e)},_populate:function(){this.combo.populate.apply(this.combo,arguments)},showView:function(){this.combo.showView()},hideView:function(){this.combo.hideView()},setValue:function(e){this.storeValue=e||{},this._assertValue(this.storeValue),this.combo.setValue(this.storeValue),this.numberCounter.setValue(this.storeValue)},getValue:function(){return BI.deepClone(this.storeValue)},populate:function(){this._populate.apply(this,arguments),this.numberCounter.populateSwitcher.apply(this.numberCounter,arguments)}}),BI.extend(BI.MultiSelectCombo,{REQ_GET_DATA_LENGTH:1,REQ_GET_ALL_DATA:-1}),BI.MultiSelectCombo.EVENT_BLUR="EVENT_BLUR",BI.MultiSelectCombo.EVENT_FOCUS="EVENT_FOCUS",BI.MultiSelectCombo.EVENT_STOP="EVENT_STOP",BI.MultiSelectCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiSelectCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.MultiSelectCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.shortcut("bi.multi_select_combo",BI.MultiSelectCombo)},function(e,t){BI.MultiSelectNoBarCombo=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.MultiSelectNoBarCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-combo-no-bar",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,itemHeight:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,height:24})},_init:function(){var e=this,t=this.options;BI.MultiSelectNoBarCombo.superclass._init.apply(this,arguments);var n=function(){BI.isKey(e._startValue)&&(e.storeValue.type===BI.Selection.All?(BI.remove(e.storeValue.value,e._startValue),e.storeValue.assist=e.storeValue.assist||[],e.storeValue.assist.pushDistinct(e._startValue)):(BI.pushDistinct(e.storeValue.value,e._startValue),BI.remove(e.storeValue.assist,e._startValue))),e.trigger.getSearcher().setState(e.storeValue),e.numberCounter.setButtonChecked(e.storeValue)};this.storeValue={type:BI.Selection.Multi,value:t.value||[]},this.requesting=!1,this.trigger=BI.createWidget({type:"bi.multi_select_trigger",height:t.height-2,text:t.text,masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:t.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),itemHeight:t.itemHeight,value:{type:BI.Selection.Multi,value:t.value}}),this.trigger.on(BI.MultiSelectTrigger.EVENT_FOCUS,(function(){e.fireEvent(BI.MultiSelectNoBarCombo.EVENT_FOCUS)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_BLUR,(function(){e.fireEvent(BI.MultiSelectNoBarCombo.EVENT_BLUR)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_START,(function(){e._setStartValue(""),this.getSearcher().setValue(e.storeValue)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_STOP,(function(){e._setStartValue(""),e.fireEvent(BI.MultiSelectNoBarCombo.EVENT_STOP)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_SEARCHING,(function(t){var i=BI.last(t);(t=BI.initial(t||[])).length>0&&e._joinKeywords(t,(function(){BI.endWith(i,BI.BlankSplitChar)?(e.combo.setValue(e.storeValue),n(),e.combo.populate(),e._setStartValue("")):(e.combo.setValue(e.storeValue),n()),e._dataChange=!0}))})),this.trigger.on(BI.MultiSelectTrigger.EVENT_CHANGE,(function(t,i){i instanceof BI.MultiSelectBar?e._joinAll(this.getValue(),(function(){n()})):e._join(this.getValue(),(function(){n()})),e._dataChange=!0,e.fireEvent(BI.MultiSelectNoBarCombo.EVENT_CLICK_ITEM)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW,(function(){e.numberCounter.updateSelectedValue(e.storeValue)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_COUNTER_CLICK,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!1,container:t.container,el:this.trigger,adjustLength:1,popup:{type:"bi.multi_select_no_bar_popup_view",ref:function(){e.popup=this,e.trigger.setAdapter(this),e.numberCounter.setAdapter(this)},listeners:[{eventName:BI.MultiSelectPopupView.EVENT_CHANGE,action:function(){e._dataChange=!0,e.storeValue=this.getValue(),e._adjust((function(){n()})),e.fireEvent(BI.MultiSelectNoBarCombo.EVENT_CLICK_ITEM)}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CONFIRM,action:function(){e._defaultState()}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CLEAR,action:function(){e._dataChange=!0,e.setValue(),e._defaultState()}}],itemsCreator:t.itemsCreator,itemHeight:t.itemHeight,valueFormatter:t.valueFormatter,onLoaded:function(){BI.nextTick((function(){e.combo.adjustWidth(),e.combo.adjustHeight(),e.numberCounter.adjustView(),e.trigger.getSearcher().adjustView()}))}},value:{type:BI.Selection.Multi,value:t.value},hideChecker:function(t){return 0===i.element.find(t.target).length&&0===e.numberCounter.element.find(t.target).length}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){this.isViewVisible()||(e._dataChange=!1),this.setValue(e.storeValue),BI.nextTick((function(){e._populate()}))})),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,(function(){e._stopEditing(),!0===e.requesting?e.wants2Quit=!0:e._dataChange&&e.fireEvent(BI.MultiSelectNoBarCombo.EVENT_CONFIRM)}));var i=BI.createWidget({type:"bi.trigger_icon_button",width:t.height,height:t.height,cls:"multi-select-trigger-icon-button"});i.on(BI.TriggerIconButton.EVENT_CHANGE,(function(){e.numberCounter.hideView(),e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()})),this.numberCounter=BI.createWidget({type:"bi.multi_select_check_selected_switcher",masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:t.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),value:{type:BI.Selection.Multi,value:t.value}}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,(function(){this.updateSelectedValue(e.storeValue)})),this.numberCounter.on(BI.Events.VIEW,(function(t){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(!0===t?e.numberCounter.element.outerWidth()+8:0)}))})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,(function(){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(0)}))})),this.trigger.element.click((function(t){e.trigger.element.find(t.target).length>0&&e.numberCounter.hideView()})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:i,right:0,top:0,bottom:0},{el:{type:"bi.vertical_adapt",items:[this.numberCounter]},right:t.height,top:0,height:t.height}]})},_addItem:function(e,t){var n=this,i=this.trigger.getSearcher().getKeyword();this._join({type:BI.Selection.Multi,value:[i]},(function(){n.storeValue.type===BI.Selection.Multi&&BI.pushDistinct(n.storeValue.value,i),n.combo.setValue(n.storeValue),n._setStartValue(i),e(),n.populate(),n._setStartValue(""),n._dataChange=!0}))},_itemsCreator4Trigger:function(e,t){var n=this;this.options.itemsCreator(e,(function(i){1===e.times&&BI.isNotNull(e.keywords)&&n.trigger.setValue(BI.deepClone(n.storeValue)),t.apply(n,arguments)}))},_stopEditing:function(){this.trigger.stopEditing(),this.numberCounter.hideView()},_defaultState:function(){this._stopEditing(),this.combo.hideView()},_assertValue:function(e){e||(e={}),e.type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(e,t){var n=this,i=this.options;this._assertValue(this.storeValue),this.requesting=!0,i.itemsCreator({type:BI.MultiSelectNoBarCombo.REQ_GET_ALL_DATA,keywords:e},(function(i){var r,a,o=BI.map(i.items,"value");r=o,a=n._makeMap(r),BI.each(e,(function(e,t){BI.isNotNull(a[t])&&(n.storeValue.type===BI.Selection.Multi?BI.pushDistinct(n.storeValue.value,t):BI.remove(n.storeValue.value,t))})),n._adjust(t)}))},_joinAll:function(e,t){var n=this,i=this.options;this._assertValue(e),this.requesting=!0,i.itemsCreator({type:BI.MultiSelectNoBarCombo.REQ_GET_ALL_DATA,keywords:[this.trigger.getKey()]},(function(i){var r=BI.map(i.items,"value");if(n.storeValue.type===e.type){var a=!1,o=n._makeMap(n.storeValue.value);return BI.each(r,(function(e,t){BI.isNotNull(o[t])&&(a=!0,n.storeValue.assist&&n.storeValue.assist.push(o[t]),delete o[t])})),a&&(n.storeValue.value=BI.values(o)),void n._adjust(t)}var s=n._makeMap(n.storeValue.value),l=n._makeMap(e.value),u=[];BI.each(r,(function(e,t){BI.isNotNull(s[r[e]])&&(n.storeValue.assist&&n.storeValue.assist.push(s[r[e]]),delete s[r[e]]),BI.isNull(l[r[e]])&&(BI.remove(n.storeValue.assist,t),u.push(t))})),n.storeValue.value=u.concat(BI.values(s)),n._adjust(t)}))},_adjust:function(e){var t=this;this.options;!function(){!0===t.wants2Quit&&(t._dataChange&&t.fireEvent(BI.MultiSelectNoBarCombo.EVENT_CONFIRM),t.wants2Quit=!1);t.requesting=!1}(),e()},_join:function(e,t){var n=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var i=this._makeMap(this.storeValue.value);BI.each(e.value,(function(e,t){i[t]||(BI.pushDistinct(n.storeValue.value,t),BI.remove(n.storeValue.assist,t),i[t]=t)}));var r=!1;return BI.each(e.assist,(function(e,t){BI.isNotNull(i[t])&&(r=!0,n.storeValue.assist&&n.storeValue.assist.push(i[t]),delete i[t])})),r&&(this.storeValue.value=BI.values(i)),void n._adjust(t)}this._joinAll(e,t)},_setStartValue:function(e){this._startValue=e,this.popup.setStartValue(e)},_populate:function(){this.combo.populate.apply(this.combo,arguments)},showView:function(){this.combo.showView()},hideView:function(){this.combo.hideView()},setValue:function(e){this.storeValue={type:BI.Selection.Multi,value:e||[]},this.combo.setValue(this.storeValue),this.numberCounter.setValue(this.storeValue)},getValue:function(){return BI.deepClone(this.storeValue.value)},populate:function(){this._populate.apply(this,arguments),this.numberCounter.populateSwitcher.apply(this.numberCounter,arguments)}}),BI.extend(BI.MultiSelectNoBarCombo,{REQ_GET_DATA_LENGTH:1,REQ_GET_ALL_DATA:-1}),BI.MultiSelectNoBarCombo.EVENT_BLUR="EVENT_BLUR",BI.MultiSelectNoBarCombo.EVENT_FOCUS="EVENT_FOCUS",BI.MultiSelectNoBarCombo.EVENT_STOP="EVENT_STOP",BI.MultiSelectNoBarCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiSelectNoBarCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.MultiSelectNoBarCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.shortcut("bi.multi_select_no_bar_combo",BI.MultiSelectNoBarCombo)},function(e,t){BI.MultiSelectInsertCombo=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.MultiSelectInsertCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-insert-combo",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,height:24,itemHeight:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,allowEdit:!0})},_init:function(){var e=this,t=this.options;BI.MultiSelectInsertCombo.superclass._init.apply(this,arguments);var n=function(){BI.isKey(e._startValue)&&(e.storeValue.type===BI.Selection.All?(BI.remove(e.storeValue.value,e._startValue),e.storeValue.assist=e.storeValue.assist||[],e.storeValue.assist.pushDistinct(e._startValue)):(BI.pushDistinct(e.storeValue.value,e._startValue),BI.remove(e.storeValue.assist,e._startValue))),e.trigger.getSearcher().setState(e.storeValue),e.numberCounter.setButtonChecked(e.storeValue)};this.storeValue=t.value||{},this.requesting=!1,this.trigger=BI.createWidget({type:"bi.multi_select_insert_trigger",allowEdit:t.allowEdit,height:t.height-2,text:t.text,watermark:t.watermark,masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:t.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),itemHeight:t.itemHeight,value:t.value}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_FOCUS,(function(){e.fireEvent(BI.MultiSelectInsertCombo.EVENT_FOCUS)})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_BLUR,(function(){e.fireEvent(BI.MultiSelectInsertCombo.EVENT_BLUR)})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_START,(function(){e._setStartValue(""),this.getSearcher().setValue(e.storeValue)})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_STOP,(function(){e._setStartValue(""),e.fireEvent(BI.MultiSelectInsertCombo.EVENT_STOP)})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_PAUSE,(function(){e._addItem(n,!0),e.fireEvent(BI.MultiSelectInsertCombo.EVENT_ADD_ITEM,this.getSearcher().getKeyword())})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_SEARCHING,(function(t){var i=BI.last(t);(t=BI.initial(t||[])).length>0&&e._joinKeywords(t,(function(){BI.endWith(i,BI.BlankSplitChar)?(e.combo.setValue(e.storeValue),n(),e.combo.populate(),e._setStartValue("")):(e.combo.setValue(e.storeValue),n()),e._dataChange=!0})),e.fireEvent(BI.MultiSelectInsertCombo.EVENT_SEARCHING)})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_CHANGE,(function(t,i){i instanceof BI.MultiSelectBar?e._joinAll(this.getValue(),(function(){n()})):e._join(this.getValue(),(function(){n()})),e._dataChange=!0,e.fireEvent(BI.MultiSelectInsertCombo.EVENT_CLICK_ITEM)})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW,(function(){e.numberCounter.updateSelectedValue(e.storeValue)})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_COUNTER_CLICK,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!t.allowEdit,el:this.trigger,adjustLength:1,container:t.container,popup:{type:"bi.multi_select_popup_view",ref:function(){e.popup=this,e.trigger.setAdapter(this),e.numberCounter.setAdapter(this)},listeners:[{eventName:BI.MultiSelectPopupView.EVENT_CHANGE,action:function(){e._dataChange=!0,e.storeValue=this.getValue(),e._adjust((function(){n()})),e.fireEvent(BI.MultiSelectInsertCombo.EVENT_CLICK_ITEM)}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CONFIRM,action:function(){e._defaultState()}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CLEAR,action:function(){e._dataChange=!0,e.setValue(),e._defaultState()}}],itemsCreator:t.itemsCreator,valueFormatter:t.valueFormatter,itemHeight:t.itemHeight,onLoaded:function(){BI.nextTick((function(){e.combo.adjustWidth(),e.combo.adjustHeight(),e.numberCounter.adjustView(),e.trigger.getSearcher().adjustView()}))}},value:t.value,hideChecker:function(t){return 0===i.element.find(t.target).length&&0===e.numberCounter.element.find(t.target).length}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){this.isViewVisible()||(e._dataChange=!1),this.setValue(e.storeValue),BI.nextTick((function(){e._populate()}))})),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,(function(){e._stopEditing(),!0===e.requesting?e.wants2Quit=!0:e._dataChange&&e.fireEvent(BI.MultiSelectInsertCombo.EVENT_CONFIRM)}));var i=BI.createWidget({type:"bi.trigger_icon_button",width:t.height,height:t.height,cls:"multi-select-trigger-icon-button"});i.on(BI.TriggerIconButton.EVENT_CHANGE,(function(){e.numberCounter.hideView(),e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()})),this.numberCounter=BI.createWidget({type:"bi.multi_select_check_selected_switcher",masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:t.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),value:t.value}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,(function(){this.updateSelectedValue(e.storeValue)})),this.numberCounter.on(BI.Events.VIEW,(function(t){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(!0===t?e.numberCounter.element.outerWidth()+8:0)}))})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,(function(){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(0)}))})),this.trigger.element.click((function(t){e.trigger.element.find(t.target).length>0&&e.numberCounter.hideView()})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:i,right:0,top:0,bottom:0},{el:{type:"bi.vertical_adapt",items:[this.numberCounter]},right:t.height,top:0,height:t.height}]})},_itemsCreator4Trigger:function(e,t){var n=this;this.options.itemsCreator(e,(function(i){1===e.times&&BI.isNotNull(e.keywords)&&n.trigger.setValue(BI.deepClone(n.getValue())),t.apply(n,arguments)}))},_addItem:function(e){var t=this,n=this.trigger.getSearcher().getKeyword();this._join({type:BI.Selection.Multi,value:[n]},(function(){t.storeValue.type===BI.Selection.Multi&&BI.pushDistinct(t.storeValue.value,n),t.combo.setValue(t.storeValue),t._setStartValue(n),e(),t.populate(),t._setStartValue(""),t._dataChange=!0}))},_stopEditing:function(){this.trigger.stopEditing(),this.numberCounter.hideView()},_defaultState:function(){this._stopEditing(),this.combo.hideView()},_assertValue:function(e){e||(e={}),e.type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(e,t){var n=this;this.options;this._assertValue(this.storeValue),this.requesting=!0,BI.each(e,(function(e,t){n.storeValue.type===BI.Selection.Multi?BI.pushDistinct(n.storeValue.value,t):BI.remove(n.storeValue.value,t)})),n._adjust(t)},_joinAll:function(e,t){var n=this,i=this.options;this._assertValue(e),this.requesting=!0,i.itemsCreator({type:BI.MultiSelectInsertCombo.REQ_GET_ALL_DATA,keywords:[this.trigger.getKey()]},(function(i){var r=BI.map(i.items,"value");if(n.storeValue.type===e.type){var a=!1,o=n._makeMap(n.storeValue.value);return BI.each(r,(function(e,t){BI.isNotNull(o[t])&&(a=!0,n.storeValue.assist&&n.storeValue.assist.push(o[t]),delete o[t])})),a&&(n.storeValue.value=BI.values(o)),void n._adjust(t)}var s=n._makeMap(n.storeValue.value),l=n._makeMap(e.value),u=[];BI.each(r,(function(e,t){BI.isNotNull(s[r[e]])&&(n.storeValue.assist&&n.storeValue.assist.push(s[r[e]]),delete s[r[e]]),BI.isNull(l[r[e]])&&(BI.remove(n.storeValue.assist,t),u.push(t))})),n.storeValue.value=u.concat(BI.values(s)),n._adjust(t)}))},_adjust:function(e){var t=this;this.options;!function(){!0===t.wants2Quit&&(t._dataChange&&t.fireEvent(BI.MultiSelectInsertCombo.EVENT_CONFIRM),t.wants2Quit=!1);t.requesting=!1}(),e()},_join:function(e,t){var n=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var i=this._makeMap(this.storeValue.value);BI.each(e.value,(function(e,t){i[t]||(BI.pushDistinct(n.storeValue.value,t),BI.remove(n.storeValue.assist,t),i[t]=t)}));var r=!1;return BI.each(e.assist,(function(e,t){BI.isNotNull(i[t])&&(r=!0,n.storeValue.assist&&n.storeValue.assist.push(i[t]),delete i[t])})),r&&(this.storeValue.value=BI.values(i)),void n._adjust(t)}this._joinAll(e,t)},_setStartValue:function(e){this._startValue=e,this.popup.setStartValue(e)},_populate:function(){this.combo.populate.apply(this.combo,arguments)},showView:function(){this.combo.showView()},hideView:function(){this.combo.hideView()},setValue:function(e){this.storeValue=e||{},this._assertValue(this.storeValue),this.combo.setValue(this.storeValue),this.numberCounter.setValue(this.storeValue)},getValue:function(){return BI.deepClone(this.storeValue)},populate:function(){this._populate.apply(this,arguments),this.numberCounter.populateSwitcher.apply(this.numberCounter,arguments)}}),BI.extend(BI.MultiSelectInsertCombo,{REQ_GET_DATA_LENGTH:1,REQ_GET_ALL_DATA:-1}),BI.MultiSelectInsertCombo.EVENT_FOCUS="EVENT_FOCUS",BI.MultiSelectInsertCombo.EVENT_BLUR="EVENT_BLUR",BI.MultiSelectInsertCombo.EVENT_STOP="EVENT_STOP",BI.MultiSelectInsertCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiSelectInsertCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.MultiSelectInsertCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.MultiSelectInsertCombo.EVENT_ADD_ITEM="EVENT_ADD_ITEM",BI.shortcut("bi.multi_select_insert_combo",BI.MultiSelectInsertCombo)},function(e,t){BI.MultiSelectInsertNoBarCombo=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.MultiSelectInsertNoBarCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-insert-combo-no-bar",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,itemHeight:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,height:24})},_init:function(){var e=this,t=this.options;BI.MultiSelectInsertNoBarCombo.superclass._init.apply(this,arguments);var n=function(){BI.isKey(e._startValue)&&(e.storeValue.type===BI.Selection.All?(BI.remove(e.storeValue.value,e._startValue),e.storeValue.assist=e.storeValue.assist||[],e.storeValue.assist.pushDistinct(e._startValue)):(BI.pushDistinct(e.storeValue.value,e._startValue),BI.remove(e.storeValue.assist,e._startValue))),e.trigger.getSearcher().setState(e.storeValue),e.numberCounter.setButtonChecked(e.storeValue)};this.storeValue={type:BI.Selection.Multi,value:t.value||[]},this.requesting=!1,this.trigger=BI.createWidget({type:"bi.multi_select_insert_trigger",height:t.height-2,text:t.text,masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:t.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),itemHeight:t.itemHeight,value:{type:BI.Selection.Multi,value:t.value}}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_START,(function(){e._setStartValue(""),this.getSearcher().setValue(e.storeValue)})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_STOP,(function(){e._setStartValue("")})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_PAUSE,(function(){e._addItem(n,!0),e.fireEvent(BI.MultiSelectInsertNoBarCombo.EVENT_ADD_ITEM,this.getSearcher().getKeyword())})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_SEARCHING,(function(t){var i=BI.last(t);(t=BI.initial(t||[])).length>0&&e._joinKeywords(t,(function(){BI.endWith(i,BI.BlankSplitChar)?(e.combo.setValue(e.storeValue),n(),e.combo.populate(),e._setStartValue("")):(e.combo.setValue(e.storeValue),n()),e._dataChange=!0}))})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_CHANGE,(function(t,i){i instanceof BI.MultiSelectBar?e._joinAll(this.getValue(),(function(){n()})):e._join(this.getValue(),(function(){n()})),e._dataChange=!0})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW,(function(){e.numberCounter.updateSelectedValue(e.storeValue)})),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_COUNTER_CLICK,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!1,container:t.container,el:this.trigger,adjustLength:1,popup:{type:"bi.multi_select_no_bar_popup_view",ref:function(){e.popup=this,e.trigger.setAdapter(this),e.numberCounter.setAdapter(this)},listeners:[{eventName:BI.MultiSelectPopupView.EVENT_CHANGE,action:function(){e._dataChange=!0,e.storeValue=this.getValue(),e._adjust((function(){n()}))}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CONFIRM,action:function(){e._defaultState()}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CLEAR,action:function(){e._dataChange=!0,e.setValue(),e._defaultState()}}],itemsCreator:t.itemsCreator,itemHeight:t.itemHeight,valueFormatter:t.valueFormatter,onLoaded:function(){BI.nextTick((function(){e.combo.adjustWidth(),e.combo.adjustHeight(),e.numberCounter.adjustView(),e.trigger.getSearcher().adjustView()}))}},value:{type:BI.Selection.Multi,value:t.value},hideChecker:function(t){return 0===i.element.find(t.target).length&&0===e.numberCounter.element.find(t.target).length}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){this.isViewVisible()||(e._dataChange=!1),this.setValue(e.storeValue),BI.nextTick((function(){e._populate()}))})),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,(function(){e._stopEditing(),!0===e.requesting?e.wants2Quit=!0:e._dataChange&&e.fireEvent(BI.MultiSelectInsertNoBarCombo.EVENT_CONFIRM)}));var i=BI.createWidget({type:"bi.trigger_icon_button",width:t.height,height:t.height,cls:"multi-select-trigger-icon-button"});i.on(BI.TriggerIconButton.EVENT_CHANGE,(function(){e.numberCounter.hideView(),e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()})),this.numberCounter=BI.createWidget({type:"bi.multi_select_check_selected_switcher",masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:t.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),value:{type:BI.Selection.Multi,value:t.value}}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,(function(){this.updateSelectedValue(e.storeValue)})),this.numberCounter.on(BI.Events.VIEW,(function(t){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(!0===t?e.numberCounter.element.outerWidth()+8:0)}))})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,(function(){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(0)}))})),this.trigger.element.click((function(t){e.trigger.element.find(t.target).length>0&&e.numberCounter.hideView()})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:i,right:0,top:0,bottom:0},{el:{type:"bi.vertical_adapt",items:[this.numberCounter]},right:t.height,top:0,height:t.height}]})},_itemsCreator4Trigger:function(e,t){var n=this;this.options.itemsCreator(e,(function(i){1===e.times&&BI.isNotNull(e.keywords)&&n.trigger.setValue(BI.deepClone(n.storeValue)),t.apply(n,arguments)}))},_addItem:function(e){var t=this,n=this.trigger.getSearcher().getKeyword();this._join({type:BI.Selection.Multi,value:[n]},(function(){t.storeValue.type===BI.Selection.Multi&&BI.pushDistinct(t.storeValue.value,n),t.combo.setValue(t.storeValue),t._setStartValue(n),e(),t.populate(),t._setStartValue(""),t._dataChange=!0}))},_stopEditing:function(){this.trigger.stopEditing(),this.numberCounter.hideView()},_defaultState:function(){this._stopEditing(),this.combo.hideView()},_assertValue:function(e){e||(e={}),e.type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(e,t){var n=this;this.options;this._assertValue(this.storeValue),this.requesting=!0,BI.each(e,(function(e,t){n.storeValue.type===BI.Selection.Multi?BI.pushDistinct(n.storeValue.value,t):BI.remove(n.storeValue.value,t)})),n._adjust(t)},_joinAll:function(e,t){var n=this,i=this.options;this._assertValue(e),this.requesting=!0,i.itemsCreator({type:BI.MultiSelectInsertNoBarCombo.REQ_GET_ALL_DATA,keywords:[this.trigger.getKey()]},(function(i){var r=BI.map(i.items,"value");if(n.storeValue.type===e.type){var a=!1,o=n._makeMap(n.storeValue.value);return BI.each(r,(function(e,t){BI.isNotNull(o[t])&&(a=!0,n.storeValue.assist&&n.storeValue.assist.push(o[t]),delete o[t])})),a&&(n.storeValue.value=BI.values(o)),void n._adjust(t)}var s=n._makeMap(n.storeValue.value),l=n._makeMap(e.value),u=[];BI.each(r,(function(e,t){BI.isNotNull(s[r[e]])&&(n.storeValue.assist&&n.storeValue.assist.push(s[r[e]]),delete s[r[e]]),BI.isNull(l[r[e]])&&(BI.remove(n.storeValue.assist,t),u.push(t))})),n.storeValue.value=u.concat(BI.values(s)),n._adjust(t)}))},_adjust:function(e){var t=this;this.options;!function(){!0===t.wants2Quit&&(t.fireEvent(BI.MultiSelectInsertNoBarCombo.EVENT_CONFIRM),t.wants2Quit=!1);t.requesting=!1}(),e()},_join:function(e,t){var n=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var i=this._makeMap(this.storeValue.value);BI.each(e.value,(function(e,t){i[t]||(n.storeValue.value.push(t),BI.remove(n.storeValue.assist,t),i[t]=t)}));var r=!1;return BI.each(e.assist,(function(e,t){BI.isNotNull(i[t])&&(r=!0,n.storeValue.assist&&n.storeValue.assist.push(i[t]),delete i[t])})),r&&(this.storeValue.value=BI.values(i)),void n._adjust(t)}this._joinAll(e,t)},_setStartValue:function(e){this._startValue=e,this.popup.setStartValue(e)},_populate:function(){this.combo.populate.apply(this.combo,arguments)},showView:function(){this.combo.showView()},hideView:function(){this.combo.hideView()},setValue:function(e){this.storeValue={type:BI.Selection.Multi,value:e||[]},this.combo.setValue(this.storeValue),this.numberCounter.setValue(this.storeValue)},getValue:function(){return BI.deepClone(this.storeValue.value)},populate:function(){this._populate.apply(this,arguments),this.numberCounter.populateSwitcher.apply(this.numberCounter,arguments)}}),BI.extend(BI.MultiSelectInsertNoBarCombo,{REQ_GET_DATA_LENGTH:1,REQ_GET_ALL_DATA:-1}),BI.MultiSelectInsertNoBarCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.MultiSelectInsertNoBarCombo.EVENT_ADD_ITEM="EVENT_ADD_ITEM",BI.shortcut("bi.multi_select_insert_no_bar_combo",BI.MultiSelectInsertNoBarCombo)},function(e,t){BI.MultiSelectInsertTrigger=BI.inherit(BI.Trigger,{constants:{height:14,rgap:4,lgap:4},_defaultConfig:function(){return BI.extend(BI.MultiSelectInsertTrigger.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-trigger",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,itemHeight:24,searcher:{},switcher:{},adapter:null,masker:{},allowEdit:!0})},_init:function(){BI.MultiSelectInsertTrigger.superclass._init.apply(this,arguments);var e=this,t=this.options;this.searcher=BI.createWidget(t.searcher,{type:"bi.multi_select_insert_searcher",height:t.height,text:t.text,itemsCreator:t.itemsCreator,valueFormatter:t.valueFormatter,itemHeight:t.itemHeight,watermark:t.watermark,popup:{},adapter:t.adapter,masker:t.masker,value:t.value}),this.searcher.on(BI.MultiSelectInsertSearcher.EVENT_START,(function(){e.fireEvent(BI.MultiSelectInsertTrigger.EVENT_START)})),this.searcher.on(BI.MultiSelectInsertSearcher.EVENT_PAUSE,(function(){e.fireEvent(BI.MultiSelectInsertTrigger.EVENT_PAUSE)})),this.searcher.on(BI.MultiSelectInsertSearcher.EVENT_SEARCHING,(function(){e.fireEvent(BI.MultiSelectInsertTrigger.EVENT_SEARCHING,arguments)})),this.searcher.on(BI.MultiSelectInsertSearcher.EVENT_STOP,(function(){e.fireEvent(BI.MultiSelectInsertTrigger.EVENT_STOP)})),this.searcher.on(BI.MultiSelectInsertSearcher.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectInsertTrigger.EVENT_CHANGE,arguments)})),this.searcher.on(BI.MultiSelectInsertSearcher.EVENT_BLUR,(function(){e.fireEvent(BI.MultiSelectInsertTrigger.EVENT_BLUR)})),this.searcher.on(BI.MultiSelectInsertSearcher.EVENT_FOCUS,(function(){e.fireEvent(BI.MultiSelectInsertTrigger.EVENT_FOCUS)})),this.wrapNumberCounter=BI.createWidget({type:"bi.layout"}),this.wrapper=BI.createWidget({type:"bi.htape",element:this,items:[{el:this.searcher,width:"fill"},{el:this.wrapNumberCounter,width:0},{el:BI.createWidget(),width:24}]}),!t.allowEdit&&BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.text",title:function(){return e.searcher.getState()}},left:0,right:24,top:0,bottom:0}]})},refreshPlaceHolderWidth:function(e){this.wrapper.attr("items")[1].width=e,this.wrapper.resize()},getSearcher:function(){return this.searcher},stopEditing:function(){this.searcher.stopSearch()},setAdapter:function(e){this.searcher.setAdapter(e)},setValue:function(e){this.searcher.setValue(e)},getKey:function(){return this.searcher.getKey()},getValue:function(){return this.searcher.getValue()}}),BI.MultiSelectInsertTrigger.EVENT_TRIGGER_CLICK="EVENT_TRIGGER_CLICK",BI.MultiSelectInsertTrigger.EVENT_COUNTER_CLICK="EVENT_COUNTER_CLICK",BI.MultiSelectInsertTrigger.EVENT_CHANGE="EVENT_CHANGE",BI.MultiSelectInsertTrigger.EVENT_START="EVENT_START",BI.MultiSelectInsertTrigger.EVENT_STOP="EVENT_STOP",BI.MultiSelectInsertTrigger.EVENT_PAUSE="EVENT_PAUSE",BI.MultiSelectInsertTrigger.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiSelectInsertTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW="EVENT_BEFORE_COUNTER_POPUPVIEW",BI.MultiSelectInsertTrigger.EVENT_FOCUS="EVENT_FOCUS",BI.MultiSelectInsertTrigger.EVENT_BLUR="EVENT_BLUR",BI.shortcut("bi.multi_select_insert_trigger",BI.MultiSelectInsertTrigger)},function(e,t){BI.MultiSelectLoader=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiSelectLoader.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-loader",logic:{dynamic:!0},el:{height:400},valueFormatter:BI.emptyFn,itemsCreator:BI.emptyFn,onLoaded:BI.emptyFn,itemHeight:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT})},_init:function(){BI.MultiSelectLoader.superclass._init.apply(this,arguments);var e=this,t=this.options,n=!1;this.storeValue=t.value||{},this._assertValue(this.storeValue),this.button_group=BI.createWidget({type:"bi.select_list",logic:t.logic,toolbar:{type:"bi.multi_select_bar",cls:"bi-list-item-active",iconWrapperWidth:36},el:BI.extend({onLoaded:t.onLoaded,el:{type:"bi.loader",isDefaultInit:!1,logic:{dynamic:!0,scrolly:!0},el:{chooseType:BI.ButtonGroup.CHOOSE_TYPE_MULTI,behaviors:{redmark:function(){return!0}},layouts:[{type:"bi.vertical"}]}}},t.el),itemsCreator:function(i,r){var a=e._startValue;e.storeValue&&(i=BI.extend(i||{},{selectedValues:BI.isKey(a)&&e.storeValue.type===BI.Selection.Multi?e.storeValue.value.concat(a):e.storeValue.value})),t.itemsCreator(i,(function(o){n=o.hasNext;var s=[];if(1===i.times&&e.storeValue){var l=BI.map(e.storeValue.value,(function(n,i){var r=t.valueFormatter(i)||i;return{text:r,value:i,title:r,selected:e.storeValue.type===BI.Selection.Multi}}));if(BI.isKey(e._startValue)&&!BI.contains(e.storeValue.value,e._startValue)){var u=t.valueFormatter(a)||a;l.unshift({text:u,value:a,title:u,selected:!0})}s=e._createItems(l)}r(s.concat(e._createItems(o.items)),o.keyword||""),1===i.times&&e.storeValue&&(BI.isKey(a)&&(e.storeValue.type===BI.Selection.All?BI.remove(e.storeValue.value,a):BI.pushDistinct(e.storeValue.value,a)),e.setValue(e.storeValue)),1===i.times&&e._scrollToTop()}))},hasNext:function(){return n},value:this.storeValue}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Top),BI.extend({scrolly:!0,vgap:5},t.logic,{items:BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Top,this.button_group)})))),this.button_group.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.button_group.on(BI.SelectList.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectLoader.EVENT_CHANGE,arguments)}))},_createItems:function(e){return BI.createItems(e,{type:"bi.multi_select_item",logic:this.options.logic,cls:"bi-list-item-active",height:this.options.itemHeight||BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,selected:this.isAllSelected(),iconWrapperWidth:36})},_scrollToTop:function(){var e=this;BI.delay((function(){e.button_group.element.scrollTop(0)}),30)},isAllSelected:function(){return this.button_group.isAllSelected()},_assertValue:function(e){e||(e={}),e.type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},setStartValue:function(e){this._startValue=e},setValue:function(e){this.storeValue=e||{},this._assertValue(this.storeValue),this.button_group.setValue(this.storeValue)},getValue:function(){return this.button_group.getValue()},getAllButtons:function(){return this.button_group.getAllButtons()},empty:function(){this.button_group.empty()},populate:function(e){BI.isNotNull(e)&&(arguments[0]=this._createItems(e)),this.button_group.populate.apply(this.button_group,arguments)},resetHeight:function(e){this.button_group.resetHeight(e-10)},resetWidth:function(e){this.button_group.resetWidth(e)}}),BI.MultiSelectLoader.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_select_loader",BI.MultiSelectLoader)},function(e,t){BI.MultiSelectNoBarLoader=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiSelectNoBarLoader.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-loader",logic:{dynamic:!0},el:{height:400},valueFormatter:BI.emptyFn,itemsCreator:BI.emptyFn,itemHeight:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,onLoaded:BI.emptyFn})},_init:function(){BI.MultiSelectNoBarLoader.superclass._init.apply(this,arguments);var e=this,t=this.options,n=!1;this.storeValue=t.value||{},this._assertValue(this.storeValue),this.button_group=BI.createWidget(BI.extend({type:"bi.list_pane",onLoaded:t.onLoaded,el:{type:"bi.loader",isDefaultInit:!1,logic:{dynamic:!0,scrolly:!0},el:{chooseType:BI.ButtonGroup.CHOOSE_TYPE_MULTI,behaviors:{redmark:function(){return!0}},layouts:[{type:"bi.vertical"}]}},itemsCreator:function(i,r){var a=e._startValue;e.storeValue&&(i=BI.extend(i||{},{selectedValues:BI.isKey(a)&&e.storeValue.type===BI.Selection.Multi?e.storeValue.value.concat(a):e.storeValue.value})),t.itemsCreator(i,(function(o){n=o.hasNext;var s=[];if(1===i.times&&e.storeValue){var l=BI.map(e.storeValue.value,(function(n,i){var r=t.valueFormatter(i)||i;return{text:r,value:i,title:r,selected:e.storeValue.type===BI.Selection.Multi}}));if(BI.isKey(e._startValue)&&!BI.contains(e.storeValue.value,e._startValue)){var u=t.valueFormatter(a)||a;l.unshift({text:u,value:a,title:u,selected:!0})}s=e._createItems(l)}r(s.concat(e._createItems(o.items)),o.keyword||""),1===i.times&&e.storeValue&&(BI.isKey(a)&&(e.storeValue.type===BI.Selection.All?BI.remove(e.storeValue.value,a):BI.pushDistinct(e.storeValue.value,a)),e.setValue(e.storeValue)),1===i.times&&e._scrollToTop()}))},hasNext:function(){return n},value:this.storeValue},t.el)),BI.createWidget({type:"bi.vertical",element:this,items:[this.button_group],vgap:5}),this.button_group.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.button_group.on(BI.SelectList.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectNoBarLoader.EVENT_CHANGE,arguments)}))},_createItems:function(e){return BI.createItems(e,{type:"bi.multi_select_item",cls:"bi-list-item-active",logic:this.options.logic,height:this.options.itemHeight||BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,iconWrapperWidth:36})},_scrollToTop:function(){var e=this;BI.delay((function(){e.button_group.element.scrollTop(0)}),30)},_assertValue:function(e){e||(e={}),e.type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},setStartValue:function(e){this._startValue=e},setValue:function(e){this.storeValue=e||{},this._assertValue(this.storeValue),this.button_group.setValue(this.storeValue.value)},getValue:function(){return{type:BI.Selection.Multi,value:this.button_group.getValue()}},getAllButtons:function(){return this.button_group.getAllButtons()},empty:function(){this.button_group.empty()},populate:function(e){BI.isNotNull(e)&&(arguments[0]=this._createItems(e)),this.button_group.populate.apply(this.button_group,arguments)},resetHeight:function(e){this.button_group.element.css({"max-height":e/BI.pixRatio+BI.pixUnit})},resetWidth:function(){}}),BI.MultiSelectNoBarLoader.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_select_no_bar_loader",BI.MultiSelectNoBarLoader)},function(e,t){BI.MultiSelectPopupView=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiSelectPopupView.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-popup-view",maxWidth:"auto",minWidth:135,maxHeight:400,valueFormatter:BI.emptyFn,itemsCreator:BI.emptyFn,onLoaded:BI.emptyFn,itemHeight:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT})},_init:function(){BI.MultiSelectPopupView.superclass._init.apply(this,arguments);var e=this,t=this.options;this.loader=BI.createWidget({type:"bi.multi_select_loader",itemsCreator:t.itemsCreator,itemHeight:t.itemHeight,valueFormatter:t.valueFormatter,onLoaded:t.onLoaded,value:t.value}),this.popupView=BI.createWidget({type:"bi.multi_popup_view",stopPropagation:!1,maxWidth:t.maxWidth,minWidth:t.minWidth,maxHeight:t.maxHeight,element:this,buttons:[BI.i18nText("BI-Basic_Clears"),BI.i18nText("BI-Basic_Sure")],el:this.loader,value:t.value}),this.popupView.on(BI.MultiPopupView.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectPopupView.EVENT_CHANGE)})),this.popupView.on(BI.MultiPopupView.EVENT_CLICK_TOOLBAR_BUTTON,(function(t){switch(t){case 0:e.fireEvent(BI.MultiSelectPopupView.EVENT_CLICK_CLEAR);break;case 1:e.fireEvent(BI.MultiSelectPopupView.EVENT_CLICK_CONFIRM)}}))},isAllSelected:function(){return this.loader.isAllSelected()},setStartValue:function(e){this.loader.setStartValue(e)},setValue:function(e){this.popupView.setValue(e)},getValue:function(){return this.popupView.getValue()},populate:function(e){this.popupView.populate.apply(this.popupView,arguments)},resetHeight:function(e){this.popupView.resetHeight(e)},resetWidth:function(e){this.popupView.resetWidth(e)}}),BI.MultiSelectPopupView.EVENT_CHANGE="EVENT_CHANGE",BI.MultiSelectPopupView.EVENT_CLICK_CONFIRM="EVENT_CLICK_CONFIRM",BI.MultiSelectPopupView.EVENT_CLICK_CLEAR="EVENT_CLICK_CLEAR",BI.shortcut("bi.multi_select_popup_view",BI.MultiSelectPopupView)},function(e,t){BI.MultiSelectNoBarPopupView=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiSelectNoBarPopupView.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-popup-view",maxWidth:"auto",minWidth:135,maxHeight:400,valueFormatter:BI.emptyFn,itemsCreator:BI.emptyFn,itemHeight:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,onLoaded:BI.emptyFn})},_init:function(){BI.MultiSelectNoBarPopupView.superclass._init.apply(this,arguments);var e=this,t=this.options;this.loader=BI.createWidget({type:"bi.multi_select_no_bar_loader",itemsCreator:t.itemsCreator,itemHeight:t.itemHeight,valueFormatter:t.valueFormatter,onLoaded:t.onLoaded,value:t.value}),this.popupView=BI.createWidget({type:"bi.multi_popup_view",stopPropagation:!1,maxWidth:t.maxWidth,minWidth:t.minWidth,maxHeight:t.maxHeight,element:this,buttons:[BI.i18nText("BI-Basic_Clears"),BI.i18nText("BI-Basic_Sure")],el:this.loader,value:t.value}),this.popupView.on(BI.MultiPopupView.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectNoBarPopupView.EVENT_CHANGE)})),this.popupView.on(BI.MultiPopupView.EVENT_CLICK_TOOLBAR_BUTTON,(function(t){switch(t){case 0:e.fireEvent(BI.MultiSelectNoBarPopupView.EVENT_CLICK_CLEAR);break;case 1:e.fireEvent(BI.MultiSelectNoBarPopupView.EVENT_CLICK_CONFIRM)}}))},setStartValue:function(e){this.loader.setStartValue(e)},setValue:function(e){this.popupView.setValue(e)},getValue:function(){return this.popupView.getValue()},populate:function(e){this.popupView.populate.apply(this.popupView,arguments)},resetHeight:function(e){this.popupView.resetHeight(e)},resetWidth:function(e){this.popupView.resetWidth(e)}}),BI.MultiSelectNoBarPopupView.EVENT_CHANGE="EVENT_CHANGE",BI.MultiSelectNoBarPopupView.EVENT_CLICK_CONFIRM="EVENT_CLICK_CONFIRM",BI.MultiSelectNoBarPopupView.EVENT_CLICK_CLEAR="EVENT_CLICK_CLEAR",BI.shortcut("bi.multi_select_no_bar_popup_view",BI.MultiSelectNoBarPopupView)},function(e,t){BI.MultiSelectTrigger=BI.inherit(BI.Trigger,{constants:{height:14,rgap:4,lgap:4},_defaultConfig:function(){return BI.extend(BI.MultiSelectTrigger.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-trigger",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,searcher:{},switcher:{},adapter:null,masker:{},allowEdit:!0,itemHeight:24})},_init:function(){BI.MultiSelectTrigger.superclass._init.apply(this,arguments);var e=this,t=this.options;this.searcher=BI.createWidget(t.searcher,{type:"bi.multi_select_searcher",height:t.height,text:t.text,itemsCreator:t.itemsCreator,itemHeight:t.itemHeight,valueFormatter:t.valueFormatter,watermark:t.watermark,popup:{},adapter:t.adapter,masker:t.masker,value:t.value}),this.searcher.on(BI.MultiSelectSearcher.EVENT_START,(function(){e.fireEvent(BI.MultiSelectTrigger.EVENT_START)})),this.searcher.on(BI.MultiSelectSearcher.EVENT_PAUSE,(function(){e.fireEvent(BI.MultiSelectTrigger.EVENT_PAUSE)})),this.searcher.on(BI.MultiSelectSearcher.EVENT_SEARCHING,(function(){e.fireEvent(BI.MultiSelectTrigger.EVENT_SEARCHING,arguments)})),this.searcher.on(BI.MultiSelectSearcher.EVENT_STOP,(function(){e.fireEvent(BI.MultiSelectTrigger.EVENT_STOP)})),this.searcher.on(BI.MultiSelectSearcher.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectTrigger.EVENT_CHANGE,arguments)})),this.searcher.on(BI.MultiSelectSearcher.EVENT_BLUR,(function(){e.fireEvent(BI.MultiSelectTrigger.EVENT_BLUR)})),this.searcher.on(BI.MultiSelectSearcher.EVENT_FOCUS,(function(){e.fireEvent(BI.MultiSelectTrigger.EVENT_FOCUS)})),this.wrapNumberCounter=BI.createWidget({type:"bi.layout"}),this.wrapper=BI.createWidget({type:"bi.htape",element:this,items:[{el:this.searcher,width:"fill"},{el:this.wrapNumberCounter,width:0},{el:BI.createWidget(),width:24}]}),!t.allowEdit&&BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.text",title:function(){return e.searcher.getState()}},left:0,right:24,top:0,bottom:0}]})},refreshPlaceHolderWidth:function(e){this.wrapper.attr("items")[1].width=e,this.wrapper.resize()},getSearcher:function(){return this.searcher},stopEditing:function(){this.searcher.stopSearch()},setAdapter:function(e){this.searcher.setAdapter(e)},setValue:function(e){this.searcher.setValue(e)},getKey:function(){return this.searcher.getKey()},getValue:function(){return this.searcher.getValue()}}),BI.MultiSelectTrigger.EVENT_TRIGGER_CLICK="EVENT_TRIGGER_CLICK",BI.MultiSelectTrigger.EVENT_COUNTER_CLICK="EVENT_COUNTER_CLICK",BI.MultiSelectTrigger.EVENT_CHANGE="EVENT_CHANGE",BI.MultiSelectTrigger.EVENT_START="EVENT_START",BI.MultiSelectTrigger.EVENT_STOP="EVENT_STOP",BI.MultiSelectTrigger.EVENT_PAUSE="EVENT_PAUSE",BI.MultiSelectTrigger.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiSelectTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW="EVENT_BEFORE_COUNTER_POPUPVIEW",BI.MultiSelectTrigger.EVENT_BLUR="EVENT_BLUR",BI.MultiSelectTrigger.EVENT_FOCUS="EVENT_FOCUS",BI.shortcut("bi.multi_select_trigger",BI.MultiSelectTrigger)},function(e,t){BI.MultiSelectSearchInsertPane=BI.inherit(BI.Widget,{constants:{height:24,lgap:10,tgap:5},_defaultConfig:function(){return BI.extend(BI.MultiSelectSearchInsertPane.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-search-pane bi-card",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,keywordGetter:BI.emptyFn,itemHeight:24})},_init:function(){BI.MultiSelectSearchInsertPane.superclass._init.apply(this,arguments);var e=this,t=this.options;this.addNotMatchTip=BI.createWidget({type:"bi.label",text:BI.i18nText("BI-Basic_Click_To_Add_Text",""),height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,cls:"bi-high-light",hgap:5}),this.loader=BI.createWidget({type:"bi.multi_select_search_loader",keywordGetter:t.keywordGetter,valueFormatter:t.valueFormatter,itemsCreator:function(n,i){t.itemsCreator.apply(e,[n,function(n){i(n),e.setKeyword(t.keywordGetter())}])},itemHeight:t.itemHeight,value:t.value}),this.loader.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.resizer=BI.createWidget({type:"bi.vtape",element:this,items:[{el:this.addNotMatchTip,height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT},{el:this.loader}]})},setKeyword:function(e){this.addNotMatchTip.setText(BI.i18nText("BI-Basic_Click_To_Add_Text",e))},isAllSelected:function(){return this.loader.isAllSelected()},hasMatched:function(){return!1},setValue:function(e){this.loader.setValue(e)},getValue:function(){return this.loader.getValue()},empty:function(){this.loader.empty()},populate:function(e){this.loader.populate.apply(this.loader,arguments)}}),BI.MultiSelectSearchInsertPane.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_select_search_insert_pane",BI.MultiSelectSearchInsertPane)},function(e,t){BI.MultiSelectSearchLoader=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiSelectSearchLoader.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-search-loader",itemsCreator:BI.emptyFn,keywordGetter:BI.emptyFn,valueFormatter:BI.emptyFn,itemHeight:24})},_init:function(){BI.MultiSelectSearchLoader.superclass._init.apply(this,arguments);var e=this,t=this.options,n=!1;this.storeValue=BI.deepClone(t.value),this.button_group=BI.createWidget({type:"bi.select_list",toolbar:{type:"bi.multi_select_bar",cls:"bi-list-item-active",iconWrapperWidth:36},element:this,logic:{dynamic:!1},value:t.value,el:{tipText:BI.i18nText("BI-No_Select"),el:{type:"bi.loader",isDefaultInit:!1,logic:{dynamic:!0,scrolly:!0},el:{chooseType:BI.ButtonGroup.CHOOSE_TYPE_MULTI,behaviors:{redmark:function(){return!0}},layouts:[{type:"bi.vertical"}]}}},itemsCreator:function(i,r){e.storeValue&&(i=BI.extend(i||{},{selectedValues:e.storeValue.value})),t.itemsCreator(i,(function(a){var o=a.keyword=t.keywordGetter();n=a.hasNext;var s=[];if(1===i.times&&e.storeValue){var l=e._filterValues(e.storeValue);s=e._createItems(l)}r(s.concat(e._createItems(a.items)),o),1===i.times&&e.storeValue&&e.setValue(e.storeValue)}))},hasNext:function(){return n}}),this.button_group.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.button_group.on(BI.SelectList.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectSearchLoader.EVENT_CHANGE,arguments)}))},_createItems:function(e){return BI.createItems(e,{type:"bi.multi_select_item",logic:{dynamic:!1},height:this.options.itemHeight||BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT,selected:this.isAllSelected(),cls:"bi-list-item-active",iconWrapperWidth:36})},isAllSelected:function(){return this.button_group.isAllSelected()},_filterValues:function(e){var t=this.options,n=t.keywordGetter(),i=BI.deepClone(e.value)||[],r=BI.map(i,(function(e,n){return{text:t.valueFormatter(n)||n,value:n}}));if(BI.isKey(n)){var a=BI.Func.getSearchResult(r,n);i=a.match.concat(a.find)}return BI.map(i,(function(t,n){return{text:n.text,title:n.text,value:n.value,selected:e.type===BI.Selection.All}}))},setValue:function(e){this.storeValue=BI.deepClone(e),this.button_group.setValue(e)},getValue:function(){return this.button_group.getValue()},getAllButtons:function(){return this.button_group.getAllButtons()},empty:function(){this.button_group.empty()},populate:function(e){this.button_group.populate.apply(this.button_group,arguments)},resetHeight:function(e){this.button_group.resetHeight(e)},resetWidth:function(e){this.button_group.resetWidth(e)}}),BI.MultiSelectSearchLoader.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_select_search_loader",BI.MultiSelectSearchLoader)},function(e,t){BI.MultiSelectSearchPane=BI.inherit(BI.Widget,{constants:{height:24,lgap:10,tgap:5},_defaultConfig:function(){return BI.extend(BI.MultiSelectSearchPane.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-search-pane bi-card",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,keywordGetter:BI.emptyFn,itemHeight:24})},_init:function(){BI.MultiSelectSearchPane.superclass._init.apply(this,arguments);var e=this,t=this.options;this.loader=BI.createWidget({type:"bi.multi_select_search_loader",keywordGetter:t.keywordGetter,valueFormatter:t.valueFormatter,itemsCreator:function(n,i){t.itemsCreator.apply(e,[n,function(e){i(e)}])},itemHeight:t.itemHeight,value:t.value}),this.loader.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.resizer=BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.loader,left:0,right:0,bottom:0,top:0}]})},isAllSelected:function(){return this.loader.isAllSelected()},hasMatched:function(){},setValue:function(e){this.loader.setValue(e)},getValue:function(){return this.loader.getValue()},empty:function(){this.loader.empty()},populate:function(e){this.loader.populate.apply(this.loader,arguments)}}),BI.MultiSelectSearchPane.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_select_search_pane",BI.MultiSelectSearchPane)},function(e,t){BI.MultiSelectCheckSelectedButton=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.MultiSelectCheckSelectedButton.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-check-selected-button",itemsCreator:BI.emptyFn})},_init:function(){BI.MultiSelectCheckSelectedButton.superclass._init.apply(this,arguments);var e=this,t=this.options;this.numberCounter=BI.createWidget({type:"bi.text_button",element:this,hgap:4,text:"0",textAlign:"center",textHeight:16,cls:"bi-high-light-background count-tip"}),this.numberCounter.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.numberCounter.on(BI.TextButton.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectCheckSelectedButton.EVENT_CHANGE,arguments)})),this.numberCounter.element.hover((function(){e.numberCounter.setTag(e.numberCounter.getText()),e.numberCounter.setText(BI.i18nText("BI-Check_Selected"))}),(function(){e.numberCounter.setText(e.numberCounter.getTag())})),this.setVisible(!1),BI.isNotNull(t.value)&&this.setValue(t.value)},_populate:function(e){var t=this,n=this.options;e.type!==BI.Selection.All?BI.nextTick((function(){t.numberCounter.setText(e.value.length),t.setVisible(e.value.length>0)})):n.itemsCreator({type:BI.MultiSelectCombo.REQ_GET_DATA_LENGTH},(function(n){if(BI.isNotEmptyString(n.count))BI.nextTick((function(){t.numberCounter.setText(n.count),t.setVisible(!0)}));else{var i=n.count-e.value.length;BI.nextTick((function(){t.numberCounter.setText(i),t.setVisible(i>0)}))}}))},_assertValue:function(e){return e||(e={}),e.type||(e.type=BI.Selection.Multi),e.value||(e.value=[]),e},setValue:function(e){e=this._assertValue(e),this.options.value=e,this._populate(e)},populate:function(){this._populate(this._assertValue(this.options.value))},getValue:function(){}}),BI.MultiSelectCheckSelectedButton.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_select_check_selected_button",BI.MultiSelectCheckSelectedButton)},function(e,t){BI.MultiSelectEditor=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiSelectEditor.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-editor",el:{},watermark:BI.i18nText("BI-Basic_Search")})},_init:function(){BI.MultiSelectEditor.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget(t.el,{type:"bi.select_patch_editor",element:this,height:t.height,watermark:t.watermark,allowBlank:!0,value:t.value,defaultText:t.text,text:t.text,tipType:t.tipType,warningTitle:t.warningTitle}),this.editor.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.editor.on(BI.StateEditor.EVENT_FOCUS,(function(){e.fireEvent(BI.MultiSelectEditor.EVENT_FOCUS)})),this.editor.on(BI.StateEditor.EVENT_BLUR,(function(){e.fireEvent(BI.MultiSelectEditor.EVENT_BLUR)}))},focus:function(){this.editor.focus()},blur:function(){this.editor.blur()},setState:function(e){this.editor.setState(e)},setValue:function(e){this.editor.setValue(e)},setTipType:function(e){this.editor.setTipType(e)},getValue:function(){return this.editor.getValue()},getState:function(){return this.editor.getText()},getKeywords:function(){var e=this.editor.getValue(),t=e.split(/\u200b\s\u200b/);return BI.isEmptyString(t[t.length-1])&&(t=t.slice(0,t.length-1)),/\u200b\s\u200b$/.test(e)?t.concat([BI.BlankSplitChar]):t},getKeyword:function(){var e=this.editor.getValue().split(/\u200b\s\u200b/);return BI.isEmptyString(e[e.length-1])&&(e=e.slice(0,e.length-1)),BI.isEmptyArray(e)?"":e[e.length-1]},populate:function(e){}}),BI.MultiSelectEditor.EVENT_FOCUS="EVENT_FOCUS",BI.MultiSelectEditor.EVENT_BLUR="EVENT_BLUR",BI.MultiSelectEditor.EVENT_PAUSE="EVENT_PAUSE",BI.shortcut("bi.multi_select_editor",BI.MultiSelectEditor)},function(e,t){BI.SelectPatchEditor=BI.inherit(BI.Widget,{props:{baseCls:"bi-patch-select-editor",height:24},render:function(){var e=this,t=this.options,n=BI.debounce(BI.bind(this._dealChange,this),300);return BI.extend({type:"bi.state_editor",ref:function(t){e.editor=t},hgap:t.hgap,vgap:t.vgap,lgap:t.lgap,rgap:t.rgap,tgap:t.tgap,bgap:t.bgap,height:t.height,watermark:t.watermark,allowBlank:!0,value:t.value,defaultText:t.text,text:t.text,tipType:t.tipType,warningTitle:t.warningTitle,el:{type:"bi.textarea_editor",scrolly:!1,validationChecker:function(){return!0},throttle:!0},listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(t,i){BI.contains(i,"\n")?e._dealChange(t,i):n(t,i)}},{eventName:BI.Editor.EVENT_KEY_DOWN,action:function(t){t===BI.KeyCode.ENTER&&e._clearSplitValue()}},{eventName:BI.Editor.EVENT_FOCUS,action:function(){e.fireEvent(BI.SelectPatchEditor.EVENT_FOCUS,arguments)}},{eventName:BI.Editor.EVENT_BLUR,action:function(){e._start=!1,e.fireEvent(BI.SelectPatchEditor.EVENT_BLUR,arguments)}}]},t.el)},_clearSplitValue:function(){this.editor.setValue("")},_dealChange:function(e,t){var n="";t===this.editor.getValue()&&(BI.isKey(t)&&(n=this._formatText(t)),e===BI.Events.CHANGE&&(this._setValue(n),""!==this._trimValue(n)&&(this._start&&BI.isKey(this._lastValue)&&(!0!==this._pause||this._trimValue(this._lastValue)===this._trimValue(n))||(this._start=!0,this._pause=!1,this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.STARTEDIT,this.getValue(),this))),this._trimValue(this._lastValue)!==this._trimValue(n)&&this.fireEvent(BI.Controller.EVENT_CHANGE,arguments),BI.endWith(n,BI.BlankSplitChar)&&(this._pause=!0,this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.PAUSE,"",this))),e!==BI.Events.EMPTY&&e!==BI.Events.STOPEDIT||this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EMPTY),this._lastValue=n)},_trimValue:function(e){return BI.trim(BI.replaceAll(e||"",BI.BlankSplitChar,""))},_formatText:function(e){return BI.replaceAll(e||"","\n",BI.BlankSplitChar)},setWaterMark:function(e){this.editor.setWaterMark(e)},doRedMark:function(){this.editor.doRedMark.apply(this.editor,arguments)},unRedMark:function(){this.editor.unRedMark.apply(this.editor,arguments)},doHighLight:function(){this.editor.doHighLight.apply(this.editor,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},focus:function(){this.editor.focus()},blur:function(){this.editor.blur()},_setValue:function(e){this.editor.setValue(this._formatText(e))},_showInput:function(){this.editor.visible(),this.text.invisible()},_showHint:function(){this.editor.invisible(),this.text.visible()},isValid:function(){return this.editor.isValid()},setErrorText:function(e){this.editor.setErrorText(e)},getErrorText:function(){return this.editor.getErrorText()},isEditing:function(){return this.editor.isEditing()},getLastValidValue:function(){return this.editor.getLastValidValue()},getLastChangedValue:function(){return this.editor.getLastChangedValue()},setValue:function(e){this._setValue(e),this._lastValue=this._trimValue(e)},getValue:function(){return BI.trim(this.editor.getValue())},getState:function(){return this.editor.getState()},setState:function(e){this.editor.setState(e)},setTipType:function(e){this.editor.setTipType(e)},getText:function(){return this.editor.getText()}}),BI.SelectPatchEditor.EVENT_CHANGE="EVENT_CHANGE",BI.SelectPatchEditor.EVENT_FOCUS="EVENT_FOCUS",BI.SelectPatchEditor.EVENT_BLUR="EVENT_BLUR",BI.shortcut("bi.select_patch_editor",BI.SelectPatchEditor)},function(e,t){BI.MultiSelectInsertSearcher=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiSelectInsertSearcher.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-searcher",itemsCreator:BI.emptyFn,itemHeight:24,el:{},popup:{},valueFormatter:BI.emptyFn,adapter:null,masker:{},text:BI.i18nText("BI-Basic_Please_Select"),watermark:BI.i18nText("BI-Basic_Search_And_Patch_Paste")})},_init:function(){BI.MultiSelectInsertSearcher.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget(t.el,{type:"bi.multi_select_editor",watermark:t.watermark,height:t.height,text:t.text,listeners:[{eventName:BI.MultiSelectEditor.EVENT_FOCUS,action:function(){e.fireEvent(BI.MultiSelectInsertSearcher.EVENT_FOCUS)}},{eventName:BI.MultiSelectEditor.EVENT_BLUR,action:function(){e.fireEvent(BI.MultiSelectInsertSearcher.EVENT_BLUR)}}]}),this.searcher=BI.createWidget({type:"bi.searcher",element:this,height:t.height,isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t()},el:this.editor,popup:BI.extend({type:"bi.multi_select_search_insert_pane",valueFormatter:t.valueFormatter,keywordGetter:function(){return e.editor.getKeyword()},itemsCreator:function(n,i){var r=e.editor.getKeyword();n.keywords=[r],this.setKeyword(r),t.itemsCreator(n,i)},itemHeight:t.itemHeight,value:t.value},t.popup),adapter:t.adapter,masker:t.masker}),this.searcher.on(BI.Searcher.EVENT_START,(function(){e.fireEvent(BI.MultiSelectInsertSearcher.EVENT_START)})),this.searcher.on(BI.Searcher.EVENT_PAUSE,(function(){this.hasMatched(),e.fireEvent(BI.MultiSelectInsertSearcher.EVENT_PAUSE)})),this.searcher.on(BI.Searcher.EVENT_STOP,(function(){e.fireEvent(BI.MultiSelectInsertSearcher.EVENT_STOP)})),this.searcher.on(BI.Searcher.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectInsertSearcher.EVENT_CHANGE,arguments)})),this.searcher.on(BI.Searcher.EVENT_SEARCHING,(function(){var t=this.getKeywords();e.fireEvent(BI.MultiSelectInsertSearcher.EVENT_SEARCHING,t)})),BI.isNotNull(t.value)&&this.setState(t.value)},adjustView:function(){this.searcher.adjustView()},isSearching:function(){return this.searcher.isSearching()},stopSearch:function(){this.searcher.stopSearch()},getKeyword:function(){return this.editor.getKeyword()},hasMatched:function(){return this.searcher.hasMatched()},hasChecked:function(){return this.searcher.getView()&&this.searcher.getView().hasChecked()},setAdapter:function(e){this.searcher.setAdapter(e)},setState:function(e){var t=this.options;if(e||(e={}),e.value||(e.value=[]),e.type===BI.Selection.All)if(0===e.value.length)this.editor.setState(BI.Selection.All);else if(BI.size(e.assist)<=20){var n="";BI.each(e.assist,(function(e,i){n+=0===e?""+(null===i?"":t.valueFormatter(i+"")||i):","+(null===i?"":t.valueFormatter(i+"")||i)})),this.editor.setState(n)}else this.editor.setState(BI.Selection.Multi);else if(0===e.value.length)this.editor.setState(BI.Selection.None);else if(BI.size(e.value)<=20){n="";BI.each(e.value,(function(e,i){n+=0===e?""+(null===i?"":t.valueFormatter(i+"")||i):","+(null===i?"":t.valueFormatter(i+"")||i)})),this.editor.setState(n)}else this.editor.setState(BI.Selection.Multi)},getState:function(){return this.editor.getState()},setValue:function(e){this.setState(e),this.searcher.setValue(e)},getKey:function(){return this.editor.getValue()},getValue:function(){return this.searcher.getValue()},populate:function(e){this.searcher.populate.apply(this.searcher,arguments)}}),BI.MultiSelectInsertSearcher.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.MultiSelectInsertSearcher.EVENT_CHANGE="EVENT_CHANGE",BI.MultiSelectInsertSearcher.EVENT_START="EVENT_START",BI.MultiSelectInsertSearcher.EVENT_STOP="EVENT_STOP",BI.MultiSelectInsertSearcher.EVENT_PAUSE="EVENT_PAUSE",BI.MultiSelectInsertSearcher.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiSelectInsertSearcher.EVENT_FOCUS="EVENT_FOCUS",BI.MultiSelectInsertSearcher.EVENT_BLUR="EVENT_BLUR",BI.shortcut("bi.multi_select_insert_searcher",BI.MultiSelectInsertSearcher)},function(e,t){BI.MultiSelectSearcher=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiSelectSearcher.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-searcher",itemsCreator:BI.emptyFn,el:{},popup:{},valueFormatter:BI.emptyFn,adapter:null,masker:{},text:BI.i18nText("BI-Basic_Please_Select"),itemHeight:24})},_init:function(){BI.MultiSelectSearcher.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget(t.el,{type:"bi.multi_select_editor",height:t.height,text:t.text,watermark:t.watermark,listeners:[{eventName:BI.MultiSelectEditor.EVENT_FOCUS,action:function(){e.fireEvent(BI.MultiSelectSearcher.EVENT_FOCUS)}},{eventName:BI.MultiSelectEditor.EVENT_BLUR,action:function(){e.fireEvent(BI.MultiSelectSearcher.EVENT_BLUR)}}]}),this.searcher=BI.createWidget({type:"bi.searcher",element:this,height:t.height,isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t()},el:this.editor,popup:BI.extend({type:"bi.multi_select_search_pane",valueFormatter:t.valueFormatter,keywordGetter:function(){return e.editor.getValue()},itemsCreator:function(n,i){var r=e.editor.getValue();n.keywords=[r],t.itemsCreator(n,i)},itemHeight:t.itemHeight,value:t.value},t.popup),adapter:t.adapter,masker:t.masker}),this.searcher.on(BI.Searcher.EVENT_START,(function(){e.fireEvent(BI.MultiSelectSearcher.EVENT_START)})),this.searcher.on(BI.Searcher.EVENT_PAUSE,(function(){this.hasMatched(),e.fireEvent(BI.MultiSelectSearcher.EVENT_PAUSE)})),this.searcher.on(BI.Searcher.EVENT_STOP,(function(){e.fireEvent(BI.MultiSelectSearcher.EVENT_STOP)})),this.searcher.on(BI.Searcher.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectSearcher.EVENT_CHANGE,arguments)})),this.searcher.on(BI.Searcher.EVENT_SEARCHING,(function(){var t=this.getKeywords();e.fireEvent(BI.MultiSelectSearcher.EVENT_SEARCHING,t)})),BI.isNotNull(t.value)&&this.setState(t.value)},adjustView:function(){this.searcher.adjustView()},isSearching:function(){return this.searcher.isSearching()},stopSearch:function(){this.searcher.stopSearch()},getKeyword:function(){return this.editor.getValue()},hasMatched:function(){return this.searcher.hasMatched()},hasChecked:function(){return this.searcher.getView()&&this.searcher.getView().hasChecked()},setAdapter:function(e){this.searcher.setAdapter(e)},setState:function(e){var t=this.options;if(e||(e={}),e.value||(e.value=[]),e.type===BI.Selection.All)if(0===e.value.length)this.editor.setState(BI.Selection.All);else if(BI.size(e.assist)<=20){var n="";BI.each(e.assist,(function(e,i){n+=0===e?""+(null===i?"":t.valueFormatter(i+"")||i):","+(null===i?"":t.valueFormatter(i+"")||i)})),this.editor.setState(n)}else this.editor.setState(BI.Selection.Multi);else if(0===e.value.length)this.editor.setState(BI.Selection.None);else if(BI.size(e.value)<=20){n="";BI.each(e.value,(function(e,i){n+=0===e?""+(null===i?"":t.valueFormatter(i+"")||i):","+(null===i?"":t.valueFormatter(i+"")||i)})),this.editor.setState(n)}else this.editor.setState(BI.Selection.Multi)},getState:function(){return this.editor.getState()},setValue:function(e){this.setState(e),this.searcher.setValue(e)},getKey:function(){return this.editor.getValue()},getValue:function(){return this.searcher.getValue()},populate:function(e){this.searcher.populate.apply(this.searcher,arguments)}}),BI.MultiSelectSearcher.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.MultiSelectSearcher.EVENT_CHANGE="EVENT_CHANGE",BI.MultiSelectSearcher.EVENT_START="EVENT_START",BI.MultiSelectSearcher.EVENT_STOP="EVENT_STOP",BI.MultiSelectSearcher.EVENT_PAUSE="EVENT_PAUSE",BI.MultiSelectSearcher.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiSelectSearcher.EVENT_FOCUS="EVENT_FOCUS",BI.MultiSelectSearcher.EVENT_BLUR="EVENT_BLUR",BI.shortcut("bi.multi_select_searcher",BI.MultiSelectSearcher)},function(e,t){BI.MultiSelectCheckSelectedSwitcher=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiSelectCheckSelectedSwitcher.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-check-selected-switcher",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,el:{},popup:{},adapter:null,masker:{}})},_init:function(){BI.MultiSelectCheckSelectedSwitcher.superclass._init.apply(this,arguments);var e=this,t=this.options;this.button=BI.createWidget(t.el,{type:"bi.multi_select_check_selected_button",itemsCreator:t.itemsCreator,value:t.value}),this.button.on(BI.Events.VIEW,(function(){e.fireEvent(BI.Events.VIEW,arguments)})),this.switcher=BI.createWidget({type:"bi.switcher",toggle:!1,element:this,el:this.button,popup:BI.extend({type:"bi.multi_select_check_pane",valueFormatter:t.valueFormatter,itemsCreator:t.itemsCreator,onClickContinueSelect:function(){e.switcher.hideView()},ref:function(t){e.checkPane=t},value:t.value},t.popup),adapter:t.adapter,masker:t.masker}),this.switcher.on(BI.Switcher.EVENT_TRIGGER_CHANGE,(function(){e.fireEvent(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE)})),this.switcher.on(BI.Switcher.EVENT_BEFORE_POPUPVIEW,(function(){e.fireEvent(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW)})),this.switcher.on(BI.Switcher.EVENT_AFTER_HIDEVIEW,(function(){e.fireEvent(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW)})),this.switcher.on(BI.Switcher.EVENT_AFTER_POPUPVIEW,(function(){var e=this;BI.nextTick((function(){e._populate()}))}))},adjustView:function(){this.switcher.adjustView()},hideView:function(){this.switcher.empty(),this.switcher.hideView()},setAdapter:function(e){this.switcher.setAdapter(e)},setValue:function(e){this.switcher.setValue(e)},updateSelectedValue:function(e){this.checkPane.setValue(e)},setButtonChecked:function(e){this.button.setValue(e)},getValue:function(){},populate:function(e){this.switcher.populate.apply(this.switcher,arguments)},populateSwitcher:function(){this.button.populate.apply(this.button,arguments)}}),BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE="EVENT_TRIGGER_CHANGE",BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW="EVENT_AFTER_HIDEVIEW",BI.shortcut("bi.multi_select_check_selected_switcher",BI.MultiSelectCheckSelectedSwitcher)},function(e,t){BI.MultiSelectInsertList=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.MultiSelectInsertList.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-insert-list",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,searcherHeight:BI.SIZE_CONSANTS.TRIGGER_HEIGHT,itemHeight:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT})},_init:function(){BI.MultiSelectInsertList.superclass._init.apply(this,arguments);var e=this,t=this.options;this.storeValue=this._assertValue(t.value||{});var n=function(){BI.isKey(e._startValue)&&(e.storeValue.type===BI.Selection.All?BI.remove(e.storeValue.value,e._startValue):BI.pushDistinct(e.storeValue.value,e._startValue))};this.adapter=BI.createWidget({type:"bi.multi_select_loader",cls:"popup-multi-select-list bi-border-left bi-border-right bi-border-bottom",itemsCreator:t.itemsCreator,itemHeight:t.itemHeight,valueFormatter:t.valueFormatter,logic:{dynamic:!1},el:{},value:t.value}),this.adapter.on(BI.MultiSelectLoader.EVENT_CHANGE,(function(){e.storeValue=this.getValue(),n(),e.fireEvent(BI.MultiSelectInsertList.EVENT_CHANGE)})),this.searcherPane=BI.createWidget({type:"bi.multi_select_search_insert_pane",cls:"bi-border-left bi-border-right bi-border-bottom",valueFormatter:t.valueFormatter,keywordGetter:function(){return e.trigger.getKeyword()},itemsCreator:function(n,i){var r=e.trigger.getKeyword();BI.isNotEmptyString(r)&&(n.keywords=[r],this.setKeyword(n.keywords[0]),t.itemsCreator(n,i))},itemHeight:t.itemHeight}),this.searcherPane.setVisible(!1),this.trigger=BI.createWidget({type:"bi.searcher",el:{type:"bi.select_patch_editor",el:{type:"bi.search_editor",watermark:BI.i18nText("BI-Basic_Search_And_Patch_Paste")},ref:function(t){e.editor=t},height:t.searcherHeight||BI.SIZE_CONSANTS.TRIGGER_HEIGHT},isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t()},adapter:this.adapter,popup:this.searcherPane,height:200,masker:!1,listeners:[{eventName:BI.Searcher.EVENT_START,action:function(){e._showSearcherPane(),e._setStartValue(""),this.setValue(BI.deepClone(e.storeValue))}},{eventName:BI.Searcher.EVENT_STOP,action:function(){e._showAdapter(),e._setStartValue(""),e.adapter.setValue(e.storeValue),e.adapter.populate()}},{eventName:BI.Searcher.EVENT_PAUSE,action:function(){var t=this.getKeyword();e._join({type:BI.Selection.Multi,value:[t]},(function(){e.storeValue.type===BI.Selection.Multi&&BI.pushDistinct(e.storeValue.value,t),e._showAdapter(),e.adapter.setValue(e.storeValue),e._setStartValue(t),n(),e.adapter.populate(),e._setStartValue(""),e.fireEvent(BI.MultiSelectInsertList.EVENT_CHANGE)})),e._showAdapter()}},{eventName:BI.Searcher.EVENT_SEARCHING,action:function(){var t=e._getKeywords(),i=BI.last(t);(t=BI.initial(t||[])).length>0&&e._joinKeywords(t,(function(){BI.endWith(i,BI.BlankSplitChar)?(e.adapter.setValue(e.storeValue),n(),e.adapter.populate(),e._setStartValue("")):(e.adapter.setValue(e.storeValue),n()),e.fireEvent(BI.MultiSelectInsertList.EVENT_CHANGE)}))}},{eventName:BI.Searcher.EVENT_CHANGE,action:function(t,i){i instanceof BI.MultiSelectBar?e._joinAll(this.getValue(),(function(){n(),e.fireEvent(BI.MultiSelectInsertList.EVENT_CHANGE)})):e._join(this.getValue(),(function(){n(),e.fireEvent(BI.MultiSelectInsertList.EVENT_CHANGE)}))}}],value:t.value}),BI.createWidget({type:"bi.vtape",element:this,items:[{el:this.trigger,height:t.searcherHeight||BI.SIZE_CONSANTS.TRIGGER_HEIGHT},{el:this.adapter,height:"fill"}]}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.searcherPane,top:t.searcherHeight||BI.SIZE_CONSANTS.TRIGGER_HEIGHT,bottom:0,left:0,right:0}]})},_getKeywords:function(){var e=this.editor.getValue(),t=e.split(/\u200b\s\u200b/);return BI.isEmptyString(t[t.length-1])&&(t=t.slice(0,t.length-1)),/\u200b\s\u200b$/.test(e)?t.concat([BI.BlankSplitChar]):t},_showAdapter:function(){this.adapter.setVisible(!0),this.searcherPane.setVisible(!1)},_showSearcherPane:function(){this.searcherPane.setVisible(!0),this.adapter.setVisible(!1)},_defaultState:function(){this.trigger.stopEditing()},_assertValue:function(e){return e||(e={}),e.type||(e.type=BI.Selection.Multi),e.value||(e.value=[]),e},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(e,t){var n=this;this.options;this._assertValue(this.storeValue),BI.each(e,(function(e,t){n.storeValue.type===BI.Selection.Multi?BI.pushDistinct(n.storeValue.value,t):BI.remove(n.storeValue.value,t)})),t()},_joinAll:function(e,t){var n=this,i=this.options;this._assertValue(e),i.itemsCreator({type:BI.MultiSelectInsertList.REQ_GET_ALL_DATA,keywords:[n.trigger.getKeyword()]},(function(i){var r=BI.map(i.items,"value");if(n.storeValue.type===e.type){var a=!1,o=n._makeMap(n.storeValue.value);return BI.each(r,(function(e,t){BI.isNotNull(o[t])&&(a=!0,delete o[t])})),a&&(n.storeValue.value=BI.values(o)),void t()}var s=n._makeMap(n.storeValue.value),l=n._makeMap(e.value),u=[];BI.each(r,(function(e,t){BI.isNotNull(s[r[e]])&&delete s[r[e]],BI.isNull(l[r[e]])&&u.push(t)})),n.storeValue.value=u.concat(BI.values(s)),t()}))},_join:function(e,t){var n=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var i=this._makeMap(this.storeValue.value);BI.each(e.value,(function(e,t){i[t]||(BI.pushDistinct(n.storeValue.value,t),i[t]=t)}));var r=!1;return BI.each(e.assist,(function(e,t){BI.isNotNull(i[t])&&(r=!0,delete i[t])})),r&&(this.storeValue.value=BI.values(i)),void t()}this._joinAll(e,t)},_setStartValue:function(e){this._startValue=e,this.adapter.setStartValue(e)},isAllSelected:function(){return this.adapter.isAllSelected()},resize:function(){},setValue:function(e){this.storeValue=e||{},this._assertValue(this.storeValue),this.adapter.setValue(this.storeValue),this.trigger.setValue(this.storeValue)},getValue:function(){return BI.deepClone(this.storeValue)},populate:function(){this.adapter.populate.apply(this.adapter,arguments),this.trigger.populate.apply(this.trigger,arguments)}}),BI.extend(BI.MultiSelectInsertList,{REQ_GET_DATA_LENGTH:1,REQ_GET_ALL_DATA:-1}),BI.MultiSelectInsertList.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_select_insert_list",BI.MultiSelectInsertList)},function(e,t){BI.MultiSelectInsertNoBarList=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.MultiSelectInsertNoBarList.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-insert-list",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,searcherHeight:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT})},_init:function(){BI.MultiSelectInsertNoBarList.superclass._init.apply(this,arguments);var e=this,t=this.options;this.storeValue={type:BI.Selection.Multi,value:t.value||[]};var n=function(){BI.isKey(e._startValue)&&(e.storeValue.type===BI.Selection.All?BI.remove(e.storeValue.value,e._startValue):BI.pushDistinct(e.storeValue.value,e._startValue))};this.adapter=BI.createWidget({type:"bi.multi_select_no_bar_loader",cls:"popup-multi-select-list bi-border-left bi-border-right bi-border-bottom",itemsCreator:t.itemsCreator,itemHeight:t.itemHeight,valueFormatter:t.valueFormatter,logic:{dynamic:!1},el:{},value:{type:BI.Selection.Multi,value:t.value||[]}}),this.adapter.on(BI.MultiSelectLoader.EVENT_CHANGE,(function(){e.storeValue=this.getValue(),n(),e.fireEvent(BI.MultiSelectInsertNoBarList.EVENT_CHANGE)})),this.searcherPane=BI.createWidget({type:"bi.multi_select_search_insert_pane",cls:"bi-border-left bi-border-right bi-border-bottom",valueFormatter:t.valueFormatter,keywordGetter:function(){return e.trigger.getKeyword()},itemsCreator:function(n,i){var r=e.trigger.getKeyword();BI.isNotEmptyString(r)&&(n.keywords=[r],this.setKeyword(n.keywords[0]),t.itemsCreator(n,i))}}),this.searcherPane.setVisible(!1),this.trigger=BI.createWidget({type:"bi.searcher",el:{type:"bi.select_patch_editor",el:{type:"bi.search_editor",watermark:BI.i18nText("BI-Basic_Search_And_Patch_Paste")},ref:function(t){e.editor=t},height:t.searcherHeight},isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t()},adapter:this.adapter,popup:this.searcherPane,height:200,masker:!1,listeners:[{eventName:BI.Searcher.EVENT_START,action:function(){e._showSearcherPane(),e._setStartValue(""),this.setValue(BI.deepClone(e.storeValue))}},{eventName:BI.Searcher.EVENT_STOP,action:function(){e._showAdapter(),e._setStartValue(""),e.adapter.setValue(e.storeValue),e.adapter.populate()}},{eventName:BI.Searcher.EVENT_PAUSE,action:function(){var t=this.getKeyword();e._join({type:BI.Selection.Multi,value:[t]},(function(){e.storeValue.type===BI.Selection.Multi&&BI.pushDistinct(e.storeValue.value,t),e._showAdapter(),e.adapter.setValue(e.storeValue),e._setStartValue(t),n(),e.adapter.populate(),e._setStartValue(""),e.fireEvent(BI.MultiSelectInsertNoBarList.EVENT_CHANGE)}))}},{eventName:BI.Searcher.EVENT_SEARCHING,action:function(){var t=e._getKeywords(),i=BI.last(t);(t=BI.initial(t||[])).length>0&&e._joinKeywords(t,(function(){BI.endWith(i,BI.BlankSplitChar)?(e.adapter.setValue(e.storeValue),n(),e.adapter.populate(),e._setStartValue("")):(e.adapter.setValue(e.storeValue),n()),e.fireEvent(BI.MultiSelectInsertNoBarList.EVENT_CHANGE)}))}},{eventName:BI.Searcher.EVENT_CHANGE,action:function(t,i){i instanceof BI.MultiSelectBar?e._joinAll(this.getValue(),(function(){n(),e.fireEvent(BI.MultiSelectInsertNoBarList.EVENT_CHANGE)})):e._join(this.getValue(),(function(){n(),e.fireEvent(BI.MultiSelectInsertNoBarList.EVENT_CHANGE)}))}}],value:{type:BI.Selection.Multi,value:t.value||[]}}),BI.createWidget({type:"bi.vtape",element:this,items:[{el:this.trigger,height:t.searcherHeight},{el:this.adapter,height:"fill"}]}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.searcherPane,top:t.searcherHeight,bottom:0,left:0,right:0}]})},_getKeywords:function(){var e=this.editor.getValue(),t=e.split(/\u200b\s\u200b/);return BI.isEmptyString(t[t.length-1])&&(t=t.slice(0,t.length-1)),/\u200b\s\u200b$/.test(e)?t.concat([BI.BlankSplitChar]):t},_showAdapter:function(){this.adapter.setVisible(!0),this.searcherPane.setVisible(!1)},_showSearcherPane:function(){this.searcherPane.setVisible(!0),this.adapter.setVisible(!1)},_defaultState:function(){this.trigger.stopEditing()},_assertValue:function(e){e||(e={}),e.type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(e,t){var n=this;this.options;this._assertValue(this.storeValue),BI.each(e,(function(e,t){n.storeValue.type===BI.Selection.Multi?BI.pushDistinct(n.storeValue.value,t):BI.remove(n.storeValue.value,t)})),t()},_joinAll:function(e,t){var n=this,i=this.options;this._assertValue(e),i.itemsCreator({type:BI.MultiSelectInsertNoBarList.REQ_GET_ALL_DATA,keywords:[n.trigger.getKeyword()]},(function(i){var r=BI.map(i.items,"value");if(n.storeValue.type===e.type){var a=!1,o=n._makeMap(n.storeValue.value);return BI.each(r,(function(e,t){BI.isNotNull(o[t])&&(a=!0,delete o[t])})),a&&(n.storeValue.value=BI.values(o)),void t()}var s=n._makeMap(n.storeValue.value),l=n._makeMap(e.value),u=[];BI.each(r,(function(e,t){BI.isNotNull(s[r[e]])&&delete s[r[e]],BI.isNull(l[r[e]])&&u.push(t)})),n.storeValue.value=u.concat(BI.values(s)),t()}))},_join:function(e,t){var n=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var i=this._makeMap(this.storeValue.value);BI.each(e.value,(function(e,t){i[t]||(BI.pushDistinct(n.storeValue.value,t),i[t]=t)}));var r=!1;return BI.each(e.assist,(function(e,t){BI.isNotNull(i[t])&&(r=!0,delete i[t])})),r&&(this.storeValue.value=BI.values(i)),void t()}this._joinAll(e,t)},_setStartValue:function(e){this._startValue=e,this.adapter.setStartValue(e)},isAllSelected:function(){return this.adapter.isAllSelected()},resize:function(){},setValue:function(e){this.storeValue={type:BI.Selection.Multi,value:e||[]},this.adapter.setValue(this.storeValue),this.trigger.setValue(this.storeValue)},getValue:function(){return BI.deepClone(this.storeValue.value)},populate:function(){this.adapter.populate.apply(this.adapter,arguments),this.trigger.populate.apply(this.trigger,arguments)}}),BI.extend(BI.MultiSelectInsertNoBarList,{REQ_GET_DATA_LENGTH:1,REQ_GET_ALL_DATA:-1}),BI.MultiSelectInsertNoBarList.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_select_insert_no_bar_list",BI.MultiSelectInsertNoBarList)},function(e,t){BI.MultiSelectList=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiSelectList.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-list",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,searcherHeight:24,itemHeight:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT})},_init:function(){BI.MultiSelectList.superclass._init.apply(this,arguments);var e=this,t=this.options;this.storeValue={};var n=function(){BI.isKey(e._startValue)&&(e.storeValue.type===BI.Selection.All?BI.remove(e.storeValue.value,e._startValue):BI.pushDistinct(e.storeValue.value,e._startValue))};this.adapter=BI.createWidget({type:"bi.multi_select_loader",cls:"popup-multi-select-list bi-border-left bi-border-right bi-border-bottom",itemsCreator:t.itemsCreator,valueFormatter:t.valueFormatter,itemHeight:t.itemHeight,logic:{dynamic:!1},el:{}}),this.adapter.on(BI.MultiSelectLoader.EVENT_CHANGE,(function(){e.storeValue=this.getValue(),e._adjust((function(){n(),e.fireEvent(BI.MultiSelectList.EVENT_CHANGE)}))})),this.searcherPane=BI.createWidget({type:"bi.multi_select_search_pane",cls:"bi-border-left bi-border-right bi-border-bottom",valueFormatter:t.valueFormatter,keywordGetter:function(){return e.trigger.getKeyword()},itemsCreator:function(n,i){var r=e.trigger.getKeyword();BI.isNotEmptyString(r)&&(n.keywords=[r],t.itemsCreator(n,i))},itemHeight:t.itemHeight}),this.searcherPane.setVisible(!1),this.trigger=BI.createWidget({type:"bi.searcher",el:{type:"bi.select_patch_editor",el:{type:"bi.search_editor"},ref:function(t){e.editor=t},height:t.searcherHeight},isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t()},adapter:this.adapter,popup:this.searcherPane,height:200,masker:!1,listeners:[{eventName:BI.Searcher.EVENT_START,action:function(){e._showSearcherPane(),e._setStartValue(""),this.setValue(BI.deepClone(e.storeValue))}},{eventName:BI.Searcher.EVENT_STOP,action:function(){e._showAdapter(),e._setStartValue(""),e.adapter.setValue(e.storeValue),e.adapter.populate()}},{eventName:BI.Searcher.EVENT_PAUSE,action:function(){e._showAdapter(),e.fireEvent(BI.MultiSelectList.EVENT_CHANGE)}},{eventName:BI.Searcher.EVENT_SEARCHING,action:function(){var t=this.getKeyword(),i=BI.last(t);(t=BI.initial(t||[])).length>0&&e._joinKeywords(t,(function(){BI.endWith(i,BI.BlankSplitChar)?(e.adapter.setValue(e.storeValue),n(),e.adapter.populate(),e._setStartValue("")):(e.adapter.setValue(e.storeValue),n()),e.fireEvent(BI.MultiSelectList.EVENT_CHANGE)}))}},{eventName:BI.Searcher.EVENT_CHANGE,action:function(t,i){i instanceof BI.MultiSelectBar?e._joinAll(this.getValue(),(function(){n(),e.fireEvent(BI.MultiSelectList.EVENT_CHANGE)})):e._join(this.getValue(),(function(){n(),e.fireEvent(BI.MultiSelectList.EVENT_CHANGE)}))}}]}),BI.createWidget({type:"bi.vtape",element:this,items:[{el:this.trigger,height:t.searcherHeight},{el:this.adapter,height:"fill"}]}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.searcherPane,top:t.searcherHeight,bottom:0,left:0,right:0}]})},_getKeywords:function(){var e=this.editor.getValue(),t=e.split(/\u200b\s\u200b/);return BI.isEmptyString(t[t.length-1])&&(t=t.slice(0,t.length-1)),/\u200b\s\u200b$/.test(e)?t.concat([BI.BlankSplitChar]):t},_showAdapter:function(){this.adapter.setVisible(!0),this.searcherPane.setVisible(!1)},_showSearcherPane:function(){this.searcherPane.setVisible(!0),this.adapter.setVisible(!1)},_defaultState:function(){this.trigger.stopEditing()},_assertValue:function(e){e||(e={}),e.type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(e,t){var n=this,i=this.options;this._assertValue(this.storeValue),i.itemsCreator({type:BI.MultiSelectList.REQ_GET_ALL_DATA,keywords:e},(function(i){var r,a,o=BI.map(i.items,"value");r=o,a=n._makeMap(r),BI.each(e,(function(e,t){BI.isNotNull(a[t])&&(n.storeValue.type===BI.Selection.Multi?BI.pushDistinct(n.storeValue.value,t):BI.remove(n.storeValue.value,t))})),n._adjust(t)}))},_joinAll:function(e,t){var n=this,i=this.options;this._assertValue(e),i.itemsCreator({type:BI.MultiSelectList.REQ_GET_ALL_DATA,keywords:[this.trigger.getKey()]},(function(i){var r=BI.map(i.items,"value");if(n.storeValue.type===e.type){var a=!1,o=n._makeMap(n.storeValue.value);return BI.each(r,(function(e,t){BI.isNotNull(o[t])&&(a=!0,delete o[t])})),a&&(n.storeValue.value=BI.values(o)),void n._adjust(t)}var s=n._makeMap(n.storeValue.value),l=n._makeMap(e.value),u=[];BI.each(r,(function(e,t){BI.isNotNull(s[r[e]])&&delete s[r[e]],BI.isNull(l[r[e]])&&u.push(t)})),n.storeValue.value=u.concat(BI.values(s)),n._adjust(t)}))},_adjust:function(e){var t=this,n=this.options;function i(){t.storeValue.type===BI.Selection.All&&t.storeValue.value.length>=t._count?t.storeValue={type:BI.Selection.Multi,value:[]}:t.storeValue.type===BI.Selection.Multi&&t.storeValue.value.length>=t._count&&(t.storeValue={type:BI.Selection.All,value:[]})}this._count?(i(),e()):n.itemsCreator({type:BI.MultiSelectList.REQ_GET_DATA_LENGTH},(function(n){t._count=n.count,i(),e()}))},_join:function(e,t){var n=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var i=this._makeMap(this.storeValue.value);BI.each(e.value,(function(e,t){i[t]||(BI.pushDistinct(n.storeValue.value,t),i[t]=t)}));var r=!1;return BI.each(e.assist,(function(e,t){BI.isNotNull(i[t])&&(r=!0,delete i[t])})),r&&(this.storeValue.value=BI.values(i)),void n._adjust(t)}this._joinAll(e,t)},_setStartValue:function(e){this._startValue=e,this.adapter.setStartValue(e)},isAllSelected:function(){return this.adapter.isAllSelected()},resize:function(){},setValue:function(e){this.storeValue=e||{},this._assertValue(this.storeValue),this.adapter.setValue(this.storeValue),this.trigger.setValue(this.storeValue)},getValue:function(){return BI.deepClone(this.storeValue)},populate:function(){this.adapter.populate.apply(this.adapter,arguments),this.trigger.populate.apply(this.trigger,arguments)}}),BI.extend(BI.MultiSelectList,{REQ_GET_DATA_LENGTH:1,REQ_GET_ALL_DATA:-1}),BI.MultiSelectList.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_select_list",BI.MultiSelectList)},function(e,t){BI.MultiSelectTree=BI.inherit(BI.Single,{_constant:{EDITOR_HEIGHT:24},_defaultConfig:function(){return BI.extend(BI.MultiSelectTree.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-tree",itemsCreator:BI.emptyFn})},_init:function(){BI.MultiSelectTree.superclass._init.apply(this,arguments);var e=this,t=this.options;this.storeValue={value:{}},this.adapter=BI.createWidget({type:"bi.multi_select_tree_popup",itemsCreator:t.itemsCreator,showLine:t.showLine}),this.adapter.on(BI.MultiSelectTreePopup.EVENT_CHANGE,(function(){e.searcher.isSearching()?e.storeValue={value:e.searcherPane.getValue()}:e.storeValue={value:e.adapter.getValue()},e.setSelectedValue(e.storeValue.value),e.fireEvent(BI.MultiSelectTree.EVENT_CHANGE)})),this.searcherPane=BI.createWidget({type:"bi.multi_tree_search_pane",cls:"bi-border-left bi-border-right bi-border-bottom",keywordGetter:function(){return e.searcher.getKeyword()},itemsCreator:function(n,i){n.keyword=e.searcher.getKeyword(),t.itemsCreator(n,i)}}),this.searcherPane.setVisible(!1),this.searcher=BI.createWidget({type:"bi.searcher",isAutoSearch:!1,isAutoSync:!1,onSearch:function(t,n){n({keyword:e.searcher.getKeyword()})},adapter:this.adapter,popup:this.searcherPane,masker:!1,listeners:[{eventName:BI.Searcher.EVENT_START,action:function(){e._showSearcherPane()}},{eventName:BI.Searcher.EVENT_STOP,action:function(){e._showAdapter(),BI.nextTick((function(){e.adapter.populate()}))}},{eventName:BI.Searcher.EVENT_CHANGE,action:function(){e.searcher.isSearching()?e.storeValue={value:e.searcherPane.getValue()}:e.storeValue={value:e.adapter.getValue()},e.setSelectedValue(e.storeValue.value),e.fireEvent(BI.MultiSelectTree.EVENT_CHANGE)}},{eventName:BI.Searcher.EVENT_PAUSE,action:function(){e._showAdapter(),BI.nextTick((function(){e.adapter.populate()}))}}]}),BI.createWidget({type:"bi.vtape",element:this,items:[{el:this.searcher,height:this._constant.EDITOR_HEIGHT},{el:this.adapter,height:"fill"}]}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.searcherPane,top:this._constant.EDITOR_HEIGHT,bottom:0,left:0,right:0}]})},_showAdapter:function(){this.adapter.setVisible(!0),this.searcherPane.setVisible(!1)},_showSearcherPane:function(){this.searcherPane.setVisible(!0),this.adapter.setVisible(!1)},resize:function(){},setSelectedValue:function(e){this.storeValue.value=e||{},this.adapter.setSelectedValue(e),this.searcherPane.setSelectedValue(e),this.searcher.setValue({value:e||{}})},setValue:function(e){this.adapter.setValue(e)},stopSearch:function(){this.searcher.stopSearch()},updateValue:function(e){this.adapter.updateValue(e)},getValue:function(){return this.storeValue.value},populate:function(){this.adapter.populate()}}),BI.MultiSelectTree.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_select_tree",BI.MultiSelectTree)},function(e,t){BI.MultiSelectTreePopup=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiSelectTreePopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-tree-popup bi-border-left bi-border-right bi-border-bottom",itemsCreator:BI.emptyFn})},_init:function(){BI.MultiSelectTreePopup.superclass._init.apply(this,arguments);var e=this,t=this.options;this.popup=BI.createWidget({type:"bi.async_tree",showLine:t.showLine,element:this,itemsCreator:t.itemsCreator}),this.popup.on(BI.TreeView.EVENT_AFTERINIT,(function(){e.fireEvent(BI.MultiSelectTreePopup.EVENT_AFTER_INIT)})),this.popup.on(BI.TreeView.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectTreePopup.EVENT_CHANGE)}))},hasChecked:function(){return this.popup.hasChecked()},getValue:function(){return this.popup.getValue()},setValue:function(e){e||(e={}),this.popup.setValue(e)},setSelectedValue:function(e){e||(e={}),this.popup.setSelectedValue(e)},updateValue:function(e){this.popup.updateValue(e),this.popup.refresh()},populate:function(e){this.popup.stroke(e)}}),BI.MultiSelectTreePopup.EVENT_AFTER_INIT="EVENT_AFTER_INIT",BI.MultiSelectTreePopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_select_tree_popup",BI.MultiSelectTreePopup)},function(e,t){BI.MultiTreeCheckPane=BI.inherit(BI.Pane,{constants:{height:25,lgap:10,tgap:5},_defaultConfig:function(){return BI.extend(BI.MultiTreeCheckPane.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-tree-check-pane bi-background",onClickContinueSelect:BI.emptyFn,el:{type:"bi.display_tree"}})},_init:function(){BI.MultiTreeCheckPane.superclass._init.apply(this,arguments);var e=this,t=this.options;this.selectedValues={};var n=BI.createWidget({type:"bi.text_button",text:BI.i18nText("BI-Continue_Select"),cls:"multi-tree-check-selected"});n.on(BI.TextButton.EVENT_CHANGE,(function(){t.onClickContinueSelect(),BI.nextTick((function(){e.empty()}))}));var i=BI.createWidget({type:"bi.left",cls:"multi-tree-continue-select",items:[{el:{type:"bi.label",text:BI.i18nText("BI-Selected_Data")},lgap:this.constants.lgap,tgap:this.constants.tgap},{el:n,lgap:this.constants.lgap,tgap:this.constants.tgap}]});this.display=BI.createWidget(t.el,{type:"bi.display_tree",cls:"bi-multi-tree-display",itemsCreator:function(e,n){e.type=BI.TreeView.REQ_TYPE_GET_SELECTED_DATA,t.itemsCreator(e,n)},value:(t.value||{}).value}),this.display.on(BI.Events.AFTERINIT,(function(){e.fireEvent(BI.Events.AFTERINIT)})),this.display.on(BI.TreeView.EVENT_INIT,(function(){i.setVisible(!1)})),this.display.on(BI.TreeView.EVENT_AFTERINIT,(function(){i.setVisible(!0)})),BI.createWidget({type:"bi.vtape",element:this,items:[{height:this.constants.height,el:i},{height:"fill",el:this.display}]})},empty:function(){this.display.empty()},populate:function(e){this.display.stroke(e)},setValue:function(e){e||(e={}),this.display.setSelectedValue(e.value)},getValue:function(){}}),BI.MultiTreeCheckPane.EVENT_CONTINUE_CLICK="EVENT_CONTINUE_CLICK",BI.shortcut("bi.multi_tree_check_pane",BI.MultiTreeCheckPane)},function(e,t){BI.MultiTreeCombo=BI.inherit(BI.Single,{constants:{offset:{top:0,left:0,right:0,bottom:25}},_defaultConfig:function(){return BI.extend(BI.MultiTreeCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-tree-combo",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,height:24,allowEdit:!0,isNeedAdjustWidth:!0})},_init:function(){var e=this,t=this.options;BI.MultiTreeCombo.superclass._init.apply(this,arguments);var n=!1,i=!1;this.storeValue={value:t.value||{}},this.trigger=BI.createWidget({type:"bi.multi_select_trigger",allowEdit:t.allowEdit,height:t.height-2,valueFormatter:t.valueFormatter,text:t.text,watermark:t.watermark,masker:{offset:this.constants.offset},searcher:{type:"bi.multi_tree_searcher",itemsCreator:t.itemsCreator},value:{value:t.value||{}}}),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!t.allowEdit,container:t.container,el:this.trigger,adjustLength:1,popup:{type:"bi.multi_tree_popup_view",ref:function(){e.popup=this,e.trigger.setAdapter(this),e.numberCounter.setAdapter(this)},listeners:[{eventName:BI.MultiTreePopup.EVENT_AFTERINIT,action:function(){e.numberCounter.adjustView(),n=!0,!0===i&&l()}},{eventName:BI.MultiTreePopup.EVENT_CHANGE,action:function(){r=!0;var t={type:BI.Selection.Multi,value:this.hasChecked()?this.getValue():{}};e.trigger.getSearcher().setState(t),e.numberCounter.setButtonChecked(t),e.fireEvent(BI.MultiTreeCombo.EVENT_CLICK_ITEM,e.combo.getValue())}},{eventName:BI.MultiTreePopup.EVENT_CLICK_CONFIRM,action:function(){e.combo.hideView()}},{eventName:BI.MultiTreePopup.EVENT_CLICK_CLEAR,action:function(){a=!0,e.setValue(),e._defaultState()}}],itemsCreator:t.itemsCreator,onLoaded:function(){BI.nextTick((function(){e.numberCounter.adjustView(),e.trigger.getSearcher().adjustView()}))},maxWidth:t.isNeedAdjustWidth?"auto":500},isNeedAdjustWidth:t.isNeedAdjustWidth,value:{value:t.value||{}},hideChecker:function(t){return 0===u.element.find(t.target).length&&0===e.numberCounter.element.find(t.target).length}});var r=!1,a=!1,o=function(){return e.trigger.getSearcher().isSearching()},s=function(){return e.combo.isViewVisible()};function l(){o()?e.storeValue={value:e.trigger.getValue()}:s()&&(e.storeValue={value:e.combo.getValue()}),e.trigger.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue)}this.trigger.on(BI.MultiSelectTrigger.EVENT_FOCUS,(function(){e.fireEvent(BI.MultiTreeCombo.EVENT_FOCUS)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_BLUR,(function(){e.fireEvent(BI.MultiTreeCombo.EVENT_BLUR)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_START,(function(){e.storeValue={value:e.combo.getValue()},this.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_STOP,(function(){e.storeValue={value:this.getValue()},e.combo.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue),BI.nextTick((function(){s()&&e.combo.populate()})),e.fireEvent(BI.MultiTreeCombo.EVENT_STOP)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_SEARCHING,(function(){e.fireEvent(BI.MultiTreeCombo.EVENT_SEARCHING)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_TRIGGER_CLICK,(function(){e.combo.toggle()})),this.trigger.on(BI.MultiSelectTrigger.EVENT_COUNTER_CLICK,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.trigger.on(BI.MultiSelectTrigger.EVENT_CHANGE,(function(){var t=this.getSearcher().hasChecked(),n={type:BI.Selection.Multi,value:t?{1:1}:{}};this.getSearcher().setState(t?BI.Selection.Multi:BI.Selection.None),e.numberCounter.setButtonChecked(n),e.fireEvent(BI.MultiTreeCombo.EVENT_CLICK_ITEM,e.combo.getValue())})),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){o()||(!0===r&&(e.storeValue={value:e.combo.getValue()},r=!1),e.combo.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue),e.populate(),e.fireEvent(BI.MultiTreeCombo.EVENT_BEFORE_POPUPVIEW))})),this.combo.on(BI.Combo.EVENT_BEFORE_HIDEVIEW,(function(){o()?(e._stopEditing(),e.fireEvent(BI.MultiTreeCombo.EVENT_CONFIRM)):s()&&(e._stopEditing(),e.storeValue={value:e.combo.getValue()},!0===a&&(e.storeValue={value:{}}),e.fireEvent(BI.MultiTreeCombo.EVENT_CONFIRM)),a=!1,r=!1}));var u=BI.createWidget({type:"bi.trigger_icon_button",width:t.height,height:t.height,cls:"multi-select-trigger-icon-button"});u.on(BI.TriggerIconButton.EVENT_CHANGE,(function(){e.numberCounter.hideView(),e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()})),this.numberCounter=BI.createWidget({type:"bi.multi_select_check_selected_switcher",el:{type:"bi.multi_tree_check_selected_button"},popup:{type:"bi.multi_tree_check_pane"},masker:{offset:this.constants.offset},itemsCreator:t.itemsCreator,valueFormatter:t.valueFormatter,value:{value:t.value||{}}}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,(function(){!1===i&&(i=!0),!0===n&&(i=null,l())})),this.numberCounter.on(BI.Events.VIEW,(function(t){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(!0===t?e.numberCounter.element.outerWidth()+8:0)}))})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,(function(){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(0)}))})),this.trigger.element.click((function(t){e.trigger.element.find(t.target).length>0&&e.numberCounter.hideView()})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:u,right:0,top:0,bottom:0},{el:{type:"bi.vertical_adapt",items:[this.numberCounter]},right:t.height,top:0,bottom:0}]})},_stopEditing:function(){this.trigger.stopEditing(),this.numberCounter.hideView()},_defaultState:function(){this._stopEditing(),this.combo.hideView()},showView:function(){this.combo.showView()},hideView:function(){this.combo.hideView()},setValue:function(e){this.storeValue.value=e||{},this.combo.setValue({value:e||{}}),this.numberCounter.setValue({value:e||{}})},getSearcher:function(){return this.trigger.getSearcher()},getValue:function(){return BI.deepClone(this.storeValue.value)},populate:function(){this.combo.populate()}}),BI.MultiTreeCombo.EVENT_FOCUS="EVENT_FOCUS",BI.MultiTreeCombo.EVENT_BLUR="EVENT_BLUR",BI.MultiTreeCombo.EVENT_STOP="EVENT_STOP",BI.MultiTreeCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiTreeCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.MultiTreeCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.MultiTreeCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.multi_tree_combo",BI.MultiTreeCombo)},function(e,t){BI.MultiTreeInsertCombo=BI.inherit(BI.Single,{constants:{offset:{top:0,left:0,right:0,bottom:25}},_defaultConfig:function(){return BI.extend(BI.MultiTreeInsertCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-tree-insert-combo",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,height:24,allowEdit:!0,isNeedAdjustWidth:!0})},_init:function(){var e=this,t=this.options;BI.MultiTreeInsertCombo.superclass._init.apply(this,arguments);var n=!1,i=!1;this.storeValue={value:t.value||{}},this.trigger=BI.createWidget({type:"bi.multi_select_trigger",allowEdit:t.allowEdit,height:t.height-2,valueFormatter:t.valueFormatter,masker:{offset:this.constants.offset},searcher:{type:"bi.multi_tree_searcher",text:t.text,watermark:t.watermark,itemsCreator:t.itemsCreator,popup:{type:"bi.multi_tree_search_insert_pane",listeners:[{eventName:BI.MultiTreeSearchInsertPane.EVENT_ADD_ITEM,action:function(){e.storeValue.value[e.trigger.getSearcher().getKeyword()]={},e._assertShowValue(),e.combo.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue),e._stopEditing()}}]}},value:{value:t.value||{}}}),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!t.allowEdit,container:t.container,el:this.trigger,adjustLength:1,popup:{type:"bi.multi_tree_popup_view",ref:function(){e.popup=this,e.trigger.setAdapter(this),e.numberCounter.setAdapter(this)},listeners:[{eventName:BI.MultiTreePopup.EVENT_AFTERINIT,action:function(){e.numberCounter.adjustView(),n=!0,!0===i&&l()}},{eventName:BI.MultiTreePopup.EVENT_CHANGE,action:function(){r=!0;var t={type:BI.Selection.Multi,value:this.hasChecked()?this.getValue():{}};e.trigger.getSearcher().setState(t),e.numberCounter.setButtonChecked(t),e.fireEvent(BI.MultiTreeInsertCombo.EVENT_CLICK_ITEM,e.combo.getValue())}},{eventName:BI.MultiTreePopup.EVENT_CLICK_CONFIRM,action:function(){e.combo.hideView()}},{eventName:BI.MultiTreePopup.EVENT_CLICK_CLEAR,action:function(){a=!0,e.setValue(),e._defaultState()}}],itemsCreator:t.itemsCreator,onLoaded:function(){BI.nextTick((function(){e.numberCounter.adjustView(),e.trigger.getSearcher().adjustView()}))},maxWidth:t.isNeedAdjustWidth?"auto":500},isNeedAdjustWidth:t.isNeedAdjustWidth,value:{value:t.value||{}},hideChecker:function(t){return 0===u.element.find(t.target).length&&0===e.numberCounter.element.find(t.target).length}});var r=!1,a=!1,o=function(){return e.trigger.getSearcher().isSearching()},s=function(){return e.combo.isViewVisible()};function l(){o()?e.storeValue={value:e.trigger.getValue()}:s()&&(e.storeValue={value:e.combo.getValue()}),e.trigger.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue)}this.trigger.on(BI.MultiSelectTrigger.EVENT_FOCUS,(function(){e.fireEvent(BI.MultiTreeInsertCombo.EVENT_FOCUS)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_BLUR,(function(){e.fireEvent(BI.MultiTreeInsertCombo.EVENT_BLUR)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_START,(function(){e.storeValue={value:e.combo.getValue()},this.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_STOP,(function(){e.storeValue={value:this.getValue()},e.combo.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue),BI.nextTick((function(){s()&&e.combo.populate()})),e.fireEvent(BI.MultiTreeInsertCombo.EVENT_STOP)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_SEARCHING,(function(){e.fireEvent(BI.MultiTreeInsertCombo.EVENT_SEARCHING)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_TRIGGER_CLICK,(function(){e.combo.toggle()})),this.trigger.on(BI.MultiSelectTrigger.EVENT_CHANGE,(function(){var t=this.getSearcher().hasChecked(),n={type:BI.Selection.Multi,value:t?{1:1}:{}};this.getSearcher().setState(t?BI.Selection.Multi:BI.Selection.None),e.numberCounter.setButtonChecked(n),e.fireEvent(BI.MultiTreeInsertCombo.EVENT_CLICK_ITEM,e.combo.getValue())})),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){o()||(!0===r&&(e.storeValue={value:e.combo.getValue()},r=!1),e.combo.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue),e.populate(),e.fireEvent(BI.MultiTreeInsertCombo.EVENT_BEFORE_POPUPVIEW))})),this.combo.on(BI.Combo.EVENT_BEFORE_HIDEVIEW,(function(){o()?(e._stopEditing(),e.fireEvent(BI.MultiTreeInsertCombo.EVENT_CONFIRM)):s()&&(e._stopEditing(),e.storeValue={value:e.combo.getValue()},!0===a&&(e.storeValue={value:{}}),e.fireEvent(BI.MultiTreeInsertCombo.EVENT_CONFIRM)),a=!1,r=!1}));var u=BI.createWidget({type:"bi.trigger_icon_button",width:t.height,height:t.height,cls:"multi-select-trigger-icon-button"});u.on(BI.TriggerIconButton.EVENT_CHANGE,(function(){e.numberCounter.hideView(),e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()})),this.numberCounter=BI.createWidget({type:"bi.multi_select_check_selected_switcher",el:{type:"bi.multi_tree_check_selected_button"},popup:{type:"bi.multi_tree_check_pane"},itemsCreator:t.itemsCreator,masker:{offset:this.constants.offset},valueFormatter:t.valueFormatter,value:t.value}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,(function(){!1===i&&(i=!0),!0===n&&(i=null,l())})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,(function(){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(0)}))})),this.numberCounter.on(BI.Events.VIEW,(function(t){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(!0===t?e.numberCounter.element.outerWidth()+8:0)}))})),this.trigger.element.click((function(t){e.trigger.element.find(t.target).length>0&&e.numberCounter.hideView()})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:u,right:0,top:0,bottom:0},{el:{type:"bi.vertical_adapt",items:[this.numberCounter]},right:t.height,top:0,height:t.height}]})},_assertShowValue:function(){this.trigger.getSearcher().setState(this.storeValue),this.numberCounter.setButtonChecked(this.storeValue)},_stopEditing:function(){this.trigger.stopEditing(),this.numberCounter.hideView()},_defaultState:function(){this._stopEditing(),this.combo.hideView()},getSearcher:function(){return this.trigger.getSearcher()},showView:function(){this.combo.showView()},hideView:function(){this.combo.hideView()},setValue:function(e){this.storeValue.value=e||{},this.combo.setValue({value:e||{}}),this.numberCounter.setValue({value:e||{}})},getValue:function(){return BI.deepClone(this.storeValue.value)},populate:function(){this.combo.populate()}}),BI.MultiTreeInsertCombo.EVENT_FOCUS="EVENT_FOCUS",BI.MultiTreeInsertCombo.EVENT_BLUR="EVENT_BLUR",BI.MultiTreeInsertCombo.EVENT_STOP="EVENT_STOP",BI.MultiTreeInsertCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.MultiTreeInsertCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiTreeInsertCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.MultiTreeInsertCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.multi_tree_insert_combo",BI.MultiTreeInsertCombo)},function(e,t){BI.MultiTreeListCombo=BI.inherit(BI.Single,{constants:{offset:{top:0,left:0,right:0,bottom:25}},_defaultConfig:function(){return BI.extend(BI.MultiTreeListCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-tree-list-combo",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,height:24,allowEdit:!0,allowInsertValue:!0,isNeedAdjustWidth:!0})},_init:function(){var e=this,t=this.options;BI.MultiTreeListCombo.superclass._init.apply(this,arguments);var n=!1,i=!1;this.storeValue={value:t.value||[]},this.trigger=BI.createWidget({type:"bi.multi_select_trigger",allowEdit:t.allowEdit,text:t.text,watermark:t.watermark,height:t.height-2,valueFormatter:t.valueFormatter,masker:{offset:this.constants.offset},searcher:{type:"bi.multi_list_tree_searcher",itemsCreator:t.itemsCreator,popup:{type:t.allowInsertValue?"bi.multi_tree_search_insert_pane":"bi.multi_tree_search_pane",el:{type:"bi.list_part_tree"},listeners:[{eventName:BI.MultiTreeSearchInsertPane.EVENT_ADD_ITEM,action:function(){e.storeValue.value.unshift([e.trigger.getSearcher().getKeyword()]),e._assertShowValue(),e.combo.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue),e._stopEditing()}}]}},switcher:{el:{type:"bi.multi_tree_check_selected_button"},popup:{type:"bi.multi_tree_check_pane",el:{type:"bi.list_display_tree"},itemsCreator:t.itemsCreator}},value:{value:t.value||{}}}),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!t.allowEdit,container:t.container,el:this.trigger,adjustLength:1,popup:{type:"bi.multi_tree_popup_view",ref:function(){e.popup=this,e.trigger.setAdapter(this),e.numberCounter.setAdapter(this)},el:{type:"bi.list_async_tree"},listeners:[{eventName:BI.MultiTreePopup.EVENT_AFTERINIT,action:function(){e.numberCounter.adjustView(),n=!0,!0===i&&l()}},{eventName:BI.MultiTreePopup.EVENT_CHANGE,action:function(){r=!0;var t={type:BI.Selection.Multi,value:this.hasChecked()?this.getValue():[]};e.trigger.getSearcher().setState(t),e.numberCounter.setButtonChecked(t),e.fireEvent(BI.MultiTreeListCombo.EVENT_CLICK_ITEM,e.combo.getValue())}},{eventName:BI.MultiTreePopup.EVENT_CLICK_CONFIRM,action:function(){e.combo.hideView()}},{eventName:BI.MultiTreePopup.EVENT_CLICK_CLEAR,action:function(){a=!0,e.setValue(),e._defaultState()}}],itemsCreator:t.itemsCreator,onLoaded:function(){BI.nextTick((function(){e.numberCounter.adjustView(),e.trigger.getSearcher().adjustView()}))},maxWidth:t.isNeedAdjustWidth?"auto":500},isNeedAdjustWidth:t.isNeedAdjustWidth,value:{value:t.value||{}},hideChecker:function(t){return 0===u.element.find(t.target).length&&0===e.numberCounter.element.find(t.target).length}});var r=!1,a=!1,o=function(){return e.trigger.getSearcher().isSearching()},s=function(){return e.combo.isViewVisible()};function l(){o()?e.storeValue={value:e.trigger.getValue()}:s()&&(e.storeValue={value:e.combo.getValue()}),e.trigger.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue)}this.trigger.on(BI.MultiSelectTrigger.EVENT_FOCUS,(function(){e.fireEvent(BI.MultiTreeListCombo.EVENT_FOCUS)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_BLUR,(function(){e.fireEvent(BI.MultiTreeListCombo.EVENT_BLUR)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_START,(function(){e.storeValue={value:e.combo.getValue()},this.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_STOP,(function(){e.storeValue={value:this.getValue()},e.combo.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue),BI.nextTick((function(){s()&&e.combo.populate()})),e.fireEvent(BI.MultiTreeListCombo.EVENT_STOP)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_SEARCHING,(function(){e.fireEvent(BI.MultiTreeListCombo.EVENT_SEARCHING)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_TRIGGER_CLICK,(function(){e.combo.toggle()})),this.trigger.on(BI.MultiSelectTrigger.EVENT_CHANGE,(function(){var t=this.getSearcher().hasChecked(),n={type:BI.Selection.Multi,value:t?{1:1}:{}};this.getSearcher().setState(t?BI.Selection.Multi:BI.Selection.None),e.numberCounter.setButtonChecked(n),e.fireEvent(BI.MultiTreeListCombo.EVENT_CLICK_ITEM,e.combo.getValue())})),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){o()||(!0===r&&(e.storeValue={value:e.combo.getValue()},r=!1),e.combo.setValue(e.storeValue),e.numberCounter.setValue(e.storeValue),e.populate(),e.fireEvent(BI.MultiTreeListCombo.EVENT_BEFORE_POPUPVIEW))})),this.combo.on(BI.Combo.EVENT_BEFORE_HIDEVIEW,(function(){o()?(e.trigger.stopEditing(),e.fireEvent(BI.MultiTreeListCombo.EVENT_CONFIRM)):s()&&(e._stopEditing(),e.storeValue={value:e.combo.getValue()},!0===a&&(e.storeValue={value:[]}),e.fireEvent(BI.MultiTreeListCombo.EVENT_CONFIRM)),a=!1,r=!1}));var u=BI.createWidget({type:"bi.trigger_icon_button",width:t.height,height:t.height,cls:"multi-select-trigger-icon-button"});u.on(BI.TriggerIconButton.EVENT_CHANGE,(function(){e.numberCounter.hideView(),e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()})),this.numberCounter=BI.createWidget({type:"bi.multi_select_check_selected_switcher",el:{type:"bi.multi_tree_check_selected_button"},popup:{type:"bi.multi_tree_check_pane"},itemsCreator:t.itemsCreator,masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:t.valueFormatter,value:t.value}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,(function(){!1===i&&(i=!0),!0===n&&(i=null,l())})),this.numberCounter.on(BI.Events.VIEW,(function(t){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(!0===t?e.numberCounter.element.outerWidth()+8:0)}))})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,(function(){BI.nextTick((function(){e.trigger.refreshPlaceHolderWidth(0)}))})),this.trigger.element.click((function(t){e.trigger.element.find(t.target).length>0&&e.numberCounter.hideView()})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:u,right:0,top:0,bottom:0},{el:{type:"bi.vertical_adapt",items:[this.numberCounter]},right:t.height,top:0,height:t.height}]})},_assertShowValue:function(){this.trigger.getSearcher().setState(this.storeValue),this.numberCounter.setButtonChecked(this.storeValue)},_stopEditing:function(){this.trigger.stopEditing(),this.numberCounter.hideView()},_defaultState:function(){this._stopEditing(),this.combo.hideView()},showView:function(){this.combo.showView()},hideView:function(){this.combo.hideView()},getSearcher:function(){return this.trigger.getSearcher()},setValue:function(e){this.storeValue.value=e||[],this.combo.setValue({value:e||[]}),this.numberCounter.setValue({value:e||[]})},getValue:function(){return BI.deepClone(this.storeValue.value)},populate:function(){this.combo.populate()}}),BI.MultiTreeListCombo.EVENT_FOCUS="EVENT_FOCUS",BI.MultiTreeListCombo.EVENT_BLUR="EVENT_BLUR",BI.MultiTreeListCombo.EVENT_STOP="EVENT_STOP",BI.MultiTreeListCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.MultiTreeListCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiTreeListCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.MultiTreeListCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.multi_tree_list_combo",BI.MultiTreeListCombo)},function(e,t){BI.MultiTreePopup=BI.inherit(BI.Pane,{_defaultConfig:function(){return BI.extend(BI.MultiTreePopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-tree-popup",maxWidth:"auto",minWidth:140,maxHeight:400,onLoaded:BI.emptyFn,el:{type:"bi.async_tree"}})},_init:function(){BI.MultiTreePopup.superclass._init.apply(this,arguments);var e=this,t=this.options,n=t.value;this.selectedValues={},this.tree=BI.createWidget(t.el,{type:"bi.async_tree",showLine:t.showLine,height:400,cls:"popup-view-tree",itemsCreator:t.itemsCreator,onLoaded:t.onLoaded,value:n.value||{}}),this.popupView=BI.createWidget({type:"bi.multi_popup_view",element:this,stopPropagation:!1,maxWidth:t.maxWidth,minWidth:t.minWidth,maxHeight:t.maxHeight,buttons:[BI.i18nText("BI-Basic_Clears"),BI.i18nText("BI-Basic_Sure")],el:this.tree}),this.popupView.on(BI.MultiPopupView.EVENT_CLICK_TOOLBAR_BUTTON,(function(t){switch(t){case 0:e.fireEvent(BI.MultiTreePopup.EVENT_CLICK_CLEAR);break;case 1:e.fireEvent(BI.MultiTreePopup.EVENT_CLICK_CONFIRM)}})),this.tree.on(BI.TreeView.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiTreePopup.EVENT_CHANGE)})),this.tree.on(BI.TreeView.EVENT_AFTERINIT,(function(){e.fireEvent(BI.MultiTreePopup.EVENT_AFTERINIT)}))},getValue:function(){return this.tree.getValue()},setValue:function(e){e||(e={}),this.tree.setSelectedValue(e.value)},populate:function(e){this.tree.stroke(e)},hasChecked:function(){return this.tree.hasChecked()},resetHeight:function(e){this.popupView.resetHeight(e)},resetWidth:function(e){this.popupView.resetWidth(e)}}),BI.MultiTreePopup.EVENT_CHANGE="EVENT_CHANGE",BI.MultiTreePopup.EVENT_CLICK_CONFIRM="EVENT_CLICK_CONFIRM",BI.MultiTreePopup.EVENT_CLICK_CLEAR="EVENT_CLICK_CLEAR",BI.MultiTreePopup.EVENT_AFTERINIT="EVENT_AFTERINIT",BI.shortcut("bi.multi_tree_popup_view",BI.MultiTreePopup)},function(e,t){BI.MultiTreeCheckSelectedButton=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.MultiTreeCheckSelectedButton.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-tree-check-selected-button",itemsCreator:BI.emptyFn})},_init:function(){BI.MultiTreeCheckSelectedButton.superclass._init.apply(this,arguments);var e=this;this.indicator=BI.createWidget({type:"bi.icon_button",cls:"check-font trigger-check-selected icon-size-12",width:15,height:15,stopPropagation:!0}),this.checkSelected=BI.createWidget({type:"bi.text_button",cls:"bi-high-light-background trigger-check-text",invisible:!0,hgap:4,text:BI.i18nText("BI-Check_Selected"),textAlign:"center",textHeight:15}),this.checkSelected.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.checkSelected.on(BI.TextButton.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiSelectCheckSelectedButton.EVENT_CHANGE,arguments)})),BI.createWidget({type:"bi.horizontal",element:this,items:[this.indicator,this.checkSelected]}),this.element.hover((function(){e.indicator.setVisible(!1),e.checkSelected.setVisible(!0)}),(function(){e.indicator.setVisible(!0),e.checkSelected.setVisible(!1)})),this.setVisible(!1)},setValue:function(e){e||(e={});var t=BI.size(e.value)>0;this.setVisible(t)}}),BI.MultiTreeCheckSelectedButton.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.multi_tree_check_selected_button",BI.MultiTreeCheckSelectedButton)},function(e,t){BI.MultiTreeSearchInsertPane=BI.inherit(BI.Widget,{constants:{height:24},props:{baseCls:"bi-multi-tree-search-insert-pane bi-card",itemsCreator:BI.emptyFn,keywordGetter:BI.emptyFn,el:{type:"bi.part_tree"}},render:function(){var e=this,t=this.options;return{type:"bi.absolute",items:[{el:{type:"bi.text_button",invisible:!0,ref:function(t){e.addTip=t},text:BI.i18nText("BI-Basic_Click_To_Add_Text",""),height:this.constants.height,cls:"bi-high-light",handler:function(){e.fireEvent(BI.MultiTreeSearchInsertPane.EVENT_ADD_ITEM,t.keywordGetter())}},top:5,left:0,right:0},{el:BI.extend({type:"bi.part_tree",tipText:BI.i18nText("BI-No_Select"),itemsCreator:function(n,i){n.keyword=t.keywordGetter(),t.itemsCreator(n,(function(n){i(n),e.setKeyword(t.keywordGetter(),n.items)}))},ref:function(t){e.partTree=t},value:t.value,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}},{eventName:BI.TreeView.EVENT_CHANGE,action:function(){e.fireEvent(BI.MultiTreeSearchInsertPane.EVENT_CHANGE)}}]},t.el),left:0,top:0,bottom:0,right:0}]}},setKeyword:function(e,t){var n=BI.isEmptyArray(t);this.addTip.setVisible(n),this.partTree.setVisible(!n),n&&this.addTip.setText(BI.i18nText("BI-Basic_Click_To_Add_Text",e))},hasChecked:function(){return this.partTree.hasChecked()},setValue:function(e){this.setSelectedValue(e.value)},setSelectedValue:function(e){e||(e={}),this.partTree.setSelectedValue(e)},getValue:function(){return this.partTree.getValue()},empty:function(){this.partTree.empty()},populate:function(e){this.partTree.stroke.apply(this.partTree,arguments)}}),BI.MultiTreeSearchInsertPane.EVENT_CHANGE="EVENT_CHANGE",BI.MultiTreeSearchInsertPane.EVENT_CLICK_CONFIRM="EVENT_CLICK_CONFIRM",BI.MultiTreeSearchInsertPane.EVENT_CLICK_CLEAR="EVENT_CLICK_CLEAR",BI.MultiTreeSearchInsertPane.EVENT_ADD_ITEM="EVENT_ADD_ITEM",BI.shortcut("bi.multi_tree_search_insert_pane",BI.MultiTreeSearchInsertPane)},function(e,t){BI.MultiTreeSearchPane=BI.inherit(BI.Pane,{props:{baseCls:"bi-multi-tree-search-pane bi-card",itemsCreator:BI.emptyFn,keywordGetter:BI.emptyFn},render:function(){var e=this,t=this.options;return BI.extend({type:"bi.part_tree",element:this,tipText:BI.i18nText("BI-No_Select"),itemsCreator:function(e,n){e.keyword=t.keywordGetter(),t.itemsCreator(e,n)},value:t.value,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}},{eventName:BI.TreeView.EVENT_CHANGE,action:function(){e.fireEvent(BI.MultiTreeSearchPane.EVENT_CHANGE)}}],ref:function(t){e.partTree=t}},t.el)},hasChecked:function(){return this.partTree.hasChecked()},setValue:function(e){this.setSelectedValue(e.value)},setSelectedValue:function(e){e||(e={}),this.partTree.setSelectedValue(e)},getValue:function(){return this.partTree.getValue()},empty:function(){this.partTree.empty()},populate:function(e){this.partTree.stroke.apply(this.partTree,arguments)}}),BI.MultiTreeSearchPane.EVENT_CHANGE="EVENT_CHANGE",BI.MultiTreeSearchPane.EVENT_CLICK_CONFIRM="EVENT_CLICK_CONFIRM",BI.MultiTreeSearchPane.EVENT_CLICK_CLEAR="EVENT_CLICK_CLEAR",BI.shortcut("bi.multi_tree_search_pane",BI.MultiTreeSearchPane)},function(e,t){BI.MultiListTreeSearcher=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiListTreeSearcher.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-tree-searcher",itemsCreator:BI.emptyFn,valueFormatter:function(e){return e},popup:{},adapter:null,masker:{}})},_init:function(){BI.MultiListTreeSearcher.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget({type:"bi.multi_select_editor",height:t.height,text:t.text,watermark:t.watermark,el:{type:"bi.simple_state_editor",height:t.height}}),this.searcher=BI.createWidget({type:"bi.searcher",element:this,isAutoSearch:!1,isAutoSync:!1,onSearch:function(t,n){n({keyword:e.editor.getValue()})},el:this.editor,popup:BI.extend({type:"bi.multi_tree_search_pane",keywordGetter:function(){return e.editor.getValue()},itemsCreator:function(n,i){n.keyword=e.editor.getValue(),t.itemsCreator(n,i)},value:t.value},t.popup),adapter:t.adapter,masker:t.masker}),this.searcher.on(BI.Searcher.EVENT_START,(function(){e.fireEvent(BI.MultiListTreeSearcher.EVENT_START)})),this.searcher.on(BI.Searcher.EVENT_PAUSE,(function(){this.hasMatched(),e.fireEvent(BI.MultiListTreeSearcher.EVENT_PAUSE)})),this.searcher.on(BI.Searcher.EVENT_STOP,(function(){e.fireEvent(BI.MultiListTreeSearcher.EVENT_STOP)})),this.searcher.on(BI.Searcher.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiListTreeSearcher.EVENT_CHANGE,arguments)})),BI.isNotNull(t.value)&&this.setState(t.value)},adjustView:function(){this.searcher.adjustView()},setAdapter:function(e){this.searcher.setAdapter(e)},isSearching:function(){return this.searcher.isSearching()},stopSearch:function(){this.searcher.stopSearch()},getKeyword:function(){return this.editor.getValue()},hasMatched:function(){return this.searcher.hasMatched()},hasChecked:function(){return this.searcher.getView()&&this.searcher.getView().hasChecked()},setState:function(e){var t=this.options;e||(e={}),e.value||(e.value=[]);var n=0;if(BI.isNumber(e))this.editor.setState(e);else if(0===BI.size(e.value))this.editor.setState(BI.Selection.None);else{var i="";BI.each(e.value,(function(e,r){var a=BI.last(r);i+="null"===r?"":(t.valueFormatter(a+"")||a)+"; ",n++})),n>20?this.editor.setState(BI.Selection.Multi):this.editor.setState(i)}},getState:function(){return this.editor.getState()},setValue:function(e){this.setState(e),this.searcher.setValue(e)},getKey:function(){return this.editor.getValue()},getValue:function(){return this.searcher.getValue()},populate:function(e){this.searcher.populate.apply(this.searcher,arguments)}}),BI.MultiListTreeSearcher.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.MultiListTreeSearcher.EVENT_CHANGE="EVENT_CHANGE",BI.MultiListTreeSearcher.EVENT_START="EVENT_START",BI.MultiListTreeSearcher.EVENT_STOP="EVENT_STOP",BI.MultiListTreeSearcher.EVENT_PAUSE="EVENT_PAUSE",BI.shortcut("bi.multi_list_tree_searcher",BI.MultiListTreeSearcher)},function(e,t){BI.MultiTreeSearcher=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.MultiTreeSearcher.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-tree-searcher",itemsCreator:BI.emptyFn,valueFormatter:function(e){return e},popup:{},adapter:null,masker:{}})},_init:function(){BI.MultiTreeSearcher.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget({type:"bi.multi_select_editor",watermark:t.watermark,height:t.height,el:{type:"bi.simple_state_editor",text:t.text,height:t.height},listeners:[{eventName:BI.MultiSelectEditor.EVENT_FOCUS,action:function(){e.fireEvent(BI.MultiSelectSearcher.EVENT_FOCUS)}},{eventName:BI.MultiSelectEditor.EVENT_BLUR,action:function(){e.fireEvent(BI.MultiSelectSearcher.EVENT_BLUR)}}]}),this.searcher=BI.createWidget({type:"bi.searcher",element:this,isAutoSearch:!1,isAutoSync:!1,onSearch:function(t,n){n({keyword:e.editor.getValue()})},el:this.editor,popup:BI.extend({type:"bi.multi_tree_search_pane",keywordGetter:function(){return e.editor.getValue()},itemsCreator:function(n,i){n.keyword=e.editor.getValue(),t.itemsCreator(n,i)},value:t.value},t.popup),adapter:t.adapter,masker:t.masker}),this.searcher.on(BI.Searcher.EVENT_START,(function(){e.fireEvent(BI.MultiTreeSearcher.EVENT_START)})),this.searcher.on(BI.Searcher.EVENT_PAUSE,(function(){e.fireEvent(BI.MultiTreeSearcher.EVENT_PAUSE)})),this.searcher.on(BI.Searcher.EVENT_STOP,(function(){e.fireEvent(BI.MultiTreeSearcher.EVENT_STOP)})),this.searcher.on(BI.Searcher.EVENT_CHANGE,(function(){e.fireEvent(BI.MultiTreeSearcher.EVENT_CHANGE,arguments)})),this.searcher.on(BI.Searcher.EVENT_SEARCHING,(function(){var t=this.getKeywords();e.fireEvent(BI.MultiTreeSearcher.EVENT_SEARCHING,t)})),BI.isNotNull(t.value)&&this.setState(t.value)},adjustView:function(){this.searcher.adjustView()},setAdapter:function(e){this.searcher.setAdapter(e)},isSearching:function(){return this.searcher.isSearching()},stopSearch:function(){this.searcher.stopSearch()},getKeyword:function(){return this.editor.getValue()},hasMatched:function(){return this.searcher.hasMatched()},hasChecked:function(){return this.searcher.getView()&&this.searcher.getView().hasChecked()},setState:function(e){var t=this.options;e||(e={}),e.value||(e.value={});var n=0;if(BI.isNumber(e))this.editor.setState(e);else if(0===BI.size(e.value))this.editor.setState(BI.Selection.None);else{var i="",r=e.value,a=BI.Func.getSortedResult(BI.keys(r));BI.each(a,(function(e,a){var s=o(r[a]);i+=("null"===a?"":t.valueFormatter(a+"")||a)+(""===s?"":":"+s)+"; ",""===s&&n++})),n>20?this.editor.setState(BI.Selection.Multi):this.editor.setState(i)}function o(e){var i="",r=0,a=BI.size(e),s=BI.Func.getSortedResult(BI.keys(e));return BI.each(s,(function(s,l){r++;var u=o(e[l]);i+=("null"===l?"":t.valueFormatter(l+"")||l)+(""===u?"":":"+u)+(r===a?"":","),""===u&&n++})),i}},getState:function(){return this.editor.getState()},setValue:function(e){this.setState(e),this.searcher.setValue(e)},getKey:function(){return this.editor.getValue()},getValue:function(){return this.searcher.getValue()},populate:function(e){this.searcher.populate.apply(this.searcher,arguments)}}),BI.MultiTreeSearcher.EVENT_SEARCHING="EVENT_SEARCHING",BI.MultiTreeSearcher.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.MultiTreeSearcher.EVENT_CHANGE="EVENT_CHANGE",BI.MultiTreeSearcher.EVENT_START="EVENT_START",BI.MultiTreeSearcher.EVENT_STOP="EVENT_STOP",BI.MultiTreeSearcher.EVENT_PAUSE="EVENT_PAUSE",BI.shortcut("bi.multi_tree_searcher",BI.MultiTreeSearcher)},function(e,t){BI.NumberEditor=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.NumberEditor.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-number-editor bi-border bi-focus-shadow",validationChecker:BI.emptyFn,valueFormatter:function(e){return e},value:0,allowBlank:!1,errorText:"",step:1,min:BI.MIN,max:BI.MAX})},_init:function(){BI.NumberEditor.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget({type:"bi.sign_editor",height:t.height-2,allowBlank:t.allowBlank,value:t.valueFormatter(t.value),validationChecker:function(n){return!(t.validationChecker===BI.emptyFn&&!e._checkValueInRange(n))&&t.validationChecker(n)},errorText:t.errorText}),this.editor.on(BI.TextEditor.EVENT_CHANGE,(function(){e.fireEvent(BI.NumberEditor.EVENT_CHANGE)})),this.editor.on(BI.TextEditor.EVENT_ERROR,(function(){t.value=BI.parseFloat(this.getLastValidValue()),e._checkAdjustDisabled(t.value)})),this.editor.on(BI.TextEditor.EVENT_VALID,(function(){t.value=BI.parseFloat(this.getValue()),e._checkAdjustDisabled(t.value)})),this.editor.on(BI.TextEditor.EVENT_CONFIRM,(function(){e.fireEvent(BI.NumberEditor.EVENT_CONFIRM)})),this.topBtn=BI.createWidget({type:"bi.icon_button",forceNotSelected:!0,trigger:"lclick,",cls:"add-up-font top-button bi-border-left bi-list-item-active2 icon-size-12"}),this.topBtn.on(BI.IconButton.EVENT_CHANGE,(function(){e._finetuning(t.step),e.fireEvent(BI.NumberEditor.EVENT_CHANGE),e.fireEvent(BI.NumberEditor.EVENT_CONFIRM)})),this.bottomBtn=BI.createWidget({type:"bi.icon_button",trigger:"lclick,",forceNotSelected:!0,cls:"minus-down-font bottom-button bi-border-left bi-list-item-active2 icon-size-12"}),this.bottomBtn.on(BI.IconButton.EVENT_CHANGE,(function(){e._finetuning(-t.step),e.fireEvent(BI.NumberEditor.EVENT_CHANGE),e.fireEvent(BI.NumberEditor.EVENT_CONFIRM)})),BI.createWidget({type:"bi.htape",height:t.height-2,element:this,items:[this.editor,{el:{type:"bi.grid",columns:1,rows:2,items:[{column:0,row:0,el:this.topBtn},{column:0,row:1,el:this.bottomBtn}]},width:23}]})},focus:function(){this.editor.focus()},isEditing:function(){return this.editor.isEditing()},_checkValueInRange:function(e){var t=this.options;return!!(BI.isNumeric(e)&&BI.parseFloat(e)>=t.min&&BI.parseFloat(e)<=t.max)},_checkAdjustDisabled:function(e){this.options.validationChecker===BI.emptyFn&&(this.bottomBtn.setEnable(BI.parseFloat(e)>this.options.min),this.topBtn.setEnable(BI.parseFloat(e)<this.options.max))},_finetuning:function(e){var t=BI.parseFloat(this.getValue());this.setValue(BI.add(t,e))},setUpEnable:function(e){this.topBtn.setEnable(!!e)},setDownEnable:function(e){this.bottomBtn.setEnable(!!e)},getLastValidValue:function(){return this.editor.getLastValidValue()},getLastChangedValue:function(){return this.editor.getLastChangedValue()},getValue:function(){return this.options.value},setValue:function(e){var t=this.options;t.value=e,this.editor.setValue(t.valueFormatter(e))}}),BI.NumberEditor.EVENT_CONFIRM="EVENT_CONFIRM",BI.NumberEditor.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.number_editor",BI.NumberEditor)},function(e,t){BI.NumberInterval=BI.inherit(BI.Single,{constants:{typeError:"typeBubble",numberError:"numberBubble",signalError:"signalBubble",editorWidth:114,columns:5,width:24,rows:1,numberErrorCls:"number-error",border:1,less:0,less_equal:1,numTip:"",adjustYOffset:2},_defaultConfig:function(){var e=BI.NumberInterval.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-number-interval"+(BI.isIE()&&BI.getIEVersion()<10?" hack":""),height:24,validation:"valid",closeMin:!0,allowBlank:!0,watermark:BI.i18nText("BI-Basic_Unrestricted")})},_init:function(){var e=this,t=this.constants,n=this.options;BI.NumberInterval.superclass._init.apply(this,arguments),this.smallEditor=BI.createWidget({type:"bi.number_interval_single_editor",height:n.height-2,watermark:n.watermark,allowBlank:n.allowBlank,value:n.min,level:"warning",tipType:"success",title:function(){return e.smallEditor&&e.smallEditor.getValue()},quitChecker:function(){return!1},validationChecker:function(n){return!!BI.isNumeric(n)||(e.smallEditorBubbleType=t.typeError,!1)},cls:"number-interval-small-editor bi-border"}),this.smallTip=BI.createWidget({type:"bi.label",text:n.numTip,height:n.height-2,invisible:!0}),BI.createWidget({type:"bi.absolute",element:this.smallEditor.element,items:[{el:this.smallTip,top:0,right:5}]}),this.bigEditor=BI.createWidget({type:"bi.number_interval_single_editor",height:n.height-2,watermark:n.watermark,allowBlank:n.allowBlank,value:n.max,title:function(){return e.bigEditor&&e.bigEditor.getValue()},quitChecker:function(){return!1},validationChecker:function(n){return!!BI.isNumeric(n)||(e.bigEditorBubbleType=t.typeError,!1)},cls:"number-interval-big-editor bi-border"}),this.bigTip=BI.createWidget({type:"bi.label",text:n.numTip,height:n.height-2,invisible:!0}),BI.createWidget({type:"bi.absolute",element:this.bigEditor.element,items:[{el:this.bigTip,top:0,right:5}]}),this.smallCombo=BI.createWidget({type:"bi.icon_combo",cls:"number-interval-small-combo bi-border-top bi-border-bottom bi-border-right",height:n.height-2,items:[{text:"("+BI.i18nText("BI-Less_Than")+")",iconCls:"less-font",value:0},{text:"("+BI.i18nText("BI-Less_And_Equal")+")",value:1,iconCls:"less-equal-font"}]}),!0===n.closeMin?this.smallCombo.setValue(1):this.smallCombo.setValue(0),this.bigCombo=BI.createWidget({type:"bi.icon_combo",cls:"number-interval-big-combo bi-border-top bi-border-bottom bi-border-left",height:n.height-2,items:[{text:"("+BI.i18nText("BI-Less_Than")+")",iconCls:"less-font",value:0},{text:"("+BI.i18nText("BI-Less_And_Equal")+")",value:1,iconCls:"less-equal-font"}]}),!0===n.closeMax?this.bigCombo.setValue(1):this.bigCombo.setValue(0),this.label=BI.createWidget({type:"bi.label",text:BI.i18nText("BI-Basic_Value"),textHeight:n.height-2*t.border,width:t.width-2*t.border,height:n.height-2*t.border,level:"warning",tipType:"warning"}),this.left=BI.createWidget({type:"bi.htape",items:[{el:e.smallEditor},{el:e.smallCombo,width:t.width-t.border}]}),this.right=BI.createWidget({type:"bi.htape",items:[{el:e.bigCombo,width:t.width-t.border},{el:e.bigEditor,lgap:1}]}),BI.createWidget({element:e,type:"bi.center",hgap:15,height:n.height,items:[{type:"bi.absolute",items:[{el:e.left,left:-15,right:0,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:e.right,left:0,right:-15,top:0,bottom:0}]}]}),BI.createWidget({element:e,type:"bi.horizontal_auto",items:[e.label]}),e._setValidEvent(e.bigEditor,t.bigEditor),e._setValidEvent(e.smallEditor,t.smallEditor),e._setErrorEvent(e.bigEditor,t.bigEditor),e._setErrorEvent(e.smallEditor,t.smallEditor),e._setBlurEvent(e.bigEditor),e._setBlurEvent(e.smallEditor),e._setFocusEvent(e.bigEditor),e._setFocusEvent(e.smallEditor),e._setComboValueChangedEvent(e.bigCombo),e._setComboValueChangedEvent(e.smallCombo),e._setEditorValueChangedEvent(e.bigEditor),e._setEditorValueChangedEvent(e.smallEditor),e._checkValidation()},_checkValidation:function(){var e=this,t=this.constants,n=this.options;if(e._setTitle(""),BI.Bubbles.hide(t.typeError),BI.Bubbles.hide(t.numberError),BI.Bubbles.hide(t.signalError),!e.smallEditor.isValid()||!e.bigEditor.isValid())return e.element.removeClass("number-error"),n.validation="invalid",t.typeError;if(BI.isEmptyString(e.smallEditor.getValue())||BI.isEmptyString(e.bigEditor.getValue()))return e.element.removeClass("number-error"),n.validation="valid","";var i=parseFloat(e.smallEditor.getValue()),r=parseFloat(e.bigEditor.getValue()),a=e.bigCombo.getValue(),o=e.smallCombo.getValue();return a[0]===t.less_equal&&o[0]===t.less_equal?i>r?(e.element.addClass("number-error"),n.validation="invalid",t.numberError):(e.element.removeClass("number-error"),n.validation="valid",""):i>r?(e.element.addClass("number-error"),n.validation="invalid",t.numberError):i===r?(e.element.addClass("number-error"),n.validation="invalid",t.signalError):(e.element.removeClass("number-error"),n.validation="valid","")},_setTitle:function(e){this.label.setTitle(e)},_setFocusEvent:function(e){var t=this,n=this.constants;e.on(BI.NumberIntervalSingleEidtor.EVENT_FOCUS,(function(){switch(t._setTitle(""),t._checkValidation()){case n.typeError:BI.Bubbles.show(n.typeError,BI.i18nText("BI-Numerical_Interval_Input_Data"),t,{offsetStyle:"left",adjustYOffset:n.adjustYOffset});break;case n.numberError:BI.Bubbles.show(n.numberError,BI.i18nText("BI-Numerical_Interval_Number_Value"),t,{offsetStyle:"left",adjustYOffset:n.adjustYOffset});break;case n.signalError:BI.Bubbles.show(n.signalError,BI.i18nText("BI-Numerical_Interval_Signal_Value"),t,{offsetStyle:"left",adjustYOffset:n.adjustYOffset});break;default:return}}))},_setBlurEvent:function(e){var t=this.constants,n=this;e.on(BI.NumberIntervalSingleEidtor.EVENT_BLUR,(function(){switch(BI.Bubbles.hide(t.typeError),BI.Bubbles.hide(t.numberError),BI.Bubbles.hide(t.signalError),n._checkValidation()){case t.typeError:n._setTitle(BI.i18nText("BI-Numerical_Interval_Input_Data"));break;case t.numberError:n._setTitle(BI.i18nText("BI-Numerical_Interval_Number_Value"));break;case t.signalError:n._setTitle(BI.i18nText("BI-Numerical_Interval_Signal_Value"));break;default:n._setTitle("")}}))},_setErrorEvent:function(e){var t=this.constants,n=this;e.on(BI.NumberIntervalSingleEidtor.EVENT_ERROR,(function(){n._checkValidation(),BI.Bubbles.show(t.typeError,BI.i18nText("BI-Numerical_Interval_Input_Data"),n,{offsetStyle:"left",adjustYOffset:t.adjustYOffset}),n.fireEvent(BI.NumberInterval.EVENT_ERROR)}))},_setValidEvent:function(e){var t=this,n=this.constants;e.on(BI.NumberIntervalSingleEidtor.EVENT_VALID,(function(){switch(t._checkValidation()){case n.numberError:BI.Bubbles.show(n.numberError,BI.i18nText("BI-Numerical_Interval_Number_Value"),t,{offsetStyle:"left",adjustYOffset:n.adjustYOffset}),t.fireEvent(BI.NumberInterval.EVENT_ERROR);break;case n.signalError:BI.Bubbles.show(n.signalError,BI.i18nText("BI-Numerical_Interval_Signal_Value"),t,{offsetStyle:"left",adjustYOffset:n.adjustYOffset}),t.fireEvent(BI.NumberInterval.EVENT_ERROR);break;default:t.fireEvent(BI.NumberInterval.EVENT_VALID)}}))},_setEditorValueChangedEvent:function(e){var t=this,n=this.constants;e.on(BI.NumberIntervalSingleEidtor.EVENT_CHANGE,(function(){switch(t._checkValidation()){case n.typeError:BI.Bubbles.show(n.typeError,BI.i18nText("BI-Numerical_Interval_Input_Data"),t,{offsetStyle:"left",adjustYOffset:n.adjustYOffset});break;case n.numberError:BI.Bubbles.show(n.numberError,BI.i18nText("BI-Numerical_Interval_Number_Value"),t,{offsetStyle:"left",adjustYOffset:n.adjustYOffset});break;case n.signalError:BI.Bubbles.show(n.signalError,BI.i18nText("BI-Numerical_Interval_Signal_Value"),t,{offsetStyle:"left",adjustYOffset:n.adjustYOffset})}t.fireEvent(BI.NumberInterval.EVENT_CHANGE)})),e.on(BI.NumberIntervalSingleEidtor.EVENT_CONFIRM,(function(){t.fireEvent(BI.NumberInterval.EVENT_CONFIRM)}))},_setComboValueChangedEvent:function(e){var t=this,n=this.constants;e.on(BI.IconCombo.EVENT_CHANGE,(function(){switch(t._checkValidation()){case n.typeError:t._setTitle(BI.i18nText("BI-Numerical_Interval_Input_Data")),t.fireEvent(BI.NumberInterval.EVENT_ERROR);break;case n.numberError:t._setTitle(BI.i18nText("BI-Numerical_Interval_Number_Value")),t.fireEvent(BI.NumberInterval.EVENT_ERROR);break;case n.signalError:t._setTitle(BI.i18nText("BI-Numerical_Interval_Signal_Value")),t.fireEvent(BI.NumberInterval.EVENT_ERROR);break;default:t.fireEvent(BI.NumberInterval.EVENT_CHANGE),t.fireEvent(BI.NumberInterval.EVENT_CONFIRM),t.fireEvent(BI.NumberInterval.EVENT_VALID)}}))},isStateValid:function(){return"valid"===this.options.validation},setMinEnable:function(e){this.smallEditor.setEnable(e)},setCloseMinEnable:function(e){this.smallCombo.setEnable(e)},setMaxEnable:function(e){this.bigEditor.setEnable(e)},setCloseMaxEnable:function(e){this.bigCombo.setEnable(e)},showNumTip:function(){this.smallTip.setVisible(!0),this.bigTip.setVisible(!0)},hideNumTip:function(){this.smallTip.setVisible(!1),this.bigTip.setVisible(!1)},setNumTip:function(e){this.smallTip.setText(e),this.bigTip.setText(e)},getNumTip:function(){return this.smallTip.getText()},setValue:function(e){e=e||{};var t,n=this;(BI.isNumeric(e.min)||BI.isEmptyString(e.min))&&n.smallEditor.setValue(e.min),BI.isNotNull(e.min)||n.smallEditor.setValue(""),(BI.isNumeric(e.max)||BI.isEmptyString(e.max))&&n.bigEditor.setValue(e.max),BI.isNotNull(e.max)||n.bigEditor.setValue(""),BI.isNull(e.closeMin)||(t=!0===e.closeMin?1:0,n.smallCombo.setValue(t)),BI.isNull(e.closeMax)||(t=!0===e.closeMax?1:0,n.bigCombo.setValue(t)),this._checkValidation()},getValue:function(){var e=this,t={},n=e.smallCombo.getValue(),i=e.bigCombo.getValue();return t.min=e.smallEditor.getValue(),t.max=e.bigEditor.getValue(),0===n[0]?t.closeMin=!1:t.closeMin=!0,0===i[0]?t.closeMax=!1:t.closeMax=!0,t},destroyed:function(){var e=this.constants;BI.Bubbles.remove(e.typeError),BI.Bubbles.remove(e.numberError),BI.Bubbles.remove(e.signalError)}}),BI.NumberInterval.EVENT_CHANGE="EVENT_CHANGE",BI.NumberInterval.EVENT_CONFIRM="EVENT_CONFIRM",BI.NumberInterval.EVENT_VALID="EVENT_VALID",BI.NumberInterval.EVENT_ERROR="EVENT_ERROR",BI.shortcut("bi.number_interval",BI.NumberInterval)},function(e,t){BI.NumberIntervalSingleEidtor=BI.inherit(BI.Single,{props:{baseCls:"bi-number-interval-single-editor",tipType:"success",title:""},render:function(){var e=this,t=this.options;return{type:"bi.vertical",items:[{type:"bi.editor",ref:function(t){e.editor=t},height:t.height,watermark:t.watermark,allowBlank:t.allowBlank,value:t.value,quitChecker:t.quitChecker,validationChecker:t.validationChecker,listeners:[{eventName:BI.Editor.EVENT_ERROR,action:function(){e.fireEvent(BI.NumberIntervalSingleEidtor.EVENT_ERROR,arguments)}},{eventName:BI.Editor.EVENT_FOCUS,action:function(){e.fireEvent(BI.NumberIntervalSingleEidtor.EVENT_FOCUS,arguments)}},{eventName:BI.Editor.EVENT_BLUR,action:function(){e.fireEvent(BI.NumberIntervalSingleEidtor.EVENT_BLUR,arguments)}},{eventName:BI.Editor.EVENT_VALID,action:function(){e.fireEvent(BI.NumberIntervalSingleEidtor.EVENT_VALID,arguments)}},{eventName:BI.Editor.EVENT_CHANGE,action:function(){e.fireEvent(BI.NumberIntervalSingleEidtor.EVENT_CHANGE,arguments)}},{eventName:BI.Editor.EVENT_CONFIRM,action:function(){e.fireEvent(BI.NumberIntervalSingleEidtor.EVENT_CONFIRM,arguments)}},{eventName:BI.Editor.EVENT_CHANGE_CONFIRM,action:function(){e.fireEvent(BI.NumberIntervalSingleEidtor.EVENT_CHANGE_CONFIRM,arguments)}}]}]}},isValid:function(){return this.editor.isValid()},getValue:function(){return this.editor.getValue()},setValue:function(e){return this.editor.setValue(e)}}),BI.NumberIntervalSingleEidtor.EVENT_FOCUS="EVENT_FOCUS",BI.NumberIntervalSingleEidtor.EVENT_BLUR="EVENT_BLUR",BI.NumberIntervalSingleEidtor.EVENT_ERROR="EVENT_ERROR",BI.NumberIntervalSingleEidtor.EVENT_VALID="EVENT_VALID",BI.NumberIntervalSingleEidtor.EVENT_CHANGE="EVENT_CHANGE",BI.NumberIntervalSingleEidtor.EVENT_CHANGE_CONFIRM="EVENT_CHANGE_CONFIRM",BI.NumberIntervalSingleEidtor.EVENT_CONFIRM="EVENT_CONFIRM",BI.shortcut("bi.number_interval_single_editor",BI.NumberIntervalSingleEidtor)},function(e,t){BI.SearchMultiTextValueCombo=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.SearchMultiTextValueCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-combo bi-search-multi-text-value-combo",height:24,items:[]})},_init:function(){var e=this,t=this.options;BI.SearchMultiTextValueCombo.superclass._init.apply(this,arguments);var n=function(){BI.isKey(e._startValue)&&(e.storeValue.type===BI.Selection.All?BI.remove(e.storeValue.value,e._startValue):BI.pushDistinct(e.storeValue.value,e._startValue)),e._updateAllValue(),e._checkError(),e.trigger.getSearcher().setState(e.storeValue),e.trigger.getCounter().setButtonChecked(e.storeValue)};this.storeValue=BI.deepClone(t.value||{}),this._updateAllValue(),this._assertValue(this.storeValue),this._checkError(),this.requesting=!1,this.trigger=BI.createWidget({type:"bi.search_multi_select_trigger",text:t.text,height:t.height-2,masker:{offset:{left:0,top:0,right:0,bottom:25}},allValueGetter:function(){return e.allValue},valueFormatter:t.valueFormatter,itemsCreator:function(t,n){e._itemsCreator(t,(function(i){1===t.times&&BI.isNotNull(t.keywords)&&e.trigger.setValue(BI.deepClone(e.getValue())),n.apply(e,arguments)}))},value:this.storeValue,warningTitle:t.warningTitle}),this.trigger.on(BI.MultiSelectTrigger.EVENT_START,(function(){e._setStartValue(""),this.getSearcher().setValue(e.storeValue)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_STOP,(function(){e._setStartValue("")})),this.trigger.on(BI.MultiSelectTrigger.EVENT_SEARCHING,(function(t){var i=BI.last(t);(t=BI.initial(t||[])).length>0&&e._joinKeywords(t,(function(){BI.endWith(i,BI.BlankSplitChar)?(e.combo.setValue(e.storeValue),n(),e.combo.populate(),e._setStartValue("")):(e.combo.setValue(e.storeValue),n()),e._dataChange=!0}))})),this.trigger.on(BI.MultiSelectTrigger.EVENT_CHANGE,(function(t,i){i instanceof BI.MultiSelectBar?e._joinAll(this.getValue(),(function(){n()})):e._join(this.getValue(),(function(){n()})),e._dataChange=!0})),this.trigger.on(BI.MultiSelectTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW,(function(){this.getCounter().setValue(e.storeValue)})),this.trigger.on(BI.MultiSelectTrigger.EVENT_COUNTER_CLICK,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!1,container:t.container,el:this.trigger,adjustLength:1,popup:{type:"bi.search_multi_select_popup_view",ref:function(){e.popup=this,e.trigger.setAdapter(this)},listeners:[{eventName:BI.MultiSelectPopupView.EVENT_CHANGE,action:function(){e._dataChange=!0,e.storeValue=this.getValue(),e._adjust((function(){n()}))}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CONFIRM,action:function(){e._defaultState()}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CLEAR,action:function(){e._dataChange=!0,e.setValue(),e._defaultState()}}],itemsCreator:BI.bind(e._itemsCreator,this),valueFormatter:t.valueFormatter,onLoaded:function(){BI.nextTick((function(){e.combo.adjustWidth(),e.combo.adjustHeight(),e.trigger.getCounter().adjustView(),e.trigger.getSearcher().adjustView()}))}},value:t.value,hideChecker:function(e){return 0===i.element.find(e.target).length}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){this.isViewVisible()||(e._dataChange=!1),this.setValue(e.storeValue),BI.nextTick((function(){e._populate()}))})),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,(function(){e.trigger.stopEditing(),!0===e.requesting?e.wants2Quit=!0:(n(),e._dataChange&&e.fireEvent(BI.SearchMultiTextValueCombo.EVENT_CONFIRM))}));var i=BI.createWidget({type:"bi.trigger_icon_button",width:t.height,height:t.height,cls:"multi-select-trigger-icon-button"});i.on(BI.TriggerIconButton.EVENT_CHANGE,(function(){e.trigger.getCounter().hideView(),e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:i,right:0,top:0,bottom:0}]}),this._checkError()},_defaultState:function(){this.trigger.stopEditing(),this.combo.hideView()},_assertValue:function(e){var t=this.options;e||(e={}),e.type||(e.type=BI.Selection.Multi),e.value||(e.value=[]),BI.remove(e.value,(function(e,n){return!BI.contains(BI.map(t.items,"value"),n)}))},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(e,t){var n=this;this.options;this._assertValue(this.storeValue),this.requesting=!0,this._itemsCreator({type:BI.SearchMultiTextValueCombo.REQ_GET_ALL_DATA,keywords:e},(function(i){var r,a,o=BI.map(i.items,"value");r=o,a=n._makeMap(r),BI.each(e,(function(e,t){BI.isNotNull(a[t])&&(n.storeValue.type===BI.Selection.Multi?BI.pushDistinct(n.storeValue.value,t):BI.remove(n.storeValue.value,t))})),n._adjust(t)}))},_joinAll:function(e,t){var n=this;this.options;this._assertValue(e),this.requesting=!0,this._itemsCreator({type:BI.SearchMultiTextValueCombo.REQ_GET_ALL_DATA,keywords:[this.trigger.getKey()]},(function(i){var r=BI.map(i.items,"value");if(n.storeValue.type===e.type){var a=!1,o=n._makeMap(n.storeValue.value);return BI.each(r,(function(e,t){BI.isNotNull(o[t])&&(a=!0,n.storeValue.assist&&n.storeValue.assist.push(o[t]),delete o[t])})),a&&(n.storeValue.value=BI.values(o)),void n._adjust(t)}var s=n._makeMap(n.storeValue.value),l=n._makeMap(e.value),u=[];BI.each(r,(function(e,t){BI.isNotNull(s[r[e]])&&(n.storeValue.assist&&n.storeValue.assist.push(s[r[e]]),delete s[r[e]]),BI.isNull(l[r[e]])&&(BI.remove(n.storeValue.assist,t),u.push(t))})),n.storeValue.value=u.concat(BI.values(s)),n._adjust(t)}))},_adjust:function(e){var t=this;this.options;function n(){t.storeValue.type===BI.Selection.All&&t.storeValue.value.length>=t._count?t.storeValue={type:BI.Selection.Multi,value:[]}:t.storeValue.type===BI.Selection.Multi&&t.storeValue.value.length>=t._count&&(t.storeValue={type:BI.Selection.All,value:[]}),t._updateAllValue(),t._checkError(),!0===t.wants2Quit&&(t.fireEvent(BI.SearchMultiTextValueCombo.EVENT_CONFIRM),t.wants2Quit=!1),t.requesting=!1}this._count?(n(),e()):this._itemsCreator({type:BI.SearchMultiTextValueCombo.REQ_GET_DATA_LENGTH},(function(i){t._count=i.count,n(),e()}))},_join:function(e,t){var n=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var i=this._makeMap(this.storeValue.value);BI.each(e.value,(function(e,t){i[t]||(n.storeValue.value.push(t),BI.remove(n.storeValue.assist,t),i[t]=t)}));var r=!1;return BI.each(e.assist,(function(e,t){BI.isNotNull(i[t])&&(r=!0,n.storeValue.assist&&n.storeValue.assist.push(i[t]),delete i[t])})),r&&(this.storeValue.value=BI.values(i)),void n._adjust(t)}this._joinAll(e,t)},_setStartValue:function(e){this._startValue=e,this.popup.setStartValue(e)},_getItemsByTimes:function(e,t){for(var n=[],i=100*(t-1);e[i]&&i<100*t;i++)n.push(e[i]);return n},_hasNextByTimes:function(e,t){return 100*t<e.length},_itemsCreator:function(e,t){var n=this.options.items,i=(e.keywords||[]).slice();if(e.keyword&&i.push(e.keyword),BI.each(i,(function(e,t){var i=BI.Func.getSearchResult(n,t);n=i.match.concat(i.find)})),e.selectedValues){var r=BI.makeObject(e.selectedValues,!0);n=BI.filter(n,(function(e,t){return!r[t.value]}))}e.type!=BI.MultiSelectCombo.REQ_GET_ALL_DATA?e.type!=BI.MultiSelectCombo.REQ_GET_DATA_LENGTH?t({items:this._getItemsByTimes(n,e.times),hasNext:this._hasNextByTimes(n,e.times)}):t({count:n.length}):t({items:n})},_checkError:function(){var e=this.storeValue.value||[];if(BI.isNotEmptyArray(e)){e=BI.isArray(e)?e:[e];var t=BI.find(this.allValue,(function(t,n){return!BI.contains(e,n)}));BI.isNull(t)?(BI.isNotNull(this.trigger)&&this.trigger.setTipType("success"),this.element.removeClass("combo-error")):(BI.isNotNull(this.trigger)&&this.trigger.setTipType("warning"),this.element.addClass("combo-error"))}else e.length===this.allValue.length?(BI.isNotNull(this.trigger)&&this.trigger.setTipType("success"),this.element.removeClass("combo-error")):(BI.isNotNull(this.trigger)&&this.trigger.setTipType("warning"),this.element.addClass("combo-error"))},_updateAllValue:function(){this.storeValue=this.storeValue||{},this.allValue=BI.deepClone(this.storeValue.value||[])},setValue:function(e){this.storeValue=BI.deepClone(e||{}),this._updateAllValue(),this._assertValue(this.storeValue),this.combo.setValue(this.storeValue),this._checkError()},getValue:function(){return BI.deepClone(this.storeValue)},_populate:function(){this._count=null,this.combo.populate()},populate:function(e){this.options.items=e,this._populate()}}),BI.extend(BI.SearchMultiTextValueCombo,{REQ_GET_DATA_LENGTH:1,REQ_GET_ALL_DATA:-1}),BI.SearchMultiTextValueCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.shortcut("bi.search_multi_text_value_combo",BI.SearchMultiTextValueCombo)},function(e,t){BI.SearchMultiSelectTrigger=BI.inherit(BI.Trigger,{constants:{height:14,rgap:4,lgap:4},_defaultConfig:function(){return BI.extend(BI.SearchMultiSelectTrigger.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-trigger",itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,searcher:{},switcher:{},adapter:null,masker:{}})},_init:function(){BI.SearchMultiSelectTrigger.superclass._init.apply(this,arguments);var e=this,t=this.options;this.searcher=BI.createWidget(t.searcher,{type:"bi.search_multi_select_searcher",height:t.height,itemsCreator:t.itemsCreator,valueFormatter:t.valueFormatter,allValueGetter:t.allValueGetter,popup:{},adapter:t.adapter,masker:t.masker,value:t.value,text:t.text,tipType:t.tipType,warningTitle:t.warningTitle}),this.searcher.on(BI.MultiSelectSearcher.EVENT_START,(function(){e.fireEvent(BI.SearchMultiSelectTrigger.EVENT_START)})),this.searcher.on(BI.MultiSelectSearcher.EVENT_PAUSE,(function(){e.fireEvent(BI.SearchMultiSelectTrigger.EVENT_PAUSE)})),this.searcher.on(BI.MultiSelectSearcher.EVENT_SEARCHING,(function(){e.fireEvent(BI.SearchMultiSelectTrigger.EVENT_SEARCHING,arguments)})),this.searcher.on(BI.MultiSelectSearcher.EVENT_STOP,(function(){e.fireEvent(BI.SearchMultiSelectTrigger.EVENT_STOP)})),this.searcher.on(BI.MultiSelectSearcher.EVENT_CHANGE,(function(){e.fireEvent(BI.SearchMultiSelectTrigger.EVENT_CHANGE,arguments)})),this.numberCounter=BI.createWidget(t.switcher,{type:"bi.multi_select_check_selected_switcher",valueFormatter:t.valueFormatter,itemsCreator:t.itemsCreator,adapter:t.adapter,masker:t.masker,value:t.value}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,(function(){e.fireEvent(BI.SearchMultiSelectTrigger.EVENT_COUNTER_CLICK)})),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,(function(){e.fireEvent(BI.SearchMultiSelectTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW)}));var n=BI.createWidget({type:"bi.right_vertical_adapt",hgap:4,items:[{el:this.numberCounter}]}),i=BI.createWidget({type:"bi.htape",element:this,items:[{el:this.searcher,width:"fill"},{el:n,width:0},{el:BI.createWidget(),width:24}]});this.numberCounter.on(BI.Events.VIEW,(function(t){BI.nextTick((function(){i.attr("items")[1].width=!0===t?e.numberCounter.element.outerWidth()+8:0,i.resize()}))})),this.element.click((function(t){e.element.find(t.target).length>0&&e.numberCounter.hideView()}))},getCounter:function(){return this.numberCounter},getSearcher:function(){return this.searcher},stopEditing:function(){this.searcher.stopSearch(),this.numberCounter.hideView()},setAdapter:function(e){this.searcher.setAdapter(e),this.numberCounter.setAdapter(e)},setValue:function(e){this.searcher.setValue(e),this.numberCounter.setValue(e)},setTipType:function(e){this.searcher.setTipType(e)},getKey:function(){return this.searcher.getKey()},getValue:function(){return this.searcher.getValue()}}),BI.SearchMultiSelectTrigger.EVENT_TRIGGER_CLICK="EVENT_TRIGGER_CLICK",BI.SearchMultiSelectTrigger.EVENT_COUNTER_CLICK="EVENT_COUNTER_CLICK",BI.SearchMultiSelectTrigger.EVENT_CHANGE="EVENT_CHANGE",BI.SearchMultiSelectTrigger.EVENT_START="EVENT_START",BI.SearchMultiSelectTrigger.EVENT_STOP="EVENT_STOP",BI.SearchMultiSelectTrigger.EVENT_PAUSE="EVENT_PAUSE",BI.SearchMultiSelectTrigger.EVENT_SEARCHING="EVENT_SEARCHING",BI.SearchMultiSelectTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW="EVENT_BEFORE_COUNTER_POPUPVIEW",BI.shortcut("bi.search_multi_select_trigger",BI.SearchMultiSelectTrigger)},function(e,t){BI.SearchMultiSelectLoader=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SearchMultiSelectLoader.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-loader",logic:{dynamic:!0},el:{height:400},valueFormatter:BI.emptyFn,itemsCreator:BI.emptyFn,onLoaded:BI.emptyFn})},_init:function(){BI.SearchMultiSelectLoader.superclass._init.apply(this,arguments);var e=this,t=this.options,n=!1;this.storeValue=t.value||{},this._assertValue(this.storeValue),this.button_group=BI.createWidget({type:"bi.select_list",element:this,logic:t.logic,el:BI.extend({onLoaded:t.onLoaded,el:{type:"bi.loader",isDefaultInit:!1,logic:{dynamic:!0,scrolly:!0},el:{chooseType:BI.ButtonGroup.CHOOSE_TYPE_MULTI,behaviors:{redmark:function(){return!0}},layouts:[{type:"bi.vertical"}]}}},t.el),itemsCreator:function(i,r){var a=e._startValue;e.storeValue&&(i=BI.extend(i||{},{selectedValues:BI.isKey(a)&&e.storeValue.type===BI.Selection.Multi?e.storeValue.value.concat(a):e.storeValue.value})),t.itemsCreator(i,(function(o){n=o.hasNext;var s=[];if(1===i.times&&e.storeValue){var l=BI.map(e.storeValue.value,(function(n,i){var r=t.valueFormatter(i)||i;return{text:r,value:i,title:r,selected:e.storeValue.type===BI.Selection.Multi}}));if(BI.isKey(e._startValue)&&!BI.contains(e.storeValue.value,e._startValue)){var u=t.valueFormatter(a)||a;l.unshift({text:u,value:a,title:u,selected:!0})}s=e._createItems(l)}r(s.concat(e._createItems(o.items)),o.keyword||""),1===i.times&&e.storeValue&&(BI.isKey(a)&&(e.storeValue.type===BI.Selection.All?BI.remove(e.storeValue.value,a):BI.pushDistinct(e.storeValue.value,a)),e.setValue(e.storeValue)),1===i.times&&e._scrollToTop()}))},hasNext:function(){return n},value:this.storeValue}),this.button_group.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.button_group.on(BI.SelectList.EVENT_CHANGE,(function(){e.fireEvent(BI.SearchMultiSelectLoader.EVENT_CHANGE,arguments)}))},_createItems:function(e){return BI.createItems(e,{type:"bi.multi_select_item",logic:this.options.logic,cls:"bi-list-item-active",height:24,selected:this.isAllSelected(),iconWrapperWidth:36})},_scrollToTop:function(){var e=this;BI.delay((function(){e.button_group.element.scrollTop(0)}),30)},isAllSelected:function(){return this.button_group.isAllSelected()},_assertValue:function(e){e||(e={}),e.type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},setStartValue:function(e){this._startValue=e},setValue:function(e){this.storeValue=e||{},this._assertValue(this.storeValue),this.button_group.setValue(this.storeValue)},getValue:function(){return this.button_group.getValue()},getAllButtons:function(){return this.button_group.getAllButtons()},empty:function(){this.button_group.empty()},populate:function(e){BI.isNotNull(e)&&(arguments[0]=this._createItems(e)),this.button_group.populate.apply(this.button_group,arguments)},resetHeight:function(e){this.button_group.resetHeight(e)},resetWidth:function(e){this.button_group.resetWidth(e)}}),BI.SearchMultiSelectLoader.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.search_multi_select_loader",BI.SearchMultiSelectLoader)},function(e,t){BI.SearchMultiSelectPopupView=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SearchMultiSelectPopupView.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-popup-view",maxWidth:"auto",minWidth:135,maxHeight:400,valueFormatter:BI.emptyFn,itemsCreator:BI.emptyFn,onLoaded:BI.emptyFn})},_init:function(){BI.SearchMultiSelectPopupView.superclass._init.apply(this,arguments);var e=this,t=this.options;this.loader=BI.createWidget({type:"bi.search_multi_select_loader",itemsCreator:t.itemsCreator,valueFormatter:t.valueFormatter,onLoaded:t.onLoaded,value:t.value}),this.popupView=BI.createWidget({type:"bi.multi_popup_view",stopPropagation:!1,maxWidth:t.maxWidth,minWidth:t.minWidth,maxHeight:t.maxHeight,element:this,buttons:[BI.i18nText("BI-Basic_Clears"),BI.i18nText("BI-Basic_Sure")],el:this.loader,value:t.value}),this.popupView.on(BI.MultiPopupView.EVENT_CHANGE,(function(){e.fireEvent(BI.SearchMultiSelectPopupView.EVENT_CHANGE)})),this.popupView.on(BI.MultiPopupView.EVENT_CLICK_TOOLBAR_BUTTON,(function(t){switch(t){case 0:e.fireEvent(BI.SearchMultiSelectPopupView.EVENT_CLICK_CLEAR);break;case 1:e.fireEvent(BI.SearchMultiSelectPopupView.EVENT_CLICK_CONFIRM)}}))},isAllSelected:function(){return this.loader.isAllSelected()},setStartValue:function(e){this.loader.setStartValue(e)},setValue:function(e){this.popupView.setValue(e)},getValue:function(){return this.popupView.getValue()},populate:function(e){this.popupView.populate.apply(this.popupView,arguments)},resetHeight:function(e){this.popupView.resetHeight(e)},resetWidth:function(e){this.popupView.resetWidth(e)}}),BI.SearchMultiSelectPopupView.EVENT_CHANGE="EVENT_CHANGE",BI.SearchMultiSelectPopupView.EVENT_CLICK_CONFIRM="EVENT_CLICK_CONFIRM",BI.SearchMultiSelectPopupView.EVENT_CLICK_CLEAR="EVENT_CLICK_CLEAR",BI.shortcut("bi.search_multi_select_popup_view",BI.SearchMultiSelectPopupView)},function(e,t){BI.SearchMultiSelectSearcher=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SearchMultiSelectSearcher.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-searcher",itemsCreator:BI.emptyFn,el:{},popup:{},valueFormatter:BI.emptyFn,adapter:null,masker:{}})},_init:function(){BI.SearchMultiSelectSearcher.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget(t.el,{type:"bi.multi_select_editor",height:t.height,text:t.text,tipType:t.tipType,warningTitle:t.warningTitle}),this.searcher=BI.createWidget({type:"bi.searcher",element:this,height:t.height,isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t()},el:this.editor,popup:BI.extend({type:"bi.multi_select_search_pane",valueFormatter:t.valueFormatter,keywordGetter:function(){return e.editor.getValue()},itemsCreator:function(n,i){var r=e.editor.getValue();n.keywords=[r],t.itemsCreator(n,i)},value:t.value},t.popup),adapter:t.adapter,masker:t.masker}),this.searcher.on(BI.Searcher.EVENT_START,(function(){e.fireEvent(BI.SearchMultiSelectSearcher.EVENT_START)})),this.searcher.on(BI.Searcher.EVENT_PAUSE,(function(){this.hasMatched(),e.fireEvent(BI.SearchMultiSelectSearcher.EVENT_PAUSE)})),this.searcher.on(BI.Searcher.EVENT_STOP,(function(){e.fireEvent(BI.SearchMultiSelectSearcher.EVENT_STOP)})),this.searcher.on(BI.Searcher.EVENT_CHANGE,(function(){e.fireEvent(BI.SearchMultiSelectSearcher.EVENT_CHANGE,arguments)})),this.searcher.on(BI.Searcher.EVENT_SEARCHING,(function(){var t=this.getKeywords();e.fireEvent(BI.SearchMultiSelectSearcher.EVENT_SEARCHING,t)})),BI.isNotNull(t.value)&&this.setState(t.value)},adjustView:function(){this.searcher.adjustView()},isSearching:function(){return this.searcher.isSearching()},stopSearch:function(){this.searcher.stopSearch()},getKeyword:function(){return this.editor.getValue()},hasMatched:function(){return this.searcher.hasMatched()},hasChecked:function(){return this.searcher.getView()&&this.searcher.getView().hasChecked()},setAdapter:function(e){this.searcher.setAdapter(e)},setState:function(e){var t=this.options,n={};if(n.type=e.type,n.value=t.allValueGetter()||[],n.assist=e.assist,n.type===BI.Selection.All)if(0===n.value.length)this.editor.setState(BI.Selection.All);else if(BI.size(n.assist)<=20){var i="";BI.each(n.assist,(function(e,n){i+=0===e?""+(t.valueFormatter(n+"")||n):","+(t.valueFormatter(n+"")||n)})),this.editor.setState(i)}else this.editor.setState(BI.Selection.Multi);else if(0===n.value.length)this.editor.setState(BI.Selection.None);else if(BI.size(n.value)<=20){i="";BI.each(n.value,(function(e,n){i+=0===e?""+(t.valueFormatter(n+"")||n):","+(t.valueFormatter(n+"")||n)})),this.editor.setState(i)}else this.editor.setState(BI.Selection.Multi)},setTipType:function(e){this.editor.setTipType(e)},setValue:function(e){this.setState(e),this.searcher.setValue(e)},getKey:function(){return this.editor.getValue()},getValue:function(){return this.searcher.getValue()},populate:function(e){this.searcher.populate.apply(this.searcher,arguments)}}),BI.SearchMultiSelectSearcher.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.SearchMultiSelectSearcher.EVENT_CHANGE="EVENT_CHANGE",BI.SearchMultiSelectSearcher.EVENT_START="EVENT_START",BI.SearchMultiSelectSearcher.EVENT_STOP="EVENT_STOP",BI.SearchMultiSelectSearcher.EVENT_PAUSE="EVENT_PAUSE",BI.SearchMultiSelectSearcher.EVENT_SEARCHING="EVENT_SEARCHING",BI.shortcut("bi.search_multi_select_searcher",BI.SearchMultiSelectSearcher)},function(e,t){BI.SelectTreeFirstPlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.SelectTreeFirstPlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-select-tree-first-plus-group-node bi-list-item-active",logic:{dynamic:!1},id:"",pId:"",readonly:!0,open:!1,height:24})},_init:function(){BI.SelectTreeFirstPlusGroupNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.checkbox=BI.createWidget({type:"bi.first_tree_node_checkbox",stopPropagation:!0}),this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:t.height,height:t.height,hgap:t.hgap,text:t.text,value:t.value,keyword:t.keyword,py:t.py}),this.checkbox.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&(this.isSelected()?e.triggerExpand():e.triggerCollapse())}));var n=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),i=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(n,BI.extend(t.logic,{items:i}))))},isOnce:function(){return!0},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.NodeButton.superclass.doClick.apply(this,arguments)},setOpened:function(e){BI.SelectTreeFirstPlusGroupNode.superclass.setOpened.apply(this,arguments),BI.isNotNull(this.checkbox)&&this.checkbox.setSelected(e)}}),BI.shortcut("bi.select_tree_first_plus_group_node",BI.SelectTreeFirstPlusGroupNode)},function(e,t){BI.SelectTreeLastPlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.SelectTreeLastPlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-select-tree-last-plus-group-node bi-list-item-active",logic:{dynamic:!1},id:"",pId:"",readonly:!0,open:!1,height:24})},_init:function(){BI.SelectTreeLastPlusGroupNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.checkbox=BI.createWidget({type:"bi.last_tree_node_checkbox",stopPropagation:!0}),this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:t.height,height:t.height,hgap:t.hgap,text:t.text,value:t.value,keyword:t.keyword,py:t.py}),this.checkbox.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&(this.isSelected()?e.triggerExpand():e.triggerCollapse())}));var n=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),i=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(n,BI.extend(t.logic,{items:i}))))},isOnce:function(){return!0},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.NodeButton.superclass.doClick.apply(this,arguments)},setOpened:function(e){BI.SelectTreeLastPlusGroupNode.superclass.setOpened.apply(this,arguments),BI.isNotNull(this.checkbox)&&this.checkbox.setSelected(e)}}),BI.shortcut("bi.select_tree_last_plus_group_node",BI.SelectTreeLastPlusGroupNode)},function(e,t){BI.SelectTreeMidPlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.SelectTreeMidPlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-select-tree-mid-plus-group-node bi-list-item-active",logic:{dynamic:!1},id:"",pId:"",readonly:!0,open:!1,height:24})},_init:function(){BI.SelectTreeMidPlusGroupNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.checkbox=BI.createWidget({type:"bi.mid_tree_node_checkbox",stopPropagation:!0}),this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:t.height,height:t.height,hgap:t.hgap,text:t.text,value:t.value,keyword:t.keyword,py:t.py}),this.checkbox.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&(this.isSelected()?e.triggerExpand():e.triggerCollapse())}));var n=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),i=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(n,BI.extend(t.logic,{items:i}))))},isOnce:function(){return!0},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.NodeButton.superclass.doClick.apply(this,arguments)},setOpened:function(e){BI.SelectTreeMidPlusGroupNode.superclass.setOpened.apply(this,arguments),BI.isNotNull(this.checkbox)&&this.checkbox.setSelected(e)}}),BI.shortcut("bi.select_tree_mid_plus_group_node",BI.SelectTreeMidPlusGroupNode)},function(e,t){BI.SelectTreePlusGroupNode=BI.inherit(BI.NodeButton,{_defaultConfig:function(){var e=BI.SelectTreePlusGroupNode.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-select-tree-plus-group-node bi-list-item-active",logic:{dynamic:!1},id:"",pId:"",readonly:!0,open:!1,height:24})},_init:function(){BI.SelectTreePlusGroupNode.superclass._init.apply(this,arguments);var e=this,t=this.options;this.checkbox=BI.createWidget({type:"bi.tree_node_checkbox",stopPropagation:!0}),this.text=BI.createWidget({type:"bi.label",textAlign:"left",whiteSpace:"nowrap",textHeight:t.height,height:t.height,hgap:t.hgap,text:t.text,value:t.value,keyword:t.keyword,py:t.py}),this.checkbox.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&(this.isSelected()?e.triggerExpand():e.triggerCollapse())}));var n=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),i=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(n,BI.extend(t.logic,{items:i}))))},isOnce:function(){return!0},doRedMark:function(){this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doClick:function(){BI.NodeButton.superclass.doClick.apply(this,arguments)},setOpened:function(e){BI.SelectTreePlusGroupNode.superclass.setOpened.apply(this,arguments),BI.isNotNull(this.checkbox)&&this.checkbox.setSelected(e)}}),BI.shortcut("bi.select_tree_plus_group_node",BI.SelectTreePlusGroupNode)},function(e,t){BI.SelectTreeCombo=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SelectTreeCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-select-tree-combo bi-border bi-border-radius",height:24,text:"",items:[],value:""})},_init:function(){var e=this,t=this.options;t.height-=2,BI.isNumeric(t.width)&&(t.width-=2),BI.SelectTreeCombo.superclass._init.apply(this,arguments),this.trigger=BI.createWidget({type:"bi.single_tree_trigger",text:t.text,height:t.height,items:t.items,value:t.value}),this.popup=BI.createWidget({type:"bi.select_level_tree",items:t.items,value:t.value}),this.combo=BI.createWidget({type:"bi.combo",container:t.container,element:this,adjustLength:2,el:this.trigger,popup:{el:this.popup}}),this.combo.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.popup.on(BI.SingleTreePopup.EVENT_CHANGE,(function(){e.setValue(e.popup.getValue()),e.combo.hideView()}))},setValue:function(e){e=BI.isArray(e)?e:[e],this.trigger.setValue(e),this.popup.setValue(e)},getValue:function(){return this.popup.getValue()},populate:function(e){this.combo.populate(e)}}),BI.shortcut("bi.select_tree_combo",BI.SelectTreeCombo)},function(e,t){BI.SelectTreeExpander=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SelectTreeExpander.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-select-tree-expander",trigger:"",toggle:!0,direction:"bottom",isDefaultInit:!0,el:{},popup:{}})},_init:function(){BI.SelectTreeExpander.superclass._init.apply(this,arguments);var e=this,t=this.options;this.trigger=BI.createWidget(t.el),this.trigger.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&this.isSelected()&&e.expander.setValue([]),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.expander=BI.createWidget({type:"bi.expander",element:this,trigger:t.trigger,toggle:t.toggle,direction:t.direction,isDefaultInit:t.isDefaultInit,el:this.trigger,popup:t.popup}),this.expander.on(BI.Controller.EVENT_CHANGE,(function(t){t===BI.Events.CLICK&&e.trigger.setSelected(!1),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}))},getAllLeaves:function(){return this.expander.getAllLeaves()},setValue:function(e){BI.contains(e,this.trigger.getValue())?(this.trigger.setSelected(!0),this.expander.setValue([])):(this.trigger.setSelected(!1),this.expander.setValue(e))},getValue:function(){return this.trigger.isSelected()?[this.trigger.getValue()]:this.expander.getValue()},populate:function(e){this.expander.populate(e)}}),BI.shortcut("bi.select_tree_expander",BI.SelectTreeExpander)},function(e,t){BI.SelectTreePopup=BI.inherit(BI.Pane,{_defaultConfig:function(){return BI.extend(BI.SelectTreePopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-select-level-tree",tipText:BI.i18nText("BI-No_Selected_Item"),items:[],value:""})},_formatItems:function(e,t,n){var i=this;return BI.each(e,(function(r,a){var o={layer:t};a.id=a.id||BI.UUID(),o.pNode=n,!0===a.isParent||!0===a.parent||BI.isNotEmptyArray(a.children)?(o.type="bi.select_tree_mid_plus_group_node",r===e.length-1&&(o.type="bi.select_tree_last_plus_group_node",o.isLastNode=!0),0!==r||n||(o.type="bi.select_tree_first_plus_group_node"),0===r&&r===e.length-1&&(o.type="bi.select_tree_plus_group_node"),BI.defaults(a,o),i._formatItems(a.children,t+1,a)):(o.type="bi.mid_tree_leaf_item",0!==r||n||(o.type="bi.first_tree_leaf_item"),r===e.length-1&&(o.type="bi.last_tree_leaf_item"),BI.defaults(a,o))})),e},_init:function(){BI.SelectTreePopup.superclass._init.apply(this,arguments);var e=this,t=this.options;this.tree=BI.createWidget({type:"bi.level_tree",expander:{type:"bi.select_tree_expander",isDefaultInit:!0},items:this._formatItems(BI.Tree.transformToTreeFormat(t.items),0),value:t.value,chooseType:BI.Selection.Single}),BI.createWidget({type:"bi.vertical",element:this,vgap:5,items:[this.tree]}),this.tree.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.tree.on(BI.LevelTree.EVENT_CHANGE,(function(){e.fireEvent(BI.SelectTreePopup.EVENT_CHANGE)})),this.check()},getValue:function(){return this.tree.getValue()},setValue:function(e){e=BI.isArray(e)?e:[e],this.tree.setValue(e)},populate:function(e){BI.SelectTreePopup.superclass.populate.apply(this,arguments),this.tree.populate(this._formatItems(BI.Tree.transformToTreeFormat(e)))}}),BI.SelectTreePopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.select_level_tree",BI.SelectTreePopup)},function(e,t){BI.SingleSelectSearchLoader=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SingleSelectSearchLoader.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-select-search-loader",allowNoSelect:!1,itemsCreator:BI.emptyFn,keywordGetter:BI.emptyFn,valueFormatter:BI.emptyFn})},_init:function(){BI.SingleSelectSearchLoader.superclass._init.apply(this,arguments);var e=this,t=this.options,n=!1;this.button_group=BI.createWidget({type:"bi.single_select_list",allowNoSelect:t.allowNoSelect,element:this,logic:{dynamic:!1},value:t.value,el:{tipText:BI.i18nText("BI-No_Select"),el:{type:"bi.loader",isDefaultInit:!1,logic:{dynamic:!0,scrolly:!0},el:{chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,behaviors:{redmark:function(){return!0}},layouts:[{type:"bi.vertical"}]}}},itemsCreator:function(i,r){e.storeValue&&(i=BI.extend(i||{},{selectedValues:[e.storeValue]})),t.itemsCreator(i,(function(a){var o=a.keyword=t.keywordGetter();n=a.hasNext;var s=[];if(1===i.times&&BI.isNotNull(e.storeValue)){var l=e._filterValues(e.storeValue);s=e._createItems(l)}r(s.concat(e._createItems(a.items)),o||""),1===i.times&&e.storeValue&&e.setValue(e.storeValue)}))},hasNext:function(){return n}}),this.button_group.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.button_group.on(BI.SingleSelectList.EVENT_CHANGE,(function(){e.fireEvent(BI.SingleSelectSearchLoader.EVENT_CHANGE,arguments)}))},_createItems:function(e){return BI.createItems(e,{type:this.options.allowNoSelect?"bi.single_select_item":"bi.single_select_radio_item",cls:"bi-list-item-active",logic:{dynamic:!1},height:25,selected:!1,iconWrapperWidth:26,hgap:this.options.allowNoSelect?10:0})},_filterValues:function(e){var t=this.options,n=t.keywordGetter(),i=e||[],r=BI.map(BI.isArray(i)?i:[i],(function(e,n){return{text:t.valueFormatter(n)||n,value:n}}));if(BI.isKey(n)){var a=BI.Func.getSearchResult(r,n);i=a.match.concat(a.find)}return BI.map(i,(function(e,t){return{text:t.text,title:t.text,value:t.value,selected:!1}}))},setValue:function(e){this.storeValue=e,this.button_group.setValue(e)},getValue:function(){return this.button_group.getValue()},getAllButtons:function(){return this.button_group.getAllButtons()},empty:function(){this.button_group.empty()},populate:function(e){this.button_group.populate.apply(this.button_group,arguments)},resetHeight:function(e){this.button_group.resetHeight(e)},resetWidth:function(e){this.button_group.resetWidth(e)}}),BI.SingleSelectSearchLoader.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.single_select_search_loader",BI.SingleSelectSearchLoader)},function(e,t){BI.SingleSelectSearchInsertPane=BI.inherit(BI.Widget,{constants:{height:25,lgap:10,tgap:5},_defaultConfig:function(){return BI.extend(BI.SingleSelectSearchInsertPane.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-select-search-pane bi-card",allowNoSelect:!1,itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,keywordGetter:BI.emptyFn})},_init:function(){BI.SingleSelectSearchInsertPane.superclass._init.apply(this,arguments);var e=this,t=this.options;this.addNotMatchTip=BI.createWidget({type:"bi.label",text:BI.i18nText("BI-Basic_Click_To_Add_Text",""),height:this.constants.height,cls:"bi-high-light",hgap:5}),this.loader=BI.createWidget({type:"bi.single_select_search_loader",allowNoSelect:t.allowNoSelect,keywordGetter:t.keywordGetter,valueFormatter:t.valueFormatter,itemsCreator:function(n,i){t.itemsCreator.apply(e,[n,function(n){i(n),e.setKeyword(t.keywordGetter())}])},value:t.value}),this.loader.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.resizer=BI.createWidget({type:"bi.vtape",element:this,items:[{type:"bi.vertical",items:[this.addNotMatchTip],height:this.constants.height},{el:this.loader}]})},setKeyword:function(e){this.addNotMatchTip.setText(BI.i18nText("BI-Basic_Click_To_Add_Text",e))},hasMatched:function(){return!1},setValue:function(e){this.loader.setValue(e)},getValue:function(){return this.loader.getValue()},empty:function(){this.loader.empty()},populate:function(e){this.loader.populate.apply(this.loader,arguments)}}),BI.SingleSelectSearchInsertPane.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.single_select_search_insert_pane",BI.SingleSelectSearchInsertPane)},function(e,t){BI.SingleSelectSearchPane=BI.inherit(BI.Widget,{constants:{height:25,lgap:10,tgap:5},_defaultConfig:function(){return BI.extend(BI.SingleSelectSearchPane.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-select-search-pane bi-card",allowNoSelect:!1,itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,keywordGetter:BI.emptyFn})},_init:function(){BI.SingleSelectSearchPane.superclass._init.apply(this,arguments);var e=this,t=this.options;this.tooltipClick=BI.createWidget({type:"bi.label",invisible:!0,text:BI.i18nText("BI-Click_Blank_To_Select"),cls:"single-select-toolbar",height:this.constants.height}),this.loader=BI.createWidget({type:"bi.single_select_search_loader",allowNoSelect:t.allowNoSelect,keywordGetter:t.keywordGetter,valueFormatter:t.valueFormatter,itemsCreator:function(n,i){t.itemsCreator.apply(e,[n,function(n){i(n),e.setKeyword(t.keywordGetter())}])},value:t.value}),this.loader.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.resizer=BI.createWidget({type:"bi.vtape",element:this,items:[{el:this.tooltipClick,height:0},{el:this.loader}]}),this.tooltipClick.setVisible(!1)},setKeyword:function(e){var t,n=this.options,i=this.loader.getAllButtons().length>0&&(t=this.loader.getAllButtons()[0])&&e===(n.valueFormatter(t.getValue())||t.getValue());i!==this.tooltipClick.isVisible()&&(this.tooltipClick.setVisible(i),this.resizer.attr("items")[0].height=i?this.constants.height:0,this.resizer.resize())},hasMatched:function(){return this.tooltipClick.isVisible()},setValue:function(e){this.loader.setValue(e)},getValue:function(){return this.loader.getValue()},empty:function(){this.loader.empty()},populate:function(e){this.loader.populate.apply(this.loader,arguments)}}),BI.SingleSelectSearchPane.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.single_select_search_pane",BI.SingleSelectSearchPane)},function(e,t){BI.SingleSelectCombo=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.SingleSelectCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-select-combo",allowNoSelect:!1,itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,height:24,allowEdit:!0})},_init:function(){var e=this,t=this.options;BI.SingleSelectCombo.superclass._init.apply(this,arguments);var n=function(){BI.isKey(e._startValue)&&(e.storeValue=e._startValue),e.trigger.getSearcher().setState(e.storeValue)};this.storeValue=t.value,this.requesting=!1,this.trigger=BI.createWidget({type:"bi.single_select_trigger",height:t.height-2,allowNoSelect:t.allowNoSelect,allowEdit:t.allowEdit,valueFormatter:t.valueFormatter,itemsCreator:function(n,i){t.itemsCreator(n,(function(t){1===n.times&&BI.isNotNull(n.keywords)&&e.trigger.setValue(e.getValue()),i.apply(e,arguments)}))},text:t.text,value:this.storeValue}),this.trigger.on(BI.SingleSelectTrigger.EVENT_FOCUS,(function(){e.fireEvent(BI.SingleSelectCombo.EVENT_FOCUS)})),this.trigger.on(BI.SingleSelectTrigger.EVENT_BLUR,(function(){e.fireEvent(BI.SingleSelectCombo.EVENT_BLUR)})),this.trigger.on(BI.SingleSelectTrigger.EVENT_START,(function(){e._setStartValue(),this.getSearcher().setValue(e.storeValue)})),this.trigger.on(BI.SingleSelectTrigger.EVENT_STOP,(function(){e._setStartValue(),e.fireEvent(BI.SingleSelectCombo.EVENT_STOP)})),this.trigger.on(BI.SingleSelectTrigger.EVENT_SEARCHING,(function(){e.fireEvent(BI.SingleSelectCombo.EVENT_SEARCHING)})),this.trigger.on(BI.SingleSelectTrigger.EVENT_CHANGE,(function(t,i){e.storeValue=this.getValue(),n(),e._defaultState()})),this.trigger.on(BI.SingleSelectTrigger.EVENT_COUNTER_CLICK,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-border-radius",container:t.container,toggle:!1,el:this.trigger,adjustLength:1,popup:{type:"bi.single_select_popup_view",allowNoSelect:t.allowNoSelect,ref:function(){e.popup=this,e.trigger.setAdapter(this)},listeners:[{eventName:BI.SingleSelectPopupView.EVENT_CHANGE,action:function(){e.storeValue=this.getValue(),e._adjust((function(){n(),e._defaultState()})),e.fireEvent(BI.SingleSelectCombo.EVENT_CLICK_ITEM)}}],itemsCreator:t.itemsCreator,valueFormatter:t.valueFormatter,onLoaded:function(){BI.nextTick((function(){e.combo.adjustWidth(),e.combo.adjustHeight(),e.trigger.getSearcher().adjustView()}))}},hideChecker:function(e){return 0===i.element.find(e.target).length},value:t.value}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){this.setValue(e.storeValue),BI.nextTick((function(){e.populate()}))})),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,(function(){e.trigger.stopEditing(),!0===e.requesting?e.wants2Quit=!0:e.fireEvent(BI.SingleSelectCombo.EVENT_CONFIRM)}));var i=BI.createWidget({type:"bi.trigger_icon_button",width:t.height,height:t.height,cls:"single-select-trigger-icon-button"});i.on(BI.TriggerIconButton.EVENT_CHANGE,(function(){e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:i,right:0,top:0,bottom:0}]})},_defaultState:function(){this.trigger.stopEditing(),this.combo.hideView()},_assertValue:function(e){},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(e,t){var n=this,i=this.options;this._assertValue(this.storeValue),this.requesting=!0,i.itemsCreator({type:BI.SingleSelectCombo.REQ_GET_ALL_DATA,keywords:e},(function(i){var r,a,o=BI.map(i.items,"value");r=o,a=n._makeMap(r),BI.each(e,(function(e,t){BI.isNotNull(a[t])&&BI.remove(n.storeValue.value,t)})),n._adjust(t)}))},_adjust:function(e){var t=this,n=this.options;function i(){!0===t.wants2Quit&&(t.fireEvent(BI.SingleSelectCombo.EVENT_CONFIRM),t.wants2Quit=!1),t.requesting=!1}this._count?(i(),e()):n.itemsCreator({type:BI.SingleSelectCombo.REQ_GET_DATA_LENGTH},(function(n){t._count=n.count,i(),e()}))},_setStartValue:function(e){this._startValue=e,this.popup.setStartValue(e)},setValue:function(e){this.storeValue=e,this._assertValue(this.storeValue),this.combo.setValue(this.storeValue)},getValue:function(){return this.storeValue},populate:function(){this._count=null,this.combo.populate.apply(this.combo,arguments)}}),BI.extend(BI.SingleSelectCombo,{REQ_GET_DATA_LENGTH:0,REQ_GET_ALL_DATA:-1}),BI.SingleSelectCombo.EVENT_BLUR="EVENT_BLUR",BI.SingleSelectCombo.EVENT_FOCUS="EVENT_FOCUS",BI.SingleSelectCombo.EVENT_STOP="EVENT_STOP",BI.SingleSelectCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.SingleSelectCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.SingleSelectCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.shortcut("bi.single_select_combo",BI.SingleSelectCombo)},function(e,t){BI.SingleSelectInsertCombo=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.SingleSelectInsertCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-select-combo",allowNoSelect:!1,itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,height:24,allowEdit:!0,watermark:BI.i18nText("BI-Basic_Search_And_Patch_Paste")})},_init:function(){var e=this,t=this.options;BI.SingleSelectInsertCombo.superclass._init.apply(this,arguments);var n=function(){BI.isKey(e._startValue)&&(e.storeValue=e._startValue),e.trigger.getSearcher().setState(e.storeValue)};this.storeValue=t.value,this.requesting=!1,this.trigger=BI.createWidget({type:"bi.single_select_trigger",watermark:t.watermark,height:t.height-2,allowNoSelect:t.allowNoSelect,allowEdit:t.allowEdit,valueFormatter:t.valueFormatter,itemsCreator:function(n,i){t.itemsCreator(n,(function(t){1===n.times&&BI.isNotNull(n.keywords)&&e.trigger.setValue(e.getValue()),i.apply(e,arguments)}))},text:t.text,value:this.storeValue,searcher:{popup:{type:"bi.single_select_search_insert_pane"}}}),this.trigger.on(BI.SingleSelectTrigger.EVENT_FOCUS,(function(){e.fireEvent(BI.SingleSelectInsertCombo.EVENT_FOCUS)})),this.trigger.on(BI.SingleSelectTrigger.EVENT_BLUR,(function(){e.fireEvent(BI.SingleSelectInsertCombo.EVENT_BLUR)})),this.trigger.on(BI.SingleSelectTrigger.EVENT_START,(function(){e._setStartValue(),this.getSearcher().setValue(e.storeValue)})),this.trigger.on(BI.SingleSelectTrigger.EVENT_STOP,(function(){e._setStartValue(),e.fireEvent(BI.SingleSelectInsertCombo.EVENT_STOP)})),this.trigger.on(BI.SingleSelectTrigger.EVENT_PAUSE,(function(){e.storeValue=e.trigger.getSearcher().getKeyword(),n(),e._defaultState()})),this.trigger.on(BI.SingleSelectTrigger.EVENT_SEARCHING,(function(){e.fireEvent(BI.SingleSelectInsertCombo.EVENT_SEARCHING)})),this.trigger.on(BI.SingleSelectTrigger.EVENT_CHANGE,(function(t,i){e.storeValue=this.getValue(),n(),e._defaultState()})),this.trigger.on(BI.SingleSelectTrigger.EVENT_COUNTER_CLICK,(function(){e.combo.isViewVisible()||e.combo.showView()})),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-border-radius",container:t.container,toggle:!1,el:this.trigger,adjustLength:1,popup:{type:"bi.single_select_popup_view",allowNoSelect:t.allowNoSelect,ref:function(){e.popup=this,e.trigger.setAdapter(this)},listeners:[{eventName:BI.SingleSelectPopupView.EVENT_CHANGE,action:function(){e.storeValue=this.getValue(),e._adjust((function(){n(),e._defaultState()})),e.fireEvent(BI.SingleSelectInsertCombo.EVENT_CLICK_ITEM)}}],itemsCreator:t.itemsCreator,valueFormatter:t.valueFormatter,onLoaded:function(){BI.nextTick((function(){e.combo.adjustWidth(),e.combo.adjustHeight(),e.trigger.getSearcher().adjustView()}))}},hideChecker:function(e){return 0===i.element.find(e.target).length},value:t.value}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){this.setValue(e.storeValue),BI.nextTick((function(){e.populate()}))})),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,(function(){e.trigger.stopEditing(),!0===e.requesting?e.wants2Quit=!0:e.fireEvent(BI.SingleSelectInsertCombo.EVENT_CONFIRM)}));var i=BI.createWidget({type:"bi.trigger_icon_button",width:t.height,height:t.height,cls:"single-select-trigger-icon-button"});i.on(BI.TriggerIconButton.EVENT_CHANGE,(function(){e.combo.isViewVisible()?e.combo.hideView():e.combo.showView()})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:i,right:0,top:0,bottom:0}]})},_defaultState:function(){this.trigger.stopEditing(),this.combo.hideView()},_assertValue:function(e){},_makeMap:function(e){return BI.makeObject(e||[])},_adjust:function(e){var t=this;this.options;!function(){!0===t.wants2Quit&&(t.fireEvent(BI.SingleSelectInsertCombo.EVENT_CONFIRM),t.wants2Quit=!1);t.requesting=!1}(),e()},_setStartValue:function(e){this._startValue=e,this.popup.setStartValue(e)},setValue:function(e){this.storeValue=e,this._assertValue(this.storeValue),this.combo.setValue(this.storeValue)},getValue:function(){return this.storeValue},populate:function(){this.combo.populate.apply(this.combo,arguments)}}),BI.extend(BI.SingleSelectInsertCombo,{REQ_GET_DATA_LENGTH:0,REQ_GET_ALL_DATA:-1}),BI.SingleSelectInsertCombo.EVENT_FOCUS="EVENT_FOCUS",BI.SingleSelectInsertCombo.EVENT_BLUR="EVENT_BLUR",BI.SingleSelectInsertCombo.EVENT_STOP="EVENT_STOP",BI.SingleSelectInsertCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.SingleSelectInsertCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.SingleSelectInsertCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.shortcut("bi.single_select_insert_combo",BI.SingleSelectInsertCombo)},function(e,t){BI.SingleSelectList=BI.inherit(BI.Widget,{_constants:{itemHeight:24},_defaultConfig:function(){return BI.extend(BI.SingleSelectList.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-select-list",direction:BI.Direction.Top,logic:{dynamic:!0},items:[],itemsCreator:BI.emptyFn,hasNext:BI.emptyFn,onLoaded:BI.emptyFn,el:{type:"bi.list_pane"},allowNoSelect:!1})},_init:function(){BI.SingleSelectList.superclass._init.apply(this,arguments);var e=this,t=this.options;this.list=BI.createWidget(t.el,{type:"bi.list_pane",items:t.items,itemsCreator:function(n,i){1===n.times&&e.toolbar&&e.toolbar.setVisible(!1),t.itemsCreator(n,(function(t){i.apply(e,arguments),1===n.times&&(e.toolbar&&e.toolbar.setVisible(t&&t.length>0),e.toolbar&&e.toolbar.setEnable(t&&t.length>0))}))},onLoaded:t.onLoaded,hasNext:t.hasNext,value:t.value}),this.list.on(BI.Controller.EVENT_CHANGE,(function(t,n,i){t===BI.Events.CLICK&&e.fireEvent(BI.SingleSelectList.EVENT_CHANGE,n,i),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(t.direction),BI.extend({scrolly:!0},t.logic,{items:t.allowNoSelect?BI.LogicFactory.createLogicItemsByDirection(t.direction,{type:"bi.single_select_item",cls:"bi-list-item-active",height:this._constants.itemHeight,forceNotSelected:!0,text:BI.i18nText("BI-Basic_No_Select"),ref:function(t){e.toolbar=t},listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(t){t===BI.Events.CLICK&&(e.list.setValue(),e.fireEvent(BI.SingleSelectList.EVENT_CHANGE)),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}}]},this.list):BI.LogicFactory.createLogicItemsByDirection(t.direction,this.list)}))))},hasPrev:function(){return this.list.hasPrev()},hasNext:function(){return this.list.hasNext()},prependItems:function(e){this.list.prependItems.apply(this.list,arguments)},addItems:function(e){this.list.addItems.apply(this.list,arguments)},setValue:function(e){this.list.setValue([e])},getValue:function(){return this.list.getValue()[0]},empty:function(){this.list.empty()},populate:function(e){this.list.populate.apply(this.list,arguments)},resetHeight:function(e){this.list.resetHeight?this.list.resetHeight(e):this.list.element.css({"max-height":(e-(this.options.allowNoSelect?this._constants.itemHeight:0))/BI.pixRatio+BI.pixUnit})},setNotSelectedValue:function(){this.list.setNotSelectedValue.apply(this.list,arguments)},getNotSelectedValue:function(){return this.list.getNotSelectedValue()},getAllButtons:function(){return this.list.getAllButtons()},getAllLeaves:function(){return this.list.getAllLeaves()},getSelectedButtons:function(){return this.list.getSelectedButtons()},getNotSelectedButtons:function(){return this.list.getNotSelectedButtons()},getIndexByValue:function(e){return this.list.getIndexByValue(e)},getNodeById:function(e){return this.list.getNodeById(e)},getNodeByValue:function(e){return this.list.getNodeByValue(e)}}),BI.SingleSelectList.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.single_select_list",BI.SingleSelectList)},function(e,t){BI.SingleSelectLoader=BI.inherit(BI.Widget,{_constants:{itemVgap:5},_defaultConfig:function(){return BI.extend(BI.SingleSelectLoader.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-select-loader",logic:{dynamic:!0},el:{height:400},allowNoSelect:!1,valueFormatter:BI.emptyFn,itemsCreator:BI.emptyFn,onLoaded:BI.emptyFn})},_init:function(){BI.SingleSelectLoader.superclass._init.apply(this,arguments);var e=this,t=this.options,n=!1;this.storeValue=t.value,this.button_group=BI.createWidget({type:"bi.single_select_list",allowNoSelect:t.allowNoSelect,logic:t.logic,el:BI.extend({onLoaded:t.onLoaded,el:{type:"bi.loader",isDefaultInit:!1,logic:{dynamic:!0,scrolly:!0},el:{chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,behaviors:{redmark:function(){return!0}},layouts:[{type:"bi.vertical"}]}}},t.el),itemsCreator:function(i,r){var a=e._startValue;BI.isNotNull(e.storeValue)&&(i=BI.extend(i||{},{selectedValues:[e.storeValue]})),t.itemsCreator(i,(function(o){n=o.hasNext;var s=[];if(1===i.times&&BI.isNotNull(e.storeValue)){var l=BI.map([e.storeValue],(function(e,n){var i=t.valueFormatter(n)||n;return{text:i,value:n,title:i,selected:!0}}));s=e._createItems(l)}r(s.concat(e._createItems(o.items)),o.keyword||""),1===i.times&&e.storeValue&&(BI.isKey(a)&&(e.storeValue=a),e.setValue(e.storeValue)),1===i.times&&e._scrollToTop()}))},hasNext:function(){return n},value:this.storeValue}),BI.createWidget({type:"bi.vertical",element:this,items:[this.button_group],vgap:this._constants.itemVgap}),this.button_group.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.button_group.on(BI.SingleSelectList.EVENT_CHANGE,(function(){e.fireEvent(BI.SingleSelectLoader.EVENT_CHANGE,arguments)}))},_createItems:function(e){return BI.createItems(e,{type:this.options.allowNoSelect?"bi.single_select_item":"bi.single_select_radio_item",logic:this.options.logic,cls:"bi-list-item-active",height:24,selected:!1,iconWrapperWidth:26,hgap:this.options.allowNoSelect?10:0})},_scrollToTop:function(){var e=this;BI.delay((function(){e.button_group.element.scrollTop(0)}),30)},_assertValue:function(e){},setStartValue:function(e){this._startValue=e},setValue:function(e){this.storeValue=e,this._assertValue(this.storeValue),this.button_group.setValue(this.storeValue)},getValue:function(){return this.button_group.getValue()},getAllButtons:function(){return this.button_group.getAllButtons()},empty:function(){this.button_group.empty()},populate:function(e){this.button_group.populate.apply(this.button_group,arguments)},resetHeight:function(e){this.button_group.resetHeight(e-2*this._constants.itemVgap)},resetWidth:function(e){this.button_group.resetWidth(e)}}),BI.SingleSelectLoader.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.single_select_loader",BI.SingleSelectLoader)},function(e,t){BI.SingleSelectPopupView=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SingleSelectPopupView.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-select-popup-view",allowNoSelect:!1,maxWidth:"auto",minWidth:135,maxHeight:400,valueFormatter:BI.emptyFn,itemsCreator:BI.emptyFn,onLoaded:BI.emptyFn})},_init:function(){BI.SingleSelectPopupView.superclass._init.apply(this,arguments);var e=this,t=this.options;this.loader=BI.createWidget({type:"bi.single_select_loader",allowNoSelect:t.allowNoSelect,itemsCreator:t.itemsCreator,valueFormatter:t.valueFormatter,onLoaded:t.onLoaded,value:t.value}),this.popupView=BI.createWidget({type:"bi.popup_view",stopPropagation:!1,maxWidth:t.maxWidth,minWidth:t.minWidth,maxHeight:t.maxHeight,element:this,el:this.loader,value:t.value}),this.popupView.on(BI.MultiPopupView.EVENT_CHANGE,(function(){e.fireEvent(BI.SingleSelectPopupView.EVENT_CHANGE)}))},setStartValue:function(e){this.loader.setStartValue(e)},setValue:function(e){this.popupView.setValue(e)},getValue:function(){return this.popupView.getValue()},populate:function(e){this.popupView.populate.apply(this.popupView,arguments)},resetHeight:function(e){this.popupView.resetHeight(e)},resetWidth:function(e){this.popupView.resetWidth(e)}}),BI.SingleSelectPopupView.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.single_select_popup_view",BI.SingleSelectPopupView)},function(e,t){BI.SingleSelectTrigger=BI.inherit(BI.Trigger,{constants:{height:14,rgap:4,lgap:4},_defaultConfig:function(){return BI.extend(BI.SingleSelectTrigger.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-select-trigger",allowNoSelect:!1,itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,searcher:{},switcher:{},adapter:null,masker:{},allowEdit:!0})},_init:function(){BI.SingleSelectTrigger.superclass._init.apply(this,arguments);var e=this,t=this.options;this.searcher=BI.createWidget(t.searcher,{type:"bi.single_select_searcher",watermark:t.watermark,allowNoSelect:t.allowNoSelect,text:t.text,height:t.height,itemsCreator:t.itemsCreator,valueFormatter:t.valueFormatter,popup:{},adapter:t.adapter,masker:t.masker,value:t.value}),this.searcher.on(BI.SingleSelectSearcher.EVENT_START,(function(){e.fireEvent(BI.SingleSelectTrigger.EVENT_START)})),this.searcher.on(BI.SingleSelectSearcher.EVENT_PAUSE,(function(){e.fireEvent(BI.SingleSelectTrigger.EVENT_PAUSE)})),this.searcher.on(BI.SingleSelectSearcher.EVENT_SEARCHING,(function(){e.fireEvent(BI.SingleSelectTrigger.EVENT_SEARCHING,arguments)})),this.searcher.on(BI.SingleSelectSearcher.EVENT_STOP,(function(){e.fireEvent(BI.SingleSelectTrigger.EVENT_STOP)})),this.searcher.on(BI.SingleSelectSearcher.EVENT_CHANGE,(function(){e.fireEvent(BI.SingleSelectTrigger.EVENT_CHANGE,arguments)})),this.searcher.on(BI.SingleSelectSearcher.EVENT_FOCUS,(function(){e.fireEvent(BI.SingleSelectTrigger.EVENT_FOCUS)})),this.searcher.on(BI.SingleSelectSearcher.EVENT_BLUR,(function(){e.fireEvent(BI.SingleSelectTrigger.EVENT_BLUR,arguments)}));BI.createWidget({type:"bi.htape",element:this,items:[{el:this.searcher,width:"fill"},{el:BI.createWidget(),width:24}]});!t.allowEdit&&BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.text",title:function(){return e.searcher.getState()}},left:0,right:24,top:0,bottom:0}]})},getSearcher:function(){return this.searcher},stopEditing:function(){this.searcher.stopSearch()},setAdapter:function(e){this.searcher.setAdapter(e)},setValue:function(e){this.searcher.setValue(e)},getKey:function(){return this.searcher.getKey()},getValue:function(){return this.searcher.getValue()}}),BI.SingleSelectTrigger.EVENT_TRIGGER_CLICK="EVENT_TRIGGER_CLICK",BI.SingleSelectTrigger.EVENT_COUNTER_CLICK="EVENT_COUNTER_CLICK",BI.SingleSelectTrigger.EVENT_CHANGE="EVENT_CHANGE",BI.SingleSelectTrigger.EVENT_START="EVENT_START",BI.SingleSelectTrigger.EVENT_STOP="EVENT_STOP",BI.SingleSelectTrigger.EVENT_PAUSE="EVENT_PAUSE",BI.SingleSelectTrigger.EVENT_SEARCHING="EVENT_SEARCHING",BI.SingleSelectTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW="EVENT_BEFORE_COUNTER_POPUPVIEW",BI.SingleSelectTrigger.EVENT_FOCUS="EVENT_FOCUS",BI.SingleSelectTrigger.EVENT_BLUR="EVENT_BLUR",BI.shortcut("bi.single_select_trigger",BI.SingleSelectTrigger)},function(e,t){BI.SingleSelectInsertList=BI.inherit(BI.Single,{_defaultConfig:function(){return BI.extend(BI.SingleSelectInsertList.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-multi-select-insert-list",allowNoSelect:!1,itemsCreator:BI.emptyFn,valueFormatter:BI.emptyFn,searcherHeight:24})},_init:function(){BI.SingleSelectInsertList.superclass._init.apply(this,arguments);var e=this,t=this.options;this.storeValue=t.value;var n=function(){BI.isKey(e._startValue)&&(e.storeValue=e._startValue)};this.adapter=BI.createWidget({type:"bi.single_select_loader",allowNoSelect:t.allowNoSelect,cls:"popup-single-select-list bi-border-left bi-border-right bi-border-bottom",itemsCreator:t.itemsCreator,valueFormatter:t.valueFormatter,logic:{dynamic:!0},el:{},value:t.value}),this.adapter.on(BI.SingleSelectLoader.EVENT_CHANGE,(function(){e.storeValue=this.getValue(),n(),e.fireEvent(BI.SingleSelectInsertList.EVENT_CHANGE)})),this.searcherPane=BI.createWidget({type:"bi.single_select_search_insert_pane",allowNoSelect:t.allowNoSelect,cls:"bi-border-left bi-border-right bi-border-bottom",valueFormatter:t.valueFormatter,keywordGetter:function(){return e.trigger.getKeyword()},itemsCreator:function(n,i){n.keywords=[e.trigger.getKeyword()],this.setKeyword(n.keywords[0]),t.itemsCreator(n,i)}}),this.searcherPane.setVisible(!1),this.trigger=BI.createWidget({type:"bi.searcher",el:{type:"bi.select_patch_editor",el:{type:"bi.search_editor",watermark:BI.i18nText("BI-Basic_Search_And_Patch_Paste")},ref:function(t){e.editor=t},height:t.searcherHeight},isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t()},adapter:this.adapter,popup:this.searcherPane,height:200,masker:!1,value:t.value,listeners:[{eventName:BI.Searcher.EVENT_START,action:function(){e._showSearcherPane(),e._setStartValue(),this.setValue(BI.deepClone(e.storeValue))}},{eventName:BI.Searcher.EVENT_STOP,action:function(){e._showAdapter(),e._setStartValue(),e.adapter.setValue(e.storeValue),e.adapter.populate()}},{eventName:BI.Searcher.EVENT_PAUSE,action:function(){var t=this.getKeyword();e.storeValue=t,e._showAdapter(),e.adapter.setValue(e.storeValue),e._setStartValue(t),n(),e.adapter.populate(),e._setStartValue(),e.fireEvent(BI.SingleSelectInsertList.EVENT_CHANGE)}},{eventName:BI.Searcher.EVENT_CHANGE,action:function(){e.storeValue=this.getValue(),e.fireEvent(BI.SingleSelectInsertList.EVENT_CHANGE)}}]}),BI.createWidget({type:"bi.vtape",element:this,items:[{el:this.trigger,height:24},{el:this.adapter,height:"fill"}]}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.searcherPane,top:24,bottom:0,left:0,right:0}]})},_showAdapter:function(){this.adapter.setVisible(!0),this.searcherPane.setVisible(!1)},_showSearcherPane:function(){this.searcherPane.setVisible(!0),this.adapter.setVisible(!1)},_defaultState:function(){this.trigger.stopEditing()},_assertValue:function(){},_makeMap:function(e){return BI.makeObject(e||[])},_setStartValue:function(e){this._startValue=e,this.adapter.setStartValue(e)},isAllSelected:function(){return this.adapter.isAllSelected()},resize:function(){},setValue:function(e){this.storeValue=e,this.adapter.setValue(this.storeValue),this.trigger.setValue(this.storeValue)},getValue:function(){return BI.deepClone(this.storeValue)},populate:function(){this._count=null,this._allData=null,this.adapter.populate.apply(this.adapter,arguments),this.trigger.populate.apply(this.trigger,arguments)}}),BI.extend(BI.SingleSelectInsertList,{REQ_GET_DATA_LENGTH:0,REQ_GET_ALL_DATA:-1}),BI.SingleSelectInsertList.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.single_select_insert_list",BI.SingleSelectInsertList)},function(e,t){BI.SingleSelectEditor=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SingleSelectEditor.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-select-editor",el:{},text:BI.i18nText("BI-Basic_Please_Select"),watermark:BI.i18nText("BI-Basic_Search")})},_init:function(){BI.SingleSelectEditor.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget(t.el,{type:"bi.select_patch_editor",element:this,height:t.height,watermark:t.watermark,allowBlank:!0,value:t.value,defaultText:t.text,text:t.text}),this.editor.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.editor.on(BI.StateEditor.EVENT_FOCUS,(function(){e.fireEvent(BI.SingleSelectEditor.EVENT_FOCUS)})),this.editor.on(BI.StateEditor.EVENT_BLUR,(function(){e.fireEvent(BI.SingleSelectEditor.EVENT_BLUR)}))},focus:function(){this.editor.focus()},blur:function(){this.editor.blur()},setState:function(e){this.editor.setState(e)},setValue:function(e){this.editor.setValue(e)},getValue:function(){return this.editor.getValue()},getKeywords:function(){var e=this.editor.getValue(),t=e.split(/\u200b\s\u200b/);return BI.isEmptyString(t[t.length-1])&&(t=t.slice(0,t.length-1)),/\u200b\s\u200b$/.test(e)?t.concat([BI.BlankSplitChar]):t},getKeyword:function(){var e=this.editor.getValue().split(/\u200b\s\u200b/);return BI.isEmptyString(e[e.length-1])&&(e=e.slice(0,e.length-1)),BI.isEmptyArray(e)?"":e[e.length-1]},populate:function(e){}}),BI.SingleSelectEditor.EVENT_FOCUS="EVENT_FOCUS",BI.SingleSelectEditor.EVENT_BLUR="EVENT_BLUR",BI.shortcut("bi.single_select_editor",BI.SingleSelectEditor)},function(e,t){BI.SingleSelectSearcher=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SingleSelectSearcher.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-select-searcher",itemsCreator:BI.emptyFn,el:{},popup:{},valueFormatter:BI.emptyFn,adapter:null,masker:{},allowNoSelect:!1})},_init:function(){BI.SingleSelectSearcher.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget(t.el,{type:"bi.single_select_editor",height:t.height,watermark:t.watermark,text:t.text,listeners:[{eventName:BI.SingleSelectEditor.EVENT_FOCUS,action:function(){e.fireEvent(BI.SingleSelectSearcher.EVENT_FOCUS)}},{eventName:BI.SingleSelectEditor.EVENT_BLUR,action:function(){e.fireEvent(BI.SingleSelectSearcher.EVENT_BLUR)}}]}),this.searcher=BI.createWidget({type:"bi.searcher",element:this,height:t.height,isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t()},el:this.editor,popup:BI.extend({type:"bi.single_select_search_pane",allowNoSelect:t.allowNoSelect,valueFormatter:t.valueFormatter,keywordGetter:function(){return e.editor.getValue()},itemsCreator:function(n,i){var r=e.editor.getValue();n.keywords=[r],this.setKeyword(r),t.itemsCreator(n,i)},value:t.value},t.popup),adapter:t.adapter,masker:t.masker}),this.searcher.on(BI.Searcher.EVENT_START,(function(){e.fireEvent(BI.SingleSelectSearcher.EVENT_START)})),this.searcher.on(BI.Searcher.EVENT_PAUSE,(function(){this.hasMatched(),e.fireEvent(BI.SingleSelectSearcher.EVENT_PAUSE)})),this.searcher.on(BI.Searcher.EVENT_STOP,(function(){e.fireEvent(BI.SingleSelectSearcher.EVENT_STOP)})),this.searcher.on(BI.Searcher.EVENT_CHANGE,(function(){e.fireEvent(BI.SingleSelectSearcher.EVENT_CHANGE,arguments)})),this.searcher.on(BI.Searcher.EVENT_SEARCHING,(function(){var t=this.getKeywords();e.fireEvent(BI.SingleSelectSearcher.EVENT_SEARCHING,t)})),BI.isNotNull(t.value)&&this.setState(t.value)},adjustView:function(){this.searcher.adjustView()},isSearching:function(){return this.searcher.isSearching()},stopSearch:function(){this.searcher.stopSearch()},getKeyword:function(){return this.editor.getKeyword()},hasMatched:function(){return this.searcher.hasMatched()},hasChecked:function(){return this.searcher.getView()&&this.searcher.getView().hasChecked()},setAdapter:function(e){this.searcher.setAdapter(e)},setState:function(e){var t=this.options;BI.isNull(e)?this.editor.setState(BI.Selection.None):this.editor.setState(t.valueFormatter(e+"")||e+"")},setValue:function(e){this.setState(e),this.searcher.setValue(e)},getKey:function(){return this.editor.getValue()},getValue:function(){return this.searcher.getValue()},populate:function(e){this.searcher.populate.apply(this.searcher,arguments)}}),BI.SingleSelectSearcher.EVENT_FOCUS="EVENT_FOCUS",BI.SingleSelectSearcher.EVENT_BLUR="EVENT_BLUR",BI.SingleSelectSearcher.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.SingleSelectSearcher.EVENT_CHANGE="EVENT_CHANGE",BI.SingleSelectSearcher.EVENT_START="EVENT_START",BI.SingleSelectSearcher.EVENT_STOP="EVENT_STOP",BI.SingleSelectSearcher.EVENT_PAUSE="EVENT_PAUSE",BI.SingleSelectSearcher.EVENT_SEARCHING="EVENT_SEARCHING",BI.shortcut("bi.single_select_searcher",BI.SingleSelectSearcher)},function(e,t){BI.SignTextEditor=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.SignTextEditor.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-sign-initial-editor",validationChecker:BI.emptyFn,text:"",height:24})},_init:function(){BI.SignTextEditor.superclass._init.apply(this,arguments);var e=this,t=this.options;this.editor=BI.createWidget({type:"bi.editor",height:t.height,hgap:4,vgap:2,value:t.value,validationChecker:t.validationChecker,allowBlank:!1}),this.text=BI.createWidget({type:"bi.text_button",cls:"sign-editor-text",title:function(){return e.getValue()},textAlign:t.textAlign,height:t.height,hgap:4,handler:function(){e._showInput(),e.editor.focus(),e.editor.selectAll()}}),this.text.on(BI.TextButton.EVENT_CHANGE,(function(){BI.nextTick((function(){e.fireEvent(BI.SignTextEditor.EVENT_CLICK_LABEL)}))})),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.text,left:0,right:0,top:0,bottom:0}]}),this.editor.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.editor.on(BI.Editor.EVENT_CONFIRM,(function(){e._showHint(),e._checkText(),e.fireEvent(BI.SignTextEditor.EVENT_CONFIRM,arguments)})),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,(function(){e._showHint(),e._checkText(),e.fireEvent(BI.SignTextEditor.EVENT_CHANGE_CONFIRM,arguments)})),this.editor.on(BI.Editor.EVENT_ERROR,(function(){e._checkText()})),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[this.editor]}),this._showHint(),e._checkText()},_checkText:function(){var e=this.options;BI.nextTick(BI.bind((function(){if(""===this.editor.getValue())this.text.setValue(e.watermark||""),this.text.element.addClass("bi-water-mark");else{var t=this.editor.getValue();t=BI.isEmpty(t)||t==e.text?e.text:t+e.text,this.text.setValue(t),this.text.element.removeClass("bi-water-mark")}}),this))},_showInput:function(){this.editor.visible(),this.text.invisible()},_showHint:function(){this.editor.invisible(),this.text.visible()},setTitle:function(e){this.text.setTitle(e)},setWarningTitle:function(e){this.text.setWarningTitle(e)},focus:function(){this._showInput(),this.editor.focus()},blur:function(){this.editor.blur(),this._showHint(),this._checkText()},doRedMark:function(){""===this.editor.getValue()&&BI.isKey(this.options.watermark)||this.text.doRedMark.apply(this.text,arguments)},unRedMark:function(){this.text.unRedMark.apply(this.text,arguments)},doHighLight:function(){""===this.editor.getValue()&&BI.isKey(this.options.watermark)||this.text.doHighLight.apply(this.text,arguments)},unHighLight:function(){this.text.unHighLight.apply(this.text,arguments)},isValid:function(){return this.editor.isValid()},setErrorText:function(e){this.editor.setErrorText(e)},getErrorText:function(){return this.editor.getErrorText()},isEditing:function(){return this.editor.isEditing()},getLastValidValue:function(){return this.editor.getLastValidValue()},getLastChangedValue:function(){return this.editor.getLastChangedValue()},setValue:function(e){this.editor.setValue(e),this._checkText()},getValue:function(){return this.editor.getValue()},getState:function(){return this.text.getValue()},setState:function(e){var t=this.options;this._showHint(),e=BI.isEmpty(e)||e==t.text?t.text:e+t.text,this.text.setValue(e)}}),BI.SignTextEditor.EVENT_CONFIRM="EVENT_CONFIRM",BI.SignTextEditor.EVENT_CHANGE_CONFIRM="EVENT_CHANGE_CONFIRM",BI.SignTextEditor.EVENT_CLICK_LABEL="EVENT_CLICK_LABEL",BI.shortcut("bi.sign_text_editor",BI.SignTextEditor)},function(e,t){BI.SliderIconButton=BI.inherit(BI.Widget,{props:{baseCls:"bi-single-slider-button"},constants:{LARGE_SIZE:16,NORMAL_SIZE:12,LARGE_OFFSET:4,NORMAL_OFFSET:6},render:function(){var e=this;return{type:"bi.absolute",ref:function(){e.wrapper=this},items:[{el:{type:"bi.text_button",cls:"slider-button bi-high-light-border",ref:function(){e.slider=this}}}]}}}),BI.shortcut("bi.single_slider_button",BI.SliderIconButton)},function(e,t){BI.SingleSlider=BI.inherit(BI.Single,{_constant:{EDITOR_WIDTH:90,EDITOR_HEIGHT:30,SLIDER_WIDTH_HALF:15,SLIDER_WIDTH:30,SLIDER_HEIGHT:30,TRACK_HEIGHT:24,TRACK_GAP_HALF:7,TRACK_GAP:14},props:{baseCls:"bi-single-slider bi-slider-track",digit:!1,unit:""},render:function(){var e=this,t=this.options,n=this._constant;this.enable=!1,this.value="",this.grayTrack=BI.createWidget({type:"bi.layout",cls:"gray-track",height:6}),this.blueTrack=BI.createWidget({type:"bi.layout",cls:"blue-track bi-high-light-background",height:6}),this.track=this._createTrackWrapper(),this.slider=BI.createWidget({type:"bi.single_slider_button"}),this._draggable(this.slider);var i=BI.createWidget({type:"bi.vertical",items:[{type:"bi.absolute",items:[this.slider]}],hgap:n.SLIDER_WIDTH_HALF,height:n.SLIDER_HEIGHT});return i.element.click((function(r){if(e.enable&&e.isEnabled()&&i.element[0]===r.originalEvent.target){var a=r.clientX-e.element.offset().left-n.SLIDER_WIDTH_HALF,o=e.track.element[0].scrollWidth-n.TRACK_GAP,s=0;a<0&&(s=0),a>0&&a<o&&(s=100*a/e._getGrayTrackLength()),a>=o&&(s=100);var l=BI.parseFloat(s.toFixed(1));e._setAllPosition(l);var u=e._getValueByPercent(l);u=!1===t.digit?u:u.toFixed(t.digit),e.label.setValue(u),e.value=u,e.fireEvent(BI.SingleSlider.EVENT_CHANGE)}})),this.label=BI.createWidget({type:"bi.sign_text_editor",cls:"slider-editor-button",text:t.unit,width:n.EDITOR_WIDTH-2,allowBlank:!1,textAlign:"center",validationChecker:function(t){return e._checkValidation(t)}}),this.label.element.hover((function(){e.label.element.removeClass("bi-border").addClass("bi-border")}),(function(){e.label.element.removeClass("bi-border")})),this.label.on(BI.SignEditor.EVENT_CONFIRM,(function(){var t=BI.parseFloat(this.getValue()),n=e._getPercentByValue(t),i=BI.parseFloat(n.toFixed(1));e._setAllPosition(i),this.setValue(t),e.value=t,e.fireEvent(BI.SingleSlider.EVENT_CHANGE)})),this._setVisible(!1),{type:"bi.absolute",items:[{el:{type:"bi.vertical",items:[{type:"bi.absolute",items:[{el:this.track,width:"100%",height:n.TRACK_HEIGHT}]}],hgap:n.TRACK_GAP_HALF,height:n.TRACK_HEIGHT},top:23,left:0,width:"100%"},{el:i,top:20,left:0,width:"100%"},{el:{type:"bi.vertical",items:[{type:"bi.horizontal_auto",items:[this.label]}],height:n.EDITOR_HEIGHT},top:0,left:0,width:"100%"}]}},_draggable:function(e){var t=this,n=this.options,i=!1,r=0,a=0,o=0,s=new BI.MouseMoveTracker((function(u){if(s.isDragging()){i=!0,r=l(o+(a+=u)),e.element.addClass("dragging");var c=100*r/t._getGrayTrackLength(),h=BI.parseFloat(c.toFixed(1));t._setBlueTrack(h),t._setLabelPosition(h),t._setSliderPosition(h);var p=t._getValueByPercent(h);p=!1===n.digit?p:p.toFixed(n.digit),t.label.setValue(p),t.value=p}}),(function(){if(!0===i){var n=100*(r=l(r))/t._getGrayTrackLength(),u=BI.parseFloat(n.toFixed(1));t._setSliderPosition(u),a=0,o=r=0,i=!1}e.element.removeClass("dragging"),s.releaseMouseMoves(),t.fireEvent(BI.SingleSlider.EVENT_CHANGE)}),window);function l(e){return BI.clamp(e,0,t._getGrayTrackLength())}e.element.on("mousedown",(function(t){e.isEnabled()&&(l(o=this.offsetLeft),s.captureMouseMoves(t))}))},_createTrackWrapper:function(){return BI.createWidget({type:"bi.absolute",items:[{el:{type:"bi.vertical",items:[{type:"bi.absolute",items:[{el:this.grayTrack,top:0,left:0,width:"100%"},{el:this.blueTrack,top:0,left:0,width:"0%"}]}],hgap:8,height:8},top:8,left:0,width:"100%"}]})},_checkValidation:function(e){var t=this.options,n=!1;BI.isNumeric(e)&&!(BI.isNull(e)||e<this.min||e>this.max)&&(n=!1===t.digit||((e+"").split(".")[1]||"").length===t.digit);return n},_setBlueTrack:function(e){this.blueTrack.element.css({width:e+"%"})},_setLabelPosition:function(e){},_setSliderPosition:function(e){this.slider.element.css({left:e+"%"})},_setAllPosition:function(e){this._setSliderPosition(e),this._setLabelPosition(e),this._setBlueTrack(e)},_setVisible:function(e){this.slider.setVisible(e),this.label.setVisible(e)},_getGrayTrackLength:function(){return this.grayTrack.element[0].scrollWidth},_getValueByPercent:function(e){var t=BI.parseInt(10*e);return(this.max-this.min)*t/1e3+this.min},_getPercentByValue:function(e){return 100*(e-this.min)/(this.max-this.min)},getValue:function(){return this.value},setValue:function(e){var t=this.options;e=BI.parseFloat(e),e=!1===t.digit?e:e.toFixed(t.digit),isNaN(e)||(this._checkValidation(e)&&(this.value=e),e>this.max&&(this.value=this.max),e<this.min&&(this.value=this.min))},_setEnable:function(e){BI.SingleSlider.superclass._setEnable.apply(this,[e]),e?this.blueTrack.element.removeClass("disabled-blue-track").addClass("blue-track"):this.blueTrack.element.removeClass("blue-track").addClass("disabled-blue-track")},setMinAndMax:function(e){var t=BI.parseFloat(e.min),n=BI.parseFloat(e.max);!isNaN(t)&&!isNaN(n)&&n>t&&(this.min=t,this.max=n)},reset:function(){this._setVisible(!1),this.enable=!1,this.value="",this.min=0,this.max=0,this._setBlueTrack(0)},populate:function(){var e=this.options;isNaN(this.min)||isNaN(this.max)||(this._setVisible(!0),this.enable=!0,e.digit?this.label.setErrorText(BI.i18nText("BI-Basic_Please_Enter_Number_Between",this.min,this.max)):this.label.setErrorText(BI.i18nText("BI-Basic_Please_Enter_Integer_Number_Between",this.min,this.max)),BI.isNumeric(this.value)||BI.isNotEmptyString(this.value)?(this.label.setValue(this.value),this._setAllPosition(this._getPercentByValue(this.value))):(this.label.setValue(this.max),this._setAllPosition(100)))}}),BI.SingleSlider.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.single_slider",BI.SingleSlider)},function(e,t){BI.SingleSliderLabel=BI.inherit(BI.Single,{_constant:{EDITOR_WIDTH:90,EDITOR_HEIGHT:20,HEIGHT:20,SLIDER_WIDTH_HALF:15,SLIDER_WIDTH:30,SLIDER_HEIGHT:30,TRACK_HEIGHT:24,TRACK_GAP_HALF:7,TRACK_GAP:14},_defaultConfig:function(){return BI.extend(BI.SingleSliderLabel.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-slider-label bi-slider-track",digit:!1,unit:""})},_init:function(){BI.SingleSliderLabel.superclass._init.apply(this,arguments);var e=this,t=this.options,n=this._constant;this.enable=!1,this.value="",this.grayTrack=BI.createWidget({type:"bi.layout",cls:"gray-track",height:6}),this.blueTrack=BI.createWidget({type:"bi.layout",cls:"blue-track bi-high-light-background",height:6}),this.track=this._createTrackWrapper(),this.slider=BI.createWidget({type:"bi.single_slider_button"}),this._draggable(this.slider);var i=BI.createWidget({type:"bi.vertical",items:[{type:"bi.absolute",items:[this.slider]}],hgap:n.SLIDER_WIDTH_HALF,height:n.SLIDER_HEIGHT});i.element.click((function(r){if(e.enable&&e.isEnabled()&&i.element[0]===r.originalEvent.target){var a=r.clientX-e.element.offset().left-n.SLIDER_WIDTH_HALF,o=e.track.element[0].scrollWidth-n.TRACK_GAP,s=0;a<0&&(s=0),a>0&&a<o&&(s=100*a/e._getGrayTrackLength()),a>=o&&(s=100);var l=BI.parseFloat(s.toFixed(1));e._setAllPosition(l);var u=e._getValueByPercent(l);u=!1===t.digit?u:u.toFixed(t.digit),e.label.setText(u+t.unit),e.value=u,e.fireEvent(BI.SingleSliderLabel.EVENT_CHANGE)}})),this.label=BI.createWidget({type:"bi.label",height:n.HEIGHT,width:n.EDITOR_WIDTH-2}),this._setVisible(!1),BI.createWidget({type:"bi.absolute",element:this,items:[{el:{type:"bi.vertical",items:[{type:"bi.absolute",items:[{el:this.track,width:"100%",height:n.TRACK_HEIGHT}]}],hgap:n.TRACK_GAP_HALF,height:n.TRACK_HEIGHT},top:13,left:0,width:"100%"},{el:i,top:10,left:0,width:"100%"},{el:{type:"bi.vertical",items:[{type:"bi.horizontal_auto",items:[this.label]}],height:n.EDITOR_HEIGHT},top:0,left:0,width:"100%"}]})},_draggable:function(e){var t=this,n=this.options,i=!1,r=0,a=0,o=0,s=new BI.MouseMoveTracker((function(u){if(s.isDragging()){i=!0,r=l(o+(a+=u)),e.element.addClass("dragging");var c=100*r/t._getGrayTrackLength(),h=BI.parseFloat(c.toFixed(1));t._setBlueTrack(h),t._setLabelPosition(h),t._setSliderPosition(h);var p=t._getValueByPercent(h);p=!1===n.digit?p:p.toFixed(n.digit),t.label.setValue(p+n.unit),t.value=p,t.fireEvent(BI.SingleSliderLabel.EVENT_CHANGE)}}),(function(){if(!0===i){var n=100*(r=l(r))/t._getGrayTrackLength(),u=BI.parseFloat(n.toFixed(1));t._setSliderPosition(u),a=0,o=r=0,i=!1}e.element.removeClass("dragging"),s.releaseMouseMoves(),t.fireEvent(BI.SingleSliderLabel.EVENT_CHANGE)}),window);function l(e){return BI.clamp(e,0,t._getGrayTrackLength())}e.element.on("mousedown",(function(t){e.isEnabled()&&(l(o=this.offsetLeft),s.captureMouseMoves(t))}))},_createTrackWrapper:function(){return BI.createWidget({type:"bi.absolute",items:[{el:{type:"bi.vertical",items:[{type:"bi.absolute",items:[{el:this.grayTrack,top:0,left:0,width:"100%"},{el:this.blueTrack,top:0,left:0,width:"0%"}]}],hgap:8,height:8},top:8,left:0,width:"100%"}]})},_checkValidation:function(e){return BI.isNumeric(e)&&!(BI.isNull(e)||e<this.min||e>this.max)},_setBlueTrack:function(e){this.blueTrack.element.css({width:e+"%"})},_setLabelPosition:function(e){},_setSliderPosition:function(e){this.slider.element.css({left:e+"%"})},_setAllPosition:function(e){this._setSliderPosition(e),this._setLabelPosition(e),this._setBlueTrack(e)},_setVisible:function(e){this.slider.setVisible(e),this.label.setVisible(e)},_getGrayTrackLength:function(){return this.grayTrack.element[0].scrollWidth},_getValueByPercent:function(e){var t=BI.parseInt(10*e);return(this.max-this.min)*t/1e3+this.min},_getPercentByValue:function(e){return 100*(e-this.min)/(this.max-this.min)},_setEnable:function(e){BI.SingleSliderLabel.superclass._setEnable.apply(this,[e]),e?this.blueTrack.element.removeClass("disabled-blue-track").addClass("blue-track"):this.blueTrack.element.removeClass("blue-track").addClass("disabled-blue-track")},getValue:function(){return this.value},setValue:function(e){var t=this.options;e=BI.parseFloat(e),e=!1===t.digit?e:e.toFixed(t.digit),isNaN(e)||(this._checkValidation(e)&&(this.value=e),e>this.max&&(this.value=this.max),e<this.min&&(this.value=this.min))},setMinAndMax:function(e){var t=BI.parseFloat(e.min),n=BI.parseFloat(e.max);!isNaN(t)&&!isNaN(n)&&n>t&&(this.min=t,this.max=n)},reset:function(){this._setVisible(!1),this.enable=!1,this.value="",this.min=0,this.max=0,this._setBlueTrack(0)},populate:function(){var e=this.options;isNaN(this.min)||isNaN(this.max)||(this._setVisible(!0),this.enable=!0,BI.isNumeric(this.value)||BI.isNotEmptyString(this.value)?(this.label.setValue(this.value+e.unit),this._setAllPosition(this._getPercentByValue(this.value))):(this.label.setValue(this.max+e.unit),this._setAllPosition(100)))}}),BI.SingleSliderLabel.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.single_slider_label",BI.SingleSliderLabel)},function(e,t){BI.SingleSliderNormal=BI.inherit(BI.Single,{_constant:{HEIGHT:28,SLIDER_WIDTH_HALF:15,SLIDER_WIDTH:30,SLIDER_HEIGHT:30,TRACK_HEIGHT:24,TRACK_GAP_HALF:7,TRACK_GAP:14},props:{baseCls:"bi-single-slider-normal bi-slider-track",minMax:{min:0,max:100}},render:function(){var e=this,t=this._constant,n=this._createTrack();this.slider=BI.createWidget({type:"bi.single_slider_button"}),this._draggable(this.slider);var i=BI.createWidget({type:"bi.vertical",items:[{type:"bi.absolute",items:[this.slider]}],hgap:t.SLIDER_WIDTH_HALF,height:t.SLIDER_HEIGHT});return i.element.click((function(n){if(e.enable&&e.isEnabled()&&i.element[0]===n.originalEvent.target){var r=n.clientX-e.element.offset().left-t.SLIDER_WIDTH_HALF,a=e.track.element[0].scrollWidth-t.TRACK_GAP,o=0;r<0&&(o=0),r>0&&r<a&&(o=100*r/e._getGrayTrackLength()),r>=a&&(o=100);var s=BI.parseFloat(o.toFixed(1));e._setAllPosition(s);var l=e._getValueByPercent(s);e.value=l,e.fireEvent(BI.SingleSlider.EVENT_CHANGE)}})),{type:"bi.absolute",element:this,items:[{el:{type:"bi.vertical",items:[{type:"bi.absolute",items:[{el:n,width:"100%",height:t.TRACK_HEIGHT}]}],hgap:t.TRACK_GAP_HALF,height:t.TRACK_HEIGHT},top:3,left:0,width:"100%"},{el:i,top:0,left:0,width:"100%"}]}},_draggable:function(e){var t=this,n=this.options,i=!1,r=0,a=0,o=0,s=new BI.MouseMoveTracker((function(u){if(s.isDragging()){i=!0,r=l(o+(a+=u)),e.element.addClass("dragging");var c=100*r/t._getGrayTrackLength(),h=BI.parseFloat(c.toFixed(1));t._setBlueTrack(h),t._setSliderPosition(h);var p=t._getValueByPercent(h);p=!1===n.digit?p:p.toFixed(n.digit),t.value=p,t.fireEvent(BI.SingleSliderNormal.EVENT_DRAG,p)}}),(function(){if(!0===i){var n=100*(r=l(r))/t._getGrayTrackLength(),u=BI.parseFloat(n.toFixed(1));t._setSliderPosition(u),a=0,o=r=0,i=!1}e.element.removeClass("dragging"),s.releaseMouseMoves(),t.fireEvent(BI.SingleSlider.EVENT_CHANGE)}),window);function l(e){return BI.clamp(e,0,t._getGrayTrackLength())}e.element.on("mousedown",(function(t){e.isEnabled()&&(l(o=this.offsetLeft),s.captureMouseMoves(t))}))},_createTrack:function(){var e=this;this._constant;return this.grayTrack=BI.createWidget({type:"bi.layout",cls:"gray-track",height:6}),this.blueTrack=BI.createWidget({type:"bi.layout",cls:"blue-track bi-high-light-background",height:6}),this.options.color&&this.blueTrack.element.css({"background-color":this.options.color}),{type:"bi.absolute",items:[{el:{type:"bi.vertical",items:[{type:"bi.absolute",items:[{el:this.grayTrack,top:0,left:0,width:"100%"},{el:this.blueTrack,top:0,left:0,width:"0%"}]}],hgap:8,height:8},top:8,left:0,width:"100%"}],ref:function(t){e.track=t}}},_checkValidation:function(e){return!(BI.isNull(e)||e<this.min||e>this.max)},_setBlueTrack:function(e){this.blueTrack.element.css({width:e+"%"})},_setSliderPosition:function(e){this.slider.element.css({left:e+"%"})},_setAllPosition:function(e){this._setSliderPosition(e),this._setBlueTrack(e)},_setVisible:function(e){this.slider.setVisible(e)},_getGrayTrackLength:function(){return this.grayTrack.element[0].scrollWidth},_getValueByPercent:function(e){var t=BI.parseInt(10*e);return(this.max-this.min)*t/1e3+this.min},_getPercentByValue:function(e){return 100*(e-this.min)/(this.max-this.min)},_setEnable:function(e){BI.SingleSliderNormal.superclass._setEnable.apply(this,[e]),e?this.blueTrack.element.removeClass("disabled-blue-track").addClass("blue-track"):this.blueTrack.element.removeClass("blue-track").addClass("disabled-blue-track")},getValue:function(){return this.value},setValue:function(e){var t=BI.parseFloat(e);isNaN(t)||(this._checkValidation(t)&&(this.value=t),t>this.max&&(this.value=this.max),t<this.min&&(this.value=this.min))},setMinAndMax:function(e){var t=BI.parseFloat(e.min),n=BI.parseFloat(e.max);!isNaN(t)&&!isNaN(n)&&n>t&&(this.min=t,this.max=n)},reset:function(){this._setVisible(!1),this.enable=!1,this.value="",this.min=0,this.max=0,this._setBlueTrack(0)},populate:function(){isNaN(this.min)||isNaN(this.max)||(this._setVisible(!0),this.enable=!0,BI.isNumeric(this.value)||BI.isNotEmptyString(this.value)?this._setAllPosition(this._getPercentByValue(this.value)):this._setAllPosition(100))}}),BI.SingleSliderNormal.EVENT_DRAG="EVENT_DRAG",BI.shortcut("bi.single_slider_normal",BI.SingleSliderNormal)},function(e,t){BI.SingleTreeCombo=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SingleTreeCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-tree-combo bi-border bi-border-radius",trigger:{},height:24,text:"",items:[],value:""})},_init:function(){var e=this,t=this.options;t.height-=2,BI.isNumeric(t.width)&&(t.width-=2),BI.SingleTreeCombo.superclass._init.apply(this,arguments),this.trigger=BI.createWidget(BI.extend({type:"bi.single_tree_trigger",text:t.text,height:t.height,items:t.items,value:t.value},t.trigger)),this.popup=BI.createWidget({type:"bi.single_level_tree",items:t.items,value:t.value}),this.combo=BI.createWidget({type:"bi.combo",container:t.container,element:this,adjustLength:2,el:this.trigger,popup:{el:this.popup}}),this.combo.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){e.fireEvent(BI.SingleTreeCombo.EVENT_BEFORE_POPUPVIEW,arguments)})),this.popup.on(BI.SingleTreePopup.EVENT_CHANGE,(function(){e.setValue(e.popup.getValue()),e.combo.hideView(),e.fireEvent(BI.SingleTreeCombo.EVENT_CHANGE)}))},populate:function(e){this.combo.populate(e)},setValue:function(e){e=BI.isArray(e)?e:[e],this.trigger.setValue(e),this.popup.setValue(e)},getValue:function(){return this.popup.getValue()}}),BI.SingleTreeCombo.EVENT_CHANGE="EVENT_CHANGE",BI.SingleTreeCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.single_tree_combo",BI.SingleTreeCombo)},function(e,t){BI.SingleTreePopup=BI.inherit(BI.Pane,{_defaultConfig:function(){return BI.extend(BI.SingleTreePopup.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-level-tree",tipText:BI.i18nText("BI-No_Selected_Item"),items:[],value:""})},_init:function(){BI.SingleTreePopup.superclass._init.apply(this,arguments);var e=this,t=this.options;this.tree=BI.createWidget({type:"bi.level_tree",expander:{isDefaultInit:!0},items:t.items,value:t.value,chooseType:BI.Selection.Single}),BI.createWidget({type:"bi.vertical",element:this,vgap:5,items:[this.tree]}),this.tree.on(BI.Controller.EVENT_CHANGE,(function(){e.fireEvent(BI.Controller.EVENT_CHANGE,arguments)})),this.tree.on(BI.LevelTree.EVENT_CHANGE,(function(){e.fireEvent(BI.SingleTreePopup.EVENT_CHANGE)})),this.check()},getValue:function(){return this.tree.getValue()},setValue:function(e){e=BI.isArray(e)?e:[e],this.tree.setValue(e)},populate:function(e){BI.SingleTreePopup.superclass.populate.apply(this,arguments),this.tree.populate(e)}}),BI.SingleTreePopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.single_level_tree",BI.SingleTreePopup)},function(e,t){BI.SingleTreeTrigger=BI.inherit(BI.Trigger,{_defaultConfig:function(){return BI.extend(BI.SingleTreeTrigger.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-single-tree-trigger",height:24,text:"",items:[],value:""})},_init:function(){BI.SingleTreeTrigger.superclass._init.apply(this,arguments);var e=this.options;this.trigger=BI.createWidget({type:"bi.select_text_trigger",element:this,text:e.text,items:e.items,height:e.height,value:e.value})},_checkTitle:function(){var e=this,t=this.getValue();BI.any(this.options.items,(function(n,i){if(BI.contains(t,i.value))return e.trigger.setTitle(i.text||i.value),!0}))},setValue:function(e){e=BI.isArray(e)?e:[e],this.options.value=e,this.trigger.setValue(e),this._checkTitle()},getValue:function(){return this.options.value||[]},getTextor:function(){return this.trigger.getTextor()},populate:function(e){this.trigger.populate(e)}}),BI.shortcut("bi.single_tree_trigger",BI.SingleTreeTrigger)},function(e,t){BI.TextValueDownListCombo=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.TextValueDownListCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-text-value-down-list-combo bi-border",height:24})},_init:function(){var e,t=this,n=this.options;n.height-=2,BI.isNumeric(n.width)&&(n.width-=2),BI.TextValueDownListCombo.superclass._init.apply(this,arguments),this._createValueMap(),BI.isNotNull(n.value)&&(e=this._digest(n.value)),this.trigger=BI.createWidget({type:"bi.down_list_select_text_trigger",cls:"text-value-down-list-trigger",height:n.height,items:n.items,text:n.text,value:e}),this.combo=BI.createWidget({type:"bi.down_list_combo",element:this,chooseType:BI.Selection.Single,adjustLength:2,height:n.height,el:this.trigger,value:BI.isNull(e)?[]:[e],items:BI.deepClone(n.items)}),this.combo.on(BI.DownListCombo.EVENT_CHANGE,(function(){var e=t.combo.getValue()[0].value;e!==t.value&&(t.setValue(e),t.fireEvent(BI.TextValueDownListCombo.EVENT_CHANGE))})),this.combo.on(BI.DownListCombo.EVENT_SON_VALUE_CHANGE,(function(){var e=t.combo.getValue()[0].childValue;e!==t.value&&(t.setValue(e),t.fireEvent(BI.TextValueDownListCombo.EVENT_CHANGE))}))},_createValueMap:function(){var e=this;this.valueMap={},BI.each(BI.flatten(this.options.items),(function(t,n){BI.has(n,"el")?BI.each(n.children,(function(t,i){e.valueMap[i.value]={value:n.el.value,childValue:i.value}})):e.valueMap[n.value]={value:n.value}}))},_digest:function(e){return this.value=e,this.valueMap[e]},setValue:function(e){e=this._digest(e),this.combo.setValue([e]),this.trigger.setValue(e)},getValue:function(){var e=this.combo.getValue()[0];return[e.childValue||e.value]},populate:function(e){this.options.items=BI.flatten(e),this.combo.populate(e),this._createValueMap()}}),BI.TextValueDownListCombo.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.text_value_down_list_combo",BI.TextValueDownListCombo)},function(e,t){BI.DownListSelectTextTrigger=BI.inherit(BI.Trigger,{_defaultConfig:function(){return BI.extend(BI.DownListSelectTextTrigger.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-down-list-select-text-trigger",height:24,text:""})},_init:function(){BI.DownListSelectTextTrigger.superclass._init.apply(this,arguments);var e=this.options;this.trigger=BI.createWidget({type:"bi.select_text_trigger",element:this,height:e.height,items:this._formatItemArray(e.items),text:e.text,value:BI.isNull(e.value)?"":e.value.childValue||e.value.value})},_formatItemArray:function(){var e=BI.flatten(BI.deepClone(this.options.items)),t=[];return BI.each(e,(function(e,n){BI.has(n,"el")?(BI.each(n.children,(function(e,t){t.text=n.el.text+"("+t.text+")"})),t=BI.concat(t,n.children)):t.push(n)})),t},setValue:function(e){this.trigger.setValue(e.childValue||e.value)},populate:function(e){this.trigger.populate(this._formatItemArray(e))}}),BI.shortcut("bi.down_list_select_text_trigger",BI.DownListSelectTextTrigger)},function(e,t){BI.TimePopup=BI.inherit(BI.Widget,{props:{baseCls:"bi-date-time-popup",height:68},render:function(){var e=this;return{type:"bi.vtape",items:[{el:{type:"bi.center_adapt",cls:"bi-split-top",items:[{type:"bi.dynamic_date_time_select",value:this.options.value,ref:function(t){e.timeSelect=t}}]},hgap:10,height:44},{el:{type:"bi.grid",items:[[{type:"bi.text_button",cls:"bi-high-light bi-split-top",shadow:!0,text:BI.i18nText("BI-Basic_Clears"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.TimePopup.BUTTON_CLEAR_EVENT_CHANGE)}}]},{type:"bi.text_button",cls:"bi-split-left bi-split-right bi-high-light bi-split-top",shadow:!0,text:BI.i18nText("BI-Basic_Now"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.TimePopup.BUTTON_NOW_EVENT_CHANGE)}}]},{type:"bi.text_button",cls:"bi-high-light bi-split-top",shadow:!0,text:BI.i18nText("BI-Basic_OK"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.TimePopup.BUTTON_OK_EVENT_CHANGE)}}]}]]},height:24}]}},setValue:function(e){this._checkValueValid(e)?this.timeSelect.setValue():this.timeSelect.setValue({hour:e.hour,minute:e.minute,second:e.second})},getValue:function(){return this.timeSelect.getValue()},_checkValueValid:function(e){return BI.isNull(e)||BI.isEmptyObject(e)||BI.isEmptyString(e)}}),BI.TimePopup.BUTTON_OK_EVENT_CHANGE="BUTTON_OK_EVENT_CHANGE",BI.TimePopup.BUTTON_CLEAR_EVENT_CHANGE="BUTTON_CLEAR_EVENT_CHANGE",BI.TimePopup.BUTTON_NOW_EVENT_CHANGE="BUTTON_NOW_EVENT_CHANGE",BI.TimePopup.CALENDAR_EVENT_CHANGE="CALENDAR_EVENT_CHANGE",BI.shortcut("bi.time_popup",BI.TimePopup)},function(e,t){BI.TimeCombo=BI.inherit(BI.Single,{constants:{popupHeight:80,popupWidth:240,comboAdjustHeight:1,border:1},props:{baseCls:"bi-time-combo",height:24,format:"",allowEdit:!1},_init:function(){this.options,BI.TimeCombo.superclass._init.apply(this,arguments)},render:function(){var e=this,t=this.options;this.storeTriggerValue="",this.storeValue=t.value;var n={type:"bi.time_popup",value:t.value,listeners:[{eventName:BI.TimePopup.BUTTON_CLEAR_EVENT_CHANGE,action:function(){e.setValue(),e.hidePopupView(),e.fireEvent(BI.TimeCombo.EVENT_CONFIRM)}},{eventName:BI.TimePopup.BUTTON_OK_EVENT_CHANGE,action:function(){e.setValue(e.popup.getValue()),e.hidePopupView(),e.fireEvent(BI.TimeCombo.EVENT_CONFIRM)}},{eventName:BI.TimePopup.BUTTON_NOW_EVENT_CHANGE,action:function(){e._setNowTime()}}],ref:function(t){e.popup=t}};return{type:"bi.htape",items:[{type:"bi.absolute",items:[{el:{type:"bi.combo",cls:"bi-border bi-border-radius bi-focus-shadow",container:t.container,toggle:!1,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,el:{type:"bi.time_trigger",height:t.height,allowEdit:t.allowEdit,watermark:t.watermark,format:t.format,value:t.value,ref:function(t){e.trigger=t},listeners:[{eventName:"EVENT_KEY_DOWN",action:function(){e.combo.isViewVisible()&&e.combo.hideView(),e.fireEvent(BI.TimeCombo.EVENT_KEY_DOWN,arguments)}},{eventName:"EVENT_STOP",action:function(){e.combo.isViewVisible()||e.combo.showView()}},{eventName:"EVENT_FOCUS",action:function(){e.storeTriggerValue=e.trigger.getKey(),e.combo.isViewVisible()||e.combo.showView(),e.fireEvent("EVENT_FOCUS")}},{eventName:"EVENT_BLUR",action:function(){e.fireEvent("EVENT_BLUR")}},{eventName:"EVENT_ERROR",action:function(){var t=BI.getDate();e.storeValue={hour:t.getHours(),minute:t.getMinutes(),second:t.getSeconds()},e.fireEvent("EVENT_ERROR")}},{eventName:"EVENT_VALID",action:function(){e.fireEvent("EVENT_VALID")}},{eventName:"EVENT_CHANGE",action:function(){e.fireEvent("EVENT_CHANGE")}},{eventName:"EVENT_CONFIRM",action:function(){if(!e.combo.isViewVisible()){var t=e.storeTriggerValue,n=e.trigger.getKey();BI.isNotEmptyString(n)&&!BI.isEqual(n,t)?(e.storeValue=e.trigger.getValue(),e.setValue(e.trigger.getValue())):BI.isEmptyString(n)&&(e.storeValue=null,e.trigger.setValue()),e.fireEvent("EVENT_CONFIRM")}}}]},adjustLength:this.constants.comboAdjustHeight,popup:{el:n,width:this.constants.popupWidth,stopPropagation:!1},hideChecker:function(t){return 0===e.triggerBtn.element.find(t.target).length},listeners:[{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){e.popup.setValue(e.storeValue),e.fireEvent(BI.TimeCombo.EVENT_BEFORE_POPUPVIEW)}}],ref:function(t){e.combo=t}},top:0,left:0,right:0,bottom:0},{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button time-font icon-size-16",width:t.height,height:t.height,listeners:[{eventName:BI.IconButton.EVENT_CHANGE,action:function(){e.combo.isViewVisible()||e.combo.showView()}}],ref:function(t){e.triggerBtn=t}},top:0,right:0}]}]}},setValue:function(e){this.storeValue=e,this.trigger.setValue(e)},getValue:function(){return this.storeValue},hidePopupView:function(){this.combo.hideView()},_setNowTime:function(){var e=BI.getDate(),t={hour:e.getHours(),minute:e.getMinutes(),second:e.getSeconds()};this.setValue(t),this.hidePopupView(),this.fireEvent(BI.TimeCombo.EVENT_CONFIRM)}}),BI.TimeCombo.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.TimeCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.TimeCombo.EVENT_CHANGE="EVENT_CHANGE",BI.TimeCombo.EVENT_VALID="EVENT_VALID",BI.TimeCombo.EVENT_ERROR="EVENT_ERROR",BI.TimeCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.time_combo",BI.TimeCombo)},function(e,t){BI.TimeTrigger=BI.inherit(BI.Trigger,{_const:{COMPARE_FORMAT:"%H:%M:%S",COMPLETE_COMPARE_FORMAT:"%Y-%M-%d %H:%M:%S %P",FORMAT_ARRAY:["%H:%M:%S","%I:%M:%S","%l:%M:%S","%k:%M:%S","%l:%M:%S %p","%l:%M:%S %P","%H:%M:%S %p","%H:%M:%S %P","%l:%M","%k:%M","%I:%M","%H:%M","%M:%S"],DEFAULT_DATE_STRING:"2000-01-01",DEFAULT_HOUR:"00"},props:{extraCls:"bi-time-trigger",value:{},format:"",allowEdit:!1},render:function(){var e=this,t=this.options;return this.storeTriggerValue="",this.storeValue=t.value,{type:"bi.absolute",items:[{el:{type:"bi.sign_editor",height:t.height,validationChecker:function(t){return e._dateCheck(t)},quitChecker:function(){return!1},ref:function(t){e.editor=t},value:this._formatValue(t.value),hgap:4,allowBlank:!0,watermark:BI.isKey(t.watermark)?t.watermark:BI.i18nText("BI-Basic_Unrestricted"),title:BI.bind(this._getTitle,this),listeners:[{eventName:"EVENT_KEY_DOWN",action:function(){e.fireEvent("EVENT_KEY_DOWN",arguments)}},{eventName:"EVENT_FOCUS",action:function(){e.storeTriggerValue=e.getKey(),e.fireEvent("EVENT_FOCUS")}},{eventName:"EVENT_BLUR",action:function(){e.fireEvent("EVENT_BLUR")}},{eventName:"EVENT_STOP",action:function(){e.fireEvent("EVENT_STOP")}},{eventName:"EVENT_VALID",action:function(){e.fireEvent("EVENT_VALID")}},{eventName:"EVENT_ERROR",action:function(){e.fireEvent("EVENT_ERROR")}},{eventName:"EVENT_CONFIRM",action:function(){var t=e.editor.getValue();if(BI.isNotNull(t)&&e.editor.setState(t),BI.isNotEmptyString(t)&&!BI.isEqual(e.storeTriggerValue,e.getKey())){var n=t.match(/\d+/g);e.storeValue={hour:0|n[0],minute:0|n[1],second:0|n[2]}}e.fireEvent("EVENT_CONFIRM")}},{eventName:"EVENT_START",action:function(){e.fireEvent("EVENT_START")}},{eventName:"EVENT_CHANGE",action:function(){e.fireEvent("EVENT_CHANGE")}}]},left:0,right:0,top:0,bottom:0},{el:{type:"bi.text",invisible:t.allowEdit,cls:"show-text",title:BI.bind(this._getTitle,this),hgap:4},left:0,right:0,top:0,bottom:0}]}},_dateCheck:function(e){var t=this._const,n=this;return BI.any(t.FORMAT_ARRAY,(function(i,r){return BI.print(BI.parseDateTime(t.DEFAULT_DATE_STRING+" "+n._getCompleteHMS(e,r),t.COMPLETE_COMPARE_FORMAT),r)===e}))},_getCompleteHMS:function(e,t){var n=this._const;switch(t){case"%M:%S":e=n.DEFAULT_HOUR+":"+e}return e},_getTitle:function(){var e=this.storeValue||{},t=BI.getDate();return BI.print(BI.getDate(t.getFullYear(),0,1,e.hour,e.minute,e.second),this._getFormatString())},_getFormatString:function(){return this.options.format||this._const.COMPARE_FORMAT},_formatValue:function(e){var t=BI.getDate();return BI.isNotEmptyObject(e)?BI.print(BI.getDate(t.getFullYear(),t.getMonth(),t.getDay(),e.hour,e.minute,e.second),this._getFormatString()):""},getKey:function(){return this.editor.getValue()},setValue:function(e){this.storeValue=e,this.editor.setValue(this._formatValue(e))},getValue:function(){return this.storeValue}}),BI.shortcut("bi.time_trigger",BI.TimeTrigger)},function(e,t){BI.DateInterval=BI.inherit(BI.Single,{constants:{height:24,width:24,lgap:15,offset:0,timeErrorCls:"time-error"},_defaultConfig:function(){var e=BI.DateInterval.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-date-interval",minDate:"1900-01-01",maxDate:"2099-12-31",height:24,supportDynamic:!0})},_init:function(){var e=this,t=this.options;BI.DateInterval.superclass._init.apply(this,arguments),t.value=t.value||{},this.left=this._createCombo(t.value.start),this.right=this._createCombo(t.value.end),this.label=BI.createWidget({type:"bi.label",height:t.height,width:this.constants.width,text:"-"}),BI.createWidget({element:e,type:"bi.center",height:t.height,items:[{type:"bi.absolute",items:[{el:e.left,left:this.constants.offset,right:this.constants.width/2,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:e.right,left:this.constants.width/2,right:this.constants.offset,top:0,bottom:0}]}]}),BI.createWidget({type:"bi.horizontal_auto",element:this,items:[e.label]})},_createCombo:function(e){var t=this,n=this.options,i=BI.createWidget({type:"bi.dynamic_date_combo",supportDynamic:n.supportDynamic,minDate:n.minDate,maxDate:n.maxDate,behaviors:n.behaviors,value:e,height:n.height,listeners:[{eventName:BI.DynamicDateCombo.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,action:function(){t.fireEvent(BI.DateInterval.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}]});return i.on(BI.DynamicDateCombo.EVENT_ERROR,(function(){t._clearTitle(),BI.Bubbles.hide("error"),t.element.removeClass(t.constants.timeErrorCls),t.fireEvent(BI.DateInterval.EVENT_ERROR)})),i.on(BI.DynamicDateCombo.EVENT_VALID,(function(){BI.Bubbles.hide("error");var e=t.left.getKey(),n=t.right.getKey();t._check(e,n)&&t._compare(e,n)?(t._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),t.element.addClass(t.constants.timeErrorCls),BI.Bubbles.show("error",BI.i18nText("BI-Time_Interval_Error_Text"),t,{offsetStyle:"center"}),t.fireEvent(BI.DateInterval.EVENT_ERROR)):(t._clearTitle(),t.element.removeClass(t.constants.timeErrorCls))})),i.on(BI.DynamicDateCombo.EVENT_FOCUS,(function(){BI.Bubbles.hide("error");var e=t.left.getKey(),n=t.right.getKey();t._check(e,n)&&t._compare(e,n)?(t._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),t.element.addClass(t.constants.timeErrorCls),BI.Bubbles.show("error",BI.i18nText("BI-Time_Interval_Error_Text"),t,{offsetStyle:"center"}),t.fireEvent(BI.DateInterval.EVENT_ERROR)):(t._clearTitle(),t.element.removeClass(t.constants.timeErrorCls))})),i.on(BI.DynamicDateCombo.EVENT_CONFIRM,(function(){BI.Bubbles.hide("error");var e=t.left.getKey(),n=t.right.getKey();t._check(e,n)&&t._compare(e,n)?(t._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),t.element.addClass(t.constants.timeErrorCls),t.fireEvent(BI.DateInterval.EVENT_ERROR)):(t._clearTitle(),t.element.removeClass(t.constants.timeErrorCls),t.fireEvent(BI.DateInterval.EVENT_CHANGE))})),i},_dateCheck:function(e){return BI.print(BI.parseDateTime(e,"%Y-%x-%d"),"%Y-%x-%d")===e||BI.print(BI.parseDateTime(e,"%Y-%X-%d"),"%Y-%X-%d")===e||BI.print(BI.parseDateTime(e,"%Y-%x-%e"),"%Y-%x-%e")===e||BI.print(BI.parseDateTime(e,"%Y-%X-%e"),"%Y-%X-%e")===e},_checkVoid:function(e){var t=this.options;return!BI.checkDateVoid(e.year,e.month,e.day,t.minDate,t.maxDate)[0]},_check:function(e,t){var n=e.match(/\d+/g),i=t.match(/\d+/g);return this._dateCheck(e)&&BI.checkDateLegal(e)&&this._checkVoid({year:n[0],month:n[1],day:n[2]})&&this._dateCheck(t)&&BI.checkDateLegal(t)&&this._checkVoid({year:i[0],month:i[1],day:i[2]})},_compare:function(e,t){return e=BI.print(BI.parseDateTime(e,"%Y-%X-%d"),"%Y-%X-%d"),t=BI.print(BI.parseDateTime(t,"%Y-%X-%d"),"%Y-%X-%d"),BI.isNotNull(e)&&BI.isNotNull(t)&&e>t},_setTitle:function(e){this.left.setTitle(e),this.right.setTitle(e),this.label.setTitle(e)},_clearTitle:function(){this.left.setTitle(""),this.right.setTitle(""),this.label.setTitle("")},setMinDate:function(e){this.options.minDate=e,this.left.setMinDate(e),this.right.setMinDate(e)},setMaxDate:function(e){this.options.maxDate=e,this.left.setMaxDate(e),this.right.setMaxDate(e)},setValue:function(e){e=e||{},this.left.setValue(e.start),this.right.setValue(e.end)},getValue:function(){return{start:this.left.getValue(),end:this.right.getValue()}}}),BI.DateInterval.EVENT_VALID="EVENT_VALID",BI.DateInterval.EVENT_ERROR="EVENT_ERROR",BI.DateInterval.EVENT_CHANGE="EVENT_CHANGE",BI.DateInterval.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW="EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",BI.shortcut("bi.date_interval",BI.DateInterval)},function(e,t){BI.TimeInterval=BI.inherit(BI.Single,{constants:{height:24,width:24,lgap:15,offset:0,timeErrorCls:"time-error"},_defaultConfig:function(){var e=BI.TimeInterval.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{extraCls:"bi-time-interval",minDate:"1900-01-01",maxDate:"2099-12-31",height:24,supportDynamic:!0})},_init:function(){var e=this,t=this.options;BI.TimeInterval.superclass._init.apply(this,arguments),t.value=t.value||{},this.left=this._createCombo(t.value.start),this.right=this._createCombo(t.value.end),this.label=BI.createWidget({type:"bi.label",height:t.height,width:this.constants.width,text:"-"}),BI.createWidget({element:e,type:"bi.center",height:t.height,items:[{type:"bi.absolute",items:[{el:e.left,left:this.constants.offset,right:this.constants.width/2,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:e.right,left:this.constants.width/2,right:this.constants.offset,top:0,bottom:0}]}]}),BI.createWidget({type:"bi.horizontal_auto",element:this,items:[e.label]})},_createCombo:function(e){var t=this,n=this.options,i=BI.createWidget({type:"bi.dynamic_date_time_combo",supportDynamic:n.supportDynamic,minDate:n.minDate,maxDate:n.maxDate,behaviors:n.behaviors,value:e,height:n.height});return i.on(BI.DynamicDateTimeCombo.EVENT_ERROR,(function(){t._clearTitle(),BI.Bubbles.hide("error"),t.element.removeClass(t.constants.timeErrorCls),t.fireEvent(BI.TimeInterval.EVENT_ERROR)})),i.on(BI.DynamicDateTimeCombo.EVENT_VALID,(function(){BI.Bubbles.hide("error");var e=t.left.getKey(),n=t.right.getKey();t.left.isValid()&&t.right.isValid()&&t._check(e,n)&&t._compare(e,n)?(t._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),t.element.addClass(t.constants.timeErrorCls),BI.Bubbles.show("error",BI.i18nText("BI-Time_Interval_Error_Text"),t,{offsetStyle:"center"}),t.fireEvent(BI.TimeInterval.EVENT_ERROR)):(t._clearTitle(),t.element.removeClass(t.constants.timeErrorCls))})),i.on(BI.DynamicDateTimeCombo.EVENT_FOCUS,(function(){BI.Bubbles.hide("error");var e=t.left.getKey(),n=t.right.getKey();t.left.isValid()&&t.right.isValid()&&t._check(e,n)&&t._compare(e,n)?(t._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),t.element.addClass(t.constants.timeErrorCls),BI.Bubbles.show("error",BI.i18nText("BI-Time_Interval_Error_Text"),t,{offsetStyle:"center"}),t.fireEvent(BI.TimeInterval.EVENT_ERROR)):(t._clearTitle(),t.element.removeClass(t.constants.timeErrorCls))})),i.on(BI.DynamicDateTimeCombo.EVENT_CONFIRM,(function(){BI.Bubbles.hide("error");var e=t.left.getKey(),n=t.right.getKey();t.left.isValid()&&t.right.isValid()&&t._check(e,n)&&t._compare(e,n)?(t._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),t.element.addClass(t.constants.timeErrorCls),t.fireEvent(BI.TimeInterval.EVENT_ERROR)):(t._clearTitle(),t.element.removeClass(t.constants.timeErrorCls),t.fireEvent(BI.TimeInterval.EVENT_CHANGE))})),i},_dateCheck:function(e){return BI.print(BI.parseDateTime(e,"%Y-%x-%d %H:%M:%S"),"%Y-%x-%d %H:%M:%S")===e||BI.print(BI.parseDateTime(e,"%Y-%X-%d %H:%M:%S"),"%Y-%X-%d %H:%M:%S")===e||BI.print(BI.parseDateTime(e,"%Y-%x-%e %H:%M:%S"),"%Y-%x-%e %H:%M:%S")===e||BI.print(BI.parseDateTime(e,"%Y-%X-%e %H:%M:%S"),"%Y-%X-%e %H:%M:%S")===e},_checkVoid:function(e){var t=this.options;return!BI.checkDateVoid(e.year,e.month,e.day,t.minDate,t.maxDate)[0]},_check:function(e,t){var n=e.match(/\d+/g),i=t.match(/\d+/g);return this._dateCheck(e)&&BI.checkDateLegal(e)&&this._checkVoid({year:n[0],month:n[1],day:n[2]})&&this._dateCheck(t)&&BI.checkDateLegal(t)&&this._checkVoid({year:i[0],month:i[1],day:i[2]})},_compare:function(e,t){return e=BI.print(BI.parseDateTime(e,"%Y-%X-%d %H:%M:%S"),"%Y-%X-%d %H:%M:%S"),t=BI.print(BI.parseDateTime(t,"%Y-%X-%d %H:%M:%S"),"%Y-%X-%d %H:%M:%S"),BI.isNotNull(e)&&BI.isNotNull(t)&&e>t},_setTitle:function(e){this.left.setTitle(e),this.right.setTitle(e),this.label.setTitle(e)},_clearTitle:function(){this.left.setTitle(""),this.right.setTitle(""),this.label.setTitle("")},setMinDate:function(e){this.options.minDate=e,this.left.setMinDate(e),this.right.setMinDate(e)},setMaxDate:function(e){this.options.maxDate=e,this.left.setMaxDate(e),this.right.setMaxDate(e)},setValue:function(e){e=e||{},this.left.setValue(e.start),this.right.setValue(e.end)},getValue:function(){return{start:this.left.getValue(),end:this.right.getValue()}}}),BI.TimeInterval.EVENT_VALID="EVENT_VALID",BI.TimeInterval.EVENT_ERROR="EVENT_ERROR",BI.TimeInterval.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.time_interval",BI.TimeInterval)},function(e,t){BI.TimePeriods=BI.inherit(BI.Single,{constants:{height:24,width:24,hgap:15,offset:-15},props:{extraCls:"bi-time-interval",value:{}},render:function(){var e=this,t=this.options;return{type:"bi.absolute",height:this.constants.height,items:[{el:{type:"bi.horizontal_auto",items:[{type:"bi.label",height:this.constants.height,width:this.constants.width,text:"-",ref:function(t){e.label=t}}]},top:0,left:0,right:0,bottom:0},{el:{type:"bi.center",height:this.constants.height,hgap:this.constants.hgap,items:[{type:"bi.absolute",items:[{el:BI.extend({ref:function(t){e.left=t}},this._createCombo(t.value.start)),left:this.constants.offset,right:0,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:BI.extend({ref:function(t){e.right=t}},this._createCombo(t.value.end)),left:0,right:this.constants.offset,top:0,bottom:0}]}]},top:0,left:0,right:0,bottom:0}]}},_createCombo:function(e){var t=this;return{type:"bi.time_combo",value:e,listeners:[{eventName:BI.TimeCombo.EVENT_BEFORE_POPUPVIEW,action:function(){t.left.hidePopupView(),t.right.hidePopupView()}},{eventName:BI.TimeCombo.EVENT_CHANGE,action:function(){t.fireEvent(BI.TimePeriods.EVENT_CHANGE)}},{eventName:BI.TimeCombo.EVENT_CONFIRM,action:function(){t.fireEvent(BI.TimePeriods.EVENT_CONFIRM)}}]}},setValue:function(e){e=e||{},this.left.setValue(e.start),this.right.setValue(e.end)},getValue:function(){return{start:this.left.getValue(),end:this.right.getValue()}}}),BI.TimePeriods.EVENT_CONFIRM="EVENT_CONFIRM",BI.TimePeriods.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.time_periods",BI.TimePeriods)},function(e,t){BI.DynamicYearCard=BI.inherit(BI.Widget,{props:{baseCls:"bi-year-card"},render:function(){var e=this;this.options;return{type:"bi.vertical",ref:function(t){e.wrapper=t},items:[{type:"bi.label",text:BI.i18nText("BI-Multi_Date_Relative_Current_Time"),textAlign:"left",height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT},{type:"bi.dynamic_date_param_item",ref:function(){e.item=this},listeners:[{eventName:"EVENT_CHANGE",action:function(){e.fireEvent("EVENT_CHANGE")}},{eventName:"EVENT_INPUT_CHANGE",action:function(){BI.Bubbles.hide("dynamic-year-error")}}]}],vgap:10,hgap:10}},_checkDate:function(e){var t=this.options,n=BI.DynamicDateHelper.getCalculation(this._getValue());return!BI.checkDateVoid(n.getFullYear(),n.getMonth()+1,n.getDate(),t.min,t.max)[0]},_createValue:function(e,t){return{dateType:e,value:Math.abs(t),offset:t>0?1:0}},_getErrorText:function(){var e=this.options,t=BI.parseDateTime(e.min,"%Y-%X-%d"),n=BI.parseDateTime(e.max,"%Y-%X-%d");return BI.i18nText("BI-Basic_Year_Range_Error",t.getFullYear(),n.getFullYear())},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e)},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e)},setValue:function(e){e=e||{year:0},this.item.setValue(this._createValue(BI.DynamicDateCard.TYPE.YEAR,e.year))},_getValue:function(){var e=this.item.getValue();return{year:0===e.offset?-e.value:+e.value}},getInputValue:function(){return this._getValue()},getValue:function(){return this.checkValidation()?this._getValue():{}},checkValidation:function(e){var t,n=!this.item.checkValidation();return n?t=BI.i18nText("BI-Please_Input_Natural_Number"):(n=!this._checkDate(this._getValue()),t=this._getErrorText()),n&&e&&BI.Bubbles.show("dynamic-year-error",t,this.item),!n}}),BI.DynamicYearCard.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.dynamic_year_card",BI.DynamicYearCard)},function(e,t){BI.StaticYearCard=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.StaticYearCard.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-year-card",behaviors:{},min:"1900-01-01",max:"2099-12-31"})},_createYearCalendar:function(e){var t=this.options,n=this._year,i=BI.createWidget({type:"bi.year_calendar",behaviors:t.behaviors,min:t.min,max:t.max,logic:{dynamic:!0},year:n+12*e});return i.setValue(this._year),i},_init:function(){BI.StaticYearCard.superclass._init.apply(this,arguments);var e=this,t=this.options;this.selectedYear=this._year=BI.getDate().getFullYear(),this.backBtn=BI.createWidget({type:"bi.icon_button",cls:"pre-page-h-font",width:25,height:25,value:-1,listeners:[{eventName:BI.IconButton.EVENT_CHANGE,action:function(){e.navigation.setSelect(e.navigation.getSelect()-1),e._checkLeftValid(),e._checkRightValid()}}]}),this.preBtn=BI.createWidget({type:"bi.icon_button",cls:"next-page-h-font",width:25,height:25,value:1,listeners:[{eventName:BI.IconButton.EVENT_CHANGE,action:function(){e.navigation.setSelect(e.navigation.getSelect()+1),e._checkLeftValid(),e._checkRightValid()}}]}),this.navigation=BI.createWidget({type:"bi.navigation",direction:"top",element:this,single:!0,logic:{dynamic:!0},tab:{type:"bi.htape",cls:"bi-split-top bi-split-bottom",height:30,items:[{el:{type:"bi.center_adapt",items:[e.backBtn]},width:25},{type:"bi.layout"},{el:{type:"bi.center_adapt",items:[e.preBtn]},width:25}]},cardCreator:BI.bind(this._createYearCalendar,this),afterCardShow:function(){this.setValue(e.selectedYear)}}),this.navigation.on(BI.Navigation.EVENT_CHANGE,(function(){e.selectedYear=this.getValue(),e.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e.fireEvent(BI.StaticYearCard.EVENT_CHANGE,e.selectedYear)})),BI.isKey(t.value)&&this.setValue(t.value)},_checkLeftValid:function(){this.options;return this.backBtn.setEnable(true),true},_checkRightValid:function(){this.options;return this.preBtn.setEnable(true),true},_checkMin:function(){var e=this.options;BI.each(this.navigation.getAllCard(),(function(t,n){n.setMinDate(e.min)}))},_checkMax:function(){var e=this.options;BI.each(this.navigation.getAllCard(),(function(t,n){n.setMaxDate(e.max)}))},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e,this._checkLeftValid(),this._checkRightValid(),this._checkMin())},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e,this._checkLeftValid(),this._checkRightValid(),this._checkMax())},getValue:function(){return{year:this.selectedYear}},setValue:function(e){var t=this.options,n=(e=e||{}).year;BI.checkDateVoid(n,1,1,t.min,t.max)[0]?(n=BI.getDate().getFullYear(),this.selectedYear="",this.navigation.setSelect(BI.YearCalendar.getPageByYear(n)),this.navigation.setValue("")):(this.selectedYear=BI.parseInt(n),this.navigation.setSelect(BI.YearCalendar.getPageByYear(n)),this.navigation.setValue(this.selectedYear)),this._checkLeftValid(),this._checkRightValid()}}),BI.StaticYearCard.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.static_year_card",BI.StaticYearCard)},function(e,t){BI.DynamicYearCombo=BI.inherit(BI.Widget,{props:{baseCls:"bi-year-combo bi-border bi-border-radius bi-focus-shadow",behaviors:{},minDate:"1900-01-01",maxDate:"2099-12-31",height:24,supportDynamic:!0},_init:function(){var e=this,t=this.options;t.height-=2,BI.isNumeric(t.width)&&(t.width-=2),BI.DynamicYearCombo.superclass._init.apply(this,arguments),this.storeValue=t.value,this.trigger=BI.createWidget({type:"bi.dynamic_year_trigger",min:t.minDate,max:t.maxDate,height:t.height,value:t.value||""}),this.trigger.on(BI.DynamicYearTrigger.EVENT_KEY_DOWN,(function(){e.combo.isViewVisible()&&e.combo.hideView()})),this.trigger.on(BI.DynamicYearTrigger.EVENT_FOCUS,(function(){e.storeTriggerValue=this.getKey(),e.fireEvent(BI.DynamicYearCombo.EVENT_FOCUS)})),this.trigger.on(BI.DynamicYearTrigger.EVENT_START,(function(){e.combo.isViewVisible()&&e.combo.hideView()})),this.trigger.on(BI.DynamicYearTrigger.EVENT_STOP,(function(){e.combo.showView()})),this.trigger.on(BI.DynamicYearTrigger.EVENT_ERROR,(function(){e.combo.isViewVisible()&&e.combo.hideView(),e.fireEvent(BI.DynamicYearCombo.EVENT_ERROR)})),this.trigger.on(BI.DynamicYearTrigger.EVENT_VALID,(function(){e.fireEvent(BI.DynamicYearCombo.EVENT_VALID)})),this.trigger.on(BI.DynamicYearTrigger.EVENT_CONFIRM,(function(){e.combo.isViewVisible()||(this.getKey()&&this.getKey()!==e.storeTriggerValue?(e.storeValue=e.trigger.getValue(),e.setValue(e.storeValue)):this.getKey()||(e.storeValue=null,e.setValue()),e._checkDynamicValue(e.storeValue),e.fireEvent(BI.DynamicYearCombo.EVENT_CONFIRM))})),this.combo=BI.createWidget({type:"bi.combo",container:t.container,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,el:this.trigger,destroyWhenHide:!0,adjustLength:1,popup:{minWidth:85,stopPropagation:!1,el:{type:"bi.dynamic_year_popup",supportDynamic:t.supportDynamic,ref:function(){e.popup=this},listeners:[{eventName:BI.DynamicYearPopup.EVENT_CHANGE,action:function(){e.setValue(e.popup.getValue()),e.combo.hideView(),e.fireEvent(BI.DynamicYearCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearPopup.BUTTON_CLEAR_EVENT_CHANGE,action:function(){e.setValue(),e.combo.hideView(),e.fireEvent(BI.DynamicYearCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearPopup.BUTTON_lABEL_EVENT_CHANGE,action:function(){var t=BI.getDate();e.setValue({type:BI.DynamicYearCombo.Static,value:{year:t.getFullYear()}}),e.combo.hideView(),e.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearPopup.BUTTON_OK_EVENT_CHANGE,action:function(){e.setValue(e.popup.getValue()),e.combo.hideView(),e.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}}],behaviors:t.behaviors,min:t.minDate,max:t.maxDate},value:t.value||""}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){e.popup.setMinDate(t.minDate),e.popup.setMaxDate(t.maxDate),e.popup.setValue(e.storeValue),e.fireEvent(BI.DynamicYearCombo.EVENT_BEFORE_POPUPVIEW)})),BI.createWidget({type:"bi.htape",element:this,ref:function(){e.comboWrapper=this},items:[{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button date-change-h-font",width:24,height:24,ref:function(){e.changeIcon=this}},width:24},this.combo]}),this._checkDynamicValue(t.value)},_checkDynamicValue:function(e){var t=null;switch(BI.isNotNull(e)&&(t=e.type),t){case BI.DynamicYearCombo.Dynamic:this.changeIcon.setVisible(!0),this.comboWrapper.attr("items")[0].width=24,this.comboWrapper.resize();break;default:this.comboWrapper.attr("items")[0].width=0,this.comboWrapper.resize(),this.changeIcon.setVisible(!1)}},setMinDate:function(e){this.options.minDate=e,this.trigger.setMinDate(e),this.popup&&this.popup.setMinDate(e)},setMaxDate:function(e){this.options.maxDate=e,this.trigger.setMaxDate(e),this.popup&&this.popup.setMaxDate(e)},hideView:function(){this.combo.hideView()},getKey:function(){return this.trigger.getKey()+""},setValue:function(e){this.storeValue=e,this.trigger.setValue(e),this._checkDynamicValue(e)},getValue:function(){return this.storeValue},isStateValid:function(){return this.trigger.isValid()}}),BI.DynamicYearCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.DynamicYearCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.DynamicYearCombo.EVENT_ERROR="EVENT_ERROR",BI.DynamicYearCombo.EVENT_VALID="EVENT_VALID",BI.DynamicYearCombo.EVENT_FOCUS="EVENT_FOCUS",BI.shortcut("bi.dynamic_year_combo",BI.DynamicYearCombo),BI.extend(BI.DynamicYearCombo,{Static:1,Dynamic:2})},function(e,t){BI.DynamicYearPopup=BI.inherit(BI.Widget,{constants:{tabHeight:30},props:{baseCls:"bi-year-popup",behaviors:{},min:"1900-01-01",max:"2099-12-31",width:180,supportDynamic:!0},render:function(){var e=this;this.options,this.constants;return this.storeValue={type:BI.DynamicYearCombo.Static},{type:"bi.vertical",items:[{el:this._getTabJson()},{el:{type:"bi.grid",items:[[{type:"bi.text_button",cls:"bi-split-top bi-high-light",textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,shadow:!0,text:BI.i18nText("BI-Basic_Clear"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicYearPopup.BUTTON_CLEAR_EVENT_CHANGE)}}]},{type:"bi.text_button",textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,cls:"bi-split-left bi-split-right bi-high-light bi-split-top",shadow:!0,text:BI.i18nText("BI-Basic_Current_Year"),disabled:this._checkTodayValid(),ref:function(){e.yearButton=this},listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicYearPopup.BUTTON_lABEL_EVENT_CHANGE)}}]},{type:"bi.text_button",cls:"bi-split-top bi-high-light",textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,shadow:!0,text:BI.i18nText("BI-Basic_OK"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.dateTab.getSelect()===BI.DynamicDateCombo.Dynamic?e.dynamicPane.checkValidation(!0)&&e.fireEvent(BI.DynamicYearMonthPopup.BUTTON_OK_EVENT_CHANGE):e.fireEvent(BI.DynamicYearPopup.BUTTON_OK_EVENT_CHANGE)}}]}]],height:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT}}]}},_setInnerValue:function(){if(this.dateTab.getSelect()===BI.DynamicDateCombo.Static)this.yearButton.setValue(BI.i18nText("BI-Basic_Current_Year")),this.yearButton.setEnable(!this._checkYearValid());else{var e=BI.DynamicDateHelper.getCalculation(this.dynamicPane.getInputValue());e=BI.print(e,"%Y"),this.yearButton.setValue(e),this.yearButton.setEnable(!1)}},_checkYearValid:function(){var e=this.options,t=BI.getDate();return!!BI.checkDateVoid(t.getFullYear(),t.getMonth()+1,t.getDate(),e.min,e.max)[0]},_getTabJson:function(){var e=this,t=this.options;return{type:"bi.tab",logic:{dynamic:!0},ref:function(){e.dateTab=this},tab:{type:"bi.linear_segment",invisible:!t.supportDynamic,height:this.constants.tabHeight,items:BI.createItems([{text:BI.i18nText("BI-Basic_Year_Fen"),value:BI.DynamicYearCombo.Static},{text:BI.i18nText("BI-Basic_Dynamic_Title"),value:BI.DynamicYearCombo.Dynamic}],{textAlign:"center"})},cardCreator:function(n){switch(n){case BI.DynamicYearCombo.Dynamic:return{type:"bi.dynamic_year_card",cls:"dynamic-year-pane",min:e.options.min,max:e.options.max,listeners:[{eventName:"EVENT_CHANGE",action:function(){e._setInnerValue(e.year,n)}}],ref:function(){e.dynamicPane=this}};case BI.DynamicYearCombo.Static:default:return{type:"bi.static_year_card",behaviors:t.behaviors,min:e.options.min,max:e.options.max,listeners:[{eventName:BI.StaticYearCard.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicYearPopup.EVENT_CHANGE)}}],ref:function(){e.year=this}}}},listeners:[{eventName:BI.Tab.EVENT_CHANGE,action:function(){switch(e.dateTab.getSelect()){case BI.DynamicYearCombo.Static:var t=BI.DynamicDateHelper.getCalculation(e.dynamicPane.getValue());e.year.setValue({year:t.getFullYear()}),e._setInnerValue();break;case BI.DynamicYearCombo.Dynamic:default:e.storeValue&&e.storeValue.type===BI.DynamicYearCombo.Dynamic?e.dynamicPane.setValue(e.storeValue.value):e.dynamicPane.setValue({year:0}),e._setInnerValue()}}}]}},_checkTodayValid:function(){var e=this.options,t=BI.getDate();return!!BI.checkDateVoid(t.getFullYear(),t.getMonth()+1,t.getDate(),e.min,e.max)[0]},setMinDate:function(e){this.options.min!==e&&(this.options.min=e,this.year&&this.year.setMinDate(e),this.dynamicPane&&this.dynamicPane.setMinDate(e))},setMaxDate:function(e){this.options.max!==e&&(this.options.max=e,this.year&&this.year.setMaxDate(e),this.dynamicPane&&this.dynamicPane.setMaxDate(e))},setValue:function(e){this.storeValue=e;var t,n;switch(t=(e=e||{}).type||BI.DynamicDateCombo.Static,n=e.value||e,this.dateTab.setSelect(t),t){case BI.DynamicDateCombo.Dynamic:this.dynamicPane.setValue(n),this._setInnerValue();break;case BI.DynamicDateCombo.Static:default:this.year.setValue(n),this.yearButton.setValue(BI.i18nText("BI-Basic_Current_Year")),this.yearButton.setEnable(!this._checkTodayValid())}},getValue:function(){return{type:this.dateTab.getSelect(),value:this.dateTab.getValue()}}}),BI.DynamicYearPopup.BUTTON_CLEAR_EVENT_CHANGE="BUTTON_CLEAR_EVENT_CHANGE",BI.DynamicYearPopup.BUTTON_lABEL_EVENT_CHANGE="BUTTON_lABEL_EVENT_CHANGE",BI.DynamicYearPopup.BUTTON_OK_EVENT_CHANGE="BUTTON_OK_EVENT_CHANGE",BI.DynamicYearPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.dynamic_year_popup",BI.DynamicYearPopup)},function(e,t){BI.DynamicYearTrigger=BI.inherit(BI.Trigger,{_const:{hgap:4,vgap:2},_defaultConfig:function(){return BI.extend(BI.DynamicYearTrigger.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-year-trigger",min:"1900-01-01",max:"2099-12-31",height:24})},beforeInit:function(e){this.options.title=BI.bind(this._titleCreator,this),e()},_init:function(){BI.DynamicYearTrigger.superclass._init.apply(this,arguments);var e=this,t=this.options,n=this._const;this.editor=BI.createWidget({type:"bi.sign_editor",height:t.height,validationChecker:function(e){return""===e||BI.isPositiveInteger(e)&&!BI.checkDateVoid(e,1,1,t.min,t.max)[0]},quitChecker:function(e){return!1},hgap:n.hgap,vgap:n.vgap,watermark:BI.i18nText("BI-Basic_Unrestricted"),allowBlank:!0,errorText:function(e){if(BI.isPositiveInteger(e)){var n=BI.parseDateTime(t.min,"%Y-%X-%d"),i=BI.parseDateTime(t.max,"%Y-%X-%d");return BI.i18nText("BI-Basic_Year_Range_Error",n.getFullYear(),i.getFullYear())}return BI.i18nText("BI-Year_Trigger_Invalid_Text")}}),this.editor.on(BI.SignEditor.EVENT_KEY_DOWN,(function(){e.fireEvent(BI.DynamicYearTrigger.EVENT_KEY_DOWN,arguments)})),this.editor.on(BI.SignEditor.EVENT_FOCUS,(function(){e.fireEvent(BI.DynamicYearTrigger.EVENT_FOCUS)})),this.editor.on(BI.SignEditor.EVENT_STOP,(function(){e.fireEvent(BI.DynamicYearTrigger.EVENT_STOP)})),this.editor.on(BI.SignEditor.EVENT_CONFIRM,(function(){var t=e.editor.getValue();BI.isNotNull(t)&&e.editor.setValue(t),BI.isNotEmptyString(t)&&(e.storeValue={type:BI.DynamicDateCombo.Static,value:{year:t}}),e.fireEvent(BI.DynamicYearTrigger.EVENT_CONFIRM)})),this.editor.on(BI.SignEditor.EVENT_SPACE,(function(){e.editor.isValid()&&e.editor.blur()})),this.editor.on(BI.SignEditor.EVENT_START,(function(){e.fireEvent(BI.DynamicYearTrigger.EVENT_START)})),this.editor.on(BI.SignEditor.EVENT_ERROR,(function(){e.fireEvent(BI.DynamicYearTrigger.EVENT_ERROR)})),this.editor.on(BI.SignEditor.EVENT_VALID,(function(){e.fireEvent(BI.DynamicYearTrigger.EVENT_VALID)})),BI.createWidget({element:this,type:"bi.htape",items:[{el:this.editor},{el:{type:"bi.text_button",baseCls:"bi-trigger-year-text",text:BI.i18nText("BI-Multi_Date_Year"),width:t.height},width:t.height},{el:{type:"bi.trigger_icon_button",width:t.height},width:t.height}]}),this.setValue(t.value)},_getText:function(e){var t="";return BI.isNotNull(e.year)&&0!==BI.parseInt(e.year)&&(t+=Math.abs(e.year)+BI.i18nText("BI-Basic_Year")+(e.year<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),t},_setInnerValue:function(e,t){var n=BI.print(e,"%Y");this.editor.setState(n),this.editor.setValue(n)},_titleCreator:function(){var e=this.storeValue||{},t=e.type||BI.DynamicDateCombo.Static,n=e.value;if(!this.editor.isValid())return"";switch(t){case BI.DynamicDateCombo.Dynamic:var i=this._getText(n),r=BI.getDate();r=BI.DynamicDateHelper.getCalculation(n);var a=BI.print(r,"%Y");return BI.isEmptyString(i)?a:i+":"+a;case BI.DynamicDateCombo.Static:default:return(n=n||{}).year}},setValue:function(e){var t,n,i=BI.getDate();switch(this.storeValue=e,BI.isNotNull(e)&&(t=e.type||BI.DynamicDateCombo.Static,n=e.value||e),t){case BI.DynamicDateCombo.Dynamic:var r=this._getText(n);i=BI.DynamicDateHelper.getCalculation(n),this._setInnerValue(i,r);break;case BI.DynamicDateCombo.Static:default:n=n||{},this.editor.setState(n.year),this.editor.setValue(n.year)}},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e)},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e)},getValue:function(){return this.storeValue},getKey:function(){return 0|this.editor.getValue()}}),BI.DynamicYearTrigger.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.DynamicYearTrigger.EVENT_FOCUS="EVENT_FOCUS",BI.DynamicYearTrigger.EVENT_ERROR="EVENT_ERROR",BI.DynamicYearTrigger.EVENT_START="EVENT_START",BI.DynamicYearTrigger.EVENT_CONFIRM="EVENT_CONFIRM",BI.DynamicYearTrigger.EVENT_STOP="EVENT_STOP",BI.DynamicYearTrigger.EVENT_VALID="EVENT_VALID",BI.shortcut("bi.dynamic_year_trigger",BI.DynamicYearTrigger)},function(e,t){BI.YearInterval=BI.inherit(BI.Single,{constants:{height:24,width:25,lgap:15,offset:-15,timeErrorCls:"time-error"},props:{extraCls:"bi-year-interval",minDate:"1900-01-01",maxDate:"2099-12-31",supportDynamic:!0},render:function(){var e=this,t=this.options;return t.value=t.value||{},this.left=this._createCombo(t.value.start),this.right=this._createCombo(t.value.end),[{type:"bi.center",hgap:15,height:this.constants.height,items:[{type:"bi.absolute",items:[{el:e.left,left:this.constants.offset,right:0,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:e.right,left:0,right:this.constants.offset,top:0,bottom:0}]}]},{type:"bi.horizontal_auto",items:[{type:"bi.label",height:this.constants.height,width:this.constants.width,text:"-",ref:function(t){e.label=t}}]}]},_createCombo:function(e){var t=this,n=this.options,i=BI.createWidget({type:"bi.dynamic_year_combo",supportDynamic:n.supportDynamic,minDate:n.minDate,maxDate:n.maxDate,behaviors:n.behaviors,value:e,listeners:[{eventName:BI.DynamicYearCombo.EVENT_BEFORE_POPUPVIEW,action:function(){t.fireEvent(BI.YearInterval.EVENT_BEFORE_POPUPVIEW)}}]});return i.on(BI.DynamicYearCombo.EVENT_ERROR,(function(){t._clearTitle(),BI.Bubbles.hide("error"),t.element.removeClass(t.constants.timeErrorCls),t.fireEvent(BI.YearInterval.EVENT_ERROR)})),i.on(BI.DynamicYearCombo.EVENT_VALID,(function(){t._checkValid()})),i.on(BI.DynamicYearCombo.EVENT_FOCUS,(function(){t._checkValid()})),i.on(BI.DynamicYearCombo.EVENT_CONFIRM,(function(){BI.Bubbles.hide("error");var e=t.left.getKey(),n=t.right.getKey();t.left.isStateValid()&&t.right.isStateValid()&&t._check(e,n)&&t._compare(e,n)?(t._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),t.element.addClass(t.constants.timeErrorCls),t.fireEvent(BI.YearInterval.EVENT_ERROR)):(t._clearTitle(),t.element.removeClass(t.constants.timeErrorCls),t.fireEvent(BI.YearInterval.EVENT_CHANGE))})),i},_dateCheck:function(e){return BI.print(BI.parseDateTime(e,"%Y"),"%Y")===e||BI.print(BI.parseDateTime(e,"%Y"),"%Y")===e},_checkVoid:function(e){var t=this.options;return!BI.checkDateVoid(e.year,1,1,t.minDate,t.maxDate)[0]},_check:function(e,t){var n=e.match(/\d+/g),i=t.match(/\d+/g),r="";BI.isNotNull(n)&&(r=n[0]||"");var a="";return BI.isNotNull(i)&&(a=i[0]||""),this._dateCheck(r)&&BI.checkDateLegal(r)&&this._checkVoid({year:n[0],month:1,day:1})&&this._dateCheck(a)&&BI.checkDateLegal(a)&&this._checkVoid({year:i[0],month:12,day:1})},_compare:function(e,t){return e=BI.print(BI.parseDateTime(e,"%Y"),"%Y"),t=BI.print(BI.parseDateTime(t,"%Y"),"%Y"),BI.isNotNull(e)&&BI.isNotNull(t)&&e>t},_setTitle:function(e){this.setTitle(e)},_clearTitle:function(){this.setTitle("")},_checkValid:function(){var e=this;BI.Bubbles.hide("error");var t=e.left.getKey(),n=e.right.getKey();e.left.isValid()&&e.right.isValid()&&e._check(t,n)&&e._compare(t,n)?(e._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),e.element.addClass(e.constants.timeErrorCls),BI.Bubbles.show("error",BI.i18nText("BI-Time_Interval_Error_Text"),e,{offsetStyle:"center"}),e.fireEvent(BI.YearInterval.EVENT_ERROR)):(e._clearTitle(),e.element.removeClass(e.constants.timeErrorCls))},setMinDate:function(e){this.options.minDate=e,this.left.setMinDate(e),this.right.setMinDate(e)},setMaxDate:function(e){this.options.maxDate=e,this.left.setMaxDate(e),this.right.setMaxDate(e)},setValue:function(e){e=e||{},this.left.setValue(e.start),this.right.setValue(e.end),this._checkValid()},getValue:function(){return{start:this.left.getValue(),end:this.right.getValue()}}}),BI.YearInterval.EVENT_VALID="EVENT_VALID",BI.YearInterval.EVENT_ERROR="EVENT_ERROR",BI.YearInterval.EVENT_CHANGE="EVENT_CHANGE",BI.YearInterval.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.year_interval",BI.YearInterval)},function(e,t){BI.DynamicYearMonthCard=BI.inherit(BI.Widget,{props:{baseCls:"bi-year-month-card"},render:function(){var e=this;return{type:"bi.vertical",items:[{type:"bi.label",text:BI.i18nText("BI-Multi_Date_Relative_Current_Time"),textAlign:"left",height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT},{type:"bi.vertical",ref:function(t){e.wrapper=t},items:[{el:{type:"bi.dynamic_date_param_item",validationChecker:BI.bind(e._checkDate,e),ref:function(){e.year=this},listeners:[{eventName:"EVENT_CHANGE",action:function(){e.fireEvent("EVENT_CHANGE")}},{eventName:"EVENT_INPUT_CHANGE",action:function(){BI.Bubbles.hide("dynamic-year-month-error")}}]},bgap:10},{type:"bi.dynamic_date_param_item",dateType:BI.DynamicDateCard.TYPE.MONTH,ref:function(){e.month=this},listeners:[{eventName:"EVENT_CHANGE",action:function(){e.fireEvent("EVENT_CHANGE")}},{eventName:"EVENT_INPUT_CHANGE",action:function(){BI.Bubbles.hide("dynamic-year-month-error")}}]}]}],vgap:10,hgap:10}},_getErrorText:function(){var e=this.options,t=BI.parseDateTime(e.min,"%Y-%X-%d"),n=BI.parseDateTime(e.max,"%Y-%X-%d");return BI.i18nText("BI-Basic_Year_Month_Range_Error",t.getFullYear(),t.getMonth()+1,n.getFullYear(),n.getMonth()+1)},_checkDate:function(e){var t=this.options,n=BI.DynamicDateHelper.getCalculation(BI.extend(this._getValue(),this._digestDateTypeValue(e)));return!BI.checkDateVoid(n.getFullYear(),n.getMonth()+1,n.getDate(),t.min,t.max)[0]},_digestDateTypeValue:function(e){var t={};switch(e.dateType){case BI.DynamicDateCard.TYPE.YEAR:t.year=0===e.offset?-e.value:+e.value;break;case BI.DynamicDateCard.TYPE.MONTH:t.month=0===e.offset?-e.value:+e.value}return t},_createValue:function(e,t){return{dateType:e,value:Math.abs(t),offset:t>0?1:0}},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e)},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e)},setValue:function(e){e=e||{year:0,month:0},this.year.setValue(this._createValue(BI.DynamicDateCard.TYPE.YEAR,e.year)),this.month.setValue(this._createValue(BI.DynamicDateCard.TYPE.MONTH,e.month))},_getValue:function(){var e=this.year.getValue(),t=this.month.getValue();return{year:0===e.offset?-e.value:e.value,month:0===t.offset?-t.value:t.value}},getInputValue:function(){return this._getValue()},getValue:function(){return this.checkValidation()?this._getValue():{}},checkValidation:function(e){var t,n=!this.year.checkValidation(),i=!this.month.checkValidation(),r=n||i;return r?t=BI.i18nText("BI-Please_Input_Natural_Number"):(r=!this._checkDate(this._getValue()),t=this._getErrorText()),r&&e&&BI.Bubbles.show("dynamic-year-month-error",t,this.wrapper),!r}}),BI.DynamicYearMonthCard.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.dynamic_year_month_card",BI.DynamicYearMonthCard)},function(e,t){BI.StaticYearMonthCard=BI.inherit(BI.Widget,{props:{baseCls:"bi-static-year-month-card",behaviors:{}},_createMonths:function(){var e=this,t=[1,7,2,8,3,9,4,10,5,11,6,12],n=[];return n.push(t.slice(0,2)),n.push(t.slice(2,4)),n.push(t.slice(4,6)),n.push(t.slice(6,8)),n.push(t.slice(8,10)),n.push(t.slice(10,12)),BI.map(n,(function(t,n){return BI.map(n,(function(n,i){return{type:"bi.text_item",cls:"bi-list-item-select",textAlign:"center",whiteSpace:"nowrap",once:!1,forceSelected:!0,height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT-1,width:38,value:i,text:i,ref:function(i){e.monthMap[0===n?t:t+6]=i}}}))}))},render:function(){var e=this,t=this.options;return this.monthMap={},{type:"bi.vertical",items:[{type:"bi.year_picker",cls:"bi-split-bottom",min:t.min,max:t.max,ref:function(){e.yearPicker=this},behaviors:t.behaviors,height:30,listeners:[{eventName:BI.YearPicker.EVENT_CHANGE,action:function(){var t=this.getValue();e._checkMonthStatus(t),e.setValue({year:t,month:e.selectedMonth})}}]},{el:{type:"bi.button_group",behaviors:t.behaviors,ref:function(){e.month=this},items:this._createMonths(),layouts:[BI.LogicFactory.createLogic("table",BI.extend({dynamic:!0},{columns:2,rows:6,columnSize:[.5,.5],rowSize:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT+1})),{type:"bi.center_adapt",vgap:1,hgap:2}],value:t.value,listeners:[{eventName:BI.ButtonGroup.EVENT_CHANGE,action:function(){e.selectedYear=e.yearPicker.getValue(),e.selectedMonth=this.getValue()[0],e.fireEvent(BI.StaticYearMonthCard.EVENT_CHANGE)}}]},vgap:5}]}},created:function(){this._checkMonthStatus(this.selectedYear)},_checkMonthStatus:function(e){var t=this.options,n=BI.parseDateTime(t.min,"%Y-%X-%d"),i=BI.parseDateTime(t.max,"%Y-%X-%d"),r=n.getFullYear(),a=i.getFullYear(),o=0,s=11;r===e&&(o=n.getMonth()),a===e&&(s=i.getMonth());var l=e<r||e>a;BI.each(this.monthMap,(function(e,t){var n=e<o||e>s;t.setEnable(!l&&!n)}))},setMinDate:function(e){this.options.min!==e&&(this.options.min=e,this.yearPicker.setMinDate(e),this._checkMonthStatus(this.selectedYear))},setMaxDate:function(e){this.options.max!==e&&(this.options.max=e,this.yearPicker.setMaxDate(e),this._checkMonthStatus(this.selectedYear))},getValue:function(){return{year:this.selectedYear,month:this.selectedMonth}},setValue:function(e){var t=this.options,n={};if(n.year=e.year||0,n.month=e.month||0,0===n.year||0===n.month||BI.checkDateVoid(n.year,n.month,1,t.min,t.max)[0]){var i=n.year||BI.getDate().getFullYear();this.selectedYear=i,this.selectedMonth="",this.yearPicker.setValue(i),this.month.setValue()}else this.selectedYear=BI.parseInt(n.year),this.selectedMonth=BI.parseInt(n.month),this.yearPicker.setValue(this.selectedYear),this.month.setValue(this.selectedMonth);this._checkMonthStatus(this.selectedYear)}}),BI.StaticYearMonthCard.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.static_year_month_card",BI.StaticYearMonthCard)},function(e,t){BI.DynamicYearMonthCombo=BI.inherit(BI.Single,{props:{baseCls:"bi-year-month-combo bi-border bi-border-radius bi-focus-shadow",behaviors:{},minDate:"1900-01-01",maxDate:"2099-12-31",height:24,supportDynamic:!0},_init:function(){var e=this,t=this.options;t.height-=2,BI.isNumeric(t.width)&&(t.width-=2),BI.DynamicYearMonthCombo.superclass._init.apply(this,arguments),this.storeValue=t.value,this.storeTriggerValue="",this.trigger=BI.createWidget({type:"bi.dynamic_year_month_trigger",min:t.minDate,max:t.maxDate,height:t.height,value:t.value||""}),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_KEY_DOWN,(function(){e.combo.isViewVisible()&&e.combo.hideView()})),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_START,(function(){e.combo.isViewVisible()&&e.combo.hideView()})),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_STOP,(function(){e.combo.showView()})),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_ERROR,(function(){e.combo.isViewVisible()&&e.combo.hideView(),e.fireEvent(BI.DynamicYearMonthCombo.EVENT_ERROR)})),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_VALID,(function(){e.fireEvent(BI.DynamicYearMonthCombo.EVENT_VALID)})),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_CONFIRM,(function(){var t=e.storeTriggerValue,n=e.trigger.getKey();BI.isEqual(n,t)||(BI.isNotEmptyString(n)&&!BI.isEqual(n,t)&&(e.storeValue=e.trigger.getValue(),e.setValue(e.trigger.getValue())),e._checkDynamicValue(e.storeValue),e.fireEvent(BI.DynamicYearMonthCombo.EVENT_CONFIRM))})),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_FOCUS,(function(){e.storeTriggerValue=e.trigger.getKey(),e.fireEvent(BI.DynamicYearMonthCombo.EVENT_FOCUS)})),this.combo=BI.createWidget({type:"bi.combo",container:t.container,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,el:this.trigger,destroyWhenHide:!0,adjustLength:1,popup:{minWidth:100,stopPropagation:!1,el:{type:"bi.dynamic_year_month_popup",supportDynamic:t.supportDynamic,ref:function(){e.popup=this},listeners:[{eventName:BI.DynamicYearMonthPopup.EVENT_CHANGE,action:function(){e.setValue(e.popup.getValue()),e.combo.hideView(),e.fireEvent(BI.DynamicYearMonthCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearMonthPopup.BUTTON_CLEAR_EVENT_CHANGE,action:function(){e.setValue(),e.combo.hideView(),e.fireEvent(BI.DynamicYearMonthCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearMonthPopup.BUTTON_lABEL_EVENT_CHANGE,action:function(){var t=BI.getDate();e.setValue({type:BI.DynamicYearMonthCombo.Static,value:{year:t.getFullYear(),month:t.getMonth()+1}}),e.combo.hideView(),e.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearMonthPopup.BUTTON_OK_EVENT_CHANGE,action:function(){var t=e.popup.getValue();e._checkValue(t)&&e.setValue(t),e.combo.hideView(),e.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}}],behaviors:t.behaviors,min:t.minDate,max:t.maxDate},value:t.value||""}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){e.popup.setMinDate(t.minDate),e.popup.setMaxDate(t.maxDate),e.popup.setValue(e.storeValue),e.fireEvent(BI.DynamicYearMonthCombo.EVENT_BEFORE_POPUPVIEW)})),BI.createWidget({type:"bi.htape",element:this,ref:function(){e.comboWrapper=this},items:[{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button date-change-h-font",width:24,height:24,ref:function(){e.changeIcon=this}},width:24},this.combo]}),this._checkDynamicValue(t.value)},_checkDynamicValue:function(e){var t=null;switch(BI.isNotNull(e)&&(t=e.type),t){case BI.DynamicYearMonthCombo.Dynamic:this.changeIcon.setVisible(!0),this.comboWrapper.attr("items")[0].width=24,this.comboWrapper.resize();break;default:this.comboWrapper.attr("items")[0].width=0,this.comboWrapper.resize(),this.changeIcon.setVisible(!1)}},_checkValue:function(e){var t=this.options;switch(e.type){case BI.DynamicDateCombo.Dynamic:return BI.isNotEmptyObject(e.value);case BI.DynamicDateCombo.Static:var n=e.value||{};return!BI.checkDateVoid(n.year,n.month,1,t.minDate,t.maxDate)[0];default:return!0}},setMinDate:function(e){this.options.minDate=e,this.trigger.setMinDate(e),this.popup&&this.popup.setMinDate(e)},setMaxDate:function(e){this.options.maxDate=e,this.trigger.setMaxDate(e),this.popup&&this.popup.setMaxDate(e)},hideView:function(){this.combo.hideView()},setValue:function(e){this.storeValue=e,this.trigger.setValue(e),this._checkDynamicValue(e)},getValue:function(){return this.storeValue},getKey:function(){return this.trigger.getKey()},isStateValid:function(){return this.trigger.isStateValid()}}),BI.DynamicYearMonthCombo.EVENT_ERROR="EVENT_ERROR",BI.DynamicYearMonthCombo.EVENT_VALID="EVENT_VALID",BI.DynamicYearMonthCombo.EVENT_FOCUS="EVENT_FOCUS",BI.DynamicYearMonthCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.DynamicYearMonthCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.dynamic_year_month_combo",BI.DynamicYearMonthCombo),BI.extend(BI.DynamicYearMonthCombo,{Static:1,Dynamic:2})},function(e,t){BI.DynamicYearMonthPopup=BI.inherit(BI.Widget,{constants:{tabHeight:30},props:{baseCls:"bi-year-month-popup",behaviors:{},min:"1900-01-01",max:"2099-12-31",width:180,supportDynamic:!0},render:function(){var e=this;this.options,this.constants;return this.storeValue={type:BI.DynamicYearMonthCombo.Static},{type:"bi.vertical",items:[{el:this._getTabJson()},{el:{type:"bi.grid",items:[[{type:"bi.text_button",cls:"bi-split-top bi-high-light",textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,shadow:!0,text:BI.i18nText("BI-Basic_Clear"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicYearMonthPopup.BUTTON_CLEAR_EVENT_CHANGE)}}]},{type:"bi.text_button",cls:"bi-split-left bi-split-right bi-high-light bi-split-top",textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,shadow:!0,text:BI.i18nText("BI-Basic_Current_Month"),disabled:this._checkTodayValid(),ref:function(){e.textButton=this},listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicYearMonthPopup.BUTTON_lABEL_EVENT_CHANGE)}}]},{type:"bi.text_button",cls:"bi-split-top bi-high-light",textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,shadow:!0,text:BI.i18nText("BI-Basic_OK"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.dateTab.getSelect()===BI.DynamicDateCombo.Dynamic?e.dynamicPane.checkValidation(!0)&&e.fireEvent(BI.DynamicYearMonthPopup.BUTTON_OK_EVENT_CHANGE):e.fireEvent(BI.DynamicYearMonthPopup.BUTTON_OK_EVENT_CHANGE)}}]}]],height:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT}}]}},_setInnerValue:function(){if(this.dateTab.getSelect()===BI.DynamicDateCombo.Static)this.textButton.setValue(BI.i18nText("BI-Basic_Current_Month")),this.textButton.setEnable(!this._checkTodayValid());else{var e=BI.DynamicDateHelper.getCalculation(this.dynamicPane.getInputValue());e=BI.print(e,"%Y-%x"),this.textButton.setValue(e),this.textButton.setEnable(!1)}},_checkTodayValid:function(){var e=this.options,t=BI.getDate();return!!BI.checkDateVoid(t.getFullYear(),t.getMonth()+1,t.getDate(),e.min,e.max)[0]},_getTabJson:function(){var e=this,t=this.options;return{type:"bi.tab",logic:{dynamic:!0},ref:function(){e.dateTab=this},tab:{type:"bi.linear_segment",cls:"bi-split-bottom",invisible:!t.supportDynamic,height:this.constants.tabHeight,items:BI.createItems([{text:BI.i18nText("BI-Basic_Year_Month"),value:BI.DynamicYearCombo.Static},{text:BI.i18nText("BI-Basic_Dynamic_Title"),value:BI.DynamicYearCombo.Dynamic}],{textAlign:"center"})},cardCreator:function(n){switch(n){case BI.DynamicYearCombo.Dynamic:return{type:"bi.dynamic_year_month_card",cls:"dynamic-year-month-pane",min:e.options.min,max:e.options.max,listeners:[{eventName:"EVENT_CHANGE",action:function(){e._setInnerValue(e.year,n)}}],ref:function(){e.dynamicPane=this}};case BI.DynamicYearCombo.Static:default:return{type:"bi.static_year_month_card",behaviors:t.behaviors,min:e.options.min,max:e.options.max,listeners:[{eventName:BI.StaticYearMonthCard.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicYearMonthPopup.EVENT_CHANGE)}}],ref:function(){e.year=this}}}},listeners:[{eventName:BI.Tab.EVENT_CHANGE,action:function(){switch(e.dateTab.getSelect()){case BI.DynamicYearCombo.Static:var t=BI.DynamicDateHelper.getCalculation(e.dynamicPane.getValue());e.year.setValue({year:t.getFullYear(),month:t.getMonth()+1}),e._setInnerValue();break;case BI.DynamicYearCombo.Dynamic:default:e.storeValue&&e.storeValue.type===BI.DynamicYearCombo.Dynamic?e.dynamicPane.setValue(e.storeValue.value):e.dynamicPane.setValue({year:0}),e._setInnerValue()}}}]}},setMinDate:function(e){this.options.min!==e&&(this.options.min=e,this.year&&this.year.setMinDate(e),this.dynamicPane&&this.dynamicPane.setMinDate(e))},setMaxDate:function(e){this.options.max!==e&&(this.options.max=e,this.year&&this.year.setMaxDate(e),this.dynamicPane&&this.dynamicPane.setMaxDate(e))},setValue:function(e){this.storeValue=e;var t,n;switch(t=(e=e||{}).type||BI.DynamicDateCombo.Static,n=e.value||e,this.dateTab.setSelect(t),t){case BI.DynamicDateCombo.Dynamic:this.dynamicPane.setValue(n),this._setInnerValue();break;case BI.DynamicDateCombo.Static:default:this.year.setValue(n),this.textButton.setValue(BI.i18nText("BI-Basic_Current_Month")),this.textButton.setEnable(!this._checkTodayValid())}},getValue:function(){return{type:this.dateTab.getSelect(),value:this.dateTab.getValue()}}}),BI.DynamicYearMonthPopup.BUTTON_CLEAR_EVENT_CHANGE="BUTTON_CLEAR_EVENT_CHANGE",BI.DynamicYearMonthPopup.BUTTON_lABEL_EVENT_CHANGE="BUTTON_lABEL_EVENT_CHANGE",BI.DynamicYearMonthPopup.BUTTON_OK_EVENT_CHANGE="BUTTON_OK_EVENT_CHANGE",BI.DynamicYearMonthPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.dynamic_year_month_popup",BI.DynamicYearMonthPopup)},function(e,t){BI.DynamicYearMonthTrigger=BI.inherit(BI.Trigger,{_const:{hgap:4,vgap:2},props:{extraCls:"bi-year-month-trigger",min:"1900-01-01",max:"2099-12-31",height:24},beforeInit:function(e){this.options.title=BI.bind(this._titleCreator,this),e()},_init:function(){BI.DynamicYearMonthTrigger.superclass._init.apply(this,arguments);var e=this.options;this.yearEditor=this._createEditor(!0),this.monthEditor=this._createEditor(!1),BI.createWidget({element:this,type:"bi.htape",items:[{type:"bi.center",items:[{type:"bi.htape",items:[this.yearEditor,{el:{type:"bi.text_button",text:BI.i18nText("BI-Multi_Date_Year"),width:e.height},width:e.height}]},{type:"bi.htape",items:[this.monthEditor,{el:{type:"bi.text_button",text:BI.i18nText("BI-Multi_Date_Month"),width:e.height},width:e.height}]}]},{el:{type:"bi.trigger_icon_button",width:e.height},width:e.height}]}),this.setValue(e.value)},_createEditor:function(e){var t=this,n=this.options,i=this._const,r=BI.createWidget({type:"bi.sign_editor",height:n.height,validationChecker:function(i){if(e)return""===i||BI.isPositiveInteger(i)&&!BI.checkDateVoid(i,parseInt(i,10)===BI.parseDateTime(n.min,"%Y-%X-%d").getFullYear()?BI.parseDateTime(n.min,"%Y-%X-%d").getMonth()+1:1,1,n.min,n.max)[0];var r=t.yearEditor.getValue();return""===i||BI.isPositiveInteger(i)&&i>=1&&i<=12&&(!!BI.isEmptyString(r)||!BI.checkDateVoid(t.yearEditor.getValue(),i,1,n.min,n.max)[0])},quitChecker:function(){return!1},watermark:BI.i18nText("BI-Basic_Unrestricted"),errorText:function(i){var r=e?i:t.yearEditor.getValue(),a=e?t.monthEditor.getValue():i;if(!BI.isPositiveInteger(r)||!BI.isPositiveInteger(a)||a>12)return BI.i18nText("BI-Year_Trigger_Invalid_Text");var o=BI.parseDateTime(n.min,"%Y-%X-%d"),s=BI.parseDateTime(n.max,"%Y-%X-%d");return BI.i18nText("BI-Basic_Year_Month_Range_Error",o.getFullYear(),o.getMonth()+1,s.getFullYear(),s.getMonth()+1)},hgap:i.hgap,vgap:i.vgap,allowBlank:!0});return r.on(BI.SignEditor.EVENT_KEY_DOWN,(function(){t.fireEvent(BI.DynamicYearMonthTrigger.EVENT_KEY_DOWN)})),r.on(BI.SignEditor.EVENT_FOCUS,(function(){t.fireEvent(BI.DynamicYearMonthTrigger.EVENT_FOCUS)})),r.on(BI.SignEditor.EVENT_STOP,(function(){t.fireEvent(BI.DynamicYearMonthTrigger.EVENT_STOP)})),r.on(BI.SignEditor.EVENT_CONFIRM,(function(){t._doEditorConfirm(r),t.fireEvent(BI.DynamicYearMonthTrigger.EVENT_CONFIRM)})),r.on(BI.SignEditor.EVENT_SPACE,(function(){r.isValid()&&r.blur()})),r.on(BI.SignEditor.EVENT_START,(function(){t.fireEvent(BI.DynamicYearMonthTrigger.EVENT_START)})),r.on(BI.SignEditor.EVENT_ERROR,(function(){t.fireEvent(BI.DynamicYearMonthTrigger.EVENT_ERROR)})),r.on(BI.SignEditor.EVENT_VALID,(function(){var e=t.yearEditor.getValue(),i=t.monthEditor.getValue();BI.isNotEmptyString(e)&&BI.isNotEmptyString(i)&&BI.isPositiveInteger(e)&&i>=1&&i<=12&&!BI.checkDateVoid(e,i,1,n.min,n.max)[0]&&t.fireEvent(BI.DynamicYearMonthTrigger.EVENT_VALID)})),r.on(BI.SignEditor.EVENT_CHANGE,(function(){e&&t._autoSwitch(r)})),r},_titleCreator:function(){var e=this.storeValue||{},t=e.type||BI.DynamicDateCombo.Static,n=e.value;if(!this.monthEditor.isValid()||!this.yearEditor.isValid())return"";switch(t){case BI.DynamicDateCombo.Dynamic:var i=this._getText(n),r=BI.getDate();r=BI.DynamicDateHelper.getCalculation(n);var a=BI.print(r,"%Y-%x");return BI.isEmptyString(i)?a:i+":"+a;case BI.DynamicDateCombo.Static:default:return n=n||{},this._getStaticTitle(n)}},_doEditorConfirm:function(e){var t=e.getValue();BI.isNotNull(t)&&e.setValue(t);var n=this.monthEditor.getValue();this.storeValue={type:BI.DynamicDateCombo.Static,value:{year:this.yearEditor.getValue(),month:BI.isEmptyString(this.monthEditor.getValue())?"":n}}},_yearCheck:function(e){var t=BI.print(BI.parseDateTime(e,"%Y-%X-%d"),"%Y-%X-%d");return BI.print(BI.parseDateTime(e,"%Y"),"%Y")===e&&t>=this.options.min&&t<=this.options.max},_autoSwitch:function(e){var t=e.getValue();BI.isNotEmptyString(t)&&BI.checkDateLegal(t)&&4===t.length&&this._yearCheck(t)&&(this._doEditorConfirm(e),this.fireEvent(BI.DynamicYearMonthTrigger.EVENT_CONFIRM),this.monthEditor.focus())},_getText:function(e){var t="";return BI.isNotNull(e.year)&&0!==BI.parseInt(e.year)&&(t+=Math.abs(e.year)+BI.i18nText("BI-Basic_Year")+(e.year<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),BI.isNotNull(e.month)&&0!==BI.parseInt(e.month)&&(t+=Math.abs(e.month)+BI.i18nText("BI-Basic_Month")+(e.month<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),t},_setInnerValue:function(e,t){this.yearEditor.setValue(e.getFullYear()),this.monthEditor.setValue(e.getMonth()+1)},_getStaticTitle:function(e){switch(e=e||{},!(BI.isNull(e.year)||BI.isEmptyString(e.year))<<1|!(BI.isNull(e.month)||BI.isEmptyString(e.month))){case 0:return"";case 1:return e.month;case 2:return e.year;case 3:default:return e.year+"-"+e.month}},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e)},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e)},setValue:function(e){var t,n,i=BI.getDate();switch(this.storeValue=e,BI.isNotNull(e)&&(t=e.type||BI.DynamicDateCombo.Static,n=e.value||e),t){case BI.DynamicDateCombo.Dynamic:var r=this._getText(n);i=BI.DynamicDateHelper.getCalculation(n),this._setInnerValue(i,r);break;case BI.DynamicDateCombo.Static:default:n=n||{};var a=BI.isNull(n.month)?null:n.month;this.yearEditor.setValue(n.year),this.monthEditor.setValue(a)}},getValue:function(){return this.storeValue},getKey:function(){return this.yearEditor.getValue()+"-"+this.monthEditor.getValue()},isStateValid:function(){return this.yearEditor.isValid()&&this.monthEditor.isValid()}}),BI.DynamicYearMonthTrigger.EVENT_VALID="EVENT_VALID",BI.DynamicYearMonthTrigger.EVENT_FOCUS="EVENT_FOCUS",BI.DynamicYearMonthTrigger.EVENT_ERROR="EVENT_ERROR",BI.DynamicYearMonthTrigger.EVENT_START="EVENT_START",BI.DynamicYearMonthTrigger.EVENT_CONFIRM="EVENT_CONFIRM",BI.DynamicYearMonthTrigger.EVENT_STOP="EVENT_STOP",BI.DynamicYearMonthTrigger.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.shortcut("bi.dynamic_year_month_trigger",BI.DynamicYearMonthTrigger)},function(e,t){BI.YearMonthInterval=BI.inherit(BI.Single,{constants:{height:24,width:25,lgap:15,offset:-15,timeErrorCls:"time-error"},props:{extraCls:"bi-year-month-interval",minDate:"1900-01-01",maxDate:"2099-12-31",supportDynamic:!0},_init:function(){var e=this,t=this.options;BI.YearMonthInterval.superclass._init.apply(this,arguments),t.value=t.value||{},this.left=this._createCombo(t.value.start),this.right=this._createCombo(t.value.end),this.label=BI.createWidget({type:"bi.label",height:this.constants.height,width:this.constants.width,text:"-"}),BI.createWidget({element:e,type:"bi.center",hgap:15,height:this.constants.height,items:[{type:"bi.absolute",items:[{el:e.left,left:this.constants.offset,right:0,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:e.right,left:0,right:this.constants.offset,top:0,bottom:0}]}]}),BI.createWidget({type:"bi.horizontal_auto",element:this,items:[e.label]})},_createCombo:function(e){var t=this,n=this.options,i=BI.createWidget({type:"bi.dynamic_year_month_combo",supportDynamic:n.supportDynamic,minDate:n.minDate,maxDate:n.maxDate,behaviors:n.behaviors,value:e,listeners:[{eventName:BI.DynamicYearMonthCombo.EVENT_BEFORE_POPUPVIEW,action:function(){t.fireEvent(BI.YearMonthInterval.EVENT_BEFORE_POPUPVIEW)}}]});return i.on(BI.DynamicYearMonthCombo.EVENT_ERROR,(function(){t._clearTitle(),BI.Bubbles.hide("error"),t.element.removeClass(t.constants.timeErrorCls),t.fireEvent(BI.YearMonthInterval.EVENT_ERROR)})),i.on(BI.DynamicYearMonthCombo.EVENT_VALID,(function(){t._checkValid()})),i.on(BI.DynamicYearMonthCombo.EVENT_FOCUS,(function(){t._checkValid()})),i.on(BI.DynamicYearMonthCombo.EVENT_CONFIRM,(function(){BI.Bubbles.hide("error");var e=t.left.getKey(),n=t.right.getKey();t.left.isStateValid()&&t.right.isStateValid()&&t._check(e,n)&&t._compare(e,n)?(t._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),t.element.addClass(t.constants.timeErrorCls),t.fireEvent(BI.YearMonthInterval.EVENT_ERROR)):(t._clearTitle(),t.element.removeClass(t.constants.timeErrorCls),t.fireEvent(BI.YearMonthInterval.EVENT_CHANGE))})),i},_dateCheck:function(e){return BI.print(BI.parseDateTime(e,"%Y-%x"),"%Y-%x")===e||BI.print(BI.parseDateTime(e,"%Y-%X"),"%Y-%X")===e},_checkVoid:function(e){var t=this.options;return!BI.checkDateVoid(e.year,e.month,1,t.minDate,t.maxDate)[0]},_check:function(e,t){var n=e.match(/\d+/g),i=t.match(/\d+/g),r="";BI.isNotNull(n)&&(r=(n[0]||"")+"-"+(n[1]||1));var a="";return BI.isNotNull(i)&&(a=(i[0]||"")+"-"+(i[1]||1)),this._dateCheck(r)&&BI.checkDateLegal(r)&&this._checkVoid({year:n[0],month:n[1]||1,day:1})&&this._dateCheck(a)&&BI.checkDateLegal(a)&&this._checkVoid({year:i[0],month:i[1]||1,day:1})},_compare:function(e,t){return e=BI.print(BI.parseDateTime(e,"%Y-%X"),"%Y-%X"),t=BI.print(BI.parseDateTime(t,"%Y-%X"),"%Y-%X"),BI.isNotNull(e)&&BI.isNotNull(t)&&e>t},_setTitle:function(e){this.setTitle(e)},_clearTitle:function(){this.setTitle("")},_checkValid:function(){var e=this;BI.Bubbles.hide("error");var t=e.left.getKey(),n=e.right.getKey();e.left.isValid()&&e.right.isValid()&&e._check(t,n)&&e._compare(t,n)?(e._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),e.element.addClass(e.constants.timeErrorCls),BI.Bubbles.show("error",BI.i18nText("BI-Time_Interval_Error_Text"),e,{offsetStyle:"center"}),e.fireEvent(BI.YearMonthInterval.EVENT_ERROR)):(e._clearTitle(),e.element.removeClass(e.constants.timeErrorCls))},setMinDate:function(e){this.options.minDate=e,this.left.setMinDate(e),this.right.setMinDate(e)},setMaxDate:function(e){this.options.maxDate=e,this.left.setMaxDate(e),this.right.setMaxDate(e)},setValue:function(e){e=e||{},this.left.setValue(e.start),this.right.setValue(e.end),this._checkValid()},getValue:function(){return{start:this.left.getValue(),end:this.right.getValue()}}}),BI.YearMonthInterval.EVENT_VALID="EVENT_VALID",BI.YearMonthInterval.EVENT_ERROR="EVENT_ERROR",BI.YearMonthInterval.EVENT_CHANGE="EVENT_CHANGE",BI.YearMonthInterval.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.year_month_interval",BI.YearMonthInterval)},function(e,t){BI.DynamicYearQuarterCard=BI.inherit(BI.Widget,{props:{baseCls:"bi-year-quarter-card"},render:function(){var e=this;return{type:"bi.vertical",items:[{type:"bi.label",text:BI.i18nText("BI-Multi_Date_Relative_Current_Time"),textAlign:"left",height:BI.SIZE_CONSANTS.LIST_ITEM_HEIGHT},{type:"bi.vertical",ref:function(t){e.wrapper=t},items:[{el:{type:"bi.dynamic_date_param_item",validationChecker:BI.bind(e._checkDate,e),ref:function(){e.year=this},listeners:[{eventName:"EVENT_CHANGE",action:function(){e.fireEvent("EVENT_CHANGE")}},{eventName:"EVENT_INPUT_CHANGE",action:function(){BI.Bubbles.hide("dynamic-year-quarter-error")}}]},bgap:10},{type:"bi.dynamic_date_param_item",dateType:BI.DynamicDateCard.TYPE.QUARTER,ref:function(){e.quarter=this},listeners:[{eventName:"EVENT_CHANGE",action:function(){e.fireEvent("EVENT_CHANGE")}},{eventName:"EVENT_INPUT_CHANGE",action:function(){BI.Bubbles.hide("dynamic-year-quarter-error")}}]}]}],vgap:10,hgap:10}},_getErrorText:function(){var e=this.options,t=BI.parseDateTime(e.min,"%Y-%X-%d"),n=BI.parseDateTime(e.max,"%Y-%X-%d");return BI.i18nText("BI-Basic_Year_Quarter_Range_Error",t.getFullYear(),BI.getQuarter(t),n.getFullYear(),BI.getQuarter(n))},_checkDate:function(e){var t=this.options,n=BI.DynamicDateHelper.getCalculation(BI.extend(this._getValue(),this._digestDateTypeValue(e)));return!BI.checkDateVoid(n.getFullYear(),n.getMonth()+1,n.getDate(),t.min,t.max)[0]},_digestDateTypeValue:function(e){var t={};switch(e.dateType){case BI.DynamicDateCard.TYPE.YEAR:t.year=0===e.offset?-e.value:+e.value;break;case BI.DynamicDateCard.TYPE.QUARTER:t.quarter=0===e.offset?-e.value:+e.value}return t},_createValue:function(e,t){return{dateType:e,value:Math.abs(t),offset:t>0?1:0}},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e)},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e)},setValue:function(e){e=e||{year:0,quarter:0},this.year.setValue(this._createValue(BI.DynamicDateCard.TYPE.YEAR,e.year)),this.quarter.setValue(this._createValue(BI.DynamicDateCard.TYPE.QUARTER,e.quarter))},_getValue:function(){var e=this.year.getValue(),t=this.quarter.getValue();return{year:0===e.offset?-e.value:e.value,quarter:0===t.offset?-t.value:t.value}},getInputValue:function(){return this._getValue()},getValue:function(){return this.checkValidation()?this._getValue():{}},checkValidation:function(e){var t,n=!this.year.checkValidation(),i=!this.quarter.checkValidation(),r=n||i;return r?t=BI.i18nText("BI-Please_Input_Natural_Number"):(r=!this._checkDate(this._getValue()),t=this._getErrorText()),r&&e&&BI.Bubbles.show("dynamic-year-quarter-error",t,this.wrapper),!r}}),BI.DynamicYearQuarterCard.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.dynamic_year_quarter_card",BI.DynamicYearQuarterCard)},function(e,t){BI.StaticYearQuarterCard=BI.inherit(BI.Widget,{props:{baseCls:"bi-static-year-quarter-card",behaviors:{}},_createQuarter:function(){var e=this,t=[{text:BI.Date._QN[1],value:1},{text:BI.Date._QN[2],value:2},{text:BI.Date._QN[3],value:3},{text:BI.Date._QN[4],value:4}];return BI.map(t,(function(t,n){return BI.extend(n,{type:"bi.text_item",cls:"bi-list-item-select",textAlign:"center",whiteSpace:"nowrap",once:!1,forceSelected:!0,height:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT,ref:function(n){e.quarterMap[t+1]=n}})}))},render:function(){var e=this,t=this.options;return this.quarterMap={},{type:"bi.vertical",items:[{type:"bi.year_picker",cls:"bi-split-bottom",ref:function(){e.yearPicker=this},min:t.min,max:t.max,behaviors:t.behaviors,height:30,listeners:[{eventName:BI.YearPicker.EVENT_CHANGE,action:function(){var t=this.getValue();e._checkQuarterStatus(t),e.setValue({year:t,quarter:e.selectedQuarter})}}]},{el:{type:"bi.button_group",behaviors:t.behaviors,ref:function(){e.quarter=this},items:this._createQuarter(),layouts:[{type:"bi.vertical",vgap:10}],value:t.value,listeners:[{eventName:BI.ButtonGroup.EVENT_CHANGE,action:function(){e.selectedYear=e.yearPicker.getValue(),e.selectedQuarter=this.getValue()[0],e.fireEvent(BI.StaticYearQuarterCard.EVENT_CHANGE)}}]},vgap:5}]}},_checkQuarterStatus:function(e){var t=this.options,n=BI.parseDateTime(t.min,"%Y-%X-%d"),i=BI.parseDateTime(t.max,"%Y-%X-%d"),r=n.getFullYear(),a=i.getFullYear(),o=1,s=4;r===e&&(o=BI.parseInt(BI.getQuarter(n))),a===e&&(s=BI.parseInt(BI.getQuarter(i)));var l=e<r||e>a;BI.each(this.quarterMap,(function(e,t){var n=e<o||e>s;t.setEnable(!l&&!n)}))},setMinDate:function(e){this.options.min!==e&&(this.options.min=e,this.yearPicker.setMinDate(e),this._checkQuarterStatus(this.selectedYear))},setMaxDate:function(e){this.options.max!==e&&(this.options.max=e,this.yearPicker.setMaxDate(e),this._checkQuarterStatus(this.selectedYear))},getValue:function(){return{year:this.selectedYear,quarter:this.selectedQuarter}},setValue:function(e){var t=this.options,n={};if(n.year=e.year||0,n.quarter=e.quarter||0,0===n.quarter||0===n.year||BI.checkDateVoid(n.year,n.quarter,1,t.min,t.max)[0]){var i=n.year||BI.getDate().getFullYear();this.selectedYear=i,this.selectedQuarter="",this.yearPicker.setValue(i),this.quarter.setValue()}else this.selectedYear=BI.parseInt(n.year),this.selectedQuarter=BI.parseInt(n.quarter),this.yearPicker.setValue(this.selectedYear),this.quarter.setValue(this.selectedQuarter);this._checkQuarterStatus(this.selectedYear)}}),BI.StaticYearQuarterCard.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.static_year_quarter_card",BI.StaticYearQuarterCard)},function(e,t){BI.DynamicYearQuarterCombo=BI.inherit(BI.Widget,{props:{baseCls:"bi-year-quarter-combo bi-border bi-border-radius bi-focus-shadow",behaviors:{},minDate:"1900-01-01",maxDate:"2099-12-31",height:24,supportDynamic:!0},_init:function(){var e=this,t=this.options;t.height-=2,BI.isNumeric(t.width)&&(t.width-=2),BI.DynamicYearQuarterCombo.superclass._init.apply(this,arguments),this.storeValue=t.value,e.storeTriggerValue="",this.trigger=BI.createWidget({type:"bi.dynamic_year_quarter_trigger",min:t.minDate,max:t.maxDate,height:t.height,value:t.value||""}),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_KEY_DOWN,(function(){e.combo.isViewVisible()&&e.combo.hideView()})),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_START,(function(){e.combo.isViewVisible()&&e.combo.hideView()})),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_STOP,(function(){e.combo.showView()})),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_ERROR,(function(){e.combo.isViewVisible()&&e.combo.hideView(),e.fireEvent(BI.DynamicYearQuarterCombo.EVENT_ERROR)})),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_VALID,(function(){e.fireEvent(BI.DynamicYearMonthCombo.EVENT_VALID)})),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_CONFIRM,(function(){var t=e.storeTriggerValue,n=e.trigger.getKey();BI.isEqual(n,t)||(BI.isNotEmptyString(n)&&!BI.isEqual(n,t)&&(e.storeValue=e.trigger.getValue(),e.setValue(e.trigger.getValue())),e._checkDynamicValue(e.storeValue),e.fireEvent(BI.DynamicYearQuarterCombo.EVENT_CONFIRM))})),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_FOCUS,(function(){e.storeTriggerValue=e.trigger.getKey(),e.fireEvent(BI.DynamicYearQuarterCombo.EVENT_FOCUS)})),this.combo=BI.createWidget({type:"bi.combo",container:t.container,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,el:this.trigger,destroyWhenHide:!0,adjustLength:1,popup:{minWidth:85,stopPropagation:!1,el:{type:"bi.dynamic_year_quarter_popup",supportDynamic:t.supportDynamic,ref:function(){e.popup=this},listeners:[{eventName:BI.DynamicYearQuarterPopup.EVENT_CHANGE,action:function(){e.setValue(e.popup.getValue()),e.combo.hideView(),e.fireEvent(BI.DynamicYearQuarterCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearQuarterPopup.BUTTON_CLEAR_EVENT_CHANGE,action:function(){e.setValue(),e.combo.hideView(),e.fireEvent(BI.DynamicYearQuarterCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearQuarterPopup.BUTTON_lABEL_EVENT_CHANGE,action:function(){var t=BI.getDate();e.setValue({type:BI.DynamicYearMonthCombo.Static,value:{year:t.getFullYear(),quarter:BI.getQuarter(t)}}),e.combo.hideView(),e.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearQuarterPopup.BUTTON_OK_EVENT_CHANGE,action:function(){var t=e.popup.getValue();e._checkValue(t)&&e.setValue(t),e.combo.hideView(),e.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}}],behaviors:t.behaviors,min:t.minDate,max:t.maxDate},value:t.value||""}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,(function(){e.popup.setMinDate(t.minDate),e.popup.setMaxDate(t.maxDate),e.popup.setValue(e.storeValue),e.fireEvent(BI.DynamicYearQuarterCombo.EVENT_BEFORE_POPUPVIEW)})),BI.createWidget({type:"bi.htape",element:this,ref:function(){e.comboWrapper=this},items:[{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button date-change-h-font",width:24,height:24,ref:function(){e.changeIcon=this}},width:24},this.combo]}),this._checkDynamicValue(t.value)},_checkDynamicValue:function(e){var t=null;switch(BI.isNotNull(e)&&(t=e.type),t){case BI.DynamicYearQuarterCombo.Dynamic:this.changeIcon.setVisible(!0),this.comboWrapper.attr("items")[0].width=24,this.comboWrapper.resize();break;default:this.comboWrapper.attr("items")[0].width=0,this.comboWrapper.resize(),this.changeIcon.setVisible(!1)}},_checkValue:function(e){var t=this.options;switch(e.type){case BI.DynamicDateCombo.Dynamic:return BI.isNotEmptyObject(e.value);case BI.DynamicDateCombo.Static:var n=e.value||{};return!BI.checkDateVoid(n.year,3*(n.quarter-1)+1,1,t.minDate,t.maxDate)[0];default:return!0}},setMinDate:function(e){this.options.minDate=e,this.trigger.setMinDate(e),this.popup&&this.popup.setMinDate(e)},setMaxDate:function(e){this.options.maxDate=e,this.trigger.setMaxDate(e),this.popup&&this.popup.setMaxDate(e)},hideView:function(){this.combo.hideView()},getKey:function(){return this.trigger.getKey()},setValue:function(e){this.storeValue=e,this.trigger.setValue(e),this._checkDynamicValue(e)},getValue:function(){return this.storeValue},isStateValid:function(){return this.trigger.isStateValid()}}),BI.DynamicYearQuarterCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.DynamicYearQuarterCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.DynamicYearQuarterCombo.EVENT_ERROR="EVENT_ERROR",BI.DynamicYearQuarterCombo.EVENT_VALID="EVENT_VALID",BI.DynamicYearQuarterCombo.EVENT_FOCUS="EVENT_FOCUS",BI.shortcut("bi.dynamic_year_quarter_combo",BI.DynamicYearQuarterCombo),BI.extend(BI.DynamicYearQuarterCombo,{Static:1,Dynamic:2})},function(e,t){BI.DynamicYearQuarterPopup=BI.inherit(BI.Widget,{constants:{tabHeight:30,buttonHeight:24},props:{baseCls:"bi-year-quarter-popup",behaviors:{},min:"1900-01-01",max:"2099-12-31",width:180,supportDynamic:!0},render:function(){var e=this;this.options,this.constants;return this.storeValue={type:BI.DynamicYearQuarterCombo.Static},{type:"bi.vertical",items:[{el:this._getTabJson()},{el:{type:"bi.grid",items:[[{type:"bi.text_button",cls:"bi-split-top bi-high-light",shadow:!0,textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,text:BI.i18nText("BI-Basic_Clear"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicYearQuarterPopup.BUTTON_CLEAR_EVENT_CHANGE)}}]},{type:"bi.text_button",cls:"bi-split-left bi-split-right bi-high-light bi-split-top",textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,shadow:!0,text:BI.i18nText("BI-Basic_Current_Quarter"),disabled:this._checkTodayValid(),ref:function(){e.textButton=this},listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicYearQuarterPopup.BUTTON_lABEL_EVENT_CHANGE)}}]},{type:"bi.text_button",cls:"bi-split-top bi-high-light",shadow:!0,textHeight:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT-1,text:BI.i18nText("BI-Basic_OK"),listeners:[{eventName:BI.TextButton.EVENT_CHANGE,action:function(){e.dateTab.getSelect()===BI.DynamicDateCombo.Dynamic?e.dynamicPane.checkValidation(!0)&&e.fireEvent(BI.DynamicDatePopup.BUTTON_OK_EVENT_CHANGE):e.fireEvent(BI.DynamicYearQuarterPopup.BUTTON_OK_EVENT_CHANGE)}}]}]],height:BI.SIZE_CONSANTS.TOOL_BAR_HEIGHT}}]}},_setInnerValue:function(){if(this.dateTab.getSelect()===BI.DynamicYearQuarterCombo.Static)this.textButton.setValue(BI.i18nText("BI-Basic_Current_Quarter")),this.textButton.setEnable(!this._checkTodayValid());else{var e=BI.DynamicDateHelper.getCalculation(this.dynamicPane.getInputValue());e=BI.print(e,"%Y-%Q"),this.textButton.setValue(e),this.textButton.setEnable(!1)}},_checkTodayValid:function(){var e=this.options,t=BI.getDate();return!!BI.checkDateVoid(t.getFullYear(),t.getMonth()+1,t.getDate(),e.min,e.max)[0]},_getTabJson:function(){var e=this,t=this.options;return{type:"bi.tab",logic:{dynamic:!0},ref:function(){e.dateTab=this},tab:{type:"bi.linear_segment",cls:"bi-split-bottom",invisible:!t.supportDynamic,height:this.constants.tabHeight,items:BI.createItems([{text:BI.i18nText("BI-Basic_Year_Quarter"),value:BI.DynamicYearQuarterCombo.Static},{text:BI.i18nText("BI-Basic_Dynamic_Title"),value:BI.DynamicYearQuarterCombo.Dynamic}],{textAlign:"center"})},cardCreator:function(n){switch(n){case BI.DynamicYearQuarterCombo.Dynamic:return{type:"bi.dynamic_year_quarter_card",cls:"dynamic-year-quarter-pane",min:e.options.min,max:e.options.max,listeners:[{eventName:"EVENT_CHANGE",action:function(){e._setInnerValue(e.year,n)}}],ref:function(){e.dynamicPane=this}};case BI.DynamicYearQuarterCombo.Static:default:return{type:"bi.static_year_quarter_card",behaviors:t.behaviors,min:e.options.min,max:e.options.max,listeners:[{eventName:BI.DynamicYearCard.EVENT_CHANGE,action:function(){e.fireEvent(BI.DynamicYearQuarterPopup.EVENT_CHANGE)}}],ref:function(){e.year=this}}}},listeners:[{eventName:BI.Tab.EVENT_CHANGE,action:function(){switch(e.dateTab.getSelect()){case BI.DynamicYearQuarterCombo.Static:var t=BI.DynamicDateHelper.getCalculation(e.dynamicPane.getValue());e.year.setValue({year:t.getFullYear(),quarter:BI.getQuarter(t)}),e._setInnerValue();break;case BI.DynamicYearQuarterCombo.Dynamic:default:e.storeValue&&e.storeValue.type===BI.DynamicYearQuarterCombo.Dynamic?e.dynamicPane.setValue(e.storeValue.value):e.dynamicPane.setValue({year:0}),e._setInnerValue()}}}]}},setMinDate:function(e){this.options.min!==e&&(this.options.min=e,this.year&&this.year.setMinDate(e),this.dynamicPane&&this.dynamicPane.setMinDate(e))},setMaxDate:function(e){this.options.max!==e&&(this.options.max=e,this.year&&this.year.setMaxDate(e),this.dynamicPane&&this.dynamicPane.setMaxDate(e))},setValue:function(e){this.storeValue=e;var t,n;switch(t=(e=e||{}).type||BI.DynamicDateCombo.Static,n=e.value||e,this.dateTab.setSelect(t),t){case BI.DynamicDateCombo.Dynamic:this.dynamicPane.setValue(n),this._setInnerValue();break;case BI.DynamicDateCombo.Static:default:this.year.setValue(n),this.textButton.setValue(BI.i18nText("BI-Basic_Current_Quarter")),this.textButton.setEnable(!this._checkTodayValid())}},getValue:function(){return{type:this.dateTab.getSelect(),value:this.dateTab.getValue()}}}),BI.DynamicYearQuarterPopup.BUTTON_CLEAR_EVENT_CHANGE="BUTTON_CLEAR_EVENT_CHANGE",BI.DynamicYearQuarterPopup.BUTTON_lABEL_EVENT_CHANGE="BUTTON_lABEL_EVENT_CHANGE",BI.DynamicYearQuarterPopup.BUTTON_OK_EVENT_CHANGE="BUTTON_OK_EVENT_CHANGE",BI.DynamicYearQuarterPopup.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.dynamic_year_quarter_popup",BI.DynamicYearQuarterPopup)},function(e,t){BI.DynamicYearQuarterTrigger=BI.inherit(BI.Trigger,{_const:{hgap:4,vgap:2},props:{extraCls:"bi-year-quarter-trigger",min:"1900-01-01",max:"2099-12-31",height:24},_init:function(){BI.DynamicYearQuarterTrigger.superclass._init.apply(this,arguments);var e=this.options;this.yearEditor=this._createEditor(!0),this.quarterEditor=this._createEditor(!1);var t=e.height+2;BI.createWidget({element:this,type:"bi.htape",items:[{type:"bi.center",items:[{type:"bi.htape",items:[this.yearEditor,{el:{type:"bi.text_button",text:BI.i18nText("BI-Multi_Date_Year"),width:t},width:t}]},{type:"bi.htape",items:[this.quarterEditor,{el:{type:"bi.text_button",text:BI.i18nText("BI-Multi_Date_Quarter"),width:t},width:t}]}]},{el:{type:"bi.trigger_icon_button",width:t},width:t}]}),this.setValue(e.value)},_createEditor:function(e){var t=this,n=this.options,i=this._const,r=BI.createWidget({type:"bi.sign_editor",height:n.height,validationChecker:function(i){if(e)return""===i||BI.isPositiveInteger(i)&&!BI.checkDateVoid(i,parseInt(i,10)===BI.parseDateTime(n.min,"%Y-%X-%d").getFullYear()?BI.parseDateTime(n.min,"%Y-%X-%d").getMonth()+1:1,1,n.min,n.max)[0];var r=t.yearEditor.getValue();return""===i||BI.isPositiveInteger(i)&&i>=1&&i<=4&&(!!BI.isEmptyString(r)||!BI.checkDateVoid(t.yearEditor.getValue(),3*(i-1)+1,1,n.min,n.max)[0])},quitChecker:function(){return!1},errorText:function(i){var r=e?i:t.yearEditor.getValue(),a=e?t.quarterEditor.getValue():i;if(!BI.isPositiveInteger(r)||!BI.isPositiveInteger(a)||a>4)return BI.i18nText("BI-Year_Trigger_Invalid_Text");var o=BI.parseDateTime(n.min,"%Y-%X-%d"),s=BI.parseDateTime(n.max,"%Y-%X-%d");return BI.i18nText("BI-Basic_Year_Quarter_Range_Error",o.getFullYear(),BI.getQuarter(o),s.getFullYear(),BI.getQuarter(s))},watermark:BI.i18nText("BI-Basic_Unrestricted"),hgap:i.hgap,vgap:i.vgap,allowBlank:!0});return r.on(BI.SignEditor.EVENT_KEY_DOWN,(function(){t.fireEvent(BI.DynamicYearQuarterTrigger.EVENT_KEY_DOWN)})),r.on(BI.SignEditor.EVENT_FOCUS,(function(){t.fireEvent(BI.DynamicYearQuarterTrigger.EVENT_FOCUS)})),r.on(BI.SignEditor.EVENT_STOP,(function(){t.fireEvent(BI.DynamicYearQuarterTrigger.EVENT_STOP)})),r.on(BI.SignEditor.EVENT_CONFIRM,(function(){t._doEditorConfirm(r),t.fireEvent(BI.DynamicYearQuarterTrigger.EVENT_CONFIRM)})),r.on(BI.SignEditor.EVENT_SPACE,(function(){r.isValid()&&r.blur()})),r.on(BI.SignEditor.EVENT_START,(function(){t.fireEvent(BI.DynamicYearQuarterTrigger.EVENT_START)})),r.on(BI.SignEditor.EVENT_ERROR,(function(){t.fireEvent(BI.DynamicYearQuarterTrigger.EVENT_ERROR)})),r.on(BI.SignEditor.EVENT_VALID,(function(){var e=t.yearEditor.getValue(),i=t.quarterEditor.getValue();BI.isNotEmptyString(e)&&BI.isNotEmptyString(i)&&BI.isPositiveInteger(e)&&i>=1&&i<=4&&!BI.checkDateVoid(e,3*(i-1)+1,1,n.min,n.max)[0]&&t.fireEvent(BI.DynamicYearMonthTrigger.EVENT_VALID)})),r.on(BI.SignEditor.EVENT_CHANGE,(function(){e&&t._autoSwitch(r)})),r},_doEditorConfirm:function(e){var t=e.getValue();BI.isNotNull(t)&&e.setValue(t);var n=this.quarterEditor.getValue();this.storeValue={type:BI.DynamicYearQuarterCombo.Static,value:{year:this.yearEditor.getValue(),quarter:BI.isEmptyString(this.quarterEditor.getValue())?"":n}},this.setTitle(this._getStaticTitle(this.storeValue.value))},_yearCheck:function(e){var t=BI.print(BI.parseDateTime(e,"%Y-%X-%d"),"%Y-%X-%d");return BI.print(BI.parseDateTime(e,"%Y"),"%Y")===e&&t>=this.options.min&&t<=this.options.max},_autoSwitch:function(e){var t=e.getValue();BI.isNotEmptyString(t)&&BI.checkDateLegal(t)&&4===t.length&&this._yearCheck(t)&&(this._doEditorConfirm(e),this.fireEvent(BI.DynamicYearQuarterTrigger.EVENT_CONFIRM),this.quarterEditor.focus())},_getStaticTitle:function(e){switch(e=e||{},!(BI.isNull(e.year)||BI.isEmptyString(e.year))<<1|!(BI.isNull(e.quarter)||BI.isEmptyString(e.quarter))){case 0:return"";case 1:return e.quarter;case 2:return e.year;case 3:default:return e.year+"-"+e.quarter}},_getText:function(e){var t="";return BI.isNotNull(e.year)&&0!==BI.parseInt(e.year)&&(t+=Math.abs(e.year)+BI.i18nText("BI-Basic_Year")+(e.year<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),BI.isNotNull(e.quarter)&&0!==BI.parseInt(e.quarter)&&(t+=Math.abs(e.quarter)+BI.i18nText("BI-Basic_Single_Quarter")+(e.quarter<0?BI.i18nText("BI-Basic_Front"):BI.i18nText("BI-Basic_Behind"))),t},_setInnerValue:function(e,t){var n=BI.print(e,"%Y-%Q");this.yearEditor.setValue(e.getFullYear()),this.quarterEditor.setValue(BI.getQuarter(e)),this.setTitle(BI.isEmptyString(t)?n:t+":"+n)},setMinDate:function(e){BI.isNotEmptyString(this.options.min)&&(this.options.min=e)},setMaxDate:function(e){BI.isNotEmptyString(this.options.max)&&(this.options.max=e)},setValue:function(e){var t,n,i=BI.getDate();switch(this.storeValue=e,BI.isNotNull(e)&&(t=e.type||BI.DynamicYearQuarterCombo.Static,n=e.value||e),t){case BI.DynamicYearQuarterCombo.Dynamic:var r=this._getText(n);i=BI.DynamicDateHelper.getCalculation(n),this._setInnerValue(i,r);break;case BI.DynamicYearQuarterCombo.Static:default:n=n||{};var a=BI.isNull(n.quarter)?null:n.quarter;this.yearEditor.setValue(n.year),this.yearEditor.setTitle(n.year),this.quarterEditor.setValue(a),this.quarterEditor.setTitle(a),this.setTitle(this._getStaticTitle(n))}},getValue:function(){return this.storeValue},getKey:function(){return this.yearEditor.getValue()+"-"+this.quarterEditor.getValue()},isStateValid:function(){return this.yearEditor.isValid()&&this.quarterEditor.isValid()}}),BI.DynamicYearQuarterTrigger.EVENT_FOCUS="EVENT_FOCUS",BI.DynamicYearQuarterTrigger.EVENT_ERROR="EVENT_ERROR",BI.DynamicYearQuarterTrigger.EVENT_START="EVENT_START",BI.DynamicYearQuarterTrigger.EVENT_CONFIRM="EVENT_CONFIRM",BI.DynamicYearQuarterTrigger.EVENT_STOP="EVENT_STOP",BI.DynamicYearQuarterTrigger.EVENT_KEY_DOWN="EVENT_KEY_DOWN",BI.DynamicYearQuarterTrigger.EVENT_VALID="EVENT_VALID",BI.shortcut("bi.dynamic_year_quarter_trigger",BI.DynamicYearQuarterTrigger)},function(e,t){BI.YearQuarterInterval=BI.inherit(BI.Single,{constants:{height:24,width:25,lgap:15,offset:-15,timeErrorCls:"time-error"},props:{extraCls:"bi-year-quarter-interval",minDate:"1900-01-01",maxDate:"2099-12-31",supportDynamic:!0},render:function(){var e=this,t=this.options;return t.value=t.value||{},this.left=this._createCombo(t.value.start),this.right=this._createCombo(t.value.end),[{type:"bi.center",hgap:15,height:this.constants.height,items:[{type:"bi.absolute",items:[{el:e.left,left:this.constants.offset,right:0,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:e.right,left:0,right:this.constants.offset,top:0,bottom:0}]}]},{type:"bi.horizontal_auto",items:[{type:"bi.label",height:this.constants.height,width:this.constants.width,text:"-",ref:function(t){e.label=t}}]}]},_createCombo:function(e){var t=this,n=this.options,i=BI.createWidget({type:"bi.dynamic_year_quarter_combo",supportDynamic:n.supportDynamic,minDate:n.minDate,maxDate:n.maxDate,behaviors:n.behaviors,value:e,listeners:[{eventName:BI.DynamicYearQuarterCombo.EVENT_BEFORE_POPUPVIEW,action:function(){t.fireEvent(BI.YearQuarterInterval.EVENT_BEFORE_POPUPVIEW)}}]});return i.on(BI.DynamicYearQuarterCombo.EVENT_ERROR,(function(){t._clearTitle(),BI.Bubbles.hide("error"),t.element.removeClass(t.constants.timeErrorCls),t.fireEvent(BI.YearQuarterInterval.EVENT_ERROR)})),i.on(BI.DynamicYearQuarterCombo.EVENT_VALID,(function(){t._checkValid()})),i.on(BI.DynamicYearQuarterCombo.EVENT_FOCUS,(function(){t._checkValid()})),i.on(BI.DynamicYearQuarterCombo.EVENT_CONFIRM,(function(){BI.Bubbles.hide("error");var e=t.left.getKey(),n=t.right.getKey();t.left.isStateValid()&&t.right.isStateValid()&&t._check(e,n)&&t._compare(e,n)?(t._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),t.element.addClass(t.constants.timeErrorCls),t.fireEvent(BI.YearQuarterInterval.EVENT_ERROR)):(t._clearTitle(),t.element.removeClass(t.constants.timeErrorCls),t.fireEvent(BI.YearQuarterInterval.EVENT_CHANGE))})),i},_dateCheck:function(e){return BI.print(BI.parseDateTime(e,"%Y-%Q"),"%Y-%Q")===e||BI.print(BI.parseDateTime(e,"%Y-%q"),"%Y-%q")===e},_checkVoid:function(e){var t=this.options;return!BI.checkDateVoid(e.year,3*(e.quarter-1)+1,1,t.minDate,t.maxDate)[0]},_check:function(e,t){var n=e.match(/\d+/g),i=t.match(/\d+/g),r="";BI.isNotNull(n)&&(r=(n[0]||"")+"-"+(n[1]||1));var a="";return BI.isNotNull(i)&&(a=(i[0]||"")+"-"+(i[1]||1)),this._dateCheck(r)&&BI.checkDateLegal(r)&&this._checkVoid({year:n[0],quarter:n[1]||1})&&this._dateCheck(a)&&BI.checkDateLegal(a)&&this._checkVoid({year:i[0],quarter:i[1]||1})},_compare:function(e,t){return e=BI.print(BI.parseDateTime(e,"%Y-%Q"),"%Y-%Q"),t=BI.print(BI.parseDateTime(t,"%Y-%Q"),"%Y-%Q"),BI.isNotNull(e)&&BI.isNotNull(t)&&e>t},_setTitle:function(e){this.setTitle(e)},_clearTitle:function(){this.setTitle("")},_checkValid:function(){var e=this;BI.Bubbles.hide("error");var t=e.left.getKey(),n=e.right.getKey();e.left.isValid()&&e.right.isValid()&&e._check(t,n)&&e._compare(t,n)?(e._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),e.element.addClass(e.constants.timeErrorCls),BI.Bubbles.show("error",BI.i18nText("BI-Time_Interval_Error_Text"),e,{offsetStyle:"center"}),e.fireEvent(BI.YearQuarterInterval.EVENT_ERROR)):(e._clearTitle(),e.element.removeClass(e.constants.timeErrorCls))},setMinDate:function(e){this.options.minDate=e,this.left.setMinDate(e),this.right.setMinDate(e)},setMaxDate:function(e){this.options.maxDate=e,this.left.setMaxDate(e),this.right.setMaxDate(e)},setValue:function(e){e=e||{},this.left.setValue(e.start),this.right.setValue(e.end),this._checkValid()},getValue:function(){return{start:this.left.getValue(),end:this.right.getValue()}}}),BI.YearQuarterInterval.EVENT_VALID="EVENT_VALID",BI.YearQuarterInterval.EVENT_ERROR="EVENT_ERROR",BI.YearQuarterInterval.EVENT_CHANGE="EVENT_CHANGE",BI.YearQuarterInterval.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.year_quarter_interval",BI.YearQuarterInterval)},function(e,t){BI.AbstractAllValueChooser=BI.inherit(BI.Widget,{_const:{perPage:100},_defaultConfig:function(){return BI.extend(BI.AbstractAllValueChooser.superclass._defaultConfig.apply(this,arguments),{width:200,height:30,items:null,itemsCreator:BI.emptyFn,cache:!0})},_valueFormatter:function(e){var t=e;return BI.isNotNull(this.items)&&BI.some(this.items,(function(n,i){if(i.value===e||i.value+""===e)return t=i.text,!0})),t},_itemsCreator:function(e,t){var n=this,i=this.options;function r(n){var i=(e.keywords||[]).slice();e.keyword&&i.push(e.keyword);var r=n;if(BI.isNotEmptyArray(i)&&(r=[],BI.each(i,(function(e,t){var i=BI.Func.getSearchResult(n,t);r=r.concat(i.match).concat(i.find)})),r=BI.uniq(r)),e.selectedValues){var a=BI.makeObject(e.selectedValues,!0);r=BI.filter(r,(function(e,t){return!a[t.value]}))}e.type!==BI.MultiSelectCombo.REQ_GET_ALL_DATA?e.type!==BI.MultiSelectCombo.REQ_GET_DATA_LENGTH?t({items:r,hasNext:!1}):t({count:r.length}):t({items:r})}i.cache&&this.items?r(this.items):i.itemsCreator({},(function(e){n.items=e,r(e)}))},_assertValue:function(e){var t=e=e||{};BI.isNotNull(this.items)&&(0===BI.difference(BI.map(this.items,"value"),e.value).length&&(t={type:BI.Selection.All,value:[]}));return t}})},function(e,t){BI.AllValueChooserCombo=BI.inherit(BI.AbstractAllValueChooser,{_defaultConfig:function(){return BI.extend(BI.AllValueChooserCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-all-value-chooser-combo",width:200,height:24,items:null,itemsCreator:BI.emptyFn,cache:!0})},_init:function(){BI.AllValueChooserCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;BI.isNotNull(t.items)&&(this.items=t.items),this.combo=BI.createWidget({type:"bi.multi_select_combo",text:t.text,element:this,itemsCreator:BI.bind(this._itemsCreator,this),valueFormatter:BI.bind(this._valueFormatter,this),width:t.width,height:t.height,value:this._assertValue({type:BI.Selection.Multi,value:t.value||[]})}),this.combo.on(BI.MultiSelectCombo.EVENT_CONFIRM,(function(){e.fireEvent(BI.AllValueChooserCombo.EVENT_CONFIRM)}))},setValue:function(e){this.combo.setValue(this._assertValue({type:BI.Selection.Multi,value:e||[]}))},getValue:function(){return this.getAllValue()},getAllValue:function(){var e=this.combo.getValue()||{};return e.type===BI.Selection.Multi?e.value||[]:BI.difference(BI.map(this.items,"value"),e.value||[])},populate:function(e){BI.isNotNull(e)&&(this.items=e),this.combo.populate()}}),BI.AllValueChooserCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.shortcut("bi.all_value_chooser_combo",BI.AllValueChooserCombo)},function(e,t){BI.AllValueChooserPane=BI.inherit(BI.AbstractAllValueChooser,{_defaultConfig:function(){return BI.extend(BI.AllValueChooserPane.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-all-value-chooser-pane",width:200,height:30,items:null,itemsCreator:BI.emptyFn,cache:!0})},_init:function(){BI.AllValueChooserPane.superclass._init.apply(this,arguments);var e=this,t=this.options;this.list=BI.createWidget({type:"bi.multi_select_list",element:this,itemsCreator:BI.bind(this._itemsCreator,this),valueFormatter:BI.bind(this._valueFormatter,this),width:t.width,height:t.height}),this.list.on(BI.MultiSelectList.EVENT_CHANGE,(function(){e.fireEvent(BI.AllValueChooserPane.EVENT_CHANGE)})),BI.isNotNull(t.items)&&(this.items=t.items,this.list.populate())},setValue:function(e){this.list.setValue({type:BI.Selection.Multi,value:e||[]})},getValue:function(){var e=this.list.getValue()||{};return e.type===BI.Selection.All?e.assist:e.value||[]},populate:function(e){BI.isNotNull(e)&&(this.items=e),this.list.populate()}}),BI.AllValueChooserPane.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.all_value_chooser_pane",BI.AllValueChooserPane)},function(e,t){BI.AllValueMultiTextValueCombo=BI.inherit(BI.Widget,{props:{baseCls:"bi-all-value-multi-text-value-combo",width:200,height:24,items:[]},render:function(){var e=this,t=this.options,n=this._digestValue(t.value);return{type:"bi.search_multi_text_value_combo",text:t.text,height:t.height,items:t.items,value:n,numOfPage:100,valueFormatter:t.valueFormatter,warningTitle:t.warningTitle,listeners:[{eventName:BI.SearchMultiTextValueCombo.EVENT_CONFIRM,action:function(){e.fireEvent(BI.AllValueMultiTextValueCombo.EVENT_CONFIRM)}}],ref:function(){e.combo=this}}},setValue:function(e){var t=this._digestValue(e);this.combo.setValue(t)},getValue:function(){var e=this.combo.getValue()||{};if(e.value=e.value||[],e.type===BI.Selection.All){var t=[];return BI.each(this.options.items,(function(n,i){!BI.contains(e.value,i.value)&&t.push(i.value)})),t}return e.value||[]},populate:function(e){this.options.items=e,this.combo.populate.apply(this.combo,arguments)},_digestValue:function(e){return{type:BI.Selection.Multi,value:e||[]}}}),BI.AllValueMultiTextValueCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.shortcut("bi.all_value_multi_text_value_combo",BI.AllValueMultiTextValueCombo)},function(e,t){BI.AbstractTreeValueChooser=BI.inherit(BI.Widget,{_const:{perPage:100},_defaultConfig:function(){return BI.extend(BI.AbstractTreeValueChooser.superclass._defaultConfig.apply(this,arguments),{items:null,itemsCreator:BI.emptyFn,open:!1})},_valueFormatter:function(e){var t=e;return BI.isNotNull(this.items)&&BI.some(this.items,(function(n,i){if(i.value===e||i.value+""===e)return t=i.text,!0})),t},_initData:function(e){this.items=e;var t=BI.Tree.treeFormat(e);this.tree=new BI.Tree,this.tree.initTree(t)},_itemsCreator:function(e,t){var n=this,i=this.options;function r(){switch(e.type){case BI.TreeView.REQ_TYPE_INIT_DATA:n._reqInitTreeNode(e,t);break;case BI.TreeView.REQ_TYPE_ADJUST_DATA:n._reqAdjustTreeNode(e,t);break;case BI.TreeView.REQ_TYPE_SELECT_DATA:n._reqSelectedTreeNode(e,t);break;case BI.TreeView.REQ_TYPE_GET_SELECTED_DATA:n._reqDisplayTreeNode(e,t);break;default:n._reqTreeNode(e,t)}}this.items?r():i.itemsCreator({},(function(e){n._initData(e),r()}))},_reqDisplayTreeNode:function(e,t){var n=this,i=[],r=e.selectedValues;function a(e,t,n){i.push({id:e.id,pId:t,text:e.text+(n>0?"("+BI.i18nText("BI-Basic_Altogether")+n+BI.i18nText("BI-Basic_Count")+")":""),value:e.value,open:!0})}null==r||BI.isEmpty(r)?t({}):(!function o(e,t,i){if(null==i||BI.isEmpty(i))return void BI.each(t.getChildren(),(function(i,r){var s=BI.clone(e);s.push(r.value);var l=n._getChildCount(s);a(r,t.id,l),o(s,r,{})}));BI.each(i,(function(t){var r=n._getTreeNode(e,t);if(BI.isNull(r))a({id:BI.UUID(),text:t,value:t},BI.UUID(),0);else{var s=BI.clone(e);s.push(r.value),a(r,r.parent&&r.parent.id,function(e,t){if(null==e)return 0;if(BI.isEmpty(e))return n._getChildCount(t);return BI.size(e)}(i[t],s)),o(s,r,i[t])}}))}([],this.tree.getRoot(),r),t({items:i}))},_reqSelectedTreeNode:function(e,t){var n=this,i=BI.deepClone(e.selectedValues),r=e.notSelectedValue||{},a=e.keyword||"",o=e.parentValues||[];function s(e,t,i){var r=e,a=[],o=[];BI.some(t,(function(s,l){var u=r[l];if(null==u){if(0===s)return!0;if(!BI.isEmpty(r))return!0;var c=t.slice(0,s),h=n._getChildren(c);if(o.push(c),a.push(h.length),s===t.length-1&&1===h.length&&h[0].value===i)for(var p=a.length-1;p>=0&&1===a[p];p--)n._deleteNode(e,o[p]);else BI.each(h,(function(e,n){if(s===t.length-1&&n.value===i)return!0;r[n.value]={}}));r=r[l]}else r=u}))}function l(e,t,i,r){var o=BI.clone(e);if(o.push(t),n._isMatch(e,t,a))return r&&r.push(o),!0;var s=n._getChildren(o),u=[],c=!1;return BI.each(s,(function(e,t){l(o,t.value,i,r)?c=!0:u.push(t.value)})),!0===c&&BI.each(u,(function(e,t){var n=BI.clone(o);n.push(t),i.push(n)})),c}function u(e){for(var t=0,i=e.length;t<i;t++)if(n._isMatch(e.slice(0,t),e[t],a))return!0;return!1}null==i||BI.isEmpty(i)?t({}):(!function(e){var t=o.concat(r);if(function(e,t){for(var n=e,i=0;i<t.length;i++){if(null==(n=n[t[i]]))return!1}return!0}(e,t))if(u(t))n._deleteNode(e,t);else{var i=[];(c=l(o,r,[],i))&&BI.isNotEmptyArray(i)&&BI.each(i,(function(t,i){n._getNode(e,i)?n._deleteNode(e,i):s(e,i,BI.last(i))}))}if(function(e,t){for(var n=e,i=0;i<t.length;i++){var r=t[i];if(!BI.has(n,r))return!1;if(n=n[r],BI.isEmpty(n))return!0}return!1}(e,t)){var a=[],c=!1;u(t)?c=!0:(c=l(o,r,a),t=o),!0===c&&(s(e,t,r),a.length>0&&BI.each(a,(function(t,i){n._buildTree(e,i)})))}}(i),t(i))},_reqAdjustTreeNode:function(e,t){var n=this,i=[],r=e.selectedValues;if(null==r||BI.isEmpty(r))t({});else{BI.each(r,(function(e,t){i.push([e])})),function e(t,r){if(null==t||BI.isEmpty(t))return!0;var a=!0;return BI.each(t,(function(n,o){var s=BI.clone(r);s.push(n),e(t[n],s)||(BI.each(t[n],(function(e,t){var n=BI.clone(s);n.push(e),i.push(n)})),a=!1)})),a&&function(e,t){return BI.isEmpty(e)||n._getChildCount(t)===BI.size(e)}(t,r)}(r,[]);var a={};BI.each(i,(function(e,t){n._buildTree(a,t)})),t(a)}},_reqInitTreeNode:function(e,t){var n=this,i=[],r=e.keyword||"",a=e.selectedValues,o=e.lastSearchValue||"",s=function(){var t=n._getChildren([]),s=t.length;if(""!==o){for(var u=0,c=s;u<c;u++)if(t[u].value===o){s=u+1;break}}else s=0;var h=[],p=s;for(c=t.length;p<c;p++){if(h.length<n._const.perPage)var d=l(1,[],t[p].value,!1,i);else if(h.length===n._const.perPage)d=l(1,[],t[p].value,!1,[]);if(!0===d[0]&&h.push(t[p].value),h.length>n._const.perPage)break}if(1===e.times){var f=n._getAddedValueNode([],a);i=BI.concat(BI.filter(f,(function(e,t){var n=BI.Func.getSearchResult([t.text||t.value],r);return n.find.length>0||n.match.length>0})),i)}return h}();function l(e,t,i,a,o){if(n._isMatch(t,i,r))return u(t,i,!1,f=a||c(t,i),!a&&function(e,t){var n=h(e);if(null==n)return null;return BI.any(n,(function(e,n){if(e===t&&null!=n&&!BI.isEmpty(n))return!0}))}(t,i),!0,o),[!0,f];var s=BI.clone(t);s.push(i);var p=n._getChildren(s),d=!1,f=!1,g=a||function(e,t){var n=h(e);if(null==n)return null;return BI.any(n,(function(e,n){if(e===t&&null!=n&&BI.isEmpty(n))return!0}))}(t,i);return BI.each(p,(function(t,n){var i=l(e+1,s,n.value,g,o);!0===i[1]&&(f=!0),!0===i[0]&&(d=!0)})),!0===d&&u(t,i,!0,f=g||c(t,i)&&f,!1,!1,o),[d,f]}function u(e,t,i,r,a,o,s){var l=n._getTreeNode(e,t);s.push({id:l.id,pId:l.pId,text:l.text,value:l.value,title:l.title,isParent:l.getChildrenLength()>0,open:i,checked:r,halfCheck:a,flag:o})}function c(e,t){var n=h(e);return null!=n&&BI.any(n,(function(e){if(e===t)return!0}))}function h(e){var t=a;return null==t?null:(BI.every(e,(function(e,n){return null!=(t=t[n])})),t)}BI.nextTick((function(){t({hasNext:s.length>n._const.perPage,items:i,lastSearchValue:BI.last(s)})}))},_reqTreeNode:function(e,t){var n,i=this,r=this.options,a=[],o=e.times,s=e.checkState||{},l=e.parentValues||[],u=e.selectedValues||{};n=f(l,u);for(var c=this._getChildren(l),h=(o-1)*this._const.perPage;c[h]&&h<o*this._const.perPage;h++){var p=m(c[h].value,l,n,s);a.push({id:c[h].id,pId:c[h].pId,value:c[h].value,text:c[h].text,times:1,isParent:c[h].getChildrenLength()>0,checked:p[0],halfCheck:p[1],open:r.open})}if(r.open){var d=[];BI.each(c,(function(e,t){d=BI.concat(d,i._getAllChildren(l.concat([t.value])))})),BI.each(d,(function(e,t){var n=f(t.parentValues,u),r={},o=BI.find(a,(function(e,n){return n.id===t.pId}));o&&(r.checked=!o.halfCheck&&o.checked,r.half=o.halfCheck);var s=m(t.value,t.parentValues,n,r);a.push({id:t.id,pId:t.pId,value:t.value,text:t.text,times:1,isParent:t.getChildrenLength()>0,checked:s[0],halfCheck:s[1],open:i.options.open})}))}function f(e,t){var n={},i=(e||[]).slice(0);return BI.each(e,(function(e,n){i.push(n),t=t[n]||{}})),BI.each(t,(function(e,t){var r=BI.concat(i,e);if(BI.isNull(t))n[e]=[0,0];else if(BI.isEmpty(t))n[e]=[2,0];else{var a={};BI.each(t,(function(e,t){(BI.isNull(t)||BI.isEmpty(t)||g(t,BI.concat(r,[e])))&&(a[e]=!0)})),n[e]=[1,BI.size(a)]}})),n}function g(e,t){return!!BI.isEmpty(e)||i._getChildCount(t)===BI.size(e)&&BI.every(e,(function(n){return g(e[n],BI.concat(t,n))}))}function m(e,t,n,r){var a=r.checked,o=r.half,s=!1,l=!1;if(BI.has(n,e))if(1===n[e][0]){var u=BI.clone(t);u.push(e);var c=i._getChildCount(u);c>0&&c!==n[e][1]&&(l=!0)}else 2===n[e][0]&&(s=!0);return[(a||l||s)&&(s||a)&&!o||BI.has(n,e),l]}0===l.length&&1===o&&(a=BI.concat(i._getAddedValueNode(l,u),a)),BI.nextTick((function(){t({items:a,hasNext:c.length>o*i._const.perPage})}))},_getAddedValueNode:function(e,t){var n=this._getChildren(e);return BI.map(BI.difference(BI.keys(t),BI.map(n,"value")),(function(e,t){return{id:BI.UUID(),pId:n.length>0?n[0].pId:BI.UUID(),value:t,text:t,times:1,isParent:!1,checked:!0,halfCheck:!1}}))},_getNode:function(e,t){for(var n=e,i=0,r=t.length;i<r;i++){if(null==n)return null;n=n[t[i]]}return n},_deleteNode:function(e,t){var n=t[t.length-1],i=t.slice(0,t.length-1),r=this._getNode(e,i);if(null!=r&&r[n])for(delete r[n];i.length>0&&BI.isEmpty(r);)n=i[i.length-1],i=i.slice(0,i.length-1),null!=(r=this._getNode(e,i))&&delete r[n]},_buildTree:function(e,t){var n=e;BI.each(t,(function(e,t){BI.has(n,t)||(n[t]={}),n=n[t]}))},_isMatch:function(e,t,n){var i=this.options,r=this._getTreeNode(e,t);if(!r)return!1;var a=BI.Func.getSearchResult([r.text||r.value],n);if(i.allowSearchValue&&r.value){var o=BI.Func.getSearchResult([r.value],n);return o.find.length>0||o.match.length>0||a.find.length>0||a.match.length>0}return a.find.length>0||a.match.length>0},_getTreeNode:function(e,t){var n,i=this,r=0,a=this.tree.getRoot();return this.tree.traverse((function(o){if(!i.tree.isRoot(o)){if(r>e.length)return!1;if(r===e.length&&o.value===t){if(o.getParent()!==a)return;return n=o,!1}return o.value!==e[r]||o.getParent()!==a||(r++,void(a=o))}})),n},_getChildren:function(e){if(e.length>0)var t=BI.last(e),n=this._getTreeNode(e.slice(0,e.length-1),t);else n=this.tree.getRoot();return n?n.getChildren():[]},_getAllChildren:function(e){var t=this._getChildren(e),n=[].concat(t);BI.each(n,(function(t,n){n.parentValues=e}));for(var i=BI.map(t,(function(t,n){return{parentValues:e,value:n.value}}));BI.isNotEmptyArray(i);){var r=i.shift(),a=r.parentValues.concat(r.value),o=this._getChildren(a);BI.each(o,(function(e,t){t.parentValues=a})),i=i.concat(o),n=n.concat(o)}return n},_getChildCount:function(e){return this._getChildren(e).length},buildCompleteTree:function(e){var t=this,n={};return null===e||BI.isEmpty(e)||function i(e,n,r,a){if(null===r||BI.isEmpty(r))return void BI.each(n.getChildren(),(function(t,n){var r=BI.clone(e);r.push(n.value),a[n.value]={},i(r,n,null,a[n.value])}));BI.each(r,(function(n){var o=t._getTreeNode(e,n),s=BI.clone(e);s.push(o.value),a[n]={},i(s,o,r[n],a[n])}))}([],this.tree.getRoot(),e,n),n}})},function(e,t){BI.AbstractListTreeValueChooser=BI.inherit(BI.AbstractTreeValueChooser,{_reqDisplayTreeNode:function(e,t){var n,i=this,r={},a=e.selectedValues;null==a||BI.isEmpty(a)?t({}):(this.tree.getRoot(),n=a,BI.each(n,(function(e,t){BI.each(t,(function(e,n){var a=n,s=i._getTreeNode(t.slice(0,e),a);BI.isNull(s)?o({id:BI.UUID(),text:a,value:a,isLeaf:!0},BI.UUID()):(BI.has(r,s.id)||o(s,s.parent&&s.parent.id),!0!==r[s.id].isLeaf&&(r[s.id].isLeaf=e===t.length-1))}))})),t({items:BI.values(r)}));function o(e,t){r[e.id]={id:e.id,pId:t,text:e.text,value:e.value,open:!0,isLeaf:e.isLeaf}}},_reqInitTreeNode:function(e,t){var n=this,i=[],r=e.keyword||"",a=e.selectedValues,o=e.lastSearchValue||"",s=function(){var t=n._getChildren([]),s=t.length;if(""!==o){for(var u=0,c=s;u<c;u++)if(t[u].value===o){s=u+1;break}}else s=0;var h=[],p=s;for(c=t.length;p<c;p++){if(h.length<n._const.perPage)var d=l(1,[],t[p].value,i);else if(h.length===n._const.perPage)d=l(1,[],t[p].value,[]);if(!0===d[0]&&h.push(t[p].value),h.length>n._const.perPage)break}if(1===e.times){var f=n._getAddedValueNode([],a);i=BI.concat(BI.filter(f,(function(e,t){var n=BI.Func.getSearchResult([t.text||t.value],r);return n.find.length>0||n.match.length>0})),i)}return h}();function l(e,t,i,a){if(n._isMatch(t,i,r))return u(t,i,!1,p=c(t,i),!0,a),[!0,p];var o=BI.clone(t);o.push(i);var s=n._getChildren(o),h=!1,p=!1;return BI.each(s,(function(t,n){var i=l(e+1,o,n.value,a);!0===i[1]&&(p=!0),!0===i[0]&&(h=!0)})),!0===h&&u(t,i,!0,p=c(t,i),!1,a),[h,p]}function u(e,t,i,r,a,o){var s=n._getTreeNode(e,t);o.push({id:s.id,pId:s.pId,text:s.text,value:s.value,title:s.title,isParent:s.getChildrenLength()>0,open:i,checked:r,halfCheck:!1,flag:a})}function c(e,t){return BI.any(a,(function(n,i){return BI.isEqual(e,i.slice(0,e.length))&&BI.last(i)===t}))}BI.nextTick((function(){t({hasNext:s.length>n._const.perPage,items:i,lastSearchValue:BI.last(s)})}))},_reqTreeNode:function(e,t){for(var n=this,i=this.options,r=[],a=e.times,o=e.parentValues||[],s=e.selectedValues||[],l=d(o,s),u=this._getChildren(o),c=(a-1)*this._const.perPage;u[c]&&c<a*this._const.perPage;c++){var h=BI.has(l,u[c].value);r.push({id:u[c].id,pId:u[c].pId,value:u[c].value,text:u[c].text,times:1,isParent:u[c].getChildrenLength()>0,checked:h,halfCheck:!1,open:i.open})}if(i.open){var p=[];BI.each(u,(function(e,t){p=BI.concat(p,n._getAllChildren(o.concat([t.value])))})),BI.each(p,(function(e,t){var n=d(t.parentValues,s),a=BI.has(n,t.value);r.push({id:t.id,pId:t.pId,value:t.value,text:t.text,times:1,isParent:t.getChildrenLength()>0,checked:a,halfCheck:!1,open:i.open})}))}function d(e,t){var n={};return BI.each(t,(function(t,i){BI.isEqual(e,i.slice(0,e.length))&&(n[BI.last(i)]=[2,0])})),n}0===o.length&&1===a&&(r=BI.concat(n._getAddedValueNode(o,s),r)),BI.nextTick((function(){t({items:r,hasNext:u.length>a*n._const.perPage})}))},_getAddedValueNode:function(e,t){var n=this._getChildren(e),i=BI.flatten(BI.filter(t,(function(e,t){return 1===t.length})));return BI.map(BI.difference(i,BI.map(n,"value")),(function(e,t){return{id:BI.UUID(),pId:n.length>0?n[0].pId:BI.UUID(),value:t,text:t,times:1,isParent:!1,checked:!0,halfCheck:!1}}))}})},function(e,t){BI.ListTreeValueChooserInsertCombo=BI.inherit(BI.AbstractListTreeValueChooser,{_defaultConfig:function(){return BI.extend(BI.ListTreeValueChooserInsertCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-list-tree-value-chooser-insert-combo",width:200,height:24,items:null,itemsCreator:BI.emptyFn,isNeedAdjustWidth:!0})},_init:function(){BI.ListTreeValueChooserInsertCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;BI.isNotNull(t.items)&&this._initData(t.items),this.combo=BI.createWidget({type:"bi.multi_tree_list_combo",isNeedAdjustWidth:t.isNeedAdjustWidth,element:this,text:t.text,value:t.value,watermark:t.watermark,allowInsertValue:t.allowInsertValue,allowEdit:t.allowEdit,itemsCreator:BI.bind(this._itemsCreator,this),valueFormatter:BI.bind(this._valueFormatter,this),width:t.width,height:t.height,listeners:[{eventName:BI.MultiTreeListCombo.EVENT_FOCUS,action:function(){e.fireEvent(BI.ListTreeValueChooserInsertCombo.EVENT_FOCUS)}},{eventName:BI.MultiTreeListCombo.EVENT_BLUR,action:function(){e.fireEvent(BI.ListTreeValueChooserInsertCombo.EVENT_BLUR)}},{eventName:BI.MultiTreeListCombo.EVENT_STOP,action:function(){e.fireEvent(BI.ListTreeValueChooserInsertCombo.EVENT_STOP)}},{eventName:BI.MultiTreeListCombo.EVENT_CLICK_ITEM,action:function(t){e.fireEvent(BI.ListTreeValueChooserInsertCombo.EVENT_CLICK_ITEM,t)}},{eventName:BI.MultiTreeListCombo.EVENT_SEARCHING,action:function(){e.fireEvent(BI.ListTreeValueChooserInsertCombo.EVENT_SEARCHING)}},{eventName:BI.MultiTreeListCombo.EVENT_CONFIRM,action:function(){e.fireEvent(BI.ListTreeValueChooserInsertCombo.EVENT_CONFIRM)}},{eventName:BI.MultiTreeCombo.EVENT_BEFORE_POPUPVIEW,action:function(){e.fireEvent(BI.TreeValueChooserInsertCombo.EVENT_BEFORE_POPUPVIEW)}}]})},showView:function(){this.combo.showView()},hideView:function(){this.combo.hideView()},getSearcher:function(){return this.combo.getSearcher()},setValue:function(e){this.combo.setValue(e)},getValue:function(){return this.combo.getValue()},populate:function(e){BI.isNotNull(e)&&this._initData(e),this.combo.populate()}}),BI.ListTreeValueChooserInsertCombo.EVENT_FOCUS="EVENT_FOCUS",BI.ListTreeValueChooserInsertCombo.EVENT_BLUR="EVENT_BLUR",BI.ListTreeValueChooserInsertCombo.EVENT_STOP="EVENT_STOP",BI.ListTreeValueChooserInsertCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.ListTreeValueChooserInsertCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.ListTreeValueChooserInsertCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.ListTreeValueChooserInsertCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.list_tree_value_chooser_insert_combo",BI.ListTreeValueChooserInsertCombo)},function(e,t){BI.TreeValueChooserInsertCombo=BI.inherit(BI.AbstractTreeValueChooser,{_defaultConfig:function(){return BI.extend(BI.TreeValueChooserInsertCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-tree-value-chooser-insert-combo",width:200,height:24,items:null,itemsCreator:BI.emptyFn,isNeedAdjustWidth:!0})},_init:function(){BI.TreeValueChooserInsertCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;BI.isNotNull(t.items)&&this._initData(t.items),this.combo=BI.createWidget({type:"bi.multi_tree_insert_combo",isNeedAdjustWidth:t.isNeedAdjustWidth,allowEdit:t.allowEdit,text:t.text,value:t.value,watermark:t.watermark,element:this,itemsCreator:BI.bind(this._itemsCreator,this),valueFormatter:BI.bind(this._valueFormatter,this),width:t.width,height:t.height,listeners:[{eventName:BI.MultiTreeInsertCombo.EVENT_FOCUS,action:function(){e.fireEvent(BI.TreeValueChooserCombo.EVENT_FOCUS)}},{eventName:BI.MultiTreeInsertCombo.EVENT_BLUR,action:function(){e.fireEvent(BI.TreeValueChooserCombo.EVENT_BLUR)}},{eventName:BI.MultiTreeInsertCombo.EVENT_STOP,action:function(){e.fireEvent(BI.TreeValueChooserInsertCombo.EVENT_STOP)}},{eventName:BI.MultiTreeInsertCombo.EVENT_CLICK_ITEM,action:function(t){e.fireEvent(BI.TreeValueChooserInsertCombo.EVENT_CLICK_ITEM,t)}},{eventName:BI.MultiTreeInsertCombo.EVENT_SEARCHING,action:function(){e.fireEvent(BI.TreeValueChooserInsertCombo.EVENT_SEARCHING)}},{eventName:BI.MultiTreeInsertCombo.EVENT_CONFIRM,action:function(){e.fireEvent(BI.TreeValueChooserInsertCombo.EVENT_CONFIRM)}},{eventName:BI.MultiTreeCombo.EVENT_BEFORE_POPUPVIEW,action:function(){e.fireEvent(BI.TreeValueChooserInsertCombo.EVENT_BEFORE_POPUPVIEW)}}]})},showView:function(){this.combo.showView()},hideView:function(){this.combo.hideView()},getSearcher:function(){return this.combo.getSearcher()},setValue:function(e){this.combo.setValue(e)},getValue:function(){return this.combo.getValue()},populate:function(e){BI.isNotNull(e)&&this._initData(e),this.combo.populate()}}),BI.TreeValueChooserInsertCombo.EVENT_FOCUS="EVENT_FOCUS",BI.TreeValueChooserInsertCombo.EVENT_BLUR="EVENT_BLUR",BI.TreeValueChooserInsertCombo.EVENT_STOP="EVENT_STOP",BI.TreeValueChooserInsertCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.TreeValueChooserInsertCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.TreeValueChooserInsertCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.TreeValueChooserInsertCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.shortcut("bi.tree_value_chooser_insert_combo",BI.TreeValueChooserInsertCombo)},function(e,t){BI.TreeValueChooserCombo=BI.inherit(BI.AbstractTreeValueChooser,{_defaultConfig:function(){return BI.extend(BI.TreeValueChooserCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-tree-value-chooser-combo",width:200,height:24,items:null,itemsCreator:BI.emptyFn,isNeedAdjustWidth:!0})},_init:function(){BI.TreeValueChooserCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;BI.isNotNull(t.items)&&this._initData(t.items),this.combo=BI.createWidget({type:"bi.multi_tree_combo",text:t.text,allowEdit:t.allowEdit,value:t.value,watermark:t.watermark,element:this,itemsCreator:BI.bind(this._itemsCreator,this),valueFormatter:BI.bind(this._valueFormatter,this),width:t.width,height:t.height,isNeedAdjustWidth:t.isNeedAdjustWidth,listeners:[{eventName:BI.MultiTreeCombo.EVENT_FOCUS,action:function(){e.fireEvent(BI.TreeValueChooserCombo.EVENT_FOCUS)}},{eventName:BI.MultiTreeCombo.EVENT_BLUR,action:function(){e.fireEvent(BI.TreeValueChooserCombo.EVENT_BLUR)}},{eventName:BI.MultiTreeCombo.EVENT_STOP,action:function(){e.fireEvent(BI.TreeValueChooserCombo.EVENT_STOP)}},{eventName:BI.MultiTreeCombo.EVENT_CLICK_ITEM,action:function(t){e.fireEvent(BI.TreeValueChooserCombo.EVENT_CLICK_ITEM,t)}},{eventName:BI.MultiTreeCombo.EVENT_SEARCHING,action:function(){e.fireEvent(BI.TreeValueChooserCombo.EVENT_SEARCHING)}},{eventName:BI.MultiTreeCombo.EVENT_CONFIRM,action:function(){e.fireEvent(BI.TreeValueChooserCombo.EVENT_CONFIRM)}},{eventName:BI.MultiTreeCombo.EVENT_BEFORE_POPUPVIEW,action:function(){e.fireEvent(BI.TreeValueChooserCombo.EVENT_BEFORE_POPUPVIEW)}}]})},showView:function(){this.combo.showView()},hideView:function(){this.combo.hideView()},getSearcher:function(){return this.combo.getSearcher()},setValue:function(e){this.combo.setValue(e)},getValue:function(){return this.combo.getValue()},getAllValue:function(){return this.buildCompleteTree(this.combo.getValue())},populate:function(e){BI.isNotNull(e)&&this._initData(e),this.combo.populate()}}),BI.TreeValueChooserCombo.EVENT_BEFORE_POPUPVIEW="EVENT_BEFORE_POPUPVIEW",BI.TreeValueChooserCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.TreeValueChooserCombo.EVENT_FOCUS="EVENT_FOCUS",BI.TreeValueChooserCombo.EVENT_BLUR="EVENT_BLUR",BI.TreeValueChooserCombo.EVENT_STOP="EVENT_STOP",BI.TreeValueChooserCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.TreeValueChooserCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.shortcut("bi.tree_value_chooser_combo",BI.TreeValueChooserCombo)},function(e,t){BI.TreeValueChooserPane=BI.inherit(BI.AbstractTreeValueChooser,{_defaultConfig:function(){return BI.extend(BI.TreeValueChooserPane.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-tree-value-chooser-pane",items:null,itemsCreator:BI.emptyFn,showLine:!0})},_init:function(){BI.TreeValueChooserPane.superclass._init.apply(this,arguments);var e=this,t=this.options;this.pane=BI.createWidget({type:t.hideSearch?"bi.multi_select_tree_popup":"bi.multi_select_tree",element:this,showLine:t.showLine,itemsCreator:BI.bind(this._itemsCreator,this)}),this.pane.on(BI.MultiSelectTree.EVENT_CHANGE,(function(){e.fireEvent(BI.TreeValueChooserPane.EVENT_CHANGE)})),BI.isNotNull(t.items)&&(this._initData(t.items),this.pane.populate())},setSelectedValue:function(e){this.pane.setSelectedValue(e)},setValue:function(e){this.pane.setValue(e)},getValue:function(){return this.pane.getValue()},getAllValue:function(){return this.buildCompleteTree(this.pane.getValue())},populate:function(e){BI.isNotNull(e)&&this._initData(e),this.pane.populate()}}),BI.TreeValueChooserPane.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.tree_value_chooser_pane",BI.TreeValueChooserPane)},function(e,t){BI.AbstractValueChooser=BI.inherit(BI.Widget,{_const:{perPage:100},_defaultConfig:function(){return BI.extend(BI.AbstractValueChooser.superclass._defaultConfig.apply(this,arguments),{items:null,itemsCreator:BI.emptyFn,cache:!0})},_valueFormatter:function(e){var t=e;return BI.isNotNull(this.items)&&BI.some(this.items,(function(n,i){if(i.value===e||i.value+""===e)return t=i.text,!0})),t},_getItemsByTimes:function(e,t){for(var n=[],i=(t-1)*this._const.perPage;e[i]&&i<t*this._const.perPage;i++)n.push(e[i]);return n},_hasNextByTimes:function(e,t){return t*this._const.perPage<e.length},_itemsCreator:function(e,t){var n=this,i=this.options;function r(i){var r=(e.keywords||[]).slice(),a=i;if(BI.isNotEmptyArray(r)&&(a=[],BI.each(r,(function(e,t){var n=BI.Func.getSearchResult(i,t);a=a.concat(n.match).concat(n.find)})),a=BI.uniq(a)),e.selectedValues){var o=BI.makeObject(e.selectedValues,!0);a=BI.filter(a,(function(e,t){return!o[t.value]}))}e.type!==BI.MultiSelectCombo.REQ_GET_ALL_DATA?e.type!==BI.MultiSelectCombo.REQ_GET_DATA_LENGTH?t({items:n._getItemsByTimes(a,e.times),hasNext:n._hasNextByTimes(a,e.times)}):t({count:a.length}):t({items:a})}i.cache&&this.items?r(this.items):i.itemsCreator({},(function(e){n.items=e,r(e)}))},_assertValue:function(e){var t=e=e||{};e.type===BI.Selection.Multi&&BI.isNotNull(this.items)&&(0===BI.difference(BI.map(this.items,"value"),e.value).length&&(t={type:BI.Selection.All,value:[]}));return t}})},function(e,t){BI.ValueChooserInsertCombo=BI.inherit(BI.AbstractValueChooser,{_defaultConfig:function(){return BI.extend(BI.ValueChooserInsertCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-value-chooser-insert-combo",width:200,height:24,items:null,itemsCreator:BI.emptyFn,cache:!0})},_init:function(){BI.ValueChooserInsertCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;BI.isNotNull(t.items)&&(this.items=t.items),this.combo=BI.createWidget({type:"bi.multi_select_insert_combo",element:this,allowEdit:t.allowEdit,text:t.text,value:this._assertValue(t.value),itemsCreator:BI.bind(this._itemsCreator,this),valueFormatter:BI.bind(this._valueFormatter,this),width:t.width,height:t.height,listeners:[{eventName:BI.MultiSelectCombo.EVENT_FOCUS,action:function(){e.fireEvent(BI.ValueChooserInsertCombo.EVENT_FOCUS)}},{eventName:BI.MultiSelectCombo.EVENT_BLUR,action:function(){e.fireEvent(BI.ValueChooserInsertCombo.EVENT_BLUR)}},{eventName:BI.MultiSelectCombo.EVENT_STOP,action:function(){e.fireEvent(BI.ValueChooserInsertCombo.EVENT_STOP)}},{eventName:BI.MultiSelectCombo.EVENT_CLICK_ITEM,action:function(){e.fireEvent(BI.ValueChooserInsertCombo.EVENT_CLICK_ITEM)}},{eventName:BI.MultiSelectCombo.EVENT_SEARCHING,action:function(){e.fireEvent(BI.ValueChooserInsertCombo.EVENT_SEARCHING)}},{eventName:BI.MultiSelectCombo.EVENT_CONFIRM,action:function(){e.fireEvent(BI.ValueChooserInsertCombo.EVENT_CONFIRM)}}]})},setValue:function(e){this.combo.setValue(this._assertValue(e))},getValue:function(){var e=this.combo.getValue()||{};return{type:e.type,value:e.value}},getAllValue:function(){var e=this.combo.getValue()||{};return e.type===BI.Selection.Multi?e.value||[]:BI.difference(BI.map(this.items,"value"),e.value||[])},populate:function(e){BI.isNotNull(e)&&(this.items=e),this.combo.populate()}}),BI.ValueChooserInsertCombo.EVENT_BLUR="EVENT_BLUR",BI.ValueChooserInsertCombo.EVENT_FOCUS="EVENT_FOCUS",BI.ValueChooserInsertCombo.EVENT_STOP="EVENT_STOP",BI.ValueChooserInsertCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.ValueChooserInsertCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.ValueChooserInsertCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.shortcut("bi.value_chooser_insert_combo",BI.ValueChooserInsertCombo)},function(e,t){BI.ValueChooserCombo=BI.inherit(BI.AbstractValueChooser,{_defaultConfig:function(){return BI.extend(BI.ValueChooserCombo.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-value-chooser-combo",width:200,height:24,items:null,itemsCreator:BI.emptyFn,cache:!0})},_init:function(){BI.ValueChooserCombo.superclass._init.apply(this,arguments);var e=this,t=this.options;BI.isNotNull(t.items)&&(this.items=t.items),this.combo=BI.createWidget({type:"bi.multi_select_combo",element:this,allowEdit:t.allowEdit,text:t.text,value:this._assertValue(t.value),itemsCreator:BI.bind(this._itemsCreator,this),valueFormatter:BI.bind(this._valueFormatter,this),width:t.width,height:t.height,listeners:[{eventName:BI.MultiSelectCombo.EVENT_FOCUS,action:function(){e.fireEvent(BI.ValueChooserCombo.EVENT_FOCUS)}},{eventName:BI.MultiSelectCombo.EVENT_BLUR,action:function(){e.fireEvent(BI.ValueChooserCombo.EVENT_BLUR)}},{eventName:BI.MultiSelectCombo.EVENT_STOP,action:function(){e.fireEvent(BI.ValueChooserCombo.EVENT_STOP)}},{eventName:BI.MultiSelectCombo.EVENT_CLICK_ITEM,action:function(){e.fireEvent(BI.ValueChooserCombo.EVENT_CLICK_ITEM)}},{eventName:BI.MultiSelectCombo.EVENT_SEARCHING,action:function(){e.fireEvent(BI.ValueChooserCombo.EVENT_SEARCHING)}},{eventName:BI.MultiSelectCombo.EVENT_CONFIRM,action:function(){e.fireEvent(BI.ValueChooserCombo.EVENT_CONFIRM)}}]})},setValue:function(e){this.combo.setValue(this._assertValue(e))},getValue:function(){var e=this.combo.getValue()||{};return{type:e.type,value:e.value}},getAllValue:function(){var e=this.combo.getValue()||{};return e.type===BI.Selection.Multi?e.value||[]:BI.difference(BI.map(this.items,"value"),e.value||[])},populate:function(e){BI.isNotNull(e)&&(this.items=e),this.combo.populate()}}),BI.ValueChooserCombo.EVENT_BLUR="EVENT_BLUR",BI.ValueChooserCombo.EVENT_FOCUS="EVENT_FOCUS",BI.ValueChooserCombo.EVENT_STOP="EVENT_STOP",BI.ValueChooserCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.ValueChooserCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.ValueChooserCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.shortcut("bi.value_chooser_combo",BI.ValueChooserCombo)},function(e,t){BI.ValueChooserNoBarCombo=BI.inherit(BI.AbstractValueChooser,{props:{baseCls:"bi-value-chooser-combo",width:200,height:24,items:null,itemsCreator:BI.emptyFn,cache:!0},render:function(){var e=this,t=this.options;return BI.isNotNull(t.items)&&(this.items=t.items),{type:"bi.multi_select_no_bar_combo",allowEdit:t.allowEdit,text:t.text,value:this._assertValue(t.value),itemsCreator:BI.bind(this._itemsCreator,this),valueFormatter:BI.bind(this._valueFormatter,this),width:t.width,height:t.height,ref:function(t){e.combo=t},listeners:[{eventName:BI.MultiSelectCombo.EVENT_FOCUS,action:function(){e.fireEvent(BI.ValueChooserNoBarCombo.EVENT_FOCUS)}},{eventName:BI.MultiSelectCombo.EVENT_BLUR,action:function(){e.fireEvent(BI.ValueChooserNoBarCombo.EVENT_BLUR)}},{eventName:BI.MultiSelectCombo.EVENT_STOP,action:function(){e.fireEvent(BI.ValueChooserNoBarCombo.EVENT_STOP)}},{eventName:BI.MultiSelectCombo.EVENT_CLICK_ITEM,action:function(){e.fireEvent(BI.ValueChooserNoBarCombo.EVENT_CLICK_ITEM)}},{eventName:BI.MultiSelectCombo.EVENT_SEARCHING,action:function(){e.fireEvent(BI.ValueChooserNoBarCombo.EVENT_SEARCHING)}},{eventName:BI.MultiSelectCombo.EVENT_CONFIRM,action:function(){e.fireEvent(BI.ValueChooserNoBarCombo.EVENT_CONFIRM)}}]}},setValue:function(e){this.combo.setValue(e)},getValue:function(){return this.combo.getValue()},getAllValue:function(){return this.getValue()},populate:function(e){BI.isNotNull(e)&&(this.items=e),this.combo.populate()}}),BI.ValueChooserNoBarCombo.EVENT_BLUR="EVENT_BLUR",BI.ValueChooserNoBarCombo.EVENT_FOCUS="EVENT_FOCUS",BI.ValueChooserNoBarCombo.EVENT_STOP="EVENT_STOP",BI.ValueChooserNoBarCombo.EVENT_SEARCHING="EVENT_SEARCHING",BI.ValueChooserNoBarCombo.EVENT_CLICK_ITEM="EVENT_CLICK_ITEM",BI.ValueChooserNoBarCombo.EVENT_CONFIRM="EVENT_CONFIRM",BI.shortcut("bi.value_chooser_no_bar_combo",BI.ValueChooserNoBarCombo)},function(e,t){BI.ValueChooserPane=BI.inherit(BI.AbstractValueChooser,{_defaultConfig:function(){return BI.extend(BI.ValueChooserPane.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-value-chooser-pane",items:null,itemsCreator:BI.emptyFn,cache:!0})},_init:function(){BI.ValueChooserPane.superclass._init.apply(this,arguments);var e=this,t=this.options;this.list=BI.createWidget({type:"bi.multi_select_list",element:this,value:t.value,itemsCreator:BI.bind(this._itemsCreator,this),valueFormatter:BI.bind(this._valueFormatter,this)}),this.list.on(BI.MultiSelectList.EVENT_CHANGE,(function(){e.fireEvent(BI.ValueChooserPane.EVENT_CHANGE)})),BI.isNotNull(t.items)&&(this.items=t.items,this.list.populate())},setValue:function(e){this.list.setValue(e)},getValue:function(){var e=this.list.getValue()||{};return{type:e.type,value:e.value}},getAllValue:function(){var e=this.combo.getValue()||{};return e.type===BI.Selection.Multi?e.value||[]:BI.difference(BI.map(this.items,"value"),e.value||[])},populate:function(e){BI.isNotNull(e)&&(this.items=e),this.list.populate()}}),BI.ValueChooserPane.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.value_chooser_pane",BI.ValueChooserPane)},function(e,t,n){"use strict";var i=function(e){return e&&e.__esModule?e:{"default":e}}(n(709));BI.extend(BI,i["default"])},function(e,t,n){"use strict";function i(e){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"Combo",{enumerable:!0,get:function(){return r.Combo}}),Object.defineProperty(t,"ButtonGroup",{enumerable:!0,get:function(){return a.ButtonGroup}}),Object.defineProperty(t,"Tab",{enumerable:!0,get:function(){return o.Tab}}),Object.defineProperty(t,"Pane",{enumerable:!0,get:function(){return s.Pane}}),Object.defineProperty(t,"BasicButton",{enumerable:!0,get:function(){return l.BasicButton}}),Object.defineProperty(t,"NodeButton",{enumerable:!0,get:function(){return u.NodeButton}}),Object.defineProperty(t,"Button",{enumerable:!0,get:function(){return c.Button}}),Object.defineProperty(t,"TextButton",{enumerable:!0,get:function(){return h.TextButton}}),Object.defineProperty(t,"IconTextItem",{enumerable:!0,get:function(){return p.IconTextItem}}),Object.defineProperty(t,"Editor",{enumerable:!0,get:function(){return d.Editor}}),Object.defineProperty(t,"Iframe",{enumerable:!0,get:function(){return f.Iframe}}),Object.defineProperty(t,"Checkbox",{enumerable:!0,get:function(){return g.Checkbox}}),Object.defineProperty(t,"Input",{enumerable:!0,get:function(){return m.Input}}),Object.defineProperty(t,"AbstractLabel",{enumerable:!0,get:function(){return I.AbstractLabel}}),Object.defineProperty(t,"Label",{enumerable:!0,get:function(){return B.Label}}),Object.defineProperty(t,"Single",{enumerable:!0,get:function(){return _.Single}}),Object.defineProperty(t,"Text",{enumerable:!0,get:function(){return E.Text}}),Object.defineProperty(t,"Trigger",{enumerable:!0,get:function(){return b.Trigger}}),Object.defineProperty(t,"IconChangeButton",{enumerable:!0,get:function(){return y.IconChangeButton}}),Object.defineProperty(t,"MultiSelectItem",{enumerable:!0,get:function(){return v.MultiSelectItem}}),Object.defineProperty(t,"BubbleCombo",{enumerable:!0,get:function(){return T.BubbleCombo}}),Object.defineProperty(t,"TextValueCombo",{enumerable:!0,get:function(){return C.TextValueCombo}}),Object.defineProperty(t,"SmallTextValueCombo",{enumerable:!0,get:function(){return N.SmallTextValueCombo}}),Object.defineProperty(t,"SearchTextValueCombo",{enumerable:!0,get:function(){return V.SearchTextValueCombo}}),Object.defineProperty(t,"SignEditor",{enumerable:!0,get:function(){return S.SignEditor}}),Object.defineProperty(t,"StateEditor",{enumerable:!0,get:function(){return x.StateEditor}}),Object.defineProperty(t,"LoadingPane",{enumerable:!0,get:function(){return w.LoadingPane}}),Object.defineProperty(t,"AllValueMultiTextValueCombo",{enumerable:!0,get:function(){return A.AllValueMultiTextValueCombo}}),Object.defineProperty(t,"AbstractTreeValueChooser",{enumerable:!0,get:function(){return L.AbstractTreeValueChooser}}),Object.defineProperty(t,"AbstractListTreeValueChooser",{enumerable:!0,get:function(){return k.AbstractListTreeValueChooser}}),Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return D.Action}}),Object.defineProperty(t,"ActionFactory",{enumerable:!0,get:function(){return D.ActionFactory}}),Object.defineProperty(t,"ShowAction",{enumerable:!0,get:function(){return M.ShowAction}}),Object.defineProperty(t,"Behavior",{enumerable:!0,get:function(){return P.Behavior}}),Object.defineProperty(t,"BehaviorFactory",{enumerable:!0,get:function(){return P.BehaviorFactory}}),Object.defineProperty(t,"HighlightBehavior",{enumerable:!0,get:function(){return R.HighlightBehavior}}),Object.defineProperty(t,"RedMarkBehavior",{enumerable:!0,get:function(){return H.RedMarkBehavior}}),Object.defineProperty(t,"OB",{enumerable:!0,get:function(){return F.OB}}),Object.defineProperty(t,"Widget",{enumerable:!0,get:function(){return Y.Widget}}),Object.defineProperty(t,"Layout",{enumerable:!0,get:function(){return W.Layout}}),Object.defineProperty(t,"AbsoluteLayout",{enumerable:!0,get:function(){return G.AbsoluteLayout}}),Object.defineProperty(t,"HTapeLayout",{enumerable:!0,get:function(){return j.HTapeLayout}}),Object.defineProperty(t,"VTapeLayout",{enumerable:!0,get:function(){return j.VTapeLayout}}),Object.defineProperty(t,"VerticalLayout",{enumerable:!0,get:function(){return Z.VerticalLayout}}),Object.defineProperty(t,"DefaultLayout",{enumerable:!0,get:function(){return X.DefaultLayout}}),Object.defineProperty(t,"DownListCombo",{enumerable:!0,get:function(){return U.DownListCombo}}),Object.defineProperty(t,"Icon",{enumerable:!0,get:function(){return J.Icon}}),Object.defineProperty(t,"LeftVerticalAdaptLayout",{enumerable:!0,get:function(){return K.LeftVerticalAdaptLayout}}),Object.defineProperty(t,"LeftRightVerticalAdaptLayout",{enumerable:!0,get:function(){return z.LeftRightVerticalAdaptLayout}}),Object.defineProperty(t,"RightVerticalAdaptLayout",{enumerable:!0,get:function(){return z.RightVerticalAdaptLayout}}),Object.defineProperty(t,"IconTextIconItem",{enumerable:!0,get:function(){return Q.IconTextIconItem}}),Object.defineProperty(t,"HorizontalAutoLayout",{enumerable:!0,get:function(){return q.HorizontalAutoLayout}}),Object.defineProperty(t,"InlineVerticalAdaptLayout",{enumerable:!0,get:function(){return $.InlineVerticalAdaptLayout}}),Object.defineProperty(t,"TableAdaptLayout",{enumerable:!0,get:function(){return ee.TableAdaptLayout}}),Object.defineProperty(t,"IconButton",{enumerable:!0,get:function(){return te.IconButton}}),Object.defineProperty(t,"TextEditor",{enumerable:!0,get:function(){return ne.TextEditor}}),Object.defineProperty(t,"IconLabel",{enumerable:!0,get:function(){return ie.IconLabel}}),Object.defineProperty(t,"Popover",{enumerable:!0,get:function(){return re.Popover}}),Object.defineProperty(t,"BarPopover",{enumerable:!0,get:function(){return re.BarPopover}}),Object.defineProperty(t,"IconCombo",{enumerable:!0,get:function(){return ae.IconCombo}}),Object.defineProperty(t,"DynamicDateCombo",{enumerable:!0,get:function(){return oe.DynamicDateCombo}}),Object.defineProperty(t,"CustomTree",{enumerable:!0,get:function(){return se.CustomTree}}),Object.defineProperty(t,"ButtonTree",{enumerable:!0,get:function(){return le.ButtonTree}}),Object.defineProperty(t,"IconArrowNode",{enumerable:!0,get:function(){return ue.IconArrowNode}}),Object.defineProperty(t,"MidTreeLeafItem",{enumerable:!0,get:function(){return ce.MidTreeLeafItem}}),Object.defineProperty(t,"FirstTreeLeafItem",{enumerable:!0,get:function(){return he.FirstTreeLeafItem}}),Object.defineProperty(t,"LastTreeLeafItem",{enumerable:!0,get:function(){return pe.LastTreeLeafItem}}),Object.defineProperty(t,"SmallTextEditor",{enumerable:!0,get:function(){return de.SmallTextEditor}}),Object.defineProperty(t,"MultifileEditor",{enumerable:!0,get:function(){return fe.MultifileEditor}}),Object.defineProperty(t,"AbsoluteCenterLayout",{enumerable:!0,get:function(){return ge.AbsoluteCenterLayout}}),Object.defineProperty(t,"HorizontalAdaptLayout",{enumerable:!0,get:function(){return me.HorizontalAdaptLayout}}),Object.defineProperty(t,"FloatLeftLayout",{enumerable:!0,get:function(){return Ie.FloatLeftLayout}}),Object.defineProperty(t,"FloatRightLayout",{enumerable:!0,get:function(){return Ie.FloatRightLayout}}),Object.defineProperty(t,"CenterAdaptLayout",{enumerable:!0,get:function(){return Be.CenterAdaptLayout}}),Object.defineProperty(t,"VerticalAdaptLayout",{enumerable:!0,get:function(){return _e.VerticalAdaptLayout}}),Object.defineProperty(t,"MultiSelectInsertCombo",{enumerable:!0,get:function(){return Ee.MultiSelectInsertCombo}}),Object.defineProperty(t,"MultiSelectCombo",{enumerable:!0,get:function(){return be.MultiSelectCombo}}),Object.defineProperty(t,"SearchEditor",{enumerable:!0,get:function(){return ye.SearchEditor}}),Object.defineProperty(t,"MultiLayerSingleLevelTree",{enumerable:!0,get:function(){return ve.MultiLayerSingleLevelTree}}),Object.defineProperty(t,"SimpleColorChooser",{enumerable:!0,get:function(){return Te.SimpleColorChooser}}),Object.defineProperty(t,"A",{enumerable:!0,get:function(){return Ce.A}}),Object.defineProperty(t,"Html",{enumerable:!0,get:function(){return Ne.Html}}),Object.defineProperty(t,"Switcher",{enumerable:!0,get:function(){return Ve.Switcher}}),Object.defineProperty(t,"Loader",{enumerable:!0,get:function(){return Se.Loader}}),Object.defineProperty(t,"ListPane",{enumerable:!0,get:function(){return xe.ListPane}}),Object.defineProperty(t,"MultiPopupView",{enumerable:!0,get:function(){return we.MultiPopupView}}),Object.defineProperty(t,"MultiSelectBar",{enumerable:!0,get:function(){return Ae.MultiSelectBar}}),Object.defineProperty(t,"SelectList",{enumerable:!0,get:function(){return Le.SelectList}}),Object.defineProperty(t,"AbstractAllValueChooser",{enumerable:!0,get:function(){return ke.AbstractAllValueChooser}}),Object.defineProperty(t,"AllValueChooserCombo",{enumerable:!0,get:function(){return De.AllValueChooserCombo}}),Object.defineProperty(t,"TextAreaEditor",{enumerable:!0,get:function(){return Me.TextAreaEditor}}),Object.defineProperty(t,"SingleSelectItem",{enumerable:!0,get:function(){return Pe.SingleSelectItem}}),Object.defineProperty(t,"DynamicDateTimeCombo",{enumerable:!0,get:function(){return Re.DynamicDateTimeCombo}}),Object.defineProperty(t,"MultiTreeCombo",{enumerable:!0,get:function(){return He.MultiTreeCombo}}),Object.defineProperty(t,"CenterLayout",{enumerable:!0,get:function(){return Oe.CenterLayout}}),Object.defineProperty(t,"VirtualGroup",{enumerable:!0,get:function(){return Fe.VirtualGroup}}),Object.defineProperty(t,"GridLayout",{enumerable:!0,get:function(){return Ye.GridLayout}}),Object.defineProperty(t,"TriggerIconButton",{enumerable:!0,get:function(){return We.TriggerIconButton}}),Object.defineProperty(t,"Searcher",{enumerable:!0,get:function(){return Ge.Searcher}}),Object.defineProperty(t,"ListTreeValueChooserInsertCombo",{enumerable:!0,get:function(){return je.ListTreeValueChooserInsertCombo}}),Object.defineProperty(t,"TreeValueChooserCombo",{enumerable:!0,get:function(){return Ze.TreeValueChooserCombo}}),Object.defineProperty(t,"TreeValueChooserInsertCombo",{enumerable:!0,get:function(){return Xe.TreeValueChooserInsertCombo}}),Object.defineProperty(t,"Radio",{enumerable:!0,get:function(){return Ue.Radio}}),Object.defineProperty(t,"MultiLayerSelectTreePopup",{enumerable:!0,get:function(){return Je.MultiLayerSelectTreePopup}}),Object.defineProperty(t,"MultiLayerSingleTreePopup",{enumerable:!0,get:function(){return Ke.MultiLayerSingleTreePopup}}),Object.defineProperty(t,"MultiLayerDownListPopup",{enumerable:!0,get:function(){return ze.MultiLayerDownListPopup}}),Object.defineProperty(t,"TreeView",{enumerable:!0,get:function(){return Qe.TreeView}}),Object.defineProperty(t,"MultiTreePopup",{enumerable:!0,get:function(){return qe.MultiTreePopup}}),Object.defineProperty(t,"SingleSelectRadioItem",{enumerable:!0,get:function(){return $e.SingleSelectRadioItem}}),Object.defineProperty(t,"SingleSelectInsertCombo",{enumerable:!0,get:function(){return et.SingleSelectInsertCombo}}),Object.defineProperty(t,"SingleSelectCombo",{enumerable:!0,get:function(){return tt.SingleSelectCombo}}),Object.defineProperty(t,"CardLayout",{enumerable:!0,get:function(){return nt.CardLayout}}),Object.defineProperty(t,"DynamicYearMonthCombo",{enumerable:!0,get:function(){return it.DynamicYearMonthCombo}}),Object.defineProperty(t,"TimeCombo",{enumerable:!0,get:function(){return rt.TimeCombo}}),Object.defineProperty(t,"ListTreeView",{enumerable:!0,get:function(){return at.ListTreeView}}),Object.defineProperty(t,"ListAsyncTree",{enumerable:!0,get:function(){return ot.ListAsyncTree}}),Object.defineProperty(t,"AsyncTree",{enumerable:!0,get:function(){return st.AsyncTree}}),Object.defineProperty(t,"MultiLayerSingleTreeCombo",{enumerable:!0,get:function(){return lt.MultiLayerSingleTreeCombo}}),Object.defineProperty(t,"MultiLayerSelectTreeCombo",{enumerable:!0,get:function(){return ut.MultiLayerSelectTreeCombo}}),Object.defineProperty(t,"MultiLayerDownListCombo",{enumerable:!0,get:function(){return ct.MultiLayerDownListCombo}}),Object.defineProperty(t,"MultiTreeListCombo",{enumerable:!0,get:function(){return ht.MultiTreeListCombo}}),Object.defineProperty(t,"MultiTreeInsertCombo",{enumerable:!0,get:function(){return pt.MultiTreeInsertCombo}}),Object.defineProperty(t,"TextValueDownListCombo",{enumerable:!0,get:function(){return dt.TextValueDownListCombo}}),Object.defineProperty(t,"Switch",{enumerable:!0,get:function(){return ft.Switch}}),Object.defineProperty(t,"HorizontalLayout",{enumerable:!0,get:function(){return gt.HorizontalLayout}}),Object.defineProperty(t,"ShelterEditor",{enumerable:!0,get:function(){return mt.ShelterEditor}}),Object.defineProperty(t,"TextTrigger",{enumerable:!0,get:function(){return It.TextTrigger}}),Object.defineProperty(t,"SelectTextTrigger",{enumerable:!0,get:function(){return Bt.SelectTextTrigger}}),Object.defineProperty(t,"DateInterval",{enumerable:!0,get:function(){return _t.DateInterval}}),Object.defineProperty(t,"DynamicDatePane",{enumerable:!0,get:function(){return Et.DynamicDatePane}}),Object.defineProperty(t,"AllCountPager",{enumerable:!0,get:function(){return bt.AllCountPager}}),Object.defineProperty(t,"PopupView",{enumerable:!0,get:function(){return yt.PopupView}}),Object.defineProperty(t,"BubblePopupView",{enumerable:!0,get:function(){return vt.BubblePopupView}}),Object.defineProperty(t,"BubblePopupBarView",{enumerable:!0,get:function(){return vt.BubblePopupBarView}}),Object.defineProperty(t,"TextBubblePopupBarView",{enumerable:!0,get:function(){return vt.TextBubblePopupBarView}}),Object.defineProperty(t,"ArrowTreeGroupNodeCheckbox",{enumerable:!0,get:function(){return Tt.ArrowTreeGroupNodeCheckbox}}),Object.defineProperty(t,"NumberInterval",{enumerable:!0,get:function(){return Ct.NumberInterval}}),Object.defineProperty(t,"DynamicYearQuarterCombo",{enumerable:!0,get:function(){return Nt.DynamicYearQuarterCombo}}),Object.defineProperty(t,"DynamicYearCombo",{enumerable:!0,get:function(){return Vt.DynamicYearCombo}}),Object.defineProperty(t,"IntervalSlider",{enumerable:!0,get:function(){return St.IntervalSlider}}),Object.defineProperty(t,"MultiSelectInsertList",{enumerable:!0,get:function(){return xt.MultiSelectInsertList}}),Object.defineProperty(t,"YearMonthInterval",{enumerable:!0,get:function(){return wt.YearMonthInterval}}),Object.defineProperty(t,"NumberEditor",{enumerable:!0,get:function(){return At.NumberEditor}}),Object.defineProperty(t,"TextValueCheckCombo",{enumerable:!0,get:function(){return Lt.TextValueCheckCombo}}),Object.defineProperty(t,"LinearSegment",{enumerable:!0,get:function(){return kt.LinearSegment}}),Object.defineProperty(t,"Img",{enumerable:!0,get:function(){return Dt.Img}}),Object.defineProperty(t,"EditorIconCheckCombo",{enumerable:!0,get:function(){return Mt.EditorIconCheckCombo}}),Object.defineProperty(t,"IconTextValueCombo",{enumerable:!0,get:function(){return Pt.IconTextValueCombo}}),Object.defineProperty(t,"ListView",{enumerable:!0,get:function(){return Rt.ListView}}),Object.defineProperty(t,"FloatCenterLayout",{enumerable:!0,get:function(){return Ht.FloatCenterLayout}}),Object.defineProperty(t,"DynamicYearMonthPopup",{enumerable:!0,get:function(){return Ot.DynamicYearMonthPopup}}),Object.defineProperty(t,"Controller",{enumerable:!0,get:function(){return Ft.Controller}}),Object.defineProperty(t,"LayerController",{enumerable:!0,get:function(){return Yt.LayerController}}),Object.defineProperty(t,"DateCalendarPopup",{enumerable:!0,get:function(){return Wt.DateCalendarPopup}}),Object.defineProperty(t,"Tree",{enumerable:!0,get:function(){return Gt.Tree}}),Object.defineProperty(t,"Node",{enumerable:!0,get:function(){return Gt.Node}}),Object.defineProperty(t,"TextNode",{enumerable:!0,get:function(){return jt.TextNode}}),Object.defineProperty(t,"TextValueCheckComboPopup",{enumerable:!0,get:function(){return Zt.TextValueCheckComboPopup}}),Object.defineProperty(t,"ImageButton",{enumerable:!0,get:function(){return Xt.ImageButton}}),Object.defineProperty(t,"History",{enumerable:!0,get:function(){return Ut.History}}),Object.defineProperty(t,"Router",{enumerable:!0,get:function(){return Ut.Router}}),Object.defineProperty(t,"DateTimeCombo",{enumerable:!0,get:function(){return Jt.DateTimeCombo}}),Object.defineProperty(t,"FloatHorizontalLayout",{enumerable:!0,get:function(){return Kt.FloatHorizontalLayout}}),Object.defineProperty(t,"AdaptiveLayout",{enumerable:!0,get:function(){return zt.AdaptiveLayout}}),Object.defineProperty(t,"HexColorChooserPopup",{enumerable:!0,get:function(){return Qt.HexColorChooserPopup}}),Object.defineProperty(t,"BlankIconTextItem",{enumerable:!0,get:function(){return qt.BlankIconTextItem}}),Object.defineProperty(t,"BroadcastController",{enumerable:!0,get:function(){return $t.BroadcastController}}),Object.defineProperty(t,"Pager",{enumerable:!0,get:function(){return en.Pager}}),Object.defineProperty(t,"TimeInterval",{enumerable:!0,get:function(){return tn.TimeInterval}}),Object.defineProperty(t,"DynamicDateTimePane",{enumerable:!0,get:function(){return nn.DynamicDateTimePane}}),Object.defineProperty(t,"SingleSelectInsertList",{enumerable:!0,get:function(){return rn.SingleSelectInsertList}}),Object.defineProperty(t,"MultiSelectTree",{enumerable:!0,get:function(){return an.MultiSelectTree}}),Object.defineProperty(t,"HtmlLabel",{enumerable:!0,get:function(){return on.HtmlLabel}}),Object.defineProperty(t,"TreeValueChooserPane",{enumerable:!0,get:function(){return sn.TreeValueChooserPane}}),t["default"]=void 0;var r=n(710),a=n(68),o=n(711),s=n(16),l=n(4),u=n(46),c=n(712),h=n(713),p=n(714),d=n(715),f=n(716),g=n(717),m=n(718),I=n(47),B=n(719),_=n(2),E=n(69),b=n(48),y=n(720),v=n(721),T=n(722),C=n(723),N=n(724),V=n(725),S=n(726),x=n(727),w=n(728),A=n(729),L=n(30),k=n(70),D=n(71),M=n(730),P=n(49),R=n(731),H=n(732),O=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==i(e)&&"function"!=typeof e)return{"default":e};var t=ln();if(t&&t.has(e))return t.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if(Object.prototype.hasOwnProperty.call(e,a)){var o=r?Object.getOwnPropertyDescriptor(e,a):null;o&&(o.get||o.set)?Object.defineProperty(n,a,o):n[a]=e[a]}n["default"]=e,t&&t.set(e,n);return n}(n(733)),F=n(29),Y=n(1),W=n(3),G=n(734),j=n(735),Z=n(736),X=n(737),U=n(738),J=n(739),K=n(740),z=n(741),Q=n(742),q=n(743),$=n(744),ee=n(745),te=n(50),ne=n(72),ie=n(746),re=n(747),ae=n(748),oe=n(749),se=n(750),le=n(751),ue=n(752),ce=n(753),he=n(754),pe=n(755),de=n(756),fe=n(757),ge=n(758),me=n(759),Ie=n(760),Be=n(761),_e=n(762),Ee=n(763),be=n(764),ye=n(765),ve=n(766),Te=n(767),Ce=n(768),Ne=n(769),Ve=n(770),Se=n(771),xe=n(772),we=n(773),Ae=n(774),Le=n(775),ke=n(73),De=n(776),Me=n(777),Pe=n(778),Re=n(779),He=n(780),Oe=n(781),Fe=n(782),Ye=n(783),We=n(784),Ge=n(785),je=n(786),Ze=n(787),Xe=n(788),Ue=n(789),Je=n(790),Ke=n(791),ze=n(792),Qe=n(52),qe=n(793),$e=n(794),et=n(795),tt=n(796),nt=n(797),it=n(798),rt=n(799),at=n(74),ot=n(800),st=n(801),lt=n(802),ut=n(803),ct=n(804),ht=n(805),pt=n(806),dt=n(807),ft=n(808),gt=n(809),mt=n(810),It=n(811),Bt=n(812),_t=n(813),Et=n(814),bt=n(815),yt=n(51),vt=n(816),Tt=n(817),Ct=n(818),Nt=n(819),Vt=n(820),St=n(821),xt=n(822),wt=n(823),At=n(824),Lt=n(825),kt=n(826),Dt=n(827),Mt=n(828),Pt=n(829),Rt=n(830),Ht=n(831),Ot=n(832),Ft=n(53),Yt=n(833),Wt=n(834),Gt=n(835),jt=n(836),Zt=n(837),Xt=n(838),Ut=n(839),Jt=n(840),Kt=n(841),zt=n(842),Qt=n(843),qt=n(844),$t=n(845),en=n(846),tn=n(847),nn=n(848),rn=n(849),an=n(850),on=n(851),sn=n(852);function ln(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return ln=function(){return e},e}var un={Decorators:O};t["default"]=un},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(47)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(16)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(71)},function(e,t,n){"use strict";n(49)},function(e,t,n){"use strict";n(49)},function(e,t,n){"use strict";function i(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,function(e,t){for(var n=Object.getOwnPropertyNames(t),i=0;i<n.length;i++){var r=n[i],a=Object.getOwnPropertyDescriptor(t,r);a&&a.configurable&&e[r]===undefined&&Object.defineProperty(e,r,a)}}(e,t)}Object.defineProperty(t,"__esModule",{value:!0}),t.shortcut=function(){return function(e){BI.shortcut(e.xtype,e)}},t.provider=function(){return function(e){BI.provider(e.xtype,e)}},t.model=function(){return function(e){BI.model(e.xtype,e)}},t.store=function(e){var t=arguments.length>1&&arguments[1]!==undefined?arguments[1]:{};return function(n){return function(n){function i(){return n.apply(this,arguments)||this}return a(i,n),i.prototype._store=function(){var n=t.props?t.props.apply(this):undefined;return BI.Models.getModel(e.xtype,n)},i}(n)}},t.mixin=function(){return function(e){var t={};Object.getOwnPropertyNames(e.prototype).forEach((function(n){"constructor"!==n&&(t[n]=e.prototype[n])})),Fix.mixin(e.xtype,t)}},t.mixins=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){var n=[];return t.forEach((function(e){e.xtype&&n.push(e.xtype)})),function(e){function t(){for(var t,a=arguments.length,o=new Array(a),s=0;s<a;s++)o[s]=arguments[s];return r(i(t=e.call.apply(e,[this].concat(o))||this),"mixins",n),t}return a(t,e),t}(e)}},t.Model=void 0;var o=function(e){function t(){for(var t,n=arguments.length,a=new Array(n),o=0;o<n;o++)a[o]=arguments[o];return r(i(t=e.call.apply(e,[this].concat(a))||this),"model",void 0),r(i(t),"store",void 0),r(i(t),"context",void 0),r(i(t),"actions",void 0),r(i(t),"childContext",void 0),r(i(t),"TYPE",void 0),r(i(t),"computed",void 0),t}return a(t,e),t.prototype.state=function(){return{}},t}(Fix.Model);t.Model=o},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(68)},function(e,t,n){"use strict";n(46)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(72)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(16)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(69)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(16)},function(e,t,n){"use strict";n(51)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(73)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(50)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(70)},function(e,t,n){"use strict";n(30)},function(e,t,n){"use strict";n(30)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(16)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(74)},function(e,t,n){"use strict";n(52)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(48)},function(e,t,n){"use strict";n(48)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(51),n(1)},function(e,t,n){"use strict";n(50)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(53)},function(e,t,n){"use strict";n(1)},function(e,t,n){},function(e,t,n){"use strict";n(46)},function(e,t,n){"use strict";n(16)},function(e,t,n){"use strict";n(4)},function(e,t,n){},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(3)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(4)},function(e,t,n){"use strict";n(53)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(1)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(2)},function(e,t,n){"use strict";n(47)},function(e,t,n){"use strict";n(30)},,function(e,t,n){},function(e,t,n){},function(e,t){BI.prepares.push((function(){var e,t=function(){return null==e&&(e=!(!BI.isSupportCss3||!BI.isSupportCss3("flex"))),e};BI.Plugin.configWidget("bi.horizontal",(function(e){return t()?BI.extend({},e,{type:"bi.flex_horizontal"}):BI.extend({scrollx:!0},e,{type:"bi.inline"})})),BI.Plugin.configWidget("bi.inline",(function(e){return e.columnSize&&e.columnSize.indexOf("")>=0&&e.columnSize.indexOf("fill")>=0?BI.extend({horizontalAlign:BI.HorizontalAlign.Stretch},e,{type:"bi.table_adapt"}):e})),BI.Plugin.configWidget("bi.center_adapt",(function(e){return t()?BI.extend({},e,{type:"bi.flex_center_adapt"}):BI.extend({},e,{type:"bi.inline_center_adapt"})})),BI.Plugin.configWidget("bi.vertical_adapt",(function(e){return t()?BI.extend({},e,{type:"bi.flex_vertical_center_adapt"}):BI.extend({},e,{type:"bi.inline_vertical_adapt"})})),BI.Plugin.configWidget("bi.horizontal_adapt",(function(e){var n=e.items&&e.items.length<=1,i=!e.horizontalAlign||e.horizontalAlign===BI.HorizontalAlign.Center||e.horizontalAlign===BI.HorizontalAlign.Stretch;if((!e.verticalAlign||e.verticalAlign===BI.VerticalAlign.TOP)&&n)return BI.extend({},e,{type:"bi.horizontal_auto"});var r=t();return i?BI.extend({horizontalAlign:BI.HorizontalAlign.Center},e,{type:"bi.table_adapt"}):r?BI.extend({horizontalAlign:BI.HorizontalAlign.Center,scrollx:!1},e,{type:"bi.flex_horizontal"}):BI.extend({horizontalAlign:BI.HorizontalAlign.Center},e,{type:"bi.table_adapt"})})),BI.Plugin.configWidget("bi.horizontal_float",(function(e){return t()?BI.extend({},e,{type:"bi.flex_horizontal_adapt"}):BI.extend({},e,{type:"bi.inline_horizontal_adapt"})})),BI.Plugin.configWidget("bi.left_right_vertical_adapt",(function(e){return t()?BI.extend({},e,{type:"bi.flex_left_right_vertical_adapt"}):e})),BI.Plugin.configWidget("bi.flex_horizontal",(function(e){if((!0===e.scrollable||!1!==e.scrollx)&&(e.hgap>0||e.rgap>0))return BI.extend({},e,{type:"bi.flex_scrollable_horizontal"})})),BI.Plugin.configWidget("bi.flex_vertical",(function(e){if((!0===e.scrollable||!0===e.scrollx)&&(e.hgap>0||e.rgap>0))return BI.extend({},e,{type:"bi.flex_scrollable_vertical"})})),BI.Plugin.configWidget("bi.radio",(function(e){return BI.isIE()&&BI.getIEVersion()<=9?BI.extend({},e,{type:"bi.image_radio"}):e})),BI.Plugin.configWidget("bi.checkbox",(function(e){return BI.isIE()&&BI.getIEVersion()<=9?BI.extend({},e,{type:"bi.image_checkbox"}):e})),BI.Plugin.configWidget("bi.half_icon_button",(function(e){return BI.isIE()&&BI.getIEVersion()<9?e:BI.extend({},e,{type:"bi.half_button"})}))}))},function(e,t){!function(){var e,t,n=_global.document&&_global.document.attachEvent,i=!1;if(_global.document&&!n){var r=(t=_global.requestAnimationFrame||_global.mozRequestAnimationFrame||_global.webkitRequestAnimationFrame||function(e){return _global.setTimeout(e,20)},function(e){return t(e)}),a=(e=_global.cancelAnimationFrame||_global.mozCancelAnimationFrame||_global.webkitCancelAnimationFrame||_global.clearTimeout,function(t){return e(t)}),o=function(e){var t=e.__resizeTriggers__,n=t.firstElementChild,i=t.lastElementChild,r=n.firstElementChild;i.scrollLeft=i.scrollWidth,i.scrollTop=i.scrollHeight,r.style.width=n.offsetWidth+1+"px",r.style.height=n.offsetHeight+1+"px",n.scrollLeft=n.scrollWidth,n.scrollTop=n.scrollHeight},s=function(e){var t=this;o(this),this.__resizeRAF__&&a(this.__resizeRAF__),this.__resizeRAF__=r((function(){(function(e){return e.offsetWidth!==e.__resizeLast__.width||e.offsetHeight!==e.__resizeLast__.height})(t)&&(t.__resizeLast__.width=t.offsetWidth,t.__resizeLast__.height=t.offsetHeight,t.__resizeListeners__.forEach((function(n){n.call(t,e)})))}))},l=!1,u="",c="animationstart",h="Webkit Moz O ms".split(" "),p="webkitAnimationStart animationstart oAnimationStart MSAnimationStart".split(" "),d="",f=document.createElement("fakeelement");if(f.style.animationName!==undefined&&(l=!0),!1===l)for(var g=0;g<h.length;g++)if(f.style[h[g]+"AnimationName"]!==undefined){(d=h[g])+"Animation",u="-"+d.toLowerCase()+"-",c=p[g],l=!0;break}var m="resizeanim",I="@"+u+"keyframes "+m+" { from { opacity: 0; } to { opacity: 0; } } ",B=u+"animation: 1ms "+m+"; "}var _=function(e,t){n?(e.attachEvent("onresize",t),BI.nextTick(t)):(e.__resizeTriggers__||("static"===getComputedStyle(e).position&&(e.style.position="relative"),function(){if(!i){var e=(I||"")+".resize-triggers { "+(B||"")+'visibility: hidden; opacity: 0; } .resize-triggers, .resize-triggers > div, .contract-trigger:before { content: " "; display: block; position: absolute; top: 0; left: 0; height: 100%; width: 100%; overflow: hidden; } .resize-triggers > div { background: #eee; overflow: auto; } .contract-trigger:before { width: 200%; height: 200%; }',t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e)),t.appendChild(n),i=!0}}(),e.__resizeLast__={},e.__resizeListeners__=[],(e.__resizeTriggers__=document.createElement("div")).className="resize-triggers",e.__resizeTriggers__.innerHTML='<div class="expand-trigger"><div></div></div><div class="contract-trigger"></div>',e.appendChild(e.__resizeTriggers__),o(e),e.addEventListener("scroll",s,!0),c&&e.__resizeTriggers__.addEventListener(c,(function(t){t.animationName===m&&o(e)}))),e.__resizeListeners__.push(t))},E=function(e,t){n?e.detachEvent("onresize",t):(e.__resizeListeners__.splice(e.__resizeListeners__.indexOf(t),1),e.__resizeListeners__.length||(e.removeEventListener("scroll",s),e.__resizeTriggers__=!e.removeChild(e.__resizeTriggers__)))};BI.ResizeDetector={addResizeListener:function(e,t){return _(e.element[0],t),function(){E(e.element[0],t)}},removeResizeListener:function(e,t){E(e.element[0],t)}}}()},function(e,t){BI.DOM=BI.DOM||{},BI.extend(BI.DOM,{ready:function(e){BI.Widget._renderEngine.createElement(document).ready(e)}}),BI.extend(BI.DOM,{patchProps:function(e,t){var n=BI.jQuery._data(e[0]).events;BI.each(n,(function(e,n){BI.each(n,(function(n,i){t.on(e+(i.namespace?"."+i.namespace:""),i)}))}));var i=e.children(),r=t.children();if(i.length!==r.length)throw new Error("不匹配");BI.each(i,(function(e,t){BI.DOM.patchProps(BI.jQuery(t),BI.jQuery(r[e]))})),BI.each(e.data("__widgets"),(function(e,n){n.element=t}))},hang:function(e){if(!BI.isEmpty(e)){var t=BI.Widget._renderEngine.createFragment();return BI.each(e,(function(e,n){n instanceof BI.Widget&&(n=n.element),n instanceof BI.$&&n[0]&&t.appendChild(n[0])})),t}},isExist:function(e){return BI.Widget._renderEngine.createElement("body").find(e.element).length>0},preloadImages:function(e,t){var n=0,i=[];function r(){++n>=e.length&&t()}BI.each(e,(function(e,t){i[e]=new Image,i[e].src=t,i[e].onload=function(){r()},i[e].onerror=function(){r()}}))},getTextSizeWidth:function(e,t){var n=BI.Widget._renderEngine.createElement("<span></span>").addClass("text-width-span").appendTo("body");null==t&&(t=12),t+="px",n.css("font-size",t).text(e);var i=n.width();return n.remove(),i},getTextSizeHeight:function(e,t){var n=BI.Widget._renderEngine.createElement("<span></span>").addClass("text-width-span").appendTo("body");null==t&&(t=12),t+="px",n.css("font-size",t).text(e);var i=n.height();return n.remove(),i},getScrollWidth:function(){if(BI.isNull(this._scrollWidth)||0===this._scrollWidth){var e=BI.Widget._renderEngine.createElement("<div>").width(50).height(50).css({position:"absolute",top:"-9999px",overflow:"scroll"}).appendTo("body");this._scrollWidth=e[0].offsetWidth-e[0].clientWidth,e.destroy()}return this._scrollWidth},getImage:function(e,t,n){var i=document.createElement("canvas");BI.Widget._renderEngine.createElement("body").append(i);var r=i.getContext("2d");r.font="12px Helvetica Neue,Arial,PingFang SC,Hiragino Sans GB,Microsoft YaHei,微软雅黑,Heiti,黑体,sans-serif";var a=r.measureText(e).width+4;i.width=2*a,i.height=32,r.font="24px Helvetica Neue,Arial,PingFang SC,Hiragino Sans GB,Microsoft YaHei,微软雅黑,Heiti,黑体,sans-serif",r.fillStyle=t||"#3685f2",r.textBaseline="middle",r.fillText(e,4,18),BI.Widget._renderEngine.createElement(i).destroy();var o=n||"rgba(54, 133, 242, 0.1)";return{width:a,height:16,src:i.toDataURL("image/png"),style:"background-color: "+o+";vertical-align: middle; margin: 0 1px; width:"+a+"px;height: 16px; max-width:"+a+"px;max-height: 16px; min-width:"+a+"px;min-height: 16px",param:e}}}),BI.extend(BI.DOM,{isColor:function(e){return e&&(this.isRGBColor(e)||this.isHexColor(e))},isRGBColor:function(e){return!!e&&"rgb"===e.substr(0,3)},isHexColor:function(e){return!!e&&"#"===e[0]&&7===e.length},isDarkColor:function(e){if(!e||!this.isHexColor(e))return!1;var t=this.rgb2json(this.hex2rgb(e));return Math.round(.299*t.r+.587*t.g+.114*t.b)<192},getContrastColor:function(e){return e&&this.isColor(e)?this.isDarkColor(e)?"#ffffff":"#1a1a1a":""},rgb2hex:function(e){if(!e||"rgb"!=e.substr(0,3))return"";var t=e.match(/\d+(\.\d+)?/g),n=BI.parseInt(t[0]),i=BI.parseInt(t[1]),r=BI.parseInt(t[2]);return"#"+this.int2hex(n)+this.int2hex(i)+this.int2hex(r)},rgb2json:function(e){if(!e)return{};if(!this.isRGBColor(e))return{};var t=e.match(/\d+(\.\d+)?/g);return{r:BI.parseInt(t[0]),g:BI.parseInt(t[1]),b:BI.parseInt(t[2])}},rgba2json:function(e){if(!e)return{};var t=e.match(/\d+(\.\d+)?/g);return{r:BI.parseInt(t[0]),g:BI.parseInt(t[1]),b:BI.parseInt(t[2]),a:BI.parseFloat(t[3])}},json2rgb:function(e){return BI.isKey(e.r)&&BI.isKey(e.g)&&BI.isKey(e.b)?"rgb("+e.r+","+e.g+","+e.b+")":""},json2rgba:function(e){return BI.isKey(e.r)&&BI.isKey(e.g)&&BI.isKey(e.b)?"rgba("+e.r+","+e.g+","+e.b+","+e.a+")":""},int2hex:function(e){var t=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"];return t[e>>>4]+""+t[15&e]},hex2rgb:function(e){if(!e)return"";if(!this.isHexColor(e))return e;var t,n="rgb(";return 7===e.length?t=[BI.parseInt("0x"+e.substring(1,3)),BI.parseInt("0x"+e.substring(3,5)),BI.parseInt("0x"+e.substring(5,7))]:4===e.length&&(t=[BI.parseInt("0x"+e.substring(1,2)),BI.parseInt("0x"+e.substring(2,3)),BI.parseInt("0x"+e.substring(3,4))]),n+=t[0]+",",n+=t[1]+",",n+=t[2]+")"},rgba2rgb:function(e,t){if(BI.isNull(t)&&(t=1),"rgba"!=e.substr(0,4))return"";var n=e.match(/\d+(\.\d+)?/g);if(n.length<4)return"";var i=BI.parseFloat(n[0]),r=BI.parseFloat(n[1]),a=BI.parseFloat(n[2]),o=BI.parseFloat(n[3]);return"rgb("+Math.floor(t*(1-o)*255+i*o)+","+Math.floor(t*(1-o)*255+r*o)+","+Math.floor(t*(1-o)*255+a*o)+")"}}),BI.extend(BI.DOM,{getLeftPosition:function(e,t,n){return{left:e.element.offset().left-t.element.outerWidth()-(n||0)}},getInnerLeftPosition:function(e,t,n){return{left:e.element.offset().left+(n||0)}},getRightPosition:function(e,t,n){var i=e.element;return{left:i.offset().left+i.outerWidth()+(n||0)}},getInnerRightPosition:function(e,t,n){var i=e.element,r=t.element.bounds();return{left:i.offset().left+i.outerWidth()-r.width-(n||0)}},getTopPosition:function(e,t,n){return{top:e.element.offset().top-t.element.outerHeight()-(n||0)}},getBottomPosition:function(e,t,n){var i=e.element;return{top:i.offset().top+i.outerHeight()+(n||0)}},isLeftSpaceEnough:function(e,t,n){return BI.DOM.getLeftPosition(e,t,n).left>=0},isInnerLeftSpaceEnough:function(e,t,n){var i=t.element.bounds(),r=BI.Widget._renderEngine.createElement("body").bounds();return BI.DOM.getInnerLeftPosition(e,t,n).left+i.width<=r.width},isRightSpaceEnough:function(e,t,n){var i=t.element.bounds(),r=BI.Widget._renderEngine.createElement("body").bounds();return BI.DOM.getRightPosition(e,t,n).left+i.width<=r.width},isInnerRightSpaceEnough:function(e,t,n){return BI.DOM.getInnerRightPosition(e,t,n).left>=0},isTopSpaceEnough:function(e,t,n){return BI.DOM.getTopPosition(e,t,n).top>=0},isBottomSpaceEnough:function(e,t,n){var i=t.element.bounds(),r=BI.Widget._renderEngine.createElement("body").bounds();return BI.DOM.getBottomPosition(e,t,n).top+i.height<=r.height},isRightSpaceLarger:function(e){return BI.Widget._renderEngine.createElement("body").bounds().width-e.element.offset().left-e.element.bounds().width>=e.element.offset().left},isBottomSpaceLarger:function(e){return BI.Widget._renderEngine.createElement("body").bounds().height-e.element.offset().top-e.element.bounds().height>=e.element.offset().top},_getLeftAlignPosition:function(e,t,n){var i=t.element.bounds(),r=BI.Widget._renderEngine.createElement("body").bounds(),a=e.element.offset().left+n;return a+i.width>r.width&&(a=r.width-i.width),a},getLeftAlignPosition:function(e,t,n){var i=this._getLeftAlignPosition(e,t,n),r="";return i<0&&(i=this._getRightAlignPosition(e,t,n),r="left"),i<0&&(i=0),{left:i,dir:r||"right"}},getLeftAdaptPosition:function(e,t,n){return BI.DOM.isLeftSpaceEnough(e,t,n)?BI.DOM.getLeftPosition(e,t,n):{left:0}},_getRightAlignPosition:function(e,t,n){var i=e.element.bounds(),r=t.element.bounds();return e.element.offset().left+i.width-r.width-n},getRightAlignPosition:function(e,t,n){var i=this._getRightAlignPosition(e,t,n),r="";return i<0&&(i=this._getLeftAlignPosition(e,t,n),r="right"),i<0&&(i=0),{left:i,dir:r||"left"}},getRightAdaptPosition:function(e,t,n){return BI.DOM.isRightSpaceEnough(e,t,n)?BI.DOM.getRightPosition(e,t,n):{left:BI.Widget._renderEngine.createElement("body").bounds().width-t.element.bounds().width}},getTopAlignPosition:function(e,t,n,i){var r,a,o,s=e.element.offset(),l=e.element.bounds(),u=t.element.bounds(),c=BI.Widget._renderEngine.createElement("body").bounds();return BI.DOM.isBottomSpaceEnough(e,t,-1*l.height+n)?r=s.top+n:i?(r=s.top+n,a=c.height-r):BI.DOM.isTopSpaceEnough(e,t,-1*l.height+n)?(r=s.top+l.height-u.height-n,o="top"):(r=c.height-u.height)<n&&(a=c.height-n),r<n&&(r=n),a?{top:r,adaptHeight:a,dir:o||"bottom"}:{top:r,dir:o||"bottom"}},getTopAdaptPosition:function(e,t,n,i){var r=t.element.bounds(),a=BI.Widget._renderEngine.createElement("body").bounds();return BI.DOM.isTopSpaceEnough(e,t,n)?BI.DOM.getTopPosition(e,t,n):i?{top:0,adaptHeight:e.element.offset().top-n}:r.height+n>a.height?{top:0,adaptHeight:a.height-n}:{top:0}},getBottomAlignPosition:function(e,t,n,i){var r,a,o,s=e.element.offset(),l=e.element.bounds(),u=t.element.bounds(),c=BI.Widget._renderEngine.createElement("body").bounds();return BI.DOM.isTopSpaceEnough(e,t,-1*l.height+n)?r=s.top+l.height-u.height-n:i?(r=0,a=s.top+l.height-n):BI.DOM.isBottomSpaceEnough(e,t,-1*l.height+n)?(r=s.top+n,o="bottom"):(r=0,u.height+n>c.height&&(a=c.height-n)),r<0&&(r=0),a?{top:r,adaptHeight:a,dir:o||"top"}:{top:r,dir:o||"top"}},getBottomAdaptPosition:function(e,t,n,i){var r=e.element.offset(),a=e.element.bounds(),o=t.element.bounds(),s=BI.Widget._renderEngine.createElement("body").bounds();return BI.DOM.isBottomSpaceEnough(e,t,n)?BI.DOM.getBottomPosition(e,t,n):i?{top:r.top+a.height+n,adaptHeight:s.height-r.top-a.height-n}:o.height+n>s.height?{top:n,adaptHeight:s.height-n}:{top:s.height-o.height-n}},getCenterAdaptPosition:function(e,t){var n,i=e.element.offset(),r=e.element.bounds(),a=t.element.bounds(),o=BI.Widget._renderEngine.createElement("body").bounds();return(n=i.left+r.width/2+a.width/2>o.width?o.width-a.width:i.left+r.width/2-a.width/2)<0&&(n=0),{left:n}},getMiddleAdaptPosition:function(e,t){var n,i=e.element.offset(),r=e.element.bounds(),a=t.element.bounds(),o=BI.Widget._renderEngine.createElement("body").bounds();return(n=i.top+r.height/2+a.height/2>o.height?o.height-a.height:i.top+r.height/2-a.height/2)<0&&(n=0),{top:n}},getComboPositionByDirections:function(e,t,n,i,r,a){var o,s;n||(n=0),i||(i=0);var l,u,c,h=[],p=[],d=[],f=!1,g=!1,m=!1,I=a[0];for(o=0;o<a.length;o++)switch(s=a[o]){case"left":case"right":h.push(s);break;case"top":case"bottom":p.push(s);break;case"innerLeft":case"innerRight":d.push(s)}for(o=0;o<a.length;o++)switch(s=a[o]){case"left":if(!f){var B=g?i:n,_=g?0:i;if(BI.DOM.isLeftSpaceEnough(e,t,B))return l=BI.DOM.getLeftPosition(e,t,B).left,(c="bottom"===p[0]?BI.DOM.getTopAlignPosition(e,t,_,r):BI.DOM.getBottomAlignPosition(e,t,_,r)).dir="left,"+c.dir,g&&(c.change="left"),c.left=l,c}m=!0;break;case"right":if(!f&&(B=g?i:n,_=g?n:i,BI.DOM.isRightSpaceEnough(e,t,B)))return l=BI.DOM.getRightPosition(e,t,B).left,(c="bottom"===p[0]?BI.DOM.getTopAlignPosition(e,t,_,r):BI.DOM.getBottomAlignPosition(e,t,_,r)).dir="right,"+c.dir,g&&(c.change="right"),c.left=l,c;m=!0;break;case"top":if(B=m?i:n,_=m?n:i,BI.DOM.isTopSpaceEnough(e,t,_))return u=BI.DOM.getTopPosition(e,t,_).top,(c="right"===h[0]?BI.DOM.getLeftAlignPosition(e,t,B,r):BI.DOM.getRightAlignPosition(e,t,B)).dir="top,"+c.dir,m&&(c.change="top"),c.top=u,c;r&&(f=!0),g=!0;break;case"bottom":if(B=m?i:n,_=m?n:i,BI.DOM.isBottomSpaceEnough(e,t,_))return u=BI.DOM.getBottomPosition(e,t,_).top,(c="right"===h[0]?BI.DOM.getLeftAlignPosition(e,t,B,r):BI.DOM.getRightAlignPosition(e,t,B)).dir="bottom,"+c.dir,m&&(c.change="bottom"),c.top=u,c;r&&(f=!0),g=!0;break;case"innerLeft":if(!f&&(B=g?i:n,_=g?0:i,BI.DOM.isInnerLeftSpaceEnough(e,t,B)))return l=BI.DOM.getInnerLeftPosition(e,t,B).left,(c="bottom"===p[0]?BI.DOM.getTopAlignPosition(e,t,_,r):BI.DOM.getBottomAlignPosition(e,t,_,r)).dir="innerLeft,"+c.dir,g&&(c.change="innerLeft"),c.left=l,c;m=!0;break;case"innerRight":if(!f&&(B=g?i:n,_=g?n:i,BI.DOM.isInnerRightSpaceEnough(e,t,B)))return l=BI.DOM.getInnerRightPosition(e,t,B).left,(c="bottom"===p[0]?BI.DOM.getTopAlignPosition(e,t,_,r):BI.DOM.getBottomAlignPosition(e,t,_,r)).dir="innerLeft,"+c.dir,g&&(c.change="innerRight"),c.left=l,c}switch(a[0]){case"left":case"right":return BI.DOM.isRightSpaceLarger(e)?(l=BI.DOM.getRightAdaptPosition(e,t,n).left,I="right"):(l=BI.DOM.getLeftAdaptPosition(e,t,n).left,I="left"),"bottom"===p[0]?((c=BI.DOM.getTopAlignPosition(e,t,i,r)).left=l,c.dir=I+","+c.dir,c):((c=BI.DOM.getBottomAlignPosition(e,t,i,r)).left=l,c.dir=I+","+c.dir,c);default:return BI.DOM.isBottomSpaceLarger(e)?(c=BI.DOM.getBottomAdaptPosition(e,t,i,r),I="bottom"):(c=BI.DOM.getTopAdaptPosition(e,t,i,r),I="top"),"right"===h[0]?(l=BI.DOM.getLeftAlignPosition(e,t,n,r).left,c.left=l,c.dir=I+","+c.dir,c):(l=BI.DOM.getRightAlignPosition(e,t,n).left,c.left=l,c.dir=I+","+c.dir,c)}},getComboPosition:function(e,t,n,i,r,a,o){n||(n=0),i||(i=0);var s=BI.Widget._renderEngine.createElement("body").bounds().height-i,l=Math.min(t.attr("maxHeight")||s,s);t.resetHeight&&t.resetHeight(l);var u=BI.DOM.getComboPositionByDirections(e,t,n,i,r,a||["bottom","top","right","left"]);switch(o){case"center":if(u.change){var c=BI.DOM.getMiddleAdaptPosition(e,t);u.top=c.top}else c=BI.DOM.getCenterAdaptPosition(e,t),u.left=c.left;break;case"middle":u.change?(c=BI.DOM.getCenterAdaptPosition(e,t),u.left=c.left):(c=BI.DOM.getMiddleAdaptPosition(e,t),u.top=c.top)}return!0===r&&t.resetHeight&&t.resetHeight(Math.min(s-u.top,l)),u}})},function(e,t){_.extend(BI,{isIE:function(){return!!_global.navigator&&(null==this.__isIE&&(this.__isIE=/(msie|trident)/i.test(navigator.userAgent.toLowerCase())),this.__isIE)},getIEVersion:function(){if(!_global.navigator)return 0;if(null!=this.__IEVersion)return this.__IEVersion;var e=0,t=navigator.userAgent.toLowerCase(),n=t.match(/(?:msie\s([\w.]+))/),i=t.match(/(?:trident.*rv:([\w.]+))/);return e=n&&i&&n[1]&&i[1]?Math.max(1*n[1],1*i[1]):n&&n[1]?1*n[1]:i&&i[1]?1*i[1]:0,this.__IEVersion=e},isIE9Below:function(){return!!BI.isIE()&&this.getIEVersion()<9},isEdge:function(){return!!_global.navigator&&/edge/i.test(navigator.userAgent.toLowerCase())},isChrome:function(){return!!_global.navigator&&/chrome/i.test(navigator.userAgent.toLowerCase())},isFireFox:function(){return!!_global.navigator&&/firefox/i.test(navigator.userAgent.toLowerCase())},isOpera:function(){return!!_global.navigator&&/opera/i.test(navigator.userAgent.toLowerCase())},isSafari:function(){return!!_global.navigator&&(/safari/i.test(navigator.userAgent.toLowerCase())&&!/chrome/i.test(navigator.userAgent.toLowerCase()))},isKhtml:function(){return!!_global.navigator&&/Konqueror|Safari|KHTML/i.test(navigator.userAgent)},isMac:function(){return!!_global.navigator&&/macintosh|mac os x/i.test(navigator.userAgent)},isWindows:function(){return!!_global.navigator&&/windows|win32/i.test(navigator.userAgent)},isSupportCss3:function(e){if(!_global.document)return!1;var t,n,i=["webkit","Moz","ms","o"],r=[],a=document.documentElement.style,o=function(e){return BI.isString(e)?e.replace(/-(\w)/g,(function(e,t){return t.toUpperCase()})):""};for(t=0;t<i.length;t++)r.push(o(i[t]+"-"+e));for(r.push(o(e)),t=0,n=r.length;t<n;t++)if(r[t]in a)return!0;return!1}})},function(e,t,n){var i,r,a;r="undefined"!=typeof window?window:this,a=function(n,r){var a=[],o=n.document,s=a.slice,l=a.concat,u=a.push,c=a.indexOf,h={},p=h.toString,d=h.hasOwnProperty,f={},g="1.12.4",m=function(e,t){return new m.fn.init(e,t)},I=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,B=/^-ms-/,E=/-([\da-z])/gi,b=function(e,t){return t.toUpperCase()};function y(e){var t=!!e&&"length"in e&&e.length,n=m.type(e);return"function"!==n&&!m.isWindow(e)&&("array"===n||0===t||"number"==typeof t&&t>0&&t-1 in e)}m.fn=m.prototype={jquery:g,constructor:m,selector:"",length:0,toArray:function(){return s.call(this)},get:function(e){return null!=e?e<0?this[e+this.length]:this[e]:s.call(this)},pushStack:function(e){var t=m.merge(this.constructor(),e);return t.prevObject=this,t.context=this.context,t},each:function(e){if(arguments.length>1)throw new Error("调用兼容出错");return m.each(this,e)},map:function(e){return this.pushStack(m.map(this,(function(t,n){return e.call(t,n,t)})))},slice:function(){return this.pushStack(s.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(n>=0&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:u,sort:a.sort,splice:a.splice},m.extend=m.fn.extend=function(){var e,t,n,i,r,a,o=arguments[0]||{},s=1,l=arguments.length,u=!1;for("boolean"==typeof o&&(u=o,o=arguments[s]||{},s++),"object"==typeof o||m.isFunction(o)||(o={}),s===l&&(o=this,s--);s<l;s++)if(null!=(r=arguments[s]))for(i in r)e=o[i],n=r[i],"__proto__"!==i&&o!==n&&(u&&n&&(m.isPlainObject(n)||(t=m.isArray(n)))?(t?(t=!1,a=e&&m.isArray(e)?e:[]):a=e&&m.isPlainObject(e)?e:{},o[i]=m.extend(u,a,n)):n!==undefined&&(o[i]=n));return o},m.extend({expando:"jQuery"+(g+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isFunction:function(e){return"function"===m.type(e)},isArray:Array.isArray||function(e){return"array"===m.type(e)},isWindow:function(e){return null!=e&&e==e.window},isNumeric:function(e){var t=e&&e.toString();return!m.isArray(e)&&t-parseFloat(t)+1>=0},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},isPlainObject:function(e){var t;if(!e||"object"!==m.type(e)||e.nodeType||m.isWindow(e))return!1;try{if(e.constructor&&!d.call(e,"constructor")&&!d.call(e.constructor.prototype,"isPrototypeOf"))return!1}catch(n){return!1}if(!f.ownFirst)for(t in e)return d.call(e,t);for(t in e);return t===undefined||d.call(e,t)},type:function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?h[p.call(e)]||"object":typeof e},globalEval:function(e){e&&m.trim(e)&&(n.execScript||function(e){n.eval.call(n,e)})(e)},camelCase:function(e){return e.replace(B,"ms-").replace(E,b)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,t){var n,i=0;if(y(e))for(n=e.length;i<n&&!1!==t.call(e[i],i,e[i]);i++);else for(i in e)if(!1===t.call(e[i],i,e[i]))break;return e},trim:function(e){return null==e?"":(e+"").replace(I,"")},makeArray:function(e,t){var n=t||[];return null!=e&&(y(Object(e))?m.merge(n,"string"==typeof e?[e]:e):u.call(n,e)),n},inArray:function(e,t,n){var i;if(t){if(c)return c.call(t,e,n);for(i=t.length,n=n?n<0?Math.max(0,i+n):n:0;n<i;n++)if(n in t&&t[n]===e)return n}return-1},merge:function(e,t){for(var n=+t.length,i=0,r=e.length;i<n;)e[r++]=t[i++];if(n!=n)for(;t[i]!==undefined;)e[r++]=t[i++];return e.length=r,e},grep:function(e,t,n){for(var i=[],r=0,a=e.length,o=!n;r<a;r++)!t(e[r],r)!==o&&i.push(e[r]);return i},map:function(e,t,n){var i,r,a=0,o=[];if(y(e))for(i=e.length;a<i;a++)null!=(r=t(e[a],a,n))&&o.push(r);else for(a in e)null!=(r=t(e[a],a,n))&&o.push(r);return l.apply([],o)},guid:1,proxy:function(e,t){var n,i,r;return"string"==typeof t&&(r=e[t],t=e,e=r),m.isFunction(e)?(n=s.call(arguments,2),(i=function(){return e.apply(t||this,n.concat(s.call(arguments)))}).guid=e.guid=e.guid||m.guid++,i):undefined},now:function(){return+new Date},support:f}),"function"==typeof Symbol&&(m.fn[Symbol.iterator]=a[Symbol.iterator]),m.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),(function(e,t){h["[object "+t+"]"]=t.toLowerCase()}));var v=function(e){var t,n,i,r,a,o,s,l,u,c,h,p,d,f,g,m,I,B,_,E="sizzle"+1*new Date,b=e.document,y=0,v=0,T=ae(),C=ae(),N=ae(),V=function(e,t){return e===t&&(h=!0),0},S=1<<31,x={}.hasOwnProperty,w=[],A=w.pop,L=w.push,k=w.push,D=w.slice,M=function(e,t){for(var n=0,i=e.length;n<i;n++)if(e[n]===t)return n;return-1},P="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",R="[\\x20\\t\\r\\n\\f]",H="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",O="\\[[\\x20\\t\\r\\n\\f]*("+H+")(?:"+R+"*([*^$|!~]?=)"+R+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+H+"))|)"+R+"*\\]",F=":("+H+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+O+")*)|.*)\\)|)",Y=new RegExp(R+"+","g"),W=new RegExp("^[\\x20\\t\\r\\n\\f]+|((?:^|[^\\\\])(?:\\\\.)*)[\\x20\\t\\r\\n\\f]+$","g"),G=new RegExp("^[\\x20\\t\\r\\n\\f]*,[\\x20\\t\\r\\n\\f]*"),j=new RegExp("^[\\x20\\t\\r\\n\\f]*([>+~]|[\\x20\\t\\r\\n\\f])[\\x20\\t\\r\\n\\f]*"),Z=new RegExp("=[\\x20\\t\\r\\n\\f]*([^\\]'\"]*?)[\\x20\\t\\r\\n\\f]*\\]","g"),X=new RegExp(F),U=new RegExp("^"+H+"$"),J={ID:new RegExp("^#("+H+")"),CLASS:new RegExp("^\\.("+H+")"),TAG:new RegExp("^("+H+"|[*])"),ATTR:new RegExp("^"+O),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\([\\x20\\t\\r\\n\\f]*(even|odd|(([+-]|)(\\d*)n|)[\\x20\\t\\r\\n\\f]*(?:([+-]|)[\\x20\\t\\r\\n\\f]*(\\d+)|))[\\x20\\t\\r\\n\\f]*\\)|)","i"),bool:new RegExp("^(?:"+P+")$","i"),needsContext:new RegExp("^[\\x20\\t\\r\\n\\f]*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\([\\x20\\t\\r\\n\\f]*((?:-\\d)?\\d*)[\\x20\\t\\r\\n\\f]*\\)|)(?=[^-]|$)","i")},K=/^(?:input|select|textarea|button)$/i,z=/^h\d$/i,Q=/^[^{]+\{\s*\[native \w/,q=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,$=/[+~]/,ee=/'|\\/g,te=new RegExp("\\\\([\\da-f]{1,6}[\\x20\\t\\r\\n\\f]?|([\\x20\\t\\r\\n\\f])|.)","ig"),ne=function(e,t,n){var i="0x"+t-65536;return i!=i||n?t:i<0?String.fromCharCode(i+65536):String.fromCharCode(i>>10|55296,1023&i|56320)},ie=function(){p()};try{k.apply(w=D.call(b.childNodes),b.childNodes),w[b.childNodes.length].nodeType}catch(be){k={apply:w.length?function(e,t){L.apply(e,D.call(t))}:function(e,t){for(var n=e.length,i=0;e[n++]=t[i++];);e.length=n-1}}}function re(e,t,i,r){var a,s,u,c,h,f,I,B,y=t&&t.ownerDocument,v=t?t.nodeType:9;if(i=i||[],"string"!=typeof e||!e||1!==v&&9!==v&&11!==v)return i;if(!r&&((t?t.ownerDocument||t:b)!==d&&p(t),t=t||d,g)){if(11!==v&&(f=q.exec(e)))if(a=f[1]){if(9===v){if(!(u=t.getElementById(a)))return i;if(u.id===a)return i.push(u),i}else if(y&&(u=y.getElementById(a))&&_(t,u)&&u.id===a)return i.push(u),i}else{if(f[2])return k.apply(i,t.getElementsByTagName(e)),i;if((a=f[3])&&n.getElementsByClassName&&t.getElementsByClassName)return k.apply(i,t.getElementsByClassName(a)),i}if(n.qsa&&!N[e+" "]&&(!m||!m.test(e))){if(1!==v)y=t,B=e;else if("object"!==t.nodeName.toLowerCase()){for((c=t.getAttribute("id"))?c=c.replace(ee,"\\$&"):t.setAttribute("id",c=E),s=(I=o(e)).length,h=U.test(c)?"#"+c:"[id='"+c+"']";s--;)I[s]=h+" "+ge(I[s]);B=I.join(","),y=$.test(e)&&de(t.parentNode)||t}if(B)try{return k.apply(i,y.querySelectorAll(B)),i}catch(T){}finally{c===E&&t.removeAttribute("id")}}}return l(e.replace(W,"$1"),t,i,r)}function ae(){var e=[];return function t(n,r){return e.push(n+" ")>i.cacheLength&&delete t[e.shift()],t[n+" "]=r}}function oe(e){return e[E]=!0,e}function se(e){var t=d.createElement("div");try{return!!e(t)}catch(be){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function le(e,t){for(var n=e.split("|"),r=n.length;r--;)i.attrHandle[n[r]]=t}function ue(e,t){var n=t&&e,i=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||S)-(~e.sourceIndex||S);if(i)return i;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function ce(e){return function(t){return"input"===t.nodeName.toLowerCase()&&t.type===e}}function he(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function pe(e){return oe((function(t){return t=+t,oe((function(n,i){for(var r,a=e([],n.length,t),o=a.length;o--;)n[r=a[o]]&&(n[r]=!(i[r]=n[r]))}))}))}function de(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(t in n=re.support={},a=re.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return!!t&&"HTML"!==t.nodeName},p=re.setDocument=function(e){var t,r,o=e?e.ownerDocument||e:b;return o!==d&&9===o.nodeType&&o.documentElement?(f=(d=o).documentElement,g=!a(d),(r=d.defaultView)&&r.top!==r&&(r.addEventListener?r.addEventListener("unload",ie,!1):r.attachEvent&&r.attachEvent("onunload",ie)),n.attributes=se((function(e){return e.className="i",!e.getAttribute("className")})),n.getElementsByTagName=se((function(e){return e.appendChild(d.createComment("")),!e.getElementsByTagName("*").length})),n.getElementsByClassName=Q.test(d.getElementsByClassName),n.getById=se((function(e){return f.appendChild(e).id=E,!d.getElementsByName||!d.getElementsByName(E).length})),n.getById?(i.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&g){var n=t.getElementById(e);return n?[n]:[]}},i.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}}):(delete i.find.ID,i.filter.ID=function(e){var t=e.replace(te,ne);return function(e){var n="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return n&&n.value===t}}),i.find.TAG=n.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):n.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,i=[],r=0,a=t.getElementsByTagName(e);if("*"===e){for(;n=a[r++];)1===n.nodeType&&i.push(n);return i}return a},i.find.CLASS=n.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&g)return t.getElementsByClassName(e)},I=[],m=[],(n.qsa=Q.test(d.querySelectorAll))&&(se((function(e){f.appendChild(e).innerHTML="<a id='"+E+"'></a><select id='"+E+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&m.push("[*^$]=[\\x20\\t\\r\\n\\f]*(?:''|\"\")"),e.querySelectorAll("[selected]").length||m.push("\\[[\\x20\\t\\r\\n\\f]*(?:value|"+P+")"),e.querySelectorAll("[id~="+E+"-]").length||m.push("~="),e.querySelectorAll(":checked").length||m.push(":checked"),e.querySelectorAll("a#"+E+"+*").length||m.push(".#.+[+~]")})),se((function(e){var t=d.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&m.push("name[\\x20\\t\\r\\n\\f]*[*^$|!~]?="),e.querySelectorAll(":enabled").length||m.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),m.push(",.*:")}))),(n.matchesSelector=Q.test(B=f.matches||f.webkitMatchesSelector||f.mozMatchesSelector||f.oMatchesSelector||f.msMatchesSelector))&&se((function(e){n.disconnectedMatch=B.call(e,"div"),B.call(e,"[s!='']:x"),I.push("!=",F)})),m=m.length&&new RegExp(m.join("|")),I=I.length&&new RegExp(I.join("|")),t=Q.test(f.compareDocumentPosition),_=t||Q.test(f.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,i=t&&t.parentNode;return e===i||!(!i||1!==i.nodeType||!(n.contains?n.contains(i):e.compareDocumentPosition&&16&e.compareDocumentPosition(i)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},V=t?function(e,t){if(e===t)return h=!0,0;var i=!e.compareDocumentPosition-!t.compareDocumentPosition;return i||(1&(i=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!n.sortDetached&&t.compareDocumentPosition(e)===i?e===d||e.ownerDocument===b&&_(b,e)?-1:t===d||t.ownerDocument===b&&_(b,t)?1:c?M(c,e)-M(c,t):0:4&i?-1:1)}:function(e,t){if(e===t)return h=!0,0;var n,i=0,r=e.parentNode,a=t.parentNode,o=[e],s=[t];if(!r||!a)return e===d?-1:t===d?1:r?-1:a?1:c?M(c,e)-M(c,t):0;if(r===a)return ue(e,t);for(n=e;n=n.parentNode;)o.unshift(n);for(n=t;n=n.parentNode;)s.unshift(n);for(;o[i]===s[i];)i++;return i?ue(o[i],s[i]):o[i]===b?-1:s[i]===b?1:0},d):d},re.matches=function(e,t){return re(e,null,null,t)},re.matchesSelector=function(e,t){if((e.ownerDocument||e)!==d&&p(e),t=t.replace(Z,"='$1']"),n.matchesSelector&&g&&!N[t+" "]&&(!I||!I.test(t))&&(!m||!m.test(t)))try{var i=B.call(e,t);if(i||n.disconnectedMatch||e.document&&11!==e.document.nodeType)return i}catch(be){}return re(t,d,null,[e]).length>0},re.contains=function(e,t){return(e.ownerDocument||e)!==d&&p(e),_(e,t)},re.attr=function(e,t){(e.ownerDocument||e)!==d&&p(e);var r=i.attrHandle[t.toLowerCase()],a=r&&x.call(i.attrHandle,t.toLowerCase())?r(e,t,!g):undefined;return a!==undefined?a:n.attributes||!g?e.getAttribute(t):(a=e.getAttributeNode(t))&&a.specified?a.value:null},re.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},re.uniqueSort=function(e){var t,i=[],r=0,a=0;if(h=!n.detectDuplicates,c=!n.sortStable&&e.slice(0),e.sort(V),h){for(;t=e[a++];)t===e[a]&&(r=i.push(a));for(;r--;)e.splice(i[r],1)}return c=null,e},r=re.getText=function(e){var t,n="",i=0,a=e.nodeType;if(a){if(1===a||9===a||11===a){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=r(e)}else if(3===a||4===a)return e.nodeValue}else for(;t=e[i++];)n+=r(t);return n},(i=re.selectors={cacheLength:50,createPseudo:oe,match:J,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||re.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&re.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return J.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=o(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=T[e+" "];return t||(t=new RegExp("(^|[\\x20\\t\\r\\n\\f])"+e+"("+R+"|$)"))&&T(e,(function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")}))},ATTR:function(e,t,n){return function(i){var r=re.attr(i,e);return null==r?"!="===t:!t||(r+="","="===t?r===n:"!="===t?r!==n:"^="===t?n&&0===r.indexOf(n):"*="===t?n&&r.indexOf(n)>-1:"$="===t?n&&r.slice(-n.length)===n:"~="===t?(" "+r.replace(Y," ")+" ").indexOf(n)>-1:"|="===t&&(r===n||r.slice(0,n.length+1)===n+"-"))}},CHILD:function(e,t,n,i,r){var a="nth"!==e.slice(0,3),o="last"!==e.slice(-4),s="of-type"===t;return 1===i&&0===r?function(e){return!!e.parentNode}:function(t,n,l){var u,c,h,p,d,f,g=a!==o?"nextSibling":"previousSibling",m=t.parentNode,I=s&&t.nodeName.toLowerCase(),B=!l&&!s,_=!1;if(m){if(a){for(;g;){for(p=t;p=p[g];)if(s?p.nodeName.toLowerCase()===I:1===p.nodeType)return!1;f=g="only"===e&&!f&&"nextSibling"}return!0}if(f=[o?m.firstChild:m.lastChild],o&&B){for(_=(d=(u=(c=(h=(p=m)[E]||(p[E]={}))[p.uniqueID]||(h[p.uniqueID]={}))[e]||[])[0]===y&&u[1])&&u[2],p=d&&m.childNodes[d];p=++d&&p&&p[g]||(_=d=0)||f.pop();)if(1===p.nodeType&&++_&&p===t){c[e]=[y,d,_];break}}else if(B&&(_=d=(u=(c=(h=(p=t)[E]||(p[E]={}))[p.uniqueID]||(h[p.uniqueID]={}))[e]||[])[0]===y&&u[1]),!1===_)for(;(p=++d&&p&&p[g]||(_=d=0)||f.pop())&&((s?p.nodeName.toLowerCase()!==I:1!==p.nodeType)||!++_||(B&&((c=(h=p[E]||(p[E]={}))[p.uniqueID]||(h[p.uniqueID]={}))[e]=[y,_]),p!==t)););return(_-=r)===i||_%i==0&&_/i>=0}}},PSEUDO:function(e,t){var n,r=i.pseudos[e]||i.setFilters[e.toLowerCase()]||re.error("unsupported pseudo: "+e);return r[E]?r(t):r.length>1?(n=[e,e,"",t],i.setFilters.hasOwnProperty(e.toLowerCase())?oe((function(e,n){for(var i,a=r(e,t),o=a.length;o--;)e[i=M(e,a[o])]=!(n[i]=a[o])})):function(e){return r(e,0,n)}):r}},pseudos:{not:oe((function(e){var t=[],n=[],i=s(e.replace(W,"$1"));return i[E]?oe((function(e,t,n,r){for(var a,o=i(e,null,r,[]),s=e.length;s--;)(a=o[s])&&(e[s]=!(t[s]=a))})):function(e,r,a){return t[0]=e,i(t,null,a,n),t[0]=null,!n.pop()}})),has:oe((function(e){return function(t){return re(e,t).length>0}})),contains:oe((function(e){return e=e.replace(te,ne),function(t){return(t.textContent||t.innerText||r(t)).indexOf(e)>-1}})),lang:oe((function(e){return U.test(e||"")||re.error("unsupported lang: "+e),e=e.replace(te,ne).toLowerCase(),function(t){var n;do{if(n=g?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return(n=n.toLowerCase())===e||0===n.indexOf(e+"-")}while((t=t.parentNode)&&1===t.nodeType);return!1}})),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===f},focus:function(e){return e===d.activeElement&&(!d.hasFocus||d.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:function(e){return!1===e.disabled},disabled:function(e){return!0===e.disabled},checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!i.pseudos.empty(e)},header:function(e){return z.test(e.nodeName)},input:function(e){return K.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:pe((function(){return[0]})),last:pe((function(e,t){return[t-1]})),eq:pe((function(e,t,n){return[n<0?n+t:n]})),even:pe((function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e})),odd:pe((function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e})),lt:pe((function(e,t,n){for(var i=n<0?n+t:n;--i>=0;)e.push(i);return e})),gt:pe((function(e,t,n){for(var i=n<0?n+t:n;++i<t;)e.push(i);return e}))}}).pseudos.nth=i.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})i.pseudos[t]=ce(t);for(t in{submit:!0,reset:!0})i.pseudos[t]=he(t);function fe(){}function ge(e){for(var t=0,n=e.length,i="";t<n;t++)i+=e[t].value;return i}function me(e,t,n){var i=t.dir,r=n&&"parentNode"===i,a=v++;return t.first?function(t,n,a){for(;t=t[i];)if(1===t.nodeType||r)return e(t,n,a)}:function(t,n,o){var s,l,u,c=[y,a];if(o){for(;t=t[i];)if((1===t.nodeType||r)&&e(t,n,o))return!0}else for(;t=t[i];)if(1===t.nodeType||r){if((s=(l=(u=t[E]||(t[E]={}))[t.uniqueID]||(u[t.uniqueID]={}))[i])&&s[0]===y&&s[1]===a)return c[2]=s[2];if(l[i]=c,c[2]=e(t,n,o))return!0}}}function Ie(e){return e.length>1?function(t,n,i){for(var r=e.length;r--;)if(!e[r](t,n,i))return!1;return!0}:e[0]}function Be(e,t,n,i,r){for(var a,o=[],s=0,l=e.length,u=null!=t;s<l;s++)(a=e[s])&&(n&&!n(a,i,r)||(o.push(a),u&&t.push(s)));return o}function _e(e,t,n,i,r,a){return i&&!i[E]&&(i=_e(i)),r&&!r[E]&&(r=_e(r,a)),oe((function(a,o,s,l){var u,c,h,p=[],d=[],f=o.length,g=a||function(e,t,n){for(var i=0,r=t.length;i<r;i++)re(e,t[i],n);return n}(t||"*",s.nodeType?[s]:s,[]),m=!e||!a&&t?g:Be(g,p,e,s,l),I=n?r||(a?e:f||i)?[]:o:m;if(n&&n(m,I,s,l),i)for(u=Be(I,d),i(u,[],s,l),c=u.length;c--;)(h=u[c])&&(I[d[c]]=!(m[d[c]]=h));if(a){if(r||e){if(r){for(u=[],c=I.length;c--;)(h=I[c])&&u.push(m[c]=h);r(null,I=[],u,l)}for(c=I.length;c--;)(h=I[c])&&(u=r?M(a,h):p[c])>-1&&(a[u]=!(o[u]=h))}}else I=Be(I===o?I.splice(f,I.length):I),r?r(null,o,I,l):k.apply(o,I)}))}function Ee(e){for(var t,n,r,a=e.length,o=i.relative[e[0].type],s=o||i.relative[" "],l=o?1:0,c=me((function(e){return e===t}),s,!0),h=me((function(e){return M(t,e)>-1}),s,!0),p=[function(e,n,i){var r=!o&&(i||n!==u)||((t=n).nodeType?c(e,n,i):h(e,n,i));return t=null,r}];l<a;l++)if(n=i.relative[e[l].type])p=[me(Ie(p),n)];else{if((n=i.filter[e[l].type].apply(null,e[l].matches))[E]){for(r=++l;r<a&&!i.relative[e[r].type];r++);return _e(l>1&&Ie(p),l>1&&ge(e.slice(0,l-1).concat({value:" "===e[l-2].type?"*":""})).replace(W,"$1"),n,l<r&&Ee(e.slice(l,r)),r<a&&Ee(e=e.slice(r)),r<a&&ge(e))}p.push(n)}return Ie(p)}return fe.prototype=i.filters=i.pseudos,i.setFilters=new fe,o=re.tokenize=function(e,t){var n,r,a,o,s,l,u,c=C[e+" "];if(c)return t?0:c.slice(0);for(s=e,l=[],u=i.preFilter;s;){for(o in n&&!(r=G.exec(s))||(r&&(s=s.slice(r[0].length)||s),l.push(a=[])),n=!1,(r=j.exec(s))&&(n=r.shift(),a.push({value:n,type:r[0].replace(W," ")}),s=s.slice(n.length)),i.filter)!(r=J[o].exec(s))||u[o]&&!(r=u[o](r))||(n=r.shift(),a.push({value:n,type:o,matches:r}),s=s.slice(n.length));if(!n)break}return t?s.length:s?re.error(e):C(e,l).slice(0)},s=re.compile=function(e,t){var n,r=[],a=[],s=N[e+" "];if(!s){for(t||(t=o(e)),n=t.length;n--;)(s=Ee(t[n]))[E]?r.push(s):a.push(s);(s=N(e,function(e,t){var n=t.length>0,r=e.length>0,a=function(a,o,s,l,c){var h,f,m,I=0,B="0",_=a&&[],E=[],b=u,v=a||r&&i.find.TAG("*",c),T=y+=null==b?1:Math.random()||.1,C=v.length;for(c&&(u=o===d||o||c);B!==C&&null!=(h=v[B]);B++){if(r&&h){for(f=0,o||h.ownerDocument===d||(p(h),s=!g);m=e[f++];)if(m(h,o||d,s)){l.push(h);break}c&&(y=T)}n&&((h=!m&&h)&&I--,a&&_.push(h))}if(I+=B,n&&B!==I){for(f=0;m=t[f++];)m(_,E,o,s);if(a){if(I>0)for(;B--;)_[B]||E[B]||(E[B]=A.call(l));E=Be(E)}k.apply(l,E),c&&!a&&E.length>0&&I+t.length>1&&re.uniqueSort(l)}return c&&(y=T,u=b),_};return n?oe(a):a}(a,r))).selector=e}return s},l=re.select=function(e,t,r,a){var l,u,c,h,p,d="function"==typeof e&&e,f=!a&&o(e=d.selector||e);if(r=r||[],1===f.length){if((u=f[0]=f[0].slice(0)).length>2&&"ID"===(c=u[0]).type&&n.getById&&9===t.nodeType&&g&&i.relative[u[1].type]){if(!(t=(i.find.ID(c.matches[0].replace(te,ne),t)||[])[0]))return r;d&&(t=t.parentNode),e=e.slice(u.shift().value.length)}for(l=J.needsContext.test(e)?0:u.length;l--&&(c=u[l],!i.relative[h=c.type]);)if((p=i.find[h])&&(a=p(c.matches[0].replace(te,ne),$.test(u[0].type)&&de(t.parentNode)||t))){if(u.splice(l,1),!(e=a.length&&ge(u)))return k.apply(r,a),r;break}}return(d||s(e,f))(a,t,!g,r,!t||$.test(e)&&de(t.parentNode)||t),r},n.sortStable=E.split("").sort(V).join("")===E,n.detectDuplicates=!!h,p(),n.sortDetached=se((function(e){return 1&e.compareDocumentPosition(d.createElement("div"))})),se((function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")}))||le("type|href|height|width",(function(e,t,n){if(!n)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)})),n.attributes&&se((function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")}))||le("value",(function(e,t,n){if(!n&&"input"===e.nodeName.toLowerCase())return e.defaultValue})),se((function(e){return null==e.getAttribute("disabled")}))||le(P,(function(e,t,n){var i;if(!n)return!0===e[t]?t.toLowerCase():(i=e.getAttributeNode(t))&&i.specified?i.value:null})),re}(n);m.find=v,m.expr=v.selectors,m.expr[":"]=m.expr.pseudos,m.uniqueSort=m.unique=v.uniqueSort,m.text=v.getText,m.isXMLDoc=v.isXML,m.contains=v.contains;var T=function(e,t,n){for(var i=[],r=n!==undefined;(e=e[t])&&9!==e.nodeType;)if(1===e.nodeType){if(r&&m(e).is(n))break;i.push(e)}return i},C=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},N=m.expr.match.needsContext,V=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,S=/^.[^:#\[\.,]*$/;function x(e,t,n){if(m.isFunction(t))return m.grep(e,(function(e,i){return!!t.call(e,i,e)!==n}));if(t.nodeType)return m.grep(e,(function(e){return e===t!==n}));if("string"==typeof t){if(S.test(t))return m.filter(t,e,n);t=m.filter(t,e)}return m.grep(e,(function(e){return m.inArray(e,t)>-1!==n}))}m.filter=function(e,t,n){var i=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===i.nodeType?m.find.matchesSelector(i,e)?[i]:[]:m.find.matches(e,m.grep(t,(function(e){return 1===e.nodeType})))},m.fn.extend({find:function(e){var t,n=[],i=this,r=i.length;if("string"!=typeof e)return this.pushStack(m(e).filter((function(){for(t=0;t<r;t++)if(m.contains(i[t],this))return!0})));for(t=0;t<r;t++)m.find(e,i[t],n);return(n=this.pushStack(r>1?m.unique(n):n)).selector=this.selector?this.selector+" "+e:e,n},filter:function(e){return this.pushStack(x(this,e||[],!1))},not:function(e){return this.pushStack(x(this,e||[],!0))},is:function(e){return!!x(this,"string"==typeof e&&N.test(e)?m(e):e||[],!1).length}});var w,A=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/;(m.fn.init=function(e,t,n){var i,r;if(!e)return this;if(n=n||w,"string"==typeof e){if(!(i="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&e.length>=3?[null,e,null]:A.exec(e))||!i[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(i[1]){if(t=t instanceof m?t[0]:t,m.merge(this,m.parseHTML(i[1],t&&t.nodeType?t.ownerDocument||t:o,!0)),V.test(i[1])&&m.isPlainObject(t))for(i in t)m.isFunction(this[i])?this[i](t[i]):this.attr(i,t[i]);return this}if((r=o.getElementById(i[2]))&&r.parentNode){if(r.id!==i[2])return w.find(e);this.length=1,this[0]=r}return this.context=o,this.selector=e,this}return e.nodeType?(this.context=this[0]=e,this.length=1,this):m.isFunction(e)?"undefined"!=typeof n.ready?n.ready(e):e(m):(e.selector!==undefined&&(this.selector=e.selector,this.context=e.context),m.makeArray(e,this))}).prototype=m.fn,w=m(o);var L=/^(?:parents|prev(?:Until|All))/,k={children:!0,contents:!0,next:!0,prev:!0};function D(e,t){do{e=e[t]}while(e&&1!==e.nodeType);return e}m.fn.extend({has:function(e){var t,n=m(e,this),i=n.length;return this.filter((function(){for(t=0;t<i;t++)if(m.contains(this,n[t]))return!0}))},closest:function(e,t){for(var n,i=0,r=this.length,a=[],o=N.test(e)||"string"!=typeof e?m(e,t||this.context):0;i<r;i++)for(n=this[i];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(o?o.index(n)>-1:1===n.nodeType&&m.find.matchesSelector(n,e))){a.push(n);break}return this.pushStack(a.length>1?m.uniqueSort(a):a)},index:function(e){return e?"string"==typeof e?m.inArray(this[0],m(e)):m.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(m.uniqueSort(m.merge(this.get(),m(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),m.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return T(e,"parentNode")},parentsUntil:function(e,t,n){return T(e,"parentNode",n)},next:function(e){return D(e,"nextSibling")},prev:function(e){return D(e,"previousSibling")},nextAll:function(e){return T(e,"nextSibling")},prevAll:function(e){return T(e,"previousSibling")},nextUntil:function(e,t,n){return T(e,"nextSibling",n)},prevUntil:function(e,t,n){return T(e,"previousSibling",n)},siblings:function(e){return C((e.parentNode||{}).firstChild,e)},children:function(e){return C(e.firstChild)},contents:function(e){return m.nodeName(e,"iframe")?e.contentDocument||e.contentWindow.document:m.merge([],e.childNodes)}},(function(e,t){m.fn[e]=function(n,i){var r=m.map(this,t,n);return"Until"!==e.slice(-5)&&(i=n),i&&"string"==typeof i&&(r=m.filter(i,r)),this.length>1&&(k[e]||(r=m.uniqueSort(r)),L.test(e)&&(r=r.reverse())),this.pushStack(r)}}));var M,P,R=/\S+/g;function H(){o.addEventListener?(o.removeEventListener("DOMContentLoaded",O),n.removeEventListener("load",O)):(o.detachEvent("onreadystatechange",O),n.detachEvent("onload",O))}function O(){(o.addEventListener||"load"===n.event.type||"complete"===o.readyState)&&(H(),m.ready())}for(P in m.Callbacks=function(e){e="string"==typeof e?function(e){var t={};return m.each(e.match(R)||[],(function(e,n){t[n]=!0})),t}(e):m.extend({},e);var t,n,i,r,a=[],o=[],s=-1,l=function(){for(r=e.once,i=t=!0;o.length;s=-1)for(n=o.shift();++s<a.length;)!1===a[s].apply(n[0],n[1])&&e.stopOnFalse&&(s=a.length,n=!1);e.memory||(n=!1),t=!1,r&&(a=n?[]:"")},u={add:function(){return a&&(n&&!t&&(s=a.length-1,o.push(n)),function i(t){m.each(t,(function(t,n){m.isFunction(n)?e.unique&&u.has(n)||a.push(n):n&&n.length&&"string"!==m.type(n)&&i(n)}))}(arguments),n&&!t&&l()),this},remove:function(){return m.each(arguments,(function(e,t){for(var n;(n=m.inArray(t,a,n))>-1;)a.splice(n,1),n<=s&&s--})),this},has:function(e){return e?m.inArray(e,a)>-1:a.length>0},empty:function(){return a&&(a=[]),this},disable:function(){return r=o=[],a=n="",this},disabled:function(){return!a},lock:function(){return r=!0,n||u.disable(),this},locked:function(){return!!r},fireWith:function(e,n){return r||(n=[e,(n=n||[]).slice?n.slice():n],o.push(n),t||l()),this},fire:function(){return u.fireWith(this,arguments),this},fired:function(){return!!i}};return u},m.extend({Deferred:function(e){var t=[["resolve","done",m.Callbacks("once memory"),"resolved"],["reject","fail",m.Callbacks("once memory"),"rejected"],["notify","progress",m.Callbacks("memory")]],n="pending",i={state:function(){return n},always:function(){return r.done(arguments).fail(arguments),this},then:function(){var e=arguments;return m.Deferred((function(n){m.each(t,(function(t,a){var o=m.isFunction(e[t])&&e[t];r[a[1]]((function(){var e=o&&o.apply(this,arguments);e&&m.isFunction(e.promise)?e.promise().progress(n.notify).done(n.resolve).fail(n.reject):n[a[0]+"With"](this===i?n.promise():this,o?[e]:arguments)}))})),e=null})).promise()},promise:function(e){return null!=e?m.extend(e,i):i}},r={};return i.pipe=i.then,m.each(t,(function(e,a){var o=a[2],s=a[3];i[a[1]]=o.add,s&&o.add((function(){n=s}),t[1^e][2].disable,t[2][2].lock),r[a[0]]=function(){return r[a[0]+"With"](this===r?i:this,arguments),this},r[a[0]+"With"]=o.fireWith})),i.promise(r),e&&e.call(r,r),r},when:function(e){var t,n,i,r=0,a=s.call(arguments),o=a.length,l=1!==o||e&&m.isFunction(e.promise)?o:0,u=1===l?e:m.Deferred(),c=function(e,n,i){return function(r){n[e]=this,i[e]=arguments.length>1?s.call(arguments):r,i===t?u.notifyWith(n,i):--l||u.resolveWith(n,i)}};if(o>1)for(t=new Array(o),n=new Array(o),i=new Array(o);r<o;r++)a[r]&&m.isFunction(a[r].promise)?a[r].promise().progress(c(r,n,t)).done(c(r,i,a)).fail(u.reject):--l;return l||u.resolveWith(i,a),u.promise()}}),m.fn.ready=function(e){return m.ready.promise().done(e),this},m.extend({isReady:!1,readyWait:1,holdReady:function(e){e?m.readyWait++:m.ready(!0)},ready:function(e){(!0===e?--m.readyWait:m.isReady)||(m.isReady=!0,!0!==e&&--m.readyWait>0||(M.resolveWith(o,[m]),m.fn.triggerHandler&&(m(o).triggerHandler("ready"),m(o).off("ready"))))}}),m.ready.promise=function(e){if(!M)if(M=m.Deferred(),"complete"===o.readyState||"loading"!==o.readyState&&!o.documentElement.doScroll)n.setTimeout(m.ready);else if(o.addEventListener)o.addEventListener("DOMContentLoaded",O),n.addEventListener("load",O);else{o.attachEvent("onreadystatechange",O),n.attachEvent("onload",O);var t=!1;try{t=null==n.frameElement&&o.documentElement}catch(i){}t&&t.doScroll&&function e(){if(!m.isReady){try{t.doScroll("left")}catch(i){return n.setTimeout(e,50)}H(),m.ready()}}()}return M.promise(e)},m.ready.promise(),m(f))break;f.ownFirst="0"===P,f.inlineBlockNeedsLayout=!1,m((function(){var e,t,n,i;(n=o.getElementsByTagName("body")[0])&&n.style&&(t=o.createElement("div"),(i=o.createElement("div")).style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",n.appendChild(i).appendChild(t),"undefined"!=typeof t.style.zoom&&(t.style.cssText="display:inline;margin:0;border:0;padding:1px;width:1px;zoom:1",f.inlineBlockNeedsLayout=e=3===t.offsetWidth,e&&(n.style.zoom=1)),n.removeChild(i))})),function(){var e=o.createElement("div");f.deleteExpando=!0;try{delete e.test}catch(t){f.deleteExpando=!1}e=null}();var F,Y=function(e){var t=m.noData[(e.nodeName+" ").toLowerCase()],n=+e.nodeType||1;return(1===n||9===n)&&(!t||!0!==t&&e.getAttribute("classid")===t)},W=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,G=/([A-Z])/g;function j(e,t,n){if(n===undefined&&1===e.nodeType){var i="data-"+t.replace(G,"-$1").toLowerCase();if("string"==typeof(n=e.getAttribute(i))){try{n="true"===n||"false"!==n&&("null"===n?null:+n+""===n?+n:W.test(n)?m.parseJSON(n):n)}catch(r){}m.data(e,t,n)}else n=undefined}return n}function Z(e){var t;for(t in e)if(("data"!==t||!m.isEmptyObject(e[t]))&&"toJSON"!==t)return!1;return!0}function X(e,t,n,i){if(Y(e)){var r,o,s=m.expando,l=e.nodeType,u=l?m.cache:e,c=l?e[s]:e[s]&&s;if(c&&u[c]&&(i||u[c].data)||n!==undefined||"string"!=typeof t)return c||(c=l?e[s]=a.pop()||m.guid++:s),u[c]||(u[c]=l?{}:{toJSON:m.noop}),"object"!=typeof t&&"function"!=typeof t||(i?u[c]=m.extend(u[c],t):u[c].data=m.extend(u[c].data,t)),o=u[c],i||(o.data||(o.data={}),o=o.data),n!==undefined&&(o[m.camelCase(t)]=n),"string"==typeof t?null==(r=o[t])&&(r=o[m.camelCase(t)]):r=o,r}}function U(e,t,n){if(Y(e)){var i,r,a=e.nodeType,o=a?m.cache:e,s=a?e[m.expando]:m.expando;if(o[s]){if(t&&(i=n?o[s]:o[s].data)){r=(t=m.isArray(t)?t.concat(m.map(t,m.camelCase)):t in i||(t=m.camelCase(t))in i?[t]:t.split(" ")).length;for(;r--;)delete i[t[r]];if(n?!Z(i):!m.isEmptyObject(i))return}(n||(delete o[s].data,Z(o[s])))&&(a?m.cleanData([e],!0):f.deleteExpando||o!=o.window?delete o[s]:o[s]=undefined)}}}m.extend({cache:{},noData:{"applet ":!0,"embed ":!0,"object ":"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(e){return!!(e=e.nodeType?m.cache[e[m.expando]]:e[m.expando])&&!Z(e)},data:function(e,t,n){return X(e,t,n)},removeData:function(e,t){return U(e,t)},_data:function(e,t,n){return X(e,t,n,!0)},_removeData:function(e,t){return U(e,t,!0)}}),m.fn.extend({data:function(e,t){var n,i,r,a=this[0],o=a&&a.attributes;if(e===undefined){if(this.length&&(r=m.data(a),1===a.nodeType&&!m._data(a,"parsedAttrs"))){for(n=o.length;n--;)o[n]&&0===(i=o[n].name).indexOf("data-")&&j(a,i=m.camelCase(i.slice(5)),r[i]);m._data(a,"parsedAttrs",!0)}return r}return"object"==typeof e?this.each((function(){m.data(this,e)})):arguments.length>1?this.each((function(){m.data(this,e,t)})):a?j(a,e,m.data(a,e)):undefined},removeData:function(e){return this.each((function(){m.removeData(this,e)}))}}),m.extend({queue:function(e,t,n){var i;if(e)return t=(t||"fx")+"queue",i=m._data(e,t),n&&(!i||m.isArray(n)?i=m._data(e,t,m.makeArray(n)):i.push(n)),i||[]},dequeue:function(e,t){t=t||"fx";var n=m.queue(e,t),i=n.length,r=n.shift(),a=m._queueHooks(e,t);"inprogress"===r&&(r=n.shift(),i--),r&&("fx"===t&&n.unshift("inprogress"),delete a.stop,r.call(e,(function(){m.dequeue(e,t)}),a)),!i&&a&&a.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return m._data(e,n)||m._data(e,n,{empty:m.Callbacks("once memory").add((function(){m._removeData(e,t+"queue"),m._removeData(e,n)}))})}}),m.fn.extend({queue:function(e,t){var n=2;return"string"!=typeof e&&(t=e,e="fx",n--),arguments.length<n?m.queue(this[0],e):t===undefined?this:this.each((function(){var n=m.queue(this,e,t);m._queueHooks(this,e),"fx"===e&&"inprogress"!==n[0]&&m.dequeue(this,e)}))},dequeue:function(e){return this.each((function(){m.dequeue(this,e)}))},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,i=1,r=m.Deferred(),a=this,o=this.length,s=function(){--i||r.resolveWith(a,[a])};for("string"!=typeof e&&(t=e,e=undefined),e=e||"fx";o--;)(n=m._data(a[o],e+"queueHooks"))&&n.empty&&(i++,n.empty.add(s));return s(),r.promise(t)}}),f.shrinkWrapBlocks=function(){return null!=F?F:(F=!1,(t=o.getElementsByTagName("body")[0])&&t.style?(e=o.createElement("div"),(n=o.createElement("div")).style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",t.appendChild(n).appendChild(e),"undefined"!=typeof e.style.zoom&&(e.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:1px;width:1px;zoom:1",e.appendChild(o.createElement("div")).style.width="5px",F=3!==e.offsetWidth),t.removeChild(n),F):void 0);var e,t,n};var J=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,K=new RegExp("^(?:([+-])=|)("+J+")([a-z%]*)$","i"),z=["Top","Right","Bottom","Left"],Q=function(e,t){return e=t||e,"none"===m.css(e,"display")||!m.contains(e.ownerDocument,e)};function q(e,t,n,i){var r,a=1,o=20,s=i?function(){return i.cur()}:function(){return m.css(e,t,"")},l=s(),u=n&&n[3]||(m.cssNumber[t]?"":"px"),c=(m.cssNumber[t]||"px"!==u&&+l)&&K.exec(m.css(e,t));if(c&&c[3]!==u){u=u||c[3],n=n||[],c=+l||1;do{c/=a=a||".5",m.style(e,t,c+u)}while(a!==(a=s()/l)&&1!==a&&--o)}return n&&(c=+c||+l||0,r=n[1]?c+(n[1]+1)*n[2]:+n[2],i&&(i.unit=u,i.start=c,i.end=r)),r}var $,ee,te,ne=function(e,t,n,i,r,a,o){var s=0,l=e.length,u=null==n;if("object"===m.type(n))for(s in r=!0,n)ne(e,t,s,n[s],!0,a,o);else if(i!==undefined&&(r=!0,m.isFunction(i)||(o=!0),u&&(o?(t.call(e,i),t=null):(u=t,t=function(e,t,n){return u.call(m(e),n)})),t))for(;s<l;s++)t(e[s],n,o?i:i.call(e[s],s,t(e[s],n)));return r?e:u?t.call(e):l?t(e[0],n):a},ie=/^(?:checkbox|radio)$/i,re=/<([\w:-]+)/,ae=/^$|\/(?:java|ecma)script/i,oe=/^\s+/,se="abbr|article|aside|audio|bdi|canvas|data|datalist|details|dialog|figcaption|figure|footer|header|hgroup|main|mark|meter|nav|output|picture|progress|section|summary|template|time|video";function le(e){var t=se.split("|"),n=e.createDocumentFragment();if(n.createElement)for(;t.length;)n.createElement(t.pop());return n}$=o.createElement("div"),ee=o.createDocumentFragment(),te=o.createElement("input"),$.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",f.leadingWhitespace=3===$.firstChild.nodeType,f.tbody=!$.getElementsByTagName("tbody").length,f.htmlSerialize=!!$.getElementsByTagName("link").length,f.html5Clone="<:nav></:nav>"!==o.createElement("nav").cloneNode(!0).outerHTML,te.type="checkbox",te.checked=!0,ee.appendChild(te),f.appendChecked=te.checked,$.innerHTML="<textarea>x</textarea>",f.noCloneChecked=!!$.cloneNode(!0).lastChild.defaultValue,ee.appendChild($),(te=o.createElement("input")).setAttribute("type","radio"),te.setAttribute("checked","checked"),te.setAttribute("name","t"),$.appendChild(te),f.checkClone=$.cloneNode(!0).cloneNode(!0).lastChild.checked,f.noCloneEvent=!!$.addEventListener,$[m.expando]=1,f.attributes=!$.getAttribute(m.expando),$.innerHTML="<option></option>",f.option=!!$.lastChild;var ue={legend:[1,"<fieldset>","</fieldset>"],area:[1,"<map>","</map>"],param:[1,"<object>","</object>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:f.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]};function ce(e,t){var n,i,r=0,a="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):undefined;if(!a)for(a=[],n=e.childNodes||e;null!=(i=n[r]);r++)!t||m.nodeName(i,t)?a.push(i):m.merge(a,ce(i,t));return t===undefined||t&&m.nodeName(e,t)?m.merge([e],a):a}function he(e,t){for(var n,i=0;null!=(n=e[i]);i++)m._data(n,"globalEval",!t||m._data(t[i],"globalEval"))}ue.tbody=ue.tfoot=ue.colgroup=ue.caption=ue.thead,ue.th=ue.td,f.option||(ue.optgroup=ue.option=[1,"<select multiple='multiple'>","</select>"]);var pe=/<|&#?\w+;/,de=/<tbody/i;function fe(e){ie.test(e.type)&&(e.defaultChecked=e.checked)}function ge(e,t,n,i,r){for(var a,o,s,l,u,c,h,p=e.length,d=le(t),g=[],I=0;I<p;I++)if((o=e[I])||0===o)if("object"===m.type(o))m.merge(g,o.nodeType?[o]:o);else if(pe.test(o)){for(l=l||d.appendChild(t.createElement("div")),u=(re.exec(o)||["",""])[1].toLowerCase(),h=ue[u]||ue._default,l.innerHTML=h[1]+m.htmlPrefilter(o)+h[2],a=h[0];a--;)l=l.lastChild;if(!f.leadingWhitespace&&oe.test(o)&&g.push(t.createTextNode(oe.exec(o)[0])),!f.tbody)for(a=(o="table"!==u||de.test(o)?"<table>"!==h[1]||de.test(o)?0:l:l.firstChild)&&o.childNodes.length;a--;)m.nodeName(c=o.childNodes[a],"tbody")&&!c.childNodes.length&&o.removeChild(c);for(m.merge(g,l.childNodes),l.textContent="";l.firstChild;)l.removeChild(l.firstChild);l=d.lastChild}else g.push(t.createTextNode(o));for(l&&d.removeChild(l),f.appendChecked||m.grep(ce(g,"input"),fe),I=0;o=g[I++];)if(i&&m.inArray(o,i)>-1)r&&r.push(o);else if(s=m.contains(o.ownerDocument,o),l=ce(d.appendChild(o),"script"),s&&he(l),n)for(a=0;o=l[a++];)ae.test(o.type||"")&&n.push(o);return l=null,d}!function(){var e,t,i=o.createElement("div");for(e in{submit:!0,change:!0,focusin:!0})t="on"+e,(f[e]=t in n)||(i.setAttribute(t,"t"),f[e]=!1===i.attributes[t].expando);i=null}();var me=/^(?:input|select|textarea)$/i,Ie=/^key/,Be=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,_e=/^(?:focusinfocus|focusoutblur)$/,Ee=/^([^.]*)(?:\.(.+)|)/;function be(){return!0}function ye(){return!1}function ve(){try{return o.activeElement}catch(e){}}function Te(e,t,n,i,r,a){var o,s;if("object"==typeof t){for(s in"string"!=typeof n&&(i=i||n,n=undefined),t)Te(e,s,n,i,t[s],a);return e}if(null==i&&null==r?(r=n,i=n=undefined):null==r&&("string"==typeof n?(r=i,i=undefined):(r=i,i=n,n=undefined)),!1===r)r=ye;else if(!r)return e;return 1===a&&(o=r,(r=function(e){return m().off(e),o.apply(this,arguments)}).guid=o.guid||(o.guid=m.guid++)),e.each((function(){m.event.add(this,t,r,i,n)}))}m.event={global:{},add:function(e,t,n,i,r){var a,o,s,l,u,c,h,p,d,f,g,I=m._data(e);if(I){for(n.handler&&(n=(l=n).handler,r=l.selector),n.guid||(n.guid=m.guid++),(o=I.events)||(o=I.events={}),(c=I.handle)||((c=I.handle=function(e){return void 0===m||e&&m.event.triggered===e.type?undefined:m.event.dispatch.apply(c.elem,arguments)}).elem=e),s=(t=(t||"").match(R)||[""]).length;s--;)d=g=(a=Ee.exec(t[s])||[])[1],f=(a[2]||"").split(".").sort(),d&&(u=m.event.special[d]||{},d=(r?u.delegateType:u.bindType)||d,u=m.event.special[d]||{},h=m.extend({type:d,origType:g,data:i,handler:n,guid:n.guid,selector:r,needsContext:r&&m.expr.match.needsContext.test(r),namespace:f.join(".")},l),(p=o[d])||((p=o[d]=[]).delegateCount=0,u.setup&&!1!==u.setup.call(e,i,f,c)||(e.addEventListener?e.addEventListener(d,c,!1):e.attachEvent&&e.attachEvent("on"+d,c))),u.add&&(u.add.call(e,h),h.handler.guid||(h.handler.guid=n.guid)),r?p.splice(p.delegateCount++,0,h):p.push(h),m.event.global[d]=!0);e=null}},remove:function(e,t,n,i,r){var a,o,s,l,u,c,h,p,d,f,g,I=m.hasData(e)&&m._data(e);if(I&&(c=I.events)){for(u=(t=(t||"").match(R)||[""]).length;u--;)if(d=g=(s=Ee.exec(t[u])||[])[1],f=(s[2]||"").split(".").sort(),d){for(h=m.event.special[d]||{},p=c[d=(i?h.delegateType:h.bindType)||d]||[],s=s[2]&&new RegExp("(^|\\.)"+f.join("\\.(?:.*\\.|)")+"(\\.|$)"),l=a=p.length;a--;)o=p[a],!r&&g!==o.origType||n&&n.guid!==o.guid||s&&!s.test(o.namespace)||i&&i!==o.selector&&("**"!==i||!o.selector)||(p.splice(a,1),o.selector&&p.delegateCount--,h.remove&&h.remove.call(e,o));l&&!p.length&&(h.teardown&&!1!==h.teardown.call(e,f,I.handle)||m.removeEvent(e,d,I.handle),delete c[d])}else for(d in c)m.event.remove(e,d+t[u],n,i,!0);m.isEmptyObject(c)&&(delete I.handle,m._removeData(e,"events"))}},trigger:function(e,t,i,r){var a,s,l,u,c,h,p,f=[i||o],g=d.call(e,"type")?e.type:e,I=d.call(e,"namespace")?e.namespace.split("."):[];if(l=h=i=i||o,3!==i.nodeType&&8!==i.nodeType&&!_e.test(g+m.event.triggered)&&(g.indexOf(".")>-1&&(I=g.split("."),g=I.shift(),I.sort()),s=g.indexOf(":")<0&&"on"+g,(e=e[m.expando]?e:new m.Event(g,"object"==typeof e&&e)).isTrigger=r?2:3,e.namespace=I.join("."),e.rnamespace=e.namespace?new RegExp("(^|\\.)"+I.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,e.result=undefined,e.target||(e.target=i),t=null==t?[e]:m.makeArray(t,[e]),c=m.event.special[g]||{},r||!c.trigger||!1!==c.trigger.apply(i,t))){if(!r&&!c.noBubble&&!m.isWindow(i)){for(u=c.delegateType||g,_e.test(u+g)||(l=l.parentNode);l;l=l.parentNode)f.push(l),h=l;h===(i.ownerDocument||o)&&f.push(h.defaultView||h.parentWindow||n)}for(p=0;(l=f[p++])&&!e.isPropagationStopped();)e.type=p>1?u:c.bindType||g,(a=(m._data(l,"events")||{})[e.type]&&m._data(l,"handle"))&&a.apply(l,t),(a=s&&l[s])&&a.apply&&Y(l)&&(e.result=a.apply(l,t),!1===e.result&&e.preventDefault());if(e.type=g,!r&&!e.isDefaultPrevented()&&(!c._default||!1===c._default.apply(f.pop(),t))&&Y(i)&&s&&i[g]&&!m.isWindow(i)){(h=i[s])&&(i[s]=null),m.event.triggered=g;try{i[g]()}catch(B){}m.event.triggered=undefined,h&&(i[s]=h)}return e.result}},dispatch:function(e){e=m.event.fix(e);var t,n,i,r,a,o=[],l=s.call(arguments),u=(m._data(this,"events")||{})[e.type]||[],c=m.event.special[e.type]||{};if(l[0]=e,e.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,e)){for(o=m.event.handlers.call(this,e,u),t=0;(r=o[t++])&&!e.isPropagationStopped();)for(e.currentTarget=r.elem,n=0;(a=r.handlers[n++])&&!e.isImmediatePropagationStopped();)e.rnamespace&&!e.rnamespace.test(a.namespace)||(e.handleObj=a,e.data=a.data,(i=((m.event.special[a.origType]||{}).handle||a.handler).apply(r.elem,l))!==undefined&&!1===(e.result=i)&&(e.preventDefault(),e.stopPropagation()));return c.postDispatch&&c.postDispatch.call(this,e),e.result}},handlers:function(e,t){var n,i,r,a,o=[],s=t.delegateCount,l=e.target;if(s&&l.nodeType&&("click"!==e.type||isNaN(e.button)||e.button<1))for(;l!=this;l=l.parentNode||this)if(1===l.nodeType&&(!0!==l.disabled||"click"!==e.type)){for(i=[],n=0;n<s;n++)i[r=(a=t[n]).selector+" "]===undefined&&(i[r]=a.needsContext?m(r,this).index(l)>-1:m.find(r,this,null,[l]).length),i[r]&&i.push(a);i.length&&o.push({elem:l,handlers:i})}return s<t.length&&o.push({elem:this,handlers:t.slice(s)}),o},fix:function(e){if(e[m.expando])return e;var t,n,i,r=e.type,a=e,s=this.fixHooks[r];for(s||(this.fixHooks[r]=s=Be.test(r)?this.mouseHooks:Ie.test(r)?this.keyHooks:{}),i=s.props?this.props.concat(s.props):this.props,e=new m.Event(a),t=i.length;t--;)e[n=i[t]]=a[n];return e.target||(e.target=a.srcElement||o),3===e.target.nodeType&&(e.target=e.target.parentNode),e.metaKey=!!e.metaKey,s.filter?s.filter(e,a):e},props:"altKey bubbles cancelable ctrlKey currentTarget detail eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(e,t){return null==e.which&&(e.which=null!=t.charCode?t.charCode:t.keyCode),e}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(e,t){var n,i,r,a=t.button,s=t.fromElement;return null==e.pageX&&null!=t.clientX&&(r=(i=e.target.ownerDocument||o).documentElement,n=i.body,e.pageX=t.clientX+(r&&r.scrollLeft||n&&n.scrollLeft||0)-(r&&r.clientLeft||n&&n.clientLeft||0),e.pageY=t.clientY+(r&&r.scrollTop||n&&n.scrollTop||0)-(r&&r.clientTop||n&&n.clientTop||0)),!e.relatedTarget&&s&&(e.relatedTarget=s===e.target?t.toElement:s),e.which||a===undefined||(e.which=1&a?1:2&a?3:4&a?2:0),e}},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==ve()&&this.focus)try{return this.focus(),!1}catch(e){}},delegateType:"focusin"},blur:{trigger:function(){if(this===ve()&&this.blur)return this.blur(),!1},delegateType:"focusout"},click:{trigger:function(){if(m.nodeName(this,"input")&&"checkbox"===this.type&&this.click)return this.click(),!1},_default:function(e){return m.nodeName(e.target,"a")}},beforeunload:{postDispatch:function(e){e.result!==undefined&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}},simulate:function(e,t,n){var i=m.extend(new m.Event,n,{type:e,isSimulated:!0});m.event.trigger(i,null,t),i.isDefaultPrevented()&&n.preventDefault()}},m.removeEvent=o.removeEventListener?function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)}:function(e,t,n){var i="on"+t;e.detachEvent&&("undefined"==typeof e[i]&&(e[i]=null),e.detachEvent(i,n))},m.Event=function(e,t){if(!(this instanceof m.Event))return new m.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||e.defaultPrevented===undefined&&!1===e.returnValue?be:ye):this.type=e,t&&m.extend(this,t),this.timeStamp=e&&e.timeStamp||m.now(),this[m.expando]=!0},m.Event.prototype={constructor:m.Event,isDefaultPrevented:ye,isPropagationStopped:ye,isImmediatePropagationStopped:ye,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=be,e&&(e.preventDefault?e.preventDefault():e.returnValue=!1)},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=be,e&&!this.isSimulated&&(e.stopPropagation&&e.stopPropagation(),e.cancelBubble=!0)},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=be,e&&e.stopImmediatePropagation&&e.stopImmediatePropagation(),this.stopPropagation()}},m.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},(function(e,t){m.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,i=this,r=e.relatedTarget,a=e.handleObj;return r&&(r===i||m.contains(i,r))||(e.type=a.origType,n=a.handler.apply(this,arguments),e.type=t),n}}})),f.submit||(m.event.special.submit={setup:function(){if(m.nodeName(this,"form"))return!1;m.event.add(this,"click._submit keypress._submit",(function(e){var t=e.target,n=m.nodeName(t,"input")||m.nodeName(t,"button")?m.prop(t,"form"):undefined;n&&!m._data(n,"submit")&&(m.event.add(n,"submit._submit",(function(e){e._submitBubble=!0})),m._data(n,"submit",!0))}))},postDispatch:function(e){e._submitBubble&&(delete e._submitBubble,this.parentNode&&!e.isTrigger&&m.event.simulate("submit",this.parentNode,e))},teardown:function(){if(m.nodeName(this,"form"))return!1;m.event.remove(this,"._submit")}}),f.change||(m.event.special.change={setup:function(){if(me.test(this.nodeName))return"checkbox"!==this.type&&"radio"!==this.type||(m.event.add(this,"propertychange._change",(function(e){"checked"===e.originalEvent.propertyName&&(this._justChanged=!0)})),m.event.add(this,"click._change",(function(e){this._justChanged&&!e.isTrigger&&(this._justChanged=!1),m.event.simulate("change",this,e)}))),!1;m.event.add(this,"beforeactivate._change",(function(e){var t=e.target;me.test(t.nodeName)&&!m._data(t,"change")&&(m.event.add(t,"change._change",(function(e){!this.parentNode||e.isSimulated||e.isTrigger||m.event.simulate("change",this.parentNode,e)})),m._data(t,"change",!0))}))},handle:function(e){var t=e.target;if(this!==t||e.isSimulated||e.isTrigger||"radio"!==t.type&&"checkbox"!==t.type)return e.handleObj.handler.apply(this,arguments)},teardown:function(){return m.event.remove(this,"._change"),!me.test(this.nodeName)}}),f.focusin||m.each({focus:"focusin",blur:"focusout"},(function(e,t){var n=function(e){m.event.simulate(t,e.target,m.event.fix(e))};m.event.special[t]={setup:function(){var i=this.ownerDocument||this,r=m._data(i,t);r||i.addEventListener(e,n,!0),m._data(i,t,(r||0)+1)},teardown:function(){var i=this.ownerDocument||this,r=m._data(i,t)-1;r?m._data(i,t,r):(i.removeEventListener(e,n,!0),m._removeData(i,t))}}})),m.fn.extend({on:function(e,t,n,i){return Te(this,e,t,n,i)},one:function(e,t,n,i){return Te(this,e,t,n,i,1)},off:function(e,t,n){var i,r;if(e&&e.preventDefault&&e.handleObj)return i=e.handleObj,m(e.delegateTarget).off(i.namespace?i.origType+"."+i.namespace:i.origType,i.selector,i.handler),this;if("object"==typeof e){for(r in e)this.off(r,t,e[r]);return this}return!1!==t&&"function"!=typeof t||(n=t,t=undefined),!1===n&&(n=ye),this.each((function(){m.event.remove(this,e,n,t)}))},trigger:function(e,t){return this.each((function(){m.event.trigger(e,t,this)}))},triggerHandler:function(e,t){var n=this[0];if(n)return m.event.trigger(e,t,n,!0)}});var Ce=/ jQuery\d+="(?:null|\d+)"/g,Ne=new RegExp("<(?:"+se+")[\\s/>]","i"),Ve=/<script|<style|<link/i,Se=/checked\s*(?:[^=]|=\s*.checked.)/i,xe=/^true\/(.*)/,we=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,Ae=le(o).appendChild(o.createElement("div"));function Le(e,t){return m.nodeName(e,"table")&&m.nodeName(11!==t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function ke(e){return e.type=(null!==m.find.attr(e,"type"))+"/"+e.type,e}function De(e){var t=xe.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function Me(e,t){if(1===t.nodeType&&m.hasData(e)){var n,i,r,a=m._data(e),o=m._data(t,a),s=a.events;if(s)for(n in delete o.handle,o.events={},s)for(i=0,r=s[n].length;i<r;i++)m.event.add(t,n,s[n][i]);o.data&&(o.data=m.extend({},o.data))}}function Pe(e,t){var n,i,r;if(1===t.nodeType){if(n=t.nodeName.toLowerCase(),!f.noCloneEvent&&t[m.expando]){for(i in(r=m._data(t)).events)m.removeEvent(t,i,r.handle);t.removeAttribute(m.expando)}"script"===n&&t.text!==e.text?(ke(t).text=e.text,De(t)):"object"===n?(t.parentNode&&(t.outerHTML=e.outerHTML),f.html5Clone&&e.innerHTML&&!m.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):"input"===n&&ie.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):"option"===n?t.defaultSelected=t.selected=e.defaultSelected:"input"!==n&&"textarea"!==n||(t.defaultValue=e.defaultValue)}}function Re(e,t,n,i){t=l.apply([],t);var r,a,o,s,u,c,h=0,p=e.length,d=p-1,g=t[0],I=m.isFunction(g);if(I||p>1&&"string"==typeof g&&!f.checkClone&&Se.test(g))return e.each((function(r){var a=e.eq(r);I&&(t[0]=g.call(this,r,a.html())),Re(a,t,n,i)}));if(p&&(r=(c=ge(t,e[0].ownerDocument,!1,e,i)).firstChild,1===c.childNodes.length&&(c=r),r||i)){for(o=(s=m.map(ce(c,"script"),ke)).length;h<p;h++)a=c,h!==d&&(a=m.clone(a,!0,!0),o&&m.merge(s,ce(a,"script"))),n.call(e[h],a,h);if(o)for(u=s[s.length-1].ownerDocument,m.map(s,De),h=0;h<o;h++)a=s[h],ae.test(a.type||"")&&!m._data(a,"globalEval")&&m.contains(u,a)&&(a.src?m._evalUrl&&m._evalUrl(a.src):m.globalEval((a.text||a.textContent||a.innerHTML||"").replace(we,"")));c=r=null}return e}function He(e,t,n){for(var i,r=t?m.filter(t,e):e,a=0;null!=(i=r[a]);a++)n||1!==i.nodeType||m.cleanData(ce(i)),i.parentNode&&(n&&m.contains(i.ownerDocument,i)&&he(ce(i,"script")),i.parentNode.removeChild(i));return e}m.extend({htmlPrefilter:function(e){return e},clone:function(e,t,n){var i,r,a,o,s,l=m.contains(e.ownerDocument,e);if(f.html5Clone||m.isXMLDoc(e)||!Ne.test("<"+e.nodeName+">")?a=e.cloneNode(!0):(Ae.innerHTML=e.outerHTML,Ae.removeChild(a=Ae.firstChild)),!(f.noCloneEvent&&f.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||m.isXMLDoc(e)))for(i=ce(a),s=ce(e),o=0;null!=(r=s[o]);++o)i[o]&&Pe(r,i[o]);if(t)if(n)for(s=s||ce(e),i=i||ce(a),o=0;null!=(r=s[o]);o++)Me(r,i[o]);else Me(e,a);return(i=ce(a,"script")).length>0&&he(i,!l&&ce(e,"script")),i=s=r=null,a},cleanData:function(e,t){for(var n,i,r,o,s=0,l=m.expando,u=m.cache,c=f.attributes,h=m.event.special;null!=(n=e[s]);s++)if((t||Y(n))&&(o=(r=n[l])&&u[r])){if(o.events)for(i in o.events)h[i]?m.event.remove(n,i):m.removeEvent(n,i,o.handle);u[r]&&(delete u[r],c||"undefined"==typeof n.removeAttribute?n[l]=undefined:n.removeAttribute(l),a.push(r))}}}),m.fn.extend({domManip:Re,detach:function(e){return He(this,e,!0)},remove:function(e){return He(this,e)},text:function(e){return ne(this,(function(e){return e===undefined?m.text(this):this.empty().append((this[0]&&this[0].ownerDocument||o).createTextNode(e))}),null,e,arguments.length)},append:function(){return Re(this,arguments,(function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||Le(this,e).appendChild(e)}))},prepend:function(){return Re(this,arguments,(function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Le(this,e);t.insertBefore(e,t.firstChild)}}))},before:function(){return Re(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this)}))},after:function(){return Re(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)}))},empty:function(){for(var e,t=0;null!=(e=this[t]);t++){for(1===e.nodeType&&m.cleanData(ce(e,!1));e.firstChild;)e.removeChild(e.firstChild);e.options&&m.nodeName(e,"select")&&(e.options.length=0)}return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map((function(){return m.clone(this,e,t)}))},html:function(e){return ne(this,(function(e){var t=this[0]||{},n=0,i=this.length;if(e===undefined)return 1===t.nodeType?t.innerHTML.replace(Ce,""):undefined;if("string"==typeof e&&!Ve.test(e)&&(f.htmlSerialize||!Ne.test(e))&&(f.leadingWhitespace||!oe.test(e))&&!ue[(re.exec(e)||["",""])[1].toLowerCase()]){e=m.htmlPrefilter(e);try{for(;n<i;n++)1===(t=this[n]||{}).nodeType&&(m.cleanData(ce(t,!1)),t.innerHTML=e);t=0}catch(r){}}t&&this.empty().append(e)}),null,e,arguments.length)},replaceWith:function(){var e=[];return Re(this,arguments,(function(t){var n=this.parentNode;m.inArray(this,e)<0&&(m.cleanData(ce(this)),n&&n.replaceChild(t,this))}),e)}}),m.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},(function(e,t){m.fn[e]=function(e){for(var n,i=0,r=[],a=m(e),o=a.length-1;i<=o;i++)n=i===o?this:this.clone(!0),m(a[i])[t](n),u.apply(r,n.get());return this.pushStack(r)}}));var Oe,Fe={HTML:"block",BODY:"block"};function Ye(e,t){var n=m(t.createElement(e)).appendTo(t.body),i=m.css(n[0],"display");return n.detach(),i}function We(e){var t=o,n=Fe[e];return n||("none"!==(n=Ye(e,t))&&n||((t=((Oe=(Oe||m("<iframe frameborder='0' width='0' height='0'/>")).appendTo(t.documentElement))[0].contentWindow||Oe[0].contentDocument).document).write(),t.close(),n=Ye(e,t),Oe.detach()),Fe[e]=n),n}var Ge=/^margin/,je=new RegExp("^("+J+")(?!px)[a-z%]+$","i"),Ze=function(e,t,n,i){var r,a,o={};for(a in t)o[a]=e.style[a],e.style[a]=t[a];for(a in r=n.apply(e,i||[]),t)e.style[a]=o[a];return r},Xe=o.documentElement;!function(){var e,t,i,r,a,s,l=o.createElement("div"),u=o.createElement("div");function c(){var c,h,p=o.documentElement;p.appendChild(l),u.style.cssText="-webkit-box-sizing:border-box;box-sizing:border-box;position:relative;display:block;margin:auto;border:1px;padding:1px;top:1%;width:50%",e=i=s=!1,t=a=!0,n.getComputedStyle&&(h=n.getComputedStyle(u),e="1%"!==(h||{}).top,s="2px"===(h||{}).marginLeft,i="4px"===(h||{width:"4px"}).width,u.style.marginRight="50%",t="4px"===(h||{marginRight:"4px"}).marginRight,(c=u.appendChild(o.createElement("div"))).style.cssText=u.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",c.style.marginRight=c.style.width="0",u.style.width="1px",a=!parseFloat((n.getComputedStyle(c)||{}).marginRight),u.removeChild(c)),u.style.display="none",(r=0===u.getClientRects().length)&&(u.style.display="",u.innerHTML="<table><tr><td></td><td>t</td></tr></table>",u.childNodes[0].style.borderCollapse="separate",(c=u.getElementsByTagName("td"))[0].style.cssText="margin:0;border:0;padding:0;display:none",(r=0===c[0].offsetHeight)&&(c[0].style.display="",c[1].style.display="none",r=0===c[0].offsetHeight)),p.removeChild(l)}u.style&&(u.style.cssText="float:left;opacity:.5",f.opacity="0.5"===u.style.opacity,f.cssFloat=!!u.style.cssFloat,u.style.backgroundClip="content-box",u.cloneNode(!0).style.backgroundClip="",f.clearCloneStyle="content-box"===u.style.backgroundClip,(l=o.createElement("div")).style.cssText="border:0;width:8px;height:0;top:0;left:-9999px;padding:0;margin-top:1px;position:absolute",u.innerHTML="",l.appendChild(u),f.boxSizing=""===u.style.boxSizing||""===u.style.MozBoxSizing||""===u.style.WebkitBoxSizing,m.extend(f,{reliableHiddenOffsets:function(){return null==e&&c(),r},boxSizingReliable:function(){return null==e&&c(),i},pixelMarginRight:function(){return null==e&&c(),t},pixelPosition:function(){return null==e&&c(),e},reliableMarginRight:function(){return null==e&&c(),a},reliableMarginLeft:function(){return null==e&&c(),s}}))}();var Ue,Je,Ke=/^(top|right|bottom|left)$/;function ze(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}n.getComputedStyle?(Ue=function(e){var t=e.ownerDocument.defaultView;return t&&t.opener||(t=n),t.getComputedStyle(e)},Je=function(e,t,n){var i,r,a,o,s=e.style;return""!==(o=(n=n||Ue(e))?n.getPropertyValue(t)||n[t]:undefined)&&o!==undefined||m.contains(e.ownerDocument,e)||(o=m.style(e,t)),n&&!f.pixelMarginRight()&&je.test(o)&&Ge.test(t)&&(i=s.width,r=s.minWidth,a=s.maxWidth,s.minWidth=s.maxWidth=s.width=o,o=n.width,s.width=i,s.minWidth=r,s.maxWidth=a),o===undefined?o:o+""}):Xe.currentStyle&&(Ue=function(e){return e.currentStyle},Je=function(e,t,n){var i,r,a,o,s=e.style;return null==(o=(n=n||Ue(e))?n[t]:undefined)&&s&&s[t]&&(o=s[t]),je.test(o)&&!Ke.test(t)&&(i=s.left,(a=(r=e.runtimeStyle)&&r.left)&&(r.left=e.currentStyle.left),s.left="fontSize"===t?"1em":o,o=s.pixelLeft+"px",s.left=i,a&&(r.left=a)),o===undefined?o:o+""||"auto"});var Qe=/alpha\([^)]*\)/i,qe=/opacity\s*=\s*([^)]*)/i,$e=/^(none|table(?!-c[ea]).+)/,et=new RegExp("^("+J+")(.*)$","i"),tt={position:"absolute",visibility:"hidden",display:"block"},nt={letterSpacing:"0",fontWeight:"400"},it=["Webkit","O","Moz","ms"],rt=o.createElement("div").style;function at(e){if(e in rt)return e;for(var t=e.charAt(0).toUpperCase()+e.slice(1),n=it.length;n--;)if((e=it[n]+t)in rt)return e}function ot(e,t){for(var n,i,r,a=[],o=0,s=e.length;o<s;o++)(i=e[o]).style&&(a[o]=m._data(i,"olddisplay"),n=i.style.display,t?(a[o]||"none"!==n||(i.style.display=""),""===i.style.display&&Q(i)&&(a[o]=m._data(i,"olddisplay",We(i.nodeName)))):(r=Q(i),(n&&"none"!==n||!r)&&m._data(i,"olddisplay",r?n:m.css(i,"display"))));for(o=0;o<s;o++)(i=e[o]).style&&(t&&"none"!==i.style.display&&""!==i.style.display||(i.style.display=t?a[o]||"":"none"));return e}function st(e,t,n){var i=et.exec(t);return i?Math.max(0,i[1]-(n||0))+(i[2]||"px"):t}function lt(e,t,n,i,r){for(var a=n===(i?"border":"content")?4:"width"===t?1:0,o=0;a<4;a+=2)"margin"===n&&(o+=m.css(e,n+z[a],!0,r)),i?("content"===n&&(o-=m.css(e,"padding"+z[a],!0,r)),"margin"!==n&&(o-=m.css(e,"border"+z[a]+"Width",!0,r))):(o+=m.css(e,"padding"+z[a],!0,r),"padding"!==n&&(o+=m.css(e,"border"+z[a]+"Width",!0,r)));return o}function ut(e,t,n){var i=!0,r="width"===t?e.offsetWidth:e.offsetHeight,a=Ue(e),o=f.boxSizing&&"border-box"===m.css(e,"boxSizing",!1,a);if(r<=0||null==r){if(((r=Je(e,t,a))<0||null==r)&&(r=e.style[t]),je.test(r))return r;i=o&&(f.boxSizingReliable()||r===e.style[t]),r=parseFloat(r)||0}return r+lt(e,t,n||(o?"border":"content"),i,a)+"px"}function ct(e,t,n,i,r){return new ct.prototype.init(e,t,n,i,r)}m.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Je(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{float:f.cssFloat?"cssFloat":"styleFloat"},style:function(e,t,n,i){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var r,a,o,s=m.camelCase(t),l=e.style;if(t=m.cssProps[s]||(m.cssProps[s]=at(s)||s),o=m.cssHooks[t]||m.cssHooks[s],n===undefined)return o&&"get"in o&&(r=o.get(e,!1,i))!==undefined?r:l[t];if("string"==(a=typeof n)&&(r=K.exec(n))&&r[1]&&(n=q(e,t,r),a="number"),null!=n&&n==n&&("number"===a&&(n+=r&&r[3]||(m.cssNumber[s]?"":"px")),f.clearCloneStyle||""!==n||0!==t.indexOf("background")||(l[t]="inherit"),!o||!("set"in o)||(n=o.set(e,n,i))!==undefined))try{l[t]=n}catch(u){}}},css:function(e,t,n,i){var r,a,o,s=m.camelCase(t);return t=m.cssProps[s]||(m.cssProps[s]=at(s)||s),(o=m.cssHooks[t]||m.cssHooks[s])&&"get"in o&&(a=o.get(e,!0,n)),a===undefined&&(a=Je(e,t,i)),"normal"===a&&t in nt&&(a=nt[t]),""===n||n?(r=parseFloat(a),!0===n||isFinite(r)?r||0:a):a}}),m.each(["height","width"],(function(e,t){m.cssHooks[t]={get:function(e,n,i){if(n)return $e.test(m.css(e,"display"))&&0===e.offsetWidth?Ze(e,tt,(function(){return ut(e,t,i)})):ut(e,t,i)},set:function(e,n,i){var r=i&&Ue(e);return st(0,n,i?lt(e,t,i,f.boxSizing&&"border-box"===m.css(e,"boxSizing",!1,r),r):0)}}})),f.opacity||(m.cssHooks.opacity={get:function(e,t){return qe.test((t&&e.currentStyle?e.currentStyle.filter:e.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":t?"1":""},set:function(e,t){var n=e.style,i=e.currentStyle,r=m.isNumeric(t)?"alpha(opacity="+100*t+")":"",a=i&&i.filter||n.filter||"";n.zoom=1,(t>=1||""===t)&&""===m.trim(a.replace(Qe,""))&&n.removeAttribute&&(n.removeAttribute("filter"),""===t||i&&!i.filter)||(n.filter=Qe.test(a)?a.replace(Qe,r):a+" "+r)}}),m.cssHooks.marginRight=ze(f.reliableMarginRight,(function(e,t){if(t)return Ze(e,{display:"inline-block"},Je,[e,"marginRight"])})),m.cssHooks.marginLeft=ze(f.reliableMarginLeft,(function(e,t){if(t)return(parseFloat(Je(e,"marginLeft"))||(m.contains(e.ownerDocument,e)?e.getBoundingClientRect().left-Ze(e,{marginLeft:0},(function(){return e.getBoundingClientRect().left})):0))+"px"})),m.each({margin:"",padding:"",border:"Width"},(function(e,t){m.cssHooks[e+t]={expand:function(n){for(var i=0,r={},a="string"==typeof n?n.split(" "):[n];i<4;i++)r[e+z[i]+t]=a[i]||a[i-2]||a[0];return r}},Ge.test(e)||(m.cssHooks[e+t].set=st)})),m.fn.extend({css:function(e,t){return ne(this,(function(e,t,n){var i,r,a={},o=0;if(m.isArray(t)){for(i=Ue(e),r=t.length;o<r;o++)a[t[o]]=m.css(e,t[o],!1,i);return a}return n!==undefined?m.style(e,t,n):m.css(e,t)}),e,t,arguments.length>1)},show:function(){return ot(this,!0)},hide:function(){return ot(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each((function(){Q(this)?m(this).show():m(this).hide()}))}}),m.Tween=ct,ct.prototype={constructor:ct,init:function(e,t,n,i,r,a){this.elem=e,this.prop=n,this.easing=r||m.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=i,this.unit=a||(m.cssNumber[n]?"":"px")},cur:function(){var e=ct.propHooks[this.prop];return e&&e.get?e.get(this):ct.propHooks._default.get(this)},run:function(e){var t,n=ct.propHooks[this.prop];return this.options.duration?this.pos=t=m.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):ct.propHooks._default.set(this),this}},ct.prototype.init.prototype=ct.prototype,ct.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=m.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){m.fx.step[e.prop]?m.fx.step[e.prop](e):1!==e.elem.nodeType||null==e.elem.style[m.cssProps[e.prop]]&&!m.cssHooks[e.prop]?e.elem[e.prop]=e.now:m.style(e.elem,e.prop,e.now+e.unit)}}},ct.propHooks.scrollTop=ct.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},m.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},m.fx=ct.prototype.init,m.fx.step={};var ht,pt,dt=/^(?:toggle|show|hide)$/,ft=/queueHooks$/;function gt(){return n.setTimeout((function(){ht=undefined})),ht=m.now()}function mt(e,t){var n,i={height:e},r=0;for(t=t?1:0;r<4;r+=2-t)i["margin"+(n=z[r])]=i["padding"+n]=e;return t&&(i.opacity=i.width=e),i}function It(e,t,n){for(var i,r=(Bt.tweeners[t]||[]).concat(Bt.tweeners["*"]),a=0,o=r.length;a<o;a++)if(i=r[a].call(n,t,e))return i}function Bt(e,t,n){var i,r,a=0,o=Bt.prefilters.length,s=m.Deferred().always((function(){delete l.elem})),l=function(){if(r)return!1;for(var t=ht||gt(),n=Math.max(0,u.startTime+u.duration-t),i=1-(n/u.duration||0),a=0,o=u.tweens.length;a<o;a++)u.tweens[a].run(i);return s.notifyWith(e,[u,i,n]),i<1&&o?n:(s.resolveWith(e,[u]),!1)},u=s.promise({elem:e,props:m.extend({},t),opts:m.extend(!0,{specialEasing:{},easing:m.easing._default},n),originalProperties:t,originalOptions:n,startTime:ht||gt(),duration:n.duration,tweens:[],createTween:function(t,n){var i=m.Tween(e,u.opts,t,n,u.opts.specialEasing[t]||u.opts.easing);return u.tweens.push(i),i},stop:function(t){var n=0,i=t?u.tweens.length:0;if(r)return this;for(r=!0;n<i;n++)u.tweens[n].run(1);return t?(s.notifyWith(e,[u,1,0]),s.resolveWith(e,[u,t])):s.rejectWith(e,[u,t]),this}}),c=u.props;for(function(e,t){var n,i,r,a,o;for(n in e)if(r=t[i=m.camelCase(n)],a=e[n],m.isArray(a)&&(r=a[1],a=e[n]=a[0]),n!==i&&(e[i]=a,delete e[n]),(o=m.cssHooks[i])&&"expand"in o)for(n in a=o.expand(a),delete e[i],a)n in e||(e[n]=a[n],t[n]=r);else t[i]=r}(c,u.opts.specialEasing);a<o;a++)if(i=Bt.prefilters[a].call(u,e,c,u.opts))return m.isFunction(i.stop)&&(m._queueHooks(u.elem,u.opts.queue).stop=m.proxy(i.stop,i)),i;return m.map(c,It,u),m.isFunction(u.opts.start)&&u.opts.start.call(e,u),m.fx.timer(m.extend(l,{elem:e,anim:u,queue:u.opts.queue})),u.progress(u.opts.progress).done(u.opts.done,u.opts.complete).fail(u.opts.fail).always(u.opts.always)}m.Animation=m.extend(Bt,{tweeners:{"*":[function(e,t){var n=this.createTween(e,t);return q(n.elem,e,K.exec(t),n),n}]},tweener:function(e,t){m.isFunction(e)?(t=e,e=["*"]):e=e.match(R);for(var n,i=0,r=e.length;i<r;i++)n=e[i],Bt.tweeners[n]=Bt.tweeners[n]||[],Bt.tweeners[n].unshift(t)},prefilters:[function(e,t,n){var i,r,a,o,s,l,u,c=this,h={},p=e.style,d=e.nodeType&&Q(e),g=m._data(e,"fxshow");for(i in n.queue||(null==(s=m._queueHooks(e,"fx")).unqueued&&(s.unqueued=0,l=s.empty.fire,s.empty.fire=function(){s.unqueued||l()}),s.unqueued++,c.always((function(){c.always((function(){s.unqueued--,m.queue(e,"fx").length||s.empty.fire()}))}))),1===e.nodeType&&("height"in t||"width"in t)&&(n.overflow=[p.overflow,p.overflowX,p.overflowY],"inline"===("none"===(u=m.css(e,"display"))?m._data(e,"olddisplay")||We(e.nodeName):u)&&"none"===m.css(e,"float")&&(f.inlineBlockNeedsLayout&&"inline"!==We(e.nodeName)?p.zoom=1:p.display="inline-block")),n.overflow&&(p.overflow="hidden",f.shrinkWrapBlocks()||c.always((function(){p.overflow=n.overflow[0],p.overflowX=n.overflow[1],p.overflowY=n.overflow[2]}))),t)if(r=t[i],dt.exec(r)){if(delete t[i],a=a||"toggle"===r,r===(d?"hide":"show")){if("show"!==r||!g||g[i]===undefined)continue;d=!0}h[i]=g&&g[i]||m.style(e,i)}else u=undefined;if(m.isEmptyObject(h))"inline"===("none"===u?We(e.nodeName):u)&&(p.display=u);else for(i in g?"hidden"in g&&(d=g.hidden):g=m._data(e,"fxshow",{}),a&&(g.hidden=!d),d?m(e).show():c.done((function(){m(e).hide()})),c.done((function(){var t;for(t in m._removeData(e,"fxshow"),h)m.style(e,t,h[t])})),h)o=It(d?g[i]:0,i,c),i in g||(g[i]=o.start,d&&(o.end=o.start,o.start="width"===i||"height"===i?1:0))}],prefilter:function(e,t){t?Bt.prefilters.unshift(e):Bt.prefilters.push(e)}}),m.speed=function(e,t,n){var i=e&&"object"==typeof e?m.extend({},e):{complete:n||!n&&t||m.isFunction(e)&&e,duration:e,easing:n&&t||t&&!m.isFunction(t)&&t};return i.duration=m.fx.off?0:"number"==typeof i.duration?i.duration:i.duration in m.fx.speeds?m.fx.speeds[i.duration]:m.fx.speeds._default,null!=i.queue&&!0!==i.queue||(i.queue="fx"),i.old=i.complete,i.complete=function(){m.isFunction(i.old)&&i.old.call(this),i.queue&&m.dequeue(this,i.queue)},i},m.fn.extend({fadeTo:function(e,t,n,i){return this.filter(Q).css("opacity",0).show().end().animate({opacity:t},e,n,i)},animate:function(e,t,n,i){var r=m.isEmptyObject(e),a=m.speed(t,n,i),o=function(){var t=Bt(this,m.extend({},e),a);(r||m._data(this,"finish"))&&t.stop(!0)};return o.finish=o,r||!1===a.queue?this.each(o):this.queue(a.queue,o)},stop:function(e,t,n){var i=function(e){var t=e.stop;delete e.stop,t(n)};return"string"!=typeof e&&(n=t,t=e,e=undefined),t&&!1!==e&&this.queue(e||"fx",[]),this.each((function(){var t=!0,r=null!=e&&e+"queueHooks",a=m.timers,o=m._data(this);if(r)o[r]&&o[r].stop&&i(o[r]);else for(r in o)o[r]&&o[r].stop&&ft.test(r)&&i(o[r]);for(r=a.length;r--;)a[r].elem!==this||null!=e&&a[r].queue!==e||(a[r].anim.stop(n),t=!1,a.splice(r,1));!t&&n||m.dequeue(this,e)}))},finish:function(e){return!1!==e&&(e=e||"fx"),this.each((function(){var t,n=m._data(this),i=n[e+"queue"],r=n[e+"queueHooks"],a=m.timers,o=i?i.length:0;for(n.finish=!0,m.queue(this,e,[]),r&&r.stop&&r.stop.call(this,!0),t=a.length;t--;)a[t].elem===this&&a[t].queue===e&&(a[t].anim.stop(!0),a.splice(t,1));for(t=0;t<o;t++)i[t]&&i[t].finish&&i[t].finish.call(this);delete n.finish}))}}),m.each(["toggle","show","hide"],(function(e,t){var n=m.fn[t];m.fn[t]=function(e,i,r){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(mt(t,!0),e,i,r)}})),m.each({slideDown:mt("show"),slideUp:mt("hide"),slideToggle:mt("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},(function(e,t){m.fn[e]=function(e,n,i){return this.animate(t,e,n,i)}})),m.timers=[],m.fx.tick=function(){var e,t=m.timers,n=0;for(ht=m.now();n<t.length;n++)(e=t[n])()||t[n]!==e||t.splice(n--,1);t.length||m.fx.stop(),ht=undefined},m.fx.timer=function(e){m.timers.push(e),e()?m.fx.start():m.timers.pop()},m.fx.interval=13,m.fx.start=function(){pt||(pt=n.setInterval(m.fx.tick,m.fx.interval))},m.fx.stop=function(){n.clearInterval(pt),pt=null},m.fx.speeds={slow:600,fast:200,_default:400},m.fn.delay=function(e,t){return e=m.fx&&m.fx.speeds[e]||e,t=t||"fx",this.queue(t,(function(t,i){var r=n.setTimeout(t,e);i.stop=function(){n.clearTimeout(r)}}))},function(){var e,t=o.createElement("input"),n=o.createElement("div"),i=o.createElement("select"),r=i.appendChild(o.createElement("option"));(n=o.createElement("div")).setAttribute("className","t"),n.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",e=n.getElementsByTagName("a")[0],t.setAttribute("type","checkbox"),n.appendChild(t),(e=n.getElementsByTagName("a")[0]).style.cssText="top:1px",f.getSetAttribute="t"!==n.className,f.style=/top/.test(e.getAttribute("style")),f.hrefNormalized="/a"===e.getAttribute("href"),f.checkOn=!!t.value,f.optSelected=r.selected,f.enctype=!!o.createElement("form").enctype,i.disabled=!0,f.optDisabled=!r.disabled,(t=o.createElement("input")).setAttribute("value",""),f.input=""===t.getAttribute("value"),t.value="t",t.setAttribute("type","radio"),f.radioValue="t"===t.value}();var _t=/\r/g,Et=/[\x20\t\r\n\f]+/g;m.fn.extend({val:function(e){var t,n,i,r=this[0];return arguments.length?(i=m.isFunction(e),this.each((function(n){var r;1===this.nodeType&&(null==(r=i?e.call(this,n,m(this).val()):e)?r="":"number"==typeof r?r+="":m.isArray(r)&&(r=m.map(r,(function(e){return null==e?"":e+""}))),(t=m.valHooks[this.type]||m.valHooks[this.nodeName.toLowerCase()])&&"set"in t&&t.set(this,r,"value")!==undefined||(this.value=r))}))):r?(t=m.valHooks[r.type]||m.valHooks[r.nodeName.toLowerCase()])&&"get"in t&&(n=t.get(r,"value"))!==undefined?n:"string"==typeof(n=r.value)?n.replace(_t,""):null==n?"":n:void 0}}),m.extend({valHooks:{option:{get:function(e){var t=m.find.attr(e,"value");return null!=t?t:m.trim(m.text(e)).replace(Et," ")}},select:{get:function(e){for(var t,n,i=e.options,r=e.selectedIndex,a="select-one"===e.type||r<0,o=a?null:[],s=a?r+1:i.length,l=r<0?s:a?r:0;l<s;l++)if(((n=i[l]).selected||l===r)&&(f.optDisabled?!n.disabled:null===n.getAttribute("disabled"))&&(!n.parentNode.disabled||!m.nodeName(n.parentNode,"optgroup"))){if(t=m(n).val(),a)return t;o.push(t)}return o},set:function(e,t){for(var n,i,r=e.options,a=m.makeArray(t),o=r.length;o--;)if(i=r[o],m.inArray(m.valHooks.option.get(i),a)>-1)try{i.selected=n=!0}catch(_){i.scrollHeight}else i.selected=!1;return n||(e.selectedIndex=-1),r}}}}),m.each(["radio","checkbox"],(function(){m.valHooks[this]={set:function(e,t){if(m.isArray(t))return e.checked=m.inArray(m(e).val(),t)>-1}},f.checkOn||(m.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})}));var bt,yt,vt=m.expr.attrHandle,Tt=/^(?:checked|selected)$/i,Ct=f.getSetAttribute,Nt=f.input;m.fn.extend({attr:function(e,t){return ne(this,m.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each((function(){m.removeAttr(this,e)}))}}),m.extend({attr:function(e,t,n){var i,r,a=e.nodeType;if(3!==a&&8!==a&&2!==a)return"undefined"==typeof e.getAttribute?m.prop(e,t,n):(1===a&&m.isXMLDoc(e)||(t=t.toLowerCase(),r=m.attrHooks[t]||(m.expr.match.bool.test(t)?yt:bt)),n!==undefined?null===n?void m.removeAttr(e,t):r&&"set"in r&&(i=r.set(e,n,t))!==undefined?i:(e.setAttribute(t,n+""),n):r&&"get"in r&&null!==(i=r.get(e,t))?i:null==(i=m.find.attr(e,t))?undefined:i)},attrHooks:{type:{set:function(e,t){if(!f.radioValue&&"radio"===t&&m.nodeName(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,i,r=0,a=t&&t.match(R);if(a&&1===e.nodeType)for(;n=a[r++];)i=m.propFix[n]||n,m.expr.match.bool.test(n)?Nt&&Ct||!Tt.test(n)?e[i]=!1:e[m.camelCase("default-"+n)]=e[i]=!1:m.attr(e,n,""),e.removeAttribute(Ct?n:i)}}),yt={set:function(e,t,n){return!1===t?m.removeAttr(e,n):Nt&&Ct||!Tt.test(n)?e.setAttribute(!Ct&&m.propFix[n]||n,n):e[m.camelCase("default-"+n)]=e[n]=!0,n}},m.each(m.expr.match.bool.source.match(/\w+/g),(function(e,t){var n=vt[t]||m.find.attr;Nt&&Ct||!Tt.test(t)?vt[t]=function(e,t,i){var r,a;return i||(a=vt[t],vt[t]=r,r=null!=n(e,t,i)?t.toLowerCase():null,vt[t]=a),r}:vt[t]=function(e,t,n){if(!n)return e[m.camelCase("default-"+t)]?t.toLowerCase():null}})),Nt&&Ct||(m.attrHooks.value={set:function(e,t,n){if(!m.nodeName(e,"input"))return bt&&bt.set(e,t,n);e.defaultValue=t}}),Ct||(bt={set:function(e,t,n){var i=e.getAttributeNode(n);if(i||e.setAttributeNode(i=e.ownerDocument.createAttribute(n)),i.value=t+="","value"===n||t===e.getAttribute(n))return t}},vt.id=vt.name=vt.coords=function(e,t,n){var i;if(!n)return(i=e.getAttributeNode(t))&&""!==i.value?i.value:null},m.valHooks.button={get:function(e,t){var n=e.getAttributeNode(t);if(n&&n.specified)return n.value},set:bt.set},m.attrHooks.contenteditable={set:function(e,t,n){bt.set(e,""!==t&&t,n)}},m.each(["width","height"],(function(e,t){m.attrHooks[t]={set:function(e,n){if(""===n)return e.setAttribute(t,"auto"),n}}}))),f.style||(m.attrHooks.style={get:function(e){return e.style.cssText||undefined},set:function(e,t){return e.style.cssText=t+""}});var Vt=/^(?:input|select|textarea|button|object)$/i,St=/^(?:a|area)$/i;m.fn.extend({prop:function(e,t){return ne(this,m.prop,e,t,arguments.length>1)},removeProp:function(e){return e=m.propFix[e]||e,this.each((function(){try{this[e]=undefined,delete this[e]}catch(t){}}))}}),m.extend({prop:function(e,t,n){var i,r,a=e.nodeType;if(3!==a&&8!==a&&2!==a)return 1===a&&m.isXMLDoc(e)||(t=m.propFix[t]||t,r=m.propHooks[t]),n!==undefined?r&&"set"in r&&(i=r.set(e,n,t))!==undefined?i:e[t]=n:r&&"get"in r&&null!==(i=r.get(e,t))?i:e[t]},propHooks:{tabIndex:{get:function(e){var t=m.find.attr(e,"tabindex");return t?parseInt(t,10):Vt.test(e.nodeName)||St.test(e.nodeName)&&e.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),f.hrefNormalized||m.each(["href","src"],(function(e,t){m.propHooks[t]={get:function(e){return e.getAttribute(t,4)}}})),f.optSelected||(m.propHooks.selected={get:function(e){var t=e.parentNode;return t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex),null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),m.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],(function(){m.propFix[this.toLowerCase()]=this})),f.enctype||(m.propFix.enctype="encoding");var xt=/[\t\r\n\f]/g;function wt(e){return m.attr(e,"class")||""}m.fn.extend({addClass:function(e){var t,n,i,r,a,o,s,l=0;if(m.isFunction(e))return this.each((function(t){m(this).addClass(e.call(this,t,wt(this)))}));if("string"==typeof e&&e)for(t=e.match(R)||[];n=this[l++];)if(r=wt(n),i=1===n.nodeType&&(" "+r+" ").replace(xt," ")){for(o=0;a=t[o++];)i.indexOf(" "+a+" ")<0&&(i+=a+" ");r!==(s=m.trim(i))&&m.attr(n,"class",s)}return this},removeClass:function(e){var t,n,i,r,a,o,s,l=0;if(m.isFunction(e))return this.each((function(t){m(this).removeClass(e.call(this,t,wt(this)))}));if(!arguments.length)return this.attr("class","");if("string"==typeof e&&e)for(t=e.match(R)||[];n=this[l++];)if(r=wt(n),i=1===n.nodeType&&(" "+r+" ").replace(xt," ")){for(o=0;a=t[o++];)for(;i.indexOf(" "+a+" ")>-1;)i=i.replace(" "+a+" "," ");r!==(s=m.trim(i))&&m.attr(n,"class",s)}return this},toggleClass:function(e,t){var n=typeof e;return"boolean"==typeof t&&"string"===n?t?this.addClass(e):this.removeClass(e):m.isFunction(e)?this.each((function(n){m(this).toggleClass(e.call(this,n,wt(this),t),t)})):this.each((function(){var t,i,r,a;if("string"===n)for(i=0,r=m(this),a=e.match(R)||[];t=a[i++];)r.hasClass(t)?r.removeClass(t):r.addClass(t);else e!==undefined&&"boolean"!==n||((t=wt(this))&&m._data(this,"__className__",t),m.attr(this,"class",t||!1===e?"":m._data(this,"__className__")||""))}))},hasClass:function(e){var t,n,i=0;for(t=" "+e+" ";n=this[i++];)if(1===n.nodeType&&(" "+wt(n)+" ").replace(xt," ").indexOf(t)>-1)return!0;return!1}}),m.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),(function(e,t){m.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}})),m.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}});var At=n.location,Lt=m.now(),kt=/\?/,Dt=/(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;m.parseJSON=function(e){if(n.JSON&&n.JSON.parse)return n.JSON.parse(e+"");var t,i=null,r=m.trim(e+"");return r&&!m.trim(r.replace(Dt,(function(e,n,r,a){return t&&n&&(i=0),0===i?e:(t=r||n,i+=!a-!r,"")})))?Function("return "+r)():m.error("Invalid JSON: "+e)},m.parseXML=function(e){var t;if(!e||"string"!=typeof e)return null;try{n.DOMParser?t=(new n.DOMParser).parseFromString(e,"text/xml"):((t=new n.ActiveXObject("Microsoft.XMLDOM")).async="false",t.loadXML(e))}catch(i){t=undefined}return t&&t.documentElement&&!t.getElementsByTagName("parsererror").length||m.error("Invalid XML: "+e),t};var Mt=/#.*$/,Pt=/([?&])_=[^&]*/,Rt=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Ht=/^(?:GET|HEAD)$/,Ot=/^\/\//,Ft=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,Yt={},Wt={},Gt="*/".concat("*"),jt=At.href,Zt=Ft.exec(jt.toLowerCase())||[];function Xt(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var i,r=0,a=t.toLowerCase().match(R)||[];if(m.isFunction(n))for(;i=a[r++];)"+"===i.charAt(0)?(i=i.slice(1)||"*",(e[i]=e[i]||[]).unshift(n)):(e[i]=e[i]||[]).push(n)}}function Ut(e,t,n,i){var r={},a=e===Wt;function o(s){var l;return r[s]=!0,m.each(e[s]||[],(function(e,s){var u=s(t,n,i);return"string"!=typeof u||a||r[u]?a?!(l=u):void 0:(t.dataTypes.unshift(u),o(u),!1)})),l}return o(t.dataTypes[0])||!r["*"]&&o("*")}function Jt(e,t){var n,i,r=m.ajaxSettings.flatOptions||{};for(i in t)t[i]!==undefined&&((r[i]?e:n||(n={}))[i]=t[i]);return n&&m.extend(!0,e,n),e}function Kt(e){return e.style&&e.style.display||m.css(e,"display")}m.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:jt,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(Zt[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Gt,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":m.parseJSON,"text xml":m.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?Jt(Jt(e,m.ajaxSettings),t):Jt(m.ajaxSettings,e)},ajaxPrefilter:Xt(Yt),ajaxTransport:Xt(Wt),ajax:function(e,t){"object"==typeof e&&(t=e,e=undefined),t=t||{};var i,r,a,o,s,l,u,c,h=m.ajaxSetup({},t),p=h.context||h,d=h.context&&(p.nodeType||p.jquery)?m(p):m.event,f=m.Deferred(),g=m.Callbacks("once memory"),I=h.statusCode||{},B={},_={},E=0,b="canceled",y={readyState:0,getResponseHeader:function(e){var t;if(2===E){if(!c)for(c={};t=Rt.exec(o);)c[t[1].toLowerCase()]=t[2];t=c[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return 2===E?o:null},setRequestHeader:function(e,t){var n=e.toLowerCase();return E||(e=_[n]=_[n]||e,B[e]=t),this},overrideMimeType:function(e){return E||(h.mimeType=e),this},statusCode:function(e){var t;if(e)if(E<2)for(t in e)I[t]=[I[t],e[t]];else y.always(e[y.status]);return this},abort:function(e){var t=e||b;return u&&u.abort(t),v(0,t),this}};if(f.promise(y).complete=g.add,y.success=y.done,y.error=y.fail,h.url=((e||h.url||jt)+"").replace(Mt,"").replace(Ot,Zt[1]+"//"),h.type=t.method||t.type||h.method||h.type,h.dataTypes=m.trim(h.dataType||"*").toLowerCase().match(R)||[""],null==h.crossDomain&&(i=Ft.exec(h.url.toLowerCase()),h.crossDomain=!(!i||i[1]===Zt[1]&&i[2]===Zt[2]&&(i[3]||("http:"===i[1]?"80":"443"))===(Zt[3]||("http:"===Zt[1]?"80":"443")))),h.data&&h.processData&&"string"!=typeof h.data&&(h.data=m.param(h.data,h.traditional)),Ut(Yt,h,t,y),2===E)return y;for(r in(l=m.event&&h.global)&&0==m.active++&&m.event.trigger("ajaxStart"),h.type=h.type.toUpperCase(),h.hasContent=!Ht.test(h.type),a=h.url,h.hasContent||(h.data&&(a=h.url+=(kt.test(a)?"&":"?")+h.data,delete h.data),!1===h.cache&&(h.url=Pt.test(a)?a.replace(Pt,"$1_="+Lt++):a+(kt.test(a)?"&":"?")+"_="+Lt++)),h.ifModified&&(m.lastModified[a]&&y.setRequestHeader("If-Modified-Since",m.lastModified[a]),m.etag[a]&&y.setRequestHeader("If-None-Match",m.etag[a])),(h.data&&h.hasContent&&!1!==h.contentType||t.contentType)&&y.setRequestHeader("Content-Type",h.contentType),y.setRequestHeader("Accept",h.dataTypes[0]&&h.accepts[h.dataTypes[0]]?h.accepts[h.dataTypes[0]]+("*"!==h.dataTypes[0]?", "+Gt+"; q=0.01":""):h.accepts["*"]),h.headers)y.setRequestHeader(r,h.headers[r]);if(h.beforeSend&&(!1===h.beforeSend.call(p,y,h)||2===E))return y.abort();for(r in b="abort",{success:1,error:1,complete:1})y[r](h[r]);if(u=Ut(Wt,h,t,y)){if(y.readyState=1,l&&d.trigger("ajaxSend",[y,h]),2===E)return y;h.async&&h.timeout>0&&(s=n.setTimeout((function(){y.abort("timeout")}),h.timeout));try{E=1,u.send(B,v)}catch(T){if(!(E<2))throw T;v(-1,T)}}else v(-1,"No Transport");function v(e,t,i,r){var c,B,_,b,v,C=t;2!==E&&(E=2,s&&n.clearTimeout(s),u=undefined,o=r||"",y.readyState=e>0?4:0,c=e>=200&&e<300||304===e,i&&(b=function(e,t,n){for(var i,r,a,o,s=e.contents,l=e.dataTypes;"*"===l[0];)l.shift(),r===undefined&&(r=e.mimeType||t.getResponseHeader("Content-Type"));if(r)for(o in s)if(s[o]&&s[o].test(r)){l.unshift(o);break}if(l[0]in n)a=l[0];else{for(o in n){if(!l[0]||e.converters[o+" "+l[0]]){a=o;break}i||(i=o)}a=a||i}if(a)return a!==l[0]&&l.unshift(a),n[a]}(h,y,i)),b=function(e,t,n,i){var r,a,o,s,l,u={},c=e.dataTypes.slice();if(c[1])for(o in e.converters)u[o.toLowerCase()]=e.converters[o];for(a=c.shift();a;)if(e.responseFields[a]&&(n[e.responseFields[a]]=t),!l&&i&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),l=a,a=c.shift())if("*"===a)a=l;else if("*"!==l&&l!==a){if(!(o=u[l+" "+a]||u["* "+a]))for(r in u)if((s=r.split(" "))[1]===a&&(o=u[l+" "+s[0]]||u["* "+s[0]])){!0===o?o=u[r]:!0!==u[r]&&(a=s[0],c.unshift(s[1]));break}if(!0!==o)if(o&&e.throws)t=o(t);else try{t=o(t)}catch(T){return{state:"parsererror",error:o?T:"No conversion from "+l+" to "+a}}}return{state:"success",data:t}}(h,b,y,c),c?(h.ifModified&&((v=y.getResponseHeader("Last-Modified"))&&(m.lastModified[a]=v),(v=y.getResponseHeader("etag"))&&(m.etag[a]=v)),204===e||"HEAD"===h.type?C="nocontent":304===e?C="notmodified":(C=b.state,B=b.data,c=!(_=b.error))):(_=C,!e&&C||(C="error",e<0&&(e=0))),y.status=e,y.statusText=(t||C)+"",c?f.resolveWith(p,[B,C,y]):f.rejectWith(p,[y,C,_]),y.statusCode(I),I=undefined,l&&d.trigger(c?"ajaxSuccess":"ajaxError",[y,h,c?B:_]),g.fireWith(p,[y,C]),l&&(d.trigger("ajaxComplete",[y,h]),--m.active||m.event.trigger("ajaxStop")))}return y},getJSON:function(e,t,n){return m.get(e,t,n,"json")},getScript:function(e,t){return m.get(e,undefined,t,"script")}}),m.each(["get","post"],(function(e,t){m[t]=function(e,n,i,r){return m.isFunction(n)&&(r=r||i,i=n,n=undefined),m.ajax(m.extend({url:e,type:t,dataType:r,data:n,success:i},m.isPlainObject(e)&&e))}})),m._evalUrl=function(e){return m.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,throws:!0})},m.fn.extend({wrapAll:function(e){if(m.isFunction(e))return this.each((function(t){m(this).wrapAll(e.call(this,t))}));if(this[0]){var t=m(e,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map((function(){for(var e=this;e.firstChild&&1===e.firstChild.nodeType;)e=e.firstChild;return e})).append(this)}return this},wrapInner:function(e){return m.isFunction(e)?this.each((function(t){m(this).wrapInner(e.call(this,t))})):this.each((function(){var t=m(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)}))},wrap:function(e){var t=m.isFunction(e);return this.each((function(n){m(this).wrapAll(t?e.call(this,n):e)}))},unwrap:function(){return this.parent().each((function(){m.nodeName(this,"body")||m(this).replaceWith(this.childNodes)})).end()}}),m.expr.filters.hidden=function(e){return f.reliableHiddenOffsets()?e.offsetWidth<=0&&e.offsetHeight<=0&&!e.getClientRects().length:function(e){if(!m.contains(e.ownerDocument||o,e))return!0;for(;e&&1===e.nodeType;){if("none"===Kt(e)||"hidden"===e.type)return!0;e=e.parentNode}return!1}(e)},m.expr.filters.visible=function(e){return!m.expr.filters.hidden(e)};var zt=/%20/g,Qt=/\[\]$/,qt=/\r?\n/g,$t=/^(?:submit|button|image|reset|file)$/i,en=/^(?:input|select|textarea|keygen)/i;function tn(e,t,n,i){var r;if(m.isArray(t))m.each(t,(function(t,r){n||Qt.test(e)?i(e,r):tn(e+"["+("object"==typeof r&&null!=r?t:"")+"]",r,n,i)}));else if(n||"object"!==m.type(t))i(e,t);else for(r in t)tn(e+"["+r+"]",t[r],n,i)}m.param=function(e,t){var n,i=[],r=function(e,t){t=m.isFunction(t)?t():null==t?"":t,i[i.length]=encodeURIComponent(e)+"="+encodeURIComponent(t)};if(t===undefined&&(t=m.ajaxSettings&&m.ajaxSettings.traditional),m.isArray(e)||e.jquery&&!m.isPlainObject(e))m.each(e,(function(){r(this.name,this.value)}));else for(n in e)tn(n,e[n],t,r);return i.join("&").replace(zt,"+")},m.fn.extend({serialize:function(){return m.param(this.serializeArray())},serializeArray:function(){return this.map((function(){var e=m.prop(this,"elements");return e?m.makeArray(e):this})).filter((function(){var e=this.type;return this.name&&!m(this).is(":disabled")&&en.test(this.nodeName)&&!$t.test(e)&&(this.checked||!ie.test(e))})).map((function(e,t){var n=m(this).val();return null==n?null:m.isArray(n)?m.map(n,(function(e){return{name:t.name,value:e.replace(qt,"\r\n")}})):{name:t.name,value:n.replace(qt,"\r\n")}})).get()}}),m.ajaxSettings.xhr=n.ActiveXObject!==undefined?function(){return this.isLocal?sn():o.documentMode>8?on():/^(get|post|head|put|delete|options)$/i.test(this.type)&&on()||sn()}:on;var nn=0,rn={},an=m.ajaxSettings.xhr();function on(){try{return new n.XMLHttpRequest}catch(e){}}function sn(){try{return new n.ActiveXObject("Microsoft.XMLHTTP")}catch(e){}}n.attachEvent&&n.attachEvent("onunload",(function(){for(var e in rn)rn[e](undefined,!0)})),f.cors=!!an&&"withCredentials"in an,(an=f.ajax=!!an)&&m.ajaxTransport((function(e){var t;if(!e.crossDomain||f.cors)return{send:function(i,r){var a,o=e.xhr(),s=++nn;if(o.open(e.type,e.url,e.async,e.username,e.password),e.xhrFields)for(a in e.xhrFields)o[a]=e.xhrFields[a];for(a in e.mimeType&&o.overrideMimeType&&o.overrideMimeType(e.mimeType),e.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest"),i)i[a]!==undefined&&o.setRequestHeader(a,i[a]+"");o.send(e.hasContent&&e.data||null),t=function(n,i){var a,l,u;if(t&&(i||4===o.readyState))if(delete rn[s],t=undefined,o.onreadystatechange=m.noop,i)4!==o.readyState&&o.abort();else{u={},a=o.status,"string"==typeof o.responseText&&(u.text=o.responseText);try{l=o.statusText}catch(c){l=""}a||!e.isLocal||e.crossDomain?1223===a&&(a=204):a=u.text?200:404}u&&r(a,l,u,o.getAllResponseHeaders())},e.async?4===o.readyState?n.setTimeout(t):o.onreadystatechange=rn[s]=t:t()},abort:function(){t&&t(undefined,!0)}}})),m.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return m.globalEval(e),e}}}),m.ajaxPrefilter("script",(function(e){e.cache===undefined&&(e.cache=!1),e.crossDomain&&(e.type="GET",e.global=!1)})),m.ajaxTransport("script",(function(e){if(e.crossDomain){var t,n=o.head||m("head")[0]||o.documentElement;return{send:function(i,r){(t=o.createElement("script")).async=!0,e.scriptCharset&&(t.charset=e.scriptCharset),t.src=e.url,t.onload=t.onreadystatechange=function(e,n){(n||!t.readyState||/loaded|complete/.test(t.readyState))&&(t.onload=t.onreadystatechange=null,t.parentNode&&t.parentNode.removeChild(t),t=null,n||r(200,"success"))},n.insertBefore(t,n.firstChild)},abort:function(){t&&t.onload(undefined,!0)}}}}));var ln=[],un=/(=)\?(?=&|$)|\?\?/;m.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=ln.pop()||m.expando+"_"+Lt++;return this[e]=!0,e}}),m.ajaxPrefilter("json jsonp",(function(e,t,i){var r,a,o,s=!1!==e.jsonp&&(un.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&un.test(e.data)&&"data");if(s||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m.isFunction(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,s?e[s]=e[s].replace(un,"$1"+r):!1!==e.jsonp&&(e.url+=(kt.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||m.error(r+" was not called"),o[0]},e.dataTypes[0]="json",a=n[r],n[r]=function(){o=arguments},i.always((function(){a===undefined?m(n).removeProp(r):n[r]=a,e[r]&&(e.jsonpCallback=t.jsonpCallback,ln.push(r)),o&&m.isFunction(a)&&a(o[0]),o=a=undefined})),"script"})),m.parseHTML=function(e,t,n){if(!e||"string"!=typeof e)return null;"boolean"==typeof t&&(n=t,t=!1),t=t||o;var i=V.exec(e),r=!n&&[];return i?[t.createElement(i[1])]:(i=ge([e],t,r),r&&r.length&&m(r).remove(),m.merge([],i.childNodes))};var cn=m.fn.load;function hn(e){return m.isWindow(e)?e:9===e.nodeType&&(e.defaultView||e.parentWindow)}m.fn.load=function(e,t,n){if("string"!=typeof e&&cn)return cn.apply(this,arguments);var i,r,a,o=this,s=e.indexOf(" ");return s>-1&&(i=m.trim(e.slice(s,e.length)),e=e.slice(0,s)),m.isFunction(t)?(n=t,t=undefined):t&&"object"==typeof t&&(r="POST"),o.length>0&&m.ajax({url:e,type:r||"GET",dataType:"html",data:t}).done((function(e){a=arguments,o.html(i?m("<div>").append(m.parseHTML(e)).find(i):e)})).always(n&&function(e,t){o.each((function(){n.apply(this,a||[e.responseText,t,e])}))}),this},m.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],(function(e,t){m.fn[t]=function(e){return this.on(t,e)}})),m.expr.filters.animated=function(e){return m.grep(m.timers,(function(t){return e===t.elem})).length},m.offset={setOffset:function(e,t,n){var i,r,a,o,s,l,u=m.css(e,"position"),c=m(e),h={};"static"===u&&(e.style.position="relative"),s=c.offset(),a=m.css(e,"top"),l=m.css(e,"left"),("absolute"===u||"fixed"===u)&&m.inArray("auto",[a,l])>-1?(o=(i=c.position()).top,r=i.left):(o=parseFloat(a)||0,r=parseFloat(l)||0),m.isFunction(t)&&(t=t.call(e,n,m.extend({},s))),null!=t.top&&(h.top=t.top-s.top+o),null!=t.left&&(h.left=t.left-s.left+r),"using"in t?t.using.call(e,h):c.css(h)}},m.fn.extend({offset:function(e){if(arguments.length)return e===undefined?this:this.each((function(t){m.offset.setOffset(this,e,t)}));var t,n,i={top:0,left:0},r=this[0],a=r&&r.ownerDocument;return a?(t=a.documentElement,m.contains(t,r)?("undefined"!=typeof r.getBoundingClientRect&&(i=r.getBoundingClientRect()),n=hn(a),{top:i.top+(n.pageYOffset||t.scrollTop)-(t.clientTop||0),left:i.left+(n.pageXOffset||t.scrollLeft)-(t.clientLeft||0)}):i):void 0},position:function(){if(this[0]){var e,t,n={top:0,left:0},i=this[0];return"fixed"===m.css(i,"position")?t=i.getBoundingClientRect():(e=this.offsetParent(),t=this.offset(),m.nodeName(e[0],"html")||(n=e.offset()),n.top+=m.css(e[0],"borderTopWidth",!0),n.left+=m.css(e[0],"borderLeftWidth",!0)),{top:t.top-n.top-m.css(i,"marginTop",!0),left:t.left-n.left-m.css(i,"marginLeft",!0)}}},offsetParent:function(){return this.map((function(){for(var e=this.offsetParent;e&&!m.nodeName(e,"html")&&"static"===m.css(e,"position");)e=e.offsetParent;return e||Xe}))}}),m.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},(function(e,t){var n=/Y/.test(t);m.fn[e]=function(i){return ne(this,(function(e,i,r){var a=hn(e);if(r===undefined)return a?t in a?a[t]:a.document.documentElement[i]:e[i];a?a.scrollTo(n?m(a).scrollLeft():r,n?r:m(a).scrollTop()):e[i]=r}),e,i,arguments.length,null)}})),m.each(["top","left"],(function(e,t){m.cssHooks[t]=ze(f.pixelPosition,(function(e,n){if(n)return n=Je(e,t),je.test(n)?m(e).position()[t]+"px":n}))})),m.each({Height:"height",Width:"width"},(function(e,t){m.each({padding:"inner"+e,content:t,"":"outer"+e},(function(n,i){m.fn[i]=function(i,r){var a=arguments.length&&(n||"boolean"!=typeof i),o=n||(!0===i||!0===r?"margin":"border");return ne(this,(function(t,n,i){var r;return m.isWindow(t)?t.document.documentElement["client"+e]:9===t.nodeType?(r=t.documentElement,Math.max(t.body["scroll"+e],r["scroll"+e],t.body["offset"+e],r["offset"+e],r["client"+e])):i===undefined?m.css(t,n,o):m.style(t,n,i,o)}),t,a?i:undefined,a,null)}}))})),m.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,i){return this.on(t,e,n,i)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}}),m.fn.size=function(){return this.length},m.fn.andSelf=m.fn.addBack,(i=function(){return m}.apply(t,[]))===undefined||(e.exports=i);var pn=n.jQuery,dn=n.$;return m.noConflict=function(e){return n.$===m&&(n.$=dn),e&&n.jQuery===m&&(n.jQuery=pn),m},n.$||n.jQuery||(n.jQuery=n.$=m),BI.jQuery=BI.$=m,m},"object"==typeof e.exports?e.exports=r.document?a(r):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return a(e)}:a(r)},function(e,t){BI.$.extend(BI.$.Event.prototype,{stopEvent:function(){this.stopPropagation(),this.preventDefault()}})},function(e,t){var n;BI.jQuery&&((n=BI.jQuery).fn.insets||(n.fn.insets=function(){var e=this.padding(),t=this.border();return{top:e.top,bottom:e.bottom+t.bottom+t.top,left:e.left,right:e.right+t.right+t.left}}),n.fn.bounds||(n.fn.bounds=function(e){var t={hasIgnoredBounds:!0};return e?(isNaN(e.x)||(t.left=e.x),isNaN(e.y)||(t.top=e.y),null!=e.width&&(t.width=e.width-(this.outerWidth(!0)-this.width()),t.width=t.width>=0?t.width:e.width),null!=e.height&&(t.height=e.height-(this.outerHeight(!0)-this.height()),t.height=t.height>=0?t.height:e.height),this.css(t),this):{x:(t=this.position()).left,y:t.top,width:this.outerWidth(),height:this.outerHeight()}}),BI.extend(BI.jQuery.fn,{destroy:function(){this.remove(),!0===BI.isIE()&&(this[0].outerHTML="")},__textKeywordMarked__:function(e,t,n){if(BI.isNull(e)&&(e=""),!BI.isKey(t)||(e+"").length>100)return BI.isIE9Below()?this.html(BI.htmlEncode(e)):(this[0].textContent=e,this);t+="",t=BI.toUpperCase(t);var i=e+"";for(n=(n||BI.makeFirstPY(e,{splitChar:""}))+"",n=BI.toUpperCase(n),this.empty();n.length>0&&i.length>0;){var r=BI.toUpperCase(i).indexOf(t),a=n.indexOf(t);if(a>=0&&(a=(a-Math.floor(a/(i.length+1)))%i.length),r>=0&&(a>r||-1===a))this.append(BI.htmlEncode(i.substr(0,r))),this.append(BI.$("<span>").addClass("bi-keyword-red-mark").html(BI.htmlEncode(i.substr(r,t.length)))),i=i.substr(r+t.length),BI.isNotEmptyString(n)&&(n=BI.map(n.split(""),(function(e,n){return n.slice(r+t.length)})).join(""));else{if(!(a>=0)){this.append(BI.htmlEncode(i));break}this.append(BI.htmlEncode(i.substr(0,a))),this.append(BI.$("<span>").addClass("bi-keyword-red-mark").html(BI.htmlEncode(i.substr(a,t.length)))),BI.isNotEmptyString(n)&&(n=BI.map(n.split(""),(function(e,n){return n.slice(a+t.length)})).join("")),i=i.substr(a+t.length)}}return this},getDomHeight:function(e){var t=BI.$(this).clone();t.appendTo(BI.$(e||"body"));var n=t.height();return t.remove(),n},hasVerticalScroll:function(){return this.height()>0&&this[0].clientWidth<this[0].offsetWidth},hasHorizonScroll:function(){return this.width()>0&&this[0].clientHeight<this[0].offsetHeight},getStyle:function(e){var t=this[0],n=void 0;if(_global.getComputedStyle&&(n=_global.getComputedStyle(t,null)))return n.getPropertyValue(BI.hyphenate(e));if(document.defaultView&&document.defaultView.getComputedStyle){if(n=document.defaultView.getComputedStyle(t,null))return n.getPropertyValue(BI.hyphenate(e));if("display"===e)return"none"}return t.currentStyle?"float"===e?t.currentStyle.cssFloat||t.currentStyle.styleFloat:t.currentStyle[BI.camelize(e)]:t.style&&t.style[BI.camelize(e)]},__isMouseInBounds__:function(e){var t=this.get(0).getBoundingClientRect?this.get(0).getBoundingClientRect():this.offset(),n=t.width||this.outerWidth(),i=t.height||this.outerHeight();return!(e.pageX<Math.floor(t.left)||e.pageX>t.left+n||e.pageY<Math.floor(t.top)||e.pageY>t.top+i)},__hasZIndexMask__:function(e){return e&&null!=this.zIndexMask[e]},__buildZIndexMask__:function(e,t){this.zIndexMask=this.zIndexMask||{},this.indexMask=this.indexMask||[];var n=BI.createWidget({type:"bi.center_adapt",cls:"bi-z-index-mask",items:t});return n.element.css({"z-index":e}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:n,left:0,right:0,top:0,bottom:0}]}),this.indexMask.push(n),e&&(this.zIndexMask[e]=n),n.element},__releaseZIndexMask__:function(e){if(e&&this.zIndexMask[e])return BI.remove(this.indexMask,this.zIndexMask[e]),void this.zIndexMask[e].destroy();this.indexMask=this.indexMask||[];var t=this.indexMask.pop();t&&t.destroy()}}))},function(e,t){!function(e){var t,n,i=["wheel","mousewheel","DOMMouseScroll","MozMousePixelScroll"],r="onwheel"in document||document.documentMode>=9?["wheel"]:["mousewheel","DomMouseScroll","MozMousePixelScroll"],a=Array.prototype.slice;if(e.event.fixHooks)for(var o=i.length;o;)e.event.fixHooks[i[--o]]=e.event.mouseHooks;var s=e.event.special.mousewheel={version:"3.1.12",setup:function(){if(this.addEventListener)for(var e=r.length;e;)this.addEventListener(r[--e],l,!1);else this.onmousewheel=l},teardown:function(){if(this.removeEventListener)for(var e=r.length;e;)this.removeEventListener(r[--e],l,!1);else this.onmousewheel=null},settings:{adjustOldDeltas:!0,normalizeOffset:!0}};function l(i){var r=i||_global.event,o=a.call(arguments,1),l=0,h=0,p=0,d=0,f=0,g=0;if((i=e.event.fix(r)).type="mousewheel","detail"in r&&(p=-1*r.detail),"wheelDelta"in r&&(p=r.wheelDelta),"wheelDeltaY"in r&&(p=r.wheelDeltaY),"wheelDeltaX"in r&&(h=-1*r.wheelDeltaX),"axis"in r&&r.axis===r.HORIZONTAL_AXIS&&(h=-1*p,p=0),l=0===p?h:p,"deltaY"in r&&(l=p=-1*r.deltaY),"deltaX"in r&&(h=r.deltaX,0===p&&(l=-1*h)),0!==p||0!==h){if(1===r.deltaMode){var m=40;l*=m,p*=m,h*=m}else if(2===r.deltaMode){var I=800;l*=I,p*=I,h*=I}if(d=Math.max(Math.abs(p),Math.abs(h)),(!n||d<n)&&(n=d,c(r,d)&&(n/=40)),c(r,d)&&(l/=40,h/=40,p/=40),l=Math[l>=1?"floor":"ceil"](l/n),h=Math[h>=1?"floor":"ceil"](h/n),p=Math[p>=1?"floor":"ceil"](p/n),s.settings.normalizeOffset&&this.getBoundingClientRect){var B=this.getBoundingClientRect();f=i.clientX-B.left,g=i.clientY-B.top}return i.deltaX=h,i.deltaY=p,i.deltaFactor=n,i.offsetX=f,i.offsetY=g,i.deltaMode=0,o.unshift(i,l,h,p),t&&clearTimeout(t),t=setTimeout(u,200),(e.event.dispatch||e.event.handle).apply(this,o)}}function u(){n=null}function c(e,t){return s.settings.adjustOldDeltas&&"mousewheel"===e.type&&t%120==0}e.fn.extend({mousewheel:function(e){return e?this.bind("mousewheel",e):this.trigger("mousewheel")},unmousewheel:function(e){return this.unbind("mousewheel",e)}})}(BI.jQuery)},function(e,t){var n;_.extend(BI,{$import:(n={},function(e,t,i){if(function(e,t){var i=BI.$("head script, body script");BI.$.each(i,(function(t,i){-1!=i.src.indexOf(e)&&(n[e]=!0)}));var r=BI.$("head link");BI.$.each(r,(function(i,r){-1!=r.href.indexOf(e)&&t&&(n[e]=!1,BI.$(r).remove())}))}(e,i),!0!==n[e])if("css"===t){var r=document.createElement("link");r.rel="stylesheet",r.type="text/css",r.href=e,document.getElementsByTagName("head")[0].appendChild(r),n[e]=!0}else BI.$.ajax({url:e,dataType:"script",async:!1,cache:!0,complete:function(t,i){"success"==i&&(n[e]=!0)}})})})},function(e,t){!function(){var e={on:function(e,t,i){return n(this,"on",e,[t,i])&&t?(this._events||(this._events={}),(this._events[e]||(this._events[e]=[])).push({callback:t,context:i,ctx:i||this}),this):this},once:function(e,t,i){if(!n(this,"once",e,[t,i])||!t)return this;var r=this,a=_.once((function(){r.off(e,a),t.apply(this,arguments)}));return a._callback=t,this.on(e,a,i)},off:function(e,t,i){if(!this._events||!n(this,"off",e,[t,i]))return this;if(!e&&!t&&!i)return this._events=void 0,this;for(var r=e?[e]:_.keys(this._events),a=0,o=r.length;a<o;a++){e=r[a];var s=this._events[e];if(s)if(t||i){for(var l=[],u=0,c=s.length;u<c;u++){var h=s[u];(t&&t!==h.callback&&t!==h.callback._callback||i&&i!==h.context)&&l.push(h)}l.length?this._events[e]=l:delete this._events[e]}else delete this._events[e]}return this},un:function(){this.off.apply(this,arguments)},trigger:function(e){if(!this._events)return this;var t=slice.call(arguments,1);if(!n(this,"trigger",e,t))return this;var r=this._events[e],a=this._events.all;return r&&i(r,t),a&&i(a,arguments),this},fireEvent:function(){this.trigger.apply(this,arguments)},listenTo:function(e,t,n){return(this._listeningTo||(this._listeningTo={}))[e._listenId||(e._listenId=_.uniqueId("l"))]=e,n||"object"!=typeof t||(n=this),e.on(t,n,this),this},listenToOnce:function(e,n,i){if("object"==typeof n){for(var r in n)this.listenToOnce(e,r,n[r]);return this}if(t.test(n)){for(var a=n.split(t),o=0,s=a.length;o<s;o++)this.listenToOnce(e,a[o],i);return this}if(!i)return this;var l=_.once((function(){this.stopListening(e,n,l),i.apply(this,arguments)}));return l._callback=i,this.listenTo(e,n,l)},stopListening:function(e,t,n){var i=this._listeningTo;if(!i)return this;var r=!t&&!n;for(var a in n||"object"!=typeof t||(n=this),e&&((i={})[e._listenId]=e),i)(e=i[a]).off(t,n,this),(r||_.isEmpty(e._events))&&delete this._listeningTo[a];return this}},t=/\s+/,n=function(e,n,i,r){if(!i)return!0;if("object"==typeof i){for(var a in i)e[n].apply(e,[a,i[a]].concat(r));return!1}if(t.test(i)){for(var o=i.split(t),s=0,l=o.length;s<l;s++)e[n].apply(e,[o[s]].concat(r));return!1}return!0},i=function(e,t){var n,i=-1,r=e.length,a=t[0],o=t[1],s=t[2];switch(t.length){case 0:for(;++i<r;)(n=e[i]).callback.call(n.ctx);return;case 1:for(;++i<r;)(n=e[i]).callback.call(n.ctx,a);return;case 2:for(;++i<r;)(n=e[i]).callback.call(n.ctx,a,o);return;case 3:for(;++i<r;)(n=e[i]).callback.call(n.ctx,a,o,s);return;default:for(;++i<r;)(n=e[i]).callback.apply(n.ctx,t);return}},r=BI.Router=function(e){e||(e={}),e.routes&&(this.routes=e.routes),this._bindRoutes(),this._init.apply(this,arguments)},a=/\((.*?)\)/g,o=/(\(\?)?:\w+/g,s=/\*\w+/g,l=/[\-{}\[\]+?.,\\\^$|#\s]/g;_.extend(r.prototype,e,{_init:function(){},route:function(e,t,n){_.isRegExp(e)||(e=this._routeToRegExp(e)),_.isFunction(t)&&(n=t,t=""),n||(n=this[t]);var i=this;return BI.history.route(e,(function(r){var a=i._extractParameters(e,r);!1!==i.execute(n,a,t)&&(i.trigger.apply(i,["route:"+t].concat(a)),i.trigger("route",t,a),BI.history.trigger("route",i,t,a))})),this},execute:function(e,t,n){e&&e.apply(this,t)},navigate:function(e,t){return BI.history.navigate(e,t),this},_bindRoutes:function(){if(this.routes){this.routes=_.result(this,"routes");for(var e,t=_.keys(this.routes);null!=(e=t.pop());)this.route(e,this.routes[e])}},_routeToRegExp:function(e){return e=e.replace(l,"\\$&").replace(a,"(?:$1)?").replace(o,(function(e,t){return t?e:"([^/?]+)"})).replace(s,"([^?]*?)"),new RegExp("^"+e+"(?:\\?([\\s\\S]*))?$")},_extractParameters:function(e,t){var n=e.exec(t).slice(1);return _.map(n,(function(e,t){if(t===n.length-1)return e||null;var i=null;if(e)try{i=decodeURIComponent(e)}catch(r){i=e}return i}))}});var u=function(){this.handlers=[],this.checkUrl=_.bind(this.checkUrl,this),"undefined"!=typeof window&&(this.location=_global.location,this.history=_global.history)},c=/^[#\/]|\s+$/g,h=/^\/+|\/+$/g,p=/#.*$/;u.started=!1,_.extend(u.prototype,e,{interval:50,atRoot:function(){return this.location.pathname.replace(/[^\/]$/,"$&/")===this.root&&!this.getSearch()},getSearch:function(){var e=this.location.href.replace(/#.*/,"").match(/\?.+/);return e?e[0]:""},getHash:function(e){var t=(e||this).location.href.match(/#(.*)$/);return t?t[1]:""},getPath:function(){var e=this.location.pathname+this.getSearch();try{e=decodeURI(e)}catch(n){}var t=this.root.slice(0,-1);return e.indexOf(t)||(e=e.slice(t.length)),"/"===e.charAt(0)?e.slice(1):e},getFragment:function(e){return null==e&&(e=this._hasPushState||!this._wantsHashChange?this.getPath():this.getHash()),e.replace(c,"")},start:function(e){if(u.started)throw new Error("BI.history has already been started");if(u.started=!0,this.options=_.extend({root:"/"},this.options,e),this.root=this.options.root,this._wantsHashChange=!1!==this.options.hashChange,this._hasHashChange="onhashchange"in window,this._wantsPushState=!!this.options.pushState,this._hasPushState=!!(this.options.pushState&&this.history&&this.history.pushState),this.fragment=this.getFragment(),this.root=("/"+this.root+"/").replace(h,"/"),this._wantsHashChange&&this._wantsPushState){if(!this._hasPushState&&!this.atRoot()){var t=this.root.slice(0,-1)||"/";return this.location.replace(t+"#"+this.getPath()),!0}this._hasPushState&&this.atRoot()&&this.navigate(this.getHash(),{replace:!0})}if(!this._hasHashChange&&this._wantsHashChange&&(!this._wantsPushState||!this._hasPushState)){var n=document.createElement("iframe");n.src="javascript:0",n.style.display="none",n.tabIndex=-1;var i=document.body;this.iframe=i.insertBefore(n,i.firstChild).contentWindow,this.iframe.document.open().close(),this.iframe.location.hash="#"+this.fragment}var r=_global.addEventListener||function(e,t){return attachEvent("on"+e,t)};if(this._hasPushState?r("popstate",this.checkUrl,!1):this._wantsHashChange&&this._hasHashChange&&!this.iframe?r("hashchange",this.checkUrl,!1):this._wantsHashChange&&(this._checkUrlInterval=setInterval(this.checkUrl,this.interval)),!this.options.silent)return this.loadUrl()},stop:function(){var e=_global.removeEventListener||function(e,t){return detachEvent("on"+e,t)};this._hasPushState?e("popstate",this.checkUrl,!1):this._wantsHashChange&&this._hasHashChange&&!this.iframe&&e("hashchange",this.checkUrl,!1),this.iframe&&(document.body.removeChild(this.iframe.frameElement),this.iframe=null),this._checkUrlInterval&&clearInterval(this._checkUrlInterval),u.started=!1},route:function(e,t){this.handlers.unshift({route:e,callback:t})},checkRoute:function(e){for(var t=0;t<this.handlers.length;t++)if(this.handlers[t].route.toString()===r.prototype._routeToRegExp(e).toString())return this.handlers[t];return null},unRoute:function(e){var t=_.findIndex(this.handlers,(function(t){return t.route.test(e)}));t>-1&&this.handlers.splice(t,1)},checkUrl:function(e){var t=this.getFragment();try{t=decodeURIComponent(t)}catch(e){}if(t===this.fragment&&this.iframe&&(t=this.getHash(this.iframe)),t===this.fragment)return!1;this.iframe&&this.navigate(t),this.loadUrl()},loadUrl:function(e){return e=this.fragment=this.getFragment(e),_.some(this.handlers,(function(t){if(t.route.test(e))return t.callback(e),!0}))},navigate:function(e,t){if(!u.started)return!1;t&&!0!==t||(t={trigger:!!t}),e=this.getFragment(e||"");var n=this.root;""!==e&&"?"!==e.charAt(0)||(n=n.slice(0,-1)||"/");var i=n+e;e=e.replace(p,"");try{e=decodeURI(e)}catch(r){}if(this.fragment!==e){if(this.fragment=e,this._hasPushState)this.history[t.replace?"replaceState":"pushState"]({},document.title,i);else{if(!this._wantsHashChange)return this.location.assign(i);this._updateHash(this.location,e,t.replace),this.iframe&&e!==this.getHash(this.iframe)&&(t.replace||this.iframe.document.open().close(),this._updateHash(this.iframe.location,e,t.replace))}return t.trigger?this.loadUrl(e):void 0}},_updateHash:function(e,t,n){if(n){var i=e.href.replace(/(javascript:|#).*$/,"");e.replace(i+"#"+t)}else e.hash="#"+t}}),BI.history=new u}()},function(e,t){!function(){var e=" !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~⺀⺁⺂⺃⺄⺅⺆⺇⺈⺉⺊⺋⺌⺍⺎⺏⺐⺑⺒⺓⺔⺕⺖⺗⺘⺙⺚⺛⺜⺝⺞⺟⺠⺡⺢⺣⺤⺥⺦⺧⺨⺩⺪⺫⺬⺭⺮⺯⺰⺱⺲⺳⺴⺵⺶⺷⺸⺹⺺⺻⺼⺽⺾⺿⻀⻁⻂⻃⻄⻅⻆⻇⻈⻉⻊⻋⻌⻍⻎⻏⻐⻑⻒⻓⻔⻕⻖⻗⻘⻙⻚⻛⻜⻝⻞⻟⻠⻡⻢⻣⻤⻥⻦⻧⻨⻩⻪⻫⻬⻭⻮⻯⻰⻱⻲⻳⻴⻵⻶⻷⻸⻹⻺⻻⻼⻽⻾⻿⼀⼁⼂⼃⼄⼅⼆⼇⼈⼉⼊⼋⼌⼍⼎⼏⼐⼑⼒⼓⼔⼕⼖⼗⼘⼙⼚⼛⼜⼝⼞⼟⼠⼡⼢⼣⼤⼥⼦⼧⼨⼩⼪⼫⼬⼭⼮⼯⼰⼱⼲⼳⼴⼵⼶⼷⼸⼹⼺⼻⼼⼽⼾⼿⽀⽁⽂⽃⽄⽅⽆⽇⽈⽉⽊⽋⽌⽍⽎⽏⽐⽑⽒⽓⽔⽕⽖⽗⽘⽙⽚⽛⽜⽝⽞⽟⽠⽡⽢⽣⽤⽥⽦⽧⽨⽩⽪⽫⽬⽭⽮⽯⽰⽱⽲⽳⽴⽵⽶⽷⽸⽹⽺⽻⽼⽽⽾⽿⾀⾁⾂⾃⾄⾅⾆⾇⾈⾉⾊⾋⾌⾍⾎⾏⾐⾑⾒⾓⾔⾕⾖⾗⾘⾙⾚⾛⾜⾝⾞⾟⾠⾡⾢⾣⾤⾥⾦⾧⾨⾩⾪⾫⾬⾭⾮⾯⾰⾱⾲⾳⾴⾵⾶⾷⾸⾹⾺⾻⾼⾽⾾⾿⿀⿁⿂⿃⿄⿅⿆⿇⿈⿉⿊⿋⿌⿍⿎⿏⿐⿑⿒⿓⿔⿕⿖⿗⿘⿙⿚⿛⿜⿝⿞⿟⿠⿡⿢⿣⿤⿥⿦⿧⿨⿩⿪⿫⿬⿭⿮⿯⿰⿱⿲⿳⿴⿵⿶⿷⿸⿹⿺⿻⿼⿽⿾⿿ 、。〃〄々〆〇〈〉《》「」『』【】〒〓〔〕〖〗〘〙〚〛〜〝〞〟〠〡〢〣〤〥〦〧〨〩〰〱〲〳〴〵〶〷〸〹〺〻〼〽〾〿぀ぁあぃいぅうぇえぉおかがきぎくぐけげこごさざしじすずせぜそぞただちぢっつづてでとどなにぬねのはばぱひびぴふぶぷへべぺほぼぽまみむめもゃやゅゆょよらりるれろゎわゐゑをんゔゕゖ゗゘゛゜ゝゞゟ゠ァアィイゥウェエォオカガキギクグケゲコゴサザシジスズセゼソゾタダチヂッツヅテデトドナニヌネノハバパヒビピフブプヘベペホボポマミムメモャヤュユョヨラリルレロヮワヰヱヲンヴヵヶヷヸヹヺ・ーヽヾヿ㄀㄁㄂㄃㄄ㄅㄆㄇㄈㄉㄊㄋㄌㄍㄎㄏㄐㄑㄒㄓㄔㄕㄖㄗㄘㄙㄚㄛㄜㄝㄞㄟㄠㄡㄢㄣㄤㄥㄦㄧㄨㄩㄪㄫㄬㄭㄮㄯ㄰ㄱㄲㄳㄴㄵㄶㄷㄸㄹㄺㄻㄼㄽㄾㄿㅀㅁㅂㅃㅄㅅㅆㅇㅈㅉㅊㅋㅌㅍㅎㅏㅐㅑㅒㅓㅔㅕㅖㅗㅘㅙㅚㅛㅜㅝㅞㅟㅠㅡㅢㅣㅤㅥㅦㅧㅨㅩㅪㅫㅬㅭㅮㅯㅰㅱㅲㅳㅴㅵㅶㅷㅸㅹㅺㅻㅼㅽㅾㅿㆀㆁㆂㆃㆄㆅㆆㆇㆈㆉㆊㆋㆌㆍㆎ㆏㆐㆑㆒㆓㆔㆕㆖㆗㆘㆙㆚㆛㆜㆝㆞㆟ㆠㆡㆢㆣㆤㆥㆦㆧㆨㆩㆪㆫㆬㆭㆮㆯㆰㆱㆲㆳㆴㆵㆶㆷㆸㆹㆺㆻㆼㆽㆾㆿ㇀㇁㇂㇃㇄㇅㇆㇇㇈㇉㇊㇋㇌㇍㇎㇏㇐㇑㇒㇓㇔㇕㇖㇗㇘㇙㇚㇛㇜㇝㇞㇟㇠㇡㇢㇣㇤㇥㇦㇧㇨㇩㇪㇫㇬㇭㇮㇯ㇰㇱㇲㇳㇴㇵㇶㇷㇸㇹㇺㇻㇼㇽㇾㇿ㈀㈁㈂㈃㈄㈅㈆㈇㈈㈉㈊㈋㈌㈍㈎㈏㈐㈑㈒㈓㈔㈕㈖㈗㈘㈙㈚㈛㈜㈝㈞㈟㈠㈡㈢㈣㈤㈥㈦㈧㈨㈩㈪㈫㈬㈭㈮㈯㈰㈱㈲㈳㈴㈵㈶㈷㈸㈹㈺㈻㈼㈽㈾㈿㉀㉁㉂㉃㉄㉅㉆㉇㉈㉉㉊㉋㉌㉍㉎㉏㉐㉑㉒㉓㉔㉕㉖㉗㉘㉙㉚㉛㉜㉝㉞㉟㉠㉡㉢㉣㉤㉥㉦㉧㉨㉩㉪㉫㉬㉭㉮㉯㉰㉱㉲㉳㉴㉵㉶㉷㉸㉹㉺㉻㉼㉽㉾㉿㊀㊁㊂㊃㊄㊅㊆㊇㊈㊉㊊㊋㊌㊍㊎㊏㊐㊑㊒㊓㊔㊕㊖㊗㊘㊙㊚㊛㊜㊝㊞㊟㊠㊡㊢㊣㊤㊥㊦㊧㊨㊩㊪㊫㊬㊭㊮㊯㊰㊱㊲㊳㊴㊵㊶㊷㊸㊹㊺㊻㊼㊽㊾㊿㋀㋁㋂㋃㋄㋅㋆㋇㋈㋉㋊㋋㋌㋍㋎㋏㋐㋑㋒㋓㋔㋕㋖㋗㋘㋙㋚㋛㋜㋝㋞㋟㋠㋡㋢㋣㋤㋥㋦㋧㋨㋩㋪㋫㋬㋭㋮㋯㋰㋱㋲㋳㋴㋵㋶㋷㋸㋹㋺㋻㋼㋽㋾㋿㌀㌁㌂㌃㌄㌅㌆㌇㌈㌉㌊㌋㌌㌍㌎㌏㌐㌑㌒㌓㌔㌕㌖㌗㌘㌙㌚㌛㌜㌝㌞㌟㌠㌡㌢㌣㌤㌥㌦㌧㌨㌩㌪㌫㌬㌭㌮㌯㌰㌱㌲㌳㌴㌵㌶㌷㌸㌹㌺㌻㌼㌽㌾㌿㍀㍁㍂㍃㍄㍅㍆㍇㍈㍉㍊㍋㍌㍍㍎㍏㍐㍑㍒㍓㍔㍕㍖㍗㍘㍙㍚㍛㍜㍝㍞㍟㍠㍡㍢㍣㍤㍥㍦㍧㍨㍩㍪㍫㍬㍭㍮㍯㍰㍱㍲㍳㍴㍵㍶㍷㍸㍹㍺㍻㍼㍽㍾㍿㎀㎁㎂㎃㎄㎅㎆㎇㎈㎉㎊㎋㎌㎍㎎㎏㎐㎑㎒㎓㎔㎕㎖㎗㎘㎙㎚㎛㎜㎝㎞㎟㎠㎡㎢㎣㎤㎥㎦㎧㎨㎩㎪㎫㎬㎭㎮㎯㎰㎱㎲㎳㎴㎵㎶㎷㎸㎹㎺㎻㎼㎽㎾㎿㏀㏁㏂㏃㏄㏅㏆㏇㏈㏉㏊㏋㏌㏍㏎㏏㏐㏑㏒㏓㏔㏕㏖㏗㏘㏙㏚㏛㏜㏝㏞㏟㏠㏡㏢㏣㏤㏥㏦㏧㏨㏩㏪㏫㏬㏭㏮㏯㏰㏱㏲㏳㏴㏵㏶㏷㏸㏹㏺㏻㏼㏽㏾㏿㐀㐁㐂㐃㐄㐅㐆㐇㐈㐉㐊㐋㐌㐍㐎㐏㐐㐑㐒㐓㐔㐕㐖㐗㐘㐙㐚㐛㐜㐝㐞㐟㐠㐡㐢㐣㐤㐥㐦㐧㐨㐩㐪㐫㐬㐭㐮㐯㐰㐱㐲㐳㐴㐵㐶㐷㐸㐹㐺㐻㐼㐽㐾㐿㑀㑁㑂㑃㑄㑅㑆㑇㑈㑉㑊㑋㑌㑍㑎㑏㑐㑑㑒㑓㑔㑕㑖㑗㑘㑙㑚㑛㑜㑝㑞㑟㑠㑡㑢㑣㑤㑥㑦㑧㑨㑩㑪㑫㑬㑭㑮㑯㑰㑱㑲㑳㑴㑵㑶㑷㑸㑹㑺㑻㑼㑽㑾㑿㒀㒁㒂㒃㒄㒅㒆㒇㒈㒉㒊㒋㒌㒍㒎㒏㒐㒑㒒㒓㒔㒕㒖㒗㒘㒙㒚㒛㒜㒝㒞㒟㒠㒡㒢㒣㒤㒥㒦㒧㒨㒩㒪㒫㒬㒭㒮㒯㒰㒱㒲㒳㒴㒵㒶㒷㒸㒹㒺㒻㒼㒽㒾㒿㓀㓁㓂㓃㓄㓅㓆㓇㓈㓉㓊㓋㓌㓍㓎㓏㓐㓑㓒㓓㓔㓕㓖㓗㓘㓙㓚㓛㓜㓝㓞㓟㓠㓡㓢㓣㓤㓥㓦㓧㓨㓩㓪㓫㓬㓭㓮㓯㓰㓱㓲㓳㓴㓵㓶㓷㓸㓹㓺㓻㓼㓽㓾㓿㔀㔁㔂㔃㔄㔅㔆㔇㔈㔉㔊㔋㔌㔍㔎㔏㔐㔑㔒㔓㔔㔕㔖㔗㔘㔙㔚㔛㔜㔝㔞㔟㔠㔡㔢㔣㔤㔥㔦㔧㔨㔩㔪㔫㔬㔭㔮㔯㔰㔱㔲㔳㔴㔵㔶㔷㔸㔹㔺㔻㔼㔽㔾㔿㕀㕁㕂㕃㕄㕅㕆㕇㕈㕉㕊㕋㕌㕍㕎㕏㕐㕑㕒㕓㕔㕕㕖㕗㕘㕙㕚㕛㕜㕝㕞㕟㕠㕡㕢㕣㕤㕥㕦㕧㕨㕩㕪㕫㕬㕭㕮㕯㕰㕱㕲㕳㕴㕵㕶㕷㕸㕹㕺㕻㕼㕽㕾㕿㖀㖁㖂㖃㖄㖅㖆㖇㖈㖉㖊㖋㖌㖍㖎㖏㖐㖑㖒㖓㖔㖕㖖㖗㖘㖙㖚㖛㖜㖝㖞㖟㖠㖡㖢㖣㖤㖥㖦㖧㖨㖩㖪㖫㖬㖭㖮㖯㖰㖱㖲㖳㖴㖵㖶㖷㖸㖹㖺㖻㖼㖽㖾㖿㗀㗁㗂㗃㗄㗅㗆㗇㗈㗉㗊㗋㗌㗍㗎㗏㗐㗑㗒㗓㗔㗕㗖㗗㗘㗙㗚㗛㗜㗝㗞㗟㗠㗡㗢㗣㗤㗥㗦㗧㗨㗩㗪㗫㗬㗭㗮㗯㗰㗱㗲㗳㗴㗵㗶㗷㗸㗹㗺㗻㗼㗽㗾㗿㘀㘁㘂㘃㘄㘅㘆㘇㘈㘉㘊㘋㘌㘍㘎㘏㘐㘑㘒㘓㘔㘕㘖㘗㘘㘙㘚㘛㘜㘝㘞㘟㘠㘡㘢㘣㘤㘥㘦㘧㘨㘩㘪㘫㘬㘭㘮㘯㘰㘱㘲㘳㘴㘵㘶㘷㘸㘹㘺㘻㘼㘽㘾㘿㙀㙁㙂㙃㙄㙅㙆㙇㙈㙉㙊㙋㙌㙍㙎㙏㙐㙑㙒㙓㙔㙕㙖㙗㙘㙙㙚㙛㙜㙝㙞㙟㙠㙡㙢㙣㙤㙥㙦㙧㙨㙩㙪㙫㙬㙭㙮㙯㙰㙱㙲㙳㙴㙵㙶㙷㙸㙹㙺㙻㙼㙽㙾㙿㚀㚁㚂㚃㚄㚅㚆㚇㚈㚉㚊㚋㚌㚍㚎㚏㚐㚑㚒㚓㚔㚕㚖㚗㚘㚙㚚㚛㚜㚝㚞㚟㚠㚡㚢㚣㚤㚥㚦㚧㚨㚩㚪㚫㚬㚭㚮㚯㚰㚱㚲㚳㚴㚵㚶㚷㚸㚹㚺㚻㚼㚽㚾㚿㛀㛁㛂㛃㛄㛅㛆㛇㛈㛉㛊㛋㛌㛍㛎㛏㛐㛑㛒㛓㛔㛕㛖㛗㛘㛙㛚㛛㛜㛝㛞㛟㛠㛡㛢㛣㛤㛥㛦㛧㛨㛩㛪㛫㛬㛭㛮㛯㛰㛱㛲㛳㛴㛵㛶㛷㛸㛹㛺㛻㛼㛽㛾㛿㜀㜁㜂㜃㜄㜅㜆㜇㜈㜉㜊㜋㜌㜍㜎㜏㜐㜑㜒㜓㜔㜕㜖㜗㜘㜙㜚㜛㜜㜝㜞㜟㜠㜡㜢㜣㜤㜥㜦㜧㜨㜩㜪㜫㜬㜭㜮㜯㜰㜱㜲㜳㜴㜵㜶㜷㜸㜹㜺㜻㜼㜽㜾㜿㝀㝁㝂㝃㝄㝅㝆㝇㝈㝉㝊㝋㝌㝍㝎㝏㝐㝑㝒㝓㝔㝕㝖㝗㝘㝙㝚㝛㝜㝝㝞㝟㝠㝡㝢㝣㝤㝥㝦㝧㝨㝩㝪㝫㝬㝭㝮㝯㝰㝱㝲㝳㝴㝵㝶㝷㝸㝹㝺㝻㝼㝽㝾㝿㞀㞁㞂㞃㞄㞅㞆㞇㞈㞉㞊㞋㞌㞍㞎㞏㞐㞑㞒㞓㞔㞕㞖㞗㞘㞙㞚㞛㞜㞝㞞㞟㞠㞡㞢㞣㞤㞥㞦㞧㞨㞩㞪㞫㞬㞭㞮㞯㞰㞱㞲㞳㞴㞵㞶㞷㞸㞹㞺㞻㞼㞽㞾㞿㟀㟁㟂㟃㟄㟅㟆㟇㟈㟉㟊㟋㟌㟍㟎㟏㟐㟑㟒㟓㟔㟕㟖㟗㟘㟙㟚㟛㟜㟝㟞㟟㟠㟡㟢㟣㟤㟥㟦㟧㟨㟩㟪㟫㟬㟭㟮㟯㟰㟱㟲㟳㟴㟵㟶㟷㟸㟹㟺㟻㟼㟽㟾㟿㠀㠁㠂㠃㠄㠅㠆㠇㠈㠉㠊㠋㠌㠍㠎㠏㠐㠑㠒㠓㠔㠕㠖㠗㠘㠙㠚㠛㠜㠝㠞㠟㠠㠡㠢㠣㠤㠥㠦㠧㠨㠩㠪㠫㠬㠭㠮㠯㠰㠱㠲㠳㠴㠵㠶㠷㠸㠹㠺㠻㠼㠽㠾㠿㡀㡁㡂㡃㡄㡅㡆㡇㡈㡉㡊㡋㡌㡍㡎㡏㡐㡑㡒㡓㡔㡕㡖㡗㡘㡙㡚㡛㡜㡝㡞㡟㡠㡡㡢㡣㡤㡥㡦㡧㡨㡩㡪㡫㡬㡭㡮㡯㡰㡱㡲㡳㡴㡵㡶㡷㡸㡹㡺㡻㡼㡽㡾㡿㢀㢁㢂㢃㢄㢅㢆㢇㢈㢉㢊㢋㢌㢍㢎㢏㢐㢑㢒㢓㢔㢕㢖㢗㢘㢙㢚㢛㢜㢝㢞㢟㢠㢡㢢㢣㢤㢥㢦㢧㢨㢩㢪㢫㢬㢭㢮㢯㢰㢱㢲㢳㢴㢵㢶㢷㢸㢹㢺㢻㢼㢽㢾㢿㣀㣁㣂㣃㣄㣅㣆㣇㣈㣉㣊㣋㣌㣍㣎㣏㣐㣑㣒㣓㣔㣕㣖㣗㣘㣙㣚㣛㣜㣝㣞㣟㣠㣡㣢㣣㣤㣥㣦㣧㣨㣩㣪㣫㣬㣭㣮㣯㣰㣱㣲㣳㣴㣵㣶㣷㣸㣹㣺㣻㣼㣽㣾㣿㤀㤁㤂㤃㤄㤅㤆㤇㤈㤉㤊㤋㤌㤍㤎㤏㤐㤑㤒㤓㤔㤕㤖㤗㤘㤙㤚㤛㤜㤝㤞㤟㤠㤡㤢㤣㤤㤥㤦㤧㤨㤩㤪㤫㤬㤭㤮㤯㤰㤱㤲㤳㤴㤵㤶㤷㤸㤹㤺㤻㤼㤽㤾㤿㥀㥁㥂㥃㥄㥅㥆㥇㥈㥉㥊㥋㥌㥍㥎㥏㥐㥑㥒㥓㥔㥕㥖㥗㥘㥙㥚㥛㥜㥝㥞㥟㥠㥡㥢㥣㥤㥥㥦㥧㥨㥩㥪㥫㥬㥭㥮㥯㥰㥱㥲㥳㥴㥵㥶㥷㥸㥹㥺㥻㥼㥽㥾㥿㦀㦁㦂㦃㦄㦅㦆㦇㦈㦉㦊㦋㦌㦍㦎㦏㦐㦑㦒㦓㦔㦕㦖㦗㦘㦙㦚㦛㦜㦝㦞㦟㦠㦡㦢㦣㦤㦥㦦㦧㦨㦩㦪㦫㦬㦭㦮㦯㦰㦱㦲㦳㦴㦵㦶㦷㦸㦹㦺㦻㦼㦽㦾㦿㧀㧁㧂㧃㧄㧅㧆㧇㧈㧉㧊㧋㧌㧍㧎㧏㧐㧑㧒㧓㧔㧕㧖㧗㧘㧙㧚㧛㧜㧝㧞㧟㧠㧡㧢㧣㧤㧥㧦㧧㧨㧩㧪㧫㧬㧭㧮㧯㧰㧱㧲㧳㧴㧵㧶㧷㧸㧹㧺㧻㧼㧽㧾㧿㨀㨁㨂㨃㨄㨅㨆㨇㨈㨉㨊㨋㨌㨍㨎㨏㨐㨑㨒㨓㨔㨕㨖㨗㨘㨙㨚㨛㨜㨝㨞㨟㨠㨡㨢㨣㨤㨥㨦㨧㨨㨩㨪㨫㨬㨭㨮㨯㨰㨱㨲㨳㨴㨵㨶㨷㨸㨹㨺㨻㨼㨽㨾㨿㩀㩁㩂㩃㩄㩅㩆㩇㩈㩉㩊㩋㩌㩍㩎㩏㩐㩑㩒㩓㩔㩕㩖㩗㩘㩙㩚㩛㩜㩝㩞㩟㩠㩡㩢㩣㩤㩥㩦㩧㩨㩩㩪㩫㩬㩭㩮㩯㩰㩱㩲㩳㩴㩵㩶㩷㩸㩹㩺㩻㩼㩽㩾㩿㪀㪁㪂㪃㪄㪅㪆㪇㪈㪉㪊㪋㪌㪍㪎㪏㪐㪑㪒㪓㪔㪕㪖㪗㪘㪙㪚㪛㪜㪝㪞㪟㪠㪡㪢㪣㪤㪥㪦㪧㪨㪩㪪㪫㪬㪭㪮㪯㪰㪱㪲㪳㪴㪵㪶㪷㪸㪹㪺㪻㪼㪽㪾㪿㫀㫁㫂㫃㫄㫅㫆㫇㫈㫉㫊㫋㫌㫍㫎㫏㫐㫑㫒㫓㫔㫕㫖㫗㫘㫙㫚㫛㫜㫝㫞㫟㫠㫡㫢㫣㫤㫥㫦㫧㫨㫩㫪㫫㫬㫭㫮㫯㫰㫱㫲㫳㫴㫵㫶㫷㫸㫹㫺㫻㫼㫽㫾㫿㬀㬁㬂㬃㬄㬅㬆㬇㬈㬉㬊㬋㬌㬍㬎㬏㬐㬑㬒㬓㬔㬕㬖㬗㬘㬙㬚㬛㬜㬝㬞㬟㬠㬡㬢㬣㬤㬥㬦㬧㬨㬩㬪㬫㬬㬭㬮㬯㬰㬱㬲㬳㬴㬵㬶㬷㬸㬹㬺㬻㬼㬽㬾㬿㭀㭁㭂㭃㭄㭅㭆㭇㭈㭉㭊㭋㭌㭍㭎㭏㭐㭑㭒㭓㭔㭕㭖㭗㭘㭙㭚㭛㭜㭝㭞㭟㭠㭡㭢㭣㭤㭥㭦㭧㭨㭩㭪㭫㭬㭭㭮㭯㭰㭱㭲㭳㭴㭵㭶㭷㭸㭹㭺㭻㭼㭽㭾㭿㮀㮁㮂㮃㮄㮅㮆㮇㮈㮉㮊㮋㮌㮍㮎㮏㮐㮑㮒㮓㮔㮕㮖㮗㮘㮙㮚㮛㮜㮝㮞㮟㮠㮡㮢㮣㮤㮥㮦㮧㮨㮩㮪㮫㮬㮭㮮㮯㮰㮱㮲㮳㮴㮵㮶㮷㮸㮹㮺㮻㮼㮽㮾㮿㯀㯁㯂㯃㯄㯅㯆㯇㯈㯉㯊㯋㯌㯍㯎㯏㯐㯑㯒㯓㯔㯕㯖㯗㯘㯙㯚㯛㯜㯝㯞㯟㯠㯡㯢㯣㯤㯥㯦㯧㯨㯩㯪㯫㯬㯭㯮㯯㯰㯱㯲㯳㯴㯵㯶㯷㯸㯹㯺㯻㯼㯽㯾㯿㰀㰁㰂㰃㰄㰅㰆㰇㰈㰉㰊㰋㰌㰍㰎㰏㰐㰑㰒㰓㰔㰕㰖㰗㰘㰙㰚㰛㰜㰝㰞㰟㰠㰡㰢㰣㰤㰥㰦㰧㰨㰩㰪㰫㰬㰭㰮㰯㰰㰱㰲㰳㰴㰵㰶㰷㰸㰹㰺㰻㰼㰽㰾㰿㱀㱁㱂㱃㱄㱅㱆㱇㱈㱉㱊㱋㱌㱍㱎㱏㱐㱑㱒㱓㱔㱕㱖㱗㱘㱙㱚㱛㱜㱝㱞㱟㱠㱡㱢㱣㱤㱥㱦㱧㱨㱩㱪㱫㱬㱭㱮㱯㱰㱱㱲㱳㱴㱵㱶㱷㱸㱹㱺㱻㱼㱽㱾㱿㲀㲁㲂㲃㲄㲅㲆㲇㲈㲉㲊㲋㲌㲍㲎㲏㲐㲑㲒㲓㲔㲕㲖㲗㲘㲙㲚㲛㲜㲝㲞㲟㲠㲡㲢㲣㲤㲥㲦㲧㲨㲩㲪㲫㲬㲭㲮㲯㲰㲱㲲㲳㲴㲵㲶㲷㲸㲹㲺㲻㲼㲽㲾㲿㳀㳁㳂㳃㳄㳅㳆㳇㳈㳉㳊㳋㳌㳍㳎㳏㳐㳑㳒㳓㳔㳕㳖㳗㳘㳙㳚㳛㳜㳝㳞㳟㳠㳡㳢㳣㳤㳥㳦㳧㳨㳩㳪㳫㳬㳭㳮㳯㳰㳱㳲㳳㳴㳵㳶㳷㳸㳹㳺㳻㳼㳽㳾㳿㴀㴁㴂㴃㴄㴅㴆㴇㴈㴉㴊㴋㴌㴍㴎㴏㴐㴑㴒㴓㴔㴕㴖㴗㴘㴙㴚㴛㴜㴝㴞㴟㴠㴡㴢㴣㴤㴥㴦㴧㴨㴩㴪㴫㴬㴭㴮㴯㴰㴱㴲㴳㴴㴵㴶㴷㴸㴹㴺㴻㴼㴽㴾㴿㵀㵁㵂㵃㵄㵅㵆㵇㵈㵉㵊㵋㵌㵍㵎㵏㵐㵑㵒㵓㵔㵕㵖㵗㵘㵙㵚㵛㵜㵝㵞㵟㵠㵡㵢㵣㵤㵥㵦㵧㵨㵩㵪㵫㵬㵭㵮㵯㵰㵱㵲㵳㵴㵵㵶㵷㵸㵹㵺㵻㵼㵽㵾㵿㶀㶁㶂㶃㶄㶅㶆㶇㶈㶉㶊㶋㶌㶍㶎㶏㶐㶑㶒㶓㶔㶕㶖㶗㶘㶙㶚㶛㶜㶝㶞㶟㶠㶡㶢㶣㶤㶥㶦㶧㶨㶩㶪㶫㶬㶭㶮㶯㶰㶱㶲㶳㶴㶵㶶㶷㶸㶹㶺㶻㶼㶽㶾㶿㷀㷁㷂㷃㷄㷅㷆㷇㷈㷉㷊㷋㷌㷍㷎㷏㷐㷑㷒㷓㷔㷕㷖㷗㷘㷙㷚㷛㷜㷝㷞㷟㷠㷡㷢㷣㷤㷥㷦㷧㷨㷩㷪㷫㷬㷭㷮㷯㷰㷱㷲㷳㷴㷵㷶㷷㷸㷹㷺㷻㷼㷽㷾㷿㸀㸁㸂㸃㸄㸅㸆㸇㸈㸉㸊㸋㸌㸍㸎㸏㸐㸑㸒㸓㸔㸕㸖㸗㸘㸙㸚㸛㸜㸝㸞㸟㸠㸡㸢㸣㸤㸥㸦㸧㸨㸩㸪㸫㸬㸭㸮㸯㸰㸱㸲㸳㸴㸵㸶㸷㸸㸹㸺㸻㸼㸽㸾㸿㹀㹁㹂㹃㹄㹅㹆㹇㹈㹉㹊㹋㹌㹍㹎㹏㹐㹑㹒㹓㹔㹕㹖㹗㹘㹙㹚㹛㹜㹝㹞㹟㹠㹡㹢㹣㹤㹥㹦㹧㹨㹩㹪㹫㹬㹭㹮㹯㹰㹱㹲㹳㹴㹵㹶㹷㹸㹹㹺㹻㹼㹽㹾㹿㺀㺁㺂㺃㺄㺅㺆㺇㺈㺉㺊㺋㺌㺍㺎㺏㺐㺑㺒㺓㺔㺕㺖㺗㺘㺙㺚㺛㺜㺝㺞㺟㺠㺡㺢㺣㺤㺥㺦㺧㺨㺩㺪㺫㺬㺭㺮㺯㺰㺱㺲㺳㺴㺵㺶㺷㺸㺹㺺㺻㺼㺽㺾㺿㻀㻁㻂㻃㻄㻅㻆㻇㻈㻉㻊㻋㻌㻍㻎㻏㻐㻑㻒㻓㻔㻕㻖㻗㻘㻙㻚㻛㻜㻝㻞㻟㻠㻡㻢㻣㻤㻥㻦㻧㻨㻩㻪㻫㻬㻭㻮㻯㻰㻱㻲㻳㻴㻵㻶㻷㻸㻹㻺㻻㻼㻽㻾㻿㼀㼁㼂㼃㼄㼅㼆㼇㼈㼉㼊㼋㼌㼍㼎㼏㼐㼑㼒㼓㼔㼕㼖㼗㼘㼙㼚㼛㼜㼝㼞㼟㼠㼡㼢㼣㼤㼥㼦㼧㼨㼩㼪㼫㼬㼭㼮㼯㼰㼱㼲㼳㼴㼵㼶㼷㼸㼹㼺㼻㼼㼽㼾㼿㽀㽁㽂㽃㽄㽅㽆㽇㽈㽉㽊㽋㽌㽍㽎㽏㽐㽑㽒㽓㽔㽕㽖㽗㽘㽙㽚㽛㽜㽝㽞㽟㽠㽡㽢㽣㽤㽥㽦㽧㽨㽩㽪㽫㽬㽭㽮㽯㽰㽱㽲㽳㽴㽵㽶㽷㽸㽹㽺㽻㽼㽽㽾㽿㾀㾁㾂㾃㾄㾅㾆㾇㾈㾉㾊㾋㾌㾍㾎㾏㾐㾑㾒㾓㾔㾕㾖㾗㾘㾙㾚㾛㾜㾝㾞㾟㾠㾡㾢㾣㾤㾥㾦㾧㾨㾩㾪㾫㾬㾭㾮㾯㾰㾱㾲㾳㾴㾵㾶㾷㾸㾹㾺㾻㾼㾽㾾㾿㿀㿁㿂㿃㿄㿅㿆㿇㿈㿉㿊㿋㿌㿍㿎㿏㿐㿑㿒㿓㿔㿕㿖㿗㿘㿙㿚㿛㿜㿝㿞㿟㿠㿡㿢㿣㿤㿥㿦㿧㿨㿩㿪㿫㿬㿭㿮㿯㿰㿱㿲㿳㿴㿵㿶㿷㿸㿹㿺㿻㿼㿽㿾㿿䀀䀁䀂䀃䀄䀅䀆䀇䀈䀉䀊䀋䀌䀍䀎䀏䀐䀑䀒䀓䀔䀕䀖䀗䀘䀙䀚䀛䀜䀝䀞䀟䀠䀡䀢䀣䀤䀥䀦䀧䀨䀩䀪䀫䀬䀭䀮䀯䀰䀱䀲䀳䀴䀵䀶䀷䀸䀹䀺䀻䀼䀽䀾䀿䁀䁁䁂䁃䁄䁅䁆䁇䁈䁉䁊䁋䁌䁍䁎䁏䁐䁑䁒䁓䁔䁕䁖䁗䁘䁙䁚䁛䁜䁝䁞䁟䁠䁡䁢䁣䁤䁥䁦䁧䁨䁩䁪䁫䁬䁭䁮䁯䁰䁱䁲䁳䁴䁵䁶䁷䁸䁹䁺䁻䁼䁽䁾䁿䂀䂁䂂䂃䂄䂅䂆䂇䂈䂉䂊䂋䂌䂍䂎䂏䂐䂑䂒䂓䂔䂕䂖䂗䂘䂙䂚䂛䂜䂝䂞䂟䂠䂡䂢䂣䂤䂥䂦䂧䂨䂩䂪䂫䂬䂭䂮䂯䂰䂱䂲䂳䂴䂵䂶䂷䂸䂹䂺䂻䂼䂽䂾䂿䃀䃁䃂䃃䃄䃅䃆䃇䃈䃉䃊䃋䃌䃍䃎䃏䃐䃑䃒䃓䃔䃕䃖䃗䃘䃙䃚䃛䃜䃝䃞䃟䃠䃡䃢䃣䃤䃥䃦䃧䃨䃩䃪䃫䃬䃭䃮䃯䃰䃱䃲䃳䃴䃵䃶䃷䃸䃹䃺䃻䃼䃽䃾䃿䄀䄁䄂䄃䄄䄅䄆䄇䄈䄉䄊䄋䄌䄍䄎䄏䄐䄑䄒䄓䄔䄕䄖䄗䄘䄙䄚䄛䄜䄝䄞䄟䄠䄡䄢䄣䄤䄥䄦䄧䄨䄩䄪䄫䄬䄭䄮䄯䄰䄱䄲䄳䄴䄵䄶䄷䄸䄹䄺䄻䄼䄽䄾䄿䅀䅁䅂䅃䅄䅅䅆䅇䅈䅉䅊䅋䅌䅍䅎䅏䅐䅑䅒䅓䅔䅕䅖䅗䅘䅙䅚䅛䅜䅝䅞䅟䅠䅡䅢䅣䅤䅥䅦䅧䅨䅩䅪䅫䅬䅭䅮䅯䅰䅱䅲䅳䅴䅵䅶䅷䅸䅹䅺䅻䅼䅽䅾䅿䆀䆁䆂䆃䆄䆅䆆䆇䆈䆉䆊䆋䆌䆍䆎䆏䆐䆑䆒䆓䆔䆕䆖䆗䆘䆙䆚䆛䆜䆝䆞䆟䆠䆡䆢䆣䆤䆥䆦䆧䆨䆩䆪䆫䆬䆭䆮䆯䆰䆱䆲䆳䆴䆵䆶䆷䆸䆹䆺䆻䆼䆽䆾䆿䇀䇁䇂䇃䇄䇅䇆䇇䇈䇉䇊䇋䇌䇍䇎䇏䇐䇑䇒䇓䇔䇕䇖䇗䇘䇙䇚䇛䇜䇝䇞䇟䇠䇡䇢䇣䇤䇥䇦䇧䇨䇩䇪䇫䇬䇭䇮䇯䇰䇱䇲䇳䇴䇵䇶䇷䇸䇹䇺䇻䇼䇽䇾䇿䈀䈁䈂䈃䈄䈅䈆䈇䈈䈉䈊䈋䈌䈍䈎䈏䈐䈑䈒䈓䈔䈕䈖䈗䈘䈙䈚䈛䈜䈝䈞䈟䈠䈡䈢䈣䈤䈥䈦䈧䈨䈩䈪䈫䈬䈭䈮䈯䈰䈱䈲䈳䈴䈵䈶䈷䈸䈹䈺䈻䈼䈽䈾䈿䉀䉁䉂䉃䉄䉅䉆䉇䉈䉉䉊䉋䉌䉍䉎䉏䉐䉑䉒䉓䉔䉕䉖䉗䉘䉙䉚䉛䉜䉝䉞䉟䉠䉡䉢䉣䉤䉥䉦䉧䉨䉩䉪䉫䉬䉭䉮䉯䉰䉱䉲䉳䉴䉵䉶䉷䉸䉹䉺䉻䉼䉽䉾䉿䊀䊁䊂䊃䊄䊅䊆䊇䊈䊉䊊䊋䊌䊍䊎䊏䊐䊑䊒䊓䊔䊕䊖䊗䊘䊙䊚䊛䊜䊝䊞䊟䊠䊡䊢䊣䊤䊥䊦䊧䊨䊩䊪䊫䊬䊭䊮䊯䊰䊱䊲䊳䊴䊵䊶䊷䊸䊹䊺䊻䊼䊽䊾䊿䋀䋁䋂䋃䋄䋅䋆䋇䋈䋉䋊䋋䋌䋍䋎䋏䋐䋑䋒䋓䋔䋕䋖䋗䋘䋙䋚䋛䋜䋝䋞䋟䋠䋡䋢䋣䋤䋥䋦䋧䋨䋩䋪䋫䋬䋭䋮䋯䋰䋱䋲䋳䋴䋵䋶䋷䋸䋹䋺䋻䋼䋽䋾䋿䌀䌁䌂䌃䌄䌅䌆䌇䌈䌉䌊䌋䌌䌍䌎䌏䌐䌑䌒䌓䌔䌕䌖䌗䌘䌙䌚䌛䌜䌝䌞䌟䌠䌡䌢䌣䌤䌥䌦䌧䌨䌩䌪䌫䌬䌭䌮䌯䌰䌱䌲䌳䌴䌵䌶䌷䌸䌹䌺䌻䌼䌽䌾䌿䍀䍁䍂䍃䍄䍅䍆䍇䍈䍉䍊䍋䍌䍍䍎䍏䍐䍑䍒䍓䍔䍕䍖䍗䍘䍙䍚䍛䍜䍝䍞䍟䍠䍡䍢䍣䍤䍥䍦䍧䍨䍩䍪䍫䍬䍭䍮䍯䍰䍱䍲䍳䍴䍵䍶䍷䍸䍹䍺䍻䍼䍽䍾䍿䎀䎁䎂䎃䎄䎅䎆䎇䎈䎉䎊䎋䎌䎍䎎䎏䎐䎑䎒䎓䎔䎕䎖䎗䎘䎙䎚䎛䎜䎝䎞䎟䎠䎡䎢䎣䎤䎥䎦䎧䎨䎩䎪䎫䎬䎭䎮䎯䎰䎱䎲䎳䎴䎵䎶䎷䎸䎹䎺䎻䎼䎽䎾䎿䏀䏁䏂䏃䏄䏅䏆䏇䏈䏉䏊䏋䏌䏍䏎䏏䏐䏑䏒䏓䏔䏕䏖䏗䏘䏙䏚䏛䏜䏝䏞䏟䏠䏡䏢䏣䏤䏥䏦䏧䏨䏩䏪䏫䏬䏭䏮䏯䏰䏱䏲䏳䏴䏵䏶䏷䏸䏹䏺䏻䏼䏽䏾䏿䐀䐁䐂䐃䐄䐅䐆䐇䐈䐉䐊䐋䐌䐍䐎䐏䐐䐑䐒䐓䐔䐕䐖䐗䐘䐙䐚䐛䐜䐝䐞䐟䐠䐡䐢䐣䐤䐥䐦䐧䐨䐩䐪䐫䐬䐭䐮䐯䐰䐱䐲䐳䐴䐵䐶䐷䐸䐹䐺䐻䐼䐽䐾䐿䑀䑁䑂䑃䑄䑅䑆䑇䑈䑉䑊䑋䑌䑍䑎䑏䑐䑑䑒䑓䑔䑕䑖䑗䑘䑙䑚䑛䑜䑝䑞䑟䑠䑡䑢䑣䑤䑥䑦䑧䑨䑩䑪䑫䑬䑭䑮䑯䑰䑱䑲䑳䑴䑵䑶䑷䑸䑹䑺䑻䑼䑽䑾䑿䒀䒁䒂䒃䒄䒅䒆䒇䒈䒉䒊䒋䒌䒍䒎䒏䒐䒑䒒䒓䒔䒕䒖䒗䒘䒙䒚䒛䒜䒝䒞䒟䒠䒡䒢䒣䒤䒥䒦䒧䒨䒩䒪䒫䒬䒭䒮䒯䒰䒱䒲䒳䒴䒵䒶䒷䒸䒹䒺䒻䒼䒽䒾䒿䓀䓁䓂䓃䓄䓅䓆䓇䓈䓉䓊䓋䓌䓍䓎䓏䓐䓑䓒䓓䓔䓕䓖䓗䓘䓙䓚䓛䓜䓝䓞䓟䓠䓡䓢䓣䓤䓥䓦䓧䓨䓩䓪䓫䓬䓭䓮䓯䓰䓱䓲䓳䓴䓵䓶䓷䓸䓹䓺䓻䓼䓽䓾䓿䔀䔁䔂䔃䔄䔅䔆䔇䔈䔉䔊䔋䔌䔍䔎䔏䔐䔑䔒䔓䔔䔕䔖䔗䔘䔙䔚䔛䔜䔝䔞䔟䔠䔡䔢䔣䔤䔥䔦䔧䔨䔩䔪䔫䔬䔭䔮䔯䔰䔱䔲䔳䔴䔵䔶䔷䔸䔹䔺䔻䔼䔽䔾䔿䕀䕁䕂䕃䕄䕅䕆䕇䕈䕉䕊䕋䕌䕍䕎䕏䕐䕑䕒䕓䕔䕕䕖䕗䕘䕙䕚䕛䕜䕝䕞䕟䕠䕡䕢䕣䕤䕥䕦䕧䕨䕩䕪䕫䕬䕭䕮䕯䕰䕱䕲䕳䕴䕵䕶䕷䕸䕹䕺䕻䕼䕽䕾䕿䖀䖁䖂䖃䖄䖅䖆䖇䖈䖉䖊䖋䖌䖍䖎䖏䖐䖑䖒䖓䖔䖕䖖䖗䖘䖙䖚䖛䖜䖝䖞䖟䖠䖡䖢䖣䖤䖥䖦䖧䖨䖩䖪䖫䖬䖭䖮䖯䖰䖱䖲䖳䖴䖵䖶䖷䖸䖹䖺䖻䖼䖽䖾䖿䗀䗁䗂䗃䗄䗅䗆䗇䗈䗉䗊䗋䗌䗍䗎䗏䗐䗑䗒䗓䗔䗕䗖䗗䗘䗙䗚䗛䗜䗝䗞䗟䗠䗡䗢䗣䗤䗥䗦䗧䗨䗩䗪䗫䗬䗭䗮䗯䗰䗱䗲䗳䗴䗵䗶䗷䗸䗹䗺䗻䗼䗽䗾䗿䘀䘁䘂䘃䘄䘅䘆䘇䘈䘉䘊䘋䘌䘍䘎䘏䘐䘑䘒䘓䘔䘕䘖䘗䘘䘙䘚䘛䘜䘝䘞䘟䘠䘡䘢䘣䘤䘥䘦䘧䘨䘩䘪䘫䘬䘭䘮䘯䘰䘱䘲䘳䘴䘵䘶䘷䘸䘹䘺䘻䘼䘽䘾䘿䙀䙁䙂䙃䙄䙅䙆䙇䙈䙉䙊䙋䙌䙍䙎䙏䙐䙑䙒䙓䙔䙕䙖䙗䙘䙙䙚䙛䙜䙝䙞䙟䙠䙡䙢䙣䙤䙥䙦䙧䙨䙩䙪䙫䙬䙭䙮䙯䙰䙱䙲䙳䙴䙵䙶䙷䙸䙹䙺䙻䙼䙽䙾䙿䚀䚁䚂䚃䚄䚅䚆䚇䚈䚉䚊䚋䚌䚍䚎䚏䚐䚑䚒䚓䚔䚕䚖䚗䚘䚙䚚䚛䚜䚝䚞䚟䚠䚡䚢䚣䚤䚥䚦䚧䚨䚩䚪䚫䚬䚭䚮䚯䚰䚱䚲䚳䚴䚵䚶䚷䚸䚹䚺䚻䚼䚽䚾䚿䛀䛁䛂䛃䛄䛅䛆䛇䛈䛉䛊䛋䛌䛍䛎䛏䛐䛑䛒䛓䛔䛕䛖䛗䛘䛙䛚䛛䛜䛝䛞䛟䛠䛡䛢䛣䛤䛥䛦䛧䛨䛩䛪䛫䛬䛭䛮䛯䛰䛱䛲䛳䛴䛵䛶䛷䛸䛹䛺䛻䛼䛽䛾䛿䜀䜁䜂䜃䜄䜅䜆䜇䜈䜉䜊䜋䜌䜍䜎䜏䜐䜑䜒䜓䜔䜕䜖䜗䜘䜙䜚䜛䜜䜝䜞䜟䜠䜡䜢䜣䜤䜥䜦䜧䜨䜩䜪䜫䜬䜭䜮䜯䜰䜱䜲䜳䜴䜵䜶䜷䜸䜹䜺䜻䜼䜽䜾䜿䝀䝁䝂䝃䝄䝅䝆䝇䝈䝉䝊䝋䝌䝍䝎䝏䝐䝑䝒䝓䝔䝕䝖䝗䝘䝙䝚䝛䝜䝝䝞䝟䝠䝡䝢䝣䝤䝥䝦䝧䝨䝩䝪䝫䝬䝭䝮䝯䝰䝱䝲䝳䝴䝵䝶䝷䝸䝹䝺䝻䝼䝽䝾䝿䞀䞁䞂䞃䞄䞅䞆䞇䞈䞉䞊䞋䞌䞍䞎䞏䞐䞑䞒䞓䞔䞕䞖䞗䞘䞙䞚䞛䞜䞝䞞䞟䞠䞡䞢䞣䞤䞥䞦䞧䞨䞩䞪䞫䞬䞭䞮䞯䞰䞱䞲䞳䞴䞵䞶䞷䞸䞹䞺䞻䞼䞽䞾䞿䟀䟁䟂䟃䟄䟅䟆䟇䟈䟉䟊䟋䟌䟍䟎䟏䟐䟑䟒䟓䟔䟕䟖䟗䟘䟙䟚䟛䟜䟝䟞䟟䟠䟡䟢䟣䟤䟥䟦䟧䟨䟩䟪䟫䟬䟭䟮䟯䟰䟱䟲䟳䟴䟵䟶䟷䟸䟹䟺䟻䟼䟽䟾䟿䠀䠁䠂䠃䠄䠅䠆䠇䠈䠉䠊䠋䠌䠍䠎䠏䠐䠑䠒䠓䠔䠕䠖䠗䠘䠙䠚䠛䠜䠝䠞䠟䠠䠡䠢䠣䠤䠥䠦䠧䠨䠩䠪䠫䠬䠭䠮䠯䠰䠱䠲䠳䠴䠵䠶䠷䠸䠹䠺䠻䠼䠽䠾䠿䡀䡁䡂䡃䡄䡅䡆䡇䡈䡉䡊䡋䡌䡍䡎䡏䡐䡑䡒䡓䡔䡕䡖䡗䡘䡙䡚䡛䡜䡝䡞䡟䡠䡡䡢䡣䡤䡥䡦䡧䡨䡩䡪䡫䡬䡭䡮䡯䡰䡱䡲䡳䡴䡵䡶䡷䡸䡹䡺䡻䡼䡽䡾䡿䢀䢁䢂䢃䢄䢅䢆䢇䢈䢉䢊䢋䢌䢍䢎䢏䢐䢑䢒䢓䢔䢕䢖䢗䢘䢙䢚䢛䢜䢝䢞䢟䢠䢡䢢䢣䢤䢥䢦䢧䢨䢩䢪䢫䢬䢭䢮䢯䢰䢱䢲䢳䢴䢵䢶䢷䢸䢹䢺䢻䢼䢽䢾䢿䣀䣁䣂䣃䣄䣅䣆䣇䣈䣉䣊䣋䣌䣍䣎䣏䣐䣑䣒䣓䣔䣕䣖䣗䣘䣙䣚䣛䣜䣝䣞䣟䣠䣡䣢䣣䣤䣥䣦䣧䣨䣩䣪䣫䣬䣭䣮䣯䣰䣱䣲䣳䣴䣵䣶䣷䣸䣹䣺䣻䣼䣽䣾䣿䤀䤁䤂䤃䤄䤅䤆䤇䤈䤉䤊䤋䤌䤍䤎䤏䤐䤑䤒䤓䤔䤕䤖䤗䤘䤙䤚䤛䤜䤝䤞䤟䤠䤡䤢䤣䤤䤥䤦䤧䤨䤩䤪䤫䤬䤭䤮䤯䤰䤱䤲䤳䤴䤵䤶䤷䤸䤹䤺䤻䤼䤽䤾䤿䥀䥁䥂䥃䥄䥅䥆䥇䥈䥉䥊䥋䥌䥍䥎䥏䥐䥑䥒䥓䥔䥕䥖䥗䥘䥙䥚䥛䥜䥝䥞䥟䥠䥡䥢䥣䥤䥥䥦䥧䥨䥩䥪䥫䥬䥭䥮䥯䥰䥱䥲䥳䥴䥵䥶䥷䥸䥹䥺䥻䥼䥽䥾䥿䦀䦁䦂䦃䦄䦅䦆䦇䦈䦉䦊䦋䦌䦍䦎䦏䦐䦑䦒䦓䦔䦕䦖䦗䦘䦙䦚䦛䦜䦝䦞䦟䦠䦡䦢䦣䦤䦥䦦䦧䦨䦩䦪䦫䦬䦭䦮䦯䦰䦱䦲䦳䦴䦵䦶䦷䦸䦹䦺䦻䦼䦽䦾䦿䧀䧁䧂䧃䧄䧅䧆䧇䧈䧉䧊䧋䧌䧍䧎䧏䧐䧑䧒䧓䧔䧕䧖䧗䧘䧙䧚䧛䧜䧝䧞䧟䧠䧡䧢䧣䧤䧥䧦䧧䧨䧩䧪䧫䧬䧭䧮䧯䧰䧱䧲䧳䧴䧵䧶䧷䧸䧹䧺䧻䧼䧽䧾䧿䨀䨁䨂䨃䨄䨅䨆䨇䨈䨉䨊䨋䨌䨍䨎䨏䨐䨑䨒䨓䨔䨕䨖䨗䨘䨙䨚䨛䨜䨝䨞䨟䨠䨡䨢䨣䨤䨥䨦䨧䨨䨩䨪䨫䨬䨭䨮䨯䨰䨱䨲䨳䨴䨵䨶䨷䨸䨹䨺䨻䨼䨽䨾䨿䩀䩁䩂䩃䩄䩅䩆䩇䩈䩉䩊䩋䩌䩍䩎䩏䩐䩑䩒䩓䩔䩕䩖䩗䩘䩙䩚䩛䩜䩝䩞䩟䩠䩡䩢䩣䩤䩥䩦䩧䩨䩩䩪䩫䩬䩭䩮䩯䩰䩱䩲䩳䩴䩵䩶䩷䩸䩹䩺䩻䩼䩽䩾䩿䪀䪁䪂䪃䪄䪅䪆䪇䪈䪉䪊䪋䪌䪍䪎䪏䪐䪑䪒䪓䪔䪕䪖䪗䪘䪙䪚䪛䪜䪝䪞䪟䪠䪡䪢䪣䪤䪥䪦䪧䪨䪩䪪䪫䪬䪭䪮䪯䪰䪱䪲䪳䪴䪵䪶䪷䪸䪹䪺䪻䪼䪽䪾䪿䫀䫁䫂䫃䫄䫅䫆䫇䫈䫉䫊䫋䫌䫍䫎䫏䫐䫑䫒䫓䫔䫕䫖䫗䫘䫙䫚䫛䫜䫝䫞䫟䫠䫡䫢䫣䫤䫥䫦䫧䫨䫩䫪䫫䫬䫭䫮䫯䫰䫱䫲䫳䫴䫵䫶䫷䫸䫹䫺䫻䫼䫽䫾䫿䬀䬁䬂䬃䬄䬅䬆䬇䬈䬉䬊䬋䬌䬍䬎䬏䬐䬑䬒䬓䬔䬕䬖䬗䬘䬙䬚䬛䬜䬝䬞䬟䬠䬡䬢䬣䬤䬥䬦䬧䬨䬩䬪䬫䬬䬭䬮䬯䬰䬱䬲䬳䬴䬵䬶䬷䬸䬹䬺䬻䬼䬽䬾䬿䭀䭁䭂䭃䭄䭅䭆䭇䭈䭉䭊䭋䭌䭍䭎䭏䭐䭑䭒䭓䭔䭕䭖䭗䭘䭙䭚䭛䭜䭝䭞䭟䭠䭡䭢䭣䭤䭥䭦䭧䭨䭩䭪䭫䭬䭭䭮䭯䭰䭱䭲䭳䭴䭵䭶䭷䭸䭹䭺䭻䭼䭽䭾䭿䮀䮁䮂䮃䮄䮅䮆䮇䮈䮉䮊䮋䮌䮍䮎䮏䮐䮑䮒䮓䮔䮕䮖䮗䮘䮙䮚䮛䮜䮝䮞䮟䮠䮡䮢䮣䮤䮥䮦䮧䮨䮩䮪䮫䮬䮭䮮䮯䮰䮱䮲䮳䮴䮵䮶䮷䮸䮹䮺䮻䮼䮽䮾䮿䯀䯁䯂䯃䯄䯅䯆䯇䯈䯉䯊䯋䯌䯍䯎䯏䯐䯑䯒䯓䯔䯕䯖䯗䯘䯙䯚䯛䯜䯝䯞䯟䯠䯡䯢䯣䯤䯥䯦䯧䯨䯩䯪䯫䯬䯭䯮䯯䯰䯱䯲䯳䯴䯵䯶䯷䯸䯹䯺䯻䯼䯽䯾䯿䰀䰁䰂䰃䰄䰅䰆䰇䰈䰉䰊䰋䰌䰍䰎䰏䰐䰑䰒䰓䰔䰕䰖䰗䰘䰙䰚䰛䰜䰝䰞䰟䰠䰡䰢䰣䰤䰥䰦䰧䰨䰩䰪䰫䰬䰭䰮䰯䰰䰱䰲䰳䰴䰵䰶䰷䰸䰹䰺䰻䰼䰽䰾䰿䱀䱁䱂䱃䱄䱅䱆䱇䱈䱉䱊䱋䱌䱍䱎䱏䱐䱑䱒䱓䱔䱕䱖䱗䱘䱙䱚䱛䱜䱝䱞䱟䱠䱡䱢䱣䱤䱥䱦䱧䱨䱩䱪䱫䱬䱭䱮䱯䱰䱱䱲䱳䱴䱵䱶䱷䱸䱹䱺䱻䱼䱽䱾䱿䲀䲁䲂䲃䲄䲅䲆䲇䲈䲉䲊䲋䲌䲍䲎䲏䲐䲑䲒䲓䲔䲕䲖䲗䲘䲙䲚䲛䲜䲝䲞䲟䲠䲡䲢䲣䲤䲥䲦䲧䲨䲩䲪䲫䲬䲭䲮䲯䲰䲱䲲䲳䲴䲵䲶䲷䲸䲹䲺䲻䲼䲽䲾䲿䳀䳁䳂䳃䳄䳅䳆䳇䳈䳉䳊䳋䳌䳍䳎䳏䳐䳑䳒䳓䳔䳕䳖䳗䳘䳙䳚䳛䳜䳝䳞䳟䳠䳡䳢䳣䳤䳥䳦䳧䳨䳩䳪䳫䳬䳭䳮䳯䳰䳱䳲䳳䳴䳵䳶䳷䳸䳹䳺䳻䳼䳽䳾䳿䴀䴁䴂䴃䴄䴅䴆䴇䴈䴉䴊䴋䴌䴍䴎䴏䴐䴑䴒䴓䴔䴕䴖䴗䴘䴙䴚䴛䴜䴝䴞䴟䴠䴡䴢䴣䴤䴥䴦䴧䴨䴩䴪䴫䴬䴭䴮䴯䴰䴱䴲䴳䴴䴵䴶䴷䴸䴹䴺䴻䴼䴽䴾䴿䵀䵁䵂䵃䵄䵅䵆䵇䵈䵉䵊䵋䵌䵍䵎䵏䵐䵑䵒䵓䵔䵕䵖䵗䵘䵙䵚䵛䵜䵝䵞䵟䵠䵡䵢䵣䵤䵥䵦䵧䵨䵩䵪䵫䵬䵭䵮䵯䵰䵱䵲䵳䵴䵵䵶䵷䵸䵹䵺䵻䵼䵽䵾䵿䶀䶁䶂䶃䶄䶅䶆䶇䶈䶉䶊䶋䶌䶍䶎䶏䶐䶑䶒䶓䶔䶕䶖䶗䶘䶙䶚䶛䶜䶝䶞䶟䶠䶡䶢䶣䶤䶥䶦䶧䶨䶩䶪䶫䶬䶭䶮䶯䶰䶱䶲䶳䶴䶵䶶䶷䶸䶹䶺䶻䶼䶽䶾䶿䷀䷁䷂䷃䷄䷅䷆䷇䷈䷉䷊䷋䷌䷍䷎䷏䷐䷑䷒䷓䷔䷕䷖䷗䷘䷙䷚䷛䷜䷝䷞䷟䷠䷡䷢䷣䷤䷥䷦䷧䷨䷩䷪䷫䷬䷭䷮䷯䷰䷱䷲䷳䷴䷵䷶䷷䷸䷹䷺䷻䷼䷽䷾䷿乥乲兙兛兝兞兡兣兺匁厼叾哛唜唟喸嗧囕夞巼怾旕朩朰栍桛椧烪猠瓧瓩瓰瓱瓲瓼甅硛硳穒縇莻虄襨迲闏鞥啊腌錒锕阿哀哎唉埃挨溾銰鎄锿凒啀嘊捱敱敳溰癌皑皚磑娾昹毐濭矮蔼藹譪躷霭靄伌僾叆嗳噯塧壒嫒嬡愛懓懝暧曖爱瑷璦皧瞹砹硋碍礙艾薆譺賹鑀隘靉餲馤鱫鴱侒偣啽媕安峖庵桉氨痷盦盫腤菴萻葊蓭誝諳谙鞌鞍韽馣鮟鵪鶕鹌儑玵雸俺唵垵埯揞罯銨铵堓屵岸按晻暗案洝胺荌豻貋錌闇隌黯肮骯岇昂昻枊盎醠凹柪梎熬爊軪厫嗷嗸嶅廒慠摮敖滶獒獓璈磝翱翶翺聱蔜螯謷謸遨鏖隞骜鰲鳌鷔鼇媪媼抝艹芺袄襖镺傲坳垇墺奡奥奧嫯岙岰嶴懊拗擙澚澳鏊隩驁丷仈八叭吧哵夿岜巴扒扷捌朳柭玐疤笆粑羓芭蚆豝釟魞鲃叐妭抜拔炦癹胈茇菝詙跋軷颰魃鼥把鈀钯靶坝垻壩弝欛灞爸矲罢罷耙覇跁霸鮁鲅挀掰白佰捭摆擺柏栢瓸百竡粨絔襬庍拜拝敗猈稗粺薭贁败韛扳搬攽斑斒班瘢癍肦般螌褩辬頒颁鳻坂岅昄板版瓪粄舨蝂鈑钣闆阪魬伴办半坢姅怑扮拌湴瓣秚絆绊辦鉡靽垹帮幇幚幫捠梆浜縍邦邫鞤榜牓綁绑膀髈傍塝挷搒棒棓玤磅稖艕蒡蚌蜯謗谤鎊镑佨剝勹包孢枹煲笣胞苞蕔裦褒襃闁齙龅窇薄雹保堡堢媬宝宲寚寳寶怉珤緥葆藵褓賲靌飹飽饱駂鳵鴇鸨儤勽嚗報忁报抱暴曓爆犦菢虣蚫袌豹趵鉋鑤铇骲髱鮑鲍卑庳悲揹杯柸桮椑盃碑背藣陂鵯鹎北鉳俻倍偝偹備僃备孛悖惫愂憊昁梖焙牬犕狈狽珼琲碚禙糒苝蓓蛽被褙誖貝贝軰輩辈邶郥鄁鋇鐾钡鞁鞴骳呗唄喯奔栟泍漰犇錛锛奙本楍畚翉苯倴坋坌捹撪桳渀笨逩伻嗙嘣奟崩嵭痭祊絣綳繃绷閍甭甮埄埲琣琫菶鞛塴揼泵甏蹦迸逬鏰镚偪屄楅榌毴螕豍逼鎞鰏鲾鵖嬶荸鼻佊俾匕啚夶妣彼朼柀比毞沘疕秕笔筆粃聛舭貏鄙佖咇哔嗶坒堛壁奰妼婢嬖币幣幤庇廦弊弻弼彃必怭怶愊愎敝斃朇柲梐毕毖毙湢滗滭潷濞煏熚狴獘獙珌璧畀畁畢疪痹痺皕睤睥碧禆筚箅箆篦篳粊綼縪繴罼腷臂芘苾荜萆萞蓖蓽蔽薜蜌袐襅襞襣觱詖诐貱賁贔贲赑跸蹕躃躄避邲鄨鄪鉍鏎鐴铋閇閉閟闭陛鞸韠飶饆馝駜驆髀髲魓鮅鷝鷩鼊炞煸牑猵獱甂砭笾箯籩糄編编萹蝙边邉邊鍽鞕鞭鯾鯿鳊匾惼扁揙碥稨窆藊褊貶贬鴘便卞变変峅弁徧忭抃昪汳汴玣緶缏艑苄覍諚變辡辧辨辩辫辮辯遍釆閞儦墂幖彪标標檦淲滮瀌熛爂猋瘭磦穮脿膘臕蔈藨謤贆鏢鑣镖镳颩颮颷飆飇飈飊飑飙飚驫骉骠髟嫑婊表裱褾諘錶俵摽鳔憋瘪癟虌蟞鱉鳖鼈龞別别徶莂蛂襒蹩彆傧儐宾彬斌梹椕槟檳汃滨濒濱濵瀕玢瑸璸繽缤虨豩豳賓賔邠鑌镔霦頻顮摈擯殡殯膑臏髌髕髩鬂鬓鬢仌仒兵冫冰掤氷蛃鋲丙偋寎怲抦昞昺柄棅炳眪禀秉稟苪邴鈵鉼陃鞆鞞餅餠饼並併倂傡垪并幷庰摒栤病窉竝誁靐鮩僠剥嶓拨撥播波溊玻癶癷盋砵碆礡紴缽菠袰蹳鉢钵餑饽驋鱍亳仢伯侼僰勃博帛愽懪挬搏桲欂泊浡淿渤煿牔狛猼瓝瓟礴秡箔簙糪肑胉脖膊舶艊萡葧袯袹襏襮謈踣郣鈸鉑鋍鎛鑮钹铂镈餺馎馛馞駁駮驳髆髉鮊鲌鵓鹁跛孹擘檗簸蘗譒啵蔔峬庯晡誧逋鈽錻钸餔鵏轐醭鳪卜卟哺捕补補鸔不佈勏吥咘埗埠布廍怖悑抪捗柨步歨歩瓿篰簿荹蔀踄部郶鈈钚餢嚓擦攃礤礸遪偲猜才材纔裁財财倸啋埰婇寀彩採棌毝睬綵跴踩采縩菜蔡傪参參叄叅喰嬠湌爘飡餐驂骖惭慙慚残殘蚕蝅蠶蠺惨慘憯朁穇黪黲儏澯灿燦璨粲薒謲仓仺伧倉傖凔嵢沧滄濸獊舱艙苍蒼螥鶬鸧欌藏鑶賶撡操糙嘈嶆慒曹曺槽漕艚蓸螬褿鏪愺懆艸草騲肏襙鄵鼜侧側冊册厕厠夨廁恻惻憡拺敇测測畟笧策筞筴箣簎粣荝萗萴蓛嵾篸埁岑涔笒噌层層嶒曽曾竲驓蹭偛叉嗏扠挿插揷杈疀臿艖銟鍤锸餷馇垞察嵖搽查査槎檫猹碴秅茬茶詧靫蹅鑔镲侘刹剎奼姹岔差汊紁衩詫诧拆肞芆釵钗侪儕喍柴犲祡豺茝囆瘥虿蠆袃訍幨掺搀摻攙梴裧襜覘觇辿鋓儃儳劖嚵壥婵嬋孱巉廛棎欃毚湹潹潺澶瀍瀺煘獑磛禅緾纏纒缠艬苂蝉螹蟐蟬蟾誗讒谗躔鄽酁鋋鑱镵饞馋丳产冁刬剗剷囅嵼幝摌斺旵浐滻灛燀產産簅繟蒇蕆諂譂讇谄醦鏟铲閳闡阐骣忏懴懺摲硟羼韂顫颤伥倀娼昌椙淐猖琩菖裮錩锠閶阊鯧鲳鼚仧仩偿償兏嘗嚐塲嫦尝常徜瑺瓺甞肠腸膓苌萇裳長镸长鱨鲿僘厂厰场場廠惝敞昶氅鋹倡唱怅悵暢焻玚瑒畅畼誯韔鬯弨怊抄欩窼訬超鈔钞嘲巢巣晁朝樔漅潮牊窲罺謿轈鄛鼂鼌吵巐炒焣煼眧麨仦仯耖觘伡俥唓砗硨莗蛼車车偖扯撦勶坼屮彻徹掣撤澈烢爡瞮硩聅迠頙嗔抻捵棽琛瞋諃謓賝郴塵宸尘忱愖敐敶晨曟栕桭梣樄沉煁瘎臣茞莀莐蔯薼螴訦諶谌軙辰迧鈂陈陳霃鷐麎墋夦硶碜磣贂趻踸鍖儭嚫榇櫬疢衬襯讖谶趁趂齓齔龀偁僜憆摚撐撑晿柽棦橕檉泟浾爯牚琤瞠碀称稱穪竀緽罉蛏蟶赪赬鏿鐣阷靗頳饓丞乗乘呈城埕堘塍塖娍宬峸惩憕懲成承挰掁揨朾枨棖椉橙檙洆溗澂澄瀓珵珹畻程窚筬絾脭荿裎誠诚郕酲鋮铖騬鯎侱庱徎悜睈逞騁骋秤吃哧喫嗤噄妛媸彨彲摛攡殦瓻痴癡眵瞝笞粚絺胵蚩螭訵誺魑鴟鵄鸱黐齝匙墀弛持池漦竾筂箎篪茌荎蚳謘貾赿踟迟迡遅遟遲鍉馳驰伬侈卶叺呎垑尺恥欼歯耻肔胣蚇袲袳裭褫豉鉹齒齿侙傺勅勑叱啻彳恜慗憏懘抶敕斥杘湁灻炽烾熾痸瘛翄翅翤翨腟赤趩遫鉓銐雴飭饬鶒鷘麶充冲嘃忡憃憧摏沖浺珫罿翀舂艟茺衝蹖崇崈漴爞緟虫蝩蟲褈隀埫宠寵揰銃铳抽搊犨犫瘳篘紬仇俦儔嬦帱幬惆愁懤栦梼椆檮燽畴疇皗稠筹籌絒綢绸菗薵裯詶讎讐踌躊酧酬醻雔雠雦丑丒偢吜杽瞅矁醜魗殠臭臰遚鮘出初岀摴榋樗貙齣刍厨媰幮廚橱櫉櫥滁犓篨耡芻蒢蒭蜍蟵豠趎蹰躇躕鉏鋤锄除雏雛鶵储儲杵椘楚楮檚濋璴础礎禇處齭齼亍俶傗儊処埱处怵憷搐敊斶欪歜泏滀珿畜矗竌竐絀绌臅触觸諔豖鄐閦黜搋膗揣膪踹巛川氚瑏穿传傳剶圌暷椽篅舡舩船輲遄僢喘堾歂舛荈踳串汌猭玔賗釧钏鶨刅摐牎牕疮瘡窓窗窻噇幢床牀傸磢闖闯创刱剏剙創怆愴吹炊龡倕垂埀捶搥桘棰槌箠腄菙錘鎚锤陲顀媋旾春暙杶椿槆橁櫄瑃箺萅蝽輴鰆鶞唇浱淳湻滣漘犉純纯脣莼蒓蓴醇醕錞陙鯙鶉鹑偆惷睶萶蠢賰戳繛趠踔逴哾啜嚽娕娖婥惙擉歠涰磭綽绰踀輟辍辵辶酫鑡餟齪龊偨玼疵縒蠀趀跐骴髊齹垐嬨慈柌濨珁瓷甆磁礠祠糍茨薋詞词辝辞辤辭雌飺餈鴜鶿鷀鹚佌此泚皉鮆伺佽刺刾庛朿栨次絘茦莿蛓螆賜赐匆囪囱忩怱悤暰枞棇樅樬漗潨熜瑽璁瞛篵繱聡聦聪聰苁茐葱蓯蔥蟌鍯鏓鏦騘驄骢丛从叢婃孮従徔徖從悰樷欉淙漎潀潈灇爜琮藂誴賨賩錝愡憁謥凑楱湊腠輳辏怚橻粗觕麁麄麤徂殂促噈媨憱猝瘄瘯簇縬脨蔟誎趗踧踿蹙蹴蹵醋顣鼀撺攛汆蹿躥鑹镩巑櫕欑穳殩熶爨窜竄篡簒催凗墔崔嵟慛摧榱槯磪縗缞脺鏙漼璀皠趡伜倅啐啛忰悴毳淬濢焠琗疩瘁竁粋粹紣綷翆翠脃脆膬膵臎萃襊顇村澊皴竴膥邨侟壿存拵刌忖寸籿搓撮瑳磋蹉遳醝鎈嵯嵳痤睉矬蒫蔖虘酂酇鹺鹾脞剉剒厝夎庴挫措莝莡蓌逪銼錯锉错咑哒嗒噠墶搭撘笚耷褡鎉鎝剳匒呾垯妲怛溚炟燵畗畣瘩笪答羍荅荙薘蟽詚跶达迏迖迚逹達鐽靼鞑韃龖龘打亣大眔繨呆呔懛獃傣歹代侢叇垈埭岱帒带帯帶廗待怠戴曃柋殆瀻玳瑇甙簤紿緿绐艜蚮蝳袋襶貣貸贷跢蹛軑軚軩轪迨逮霴靆鴏黛黱丹儋勯匰单単單妉媅担擔殚殫甔眈砃箪簞耼耽聃聸褝襌躭郸鄲酖頕亶伔刐抌掸撢撣玬瓭疸紞胆膽衴賧赕馾黕黵但僤唌啖啗啿嘾噉嚪帎惮憚憺旦柦氮沊泹淡澹狚疍瘅癉癚禫窞繵腅萏蓞蛋蜑觛訑誕诞贉霮餤饏駳髧鴠黮儅噹当澢珰璫當筜簹艡蟷裆襠鐺铛闣党挡擋攩欓灙譡讜谠黨凼圵垱壋婸宕愓档檔氹潒璗瓽盪瞊砀碭礑簜荡菪蕩蘯趤逿雼刀刂叨忉朷氘舠螩釖魛鱽捯倒壔导導岛島嶋嶌嶹捣搗擣槝祷禂禱蹈陦隝隯到噵悼椡檤焘燾瓙盗盜稲稻纛翢翿艔菿衜衟軇辺道嘚得徳德恴悳惪棏淂鍀锝的扥扽噔嬁灯燈璒登竳簦艠豋蹬戥等凳墱嶝櫈瞪磴覴邓鄧鐙镫隥仾低啲埞堤奃岻彽樀氐滴磾秪羝袛趆隄鞮唙啇嘀嚁嫡廸敌敵梑涤滌狄笛籴糴翟苖荻蔋蔐藡覿觌豴蹢迪鏑镝靮頔馰髢鸐厎呧坘坻底弤抵拞掋柢牴砥聜菧觝詆诋軧邸阺骶鯳俤偙僀地坔埅埊墑墬娣媂嶳帝弟怟慸摕旳杕枤梊棣楴焍玓珶甋眱睇碲祶禘第締缔腣苐菂蒂蔕蝃蝭螮諦谛踶递逓遆遞遰釱鉪嗲傎厧嵮巅巓巔掂攧敁槇槙滇瘨癫癲蹎顚顛颠齻典嚸奌婰敟椣点碘蒧蕇跕踮點佃坫垫墊壂奠婝店惦扂橂殿淀澱玷琔电甸癜磹簟蜔鈿钿阽電靛驔凋刁刟叼奝弴彫汈琱瞗碉簓虭蛁貂錭雕鮉鯛鲷鳭鵰鼦屌扚伄吊弔掉瘹盄窎窵竨蓧藋訋調釣鈟銚銱鋽鑃钓铞铫雿魡爹褺跌叠咥喋垤堞峌嵽幉恎惵戜挕昳曡楪殜氎牃牒瓞畳疂疉疊眣眰碟絰绖耊耋胅臷艓苵蜨蝶螲褋詄諜谍趃跮蹀迭镻鰈鲽鴩哋丁仃叮帄玎疔盯耵虰酊釘钉靪奵嵿濎艼薡鐤頂顶鼎鼑啶定忊椗矴碇碠磸聢腚萣蝊訂订錠锭顁飣饤丟丢銩铥东倲冬咚埬娻岽崠崬徚昸東氡氭涷笗苳菄蝀鮗鯟鶇鶫鸫鼕嬞懂箽董蕫諌侗働冻凍动動垌姛恫戙挏栋棟洞湩硐胨胴腖迵霘駧兜兠吺唗枓橷篼蔸都唞乧抖蚪鈄钭阧陡吋斗斣梪毭浢痘窦竇脰荳豆逗郖酘閗闘餖饾鬥鬦鬪鬬鬭剢厾嘟督醏闍阇凟匵嬻椟櫝殰毒涜渎瀆牍牘犊犢独獨瓄皾裻読讀讟读豄贕錖鑟韇韣韥騳髑黩黷堵琽睹笃篤覩賭赌妒妬度杜殬渡秺肚芏荰螙蠧蠹鍍镀靯偳媏端耑褍鍴短塅断斷椴段毈煅瑖碫簖籪緞缎腶葮躖鍛锻垖堆塠痽磓鐓鐜镦鴭頧兊兌兑对対對怼憝憞懟濧瀩碓祋綐薱譈譵轛队陮隊吨噸墩墪惇撉撴敦犜獤礅蜳蹲蹾驐盹趸躉伅庉沌潡炖燉盾砘碷踲逇遁遯鈍钝頓顿剟咄哆嚉多夛掇敠敪毲畓裰凙剫喥夺奪敓敚痥踱鈬鐸铎亸哚嚲垛垜埵奲崜挆朵朶椯綞缍趓躱躲軃鬌刴剁堕墮墯尮惰憜挅柮桗舵跥跺陊陏飿饳鵽妸妿娿婀屙俄吪囮娥峉峨峩涐珴皒睋磀莪蛾訛誐譌讹迗鈋鋨锇頟額额魤鵝鵞鹅噁枙砨頋騀鵈偔僫匎卾厄呃呝咢咹噩垩堊堨堮姶岋崿廅恶悪惡愕戹扼搤搹擜櫮歞歺湂琧砈砐硆礘腭苊萼蕚蚅蝁覨諤讍谔豟軛軶轭遌遏遻鄂鈪鍔鑩锷閼阏阨阸頞顎颚餓餩饿鰐鰪鱷鳄鶚鹗齃齶誒诶欸奀恩煾蒽峎嗯摁侕儿児兒唲峏栭洏粫而耏聏胹荋袻輀轜陑隭髵鮞鲕鴯鸸尒尓尔栮毦洱爾珥耳薾衈趰迩邇鉺铒餌饵駬二佴刵咡弍弐樲誀貮貳贰髶冹发彂沷発發乏伐傠坺垡墢姂栰橃浌疺瞂笩筏罚罰罸茷藅閥阀佱峜法灋砝鍅珐琺蕟髪髮勫噃嬏帆幡忛憣旙旛畨番籓繙翻藩轓颿飜鱕凡凢凣匥墦杋柉棥樊瀿烦煩燔璠矾礬笲籵緐繁羳膰舤舧蕃薠蘩蠜襎蹯釩鐇鐢钒鷭仮反払橎返奿嬎梵氾汎泛滼瀪犯畈盕笵範范訉販贩軓軬輽飯飰饭匚坊堏方枋汸淓牥芳蚄趽邡鈁錺钫鴋妨房肪防魴鲂仿倣旊昉昘瓬眆紡纺舫訪访髣鶭放啡妃婓婔扉暃渄猆緋绯菲蜚裶霏非靟飛飝飞餥馡騑騛鯡鲱淝肥腓蜰匪奜悱斐朏棐榧篚翡胐蕜誹诽俷剕厞吠屝废廃廢昲曊杮櫠沸濷狒疿痱癈肺胇芾萉蟦費费鐨镄陫靅鼣分吩帉昐朆梤棻氛竕紛纷翂芬衯訜躮酚鈖雰餴饙馚坟墳妢岎幩朌枌棼橨汾濆炃焚燌燓獖羒羵蒶蕡蚠蚡豮豶轒鐼隫馩魵黂鼖鼢粉黺份偾僨奋奮弅忿愤憤瀵瞓秎粪糞膹鱝鲼丰仹偑僼凨凬凮堼妦寷封峯峰崶枫桻楓檒沣沨渢灃烽犎猦琒疯瘋盽砜碸篈葑蘴蜂蠭豐鄷酆鋒鎽鏠锋霻靊風飌风麷冯堸夆摓浲溄漨綘縫缝艂逢馮唪覂諷讽俸凤奉湗焨煈賵赗鳯鳳鴌覅仏佛坲梻紑否妚殕缶缹缻雬鴀伕呋夫妋姇娐孵尃怤懯敷旉柎玞砆稃筟粰糐紨綒肤胕膚荂荴衭趺跗邞鄜酜鈇鳺麩麬麱麸乀伏俘凫刜匐咈哹垘孚岪巿帗幅幞弗怫扶拂服枎柫栿桴棴榑氟泭洑浮涪澓炥烰玸琈甶畉畐癁砩祓福稪符笰箙紱紼絥綍绂绋罘罦翇艀艴芙芣苻茀茯莩菔葍虙蚨蜉蝠袚袱襆襥諨豧踾輻辐郛鉘鉜韍韨颫髴鮄鮲鳧鳬鴔鵩鶝黻乶俌俛俯呒嘸府弣抚拊捬撫斧椨滏焤甫盙簠脯腐腑蜅輔辅郙釜釡阝頫鬴黼付偩傅冨副咐坿复妇婏婦媍嬔富峊彿復椱父祔禣秿竎緮縛缚腹萯蕧蚥蚹蛗蝜蝮袝複褔覄覆訃詂讣負賦賻负赋赙赴輹鍑鍢阜附馥駙驸鮒鰒鲋鳆嘎嘠旮噶尜釓錷钆尕玍尬魀侅垓姟峐晐畡祴絯荄該该豥賅賌赅郂陔忋改絠丐乢匃匄戤摡概槩槪溉漑瓂盖葢蓋鈣钙凲坩尲尴尶尷干忓攼杆柑泔漧玕甘疳矸竿筸粓肝苷迀酐魐鳱仠感擀敢桿橄澉澸皯秆稈簳芉衦赶趕鱤鳡倝凎幹旰榦檊汵淦灨盰紺绀詌贑贛赣骭冈冮刚剛堈堽岡掆摃棡牨犅疘矼綱纲缸罁罡肛釭鋼鎠钢岗崗港戅戆戇杠槓焵焹筻槔槹橰櫜皋皐睾篙糕羔膏臯韟餻高髙鷎鷱鼛夰搞杲槀槁檺稁稾稿縞缟菒藁藳鎬镐勂吿告峼祮祰禞筶誥诰郜鋯锆割哥圪彁戈戓戨搁擱歌滒牫犵疙肐胳袼謌鎶饹鴚鴿鸽佫佮匌呄嗝塥愅挌搿敋格槅櫊滆獦膈臵葛蛒蛤裓觡諽輵轕鎘镉閣阁隔革鞈鞷韐韚騔骼鬲鮯哿嗰笴舸个亇個各箇茖虼鉻铬給给根跟哏亘亙揯搄艮茛刯庚椩浭焿畊絚緪縆羮羹耕菮賡赓鶊鹒哽埂峺挭梗綆绠耿莄郠骾鯁鲠堩更侊公功匑匔厷塨宫宮工幊弓恭愩慐攻杛碽篢糼糿肱蚣觥觵躬躳髸龏龔龚巩廾拱拲栱汞珙輁鞏供共唝嗊熕貢贡佝勾沟溝痀篝簼緱缑芶袧褠鈎鉤钩鞲韝岣枸狗玽笱耇耈耉苟蚼豿冓啂坸垢够夠姤媾彀搆撀构構煹覯觏訽詬诟購购遘雊估咕唂唃姑嫴孤巬巭杚柧橭沽泒稒笟箍箛篐罛苽菇菰蓇蛄觚軱軲轱辜酤鈲鮕鴣鸪傦古啒嘏夃尳愲扢榖毂汩淈濲瀔牯皷皼盬瞽穀糓縎罟羖股脵臌薣蛊蠱詁诂谷轂逧鈷钴餶馉骨鶻鹘鼓鼔僱凅固堌崓崮故梏棝榾牿痼祻錮锢雇顧顾鯝鲴刮劀呱栝桰歄煱瓜緺胍趏踻颪颳騧鴰鸹冎剐剮叧寡卦啩坬挂掛絓罣褂詿诖乖叏拐枴柺箉罫夬怪恠倌关官棺涫瘝癏窤蒄覌観觀观関闗關鰥鱞鳏琯璭痯筦管舘輨錧館馆鳤丱冠卝悹悺惯慣掼摜樌欟毌泴潅灌爟瓘盥矔礶祼罆罐貫贯躀遦鏆鑵雚鱹鸛鹳僙光咣垙姯桄洸灮炗炚炛烡珖胱茪輄銧黆广広廣犷獷臩俇臦逛亀圭妫媯嫢嬀嶲巂帰廆归摫椝槻槼櫷歸珪瑰璝瓌皈瞡硅胿茥蘬袿規规邽郌閨闺雟騩鬶鬹鮭鲑龜龟佹匦匭厬垝姽宄庋庪恑攱晷氿湀癸祪簋蛫蟡觤詭诡軌轨陒鬼刽刿劊劌撌攰昋柜桂桧椢槶樻檜櫃猤癐眭瞆瞶禬筀蓕螝襘貴贵跪鐀鑎鞼鱖鱥鳜丨惃滚滾磙緄緷绲蓘蔉衮袞輥辊鮌鯀鲧棍睔謴啯嘓埚堝墎崞彉彍懖楇濄猓瘑聒蝈蟈郭鈛鍋锅囯囶囻国圀國帼幗慖掴摑漍簂聝腘膕蔮虢馘惈果椁槨淉粿綶菓蜾裹褁輠餜馃腂过過鐹哈紦鉿铪咍嗨孩还骸塰海烸胲酼醢亥嗐妎害氦餀饚駭駴骇佄哻嫨憨犴蚶谽酣頇顸馠魽鼾函凾含唅圅娢寒崡嵅晗梒浛涵澏焓琀甝筨虷蜬邗邯鋡韓韩丆喊浫罕豃傼厈垾屽悍憾扞捍撖撼旱晘暵汉汗涆漢瀚焊熯猂皔睅翰莟菡蔊蛿蜭螒譀輚釬銲鋎閈闬雗頷顄颔馯駻鶾兯爳夯吭垳斻杭笐筕絎绗航苀蚢裄貥迒頏颃魧沆嚆茠蒿薅薧乚儫嗥嘷噑嚎壕椃毜毫濠獆獋獔竓籇蚝蠔譹豪好郝侴傐号哠恏悎昊昦晧暠暤暭曍浩淏滈澔灏灝皓皜皞皡皥秏耗聕薃號鄗顥颢鰝呵喝嗬抲欱蠚訶诃何劾合咊和啝姀峆惒敆曷朅柇核楁毼河涸渮澕熆狢皬盇盉盍盒礉禾篕籺粭紇纥翮荷菏萂螛覈訸詥貈貉郃釛鉌鑉閡閤闔阂阖鞨頜颌餄饸魺鲄鶡鹖麧齕龁龢哬嗃嚇垎壑寉焃煂熇燺爀癋碋翯袔褐謞賀贺赫靍靎靏鶮鶴鸖鹤嘿潶黑黒拫痕鞎佷很狠詪恨亨哼悙涥脝姮恆恒撗桁横橫烆珩胻蘅衡鑅鴴鵆鸻啈叿呍哄嚝揈渹灴烘焢硡薨訇谾軣輷轟轰鍧仜吰垬妅娂宏宖屸弘彋汯沗泓洪浤渱潂玒玜硔竑竤篊粠紅紘紭綋红纮羾翃翝耾苰荭葒葓虹谹谼鈜鉷鋐閎闳霐霟鞃魟鴻鸿黉黌晎撔澒蕻訌讧銾閧闀闂鬨齁侯喉帿猴瘊睺矦篌糇翭翵葔鄇銗鍭餱骺鯸吼吽犼候厚后垕堠後洉茩豞逅郈鮜鱟鲎鲘乎乯匢匫呼唿嘑垀寣幠忽恗惚昒曶歑泘淴滹烀糊膴苸虍虖謼軤轷雐雽喖嘝囫壶壷壺媩弧抇搰斛楜槲湖瀫焀煳狐猢瑚瓳箶絗縠胡葫蔛蝴螜衚觳醐鍸隺頶餬鬍魱鰗鵠鶘鶦鹄鹕乕俿唬汻浒滸琥萀虎虝錿鯱互冱嗀嚛婟嫭嫮岵帍弖怘怙戶户戸戽扈护摢昈枑槴沍沪滬熩瓠祜笏簄粐綔芐蔰護豰鄠鍙頀鱯鳠鳸鸌鹱埖婲椛硴糀花蒊蘤誮錵划劃华呚哗嘩姡搳撶滑猾磆華蕐螖譁釪釫鋘鏵铧驊骅鷨化夻婳嫿嬅崋摦杹枠桦槬樺澅画畫畵繣舙觟話諙諣譮话黊徊怀懐懷槐櫰淮瀤耲蘹褢褱踝咶坏壊壞蘾孉懽欢歓歡犿獾讙貛酄驩鴅鵍圜堚嬛寏寰峘桓洹澴狟獂环環瓛糫絙綄繯缳羦荁萈萑豲貆還鍰鐶锾镮闤阛雈鬟鹮睆緩缓唤喚喛嚾奂奐宦嵈幻患愌换換擐攌梙槵浣涣渙漶澣烉焕煥瑍痪瘓肒藧豢轘逭鯇鯶鰀鲩塃宺巟慌朚肓荒衁偟凰喤堭墴媓崲徨惶揘楻湟潢煌熿獚瑝璜癀皇磺穔篁簧艎葟蝗蟥諻趪遑鍠鐄锽隍韹餭騜鰉鱑鳇鷬黃黄兤奛幌怳恍晃晄櫎炾熀縨詤謊谎愰曂榥滉皝皩鎤咴噅噕婎媈幑徽恢拻挥揮撝晖暉楎洃瀈灰灳烣煇睢睳禈翚翬蘳袆褘詼诙豗輝辉隓隳鰴麾佪囘回囬廻廽恛洄烠痐茴蚘蛔蛕蜖迴逥鮰悔檓毀毁毇燬虺譭会僡儶匯卉喙嘒嚖圚嬒寭屶屷彗彙彚徻恚恵惠慧憓懳晦暳會槥橞檅櫘汇泋湏滙潓濊烩燴獩璤璯瘣瞺秽穢篲絵繢繪绘缋翙翽芔荟蔧蕙薈薉藱蟪詯誨諱譓譿讳诲賄贿鏸鐬闠阓靧頮顪颒餯婚惛昏昬棔殙涽睧睯荤葷蔒轋閽阍忶浑渾珲琿餛馄魂鼲俒倱圂婫尡慁掍混溷焝睴觨諢诨劐吙攉秴耠豁騞佸活秮秳伙夥漷火灬煷邩鈥钬俰剨咟喐嚄嚯嚿奯彟彠惑或捇掝擭旤曤檴沎湱濩瀖獲癨眓矆矐祸禍穫窢耯臛艧获蒦藿蠖謋貨货鍃鑊锪镬閄雘霍靃韄乩僟击刉刏剞叽咭唧喞嗘嘰圾基墼姬屐嵆嵇撃擊朞机枅槣樭機櫅毄激犄玑璣畸畿癪矶磯禨积稘稽積笄筓箕簊綨緁緝缉羁羇羈耭肌芨虀覉覊觭譏譤讥賫賷赍跻踑躋躸銈錤鐖鑇鑙隮雞鞿韲飢饑饥魕鳮鶏鶺鷄鸄鸡鹡齏齑亟亼亽伋佶偮卙即卽及叝吉堲塉姞嫉岌嶯彶忣急愱戢揤极棘楖楫極槉檝殛汲湒潗濈焏疾瘠皀皍磼笈箿籍級级耤膌艥蒺蕀蕺蝍螏襋觙谻趌踖蹐躤輯轚辑郆銡鍓鏶集雧霵齎丮几妀嵴己幾戟挤掎撠擠橶泲犱穖脊虮蟣魢鱾麂伎偈兾冀剂剤劑勣哜嚌坖垍塈妓季寂寄廭彐彑徛忌悸惎懻技旡既旣暨暩曁梞檕檵洎济済漃漈濟瀱璾痵癠祭禝稩稷穄穊穧紀紒継績繋繼纪继绩罽臮芰茍茤荠葪蓟蔇薊薺蘎蘮蘻裚襀覬觊計記誋諅计记跡跽蹟迹际際霁霽驥骥髻鬾魝魥鯚鯽鰶鰿鱀鱭鲚鲫鵋鷑齌乫伽佳傢加嘉家徍抸拁枷梜毠泇浃浹犌猳珈痂笳糘耞腵葭袈豭貑跏迦鉫鎵镓鴐麚唊圿夹夾忦恝戛戞扴脥荚莢蛱蛺袷裌郏郟鋏铗頬頰颊鴶鵊假叚婽岬徦斚斝椵榎槚檟玾甲瘕胛賈贾鉀钾价價嫁幏架榢稼駕驾兼冿囏坚堅奸姦姧尖幵惤戋戔搛椷椾樫櫼歼殱殲湔瀐瀸煎熞熸牋犍猏玪瑊监監睷碊礛礷笺箋緘縑缄缣肩艰艱菅菺葌蒹蔪蕑蕳虃譼豜豣鋻鑯間间雃靬鞯韀韉餰馢鰔鰜鰹鲣鳒鳽鵑鵳鶼鹣麉俭倹儉减剪囝堿帴弿彅戩戬拣挸捡揀揃撿暕枧柬梘检検檢減湕瀽瑐睑瞼硷碱礆笕筧简篯簡籛絸繭翦茧藆蠒裥襇襉襺詃謇謭譾谫趼蹇鐗鐧锏鬋鰎鹸鹻鹼件俴健僭剑剣剱劍劎劒劔墹寋建徤擶旔栫楗榗槛檻毽洊涧渐溅漸澗濺瀳牮珔瞷磵礀箭糋繝腱臶舰艦荐薦袸見覵覸见諓諫譛谏賎賤贱趝跈践踐踺轞鉴鍳鍵鏩鐱鑑鑒鑬鑳键鞬餞饯僵壃姜将將摪橿殭江浆漿畕畺疅疆礓繮缰翞茳葁薑螀螿豇韁鱂鳉傋塂奖奨奬桨槳獎耩膙蒋蔣講讲顜勥匞匠夅嵹弜弶摾櫤洚滰犟糡糨絳绛謽酱醤醬降交僬姣娇嬌峧嶕嶣憍椒浇澆焦燋礁穚簥胶膠膲艽茭茮蕉虠蛟蟭跤轇郊鐎驕骄鮫鲛鵁鷦鷮鹪嚼佼侥僥儌剿劋勦孂徺徼憿挢捁搅摷撟撹攪敫敽敿晈暞曒灚烄煍燞狡璬皎皦矫矯笅筊絞繳纐绞缴脚腳臫蟜角譑賋踋鉸铰餃饺鱎龣叫呌嘂嘄嘦噍噭嬓嶠挍敎教斠滘漖潐獥珓皭窌窖藠訆譥趭較轎轿较酵醮釂喈喼嗟堦媘嫅接掲揭擑椄楬湝煯疖痎癤皆秸稭脻菨蝔街謯阶階鞂鶛倢偼傑刦刧刼劫劼卩卪婕媫孑尐岊崨嵥嶻巀幯截拮捷掶搩擮昅杢杰桀桔桝楶榤洁滐潔狤疌睫碣礍竭節結结羯节莭蓵蛣蜐蠘蠞蠽衱袺訐詰誱讦诘跲踕迼鉣鍻镼鞊頡颉鮚鲒姐媎檞毑解觧飷丯介借吤唶堺屆届岕庎徣悈戒楐犗玠琾界畍疥砎芥藉蚧蛶衸褯誡诫鎅骱魪今仐堇堻巾惍斤津珒琎琻璡矜矝砛禁筋紟荕衿襟觔金釒釿钅鹶黅仅侭僅儘卺厪嫤巹廑慬槿漌瑾紧緊菫蓳謹谨錦锦饉馑伒僸凚劤劲勁唫噤嚍墐壗妗嬧尽搢晉晋枃歏殣浕浸溍濅濜烬煡燼瑨璶盡祲縉缙荩藎覲觐賮贐赆近进進靳齽京亰兢坕坙婛巠惊旌旍晶橸泾涇猄睛秔稉粳精経經綡经聙腈茎荆荊菁葏驚鯨鲸鶁鶄麖麠鼱丼井儆刭剄坓宑幜憬憼景暻殌汫汬澋璄璟璥穽肼蟼警阱頚頸颈俓傹净凈境妌婙婧弪弳径徑敬曔桱梷浄淨瀞獍痉痙竞竟竧竫競竸胫脛莖誩踁迳逕鏡镜靓靖静靚靜鵛冂冋坰埛扃絅蘏蘔駉駫侰僒冏囧泂浻澃炅炯烱煚煛熲燛窘綗褧迥逈顈颎丩勼啾揂揪揫摎朻樛牞究糺糾纠萛赳阄鬏鬮鳩鸠久乆九乣奺杦汣灸玖紤舏酒镹韭韮倃僦匓匛匶厩咎就廄廏廐慦捄救旧柩柾桕欍殧疚臼舅舊鯦鷲鹫麔齨凥匊娵婮居岨崌抅拘掬梮椐檋毩毱泃涺狙琚疽眗砠罝腒艍苴蜛裾諊跔跙踘躹鋦锔陱雎鞠鞫駒驹鮈鴡鶋侷啹婅局巈挶椈橘泦淗湨焗犑狊粷繘菊蘜趜跼蹫輂郹閰駶驧鵙鵴鶪鼰鼳举咀弆挙擧椇榉榘櫸欅沮矩筥聥舉莒蒟襷踽齟龃乬俱倨倶具剧劇勮句埧埾壉姖寠屦屨岠巨巪怇惧愳懅懼拒拠据據昛歫洰澽炬烥犋秬窭窶簴粔耟聚苣虡蚷袓詎讵豦貗距踞躆遽邭醵鉅鋸鐻钜锯颶飓駏鮔勬姢娟捐朘涓焆脧蠲裐鋑鎸鐫镌鹃卷呟埍巻捲臇菤錈锩倦劵勌奆婘帣弮惓慻桊淃狷獧瓹眷睊睠絭絹绢罥羂腃蔨讂鄄餋噘屩屫撅撧亅决刔劂匷厥噊噱孒孓崛崫嶡嶥弡彏憠憰戄抉挗捔掘攫斍桷橛橜櫭欮氒決泬灍焳熦爑爝爴爵獗玃玦玨珏瑴疦瘚矍矡砄絕絶绝臄芵蕝蕨虳蚗蟨蟩覐覚覺觉觖觮觼訣譎诀谲貜赽趉趹蹶蹷躩鈌鐍鐝钁镢駃鴂鴃鷢倔军君均桾汮皲皸皹碅莙菌蚐袀覠軍鈞銁銞鍕钧頵鮶鲪麇麏麕俊儁呁埈寯峻懏捃攈攟晙棞浚濬燇珺畯竣箘箟葰蜠賐郡陖隽雋餕馂駿骏鵔鵕鵘咖喀佧卡咔咯垰胩裃鉲奒开揩鐦锎開凯凱剀剴嘅垲塏嵦恺愷慨暟楷蒈輆鍇鎧铠锴闓闿颽勓忾愾欬炌烗鎎刊勘堪嵁戡栞龕龛侃偘冚凵坎惂欿歁砍竷莰輡轗顑墈崁看瞰矙磡衎闞阚鬫嫝嵻康忼慷槺漮砊穅粇糠躿鏮閌鱇扛亢伉匟囥抗炕犺邟鈧钪闶尻嵪髛丂拷攷栲洘烤考犒銬铐靠鮳鯌鲓匼嗑嵙搕柯棵榼樖牁牱犐珂疴痾瞌砢磕礚科稞窠苛萪薖蚵蝌趷軻轲醘鈳钶頦顆颏颗髁咳壳揢殻殼翗可坷岢嵑嶱敤渇渴炣克刻勀勊堁娔客尅峇恪愘愙氪溘碦礊緙缂艐衉課课錁锞騍骒剋啃垦墾恳懇肎肯肻豤貇錹掯硍裉褃劥坑妔挳摼牼硁硜硻誙銵鍞鏗铿阬倥埪崆悾涳硿空箜躻錓鵼孔恐控鞚剾彄抠摳眍瞘芤劶口冦叩宼寇怐扣敂滱瞉窛筘簆蔲蔻釦鷇刳哭圐堀枯桍矻窟跍郀骷鮬楛狜苦俈喾嚳库庫廤焅瘔秙絝绔袴裤褲酷咵夸姱舿誇侉垮銙挎胯趶跨骻擓蒯侩儈凷哙噲圦块塊墤巜廥快旝欳浍澮狯獪筷糩脍膾郐鄶鱠鲙宽寛寬臗鑧髋髖梡欵款歀窽窾劻匡匩哐恇洭硄筐筺誆诓軭邼忹抂狂狅誑诳軖軠鵟儣夼懭况圹壙岲懬旷昿曠框況爌眖眶矌矿砿礦穬絋絖纊纩貺贶軦邝鄺鉱鋛鑛黋亏刲岿巋悝盔窥窺聧虧闚顝喹夔奎巙戣揆晆暌楏楑櫆犪睽葵藈蘷虁蝰躨逵鄈鍨鍷頯馗騤骙魁傀煃磈跬蹞頍匮匱喟嘳媿嬇尯愦愧憒殨溃潰篑簣籄聩聭聵膭蒉蕢謉餽饋馈坤堃堒崐崑昆晜潉焜熴猑琨瑻菎蜫裈裩褌醌錕锟騉髠髡髨鯤鲲鵾鶤鹍壸壼悃捆梱硱祵稇稛綑裍閫閸阃困涃睏廓扩拡括挄擴濶筈萿葀蛞闊阔霩鞟鞹韕頢髺鬠啦垃拉搚柆菈邋嚹旯磖喇藞剌揦揧攋楋櫴溂爉瓎瘌翋腊臈臘蜡蝋蝲蠟辢辣鑞镴鬎鯻鞡來俫倈婡崃崍庲徕徠来梾棶涞淶猍琜筙箂莱萊逨郲錸铼騋鯠鶆麳襰唻濑瀨瀬癞癩睐睞籁籟藾賚賴赉赖頼顂鵣儖兰啉囒婪岚嵐幱惏懢拦攔斓斕栏欄欗澜瀾灆灡燣燷璼篮籃籣繿葻蓝藍蘫蘭褴襕襤襴襽譋讕谰躝鑭镧闌阑韊壈嬾孄孏懒懶揽擥攬榄欖浨漤灠爦纜缆罱覧覽览醂顲嚂滥濫烂燗爁爛爤瓓糷钄啷勆嫏廊斏桹榔樃欴狼琅瑯硠稂筤艆蓈蜋螂躴郎郒郞鋃鎯锒塱崀朖朗朤烺蓢誏埌浪莨蒗閬阆捞撈粩僗劳労勞哰崂嶗憥朥浶牢痨癆磱窂簩蟧醪鐒铹顟髝佬咾姥恅栳潦狫珯硓老耂荖蛯轑銠铑鮱唠嗠嘮嫪憦橯涝澇烙耢耮躼軂酪乐仂勒叻忇扐楽樂氻泐玏砳竻簕艻阞韷餎鰳鱳鳓了儽嫘擂攂樏檑櫑欙瓃畾礌礧累縲纍纝缧罍羸蔂蘲虆轠鐳鑘镭雷靁鱩鼺傫儡厽垒塁壘壨櫐洡灅癗矋磊磥礨絫耒蕌蕾藟蘽蠝誄讄诔鑸鸓泪涙淚禷类纇肋蘱酹銇錑頛頪類颣嘞唥塄棱楞碐稜薐冷倰堎愣睖踜刕剓剺劙厘喱嚟囄嫠孷廲悡斄梨梸棃樆漓灕犁犂狸琍璃瓈盠睝离穲竰筣篱籬糎縭纚缡罹艃荲菞蓠蔾藜蘺蟍蟸蠫褵謧貍邌醨釐鋫錅鏫鑗離驪骊鯏鯬鱺鲡鵹鸝鹂黎黧俚娌峛峢峲李欚浬澧理礼禮粴蠡裏裡豊逦邐醴里鋰锂鯉鱧鱱鲤鳢丽例俐俪傈儮儷凓利力励勵历厉厤厯厲叓吏呖唎唳嚦囇坜塛壢娳婯孋屴岦巁悧悷慄戾搮擽攊攦攭暦曆曞朸枥栃栎栗栛棙檪櫔櫟櫪欐歴歷沥沴浰涖溧濿瀝爄爏犡猁珕瑮瓅瓑瓥疠疬痢癘癧皪盭睙砅砬砺砾磿礪礫礰禲秝立笠篥粒粝糲綟脷苈苙茘荔莅莉蒚蒞藶蚸蛎蛠蜊蜧蝷蠇蠣觻詈讈赲跞躒轢轣轹郦酈鉝隶隷隸雳靂靋鬁鳨鴗鷅麗麜哩亷劆匲匳嗹噒奁奩嫾帘廉怜慩憐梿槤櫣涟溓漣濂濓瀮熑燫磏簾籢籨縺翴联聨聫聮聯臁莲蓮薕螊蠊裢褳覝謰蹥连連鎌鐮镰鬑鰱鲢嬚摙敛斂歛琏璉羷脸臉蔹蘝蘞裣襝鄻僆堜媡恋戀楝殓殮湅潋澰瀲炼煉瑓練纞练萰錬鍊鏈链鰊俍凉墚梁椋樑涼粮粱糧良踉輬辌駺両两俩倆兩唡啢掚緉脼蜽裲魉魎亮倞哴喨悢晾湸諒谅輌輛辆量鍄撩蹽僚嘹嫽寥寮尞屪嵺嶚嶛廫憀敹暸橑漻燎爎爒獠璙疗療竂簝繚缭聊膋膫藔蟟豂賿蹘辽遼飉髎鷯鹩憭曢瞭蓼鄝釕钌镽尥尦廖撂料炓窷鐐镣咧挘毟儠冽列劣劽哷埒埓姴巤挒捩擸栵洌浖烈烮煭犣猎猟獵聗脟茢蛚裂趔躐迾颲鬛鬣鮤鱲鴷拎临冧厸壣崊嶙斴晽暽林淋潾瀶燐獜琳璘疄瞵碄磷箖粦粼綝繗翷臨轔辚遴邻鄰鏻阾隣霖驎鱗鳞麐麟亃僯凛凜廩廪懍懔撛檁檩澟癛癝菻吝恡悋橉焛甐膦蔺藺賃赁蹸躏躙躪轥閵〇伶凌刢呤囹坽夌姈婈孁崚彾掕昤朎柃棂櫺欞泠淩澪灵燯爧狑玲琌瓴皊砱祾秢竛笭紷綾绫羐羚翎聆舲苓菱蓤蔆蕶蛉衑裬詅跉軨輘酃醽鈴錂铃閝陵零霊霗霛霝駖魿鯪鲮鴒鸰鹷麢齡齢龄龗岭岺嶺袊領领令另炩蘦靈溜澑熘蹓刘劉嚠媹嵧懰斿旈旒榴橊流浏瀏琉瑠瑬璢畄留畱疁瘤癅硫磂蒥蓅藰蟉裗鎏鎦鏐鐂镏镠飀飅飗駠駵騮驑骝鰡鶹鹠麍嬼柳栁桞桺橮熮珋綹绺罶羀鋶锍六塯廇磟翏遛雡霤飂餾馏鬸鷚鹨咙嚨尨嶐巃巄昽曨朧栊槞櫳泷湰滝漋瀧爖珑瓏癃眬矓砻礱礲窿竜笼篭籠聋聾胧茏蘢蠪蠬襱豅躘鏧鑨隆霳靇驡鸗龍龒龓龙儱垄垅壟壠拢攏竉陇隴哢徿梇贚剅喽嘍娄婁廔楼樓溇漊熡瞜耧耬艛蒌蔞蝼螻謱軁遱鞻髅髏鷜塿嵝嶁搂摟甊篓簍屚漏瘘瘺瘻鏤镂陋露噜嚕撸擼謢卢嚧垆壚庐廬攎曥枦栌櫨泸瀘炉爐獹玈璷瓐盧矑籚纑罏胪臚舮舻艫芦蘆蠦轤轳鈩鑪顱颅馿髗魲鱸鲈鸕鸬黸卤塷掳擄樐橹櫓氇氌滷澛瀂硵磠穞艣艪蓾虏虜鏀鐪鑥镥魯鲁鹵侓僇剹勎勠圥坴塶娽峍廘彔录戮摝椂樚淕淥渌漉潞熝琭璐甪盝睩硉碌祿禄稑穋箓簏簬簵簶籙粶膔菉蔍蕗虂螰賂赂趢路踛蹗輅轆辂辘逯醁錄録錴鏕鏴陆陸騄騼鯥鴼鵦鵱鷺鹭鹿麓圝圞奱娈孌孪孿峦巒挛攣曫栾欒滦灓灤癴癵羉脔臠虊銮鑾鵉鸞鸾卵乱亂釠抡掄仑伦侖倫囵圇婨崘崙棆沦淪碖磮綸纶耣腀芲菕蜦踚輪轮錀陯鯩埨惀稐溣論论啰囉捋頱儸囖攞椤欏猡玀箩籮罗羅脶腡萝蘿螺覶覼逻邏鏍鑼锣镙饠騾驘骡鸁倮剆曪瘰癳臝蓏蠃裸躶峈摞泺洛洜漯濼犖珞硌硦笿絡纙络荦落詻雒駱骆鮥鵅榈櫚氀膢藘閭闾驢驴侣侶偻僂儢吕呂屡屢履慺挔捛旅梠焒祣稆穭絽縷缕膂膐褛褸郘鋁铝勴垏嵂律慮櫖氯滤濾爈率箻綠緑繂绿膟葎虑鑢圙寽掠略畧稤鋝鋢锊妈媽嫲嘛犘痲痳蔴蟆蟇麻杩溤犸獁玛瑪码碼蚂螞遤鎷馬马鰢鷌傌嘜榪睰祃禡罵閁駡骂鬕吗嗎埋薶霾买嘪荬蕒買鷶佅劢勱卖唛売脈脉衇賣迈邁霡霢麥麦顢颟姏悗慲摱樠瞒瞞蛮蠻謾谩鞔饅馒鬗鬘鰻鳗娨屘満满滿矕螨蟎襔鏋僈墁嫚幔慢曼槾漫澷熳獌縵缦蔄蔓蘰鄤鏝镘牤厖吂哤娏忙恾杗杧汒浝牻狵痝盲盳硭笀芒茫蘉蛖邙釯鋩铓駹壾漭硥茻莽莾蟒蠎猫貓堥旄枆楙毛氂渵牦犛矛罞芼茅茆蝥蟊軞酕鉾錨锚髦髳鶜乮冇卯夘峁戼昴泖笷蓩鉚铆冃冐冒媢帽愗懋暓柕毷瑁皃眊瞀耄茂萺蝐袤覒貌貿贸鄚鄮嚒嚰濹么麼麽坆堳塺媒嵋徾攗枚栂梅楣楳槑沒没湄湈煤猸玫珻瑂眉睂禖脄脢腜苺莓葿郿酶鋂鎇镅霉鶥鹛黴凂媄媺嬍嵄挴毎每浼渼燘美羙躾鎂镁黣嚜妹媚寐抺旀昧沬煝痗眛睸祙篃蝞袂跊韎鬽魅椚们們扪捫玧璊穈菛虋鍆钔門閅门悶懑懣暪焖燜闷掹擝矇蒙儚幪懞曚朦橗檬氋氓溕濛獴甍甿盟瞢矒礞艨莔萌蕄虻蝱鄳鄸霿靀顭饛鯍鸏鹲冡勐懵猛艋蜢蠓錳锰鯭鼆夢夣孟懜梦癦霥咪眯瞇冞弥彌戂擟攠瀰爢猕獼瓕祢禰糜縻蒾藌蘪蘼袮詸謎谜迷醚醾醿釄镾靡鸍麊麋麛麿侎孊弭敉沵洣渳濔灖米粎羋脒芈葞蔝銤冖冪嘧塓宓宻密峚幂幎幦怽榓樒櫁汨沕泌淧滵漞濗熐祕秘簚糸羃蔤蜜覓覔覛觅謐谧鼏婂媔嬵宀杣棉檰櫋眠矈矊矏綿緜绵臱芇蝒丏偭免冕勉勔喕娩愐汅沔渑湎澠眄睌絻緬缅腼葂靦鮸糆面靣麪麫麵麺喵媌嫹描瞄緢苗鶓鹋劰杪淼渺眇秒篎緲缈藐邈妙庙庿廟玅竗乜吀咩哶孭幭懱搣櫗滅瀎灭烕礣篾蔑薎蠛衊鑖鱴鴓垊姄岷崏怋慜捪旻旼民玟珉琘琝瑉痻盿砇碈緍緡缗罠苠鈱錉鍲鴖僶冺刡勄忞忟悯惽愍憫抿敃敏敯暋泯湣潣皿笢笽簢蠠閔閩闵闽鰵鳘黽黾冥名嫇明暝朙榠洺溟猽眀眳瞑茗蓂螟覭詺鄍銘铭鳴鸣佲凕姳慏酩命掵謬谬嚤摸劘嫫嬤嬷尛庅摩摹擵模橅磨糢膜蘑謨謩谟饃饝馍髍魔魹懡抹嗼圽塻墨妺嫼寞帓帞昩末枺歾歿殁沫漠爅獏瘼皌眜眽眿瞐瞙砞礳秣絈纆耱茉莈莫蓦藦蛨蟔貃貊貘銆鏌镆陌靺驀魩默黙哞侔劺呣恈牟眸繆缪蛑謀谋踎鍪鴾麰某毪氁亩姆峔拇母牡牳畂畆畒畝畞畮砪胟踇鉧仫凩募坶墓幕幙慔慕暮暯木楘毣沐炑牧狇目睦穆縸艒苜莯蚞鉬钼雮霂鞪嗱拏拿搻鎿镎乸哪雫吶呐妠捺笝納纳肭蒳衲袦豽貀軜那郍鈉钠靹魶孻腉乃倷奶嬭廼氖疓艿迺釢奈柰渿耐萘螚褦錼鼐囡侽南喃娚抩暔枏柟楠男畘莮諵遖难難戁揇湳煵腩萳蝻赧婻囔乪嚢囊欜蠰饢馕擃攮曩灢儾齉孬呶夒峱嶩巎怓憹挠撓猱獶獿硇碙蛲蟯詉譊鐃铙匘垴堖嫐恼悩惱瑙碯脑脳腦淖臑閙闹鬧抐疒眲訥讷呢娞脮腇餒馁鮾鯘內内氝氞錗嫩嫰恁能妮倪坭埿婗尼屔怩棿泥淣猊秜籾聣臡蚭蜺觬貎跜輗郳鈮铌霓馜鯢鲵麑齯伱伲你儗儞妳孴抳拟掜擬旎晲柅檷狔聻苨薿隬匿堄嫟嬺屰惄愵昵暱氼溺眤睨縌胒腻膩誽逆拈蔫哖姩年秊秥粘鮎鯰鲇鲶鵇黏捻撚撵攆涊淰焾碾簐蹍蹨躎輦辇卄唸埝廿念惗艌娘嬢孃酿醸釀嫋嬝嬲樢茑蔦袅裊褭鳥鸟尿脲捏揑苶啮嗫噛嚙囁囓圼孼孽嵲嶭巕帇摰敜枿槷櫱涅湼痆篞籋糱糵聂聶臬臲菍蘖蠥讘踂踗踙蹑躡錜鎳鑈鑷钀镊镍闑陧隉顳颞齧囜您脌拰儜凝咛嚀嬣宁寍寕寗寜寧擰柠橣檸狞獰甯聍聹薴鑏鬡鸋拧矃佞侫倿泞澝濘妞汼牛牜忸扭杻炄狃紐纽莥鈕钮靵侬儂农哝噥檂欁浓濃燶禯秾穠脓膿蕽襛譨農辳醲鬞繷弄挊挵癑齈羺槈檽獳耨鎒鐞伮奴孥帑笯駑驽努弩砮胬傉怒搙奻暖渜煖煗餪黁傩儺娜挪梛橠喏愞懦懧掿搦榒稬穤糑糥糯諾诺蹃逽鍩锘女籹釹钕恧朒沑衂衄婩疟瘧硸虐喔噢哦筽塸櫙欧歐殴毆熰瓯甌膒藲謳讴鏂鴎鷗鸥偶吘呕嘔耦腢蕅藕怄慪沤漚啪妑皅舥苩葩趴掱杷潖爬琶筢帊帕怕袙拍俳徘排棑牌犤猅箄簰簲輫哌沠派渒湃蒎鎃攀潘眅萠丬媻幋搫柈槃洀瀊爿盘盤磐磻縏蒰蟠跘蹒蹣鎜鞶冸判叛沜泮溿炍牉畔盼聁袢襻詊鋬鑻頖鵥乓滂胮膖雱霶厐嫎庞庬彷徬旁舽螃逄鰟鳑龎龐耪覫炐眫肨胖抛拋脬萢刨匏咆垉庖炰爮狍袍褜軳鞄麃麅跑奅泡炮疱皰砲礟礮靤麭呸怌肧胚衃醅培婄毰裴裵賠赔錇锫阫陪俖伂佩姵帔斾旆沛浿犻珮蓜轡辔配霈馷喷噴歕湓瓫盆葐呠翸剻匉嘭怦恲抨梈泙烹砰硑磞軯閛駍倗傰堋塜塳弸彭憉捀朋棚椖樥澎熢硼稝竼篣篷纄膨芃莑蓬蘕蟚蟛袶輣錋鑝韸韼騯髼鬅鬔鵬鹏捧淎皏掽椪槰碰踫丕伓伾劈噼坯岯悂憵批披抷旇枈炋狉狓砒磇礔礕秛秠紕纰翍耚豾邳釽鈚鉟銔錃錍陴霹駓髬魾啤埤壀崥枇毗毘焷琵疲皮笓篺罴羆肶脾腗膍蚍蚽蚾蜱螷蠯裨豼貔郫鈹铍阰隦魮鮍鲏鵧鼙仳匹吡噽嚭圮嶏庀擗疋痞癖脴苉諀銢鴄僻媲嫓屁揊淠潎澼甓疈稫譬辟闢鷿鸊偏囨媥楄犏篇翩鍂鶣楩胼腁賆跰蹁駢騈骈骿覑諞谝貵片騗騙骗魸剽勡嘌彯慓旚漂犥翲螵飃飄飘魒嫖瓢薸闝殍皫瞟篻縹缥醥顠僄徱票驃鰾撆撇暼氕瞥覕丿苤鐅嫳姘拚拼砏礗穦馪驞嚬娦嫔嬪玭琕矉薲蘋蠙貧贫顰频颦品榀汖牝聘乒俜娉涄甹砯聠艵頩凭凴呯坪塀屏岼帡帲幈平慿憑枰檘洴淜焩玶瓶甁竮箳簈缾胓苹荓萍蓱蚲蛢評评軿輧郱鮃鲆屛坡岥泼溌潑酦醗醱釙鏺钋頗颇嘙嚩婆櫇皤蔢鄱叵尀笸箥鉕钷駊哱奤岶廹敀昢洦湐烞珀破砶粕蒪迫魄剖娝垺抔抙捊箁裒咅哣掊犃仆噗扑撲攴攵潽炇痡鋪铺陠鯆僕匍圤墣濮獛璞瞨穙纀莆菐菩葡蒱蒲贌酺鏷镤圃圑埔擈普暜朴樸檏氆浦溥烳諩譜谱蹼鐠镨曝瀑舖舗七倛傶僛凄嘁墄妻娸悽慼慽戚捿攲敧期柒栖桤桼棲榿欹欺沏淒漆紪緀萋褄諆踦蹊迉郪鏚霋魌鶈丌亓亝其剘圻埼奇岐岓崎嵜帺忯愭懠掑斉斊旂旗棊棋檱櫀歧淇濝猉玂琦琪璂畦疧碁碕祁祈祺禥竒簯簱籏粸綥綦耆肵脐臍艩芪萁萕蕲藄蘄蚑蚔蚚蛴蜝蜞螧蠐褀跂軝鄿釮錡锜陭隑頎颀騎騏騹骐骑鬐鬿鯕鰭鲯鳍鵸鶀麒麡齊齐乞企启呇唘啓啔啟婍屺岂晵杞棨玘盀綺绮芑諬豈起邔闙呮咠唭噐器夡契弃愒憇憩摖暣栔棄槭欫气気氣汔汽泣湆湇滊炁甈盵矵砌碛碶磜磧磩罊芞葺藒蟿訖讫迄鐑掐擖葜峠拤跒酠鞐冾圶帢恰殎洽硈胢髂仟佥僉千厱圱圲奷婜孯岍悭愆慳扦拪掔搴撁攐攑攓杄檶櫏欦汘汧牵牽竏签簽籖籤粁臤芊茾蚈褰諐謙谦谸迁遷釺鈆鉛鏲钎铅阡韆顅騫骞鬜鬝鵮鹐乹乾亁仱偂前墘媊岒忴扲拑掮揵榩橬歬潛潜濳灊箝羬荨葥蕁虔軡鈐鉗銭錢鎆钤钱钳騚騝鰬黔黚槏浅淺繾缱肷膁蜸譴谴遣鑓伣俔倩傔儙刋堑塹壍嬱嵌悓慊棈椠槧欠歉皘篏篟綪縴芡茜蒨蔳輤呛啌嗆嗴嶈戕戗戧搶摤斨枪椌槍溬牄猐獇玱瑲篬羌羗羫腔蜣謒跄蹌蹡鎗鏘锖锵墙墻嫱嬙廧強强彊樯檣漒牆艢蔃蔷薔蘠墏抢繈繦羟羥襁鏹镪唴炝熗羻劁勪墝墽帩幧悄敲橇毃燆硗磽繑繰缲趬跷踍蹺蹻郻鄡鄥鍫鍬鐰锹頝骹乔侨僑喬嘺墧嫶峤憔桥槗樵橋櫵犞癄睄瞧硚礄翘翹荍荞菬蕎藮譙谯趫鐈鞒鞽顦巧愀釥髜俏僺峭撬撽窍竅誚诮躈陗鞘鞩韒髚切苆癿聺茄且匧厒妾怯悏惬愜挈洯淁穕窃竊笡箧篋籡蛪趄踥郄鍥锲鯜亲侵兓媇寴嵚嵰嶔欽綅衾親誛钦顉駸骎鮼勤嗪噙埐嫀嶜庈懃懄捦擒斳檎澿珡琴琹瘽禽秦耹肣芩芹菦菳蚙螓蠄鈙鈫雂靲鳹鵭坅寑寖寝寢昑梫笉螼赾鋟锓吢吣唚抋揿搇撳沁瀙菣藽倾傾卿圊埥寈氢氫淸清蜻軽輕轻郬錆鑋靑青鯖鲭剠勍啨夝情擎擏晴暒棾樈檠殑氰甠硘葝黥庼廎檾漀苘請謦请頃顷儬凊庆慶掅櫦殸濪碃磬箐綮罄靘儝卭宆惸憌桏橩焪焭煢熍琼璚瓊瓗睘瞏穷穹窮竆笻筇舼茕藑藭蛩蛬赹跫邛銎丘丠坵媝恘恷楸湫湬秋秌穐篍緧萩蓲蘒蚯蝵蟗蠤趥邱鞦鞧鰌鰍鳅鶖鹙龝俅叴唒囚崷巯巰扏朹梂殏毬求汓泅浗渞湭煪犰玌球璆皳盚紌絿肍芁莍虬虯蛷蝤裘觓觩訄訅賕赇逎逑遒酋醔釚釻銶頄鮂鯄鰽鼽搝糗伹佉匤区區呿坥屈岖岴嶇憈抾敺浀焌煀祛筁粬紶胠蛆蛐袪覰詘誳诎趋趍趨躯軀阹駆駈驅驱髷魼鰸鱋鶌麯麴麹黢佢劬忂戵斪朐欋欔氍淭渠灈爠璖璩癯瞿磲籧絇翑胊臞菃葋蕖蘧螶蟝蠷蠼衐衢躣軥鑺鴝鸜鸲鼩取娶曲竘竬蝺詓齲龋刞厺去耝覷覻觑趣閴闃阒麮鼁圈圏奍悛棬椦箞鐉佺全啳埢姾峑巏恮拳搼权楾権權泉洤湶牷犈瑔痊硂筌絟縓荃葲蜷蠸觠詮诠跧踡輇辁醛銓铨闎顴颧駩騡鬈鰁鳈齤烇犬犭犮畎綣绻虇券劝勧勸牶韏炔缺缼蒛阙瘸傕却卻埆塙崅悫愨慤搉棤榷燩琷皵硞确碏確碻礐礭趞闋闕阕雀鵲鹊囷夋踆逡宭峮帬羣群裙裠呥嘫然燃繎肰蚦蚺衻袇袡髥髯冄冉姌媣染橪珃苒蒅儴勷瀼獽瓤禳穣穰蘘躟鬤嚷壌壤攘爙懹譲讓让娆嬈桡橈荛蕘襓饒饶扰擾隢繞绕遶惹热熱人亻仁壬忈忎朲秂芢銋魜鵀忍栠栣棯秹稔綛荏荵躵仞仭任刃刄妊姙屻岃扨杒梕牣祍紉紝絍纫纴肕腍衽袵訒認认讱軔轫鈓靭靱韌韧飪餁饪扔仍礽芿辸陾囸日衵釰釼鈤馹驲傛媶嫆嬫容峵嵘嵤嶸戎搈搑曧栄榕榮榵槦毧溶瀜烿熔爃狨瑢穁絨縙绒羢肜茙茸荣蓉蝾融螎蠑褣鎔镕駥傇冗坈宂氄軵穃厹媃揉柔楺渘煣瑈瓇禸粈糅脜腬葇蝚蹂輮鍒鞣騥鰇鶔韖宍肉譳嶿侞儒嚅如嬬孺帤挐曘桇渪濡筎繻茹蒘蕠薷蝡蠕袽襦邚醹銣铷顬颥鱬鴑鴽乳擩汝肗辱鄏入嗕媷扖杁洳溽縟缛蓐褥鳰堧壖撋偄媆朊瑌瓀碝礝緛耎腝軟輭软阮桵甤緌蕤壡惢橤繠蕊蕋蘂蘃叡枘汭瑞睿芮蚋蜹銳鋭锐瞤橍润潤膶閏閠闰挼捼偌叒婼嵶弱楉渃焫爇箬篛若蒻鄀鰙鰯鶸仨撒洒灑訯躠靸卅摋櫒脎萨蕯薩鈒钑隡颯飒馺嘥噻塞愢揌毢毸腮顋鰓鳃嗮僿簺賽赛三厁叁弎毵毶毿犙鬖伞傘糁糝糣糤繖鏒鏾饊馓俕散潵閐壭桑桒槡嗓搡磉褬鎟顙颡丧喪慅掻搔溞繅缫臊螦颾騒騷骚鰠鱢鳋嫂扫掃埽氉瘙矂髞閪啬嗇懎摵擌栜歮歰洓涩渋澀澁濇濏瀒瑟璱瘷穑穡穯繬色譅轖銫鏼铯雭飋森椮槮襂僧鬙乷唦杀桬榝樧殺毮沙煞猀痧砂硰粆紗繺纱蔱裟鎩铩閷髿魦鯊鯋鲨啥傻儍倽厦唼啑喢嗄帹廈歃箑翜翣萐閯霎筛篩簁簛籭晒曬傓删刪剼嘇圸姍姗山幓彡挻搧杉柵檆潸澘煽狦珊痁笘縿羴羶脠膻舢芟苫衫跚軕邖釤钐閊鯅晱炶煔熌睒覢閃闪陕陝僐善墠墡嬗扇掞擅敾椫樿歚汕灗疝磰禪繕缮膳蟮蟺訕謆譱讪贍赡赸鄯銏鐥饍騸骟鱓鱔鳝伤傷商墒慯殇殤滳漡熵禓蔏螪觞觴謪鬺垧扄晌樉賞贘赏鋿鏛鑜丄上尙尚恦緔绱鞝弰捎旓梢烧焼燒稍筲艄莦萷蕱輎髾鮹勺杓柖玿芍韶少劭卲哨娋潲紹綤绍袑邵奓奢檨猞畬畭畲賒賖赊輋佘揲舌虵蛇蛥捨舍厍厙射弽慑慴懾摂摄攝欇涉涻渉滠灄社舎蔎蠂設设赦韘騇麝伸侁兟呻堔妽姺娠屾峷扟敒曑柛氠深燊珅甡甧申眒砷穼籶籸糂紳绅罙罧莘葠蓡蔘薓裑訷詵诜身駪鯓鯵鰺鲹鵢什榊神鉮鰰哂婶嬸审宷審弞曋沈渖瀋瞫矤矧覾訠諗讅谂谉邥頣魫侺愼慎昚涁渗滲甚瘆瘮眘祳肾胂脤腎葚蜃蜄鋠升呏声斘昇曻枡殅泩湦焺牲狌珄生甥竔笙聲苼鉎鍟阩陞陹鵿鼪憴縄繉繩绳譝偗渻省眚剩剰勝圣墭嵊晟晠榺橳琞盛聖胜蕂貹賸呞失尸屍师師施浉湤湿溮溼濕狮獅瑡箷絁葹蒒蓍虱蝨褷襹詩诗邿酾釃釶鉇鍦鯴鰤鲺鳲鳾鶳鸤乭十埘塒姼实実寔實峕嵵拾时旹時榯湜溡炻石祏竍蚀蝕識识遈鉐食飠饣鮖鰣鲥鼫鼭乨使兘史始宩屎榁矢笶豕鉂駛驶世丗亊事仕侍冟势勢卋呩嗜噬士奭嬕室崼市式弑弒徥忕恀恃戺拭揓是昰枾柹柿栻氏澨烒煶眂眎眡睗示礻秲筮簭舐舓莳蒔螫襫視视觢試誓諟諡謚试谥貰贳軾轼适逝適遾釈释釋鈰鉃鉽銴铈飾餙餝饰鰘籂辻収收垨守手扌艏首兽受售嘼壽夀寿授涭狩獣獸痩瘦綬绶膄鏉书倏倐儵叔姝婌抒掓摅攄書杸枢梳樞橾殊殳毹毺淑瀭焂琡疎疏紓綀纾舒菽蔬跾踈軗輸输鄃陎鮛鵨塾孰尗熟璹秫贖赎属屬数數暏暑曙潻癙糬署薥薯藷蜀蠴襡襩鱪鱰黍鼠鼡侸咰墅尌庶庻怷恕戍捒朮术束树樹沭漱潄澍濖竖竪絉腧荗蒁虪術裋豎述鉥錰鏣霔鶐刷唰耍誜摔衰甩卛帅帥蟀拴栓閂闩涮腨双孀孇欆礵艭雙霜騻驦骦鷞鸘鹴塽慡漺爽縔鏯灀脽誰谁水氵氺閖帨涗涚睡祱稅税裞吮楯橓瞚瞬舜蕣順顺鬊說説说妁搠朔槊欶烁爍獡矟硕碩箾蒴鎙鑠铄丝俬凘厮厶司咝嘶噝媤廝思恖撕斯楒泀澌燍磃禗禠私糹絲緦纟缌罳蕬虒蛳蜤螄蟖蟴鉰銯鋖鍶鐁锶颸飔騦鷥鸶鼶死亖似佀価俟儩兕嗣四姒娰孠寺巳杫枱柶梩榹汜泗泤洍洠涘瀃牭祀禩竢笥耛耜肂肆蕼覗貄釲鈶鈻飤飼饲駟騃驷倯凇娀崧嵩庺忪憽松枀枩柗梥檧淞濍硹菘鬆傱嵷怂悚愯慫楤竦耸聳駷宋訟誦讼诵送鎹頌颂餸凁嗖廀廋捜搜摉摗溲獀艘蒐蓃螋鄋醙鎪锼颼飕餿馊騪傁叜叟嗾擻櫢瞍籔薮藪嗽擞瘶囌櫯甦稣穌窣苏蘇蘓酥鯂俗傃僳嗉塐塑夙嫊宿愫愬憟梀榡樎樕橚殐泝洬涑溯溸潚潥玊珟璛碿簌粛粟素縤肃肅膆莤蔌藗觫訴謖诉谡趚蹜速遡遬鋉餗驌骕鱐鷫鹔狻痠酸匴祘笇筭算蒜倠哸夊浽滖濉熣芕荽荾虽雖鞖瓍綏绥遀隋随隨髄瀡膸髓亗埣嬘岁嵗旞檖歲歳澻煫燧璲睟砕碎祟禭穂穗穟繀繐繸襚誶譢谇賥遂邃鐆鐩隧韢孙孫搎槂狲猻荪蓀蕵薞飧飱损損榫笋筍箰簨鎨隼鶽傞唆嗍嗦娑挱挲摍桫梭睃簑簔縮缩羧莎莏蓑趖鮻乺唢嗩所暛溑獕琐琑瑣索褨鎍鎖鎻鏁锁溹蜶逤他塌她它榙溻牠祂褟趿鉈铊闧塔墖獭獺鮙鰨鳎傝嚃嚺崉挞搨撻榻橽毾沓涾澾濌狧禢粏誻譶踏蹋蹹躂躢遝遢錔闒闥闼阘鞜鞳侤囼孡胎儓台坮嬯抬擡旲檯炱炲箈籉臺苔菭薹跆邰颱駘骀鮐鲐冭太夳忲态態汏汰汱泰溙燤肽舦酞鈦钛啴嘽坍怹摊擹攤滩潬灘痑瘫癱舑貪贪倓坛埮墰墵壇壜婒弹弾彈惔憛昙曇榃橝檀潭燂痰罈罎藫覃談譚譠谈谭貚郯醈醰錟锬顃僋嗿坦忐憳憻暺毯璮菼袒襢醓鉭钽叹嘆探歎湠炭碳舕劏嘡汤湯羰薚蝪蹚鏜镗鞺鼞傏唐啺坣堂塘嵣搪棠榶樘橖溏漟煻瑭磄禟篖糃糖糛膅膛蓎螗螳赯踼鄌醣鎕闛隚餹饄鶶伖倘偒傥儻戃曭淌爣矘耥躺鎲钂镋摥烫燙趟鐋铴夲嫍幍弢慆掏搯槄涛滔濤瑫絛縚縧绦詜謟轁鞱韜韬飸饕匋咷啕桃洮淘祹綯绹萄蜪裪迯逃醄鋾陶鞀鞉饀駣騊鼗討讨套忑忒慝特脦蟘鋱铽熥膯鼟儯幐滕漛疼痋籐籘縢腾藤虅螣誊謄邆駦騰驣鰧霯剔擿梯踢銻锑鷈鷉偍厗啼嗁媞崹徲惿提渧漽瑅睼碮禔禵稊綈緹绨缇罤蕛褆謕趧蹄蹏醍鍗題题騠鮷鯷鳀鵜鶗鶙鷤鹈体挮躰軆骵體倜剃嚏嚔屉屜悌悐惕惖戻掦揥替朑歒殢涕瓋笹籊薙褅趯逖逷髰鬀鬄兲天婖添酟靔靝黇塡填屇恬搷沺湉璳甛甜田畋畑碵磌窴緂胋菾闐阗鴫鷆鷏倎唺忝悿晪殄淟琠痶睓腆舔覥觍賟錪餂掭瑱舚佻庣恌挑旫祧聎岧岹条條樤祒笤芀苕萔蓚蓨蜩调迢鋚鎥鞗髫鯈鰷鲦齠龆嬥宨晀朓窕窱脁誂眺粜糶絩覜趒跳怗聑萜貼贴僣帖蛈鉄銕鐡鐵铁驖呫飻餮厅厛听庁廰廳桯汀烃烴綎耓聴聼聽鞓亭停婷嵉庭廷楟榳渟筳聤莛葶蜓蝏諪邒閮霆鼮侹圢娗挺梃涏烶珽町甼脡艇誔鋌铤頲颋嗵樋炵痌絧蓪通仝佟僮勭同哃峂峒峝庝彤晍曈朣桐橦氃浵潼烔燑犝狪獞眮瞳砼秱穜童粡膧茼蚒詷赨酮鉖鉵銅铜餇鮦鲖捅桶筒筩統綂统恸慟憅痛衕偷偸婾媮緰鋀鍮亠头投頭骰妵敨斢紏蘣黈透凸堗宊嶀怢捸涋湥痜禿秃突葖鋵鵚鼵凃図图圖圗塗屠峹嵞庩廜徒悇捈揬梌涂潳瑹瘏稌筡腯荼蒤跿途酴鈯鍎馟駼鵌鶟鷋鷵吐唋土圡釷钍兎兔堍莵菟迌鵵汢圕湍煓猯貒剸团団團慱抟摶槫檲漙篿糰鏄鷒鷻墥畽疃彖湪褖推蓷藬尵弚橔穨蘈蹪隤頹頺頽颓魋俀僓腿蹆骽娧煺蛻蜕螁褪退駾吞呑噋旽暾朜涒焞囤坉屯忳臀臋芚蛌豘豚軘霕飩饨魨鲀黗氽乇仛侂咃咜托扡拕拖挩捝杔汑沰涶脫脱莌袥託讬飥饦馲魠鮵佗侻坨堶媠岮柁槖橐沱沲狏砣砤碢紽袉詑跎酡阤陀陁馱駄駝駞騨驒驝驮驼鮀鴕鸵鼉鼍鼧妥嫷庹彵椭楕橢鰖鵎唾嶞拓柝毤毻箨籜萚蘀跅劸哇嗗娲媧屲挖搲攨洼溛漥瓾畖穵窊窐窪蛙韈鼃娃佤咓瓦砙邷嗢聉腽膃袜襪韤呙咼喎歪竵外顡剜塆壪婠帵弯彎湾潫灣睕蜿豌丸刓完岏忨抏捖汍烷玩琓笂紈纨翫芄貦頑顽倇唍埦婉宛惋挽晚晥晩晼梚椀涴琬畹皖盌碗箢綩綰绾脘莞菀萖踠輓鋔万卍卐妧捥杤澫瞣脕腕萬薍蟃贃贎輐鋄錽鎫尣尩尪尫汪亡亾仼兦王莣蚟彺往徃惘暀枉棢瀇網网罒罓罔罖菵蛧蝄誷輞辋魍妄忘旺望朢迋偎危厃喴威媙崴嵔嶶巍微愄揋揻椳楲溦烓煨燰癓縅葨葳薇蜲蝛覣詴逶隇隈霺鰃鰄鳂唯喡囗囲围圍壝媁峗峞嵬帏帷幃惟桅欈沩洈涠湋溈潍潙潿濰為爲犩琟矀硙維维蓶覹违違鄬醀鍏闈闱韋韦鮠亹伟伪偉偽僞儰委娓寪尾屗崣嶉徫愇捤撱斖暐梶椲洧浘渨濻瀢炜煒猥玮瑋痏痿硊碨緯纬腲艉芛苇荱萎葦蒍蔿諉诿踓鍡隗韑韙韡韪頠颹骩骪骫鮪鲔为位卫叞味喂墛媦尉慰懀未渭煟熭犚猬畏緭罻胃苿菋蔚藯蘶蜼蝟螱衛衞褽謂讆讏谓躗躛軎轊鏏霨餧餵饖魏鮇鳚塭昷榅榲殟温溫瑥瘟豱輼轀辒鎾鞰饂鰛鰮鳁彣文炆珳瘒紋繧纹聞芠蚉蚊螡蟁閺閿闅闦闻阌雯馼駇魰鳼鴍鼤伆刎吻呅呡抆桽稳穏穩紊肳脗問妏揾搵汶渂璺莬问顐嗡翁聬螉鎓鶲鹟勜塕奣嵡攚暡滃瞈蓊瓮甕罋蕹齆倭唩挝涡涹渦猧窝窩莴萵蜗蝸踒婐婑我捰仴偓卧媉幄捾握斡枂楃沃渥濣焥瓁瞃硪肟腛臒臥齷龌乌剭呜嗚圬屋巫弙杇歍汙汚污洿烏窏箼螐誈誣诬邬鄔鎢钨鰞鴮吳吴吾呉墲娪峿无梧橆毋洖浯無珸璑祦芜茣莁蕪蜈蟱譕郚鋙铻鯃鵐鷡鹀鼯乄五仵伍侮倵儛午啎妩娒娬嫵庑廡忤怃憮捂摀武潕熓牾玝珷瑦甒瞴碔舞躌迕逜陚鵡鹉俉兀务務勿卼唔坞塢奦婺寤屼岉嵍嵨忢悞悟悮戊扤敄旿晤杌溩焐熃物痦矹窹粅芴蘁誤误鋈阢隖雺雾霚霧靰騖骛鶩鹜鼿齀俙傒僖兮凞卥厀吸唏唽嘻噏嚱夕奚娭嬆嬉屖嵠巇希徆徯忚怸恓息悉悕惁惜扱扸昔晞晰晳暿曦析桸榽樨橀欷歙氥汐浠淅渓溪潝烯焁焈焟焬煕熄熈熙熹熺熻燨爔牺犀犠犧狶琋瘜皙睎瞦矽硒磎礂稀穸窸粞糦緆繥羲翕翖肸肹膝舾莃菥蒠蜥螅螇蟋蠵裼西覡觹觽觿譆谿豀豨豯貕赥邜郗鄎酅醯釸錫鏭鐊鑴锡隵餏饎饻鯑鵗鸂鼷习喺媳嶍席椺槢檄漝習蒵蓆薂袭襲觋謵趘郋鎴隰霫飁騱騽驨鰼鳛喜囍壐屣徙憘憙枲橲歖洗漇玺璽矖禧縰葈葸蓰蟢諰謑蹝躧鈢鉨鉩鱚係匸卌呬墍屃屓屭忥怬恄慀戏戯戱戲椞欯潟澙熂犔盻磶禊稧系細綌縘繫细绤舃舄蕮虩衋覤赩趇郤釳闟阋隙隟霼餼饩鬩黖傄呷煆瞎虲虾蝦谺閕颬鰕侠俠匣埉峡峽敮暇柙炠烚狎狭狹珨瑕硖硤碬磍祫筪縖翈舝舺蕸赮轄辖遐鍜鎋陜陿霞騢魻鶷黠閜丅下乤吓圷夏夓懗梺疜睱罅諕鎼鏬仙仚佡僊僲先嘕奾嬐孅屳廯忺憸掀攕暹杴枮氙珗祆秈籼繊纎纖纤苮莶薟褼襳跹蹮躚酰銛銽鍁铦锨韯韱馦鮮鱻鲜鶱伭咁咸啣嗛妶娴娹婱嫌嫺嫻弦憪挦撏涎湺澖甉痫癇癎盷瞯礥稴絃胘舷藖蚿蛝衔衘誸諴賢贒贤輱醎銜鑦閑閒闲鷳鷴鷼鹇鹹麙冼尟尠崄嶮幰搟攇显櫶毨灦烍燹狝猃獫獮玁禒筅箲藓蘚蚬蜆譣赻跣銑鍌铣险険險韅顕顯僩僴县咞哯垷埳塪壏姭娊宪岘峴憲撊晛橌橺涀瀗献獻现現県睍粯糮絤綫線縣线缐羡羨腺臔臽苋莧誢豏鋧錎限陥陷霰餡馅麲鼸乡厢廂忀楿欀湘瓖相稥箱緗纕缃膷芗萫葙薌襄郷鄉鄊鄕鑲镶香驤骧鱜麘佭庠栙瓨祥絴翔詳详跭享亯响想晑蚃蠁銄響飨餉饗饟饷鮝鯗鱶鲞像勨向嚮姠嶑巷曏橡珦缿蟓衖襐象鐌項项鱌侾削呺哓嘐嘵嚣嚻囂婋宯宵庨彇憢揱撨枭枵梟櫹歊毊消潇瀟灱灲烋焇猇獢痚痟硝硣穘窙箫簘簫綃绡翛肖膮萧蕭藃虈虓蛸蟂蟏蟰蠨踃逍銷销霄颵驍骁髇髐魈鴞鴵鷍鸮崤殽洨淆訤誵郩小晓暁曉皛皢筱筿篠謏俲傚効咲哮啸嘋嘨嘯孝恔效敩斅斆校歗涍熽笑詨誟些娎揳楔歇猲蝎蠍偕劦勰协協嗋嚡垥奊孈峫恊愶拹挟挾携撷擕擷攜斜旪熁燲瑎絜綊緳縀缬翓胁脅脇脋膎蝢衺襭諧讗谐邪鞋鞵龤写冩寫藛血亵伳偞偰僁卨卸噧塮夑媟屑屟屧嶰廨徢懈暬械榍榭泄泻洩渫澥瀉瀣灺炧炨烲焎燮爕獬祄禼糏紲絏絬緤繲纈绁缷薢薤蟹蠏褉褻謝谢躞邂靾鞢韰齂齘齛齥俽噷噺妡嬜廞心忄忻惞新昕杺欣歆盺芯薪訢辛邤鈊鋅鑫锌馨馫枔襑鐔镡伈伩信囟孞炘焮脪舋衅訫軐釁阠顖馸垶惺星曐煋猩瑆皨箵篂腥興觪觲謃騂骍鮏鯹侀刑哘型娙形洐滎硎荥蛵行邢郉鈃鉶銒鋞钘铏陉陘餳饧擤睲醒倖兴姓婞嬹幸性悻杏涬緈臖荇莕葕兄兇凶匂匈哅忷恟汹洶胷胸芎訩詾讻賯熊熋雄焸焽夐敻詗诇休俢修咻庥樇烌羞脙脩臹貅銝鎀鏅飍饈馐髤髹鮴鱃鵂鸺苬朽滫潃糔嗅嚊岫峀溴珛琇璓秀綉繍繡绣螑袖褎褏銹鏥鏽锈齅偦吁嘘噓圩墟媭嬃戌揟旴楈欨欻歔歘燸疞盱砉綇縃胥蕦虗虚虛蝑裇訏許諝譃谞鑐需須须顼驉鬚魆魖俆冔徐禑蒣呴喣姁暊栩湑珝盨稰糈詡諿许诩鄦醑伵侐勖勗卹叙垿壻婿序怴恤慉敍敘旭昫晇朂槒欰殈汿沀洫溆漵潊烅烼煦獝珬盢瞁稸絮続緒緖續绪续聓聟芧蓄蓿藇藚訹賉酗銊頊鱮儇吅喧塇媗宣弲愃愋懁揎昍晅暄梋煊瑄睻矎禤箮翧翾萱萲蓒蕿藼蘐蝖蠉諠諼譞谖軒轩鋗鍹鞙駽鰚嫙悬懸旋暶檈漩玄玹琁璇璿痃蜁咺暅烜癣癬选選怰昡楥楦泫渲炫琄眩眴碹絢縼繏绚蔙衒袨贙鉉鏇铉镟颴疶蒆薛辥辪靴鞾乴壆学學峃嶨斈泶澩燢穴茓袕觷踅鷽鸴樰膤艝轌雪鱈鳕吷坹岤桖瀥狘瞲謔谑趐勋勛勲勳嚑坃埙塤壎壦曛焄熏燻爋獯矄纁臐薫薰蘍醺偱噚姰寻尋峋巡廵循恂揗攳旬杊栒桪樳毥洵浔潯灥燅燖珣璕畃紃荀蟳詢询郇鄩駨鱏鱘鲟伨侚卂噀奞巺巽徇愻殉殾汛潠狥稄蕈訊訓訙训讯迅迿逊遜鑂顨馴驯丫压吖呀圧垭壓孲庘押枒桠椏錏鐚铔鴉鴨鵶鸦鸭伢厑厓堐岈崕崖涯漄牙猚琊睚笌芽蚜衙齖厊哑唖啞庌疨痖瘂蕥雅亚亜亞俹冴劜圔圠埡娅婭挜掗揠氩氬犽猰玡砑稏窫聐襾覀訝讶軋轧迓齾傿剦嫣嬮崦嶖恹懕懨樮歅淊淹渰湮漹烟焉焑煙珚硽篶胭臙菸鄢醃閹阉黫严厳啱喦嚴埏塩壛壧妍姸娫娮岩嵒嵓巌巖巗延揅昖楌檐櫩欕沿炎炏狿琂盐研硏碞礹筵簷綖莚蔅虤蜒言訁訮詽讠郔閆閻闫阎顏顔颜鹽麣乵俨偃儼兖兗剡匽厣厴噞夵奄孍嵃巘巚弇愝戭扊抁掩揜曮棪椼檿沇渷演琰甗眼縯罨萒蝘衍裺褗躽遃郾酓隒顩魇魘鰋鶠黡黤黬黭黶鼴鼹齴龑偐厌厭咽唁喭嚈嚥囐堰墕妟姲嬊嬿宴彥彦敥晏暥曕曣椻溎滟灎灔灧灩烻焔焰焱熖燄燕爓牪猒砚硯艳艶艷覎觃觾諺讌讞谚谳豓豔贋贗赝軅酀酽醶醼釅隁雁餍饜騐験騴驗驠验鬳鳫鴈鴳鷃鷰齞央姎抰殃泱眏秧胦鉠鍈雵鞅鴦鸯佯劷垟崵崸徉扬揚敭旸昜暘杨楊氜洋炀烊煬珜疡瘍眻羊羏蛘諹輰鍚钖阦阳陽霷颺飏鰑鴹鸉仰佒傟养卬咉坱岟慃懩攁柍楧氧氱瀁炴痒癢礢紻蝆軮飬養駚怏恙样様樣漾羕詇吆喓夭妖幺楆殀祅腰葽訞邀鴁鴢倄傜嗂垚堯姚媱尧尭峣嶢嶤徭愮揺搖摇摿暚榣滧烑爻猺珧瑤瑶磘窑窯窰繇肴蘨謠謡谣軺轺遙遥邎鎐顤颻飖餆餚鰩鱙鳐仸偠咬婹宎岆崾抭杳枖柼榚溔狕眑窅窈舀苭蓔闄騕鷕齩曜熎燿獟矅穾窔筄纅耀艞药葯薬藥袎要覞詏讑靿鷂鹞鼼倻吔噎擨暍椰歋潱蠮捓揶爷爺瑘耶釾鋣鎁铘也冶嘢埜壄漜野业亱僷叶墷夜嶪嶫抴捙掖擛擪擫晔曄曅曗曳曵枼枽業殗洂液澲烨煠燁爗璍皣瞱瞸礏腋葉謁谒邺鄴鍱鎑鐷靥靨頁页餣饁馌驜鵺鸈亪一乊伊依医吚咿噫壱壹夁嫛嬄弌悘揖撎檹毉洢渏漪猗瑿畩祎禕稦繄蛜衣衤譩辷郼醫銥铱鷖鹥黟黳乁仪侇儀冝匜咦圯夷姨媐宐宜宧寲峓嶬嶷巸彛彜彝彞怡恞扅拸暆杝柂栘桋椬椸沂沶洟熪狋珆瓵疑痍眙移簃籎羠胰荑萓蛦螔袘觺詒誃謻讉诒貽贻跠迻遗遺鏔頉頤頥顊颐飴饴鮧鴺乙乛以佁倚偯嬟崺已庡扆攺敼旑旖椅檥矣礒笖舣艤苡苢蚁螘蟻裿輢轙迆迤迱逘酏釔鈘鉯钇顗鳦齮乂义亄亦亿仡伇伿佚佾俋億兿刈劓劮勚勩匇呓呭呹唈嗌囈圛坄垼埶埸墿奕嫕嬑寱屹峄嶧帟帠幆廙异弈弋役忆忔怈怿悒悥意憶懌懿抑挹敡斁易晹曀曎杙枍枻栧棭榏槸檍欭歝殔殪殹毅泆浂浥浳湙溢潩澺瀷炈焲熠熤熼燚燡燱獈玴異疫痬瘗瘞瘱癔益睪瞖秇穓竩篒縊繶繹绎缢羛義羿翊翌翳翼耴肄肊膉臆艗艺芅苅萟蓺薏藙藝蘙虉蛡蜴螠衪袣裔裛褹襼訲訳詍詣誼譯議讛议译诣谊豙豛豷貖貤贀跇軼轶逸邑鄓醳醷釴鈠鎰鐿镒镱阣隿霬饐駅驛驿骮鮨鯣鶂鶃鶍鷁鷊鷧鷾鸃鹝鹢黓齸弬侌凐喑噾囙因垔堙姻婣愔慇栶殷氤洇溵濦瘖磤禋秵筃絪緸茵荫蒑蔭裀諲銦铟闉阥阴陰陻隂霒霠鞇音韾駰骃齗乑冘吟噖嚚圁垠夤婬寅峾崟崯斦檭殥泿淫滛烎犾狺珢璌碒荶蔩蟫訔訚訡誾鄞鈝銀银霪鷣齦龂龈吲尹嶾廴引朄檃檼櫽淾濥瘾癮粌蘟蚓螾讔赺趛輑鈏隐隠隱靷飮飲饮印垽堷廕慭憖憗懚洕湚猌癊窨胤茚酳鮣偀嘤噟嚶婴媖嫈嬰孆孾应応愥應撄攖朠桜樱櫻渶瀴煐珱瑛璎瓔甇甖碤礯緓纓绬缨罂罃罌膺英莺蘡蝧蠳褮譍譻賏軈鑍锳霙韺鴬鶑鶧鶯鷪鷹鸎鸚鹦鹰僌営塋嬴巆攍楹櫿溁溋滢潆濙濚濴瀅瀛瀠瀯灐灜熒營瑩盁盈禜籝籯縈茔荧莹萤营萦萾蓥藀蛍蝇蝿螢蠅覮謍贏赢迎鎣巊廮影摬梬浧潁瘿癭矨穎郢鐛頴颍颕颖媵映暎硬膡鱦哟唷喲佣傭嗈噰墉壅嫞庸廱慵拥擁滽澭灉牅痈癕癰臃邕郺鄘鏞镛雍雝饔鱅鳙鷛喁顒颙鰫俑勇勈咏埇塎嵱彮怺恿悀惥愑愹慂柡栐永泳涌湧甬硧蛹詠踊踴鯒鲬用砽苚蒏醟优優呦嚘峳幽忧怮悠憂懮攸櫌泑浟滺瀀纋羪耰逌鄾麀偤尢尤庮怞怣楢沋油游犹猶猷由甴疣秞肬莜莸蕕蚰蝣訧輏輶逰遊邮郵鈾铀駀魷鮋鱿鲉丣卣友有栯梄槱湵牖牗禉羑聈苃莠蜏酉銪铕黝亴佑佦侑又右哊唀囿姷孧宥峟幼柚櫾牰狖祐蚴誘诱貁迶酭釉鼬唹扜扝淤瘀盓穻箊紆纡込迂迃陓乻予于亐伃余俞兪堣堬妤娛娯娱媀嬩崳嵎嵛愉愚扵揄於旟杅桙楡楰榆欤歈歟歶渔渝湡漁澞牏狳玗玙瑜璵盂睮禺窬竽籅羭腴臾舁舆艅茰萮萸蕍蘛虞虶蝓螸衧褕覦觎諛謣谀踰輿轝逾邘酑鍝隃隅雓雩餘馀騟骬髃魚魣鮽鯲鰅鱼鷠鸆齵与伛俁俣偊傴匬噳圄圉宇寙屿嶼庾懙挧敔斔斞楀瑀瘐祤禹穥窳羽與萭語语貐鄅雨頨麌齬龉俼僪儥喅喩喻圫域堉妪嫗寓峪嶎庽彧御忬悆惐愈慾戫昱棛棜棫櫲欎欝欥欲毓浴淢淯滪潏澦灪焴煜燏燠爩狱獄玉琙瘉癒矞砡硢硲礇礖礜禦秗稢稶篽籞籲粖緎罭聿肀育艈芋芌茟蒮蓣蓹蕷薁蘌蜟蜮袬裕誉諭譽谕豫軉輍逳遇遹郁醧鈺銉鋊錥鐭钰閾阈雤霱預预飫饇饫馭驈驭鬰鬱鬻魊鱊鳿鴥鴧鴪鵒鷸鸒鹆鹬冤剈囦嬽寃悁惌棩淵渁渆渊渕灁眢肙葾蒬蜎蜵裷駌鳶鴛鵷鸢鸳鹓鼘鼝元円原厡厵员員园圆圎園圓垣塬媴嫄援杬榞榬橼櫞沅湲源溒爰猨猿笎緣縁缘羱芫茒蒝薗蚖蝝蝯螈袁褤謜貟贠轅辕邍邧酛鈨鎱騵魭鶢鶰黿鼋盶薳远逺遠鋺傆噮垸夗妴媛怨愿掾瑗禐苑衏裫褑院願啘曰曱矱箹約约哕噦刖妜嬳岄岳嶽恱悅悦戉抈捳月樾泧瀹爚玥礿禴篗籆籥籰粤粵蘥蚎蚏越跀跃躍軏鈅鉞鑰钥钺閱閲阅鸑鸙黦龠龥奫晕暈氲氳煴熅蒀蒕蝹贇赟馧云伝勻匀囩妘愪抣昀橒沄涢溳澐熉畇眃秐筠筼篔紜縜纭耘耺芸蒷蕓郧鄖鋆雲允喗夽抎殒殞狁磒荺賱鈗阭陨隕霣馻齫齳傊孕恽惲愠慍枟熨緼縕缊腪蕰蕴薀藴蘊褞运運郓鄆酝醖醞韗韞韫韵韻餫匝咂帀扎拶桚沞臜臢迊鉔魳囃杂沯砸襍雑雜雥韴咋哉栽渽溨災灾烖甾畠睵賳宰崽傤儎再在扗洅縡載载酨兂橵簪簮糌鐕鐟鵤偺咱喒儧儹噆寁揝撍攅攒攢昝趱趲囋暂暫濽灒瓉瓒瓚禶襸讃讚賛贊赞蹔鄼錾鏨饡匨牂羘臧賍賘贓贜赃髒駔驵塟奘弉脏臓臟葬蔵銺傮糟蹧遭醩凿鑿早枣栆棗澡璅璪薻藻蚤唕唣喿噪慥梍灶煰燥皁皂竃竈簉艁譟趮躁造则則啧啫嘖嫧帻幘択择擇樍歵沢泎泽溭滜澤皟瞔矠礋箦簀舴蔶蠌襗諎謮責賾责赜迮鸅齚齰仄崱庂捑昃昗汄戝蠈賊贼鰂鱡鲗怎譖谮増增憎橧璔矰磳繒缯罾譄鄫鱛囎熷甑贈赠鋥锃鬵偧劄哳喳抯挓揸摣柤楂樝渣皶皻紥紮觰譇齄齇札牐箚耫蚻譗鍘铡閘闸霅厏拃眨砟鮓鮺鲊鲝乍吒咤宱搾栅榨溠灹炸痄蚱詐诈醡夈捚摘斋斎榸粂齋宅檡窄鉙债債寨瘵砦噡岾嶦惉旃旜枬栴毡氈氊沾瞻薝蛅詀詹譫谵趈邅閚霑飦饘驙魙鱣鳣鸇鹯讝嫸展崭嶃嶄搌斩斬榐橏琖盏盞輾辗醆颭飐佔偡僝占嶘战戦戰栈桟棧湛站綻绽菚蘸虥虦覱譧轏驏傽嫜张張彰慞暲樟漳獐璋章粻蔁蟑遧鄣鏱餦騿鱆麞仉幥掌涨漲礃丈仗墇嶂帐帳幛扙杖涱痮瘬瘴瞕粀胀脹賬账障佋妱巶招昭皽釗鉊鍣钊駋找沼爪爫瑵兆召垗旐曌枛棹櫂炤照燳狣瞾笊箌罀罩羄肁肇肈詔诏赵趙鮡嗻嫬遮厇哲啠喆嚞埑悊折摺晢晣歽矺砓磔籷粍虴蛰蜇蟄袩詟謫謺讁讋谪輒輙轍辄辙銸鮿乽者褶襵赭踷鍺锗柘樜浙淛蔗蟅这這鷓鹧侦偵嫃寊帧帪幀搸斟桢椹楨榛樼殝浈湞溱潧澵獉珍珎瑧甄眞真砧碪祯禎禛箴籈胗臻葴蒖蓁薽貞贞轃遉酙針鉁錱鍼针鱵姫屒弫抮昣枕畛疹眕稹紾縝縥缜聄萙袗裖覙診诊軫轸辴駗鬒黰侲圳塦挋振揕朕栚甽眹紖絼纼誫賑赈鋴鎭鎮镇阵陣震鴆鸩争佂凧埩姃媜峥崝崢征徰徴徵怔掙揁炡烝爭狰猙癥眐睁睜筝箏篜糽聇脀蒸踭鉦錚鏳钲铮鬇愸抍拯掟撜整晸氶塣幁挣政正症証諍證证诤郑鄭靕鴊之倁卮吱巵憄搘支枝栀栺梔椥榰汁汥泜疷知祗祬秓稙綕織织肢胑胝脂臸芝蘵蜘衼隻馶鳷鴲鼅侄値值埴執妷姪嬂慹戠执摭植樴殖淔漐潪犆瓡直禃絷縶聀职職膱蟙跖踯蹠躑軄釞馽凪劧只咫址坁坧墌夂帋恉扺抧指旨枳止汦沚洔淽疻砋祇祉秖紙纸芷茋藢衹襧訨趾軹轵酯阯黹乿俧偫傂儨制剬劕厔垁墆娡寘峙崻帙帜幟庢庤廌彘徏徝志忮懥懫扻挃挚掷搱摨摯擲擳旘晊智柣栉桎梽櫍櫛歭治洷滍滞滯潌瀄炙熫狾猘璏瓆畤疐痓痔痣瘈礩祑秩秷稚稺穉窒筫紩緻置翐膣至致芖蛭袟袠製覟觗觯觶誌豑豒豸貭質贄质贽跱踬躓輊轾迣郅銍鋕鑕铚锧陟隲雉駤騭騺驇骘鯯鴙鷙鸷中伀刣妐幒彸忠柊汷泈炂盅籦終终舯蔠蜙螤螽衳衷蹱鈡銿鍾鐘钟锺鴤鼨冢喠塚尰徸歱煄瘇种種肿腫踵仲众偅堹妕媑狆眾祌筗茽蚛衆衶諥重侜周啁喌嚋婤州徟洲淍炿烐珘盩矪粥舟謅譸诌诪賙赒輈輖辀週郮銂霌駲騆鵃鸼妯碡軸轴帚晭疛睭箒肘菷鯞伷僽冑呪咒咮噣宙昼晝甃皱皺籀籒籕粙紂縐纣绉胄荮葤詋酎駎驟骤侏朱株槠橥櫧櫫洙潴瀦猪珠硃秼絑茱蕏藸蛛蝫蠩袾誅諸诛诸豬跦邾銖铢駯鮢鯺鴸鼄劚孎斸曯欘灟炢烛燭爥瘃窋竹竺笁笜篴舳茿蓫蠋蠾躅逐逫钃鱁丶主劯嘱囑宔帾拄渚濐煑煮燝瞩矚罜褚詝陼鸀麈乼伫佇住助坾墸壴嵀拀杼柱柷樦殶注炷疰眝砫祝祩竚筑筯箸築篫簗紵紸纻羜翥苎苧莇著蛀註貯贮跓軴迬鉒鋳鑄铸飳馵駐驻麆抓撾檛簻膼髽跩拽专叀塼嫥専專瑼甎砖磗磚膞蟤諯鄟顓颛鱄孨竱轉转僎啭囀堟撰灷瑑篆篹籑縳腞蒃襈譔賺赚転饌馔妆妝娤庄庒桩梉樁湷粧糚荘莊装裝壮壯壵撞焋状狀椎追錐锥隹騅骓鵻沝坠墜娷惴甀畷硾礈笍綴縋缀缒腏膇諈贅赘醊錣鑆啍宒窀肫衠諄谆迍准凖埻準綧稕訰倬拙捉桌梲棁棳槕涿炪焯穛穱窧鐯丵劅卓叕啄啅圴妰娺彴撯擆擢斀斫斮斱斲斵晫椓櫡汋浊浞濁濯灂灼烵犳琢琸着硺禚窡篧籗籱罬茁蠗蠿諁諑謶诼酌鋜鐲镯鵫鷟兹呲咨嗞姕姿孖孜孳孶崰嵫栥椔淄湽滋澬玆禌秶稵粢紎緇緕纃缁茊茲菑葘觜訾諮谘貲資赀资赼趑趦輜輺辎鄑鈭錙鍿鎡锱镃頾頿髭鯔鰦鲻鶅鼒齍齜龇蓻仔吇呰啙姉姊子杍梓榟橴滓矷秄秭笫籽紫耔胏茈虸訿釨倳剚字恣渍漬牸眥眦胔胾自芓茡荢嗭倧堫宗嵏嵕惾朡棕椶熧猣磫稯綜緃緵繌综翪腙葼蝬豵踨踪蹤鍐鑁騌騣骔鬃鬉鬷鯮鯼倊偬傯嵸总惣捴揔搃摠焧燪総緫縂總蓗昮猔疭瘲碂粽糉糭縦縱纵掫棷棸箃緅菆諏诹邹郰鄒鄹陬騶驺鯫鲰黀齱齺走赱鯐奏揍租菹葅蒩卆卒哫崒崪族椊箤足踤鏃镞俎唨爼珇祖組组詛诅鎺阻靻劗躜躦鉆鑚鑽钻籫繤纂纉纘缵攥厜嗺樶纗蟕嘴噿嶊璻冣嶵晬最栬槜檇檌祽稡絊罪蕞辠酔酻醉鋷錊噂墫尊嶟樽繜罇遵鐏鱒鳟鶎鷷僔撙譐捘銌嘬穝捽昨秨稓笮筰苲莋鈼佐左繓作侳做唑坐岝岞座怍柞祚糳胙葃葄蓙袏酢阼飵咗龦龧龨龩龪龫龬龭龮龯龰龱龲龳龴龵龶龷龸龹龺龻龼龽龾龿鿀鿁鿂鿃鿄鿅鿆鿇鿈鿉鿊鿋鿌鿍鿎鿏鿐";BI.CODE_INDEX={};for(var t=0;t<e.length;t++)BI.CODE_INDEX[e[t]]=t}()},function(module,exports){(function(document){var F=(item=function(e){return this[e]},function(e){var t=e.files||[e];return t.item||(t.item=item),t}),item,event={add:document.addEventListener?function(e,t,n){return e.addEventListener(t,n,!1),this}:function(e,t,n){return e.attachEvent("on"+t,n),this},del:document.removeEventListener?function(e,t,n){return e.removeEventListener(t,n,!1),this}:function(e,t,n){return e.detachEvent("on"+t,n),this},stop:function(e){return e?(e.stopPropagation?e.stopPropagation():e.cancelBubble=!0,e.preventDefault?e.preventDefault():e.returnValue=!1):self.event&&(event.returnValue=!(event.cancelBubble=!0)),!1}},sendFile=function(toString){var multipart=function(e,t,n){return"--".concat(e,CRLF,'Content-Disposition: form-data; name="',t,'"; filename="',_global.encodeURIComponent(n.fileName),'"',CRLF,"Content-Type: application/octet-stream",CRLF,CRLF,n.getAsBinary(),CRLF,"--",e,"--",CRLF)},isFunction=function(e){return"[object Function]"===toString.call(e)},split="onabort.onerror.onloadstart.onprogress".split("."),length=split.length,CRLF="\r\n",xhr=this.XMLHttpRequest?new XMLHttpRequest:new ActiveXObject("Microsoft.XMLHTTP"),sendFile;return sendFile=xhr.upload||xhr.sendAsBinary?function(e,t,n,i){var r=e.current;if(!(-1<t&&t<e.file.fileSize)){for(var a=new XMLHttpRequest,o=a.upload||{addEventListener:function(e,t){this["on"+e]=t}},s=0;s<length;s++)o.addEventListener(split[s].substring(2),function(t){return function(n){isFunction(e[t])&&e[t](n,a)}}(split[s]),!1);if(o.addEventListener("load",(function(t){!1===e.onreadystatechange?isFunction(e.onload)&&e.onload(t,a):setTimeout((function(){4===a.readyState?isFunction(e.onload)&&e.onload(t,a):setTimeout(arguments.callee,15)}),15)}),!1),a.open("post",BI.appendQuery(e.url,{filename:_global.encodeURIComponent(e.file.fileName)}),!0),a.upload)a.onreadystatechange=function(){switch(a.readyState){case 4:var t=BI.jsonDecode(a.responseText);-1!=e.file.type.indexOf("image")&&(t.attach_type="image"),t.filename=e.file.fileName,1==e.maxLength?e.attach_array[0]=t:e.attach_array[r]=t}},isFunction(o.onloadstart)&&o.onloadstart();else{var l={loaded:0,total:e.file.fileSize||e.file.size,simulation:!0};l.interval=setInterval((function(){l.loaded+=256,l.total<=l.loaded&&(l.loaded=l.total),o.onprogress(l)}),100),a.onabort=function(){o.onabort({})},a.onerror=function(){o.onerror({})},a.onreadystatechange=function(){switch(a.readyState){case 2:case 3:l.total<=l.loaded&&(l.loaded=l.total),o.onprogress(l);break;case 4:if(clearInterval(l.interval),l.interval=0,l.loaded=l.total,o.onprogress(l),199<a.status&&a.status<400){o.onload({});var t=BI.jsonDecode(a.responseText);t.filename=e.file.fileName,-1!=e.file.type.indexOf("image")&&(t.attach_type="image"),e.attach_array[r]=t}else o.onerror({})}},o.onloadstart(l)}var u="AjaxUploadBoundary"+(new Date).getTime();if(a.setRequestHeader("Content-Type","multipart/form-data; boundary="+u),e.file.getAsBinary)a[a.sendAsBinary?"sendAsBinary":"send"](multipart(u,e.name,e.file));else{a.setRequestHeader("Content-Type","multipart/form-data");var c=new FormData;c.append("FileData",e.file),a.send(c)}return e}isFunction(e.onerror)&&e.onerror()}:function(handler,maxSize,width,height){var current=handler.current,url=handler.url.concat(-1===handler.url.indexOf("?")?"?":"&","AjaxUploadFrame=true"),rpe={loaded:1,total:100,simulation:!0,interval:setInterval((function(){rpe.loaded<rpe.total&&++rpe.loaded,isFunction(handler.onprogress)&&handler.onprogress(rpe,{})}),100)},onload=function(){iframe.onreadystatechange=iframe.onload=iframe.onerror=null,form.parentNode.removeChild(form),form=null,clearInterval(rpe.interval);try{var e=(iframe.contentWindow.document||iframe.contentWindow.contentDocument).body.innerHTML,t=BI.jsonDecode(e);-1!=handler.file.type.indexOf("image")&&(t.attach_type="image");try{t.filename=_global.decodeURIComponent(handler.file.fileName)}catch(n){t.filename=handler.file.fileName}1==handler.maxLength?handler.attach_array[0]=t:handler.attach_array[current]=t}catch(n){isFunction(handler.onerror)&&handler.onerror(rpe,event||_global.event)}isFunction(handler.onload)&&handler.onload(rpe,{responseText:e})},target=["AjaxUpload",(new Date).getTime(),String(Math.random()).substring(2)].join("_");try{var form=document.createElement('<form enctype="multipart/form-data"></form>'),iframe=handler.iframe||(handler.iframe=document.createElement('<iframe id="'+target+'" name="'+target+'" src="'+url+'"></iframe>'))}catch(e){var form=document.createElement("form"),iframe=handler.iframe||(handler.iframe=document.createElement("iframe"));form.setAttribute("enctype","multipart/form-data"),iframe.setAttribute("name",iframe.id=target),iframe.setAttribute("src",url)}with(iframe.style.position="absolute",iframe.style.left=iframe.style.top="-10000px",iframe.onload=onload,iframe.onerror=function(e){isFunction(handler.onerror)&&handler.onerror(rpe,e||_global.event)},iframe.onreadystatechange=function(){/loaded|complete/i.test(iframe.readyState)?onload():isFunction(handler.onloadprogress)&&(rpe.loaded<rpe.total&&++rpe.loaded,handler.onloadprogress(rpe,{readyState:{loading:2,interactive:3,loaded:4,complete:4}[iframe.readyState]||1}))},form.setAttribute("action",handler.url+"&filename="+_global.encodeURIComponent(handler.file.fileName)),form.setAttribute("target",iframe.id),form.setAttribute("method","post"),form.appendChild(handler.file),form.style.display="none",isFunction(handler.onloadstart)&&handler.onloadstart(rpe,{}),document.body||document.documentElement)appendChild(iframe),appendChild(form),form.submit();return handler},xhr=null,sendFile}(Object.prototype.toString),sendFiles=function(e,t,n,i){var r=e.files.length,a=e.onload,o=e.onloadstart;for(e.current=0,e.total=0,e.sent=0;e.current<r;)e.total+=e.files[e.current].fileSize||e.files[e.current].size,e.current++;return e.current=0,r&&-1!==e.files[0].fileSize?(e.file=e.files[e.current],sendFile(e,t,n,i).onload=function(s,l){e.onloadstart=null,e.sent+=e.files[e.current].fileSize||e.files[e.current].size,++e.current<r?(e.file=e.files[e.current],sendFile(e,t,n,i).onload=arguments.callee):a&&(e.onloadstart=o,e.onload=a,e.onload(s,l))}):r&&(e.total=100*r,e.file=e.files[e.current],sendFile(e,t,n,i).onload=function(s,l){var u=arguments.callee;e.onloadstart=null,e.sent+=100,++e.current<r?(/\b(chrome|safari)\b/i.test(navigator.userAgent)&&(e.iframe.parentNode.removeChild(e.iframe),e.iframe=null),setTimeout((function(){e.file=e.files[e.current],sendFile(e,t,n,i).onload=u}),15)):a&&setTimeout((function(){e.iframe.parentNode.removeChild(e.iframe),e.iframe=null,e.onloadstart=o,e.onload=a,e.onload(s,l)}),15)}),e},r1=/\.([^.]+)$/,r2=/\/([^/]+)$/,fileTypeValidate=function(e,t){if(!t)return!0;var n=t.split(",");return n[0]===t&&(n=(t+"").split(";")),BI.some(n,(function(t,n){var i;return(i=n.match(r1))?e.toLowerCase().indexOf(i[1])>-1:(i=n.match(r2))?"*"===i[1]||e.toLowerCase().indexOf(i[1])>-1:void 0}))};BI.File=BI.inherit(BI.Widget,{_defaultConfig:function(){var e=BI.File.superclass._defaultConfig.apply(this,arguments);return BI.extend(e,{baseCls:(e.baseCls||"")+" bi-file display-block",tagName:"input",attributes:{type:"file"},name:"",url:"",multiple:!0,accept:"",maxSize:-1,maxLength:-1})},_init:function(){var e=this.options;BI.File.superclass._init.apply(this,arguments),!0===e.multiple&&this.element.attr("multiple","multiple"),this.element.attr("name",e.name||this.getName()),this.element.attr("title",e.title||""),this.element.attr("accept",e.accept)},created:function(){var e=this,t=this.options,n=this.wrap=this._wrap(this.element[0],t.maxSize);n.onloadstart=function(t,n){e.fireEvent(BI.File.EVENT_UPLOADSTART,arguments)},n.onprogress=function(t,n){-1!==this.file.fileSize&&t.simulation,e.fireEvent(BI.File.EVENT_PROGRESS,{file:this.file,total:t.total,loaded:t.loaded,simulation:t.simulation})},n.onerror=function(){e.fireEvent(BI.File.EVENT_ERROR)},n.onload=function(t,i){var r=this;setTimeout((function(){if(r.clean(),r.hide(),200>i.status||i.status>399)return BI.Msg.toast(BI.i18nText("BI-Upload_File_Error"),{level:"error"}),void e.fireEvent(BI.File.EVENT_ERROR);!BI.some(n.attach_array,(function(t,n){if(n.errorCode)return BI.Msg.toast(BI.i18nText(n.errorMsg),{level:"error"}),e.fireEvent(BI.File.EVENT_ERROR,n),!0}))&&e.fireEvent(BI.File.EVENT_UPLOADED)}),1e3)},n.url=t.url,n.fileType=t.accept,n.attach_array=[],n.attach_names=[],n.attachNum=0},_events:function(e){var t=this,n=this.options;return event.add(e.dom.input,"change",(function(){event.del(e.dom.input,"change",arguments.callee);var i=e.dom.input.cloneNode(!0),r=F(e.dom.input);if(-1!==n.maxLength&&n.maxLength<r.length)t.fireEvent(BI.File.EVENT_ERROR,{errorType:2});else for(var a=0;a<r.length;a++){var o=r.item(a),s=o.value||o.name,l=o.fileName||(o.fileName=s.split("\\").pop()),u=(-1!==l.indexOf(".")&&l.split(".").pop().toLowerCase(),o.fileSize||o.size),c=fileTypeValidate(l,e.fileType);c?-1!==e.maxSize&&u&&e.maxSize<u?(BI.Msg.toast(BI.i18nText("BI-Upload_File_Size_Error"),{level:"error"}),t.fireEvent(BI.File.EVENT_ERROR,{errorType:1,file:o})):e.files.unshift(o):(BI.Msg.toast(BI.i18nText("BI-Upload_File_Type_Error"),{level:"error"}),t.fireEvent(BI.File.EVENT_ERROR,{errorType:0,file:o}))}e.files.length>0&&t.fireEvent(BI.File.EVENT_CHANGE,{files:e.files}),i.value="",e.dom.input.parentNode.replaceChild(i,e.dom.input),e.dom.input=i,event.add(e.dom.input,"change",arguments.callee)})),e},_wrap:function(){var e=this.options,t=this.element[0];return!0===e.multiple&&this.element.attr("multiple","multiple"),t.value="",this._events({dom:{input:t,disabled:!1},name:t.name,maxSize:e.maxSize?e.maxSize>>0:-1,maxLength:e.maxLength,files:[],clean:function(){this.files=[]},upload:function(e){if(e)for(var t in e)this[t]=e[t];return sendFiles(this,this.maxSize),this},hide:function(){this.dom.disabled&&(this.dom.disabled=!1,this.dom.input.removeAttribute("disabled"))},show:function(e,t,n,i){this.dom.disabled||(this.dom.disabled=!0,this.dom.input.setAttribute("disabled","disabled"))}})},setMaxFileLength:function(e){this.options.maxLength=e,this.wrap&&(this.wrap.maxLength=e)},select:function(){this.wrap&&BI.Widget._renderEngine.createElement(this.wrap.dom.input).click()},upload:function(e){this.wrap&&this.wrap.upload(e)},getValue:function(){return this.wrap?this.wrap.attach_array:[]},reset:function(){this.wrap&&(this.wrap.attach_array=[],this.wrap.attach_names=[],this.wrap.attachNum=0)},_setEnable:function(e){BI.File.superclass._setEnable.apply(this,arguments),!0===e?this.element.attr("disabled","disabled"):this.element.removeAttr("disabled")}}),BI.File.EVENT_CHANGE="EVENT_CHANGE",BI.File.EVENT_UPLOADSTART="EVENT_UPLOADSTART",BI.File.EVENT_ERROR="EVENT_ERROR",BI.File.EVENT_PROGRESS="EVENT_PROGRESS",BI.File.EVENT_UPLOADED="EVENT_UPLOADED",BI.shortcut("bi.file",BI.File)})(_global.document||{})},function(e,t){BI.TreeView=BI.inherit(BI.Pane,{_defaultConfig:function(){return BI.extend(BI.TreeView.superclass._defaultConfig.apply(this,arguments),{_baseCls:"bi-tree",paras:{selectedValues:{}},itemsCreator:BI.emptyFn,showLine:!0})},_init:function(){BI.TreeView.superclass._init.apply(this,arguments);var e=this.options;this._stop=!1,this._createTree(),this.tip=BI.createWidget({type:"bi.loading_bar",invisible:!0,handler:BI.bind(this._loadMore,this)}),BI.createWidget({type:"bi.vertical",scrollable:!0,scrolly:!1,element:this,items:[this.tip]}),BI.isNotNull(e.value)&&this.setSelectedValue(e.value),BI.isIE9Below&&BI.isIE9Below()&&this.element.addClass("hack")},_createTree:function(){this.id="bi-tree"+BI.UUID(),this.nodes&&this.nodes.destroy(),this.tree&&this.tree.destroy(),this.tree=BI.createWidget({type:"bi.layout",element:"<ul id='"+this.id+"' class='ztree'></ul>"}),BI.createWidget({type:"bi.default",element:this.element,items:[this.tree]})},_selectTreeNode:function(e,t){this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.CLICK,t,this),this.fireEvent(BI.TreeView.EVENT_CHANGE,t,this)},_configSetting:function(){var e=this.options.paras,t=this,n=this.options,i={async:{enable:!0,url:function(e,n){var i=t._getParentValues(n);return n.times=n.times||1,"&id="+n.id+"&times="+n.times+++"&parentValues= "+_global.encodeURIComponent(BI.jsonEncode(i))+"&checkState="+_global.encodeURIComponent(BI.jsonEncode(n.getCheckStatus()))},autoParam:["id","name"],otherParam:BI.cjkEncodeDO(e)},check:{enable:!0},data:{key:{title:"title",name:"text"},simpleData:{enable:!0}},view:{showIcon:!1,expandSpeed:"",nameIsHTML:!0,dblClickExpand:!1,showLine:n.showLine},callback:{beforeExpand:function(e,t){if(!t.isAjaxing)return t.children||(t.times=1,r(t,"refresh")),!0;return BI.Msg.toast("Please Wait。","warning"),!1},onAsyncSuccess:function(e,n,i,a){if(i.halfCheck=!1,!a||0===a.length||/^<html>[\s,\S]*<\/html>$/gi.test(a)||t._stop)return;var o=t.nodes,s=i.count||0;i.children.length>s?(i.count=i.children.length,BI.delay((function(){r(i)}),100)):(o.updateNode(i),o.selectNode(i.children[0]))},onAsyncError:function(e,n,i,r,a,o){t.nodes;BI.Msg.toast("Error!","warning")},beforeCheck:function(e,n){var i=n.getCheckStatus();if(n.halfCheck=!1,!0===n.checked){!function e(t){BI.each(t,(function(t,n){!0===n.halfCheck&&(n.halfCheck=!1,e(n.children))}))}(n.children);var r=t.nodes.getSelectedNodes();BI.$.each(r,(function(e,t){t.halfCheck=!1}))}!0===i.half&&!0===i.checked&&(n.checked=!1)},onCheck:function(e,n,i){t._selectTreeNode(n,i)},onExpand:function(e,t,n){n.halfCheck=!1},onCollapse:function(e,t,n){},onClick:function(e,n,i){var r=i.checked,a=i.getCheckStatus();!0===a.half&&!0===a.checked&&(r=!1);t.nodes.checkNode(i,!r,!0,!0)}}};function r(e,n){var i=t.nodes;"refresh"==n&&i.updateNode(e),i.reAsyncChildNodes(e,n,!0)}return i},_getParentValues:function(e){if(!e.getParentNode())return[];var t=e.getParentNode(),n=this._getParentValues(t);return n=n.concat([this._getNodeValue(t)])},_getNodeValue:function(e){return BI.isUndefined(e.value)?BI.replaceAll(e.text.replace(/<[^>]+>/g,""),"&nbsp;"," "):e.value},_getHalfSelectedValues:function(e,t){var n=this,i=t.getCheckStatus();if(!1!==i.checked||!1!==i.half)if(BI.isNotEmptyArray(t.children)&&!0===i.half){var r=t.children;BI.each(r,(function(t,i){n._getHalfSelectedValues(e,i)}))}else{var a=t.parentValues||n._getParentValues(t),o=a.concat(this._getNodeValue(t));if(BI.isNotEmptyArray(t.children)||!1===i.half)this._buildTree(e,o);else{var s=BI.deepClone(this.options.paras.selectedValues),l=this._getTree(s,o);this._addTreeNode(e,a,this._getNodeValue(t),l)}}},_getTree:function(e,t){var n=e;return BI.any(t,(function(e,t){if(null==n[t])return!0;n=n[t]})),n},_addTreeNode:function(e,t,n,i){var r=e;BI.each(t,(function(e,t){null==r[t]&&(r[t]={}),r=r[t]})),r[n]=i},_buildTree:function(e,t){var n=e;BI.each(t,(function(e,t){null==n[t]&&(n[t]={}),n=n[t]}))},_getSelectedValues:function(){var e,t=this,n={},i=this.nodes.getNodes();return e=i,BI.each(e,(function(e,i){var r=i.getCheckStatus();if(!0===r.checked||!0===r.half)if(!0===r.half)t._getHalfSelectedValues(n,i);else{var a=(i.parentValues||t._getParentValues(i)).concat([t._getNodeValue(i)]);t._buildTree(n,a)}})),n},_dealWidthNodes:function(e){var t=this.options,n=BI.Tree.arrayFormat(e);return BI.each(n,(function(e,n){n.isParent=n.isParent||n.parent,n.value=BI.isUndefined(n.value)?n.text:n.value,n.text=BI.isUndefined(n.text)?n.value:n.text,null===n.text&&(n.text=""),BI.isNull(n.title)&&(n.title=n.text),BI.isNotNull(n.text)&&(BI.isKey(t.paras.keyword)?n.text=BI.$("<div>").__textKeywordMarked__(BI.Text.formatText(n.text+""),t.paras.keyword,n.py).html():n.text=BI.htmlEncode(BI.Text.formatText(n.text+"")))})),e},_loadMore:function(){var e=this,t=this.options;this.tip.setLoading();var n=BI.extend({},t.paras,{times:++this.times});t.itemsCreator(n,(function(t){if(!0!==e._stop){var n=!!t.hasNext,i=t.items||[];n?e.tip.setLoaded():e.tip.setEnd(),i.length>0&&e.nodes.addNodes(null,e._dealWidthNodes(i))}}))},_initTree:function(e){var t=this,n=this.options;t.fireEvent(BI.Events.INIT),this.times=1;var i=this.tree;i.empty(),this.loading(),this.tip.setVisible(!1);var r=BI.extend({},n.paras,{times:1});n.itemsCreator(r,(function(n){if(!0!==t._stop){var a=!!n.hasNext,o=n.items||[];o.length>0&&function(n){!0!==t._stop&&(t.nodes=BI.$.fn.zTree.init(i.element,e,n))}(t._dealWidthNodes(o)),t.setTipVisible(o.length<=0),t.loaded(),a?t.tip.setLoaded():t.tip.invisible(),1===r.times&&t.fireEvent(BI.Events.AFTERINIT)}}))},initTree:function(e,t){t=t||{async:{enable:!1},check:{enable:!1},data:{key:{title:"title",name:"text"},simpleData:{enable:!0}},view:{showIcon:!1,expandSpeed:"",nameIsHTML:!0},callback:{}};this.nodes=BI.$.fn.zTree.init(this.tree.element,t,e)},start:function(){this._stop=!1},stop:function(){this._stop=!0},stroke:function(e){delete this.options.keyword,BI.extend(this.options.paras,e);var t=this._configSetting();this._createTree(),this.start(),this._initTree(t)},populate:function(){this.stroke.apply(this,arguments)},hasChecked:function(){return this.nodes.getCheckedNodes(!0).length>0},checkAll:function(e){function t(e){BI.each(e,(function(e,n){n.halfCheck=!1,t(n.children)}))}this.nodes&&(BI.each(this.nodes.getNodes(),(function(e,n){n.halfCheck=!1,t(n.children)})),this.nodes.checkAllNodes(e))},expandAll:function(e){this.nodes&&this.nodes.expandAll(e)},setValue:function(e,t){this.checkAll(!1),this.updateValue(e,t),this.refresh()},setSelectedValue:function(e){this.options.paras.selectedValues=BI.deepClone(e||{})},updateValue:function(e,t){if(this.nodes){t||(t="value");var n=this.nodes;BI.each(e,(function(e,i){var r=n.getNodesByParam(t,e,null);BI.each(r,(function(e,t){BI.extend(t,{checked:!0},i),n.updateNode(t)}))}))}},refresh:function(){this.nodes&&this.nodes.refresh()},getValue:function(){return this.nodes?this._getSelectedValues():null},destroyed:function(){this.stop(),this.nodes&&this.nodes.destroy()}}),BI.extend(BI.TreeView,{REQ_TYPE_INIT_DATA:1,REQ_TYPE_ADJUST_DATA:2,REQ_TYPE_SELECT_DATA:3,REQ_TYPE_GET_SELECTED_DATA:4}),BI.TreeView.EVENT_CHANGE="EVENT_CHANGE",BI.TreeView.EVENT_INIT=BI.Events.INIT,BI.TreeView.EVENT_AFTERINIT=BI.Events.AFTERINIT,BI.shortcut("bi.tree_view",BI.TreeView)},function(e,t){BI.AsyncTree=BI.inherit(BI.TreeView,{_defaultConfig:function(){return BI.extend(BI.AsyncTree.superclass._defaultConfig.apply(this,arguments),{})},_init:function(){BI.AsyncTree.superclass._init.apply(this,arguments);var e=this;this.service=new BI.TreeRenderPageService({subNodeListGetter:function(t){return BI.$("#"+e.id+" #"+t+"_ul")}})},_configSetting:function(){var e=this.options,t=this.options.paras,n=this;return{async:{enable:!1,otherParam:BI.cjkEncodeDO(t)},check:{enable:!0},data:{key:{title:"title",name:"text"},simpleData:{enable:!0}},view:{showIcon:!1,expandSpeed:"",nameIsHTML:!0,dblClickExpand:!1,showLine:e.showLine},callback:{beforeCheck:function(e,t){var n=t.getCheckStatus();if(t.halfCheck=!1,!0===t.checked){!function n(e){BI.each(e,(function(e,t){t.halfCheck=!1,n(t.children)}))}(t.children);var i=BI.$.fn.zTree.getZTreeObj(e).getSelectedNodes();BI.each(i,(function(e,t){t.halfCheck=!1}))}!0===n.half&&!0===n.checked&&(t.checked=!1)},onCheck:function(e,t,i){n._selectTreeNode(t,i)},beforeExpand:function(e,t){n._beforeExpandNode(e,t)},onExpand:function(e,t,n){n.halfCheck=!1},onCollapse:function(e,t,n){n.halfCheck=!1},onClick:function(e,t,n){var i=BI.$.fn.zTree.getZTreeObj(t),r=n.checked,a=n.getCheckStatus();!0===a.half&&!0===a.checked&&(r=!1);i.checkNode(n,!r,!0,!0)}}}},_selectTreeNode:function(e,t){var n=this,i=(this.options,BI.deepClone(t.parentValues||n._getParentValues(t))),r=this._getNodeValue(t);if(!0===t.checked)this._addTreeNode(this.options.paras.selectedValues,i,r,{});else{var a=t,o=this._getTree(this.options.paras.selectedValues,i);for(BI.isNotNull(o[r])&&delete o[r];null!=a&&BI.isEmpty(o);)i=i.slice(0,i.length-1),null!=(a=a.getParentNode())&&delete(o=this._getTree(this.options.paras.selectedValues,i))[r=this._getNodeValue(a)];this.options.paras.selectedValues=this._getJoinValue()}BI.AsyncTree.superclass._selectTreeNode.apply(n,arguments)},_beforeExpandNode:function(e,t){var n=this,i=this.options,r=function(e){var i=e.items||[];i.length>0&&function(e,i){n.nodes.addNodes(t,e),i?n.service.pushNodeList(t.tId,a):n.service.removeNodeList(t.tId)}(n._dealWidthNodes(i),!!e.hasNext)};function a(e){e=e||{};var a=t.parentValues||n._getParentValues(t),o=BI.extend({},i.paras,{id:t.id,times:e.times,parentValues:a.concat(n._getNodeValue(t)),checkState:t.getCheckStatus()},e);i.itemsCreator(o,r)}var o=t.getCheckStatus();t.children||setTimeout((function(){a({times:1,checkState:o})}),17)},_join:function(e,t){var n=this,i={};function r(e,t,a){BI.each(t,(function(o,s){BI.isNull(a[o])||BI.isEmpty(a[o])?n._addTreeNode(i,e,o,s):r(e.concat([o]),t[o],a[o])}))}return r([],e,t),r([],t,e),i},hasChecked:function(){return!BI.isEmpty(this.options.paras.selectedValues)||BI.AsyncTree.superclass.hasChecked.apply(this,arguments)},_getJoinValue:function(){if(!this.nodes)return this.options.paras.selectedValues||{};var e=this._getSelectedValues();return BI.isEmpty(e)?BI.deepClone(this.options.paras.selectedValues):BI.isEmpty(this.options.paras.selectedValues)?e:this._join(e,this.options.paras.selectedValues)},getValue:function(){return this._getJoinValue()},stroke:function(e){delete this.options.keyword,this.service.clear(),BI.extend(this.options.paras,e);var t=this._configSetting();this._initTree(t)}}),BI.shortcut("bi.async_tree",BI.AsyncTree)},function(module,exports){(function($){var settings={},roots={},caches={},_consts={className:{BUTTON:"button",LEVEL:"level",ICO_LOADING:"ico_loading",SWITCH:"switch"},event:{NODECREATED:"ztree_nodeCreated",CLICK:"ztree_click",EXPAND:"ztree_expand",COLLAPSE:"ztree_collapse",ASYNC_SUCCESS:"ztree_async_success",ASYNC_ERROR:"ztree_async_error",REMOVE:"ztree_remove",SELECTED:"ztree_selected",UNSELECTED:"ztree_unselected"},id:{A:"_a",ICON:"_ico",SPAN:"_span",SWITCH:"_switch",UL:"_ul"},line:{ROOT:"root",ROOTS:"roots",CENTER:"center",BOTTOM:"bottom",NOLINE:"noline",LINE:"line"},folder:{OPEN:"open",CLOSE:"close",DOCU:"docu"},node:{CURSELECTED:"curSelectedNode"}},_setting={treeId:"",treeObj:null,view:{addDiyDom:null,autoCancelSelected:!0,dblClickExpand:!0,expandSpeed:"fast",fontCss:{},nameIsHTML:!1,selectedMulti:!0,showIcon:!0,showLine:!0,showTitle:!0,txtSelectedEnable:!1},data:{key:{children:"children",name:"name",title:"",url:"url"},simpleData:{enable:!1,idKey:"id",pIdKey:"pId",rootPId:null},keep:{parent:!1,leaf:!1}},async:{enable:!1,contentType:"application/x-www-form-urlencoded",type:"post",dataType:"text",url:"",autoParam:[],otherParam:[],dataFilter:null},callback:{beforeAsync:null,beforeClick:null,beforeDblClick:null,beforeRightClick:null,beforeMouseDown:null,beforeMouseUp:null,beforeExpand:null,beforeCollapse:null,beforeRemove:null,onAsyncError:null,onAsyncSuccess:null,onNodeCreated:null,onClick:null,onDblClick:null,onRightClick:null,onMouseDown:null,onMouseUp:null,onExpand:null,onCollapse:null,onRemove:null}},_initRoot=function(e){var t=data.getRoot(e);t||(t={},data.setRoot(e,t)),t[e.data.key.children]=[],t.expandTriggerFlag=!1,t.curSelectedList=[],t.noSelection=!0,t.createdNodes=[],t.zId=0,t._ver=(new Date).getTime()},_initCache=function(e){var t=data.getCache(e);t||(t={},data.setCache(e,t)),t.nodes=[],t.doms=[]},_bindEvent=function(e){var t=e.treeObj,n=consts.event;t.bind(n.NODECREATED,(function(t,n,i){tools.apply(e.callback.onNodeCreated,[t,n,i])})),t.bind(n.CLICK,(function(t,n,i,r,a){tools.apply(e.callback.onClick,[n,i,r,a])})),t.bind(n.EXPAND,(function(t,n,i){tools.apply(e.callback.onExpand,[t,n,i])})),t.bind(n.COLLAPSE,(function(t,n,i){tools.apply(e.callback.onCollapse,[t,n,i])})),t.bind(n.ASYNC_SUCCESS,(function(t,n,i,r){tools.apply(e.callback.onAsyncSuccess,[t,n,i,r])})),t.bind(n.ASYNC_ERROR,(function(t,n,i,r,a,o){tools.apply(e.callback.onAsyncError,[t,n,i,r,a,o])})),t.bind(n.REMOVE,(function(t,n,i){tools.apply(e.callback.onRemove,[t,n,i])})),t.bind(n.SELECTED,(function(t,n,i,r){tools.apply(e.callback.onSelected,[n,i,r])})),t.bind(n.UNSELECTED,(function(t,n,i,r){tools.apply(e.callback.onUnSelected,[n,i,r])}))},_unbindEvent=function(e){var t=e.treeObj,n=consts.event;t.unbind(n.NODECREATED).unbind(n.CLICK).unbind(n.EXPAND).unbind(n.COLLAPSE).unbind(n.ASYNC_SUCCESS).unbind(n.ASYNC_ERROR).unbind(n.REMOVE).unbind(n.SELECTED).unbind(n.UNSELECTED)},_eventProxy=function(e){var t=e.target,n=data.getSetting(e.data.treeId),i="",r=null,a="",o="",s=null,l=null,u=null;if(tools.eqs(e.type,"mousedown")?o="mousedown":tools.eqs(e.type,"mouseup")?o="mouseup":tools.eqs(e.type,"contextmenu")?o="contextmenu":tools.eqs(e.type,"click")?tools.eqs(t.tagName,"span")&&null!==t.getAttribute("treeNode"+consts.id.SWITCH)?(i=tools.getNodeMainDom(t).id,a="switchNode"):(u=tools.getMDom(n,t,[{tagName:"a",attrName:"treeNode"+consts.id.A}]))&&(i=tools.getNodeMainDom(u).id,a="clickNode"):tools.eqs(e.type,"dblclick")&&(o="dblclick",(u=tools.getMDom(n,t,[{tagName:"a",attrName:"treeNode"+consts.id.A}]))&&(i=tools.getNodeMainDom(u).id,a="switchNode")),o.length>0&&0==i.length&&(u=tools.getMDom(n,t,[{tagName:"a",attrName:"treeNode"+consts.id.A}]))&&(i=tools.getNodeMainDom(u).id),i.length>0)switch(r=data.getNodeCache(n,i),a){case"switchNode":r.isParent&&(tools.eqs(e.type,"click")||tools.eqs(e.type,"dblclick")&&tools.apply(n.view.dblClickExpand,[n.treeId,r],n.view.dblClickExpand))?s=handler.onSwitchNode:a="";break;case"clickNode":s=handler.onClickNode}switch(o){case"mousedown":l=handler.onZTreeMousedown;break;case"mouseup":l=handler.onZTreeMouseup;break;case"dblclick":l=handler.onZTreeDblclick;break;case"contextmenu":l=handler.onZTreeContextmenu}return{stop:!1,node:r,nodeEventType:a,nodeEventCallback:s,treeEventType:o,treeEventCallback:l}},_initNode=function(e,t,n,i,r,a,o){if(n){var s=data.getRoot(e),l=e.data.key.children;n.level=t,n.tId=e.treeId+"_"+ ++s.zId,n.parentTId=i?i.tId:null,n.open="string"==typeof n.open?tools.eqs(n.open,"true"):!!n.open,n[l]&&n[l].length>0?(n.isParent=!0,n.zAsync=!0):(n.isParent="string"==typeof n.isParent?tools.eqs(n.isParent,"true"):!!n.isParent,n.open=!(!n.isParent||e.async.enable)&&n.open,n.zAsync=!n.isParent),n.isFirstNode=r,n.isLastNode=a,n.getParentNode=function(){return data.getNodeCache(e,n.parentTId)},n.getPreNode=function(){return data.getPreNode(e,n)},n.getNextNode=function(){return data.getNextNode(e,n)},n.isAjaxing=!1,data.fixPIdKeyValue(e,n)}},_init={bind:[_bindEvent],unbind:[_unbindEvent],caches:[_initCache],nodes:[_initNode],proxys:[_eventProxy],roots:[_initRoot],beforeA:[],afterA:[],innerBeforeA:[],innerAfterA:[],zTreeTools:[]},data={addNodeCache:function(e,t){data.getCache(e).nodes[data.getNodeCacheId(t.tId)]=t},getNodeCacheId:function(e){return e.substring(e.lastIndexOf("_")+1)},addAfterA:function(e){_init.afterA.push(e)},addBeforeA:function(e){_init.beforeA.push(e)},addInnerAfterA:function(e){_init.innerAfterA.push(e)},addInnerBeforeA:function(e){_init.innerBeforeA.push(e)},addInitBind:function(e){_init.bind.push(e)},addInitUnBind:function(e){_init.unbind.push(e)},addInitCache:function(e){_init.caches.push(e)},addInitNode:function(e){_init.nodes.push(e)},addInitProxy:function(e,t){t?_init.proxys.splice(0,0,e):_init.proxys.push(e)},addInitRoot:function(e){_init.roots.push(e)},addNodesData:function(e,t,n){var i=e.data.key.children;t[i]||(t[i]=[]),t[i].length>0&&(t[i][t[i].length-1].isLastNode=!1,view.setNodeLineIcos(e,t[i][t[i].length-1])),t.isParent=!0,t[i]=t[i].concat(n)},addSelectedNode:function(e,t){var n=data.getRoot(e);data.isSelectedNode(e,t)||n.curSelectedList.push(t)},addCreatedNode:function(e,t){(e.callback.onNodeCreated||e.view.addDiyDom)&&data.getRoot(e).createdNodes.push(t)},addZTreeTools:function(e){_init.zTreeTools.push(e)},exSetting:function(e){$.extend(!0,_setting,e)},fixPIdKeyValue:function(e,t){e.data.simpleData.enable&&(t[e.data.simpleData.pIdKey]=t.parentTId?t.getParentNode()[e.data.simpleData.idKey]:e.data.simpleData.rootPId)},getAfterA:function(e,t,n){for(var i=0,r=_init.afterA.length;i<r;i++)_init.afterA[i].apply(this,arguments)},getBeforeA:function(e,t,n){for(var i=0,r=_init.beforeA.length;i<r;i++)_init.beforeA[i].apply(this,arguments)},getInnerAfterA:function(e,t,n){for(var i=0,r=_init.innerAfterA.length;i<r;i++)_init.innerAfterA[i].apply(this,arguments)},getInnerBeforeA:function(e,t,n){for(var i=0,r=_init.innerBeforeA.length;i<r;i++)_init.innerBeforeA[i].apply(this,arguments)},getCache:function(e){return caches[e.treeId]},getNextNode:function(e,t){if(!t)return null;for(var n=e.data.key.children,i=t.parentTId?t.getParentNode():data.getRoot(e),r=0,a=i[n].length-1;r<=a;r++)if(i[n][r]===t)return r==a?null:i[n][r+1];return null},getNodeByParam:function(e,t,n,i){if(!t||!n)return null;for(var r=e.data.key.children,a=0,o=t.length;a<o;a++){if(t[a][n]==i)return t[a];var s=data.getNodeByParam(e,t[a][r],n,i);if(s)return s}return null},getNodeCache:function(e,t){if(!t)return null;var n=caches[e.treeId].nodes[data.getNodeCacheId(t)];return n||null},getNodeName:function(e,t){return""+t[e.data.key.name]},getNodeTitle:function(e,t){return""+t[""===e.data.key.title?e.data.key.name:e.data.key.title]},getNodes:function(e){return data.getRoot(e)[e.data.key.children]},getNodesByParam:function(e,t,n,i){if(!t||!n)return[];for(var r=e.data.key.children,a=[],o=0,s=t.length;o<s;o++)t[o][n]==i&&a.push(t[o]),a=a.concat(data.getNodesByParam(e,t[o][r],n,i));return a},getNodesByParamFuzzy:function(e,t,n,i){if(!t||!n)return[];var r=e.data.key.children,a=[];i=i.toLowerCase();for(var o=0,s=t.length;o<s;o++)"string"==typeof t[o][n]&&t[o][n].toLowerCase().indexOf(i)>-1&&a.push(t[o]),a=a.concat(data.getNodesByParamFuzzy(e,t[o][r],n,i));return a},getNodesByFilter:function(e,t,n,i,r){if(!t)return i?null:[];for(var a=e.data.key.children,o=i?null:[],s=0,l=t.length;s<l;s++){if(tools.apply(n,[t[s],r],!1)){if(i)return t[s];o.push(t[s])}var u=data.getNodesByFilter(e,t[s][a],n,i,r);if(i&&u)return u;o=i?u:o.concat(u)}return o},getPreNode:function(e,t){if(!t)return null;for(var n=e.data.key.children,i=t.parentTId?t.getParentNode():data.getRoot(e),r=0,a=i[n].length;r<a;r++)if(i[n][r]===t)return 0==r?null:i[n][r-1];return null},getRoot:function(e){return e?roots[e.treeId]:null},getRoots:function(){return roots},getSetting:function(e){return settings[e]},getSettings:function(){return settings},getZTreeTools:function(e){var t=this.getRoot(this.getSetting(e));return t?t.treeTools:null},initCache:function(e){for(var t=0,n=_init.caches.length;t<n;t++)_init.caches[t].apply(this,arguments)},initNode:function(e,t,n,i,r,a){for(var o=0,s=_init.nodes.length;o<s;o++)_init.nodes[o].apply(this,arguments)},initRoot:function(e){for(var t=0,n=_init.roots.length;t<n;t++)_init.roots[t].apply(this,arguments)},isSelectedNode:function(e,t){for(var n=data.getRoot(e),i=0,r=n.curSelectedList.length;i<r;i++)if(t===n.curSelectedList[i])return!0;return!1},removeNodeCache:function(e,t){var n=e.data.key.children;if(t[n])for(var i=0,r=t[n].length;i<r;i++)arguments.callee(e,t[n][i]);data.getCache(e).nodes[data.getNodeCacheId(t.tId)]=null},removeSelectedNode:function(e,t){for(var n=data.getRoot(e),i=0,r=n.curSelectedList.length;i<r;i++)t!==n.curSelectedList[i]&&data.getNodeCache(e,n.curSelectedList[i].tId)||(n.curSelectedList.splice(i,1),i--,r--)},setCache:function(e,t){caches[e.treeId]=t},setRoot:function(e,t){roots[e.treeId]=t},setZTreeTools:function(e,t){for(var n=0,i=_init.zTreeTools.length;n<i;n++)_init.zTreeTools[n].apply(this,arguments)},transformToArrayFormat:function(e,t){if(!t)return[];var n=e.data.key.children,i=[];if(tools.isArray(t))for(var r=0,a=t.length;r<a;r++)i.push(t[r]),t[r][n]&&(i=i.concat(data.transformToArrayFormat(e,t[r][n])));else i.push(t),t[n]&&(i=i.concat(data.transformToArrayFormat(e,t[n])));return i},transformTozTreeFormat:function(e,t){var n,i,r=e.data.simpleData.idKey,a=e.data.simpleData.pIdKey,o=e.data.key.children;if(!r||""==r||!t)return[];if(tools.isArray(t)){var s=[],l={};for(n=0,i=t.length;n<i;n++)l[t[n][r]]=t[n];for(n=0,i=t.length;n<i;n++)l[t[n][a]]&&t[n][r]!=t[n][a]?(l[t[n][a]][o]||(l[t[n][a]][o]=[]),l[t[n][a]][o].push(t[n])):s.push(t[n]);return s}return[t]}},event={bindEvent:function(e){for(var t=0,n=_init.bind.length;t<n;t++)_init.bind[t].apply(this,arguments)},unbindEvent:function(e){for(var t=0,n=_init.unbind.length;t<n;t++)_init.unbind[t].apply(this,arguments)},bindTree:function(e){var t={treeId:e.treeId},n=e.treeObj;e.view.txtSelectedEnable||n.bind("selectstart",(function(e){var t=e.originalEvent.srcElement.nodeName.toLowerCase();return"input"===t||"textarea"===t})).css({"-moz-user-select":"-moz-none"}),n.bind("click",t,event.proxy),n.bind("dblclick",t,event.proxy),n.bind("mouseover",t,event.proxy),n.bind("mouseout",t,event.proxy),n.bind("mousedown",t,event.proxy),n.bind("mouseup",t,event.proxy),n.bind("contextmenu",t,event.proxy)},unbindTree:function(e){e.treeObj.unbind("click",event.proxy).unbind("dblclick",event.proxy).unbind("mouseover",event.proxy).unbind("mouseout",event.proxy).unbind("mousedown",event.proxy).unbind("mouseup",event.proxy).unbind("contextmenu",event.proxy)},doProxy:function(e){for(var t=[],n=0,i=_init.proxys.length;n<i;n++){var r=_init.proxys[n].apply(this,arguments);if(t.push(r),r.stop)break}return t},proxy:function(e){var t=data.getSetting(e.data.treeId);if(!tools.uCanDo(t,e))return!0;for(var n=event.doProxy(e),i=!0,r=0,a=n.length;r<a;r++){var o=n[r];o.nodeEventCallback&&(!0,i=o.nodeEventCallback.apply(o,[e,o.node])&&i),o.treeEventCallback&&(!0,i=o.treeEventCallback.apply(o,[e,o.node])&&i)}return i}},handler={onSwitchNode:function(e,t){var n=data.getSetting(e.data.treeId);if(t.open){if(0==tools.apply(n.callback.beforeCollapse,[n.treeId,t],!0))return!0;data.getRoot(n).expandTriggerFlag=!0,view.switchNode(n,t)}else{if(0==tools.apply(n.callback.beforeExpand,[n.treeId,t],!0))return!0;data.getRoot(n).expandTriggerFlag=!0,view.switchNode(n,t)}return!0},onClickNode:function(e,t){var n=data.getSetting(e.data.treeId),i=n.view.autoCancelSelected&&(e.ctrlKey||e.metaKey)&&data.isSelectedNode(n,t)?0:n.view.autoCancelSelected&&(e.ctrlKey||e.metaKey)&&n.view.selectedMulti?2:1;return 0==tools.apply(n.callback.beforeClick,[n.treeId,t,i],!0)||(0===i?view.cancelPreSelectedNode(n,t):view.selectNode(n,t,2===i),n.treeObj.trigger(consts.event.CLICK,[e,n.treeId,t,i])),!0},onZTreeMousedown:function(e,t){var n=data.getSetting(e.data.treeId);return tools.apply(n.callback.beforeMouseDown,[n.treeId,t],!0)&&tools.apply(n.callback.onMouseDown,[e,n.treeId,t]),!0},onZTreeMouseup:function(e,t){var n=data.getSetting(e.data.treeId);return tools.apply(n.callback.beforeMouseUp,[n.treeId,t],!0)&&tools.apply(n.callback.onMouseUp,[e,n.treeId,t]),!0},onZTreeDblclick:function(e,t){var n=data.getSetting(e.data.treeId);return tools.apply(n.callback.beforeDblClick,[n.treeId,t],!0)&&tools.apply(n.callback.onDblClick,[e,n.treeId,t]),!0},onZTreeContextmenu:function(e,t){var n=data.getSetting(e.data.treeId);return tools.apply(n.callback.beforeRightClick,[n.treeId,t],!0)&&tools.apply(n.callback.onRightClick,[e,n.treeId,t]),"function"!=typeof n.callback.onRightClick}},tools={apply:function(e,t,n){return"function"==typeof e?e.apply(zt,t||[]):n},canAsync:function(e,t){var n=e.data.key.children;return e.async.enable&&t&&t.isParent&&!(t.zAsync||t[n]&&t[n].length>0)},clone:function(e){if(null===e)return null;var t=tools.isArray(e)?[]:{};for(var n in e)t[n]=e[n]instanceof Date?new Date(e[n].getTime()):"object"==typeof e[n]?arguments.callee(e[n]):e[n];return t},eqs:function(e,t){return e.toLowerCase()===t.toLowerCase()},isArray:function(e){return"[object Array]"===Object.prototype.toString.apply(e)},$:function(e,t,n){return t&&"string"!=typeof t&&(n=t,t=""),"string"==typeof e?$(e,n?n.treeObj.get(0).ownerDocument:null):$("#"+e.tId+t,n?n.treeObj:null)},getMDom:function(e,t,n){if(!t)return null;for(;t&&t.id!==e.treeId;){for(var i=0,r=n.length;t.tagName&&i<r;i++)if(tools.eqs(t.tagName,n[i].tagName)&&null!==t.getAttribute(n[i].attrName))return t;t=t.parentNode}return null},getNodeMainDom:function(e){return $(e).parent("li").get(0)||$(e).parentsUntil("li").parent().get(0)},isChildOrSelf:function(e,t){return $(e).closest("#"+t).length>0},uCanDo:function(e,t){return!0}},view={addNodes:function(e,t,n,i){if(!e.data.keep.leaf||!t||t.isParent)if(tools.isArray(n)||(n=[n]),e.data.simpleData.enable&&(n=data.transformTozTreeFormat(e,n)),t){var r=$$(t,consts.id.SWITCH,e),a=$$(t,consts.id.ICON,e),o=$$(t,consts.id.UL,e);t.open||(view.replaceSwitchClass(t,r,consts.folder.CLOSE),view.replaceIcoClass(t,a,consts.folder.CLOSE),t.open=!1,o.css({display:"none"})),data.addNodesData(e,t,n),view.createNodes(e,t.level+1,n,t),i||view.expandCollapseParentNode(e,t,!0)}else data.addNodesData(e,data.getRoot(e),n),view.createNodes(e,0,n,null)},appendNodes:function(e,t,n,i,r,a){if(!n)return[];for(var o=[],s=e.data.key.children,l=0,u=n.length;l<u;l++){var c=n[l];if(r){var h=(i||data.getRoot(e))[s].length==n.length&&0==l,p=l==n.length-1;data.initNode(e,t,c,i,h,p,a),data.addNodeCache(e,c)}var d=[];c[s]&&c[s].length>0&&(d=view.appendNodes(e,t+1,c[s],c,r,a&&c.open)),a&&(view.makeDOMNodeMainBefore(o,e,c),view.makeDOMNodeLine(o,e,c),data.getBeforeA(e,c,o),view.makeDOMNodeNameBefore(o,e,c),data.getInnerBeforeA(e,c,o),view.makeDOMNodeIcon(o,e,c),data.getInnerAfterA(e,c,o),view.makeDOMNodeNameAfter(o,e,c),data.getAfterA(e,c,o),c.isParent&&c.open&&view.makeUlHtml(e,c,o,d.join("")),view.makeDOMNodeMainAfter(o,e,c),data.addCreatedNode(e,c))}return o},appendParentULDom:function(e,t){var n=[],i=$$(t,e);!i.get(0)&&t.parentTId&&(view.appendParentULDom(e,t.getParentNode()),i=$$(t,e));var r=$$(t,consts.id.UL,e);r.get(0)&&r.remove();var a=e.data.key.children,o=view.appendNodes(e,t.level+1,t[a],t,!1,!0);view.makeUlHtml(e,t,n,o.join("")),i.append(n.join(""))},asyncNode:function(setting,node,isSilent,callback){var i,l;if(node&&!node.isParent)return tools.apply(callback),!1;if(node&&node.isAjaxing)return!1;if(0==tools.apply(setting.callback.beforeAsync,[setting.treeId,node],!0))return tools.apply(callback),!1;if(node){node.isAjaxing=!0;var icoObj=$$(node,consts.id.ICON,setting);icoObj.attr({style:"","class":consts.className.BUTTON+" "+consts.className.ICO_LOADING})}var tmpParam={};for(i=0,l=setting.async.autoParam.length;node&&i<l;i++){var pKey=setting.async.autoParam[i].split("="),spKey=pKey;pKey.length>1&&(spKey=pKey[1],pKey=pKey[0]),tmpParam[spKey]=node[pKey]}if(tools.isArray(setting.async.otherParam))for(i=0,l=setting.async.otherParam.length;i<l;i+=2)tmpParam[setting.async.otherParam[i]]=setting.async.otherParam[i+1];else for(var p in setting.async.otherParam)tmpParam[p]=setting.async.otherParam[p];var _tmpV=data.getRoot(setting)._ver;return $.ajax({contentType:setting.async.contentType,cache:!1,type:setting.async.type,url:tools.apply(setting.async.url,[setting.treeId,node],setting.async.url),data:tmpParam,dataType:setting.async.dataType,success:function(msg){if(_tmpV==data.getRoot(setting)._ver){var newNodes=[];try{newNodes=msg&&0!=msg.length?"string"==typeof msg?eval("("+msg+")"):msg:[]}catch(err){newNodes=msg}node&&(node.isAjaxing=null,node.zAsync=!0),view.setNodeLineIcos(setting,node),newNodes&&""!==newNodes?(newNodes=tools.apply(setting.async.dataFilter,[setting.treeId,node,newNodes],newNodes),view.addNodes(setting,node,newNodes?tools.clone(newNodes):[],!!isSilent)):view.addNodes(setting,node,[],!!isSilent),setting.treeObj.trigger(consts.event.ASYNC_SUCCESS,[setting.treeId,node,msg]),tools.apply(callback)}},error:function(e,t,n){_tmpV==data.getRoot(setting)._ver&&(node&&(node.isAjaxing=null),view.setNodeLineIcos(setting,node),setting.treeObj.trigger(consts.event.ASYNC_ERROR,[setting.treeId,node,e,t,n]))}}),!0},cancelPreSelectedNode:function(e,t,n){var i,r,a=data.getRoot(e).curSelectedList;for(i=a.length-1;i>=0;i--)if(t===(r=a[i])||!t&&(!n||n!==r)){if($$(r,consts.id.A,e).removeClass(consts.node.CURSELECTED),t){data.removeSelectedNode(e,t),e.treeObj.trigger(consts.event.UNSELECTED,[event,e.treeId,r]);break}a.splice(i,1),e.treeObj.trigger(consts.event.UNSELECTED,[event,e.treeId,r])}},createNodeCallback:function(e){if(e.callback.onNodeCreated||e.view.addDiyDom)for(var t=data.getRoot(e);t.createdNodes.length>0;){var n=t.createdNodes.shift();tools.apply(e.view.addDiyDom,[e.treeId,n]),e.callback.onNodeCreated&&e.treeObj.trigger(consts.event.NODECREATED,[e.treeId,n])}},createNodes:function(e,t,n,i){if(n&&0!=n.length){var r=data.getRoot(e),a=e.data.key.children,o=!i||i.open||!!$$(i[a][0],e).get(0);r.createdNodes=[];var s=view.appendNodes(e,t,n,i,!0,o);if(i){var l=$$(i,consts.id.UL,e);l.get(0)&&l.append(s.join(""))}else e.treeObj.append(s.join(""));view.createNodeCallback(e)}},destroy:function(e){e&&(data.initCache(e),data.initRoot(e),event.unbindTree(e),event.unbindEvent(e),e.treeObj.empty(),delete settings[e.treeId])},expandCollapseNode:function(e,t,n,i,r){var a=data.getRoot(e),o=e.data.key.children;if(t){if(a.expandTriggerFlag){var s=r;r=function(){s&&s(),t.open?e.treeObj.trigger(consts.event.EXPAND,[e.treeId,t]):e.treeObj.trigger(consts.event.COLLAPSE,[e.treeId,t])},a.expandTriggerFlag=!1}if(!t.open&&t.isParent&&(!$$(t,consts.id.UL,e).get(0)||t[o]&&t[o].length>0&&!$$(t[o][0],e).get(0))&&(view.appendParentULDom(e,t),view.createNodeCallback(e)),t.open!=n){var l=$$(t,consts.id.UL,e),u=$$(t,consts.id.SWITCH,e),c=$$(t,consts.id.ICON,e);t.isParent?(t.open=!t.open,t.iconOpen&&t.iconClose&&c.attr("style",view.makeNodeIcoStyle(e,t)),t.open?(view.replaceSwitchClass(t,u,consts.folder.OPEN),view.replaceIcoClass(t,c,consts.folder.OPEN),0==i||""==e.view.expandSpeed?(l.show(),tools.apply(r,[])):t[o]&&t[o].length>0?l.slideDown(e.view.expandSpeed,r):(l.show(),tools.apply(r,[]))):(view.replaceSwitchClass(t,u,consts.folder.CLOSE),view.replaceIcoClass(t,c,consts.folder.CLOSE),0!=i&&""!=e.view.expandSpeed&&t[o]&&t[o].length>0?l.slideUp(e.view.expandSpeed,r):(l.hide(),tools.apply(r,[])))):tools.apply(r,[])}else tools.apply(r,[])}else tools.apply(r,[])},expandCollapseParentNode:function(e,t,n,i,r){t&&(t.parentTId?(view.expandCollapseNode(e,t,n,i),t.parentTId&&view.expandCollapseParentNode(e,t.getParentNode(),n,i,r)):view.expandCollapseNode(e,t,n,i,r))},expandCollapseSonNode:function(e,t,n,i,r){var a=data.getRoot(e),o=e.data.key.children,s=t?t[o]:a[o],l=!t&&i,u=data.getRoot(e).expandTriggerFlag;if(data.getRoot(e).expandTriggerFlag=!1,s)for(var c=0,h=s.length;c<h;c++)s[c]&&view.expandCollapseSonNode(e,s[c],n,l);data.getRoot(e).expandTriggerFlag=u,view.expandCollapseNode(e,t,n,i,r)},isSelectedNode:function(e,t){if(!t)return!1;var n,i=data.getRoot(e).curSelectedList;for(n=i.length-1;n>=0;n--)if(t===i[n])return!0;return!1},makeDOMNodeIcon:function(e,t,n){var i=data.getNodeName(t,n),r=t.view.nameIsHTML?i:i.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;");e.push("<span id='",n.tId,consts.id.ICON,"' title='' treeNode",consts.id.ICON," class='",view.makeNodeIcoClass(t,n),"' style='",view.makeNodeIcoStyle(t,n),"'></span><span id='",n.tId,consts.id.SPAN,"'>",r,"</span>")},makeDOMNodeLine:function(e,t,n){e.push("<span id='",n.tId,consts.id.SWITCH,"' title='' class='",view.makeNodeLineClass(t,n),"' treeNode",consts.id.SWITCH,"></span>")},makeDOMNodeMainAfter:function(e,t,n){e.push("</li>")},makeDOMNodeMainBefore:function(e,t,n){e.push("<li id='",n.tId,"' class='",consts.className.LEVEL,n.level,"' tabindex='0' hidefocus='true' treenode>")},makeDOMNodeNameAfter:function(e,t,n){e.push("</a>")},makeDOMNodeNameBefore:function(e,t,n){var i=data.getNodeTitle(t,n),r=view.makeNodeUrl(t,n),a=view.makeNodeFontCss(t,n),o=[];for(var s in a)o.push(s,":",a[s],";");e.push("<a id='",n.tId,consts.id.A,"' class='",consts.className.LEVEL,n.level,"' treeNode",consts.id.A,' onclick="',n.click||"",'" ',null!=r&&r.length>0?"href='"+r+"'":""," target='",view.makeNodeTarget(n),"' style='",o.join(""),"'"),tools.apply(t.view.showTitle,[t.treeId,n],t.view.showTitle)&&i&&e.push("title='",i.replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;"),"'"),e.push(">")},makeNodeFontCss:function(e,t){var n=tools.apply(e.view.fontCss,[e.treeId,t],e.view.fontCss);return n&&"function"!=typeof n?n:{}},makeNodeIcoClass:function(e,t){var n=["ico"];return t.isAjaxing||(n[0]=(t.iconSkin?t.iconSkin+"_":"")+n[0],t.isParent?n.push(t.open?consts.folder.OPEN:consts.folder.CLOSE):n.push(consts.folder.DOCU)),consts.className.BUTTON+" "+n.join("_")},makeNodeIcoStyle:function(e,t){var n=[];if(!t.isAjaxing){var i=t.isParent&&t.iconOpen&&t.iconClose?t.open?t.iconOpen:t.iconClose:t.icon;i&&n.push("background:url(",i,") 0 0 no-repeat;"),0!=e.view.showIcon&&tools.apply(e.view.showIcon,[e.treeId,t],!0)||n.push("width:0px;height:0px;")}return n.join("")},makeNodeLineClass:function(e,t){var n=[];return e.view.showLine?0==t.level&&t.isFirstNode&&t.isLastNode?n.push(consts.line.ROOT):0==t.level&&t.isFirstNode?n.push(consts.line.ROOTS):t.isLastNode?n.push(consts.line.BOTTOM):n.push(consts.line.CENTER):n.push(consts.line.NOLINE),t.isParent?n.push(t.open?consts.folder.OPEN:consts.folder.CLOSE):n.push(consts.folder.DOCU),view.makeNodeLineClassEx(t)+n.join("_")},makeNodeLineClassEx:function(e){return consts.className.BUTTON+" "+consts.className.LEVEL+e.level+" "+consts.className.SWITCH+" "},makeNodeTarget:function(e){return e.target||"_blank"},makeNodeUrl:function(e,t){var n=e.data.key.url;return t[n]?t[n]:null},makeUlHtml:function(e,t,n,i){n.push("<ul id='",t.tId,consts.id.UL,"' class='",consts.className.LEVEL,t.level," ",view.makeUlLineClass(e,t),"' style='display:",t.open?"block":"none","'>"),n.push(i),n.push("</ul>")},makeUlLineClass:function(e,t){return e.view.showLine&&!t.isLastNode?consts.line.LINE:""},removeChildNodes:function(e,t){if(t){var n=e.data.key.children,i=t[n];if(i){for(var r=0,a=i.length;r<a;r++)data.removeNodeCache(e,i[r]);if(data.removeSelectedNode(e),delete t[n],e.data.keep.parent)$$(t,consts.id.UL,e).empty();else{t.isParent=!1,t.open=!1;var o=$$(t,consts.id.SWITCH,e),s=$$(t,consts.id.ICON,e);view.replaceSwitchClass(t,o,consts.folder.DOCU),view.replaceIcoClass(t,s,consts.folder.DOCU),$$(t,consts.id.UL,e).remove()}}}},setFirstNode:function(e,t){var n=e.data.key.children;t[n].length>0&&(t[n][0].isFirstNode=!0)},setLastNode:function(e,t){var n=e.data.key.children,i=t[n].length;i>0&&(t[n][i-1].isLastNode=!0)},removeNode:function(e,t){var n=data.getRoot(e),i=e.data.key.children,r=t.parentTId?t.getParentNode():n;if(t.isFirstNode=!1,t.isLastNode=!1,t.getPreNode=function(){return null},t.getNextNode=function(){return null},data.getNodeCache(e,t.tId)){$$(t,e).remove(),data.removeNodeCache(e,t),data.removeSelectedNode(e,t);for(var a=0,o=r[i].length;a<o;a++)if(r[i][a].tId==t.tId){r[i].splice(a,1);break}view.setFirstNode(e,r),view.setLastNode(e,r);var s,l,u,c=r[i].length;if(e.data.keep.parent||0!=c){if(e.view.showLine&&c>0){var h=r[i][c-1];if(s=$$(h,consts.id.UL,e),l=$$(h,consts.id.SWITCH,e),u=$$(h,consts.id.ICON,e),r==n)if(1==r[i].length)view.replaceSwitchClass(h,l,consts.line.ROOT);else{var p=$$(r[i][0],consts.id.SWITCH,e);view.replaceSwitchClass(r[i][0],p,consts.line.ROOTS),view.replaceSwitchClass(h,l,consts.line.BOTTOM)}else view.replaceSwitchClass(h,l,consts.line.BOTTOM);s.removeClass(consts.line.LINE)}}else r.isParent=!1,r.open=!1,s=$$(r,consts.id.UL,e),l=$$(r,consts.id.SWITCH,e),u=$$(r,consts.id.ICON,e),view.replaceSwitchClass(r,l,consts.folder.DOCU),view.replaceIcoClass(r,u,consts.folder.DOCU),s.css("display","none")}},replaceIcoClass:function(e,t,n){if(t&&!e.isAjaxing){var i=t.attr("class");if(i!=undefined){var r=i.split("_");switch(n){case consts.folder.OPEN:case consts.folder.CLOSE:case consts.folder.DOCU:r[r.length-1]=n}t.attr("class",r.join("_"))}}},replaceSwitchClass:function(e,t,n){if(t){var i=t.attr("class");if(i!=undefined){var r=i.split("_");switch(n){case consts.line.ROOT:case consts.line.ROOTS:case consts.line.CENTER:case consts.line.BOTTOM:case consts.line.NOLINE:r[0]=view.makeNodeLineClassEx(e)+n;break;case consts.folder.OPEN:case consts.folder.CLOSE:case consts.folder.DOCU:r[1]=n}t.attr("class",r.join("_")),n!==consts.folder.DOCU?t.removeAttr("disabled"):t.attr("disabled","disabled")}}},selectNode:function(e,t,n){n||view.cancelPreSelectedNode(e,null,t),$$(t,consts.id.A,e).addClass(consts.node.CURSELECTED),data.addSelectedNode(e,t),e.treeObj.trigger(consts.event.SELECTED,[event,e.treeId,t])},setNodeFontCss:function(e,t){var n=$$(t,consts.id.A,e),i=view.makeNodeFontCss(e,t);i&&n.css(i)},setNodeLineIcos:function(e,t){if(t){var n=$$(t,consts.id.SWITCH,e),i=$$(t,consts.id.UL,e),r=$$(t,consts.id.ICON,e),a=view.makeUlLineClass(e,t);0==a.length?i.removeClass(consts.line.LINE):i.addClass(a),n.attr("class",view.makeNodeLineClass(e,t)),t.isParent?n.removeAttr("disabled"):n.attr("disabled","disabled"),r.removeAttr("style"),r.attr("style",view.makeNodeIcoStyle(e,t)),r.attr("class",view.makeNodeIcoClass(e,t))}},setNodeName:function(e,t){var n=data.getNodeTitle(e,t),i=$$(t,consts.id.SPAN,e);(i.empty(),e.view.nameIsHTML?i.html(data.getNodeName(e,t)):i.text(data.getNodeName(e,t)),tools.apply(e.view.showTitle,[e.treeId,t],e.view.showTitle))&&$$(t,consts.id.A,e).attr("title",n||"")},setNodeTarget:function(e,t){$$(t,consts.id.A,e).attr("target",view.makeNodeTarget(t))},setNodeUrl:function(e,t){var n=$$(t,consts.id.A,e),i=view.makeNodeUrl(e,t);null==i||0==i.length?n.removeAttr("href"):n.attr("href",i)},switchNode:function(e,t){if(t.open||!tools.canAsync(e,t))view.expandCollapseNode(e,t,!t.open);else if(e.async.enable){if(!view.asyncNode(e,t))return void view.expandCollapseNode(e,t,!t.open)}else t&&view.expandCollapseNode(e,t,!t.open)}};$.fn.zTree={consts:_consts,_z:{tools:tools,view:view,event:event,data:data},getZTreeObj:function(e){var t=data.getZTreeTools(e);return t||null},destroy:function(e){if(e&&e.length>0)view.destroy(data.getSetting(e));else for(var t in settings)view.destroy(settings[t])},init:function(e,t,n){var i=tools.clone(_setting);$.extend(!0,i,t),i.treeId=e.attr("id"),i.treeObj=e,i.treeObj.empty(),settings[i.treeId]=i,"undefined"==typeof document.body.style.maxHeight&&(i.view.expandSpeed=""),data.initRoot(i);var r=data.getRoot(i),a=i.data.key.children;n=n?tools.clone(tools.isArray(n)?n:[n]):[],i.data.simpleData.enable?r[a]=data.transformTozTreeFormat(i,n):r[a]=n,data.initCache(i),event.unbindTree(i),event.bindTree(i),event.unbindEvent(i),event.bindEvent(i);var o={setting:i,addNodes:function(e,t,n){if(!t)return null;if(e||(e=null),e&&!e.isParent&&i.data.keep.leaf)return null;var r=tools.clone(tools.isArray(t)?t:[t]);function a(){view.addNodes(i,e,r,1==n)}return tools.canAsync(i,e)?view.asyncNode(i,e,n,a):a(),r},cancelSelectedNode:function(e){view.cancelPreSelectedNode(i,e)},destroy:function(){view.destroy(i)},expandAll:function(e){return e=!!e,view.expandCollapseSonNode(i,null,e,!0),e},expandNode:function(e,t,n,r,a){if(!e||!e.isParent)return null;if(!0!==t&&!1!==t&&(t=!e.open),(a=!!a)&&t&&0==tools.apply(i.callback.beforeExpand,[i.treeId,e],!0))return null;if(a&&!t&&0==tools.apply(i.callback.beforeCollapse,[i.treeId,e],!0))return null;if(t&&e.parentTId&&view.expandCollapseParentNode(i,e.getParentNode(),t,!1),t===e.open&&!n)return null;if(data.getRoot(i).expandTriggerFlag=a,!tools.canAsync(i,e)&&n)view.expandCollapseSonNode(i,e,t,!0,(function(){if(!1!==r)try{$$(e,i).focus().blur()}catch(t){}}));else if(e.open=!t,view.switchNode(this.setting,e),!1!==r)try{$$(e,i).focus().blur()}catch(o){}return t},getNodes:function(){return data.getNodes(i)},getNodeByParam:function(e,t,n){return e?data.getNodeByParam(i,n?n[i.data.key.children]:data.getNodes(i),e,t):null},getNodeByTId:function(e){return data.getNodeCache(i,e)},getNodesByParam:function(e,t,n){return e?data.getNodesByParam(i,n?n[i.data.key.children]:data.getNodes(i),e,t):null},getNodesByParamFuzzy:function(e,t,n){return e?data.getNodesByParamFuzzy(i,n?n[i.data.key.children]:data.getNodes(i),e,t):null},getNodesByFilter:function(e,t,n,r){return t=!!t,e&&"function"==typeof e?data.getNodesByFilter(i,n?n[i.data.key.children]:data.getNodes(i),e,t,r):t?null:[]},getNodeIndex:function(e){if(!e)return null;for(var t=i.data.key.children,n=e.parentTId?e.getParentNode():data.getRoot(i),r=0,a=n[t].length;r<a;r++)if(n[t][r]==e)return r;return-1},getSelectedNodes:function(){for(var e=[],t=data.getRoot(i).curSelectedList,n=0,r=t.length;n<r;n++)e.push(t[n]);return e},isSelectedNode:function(e){return data.isSelectedNode(i,e)},reAsyncChildNodes:function(e,t,n){if(this.setting.async.enable){var r=!e;if(r&&(e=data.getRoot(i)),"refresh"==t){for(var a=this.setting.data.key.children,o=0,s=e[a]?e[a].length:0;o<s;o++)data.removeNodeCache(i,e[a][o]);if(data.removeSelectedNode(i),e[a]=[],r)this.setting.treeObj.empty();else $$(e,consts.id.UL,i).empty()}view.asyncNode(this.setting,r?null:e,!!n)}},refresh:function(){this.setting.treeObj.empty();var e=data.getRoot(i),t=e[i.data.key.children];data.initRoot(i),e[i.data.key.children]=t,data.initCache(i),view.createNodes(i,0,e[i.data.key.children])},removeChildNodes:function(e){if(!e)return null;var t=e[i.data.key.children];return view.removeChildNodes(i,e),t||null},removeNode:function(e,t){e&&((t=!!t)&&0==tools.apply(i.callback.beforeRemove,[i.treeId,e],!0)||(view.removeNode(i,e),t&&this.setting.treeObj.trigger(consts.event.REMOVE,[i.treeId,e])))},selectNode:function(e,t){if(e&&tools.uCanDo(i)){if(t=i.view.selectedMulti&&t,e.parentTId)view.expandCollapseParentNode(i,e.getParentNode(),!0,!1,(function(){try{$$(e,i).focus().blur()}catch(t){}}));else try{$$(e,i).focus().blur()}catch(n){}view.selectNode(i,e,t)}},transformTozTreeNodes:function(e){return data.transformTozTreeFormat(i,e)},transformToArray:function(e){return data.transformToArrayFormat(i,e)},updateNode:function(e,t){e&&($$(e,i).get(0)&&tools.uCanDo(i)&&(view.setNodeName(i,e),view.setNodeTarget(i,e),view.setNodeUrl(i,e),view.setNodeLineIcos(i,e),view.setNodeFontCss(i,e)))}};return r.treeTools=o,data.setZTreeTools(i,o),r[a]&&r[a].length>0?view.createNodes(i,0,r[a]):i.async.enable&&i.async.url&&""!==i.async.url&&view.asyncNode(i),o}};var zt=$.fn.zTree,$$=tools.$,consts=zt.consts})(BI.jQuery)},function(e,t){!function(e){var t={event:{CHECK:"ztree_check"},id:{CHECK:"_check"},checkbox:{STYLE:"checkbox",DEFAULT:"chk",DISABLED:"disable",FALSE:"false",TRUE:"true",FULL:"full",PART:"part",FOCUS:"focus"},radio:{STYLE:"radio",TYPE_ALL:"all",TYPE_LEVEL:"level"}},n={check:{enable:!1,autoCheckTrigger:!1,chkStyle:t.checkbox.STYLE,nocheckInherit:!1,chkDisabledInherit:!1,radioType:t.radio.TYPE_LEVEL,chkboxType:{Y:"ps",N:"ps"}},data:{key:{checked:"checked"}},callback:{beforeCheck:null,onCheck:null}},i={onCheckNode:function(e,t){if(!0===t.chkDisabled)return!1;var n=u.getSetting(e.data.treeId),i=n.data.key.checked;if(0==o.apply(n.callback.beforeCheck,[n.treeId,t],!0))return!0;t[i]=!t[i],l.checkNodeRelation(n,t);var r=c(t,s.id.CHECK,n);return l.setChkClass(n,r,t),l.repairParentChkClassWithSelf(n,t),n.treeObj.trigger(s.event.CHECK,[e,n.treeId,t]),!0},onMouseoverCheck:function(e,t){if(!0===t.chkDisabled)return!1;var n=u.getSetting(e.data.treeId),i=c(t,s.id.CHECK,n);return t.check_Focus=!0,l.setChkClass(n,i,t),!0},onMouseoutCheck:function(e,t){if(!0===t.chkDisabled)return!1;var n=u.getSetting(e.data.treeId),i=c(t,s.id.CHECK,n);return t.check_Focus=!1,l.setChkClass(n,i,t),!0}},r={tools:{},view:{checkNodeRelation:function(e,t){var n,i,r,a=e.data.key.children,o=e.data.key.checked,h=s.radio;if(e.check.chkStyle==h.STYLE){var p=u.getRadioCheckedList(e);if(t[o])if(e.check.radioType==h.TYPE_ALL){for(i=p.length-1;i>=0;i--)(n=p[i])[o]&&n!=t&&(n[o]=!1,p.splice(i,1),l.setChkClass(e,c(n,s.id.CHECK,e),n),n.parentTId!=t.parentTId&&l.repairParentChkClassWithSelf(e,n));p.push(t)}else{var d=t.parentTId?t.getParentNode():u.getRoot(e);for(i=0,r=d[a].length;i<r;i++)(n=d[a][i])[o]&&n!=t&&(n[o]=!1,l.setChkClass(e,c(n,s.id.CHECK,e),n))}else if(e.check.radioType==h.TYPE_ALL)for(i=0,r=p.length;i<r;i++)if(t==p[i]){p.splice(i,1);break}}else t[o]&&(!t[a]||0==t[a].length||e.check.chkboxType.Y.indexOf("s")>-1)&&l.setSonNodeCheckBox(e,t,!0),t[o]||t[a]&&0!=t[a].length&&!(e.check.chkboxType.N.indexOf("s")>-1)||l.setSonNodeCheckBox(e,t,!1),t[o]&&e.check.chkboxType.Y.indexOf("p")>-1&&l.setParentNodeCheckBox(e,t,!0),!t[o]&&e.check.chkboxType.N.indexOf("p")>-1&&l.setParentNodeCheckBox(e,t,!1)},makeChkClass:function(e,t){var n=e.data.key.checked,i=s.checkbox,r=s.radio,a=e.check.chkboxType,o=""===a.Y&&""===a.N;fullStyle="",!0===t.chkDisabled?fullStyle=i.DISABLED:t.halfCheck?fullStyle=i.PART:e.check.chkStyle==r.STYLE?fullStyle=t.check_Child_State<1?i.FULL:i.PART:fullStyle=t[n]?2===t.check_Child_State||-1===t.check_Child_State||o?i.FULL:i.PART:t.check_Child_State<1||o?i.FULL:i.PART;var l=e.check.chkStyle+"_"+(t[n]?i.TRUE:i.FALSE)+"_"+fullStyle;return l=t.check_Focus&&!0!==t.chkDisabled?l+"_"+i.FOCUS:l,s.className.BUTTON+" "+i.DEFAULT+" "+l},repairAllChk:function(e,t){if(e.check.enable&&e.check.chkStyle===s.checkbox.STYLE)for(var n=e.data.key.checked,i=e.data.key.children,r=u.getRoot(e),a=0,o=r[i].length;a<o;a++){var c=r[i][a];!0!==c.nocheck&&!0!==c.chkDisabled&&(c[n]=t),l.setSonNodeCheckBox(e,c,t)}},repairChkClass:function(e,t){if(t&&(u.makeChkFlag(e,t),!0!==t.nocheck)){var n=c(t,s.id.CHECK,e);l.setChkClass(e,n,t)}},repairParentChkClass:function(e,t){if(t&&t.parentTId){var n=t.getParentNode();l.repairChkClass(e,n),l.repairParentChkClass(e,n)}},repairParentChkClassWithSelf:function(e,t){if(t){var n=e.data.key.children;t[n]&&t[n].length>0?l.repairParentChkClass(e,t[n][0]):l.repairParentChkClass(e,t)}},repairSonChkDisabled:function(e,t,n,i){if(t){var r=e.data.key.children;if(t.chkDisabled!=n&&(t.chkDisabled=n),l.repairChkClass(e,t),t[r]&&i)for(var a=0,o=t[r].length;a<o;a++){var s=t[r][a];l.repairSonChkDisabled(e,s,n,i)}}},repairParentChkDisabled:function(e,t,n,i){t&&(t.chkDisabled!=n&&i&&(t.chkDisabled=n),l.repairChkClass(e,t),l.repairParentChkDisabled(e,t.getParentNode(),n,i))},setChkClass:function(e,t,n){t&&(!0===n.nocheck?t.hide():t.show(),t.attr("class",l.makeChkClass(e,n)))},setParentNodeCheckBox:function(e,t,n,i){var r=e.data.key.children,a=e.data.key.checked,o=c(t,s.id.CHECK,e);if(i||(i=t),u.makeChkFlag(e,t),!0!==t.nocheck&&!0!==t.chkDisabled&&(t[a]=n,l.setChkClass(e,o,t),e.check.autoCheckTrigger&&t!=i&&e.treeObj.trigger(s.event.CHECK,[null,e.treeId,t])),t.parentTId){var h=!0;if(!n)for(var p=t.getParentNode()[r],d=0,f=p.length;d<f;d++)if(!0!==p[d].nocheck&&!0!==p[d].chkDisabled&&p[d][a]||(!0===p[d].nocheck||!0===p[d].chkDisabled)&&p[d].check_Child_State>0){h=!1;break}h&&l.setParentNodeCheckBox(e,t.getParentNode(),n,i)}},setSonNodeCheckBox:function(e,t,n,i){if(t){var r=e.data.key.children,a=e.data.key.checked,o=c(t,s.id.CHECK,e);i||(i=t);var h=!1;if(t[r])for(var p=0,d=t[r].length;p<d&&!0!==t.chkDisabled;p++){var f=t[r][p];l.setSonNodeCheckBox(e,f,n,i),!0===f.chkDisabled&&(h=!0)}t!=u.getRoot(e)&&!0!==t.chkDisabled&&(h&&!0!==t.nocheck&&u.makeChkFlag(e,t),!0!==t.nocheck&&!0!==t.chkDisabled?(t[a]=n,h||(t.check_Child_State=t[r]&&t[r].length>0?n?2:0:-1)):t.check_Child_State=-1,l.setChkClass(e,o,t),e.check.autoCheckTrigger&&t!=i&&!0!==t.nocheck&&!0!==t.chkDisabled&&e.treeObj.trigger(s.event.CHECK,[null,e.treeId,t]))}}},event:{},data:{getRadioCheckedList:function(e){for(var t=u.getRoot(e).radioCheckedList,n=0,i=t.length;n<i;n++)u.getNodeCache(e,t[n].tId)||(t.splice(n,1),n--,i--);return t},getCheckStatus:function(e,t){if(!e.check.enable||t.nocheck||t.chkDisabled)return null;var n=e.data.key.checked;return{checked:t[n],half:t.halfCheck?t.halfCheck:e.check.chkStyle==s.radio.STYLE?2===t.check_Child_State:t[n]?t.check_Child_State>-1&&t.check_Child_State<2:t.check_Child_State>0}},getTreeCheckedNodes:function(e,t,n,i){if(!t)return[];var r=e.data.key.children,a=e.data.key.checked,o=n&&e.check.chkStyle==s.radio.STYLE&&e.check.radioType==s.radio.TYPE_ALL;i=i||[];for(var l=0,c=t.length;l<c&&(!0===t[l].nocheck||!0===t[l].chkDisabled||t[l][a]!=n||(i.push(t[l]),!o))&&(u.getTreeCheckedNodes(e,t[l][r],n,i),!(o&&i.length>0));l++);return i},getTreeChangeCheckedNodes:function(e,t,n){if(!t)return[];var i=e.data.key.children,r=e.data.key.checked;n=n||[];for(var a=0,o=t.length;a<o;a++)!0!==t[a].nocheck&&!0!==t[a].chkDisabled&&t[a][r]!=t[a].checkedOld&&n.push(t[a]),u.getTreeChangeCheckedNodes(e,t[a][i],n);return n},makeChkFlag:function(e,t){if(t){var n=e.data.key.children,i=e.data.key.checked,r=-1;if(t[n])for(var a=0,o=t[n].length;a<o;a++){var l=t[n][a],u=-1;if(e.check.chkStyle==s.radio.STYLE){if(2==(u=!0===l.nocheck||!0===l.chkDisabled?l.check_Child_State:!0===l.halfCheck||l[i]||l.check_Child_State>0?2:0)){r=2;break}0==u&&(r=0)}else if(e.check.chkStyle==s.checkbox.STYLE){if(1===(u=!0===l.nocheck||!0===l.chkDisabled?l.check_Child_State:!0===l.halfCheck?1:l[i]?-1===l.check_Child_State||2===l.check_Child_State?2:1:l.check_Child_State>0?1:0)){r=1;break}if(2===u&&r>-1&&a>0&&u!==r){r=1;break}if(2===r&&u>-1&&u<2){r=1;break}u>-1&&(r=u)}}t.check_Child_State=r}}}};e.extend(!0,e.fn.zTree.consts,t),e.extend(!0,e.fn.zTree._z,r);var a=e.fn.zTree,o=a._z.tools,s=a.consts,l=a._z.view,u=a._z.data,c=(a._z.event,o.$);u.exSetting(n),u.addInitBind((function(e){var t=e.treeObj,n=s.event;t.bind(n.CHECK,(function(t,n,i,r){t.srcEvent=n,o.apply(e.callback.onCheck,[t,i,r])}))})),u.addInitUnBind((function(e){var t=e.treeObj,n=s.event;t.unbind(n.CHECK)})),u.addInitCache((function(e){})),u.addInitNode((function(e,t,n,i,r,a,l){if(n){var c=e.data.key.checked;if("string"==typeof n[c]&&(n[c]=o.eqs(n[c],"true")),n[c]=!!n[c],n.checkedOld=n[c],"string"==typeof n.nocheck&&(n.nocheck=o.eqs(n.nocheck,"true")),n.nocheck=!!n.nocheck||e.check.nocheckInherit&&i&&!!i.nocheck,"string"==typeof n.chkDisabled&&(n.chkDisabled=o.eqs(n.chkDisabled,"true")),n.chkDisabled=!!n.chkDisabled||e.check.chkDisabledInherit&&i&&!!i.chkDisabled,"string"==typeof n.halfCheck&&(n.halfCheck=o.eqs(n.halfCheck,"true")),n.halfCheck=!!n.halfCheck,n.check_Child_State=-1,n.check_Focus=!1,n.getCheckStatus=function(){return u.getCheckStatus(e,n)},e.check.chkStyle==s.radio.STYLE&&e.check.radioType==s.radio.TYPE_ALL&&n[c])u.getRoot(e).radioCheckedList.push(n)}})),u.addInitProxy((function(e){var t=e.target,n=u.getSetting(e.data.treeId),r="",a=null,l="",c=null;if(o.eqs(e.type,"mouseover")?n.check.enable&&o.eqs(t.tagName,"span")&&null!==t.getAttribute("treeNode"+s.id.CHECK)&&(r=o.getNodeMainDom(t).id,l="mouseoverCheck"):o.eqs(e.type,"mouseout")?n.check.enable&&o.eqs(t.tagName,"span")&&null!==t.getAttribute("treeNode"+s.id.CHECK)&&(r=o.getNodeMainDom(t).id,l="mouseoutCheck"):o.eqs(e.type,"click")&&n.check.enable&&o.eqs(t.tagName,"span")&&null!==t.getAttribute("treeNode"+s.id.CHECK)&&(r=o.getNodeMainDom(t).id,l="checkNode"),r.length>0)switch(a=u.getNodeCache(n,r),l){case"checkNode":c=i.onCheckNode;break;case"mouseoverCheck":c=i.onMouseoverCheck;break;case"mouseoutCheck":c=i.onMouseoutCheck}return{stop:"checkNode"===l,node:a,nodeEventType:l,nodeEventCallback:c,treeEventType:"",treeEventCallback:null}}),!0),u.addInitRoot((function(e){u.getRoot(e).radioCheckedList=[]})),u.addBeforeA((function(e,t,n){e.data.key.checked;e.check.enable&&(u.makeChkFlag(e,t),n.push("<span ID='",t.tId,s.id.CHECK,"' class='",l.makeChkClass(e,t),"' treeNode",s.id.CHECK,!0===t.nocheck?" style='display:none;'":"","></span>"))})),u.addZTreeTools((function(e,t){t.checkNode=function(e,t,n,i){var r=this.setting.data.key.checked;if(!0!==e.chkDisabled&&(!0!==t&&!1!==t&&(t=!e[r]),i=!!i,(e[r]!==t||n)&&(!i||0!=o.apply(this.setting.callback.beforeCheck,[this.setting.treeId,e],!0))&&o.uCanDo(this.setting)&&this.setting.check.enable&&!0!==e.nocheck)){e[r]=t;var a=c(e,s.id.CHECK,this.setting);(n||this.setting.check.chkStyle===s.radio.STYLE)&&l.checkNodeRelation(this.setting,e),l.setChkClass(this.setting,a,e),l.repairParentChkClassWithSelf(this.setting,e),i&&this.setting.treeObj.trigger(s.event.CHECK,[null,this.setting.treeId,e])}},t.checkAllNodes=function(e){l.repairAllChk(this.setting,!!e)},t.getCheckedNodes=function(e){var t=this.setting.data.key.children;return e=!1!==e,u.getTreeCheckedNodes(this.setting,u.getRoot(this.setting)[t],e)},t.getChangeCheckedNodes=function(){var e=this.setting.data.key.children;return u.getTreeChangeCheckedNodes(this.setting,u.getRoot(this.setting)[e])},t.setChkDisabled=function(e,t,n,i){t=!!t,n=!!n,i=!!i,l.repairSonChkDisabled(this.setting,e,t,i),l.repairParentChkDisabled(this.setting,e.getParentNode(),t,n)};var n=t.updateNode;t.updateNode=function(e,i){if(n&&n.apply(t,arguments),e&&this.setting.check.enable){var r=c(e,this.setting);if(r.get(0)&&o.uCanDo(this.setting)){var a=c(e,s.id.CHECK,this.setting);1!=i&&this.setting.check.chkStyle!==s.radio.STYLE||l.checkNodeRelation(this.setting,e),l.setChkClass(this.setting,a,e),l.repairParentChkClassWithSelf(this.setting,e)}}}}));var h=l.createNodes;l.createNodes=function(e,t,n,i){h&&h.apply(l,arguments),n&&l.repairParentChkClassWithSelf(e,i)};var p=l.removeNode;l.removeNode=function(e,t){var n=t.getParentNode();p&&p.apply(l,arguments),t&&n&&(l.repairChkClass(e,n),l.repairParentChkClass(e,n))};var d=l.appendNodes;l.appendNodes=function(e,t,n,i,r,a){var o="";return d&&(o=d.apply(l,arguments)),i&&u.makeChkFlag(e,i),o}}(BI.jQuery)},function(e,t){BI.ListTreeView=BI.inherit(BI.TreeView,{_constants:{SPLIT:"<|>"},_defaultConfig:function(){return BI.extend(BI.ListTreeView.superclass._defaultConfig.apply(this,arguments),{value:{}})},_init:function(){BI.ListTreeView.superclass._init.apply(this,arguments);var e=this.options;BI.isNotNull(e.value)&&this.setSelectedValue(e.value)},_configSetting:function(){this.options.paras;var e=this;return{async:{enable:!1},check:{enable:!0,chkboxType:{Y:"",N:""}},data:{key:{title:"title",name:"text"},simpleData:{enable:!0}},view:{showIcon:!1,expandSpeed:"",nameIsHTML:!0,dblClickExpand:!1},callback:{onCheck:function(t,n,i){e._selectTreeNode(n,i)},onClick:function(t,n,i){var r=BI.$.fn.zTree.getZTreeObj(n),a=i.checked;e._checkValue(i,!a),r.checkNode(i,!a,!0,!0)}}}},_selectTreeNode:function(e,t){this._checkValue(t,t.checked),BI.ListTreeView.superclass._selectTreeNode.apply(this,arguments)},_transArrayToMap:function(e){var t=this,n={};return BI.each(e,(function(e,i){var r=i.join(t._constants.SPLIT);n[r]=!0})),n},_transMapToArray:function(e){var t=this,n=[];return BI.each(e,(function(e){var i=e.split(t._constants.SPLIT);n.push(i)})),n},_checkValue:function(e,t){var n=BI.concat(this._getParentValues(e),this._getNodeValue(e)).join(this._constants.SPLIT);t?this.storeValue[n]=!0:delete this.storeValue[n]},setSelectedValue:function(e){this.options.paras.selectedValues=e||[],this.storeValue=this._transArrayToMap(e)},getValue:function(){return this._transMapToArray(this.storeValue)}}),BI.shortcut("bi.list_tree_view",BI.ListTreeView)},function(e,t){BI.ListAsyncTree=BI.inherit(BI.ListTreeView,{_defaultConfig:function(){return BI.extend(BI.ListAsyncTree.superclass._defaultConfig.apply(this,arguments),{})},_init:function(){BI.ListAsyncTree.superclass._init.apply(this,arguments)},_configSetting:function(){var e=this.options.paras,t=this;return{async:{enable:!1,otherParam:BI.cjkEncodeDO(e)},check:{enable:!0,chkboxType:{Y:"",N:""}},data:{key:{title:"title",name:"text"},simpleData:{enable:!0}},view:{showIcon:!1,expandSpeed:"",nameIsHTML:!0,dblClickExpand:!1},callback:{onCheck:function(e,n,i){t._selectTreeNode(n,i)},beforeExpand:function(e,n){t._beforeExpandNode(e,n)},beforeCheck:function(e,t){t.half=!1},onClick:function(e,n,i){var r=BI.$.fn.zTree.getZTreeObj(n),a=i.checked;t._checkValue(i,!a),r.checkNode(i,!a,!0,!0)}}}},_beforeExpandNode:function(e,t){var n=this,i=this.options,r=t.parentValues||n._getParentValues(t),a=BI.extend({},i.paras,{id:t.id,times:1,parentValues:r.concat(this._getNodeValue(t))}),o=function(e){var r=e.items||[];r.length>0&&function(e,r){n.nodes.addNodes(t,e),!0===r&&BI.delay((function(){s++,a.times=s,i.itemsCreator(a,o)}),100)}(n._dealWidthNodes(r),!!e.hasNext)},s=1;t.children||setTimeout((function(){i.itemsCreator(a,o)}),17)},hasChecked:function(){return!BI.isEmpty(this.options.paras.selectedValues)||BI.ListAsyncTree.superclass.hasChecked.apply(this,arguments)},stroke:function(e){delete this.options.keyword,BI.extend(this.options.paras,e);var t=this._configSetting();this._initTree(t)}}),BI.shortcut("bi.list_async_tree",BI.ListAsyncTree)},function(e,t){BI.ListPartTree=BI.inherit(BI.ListAsyncTree,{_defaultConfig:function(){return BI.extend(BI.ListPartTree.superclass._defaultConfig.apply(this,arguments),{})},_init:function(){BI.ListPartTree.superclass._init.apply(this,arguments)},_loadMore:function(){var e=this,t=this.options,n=BI.extend({},t.paras,{type:BI.TreeView.REQ_TYPE_INIT_DATA,times:++this.times});this.tip.setLoading(),t.itemsCreator(n,(function(n){var i=!!n.hasNext,r=n.items||[];t.paras.lastSearchValue=n.lastSearchValue,!0!==e._stop&&(i?e.tip.setLoaded():e.tip.setEnd(),r.length>0&&e.nodes.addNodes(null,e._dealWidthNodes(r)))}))},_initTree:function(e,t){var n=this,i=this.options;this.times=1;var r=this.tree;r.empty(),n.tip.setVisible(!1),this.loading();var a=BI.extend({},i.paras,{type:BI.TreeView.REQ_TYPE_INIT_DATA,times:this.times}),o=function(a){if(!0!==n._stop&&t==i.paras.keyword){var o=!!a.hasNext,s=a.items||[];i.paras.lastSearchValue=a.lastSearchValue,function(t){if(!0===n._stop)return;n.nodes=BI.$.fn.zTree.init(r.element,e,t)}(s.length>0?n._dealWidthNodes(s):[]),n.setTipVisible(s.length<=0),n.loaded(),o?n.tip.setLoaded():n.tip.invisible(),n.fireEvent(BI.Events.AFTERINIT)}};BI.delay((function(){i.itemsCreator(a,o)}),100)},stroke:function(e){var t=this.options;delete t.paras.keyword,BI.extend(t.paras,e),delete t.paras.lastSearchValue;var n=this._configSetting();this._initTree(n,t.paras.keyword)}}),BI.shortcut("bi.list_part_tree",BI.ListPartTree)},function(e,t){BI.PartTree=BI.inherit(BI.AsyncTree,{_defaultConfig:function(){return BI.extend(BI.PartTree.superclass._defaultConfig.apply(this,arguments),{})},_loadMore:function(){var e=this,t=this.options,n=BI.extend({},t.paras,{type:BI.TreeView.REQ_TYPE_INIT_DATA,times:++this.times});this.tip.setLoading(),t.itemsCreator(n,(function(n){var i=!!n.hasNext,r=n.items||[];t.paras.lastSearchValue=n.lastSearchValue,!0!==e._stop&&(i?e.tip.setLoaded():e.tip.setEnd(),r.length>0&&e.nodes.addNodes(null,e._dealWidthNodes(r)))}))},_selectTreeNode:function(e,t){var n=this,i=this.options,r=BI.deepClone(t.parentValues||n._getParentValues(t)),a=this._getNodeValue(t);if(!0===t.checked)this.options.paras.selectedValues=this._getUnionValue(),i.itemsCreator(BI.extend({},i.paras,{type:BI.TreeView.REQ_TYPE_ADJUST_DATA,curSelectedValue:a,parentValues:r}),(function(e){n.options.paras.selectedValues=e,BI.AsyncTree.superclass._selectTreeNode.apply(n,arguments)}));else{for(var o=this.options.paras.selectedValues,s=r.concat(a),l=0,u=s.length;l<u;l++){if(null==(o=o[s[l]]))return;if(BI.isEmpty(o))break}i.itemsCreator(BI.extend({},i.paras,{type:BI.TreeView.REQ_TYPE_SELECT_DATA,notSelectedValue:a,parentValues:r}),(function(e){n.options.paras.selectedValues=e,BI.AsyncTree.superclass._selectTreeNode.apply(n,arguments)}))}},_getSelectedValues:function(){var e=this,t={};return function n(i){BI.each(i,(function(i,r){var a=r.getCheckStatus();if(!1===a.checked)return!0;var o=(r.parentValues||e._getParentValues(r)).concat([e._getNodeValue(r)]);if(e._buildTree(t,o),BI.isNotEmptyArray(r.children))return n(r.children),!0;!0===a.half&&e._getHalfSelectedValues(t,r)}))}(this.nodes.getNodes()),t},_initTree:function(e,t){var n=this,i=this.options;this.times=1;var r=this.tree;r.empty(),n.tip.setVisible(!1),this.loading();var a=BI.extend({},i.paras,{type:BI.TreeView.REQ_TYPE_INIT_DATA,times:this.times}),o=function(a){if(!0!==n._stop&&t==i.paras.keyword){var o=!!a.hasNext,s=a.items||[];i.paras.lastSearchValue=a.lastSearchValue,function(t){if(!0===n._stop)return;n.nodes=BI.$.fn.zTree.init(r.element,e,t)}(s.length>0?n._dealWidthNodes(s):[]),n.setTipVisible(s.length<=0),n.loaded(),o?n.tip.setLoaded():n.tip.invisible(),n.fireEvent(BI.Events.AFTERINIT)}};BI.delay((function(){i.itemsCreator(a,o)}),100)},getValue:function(){return BI.deepClone(this.options.paras.selectedValues||{})},_getUnionValue:function(){if(!this.nodes)return{};var e=this._getSelectedValues();return BI.isEmpty(e)?BI.deepClone(this.options.paras.selectedValues):BI.isEmpty(this.options.paras.selectedValues)?e:this._union(e,this.options.paras.selectedValues)},_union:function(e,t){var n=this,i={};function r(e,t,a){BI.each(t,(function(o,s){BI.isNull(a[o])?n._addTreeNode(i,e,o,s):BI.isEmpty(a[o])?n._addTreeNode(i,e,o,{}):r(e.concat([o]),t[o],a[o])}))}return r([],e,t),r([],t,e),i},stroke:function(e){var t=this.options;delete t.paras.keyword,BI.extend(t.paras,e),delete t.paras.lastSearchValue;var n=this._configSetting();this._initTree(n,t.paras.keyword)}}),BI.shortcut("bi.part_tree",BI.PartTree)},function(e,t){BI.DisplayTree=BI.inherit(BI.TreeView,{_defaultConfig:function(){return BI.extend(BI.DisplayTree.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-display-tree"})},_configSetting:function(){return{view:{selectedMulti:!1,dblClickExpand:!1,showIcon:!1,nameIsHTML:!0,showTitle:!1},data:{key:{title:"title",name:"text"},simpleData:{enable:!0}},callback:{beforeCollapse:function(e,t){return!1}}}},_dealWidthNodes:function(e){e=BI.DisplayTree.superclass._dealWidthNodes.apply(this,arguments);this.options;return BI.each(e,(function(e,t){t.isParent=t.isParent||t.parent,null==t.text&&t.count>0&&(t.text=t.value+"("+BI.i18nText("BI-Basic_Altogether")+t.count+BI.i18nText("BI-Basic_Count")+")")})),e},initTree:function(e,t){t=t||this._configSetting();this.nodes=BI.$.fn.zTree.init(this.tree.element,t,e)}}),BI.DisplayTree.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.display_tree",BI.DisplayTree)},function(e,t){BI.ListDisplayTree=BI.inherit(BI.ListTreeView,{_defaultConfig:function(){return BI.extend(BI.ListDisplayTree.superclass._defaultConfig.apply(this,arguments),{extraCls:"bi-list-display-tree"})},_init:function(){BI.ListDisplayTree.superclass._init.apply(this,arguments)},_configSetting:function(){return{view:{selectedMulti:!1,dblClickExpand:!1,showIcon:!1,nameIsHTML:!0,showTitle:!1,fontCss:function(e,t){return t.isLeaf?{}:{color:"#999999"}}},data:{key:{title:"title",name:"text"},simpleData:{enable:!0}},callback:{beforeCollapse:function(e,t){return!1}}}},_dealWidthNodes:function(e){e=BI.ListDisplayTree.superclass._dealWidthNodes.apply(this,arguments);this.options;return BI.each(e,(function(e,t){t.isParent=t.isParent||t.parent,null==t.text&&t.count>0&&(t.text=t.value+"("+BI.i18nText("BI-Basic_Altogether")+t.count+BI.i18nText("BI-Basic_Count")+")")})),e},initTree:function(e,t){t=t||this._configSetting();this.nodes=BI.$.fn.zTree.init(this.tree.element,t,e)},destroy:function(){BI.ListDisplayTree.superclass.destroy.apply(this,arguments)}}),BI.ListDisplayTree.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.list_display_tree",BI.ListDisplayTree)},function(e,t){BI.SimpleTreeView=BI.inherit(BI.Widget,{_defaultConfig:function(){return BI.extend(BI.SimpleTreeView.superclass._defaultConfig.apply(this,arguments),{baseCls:"bi-simple-tree",itemsCreator:BI.emptyFn,items:null})},_init:function(){BI.SimpleTreeView.superclass._init.apply(this,arguments);var e=this,t=this.options;this.structure=new BI.Tree,this.tree=BI.createWidget({type:"bi.tree_view",element:this,itemsCreator:function(n,i){var r=function(t){i({items:t}),e.structure.initTree(BI.Tree.transformToTreeFormat(t))};BI.isNotNull(t.items)?r(t.items):t.itemsCreator(n,r)}}),this.tree.on(BI.TreeView.EVENT_CHANGE,(function(){e.fireEvent(BI.SimpleTreeView.EVENT_CHANGE,arguments)})),BI.isNotEmptyArray(t.items)&&this.populate(),BI.isNotNull(t.value)&&this.setValue(t.value)},populate:function(e,t){e&&(this.options.items=e),this.tree.stroke({keyword:t})},_digest:function(e){e||(e=[]);var t=this,n={},i=[];return BI.each(e,(function(e,r){var a=t.structure.search(r,"value");if(a){var o=a;for((o=o.getParent())&&(n[o.value]||(n[o.value]=0),n[o.value]++);o&&o.getChildrenLength()<=n[o.value];)i.push(o.value),(o=o.getParent())&&(n[o.value]||(n[o.value]=0),n[o.value]++)}})),BI.makeObject(e.concat(i))},setValue:function(e){this.tree.setValue(this._digest(e))},_getValue:function(){var e=[],t=this.tree.getValue(),n=function(t){BI.each(t,(function(t,i){BI.isEmpty(i)?e.push(t):n(i)}))};return n(t),e},empty:function(){this.tree.empty()},getValue:function(){var e=this,t=[],n=this._getValue();return BI.each(n,(function(n,i){var r=e.structure.search(i,"value");r&&e.structure._traverse(r,(function(e){e.isLeaf()&&t.push(e.value)}))})),t}}),BI.SimpleTreeView.EVENT_CHANGE="EVENT_CHANGE",BI.shortcut("bi.simple_tree",BI.SimpleTreeView)},function(e,t){BI.TreeRenderScrollService=BI.inherit(BI.OB,{_init:function(){this.nodeLists={},this.id=this.options.id,this.hasBinded=!1,this.container=this.options.container},_getNodeListBounds:function(e){var t=this.options.subNodeListGetter(e)[0];return{top:t.offsetTop,left:t.offsetLeft,width:t.offsetWidth,height:t.offsetHeight}},_getTreeContainerBounds:function(){var e=this.container[0];return BI.isNotNull(e)?{top:e.offsetTop+e.scrollTop,left:e.offsetLeft+e.scrollLeft,width:e.offsetWidth,height:e.offsetHeight}:{}},_canNodePopulate:function(e){if(this.nodeLists[e].locked)return!1;var t=this._getNodeListBounds(e),n=this._getTreeContainerBounds(e);return t.top+t.height<n.top+n.height},_isNodeInVisible:function(e){var t=this.options.subNodeListGetter(e);return 0===t.length||"none"===t.css("display")},pushNodeList:function(e,t){var n=this;BI.has(this.nodeLists,e)?this.nodeLists[e].locked=!1:this.nodeLists[e]={populate:BI.debounce(t,0),options:{times:1},locked:!1},this.hasBinded||(this.hasBinded=!0,this.container&&this.container.on("scroll",BI.debounce((function(){n.refreshAllNodes()}),30)))},refreshAllNodes:function(){var e=this;BI.each(this.nodeLists,(function(t){!e._isNodeInVisible(t)&&e.refreshNodes(t)}))},refreshNodes:function(e){if(this._canNodePopulate(e)){var t=this.nodeLists[e];t.options.times++,t.locked=!0,t.populate({times:t.options.times})}},removeNodeList:function(e){delete this.nodeLists[e],0===BI.size(this.nodeLists)&&this.clear()},clear:function(){var e=this;BI.each(this.nodeLists,(function(t){e.removeNodeList(t)})),this.nodeLists={},this.container.off("scroll"),this.hasBinded=!1}})},function(e,t){BI.TreeRenderPageService=BI.inherit(BI.OB,{_init:function(){this.nodeLists={}},_getLoadingBar:function(e){var t=this,n=BI.createWidget({type:"bi.loading_bar",height:25,handler:function(){t.refreshNodes(e)}});return n.setLoaded(),n},pushNodeList:function(e,t){var n=this.options,i=this._getLoadingBar(e);BI.has(this.nodeLists,e)?(this.nodeLists[e].loadWidget.destroy(),this.nodeLists[e].loadWidget=i):this.nodeLists[e]={populate:BI.debounce(t,0),options:{times:1},loadWidget:i},BI.createWidget({type:"bi.vertical",element:n.subNodeListGetter(e),items:[i]})},refreshNodes:function(e){var t=this.nodeLists[e];t.options.times++,t.loadWidget.setLoading(),t.populate({times:t.options.times})},removeNodeList:function(e){this.nodeLists[e]&&this.nodeLists[e].loadWidget.destroy(),this.nodeLists[e]&&(this.nodeLists[e].loadWidget=null),delete this.nodeLists[e],0===BI.size(this.nodeLists)&&this.clear()},clear:function(){var e=this;BI.each(this.nodeLists,(function(t){e.removeNodeList(t)})),this.nodeLists={}}})},function(e,t){!function(){var e,t={};function n(){if(this._worker){var n,r=this.getName(),a=this._worker();if(BI.isArray(a)&&(n=a[1],a=a[0]),e){t[r]=this,e.postMessage({type:a,name:r,eventType:"create",options:n,watches:BI.map(this.watch,(function(e){return e}))});return this.store=new Proxy({},{get:function(t,n){return function(){e.postMessage({type:a,name:r,eventType:"action",action:n,args:[].slice.call(arguments)})}},set:function(e,t,n){return Reflect.set(e,t,n)}}),function(){delete t[r],e.postMessage({type:a,name:r,eventType:"destroy"})}}return this.store=BI.Models.getModel(a,n),this.store&&(this.store._widget=this),this.store instanceof Fix.Model?this.model=this.store.model:this.model=this.store,function(e,t){for(var n in e._watchers||(e._watchers=[]),t){var r=t[n];if(BI.isArray(r))for(var a=0;a<r.length;a++)e._watchers.push(i(e,n,r[a]));else e._watchers.push(i(e,n,r))}}(this,this.watch),function(){this.store&&BI.isFunction(this.store.destroy)&&this.store.destroy(),BI.each(this._watchers,(function(e,t){t=BI.isArray(t)?t:[t],BI.each(t,(function(e,t){t()}))})),this._watchers&&(this._watchers=[]),this.store&&(this.store._parent&&(this.store._parent=null),this.store._widget&&(this.store._widget=null),this.store=null)}}}function i(e,t,n,i){return BI.isPlainObject(n)&&(i=n,n=n.handler),i=i||{},Fix.watch(e.model,t,_.bind(n,e),BI.extend(i,{store:e.store}))}BI.useWorker=function(i){e=i;var r=BI.Widget.prototype._init;BI.Widget.prototype._init=function(){this.$destroyWorker=n.call(this);try{r.apply(this,arguments)}catch(e){console.error(e)}};var a=BI.Widget.prototype._initRender,o=function(e){switch(e.eventType){case"create":this.model=e.msg,a.call(this);break;case"watch":var t=e.args;this.watch[e.currentWatchType].apply(this,t)}};BI.Widget.prototype._initRender=function(){e&&this._worker?(this.__asking=!0,this.__async=!0):a.apply(this,arguments)};var s=BI.Widget.prototype.__d;BI.Widget.prototype.__d=function(){this.$destroyWorker&&this.$destroyWorker();try{s.apply(this,arguments)}catch(e){console.error(e)}},e&&e.addEventListener("message",(function(e){var n=e.data;o.apply(t[n.name],[n])}),!1)}}()},,function(e,t,n){e.exports=!n(12)&&!n(6)((function(){return 7!=Object.defineProperty(n(174)("div"),"a",{get:function(){return 7}}).a}))},function(e,t,n){var i=n(5),r=n(11),a=n(38),o=n(175),s=n(13).f;e.exports=function(e){var t=r.Symbol||(r.Symbol=a?{}:i.Symbol||{});"_"==e.charAt(0)||e in t||s(t,e,{value:o.f(e)})}},function(e,t,n){var i=n(19),r=n(21),a=n(77)(!1),o=n(176)("IE_PROTO");e.exports=function(e,t){var n,s=r(e),l=0,u=[];for(n in s)n!=o&&i(s,n)&&u.push(n);for(;t.length>l;)i(s,n=t[l++])&&(~a(u,n)||u.push(n));return u}},function(e,t,n){var i=n(13),r=n(7),a=n(39);e.exports=n(12)?Object.defineProperties:function(e,t){r(e);for(var n,o=a(t),s=o.length,l=0;s>l;)i.f(e,n=o[l++],t[n]);return e}},function(e,t,n){var i=n(21),r=n(42).f,a={}.toString,o="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];e.exports.f=function(e){return o&&"[object Window]"==a.call(e)?function(e){try{return r(e)}catch(t){return o.slice()}}(e):r(i(e))}},function(e,t,n){"use strict";var i=n(12),r=n(39),a=n(78),o=n(63),s=n(15),l=n(62),u=Object.assign;e.exports=!u||n(6)((function(){var e={},t={},n=Symbol(),i="abcdefghijklmnopqrst";return e[n]=7,i.split("").forEach((function(e){t[e]=e})),7!=u({},e)[n]||Object.keys(u({},t)).join("")!=i}))?function(e,t){for(var n=s(e),u=arguments.length,c=1,h=a.f,p=o.f;u>c;)for(var d,f=l(arguments[c++]),g=h?r(f).concat(h(f)):r(f),m=g.length,I=0;m>I;)d=g[I++],i&&!p.call(f,d)||(n[d]=f[d]);return n}:u},function(e,t){e.exports=Object.is||function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}},function(e,t,n){"use strict";var i=n(24),r=n(8),a=n(891),o=[].slice,s={},l=function(e,t,n){if(!(t in s)){for(var i=[],r=0;r<t;r++)i[r]="a["+r+"]";s[t]=Function("F,a","return new F("+i.join(",")+")")}return s[t](e,n)};e.exports=Function.bind||function(e){var t=i(this),n=o.call(arguments,1),s=function(){var i=n.concat(o.call(arguments));return this instanceof s?l(t,i.length,i):a(t,i,e)};return r(t.prototype)&&(s.prototype=t.prototype),s}},function(e,t){e.exports=function(e,t,n){var i=n===undefined;switch(t.length){case 0:return i?e():e.call(n);case 1:return i?e(t[0]):e.call(n,t[0]);case 2:return i?e(t[0],t[1]):e.call(n,t[0],t[1]);case 3:return i?e(t[0],t[1],t[2]):e.call(n,t[0],t[1],t[2]);case 4:return i?e(t[0],t[1],t[2],t[3]):e.call(n,t[0],t[1],t[2],t[3])}return e.apply(n,t)}},function(e,t,n){var i=n(5).parseInt,r=n(55).trim,a=n(180),o=/^[-+]?0[xX]/;e.exports=8!==i(a+"08")||22!==i(a+"0x16")?function(e,t){var n=r(String(e),3);return i(n,t>>>0||(o.test(n)?16:10))}:i},function(e,t,n){var i=n(5).parseFloat,r=n(55).trim;e.exports=1/i(n(180)+"-0")!=-Infinity?function(e){var t=r(String(e),3),n=i(t);return 0===n&&"-"==t.charAt(0)?-0:n}:i},function(e,t,n){var i=n(31);e.exports=function(e,t){if("number"!=typeof e&&"Number"!=i(e))throw TypeError(t);return+e}},function(e,t,n){var i=n(8),r=Math.floor;e.exports=function(e){return!i(e)&&isFinite(e)&&r(e)===e}},function(e,t){e.exports=Math.log1p||function(e){return(e=+e)>-1e-8&&e<1e-8?e-e*e/2:Math.log(1+e)}},function(e,t,n){"use strict";var i=n(41),r=n(36),a=n(54),o={};n(20)(o,n(9)("iterator"),(function(){return this})),e.exports=function(e,t,n){e.prototype=i(o,{next:r(1,n)}),a(e,t+" Iterator")}},function(e,t,n){var i=n(7);e.exports=function(e,t,n,r){try{return r?t(i(n)[0],n[1]):t(n)}catch(o){var a=e["return"];throw a!==undefined&&i(a.call(e)),o}}},function(e,t,n){var i=n(1029);e.exports=function(e,t){return new(i(e))(t)}},function(e,t,n){var i=n(24),r=n(15),a=n(62),o=n(10);e.exports=function(e,t,n,s,l){i(t);var u=r(e),c=a(u),h=o(u.length),p=l?h-1:0,d=l?-1:1;if(n<2)for(;;){if(p in c){s=c[p],p+=d;break}if(p+=d,l?p<0:h<=p)throw TypeError("Reduce of empty array with no initial value")}for(;l?p>=0:h>p;p+=d)p in c&&(s=t(s,c[p],p,u));return s}},function(e,t,n){"use strict";var i=n(15),r=n(40),a=n(10);e.exports=[].copyWithin||function(e,t){var n=i(this),o=a(n.length),s=r(e,o),l=r(t,o),u=arguments.length>2?arguments[2]:undefined,c=Math.min((u===undefined?o:r(u,o))-l,o-s),h=1;for(l<s&&s<l+c&&(h=-1,l+=c-1,s+=c-1);c-- >0;)l in n?n[s]=n[l]:delete n[s],s+=h,l+=h;return n}},function(e,t){e.exports=function(e,t){return{value:t,done:!!e}}},function(e,t,n){"use strict";var i=n(195);n(0)({target:"RegExp",proto:!0,forced:i!==/./.exec},{exec:i})},function(e,t,n){n(12)&&"g"!=/./g.flags&&n(13).f(RegExp.prototype,"flags",{configurable:!0,get:n(81)})},function(e,t,n){"use strict";var i,r,a,o,s=n(38),l=n(5),u=n(23),c=n(64),h=n(0),p=n(8),d=n(24),f=n(58),g=n(84),m=n(65),I=n(197).set,B=n(1049)(),_=n(906),E=n(1050),b=n(85),y=n(907),v="Promise",T=l.TypeError,C=l.process,N=C&&C.versions,V=N&&N.v8||"",S=l.Promise,x="process"==c(C),w=function(){},A=r=_.f,L=!!function(){try{var e=S.resolve(1),t=(e.constructor={})[n(9)("species")]=function(e){e(w,w)};return(x||"function"==typeof PromiseRejectionEvent)&&e.then(w)instanceof t&&0!==V.indexOf("6.6")&&-1===b.indexOf("Chrome/66")}catch(i){}}(),k=function(e){var t;return!(!p(e)||"function"!=typeof(t=e.then))&&t},D=function(e,t){if(!e._n){e._n=!0;var n=e._c;B((function(){for(var i=e._v,r=1==e._s,a=0,o=function(t){var n,a,o,s=r?t.ok:t.fail,l=t.resolve,u=t.reject,c=t.domain;try{s?(r||(2==e._h&&R(e),e._h=1),!0===s?n=i:(c&&c.enter(),n=s(i),c&&(c.exit(),o=!0)),n===t.promise?u(T("Promise-chain cycle")):(a=k(n))?a.call(n,l,u):l(n)):u(i)}catch(h){c&&!o&&c.exit(),u(h)}};n.length>a;)o(n[a++]);e._c=[],e._n=!1,t&&!e._h&&M(e)}))}},M=function(e){I.call(l,(function(){var t,n,i,r=e._v,a=P(e);if(a&&(t=E((function(){x?C.emit("unhandledRejection",r,e):(n=l.onunhandledrejection)?n({promise:e,reason:r}):(i=l.console)&&i.error&&i.error("Unhandled promise rejection",r)})),e._h=x||P(e)?2:1),e._a=undefined,a&&t.e)throw t.v}))},P=function(e){return 1!==e._h&&0===(e._a||e._c).length},R=function(e){I.call(l,(function(){var t;x?C.emit("rejectionHandled",e):(t=l.onrejectionhandled)&&t({promise:e,reason:e._v})}))},H=function(e){var t=this;t._d||(t._d=!0,(t=t._w||t)._v=e,t._s=2,t._a||(t._a=t._c.slice()),D(t,!0))},O=function(e){var t,n=this;if(!n._d){n._d=!0,n=n._w||n;try{if(n===e)throw T("Promise can't be resolved itself");(t=k(e))?B((function(){var i={_w:n,_d:!1};try{t.call(e,u(O,i,1),u(H,i,1))}catch(r){H.call(i,r)}})):(n._v=e,n._s=1,D(n,!1))}catch(i){H.call({_w:n,_d:!1},i)}}};L||(S=function(e){f(this,S,v,"_h"),d(e),i.call(this);try{e(u(O,this,1),u(H,this,1))}catch(t){H.call(this,t)}},(i=function(e){this._c=[],this._a=undefined,this._s=0,this._d=!1,this._v=undefined,this._h=0,this._n=!1}).prototype=n(59)(S.prototype,{then:function(e,t){var n=A(m(this,S));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=x?C.domain:undefined,this._c.push(n),this._a&&this._a.push(n),this._s&&D(this,!1),n.promise},"catch":function(e){return this.then(undefined,e)}}),a=function(){var e=new i;this.promise=e,this.resolve=u(O,e,1),this.reject=u(H,e,1)},_.f=A=function(e){return e===S||e===o?new a(e):r(e)}),h(h.G+h.W+h.F*!L,{Promise:S}),n(54)(S,v),n(57)(v),o=n(11).Promise,h(h.S+h.F*!L,v,{reject:function(e){var t=A(this);return(0,t.reject)(e),t.promise}}),h(h.S+h.F*(s||!L),v,{resolve:function(e){return y(s&&this===o?S:this,e)}}),h(h.S+h.F*!(L&&n(80)((function(e){S.all(e)["catch"](w)}))),v,{all:function(e){var t=this,n=A(t),i=n.resolve,r=n.reject,a=E((function(){var n=[],a=0,o=1;g(e,!1,(function(e){var s=a++,l=!1;n.push(undefined),o++,t.resolve(e).then((function(e){l||(l=!0,n[s]=e,--o||i(n))}),r)})),--o||i(n)}));return a.e&&r(a.v),n.promise},race:function(e){var t=this,n=A(t),i=n.reject,r=E((function(){g(e,!1,(function(e){t.resolve(e).then(n.resolve,i)}))}));return r.e&&i(r.v),n.promise}})},function(e,t,n){"use strict";var i=n(24);function r(e){var t,n;this.promise=new e((function(e,i){if(t!==undefined||n!==undefined)throw TypeError("Bad Promise constructor");t=e,n=i})),this.resolve=i(t),this.reject=i(n)}e.exports.f=function(e){return new r(e)}},function(e,t,n){var i=n(7),r=n(8),a=n(906);e.exports=function(e,t){if(i(e),r(t)&&t.constructor===e)return t;var n=a.f(e);return(0,n.resolve)(t),n.promise}},function(e,t,n){"use strict";var i=n(13).f,r=n(41),a=n(59),o=n(23),s=n(58),l=n(84),u=n(186),c=n(902),h=n(57),p=n(12),d=n(35).fastKey,f=n(45),g=p?"_s":"size",m=function(e,t){var n,i=d(t);if("F"!==i)return e._i[i];for(n=e._f;n;n=n.n)if(n.k==t)return n};e.exports={getConstructor:function(e,t,n,u){var c=e((function(e,i){s(e,c,t,"_i"),e._t=t,e._i=r(null),e._f=undefined,e._l=undefined,e[g]=0,i!=undefined&&l(i,n,e[u],e)}));return a(c.prototype,{clear:function(){for(var e=f(this,t),n=e._i,i=e._f;i;i=i.n)i.r=!0,i.p&&(i.p=i.p.n=undefined),delete n[i.i];e._f=e._l=undefined,e[g]=0},"delete":function(e){var n=f(this,t),i=m(n,e);if(i){var r=i.n,a=i.p;delete n._i[i.i],i.r=!0,a&&(a.n=r),r&&(r.p=a),n._f==i&&(n._f=r),n._l==i&&(n._l=a),n[g]--}return!!i},forEach:function(e){f(this,t);for(var n,i=o(e,arguments.length>1?arguments[1]:undefined,3);n=n?n.n:this._f;)for(i(n.v,n.k,this);n&&n.r;)n=n.p},has:function(e){return!!m(f(this,t),e)}}),p&&i(c.prototype,"size",{get:function(){return f(this,t)[g]}}),c},def:function(e,t,n){var i,r,a=m(e,t);return a?a.v=n:(e._l=a={i:r=d(t,!0),k:t,v:n,p:i=e._l,n:undefined,r:!1},e._f||(e._f=a),i&&(i.n=a),e[g]++,"F"!==r&&(e._i[r]=a)),e},getEntry:m,setStrong:function(e,t,n){u(e,t,(function(e,n){this._t=f(e,t),this._k=n,this._l=undefined}),(function(){for(var e=this,t=e._k,n=e._l;n&&n.r;)n=n.p;return e._t&&(e._l=n=n?n.n:e._t._f)?c(0,"keys"==t?n.k:"values"==t?n.v:[n.k,n.v]):(e._t=undefined,c(1))}),n?"entries":"values",!n,!0),h(t)}}},function(e,t,n){"use strict";var i=n(59),r=n(35).getWeak,a=n(7),o=n(8),s=n(58),l=n(84),u=n(28),c=n(19),h=n(45),p=u(5),d=u(6),f=0,g=function(e){return e._l||(e._l=new m)},m=function(){this.a=[]},I=function(e,t){return p(e.a,(function(e){return e[0]===t}))};m.prototype={get:function(e){var t=I(this,e);if(t)return t[1]},has:function(e){return!!I(this,e)},set:function(e,t){var n=I(this,e);n?n[1]=t:this.a.push([e,t])},"delete":function(e){var t=d(this.a,(function(t){return t[0]===e}));return~t&&this.a.splice(t,1),!!~t}},e.exports={getConstructor:function(e,t,n,a){var u=e((function(e,i){s(e,u,t,"_i"),e._t=t,e._i=f++,e._l=undefined,i!=undefined&&l(i,n,e[a],e)}));return i(u.prototype,{"delete":function(e){if(!o(e))return!1;var n=r(e);return!0===n?g(h(this,t))["delete"](e):n&&c(n,this._i)&&delete n[this._i]},has:function(e){if(!o(e))return!1;var n=r(e);return!0===n?g(h(this,t)).has(e):n&&c(n,this._i)}}),u},def:function(e,t,n){var i=r(a(t),!0);return!0===i?g(e).set(t,n):i[e._i]=n,e},ufstore:g}},function(e,t,n){var i=n(25),r=n(10);e.exports=function(e){if(e===undefined)return 0;var t=i(e),n=r(t);if(t!==n)throw RangeError("Wrong length!");return n}},function(e,t,n){var i=n(42),r=n(78),a=n(7),o=n(5).Reflect;e.exports=o&&o.ownKeys||function(e){var t=i.f(a(e)),n=r.f;return n?t.concat(n(e)):t}},function(e,t,n){var i=n(10),r=n(182),a=n(32);e.exports=function(e,t,n,o){var s=String(a(e)),l=s.length,u=n===undefined?" ":String(n),c=i(t);if(c<=l||""==u)return s;var h=c-l,p=r.call(u,Math.ceil(h/u.length));return p.length>h&&(p=p.slice(0,h)),o?p+s:s+p}},function(e,t,n){var i=n(12),r=n(39),a=n(21),o=n(63).f;e.exports=function(e){return function(t){for(var n,s=a(t),l=r(s),u=l.length,c=0,h=[];u>c;)n=l[c++],i&&!o.call(s,n)||h.push(e?[n,s[n]]:s[n]);return h}}},function(e,t){var n=e.exports={version:"2.6.11"};"number"==typeof __e&&(__e=n)},function(e,t){e.exports=function(e){try{return!!e()}catch(t){return!0}}},function(e,t){!function(){function e(e,n){for(var i in e._watchers||(e._watchers=[]),n){var r=n[i];if(BI.isArray(r))for(var a=0;a<r.length;a++)e._watchers.push(t(e,i,r[a]));else e._watchers.push(t(e,i,r))}BI.each(e.$watchDelayCallbacks,(function(n,i){var r=i[0],a=i[1];if(BI.isKey(r)){var o=r;(r={})[o]=a}for(var o in r){var s=r[o];if(BI.isArray(s))for(n=0;n<s.length;n++)e._watchers.push(t(e,o,s[n]));else e._watchers.push(t(e,o,s))}}))}function t(e,t,n,i){return BI.isPlainObject(n)&&(i=n,n=n.handler),i=i||{},Fix.watch(e.model,t,_.bind(n,e),BI.extend(i,{store:e.store}))}var n=null,i=[];function r(e){n&&i.push(n),Fix.Model.target=n=e}function a(){Fix.Model.target=n=i.pop()}var o=Fix.watch;function s(){var e=!1;if(_global.Fix&&this._store){var t=function(e){if(null!=n)return n;for(var t=e=e||BI.Widget.context;t&&!(t instanceof Fix.Model||t.store||t.__cacheStore);)t=t._parent||t.options&&t.options.element||t._context;return t?t instanceof Fix.Model?e.__cacheStore=t:(e.__cacheStore=t.store||t.__cacheStore,t.__cacheStore||t.store):void 0}(this.options.context||this._parent||this.options.element||this._context);t&&(r(t),e=!0),this.store=this._store(),this.store&&(this.store._widget=this),e&&a(),e=!1,r(this.store),this.store instanceof Fix.Model?this.model=this.store.model:this.model=this.store,e=!0}return e}Fix.watch=function(e,t,n,i){return BI.isPlainObject(n)&&(i=n,n=n.handler),"string"==typeof n&&(n=e[n]),o.call(this,e,t,(function(){i&&i.store&&r(i.store);try{var e=n.apply(this,arguments)}catch(t){console.error(t)}return i&&i.store&&a(),e}),i)},_.each(["populate","addItems","prependItems"],(function(e){var t=BI.Loader.prototype[e];BI.Loader.prototype[e]=function(){BI.Widget.pushContext(this);try{var e=t.apply(this,arguments)}catch(n){console.error(n)}return BI.Widget.popContext(),e}}));var l=BI.Widget.prototype._init;BI.Widget.prototype._init=function(){var e=s.call(this);try{l.apply(this,arguments)}catch(t){console.error(t)}e&&a()};var u=BI.Widget.prototype._render;BI.Widget.prototype._render=function(){var t=!1;_global.Fix&&this._store&&(t=!0,r(this.store),e(this,this.watch)),u.apply(this,arguments),t&&a()};var c=BI.Widget.prototype.__d;BI.Widget.prototype.__d=function(){try{c.apply(this,arguments)}catch(e){console.error(e)}this.store&&BI.isFunction(this.store.destroy)&&this.store.destroy(),BI.each(this._watchers,(function(e,t){t=BI.isArray(t)?t:[t],BI.each(t,(function(e,t){t()}))})),this._watchers&&(this._watchers=[]),this.store&&(this.store._parent&&(this.store._parent=null),this.store._widget&&(this.store._widget=null),this.store=null),delete this.__cacheStore},_.each(["_mount","__afterMount"],(function(e){var t=BI.Widget.prototype[e];t&&(BI.Widget.prototype[e]=function(){this.store&&r(this.store);try{var e=t.apply(this,arguments)}catch(n){console.error(n)}return this.store&&a(),e})})),BI.isIE9Below&&BI.isIE9Below()&&(_.each(["each","map","reduce","reduceRight","find","filter","reject","every","all","some","any","max","min","sortBy","groupBy","indexBy","countBy","partition","keys","allKeys","values","pairs","invert","mapObject","findKey","pick","omit","tap"],(function(e){var t=BI[e];BI[e]=function(e,n,i){return"function"==typeof n?t(e,(function(e,t){if(!(e in Fix.$$skipArray))return n.apply(this,arguments)}),i):t.apply(this,arguments)}})),BI.isEmpty=function(e){return BI.isPlainObject(e)&&e.__ob__?0===BI.keys(e).length:_.isEmpty(e)},BI.keys=function(e){for(var t=_.keys(e),n=[],i=0;i<t.length;i++)t[i]in Fix.$$skipArray||n.push(t[i]);return n},BI.values=function(e){for(var t=BI.keys(obj),n=t.length,i=[],r=0;r<n;r++)i[r]=obj[t[r]];return i},BI.extend=function(){var e=Array.prototype.slice.call(arguments);if(e.length<1)return{};for(var t=e[0],n=1;n<e.length;)BI.each(e[n],(function(e,n){t[e]=n})),n++;return t},BI.size=function(e){return BI.isPlainObject(e)&&e.__ob__?BI.keys(e).length:_.size(e)},BI.isEmptyObject=function(e){return 0===BI.size(e)},BI.deepClone=function(e){return Fix.toJSON(e)})}()},function(e,t){Array.prototype.indexOf||(Array.prototype.indexOf=function(e,t){var n;if(null==this)throw new TypeError('"this" is null or not defined');var i=Object(this),r=i.length>>>0;if(0===r)return-1;var a=0|t;if(a>=r)return-1;for(n=Math.max(a>=0?a:r-Math.abs(a),0);n<r;){if(n in i&&i[n]===e)return n;n++}return-1}),Array.prototype.lastIndexOf||(Array.prototype.lastIndexOf=function(e){"use strict";if(null==this)throw new TypeError;var t,n,i=Object(this),r=i.length>>>0;if(0===r)return-1;for(t=r-1,arguments.length>1&&((t=Number(arguments[1]))!=t?t=0:0!=t&&t!=1/0&&t!=-1/0&&(t=(t>0||-1)*Math.floor(Math.abs(t)))),n=t>=0?Math.min(t,r-1):r-Math.abs(t);n>=0;n--)if(n in i&&i[n]===e)return n;return-1})},function(e,t){var n;_global.console=_global.console||((n={}).log=n.warn=n.debug=n.info=n.error=n.time=n.dir=n.profile=n.clear=n.exception=n.trace=n.assert=function(){},n)},function(e,t){_global.localStorage||(_global.localStorage={items:{},setItem:function(e,t){BI.Cache.addCookie(e,t)},getItem:function(e){return BI.Cache.getCookie(e)},removeItem:function(e){BI.Cache.deleteCookie(e)},key:function(){},clear:function(){this.items={}}})},function(e,t){Object.keys||(Object.keys=function(e){if(e!==Object(e))throw new TypeError("Object.keys called on a non-object");var t,n,i={__ob__:t,$accessors:t,$vbthis:t,$vbsetter:t},r=[];for(n in e)n in i||Object.prototype.hasOwnProperty.call(e,n)&&r.push(n);return r}),Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),Date.now||(Date.now=function(){return(new Date).valueOf()})},function(e,t){"undefined"!=typeof Set&&Set.toString().match(/native code/)||(Set=function(){this.set={}},Set.prototype.has=function(e){return this.set[e]!==undefined},Set.prototype.add=function(e){this.set[e]=1},Set.prototype.clear=function(){this.set={}})},function(e,t){!function(e){var t=e.navigator.userAgent.toLowerCase();if(/msie/.test(t)){var n=Array.prototype.sort;Array.prototype.sort=function(e){if(e&&"function"==typeof e){if(this.length<2)return this;for(var t,i=0,r=i+1,a=this.length,o=0;i<a;i++)for(r=i+1;r<a;r++)!0===("number"==typeof(o=e.call(this,this[i],this[r]))?o:o?1:0)>0&&(t=this[i],this[i]=this[r],this[r]=t);return this}return n.call(this)}}}(window)},,,,function(e,t,n){(function(t){e.exports=t.Fix=n(927)}).call(this,n(14))},function(e,t,n){(function(e){function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}!function(t){"use strict";function i(e,t,n){}function r(e){return"function"==typeof e&&/native code/.test(e.toString())}var a=/\d\.\d{4}/;function o(e){return e=e||"bi",String(Math.random()+Math.random()).replace(a,e)}var s="__proto__"in{},l=function(){if("undefined"==typeof navigator)return!1;var e=navigator.userAgent.toLowerCase(),t=e.match(/(?:msie\s([\w.]+))/),n=e.match(/(?:trident.*rv:([\w.]+))/);return t&&n&&t[1]&&n[1]?Math.max(1*t[1],1*n[1]):t&&t[1]?1*t[1]:n&&n[1]?1*n[1]:0},u="undefined"!=typeof navigator&&/(msie|trident)/i.test(navigator.userAgent.toLowerCase())&&l()<9,c=Object.prototype.toString;function h(e){return"[object Object]"===c.call(e)}function p(e,t){var n=!0,i=Object.getOwnPropertyDescriptor&&Object.getOwnPropertyDescriptor(e,t);return i&&!1===i.configurable&&(n=!1),n}function d(e){if(Object.isExtensible)return Object.isExtensible(e);for(var t="";e.hasOwnProperty(t);)t+="?";e[t]=!0;var n=e.hasOwnProperty(t);return delete e[t],n}function f(e,t){if(e&&e.length){var n=e.indexOf(t);if(n>-1)return e.splice(n,1)}}var g=/[^\w.$]/;function m(e){if(!g.test(e)){var t=e.split(".");return function(e){for(var n=0;n<t.length;n++){if(!e)return;e=e[t[n]]}return e}}}var I,B=function(){var t=[],n=!1,i=void 0;function a(){n=!1;var e=t.slice(0);t.length=0;for(var i=0;i<e.length;i++)e[i]()}if(void 0!==e&&r(e))i=function(){e(a)};else if("undefined"==typeof MessageChannel||!r(MessageChannel)&&"[object MessageChannelConstructor]"!==MessageChannel.toString())if("undefined"!=typeof Promise&&r(Promise)){var o=Promise.resolve();i=function(){o.then(a)}}else i=function(){setTimeout(a,0)};else{var s=new MessageChannel,l=s.port2;s.port1.onmessage=a,i=function(){l.postMessage(1)}}return function(e,r){var a=void 0;if(t.push((function(){if(e)try{e.call(r)}catch(t){console.error(t)}else a&&a(r)})),n||(n=!0,i()),!e&&"undefined"!=typeof Promise)return new Promise((function(e,t){a=e}))}}(),E={__ob__:I,$accessors:I,$vbthis:I,$vbsetter:I},b=0,y=function(){function e(){n(this,e),this.id=b++,this.subs=[]}return e.prototype.addSub=function(e){this.subs.push(e)},e.prototype.removeSub=function(e){f(this.subs,e)},e.prototype.depend=function(){e.target&&e.target.addDep(this)},e.prototype.notify=function(e){for(var t=this.subs.slice(),n=0,i=t.length;n<i;n++)t[n].update(e)},e}();y.target=null;var v=[];function T(e){y.target&&v.push(y.target),y.target=e}function C(){y.target=v.pop()}var N=!0;try{Object.defineProperty({},"_",{value:"x"}),delete E.$vbsetter,delete E.$vbthis}catch(Re){N=!1}var V=Object.defineProperties,S=void 0,x=new Date-0;if(!N&&("__defineGetter__"in{}&&(S=function(e,t,n){return"value"in n&&(e[t]=n.value),"get"in n&&e.__defineGetter__(t,n.get),"set"in n&&e.__defineSetter__(t,n.set),e},V=function(e,t){for(var n in t)t.hasOwnProperty(n)&&S(e,n,t[n]);return e}),u)){var w={};window.execScript(["Function parseVB(code)","\tExecuteGlobal(code)","End Function"].join("\n"),"VBScript");var A=function(e,t,n,i){var r=t[n];if(4!==arguments.length)return r.get.call(e);r.set.call(e,i)};V=function(e,t,n){var i=[];i.push("\tPrivate [$vbsetter]","\tPublic [$accessors]","\tPublic Default Function [$vbthis](ac"+x+", s"+x+")","\t\tSet [$accessors] = ac"+x+": set [$vbsetter] = s"+x,"\t\tSet [$vbthis] = Me","\tEnd Function");var r={$vbthis:!0,$vbsetter:!0,$accessors:!0};for(e in E)r[e]||(i.push("\tPublic ["+e+"]"),r[e]=!0);for(e in t)r[e]||(r[e]=!0,i.push("\tPublic Property Let ["+e+"](val"+x+")",'\t\tCall [$vbsetter](Me, [$accessors], "'+e+'", val'+x+")","\tEnd Property","\tPublic Property Set ["+e+"](val"+x+")",'\t\tCall [$vbsetter](Me, [$accessors], "'+e+'", val'+x+")","\tEnd Property","\tPublic Property Get ["+e+"]","\tOn Error Resume Next","\t\tSet["+e+'] = [$vbsetter](Me, [$accessors],"'+e+'")',"\tIf Err.Number <> 0 Then","\t\t["+e+'] = [$vbsetter](Me, [$accessors],"'+e+'")',"\tEnd If","\tOn Error Goto 0","\tEnd Property"));for(e in n)r[e]||(r[e]=!0,i.push("\tPublic ["+e+"]"));i.push("\tPublic [hasOwnProperty]"),i.push("End Class");var a=i.join("\r\n"),s=w[a];return s||(s=o("VBClass"),window.parseVB("Class "+s+a),window.parseVB(["Function "+s+"Factory(acc, vbm)","\tDim o","\tSet o = (New "+s+")(acc, vbm)","\tSet "+s+"Factory = o","End Function"].join("\r\n")),w[a]=s),window[s+"Factory"](t,A)}}var L=V,k=[],D=[],M={},P=!1,R=!1,H=0;function O(){H=k.length=D.length=0,M={},P=R=!1}function F(){R=!0;var e=void 0,t=void 0,n=void 0;for(k.sort((function(e,t){return e.id-t.id})),H=0;H<k.length;H++)e=k[H].watcher,n=k[H].options,t=e.id,M[t]=null,e.run(n);O()}function Y(e,t){var n=e.id;if(null==M[n]){if(M[n]=!0,R){for(var i=k.length-1;i>H&&k[i].watcher.id>e.id;)i--;k.splice(i+1,0,{watcher:e,options:t})}else k.push({watcher:e,options:t});P||(P=!0,B(F))}}var W=0,G=function(){function e(t,i,r,a){n(this,e),this.vm=t,a?(this.deep=!!a.deep,this.user=!!a.user,this.lazy=!!a.lazy,this.sync=!!a.sync):this.deep=this.user=this.lazy=this.sync=!1,this.cb=r,this.id=++W,this.active=!0,this.dirty=this.lazy,this.deps=[],this.newDeps=[],this.depIds=new Set,this.newDepIds=new Set,this.expression="","function"==typeof i?this.getter=i:(this.getter=m(i),this.getter||(this.getter=function(){})),this.value=this.lazy?undefined:this.get()}return e.prototype.get=function(){T(this);var e=void 0,t=this.vm;try{e=this.getter.call(t,t)}catch(Re){}finally{this.deep&&Z(e),C(),this.cleanupDeps()}return e},e.prototype.addDep=function(e){var t=e.id;this.newDepIds.has(t)||(this.newDepIds.add(t),this.newDeps.push(e),this.depIds.has(t)||e.addSub(this))},e.prototype.cleanupDeps=function(){for(var e=this.deps.length;e--;){var t=this.deps[e];this.newDepIds.has(t.id)||t.removeSub(this)}var n=this.depIds;this.depIds=this.newDepIds,this.newDepIds=n,this.newDepIds.clear(),n=this.deps,this.deps=this.newDeps,this.newDeps=n,this.newDeps.length=0},e.prototype.update=function(e){this.lazy?this.dirty=!0:this.sync?this.run(e):Y(this,e)},e.prototype.run=function(e){if(this.active){var t=this.get();if(t!==this.value||_.isObject(t)&&e&&e.refresh||this.deep){var n=this.value;if(this.value=t,this.user)try{this.cb.call(this.vm,t,n,e)}catch(Re){console.error(Re)}else try{this.cb.call(this.vm,t,n,e)}catch(Re){console.error(Re)}}}},e.prototype.evaluate=function(){this.value=this.get(),this.dirty=!1},e.prototype.depend=function(){for(var e=this.deps.length;e--;)this.deps[e].depend()},e.prototype.teardown=function(){if(this.active){f(this.vm._watchers,this);for(var e=this.deps.length;e--;)this.deps[e].removeSub(this);this.active=!1}},e}(),j=new Set;function Z(e){j.clear(),X(e,j)}function X(e,t){var n=void 0,i=void 0,r=_.isArray(e);if(r||_.isObject(e)){if(e.__ob__){var a=e.__ob__.dep.id;if(t.has(a))return;t.add(a)}if(r)for(n=e.length;n--;)X(e[n],t);else for(n=(i=_.keys(e)).length;n--;)X(e[i[n]],t)}}var U=Array.prototype,J=[];_.each(["push","pop","shift","unshift","splice","sort","reverse"],(function(e){var t=U[e];J[e]=function(){for(var n=arguments.length,i=Array(n),r=0;r<n;r++)i[r]=arguments[r];var a=this.__ob__,o=void 0;switch(e){case"push":case"unshift":o=i;break;case"splice":o=i.slice(2)}switch(o&&(o=a.observeArray(o)),e){case"push":case"unshift":i=o;break;case"splice":i.length>2&&(i=[i[0],i[1]].concat(o||[]))}var s=t.apply(this,i);return ie(a.parent,a.parentKey,a.dep,!0),s}}));var K=_.keys(J),z={shouldConvert:!0};function Q(e,t,n,i){Object.defineProperty(e,t,{value:n,enumerable:!!i,writable:!0,configurable:!0})}var q,$=function(){function e(t){n(this,e),this.value=t,this.dep=new y,this.vmCount=0,_.isArray(t)?((s?ee:te)(t,J,K),this.model=this.observeArray(t)):this.model=this.walk(t),u?this.model.__ob__=this:Q(this.model,"__ob__",this)}return e.prototype.walk=function(e){return re(e,this)},e.prototype.observeArray=function(e){for(var t=0,n=e.length;t<n;t++){var i=ne(e[t],this,t);e[t]=i?i.model:e[t]}return e},e}();function ee(e,t,n){e.__proto__=t}function te(e,t,n){for(var i=0,r=n.length;i<r;i++){var a=n[i];e[a]=t[a]}}function ne(e,t,n){if(_.isObject(e)){var i=void 0;return e.__ob__ instanceof $?i=e.__ob__:z.shouldConvert&&d(e)&&(_.isArray(e)||h(e))&&(i=new $(e)),i&&(i.parent=t||i.parent,i.parentKey=n),i}}function ie(e,t,n,i){if(n.notify({observer:e,key:t,refresh:i}),e){_.each(e._deps,(function(n){n.notify({observer:e,key:t})}));for(var r=e,a=e,o=t||"";r;)_.each(r._scopeDeps,(function(n){n.notify({observer:e,key:t})})),null!=r.parentKey&&(o=r.parentKey+"."+o),a=r,r=r.parent;for(var s in a._globalDeps)if(new RegExp(s).test(o))for(var l=0;l<a._globalDeps[s].length;l++)a._globalDeps[s][l].notify({observer:e,key:s})}}function re(e,t,n){var i={},r=void 0;return _.each(e,(function(a,o){if(!(o in E)){var s=p(e,o),l=t&&t["__dep"+o]||new y;t&&(t["__dep"+o]=l);var u=s&&!n&&ne(a,t,o);i[o]={enumerable:!0,configurable:!0,get:function(){var e=u?u.model:a;return y.target&&(l.depend(),u&&(u.dep.depend(),_.isArray(e)&&se(e))),e},set:function(i){var c=u?u.model:a;i===c||i!=i&&c!=c||(a=i,(u=s&&!n&&ne(i,t,o))&&c&&c.__ob__&&(u._scopeDeps=c.__ob__._scopeDeps,u._deps=c.__ob__._deps),e[o]=u?u.model:i,ie(r.__ob__,o,l))}}}})),r=L(e,i)}function ae(e,t,n){if(_.isArray(e))return e.length=Math.max(e.length,t),e.splice(t,1,n),n;if(_.has(e,t))return e[t]=n,n;var i=e.__ob__;return i?(i.value[t]=n,e=re(i.value,i),ie(i,t,i.dep),e):(e[t]=n,n)}function oe(e,t){if(_.isArray(e))e.splice(t,1);else{var n=e.__ob__;if(_.has(e,t))return n?(delete n.value[t],e=re(n.value,n),ie(n,t,n.dep),e):(delete e[t],e)}}function se(e){for(var t,n=0,i=e.length;n<i;n++)(t=e[n])&&t.__ob__&&t.__ob__.dep.depend(),_.isArray(t)&&se(t)}var le={"||":q,"&&":q,"(":q,")":q};function ue(e){for(var t="",n=0,i=e.length;n<i;n++)_.isBoolean(e[n])||_.has(le,e[n])?t+=e[n]:t+="false";return new Function("return "+t)()}function ce(e){return"^"+(e=e.replace(/\*\*/g,"[a-zA-Z0-9_]+").replace(/\*./g,"[a-zA-Z0-9_]+."))+"$"}function he(e,t,n,i){h(n)&&(i=n,n=n.handler),"string"==typeof n&&(n=e[n]),(i=i||{}).user=!0;var r=void 0;if(_.isFunction(t)||!(r=t.match(/[a-zA-Z0-9_.*]+|[|][|]|[&][&]|[(]|[)]/g))||1===r.length&&!/\*/.test(t)){var a=new G(e,t,n,i);return i.immediate&&n(a.value),function(){a.teardown()}}var o=[],s=r.slice(),l=!1,u=!1,c=function(e,t,a,o){!0!==l&&(s[e]=!0,ue(s)&&(l=!0,n(t,a,o)),i&&i.sync?(l=!1,u=!1,s=r.slice()):u||(u=!0,B((function(){l=!1,u=!1,s=r.slice()}))))};return _.each(r,(function(t,n){if(!_.has(le,t))if(/^[1-9a-zA-Z.]+(\*\*$|\*$)/.test(t)||"**"===t){var r=/\*\*$/.test(t),a=("**"===(t=r?t.replace(".**",""):t.replace(".*",""))?function(e){return e}:m(t)).call(e,e),s=new y;r?(a.__ob__._scopeDeps||(a.__ob__._scopeDeps=[])).push(s):(a.__ob__._deps||(a.__ob__._deps=[])).push(s);var l=new G(e,(function(){return s.depend(),NaN}),(function(e,t,i){c(n,e,t,_.extend({index:n},i))}),i);o.push((function(){l.teardown(),a.__ob__._scopeDeps&&f(a.__ob__._scopeDeps,s),a.__ob__._deps&&f(a.__ob__._deps,s)}))}else if(/^(\*\*\.)+[1-9a-zA-Z]+(\.\*\*$)/.test(t)){var u=t.split("."),h=e[u[1]];t=u[1]+".**";for(var p=h.__ob__.parent,d=h.__ob__;p;)t="*."+t,d=p,p=p.parent;var g=ce(t),I=new y;d._globalDeps||(d._globalDeps={}),_.isArray(d._globalDeps[g])?d._globalDeps[g].push(I):d._globalDeps[g]=[I];var B=new G(h,(function(){return I.depend(),NaN}),(function(e,t,i){c(n,e,t,_.extend({index:n},i))}),i);o.push((function(){d._globalDeps&&(f(d._globalDeps[g],I),0===d._globalDeps[g].length&&(delete d._globalDeps[g],B.teardown()))}))}else{if(/\*\*$|\*$/.test(t))throw new Error("not support");if(/\*/.test(t)){for(var E=e,b=t.split("."),v=0,T=b.length;v<T&&"*"!==b[v];v++)E=e[b[v]];t=t.substr(t.indexOf("*"));for(var C=E.__ob__.parent,N=E.__ob__;C;)t="*."+t,N=C,C=C.parent;var V=ce(t),S=new y;N._globalDeps||(N._globalDeps={}),_.isArray(N._globalDeps[V])?N._globalDeps[V].push(S):N._globalDeps[V]=[S];var x=new G(E,(function(){return S.depend(),NaN}),(function(e,t,i){c(n,e,t,_.extend({index:n},i))}),i);o.push((function(){N._globalDeps&&(f(N._globalDeps[V],S),0===N._globalDeps[V].length&&(delete N._globalDeps[V],x.teardown()))}))}else{var w=new G(e,t,(function(e,t,i){c(n,e,t,_.extend({index:n},i))}),i);o.push((function(){w.teardown()}))}}})),o}var pe={};function de(e){return pe[e]}function fe(e,t){pe[e]=_.cloneDeep(t)}var ge={lazy:!0},me=!0;function Ie(e,t){t&&(e.$$state=me?ne(t).model:t)}function Be(e,t){var n=e._computedWatchers={};for(var i in be(e,t),t)n[i]=_e(e,t[i])}function _e(e,t){var n=e.$$model?e.model:e,r="function"==typeof t?t:t.get;return new G(n,r||i,i,ge)}function Ee(e,t,n){var r=!0,a={enumerable:!0,configurable:!0,get:i,set:i};return"function"==typeof n?(a.get=ye(e,t),a.set=i):(a.get=n.get?r&&!1!==n.cache?ye(e,t):n.get:i,a.set=n.set?n.set:i),a}function be(e,t){var n={};for(var i in t)i in e||(n[i]=Ee(e,i,t[i]));e.$$computed=L({},n)}function ye(e,t){return function(){var n=e._computedWatchers&&e._computedWatchers[t];if(n)return n.dirty&&n.evaluate(),me&&y.target&&n.depend(),n.value}}function ve(e,t){for(var n in e._watchers||(e._watchers=[]),t){var i=t[n];if(_.isArray(i))for(var r=0;r<i.length;r++)e._watchers.push(Te(e,n,i[r]));else e._watchers.push(Te(e,n,i))}}function Te(e,t,n,i){return h(n)&&(i=n,n=n.handler),"string"==typeof n&&(n=e[n]),he(e.model,t,_.bind(n,e.$$model?e.model:e),i)}function Ce(e,t){for(var n in t)e[n]=null==t[n]?i:_.bind(t[n],e.$$model?e.model:e)}function Ne(e,t){t=t||[],_.each(t.reverse(),(function(t){var n=de(t);for(var i in n)"function"==typeof n[i]&&(_.has(e,i)||(e[i]=_.bind(n[i],e.$$model?e.model:e)))}))}function Ve(e,t){for(var n={},i=function(i,r){var a=t[i];a in E||(n[a]={enumerable:!0,configurable:!0,get:function(){if(e.$$computed&&a in e.$$computed)return e.$$computed[a];if(e.$$state&&a in e.$$state)return e.$$state[a];if(e.$$model&&a in e.$$model)return e.$$model[a];for(var t=e._parent;t;){if(t.$$context&&a in t.$$context)return t.$$context[a];t=t._parent}},set:function(t){if(e.$$state&&a in e.$$state)return e.$$state[a]=t;if(e.$$model&&a in e.$$model)return e.$$model[a]=t;for(var n=e._parent;n;){if(n.$$context&&a in n.$$context)return n.$$context[a]=t;n=n._parent}}})},r=0,a=t.length;r<a;r++)i(r,a);e.model=L({},n)}function Se(e,t){for(var n={},i=function(i,r){var a=t[i];a in E||(n[a]={enumerable:!0,configurable:!0,get:function(){return e.model[a]},set:function(t){return e.model[a]=t}})},r=0,a=t.length;r<a;r++)i(r,a);e.$$context=L({},n)}function xe(e,t){for(var n=e._parent;n;){if(n.$$context&&t in n.$$context)return n.$$context[t];n=n._parent}}function we(e){var t=e.inject||[],n={};return _.each(t,(function(t){n[t]=xe(e,t)})),n}var Ae=function(){function e(){n(this,e)}return e.prototype._constructor=function(t,n){(t instanceof $||t instanceof e)&&(t=t.model),t&&t.__ob__?this.$$model=t:this.options=t||{},this._parent=e.target;var i=_.isFunction(this.state)?this.state():this.state,r=this.computed,a=this.context,o=this.inject,s=this.childContext,l=this.watch,u=this.actions,c=_.keys(this.$$model).concat(_.keys(i)).concat(_.keys(r)).concat(o||[]).concat(a||[]),h=this.mixins;if(Ve(this,c),s&&Se(this,s),this.$$model&&(this.model.__ob__=this.$$model.__ob__),Ne(this,h),this.init(),Ie(this,_.extend(we(this),i)),Be(this,r),me&&ve(this,l),Ce(this,u),this.created&&this.created(),this._destroyHandler=n,this.$$model)return this.model},e.prototype._init=function(){},e.prototype.init=function(){this._init()},e.prototype.destroy=function(){for(var e in this._computedWatchers)this._computedWatchers[e].teardown();_.each(this._watchers,(function(e){e=_.isArray(e)?e:[e],_.each(e,(function(e){e()}))})),this._watchers&&(this._watchers=[]),this.destroyed&&this.destroyed(),this.$$model=null,this.$$computed=null,this.$$state=null,this._destroyHandler&&this._destroyHandler()},e}();function Le(e){return me?new $(e).model:e}var ke=Le;function De(e){e||(e={}),"reactive"in e&&(me=e.reactive)}function Me(e){var t=void 0;if(_.isArray(e)){t=[];for(var n=0,i=e.length;n<i;n++)t[n]=Me(e[n])}else if(e&&h(e))for(var r in t={},e)_.has(E,r)||(t[r]=Me(e[r]));else t=e;return t}var Pe="2.0";t.version=Pe,t.$$skipArray=E,t.mixin=fe,t.Model=Ae,t.define=Le,t.reactive=ke,t.config=De,t.observerState=z,t.Observer=$,t.observe=ne,t.notify=ie,t.defineReactive=re,t.set=ae,t.del=oe,t.Watcher=G,t.pushTarget=T,t.popTarget=C,t.watch=he,t.toJSON=Me,t.__esModule=!0}(t)}).call(this,n(61).setImmediate)},,,,,,,,function(e,t,n){"use strict";n(936);var i=function(e){return e&&e.__esModule?e:{"default":e}}(n(1109));i["default"]._babelPolyfill&&"undefined"!=typeof console&&console.warn&&console.warn("@babel/polyfill is loaded more than once on this page. This is probably not desirable/intended and may have consequences if different versions of the polyfills are applied sequentially. If you do need to load the polyfill more than once, use @babel/polyfill/noConflict instead to bypass the warning."),i["default"]._babelPolyfill=!0},function(e,t,n){"use strict";n(937),n(1080),n(1082),n(1085),n(1087),n(1089),n(1091),n(1093),n(1095),n(1097),n(1099),n(1101),n(1103),n(1107)},function(e,t,n){n(938),n(941),n(942),n(943),n(944),n(945),n(946),n(947),n(948),n(949),n(950),n(951),n(952),n(953),n(954),n(955),n(956),n(957),n(958),n(959),n(960),n(961),n(962),n(963),n(964),n(965),n(966),n(967),n(968),n(969),n(970),n(971),n(972),n(973),n(974),n(975),n(976),n(977),n(978),n(979),n(980),n(981),n(982),n(984),n(985),n(986),n(987),n(988),n(989),n(990),n(991),n(992),n(993),n(994),n(995),n(996),n(997),n(998),n(999),n(1e3),n(1001),n(1002),n(1003),n(1004),n(1005),n(1006),n(1007),n(1008),n(1009),n(1010),n(1011),n(1012),n(1013),n(1014),n(1015),n(1016),n(1017),n(1019),n(1020),n(1022),n(1023),n(1024),n(1025),n(1026),n(1027),n(1028),n(1030),n(1031),n(1032),n(1033),n(1034),n(1035),n(1036),n(1037),n(1038),n(1039),n(1040),n(1041),n(1042),n(194),n(1043),n(903),n(1044),n(904),n(1045),n(1046),n(1047),n(1048),n(905),n(1051),n(1052),n(1053),n(1054),n(1055),n(1056),n(1057),n(1058),n(1059),n(1060),n(1061),n(1062),n(1063),n(1064),n(1065),n(1066),n(1067),n(1068),n(1069),n(1070),n(1071),n(1072),n(1073),n(1074),n(1075),n(1076),n(1077),n(1078),n(1079),e.exports=n(11)},function(e,t,n){"use strict";var i=n(5),r=n(19),a=n(12),o=n(0),s=n(17),l=n(35).KEY,u=n(6),c=n(76),h=n(54),p=n(37),d=n(9),f=n(175),g=n(884),m=n(940),I=n(79),B=n(7),_=n(8),E=n(15),b=n(21),y=n(34),v=n(36),T=n(41),C=n(887),N=n(26),V=n(78),S=n(13),x=n(39),w=N.f,A=S.f,L=C.f,k=i.Symbol,D=i.JSON,M=D&&D.stringify,P=d("_hidden"),R=d("toPrimitive"),H={}.propertyIsEnumerable,O=c("symbol-registry"),F=c("symbols"),Y=c("op-symbols"),W=Object.prototype,G="function"==typeof k&&!!V.f,j=i.QObject,Z=!j||!j.prototype||!j.prototype.findChild,X=a&&u((function(){return 7!=T(A({},"a",{get:function(){return A(this,"a",{value:7}).a}})).a}))?function(e,t,n){var i=w(W,t);i&&delete W[t],A(e,t,n),i&&e!==W&&A(W,t,i)}:A,U=function(e){var t=F[e]=T(k.prototype);return t._k=e,t},J=G&&"symbol"==typeof k.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof k},K=function(e,t,n){return e===W&&K(Y,t,n),B(e),t=y(t,!0),B(n),r(F,t)?(n.enumerable?(r(e,P)&&e[P][t]&&(e[P][t]=!1),n=T(n,{enumerable:v(0,!1)})):(r(e,P)||A(e,P,v(1,{})),e[P][t]=!0),X(e,t,n)):A(e,t,n)},z=function(e,t){B(e);for(var n,i=m(t=b(t)),r=0,a=i.length;a>r;)K(e,n=i[r++],t[n]);return e},Q=function(e){var t=H.call(this,e=y(e,!0));return!(this===W&&r(F,e)&&!r(Y,e))&&(!(t||!r(this,e)||!r(F,e)||r(this,P)&&this[P][e])||t)},q=function(e,t){if(e=b(e),t=y(t,!0),e!==W||!r(F,t)||r(Y,t)){var n=w(e,t);return!n||!r(F,t)||r(e,P)&&e[P][t]||(n.enumerable=!0),n}},$=function(e){for(var t,n=L(b(e)),i=[],a=0;n.length>a;)r(F,t=n[a++])||t==P||t==l||i.push(t);return i},ee=function(e){for(var t,n=e===W,i=L(n?Y:b(e)),a=[],o=0;i.length>o;)!r(F,t=i[o++])||n&&!r(W,t)||a.push(F[t]);return a};G||(s((k=function(){if(this instanceof k)throw TypeError("Symbol is not a constructor!");var e=p(arguments.length>0?arguments[0]:undefined),t=function(n){this===W&&t.call(Y,n),r(this,P)&&r(this[P],e)&&(this[P][e]=!1),X(this,e,v(1,n))};return a&&Z&&X(W,e,{configurable:!0,set:t}),U(e)}).prototype,"toString",(function(){return this._k})),N.f=q,S.f=K,n(42).f=C.f=$,n(63).f=Q,V.f=ee,a&&!n(38)&&s(W,"propertyIsEnumerable",Q,!0),f.f=function(e){return U(d(e))}),o(o.G+o.W+o.F*!G,{Symbol:k});for(var te="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),ne=0;te.length>ne;)d(te[ne++]);for(var ie=x(d.store),re=0;ie.length>re;)g(ie[re++]);o(o.S+o.F*!G,"Symbol",{"for":function(e){return r(O,e+="")?O[e]:O[e]=k(e)},keyFor:function(e){if(!J(e))throw TypeError(e+" is not a symbol!");for(var t in O)if(O[t]===e)return t},useSetter:function(){Z=!0},useSimple:function(){Z=!1}}),o(o.S+o.F*!G,"Object",{create:function(e,t){return t===undefined?T(e):z(T(e),t)},defineProperty:K,defineProperties:z,getOwnPropertyDescriptor:q,getOwnPropertyNames:$,getOwnPropertySymbols:ee});var ae=u((function(){V.f(1)}));o(o.S+o.F*ae,"Object",{getOwnPropertySymbols:function(e){return V.f(E(e))}}),D&&o(o.S+o.F*(!G||u((function(){var e=k();return"[null]"!=M([e])||"{}"!=M({a:e})||"{}"!=M(Object(e))}))),"JSON",{stringify:function(e){for(var t,n,i=[e],r=1;arguments.length>r;)i.push(arguments[r++]);if(n=t=i[1],(_(t)||e!==undefined)&&!J(e))return I(t)||(t=function(e,t){if("function"==typeof n&&(t=n.call(this,e,t)),!J(t))return t}),i[1]=t,M.apply(D,i)}}),k.prototype[R]||n(20)(k.prototype,R,k.prototype.valueOf),h(k,"Symbol"),h(Math,"Math",!0),h(i.JSON,"JSON",!0)},function(e,t,n){e.exports=n(76)("native-function-to-string",Function.toString)},function(e,t,n){var i=n(39),r=n(78),a=n(63);e.exports=function(e){var t=i(e),n=r.f;if(n)for(var o,s=n(e),l=a.f,u=0;s.length>u;)l.call(e,o=s[u++])&&t.push(o);return t}},function(e,t,n){var i=n(0);i(i.S,"Object",{create:n(41)})},function(e,t,n){var i=n(0);i(i.S+i.F*!n(12),"Object",{defineProperty:n(13).f})},function(e,t,n){var i=n(0);i(i.S+i.F*!n(12),"Object",{defineProperties:n(886)})},function(e,t,n){var i=n(21),r=n(26).f;n(27)("getOwnPropertyDescriptor",(function(){return function(e,t){return r(i(e),t)}}))},function(e,t,n){var i=n(15),r=n(43);n(27)("getPrototypeOf",(function(){return function(e){return r(i(e))}}))},function(e,t,n){var i=n(15),r=n(39);n(27)("keys",(function(){return function(e){return r(i(e))}}))},function(e,t,n){n(27)("getOwnPropertyNames",(function(){return n(887).f}))},function(e,t,n){var i=n(8),r=n(35).onFreeze;n(27)("freeze",(function(e){return function(t){return e&&i(t)?e(r(t)):t}}))},function(e,t,n){var i=n(8),r=n(35).onFreeze;n(27)("seal",(function(e){return function(t){return e&&i(t)?e(r(t)):t}}))},function(e,t,n){var i=n(8),r=n(35).onFreeze;n(27)("preventExtensions",(function(e){return function(t){return e&&i(t)?e(r(t)):t}}))},function(e,t,n){var i=n(8);n(27)("isFrozen",(function(e){return function(t){return!i(t)||!!e&&e(t)}}))},function(e,t,n){var i=n(8);n(27)("isSealed",(function(e){return function(t){return!i(t)||!!e&&e(t)}}))},function(e,t,n){var i=n(8);n(27)("isExtensible",(function(e){return function(t){return!!i(t)&&(!e||e(t))}}))},function(e,t,n){var i=n(0);i(i.S+i.F,"Object",{assign:n(888)})},function(e,t,n){var i=n(0);i(i.S,"Object",{is:n(889)})},function(e,t,n){var i=n(0);i(i.S,"Object",{setPrototypeOf:n(179).set})},function(e,t,n){"use strict";var i=n(64),r={};r[n(9)("toStringTag")]="z",r+""!="[object z]"&&n(17)(Object.prototype,"toString",(function(){return"[object "+i(this)+"]"}),!0)},function(e,t,n){var i=n(0);i(i.P,"Function",{bind:n(890)})},function(e,t,n){var i=n(13).f,r=Function.prototype,a=/^\s*function ([^ (]*)/,o="name";o in r||n(12)&&i(r,o,{configurable:!0,get:function(){try{return(""+this).match(a)[1]}catch(e){return""}}})},function(e,t,n){"use strict";var i=n(8),r=n(43),a=n(9)("hasInstance"),o=Function.prototype;a in o||n(13).f(o,a,{value:function(e){if("function"!=typeof this||!i(e))return!1;if(!i(this.prototype))return e instanceof this;for(;e=r(e);)if(this.prototype===e)return!0;return!1}})},function(e,t,n){var i=n(0),r=n(892);i(i.G+i.F*(parseInt!=r),{parseInt:r})},function(e,t,n){var i=n(0),r=n(893);i(i.G+i.F*(parseFloat!=r),{parseFloat:r})},function(e,t,n){"use strict";var i=n(5),r=n(19),a=n(31),o=n(181),s=n(34),l=n(6),u=n(42).f,c=n(26).f,h=n(13).f,p=n(55).trim,d="Number",f=i.Number,g=f,m=f.prototype,I=a(n(41)(m))==d,B="trim"in String.prototype,_=function(e){var t=s(e,!1);if("string"==typeof t&&t.length>2){var n,i,r,a=(t=B?t.trim():p(t,3)).charCodeAt(0);if(43===a||45===a){if(88===(n=t.charCodeAt(2))||120===n)return NaN}else if(48===a){switch(t.charCodeAt(1)){case 66:case 98:i=2,r=49;break;case 79:case 111:i=8,r=55;break;default:return+t}for(var o,l=t.slice(2),u=0,c=l.length;u<c;u++)if((o=l.charCodeAt(u))<48||o>r)return NaN;return parseInt(l,i)}}return+t};if(!f(" 0o1")||!f("0b1")||f("+0x1")){f=function(e){var t=arguments.length<1?0:e,n=this;return n instanceof f&&(I?l((function(){m.valueOf.call(n)})):a(n)!=d)?o(new g(_(t)),n,f):_(t)};for(var E,b=n(12)?u(g):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger".split(","),y=0;b.length>y;y++)r(g,E=b[y])&&!r(f,E)&&h(f,E,c(g,E));f.prototype=m,m.constructor=f,n(17)(i,d,f)}},function(e,t,n){"use strict";var i=n(0),r=n(25),a=n(894),o=n(182),s=1..toFixed,l=Math.floor,u=[0,0,0,0,0,0],c="Number.toFixed: incorrect invocation!",h="0",p=function(e,t){for(var n=-1,i=t;++n<6;)i+=e*u[n],u[n]=i%1e7,i=l(i/1e7)},d=function(e){for(var t=6,n=0;--t>=0;)n+=u[t],u[t]=l(n/e),n=n%e*1e7},f=function(){for(var e=6,t="";--e>=0;)if(""!==t||0===e||0!==u[e]){var n=String(u[e]);t=""===t?n:t+o.call(h,7-n.length)+n}return t},g=function(e,t,n){return 0===t?n:t%2==1?g(e,t-1,n*e):g(e*e,t/2,n)};i(i.P+i.F*(!!s&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!n(6)((function(){s.call({})}))),"Number",{toFixed:function(e){var t,n,i,s,l=a(this,c),u=r(e),m="",I=h;if(u<0||u>20)throw RangeError(c);if(l!=l)return"NaN";if(l<=-1e21||l>=1e21)return String(l);if(l<0&&(m="-",l=-l),l>1e-21)if(n=(t=function(e){for(var t=0,n=e;n>=4096;)t+=12,n/=4096;for(;n>=2;)t+=1,n/=2;return t}(l*g(2,69,1))-69)<0?l*g(2,-t,1):l/g(2,t,1),n*=4503599627370496,(t=52-t)>0){for(p(0,n),i=u;i>=7;)p(1e7,0),i-=7;for(p(g(10,i,1),0),i=t-1;i>=23;)d(1<<23),i-=23;d(1<<i),p(1,1),d(2),I=f()}else p(0,n),p(1<<-t,0),I=f()+o.call(h,u);return I=u>0?m+((s=I.length)<=u?"0."+o.call(h,u-s)+I:I.slice(0,s-u)+"."+I.slice(s-u)):m+I}})},function(e,t,n){"use strict";var i=n(0),r=n(6),a=n(894),o=1..toPrecision;i(i.P+i.F*(r((function(){return"1"!==o.call(1,undefined)}))||!r((function(){o.call({})}))),"Number",{toPrecision:function(e){var t=a(this,"Number#toPrecision: incorrect invocation!");return e===undefined?o.call(t):o.call(t,e)}})},function(e,t,n){var i=n(0);i(i.S,"Number",{EPSILON:Math.pow(2,-52)})},function(e,t,n){var i=n(0),r=n(5).isFinite;i(i.S,"Number",{isFinite:function(e){return"number"==typeof e&&r(e)}})},function(e,t,n){var i=n(0);i(i.S,"Number",{isInteger:n(895)})},function(e,t,n){var i=n(0);i(i.S,"Number",{isNaN:function(e){return e!=e}})},function(e,t,n){var i=n(0),r=n(895),a=Math.abs;i(i.S,"Number",{isSafeInteger:function(e){return r(e)&&a(e)<=9007199254740991}})},function(e,t,n){var i=n(0);i(i.S,"Number",{MAX_SAFE_INTEGER:9007199254740991})},function(e,t,n){var i=n(0);i(i.S,"Number",{MIN_SAFE_INTEGER:-9007199254740991})},function(e,t,n){var i=n(0),r=n(893);i(i.S+i.F*(Number.parseFloat!=r),"Number",{parseFloat:r})},function(e,t,n){var i=n(0),r=n(892);i(i.S+i.F*(Number.parseInt!=r),"Number",{parseInt:r})},function(e,t,n){var i=n(0),r=n(896),a=Math.sqrt,o=Math.acosh;i(i.S+i.F*!(o&&710==Math.floor(o(Number.MAX_VALUE))&&o(Infinity)==Infinity),"Math",{acosh:function(e){return(e=+e)<1?NaN:e>94906265.62425156?Math.log(e)+Math.LN2:r(e-1+a(e-1)*a(e+1))}})},function(e,t,n){var i=n(0),r=Math.asinh;i(i.S+i.F*!(r&&1/r(0)>0),"Math",{asinh:function a(e){return isFinite(e=+e)&&0!=e?e<0?-a(-e):Math.log(e+Math.sqrt(e*e+1)):e}})},function(e,t,n){var i=n(0),r=Math.atanh;i(i.S+i.F*!(r&&1/r(-0)<0),"Math",{atanh:function(e){return 0==(e=+e)?e:Math.log((1+e)/(1-e))/2}})},function(e,t,n){var i=n(0),r=n(183);i(i.S,"Math",{cbrt:function(e){return r(e=+e)*Math.pow(Math.abs(e),1/3)}})},function(e,t,n){var i=n(0);i(i.S,"Math",{clz32:function(e){return(e>>>=0)?31-Math.floor(Math.log(e+.5)*Math.LOG2E):32}})},function(e,t,n){var i=n(0),r=Math.exp;i(i.S,"Math",{cosh:function(e){return(r(e=+e)+r(-e))/2}})},function(e,t,n){var i=n(0),r=n(184);i(i.S+i.F*(r!=Math.expm1),"Math",{expm1:r})},function(e,t,n){var i=n(0);i(i.S,"Math",{fround:n(983)})},function(e,t,n){var i=n(183),r=Math.pow,a=r(2,-52),o=r(2,-23),s=r(2,127)*(2-o),l=r(2,-126);e.exports=Math.fround||function(e){var t,n,r=Math.abs(e),u=i(e);return r<l?u*function(e){return e+1/a-1/a}(r/l/o)*l*o:(n=(t=(1+o/a)*r)-(t-r))>s||n!=n?u*Infinity:u*n}},function(e,t,n){var i=n(0),r=Math.abs;i(i.S,"Math",{hypot:function(e,t){for(var n,i,a=0,o=0,s=arguments.length,l=0;o<s;)l<(n=r(arguments[o++]))?(a=a*(i=l/n)*i+1,l=n):a+=n>0?(i=n/l)*i:n;return l===Infinity?Infinity:l*Math.sqrt(a)}})},function(e,t,n){var i=n(0),r=Math.imul;i(i.S+i.F*n(6)((function(){return-5!=r(4294967295,5)||2!=r.length})),"Math",{imul:function(e,t){var n=65535,i=+e,r=+t,a=n&i,o=n&r;return 0|a*o+((n&i>>>16)*o+a*(n&r>>>16)<<16>>>0)}})},function(e,t,n){var i=n(0);i(i.S,"Math",{log10:function(e){return Math.log(e)*Math.LOG10E}})},function(e,t,n){var i=n(0);i(i.S,"Math",{log1p:n(896)})},function(e,t,n){var i=n(0);i(i.S,"Math",{log2:function(e){return Math.log(e)/Math.LN2}})},function(e,t,n){var i=n(0);i(i.S,"Math",{sign:n(183)})},function(e,t,n){var i=n(0),r=n(184),a=Math.exp;i(i.S+i.F*n(6)((function(){return-2e-17!=!Math.sinh(-2e-17)})),"Math",{sinh:function(e){return Math.abs(e=+e)<1?(r(e)-r(-e))/2:(a(e-1)-a(-e-1))*(Math.E/2)}})},function(e,t,n){var i=n(0),r=n(184),a=Math.exp;i(i.S,"Math",{tanh:function(e){var t=r(e=+e),n=r(-e);return t==Infinity?1:n==Infinity?-1:(t-n)/(a(e)+a(-e))}})},function(e,t,n){var i=n(0);i(i.S,"Math",{trunc:function(e){return(e>0?Math.floor:Math.ceil)(e)}})},function(e,t,n){var i=n(0),r=n(40),a=String.fromCharCode,o=String.fromCodePoint;i(i.S+i.F*(!!o&&1!=o.length),"String",{fromCodePoint:function(e){for(var t,n=[],i=arguments.length,o=0;i>o;){if(t=+arguments[o++],r(t,1114111)!==t)throw RangeError(t+" is not a valid code point");n.push(t<65536?a(t):a(55296+((t-=65536)>>10),t%1024+56320))}return n.join("")}})},function(e,t,n){var i=n(0),r=n(21),a=n(10);i(i.S,"String",{raw:function(e){for(var t=r(e.raw),n=a(t.length),i=arguments.length,o=[],s=0;n>s;)o.push(String(t[s++])),s<i&&o.push(String(arguments[s]));return o.join("")}})},function(e,t,n){"use strict";n(55)("trim",(function(e){return function(){return e(this,3)}}))},function(e,t,n){"use strict";var i=n(185)(!0);n(186)(String,"String",(function(e){this._t=String(e),this._i=0}),(function(){var e,t=this._t,n=this._i;return n>=t.length?{value:undefined,done:!0}:(e=i(t,n),this._i+=e.length,{value:e,done:!1})}))},function(e,t,n){"use strict";var i=n(0),r=n(185)(!1);i(i.P,"String",{codePointAt:function(e){return r(this,e)}})},function(e,t,n){"use strict";var i=n(0),r=n(10),a=n(187),o="endsWith",s="".endsWith;i(i.P+i.F*n(189)(o),"String",{endsWith:function(e){var t=a(this,e,o),n=arguments.length>1?arguments[1]:undefined,i=r(t.length),l=n===undefined?i:Math.min(r(n),i),u=String(e);return s?s.call(t,u,l):t.slice(l-u.length,l)===u}})},function(e,t,n){"use strict";var i=n(0),r=n(187),a="includes";i(i.P+i.F*n(189)(a),"String",{includes:function(e){return!!~r(this,e,a).indexOf(e,arguments.length>1?arguments[1]:undefined)}})},function(e,t,n){var i=n(0);i(i.P,"String",{repeat:n(182)})},function(e,t,n){"use strict";var i=n(0),r=n(10),a=n(187),o="startsWith",s="".startsWith;i(i.P+i.F*n(189)(o),"String",{startsWith:function(e){var t=a(this,e,o),n=r(Math.min(arguments.length>1?arguments[1]:undefined,t.length)),i=String(e);return s?s.call(t,i,n):t.slice(n,n+i.length)===i}})},function(e,t,n){"use strict";n(18)("anchor",(function(e){return function(t){return e(this,"a","name",t)}}))},function(e,t,n){"use strict";n(18)("big",(function(e){return function(){return e(this,"big","","")}}))},function(e,t,n){"use strict";n(18)("blink",(function(e){return function(){return e(this,"blink","","")}}))},function(e,t,n){"use strict";n(18)("bold",(function(e){return function(){return e(this,"b","","")}}))},function(e,t,n){"use strict";n(18)("fixed",(function(e){return function(){return e(this,"tt","","")}}))},function(e,t,n){"use strict";n(18)("fontcolor",(function(e){return function(t){return e(this,"font","color",t)}}))},function(e,t,n){"use strict";n(18)("fontsize",(function(e){return function(t){return e(this,"font","size",t)}}))},function(e,t,n){"use strict";n(18)("italics",(function(e){return function(){return e(this,"i","","")}}))},function(e,t,n){"use strict";n(18)("link",(function(e){return function(t){return e(this,"a","href",t)}}))},function(e,t,n){"use strict";n(18)("small",(function(e){return function(){return e(this,"small","","")}}))},function(e,t,n){"use strict";n(18)("strike",(function(e){return function(){return e(this,"strike","","")}}))},function(e,t,n){"use strict";n(18)("sub",(function(e){return function(){return e(this,"sub","","")}}))},function(e,t,n){"use strict";n(18)("sup",(function(e){return function(){return e(this,"sup","","")}}))},function(e,t,n){var i=n(0);i(i.S,"Date",{now:function(){return(new Date).getTime()}})},function(e,t,n){"use strict";var i=n(0),r=n(15),a=n(34);i(i.P+i.F*n(6)((function(){return null!==new Date(NaN).toJSON()||1!==Date.prototype.toJSON.call({toISOString:function(){return 1}})})),"Date",{toJSON:function(e){var t=r(this),n=a(t);return"number"!=typeof n||isFinite(n)?t.toISOString():null}})},function(e,t,n){var i=n(0),r=n(1018);i(i.P+i.F*(Date.prototype.toISOString!==r),"Date",{toISOString:r})},function(e,t,n){"use strict";var i=n(6),r=Date.prototype.getTime,a=Date.prototype.toISOString,o=function(e){return e>9?e:"0"+e};e.exports=i((function(){return"0385-07-25T07:06:39.999Z"!=a.call(new Date(-50000000000001))}))||!i((function(){a.call(new Date(NaN))}))?function(){if(!isFinite(r.call(this)))throw RangeError("Invalid time value");var e=this,t=e.getUTCFullYear(),n=e.getUTCMilliseconds(),i=t<0?"-":t>9999?"+":"";return i+("00000"+Math.abs(t)).slice(i?-6:-4)+"-"+o(e.getUTCMonth()+1)+"-"+o(e.getUTCDate())+"T"+o(e.getUTCHours())+":"+o(e.getUTCMinutes())+":"+o(e.getUTCSeconds())+"."+(n>99?n:"0"+o(n))+"Z"}:a},function(e,t,n){var i=Date.prototype,r="Invalid Date",a="toString",o=i.toString,s=i.getTime;new Date(NaN)+""!=r&&n(17)(i,a,(function(){var e=s.call(this);return e==e?o.call(this):r}))},function(e,t,n){var i=n(9)("toPrimitive"),r=Date.prototype;i in r||n(20)(r,i,n(1021))},function(e,t,n){"use strict";var i=n(7),r=n(34),a="number";e.exports=function(e){if("string"!==e&&e!==a&&"default"!==e)throw TypeError("Incorrect hint");return r(i(this),e!=a)}},function(e,t,n){var i=n(0);i(i.S,"Array",{isArray:n(79)})},function(e,t,n){"use strict";var i=n(23),r=n(0),a=n(15),o=n(898),s=n(190),l=n(10),u=n(191),c=n(192);r(r.S+r.F*!n(80)((function(e){Array.from(e)})),"Array",{from:function(e){var t,n,r,h,p=a(e),d="function"==typeof this?this:Array,f=arguments.length,g=f>1?arguments[1]:undefined,m=g!==undefined,I=0,B=c(p);if(m&&(g=i(g,f>2?arguments[2]:undefined,2)),B==undefined||d==Array&&s(B))for(n=new d(t=l(p.length));t>I;I++)u(n,I,m?g(p[I],I):p[I]);else for(h=B.call(p),n=new d;!(r=h.next()).done;I++)u(n,I,m?o(h,g,[r.value,I],!0):r.value);return n.length=I,n}})},function(e,t,n){"use strict";var i=n(0),r=n(191);i(i.S+i.F*n(6)((function(){function e(){}return!(Array.of.call(e)instanceof e)})),"Array",{of:function(){for(var e=0,t=arguments.length,n=new("function"==typeof this?this:Array)(t);t>e;)r(n,e,arguments[e++]);return n.length=t,n}})},function(e,t,n){"use strict";var i=n(0),r=n(21),a=[].join;i(i.P+i.F*(n(62)!=Object||!n(22)(a)),"Array",{join:function(e){return a.call(r(this),e===undefined?",":e)}})},function(e,t,n){"use strict";var i=n(0),r=n(178),a=n(31),o=n(40),s=n(10),l=[].slice;i(i.P+i.F*n(6)((function(){r&&l.call(r)})),"Array",{slice:function(e,t){var n=s(this.length),i=a(this);if(t=t===undefined?n:t,"Array"==i)return l.call(this,e,t);for(var r=o(e,n),u=o(t,n),c=s(u-r),h=new Array(c),p=0;p<c;p++)h[p]="String"==i?this.charAt(r+p):this[r+p];return h}})},function(e,t,n){"use strict";var i=n(0),r=n(24),a=n(15),o=n(6),s=[].sort,l=[1,2,3];i(i.P+i.F*(o((function(){l.sort(undefined)}))||!o((function(){l.sort(null)}))||!n(22)(s)),"Array",{sort:function(e){return e===undefined?s.call(a(this)):s.call(a(this),r(e))}})},function(e,t,n){"use strict";var i=n(0),r=n(28)(0),a=n(22)([].forEach,!0);i(i.P+i.F*!a,"Array",{forEach:function(e){return r(this,e,arguments[1])}})},function(e,t,n){var i=n(8),r=n(79),a=n(9)("species");e.exports=function(e){var t;return r(e)&&("function"!=typeof(t=e.constructor)||t!==Array&&!r(t.prototype)||(t=undefined),i(t)&&null===(t=t[a])&&(t=undefined)),t===undefined?Array:t}},function(e,t,n){"use strict";var i=n(0),r=n(28)(1);i(i.P+i.F*!n(22)([].map,!0),"Array",{map:function(e){return r(this,e,arguments[1])}})},function(e,t,n){"use strict";var i=n(0),r=n(28)(2);i(i.P+i.F*!n(22)([].filter,!0),"Array",{filter:function(e){return r(this,e,arguments[1])}})},function(e,t,n){"use strict";var i=n(0),r=n(28)(3);i(i.P+i.F*!n(22)([].some,!0),"Array",{some:function(e){return r(this,e,arguments[1])}})},function(e,t,n){"use strict";var i=n(0),r=n(28)(4);i(i.P+i.F*!n(22)([].every,!0),"Array",{every:function(e){return r(this,e,arguments[1])}})},function(e,t,n){"use strict";var i=n(0),r=n(900);i(i.P+i.F*!n(22)([].reduce,!0),"Array",{reduce:function(e){return r(this,e,arguments.length,arguments[1],!1)}})},function(e,t,n){"use strict";var i=n(0),r=n(900);i(i.P+i.F*!n(22)([].reduceRight,!0),"Array",{reduceRight:function(e){return r(this,e,arguments.length,arguments[1],!0)}})},function(e,t,n){"use strict";var i=n(0),r=n(77)(!1),a=[].indexOf,o=!!a&&1/[1].indexOf(1,-0)<0;i(i.P+i.F*(o||!n(22)(a)),"Array",{indexOf:function(e){return o?a.apply(this,arguments)||0:r(this,e,arguments[1])}})},function(e,t,n){"use strict";var i=n(0),r=n(21),a=n(25),o=n(10),s=[].lastIndexOf,l=!!s&&1/[1].lastIndexOf(1,-0)<0;i(i.P+i.F*(l||!n(22)(s)),"Array",{lastIndexOf:function(e){if(l)return s.apply(this,arguments)||0;var t=r(this),n=o(t.length),i=n-1;for(arguments.length>1&&(i=Math.min(i,a(arguments[1]))),i<0&&(i=n+i);i>=0;i--)if(i in t&&t[i]===e)return i||0;return-1}})},function(e,t,n){var i=n(0);i(i.P,"Array",{copyWithin:n(901)}),n(44)("copyWithin")},function(e,t,n){var i=n(0);i(i.P,"Array",{fill:n(193)}),n(44)("fill")},function(e,t,n){"use strict";var i=n(0),r=n(28)(5),a="find",o=!0;a in[]&&Array(1).find((function(){o=!1})),i(i.P+i.F*o,"Array",{find:function(e){return r(this,e,arguments.length>1?arguments[1]:undefined)}}),n(44)(a)},function(e,t,n){"use strict";var i=n(0),r=n(28)(6),a="findIndex",o=!0;a in[]&&Array(1)[a]((function(){o=!1})),i(i.P+i.F*o,"Array",{findIndex:function(e){return r(this,e,arguments.length>1?arguments[1]:undefined)}}),n(44)(a)},function(e,t,n){n(57)("Array")},function(e,t,n){var i=n(5),r=n(181),a=n(13).f,o=n(42).f,s=n(188),l=n(81),u=i.RegExp,c=u,h=u.prototype,p=/a/g,d=/a/g,f=new u(p)!==p;if(n(12)&&(!f||n(6)((function(){return d[n(9)("match")]=!1,u(p)!=p||u(d)==d||"/a/i"!=u(p,"i")})))){u=function(e,t){var n=this instanceof u,i=s(e),a=t===undefined;return!n&&i&&e.constructor===u&&a?e:r(f?new c(i&&!a?e.source:e,t):c((i=e instanceof u)?e.source:e,i&&a?l.call(e):t),n?this:h,u)};for(var g=function(e){e in u||a(u,e,{configurable:!0,get:function(){return c[e]},set:function(t){c[e]=t}})},m=o(c),I=0;m.length>I;)g(m[I++]);h.constructor=u,u.prototype=h,n(17)(i,"RegExp",u)}n(57)("RegExp")},function(e,t,n){"use strict";n(904);var i=n(7),r=n(81),a=n(12),o="toString",s=/./.toString,l=function(e){n(17)(RegExp.prototype,o,e,!0)};n(6)((function(){return"/a/b"!=s.call({source:"a",flags:"b"})}))?l((function(){var e=i(this);return"/".concat(e.source,"/","flags"in e?e.flags:!a&&e instanceof RegExp?r.call(e):undefined)})):s.name!=o&&l((function(){return s.call(this)}))},function(e,t,n){"use strict";var i=n(7),r=n(10),a=n(196),o=n(82);n(83)("match",1,(function(e,t,n,s){return[function(n){var i=e(this),r=n==undefined?undefined:n[t];return r!==undefined?r.call(n,i):new RegExp(n)[t](String(i))},function(e){var t=s(n,e,this);if(t.done)return t.value;var l=i(e),u=String(this);if(!l.global)return o(l,u);var c=l.unicode;l.lastIndex=0;for(var h,p=[],d=0;null!==(h=o(l,u));){var f=String(h[0]);p[d]=f,""===f&&(l.lastIndex=a(u,r(l.lastIndex),c)),d++}return 0===d?null:p}]}))},function(e,t,n){"use strict";var i=n(7),r=n(15),a=n(10),o=n(25),s=n(196),l=n(82),u=Math.max,c=Math.min,h=Math.floor,p=/\$([$&`']|\d\d?|<[^>]*>)/g,d=/\$([$&`']|\d\d?)/g;n(83)("replace",2,(function(e,t,n,f){return[function(i,r){var a=e(this),o=i==undefined?undefined:i[t];return o!==undefined?o.call(i,a,r):n.call(String(a),i,r)},function(e,t){var r=f(n,e,this,t);if(r.done)return r.value;var h=i(e),p=String(this),d="function"==typeof t;d||(t=String(t));var m=h.global;if(m){var I=h.unicode;h.lastIndex=0}for(var B=[];;){var _=l(h,p);if(null===_)break;if(B.push(_),!m)break;""===String(_[0])&&(h.lastIndex=s(p,a(h.lastIndex),I))}for(var E,b="",y=0,v=0;v<B.length;v++){_=B[v];for(var T=String(_[0]),C=u(c(o(_.index),p.length),0),N=[],V=1;V<_.length;V++)N.push((E=_[V])===undefined?E:String(E));var S=_.groups;if(d){var x=[T].concat(N,C,p);S!==undefined&&x.push(S);var w=String(t.apply(undefined,x))}else w=g(T,p,C,N,S,t);C>=y&&(b+=p.slice(y,C)+w,y=C+T.length)}return b+p.slice(y)}];function g(e,t,i,a,o,s){var l=i+e.length,u=a.length,c=d;return o!==undefined&&(o=r(o),c=p),n.call(s,c,(function(n,r){var s;switch(r.charAt(0)){case"$":return"$";case"&":return e;case"`":return t.slice(0,i);case"'":return t.slice(l);case"<":s=o[r.slice(1,-1)];break;default:var c=+r;if(0===c)return n;if(c>u){var p=h(c/10);return 0===p?n:p<=u?a[p-1]===undefined?r.charAt(1):a[p-1]+r.charAt(1):n}s=a[c-1]}return s===undefined?"":s}))}}))},function(e,t,n){"use strict";var i=n(7),r=n(889),a=n(82);n(83)("search",1,(function(e,t,n,o){return[function(n){var i=e(this),r=n==undefined?undefined:n[t];return r!==undefined?r.call(n,i):new RegExp(n)[t](String(i))},function(e){var t=o(n,e,this);if(t.done)return t.value;var s=i(e),l=String(this),u=s.lastIndex;r(u,0)||(s.lastIndex=0);var c=a(s,l);return r(s.lastIndex,u)||(s.lastIndex=u),null===c?-1:c.index}]}))},function(e,t,n){"use strict";var i=n(188),r=n(7),a=n(65),o=n(196),s=n(10),l=n(82),u=n(195),c=n(6),h=Math.min,p=[].push,d=4294967295,f=!c((function(){RegExp(d,"y")}));n(83)("split",2,(function(e,t,n,c){var g;return g="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length?function(e,t){var r=String(this);if(e===undefined&&0===t)return[];if(!i(e))return n.call(r,e,t);for(var a,o,s,l=[],c=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),h=0,f=t===undefined?d:t>>>0,g=new RegExp(e.source,c+"g");(a=u.call(g,r))&&!((o=g.lastIndex)>h&&(l.push(r.slice(h,a.index)),a.length>1&&a.index<r.length&&p.apply(l,a.slice(1)),s=a[0].length,h=o,l.length>=f));)g.lastIndex===a.index&&g.lastIndex++;return h===r.length?!s&&g.test("")||l.push(""):l.push(r.slice(h)),l.length>f?l.slice(0,f):l}:"0".split(undefined,0).length?function(e,t){return e===undefined&&0===t?[]:n.call(this,e,t)}:n,[function(n,i){var r=e(this),a=n==undefined?undefined:n[t];return a!==undefined?a.call(n,r,i):g.call(String(r),n,i)},function(e,t){var i=c(g,e,this,t,g!==n);if(i.done)return i.value;var u=r(e),p=String(this),m=a(u,RegExp),I=u.unicode,B=(u.ignoreCase?"i":"")+(u.multiline?"m":"")+(u.unicode?"u":"")+(f?"y":"g"),_=new m(f?u:"^(?:"+u.source+")",B),E=t===undefined?d:t>>>0;if(0===E)return[];if(0===p.length)return null===l(_,p)?[p]:[];for(var b=0,y=0,v=[];y<p.length;){_.lastIndex=f?y:0;var T,C=l(_,f?p:p.slice(y));if(null===C||(T=h(s(_.lastIndex+(f?0:y)),p.length))===b)y=o(p,y,I);else{if(v.push(p.slice(b,y)),v.length===E)return v;for(var N=1;N<=C.length-1;N++)if(v.push(C[N]),v.length===E)return v;y=b=T}}return v.push(p.slice(b)),v}]}))},function(e,t,n){var i=n(5),r=n(197).set,a=i.MutationObserver||i.WebKitMutationObserver,o=i.process,s=i.Promise,l="process"==n(31)(o);e.exports=function(){var e,t,n,u=function(){var i,r;for(l&&(i=o.domain)&&i.exit();e;){r=e.fn,e=e.next;try{r()}catch(a){throw e?n():t=undefined,a}}t=undefined,i&&i.enter()};if(l)n=function(){o.nextTick(u)};else if(!a||i.navigator&&i.navigator.standalone)if(s&&s.resolve){var c=s.resolve(undefined);n=function(){c.then(u)}}else n=function(){r.call(i,u)};else{var h=!0,p=document.createTextNode("");new a(u).observe(p,{characterData:!0}),n=function(){p.data=h=!h}}return function(i){var r={fn:i,next:undefined};t&&(t.next=r),e||(e=r,n()),t=r}}},function(e,t){e.exports=function(e){try{return{e:!1,v:e()}}catch(t){return{e:!0,v:t}}}},function(e,t,n){"use strict";var i=n(908),r=n(45),a="Map";e.exports=n(86)(a,(function(e){return function(){return e(this,arguments.length>0?arguments[0]:undefined)}}),{get:function(e){var t=i.getEntry(r(this,a),e);return t&&t.v},set:function(e,t){return i.def(r(this,a),0===e?0:e,t)}},i,!0)},function(e,t,n){"use strict";var i=n(908),r=n(45);e.exports=n(86)("Set",(function(e){return function(){return e(this,arguments.length>0?arguments[0]:undefined)}}),{add:function(e){return i.def(r(this,"Set"),e=0===e?0:e,e)}},i)},function(e,t,n){"use strict";var i,r=n(5),a=n(28)(0),o=n(17),s=n(35),l=n(888),u=n(909),c=n(8),h=n(45),p=n(45),d=!r.ActiveXObject&&"ActiveXObject"in r,f="WeakMap",g=s.getWeak,m=Object.isExtensible,I=u.ufstore,B=function(e){return function(){return e(this,arguments.length>0?arguments[0]:undefined)}},_={get:function(e){if(c(e)){var t=g(e);return!0===t?I(h(this,f)).get(e):t?t[this._i]:undefined}},set:function(e,t){return u.def(h(this,f),e,t)}},E=e.exports=n(86)(f,B,_,u,!0,!0);p&&d&&(l((i=u.getConstructor(B,f)).prototype,_),s.NEED=!0,a(["delete","has","get","set"],(function(e){var t=E.prototype,n=t[e];o(t,e,(function(t,r){if(c(t)&&!m(t)){this._f||(this._f=new i);var a=this._f[e](t,r);return"set"==e?this:a}return n.call(this,t,r)}))})))},function(e,t,n){"use strict";var i=n(909),r=n(45),a="WeakSet";n(86)(a,(function(e){return function(){return e(this,arguments.length>0?arguments[0]:undefined)}}),{add:function(e){return i.def(r(this,a),e,!0)}},i,!1,!0)},function(e,t,n){"use strict";var i=n(0),r=n(87),a=n(198),o=n(7),s=n(40),l=n(10),u=n(8),c=n(5).ArrayBuffer,h=n(65),p=a.ArrayBuffer,d=a.DataView,f=r.ABV&&c.isView,g=p.prototype.slice,m=r.VIEW,I="ArrayBuffer";i(i.G+i.W+i.F*(c!==p),{ArrayBuffer:p}),i(i.S+i.F*!r.CONSTR,I,{isView:function(e){return f&&f(e)||u(e)&&m in e}}),i(i.P+i.U+i.F*n(6)((function(){return!new p(2).slice(1,undefined).byteLength})),I,{slice:function(e,t){if(g!==undefined&&t===undefined)return g.call(o(this),e);for(var n=o(this).byteLength,i=s(e,n),r=s(t===undefined?n:t,n),a=new(h(this,p))(l(r-i)),u=new d(this),c=new d(a),f=0;i<r;)c.setUint8(f++,u.getUint8(i++));return a}}),n(57)(I)},function(e,t,n){var i=n(0);i(i.G+i.W+i.F*!n(87).ABV,{DataView:n(198).DataView})},function(e,t,n){n(33)("Int8",1,(function(e){return function(t,n,i){return e(this,t,n,i)}}))},function(e,t,n){n(33)("Uint8",1,(function(e){return function(t,n,i){return e(this,t,n,i)}}))},function(e,t,n){n(33)("Uint8",1,(function(e){return function(t,n,i){return e(this,t,n,i)}}),!0)},function(e,t,n){n(33)("Int16",2,(function(e){return function(t,n,i){return e(this,t,n,i)}}))},function(e,t,n){n(33)("Uint16",2,(function(e){return function(t,n,i){return e(this,t,n,i)}}))},function(e,t,n){n(33)("Int32",4,(function(e){return function(t,n,i){return e(this,t,n,i)}}))},function(e,t,n){n(33)("Uint32",4,(function(e){return function(t,n,i){return e(this,t,n,i)}}))},function(e,t,n){n(33)("Float32",4,(function(e){return function(t,n,i){return e(this,t,n,i)}}))},function(e,t,n){n(33)("Float64",8,(function(e){return function(t,n,i){return e(this,t,n,i)}}))},function(e,t,n){var i=n(0),r=n(24),a=n(7),o=(n(5).Reflect||{}).apply,s=Function.apply;i(i.S+i.F*!n(6)((function(){o((function(){}))})),"Reflect",{apply:function(e,t,n){var i=r(e),l=a(n);return o?o(i,t,l):s.call(i,t,l)}})},function(e,t,n){var i=n(0),r=n(41),a=n(24),o=n(7),s=n(8),l=n(6),u=n(890),c=(n(5).Reflect||{}).construct,h=l((function(){function e(){}return!(c((function(){}),[],e)instanceof e)})),p=!l((function(){c((function(){}))}));i(i.S+i.F*(h||p),"Reflect",{construct:function(e,t){a(e),o(t);var n=arguments.length<3?e:a(arguments[2]);if(p&&!h)return c(e,t,n);if(e==n){switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3])}var i=[null];return i.push.apply(i,t),new(u.apply(e,i))}var l=n.prototype,d=r(s(l)?l:Object.prototype),f=Function.apply.call(e,d,t);return s(f)?f:d}})},function(e,t,n){var i=n(13),r=n(0),a=n(7),o=n(34);r(r.S+r.F*n(6)((function(){Reflect.defineProperty(i.f({},1,{value:1}),1,{value:2})})),"Reflect",{defineProperty:function(e,t,n){a(e),t=o(t,!0),a(n);try{return i.f(e,t,n),!0}catch(r){return!1}}})},function(e,t,n){var i=n(0),r=n(26).f,a=n(7);i(i.S,"Reflect",{deleteProperty:function(e,t){var n=r(a(e),t);return!(n&&!n.configurable)&&delete e[t]}})},function(e,t,n){"use strict";var i=n(0),r=n(7),a=function(e){this._t=r(e),this._i=0;var t,n=this._k=[];for(t in e)n.push(t)};n(897)(a,"Object",(function(){var e,t=this,n=t._k;do{if(t._i>=n.length)return{value:undefined,done:!0}}while(!((e=n[t._i++])in t._t));return{value:e,done:!1}})),i(i.S,"Reflect",{enumerate:function(e){return new a(e)}})},function(e,t,n){var i=n(26),r=n(43),a=n(19),o=n(0),s=n(8),l=n(7);o(o.S,"Reflect",{get:function u(e,t){var n,o,c=arguments.length<3?e:arguments[2];return l(e)===c?e[t]:(n=i.f(e,t))?a(n,"value")?n.value:n.get!==undefined?n.get.call(c):undefined:s(o=r(e))?u(o,t,c):void 0}})},function(e,t,n){var i=n(26),r=n(0),a=n(7);r(r.S,"Reflect",{getOwnPropertyDescriptor:function(e,t){return i.f(a(e),t)}})},function(e,t,n){var i=n(0),r=n(43),a=n(7);i(i.S,"Reflect",{getPrototypeOf:function(e){return r(a(e))}})},function(e,t,n){var i=n(0);i(i.S,"Reflect",{has:function(e,t){return t in e}})},function(e,t,n){var i=n(0),r=n(7),a=Object.isExtensible;i(i.S,"Reflect",{isExtensible:function(e){return r(e),!a||a(e)}})},function(e,t,n){var i=n(0);i(i.S,"Reflect",{ownKeys:n(911)})},function(e,t,n){var i=n(0),r=n(7),a=Object.preventExtensions;i(i.S,"Reflect",{preventExtensions:function(e){r(e);try{return a&&a(e),!0}catch(t){return!1}}})},function(e,t,n){var i=n(13),r=n(26),a=n(43),o=n(19),s=n(0),l=n(36),u=n(7),c=n(8);s(s.S,"Reflect",{set:function h(e,t,n){var s,p,d=arguments.length<4?e:arguments[3],f=r.f(u(e),t);if(!f){if(c(p=a(e)))return h(p,t,n,d);f=l(0)}if(o(f,"value")){if(!1===f.writable||!c(d))return!1;if(s=r.f(d,t)){if(s.get||s.set||!1===s.writable)return!1;s.value=n,i.f(d,t,s)}else i.f(d,t,l(0,n));return!0}return f.set!==undefined&&(f.set.call(d,n),!0)}})},function(e,t,n){var i=n(0),r=n(179);r&&i(i.S,"Reflect",{setPrototypeOf:function(e,t){r.check(e,t);try{return r.set(e,t),!0}catch(n){return!1}}})},function(e,t,n){n(1081),e.exports=n(11).Array.includes},function(e,t,n){"use strict";var i=n(0),r=n(77)(!0);i(i.P,"Array",{includes:function(e){return r(this,e,arguments.length>1?arguments[1]:undefined)}}),n(44)("includes")},function(e,t,n){n(1083),e.exports=n(11).Array.flatMap},function(e,t,n){"use strict";var i=n(0),r=n(1084),a=n(15),o=n(10),s=n(24),l=n(899);i(i.P,"Array",{flatMap:function(e){var t,n,i=a(this);return s(e),t=o(i.length),n=l(i,0),r(n,i,i,t,0,1,e,arguments[1]),n}}),n(44)("flatMap")},function(e,t,n){"use strict";var i=n(79),r=n(8),a=n(10),o=n(23),s=n(9)("isConcatSpreadable");e.exports=function l(e,t,n,u,c,h,p,d){for(var f,g,m=c,I=0,B=!!p&&o(p,d,3);I<u;){if(I in n){if(f=B?B(n[I],I,t):n[I],g=!1,r(f)&&(g=(g=f[s])!==undefined?!!g:i(f)),g&&h>0)m=l(e,t,f,a(f.length),m,h-1)-1;else{if(m>=9007199254740991)throw TypeError();e[m]=f}m++}I++}return m}},function(e,t,n){n(1086),e.exports=n(11).String.padStart},function(e,t,n){"use strict";var i=n(0),r=n(912),a=n(85),o=/Version\/10\.\d+(\.\d+)?( Mobile\/\w+)? Safari\//.test(a);i(i.P+i.F*o,"String",{padStart:function(e){return r(this,e,arguments.length>1?arguments[1]:undefined,!0)}})},function(e,t,n){n(1088),e.exports=n(11).String.padEnd},function(e,t,n){"use strict";var i=n(0),r=n(912),a=n(85),o=/Version\/10\.\d+(\.\d+)?( Mobile\/\w+)? Safari\//.test(a);i(i.P+i.F*o,"String",{padEnd:function(e){return r(this,e,arguments.length>1?arguments[1]:undefined,!1)}})},function(e,t,n){n(1090),e.exports=n(11).String.trimLeft},function(e,t,n){"use strict";n(55)("trimLeft",(function(e){return function(){return e(this,1)}}),"trimStart")},function(e,t,n){n(1092),e.exports=n(11).String.trimRight},function(e,t,n){"use strict";n(55)("trimRight",(function(e){return function(){return e(this,2)}}),"trimEnd")},function(e,t,n){n(1094),e.exports=n(175).f("asyncIterator")},function(e,t,n){n(884)("asyncIterator")},function(e,t,n){n(1096),e.exports=n(11).Object.getOwnPropertyDescriptors},function(e,t,n){var i=n(0),r=n(911),a=n(21),o=n(26),s=n(191);i(i.S,"Object",{getOwnPropertyDescriptors:function(e){for(var t,n,i=a(e),l=o.f,u=r(i),c={},h=0;u.length>h;)(n=l(i,t=u[h++]))!==undefined&&s(c,t,n);return c}})},function(e,t,n){n(1098),e.exports=n(11).Object.values},function(e,t,n){var i=n(0),r=n(913)(!1);i(i.S,"Object",{values:function(e){return r(e)}})},function(e,t,n){n(1100),e.exports=n(11).Object.entries},function(e,t,n){var i=n(0),r=n(913)(!0);i(i.S,"Object",{entries:function(e){return r(e)}})},function(e,t,n){"use strict";n(905),n(1102),e.exports=n(11).Promise["finally"]},function(e,t,n){"use strict";var i=n(0),r=n(11),a=n(5),o=n(65),s=n(907);i(i.P+i.R,"Promise",{"finally":function(e){var t=o(this,r.Promise||a.Promise),n="function"==typeof e;return this.then(n?function(n){return s(t,e()).then((function(){return n}))}:e,n?function(n){return s(t,e()).then((function(){throw n}))}:e)}})},function(e,t,n){n(1104),n(1105),n(1106),e.exports=n(11)},function(e,t,n){var i=n(5),r=n(0),a=n(85),o=[].slice,s=/MSIE .\./.test(a),l=function(e){return function(t,n){var i=arguments.length>2,r=!!i&&o.call(arguments,2);return e(i?function(){("function"==typeof t?t:Function(t)).apply(this,r)}:t,n)}};r(r.G+r.B+r.F*s,{setTimeout:l(i.setTimeout),setInterval:l(i.setInterval)})},function(e,t,n){var i=n(0),r=n(197);i(i.G+i.B,{setImmediate:r.set,clearImmediate:r.clear})},function(e,t,n){for(var i=n(194),r=n(39),a=n(17),o=n(5),s=n(20),l=n(56),u=n(9),c=u("iterator"),h=u("toStringTag"),p=l.Array,d={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1},f=r(d),g=0;g<f.length;g++){var m,I=f[g],B=d[I],_=o[I],E=_&&_.prototype;if(E&&(E[c]||s(E,c,p),E[h]||s(E,h,I),l[I]=p,B))for(m in i)E[m]||a(E,m,i[m],!0)}},function(e,t,n){"use strict";(function(e){function t(e){return(t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function n(e,t){for(var n=Object.getOwnPropertyNames(t),i=0;i<n.length;i++){var r=n[i],a=Object.getOwnPropertyDescriptor(t,r);a&&a.configurable&&e[r]===undefined&&Object.defineProperty(e,r,a)}return e}var i=function(e){var i,r=Object.prototype,a=r.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},s=o.iterator||"@@iterator",l=o.asyncIterator||"@@asyncIterator",u=o.toStringTag||"@@toStringTag";function c(e,t,n,i){var r=t&&t.prototype instanceof I?t:I,a=Object.create(r.prototype),o=new x(i||[]);return a._invoke=function(e,t,n){var i=p;return function(r,a){if(i===f)throw new Error("Generator is already running");if(i===g){if("throw"===r)throw a;return A()}for(n.method=r,n.arg=a;;){var o=n.delegate;if(o){var s=N(o,n);if(s){if(s===m)continue;return s}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(i===p)throw i=g,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);i=f;var l=h(e,t,n);if("normal"===l.type){if(i=n.done?g:d,l.arg===m)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(i=g,n.method="throw",n.arg=l.arg)}}}(e,n,o),a}function h(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(i){return{type:"throw",arg:i}}}e.wrap=c;var p="suspendedStart",d="suspendedYield",f="executing",g="completed",m={};function I(){}function B(){}function _(){}var E={};E[s]=function(){return this};var b=Object.getPrototypeOf,y=b&&b(b(w([])));y&&y!==r&&a.call(y,s)&&(E=y);var v=_.prototype=I.prototype=Object.create(E);function T(e){["next","throw","return"].forEach((function(t){e[t]=function(e){return this._invoke(t,e)}}))}function C(e,n){function i(r,o,s,l){var u=h(e[r],e,o);if("throw"!==u.type){var c=u.arg,p=c.value;return p&&"object"===t(p)&&a.call(p,"__await")?n.resolve(p.__await).then((function(e){i("next",e,s,l)}),(function(e){i("throw",e,s,l)})):n.resolve(p).then((function(e){c.value=e,s(c)}),(function(e){return i("throw",e,s,l)}))}l(u.arg)}var r;this._invoke=function(e,t){function a(){return new n((function(n,r){i(e,t,n,r)}))}return r=r?r.then(a,a):a()}}function N(e,t){var n=e.iterator[t.method];if(n===i){if(t.delegate=null,"throw"===t.method){if(e.iterator["return"]&&(t.method="return",t.arg=i,N(e,t),"throw"===t.method))return m;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return m}var r=h(n,e.iterator,t.arg);if("throw"===r.type)return t.method="throw",t.arg=r.arg,t.delegate=null,m;var a=r.arg;return a?a.done?(t[e.resultName]=a.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=i),t.delegate=null,m):a:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,m)}function V(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function S(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function x(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(V,this),this.reset(!0)}function w(e){if(e){var t=e[s];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var n=-1,r=function t(){for(;++n<e.length;)if(a.call(e,n))return t.value=e[n],t.done=!1,t;return t.value=i,t.done=!0,t};return r.next=r}}return{next:A}}function A(){return{value:i,done:!0}}return B.prototype=v.constructor=_,_.constructor=B,_[u]=B.displayName="GeneratorFunction",e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===B||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,_):(n(e,_),u in e||(e[u]="GeneratorFunction")),e.prototype=Object.create(v),e},e.awrap=function(e){return{__await:e}},T(C.prototype),C.prototype[l]=function(){return this},e.AsyncIterator=C,e.async=function(t,n,i,r,a){void 0===a&&(a=Promise);var o=new C(c(t,n,i,r),a);return e.isGeneratorFunction(n)?o:o.next().then((function(e){return e.done?e.value:o.next()}))},T(v),v[u]="Generator",v[s]=function(){return this},v.toString=function(){return"[object Generator]"},e.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function i(){for(;t.length;){var n=t.pop();if(n in e)return i.value=n,i.done=!1,i}return i.done=!0,i}},e.values=w,x.prototype={constructor:x,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=i,this.done=!1,this.delegate=null,this.method="next",this.arg=i,this.tryEntries.forEach(S),!e)for(var t in this)"t"===t.charAt(0)&&a.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=i)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function n(n,r){return s.type="throw",s.arg=e,t.next=n,r&&(t.method="next",t.arg=i),!!r}for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r],s=o.completion;if("root"===o.tryLoc)return n("end");if(o.tryLoc<=this.prev){var l=a.call(o,"catchLoc"),u=a.call(o,"finallyLoc");if(l&&u){if(this.prev<o.catchLoc)return n(o.catchLoc,!0);if(this.prev<o.finallyLoc)return n(o.finallyLoc)}else if(l){if(this.prev<o.catchLoc)return n(o.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return n(o.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&a.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var r=i;break}}r&&("break"===e||"continue"===e)&&r.tryLoc<=t&&t<=r.finallyLoc&&(r=null);var o=r?r.completion:{};return o.type=e,o.arg=t,r?(this.method="next",this.next=r.finallyLoc,m):this.complete(o)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),m},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),S(n),m}},"catch":function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var i=n.completion;if("throw"===i.type){var r=i.arg;S(n)}return r}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:w(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=i),m}},e}("object"===t(e)?e.exports:{});try{regeneratorRuntime=i}catch(r){Function("r","regeneratorRuntime = r")(i)}}).call(this,n(1108)(e))},function(e,t,n){"use strict";e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,n){n(1110),e.exports=n(914).global},function(e,t,n){var i=n(1111);i(i.G,{global:n(199)})},function(e,t,n){var i=n(199),r=n(914),a=n(1112),o=n(1114),s=n(1121),l=function(e,t,n){var u,c,h,p=e&l.F,d=e&l.G,f=e&l.S,g=e&l.P,m=e&l.B,I=e&l.W,B=d?r:r[t]||(r[t]={}),_=B.prototype,E=d?i:f?i[t]:(i[t]||{}).prototype;for(u in d&&(n=t),n)(c=!p&&E&&E[u]!==undefined)&&s(B,u)||(h=c?E[u]:n[u],B[u]=d&&"function"!=typeof E[u]?n[u]:m&&c?a(h,i):I&&E[u]==h?function(e){var t=function(t,n,i){if(this instanceof e){switch(arguments.length){case 0:return new e;case 1:return new e(t);case 2:return new e(t,n)}return new e(t,n,i)}return e.apply(this,arguments)};return t.prototype=e.prototype,t}(h):g&&"function"==typeof h?a(Function.call,h):h,g&&((B.virtual||(B.virtual={}))[u]=h,e&l.R&&_&&!_[u]&&o(_,u,h)))};l.F=1,l.G=2,l.S=4,l.P=8,l.B=16,l.W=32,l.U=64,l.R=128,e.exports=l},function(e,t,n){var i=n(1113);e.exports=function(e,t,n){if(i(e),t===undefined)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,i){return e.call(t,n,i)};case 3:return function(n,i,r){return e.call(t,n,i,r)}}return function(){return e.apply(t,arguments)}}},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t,n){var i=n(1115),r=n(1120);e.exports=n(201)?function(e,t,n){return i.f(e,t,r(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t,n){var i=n(1116),r=n(1117),a=n(1119),o=Object.defineProperty;t.f=n(201)?Object.defineProperty:function(e,t,n){if(i(e),t=a(t,!0),i(n),r)try{return o(e,t,n)}catch(s){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},function(e,t,n){var i=n(200);e.exports=function(e){if(!i(e))throw TypeError(e+" is not an object!");return e}},function(e,t,n){e.exports=!n(201)&&!n(915)((function(){return 7!=Object.defineProperty(n(1118)("div"),"a",{get:function(){return 7}}).a}))},function(e,t,n){var i=n(200),r=n(199).document,a=i(r)&&i(r.createElement);e.exports=function(e){return a?r.createElement(e):{}}},function(e,t,n){var i=n(200);e.exports=function(e,t){if(!i(e))return e;var n,r;if(t&&"function"==typeof(n=e.toString)&&!i(r=n.call(e)))return r;if("function"==typeof(n=e.valueOf)&&!i(r=n.call(e)))return r;if(!t&&"function"==typeof(n=e.toString)&&!i(r=n.call(e)))return r;throw TypeError("Can't convert object to primitive value")}},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},function(e,t,n){"use strict";e.exports=n(1123).polyfill()},function(e,t,n){"use strict";(function(i,r){var a,o,s;function l(e){return(l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}s=function(){function e(e){return"function"==typeof e}var t=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)},n=0,a=void 0,o=void 0,s=function(e,t){g[n]=e,g[n+1]=t,2===(n+=2)&&(o?o(m):b())},u="undefined"!=typeof window?window:undefined,c=u||{},h=c.MutationObserver||c.WebKitMutationObserver,p="undefined"==typeof self&&void 0!==i&&"[object process]"==={}.toString.call(i),d="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function f(){var e=setTimeout;return function(){return e(m,1)}}var g=new Array(1e3);function m(){for(var e=0;e<n;e+=2)(0,g[e])(g[e+1]),g[e]=undefined,g[e+1]=undefined;n=0}var I,B,_,E,b=void 0;function y(e,t){var n=this,i=new this.constructor(C);i[T]===undefined&&P(i);var r=n._state;if(r){var a=arguments[r-1];s((function(){return D(r,i,a,n._result)}))}else L(n,i,e,t);return i}function v(e){if(e&&"object"===l(e)&&e.constructor===this)return e;var t=new this(C);return S(t,e),t}p?b=function(){return i.nextTick(m)}:h?(B=0,_=new h(m),E=document.createTextNode(""),_.observe(E,{characterData:!0}),b=function(){E.data=B=++B%2}):d?((I=new MessageChannel).port1.onmessage=m,b=function(){return I.port2.postMessage(0)}):b=u===undefined?function(){try{var e=Function("return this")().require("vertx");return void 0!==(a=e.runOnLoop||e.runOnContext)?function(){a(m)}:f()}catch(t){return f()}}():f();var T=Math.random().toString(36).substring(2);function C(){}var N=void 0;function V(t,n,i){n.constructor===t.constructor&&i===y&&n.constructor.resolve===v?function(e,t){1===t._state?w(e,t._result):2===t._state?A(e,t._result):L(t,undefined,(function(t){return S(e,t)}),(function(t){return A(e,t)}))}(t,n):i===undefined?w(t,n):e(i)?function(e,t,n){s((function(e){var i=!1,r=function(e,t,n,i){try{e.call(t,n,i)}catch(r){return r}}(n,t,(function(n){i||(i=!0,t!==n?S(e,n):w(e,n))}),(function(t){i||(i=!0,A(e,t))}),e._label);!i&&r&&(i=!0,A(e,r))}),e)}(t,n,i):w(t,n)}function S(e,t){if(e===t)A(e,new TypeError("You cannot resolve a promise with itself"));else if(r=l(i=t),null===i||"object"!==r&&"function"!==r)w(e,t);else{var n=void 0;try{n=t.then}catch(a){return void A(e,a)}V(e,t,n)}var i,r}function x(e){e._onerror&&e._onerror(e._result),k(e)}function w(e,t){e._state===N&&(e._result=t,e._state=1,0!==e._subscribers.length&&s(k,e))}function A(e,t){e._state===N&&(e._state=2,e._result=t,s(x,e))}function L(e,t,n,i){var r=e._subscribers,a=r.length;e._onerror=null,r[a]=t,r[a+1]=n,r[a+2]=i,0===a&&e._state&&s(k,e)}function k(e){var t=e._subscribers,n=e._state;if(0!==t.length){for(var i=void 0,r=void 0,a=e._result,o=0;o<t.length;o+=3)i=t[o],r=t[o+n],i?D(n,i,r,a):r(a);e._subscribers.length=0}}function D(t,n,i,r){var a=e(i),o=void 0,s=void 0,l=!0;if(a){try{o=i(r)}catch(u){l=!1,s=u}if(n===o)return void A(n,new TypeError("A promises callback cannot return that same promise."))}else o=r;n._state!==N||(a&&l?S(n,o):!1===l?A(n,s):1===t?w(n,o):2===t&&A(n,o))}var M=0;function P(e){e[T]=M++,e._state=undefined,e._result=undefined,e._subscribers=[]}var R=function(){function e(e,n){this._instanceConstructor=e,this.promise=new e(C),this.promise[T]||P(this.promise),t(n)?(this.length=n.length,this._remaining=n.length,this._result=new Array(this.length),0===this.length?w(this.promise,this._result):(this.length=this.length||0,this._enumerate(n),0===this._remaining&&w(this.promise,this._result))):A(this.promise,new Error("Array Methods must be provided an Array"))}return e.prototype._enumerate=function(e){for(var t=0;this._state===N&&t<e.length;t++)this._eachEntry(e[t],t)},e.prototype._eachEntry=function(e,t){var n=this._instanceConstructor,i=n.resolve;if(i===v){var r=void 0,a=void 0,o=!1;try{r=e.then}catch(l){o=!0,a=l}if(r===y&&e._state!==N)this._settledAt(e._state,t,e._result);else if("function"!=typeof r)this._remaining--,this._result[t]=e;else if(n===H){var s=new n(C);o?A(s,a):V(s,e,r),this._willSettleAt(s,t)}else this._willSettleAt(new n((function(t){return t(e)})),t)}else this._willSettleAt(i(e),t)},e.prototype._settledAt=function(e,t,n){var i=this.promise;i._state===N&&(this._remaining--,2===e?A(i,n):this._result[t]=n),0===this._remaining&&w(i,this._result)},e.prototype._willSettleAt=function(e,t){var n=this;L(e,undefined,(function(e){return n._settledAt(1,t,e)}),(function(e){return n._settledAt(2,t,e)}))},e}(),H=function(){function t(e){this[T]=M++,this._result=this._state=undefined,this._subscribers=[],C!==e&&("function"!=typeof e&&function(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}(),this instanceof t?function(e,t){try{t((function(t){S(e,t)}),(function(t){A(e,t)}))}catch(n){A(e,n)}}(this,e):function(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}())}return t.prototype["catch"]=function(e){return this.then(null,e)},t.prototype["finally"]=function(t){var n=this,i=n.constructor;return e(t)?n.then((function(e){return i.resolve(t()).then((function(){return e}))}),(function(e){return i.resolve(t()).then((function(){throw e}))})):n.then(t,t)},t}();return H.prototype.then=y,H.all=function(e){return new R(this,e).promise},H.race=function(e){var n=this;return t(e)?new n((function(t,i){for(var r=e.length,a=0;a<r;a++)n.resolve(e[a]).then(t,i)})):new n((function(e,t){return t(new TypeError("You must pass an array to race."))}))},H.resolve=v,H.reject=function(e){var t=new this(C);return A(t,e),t},H._setScheduler=function(e){o=e},H._setAsap=function(e){s=e},H._asap=s,H.polyfill=function(){var e=void 0;if(void 0!==r)e=r;else if("undefined"!=typeof self)e=self;else try{e=Function("return this")()}catch(i){throw new Error("polyfill failed because global object is unavailable in this environment")}var t=e.Promise;if(t){var n=null;try{n=Object.prototype.toString.call(t.resolve())}catch(i){}if("[object Promise]"===n&&!t.cast)return}e.Promise=H},H.Promise=H,H},"object"===l(t)&&void 0!==e?e.exports=s():(o="function"==typeof(a=s)?a.call(t,n,t,e):a)===undefined||(e.exports=o)}).call(this,n(75),n(14))},,,,,function(e,t){},,,,,,,,function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},function(e,t,n){},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,n){n(91),n(917),n(918),n(919),n(920),n(921),n(922),n(935),n(1122),n(854),n(855),n(202),n(203),n(204),n(205),n(206),n(207),n(208),n(209),n(210),n(211),n(212),n(213),n(214),n(215),n(216),n(217),n(218),n(219),n(220),n(221),n(92),n(95),n(97),n(283),n(284),n(98),n(285),n(286),n(287),n(288),n(289),n(290),n(291),n(99),n(100),n(101),n(292),n(293),n(294),n(295),n(296),n(297),n(298),n(299),n(300),n(102),n(103),n(104),n(105),n(106),n(107),n(301),n(302),n(303),n(304),n(305),n(856),n(857),n(858),n(859),n(860),n(861),n(862),n(863),n(864),n(306),n(307),n(308),n(309),n(310),n(311),n(312),n(313),n(314),n(315),n(316),n(317),n(318),n(319),n(320),n(108),n(321),n(322),n(323),n(109),n(324),n(325),n(326),n(327),n(328),n(329),n(330),n(331),n(332),n(333),n(334),n(335),n(336),n(337),n(338),n(339),n(340),n(341),n(342),n(343),n(344),n(345),n(346),n(347),n(348),n(349),n(350),n(351),n(352),n(353),n(354),n(355),n(356),n(357),n(358),n(359),n(360),n(361),n(362),n(363),n(364),n(365),n(366),n(367),n(368),n(369),n(370),n(371),n(110),n(111),n(112),n(926),n(222),n(223),n(224),n(225),n(226),n(227),n(228),n(229),n(230),n(231),n(232),n(233),n(234),n(235),n(236),n(237),n(238),n(239),n(240),n(241),n(242),n(243),n(244),n(245),n(246),n(247),n(248),n(249),n(250),n(251),n(252),n(253),n(254),n(255),n(256),n(257),n(258),n(259),n(260),n(261),n(262),n(263),n(264),n(265),n(266),n(267),n(268),n(269),n(270),n(271),n(272),n(273),n(274),n(275),n(276),n(277),n(278),n(279),n(866),n(372),n(373),n(374),n(375),n(376),n(377),n(378),n(379),n(380),n(381),n(382),n(383),n(384),n(385),n(386),n(387),n(388),n(389),n(390),n(391),n(392),n(393),n(394),n(395),n(396),n(397),n(398),n(399),n(400),n(401),n(402),n(403),n(404),n(405),n(406),n(407),n(408),n(409),n(410),n(411),n(412),n(413),n(414),n(415),n(416),n(417),n(418),n(419),n(420),n(421),n(422),n(423),n(424),n(867),n(425),n(426),n(427),n(428),n(429),n(430),n(431),n(432),n(433),n(434),n(435),n(436),n(437),n(438),n(439),n(440),n(441),n(442),n(443),n(444),n(445),n(446),n(447),n(448),n(449),n(450),n(451),n(452),n(453),n(454),n(455),n(456),n(457),n(458),n(459),n(460),n(461),n(462),n(463),n(464),n(465),n(466),n(467),n(468),n(469),n(470),n(471),n(472),n(473),n(474),n(475),n(476),n(477),n(478),n(479),n(480),n(481),n(482),n(483),n(484),n(485),n(486),n(487),n(488),n(489),n(490),n(491),n(492),n(493),n(494),n(495),n(496),n(497),n(498),n(499),n(500),n(501),n(502),n(503),n(504),n(505),n(506),n(507),n(508),n(509),n(510),n(511),n(512),n(513),n(514),n(515),n(516),n(517),n(518),n(519),n(520),n(521),n(522),n(523),n(524),n(525),n(526),n(527),n(528),n(529),n(530),n(531),n(532),n(533),n(534),n(535),n(536),n(868),n(869),n(870),n(871),n(872),n(873),n(874),n(875),n(876),n(877),n(878),n(879),n(880),n(113),n(114),n(115),n(116),n(117),n(118),n(119),n(120),n(121),n(122),n(123),n(124),n(125),n(126),n(127),n(128),n(129),n(130),n(131),n(132),n(133),n(134),n(135),n(136),n(137),n(138),n(139),n(140),n(141),n(142),n(143),n(144),n(145),n(146),n(147),n(148),n(149),n(150),n(151),n(152),n(153),n(154),n(155),n(156),n(157),n(158),n(159),n(160),n(161),n(162),n(163),n(164),n(165),n(166),n(167),n(168),n(169),n(170),n(171),n(172),n(537),n(538),n(539),n(540),n(541),n(542),n(543),n(544),n(545),n(546),n(547),n(548),n(549),n(550),n(551),n(552),n(553),n(554),n(555),n(556),n(557),n(558),n(559),n(560),n(561),n(562),n(563),n(564),n(565),n(566),n(567),n(568),n(569),n(570),n(571),n(572),n(573),n(574),n(575),n(576),n(577),n(578),n(579),n(580),n(581),n(582),n(583),n(584),n(585),n(586),n(587),n(588),n(589),n(590),n(591),n(592),n(593),n(594),n(595),n(596),n(597),n(598),n(599),n(600),n(601),n(602),n(603),n(604),n(605),n(606),n(607),n(608),n(609),n(610),n(611),n(612),n(613),n(614),n(615),n(616),n(617),n(618),n(619),n(620),n(621),n(622),n(623),n(624),n(625),n(626),n(627),n(628),n(629),n(630),n(631),n(632),n(633),n(634),n(635),n(636),n(637),n(638),n(639),n(640),n(641),n(642),n(643),n(644),n(645),n(646),n(647),n(648),n(649),n(650),n(651),n(652),n(653),n(654),n(655),n(656),n(657),n(658),n(659),n(660),n(661),n(662),n(663),n(664),n(665),n(666),n(667),n(668),n(669),n(670),n(671),n(672),n(673),n(674),n(675),n(676),n(677),n(678),n(679),n(680),n(681),n(682),n(683),n(684),n(685),n(686),n(687),n(688),n(689),n(690),n(691),n(692),n(693),n(694),n(695),n(696),n(697),n(698),n(699),n(700),n(701),n(702),n(703),n(704),n(705),n(706),n(707),n(865),n(916),n(881),n(1136),n(1137),n(1138),n(1139),n(1140),n(1128),e.exports=n(708)}]);