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.
 
 
 

2 lines
1.8 MiB

/*! time: 2021-6-4 5:30:19 PM */
!function(i){var n={};function r(e){if(n[e])return n[e].exports;var t=n[e]={i:e,l:!1,exports:{}};return i[e].call(t.exports,t,t.exports,r),t.l=!0,t.exports}r.m=i,r.c=n,r.d=function(e,t,i){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(t,e){if(1&e&&(t=r(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(r.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var n in t)r.d(i,n,function(e){return t[e]}.bind(null,n));return i},r.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=1438)}([,function(e,t,i){"use strict";i(29)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(2)},,,,,,,,,,function(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function n(t){return typeof t}:function n(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},n(e)}var r=function(){return this}();try{r=r||new Function("return this")()}catch(a){"object"===("undefined"==typeof window?"undefined":n(window))&&(r=window)}e.exports=r},,function(e,t,i){"use strict";i(1)},,,,,,,,,,,,,function(e,t,i){},,,,function(e,t,i){"use strict";i(1)},,,,,,,,,,,,,function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(29)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(16)},function(e,t,i){"use strict";i(29)},,,,,,,function(i,e,t){(function(e){var t=function(e){return e&&e.Math==Math&&e};i.exports=t("object"==typeof globalThis&&globalThis)||t("object"==typeof window&&window)||t("object"==typeof self&&self)||t("object"==typeof e&&e)||Function("return this")()}).call(this,t(14))},function(e,r,a){"use strict";(function(e){var t=void 0!==e&&e||"undefined"!=typeof self&&self||window,i=Function.prototype.apply;function n(e,t){this._id=e,this._clearFn=t}r.setTimeout=function(){return new n(i.call(setTimeout,t,arguments),clearTimeout)},r.setInterval=function(){return new n(i.call(setInterval,t,arguments),clearInterval)},r.clearTimeout=r.clearInterval=function(e){e&&e.close()},n.prototype.unref=n.prototype.ref=function(){},n.prototype.close=function(){this._clearFn.call(t,this._id)},r.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},r.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},r._unrefActive=r.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;0<=t&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},a(96),r.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==e&&e.setImmediate||void 0,r.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==e&&e.clearImmediate||void 0}).call(this,a(14))},,,,,function(e,t,i){var n=i(60),r=i(1123),a=i(1137),o=i(1163),s=n.Symbol,l=r("wks");e.exports=function(e){return l[e]||(l[e]=o&&s[e]||(o?s:a)("Symbol."+e))}},function(e,t,i){var c=i(60),h=i(1134).f,p=i(281),d=i(875),f=i(1148),g=i(1196),m=i(1152);e.exports=function(e,t){var i,n,r,a,o=e.target,s=e.global,l=e.stat,u=s?c:l?c[o]||f(o,{}):(c[o]||{}).prototype;if(u)for(i in t){if(r=t[i],n=e.noTargetGet?(a=h(u,i))&&a.value:u[i],!m(s?i:o+(l?".":"#")+i,e.forced)&&n!==undefined){if(typeof r==typeof n)continue;g(r,n)}(e.sham||n&&n.sham)&&p(r,"sham",!0),d(u,i,r,e)}}},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(33)},function(e,t,i){"use strict";i(29)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(52)},function(e,t,i){"use strict";var n,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(n===setTimeout)return setTimeout(e,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:o}catch(e){n=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(1<arguments.length)for(var i=1;i<arguments.length;i++)t[i-1]=arguments[i];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){e.exports=function(e){try{return!!e()}catch(t){return!0}}},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t,i){var n=i(89);e.exports=function(e){if(!n(e))throw TypeError(String(e)+" is not an object");return e}},function(e,t,i){(function(e){_global=undefined,_global="undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:this,null==_global.BI&&(_global.BI={prepares:[]}),null==_global.BI.prepares&&(_global.BI.prepares=[])}).call(this,i(14))},function(e,t,i){i(93)(i(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(i){t(i)}}},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,i){(function(e,t){function i(){u=!1;for(var e=l.slice(0),t=l.length=0;t<e.length;t++)e[t]()}var n,r,a,o,s,l,u,c,h,p,d;_global=undefined,_global="undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:this,_global.BI||(_global.BI={}),h=function(n,r){return function(e,t,i){return n.call(r,t,e,i)}},p=function(e){return function(){return _[e].apply(_,arguments)}},d=function(t){return function(){var e=Array.prototype.slice.call(arguments,0);return e[1]=_.isFunction(e[1])?h(e[1],e[2]):e[1],_[t].apply(_,e)}},_.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="",i=0;i<16;i++){t+=e[parseInt(e.length*Math.random(),10)]}return t},isWidget:function(e){return e instanceof BI.Widget},createWidgets:function(e,i,t){if(!BI.isArray(e))throw new Error("cannot create Widgets");return i=BI.isWidget(i)?{}:i||{},BI.map(BI.flatten(e),function(e,t){return BI.createWidget(t,BI.deepClone(i))})},createItems:function(e,i,n){return i=BI.isArray(i)?i:BI.makeArray(BI.flatten(e).length,i||{}),n=BI.isArray(n)?n:BI.makeArray(BI.flatten(e).length,n||{}),BI.map(e,function(e,t){return BI.isArray(t)?BI.createItems(t,i,n):t instanceof BI.Widget?BI.extend({},i.shift(),n.shift(),{type:null,el:t}):i[0]instanceof BI.Widget?(n.shift(),BI.extend({},t,{el:i.shift()})):t.el instanceof BI.Widget?(i.shift(),BI.extend({},n.shift(),{type:null},t)):t.el?BI.extend({},n.shift(),t,{el:BI.extend({},i.shift(),t.el)}):BI.extend({},n.shift(),{el:BI.extend({},i.shift(),t)})})},packageItems:function(e,i){for(var n=i.length-1;0<=n;n--)e=BI.map(e,function(e,t){return BI.extend({},i[n],{items:[BI.extend({},i[n].el,{el:t})]})});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]=p(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]=d("any"===e?"some":e)}),_.extend(BI,{count:function(e,t,i){var n;if(i)for(n=e;n<t;n++)i(n);return t-e},inverse:function(e,t,i){return BI.count(t,e,i)},firstKey:function(e){var i=n;return BI.any(e,function(e,t){return i=e,!0}),i},lastKey:function(e){var i=n;return BI.each(e,function(e,t){return i=e,!0}),i},firstObject:function(e){var i=n;return BI.any(e,function(e,t){return i=t,!0}),i},lastObject:function(e){var i=n;return BI.each(e,function(e,t){return i=t,!0}),i},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,i){t=BI.iteratee(t,i);for(var n=e.length-1;0<=n;n--)t(n,e[n],e);return!1},backAny:function(e,t,i){t=BI.iteratee(t,i);for(var n=e.length-1;0<=n;n--)if(t(n,e[n],e))return!0;return!1},backEvery:function(e,t,i){t=BI.iteratee(t,i);for(var n=e.length-1;0<=n;n--)if(!t(n,e[n],e))return!1;return!0},backFindKey:function(e,t,i){t=BI.iteratee(t,i);for(var n,r=_.keys(e),a=r.length-1;0<=a;a--)if(t(e[n=r[a]],n,e))return n},backFind:function(e,t,i){var n=BI.isArray(e)?BI.findLastIndex(e,t,i):BI.backFindKey(e,t,i);if(void 0!==n&&-1!==n)return e[n]},remove:function(i,n,r){var e,a=BI.isFunction(n);if(n=a||BI.isArray(n)?n:[n],BI.isArray(i))for(e=0;e<i.length;e++)(a&&!0===n.apply(r,[e,i[e]])||!a&&BI.contains(n,i[e]))&&i.splice(e--,1);else BI.each(i,function(e,t){(a&&!0===n.apply(r,[e,i[e]])||!a&&BI.contains(n,i[e]))&&delete i[e]})},removeAt:function(e,t){t=BI.isArray(t)?t:[t];for(var i=BI.isArray(e),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,i=0,n=(e=e.toUpperCase()).length;i<n;++i)if((t=e.charAt(i).charCodeAt(0)-"A".charCodeAt(0)+26*t+1)>(2147483646-e.charAt(i).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"],i=e,n="";if(0===e)return"";for(;0!==i;){var r=i%26;0===r&&(r=26),n=t[r-1]+n,i=(i-r)/26}return n}}),_.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]=p(e)}),_.each(["findIndex","findLastIndex"],function(e){BI[e]=d(e)}),_.extend(BI,{makeArray:function(e,t){for(var i=[],n=0;n<e;n++)BI.isNull(t)?i.push(n):i.push(BI.deepClone(t));return i},makeObject:function(e,t){for(var i={},n=0;n<e.length;n++)BI.isNull(t)?i[e[n]]=e[n]:BI.isFunction(t)?i[e[n]]=t(n,e[n]):i[e[n]]=BI.deepClone(t);return i},makeArrayByArray:function(e,t){var i=[];if(!e)return i;for(var n=0,r=e.length;n<r;n++)BI.isArray(e[n])?i.push(arguments.callee(e[n],t)):i.push(BI.deepClone(t));return i},uniq:function(e,t,i,n){return null==e?[]:(_.isBoolean(t)||(n=i,i=t,t=!1),i=i&&h(i,n),_.uniq.call(_,e,t,i,n))}}),_.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]=p(e)}),_.each(["mapObject","findKey","pick","omit","tap"],function(e){BI[e]=d(e)}),_.extend(BI,{inherit:function(e,t){var i=function(){return e.apply(this,arguments)},n=function(){},r=e.prototype;return n.prototype=r,i.prototype=new n,i.superclass=r,_.extend(i.prototype,t,{superclass:e}),i},init:function(){for(;BI.prepares&&0<BI.prepares.length;)BI.prepares.shift()();for(;_global.___fineuiExposedFunction&&0<_global.___fineuiExposedFunction.length;)_global.___fineuiExposedFunction.shift()();BI.initialized=!0},has:function(i,e){return BI.isArray(e)?0!==e.length&&BI.every(e,function(e,t){return _.has(i,t)}):_.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)&&0<e.length},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?0<=e:"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 i=BI.keys(t),n=i.length;if(null==e)return!n;for(var r=Object(e),a=0;a<n;a++){var o=i[a];if(!(BI.isEqual(t[o],r[o])&&o in r))return!1}return!0},contains:function(e,t,i){return _.isArrayLike(e)||(e=_.values(e)),0<=_.indexOf(e,t,"number"==typeof i&&i)},deepContains:function(e,i){return BI.isObject(i)?BI.any(e,function(e,t){if(BI.isEqual(t,i))return!0}):BI.contains(e,i)},deepIndexOf:function(e,t){for(var i=0;i<e.length;i++)if(BI.isEqual(t,e[i]))return i;return-1},deepRemove:function(i,n){var e,r=!1;if(BI.isArray(i))for(e=0;e<i.length;e++)BI.isEqual(n,i[e])&&(i.splice(e--,1),r=!0);else BI.each(i,function(e,t){BI.isEqual(n,i[e])&&(delete i[e],r=!0)});return r},deepWithout:function(i,n){if(BI.isArray(i)){for(var r=[],e=0;e<i.length;e++)BI.isEqual(n,i[e])||r.push(i[e]);return r}r={};return BI.each(i,function(e,t){BI.isEqual(n,i[e])||(r[e]=t)}),r},deepUnique:function(e){var i=[];return BI.each(e,function(e,t){BI.deepContains(i,t)||i.push(t)}),i},deepDiff:function(e,t){e=e||{},t=t||{};var i=[],n=[];for(var r in e)this.has(e,r)&&(this.isEqual(e[r],t[r])||i.push(r),n.push(r));for(var r in t)this.has(t,r)&&!BI.contains(n,r)&&i.push(r);return i}}),_.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:(u=!(l=[]),c=void 0,c="undefined"!=typeof Promise?(r=Promise.resolve(),function c(){r.then(i)}):"undefined"!=typeof MutationObserver?(a=1,o=new MutationObserver(i),s=document.createTextNode(String(a)),o.observe(s,{characterData:!0}),function c(){a=(a+1)%2,s.data=String(a)}):void 0!==t?function c(){t(i)}:function c(){setTimeout(i,0)},function(t){var i=void 0,n=[].slice.call(arguments,1);if(l.push(function(){if(t)try{t.apply(null,n)}catch(e){console.error(e)}else i&&i.apply(null,n)}),u||(u=!0,c()),!t&&"undefined"!=typeof Promise)return new Promise(function(e,t){i=e})})}),_.each(["random"],function(e){BI[e]=p(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(i){throw new Error(e+"parse int error")}},parseSafeInt:function(e){var t=9007199254740991;return e?this.clamp(this.parseInt(e),-t,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,i,n){var r=0;return BI.each(e,function(e,t){r+=i?Number(i.apply(n,[e,t])):Number(t)}),r},average:function(e,t,i){return BI.sum(e,t,i)/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,i){switch(e){case BI.CRYPT_TYPE.AES:default:return BI.aesEncrypt(t,i)}},decrypt:function(e,t,i){switch(e){case BI.CRYPT_TYPE.AES:default:return BI.aesDecrypt(t,i)}},escape:function(e){return e.replace(/('|\\)/g,"\\$1")},leftPad:function(e,t,i){var n=String(e);for(i=i||" ";n.length<t;)n=i+n;return n.toString()},format:function(e){var i=Array.prototype.slice.call(arguments,1);return e.replace(/\{(\d+)\}/g,function(e,t){return i[t]})}}),_.extend(BI,{isLeapYear:function(e){return e%4==0&&e%100!=0||e%400==0},checkDateVoid:function(e,t,i,n,r){var a=[];return e|=0,t|=0,i|=0,n=BI.isString(n)?n.match(/\d+/g):n,r=BI.isString(r)?r.match(/\d+/g):r,e<n[0]?a=["y"]:e>r[0]?a=["y",1]:e>=n[0]&&e<=r[0]&&(e==n[0]&&(t<n[1]?a=["m"]:t==n[1]&&i<n[2]&&(a=["d"])),e==r[0]&&(t>r[1]?a=["m",1]:t==r[1]&&i>r[2]&&(a=["d",1]))),a},checkDateLegal:function(e){var t=e.match(/\d+/g),i=0|t[0],n=0|t[1],r=0|t[2];if(t.length<=1)return!0;if(t.length<=2)return 1<=n&&n<=12;var a=BI.Date._MD.slice(0);return a[1]=BI.isLeapYear(i)?29:28,1<=n&&n<=12&&r<=a[n-1]},parseDateTime:function(e,t){var i=BI.getDate(),n=0,r=0,a=1,o=e.split(/\W+/);"%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));for(var s=t.match(/%./g),l=0,u=0,c=0,h=0,p=0,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":(n=parseInt(o[l],10))<100&&(n+=29<n?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])&&12<=c&&(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(n)&&(n=i.getFullYear()),isNaN(r)&&(r=i.getMonth()),isNaN(a)&&(a=i.getDate()),isNaN(c)&&(c=i.getHours()),isNaN(h)&&(h=i.getMinutes()),isNaN(p)&&(p=i.getSeconds()),0!=n)return BI.getDate(n,r,a,c,h,p);for(r=-1,l=a=n=0;l<o.length;++l)if(-1!=o[l].search(/[a-zA-Z]+/)){for(var d=-1,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:31<parseInt(o[l],10)&&0==n?(n=parseInt(o[l],10))<100&&(n+=29<n?1900:2e3):0==a&&(a=o[l]);return 0==n&&(n=i.getFullYear()),-1===r&&(r=i.getMonth()),-1!=r&&0!=a?BI.getDate(n,r,a,c,h,p):i},getDate:function(){var e,t=arguments;switch(arguments.length){case 0:e=new Date;break;case 1:e=new Date(t[0]);break;case 2:e=new Date(t[0],t[1]);break;case 3:e=new Date(t[0],t[1],t[2]);break;case 4:e=new Date(t[0],t[1],t[2],t[3]);break;case 5:e=new Date(t[0],t[1],t[2],t[3],t[4]);break;case 6:e=new Date(t[0],t[1],t[2],t[3],t[4],t[5]);break;case 7:e=new Date(t[0],t[1],t[2],t[3],t[4],t[5],t[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(),n=6e4*e.getTimezoneOffset();return new Date(i+n+BI.timeZone)}return e},getTime:function(){var e,t=arguments;switch(arguments.length){case 0:e=new Date;break;case 1:e=new Date(t[0]);break;case 2:e=new Date(t[0],t[1]);break;case 3:e=new Date(t[0],t[1],t[2]);break;case 4:e=new Date(t[0],t[1],t[2],t[3]);break;case 5:e=new Date(t[0],t[1],t[2],t[3],t[4]);break;case 6:e=new Date(t[0],t[1],t[2],t[3],t[4],t[5]);break;case 7:e=new Date(t[0],t[1],t[2],t[3],t[4],t[5],t[6]);break;default:e=new Date}return BI.isNotNull(BI.timeZone)?e.getTime()-BI.timeZone-6e4*(new Date).getTimezoneOffset():e.getTime()}})}).call(this,i(14),i(61).setImmediate)},function(e,t,i){"use strict";(function(e,t){function i(e){delete s[e]}function n(e){if(l)setTimeout(n,0,e);else{var t=s[e];if(t){l=!0;try{!function(e){var t=e.callback,i=e.args;switch(i.length){case 0:t();break;case 1:t(i[0]);break;case 2:t(i[0],i[1]);break;case 3:t(i[0],i[1],i[2]);break;default:t.apply(a,i)}}(t)}finally{i(e),l=!1}}}}var r,a,o,s,l,u,c,h,p,d,f,g;(r="undefined"==typeof self?void 0===e?void 0:e:self).setImmediate||(o=1,l=!(s={}),u=r.document,g=(g=Object.getPrototypeOf&&Object.getPrototypeOf(r))&&g.setTimeout?g:r,c="[object process]"==={}.toString.call(r.process)?function c(e){t.nextTick(function(){n(e)})}:function(){if(r.postMessage&&!r.importScripts){var e=!0,t=r.onmessage;return r.onmessage=function(){e=!1},r.postMessage("","*"),r.onmessage=t,e}}()?(d="setImmediate$"+Math.random()+"$",f=function f(e){e.source===r&&"string"==typeof e.data&&0===e.data.indexOf(d)&&n(+e.data.slice(d.length))},r.addEventListener?r.addEventListener("message",f,!1):r.attachEvent("onmessage",f),function c(e){r.postMessage(d+e,"*")}):r.MessageChannel?((p=new MessageChannel).port1.onmessage=function(e){n(e.data)},function c(e){p.port2.postMessage(e)}):u&&"onreadystatechange"in u.createElement("script")?(h=u.documentElement,function c(e){var t=u.createElement("script");t.onreadystatechange=function(){n(e),t.onreadystatechange=null,h.removeChild(t),t=null},h.appendChild(t)}):function c(e){setTimeout(n,0,e)},g.setImmediate=function(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),i=0;i<t.length;i++)t[i]=arguments[i+1];var n={callback:e,args:t};return s[o]=n,c(o),o++},g.clearImmediate=i)}).call(this,i(14),i(75))},function(e,t){var i;i=function(e){this._constructor(e)},_.extend(i.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(e){for(var t,i,n,r=e||{},a=arguments.length,o=1;o<a;o++)if(null!=(t=arguments[o]))for(i in t)r[i],r!==(n=t[i])&&n!==undefined&&(r[i]=n);return r}(this._defaultConfig(e),t,e)},_init:function(){this._initListeners(),this.init&&this.init()},_initListeners:function(){var t=this;null!=this.options.listeners&&(_.each(this.options.listeners,function(e){(e.target?e.target:t)[e.once?"once":"on"](e.eventName,_.bind(e.action,t))}),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 i=this;e=e.toLowerCase();var n=this._getEvents()[e];return _.isArray(n)||(n=[],this._getEvents()[e]=n),n.push(t),function(){i.un(e,t)}},once:function(e,t){var i=function(){t.apply(this,arguments),this.un(e,i)};this.on(e,i)},un:function(e,t){var i,n;e=e.toLowerCase(),null==t?delete this._getEvents()[e]:(i=this._getEvents()[e],_.isArray(i)&&(n=[],_.each(i,function(e){e!=t&&n.push(e)}),this._getEvents()[e]=n))},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 i=0;i<t.length;i++)if(!1===t[i].apply(this,arguments[1]))return!1}else for(var n=Array.prototype.slice.call(arguments,1),i=0;i<t.length;i++)if(!1===t[i].apply(this,n))return!1;return!0},destroy:function(){this.destroyed&&this.destroyed(),this._purgeRef(),this.purgeListeners()}}),BI.OB=BI.OB||i},function(e,t){!function(){var i={};BI.module=BI.module||function(e,t){null!=i[e]&&_global.console&&console.error("module:["+e+"] has been registed"),i[e]=t};var n={};BI.constant=BI.constant||function(e,t){null!=n[e]&&_global.console&&console.error("constant:["+e+"] has been registed"),n[e]=t};var r={};BI.model=BI.model||function(e,t){null!=r[e]&&_global.console&&console.error("model:["+e+"] has been registed"),r[e]=t};var a={};BI.store=BI.store||function(e,t){null!=a[e]&&_global.console&&console.error("store:["+e+"] has been registed"),a[e]=t};var o={};BI.service=BI.service||function(e,t){null!=o[e]&&_global.console&&console.error("service:["+e+"] has been registed"),o[e]=t};var s={};BI.provider=BI.provider||function(e,t){null!=s[e]&&_global.console&&console.error("provider:["+e+"] has been registed"),s[e]=t};var l={};BI.config=BI.config||function(i,e,t){if(BI.initialized)return n[i]?n[i]=e(n[i]):s[i]?(g[i]||(g[i]=new s[i]),m[i]&&delete m[i],e(g[i])):BI.Plugin.configWidget(i,e,t);l[i]||(l[i]=[],BI.prepares.push(function(){for(var e=l[i],t=0;t<e.length;t++)n[i]?n[i]=e[t](n[i]):s[i]?(g[i]||(g[i]=new s[i]),m[i]&&delete m[i],e[t](g[i])):BI.Plugin.configWidget(i,e[t]);l[i]=null})),l[i].push(e)},BI.getReference=BI.getReference||function(e,t){return BI.Plugin.registerObject(e,t)};var u={},c=[];BI.action=BI.action||function(t,i){return BI.isFunction(t)?(c.push(t),function(){BI.remove(c,function(e){return c.indexOf(i)===e})}):(u[t]||(u[t]=[]),u[t].push(i),function(){BI.remove(u[t],function(e){return u[t].indexOf(i)===e}),0===u[t].length&&delete u[t]})};var h={};BI.point=BI.point||function(e,t,i,n){h[e]||(h[e]={}),h[e][t]||(h[e][t]={}),h[e][t][n?"after":"before"]||(h[e][t][n?"after":"before"]=[]),h[e][t][n?"after":"before"].push(i)},BI.Modules=BI.Modules||{getModule:function(e){return i[e]?i[e]:(_global.console&&console.error("module:["+e+"] does not exists"),!1)},getAllModules:function(){return i}},BI.Constants=BI.Constants||{getConstant:function(e){return n[e]}};var p=function(a,e){e=BI.isArray(e)?e:[e],BI.each(e,function(e,t){if(h[t])for(var i in h[t]){var n=h[t][i].before;n&&BI.aspect.before(a,i,function(n){return function(){for(var e=0,t=n.length;e<t;e++)try{n[e].apply(a,arguments)}catch(i){_global.console&&console.error(i)}}}(n));var r=h[t][i].after;r&&BI.aspect.after(a,i,function(n){return function(){for(var e=0,t=n.length;e<t;e++)try{n[e].apply(a,arguments)}catch(i){_global.console&&console.error(i)}}}(r))}})};BI.Models=BI.Models||{getModel:function(e,t){var i=new r[e](t);return i._constructor&&i._constructor(t),i.mixins&&p(i,i.mixins),p(i,e),i}};var d={};BI.Stores=BI.Stores||{getStore:function(e,t){if(d[e])return d[e];var i=d[e]=new a[e](t);return i._constructor&&i._constructor(t,function(){delete d[e]}),p(i,e),i}};var f={};BI.Services=BI.Services||{getService:function(e,t){return f[e]||(f[e]=new o[e](t),p(f[e],e)),f[e]}};var g={},m={};BI.Providers=BI.Providers||{getProvider:function(e,t){return g[e]||(g[e]=new s[e]),m[e]||(m[e]=new(g[e].$get())(t)),m[e]}},BI.Actions=BI.Actions||{runAction:function(e,n,r){BI.each(u[e],function(e,t){try{t(n,r)}catch(i){_global.console&&console.error(i)}})},runGlobalAction:function(){var n=[].slice.call(arguments);BI.each(c,function(e,t){try{t.apply(null,n)}catch(i){_global.console&&console.error(i)}})}},BI.getResource=BI.getResource||function(e,t){return n[e]?BI.Constants.getConstant(e):r[e]?BI.Models.getModel(e,t):a[e]?BI.Stores.getStore(e,t):o[e]?BI.Services.getService(e,t):s[e]?BI.Providers.getProvider(e,t):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 i=e<0?(e*=-1,"-"):"",n="",r=Math[0<e&&e<1?"floor":"ceil"](Math.log(e)/Math.log(10));if(!isFinite(r))return t.replace(/#/gi,"").replace(/\.e/gi,"E");0<(e/=Math.pow(10,r))&&e<1&&(e*=10,--r);var a=function(e,t){if(!/e/gi.test(t))return 0;var i,n,r=t.split(/e/gi)[0].split(".")[0],a=r.length,o=0;for(i=0;i<a;i++)(0==(n=r.charAt(i))||"#"==n&&a-i<=e+1)&&o++;return o}(r,t);1<a&&(r-=a-1,e*=Math.pow(10,a-1)),r<0&&(n="-",r*=-1);var o=function(e){if(!/e/gi.test(e))return 0;var t=e.split(/e/gi)[0].split(".");return 1<t.length?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+="-"===n?-1:1),e=(e/=Math.pow(10,o)).toFixed(o),r=function(e,t,i){if(t+="",!/e/gi.test(e))return t;e=e.split(/e/gi)[1];for(;t.length<e.length;)t="0"+t;for(var n=!0,r=0,a=t.length;r<a;r++)n=n&&"0"===t.charAt(r);return(i=n?"":i)+t}(t,r,n),i+e+"E"+r}(e=+e,t)}function _dealNumberPrecision(e,t){if(/[eE]/.test(e)){var i,n=0,r=0;/[%‰]$/.test(t)&&(n=/[%]$/.test(t)?2:3);for(var a=t.length;r<a;r++)"0"!=(i=t.charAt(r))&&"#"!=i||n++;return Number(e).toFixed(n)}return e}function _numberFormat(e,t){if(!/[0-9]/.test(e=e+"")||!t)return e;var i=t.indexOf(";");if(-1<i)return 0<=e?_numberFormat(e+"",t.substring(0,i)):_numberFormat(-e+"",t.substr(i+1));if(+e<0&&"-"!==t.charAt(0))return _numberFormat(-e+"","-"+t);var n,r=t.split("."),a=r[0]||"",o=r[1]||"",s=(e=_dealNumberPrecision(e,o)).split("."),l=s[0]||"",u=s[1]||"";/[%‰]$/.test(t)&&(l=(l+=(u+=n=/[%]$/.test(t)?"00":"000").substr(0,n.length)).replace(/^0+/gi,""),u=u.substr(n.length).replace(/0+$/gi,""));var c=_dealWithRight(u,o);c.leftPlus&&(l=parseInt(l)+1+"",l=isNaN(l)?"1":l),c=c.num;var h=_dealWithLeft(l,a);return/[0-9]/.test(h)||(h+="0"),/[0-9]/.test(c)?h+"."+c:h+c}function _dealWithRight(e,t){for(var i="",n=0,r=0,a=t.length;r<a;r++){var o=t.charAt(r),s=e.charAt(n);switch(o){case"0":isEmpty(s)&&(s="0"),i+=s,n++;break;case"#":i+=s,n++;break;default:i+=o}}var l,u,c,h,p=e.substr(n),d={};return!isEmpty(p)&&4<p.charAt(0)&&(d.leftPlus=!0,(l=i.match(/^[0-9]+/))&&(c=(u=l[0]).length,(h=parseInt(u)+1+"").length>c?h=h.substr(1):(h=BI.leftPad(h,c,"0"),d.leftPlus=!1),i=i.replace(/^[0-9]+/,h))),d.num=i,d}function _dealWithLeft(e,t){for(var i,n="",r=e.length-1,a=-1,o=-1,s=t.length-1;0<=s;s--){var l,u=t.charAt(s),c=e.charAt(r);switch(u){case"0":isEmpty(c)&&(c="0"),o=-1,n=c+n,r--;break;case"#":o=s,n=c+n,r--;break;case",":isEmpty(c)||((l=t.match(/,[#0]+/))&&(a=l[0].length-1),n=","+n);break;default:n=u+n}}if(-1<o&&(i=e.substr(0,r+1),n=n.substr(0,o)+i+n.substr(o)),0<a){var h=n.match(/[0-9]+,/);if(h){for(var p="",d=(h=h[0]).length-1-a;0<=d;d-=a)p=h.substr(d,a)+","+p;var f=h.substr(0,d+a);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="",i=0;i<e.length;i++){var n=e.charCodeAt(i);t+=128<=n||91===n||93===n?"["+n.toString(16)+"]":e.charAt(i)}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),rightIdx,subText;"["==ch&&(rightIdx=text.indexOf("]",i+1),i+1<rightIdx&&(subText=text.substring(i+1,rightIdx),0<subText.length&&(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 i={};return _.each(e,function(e,t){"string"!=typeof e&&(e=BI.jsonEncode(e)),t=BI.cjkEncode(t),i[t]=BI.cjkEncode(e)}),i}return e},BI.jsonEncode=function(e){var t,i=!!{}.hasOwnProperty,n={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"};if(null==e)return"null";if(BI.isArray(e))return function(e){for(var t,i,n=["["],r=e.length,a=0;a<r;a+=1)switch(typeof(i=e[a])){case"undefined":case"function":case"unknown":break;default:t&&n.push(","),n.push(null===i?"null":BI.jsonEncode(i)),t=!0}return n.push("]"),n.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 i=n[t];return i||(i=t.charCodeAt(),"\\u00"+Math.floor(i/16).toString(16)+(i%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(!i||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(!(i=e)||"string"!=typeof i||-1==i.indexOf("__time__"))return t;var i;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,i){return BI.replaceAll(e,"\\{(.*?)\\}",function(e,t){return BI.encodeURIComponent(BI.isObject(i)?i[t]:i)})},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 i={};return BI.each(BI.specialCharsMap,function(e,t){i[t]="\\\\"===e?"\\":e}),e=e||"",e=BI.replaceAll(e+"",BI.keys(i||[]).join("|"),function(e){return i[e]||e}),_global.decodeURIComponent(e)},BI.contentFormat=function(e,t){if(isEmpty(e))return"";var i,n=e.toString();return isEmpty(t)||t.match(/^T/)?n:(t.match(/^D/)?(e instanceof Date||(e="number"==typeof e?new Date(e):new Date(Date.parse((""+e).replace(/-|\./g,"/")))),isInvalidDate(e)||BI.isNull(e)||(i=t.match(/^DT/),n=BI.date2Str(e,t.substring(i?2:1)))):n=(t.match(/E/)?_eFormat:_numberFormat)(n,t),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 i=BI.parseFmt(t);return BI.parseDateTime(e,i)},BI.date2Str=function(e,t){if(!e)return"";var i=t.length,n="";if(0<i){for(var r=t.charAt(0),a=0,o=r,s=1;s<i;s++){var l=t.charAt(s);r!==l?(n+=u({"char":r,str:o,len:s-a},e),a=s,o=r=l):o+=l}n+=u({"char":r,str:o,len:i-a},e)}return n;function u(e,t){var i=e.str,n=e.len;switch(e["char"]){case"E":i=BI.Date._DN[t.getDay()];break;case"y":i=n<=3?(t.getFullYear()+"").slice(2,4):t.getFullYear();break;case"M":i=2<n?BI.Date._MN[t.getMonth()]:n<2?t.getMonth()+1:BI.leftPad(t.getMonth()+1+"",2,"0");break;case"d":i=1<n?BI.leftPad(t.getDate()+"",2,"0"):t.getDate();break;case"h":var r=t.getHours()%12;0===r&&(r=12),i=1<n?BI.leftPad(r+"",2,"0"):r;break;case"H":i=1<n?BI.leftPad(t.getHours()+"",2,"0"):t.getHours();break;case"m":i=1<n?BI.leftPad(t.getMinutes()+"",2,"0"):t.getMinutes();break;case"s":i=1<n?BI.leftPad(t.getSeconds()+"",2,"0"):t.getSeconds();break;case"a":i=t.getHours()<12?"am":"pm";break;case"z":i=BI.getTimezone(t);break;default:i=e.str}return i}},BI.object2Number=function(e){if(null==e)return 0;if("number"==typeof e)return e;var t=e+"";return(-1===t.indexOf(".")?parseInt: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=(t=e+"").replace(/-/g,"/"),i=new Date(t);return isInvalidDate(i)?new Date:i},BI.object2Time=function(e){if(null==e)return new Date;if(e instanceof Date)return e;var t=(t=e+"").replace(/-/g,"/"),i=new Date(t);return isInvalidDate(i)&&(-1!==t.indexOf("/")||-1===t.indexOf(":")||isInvalidDate(i=new Date("1970/01/01 "+t)))&&isInvalidDate(i=BI.parseDateTime(t,"HH:mm:ss"))?new Date:i}}()}).call(this,__webpack_require__(14))},function(e,t){_.extend(BI,{pushArray:function(e,t){for(var i=0;i<t.length;i++)e.push(t[i])},pushDistinct:function(e,t){BI.contains(e,t)||e.push(t)},pushDistinctArray:function(e,t){for(var i=0,n=t.length;i<n;i++)BI.pushDistinct(e,t[i])}})},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 i=e.getFullYear();return void 0===t&&(t=e.getMonth()),0!=i%4||0==i%100&&0!=i%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),i=t.getDay(),n=BI.StartOfWeek%7,r=(3+n)%7,a=i<n?7+i-n:i-n,o=(r=r||7)<n?7+r-n:r-n;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 i=BI.getDate(BI.getTime(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds())),n=i.getDate(),r=BI.getMonthDays(BI.getDate(i.getFullYear(),i.getMonth()+3*BI.parseInt(t),1));return r<n&&(n=r),i.setDate(n),i.setMonth(i.getMonth()+3*parseInt(t)),i},getQuarterStartMonth:function(e){var t=0,i=e.getMonth();return i<3&&(t=0),2<i&&i<6&&(t=3),5<i&&i<9&&(t=6),8<i&&(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 i=BI.getDate(BI.getTime(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds())),n=i.getDate(),r=BI.getMonthDays(BI.getDate(i.getFullYear(),i.getMonth()+parseInt(t),1));return r<n&&(n=r),i.setDate(n),i.setMonth(i.getMonth()+parseInt(t)),i},getWeekStartDate:function(e){var t=e.getDay(),i=BI.StartOfWeek%7;return BI.getOffsetDate(e,BI.Date._OFFSET[t<i?7+t-i:t-i])},getWeekEndDate:function(e){var t=e.getDay(),i=BI.StartOfWeek%7;return BI.getOffsetDate(e,BI.Date._OFFSET[t<i?7+t-i:t-i]+6)},print:function(e,t){for(var i=e.getMonth(),n=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=12<=c,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[i],u["%B"]=BI.Date._MN[i],u["%C"]=1+Math.floor(r/100),u["%d"]=n<10?"0"+n:n,u["%e"]=n,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"]=i<9?"0"+(1+i):1+i,u["%x"]=i+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===i&&(u["%y"]=parseInt(u["%y"])+1,u["%Y"]=parseInt(u["%Y"])+1);break;case 53:0===i&&(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 E=u[I[B]];E&&(m=new RegExp(I[B],"g"),t=t.replace(m,E))}return t}})},function(e,t){BI.Func=BI.Func||{},_.extend(BI.Func,{createDistinctName:function(e,i){var t=i,n=1;for(i=i||"";!BI.every(e,function(e,t){return BI.isKey(t)?t!==i:t.name!==i});)i=t+n++;return i},getGBWidth:function(e){return e=(e+="").replace(/[^\x00-\xff]/g,"xx"),Math.ceil(e.length/2)},getSearchResult:function(e,i,n,r){var a,o,s,l=BI.isArray(e);if(e=l?BI.flatten(e):e,n=n||"text",BI.isNull(r)&&(r=!0),!BI.isKey(i))return{find:r?BI.deepClone(e):e,match:l?[]:{}};i=BI.toUpperCase(i);var u=l?[]:{},c=l?[]:{};return BI.each(e,function(e,t){BI.isNull(t)||(r&&(t=BI.deepClone(t)),a=BI.stripEL(t),o=BI.find([a[n],a.text,a.value,a.name,a],function(e,t){return BI.isNotNull(t)}),BI.isNull(o)||BI.isObject(o)||(s=BI.makeFirstPY(o,{splitChar:""}),o=BI.toUpperCase(o),s=BI.toUpperCase(s),-1<o.indexOf(i)?o===i?l?u.push(t):u[e]=t:l?c.push(t):c[e]=t:-1<s.indexOf(i)&&(o===i||i.length===o.length?l?u.push(t):u[e]=t:l?c.push(t):c[e]=t)))}),{match:u,find:c}},getSortedResult:function(e,u){var c=BI.isFunction(u)?u: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,t){var i=c(e,u),n=c(t,u);if(BI.isNull(i)&&BI.isNull(n))return 0;if(BI.isNull(i))return-1;if(BI.isNull(n))return 1;if(i===n)return 0;for(var r=i.length,a=n.length,o=0;o<r&&o<a;o++){var s=i[o],l=n[o];if(s!==l)return(BI.isNull(BI.CODE_INDEX[s])?BI.MAX:BI.CODE_INDEX[s])-(BI.isNull(BI.CODE_INDEX[l])?BI.MAX:BI.CODE_INDEX[l])}return r-a})}}),_.extend(BI,{beforeFunc:function(e,t){var i=e;return function(){return!1!==t.apply(e,arguments)&&i.apply(e,arguments)}},afterFunc:function(t,i){var n=t;return function(){var e=n.apply(t,arguments);return!1!==e&&(i.apply(t,arguments),e)}}})},function(e,t){_.extend(BI,{add:function(e,t){return function(e,t){var i,n,r,a;try{i=e.toString().split(".")[1].length}catch(s){i=0}try{n=t.toString().split(".")[1].length}catch(s){n=0}{var o;a=Math.abs(i-n),r=Math.pow(10,Math.max(i,n)),t=0<a?(o=Math.pow(10,a),n<i?(e=Number(e.toString().replace(".","")),Number(t.toString().replace(".",""))*o):(e=Number(e.toString().replace(".",""))*o,Number(t.toString().replace(".","")))):(e=Number(e.toString().replace(".","")),Number(t.toString().replace(".","")))}return(e+t)/r}(t,e)},sub:function(e,t){var i,n,r;try{i=e.toString().split(".")[1].length}catch(a){i=0}try{n=t.toString().split(".")[1].length}catch(a){n=0}return r=Math.pow(10,Math.max(i,n)),((e*r-t*r)/r).toFixed(n<=i?i:n)},mul:function(e,t){return function(e,t){var i=0,n=e.toString(),r=t.toString();try{i+=n.split(".")[1].length}catch(a){}try{i+=r.split(".")[1].length}catch(a){}return Number(n.replace(".",""))*Number(r.replace(".",""))/Math.pow(10,i)}(t,e)},div:function(e,t){return r(e,t);function s(e){var t=e.toString().split(/[eE]/),i=(t[0].split(".")[1]||"").length-(t[1]||0);return 0<i?i:0}function l(e){if(-1===e.toString().indexOf("e"))return Number(e.toString().replace(".",""));var t=s(e);return 0<t?e*Math.pow(10,t):e}function u(e,t){for(var i=[],n=2;n<arguments.length;n++)i[n-2]=arguments[n];if(0<i.length)return u.apply(void 0,[u(e,t),i[0]].concat(i.slice(1)));var r=l(e),a=l(t),o=s(e)+s(t);return r*a/Math.pow(10,o)}function r(e,t){for(var i=[],n=2;n<arguments.length;n++)i[n-2]=arguments[n];return 0<i.length?r.apply(void 0,[r(e,t),i[0]].concat(i.slice(1))):u(l(e)/l(t),Math.pow(10,s(t)-s(e)))}}})},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 i=new RegExp("(^|&)"+t+"=([^&]*)(&|$)"),n=e.substr(e.indexOf("?")+1).match(i);return n?unescape(n[2]):null},appendQuery:function(e,t){if(!t)return e;var i=e;return-1===i.indexOf("?")&&(i+="?"),!1!==BI.endWith(i,"?")||(i+="&"),_.each(t,function(e,t){"string"==typeof t&&(i+=t+"="+e+"&")}),i=i.substr(0,i.length-1)},replaceAll:function(e,t,i){return BI.isString(e)?e.replace(new RegExp(t,"gm"),i):e},perfectStart:function(e,t){return BI.startWith(e,t)?e:t+e},allIndexOf:function(e,t){if("string"!=typeof t)return[];for(var i=[],n=0;0<e.length;){var r=e.indexOf(t);if(-1===r)break;i.push(n+r),e=e.substring(r+t.length,e.length),n+=r+t.length}return i}})},function(e,t){var l;l={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"},_.extend(BI,{makeFirstPY:function(e,t){if(t=t||{},"string"!=typeof e)return""+e;for(var i,n,r=[],a=0,o=e.length;a<o;a++){var s=e.charAt(a);r.push((n=void 0,40869<(n=(i=s).charCodeAt(0))||n<19968?i:l[n]?l[n]:"YDYQSXMWZSSXJBYMGCCZQPSSQBYCDSCDQLDYLYBSSJGYZZJJFKCCLZDHWDWZJLJPFYYNWJJTMYHZWZHFLZPPQHGSCYYYNJQYXXGJHHSDSJNKKTMOMLCRXYPSNQSECCQZGGLLYJLMYZZSECYKYYHQWJSSGGYXYZYJWWKDJHYCHMYXJTLXJYQBYXZLDWRDJRWYSRLDZJPCBZJJBRCFTLECZSTZFXXZHTRQHYBDLYCZSSYMMRFMYQZPWWJJYFCRWFDFZQPYDDWYXKYJAWJFFXYPSFTZYHHYZYSWCJYXSCLCXXWZZXNBGNNXBXLZSZSBSGPYSYZDHMDZBQBZCWDZZYYTZHBTSYYBZGNTNXQYWQSKBPHHLXGYBFMJEBJHHGQTJCYSXSTKZHLYCKGLYSMZXYALMELDCCXGZYRJXSDLTYZCQKCNNJWHJTZZCQLJSTSTBNXBTYXCEQXGKWJYFLZQLYHYXSPSFXLMPBYSXXXYDJCZYLLLSJXFHJXPJBTFFYABYXBHZZBJYZLWLCZGGBTSSMDTJZXPTHYQTGLJSCQFZKJZJQNLZWLSLHDZBWJNCJZYZSQQYCQYRZCJJWYBRTWPYFTWEXCSKDZCTBZHYZZYYJXZCFFZZMJYXXSDZZOTTBZLQWFCKSZSXFYRLNYJMBDTHJXSQQCCSBXYYTSYFBXDZTGBCNSLCYZZPSAZYZZSCJCSHZQYDXLBPJLLMQXTYDZXSQJTZPXLCGLQTZWJBHCTSYJSFXYEJJTLBGXSXJMYJQQPFZASYJNTYDJXKJCDJSZCBARTDCLYJQMWNQNCLLLKBYBZZSYHQQLTWLCCXTXLLZNTYLNEWYZYXCZXXGRKRMTCNDNJTSYYSSDQDGHSDBJGHRWRQLYBGLXHLGTGXBQJDZPYJSJYJCTMRNYMGRZJCZGJMZMGXMPRYXKJNYMSGMZJYMKMFXMLDTGFBHCJHKYLPFMDXLQJJSMTQGZSJLQDLDGJYCALCMZCSDJLLNXDJFFFFJCZFMZFFPFKHKGDPSXKTACJDHHZDDCRRCFQYJKQCCWJDXHWJLYLLZGCFCQDSMLZPBJJPLSBCJGGDCKKDEZSQCCKJGCGKDJTJDLZYCXKLQSCGJCLTFPCQCZGWPJDQYZJJBYJHSJDZWGFSJGZKQCCZLLPSPKJGQJHZZLJPLGJGJJTHJJYJZCZMLZLYQBGJWMLJKXZDZNJQSYZMLJLLJKYWXMKJLHSKJGBMCLYYMKXJQLBMLLKMDXXKWYXYSLMLPSJQQJQXYXFJTJDXMXXLLCXQBSYJBGWYMBGGBCYXPJYGPEPFGDJGBHBNSQJYZJKJKHXQFGQZKFHYGKHDKLLSDJQXPQYKYBNQSXQNSZSWHBSXWHXWBZZXDMNSJBSBKBBZKLYLXGWXDRWYQZMYWSJQLCJXXJXKJEQXSCYETLZHLYYYSDZPAQYZCMTLSHTZCFYZYXYLJSDCJQAGYSLCQLYYYSHMRQQKLDXZSCSSSYDYCJYSFSJBFRSSZQSBXXPXJYSDRCKGJLGDKZJZBDKTCSYQPYHSTCLDJDHMXMCGXYZHJDDTMHLTXZXYLYMOHYJCLTYFBQQXPFBDFHHTKSQHZYYWCNXXCRWHOWGYJLEGWDQCWGFJYCSNTMYTOLBYGWQWESJPWNMLRYDZSZTXYQPZGCWXHNGPYXSHMYQJXZTDPPBFYHZHTJYFDZWKGKZBLDNTSXHQEEGZZYLZMMZYJZGXZXKHKSTXNXXWYLYAPSTHXDWHZYMPXAGKYDXBHNHXKDPJNMYHYLPMGOCSLNZHKXXLPZZLBMLSFBHHGYGYYGGBHSCYAQTYWLXTZQCEZYDQDQMMHTKLLSZHLSJZWFYHQSWSCWLQAZYNYTLSXTHAZNKZZSZZLAXXZWWCTGQQTDDYZTCCHYQZFLXPSLZYGPZSZNGLNDQTBDLXGTCTAJDKYWNSYZLJHHZZCWNYYZYWMHYCHHYXHJKZWSXHZYXLYSKQYSPSLYZWMYPPKBYGLKZHTYXAXQSYSHXASMCHKDSCRSWJPWXSGZJLWWSCHSJHSQNHCSEGNDAQTBAALZZMSSTDQJCJKTSCJAXPLGGXHHGXXZCXPDMMHLDGTYBYSJMXHMRCPXXJZCKZXSHMLQXXTTHXWZFKHCCZDYTCJYXQHLXDHYPJQXYLSYYDZOZJNYXQEZYSQYAYXWYPDGXDDXSPPYZNDLTWRHXYDXZZJHTCXMCZLHPYYYYMHZLLHNXMYLLLMDCPPXHMXDKYCYRDLTXJCHHZZXZLCCLYLNZSHZJZZLNNRLWHYQSNJHXYNTTTKYJPYCHHYEGKCTTWLGQRLGGTGTYGYHPYHYLQYQGCWYQKPYYYTTTTLHYHLLTYTTSPLKYZXGZWGPYDSSZZDQXSKCQNMJJZZBXYQMJRTFFBTKHZKBXLJJKDXJTLBWFZPPTKQTZTGPDGNTPJYFALQMKGXBDCLZFHZCLLLLADPMXDJHLCCLGYHDZFGYDDGCYYFGYDXKSSEBDHYKDKDKHNAXXYBPBYYHXZQGAFFQYJXDMLJCSQZLLPCHBSXGJYNDYBYQSPZWJLZKSDDTACTBXZDYZYPJZQSJNKKTKNJDJGYYPGTLFYQKASDNTCYHBLWDZHBBYDWJRYGKZYHEYYFJMSDTYFZJJHGCXPLXHLDWXXJKYTCYKSSSMTWCTTQZLPBSZDZWZXGZAGYKTYWXLHLSPBCLLOQMMZSSLCMBJCSZZKYDCZJGQQDSMCYTZQQLWZQZXSSFPTTFQMDDZDSHDTDWFHTDYZJYQJQKYPBDJYYXTLJHDRQXXXHAYDHRJLKLYTWHLLRLLRCXYLBWSRSZZSYMKZZHHKYHXKSMDSYDYCJPBZBSQLFCXXXNXKXWYWSDZYQOGGQMMYHCDZTTFJYYBGSTTTYBYKJDHKYXBELHTYPJQNFXFDYKZHQKZBYJTZBXHFDXKDASWTAWAJLDYJSFHBLDNNTNQJTJNCHXFJSRFWHZFMDRYJYJWZPDJKZYJYMPCYZNYNXFBYTFYFWYGDBNZZZDNYTXZEMMQBSQEHXFZMBMFLZZSRXYMJGSXWZJSPRYDJSJGXHJJGLJJYNZZJXHGXKYMLPYYYCXYTWQZSWHWLYRJLPXSLSXMFSWWKLCTNXNYNPSJSZHDZEPTXMYYWXYYSYWLXJQZQXZDCLEEELMCPJPCLWBXSQHFWWTFFJTNQJHJQDXHWLBYZNFJLALKYYJLDXHHYCSTYYWNRJYXYWTRMDRQHWQCMFJDYZMHMYYXJWMYZQZXTLMRSPWWCHAQBXYGZYPXYYRRCLMPYMGKSJSZYSRMYJSNXTPLNBAPPYPYLXYYZKYNLDZYJZCZNNLMZHHARQMPGWQTZMXXMLLHGDZXYHXKYXYCJMFFYYHJFSBSSQLXXNDYCANNMTCJCYPRRNYTYQNYYMBMSXNDLYLYSLJRLXYSXQMLLYZLZJJJKYZZCSFBZXXMSTBJGNXYZHLXNMCWSCYZYFZLXBRNNNYLBNRTGZQYSATSWRYHYJZMZDHZGZDWYBSSCSKXSYHYTXXGCQGXZZSHYXJSCRHMKKBXCZJYJYMKQHZJFNBHMQHYSNJNZYBKNQMCLGQHWLZNZSWXKHLJHYYBQLBFCDSXDLDSPFZPSKJYZWZXZDDXJSMMEGJSCSSMGCLXXKYYYLNYPWWWGYDKZJGGGZGGSYCKNJWNJPCXBJJTQTJWDSSPJXZXNZXUMELPXFSXTLLXCLJXJJLJZXCTPSWXLYDHLYQRWHSYCSQYYBYAYWJJJQFWQCQQCJQGXALDBZZYJGKGXPLTZYFXJLTPADKYQHPMATLCPDCKBMTXYBHKLENXDLEEGQDYMSAWHZMLJTWYGXLYQZLJEEYYBQQFFNLYXRDSCTGJGXYYNKLLYQKCCTLHJLQMKKZGCYYGLLLJDZGYDHZWXPYSJBZKDZGYZZHYWYFQYTYZSZYEZZLYMHJJHTSMQWYZLKYYWZCSRKQYTLTDXWCTYJKLWSQZWBDCQYNCJSRSZJLKCDCDTLZZZACQQZZDDXYPLXZBQJYLZLLLQDDZQJYJYJZYXNYYYNYJXKXDAZWYRDLJYYYRJLXLLDYXJCYWYWNQCCLDDNYYYNYCKCZHXXCCLGZQJGKWPPCQQJYSBZZXYJSQPXJPZBSBDSFNSFPZXHDWZTDWPPTFLZZBZDMYYPQJRSDZSQZSQXBDGCPZSWDWCSQZGMDHZXMWWFYBPDGPHTMJTHZSMMBGZMBZJCFZWFZBBZMQCFMBDMCJXLGPNJBBXGYHYYJGPTZGZMQBQTCGYXJXLWZKYDPDYMGCFTPFXYZTZXDZXTGKMTYBBCLBJASKYTSSQYYMSZXFJEWLXLLSZBQJJJAKLYLXLYCCTSXMCWFKKKBSXLLLLJYXTYLTJYYTDPJHNHNNKBYQNFQYYZBYYESSESSGDYHFHWTCJBSDZZTFDMXHCNJZYMQWSRYJDZJQPDQBBSTJGGFBKJBXTGQHNGWJXJGDLLTHZHHYYYYYYSXWTYYYCCBDBPYPZYCCZYJPZYWCBDLFWZCWJDXXHYHLHWZZXJTCZLCDPXUJCZZZLYXJJTXPHFXWPYWXZPTDZZBDZCYHJHMLXBQXSBYLRDTGJRRCTTTHYTCZWMXFYTWWZCWJWXJYWCSKYBZSCCTZQNHXNWXXKHKFHTSWOCCJYBCMPZZYKBNNZPBZHHZDLSYDDYTYFJPXYNGFXBYQXCBHXCPSXTYZDMKYSNXSXLHKMZXLYHDHKWHXXSSKQYHHCJYXGLHZXCSNHEKDTGZXQYPKDHEXTYKCNYMYYYPKQYYYKXZLTHJQTBYQHXBMYHSQCKWWYLLHCYYLNNEQXQWMCFBDCCMLJGGXDQKTLXKGNQCDGZJWYJJLYHHQTTTNWCHMXCXWHWSZJYDJCCDBQCDGDNYXZTHCQRXCBHZTQCBXWGQWYYBXHMBYMYQTYEXMQKYAQYRGYZSLFYKKQHYSSQYSHJGJCNXKZYCXSBXYXHYYLSTYCXQTHYSMGSCPMMGCCCCCMTZTASMGQZJHKLOSQYLSWTMXSYQKDZLJQQYPLSYCZTCQQPBBQJZCLPKHQZYYXXDTDDTSJCXFFLLCHQXMJLWCJCXTSPYCXNDTJSHJWXDQQJSKXYAMYLSJHMLALYKXCYYDMNMDQMXMCZNNCYBZKKYFLMCHCMLHXRCJJHSYLNMTJZGZGYWJXSRXCWJGJQHQZDQJDCJJZKJKGDZQGJJYJYLXZXXCDQHHHEYTMHLFSBDJSYYSHFYSTCZQLPBDRFRZTZYKYWHSZYQKWDQZRKMSYNBCRXQBJYFAZPZZEDZCJYWBCJWHYJBQSZYWRYSZPTDKZPFPBNZTKLQYHBBZPNPPTYZZYBQNYDCPJMMCYCQMCYFZZDCMNLFPBPLNGQJTBTTNJZPZBBZNJKLJQYLNBZQHKSJZNGGQSZZKYXSHPZSNBCGZKDDZQANZHJKDRTLZLSWJLJZLYWTJNDJZJHXYAYNCBGTZCSSQMNJPJYTYSWXZFKWJQTKHTZPLBHSNJZSYZBWZZZZLSYLSBJHDWWQPSLMMFBJDWAQYZTCJTBNNWZXQXCDSLQGDSDPDZHJTQQPSWLYYJZLGYXYZLCTCBJTKTYCZJTQKBSJLGMGZDMCSGPYNJZYQYYKNXRPWSZXMTNCSZZYXYBYHYZAXYWQCJTLLCKJJTJHGDXDXYQYZZBYWDLWQCGLZGJGQRQZCZSSBCRPCSKYDZNXJSQGXSSJMYDNSTZTPBDLTKZWXQWQTZEXNQCZGWEZKSSBYBRTSSSLCCGBPSZQSZLCCGLLLZXHZQTHCZMQGYZQZNMCOCSZJMMZSQPJYGQLJYJPPLDXRGZYXCCSXHSHGTZNLZWZKJCXTCFCJXLBMQBCZZWPQDNHXLJCTHYZLGYLNLSZZPCXDSCQQHJQKSXZPBAJYEMSMJTZDXLCJYRYYNWJBNGZZTMJXLTBSLYRZPYLSSCNXPHLLHYLLQQZQLXYMRSYCXZLMMCZLTZSDWTJJLLNZGGQXPFSKYGYGHBFZPDKMWGHCXMSGDXJMCJZDYCABXJDLNBCDQYGSKYDQTXDJJYXMSZQAZDZFSLQXYJSJZYLBTXXWXQQZBJZUFBBLYLWDSLJHXJYZJWTDJCZFQZQZZDZSXZZQLZCDZFJHYSPYMPQZMLPPLFFXJJNZZYLSJEYQZFPFZKSYWJJJHRDJZZXTXXGLGHYDXCSKYSWMMZCWYBAZBJKSHFHJCXMHFQHYXXYZFTSJYZFXYXPZLCHMZMBXHZZSXYFYMNCWDABAZLXKTCSHHXKXJJZJSTHYGXSXYYHHHJWXKZXSSBZZWHHHCWTZZZPJXSNXQQJGZYZYWLLCWXZFXXYXYHXMKYYSWSQMNLNAYCYSPMJKHWCQHYLAJJMZXHMMCNZHBHXCLXTJPLTXYJHDYYLTTXFSZHYXXSJBJYAYRSMXYPLCKDUYHLXRLNLLSTYZYYQYGYHHSCCSMZCTZQXKYQFPYYRPFFLKQUNTSZLLZMWWTCQQYZWTLLMLMPWMBZSSTZRBPDDTLQJJBXZCSRZQQYGWCSXFWZLXCCRSZDZMCYGGDZQSGTJSWLJMYMMZYHFBJDGYXCCPSHXNZCSBSJYJGJMPPWAFFYFNXHYZXZYLREMZGZCYZSSZDLLJCSQFNXZKPTXZGXJJGFMYYYSNBTYLBNLHPFZDCYFBMGQRRSSSZXYSGTZRNYDZZCDGPJAFJFZKNZBLCZSZPSGCYCJSZLMLRSZBZZLDLSLLYSXSQZQLYXZLSKKBRXBRBZCYCXZZZEEYFGKLZLYYHGZSGZLFJHGTGWKRAAJYZKZQTSSHJJXDCYZUYJLZYRZDQQHGJZXSSZBYKJPBFRTJXLLFQWJHYLQTYMBLPZDXTZYGBDHZZRBGXHWNJTJXLKSCFSMWLSDQYSJTXKZSCFWJLBXFTZLLJZLLQBLSQMQQCGCZFPBPHZCZJLPYYGGDTGWDCFCZQYYYQYSSCLXZSKLZZZGFFCQNWGLHQYZJJCZLQZZYJPJZZBPDCCMHJGXDQDGDLZQMFGPSYTSDYFWWDJZJYSXYYCZCYHZWPBYKXRYLYBHKJKSFXTZJMMCKHLLTNYYMSYXYZPYJQYCSYCWMTJJKQYRHLLQXPSGTLYYCLJSCPXJYZFNMLRGJJTYZBXYZMSJYJHHFZQMSYXRSZCWTLRTQZSSTKXGQKGSPTGCZNJSJCQCXHMXGGZTQYDJKZDLBZSXJLHYQGGGTHQSZPYHJHHGYYGKGGCWJZZYLCZLXQSFTGZSLLLMLJSKCTBLLZZSZMMNYTPZSXQHJCJYQXYZXZQZCPSHKZZYSXCDFGMWQRLLQXRFZTLYSTCTMJCXJJXHJNXTNRZTZFQYHQGLLGCXSZSJDJLJCYDSJTLNYXHSZXCGJZYQPYLFHDJSBPCCZHJJJQZJQDYBSSLLCMYTTMQTBHJQNNYGKYRQYQMZGCJKPDCGMYZHQLLSLLCLMHOLZGDYYFZSLJCQZLYLZQJESHNYLLJXGJXLYSYYYXNBZLJSSZCQQCJYLLZLTJYLLZLLBNYLGQCHXYYXOXCXQKYJXXXYKLXSXXYQXCYKQXQCSGYXXYQXYGYTQOHXHXPYXXXULCYEYCHZZCBWQBBWJQZSCSZSSLZYLKDESJZWMYMCYTSDSXXSCJPQQSQYLYYZYCMDJDZYWCBTJSYDJKCYDDJLBDJJSODZYSYXQQYXDHHGQQYQHDYXWGMMMAJDYBBBPPBCMUUPLJZSMTXERXJMHQNUTPJDCBSSMSSSTKJTSSMMTRCPLZSZMLQDSDMJMQPNQDXCFYNBFSDQXYXHYAYKQYDDLQYYYSSZBYDSLNTFQTZQPZMCHDHCZCWFDXTMYQSPHQYYXSRGJCWTJTZZQMGWJJTJHTQJBBHWZPXXHYQFXXQYWYYHYSCDYDHHQMNMTMWCPBSZPPZZGLMZFOLLCFWHMMSJZTTDHZZYFFYTZZGZYSKYJXQYJZQBHMBZZLYGHGFMSHPZFZSNCLPBQSNJXZSLXXFPMTYJYGBXLLDLXPZJYZJYHHZCYWHJYLSJEXFSZZYWXKZJLUYDTMLYMQJPWXYHXSKTQJEZRPXXZHHMHWQPWQLYJJQJJZSZCPHJLCHHNXJLQWZJHBMZYXBDHHYPZLHLHLGFWLCHYYTLHJXCJMSCPXSTKPNHQXSRTYXXTESYJCTLSSLSTDLLLWWYHDHRJZSFGXTSYCZYNYHTDHWJSLHTZDQDJZXXQHGYLTZPHCSQFCLNJTCLZPFSTPDYNYLGMJLLYCQHYSSHCHYLHQYQTMZYPBYWRFQYKQSYSLZDQJMPXYYSSRHZJNYWTQDFZBWWTWWRXCWHGYHXMKMYYYQMSMZHNGCEPMLQQMTCWCTMMPXJPJJHFXYYZSXZHTYBMSTSYJTTQQQYYLHYNPYQZLCYZHZWSMYLKFJXLWGXYPJYTYSYXYMZCKTTWLKSMZSYLMPWLZWXWQZSSAQSYXYRHSSNTSRAPXCPWCMGDXHXZDZYFJHGZTTSBJHGYZSZYSMYCLLLXBTYXHBBZJKSSDMALXHYCFYGMQYPJYCQXJLLLJGSLZGQLYCJCCZOTYXMTMTTLLWTGPXYMZMKLPSZZZXHKQYSXCTYJZYHXSHYXZKXLZWPSQPYHJWPJPWXQQYLXSDHMRSLZZYZWTTCYXYSZZSHBSCCSTPLWSSCJCHNLCGCHSSPHYLHFHHXJSXYLLNYLSZDHZXYLSXLWZYKCLDYAXZCMDDYSPJTQJZLNWQPSSSWCTSTSZLBLNXSMNYYMJQBQHRZWTYYDCHQLXKPZWBGQYBKFCMZWPZLLYYLSZYDWHXPSBCMLJBSCGBHXLQHYRLJXYSWXWXZSLDFHLSLYNJLZYFLYJYCDRJLFSYZFSLLCQYQFGJYHYXZLYLMSTDJCYHBZLLNWLXXYGYYHSMGDHXXHHLZZJZXCZZZCYQZFNGWPYLCPKPYYPMCLQKDGXZGGWQBDXZZKZFBXXLZXJTPJPTTBYTSZZDWSLCHZHSLTYXHQLHYXXXYYZYSWTXZKHLXZXZPYHGCHKCFSYHUTJRLXFJXPTZTWHPLYXFCRHXSHXKYXXYHZQDXQWULHYHMJTBFLKHTXCWHJFWJCFPQRYQXCYYYQYGRPYWSGSUNGWCHKZDXYFLXXHJJBYZWTSXXNCYJJYMSWZJQRMHXZWFQSYLZJZGBHYNSLBGTTCSYBYXXWXYHXYYXNSQYXMQYWRGYQLXBBZLJSYLPSYTJZYHYZAWLRORJMKSCZJXXXYXCHDYXRYXXJDTSQFXLYLTSFFYXLMTYJMJUYYYXLTZCSXQZQHZXLYYXZHDNBRXXXJCTYHLBRLMBRLLAXKYLLLJLYXXLYCRYLCJTGJCMTLZLLCYZZPZPCYAWHJJFYBDYYZSMPCKZDQYQPBPCJPDCYZMDPBCYYDYCNNPLMTMLRMFMMGWYZBSJGYGSMZQQQZTXMKQWGXLLPJGZBQCDJJJFPKJKCXBLJMSWMDTQJXLDLPPBXCWRCQFBFQJCZAHZGMYKPHYYHZYKNDKZMBPJYXPXYHLFPNYYGXJDBKXNXHJMZJXSTRSTLDXSKZYSYBZXJLXYSLBZYSLHXJPFXPQNBYLLJQKYGZMCYZZYMCCSLCLHZFWFWYXZMWSXTYNXJHPYYMCYSPMHYSMYDYSHQYZCHMJJMZCAAGCFJBBHPLYZYLXXSDJGXDHKXXTXXNBHRMLYJSLTXMRHNLXQJXYZLLYSWQGDLBJHDCGJYQYCMHWFMJYBMBYJYJWYMDPWHXQLDYGPDFXXBCGJSPCKRSSYZJMSLBZZJFLJJJLGXZGYXYXLSZQYXBEXYXHGCXBPLDYHWETTWWCJMBTXCHXYQXLLXFLYXLLJLSSFWDPZSMYJCLMWYTCZPCHQEKCQBWLCQYDPLQPPQZQFJQDJHYMMCXTXDRMJWRHXCJZYLQXDYYNHYYHRSLSRSYWWZJYMTLTLLGTQCJZYABTCKZCJYCCQLJZQXALMZYHYWLWDXZXQDLLQSHGPJFJLJHJABCQZDJGTKHSSTCYJLPSWZLXZXRWGLDLZRLZXTGSLLLLZLYXXWGDZYGBDPHZPBRLWSXQBPFDWOFMWHLYPCBJCCLDMBZPBZZLCYQXLDOMZBLZWPDWYYGDSTTHCSQSCCRSSSYSLFYBFNTYJSZDFNDPDHDZZMBBLSLCMYFFGTJJQWFTMTPJWFNLBZCMMJTGBDZLQLPYFHYYMJYLSDCHDZJWJCCTLJCLDTLJJCPDDSQDSSZYBNDBJLGGJZXSXNLYCYBJXQYCBYLZCFZPPGKCXZDZFZTJJFJSJXZBNZYJQTTYJYHTYCZHYMDJXTTMPXSPLZCDWSLSHXYPZGTFMLCJTYCBPMGDKWYCYZCDSZZYHFLYCTYGWHKJYYLSJCXGYWJCBLLCSNDDBTZBSCLYZCZZSSQDLLMQYYHFSLQLLXFTYHABXGWNYWYYPLLSDLDLLBJCYXJZMLHLJDXYYQYTDLLLBUGBFDFBBQJZZMDPJHGCLGMJJPGAEHHBWCQXAXHHHZCHXYPHJAXHLPHJPGPZJQCQZGJJZZUZDMQYYBZZPHYHYBWHAZYJHYKFGDPFQSDLZMLJXKXGALXZDAGLMDGXMWZQYXXDXXPFDMMSSYMPFMDMMKXKSYZYSHDZKXSYSMMZZZMSYDNZZCZXFPLSTMZDNMXCKJMZTYYMZMZZMSXHHDCZJEMXXKLJSTLWLSQLYJZLLZJSSDPPMHNLZJCZYHMXXHGZCJMDHXTKGRMXFWMCGMWKDTKSXQMMMFZZYDKMSCLCMPCGMHSPXQPZDSSLCXKYXTWLWJYAHZJGZQMCSNXYYMMPMLKJXMHLMLQMXCTKZMJQYSZJSYSZHSYJZJCDAJZYBSDQJZGWZQQXFKDMSDJLFWEHKZQKJPEYPZYSZCDWYJFFMZZYLTTDZZEFMZLBNPPLPLPEPSZALLTYLKCKQZKGENQLWAGYXYDPXLHSXQQWQCQXQCLHYXXMLYCCWLYMQYSKGCHLCJNSZKPYZKCQZQLJPDMDZHLASXLBYDWQLWDNBQCRYDDZTJYBKBWSZDXDTNPJDTCTQDFXQQMGNXECLTTBKPWSLCTYQLPWYZZKLPYGZCQQPLLKCCYLPQMZCZQCLJSLQZDJXLDDHPZQDLJJXZQDXYZQKZLJCYQDYJPPYPQYKJYRMPCBYMCXKLLZLLFQPYLLLMBSGLCYSSLRSYSQTMXYXZQZFDZUYSYZTFFMZZSMZQHZSSCCMLYXWTPZGXZJGZGSJSGKDDHTQGGZLLBJDZLCBCHYXYZHZFYWXYZYMSDBZZYJGTSMTFXQYXQSTDGSLNXDLRYZZLRYYLXQHTXSRTZNGZXBNQQZFMYKMZJBZYMKBPNLYZPBLMCNQYZZZSJZHJCTZKHYZZJRDYZHNPXGLFZTLKGJTCTSSYLLGZRZBBQZZKLPKLCZYSSUYXBJFPNJZZXCDWXZYJXZZDJJKGGRSRJKMSMZJLSJYWQSKYHQJSXPJZZZLSNSHRNYPZTWCHKLPSRZLZXYJQXQKYSJYCZTLQZYBBYBWZPQDWWYZCYTJCJXCKCWDKKZXSGKDZXWWYYJQYYTCYTDLLXWKCZKKLCCLZCQQDZLQLCSFQCHQHSFSMQZZLNBJJZBSJHTSZDYSJQJPDLZCDCWJKJZZLPYCGMZWDJJBSJQZSYZYHHXJPBJYDSSXDZNCGLQMBTSFSBPDZDLZNFGFJGFSMPXJQLMBLGQCYYXBQKDJJQYRFKZTJDHCZKLBSDZCFJTPLLJGXHYXZCSSZZXSTJYGKGCKGYOQXJPLZPBPGTGYJZGHZQZZLBJLSQFZGKQQJZGYCZBZQTLDXRJXBSXXPZXHYZYCLWDXJJHXMFDZPFZHQHQMQGKSLYHTYCGFRZGNQXCLPDLBZCSCZQLLJBLHBZCYPZZPPDYMZZSGYHCKCPZJGSLJLNSCDSLDLXBMSTLDDFJMKDJDHZLZXLSZQPQPGJLLYBDSZGQLBZLSLKYYHZTTNTJYQTZZPSZQZTLLJTYYLLQLLQYZQLBDZLSLYYZYMDFSZSNHLXZNCZQZPBWSKRFBSYZMTHBLGJPMCZZLSTLXSHTCSYZLZBLFEQHLXFLCJLYLJQCBZLZJHHSSTBRMHXZHJZCLXFNBGXGTQJCZTMSFZKJMSSNXLJKBHSJXNTNLZDNTLMSJXGZJYJCZXYJYJWRWWQNZTNFJSZPZSHZJFYRDJSFSZJZBJFZQZZHZLXFYSBZQLZSGYFTZDCSZXZJBQMSZKJRHYJZCKMJKHCHGTXKXQGLXPXFXTRTYLXJXHDTSJXHJZJXZWZLCQSBTXWXGXTXXHXFTSDKFJHZYJFJXRZSDLLLTQSQQZQWZXSYQTWGWBZCGZLLYZBCLMQQTZHZXZXLJFRMYZFLXYSQXXJKXRMQDZDMMYYBSQBHGZMWFWXGMXLZPYYTGZYCCDXYZXYWGSYJYZNBHPZJSQSYXSXRTFYZGRHZTXSZZTHCBFCLSYXZLZQMZLMPLMXZJXSFLBYZMYQHXJSXRXSQZZZSSLYFRCZJRCRXHHZXQYDYHXSJJHZCXZBTYNSYSXJBQLPXZQPYMLXZKYXLXCJLCYSXXZZLXDLLLJJYHZXGYJWKJRWYHCPSGNRZLFZWFZZNSXGXFLZSXZZZBFCSYJDBRJKRDHHGXJLJJTGXJXXSTJTJXLYXQFCSGSWMSBCTLQZZWLZZKXJMLTMJYHSDDBXGZHDLBMYJFRZFSGCLYJBPMLYSMSXLSZJQQHJZFXGFQFQBPXZGYYQXGZTCQWYLTLGWSGWHRLFSFGZJMGMGBGTJFSYZZGZYZAFLSSPMLPFLCWBJZCLJJMZLPJJLYMQDMYYYFBGYGYZMLYZDXQYXRQQQHSYYYQXYLJTYXFSFSLLGNQCYHYCWFHCCCFXPYLYPLLZYXXXXXKQHHXSHJZCFZSCZJXCPZWHHHHHAPYLQALPQAFYHXDYLUKMZQGGGDDESRNNZLTZGCHYPPYSQJJHCLLJTOLNJPZLJLHYMHEYDYDSQYCDDHGZUNDZCLZYZLLZNTNYZGSLHSLPJJBDGWXPCDUTJCKLKCLWKLLCASSTKZZDNQNTTLYYZSSYSSZZRYLJQKCQDHHCRXRZYDGRGCWCGZQFFFPPJFZYNAKRGYWYQPQXXFKJTSZZXSWZDDFBBXTBGTZKZNPZZPZXZPJSZBMQHKCYXYLDKLJNYPKYGHGDZJXXEAHPNZKZTZCMXCXMMJXNKSZQNMNLWBWWXJKYHCPSTMCSQTZJYXTPCTPDTNNPGLLLZSJLSPBLPLQHDTNJNLYYRSZFFJFQWDPHZDWMRZCCLODAXNSSNYZRESTYJWJYJDBCFXNMWTTBYLWSTSZGYBLJPXGLBOCLHPCBJLTMXZLJYLZXCLTPNCLCKXTPZJSWCYXSFYSZDKNTLBYJCYJLLSTGQCBXRYZXBXKLYLHZLQZLNZCXWJZLJZJNCJHXMNZZGJZZXTZJXYCYYCXXJYYXJJXSSSJSTSSTTPPGQTCSXWZDCSYFPTFBFHFBBLZJCLZZDBXGCXLQPXKFZFLSYLTUWBMQJHSZBMDDBCYSCCLDXYCDDQLYJJWMQLLCSGLJJSYFPYYCCYLTJANTJJPWYCMMGQYYSXDXQMZHSZXPFTWWZQSWQRFKJLZJQQYFBRXJHHFWJJZYQAZMYFRHCYYBYQWLPEXCCZSTYRLTTDMQLYKMBBGMYYJPRKZNPBSXYXBHYZDJDNGHPMFSGMWFZMFQMMBCMZZCJJLCNUXYQLMLRYGQZCYXZLWJGCJCGGMCJNFYZZJHYCPRRCMTZQZXHFQGTJXCCJEAQCRJYHPLQLSZDJRBCQHQDYRHYLYXJSYMHZYDWLDFRYHBPYDTSSCNWBXGLPZMLZZTQSSCPJMXXYCSJYTYCGHYCJWYRXXLFEMWJNMKLLSWTXHYYYNCMMCWJDQDJZGLLJWJRKHPZGGFLCCSCZMCBLTBHBQJXQDSPDJZZGHGLFQYWBZYZJLTSTDHQHCTCBCHFLQMPWDSHYYTQWCNZZJTLBYMBPDYYYXSQKXWYYFLXXNCWCXYPMAELYKKJMZZZBRXYYQJFLJPFHHHYTZZXSGQQMHSPGDZQWBWPJHZJDYSCQWZKTXXSQLZYYMYSDZGRXCKKUJLWPYSYSCSYZLRMLQSYLJXBCXTLWDQZPCYCYKPPPNSXFYZJJRCEMHSZMSXLXGLRWGCSTLRSXBZGBZGZTCPLUJLSLYLYMTXMTZPALZXPXJTJWTCYYZLBLXBZLQMYLXPGHDSLSSDMXMBDZZSXWHAMLCZCPJMCNHJYSNSYGCHSKQMZZQDLLKABLWJXSFMOCDXJRRLYQZKJMYBYQLYHETFJZFRFKSRYXFJTWDSXXSYSQJYSLYXWJHSNLXYYXHBHAWHHJZXWMYLJCSSLKYDZTXBZSYFDXGXZJKHSXXYBSSXDPYNZWRPTQZCZENYGCXQFJYKJBZMLJCMQQXUOXSLYXXLYLLJDZBTYMHPFSTTQQWLHOKYBLZZALZXQLHZWRRQHLSTMYPYXJJXMQSJFNBXYXYJXXYQYLTHYLQYFMLKLJTMLLHSZWKZHLJMLHLJKLJSTLQXYLMBHHLNLZXQJHXCFXXLHYHJJGBYZZKBXSCQDJQDSUJZYYHZHHMGSXCSYMXFEBCQWWRBPYYJQTYZCYQYQQZYHMWFFHGZFRJFCDPXNTQYZPDYKHJLFRZXPPXZDBBGZQSTLGDGYLCQMLCHHMFYWLZYXKJLYPQHSYWMQQGQZMLZJNSQXJQSYJYCBEHSXFSZPXZWFLLBCYYJDYTDTHWZSFJMQQYJLMQXXLLDTTKHHYBFPWTYYSQQWNQWLGWDEBZWCMYGCULKJXTMXMYJSXHYBRWFYMWFRXYQMXYSZTZZTFYKMLDHQDXWYYNLCRYJBLPSXCXYWLSPRRJWXHQYPHTYDNXHHMMYWYTZCSQMTSSCCDALWZTCPQPYJLLQZYJSWXMZZMMYLMXCLMXCZMXMZSQTZPPQQBLPGXQZHFLJJHYTJSRXWZXSCCDLXTYJDCQJXSLQYCLZXLZZXMXQRJMHRHZJBHMFLJLMLCLQNLDXZLLLPYPSYJYSXCQQDCMQJZZXHNPNXZMEKMXHYKYQLXSXTXJYYHWDCWDZHQYYBGYBCYSCFGPSJNZDYZZJZXRZRQJJYMCANYRJTLDPPYZBSTJKXXZYPFDWFGZZRPYMTNGXZQBYXNBUFNQKRJQZMJEGRZGYCLKXZDSKKNSXKCLJSPJYYZLQQJYBZSSQLLLKJXTBKTYLCCDDBLSPPFYLGYDTZJYQGGKQTTFZXBDKTYYHYBBFYTYYBCLPDYTGDHRYRNJSPTCSNYJQHKLLLZSLYDXXWBCJQSPXBPJZJCJDZFFXXBRMLAZHCSNDLBJDSZBLPRZTSWSBXBCLLXXLZDJZSJPYLYXXYFTFFFBHJJXGBYXJPMMMPSSJZJMTLYZJXSWXTYLEDQPJMYGQZJGDJLQJWJQLLSJGJGYGMSCLJJXDTYGJQJQJCJZCJGDZZSXQGSJGGCXHQXSNQLZZBXHSGZXCXYLJXYXYYDFQQJHJFXDHCTXJYRXYSQTJXYEFYYSSYYJXNCYZXFXMSYSZXYYSCHSHXZZZGZZZGFJDLTYLNPZGYJYZYYQZPBXQBDZTZCZYXXYHHSQXSHDHGQHJHGYWSZTMZMLHYXGEBTYLZKQWYTJZRCLEKYSTDBCYKQQSAYXCJXWWGSBHJYZYDHCSJKQCXSWXFLTYNYZPZCCZJQTZWJQDZZZQZLJJXLSBHPYXXPSXSHHEZTXFPTLQYZZXHYTXNCFZYYHXGNXMYWXTZSJPTHHGYMXMXQZXTSBCZYJYXXTYYZYPCQLMMSZMJZZLLZXGXZAAJZYXJMZXWDXZSXZDZXLEYJJZQBHZWZZZQTZPSXZTDSXJJJZNYAZPHXYYSRNQDTHZHYYKYJHDZXZLSWCLYBZYECWCYCRYLCXNHZYDZYDYJDFRJJHTRSQTXYXJRJHOJYNXELXSFSFJZGHPZSXZSZDZCQZBYYKLSGSJHCZSHDGQGXYZGXCHXZJWYQWGYHKSSEQZZNDZFKWYSSTCLZSTSYMCDHJXXYWEYXCZAYDMPXMDSXYBSQMJMZJMTZQLPJYQZCGQHXJHHLXXHLHDLDJQCLDWBSXFZZYYSCHTYTYYBHECXHYKGJPXHHYZJFXHWHBDZFYZBCAPNPGNYDMSXHMMMMAMYNBYJTMPXYYMCTHJBZYFCGTYHWPHFTWZZEZSBZEGPFMTSKFTYCMHFLLHGPZJXZJGZJYXZSBBQSCZZLZCCSTPGXMJSFTCCZJZDJXCYBZLFCJSYZFGSZLYBCWZZBYZDZYPSWYJZXZBDSYUXLZZBZFYGCZXBZHZFTPBGZGEJBSTGKDMFHYZZJHZLLZZGJQZLSFDJSSCBZGPDLFZFZSZYZYZSYGCXSNXXCHCZXTZZLJFZGQSQYXZJQDCCZTQCDXZJYQJQCHXZTDLGSCXZSYQJQTZWLQDQZTQCHQQJZYEZZZPBWKDJFCJPZTYPQYQTTYNLMBDKTJZPQZQZZFPZSBNJLGYJDXJDZZKZGQKXDLPZJTCJDQBXDJQJSTCKNXBXZMSLYJCQMTJQWWCJQNJNLLLHJCWQTBZQYDZCZPZZDZYDDCYZZZCCJTTJFZDPRRTZTJDCQTQZDTJNPLZBCLLCTZSXKJZQZPZLBZRBTJDCXFCZDBCCJJLTQQPLDCGZDBBZJCQDCJWYNLLZYZCCDWLLXWZLXRXNTQQCZXKQLSGDFQTDDGLRLAJJTKUYMKQLLTZYTDYYCZGJWYXDXFRSKSTQTENQMRKQZHHQKDLDAZFKYPBGGPZREBZZYKZZSPEGJXGYKQZZZSLYSYYYZWFQZYLZZLZHWCHKYPQGNPGBLPLRRJYXCCSYYHSFZFYBZYYTGZXYLXCZWXXZJZBLFFLGSKHYJZEYJHLPLLLLCZGXDRZELRHGKLZZYHZLYQSZZJZQLJZFLNBHGWLCZCFJYSPYXZLZLXGCCPZBLLCYBBBBUBBCBPCRNNZCZYRBFSRLDCGQYYQXYGMQZWTZYTYJXYFWTEHZZJYWLCCNTZYJJZDEDPZDZTSYQJHDYMBJNYJZLXTSSTPHNDJXXBYXQTZQDDTJTDYYTGWSCSZQFLSHLGLBCZPHDLYZJYCKWTYTYLBNYTSDSYCCTYSZYYEBHEXHQDTWNYGYCLXTSZYSTQMYGZAZCCSZZDSLZCLZRQXYYELJSBYMXSXZTEMBBLLYYLLYTDQYSHYMRQWKFKBFXNXSBYCHXBWJYHTQBPBSBWDZYLKGZSKYHXQZJXHXJXGNLJKZLYYCDXLFYFGHLJGJYBXQLYBXQPQGZTZPLNCYPXDJYQYDYMRBESJYYHKXXSTMXRCZZYWXYQYBMCLLYZHQYZWQXDBXBZWZMSLPDMYSKFMZKLZCYQYCZLQXFZZYDQZPZYGYJYZMZXDZFYFYTTQTZHGSPCZMLCCYTZXJCYTJMKSLPZHYSNZLLYTPZCTZZCKTXDHXXTQCYFKSMQCCYYAZHTJPCYLZLYJBJXTPNYLJYYNRXSYLMMNXJSMYBCSYSYLZYLXJJQYLDZLPQBFZZBLFNDXQKCZFYWHGQMRDSXYCYTXNQQJZYYPFZXDYZFPRXEJDGYQBXRCNFYYQPGHYJDYZXGRHTKYLNWDZNTSMPKLBTHBPYSZBZTJZSZZJTYYXZPHSSZZBZCZPTQFZMYFLYPYBBJQXZMXXDJMTSYSKKBJZXHJCKLPSMKYJZCXTMLJYXRZZQSLXXQPYZXMKYXXXJCLJPRMYYGADYSKQLSNDHYZKQXZYZTCGHZTLMLWZYBWSYCTBHJHJFCWZTXWYTKZLXQSHLYJZJXTMPLPYCGLTBZZTLZJCYJGDTCLKLPLLQPJMZPAPXYZLKKTKDZCZZBNZDYDYQZJYJGMCTXLTGXSZLMLHBGLKFWNWZHDXUHLFMKYSLGXDTWWFRJEJZTZHYDXYKSHWFZCQSHKTMQQHTZHYMJDJSKHXZJZBZZXYMPAGQMSTPXLSKLZYNWRTSQLSZBPSPSGZWYHTLKSSSWHZZLYYTNXJGMJSZSUFWNLSOZTXGXLSAMMLBWLDSZYLAKQCQCTMYCFJBSLXCLZZCLXXKSBZQCLHJPSQPLSXXCKSLNHPSFQQYTXYJZLQLDXZQJZDYYDJNZPTUZDSKJFSLJHYLZSQZLBTXYDGTQFDBYAZXDZHZJNHHQBYKNXJJQCZMLLJZKSPLDYCLBBLXKLELXJLBQYCXJXGCNLCQPLZLZYJTZLJGYZDZPLTQCSXFDMNYCXGBTJDCZNBGBQYQJWGKFHTNPYQZQGBKPBBYZMTJDYTBLSQMPSXTBNPDXKLEMYYCJYNZCTLDYKZZXDDXHQSHDGMZSJYCCTAYRZLPYLTLKXSLZCGGEXCLFXLKJRTLQJAQZNCMBYDKKCXGLCZJZXJHPTDJJMZQYKQSECQZDSHHADMLZFMMZBGNTJNNLGBYJBRBTMLBYJDZXLCJLPLDLPCQDHLXZLYCBLCXZZJADJLNZMMSSSMYBHBSQKBHRSXXJMXSDZNZPXLGBRHWGGFCXGMSKLLTSJYYCQLTSKYWYYHYWXBXQYWPYWYKQLSQPTNTKHQCWDQKTWPXXHCPTHTWUMSSYHBWCRWXHJMKMZNGWTMLKFGHKJYLSYYCXWHYECLQHKQHTTQKHFZLDXQWYZYYDESBPKYRZPJFYYZJCEQDZZDLATZBBFJLLCXDLMJSSXEGYGSJQXCWBXSSZPDYZCXDNYXPPZYDLYJCZPLTXLSXYZYRXCYYYDYLWWNZSAHJSYQYHGYWWAXTJZDAXYSRLTDPSSYYFNEJDXYZHLXLLLZQZSJNYQYQQXYJGHZGZCYJCHZLYCDSHWSHJZYJXCLLNXZJJYYXNFXMWFPYLCYLLABWDDHWDXJMCXZTZPMLQZHSFHZYNZTLLDYWLSLXHYMMYLMBWWKYXYADTXYLLDJPYBPWUXJMWMLLSAFDLLYFLBHHHBQQLTZJCQJLDJTFFKMMMBYTHYGDCQRDDWRQJXNBYSNWZDBYYTBJHPYBYTTJXAAHGQDQTMYSTQXKBTZPKJLZRBEQQSSMJJBDJOTGTBXPGBKTLHQXJJJCTHXQDWJLWRFWQGWSHCKRYSWGFTGYGBXSDWDWRFHWYTJJXXXJYZYSLPYYYPAYXHYDQKXSHXYXGSKQHYWFDDDPPLCJLQQEEWXKSYYKDYPLTJTHKJLTCYYHHJTTPLTZZCDLTHQKZXQYSTEEYWYYZYXXYYSTTJKLLPZMCYHQGXYHSRMBXPLLNQYDQHXSXXWGDQBSHYLLPJJJTHYJKYPPTHYYKTYEZYENMDSHLCRPQFDGFXZPSFTLJXXJBSWYYSKSFLXLPPLBBBLBSFXFYZBSJSSYLPBBFFFFSSCJDSTZSXZRYYSYFFSYZYZBJTBCTSBSDHRTJJBYTCXYJEYLXCBNEBJDSYXYKGSJZBXBYTFZWGENYHHTHZHHXFWGCSTBGXKLSXYWMTMBYXJSTZSCDYQRCYTWXZFHMYMCXLZNSDJTTTXRYCFYJSBSDYERXJLJXBBDEYNJGHXGCKGSCYMBLXJMSZNSKGXFBNBPTHFJAAFXYXFPXMYPQDTZCXZZPXRSYWZDLYBBKTYQPQJPZYPZJZNJPZJLZZFYSBTTSLMPTZRTDXQSJEHBZYLZDHLJSQMLHTXTJECXSLZZSPKTLZKQQYFSYGYWPCPQFHQHYTQXZKRSGTTSQCZLPTXCDYYZXSQZSLXLZMYCPCQBZYXHBSXLZDLTCDXTYLZJYYZPZYZLTXJSJXHLPMYTXCQRBLZSSFJZZTNJYTXMYJHLHPPLCYXQJQQKZZSCPZKSWALQSBLCCZJSXGWWWYGYKTJBBZTDKHXHKGTGPBKQYSLPXPJCKBMLLXDZSTBKLGGQKQLSBKKTFXRMDKBFTPZFRTBBRFERQGXYJPZSSTLBZTPSZQZSJDHLJQLZBPMSMMSXLQQNHKNBLRDDNXXDHDDJCYYGYLXGZLXSYGMQQGKHBPMXYXLYTQWLWGCPBMQXCYZYDRJBHTDJYHQSHTMJSBYPLWHLZFFNYPMHXXHPLTBQPFBJWQDBYGPNZTPFZJGSDDTQSHZEAWZZYLLTYYBWJKXXGHLFKXDJTMSZSQYNZGGSWQSPHTLSSKMCLZXYSZQZXNCJDQGZDLFNYKLJCJLLZLMZZNHYDSSHTHZZLZZBBHQZWWYCRZHLYQQJBEYFXXXWHSRXWQHWPSLMSSKZTTYGYQQWRSLALHMJTQJSMXQBJJZJXZYZKXBYQXBJXSHZTSFJLXMXZXFGHKZSZGGYLCLSARJYHSLLLMZXELGLXYDJYTLFBHBPNLYZFBBHPTGJKWETZHKJJXZXXGLLJLSTGSHJJYQLQZFKCGNNDJSSZFDBCTWWSEQFHQJBSAQTGYPQLBXBMMYWXGSLZHGLZGQYFLZBYFZJFRYSFMBYZHQGFWZSYFYJJPHZBYYZFFWODGRLMFTWLBZGYCQXCDJYGZYYYYTYTYDWEGAZYHXJLZYYHLRMGRXXZCLHNELJJTJTPWJYBJJBXJJTJTEEKHWSLJPLPSFYZPQQBDLQJJTYYQLYZKDKSQJYYQZLDQTGJQYZJSUCMRYQTHTEJMFCTYHYPKMHYZWJDQFHYYXWSHCTXRLJHQXHCCYYYJLTKTTYTMXGTCJTZAYYOCZLYLBSZYWJYTSJYHBYSHFJLYGJXXTMZYYLTXXYPZLXYJZYZYYPNHMYMDYYLBLHLSYYQQLLNJJYMSOYQBZGDLYXYLCQYXTSZEGXHZGLHWBLJHEYXTWQMAKBPQCGYSHHEGQCMWYYWLJYJHYYZLLJJYLHZYHMGSLJLJXCJJYCLYCJPCPZJZJMMYLCQLNQLJQJSXYJMLSZLJQLYCMMHCFMMFPQQMFYLQMCFFQMMMMHMZNFHHJGTTHHKHSLNCHHYQDXTMMQDCYZYXYQMYQYLTDCYYYZAZZCYMZYDLZFFFMMYCQZWZZMABTBYZTDMNZZGGDFTYPCGQYTTSSFFWFDTZQSSYSTWXJHXYTSXXYLBYQHWWKXHZXWZNNZZJZJJQJCCCHYYXBZXZCYZTLLCQXYNJYCYYCYNZZQYYYEWYCZDCJYCCHYJLBTZYYCQWMPWPYMLGKDLDLGKQQBGYCHJXY".charAt(n-19968)))}return function(e,t){for(var i=t.ignoreMulti,n=t.splitChar,r=[""],a=0,o=0,s=e.length;o<s;o++){var l=e[o],u=l.length;if(1==u||14<a||i)for(var c=l.substring(0,1),h=0;h<r.length;h++)r[h]+=c;else{var p=r.slice(0),r=[];for(a++,h=0;h<u;h++){for(var d=p.slice(0),f=0;f<d.length;f++)d[f]+=l.charAt(h);r=r.concat(d)}}}return r.join(n||"").toLowerCase()}(r,t)}})},function(e,t){var o;o={},_.extend(BI,{addI18n:function(e){BI.extend(o,e)},i18nText:function(e){a=(a=o[e]||BI.i18n&&BI.i18n[e]||"")||e;var t=arguments.length;if(1<t){if(!(-1<a.indexOf("{R1}"))){var i=Array.prototype.slice.call(arguments),n=1;return BI.replaceAll(a,"\\{\\s*\\}",function(){return i[n++]+""})}for(var r=1;r<t;r++)var e="{R"+r+"}",a=BI.replaceAll(a,e,arguments[r]+"")}return a}})},function(e,t){var i;i={},BI.BufferPool={put:function(e,t){if(BI.isNotNull(i[e]))throw new Error("Buffer Pool has the key already!");i[e]=t},get:function(e){return i[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,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){var n=i(88);e.exports=!n(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t){var i={}.hasOwnProperty;e.exports=function(e,t){return i.call(e,t)}},function(e,t,i){var n=i(173),r=i(282),a=i(1122);e.exports=n?function(e,t,i){return r.f(e,t,a(1,i))}:function(e,t,i){return e[t]=i,e}},function(e,t,i){var n=i(173),r=i(1158),a=i(90),o=i(1146),s=Object.defineProperty;t.f=n?s:function(e,t,i){if(a(e),t=o(t,!0),a(i),r)try{return s(e,t,i)}catch(n){}if("get"in i||"set"in i)throw TypeError("Accessors not supported");return"value"in i&&(e[t]=i.value),e}},function(e,t){!function(){function s(i,e){var t=[],n=i[e];n&&(t=t.concat(BI.isArray(n)?n:[n])),(n=i.options[e])&&(t=t.concat(BI.isArray(n)?n:[n])),BI.each(t,function(e,t){t.call(i)})}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,tag:null,disabled:!1,invisible:!1,invalid:!1,baseCls:"",extraCls:"",cls:"",css:null,updateMode:"manual"})},_constructor:function(){},_constructed:function(){this.setup&&(function(e){r&&n.push(r);BI.Widget.current=r=e}(this),this.service=this.setup(this.options),this.render=BI.isPlainObject(this.service)?this.service.render:this.service,BI.Widget.current=r=n.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,s(this,"beforeCreate"),this._initElement(),this._initEffects(),s(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||"")),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,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 i=this,e=this._isMounted;!0===this.__async&&e&&s(this,"beforeMount");var t=BI.isFunction(this.options.render)?this.options.render:this.render,n=t&&t.call(this);BI.isPlainObject(n)&&(n=[n]),BI.isArray(n)&&BI.each(n,function(e,t){t&&BI._lazyCreateWidget(t,{element:i})}),this._mount(),!0===this.__async&&e&&(s(this,"mounted"),this.fireEvent(BI.Events.MOUNT))},_setParent:function(e){this._parent=e},_mount:function(e,t,i,n,r){if(!e&&(this._isMounted||!this.isVisible()||!0===this.__asking||!(!0===this._isRoot||this._parent&&!0===this._parent._isMounted)))return!1;for(var a in r=r||0,!1===i||this.__async||s(this,"beforeMount"),this._isMounted=!0,this._children){var o=this._children[a];this.isEnabled()||o._setEnable(!1),this.isValid()||o._setValid(!1),o._mount&&o._mount(!!t&&e,t,i,n,r+1)}return this._mountChildren&&this._mountChildren(),0===r&&this.__afterMount(i,n),!0},__afterMount:function(e,t){if(this._isMounted){for(var i in this._children){var n=this._children[i];n.__afterMount&&n.__afterMount(e,t)}!1===e||this.__async||(s(this,"mounted"),this.fireEvent(BI.Events.MOUNT)),t&&t(this)}},_mountChildren:null,_update:function(e,t){var i,n,r=this.options;return s(this,"beforeUpdate"),t?n=this.update&&this.update(e,t):BI.isNull(t)&&(i={},BI.each(e,function(e,t){r[e]!==t&&(i[e]=t)}),n=this.update&&BI.isNotEmptyObject(i)&&this.update(i)),s(this,"updated"),n},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(i){!0===i?this.options.disabled=!1:!1===i&&(this.options.disabled=!0),BI.each(this._children,function(e,t){!t._manualSetEnable&&t._setEnable&&t._setEnable(i)})},_setValid:function(i){!0===i?this.options.invalid=!1:!1===i&&(this.options.invalid=!0),BI.each(this._children,function(e,t){!t._manualSetValid&&t._setValid&&t._setValid(i)})},_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 i=arguments;BI.each(this._children,function(e,t){t.doBehavior&&t.doBehavior.apply(t,i)})},getWidth:function(){return this.options.width},getHeight:function(){return this.options.height},isValid:function(){return!this.options.invalid},addWidget:function(e,t){var i=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(i._children,this)}),this._children[e]=t},getWidgetByName:function(i){if(!BI.isKey(i)||i===this.getName())return this;i+="";var n=void 0,r={};return BI.any(this._children,function(e,t){return e===i?(n=t,!0):void(r[e]=t)}),n||BI.any(r,function(e,t){return n=t.getWidgetByName(e)}),n},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 i=this;if(!BI.isPlainObject(e))return BI.isNotNull(t)?this.options[e]=t:this.options[e];BI.each(e,function(e,t){i.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(){s(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,s(this,"destroyed"),this.destroyed=null},_unMount:function(){this.__d(),this.fireEvent(BI.Events.UNMOUNT),this.purgeListeners()},isolate:function(){this._parent&&this._parent.removeWidget(this),BI.DOM.hang([this])},empty:function(){BI.each(this._children,function(e,t){t&&t._unMount&&t._unMount()}),this._children={},this.element.empty()},reset:function(){!0!==this.__async&&!0!==this.__asking&&(this.empty(),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,r=null,i=[],n=[];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(t){if(r&&r.store)return r.store;if(r&&r.$storeDelegate)return r.$storeDelegate;if(r){var n,i={};if(_global.Proxy){var e=new Proxy(i,{get:function(e,t){return Reflect.get(n,t)},set:function(e,t,i){return Reflect.set(n,t,i)}});return r._store=function(){return n=t.apply(this,arguments)},r.$storeDelegate=e}return r._store=function(){var e=t.apply(this,arguments);return BI.extend(i,e),e},r.$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){r&&(r.beforeMount?BI.isArray(r.beforeMount)||(r.beforeMount=[r.beforeMount]):r.beforeMount=[],r.beforeMount.push(e))},BI.onMounted=function(e){r&&(r.mounted?BI.isArray(r.mounted)||(r.mounted=[r.mounted]):r.mounted=[],r.mounted.push(e))},BI.onBeforeUnmount=function(e){r&&(r.beforeDestroy?BI.isArray(r.beforeDestroy)||(r.beforeDestroy=[r.beforeDestroy]):r.beforeDestroy=[],r.beforeDestroy.push(e))},BI.onUnmounted=function(e){r&&(r.destroyed?BI.isArray(r.destroyed)||(r.destroyed=[r.destroyed]):r.destroyed=[],r.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,i,n){if(!0!==n)return t&&BI.Widget._renderEngine.createElement(t).append(e.element),e._mount(!0,!1,!1,i);e.element.data("__widgets",[e]);var r=e._mount(!0,!1,!1,function(e){BI.each(e._children,function(e,t){var i=t.element.data("__widgets");(i=i||[]).push(t),t.element.data("__widgets",i)}),i&&i.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}}()},function(e,t){!function(){var o={};BI.shortcut=BI.component=BI.shortcut||function(e,t){null!=o[e]&&_global.console&&console.error("shortcut:["+e+"] has been registed"),t&&(t.xtype=e),o[e]=t};var s=function(e,t,i){var n=o[e.type];if(!n)throw new Error("组件"+e.type+"未定义");var r=!1,a=new n;return a._context=BI.Widget.context||t,!BI.Widget.context&&t&&(r=!0,BI.Widget.pushContext(t)),a._initProps(e),a._constructed(),a._initRoot(),a._lazyConstructor(),r&&BI.Widget.popContext(),a};BI.createWidget=BI.createWidget||function(e,t,i,n){var r,a;if(BI.init(),e=e||{},t=BI.isWidget(t)?(i=t,{}):t||{},BI.isEmpty(e)&&BI.isEmpty(t))return BI.createWidget({type:"bi.layout"});if(BI.isWidget(e))return e;if(e.type||t.type)return r=BI.extend({},t,e),(a=BI.Plugin.getWidget(r.type,r)).type===r.type?(BI.Plugin.hasObject(r.type)&&(a.listeners=(a.listeners||[]).concat([{eventName:BI.Events.MOUNT,action:function(){BI.Plugin.getObject(r.type,this)}}])),s(a,i)):BI.createWidget(a,t,i,n);if(e.el&&(e.el.type||t.type))return r=BI.extend({},t,e.el),(a=BI.Plugin.getWidget(r.type,r)).type===r.type?(BI.Plugin.hasObject(r.type)&&(a.listeners=(a.listeners||[]).concat([{eventName:BI.Events.MOUNT,action:function(){BI.Plugin.getObject(r.type,this)}}])),s(a,i)):BI.createWidget(a,t,i,n);if(BI.isWidget(e.el))return e.el;throw new Error("无法根据item创建组件")},BI._lazyCreateWidget=BI._lazyCreateWidget||function(e,t,i){return BI.createWidget(e,t,i,!0)},BI.createElement=BI.createElement||function(){return BI.createWidget.apply(this,arguments).element}}()},function(e,t){var a,o,s,l,u;BI.Plugin=BI.Plugin||{},a={},o={},s={},l=[],u=[],BI.defaults(BI.Plugin,{getWidget:function(e,t){if(0<l.length)for(var i=l.slice(0),n=i.length-1;0<=n;n--)i[n](e,t);var r;if(s[e])for(n=s[e].length-1;0<=n;n--)(r=s[e][n](t))&&(t=r);if(a[e])for(n=a[e].length-1;0<=n;n--)if(r=a[e][n](t))return r;return t},config:function(e,t){l=l.concat(_.isArray(e)?e:[e]),u=u.concat(_.isArray(t)?t:[t])},configWidget:function(e,t,i){(!s[e]||i&&i.single)&&(s[e]=[]),s[e].push(t)},registerWidget:function(e,t){a[e]||(a[e]=[]),0<a[e].length&&console.log("组件已经注册过了!"),a[e].push(t)},relieveWidget:function(e){delete a[e]},getObject:function(e,t){if(0<u.length)for(var i=u.slice(0),n=i.length-1;0<=n;n--)i[n](e,t);if(o[e])for(var r,n=0,a=o[e].length;n<a;n++)(r=o[e][n](t))&&(t=r);return r||t},hasObject:function(e){return 0<u.length||!!o[e]},registerObject:function(e,t){o[e]||(o[e]=[]),0<o[e].length&&console.log("对象已经注册过了!"),o[e].push(t)},relieveObject:function(e){delete o[e]}})},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,i){},actionBack:function(e,t,i){}}),BI.ActionFactory={createAction:function(e,t){var i;switch(e){case"show":i=BI.ShowAction}return new i(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,i){(t=t||this.options.tar).setVisible(!0),i&&i()},actionBack:function(e,t,i){(e=e||this.options.tar).setVisible(!1),i&&i()}})},function(e,t){BI.BehaviorFactory={createBehavior:function(e,t){var i;switch(e){case"highlight":i=BI.HighlightBehavior;break;case"redmark":i=BI.RedMarkBehavior}return new i(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 r=Array.prototype.slice.call(arguments,1),a=this.options;BI.each(e,function(e,t){function i(e){!0===e?t.doHighLight&&t.doHighLight.apply(t,r):t.unHighLight&&t.unHighLight.apply(t,r)}var n;t instanceof BI.Single?(n=a.rule(t.getValue(),t),BI.isFunction(n)?n(i):i(n)):t.doBehavior&&t.doBehavior.apply(t,r)})}})},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 i=Array.prototype.slice.call(arguments,1),n=this.options;BI.each(e,function(e,t){t instanceof BI.Single?n.rule(t.getValue(),t)?t.doRedMark&&t.doRedMark.apply(t,i):t.doRedMark&&t.unRedMark.apply(t,i):t.doBehavior&&t.doBehavior.apply(t,i)})}})},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 i=this;return this._broadcasts[e]||(this._broadcasts[e]=[]),this._broadcasts[e].push(t),function(){i.remove(e,t)}},send:function(e){var i=[].slice.call(arguments,1);BI.each(this._broadcasts[e],function(e,t){t.apply(null,i)})},remove:function(t,i){var n=this;return i?(BI.remove(this._broadcasts[t],function(e){return n._broadcasts[t].indexOf(i)===e}),this._broadcasts[t].remove(i),0===this._broadcasts[t].length&&delete this._broadcasts[t]):delete this._broadcasts[t],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 t=this;this.fixedBubblesManager={},this.fixedStoreBubbles={},this.bubblesManager={},this.storeBubbles={},BI.Resizers.add("bubbleController"+BI.uniqueId(),function(){BI.each(t.fixedBubblesManager,function(e){t.remove(e)}),t.fixedBubblesManager={},t.fixedStoreBubbles={}})},_createBubble:function(e,t,i,n,r){return BI.createWidget({type:!1===r?"bi.bubble_view":"bi.bubble",text:t,level:i,height:n||18,direction:e})},_getOffsetLeft:function(e,t,i){var n=0;return"center"===i?((n=t.element.offset().left+(t.element.bounds().width-this.get(e).element.bounds().width)/2)<0&&(n=0),n):"right"===i?((n=t.element.offset().left+t.element.bounds().width-this.get(e).element.bounds().width)<0&&(n=0),n):t.element.offset().left},_getOffsetTop:function(e,t,i){var n=0;return"center"===i?((n=t.element.offset().top+(t.element.bounds().height-this.get(e).element.bounds().height)/2)<0&&(n=0),n):"right"===i?((n=t.element.offset().top+t.element.bounds().height-this.get(e).element.bounds().height)<0&&(n=0),n):t.element.offset().top},_getLeftPosition:function(e,t,i){var n=BI.DOM.getLeftPosition(t,this.get(e));return n.top=this._getOffsetTop(e,t,i),n},_getBottomPosition:function(e,t,i){var n=BI.DOM.getBottomPosition(t,this.get(e));return n.left=this._getOffsetLeft(e,t,i),n},_getTopPosition:function(e,t,i){var n=BI.DOM.getTopPosition(t,this.get(e));return n.left=this._getOffsetLeft(e,t,i),n},_getRightPosition:function(e,t,i){var n=BI.DOM.getRightPosition(t,this.get(e));return n.top=this._getOffsetTop(e,t,i),n},show:function(e,t,i,n){var r=(n=n||{}).container||i,a=n.offsetStyle||"left",o=n.level||"error",s=n.adjustYOffset||0,l=n.adjustXOffset||0,u=!1!==n.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(i,this.get(e),s)){var p=-(h.height+s);switch(a){case"center":c.element.css({left:(i.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:(i.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,i,a);this.get(e).element.css({left:f.left+l,top:f.top-s}),BI.DOM.isTopSpaceEnough(i,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,i,a),this.get(e).element.css({left:f.left+l,top:f.top+s}),BI.DOM.isBottomSpaceEnough(i,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,i,a),this.get(e).element.css({left:f.left+l,top:f.top-s}),BI.DOM.isRightSpaceEnough(i,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,i,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},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,i){!1===i?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}})},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,i,n){return BI.isWidget(t)?(i=i||{}).container=t:(n=i,i=t),this.create(e,null,i,n)},create:function(e,t,i,n){if(this.has(e))return this.get(e);var r=(i=i||{}).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(i.render||{},BI.extend({type:"bi.layout"},i),n),s=BI.createWidget({type:"bi.absolute",invisible:!0,items:[{el:o,left:0,right:0,top:0,bottom:0}]},n);return BI.createWidget({type:"bi.absolute",element:i.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},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},isVisible:function(e){return this.has(e)&&this._getLayout(e).isVisible()},add:function(e,t,i){if(this.has(e))throw new Error("name is already exist");return i.setVisible(!1),this.layerManager[e]=t,(this.layouts[e]=i).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},removeAll:function(){var i=this;return BI.each(BI.keys(this.layerManager),function(e,t){i.layerManager[t].destroy(),i.layouts[t].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,i){if(this._check(e))return this;var n=BI.createWidget(t||{},{type:"bi.popover"},i);return this.add(e,n,t,i),this},add:function(e,t,i,n){var r,a=this;return i=i||{},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]},n),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:i.container||this.options.render,items:[{el:this.floatContainer[e],left:0,right:0,top:0,bottom:0}]})),this},open:function(e){return this._check(e)&&(this.floatOpened[e]||(this.floatOpened[e]=!0,(t=this.floatContainer[e]).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(),(i=this.get(e)).show&&i.show(),n=BI.Widget._renderEngine.createElement(this.options.render).width(),r=BI.Widget._renderEngine.createElement(this.options.render).height(),(a=(n-i.element.width())/2)<0&&(a=0),(o=(r-i.element.height())/2)<0&&(o=0),i.element.css({left:a/BI.pixRatio+BI.pixUnit,top:o/BI.pixRatio+BI.pixUnit}))),this;var t,i,n,r,a,o},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},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},removeAll:function(){var i=this;return BI.each(this.floatContainer,function(e,t){t.destroy(),i.modal&&i.floatContainer[e].element.__releaseZIndexMask__(i.zindexMap[e])}),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 t=this;this.resizerManger={};var e=BI.debounce(function(e){t._resize(e)},30);"onorientationchange"in _global?_global.onorientationchange=e:BI.Widget._renderEngine.createElement(_global).resize(e)},_resize:function(i){BI.each(this.resizerManger,function(e,t){t instanceof BI.$?t.is(":visible")&&t.trigger("__resize__"):t instanceof BI.Layout?t.resize():BI.isFunction(t)&&t(i)})},add:function(e,t){var i=this;return this.has(e)?this:(this.resizerManger[e]=t,function(){i.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}})},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},create:function(e,t,i,n){var r;return this.has(e)||(r=this._createTooltip(t,i),this.add(e,r),BI.createWidget({type:"bi.absolute",element:n||"body",items:[{el:r}]}),r.invisible()),this.get(e)},show:function(e,t,i,n,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,i,n,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(i),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}})},function(e,t){BI.Fragment=function(){},BI.h=function(e,t,i){if(null!=i?BI.isArray(i)||(i=[i]):i=[],3<arguments.length)for(var n=3;n<arguments.length;n++)BI.isArray(arguments[n])?i=i.concat(arguments[n]):i.push(arguments[n]);return e===BI.Fragment?i:(BI.isFunction(e)&&(e=e.xtype||e),"el"===e?BI.extend({el:i[0]},t):BI.extend({type:e},0<i.length?{items:i}:{},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 a=this,o=this.options;o.eventObj&&o.eventObj.on(BI.Controller.EVENT_CHANGE,function(e,t,i){if(e===BI.Events.CLICK){if(t=t||o.eventObj.getValue(),t=BI.isArray(t)?1<t.length?t.toString():t[0]:t,BI.isNull(t))throw new Error("value cannot be null");var n,r=o.cardNameCreator(t);o.cardLayout.isCardExisted(r)||(n=o.cardCreator(r),o.cardLayout.addCardByName(r,n),o.afterCardCreated(r)),o.cardLayout.showCardByName(r),BI.nextTick(function(){o.afterCardShow(r),a.fireEvent(BI.ShowListener.EVENT_CHANGE,r)})}})}}),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 i=document,n=i.createElement("style");return i.getElementsByTagName("head")[0].appendChild(n),n.setAttribute("type","text/css"),n.styleSheet?n.styleSheet.cssText=t:n.appendChild(document.createTextNode(t)),this.stylesManager[e]=n,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}})},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 i;switch(e){case BI.LogicFactory.Type.Vertical:i=BI.VerticalLayoutLogic;break;case BI.LogicFactory.Type.Horizontal:i=BI.HorizontalLayoutLogic;break;case BI.LogicFactory.Type.Table:i=BI.TableLayoutLogic;break;case BI.LogicFactory.Type.HorizontalFill:i=BI.HorizontalFillLayoutLogic;break;default:i=BI.Logic}return new i(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),t=BI.map(t,function(e,t){return BI.isWidget(t)?{el:t,width:t.options.width,height:t.options.height}:t});switch(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,t=e.dynamic?"bi.vertical":"bi.vtape";return{type: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}}}),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,t=e.dynamic?"bi.vertical_adapt":"bi.htape";return{type: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}}}),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,t=e.dynamic?"bi.table":"bi.window";return{type:t,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,i=[];return BI.each(e.items,function(e,t){i.push(t.width||0)}),{type:e.dynamic?"bi.horizontal_adapt":"bi.htape",columnSize:i,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){function u(e,t){for(var i=-1;++i<r;)t+=e*a[i],a[i]=t%n,t=Math.floor(t/n)}function c(e){for(var t=r,i=0;0<=--t;)i+=a[t],a[t]=Math.floor(i/e),i=i%e*n}function h(){for(var e,t=r,i="";0<=--t;){""===i&&0!==t&&0===a[t]||(e=String(a[t]),""===i?i=e:i+="0000000".slice(0,7-e.length)+e)}return i}function p(e,t,i){return 0===t?i:t%2==1?p(e,t-1,i*e):p(e*e,t/2,i)}var n,r,a;Number.prototype.toFixed&&"0.000"===8e-5.toFixed(3)&&"0"!==.9.toFixed(0)&&"1.25"===1.255.toFixed(2)&&"1000000000000000128"===(0xde0b6b3a7640080).toFixed(0)||(n=1e7,r=6,a=[0,0,0,0,0,0],Number.prototype.toFixed=function(e){var t,i,n,r,a,o,s,l=Number(e);if((l=l!=l?0:Math.floor(l))<0||20<l)throw new RangeError("Number.toFixed called with invalid number of decimals");if((t=Number(this))!=t)return"NaN";if(t<=-1e21||1e21<t)return String(t);if(i="",t<0&&(i="-",t=-t),n="0",1e-21<t)if(a=(r=function(e){for(var t=0;4096<=e;)t+=12,e/=4096;for(;2<=e;)t+=1,e/=2;return t}(t*p(2,69,1))-69)<0?t*p(2,-r,1):t/p(2,r,1),a*=4503599627370496,0<(r=52-r)){for(u(0,a),o=l;7<=o;)u(1e7,0),o-=7;for(u(p(10,o,1),0),o=r-1;23<=o;)c(1<<23),o-=23;c(1<<o),u(1,1),c(2),n=h()}else u(0,a),u(1<<-r,0),n=h()+"0.00000000000000000000".slice(2,2+l);return n=0<l?(s=n.length)<=l?i+"0.0000000000000000000".slice(0,l-s+2)+n:i+n.slice(0,s-l)+"."+n.slice(s-l):i+n})},function(e,t){!function(){BI.CRYPT_TYPE=BI.CRYPT_TYPE||{},BI.CRYPT_TYPE.AES="aes";var c,e,t,i,h,n,r,a,o,s,l,p,u,d,f,g,m,I,B,E,b=b||(c=Math,t=(e={}).lib={},i=t.Base={extend:function(e){y.prototype=this;var t=new y;return e&&t.mixIn(e),t.hasOwnProperty("init")||(t.init=function(){t.$super.init.apply(this,arguments)}),(t.init.prototype=t).$super=this,t},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)}},h=t.WordArray=i.extend({init:function(e,t){e=this.words=e||[],this.sigBytes=null!=t?t:4*e.length},toString:function(e){return(e||r).stringify(this)},concat:function(e){var t=this.words,i=e.words,n=this.sigBytes,r=e.sigBytes;if(this.clamp(),n%4)for(var a=0;a<r;a++){var o=i[a>>>2]>>>24-a%4*8&255;t[n+a>>>2]|=o<<24-(n+a)%4*8}else if(65535<i.length)for(a=0;a<r;a+=4)t[n+a>>>2]=i[a>>>2];else t.push.apply(t,i);return this.sigBytes+=r,this},clamp:function(){var e=this.words,t=this.sigBytes;e[t>>>2]&=4294967295<<32-t%4*8,e.length=c.ceil(t/4)},clone:function(){var e=i.clone.call(this);return e.words=this.words.slice(0),e},random:function(e){for(var t=[],i=0;i<e;i+=4)t.push(4294967296*c.random()|0);return new h.init(t,e)}}),n=e.enc={},r=n.Hex={stringify:function(e){for(var t=e.words,i=e.sigBytes,n=[],r=0;r<i;r++){var a=t[r>>>2]>>>24-r%4*8&255;n.push((a>>>4).toString(16)),n.push((15&a).toString(16))}return n.join("")},parse:function(e){for(var t=e.length,i=[],n=0;n<t;n+=2)i[n>>>3]|=parseInt(e.substr(n,2),16)<<24-n%8*4;return new h.init(i,t/2)}},a=n.Latin1={stringify:function(e){for(var t=e.words,i=e.sigBytes,n=[],r=0;r<i;r++){var a=t[r>>>2]>>>24-r%4*8&255;n.push(String.fromCharCode(a))}return n.join("")},parse:function(e){for(var t=e.length,i=[],n=0;n<t;n++)i[n>>>2]|=(255&e.charCodeAt(n))<<24-n%4*8;return new h.init(i,t)}},o=n.Utf8={stringify:function(e){try{return decodeURIComponent(escape(a.stringify(e)))}catch(t){throw new Error("Malformed UTF-8 data")}},parse:function(e){return a.parse(unescape(encodeURIComponent(e)))}},s=t.BufferedBlockAlgorithm=i.extend({reset:function(){this._data=new h.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=o.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(e){var t=this._data,i=t.words,n=t.sigBytes,r=this.blockSize,a=n/(4*r),o=(a=e?c.ceil(a):c.max((0|a)-this._minBufferSize,0))*r,s=c.min(4*o,n);if(o){for(var l=0;l<o;l+=r)this._doProcessBlock(i,l);var u=i.splice(0,o);t.sigBytes-=s}return new h.init(u,s)},clone:function(){var e=i.clone.call(this);return e._data=this._data.clone(),e},_minBufferSize:0}),t.Hasher=s.extend({cfg:i.extend(),init:function(e){this.cfg=this.cfg.extend(e),this.reset()},reset:function(){s.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(i){return function(e,t){return new i.init(t).finalize(e)}},_createHmacHelper:function(i){return function(e,t){return new l.HMAC.init(i,t).finalize(e)}}}),l=e.algo={},e);function y(){}p=b.lib.WordArray,b.enc.Base64={stringify:function(e){var t=e.words,i=e.sigBytes,n=this._map;e.clamp();for(var r=[],a=0;a<i;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<i;s++)r.push(n.charAt(o>>>6*(3-s)&63));var l=n.charAt(64);if(l)for(;r.length%4;)r.push(l);return r.join("")},parse:function(e){var t,i=e.length,n=this._map,r=n.charAt(64);!r||-1!=(t=e.indexOf(r))&&(i=t);for(var a,o,s=[],l=0,u=0;u<i;u++){u%4&&(a=n.indexOf(e.charAt(u-1))<<u%4*2,o=n.indexOf(e.charAt(u))>>>6-u%4*2,s[l>>>2]|=(a|o)<<24-l%4*8,l++)}return p.create(s,l)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="},function(c){var e=b,t=e.lib,i=t.WordArray,n=t.Hasher,r=e.algo,N=[];!function(){for(var e=0;e<64;e++)N[e]=4294967296*c.abs(c.sin(e+1))|0}();var a=r.MD5=n.extend({_doReset:function(){this._hash=new i.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(e,t){for(var i=0;i<16;i++){var n=t+i,r=e[n];e[n]=16711935&(r<<8|r>>>24)|4278255360&(r<<24|r>>>8)}var a=this._hash.words,o=e[t+0],s=e[t+1],l=e[t+2],u=e[t+3],c=e[t+4],h=e[t+5],p=e[t+6],d=e[t+7],f=e[t+8],g=e[t+9],m=e[t+10],I=e[t+11],B=e[t+12],E=e[t+13],_=e[t+14],b=e[t+15],y=V(y=a[0],C=a[1],T=a[2],v=a[3],o,7,N[0]),v=V(v,y,C,T,s,12,N[1]),T=V(T,v,y,C,l,17,N[2]),C=V(C,T,v,y,u,22,N[3]);y=V(y,C,T,v,c,7,N[4]),v=V(v,y,C,T,h,12,N[5]),T=V(T,v,y,C,p,17,N[6]),C=V(C,T,v,y,d,22,N[7]),y=V(y,C,T,v,f,7,N[8]),v=V(v,y,C,T,g,12,N[9]),T=V(T,v,y,C,m,17,N[10]),C=V(C,T,v,y,I,22,N[11]),y=V(y,C,T,v,B,7,N[12]),v=V(v,y,C,T,E,12,N[13]),T=V(T,v,y,C,_,17,N[14]),y=S(y,C=V(C,T,v,y,b,22,N[15]),T,v,s,5,N[16]),v=S(v,y,C,T,p,9,N[17]),T=S(T,v,y,C,I,14,N[18]),C=S(C,T,v,y,o,20,N[19]),y=S(y,C,T,v,h,5,N[20]),v=S(v,y,C,T,m,9,N[21]),T=S(T,v,y,C,b,14,N[22]),C=S(C,T,v,y,c,20,N[23]),y=S(y,C,T,v,g,5,N[24]),v=S(v,y,C,T,_,9,N[25]),T=S(T,v,y,C,u,14,N[26]),C=S(C,T,v,y,f,20,N[27]),y=S(y,C,T,v,E,5,N[28]),v=S(v,y,C,T,l,9,N[29]),T=S(T,v,y,C,d,14,N[30]),y=x(y,C=S(C,T,v,y,B,20,N[31]),T,v,h,4,N[32]),v=x(v,y,C,T,f,11,N[33]),T=x(T,v,y,C,I,16,N[34]),C=x(C,T,v,y,_,23,N[35]),y=x(y,C,T,v,s,4,N[36]),v=x(v,y,C,T,c,11,N[37]),T=x(T,v,y,C,d,16,N[38]),C=x(C,T,v,y,m,23,N[39]),y=x(y,C,T,v,E,4,N[40]),v=x(v,y,C,T,o,11,N[41]),T=x(T,v,y,C,u,16,N[42]),C=x(C,T,v,y,p,23,N[43]),y=x(y,C,T,v,g,4,N[44]),v=x(v,y,C,T,B,11,N[45]),T=x(T,v,y,C,b,16,N[46]),y=w(y,C=x(C,T,v,y,l,23,N[47]),T,v,o,6,N[48]),v=w(v,y,C,T,d,10,N[49]),T=w(T,v,y,C,_,15,N[50]),C=w(C,T,v,y,h,21,N[51]),y=w(y,C,T,v,B,6,N[52]),v=w(v,y,C,T,u,10,N[53]),T=w(T,v,y,C,m,15,N[54]),C=w(C,T,v,y,s,21,N[55]),y=w(y,C,T,v,f,6,N[56]),v=w(v,y,C,T,b,10,N[57]),T=w(T,v,y,C,p,15,N[58]),C=w(C,T,v,y,E,21,N[59]),y=w(y,C,T,v,c,6,N[60]),v=w(v,y,C,T,I,10,N[61]),T=w(T,v,y,C,l,15,N[62]),C=w(C,T,v,y,g,21,N[63]),a[0]=a[0]+y|0,a[1]=a[1]+C|0,a[2]=a[2]+T|0,a[3]=a[3]+v|0},_doFinalize:function(){var e=this._data,t=e.words,i=8*this._nDataBytes,n=8*e.sigBytes;t[n>>>5]|=128<<24-n%32;var r=c.floor(i/4294967296),a=i;t[15+(64+n>>>9<<4)]=16711935&(r<<8|r>>>24)|4278255360&(r<<24|r>>>8),t[14+(64+n>>>9<<4)]=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),e.sigBytes=4*(t.length+1),this._process();for(var o=this._hash,s=o.words,l=0;l<4;l++){var u=s[l];s[l]=16711935&(u<<8|u>>>24)|4278255360&(u<<24|u>>>8)}return o},clone:function(){var e=n.clone.call(this);return e._hash=this._hash.clone(),e}});function V(e,t,i,n,r,a,o){var s=e+(t&i|~t&n)+r+o;return(s<<a|s>>>32-a)+t}function S(e,t,i,n,r,a,o){var s=e+(t&n|i&~n)+r+o;return(s<<a|s>>>32-a)+t}function x(e,t,i,n,r,a,o){var s=e+(t^i^n)+r+o;return(s<<a|s>>>32-a)+t}function w(e,t,i,n,r,a,o){var s=e+(i^(t|~n))+r+o;return(s<<a|s>>>32-a)+t}e.MD5=n._createHelper(a),e.HmacMD5=n._createHmacHelper(a)}(Math),d=(u=b).lib,f=d.Base,g=d.WordArray,m=u.algo,I=m.MD5,B=m.EvpKDF=f.extend({cfg:f.extend({keySize:4,hasher:I,iterations:1}),init:function(e){this.cfg=this.cfg.extend(e)},compute:function(e,t){for(var i=this.cfg,n=i.hasher.create(),r=g.create(),a=r.words,o=i.keySize,s=i.iterations;a.length<o;){l&&n.update(l);var l=n.update(e).finalize(t);n.reset();for(var u=1;u<s;u++)l=n.finalize(l),n.reset();r.concat(l)}return r.sigBytes=4*o,r}}),u.EvpKDF=function(e,t,i){return B.create(i).compute(e,t)},b.lib.Cipher||function(){var e=b,t=e.lib,i=t.Base,l=t.WordArray,n=t.BufferedBlockAlgorithm,r=e.enc,a=(r.Utf8,r.Base64),o=e.algo.EvpKDF,s=t.Cipher=n.extend({cfg:i.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,i){this.cfg=this.cfg.extend(i),this._xformMode=e,this._key=t,this.reset()},reset:function(){n.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(n){return{encrypt:function(e,t,i){return u(t).encrypt(n,e,t,i)},decrypt:function(e,t,i){return u(t).decrypt(n,e,t,i)}}}});function u(e){return"string"==typeof e?_:B}t.StreamCipher=s.extend({_doFinalize:function(){return this._process(!0)},blockSize:1});var c,h=e.mode={},p=t.BlockCipherMode=i.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=((c=p.extend()).Encryptor=c.extend({processBlock:function(e,t){var i=this._cipher,n=i.blockSize;f.call(this,e,t,n),i.encryptBlock(e,t),this._prevBlock=e.slice(t,t+n)}}),c.Decryptor=c.extend({processBlock:function(e,t){var i=this._cipher,n=i.blockSize,r=e.slice(t,t+n);i.decryptBlock(e,t),f.call(this,e,t,n),this._prevBlock=r}}),c);function f(e,t,i){var n,r=this._iv;r?(n=r,this._iv=void 0):n=this._prevBlock;for(var a=0;a<i;a++)e[t+a]^=n[a]}var g=(e.pad={}).Pkcs7={pad:function(e,t){for(var i=4*t,n=i-e.sigBytes%i,r=n<<24|n<<16|n<<8|n,a=[],o=0;o<n;o+=4)a.push(r);var s=l.create(a,n);e.concat(s)},unpad:function(e){var t=255&e.words[e.sigBytes-1>>>2];e.sigBytes-=t}},m=(t.BlockCipher=s.extend({cfg:s.cfg.extend({mode:d,padding:g}),reset:function(){s.reset.call(this);var e,t=this.cfg,i=t.iv,n=t.mode;this._xformMode==this._ENC_XFORM_MODE?e=n.createEncryptor:(e=n.createDecryptor,this._minBufferSize=1),this._mode=e.call(n,this,i&&i.words)},_doProcessBlock:function(e,t){this._mode.processBlock(e,t)},_doFinalize:function(){var e,t=this.cfg.padding;return this._xformMode==this._ENC_XFORM_MODE?(t.pad(this._data,this.blockSize),e=this._process(!0)):(e=this._process(!0),t.unpad(e)),e},blockSize:4}),t.CipherParams=i.extend({init:function(e){this.mixIn(e)},toString:function(e){return(e||this.formatter).stringify(this)}})),I=(e.format={}).OpenSSL={stringify:function(e){var t=e.ciphertext,i=e.salt;return(i?l.create([1398893684,1701076831]).concat(i).concat(t):t).toString(a)},parse:function(e){var t,i=a.parse(e),n=i.words;return 1398893684==n[0]&&1701076831==n[1]&&(t=l.create(n.slice(2,4)),n.splice(0,4),i.sigBytes-=16),m.create({ciphertext:i,salt:t})}},B=t.SerializableCipher=i.extend({cfg:i.extend({format:I}),encrypt:function(e,t,i,n){n=this.cfg.extend(n);var r=e.createEncryptor(i,n),a=r.finalize(t),o=r.cfg;return m.create({ciphertext:a,key:i,iv:o.iv,algorithm:e,mode:o.mode,padding:o.padding,blockSize:e.blockSize,formatter:n.format})},decrypt:function(e,t,i,n){return n=this.cfg.extend(n),t=this._parse(t,n.format),e.createDecryptor(i,n).finalize(t.ciphertext)},_parse:function(e,t){return"string"==typeof e?t.parse(e,this):e}}),E=(e.kdf={}).OpenSSL={execute:function(e,t,i,n){n=n||l.random(8);var r=o.create({keySize:t+i}).compute(e,n),a=l.create(r.words.slice(t),4*i);return r.sigBytes=4*t,m.create({key:r,iv:a,salt:n})}},_=t.PasswordBasedCipher=B.extend({cfg:B.cfg.extend({kdf:E}),encrypt:function(e,t,i,n){var r=(n=this.cfg.extend(n)).kdf.execute(i,e.keySize,e.ivSize);n.iv=r.iv;var a=B.encrypt.call(this,e,t,r.key,n);return a.mixIn(r),a},decrypt:function(e,t,i,n){n=this.cfg.extend(n),t=this._parse(t,n.format);var r=n.kdf.execute(i,e.keySize,e.ivSize,t.salt);return n.iv=r.iv,B.decrypt.call(this,e,t,r.key,n)}})}(),b.mode.ECB=((E=b.lib.BlockCipherMode.extend()).Encryptor=E.extend({processBlock:function(e,t){this._cipher.encryptBlock(e,t)}}),E.Decryptor=E.extend({processBlock:function(e,t){this._cipher.decryptBlock(e,t)}}),E),function(){var e=b,t=e.lib.BlockCipher,i=e.algo,u=[],c=[],h=[],p=[],d=[],f=[],g=[],m=[],I=[],B=[];!function(){for(var e=[],t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;for(var i=0,n=0,t=0;t<256;t++){var r=(r=n^n<<1^n<<2^n<<3^n<<4)>>>8^255&r^99;u[i]=r;var a=e[c[r]=i],o=e[a],s=e[o],l=257*e[r]^16843008*r;h[i]=l<<24|l>>>8,p[i]=l<<16|l>>>16,d[i]=l<<8|l>>>24,f[i]=l;l=16843009*s^65537*o^257*a^16843008*i;g[r]=l<<24|l>>>8,m[r]=l<<16|l>>>16,I[r]=l<<8|l>>>24,B[r]=l,i?(i=a^e[e[e[s^a]]],n^=e[e[n]]):i=n=1}}();var E=[0,1,2,4,8,16,32,64,128,27,54],n=i.AES=t.extend({_doReset:function(){for(var e=this._key,t=e.words,i=e.sigBytes/4,n=4*(1+(this._nRounds=6+i)),r=this._keySchedule=[],a=0;a<n;a++){a<i?r[a]=t[a]:(l=r[a-1],a%i?6<i&&a%i==4&&(l=u[l>>>24]<<24|u[l>>>16&255]<<16|u[l>>>8&255]<<8|u[255&l]):(l=u[(l=l<<8|l>>>24)>>>24]<<24|u[l>>>16&255]<<16|u[l>>>8&255]<<8|u[255&l],l^=E[a/i|0]<<24),r[a]=r[a-i]^l)}for(var o=this._invKeySchedule=[],s=0;s<n;s++){var l,a=n-s;l=s%4?r[a]:r[a-4],o[s]=s<4||a<=4?l:g[u[l>>>24]]^m[u[l>>>16&255]]^I[u[l>>>8&255]]^B[u[255&l]]}},encryptBlock:function(e,t){this._doCryptBlock(e,t,this._keySchedule,h,p,d,f,u)},decryptBlock:function(e,t){var i=e[t+1];e[t+1]=e[t+3],e[t+3]=i,this._doCryptBlock(e,t,this._invKeySchedule,g,m,I,B,c);i=e[t+1];e[t+1]=e[t+3],e[t+3]=i},_doCryptBlock:function(e,t,i,n,r,a,o,s){for(var l=this._nRounds,u=e[t]^i[0],c=e[t+1]^i[1],h=e[t+2]^i[2],p=e[t+3]^i[3],d=4,f=1;f<l;f++)var g=n[u>>>24]^r[c>>>16&255]^a[h>>>8&255]^o[255&p]^i[d++],m=n[c>>>24]^r[h>>>16&255]^a[p>>>8&255]^o[255&u]^i[d++],I=n[h>>>24]^r[p>>>16&255]^a[u>>>8&255]^o[255&c]^i[d++],B=n[p>>>24]^r[u>>>16&255]^a[c>>>8&255]^o[255&h]^i[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])^i[d++],m=(s[c>>>24]<<24|s[h>>>16&255]<<16|s[p>>>8&255]<<8|s[255&u])^i[d++],I=(s[h>>>24]<<24|s[p>>>16&255]<<16|s[u>>>8&255]<<8|s[255&c])^i[d++],B=(s[p>>>24]<<24|s[u>>>16&255]<<16|s[c>>>8&255]<<8|s[255&h])^i[d++];e[t]=g,e[t+1]=m,e[t+2]=I,e[t+3]=B},keySize:8});e.AES=t._createHelper(n)}(),_.extend(BI,{aesEncrypt:function(e,t){return t=b.enc.Utf8.parse(t),b.AES.encrypt(e,t,{mode:b.mode.ECB,padding:b.pad.Pkcs7}).ciphertext.toString(b.enc.Base64)},aesDecrypt:function(e,t){t=b.enc.Utf8.parse(t);var i=b.AES.decrypt(e,t,{mode:b.mode.ECB,padding:b.pad.Pkcs7});return b.enc.Utf8.stringify(i)}})}()},function(e,t){function i(o){return function(e,t,i){var l,n=e[t];n&&n.target==e||((l=e[t]=function(){for(var e,t=l.before,i=arguments,n=t.length;n--;){if(!1===(e=t[n].advice.apply(this,i)))return!1;i=e||i}for(var r=l.method.apply(this,i),a=l.after,o=0,s=a.length;o<s;o++){if(e=a[o].advice.call(this,r,i),!1===r)return!1;i=e||i}return r}).before=[],l.after=[],n&&(l.method=n),l.target=e);var r=(l||n)[o],a={advice:i,_index:r.length,remove:function(){r.splice(this._index,1)}};return r.push(a),a}}BI.aspect={before:i("before"),after:i("after")},BI.aspect},function(e,t){var c;c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_.extend(BI,{encode:function(e){var t,i,n,r,a,o,s,l="",u=0;for(e=function(e){e=e.replace(/\r\n/g,"\n");for(var t="",i=0;i<e.length;i++){var n=e.charCodeAt(i);n<128?t+=String.fromCharCode(n):(127<n&&n<2048?t+=String.fromCharCode(n>>6|192):(t+=String.fromCharCode(n>>12|224),t+=String.fromCharCode(n>>6&63|128)),t+=String.fromCharCode(63&n|128))}return t}(e);u<e.length;)r=(t=e.charCodeAt(u++))>>2,a=(3&t)<<4|(i=e.charCodeAt(u++))>>4,o=(15&i)<<2|(n=e.charCodeAt(u++))>>6,s=63&n,isNaN(i)?o=s=64:isNaN(n)&&(s=64),l=l+c.charAt(r)+c.charAt(a)+c.charAt(o)+c.charAt(s);return l},decode:function(e){var t,i,n,r,a,o,s="",l=0;for(e=e.replace(/[^A-Za-z0-9\+\/\=]/g,"");l<e.length;)t=c.indexOf(e.charAt(l++))<<2|(r=c.indexOf(e.charAt(l++)))>>4,i=(15&r)<<4|(a=c.indexOf(e.charAt(l++)))>>2,n=(3&a)<<6|(o=c.indexOf(e.charAt(l++))),s+=String.fromCharCode(t),64!=a&&(s+=String.fromCharCode(i)),64!=o&&(s+=String.fromCharCode(n));return s=function(e){for(var t,i,n="",r=0,a=0;r<e.length;)(t=e.charCodeAt(r))<128?(n+=String.fromCharCode(t),r++):191<t&&t<224?(a=e.charCodeAt(r+1),n+=String.fromCharCode((31&t)<<6|63&a),r+=2):(a=e.charCodeAt(r+1),i=e.charCodeAt(r+2),n+=String.fromCharCode((15&t)<<12|(63&a)<<6|63&i),r+=3);return n}(s)}})},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;0<=e;e--){var t=localStorage.key(e);t&&0===t.indexOf(BI.Cache._getKeyPrefix())&&localStorage.removeItem(t)}},keys:function(){for(var e=[],t=localStorage.length;0<=t;t--){var i,n=localStorage.key(t);n&&(i=BI.Cache._getKeyPrefix(),0===n.indexOf(i)&&(e[e.length]=n.substring(i.length)))}return e},addCookie:function(e,t,i,n){var r,a=e+"="+escape(t);n&&0<n&&((r=new Date).setTime(r.getTime()+3600*n*1e3),a=a+"; expires="+r.toUTCString()),i&&(a=a+"; path="+i),document.cookie=a},getCookie:function(e){var t,i=new RegExp("(^| )"+e+"=([^;]*)(;|$)");return(t=document.cookie.match(i))?unescape(t[2]):null},deleteCookie:function(e,t){var i=new Date;i.setTime(i.getTime()-1e4);var n=e+"=v; expires="+i.toUTCString();t&&(n=n+"; path="+t),document.cookie=n}}},function(e,t){BI.CellSizeAndPositionManager=function(e,t,i){this._cellSizeGetter=t,this._cellCount=e,this._estimatedCellSize=i,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(),i=t.offset+t.size,n=this._lastMeasuredIndex+1;n<=e;n++){var r=this._cellSizeGetter(n);null==r||isNaN(r)||(this._cellSizeAndPositionData[n]={offset:i,size:r},i+=r)}this._lastMeasuredIndex=e}return this._cellSizeAndPositionData[e]}},getSizeAndPositionOfLastMeasuredCell:function(){return 0<=this._lastMeasuredIndex?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,i,n){var r,a=this.getSizeAndPositionOfCell(n),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,i))}var l=this.getTotalSize();return Math.max(0,Math.min(l-t,r))},getVisibleCellRange:function(e,t){if(0===this.getTotalSize())return{};var i=t+e,n=this._findNearestCell(t),r=this.getSizeAndPositionOfCell(n);t=r.offset+r.size;for(var a=n;t<i&&a<this._cellCount-1;)a++,t+=this.getSizeAndPositionOfCell(a).size;return{start:n,stop:a}},resetCell:function(e){this._lastMeasuredIndex=Math.min(this._lastMeasuredIndex,e-1)},_binarySearch:function(e,t,i){for(var n,r;t<=e;){if(n=t+Math.floor((e-t)/2),(r=this.getSizeAndPositionOfCell(n).offset)===i)return n;r<i?t=n+1:i<r&&(e=n-1)}if(0<t)return t-1},_exponentialSearch:function(e,t){for(var i=1;e<this._cellCount&&this.getSizeAndPositionOfCell(e).offset<t;)e+=i,i*=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(),i=Math.max(0,this._lastMeasuredIndex);return t.offset>=e?this._binarySearch(i,0,e):this._exponentialSearch(i,e)}}},BI.ScalingCellSizeAndPositionManager=function(e,t,i,n){this._cellSizeAndPositionManager=new BI.CellSizeAndPositionManager(e,t,i),this._maxScrollSize=n||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 i=this._cellSizeAndPositionManager.getTotalSize(),n=this.getTotalSize(),r=this._getOffsetPercentage(e,t,n);return Math.round(r*(n-i))},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,i,n){i=this._safeOffsetToOffset(t,i);var r=this._cellSizeAndPositionManager.getUpdatedOffsetForIndex(e,t,i,n);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,i){return i<=e?0:t/(i-e)},_offsetToSafeOffset:function(e,t){var i=this._cellSizeAndPositionManager.getTotalSize(),n=this.getTotalSize();if(i===n)return t;var r=this._getOffsetPercentage(e,t,i);return Math.round(r*(n-e))},_safeOffsetToOffset:function(e,t){var i=this._cellSizeAndPositionManager.getTotalSize(),n=this.getTotalSize();if(i===n)return t;var r=this._getOffsetPercentage(e,t,n);return Math.round(r*(i-e))}}},function(e,t){function i(e,t){return e<t}BI.Heap=function(e,t){this._items=e||[],this._size=this._items.length,this._comparator=t||i,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--,0<this._size&&(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);0<=e;e--)this._sinkDown(e)},_bubbleUp:function(e){for(var t=this._items[e];0<e;){var i=Math.floor((e+1)/2)-1,n=this._items[i];if(this._comparator(n,t))return;this._items[i]=t,this._items[e]=n,e=i}},_sinkDown:function(e){for(var t=this._items[e];;){var i,n,r=2*(e+1)-1,a=2*(e+1),o=-1;if(r<this._size&&(i=this._items[r],this._comparator(i,t)&&(o=r)),a<this._size&&(n=this._items[a],this._comparator(n,t)&&(-1!==o&&!this._comparator(n,this._items[o])||(o=a))),-1===o)return;this._items[e]=this._items[o],this._items[o]=t,e=o}}}},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){t=t||window;if(null!=(e=e||null)&&"function"==typeof e)for(var i=0;i<this.array.length;i++){var n=this.array[i],r=this.map[n];if(0==e.call(t,n,r,i,this.array,this.map))break}},get:function(e){return this.map[e]},toArray:function(){var i=[];return this.each(function(e,t){i.push(t)}),i}}},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 i;this.size===this.limit&&(i=this.shift());var n=this.get(e,!0);return n||(n={key:e},this._keymap[e]=n,this.tail?(this.tail.newer=n).older=this.tail:this.head=n,this.tail=n,this.size++),n.value=t,i},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 i=this._keymap[e];if(i!==undefined)return i===this.tail||(i.newer&&(i===this.head&&(this.head=i.newer),i.newer.older=i.older),i.older&&(i.older.newer=i.newer),i.newer=undefined,i.older=this.tail,this.tail&&(this.tail.newer=i),this.tail=i),t?i:i.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=[],i=e-1;0<=i;--i)t[i]=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;0<t;--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 i=this._heap[2*t];e<i?t*=2:(t=2*t+1,e-=i)}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 i=this._heap[2*t];e<=i?t*=2:(t=2*t+1,e-=i)}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 i=[],n=e-1;0<=n;--n)i[n]=t;return new BI.PrefixIntervalTree(i)},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){t=t||window;if(null!=(e=e||null)&&"function"==typeof e)for(var i=0;i<this.array.length;i++){if(0==e.call(t,i,this.array[i],this.array))break}},toArray:function(){return this.array},fromArray:function(e){var i=this;BI.each(e,function(e,t){i.push(t)})},clear:function(){this.array.length=0}}},function(e,t){!function(){var p=function(e,t,i,n){this.height=e,this.width=t,this.x=i,this.y=n,this._indexMap={},this._indices=[]};p.prototype={constructor:p,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,i,n){var r={};return BI.each(this.getSections(e,t,i,n),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(e,t,i,n){for(var r=Math.floor(i/this._sectionSize),a=Math.floor((i+t-1)/this._sectionSize),o=Math.floor(n/this._sectionSize),s=Math.floor((n+e-1)/this._sectionSize),l=[],u=r;u<=a;u++)for(var c=o;c<=s;c++){var h=u+"."+c;this._sections[h]||(this._sections[h]=new p(this._sectionSize,this._sectionSize,u*this._sectionSize,c*this._sectionSize)),l.push(this._sections[h])}return l},getTotalSectionCount:function(){return BI.size(this._sections)},registerCell:function(e,i){this._cellMetadata[i]=e,BI.each(this.getSections(e.height,e.width,e.x,e.y),function(e,t){t.addCellIndex(i)})}}}()},function(e,t){BI.Tree=function(){this.root=new BI.Node(BI.UUID())},BI.Tree.prototype={constructor:BI.Tree,addNode:function(e,t,i){BI.isNull(t)?this.root.addChild(e,i):BI.isNull(e)?this.root.addChild(t,i):e.addChild(t,i)},isRoot:function(e){return e===this.root},getRoot:function(){return this.root},clear:function(){this.root.clear()},initTree:function(e){var n=this;this.clear();var r=[];for(BI.each(e,function(e,t){var i=new BI.Node(t);i.set("data",t),n.addNode(i),r.push(i)});!BI.isEmpty(r);){var a=r.shift(),t=a.get("data");BI.each(t.children,function(e,t){var i=new BI.Node(t);i.set("data",t),r.push(i),n.addNode(a,i)})}},_toJSON:function(e){var i=this,n=[];return BI.each(e.getChildren(),function(e,t){n.push(i._toJSON(t))}),BI.extend({id:e.id},BI.deepClone(e.get("data")),0<n.length?{children:n}:{})},toJSON:function(e){var i=this,n=[];return BI.each((e||this.root).getChildren(),function(e,t){n.push(i._toJSON(t))}),n},_toJSONWithNode:function(e){var i=this,n=[];return BI.each(e.getChildren(),function(e,t){n.push(i._toJSONWithNode(t))}),BI.extend({id:e.id},BI.deepClone(e.get("data")),{node:e},0<n.length?{children:n}:{})},toJSONWithNode:function(e){var i=this,n=[];return BI.each((e||this.root).getChildren(),function(e,t){n.push(i._toJSONWithNode(t))}),n},search:function(e,i,n){if(!(e instanceof BI.Node))return arguments.callee.apply(this,[this.root,e,i]);var r=this,a=null;return BI.isNull(i)?null:BI.isEqual(e[n||"id"],i)?e:(BI.any(e.getChildren(),function(e,t){if(null!==(a=r.search(t,i,n)))return!0}),a)},_traverse:function(e,t){var i=[];for(i.push(e);!BI.isEmpty(i);){var n=i.shift(),r=t&&t(n);if(!1===r)break;!0!==r&&null!=n&&(i=i.concat(n.getChildren()))}},traverse:function(e){this._traverse(this.root,e)},_recursion:function(e,r,a){var o=this;return BI.every(e.getChildren(),function(e,t){var i=BI.clone(r);i.push(t.id);var n=a&&a(t,i);return!1!==n&&(!0===n||o._recursion(t,i,a))})},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=[],i=this.root;null!=i||!BI.isEmpty(t);){for(;null!=i;)t.push(i),i=i.getLeft();i=t.pop(),e&&e(i),i=i.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=[],i=this.root;null!=i||!BI.isEmpty(t);){for(;null!=i;)e&&e(i),t.push(i),i=i.getLeft();i=(i=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=[],i=this.root,n=null;null!=i||!BI.isEmpty(t);){for(;null!=i;)t.push(i),i=i.getLeft();i=null==(i=BI.last(t)).getRight()||i.getRight()==n?(e&&e(i),n=i=t.pop(),null):i.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(i){return BI.findIndex(this.children,function(e,t){return t.get("id")===i})},removeChild:function(e){this.removeChildByIndex(this.getChildIndex(e))},removeChildByIndex:function(e){var t=this.getChild(e-1),i=this.getChild(e+1);null!=t&&t.setRight(i||null),null!=i&&i.setLeft(t||null),this.children.splice(e,1)},removeAllChilds:function(){this.children=[]},addChild:function(e,t){var i=null,i=BI.isUndefined(t)?this.children.length-1:t-1;e.setParent(this),0<=i&&(this.getChild(i)&&this.getChild(i).setRight(e),e.setLeft(this.getChild(i))),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 i=[];if(BI.isArray(e))for(var n=0,r=e.length;n<r;n++){var a=BI.clone(e[n]);a.pId=null==a.pId?t:a.pId,delete a.children,i.push(a),e[n].children&&(i=i.concat(BI.Tree.transformToArrayFormat(e[n].children,a.id)))}else{var o=BI.clone(e);o.pId=null==o.pId?t:o.pId,delete o.children,i.push(o),e.children&&(i=i.concat(BI.Tree.transformToArrayFormat(e.children,o.id)))}return i},arrayFormat:function(e,t){if(!e)return[];var i=[];if(BI.isArray(e))for(var n=0,r=e.length;n<r;n++){var a=e[n];a.pId=null==a.pId?t:a.pId,i.push(a),e[n].children&&(i=i.concat(BI.Tree.arrayFormat(e[n].children,a.id)))}else{var o=e;o.pId=null==o.pId?t:o.pId,i.push(o),e.children&&(i=i.concat(BI.Tree.arrayFormat(e.children,o.id)))}return i},transformToTreeFormat:function(e){if(!e)return[];if(BI.isArray(e)){for(var t=[],i={},n=0,r=e.length;n<r;n++){if(BI.isNull(e[n].id))return e;i[e[n].id]=BI.clone(e[n])}for(n=0,r=e.length;n<r;n++)i[e[n].pId]&&e[n].id!==e[n].pId?(i[e[n].pId].children||(i[e[n].pId].children=[]),i[e[n].pId].children.push(i[e[n].id])):t.push(i[e[n].id]),delete i[e[n].id].pId;return t}return[e]},treeFormat:function(e){if(!e)return[];if(BI.isArray(e)){for(var t=[],i={},n=0,r=e.length;n<r;n++){if(BI.isNull(e[n].id))return e;i[e[n].id]=e[n]}for(n=0,r=e.length;n<r;n++)i[e[n].pId]&&e[n].id!==e[n].pId?(i[e[n].pId].children||(i[e[n].pId].children=[]),i[e[n].pId].children.push(i[e[n].id])):t.push(i[e[n].id]);return t}return[e]},traversal:function(e,i,n){var r;BI.isNull(e)||(r=this,BI.some(e,function(e,t){return!1===i(e,t,n)||void r.traversal(t.children,i,t)}))}})},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,i,n){this.x=e,this.y=t,this.w=i,this.h=n},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),i=new BI.Vector(e.x-this.x,e.y-this.y),n=new BI.Vector(i.x+e.w,i.y+e.h);if(t.cross(i)*t.cross(n)<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){BI.EventListener={listen:function(e,t,i){return e.addEventListener?(e.addEventListener(t,i,!1),{remove:function(){e.removeEventListener(t,i,!1)}}):e.attachEvent?(e.attachEvent("on"+t,i),{remove:function(){e.detachEvent("on"+t,i)}}):void 0},capture:function(e,t,i){return e.addEventListener?(e.addEventListener(t,i,!0),{remove:function(){e.removeEventListener(t,i,!0)}}):{remove:BI.emptyFn}},registerDefault:function(){}}},function(e,t){var i,n;i=_global.cancelAnimationFrame||_global.webkitCancelAnimationFrame||_global.mozCancelAnimationFrame||_global.oCancelAnimationFrame||_global.msCancelAnimationFrame||_global.clearTimeout,n=_global.requestAnimationFrame||_global.webkitRequestAnimationFrame||_global.mozRequestAnimationFrame||_global.oRequestAnimationFrame||_global.msRequestAnimationFrame||_global.setTimeout,BI.MouseMoveTracker=function(e,t,i){this._isDragging=!1,this._animationFrameID=null,this._domNode=i,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&&(i(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,i=e.clientY;this._deltaX+=t-this._x,this._deltaY+=i-this._y,null===this._animationFrameID&&(this._animationFrameID=n(this._didMouseMove)),this._x=t,this._y=i,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 p;p=_global.requestAnimationFrame||_global.webkitRequestAnimationFrame||_global.mozRequestAnimationFrame||_global.oRequestAnimationFrame||_global.msRequestAnimationFrame||_global.setTimeout,BI.WheelHandler=function(e,t,i,n){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 i&&(i=i?function(){return!0}:function(){return!1}),"function"!=typeof n&&(n=n?function(){return!0}:function(){return!1}),this._handleScrollX=t,this._handleScrollY=i,this._stopPropagation=n,this._onWheelCallback=e,this.onWheel=BI.bind(this.onWheel,this)},BI.WheelHandler.prototype={constructor:BI.WheelHandler,onWheel:function(e){var t,i,n,r,a,o,s=(a=r=n=i=0,"detail"in(t=e)&&(n=t.detail),"wheelDelta"in t&&(n=-t.wheelDelta/120),"wheelDeltaY"in t&&(n=-t.wheelDeltaY/120),"wheelDeltaX"in t&&(i=-t.wheelDeltaX/120),"axis"in t&&t.axis===t.HORIZONTAL_AXIS&&(i=n,n=0),r=10*i,a=10*n,"deltaY"in t&&(a=t.deltaY),"deltaX"in t&&(r=t.deltaX),(r||a)&&t.deltaMode&&(1===t.deltaMode?(r*=40,a*=40):(r*=800,a*=800)),r&&!i&&(i=r<1?-1:1),a&&!n&&(n=a<1?-1:1),{spinX:i,spinY:n,pixelX:r,pixelY:a}),l=this._deltaX+s.pixelX,u=this._deltaY+s.pixelY,c=this._handleScrollX(l,u),h=this._handleScrollY(u,l);(c||h)&&(this._deltaX+=c?s.pixelX:0,this._deltaY+=h?s.pixelY:0,e.preventDefault?e.preventDefault():e.returnValue=!1,0===this._deltaX&&0===this._deltaY||(this._stopPropagation()&&(e.stopPropagation?e.stopPropagation():e.cancelBubble=!0),o=!0),!0===o&&null===this._animationFrameID&&(this._animationFrameID=p(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 t={},l={};addEventListener("message",function(e){var o=e.data;switch(o.eventType){case"action":t[o.name][o.action].apply(t[o.name],o.args);break;case"destroy":BI.each(l[o.name],function(e,t){t=BI.isArray(t)?t:[t],BI.each(t,function(e,t){t()})}),delete t[o.name],delete l[o.name];break;case"create":var s=t[o.name]=BI.Models.getModel(o.type,o.options);l[o.name]=[],BI.each(o.watches,function(e,i){var t,n,r,a;l[o.name].push((t=s.model,n=i,r=function(e,t){postMessage(BI.extend({},o,{eventType:"watch",currentWatchType:i},{args:[e,t]}))},a=a||{},Fix.watch(t,n,r,BI.extend(a,{store:t}))))}),postMessage(BI.extend({},o,{eventType:"create"},{msg:s.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 i in this._children){var n=this._children[i];n.element!==this.element&&(e.appendChild(n.element[0]),t=!0)}!0===t&&this.appendFragment(e)},_getChildName:function(e){return""+e},_addElement:function(e,t,i){var n,r=this;return this.hasWidget(this._getChildName(e))?n=this.getWidgetByName(this._getChildName(e)):((n=BI._lazyCreateWidget(t,i)).on(BI.Events.DESTROY,function(){BI.each(r._children,function(e,t){t===n&&(BI.remove(r._children,t),r.removeItemAt(0|e))})}),this.addWidget(this._getChildName(e),n)),n},_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 u=this;return function c(e,t,i,n){if(e===t)return 0!==e||1/e==1/t;if(null==e||null==t)return e===t;var r=Object.prototype.toString.call(e);switch(r){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 a="[object Array]"===r;if(!a){if(BI.isFunction(e)&&BI.isFunction(t))return!0;e=u._getOptions(e),t=u._getOptions(t)}i=i||[];n=n||[];var o=i.length;for(;o--;)if(i[o]===e)return n[o]===t;i.push(e);n.push(t);if(a){if((o=e.length)!==t.length)return!1;for(;o--;)if(!c(e[o],t[o],i,n))return!1}else{var s,l=_.keys(e);if(o=l.length,_.keys(t).length!==o)return!1;for(;o--;)if(s=l[o],!_.has(t,s)||!c(e[s],t[s],i,n))return!1}i.pop();n.pop();return!0}(e,t)},_getWrapper:function(){return this.element},_addItemAt:function(e,t){for(var i=this.options.items.length;e<i;i--)this._children[this._getChildName(i)]=this._children[this._getChildName(i-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 i=this._addElement(e,t);return 0<e?this._children[this._getChildName(e-1)].element.after(i.element):i.element.prependTo(this._getWrapper()),i._mount(),i}},removeItemAt:function(e){e=BI.isArray(e)?e:[e];for(var t=[],i=[],n={},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):(n[this._getChildName(i.length)]=o,i.push(this.options.items[r]))}this.options.items=i,this._children=n,BI.each(t,function(e,t){t._destroy()})},shouldUpdateItem:function(e,t){if(e<0||e>this.options.items.length-1)return!1;var i=this._children[this._getChildName(e)];return i.shouldUpdate?i.shouldUpdate(this._getOptions(t)):null},updateItemAt:function(e,t){var i,n;e<0||e>this.options.items.length-1||(i=this._children[this._getChildName(e)],delete this._children[this._getChildName(e)],this.options.items.splice(e,1),n=this._addElement(e,t),this.options.items.splice(e,0,t),this._children[this._getChildName(e)]=n,0<e?this._children[this._getChildName(e-1)].element.after(n.element):n.element.prependTo(this._getWrapper()),i._destroy(),n._mount())},addItems:function(e,n){var r=this,a=this.options,o=BI.Widget._renderEngine.createFragment(),s=[];BI.each(e,function(e,t){var i=r._addElement(a.items.length,t,n);r._children[r._getChildName(a.items.length)]=i,a.items.push(t),s.push(i),o.appendChild(i.element[0])}),this._isMounted&&(this._getWrapper().append(o),BI.each(s,function(e,t){t._mount()}))},prependItems:function(e,t){e=e||[];for(var i=BI.Widget._renderEngine.createFragment(),n=[],r=e.length-1;0<=r;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]),n.push(a),i.appendChild(a.element[0])}this._isMounted&&(this._getWrapper().prepend(i),BI.each(n,function(e,t){t._mount()}))},getValue:function(){var i,n=this,r=[];return BI.each(this.options.items,function(e){var t;(i=n._children[n._getChildName(e)])&&(t=i.getValue(),t=BI.isArray(t)?t:[t],r=r.concat(t))}),r},setValue:function(t){var i,n=this;BI.each(this.options.items,function(e){(i=n._children[n._getChildName(e)])&&i.setValue(t)})},setText:function(t){var i,n=this;BI.each(this.options.items,function(e){(i=n._children[n._getChildName(e)])&&i.setText(t)})},patchItem:function(e,t,i){var n=this.shouldUpdateItem(i,t),r=this._children[this._getChildName(i)];return n?r._update(this._getOptions(t),n):null!==n||this._compare(e,t)?void 0:this.updateItemAt(i,t)},updateChildren:function(i,e){var n,r,s=this,t=0,a=0,o=i.length-1,l=i[0],u=i[o],c=e.length-1,h=e[0],p=e[c],d={};for(BI.each(i,function(e,t){var i=null==(t=s._getOptions(t)).key?e:t.key;BI.isKey(i)&&(d[i]=s._children[s._getChildName(e)])});t<=o&&a<=c;){BI.isNull(l)?l=i[++t]:BI.isNull(u)?u=i[--o]:f(l,h,t,a)?(n=this.patchItem(l,h,t)||n,d[null==l.key?t:l.key]=this._children[this._getChildName(t)],l=i[++t],h=e[++a]):f(u,p,o,c)?(n=this.patchItem(u,p,o)||n,d[null==u.key?o:u.key]=this._children[this._getChildName(o)],u=i[--o],p=e[--c]):f(l,p)?(n=this.patchItem(l,p,t)||n,d[null==l.key?t:l.key]=this._children[this._getChildName(t)],m(l,u,!0),l=i[++t],p=e[--c]):h=(f(u,h)?(n=this.patchItem(u,h,o)||n,d[null==u.key?o:u.key]=this._children[this._getChildName(o)],m(u,l),u=i[--o]):(r=function(e,t,i,n){var r,a;for(r=i;r<=n;++r)e[r]&&f(e[r],t)&&(a=e[r]);return a}(i,h,t,o),BI.isNull(r)?m(g(h),l):BI.each(i,function(e,t){t&&f(t,h)&&(n=s.patchItem(r,h,e)||n,d[null==r.key?e:r.key]=s._children[s._getChildName(e)],i[e]=undefined,m(r,l))})),e[++a])}function f(e,t,i,n){return e=s._getOptions(e),t=s._getOptions(t),BI.isKey(e.key)?e.key===t.key:0<=i&&i===n}function g(e,t){var i=s._getOptions(e),n=null==i.key?t:i.key;return d[n]=s._addElement(n,e)}function m(e,t,i,n){e=s._getOptions(e),t=t&&s._getOptions(t);var r,a,o=BI.isKey(e.key)?e.key:n;t&&d[t.key]?(r=BI.isKey(t.key)?t.key:n,0<(a=i?d[r].element.next():d[r].element).length?a.before(d[o].element):s._getWrapper().append(d[o].element)):s._getWrapper().append(d[o].element)}return o<t?function(e,t,i,n){for(;i<=n;++i){m(g(t[i],i),e,!1,i)}}(BI.isNull(e[c+1])?null:e[c+1],e,a,c):c<a&&function(e,t,i){for(;t<=i;++t){var n,r,a=e[t];BI.isNotNull(a)&&(n=s._getOptions(a),r=null==n.key?t:n.key,delete s._children[s._getChildName(r)],d[r]._destroy())}}(i,t,o),this._children={},BI.each(e,function(e,t){var i=s._getOptions(t),n=null==i.key?e:i.key;d[n]._mount(),s._children[s._getChildName(e)]=d[n]}),n},update:function(e){var t=this.options,i=e.items||[],n=this.updateChildren(t.items,i);return this.options.items=i,n},stroke:function(e){var i=this;BI.each(e,function(e,t){t&&i._addElement(e,t)})},removeWidget:function(i){var n;BI.isWidget(i)?BI.each(this._children,function(e,t){t===i&&(n=e)}):n=i,n&&this._removeItemAt(0|n)},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 i=this.options,n=BI.AbsoluteCenterLayout.superclass._addElement.apply(this,arguments);return n.element.css({position:"absolute",left:(i.hgap+i.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit,right:(i.hgap+i.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit,top:(i.vgap+i.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit,bottom:(i.vgap+i.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit,margin:"auto"}),n},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",hgap:0,lgap:0,rgap:0,vgap:0,tgap:0,bgap:0})},render:function(){BI.AbsoluteHorizontalLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},_addElement:function(e,t){var i=this.options,n=BI.AbsoluteHorizontalLayout.superclass._addElement.apply(this,arguments);return n.element.css({position:"absolute",left:(i.hgap+i.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit,right:(i.hgap+i.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit,margin:"auto"}),i.vgap+i.tgap+(t.vgap||0)+(t.tgap||0)!==0&&n.element.css("top",(i.vgap+i.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit),i.vgap+i.bgap+(t.vgap||0)+(t.bgap||0)!==0&&n.element.css("bottom",(i.vgap+i.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit),n},resize:function(){},populate:function(e){BI.AbsoluteHorizontalLayout.superclass.populate.apply(this,arguments),this._mount()}}),BI.shortcut("bi.absolute_horizontal_adapt",BI.AbsoluteHorizontalLayout)},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",hgap:0,lgap:0,rgap:0,vgap:0,tgap:0,bgap:0})},render:function(){BI.AbsoluteVerticalLayout.superclass.render.apply(this,arguments),this.populate(this.options.items)},_addElement:function(e,t){var i=this.options,n=BI.AbsoluteVerticalLayout.superclass._addElement.apply(this,arguments);return n.element.css({position:"absolute",left:t.lgap/BI.pixRatio+BI.pixUnit,right:t.rgap/BI.pixRatio+BI.pixUnit,top:(i.vgap+i.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit,bottom:(i.vgap+i.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit,margin:"auto"}),i.hgap+i.lgap+(t.hgap||0)+(t.lgap||0)!==0&&n.element.css("left",(i.hgap+i.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit),i.hgap+i.rgap+(t.hgap||0)+(t.rgap||0)!==0&&n.element.css("right",(i.hgap+i.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit),n},resize:function(){},populate:function(e){BI.AbsoluteVerticalLayout.superclass.populate.apply(this,arguments),this._mount()}}),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=BI.inherit(BI.Layout,{props:function(){return BI.extend(BI.HorizontalAdaptLayout.superclass.props.apply(this,arguments),{baseCls:"bi-h-a",verticalAlign:BI.VerticalAlign.Top,horizontalAlign:BI.HorizontalAlign.Center,columnSize:[],scrollx:!1,hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0})},render:function(){var t=this,e=this.options;return BI.HorizontalAdaptLayout.superclass.render.apply(this,arguments),{type:"bi.horizontal",verticalAlign:e.verticalAlign,horizontalAlign:e.horizontalAlign,columnSize:e.columnSize,items:e.items,scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable,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.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 i=[];return"left"in e.items&&i.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&&i.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}}]}),i},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,scrollx:!0,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 i,n,r=this.options,a=""===r.columnSize[e]?"":r.columnSize[e]<=1?(100*r.columnSize[e]).toFixed(1)+"%":(0===e?r.hgap:0)+r.hgap+r.lgap+r.rgap+r.columnSize[e];return this.hasWidget(this._getChildName(e))?(i=this.getWidgetByName(this._getChildName(e))).element.width(a):((n=BI._lazyCreateWidget(t)).element.css({position:"relative",top:"0",left:"0",margin:"0px auto"}),i=BI._lazyCreateWidget({type:"bi.default",width:a,items:[n]}),this.addWidget(this._getChildName(e),i)),i.element.css({"max-width":!BI.isNumber(r.columnSize[e])||r.columnSize[e]<=1?a:a/BI.pixRatio+BI.pixUnit}),0===e&&i.element.addClass("first-element"),i.element.css({position:"relative",display:"table-cell","vertical-align":r.verticalAlign,height:"100%"}),r.vgap+r.tgap+(t.tgap||0)+(t.vgap||0)!==0&&n.element.css({"margin-top":(r.vgap+r.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),r.hgap+r.lgap+(t.lgap||0)+(t.hgap||0)!==0&&n.element.css({"margin-left":((0===e?r.hgap:0)+r.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),r.hgap+r.rgap+(t.rgap||0)+(t.hgap||0)!==0&&n.element.css({"margin-right":(r.hgap+r.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),r.vgap+r.bgap+(t.bgap||0)+(t.vgap||0)!==0&&n.element.css({"margin-bottom":(r.vgap+r.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i},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 t=this,e=this.options;return BI.VerticalAdaptLayout.superclass.render.apply(this,arguments),{type:"bi.horizontal",horizontalAlign:e.horizontalAlign,verticalAlign:e.verticalAlign,columnSize:e.columnSize,items:e.items,scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable,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.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 i=this.options,n=BI.HorizontalAutoLayout.superclass._addElement.apply(this,arguments);return n.element.css({position:"relative",margin:"0px auto"}),i.vgap+i.tgap+(t.tgap||0)+(t.vgap||0)!==0&&n.element.css({"margin-top":((0===e?i.vgap:0)+i.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.lgap+(t.lgap||0)+(t.hgap||0)!==0&&n.element.css({"margin-left":(i.hgap+i.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.rgap+(t.rgap||0)+(t.hgap||0)!==0&&n.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&&n.element.css({"margin-bottom":(i.vgap+i.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n},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 t=this,e=this.options;return{type:"bi.inline",ref:function(e){t.layout=e},items:e.items,horizontalAlign:e.horizontalAlign,verticalAlign:e.verticalAlign,columnSize:e.columnSize,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.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 t=this,e=this.options;return{type:"bi.inline",ref:function(e){t.layout=e},items:e.items,horizontalAlign:e.horizontalAlign,verticalAlign:e.verticalAlign,columnSize:e.columnSize,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.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 t=this,e=this.options;return{type:"bi.inline",ref:function(e){t.layout=e},items:e.items,horizontalAlign:e.horizontalAlign,verticalAlign:e.verticalAlign,columnSize:e.columnSize,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.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 t=this,e=this.options;return{type:"bi.flex_horizontal",ref:function(e){t.wrapper=e},horizontalAlign:e.horizontalAlign,verticalAlign:e.verticalAlign,columnSize:e.columnSize,rowSize:e.rowSize,scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable,hgap:e.hgap,vgap:e.vgap,tgap:e.tgap,bgap:e.bgap,items:e.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 t=this,e=this.options;return{type:"bi.flex_vertical",ref:function(e){t.wrapper=e},horizontalAlign:e.horizontalAlign,verticalAlign:e.verticalAlign,columnSize:e.columnSize,rowSize:e.rowSize,scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable,hgap:e.hgap,vgap:e.vgap,tgap:e.tgap,bgap:e.bgap,items:e.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 i=this.options,n=BI.FlexHorizontalLayout.superclass._addElement.apply(this,arguments);return n.element.css({position:"relative"}),"auto"!==i.columnSize[e]&&("fill"===i.columnSize[e]||""===i.columnSize[e]?i.horizontalAlign!==BI.HorizontalAlign.Stretch&&(!0!==i.scrollable&&!0!==i.scrollx||n.element.addClass("f-s-n")):n.element.addClass("f-s-n")),0<i.columnSize[e]&&n.element.width(""===i.columnSize[e]?"":i.columnSize[e]<=1?(100*i.columnSize[e]).toFixed(1)+"%":i.columnSize[e]/BI.pixRatio+BI.pixUnit),"fill"===i.columnSize[e]&&n.element.addClass("f-f"),n.element.addClass("c-e"),0===e&&n.element.addClass("f-c"),e===i.items.length-1&&n.element.addClass("l-c"),i.vgap+i.tgap+(t.tgap||0)+(t.vgap||0)!==0&&n.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&&n.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&&n.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&&n.element.css({"margin-bottom":(i.vgap+i.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n},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 n=this.options,e=n.items.left||[],t=n.items.right||[],e=BI.map(e,function(e,t){var i={el:BI.stripEL(t)};return n.lvgap+n.ltgap+(t.tgap||0)+(t.vgap||0)!==0&&(i.tgap=n.lvgap+n.ltgap+(t.tgap||0)+(t.vgap||0)),n.lhgap+n.llgap+(t.lgap||0)+(t.hgap||0)!==0&&(i.lgap=(0===e?n.lhgap:0)+n.llgap+(t.lgap||0)+(t.hgap||0)),n.lhgap+n.lrgap+(t.rgap||0)+(t.hgap||0)!==0&&(i.rgap=n.lhgap+n.lrgap+(t.rgap||0)+(t.hgap||0)),n.lvgap+n.lbgap+(t.bgap||0)+(t.vgap||0)!==0&&(i.bgap=n.lvgap+n.lbgap+(t.bgap||0)+(t.vgap||0)),i}),t=BI.map(t,function(e,t){var i={el:BI.stripEL(t)};return n.rvgap+n.rtgap+(t.tgap||0)+(t.vgap||0)!==0&&(i.tgap=n.rvgap+n.rtgap+(t.tgap||0)+(t.vgap||0)),n.rhgap+n.rlgap+(t.lgap||0)+(t.hgap||0)!==0&&(i.lgap=n.rlgap+(t.lgap||0)+(t.hgap||0)),n.rhgap+n.rrgap+(t.rgap||0)+(t.hgap||0)!==0&&(i.rgap=n.rhgap+n.rrgap+(t.rgap||0)+(t.hgap||0)),n.rvgap+n.rbgap+(t.bgap||0)+(t.vgap||0)!==0&&(i.bgap=n.rvgap+n.rbgap+(t.bgap||0)+(t.vgap||0)),i});return e.concat({type:"bi.flex_vertical_adapt",cls:"flex-left-auto",items:t})},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 t=this,e=this.options;return{type:"bi.flex_horizontal",ref:function(e){t.wrapper=e},verticalAlign:e.verticalAlign,horizontalAlign:e.horizontalAlign,columnSize:e.columnSize,rowSize:e.rowSize,scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,hgap:e.hgap,items:e.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 i=BI.FlexVerticalLayout.superclass._addElement.apply(this,arguments),n=this.options;return i.element.css({position:"relative"}),"auto"!==n.rowSize[e]&&("fill"===n.rowSize[e]||""===n.rowSize[e]?n.verticalAlign!==BI.VerticalAlign.Stretch&&(!0!==n.scrollable&&!0!==n.scrolly||i.element.addClass("f-s-n")):i.element.addClass("f-s-n")),0<n.rowSize[e]&&i.element.height(""===n.rowSize[e]?"":n.rowSize[e]<=1?(100*n.rowSize[e]).toFixed(1)+"%":n.rowSize[e]/BI.pixRatio+BI.pixUnit),"fill"===n.rowSize[e]&&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 t=this,e=this.options;return{type:"bi.flex_scrollable_horizontal",ref:function(e){t.wrapper=e},horizontalAlign:e.horizontalAlign,verticalAlign:e.verticalAlign,columnSize:e.columnSize,rowSize:e.rowSize,scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,items:e.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 t=this,e=this.options;return{type:"bi.flex_scrollable_vertical",ref:function(e){t.wrapper=e},horizontalAlign:e.horizontalAlign,verticalAlign:e.verticalAlign,columnSize:e.columnSize,rowSize:e.rowSize,scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable,hgap:e.hgap,vgap:e.vgap,tgap:e.tgap,bgap:e.bgap,items:e.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 i=this.options,n=BI.FlexWrapperHorizontalLayout.superclass._addElement.apply(this,arguments);return n.element.css({position:"relative"}),"auto"!==i.columnSize[e]&&("fill"===i.columnSize[e]||""===i.columnSize[e]?i.horizontalAlign!==BI.HorizontalAlign.Stretch&&(!0!==i.scrollable&&!0!==i.scrollx||n.element.addClass("f-s-n")):n.element.addClass("f-s-n")),0<i.columnSize[e]&&n.element.width(""===i.columnSize[e]?"":i.columnSize[e]<=1?(100*i.columnSize[e]).toFixed(1)+"%":i.columnSize[e]/BI.pixRatio+BI.pixUnit),"fill"===i.columnSize[e]&&(n.element.addClass("f-f"),this.element.addClass("f-f")),n.element.addClass("c-e"),0===e&&n.element.addClass("f-c"),e===i.items.length-1&&n.element.addClass("l-c"),i.vgap+i.tgap+(t.tgap||0)+(t.vgap||0)!==0&&n.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&&n.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&&n.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&&n.element.css({"margin-bottom":(i.vgap+i.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n},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 t=this,e=this.options;return{type:"bi.flex_scrollable_horizontal",ref:function(e){t.wrapper=e},verticalAlign:e.verticalAlign,horizontalAlign:e.horizontalAlign,columnSize:e.columnSize,rowSize:e.rowSize,scrollx:e.scrollx,scrolly:e.scrolly,scrollable:e.scrollable,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,items:e.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 i=this.options,n=BI.FlexWrapperVerticalLayout.superclass._addElement.apply(this,arguments);return n.element.css({position:"relative"}),"auto"!==i.rowSize[e]&&("fill"===i.rowSize[e]||""===i.rowSize[e]?i.verticalAlign!==BI.VerticalAlign.Stretch&&(!0!==i.scrollable&&!0!==i.scrolly||n.element.addClass("f-s-n")):n.element.addClass("f-s-n")),0<i.rowSize[e]&&n.element.height(""===i.rowSize[e]?"":i.rowSize[e]<=1?(100*i.rowSize[e]).toFixed(1)+"%":i.rowSize[e]/BI.pixRatio+BI.pixUnit),"fill"===i.rowSize[e]&&(n.element.addClass("f-f"),this.element.addClass("f-f")),n.element.addClass("c-e"),0===e&&n.element.addClass("f-c"),e===i.items.length-1&&n.element.addClass("l-c"),i.vgap+i.tgap+(t.tgap||0)+(t.vgap||0)!==0&&n.element.css({"margin-top":((0===e?i.vgap:0)+i.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.lgap+(t.lgap||0)+(t.hgap||0)!==0&&n.element.css({"margin-left":(i.hgap+i.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.rgap+(t.rgap||0)+(t.hgap||0)!==0&&n.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&&n.element.css({"margin-bottom":(i.vgap+i.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n},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 i=this.options,n=BI.AbsoluteLayout.superclass._addElement.apply(this,arguments),r=0,a=0,o=0,s=0;return BI.isNotNull(t.left)&&(n.element.css({left:BI.isNumber(t.left)?t.left/BI.pixRatio+BI.pixUnit:t.left}),r+=t.left),BI.isNotNull(t.right)&&(n.element.css({right:BI.isNumber(t.right)?t.right/BI.pixRatio+BI.pixUnit:t.right}),a+=t.right),BI.isNotNull(t.top)&&(n.element.css({top:BI.isNumber(t.top)?t.top/BI.pixRatio+BI.pixUnit:t.top}),o+=t.top),BI.isNotNull(t.bottom)&&(n.element.css({bottom:BI.isNumber(t.bottom)?t.bottom/BI.pixRatio+BI.pixUnit:t.bottom}),s+=t.bottom),BI.isNotNull(i.hgap)&&(r+=i.hgap,n.element.css({left:r/BI.pixRatio+BI.pixUnit}),a+=i.hgap,n.element.css({right:a/BI.pixRatio+BI.pixUnit})),BI.isNotNull(i.vgap)&&(o+=i.vgap,n.element.css({top:o/BI.pixRatio+BI.pixUnit}),s+=i.vgap,n.element.css({bottom:s/BI.pixRatio+BI.pixUnit})),BI.isNotNull(i.lgap)&&(r+=i.lgap,n.element.css({left:r/BI.pixRatio+BI.pixUnit})),BI.isNotNull(i.rgap)&&(a+=i.rgap,n.element.css({right:a/BI.pixRatio+BI.pixUnit})),BI.isNotNull(i.tgap)&&(o+=i.tgap,n.element.css({top:o/BI.pixRatio+BI.pixUnit})),BI.isNotNull(i.bgap)&&(s+=i.bgap,n.element.css({bottom:s/BI.pixRatio+BI.pixUnit})),BI.isNotNull(t.width)&&n.element.css({width:BI.isNumber(t.width)?t.width/BI.pixRatio+BI.pixUnit:t.width}),BI.isNotNull(t.height)&&n.element.css({height:BI.isNumber(t.height)?t.height/BI.pixRatio+BI.pixUnit:t.height}),n.element.css({position:"absolute"}),n},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 i=this.options,n=BI.AdaptiveLayout.superclass._addElement.apply(this,arguments);n.element.css({position:"relative"});var r=0,a=0,o=0,s=0;return BI.isNotNull(t.left)&&n.element.css({left:BI.isNumber(t.left)?t.left/BI.pixRatio+BI.pixUnit:t.left}),BI.isNotNull(t.right)&&n.element.css({right:BI.isNumber(t.right)?t.right/BI.pixRatio+BI.pixUnit:t.right}),BI.isNotNull(t.top)&&n.element.css({top:BI.isNumber(t.top)?t.top/BI.pixRatio+BI.pixUnit:t.top}),BI.isNotNull(t.bottom)&&n.element.css({bottom:BI.isNumber(t.bottom)?t.bottom/BI.pixRatio+BI.pixUnit:t.bottom}),BI.isNotNull(i.hgap)&&(r+=i.hgap,n.element.css({"margin-left":r/BI.pixRatio+BI.pixUnit}),a+=i.hgap,n.element.css({"margin-right":a/BI.pixRatio+BI.pixUnit})),BI.isNotNull(i.vgap)&&(o+=i.vgap,n.element.css({"margin-top":o/BI.pixRatio+BI.pixUnit}),s+=i.vgap,n.element.css({"margin-bottom":s/BI.pixRatio+BI.pixUnit})),BI.isNotNull(i.lgap)&&(r+=i.lgap,n.element.css({"margin-left":r/BI.pixRatio+BI.pixUnit})),BI.isNotNull(i.rgap)&&(a+=i.rgap,n.element.css({"margin-right":a/BI.pixRatio+BI.pixUnit})),BI.isNotNull(i.tgap)&&(o+=i.tgap,n.element.css({"margin-top":o/BI.pixRatio+BI.pixUnit})),BI.isNotNull(i.bgap)&&(s+=i.bgap,n.element.css({"margin-bottom":s/BI.pixRatio+BI.pixUnit})),BI.isNotNull(t.width)&&n.element.css({width:BI.isNumber(t.width)?t.width/BI.pixRatio+BI.pixUnit:t.width}),BI.isNotNull(t.height)&&n.element.css({height:BI.isNumber(t.height)?t.height/BI.pixRatio+BI.pixUnit:t.height}),n},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,i,n=0,r=0,a=0,o=0;"north"in e&&null!=(t=e.north)&&(t.el&&(this.hasWidget(this._getChildName("north"))||(i=BI._lazyCreateWidget(t),this.addWidget(this._getChildName("north"),i)),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)),"south"in e&&null!=(t=e.south)&&(t.el&&(this.hasWidget(this._getChildName("south"))||(i=BI._lazyCreateWidget(t),this.addWidget(this._getChildName("south"),i)),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"})),r=(t.height||0)+(t.top||0)+(t.bottom||0)),"west"in e&&null!=(t=e.west)&&(t.el&&(this.hasWidget(this._getChildName("west"))||(i=BI._lazyCreateWidget(t),this.addWidget(this._getChildName("west"),i)),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:r/BI.pixRatio+BI.pixUnit,right:"initial"})),a=(t.width||0)+(t.left||0)+(t.right||0)),"east"in e&&null!=(t=e.east)&&(t.el&&(this.hasWidget(this._getChildName("east"))||(i=BI._lazyCreateWidget(t),this.addWidget(this._getChildName("east"),i)),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:r/BI.pixRatio+BI.pixUnit,left:"initial"})),o=(t.width||0)+(t.left||0)+(t.right||0)),"center"in e&&null!=(t=e.center)&&(this.hasWidget(this._getChildName("center"))||(i=BI._lazyCreateWidget(t),this.addWidget(this._getChildName("center"),i)),this.getWidgetByName(this._getChildName("center")).element.css({position:"absolute",top:n/BI.pixRatio+BI.pixUnit,bottom:r/BI.pixRatio+BI.pixUnit,left:a/BI.pixRatio+BI.pixUnit,right:o/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 n=this,r=this.options;this.showIndex=void 0,BI.each(e,function(e,i){var t;i&&(n.hasWidget(i.cardName)?t=n.getWidgetByName(n._getChildName(i.cardName)):((t=BI._lazyCreateWidget(i)).on(BI.Events.DESTROY,function(){var e=BI.findIndex(r.items,function(e,t){return t.cardName==i.cardName});-1<e&&r.items.splice(e,1)}),n.addWidget(n._getChildName(i.cardName),t)),t.element.css({position:"absolute",top:"0",right:"0",bottom:"0",left:"0"}),t.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(i){return BI.some(this.options.items,function(e,t){return t.cardName==i&&t.el})},getCardByName:function(e){if(!this.isCardExisted(e))throw new Error("cardName is not exist");return this._children[this._getChildName(e)]},_deleteCardByName:function(i){delete this._children[this._getChildName(i)];var e=BI.findIndex(this.options.items,function(e,t){return t.cardName==i});-1<e&&this.options.items.splice(e,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 i=BI._lazyCreateWidget(t,this);return i.element.css({position:"relative",top:"0",left:"0",width:"100%",height:"100%"}).appendTo(this.element),i.invisible(),this.addWidget(this._getChildName(e),i),this.options.items.push({el:t,cardName:e}),i},showCardByName:function(n,r,a){var o=this,s=this.isCardExisted(n);null!=this.showIndex&&(this.lastShowIndex=this.showIndex),this.showIndex=n;var l=!1;BI.each(this.options.items,function(e,t){var i=o._children[o._getChildName(t.cardName)];i&&(n!=t.cardName?!l&&!s&&BI.Action&&r instanceof BI.Action?(r.actionBack(i),l=!0):i.invisible():BI.Action&&r instanceof BI.Action?r.actionPerformed(void 0,i,a):(i.visible(),a&&a()))})},showLastCard:function(){var i=this;this.showIndex=this.lastShowIndex,BI.each(this.options.items,function(e,t){i._children[i._getChildName(t.cardName)].setVisible(i.showIndex==e)})},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 i=this;BI.each(this.getAllCardNames(),function(e,t){i.deleteCardByName(t)})},hideAllCard:function(){var i=this;BI.each(this.options.items,function(e,t){i._children[i._getChildName(t.cardName)].invisible()})},isAllCardHide:function(){var i=this,n=!0;return BI.some(this.options.items,function(e,t){if(i._children[i._getChildName(t.cardName)].isVisible())return n=!1}),n},removeWidget:function(i){var n;BI.isWidget(i)?BI.each(this._children,function(e,t){t===i&&(n=e)}):n=i,n&&this._deleteCardByName(n)}}),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 i=this.options,n=BI.DefaultLayout.superclass._addElement.apply(this,arguments);return i.vgap+i.tgap+(t.tgap||0)!==0&&n.element.css({"margin-top":(i.vgap+i.tgap+(t.tgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.lgap+(t.lgap||0)!==0&&n.element.css({"margin-left":(i.hgap+i.lgap+(t.lgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.rgap+(t.rgap||0)!==0&&n.element.css({"margin-right":(i.hgap+i.rgap+(t.rgap||0))/BI.pixRatio+BI.pixUnit}),i.vgap+i.bgap+(t.bgap||0)!==0&&n.element.css({"margin-bottom":(i.vgap+i.bgap+(t.bgap||0))/BI.pixRatio+BI.pixUnit}),n},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=this.options,i=t.rows||t.items.length,n=t.columns||0|(t.items[0]&&t.items[0].length),r=BI.makeArray(i),a={},o={};function s(e,t,i){0===t&&e.addClass("first-row"),0===i&&e.addClass("first-col"),e.addClass(BI.isOdd(t+1)?"odd-row":"even-row"),e.addClass(BI.isOdd(i+1)?"odd-col":"even-col"),e.addClass("center-element")}function l(e,t,i){var n="";0===t&&(n+=" first-row"),0===i&&(n+=" first-col"),BI.isOdd(t+1)?n+=" odd-row":n+=" even-row",BI.isOdd(i+1)?n+=" odd-col":n+=" even-col",e.cls=(e.cls||"")+n+" center-element"}BI.each(r,function(e){r[e]=BI.makeArray(n)}),BI.each(e,function(i,n){BI.isArray(n)?BI.each(n,function(e,t){a[i]=(a[i]||0)+n.width,o[e]=(o[e]||0)+n.height,r[i][e]=t}):(a[n.row]=(a[n.row]||0)+n.width,o[n.column]=(o[n.column]||0)+n.height,r[n.row][n.column]=n)});for(var u,c,h,p=0;p<i;p++)for(var d=0,f=0;f<n;f++){if(!r[p][f])throw new Error("item be required");this.hasWidget(this._getChildName(p+"_"+f))?I=this.getWidgetByName(this._getChildName(p+"_"+f)):(I=BI._lazyCreateWidget(r[p][f]),this.addWidget(this._getChildName(p+"_"+f),I));var g=100*d/a[p];I.element.css({position:"absolute",left:g+"%"}),0<f&&this.getWidgetByName(this._getChildName(p+"_"+(f-1))).element.css({right:100-g+"%"}),f==t.columns-1&&I.element.css({right:"0%"}),c=p,h=f,(u=I)instanceof BI.Widget?s(u.element,c,h):u.el instanceof BI.Widget?s(u.el.element,c,h):u.el?l(u.el,c,h):l(u,c,h),d+=r[p][f].width}for(f=0;f<t.columns;f++)for(var m=0,p=0;p<t.rows;p++){var I=this.getWidgetByName(this._getChildName(p+"_"+f)),B=100*m/o[f];I.element.css({top:B+"%"}),0<p&&this.getWidgetByName(this._getChildName(p-1+"_"+f)).element.css({bottom:100-B+"%"}),p==t.rows-1&&I.element.css({bottom:"0%"}),m+=r[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 i=this.options,n=BI.FloatLeftLayout.superclass._addElement.apply(this,arguments);return n.element.css({position:"relative","float":"left"}),BI.isNotNull(t.left)&&n.element.css({left:BI.isNumber(t.left)?t.left/BI.pixRatio+BI.pixUnit:t.left}),BI.isNotNull(t.right)&&n.element.css({right:BI.isNumber(t.right)?t.right/BI.pixRatio+BI.pixUnit:t.right}),BI.isNotNull(t.top)&&n.element.css({top:BI.isNumber(t.top)?t.top/BI.pixRatio+BI.pixUnit:t.top}),BI.isNotNull(t.bottom)&&n.element.css({bottom:BI.isNumber(t.bottom)?t.bottom/BI.pixRatio+BI.pixUnit:t.bottom}),i.vgap+i.tgap+(t.tgap||0)+(t.vgap||0)!==0&&n.element.css({"margin-top":(i.vgap/2+i.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.lgap+(t.lgap||0)+(t.hgap||0)!==0&&n.element.css({"margin-left":(i.hgap/2+i.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.rgap+(t.rgap||0)+(t.hgap||0)!==0&&n.element.css({"margin-right":(i.hgap/2+i.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),i.vgap+i.bgap+(t.bgap||0)+(t.vgap||0)!==0&&n.element.css({"margin-bottom":(i.vgap/2+i.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n},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 i=this.options,n=BI.FloatRightLayout.superclass._addElement.apply(this,arguments);return n.element.css({position:"relative","float":"right"}),BI.isNotNull(t.left)&&n.element.css({left:BI.isNumber(t.left)?t.left/BI.pixRatio+BI.pixUnit:t.left}),BI.isNotNull(t.right)&&n.element.css({right:BI.isNumber(t.right)?t.right/BI.pixRatio+BI.pixUnit:t.right}),BI.isNotNull(t.top)&&n.element.css({top:BI.isNumber(t.top)?t.top/BI.pixRatio+BI.pixUnit:t.top}),BI.isNotNull(t.bottom)&&n.element.css({bottom:BI.isNumber(t.bottom)?t.bottom/BI.pixRatio+BI.pixUnit:t.bottom}),i.vgap+i.tgap+(t.tgap||0)+(t.vgap||0)!==0&&n.element.css({"margin-top":(i.vgap/2+i.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.lgap+(t.lgap||0)+(t.hgap||0)!==0&&n.element.css({"margin-left":(i.hgap/2+i.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.rgap+(t.rgap||0)+(t.hgap||0)!==0&&n.element.css({"margin-right":(i.hgap/2+i.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),i.vgap+i.bgap+(t.bgap||0)+(t.vgap||0)!==0&&n.element.css({"margin-bottom":(i.vgap/2+i.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n},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=this.options,i=t.rows||t.items.length,n=t.columns||0|(t.items[0]&&t.items[0].length),r=100/n,a=100/i,o=[],s=0;s<i;s++)o[s]=[];function l(e,t,i){0===t&&e.addClass("first-row"),0===i&&e.addClass("first-col"),e.addClass(BI.isOdd(t+1)?"odd-row":"even-row"),e.addClass(BI.isOdd(i+1)?"odd-col":"even-col"),e.addClass("center-element")}function u(e,t,i){var n="";0===t&&(n+=" first-row"),0===i&&(n+=" first-col"),BI.isOdd(t+1)?n+=" odd-row":n+=" even-row",BI.isOdd(i+1)?n+=" odd-col":n+=" even-col",e.cls=(e.cls||"")+n+" center-element"}BI.each(e,function(i,e){BI.isArray(e)?BI.each(e,function(e,t){o[i][e]=BI._lazyCreateWidget(t)}):o[e.row][e.column]=BI._lazyCreateWidget(e)});for(var c,h,p,s=0;s<i;s++)for(var d=0;d<n;d++)o[s][d]||(o[s][d]=BI._lazyCreateWidget({type:"bi.layout"})),c=o[s][d],h=s,p=d,c instanceof BI.Widget?l(c.element,h,p):c.el instanceof BI.Widget?l(c.el.element,h,p):c.el?u(c.el,h,p):u(c,h,p),o[s][d].element.css({position:"absolute",top:a*s+"%",left:r*d+"%",right:100-r*(d+1)+"%",bottom:100-a*(s+1)+"%"}),this.addWidget(this._getChildName(s+"_"+d),o[s][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,i){var n,r,a=this.options,o=BI.InlineLayout.superclass._addElement.apply(this,arguments);if(o.element.css({width:""===a.columnSize[e]?"":a.columnSize[e]<=1?(100*a.columnSize[e]).toFixed(1)+"%":a.columnSize[e]/BI.pixRatio+BI.pixUnit,position:"relative","vertical-align":a.verticalAlign}),o.element.addClass("i-item"),"fill"===a.columnSize[e]||""===a.columnSize[e]){for(var s=a.hgap+(t.lgap||0)+(t.hgap||0),l=a.hgap+(t.rgap||0)+(t.hgap||0),u=0;u<e;u++)s+=a.hgap+a.lgap+a.rgap+a.columnSize[u];for(u=e+1;u<a.columnSize.length;u++)l+=a.hgap+a.lgap+a.rgap+a.columnSize[u];"fill"===a.columnSize[e]&&o.element.css("min-width","calc(100% - "+((s+l)/BI.pixRatio+BI.pixUnit)+")"),(a.horizontalAlign===BI.HorizontalAlign.Stretch||!0!==a.scrollable&&!0!==a.scrollx)&&o.element.css("max-width","calc(100% - "+((s+l)/BI.pixRatio+BI.pixUnit)+")")}return a.verticalAlign===BI.VerticalAlign.Stretch&&(n=a.vgap+(t.tgap||0)+(t.vgap||0),r=a.vgap+(t.bgap||0)+(t.vgap||0),o.element.css("height","calc(100% - "+((n+r)/BI.pixRatio+BI.pixUnit)+")")),a.vgap+a.tgap+(t.tgap||0)+(t.vgap||0)!==0&&o.element.css({"margin-top":(a.vgap+a.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),a.hgap+a.lgap+(t.lgap||0)+(t.hgap||0)!==0&&o.element.css({"margin-left":((0===e?a.hgap:0)+a.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),a.hgap+a.rgap+(t.rgap||0)+(t.hgap||0)!==0&&o.element.css({"margin-right":(a.hgap+a.rgap+(t.rgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),a.vgap+a.bgap+(t.bgap||0)+(t.vgap||0)!==0&&o.element.css({"margin-bottom":(a.vgap+a.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),o},resize:function(){this.stroke(this.options.items)},addItem:function(e){throw new Error("不能添加元素")},stroke:function(i){var n=this;BI.each(i,function(e,t){t&&n._addElement(e,t,i.length)})},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 i,n=this.options,r=BI.LatticeLayout.superclass._addElement.apply(this,arguments);return i=n.columnSize&&n.columnSize[e]?n.columnSize[e]/BI.sum(n.columnSize)*100+"%":1/this.options.items.length*100+"%",r.element.css({position:"relative","float":"left",width:i}),r},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 i,n,r=this.options,a=[],o=0,s=0;function l(e,t,i){0===t&&e.addClass("first-row"),0===i&&e.addClass("first-col"),e.addClass(BI.isOdd(t+1)?"odd-row":"even-row"),e.addClass(BI.isOdd(i+1)?"odd-col":"even-col"),e.addClass("center-element")}function u(e,t,i){var n="";0===t&&(n+=" first-row"),0===i&&(n+=" first-col"),BI.isOdd(t+1)?n+=" odd-row":n+=" even-row",BI.isOdd(i+1)?n+=" odd-col":n+=" even-col",e.cls=(e.cls||"")+n+" center-element"}function c(e,t,i){e instanceof BI.Widget?l(e.element,t,i):e.el instanceof BI.Widget?l(e.el.element,t,i):e.el?u(e.el,t,i):u(e,t,i)}for(i=0;i<t.length&&BI.isNumber(r.columnSize[i]);i++)c(t[i],this.rows,i),a.push(BI.extend({top:0,bottom:0,left:r.columnSize[i]<=1?(100*o).toFixed(1)+"%":o,width:r.columnSize[i]<=1?(100*r.columnSize[i]).toFixed(1)+"%":r.columnSize[i]},t[i])),o+=r.columnSize[i]+(r.columnSize[i]<1?0:r.hgap);for(n=t.length-1;i<n;n--){if(!BI.isNumber(r.columnSize[n]))throw new Error("item with fill can only be one");c(t[n],this.rows,n),a.push(BI.extend({top:0,bottom:0,right:r.columnSize[n]<=1?(100*s).toFixed(1)+"%":s,width:r.columnSize[n]<=1?(100*r.columnSize[n]).toFixed(1)+"%":r.columnSize[n]},t[n])),s+=r.columnSize[n]+(r.columnSize[n]<1?0:r.hgap)}0<=i&&i<t.length&&(c(t[i],this.rows,i),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[i])));var h=BI._lazyCreateWidget({type:"bi.absolute",height:BI.isArray(r.rowSize)?r.rowSize[this.rows]:r.rowSize,items:a});return 0<this.rows&&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",hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0,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(n){var r=this,a=this.options;n=BI.compact(n),BI.each(n,function(e,t){var i;r.hasWidget(r._getChildName(e))?i=r.getWidgetByName(r._getChildName(e)):(i=BI._lazyCreateWidget(t),r.addWidget(r._getChildName(e),i)),i.element.css({position:"absolute",top:((t.vgap||0)+(t.tgap||0)+a.vgap+a.tgap)/BI.pixRatio+BI.pixUnit,bottom:((t.bgap||0)+(t.vgap||0)+a.vgap+a.bgap)/BI.pixRatio+BI.pixUnit})});var o={},s={};o[0]=0,s[n.length-1]=0,BI.any(n,function(e,t){var i=r.getWidgetByName(r._getChildName(e));if(BI.isNull(o[e])&&(o[e]=o[e-1]+n[e-1].width+(n[e-1].lgap||0)+2*(n[e-1].hgap||0)+a.hgap+a.lgap+a.rgap),t.width<1&&0<=t.width?i.element.css({left:(100*o[e]).toFixed(1)+"%",width:(100*t.width).toFixed(1)+"%"}):i.element.css({left:(o[e]+(t.lgap||0)+(t.hgap||0)+a.hgap+a.lgap)/BI.pixRatio+BI.pixUnit,width:BI.isNumber(t.width)?t.width/BI.pixRatio+BI.pixUnit:""}),!BI.isNumber(t.width))return!0}),BI.backAny(n,function(e,t){var i=r.getWidgetByName(r._getChildName(e));if(BI.isNull(s[e])&&(s[e]=s[e+1]+n[e+1].width+(n[e+1].rgap||0)+2*(n[e+1].hgap||0)+a.hgap+a.lgap+a.rgap),t.width<1&&0<=t.width?i.element.css({right:(100*s[e]).toFixed(1)+"%",width:(100*t.width).toFixed(1)+"%"}):i.element.css({right:(s[e]+(t.rgap||0)+(t.hgap||0)+a.hgap+a.rgap)/BI.pixRatio+BI.pixUnit,width:BI.isNumber(t.width)?t.width/BI.pixRatio+BI.pixUnit:""}),!BI.isNumber(t.width))return!0})},update:function(){var i;return BI.each(this._children,function(e,t){i=t.update()||i}),i},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",hgap:0,vgap:0,lgap:0,rgap:0,tgap:0,bgap:0,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(n){var r=this,a=this.options;n=BI.compact(n),BI.each(n,function(e,t){var i;r.hasWidget(r._getChildName(e))?i=r.getWidgetByName(r._getChildName(e)):(i=BI._lazyCreateWidget(t),r.addWidget(r._getChildName(e),i)),i.element.css({position:"absolute",left:((t.lgap||0)+(t.hgap||0)+a.hgap+a.lgap)/BI.pixRatio+BI.pixUnit,right:((t.hgap||0)+(t.rgap||0)+a.hgap+a.rgap)/BI.pixRatio+BI.pixUnit})});var o={},s={};o[0]=0,s[n.length-1]=0,BI.any(n,function(e,t){var i=r.getWidgetByName(r._getChildName(e));if(BI.isNull(o[e])&&(o[e]=o[e-1]+n[e-1].height+(n[e-1].tgap||0)+2*(n[e-1].vgap||0)+a.vgap+a.tgap+a.bgap),t.height<1&&0<=t.height?i.element.css({top:(100*o[e]).toFixed(1)+"%",height:(100*t.height).toFixed(1)+"%"}):i.element.css({top:(o[e]+(t.vgap||0)+(t.tgap||0)+a.vgap+a.tgap)/BI.pixRatio+BI.pixUnit,height:BI.isNumber(t.height)?t.height/BI.pixRatio+BI.pixUnit:""}),!BI.isNumber(t.height))return!0}),BI.backAny(n,function(e,t){var i=r.getWidgetByName(r._getChildName(e));if(BI.isNull(s[e])&&(s[e]=s[e+1]+n[e+1].height+(n[e+1].bgap||0)+2*(n[e+1].vgap||0)+a.vgap+a.tgap+a.bgap),t.height<1&&0<=t.height?i.element.css({bottom:(100*s[e]).toFixed(1)+"%",height:(100*t.height).toFixed(1)+"%"}):i.element.css({bottom:(s[e]+(t.vgap||0)+(t.bgap||0)+a.vgap+a.bgap)/BI.pixRatio+BI.pixUnit,height:BI.isNumber(t.height)?t.height/BI.pixRatio+BI.pixUnit:""}),!BI.isNumber(t.height))return!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:[],verticalAlign:BI.VerticalAlign.Middle,hgap:0,vgap:0,tgap:0,bgap:0,lgap:0,rgap:0,items:[]})},render:function(){BI.TdLayout.superclass.render.apply(this,arguments),this.$table=BI.Widget._renderEngine.createElement("<table>").attr({cellspacing:0,cellpadding:0}).css({position:"relative",width:"100%",height:"100%","border-spacing":"0px",border:"none","border-collapse":"separate"}),this.rows=0,this.populate(this.options.items)},_addElement:function(e,t){var i=this.options;function n(e,t,i){0===t&&e.addClass("first-row"),0===i&&e.addClass("first-col"),e.addClass(BI.isOdd(t+1)?"odd-row":"even-row"),e.addClass(BI.isOdd(i+1)?"odd-col":"even-col"),e.addClass("center-element")}function r(e,t,i){var n="";0===t&&(n+=" first-row"),0===i&&(n+=" first-col"),BI.isOdd(t+1)?n+=" odd-row":n+=" even-row",BI.isOdd(i+1)?n+=" odd-col":n+=" even-col",e.cls=(e.cls||"")+n+" center-element"}for(var a,o,s,l=BI._lazyCreateWidget({type:"bi.default",tagName:"tr"}),u=0;u<t.length;u++){var c=BI._lazyCreateWidget(t[u]);c.element.css({position:"relative",top:"0",left:"0",margin:"0px auto"});var h=t[u];i.vgap+i.tgap+(h.tgap||0)+(h.vgap||0)!==0&&c.element.css({"margin-top":(i.vgap+i.tgap+(h.tgap||0)+(h.vgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.lgap+(h.lgap||0)+(h.hgap||0)!==0&&c.element.css({"margin-left":((0===u?i.hgap:0)+i.lgap+(h.lgap||0)+(h.hgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.rgap+(h.rgap||0)+(h.hgap||0)!==0&&c.element.css({"margin-right":(i.hgap+i.rgap+(h.rgap||0)+(h.hgap||0))/BI.pixRatio+BI.pixUnit}),i.vgap+i.bgap+(h.bgap||0)+(h.vgap||0)!==0&&c.element.css({"margin-bottom":(i.vgap+i.bgap+(h.bgap||0)+(h.vgap||0))/BI.pixRatio+BI.pixUnit}),a=c,o=this.rows++,s=u,a instanceof BI.Widget?n(a.element,o,s):a.el instanceof BI.Widget?n(a.el.element,o,s):a.el?r(a.el,o,s):r(a,o,s);var p=""===i.columnSize[u]?"":i.columnSize[u]<=1?(100*i.columnSize[u]).toFixed(1)+"%":(0===u?i.hgap:0)+i.hgap+i.lgap+i.rgap+i.columnSize[u],d=BI._lazyCreateWidget({type:"bi.default",width:p,tagName:"td",items:[c]});d.element.css({"max-width":!BI.isNumber(i.columnSize[u])||i.columnSize[u]<=1?p:p/BI.pixRatio+BI.pixUnit,position:"relative","vertical-align":i.verticalAlign,margin:"0",padding:"0",border:"none"}),l.addItem(d)}return this.addWidget(this._getChildName(e),l),l},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",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 i=this.options,n=BI.VerticalLayout.superclass._addElement.apply(this,arguments);return n.element.css({position:"relative"}),i.vgap+i.tgap+(t.tgap||0)+(t.vgap||0)!==0&&n.element.css({"margin-top":((0===e?i.vgap:0)+i.tgap+(t.tgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.lgap+(t.lgap||0)+(t.hgap||0)!==0&&n.element.css({"margin-left":(i.hgap+i.lgap+(t.lgap||0)+(t.hgap||0))/BI.pixRatio+BI.pixUnit}),i.hgap+i.rgap+(t.rgap||0)+(t.hgap||0)!==0&&n.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&&n.element.css({"margin-bottom":(i.vgap+i.bgap+(t.bgap||0)+(t.vgap||0))/BI.pixRatio+BI.pixUnit}),n},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,i){0===t&&e.addClass("first-row"),0===i&&e.addClass("first-col"),e.addClass(BI.isOdd(t+1)?"odd-row":"even-row"),e.addClass(BI.isOdd(i+1)?"odd-col":"even-col"),e.addClass("center-element")}function r(e,t,i){var n="";0===t&&(n+=" first-row"),0===i&&(n+=" first-col"),BI.isOdd(t+1)?n+=" odd-row":n+=" even-row",BI.isOdd(i+1)?n+=" odd-col":n+=" even-col",e.cls=(e.cls||"")+n+" center-element"}function i(e,t,i){e instanceof BI.Widget?n(e.element,t,i):e.el instanceof BI.Widget?n(e.el.element,t,i):e.el?r(e.el,t,i):r(e,t,i)}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");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={};u[s[0]=0]=0,l[t.columns-1]=0;for(a=c[t.rows-1]=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}),i(h,a,o)}if(!BI.isNumber(t.rowSize[a]))break}for(a=t.rows-1;0<=a;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}),i(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}),i(h,a,o)}if(!BI.isNumber(t.columnSize[o]))break}for(o=t.columns-1;0<=o;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}),i(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 t=this,n=this.options,r=[],i=n.items;return BI.each(i,function(e){r.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,t){var i;t&&((i=BI._lazyCreateWidget(t)).element.css({position:"absolute",left:(n.hgap+n.lgap)/BI.pixRatio+BI.pixUnit,right:(n.hgap+n.rgap)/BI.pixRatio+BI.pixUnit,top:(n.vgap+n.tgap)/BI.pixRatio+BI.pixUnit,bottom:(n.vgap+n.bgap)/BI.pixRatio+BI.pixUnit,width:"auto",height:"auto"}),r[e].el.addItem(i))}),{type:"bi.grid",ref:function(e){t.wrapper=e},columns:r.length,rows:1,items:r}},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 t=this,n=this.options,i=n.items,r=[],a=100/i.length;return BI.each(i,function(e){var t=BI._lazyCreateWidget({type:"bi.default"});t.element.addClass("center-element "+(0===e?"first-element ":"")+(e===i.length-1?"last-element":"")).css({width:a+"%",height:"100%"}),r.push({el:t})}),BI.each(i,function(e,t){var i;t&&((i=BI._lazyCreateWidget(t)).element.css({position:"absolute",left:(n.hgap+n.lgap)/BI.pixRatio+BI.pixUnit,right:(n.hgap+n.rgap)/BI.pixRatio+BI.pixUnit,top:(n.vgap+n.tgap)/BI.pixRatio+BI.pixUnit,bottom:(n.vgap+n.bgap)/BI.pixRatio+BI.pixUnit,width:"auto",height:"auto"}),r[e].el.addItem(i))}),{type:"bi.left",ref:function(e){t.wrapper=e},items:r}},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 t=this,n=this.options,i=n.items,r=[];return BI.each(i,function(e){r.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,t){var i;t&&((i=BI._lazyCreateWidget(t)).element.css({position:"absolute",left:(n.hgap+n.lgap)/BI.pixRatio+BI.pixUnit,right:(n.hgap+n.rgap)/BI.pixRatio+BI.pixUnit,top:(n.vgap+n.tgap)/BI.pixRatio+BI.pixUnit,bottom:(n.vgap+n.bgap)/BI.pixRatio+BI.pixUnit,width:"auto"}),r[e].el.addItem(i))}),{type:"bi.grid",ref:function(e){t.wrapper=e},columns:r.length,rows:1,items:r}},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 t=this,n=this.options,i=n.items,r=[];return BI.each(i,function(e){r.push({column:0,row:e,el:BI._lazyCreateWidget({type:"bi.default",cls:"center-element "+(0===e?"first-element ":"")+(e===i.length-1?"last-element":"")})})}),BI.each(i,function(e,t){var i;t&&((i=BI._lazyCreateWidget(t)).element.css({position:"absolute",left:(n.hgap+n.lgap)/BI.pixRatio+BI.pixUnit,right:(n.hgap+n.rgap)/BI.pixRatio+BI.pixUnit,top:(n.vgap+n.tgap)/BI.pixRatio+BI.pixUnit,bottom:(n.vgap+n.bgap)/BI.pixRatio+BI.pixUnit,height:"auto"}),r[e].el.addItem(i))}),{type:"bi.grid",ref:function(e){t.wrapper=e},columns:1,rows:r.length,items:r}},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.options;this._tipText||(this._tipText=BI.createWidget({type:"bi.label",cls:"bi-tips",text:e.tipText,height:25}),BI.createWidget({type:"bi.absolute_center_adapt",element:this,items:[this._tipText]}))},loading:function(){var e=this.options,t=BI.isIE(),i=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(i),element:BI.Layers.make(this.getName(),this)}),BI.Layers.show(this.getName())):BI.isNull(this._loading)&&(this._loading=i,this._loading.element.css("zIndex",1),BI.createWidget({type:"bi.center_adapt",element:this,cls:"loading-container",items:this._getLoadingTipItems(this._loading)})),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.options,i=[{type:"bi.horizontal_adapt",items:[e]}];return BI.isNotEmptyString(t.loadingText)&&i.push({type:"bi.text",text:t.loadingText,tgap:this._getSize(10)}),[{type:"bi.vertical",items:i}]},loaded:function(){var e=this.options;BI.Layers.remove(this.getName()),this._loading&&this._loading.destroy(),this._loading&&(this._loading=null),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()},empty:function(){}}),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]}),0<t.items.length&&(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=[],i=new BI.SectionManager,n=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();n=Math.max(n,s.y+s.height),r=Math.max(r,s.x+s.width),t[s.index=a]=s,i.registerCell(s,a)}this._cellMetadata=t,this._sectionManager=i,this._height=n,this._width=r},_cellRenderers:function(e,t,i,n){return this._lastRenderedCellIndices=this._sectionManager.getCellIndices(e,t,i,n),this._cellGroupRenderer()},_cellGroupRenderer:function(){var n=this,r=(this.options,[]);return BI.each(this._lastRenderedCellIndices,function(e,t){var i=n._sectionManager.getCellMetadata(t);r.push(i)}),r},_calculateChildrenToRender:function(){var i=this,e=this.options,t=BI.clamp(e.scrollLeft,0,this._getMaxScrollLeft()),n=BI.clamp(e.scrollTop,0,this._getMaxScrollTop()),r=Math.max(0,t-e.horizontalOverscanSize),a=Math.max(0,n-e.verticalOverscanSize),o=Math.min(this._width,t+e.width+e.horizontalOverscanSize),s=Math.min(this._height,n+e.height+e.verticalOverscanSize);if(0<o&&0<s){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);for(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)},f=0,g=l.length;f<g;f++){var T,C=l[f],N=this.renderedKeys[C.index]&&this.renderedKeys[C.index][1];0<=N?(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},e.items[C.index],{cls:(e.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(E,w),B[w]=Math.min(B[w],C.x),E[w]=Math.max(E[w],C.x+C.width)}for(var A=0|m[C.x],L=0|m[C.x+C.width],x=A;x<=L;x++){var k=p[x];y(_,k),v(b,k),_[k]=Math.min(_[k],C.y),b[k]=Math.max(b[k],C.y+C.height)}c[C.index]=[C.index,f],h[f]=T}var D={},P={},M=[];BI.each(c,function(e,t){i.renderedKeys[e]?D[e]=t:P[e]=t}),BI.each(this.renderedKeys,function(e,t){D[e]||P[e]||M.push(t[1])}),BI.each(M,function(e,t){i.renderedCells[t].el._destroy()});var R=[];BI.each(P,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(E),F=BI.max(_),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()),0<t.items.length){this.container.setWidth(this._width),this.container.setHeight(this._height),this._calculateChildrenToRender();try{this.element.scrollTop(t.scrollTop),this.element.scrollLeft(t.scrollLeft)}catch(i){}}},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 r;r={},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 n=this,t=this.options;this._initCombo(),this._initPullDownAction(),this.combo.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.isEnabled()&&n.isValid()&&(e===BI.Events.EXPAND&&n._popupView(),e===BI.Events.COLLAPSE&&n._hideView(),e===BI.Events.EXPAND&&(n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),n.fireEvent(BI.Combo.EVENT_EXPAND)),e===BI.Events.COLLAPSE&&(n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),n.isViewVisible()&&n.fireEvent(BI.Combo.EVENT_COLLAPSE)),e===BI.Events.CLICK&&n.fireEvent(BI.Combo.EVENT_TRIGGER_CHANGE,i))}),n.element.on("mouseenter."+n.getName(),function(e){n.isEnabled()&&n.isValid()&&n.combo.isEnabled()&&n.combo.isValid()&&n.element.addClass(t.hoverClass)}),n.element.on("mouseleave."+n.getName(),function(e){n.isEnabled()&&n.isValid()&&n.combo.isEnabled()&&n.combo.isValid()&&n.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 n=this,r=this.options,e=(this.options.trigger||"").split(","),a=function(e){r.stopEvent&&e.stopEvent(),r.stopPropagation&&e.stopPropagation()},o=!1;function s(e){n.isEnabled()&&n.isValid()&&n.combo.isEnabled()&&n.combo.isValid()&&!0===r.toggle&&(n._hideView(e),n.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.COLLAPSE,"",n.combo),n.fireEvent(BI.Combo.EVENT_COLLAPSE)),n.popupView&&n.popupView.element.off("mouseenter."+n.getName()).off("mouseleave."+n.getName()),o=!1}BI.each(e,function(e,t){switch(t){case"hover":n.element.on("mouseenter."+n.getName(),function(e){n.isEnabled()&&n.isValid()&&n.combo.isEnabled()&&n.combo.isValid()&&(n._popupView(e),n.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",n.combo),n.fireEvent(BI.Combo.EVENT_EXPAND))}),n.element.on("mouseleave."+n.getName(),function(e){n.popupView&&(n.popupView.element.on("mouseenter."+n.getName(),function(e){o=!0,n.popupView.element.on("mouseleave."+n.getName(),function(e){s(e)}),n.popupView.element.off("mouseenter."+n.getName())}),BI.defer(function(){o||s(e)},50))});break;case"click":var i=BI.debounce(function(e){n.combo.element.__isMouseInBounds__(e)&&n.isEnabled()&&n.isValid()&&n.combo.isEnabled()&&n.combo.isValid()&&(r.toggle?n._toggle(e):n._popupView(e),n.isViewVisible()?(n.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",n.combo),n.fireEvent(BI.Combo.EVENT_EXPAND)):(n.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.COLLAPSE,"",n.combo),n.fireEvent(BI.Combo.EVENT_COLLAPSE)))},BI.EVENT_RESPONSE_TIME,{leading:!0,trailing:!1});n.element.off(t+"."+n.getName()).on(t+"."+n.getName(),function(e){i(e),a(e)});break;case"click-hover":i=BI.debounce(function(e){n.combo.element.__isMouseInBounds__(e)&&n.isEnabled()&&n.isValid()&&n.combo.isEnabled()&&n.combo.isValid()&&(n._popupView(e),n.isViewVisible()&&(n.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",n.combo),n.fireEvent(BI.Combo.EVENT_EXPAND)))},BI.EVENT_RESPONSE_TIME,{leading:!0,trailing:!1});n.element.off("click."+n.getName()).on("click."+n.getName(),function(e){i(e),a(e)}),n.element.on("mouseleave."+n.getName(),function(e){n.popupView&&(n.popupView.element.on("mouseenter."+n.getName(),function(e){o=!0,n.popupView.element.on("mouseleave."+n.getName(),function(e){s(e)}),n.popupView.element.off("mouseenter."+n.getName())}),BI.delay(function(){o||s(e)},50))})}})},_initCombo:function(){this.combo=BI.createWidget(this.options.el,{value:this.options.value})},_assertPopupView:function(){var n=this,e=this.options;null==this.popupView&&(this.popupView=BI.createWidget(this.options.popup,{type:"bi.popup_view",value:e.value},this),this.popupView.on(BI.Controller.EVENT_CHANGE,function(e,t,i){e===BI.Events.CLICK&&(n.combo.setValue(n.getValue()),n.fireEvent(BI.Combo.EVENT_CHANGE,t,i)),n.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.popupView.setVisible(!1),BI.nextTick(function(){n.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&&0<this.element.find(e.target).length||this.popupView&&0<this.popupView.element.find(e.target).length||"CodeMirror-cursor"===e.target.className||0<BI.Widget._renderEngine.createElement(e.target).closest(".CodeMirror-hints").length)){var i=this.options.direction.split(",");(BI.contains(i,"innerLeft")||BI.contains(i,"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 r[this.getName()],BI.Widget._renderEngine.createElement(document).unbind("mousedown."+this.getName()).unbind("mousewheel."+this.getName()),this.fireEvent(BI.Combo.EVENT_AFTER_HIDEVIEW)},_popupView:function(i){var n=this;this._assertPopupViewRender(),this.fireEvent(BI.Combo.EVENT_BEFORE_POPUPVIEW),this.popupView.css({left:-999999999,top:-99999999}),this.popupView.visible(),BI.each(r,function(e,t){e!==n.getName()&&t&&!0===t._hideIf(i,!0)&&delete r[e]}),this.options.hideWhenAnotherComboOpen&&(r[this.getName()]=this),this.adjustWidth(i),this.adjustHeight(i),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,i,n=this.options;this.popupView&&!0===n.isNeedAdjustWidth&&(this.resetListWidth(""),t=this.popupView.element.outerWidth(),(i=this.element.outerWidth()||n.width)+80<t?i+=80:i<t&&(i=t),this.resetListWidth(i<100?100:i))},adjustHeight:function(e){var t=this.options,i={};if(this.popupView){var n=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":i=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":i=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":i=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":i=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset||t.adjustLength,t.adjustYOffset,t.isNeedAdjustHeight,["right","left","bottom","top"],t.offsetStyle);break;case"top,left":i=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset,t.adjustYOffset||t.adjustLength,t.isNeedAdjustHeight,["top","bottom","left","right"],t.offsetStyle);break;case"bottom,left":i=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset,t.adjustYOffset||t.adjustLength,t.isNeedAdjustHeight,["bottom","top","left","right"],t.offsetStyle);break;case"left,top":i=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset||t.adjustLength,t.adjustYOffset,t.isNeedAdjustHeight,["left","right","top","bottom"],t.offsetStyle);break;case"right,top":i=BI.DOM.getComboPosition(r,this.popupView,t.adjustXOffset||t.adjustLength,t.adjustYOffset,t.isNeedAdjustHeight,["right","left","top","bottom"],t.offsetStyle);break;case"right,innerRight":i=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":i=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":i=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":i=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":i=BI.DOM.getTopAdaptPosition(r,this.popupView,t.adjustYOffset||t.adjustLength,t.isNeedAdjustHeight);break;case"custom,bottom":case"bottom,custom":i=BI.DOM.getBottomAdaptPosition(r,this.popupView,t.adjustYOffset||t.adjustLength,t.isNeedAdjustHeight);break;case"left,custom":case"custom,left":delete(i=BI.DOM.getLeftAdaptPosition(r,this.popupView,t.adjustXOffset||t.adjustLength)).top,delete i.adaptHeight;break;case"custom,right":case"right,custom":delete(i=BI.DOM.getRightAdaptPosition(r,this.popupView,t.adjustXOffset||t.adjustLength)).top,delete i.adaptHeight}"adaptHeight"in i&&this.resetListHeight(i.adaptHeight),"left"in i&&this.popupView.element.css({left:i.left}),"top"in i&&this.popupView.element.css({top:i.top}),this.position=i,this.popupView.setVisible(n)}},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 r[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 n=this,e=this.options;this._expanded=!!e.el.open,this._initExpander(),this._initPullDownAction(),this.expander.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.isEnabled()&&n.isValid()&&(e===BI.Events.EXPAND&&n._popupView(),e===BI.Events.COLLAPSE&&n._hideView(),e===BI.Events.EXPAND&&(n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),n.fireEvent(BI.Expander.EVENT_EXPAND)),e===BI.Events.COLLAPSE&&(n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),n.isViewVisible()&&n.fireEvent(BI.Expander.EVENT_COLLAPSE)),e===BI.Events.CLICK&&n.fireEvent(BI.Expander.EVENT_TRIGGER_CHANGE,t,i))}),this.element.hover(function(){n.isEnabled()&&n.isValid()&&n.expander.isEnabled()&&n.expander.isValid()&&n.element.addClass(e.hoverClass)},function(){n.isEnabled()&&n.isValid()&&n.expander.isEnabled()&&n.expander.isValid()&&n.element.removeClass(e.hoverClass)}),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[{el:this.expander}]}),e.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 i=this,n=this.options,e=this.options.trigger.split(",");BI.each(e,function(e,t){switch(t){case"hover":i.element[t](function(e){i.isEnabled()&&i.isValid()&&i.expander.isEnabled()&&i.expander.isValid()&&(i._popupView(),i.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",i.expander),i.fireEvent(BI.Expander.EVENT_EXPAND))},function(){i.isEnabled()&&i.isValid()&&i.expander.isEnabled()&&i.expander.isValid()&&n.toggle&&(i._hideView(),i.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.COLLAPSE,"",i.expander),i.fireEvent(BI.Expander.EVENT_COLLAPSE))});break;case"click":t&&i.element.off(t+"."+i.getName()).on(t+"."+i.getName(),BI.debounce(function(e){i.expander.element.__isMouseInBounds__(e)&&i.isEnabled()&&i.isValid()&&i.expander.isEnabled()&&i.expander.isValid()&&(n.toggle?i._toggle():i._popupView(),i.isExpanded()?(i.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",i.expander),i.fireEvent(BI.Expander.EVENT_EXPAND)):(i.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.COLLAPSE,"",i.expander),i.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 n=this,e=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:e.value},this),this.popupView.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.Expander.EVENT_CHANGE,t,i)}),this.popupView.setVisible(this.isExpanded()),BI.nextTick(function(){n.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,i={};BI.each(e.behaviors,function(e,t){i[e]=BI.BehaviorFactory.createBehavior(e,{rule:t})}),this.behaviors=i,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 r=this,i=Array.prototype.slice.call(arguments),a=this.options,t=this._createBtns(e);return i[0]=t,BI.each(this.behaviors,function(e,t){t.doBehavior.apply(t,i)}),BI.each(t,function(e,n){n.on(BI.Controller.EVENT_CHANGE,function(e,t,i){if(e===BI.Events.CLICK){switch(a.chooseType){case BI.ButtonGroup.CHOOSE_TYPE_SINGLE:r.setValue(n.getValue());break;case BI.ButtonGroup.CHOOSE_TYPE_NONE:r.setValue([])}r.fireEvent(BI.Controller.EVENT_CHANGE,arguments),r.fireEvent(BI.ButtonGroup.EVENT_CHANGE,t,i)}else r.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),n.on(BI.Events.DESTROY,function(){BI.remove(r.buttons,n)})}),t},_packageBtns:function(e){for(var i=this.options,n=i.layouts.length-1;0<n;n--)e=BI.map(e,function(e,t){return BI.extend({},i.layouts[n],{items:[BI.extend({},i.layouts[n].el,{el:t})]})});return e},_packageSimpleItems:function(i){var e=this.options;return BI.map(e.items,function(e,t){return BI.stripEL(t)===t?i[e]:BI.extend({},t,{el:i[e]})})},_packageItems:function(e,t){return BI.createItems(BI.makeArrayByArray(e,{}),BI.clone(t))},_packageLayout:function(e){for(var t=this.options,i=BI.deepClone(t.layouts[0]),n=BI.formatEL(i).el;n&&n.items&&!BI.isEmpty(n.items);)n=BI.formatEL(n.items[0]).el;return n.items=e,i},_isSimpleLayout:function(){var e=this.options;return 1===e.layouts.length&&!BI.isArray(e.items[0])},doBehavior:function(){var i=Array.prototype.slice.call(arguments);i.unshift(this.buttons),BI.each(this.behaviors,function(e,t){t.doBehavior.apply(t,i)})},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(i){i=BI.isArray(i)?i:[i];var n=[];BI.each(this.buttons,function(e,t){BI.deepContains(i,t.getValue())&&n.push(e)}),BI.removeAt(this.buttons,n),this.layouts.removeItemAt(n)},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(i){i=BI.isArray(i)?i:[i],BI.each(this.buttons,function(e,t){BI.deepContains(i,t.getValue())?t.setSelected&&t.setSelected(!1):t.setSelected&&t.setSelected(!0)})},setEnabledValue:function(i){i=BI.isArray(i)?i:[i],BI.each(this.buttons,function(e,t){BI.deepContains(i,t.getValue())?t.setEnable(!0):t.setEnable(!1)})},setValue:function(i){i=BI.isArray(i)?i:[i],BI.each(this.buttons,function(e,t){BI.deepContains(i,t.getValue())?t.setSelected&&t.setSelected(!0):t.setSelected&&t.setSelected(!1)})},getNotSelectedValue:function(){var i=[];return BI.each(this.buttons,function(e,t){!t.isEnabled()||t.isSelected&&t.isSelected()||i.push(t.getValue())}),i},getValue:function(){var i=[];return BI.each(this.buttons,function(e,t){t.isEnabled()&&t.isSelected&&t.isSelected()&&i.push(t.getValue())}),i},getAllButtons:function(){return this.buttons},getAllLeaves:function(){return this.buttons},getSelectedButtons:function(){var i=[];return BI.each(this.buttons,function(e,t){t.isSelected&&t.isSelected()&&i.push(t)}),i},getNotSelectedButtons:function(){var i=[];return BI.each(this.buttons,function(e,t){t.isSelected&&!t.isSelected()&&i.push(t)}),i},getIndexByValue:function(i){var n=-1;return BI.any(this.buttons,function(e,t){if(t.isEnabled()&&t.getValue()===i)return n=e,!0}),n},getNodeById:function(i){var n;return BI.any(this.buttons,function(e,t){if(t.isEnabled()&&t.options.id===i)return n=t,!0}),n},getNodeByValue:function(i){var n;return BI.any(this.buttons,function(e,t){if(t.isEnabled()&&t.getValue()===i)return n=t,!0}),n},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 n=this,r=this.options,t=r.children;if(BI.isEmpty(t))throw new Error("ComboGroup构造错误");BI.each(t,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=r.action,t.height=r.height,t.direction=r.direction,t.isDefaultInit=r.isDefaultInit,t.isNeedAdjustHeight=r.isNeedAdjustHeight,t.isNeedAdjustWidth=r.isNeedAdjustWidth,t.adjustLength=r.adjustLength,t.popup=r.popup)}),this.combo=BI.createWidget({type:"bi.combo",element:this,container:r.container,height:r.height,trigger:r.trigger,direction:r.direction,isDefaultInit:r.isDefaultInit,isNeedAdjustWidth:r.isNeedAdjustWidth,isNeedAdjustHeight:r.isNeedAdjustHeight,adjustLength:r.adjustLength,el:e,popup:BI.extend({},r.popup,{el:BI.extend({items:t},r.popup.el)})}),this.combo.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.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 n=this.options,r=this.buttonMap={},a=n.layouts.length-1;0<a;a--)e=BI.map(e,function(e,t){var i=BI.stripEL(t);return BI.extend({},n.layouts[a],{items:[BI.extend({},n.layouts[a].el,{el:BI.extend({ref:function(e){BI.isKey(r[i.value])&&(r[i.value]=e)}},i)})]})});return e},_packageLayout:function(e){for(var t=this.options,i=BI.deepClone(t.layouts[0]),n=BI.formatEL(i).el;n&&n.items&&!BI.isEmpty(n.items);)n=BI.formatEL(n.items[0]).el;return n.items=e,i},addItems:function(e){this.layouts.addItems(e)},prependItems:function(e){this.layouts.prependItems(e)},setValue:function(i){i=BI.isArray(i)?i:[i],BI.each(this.buttonMap,function(e,t){t&&(i.deepContains(e)?t.setSelected&&t.setSelected(!0):t.setSelected&&t.setSelected(!1))})},getNotSelectedValue:function(){var i=[];return BI.each(this.buttonMap,function(e,t){t&&(!t.isEnabled()||t.isSelected&&t.isSelected()||i.push(t.getValue()))}),i},getValue:function(){var i=[];return BI.each(this.buttonMap,function(e,t){t&&t.isEnabled()&&t.isSelected&&t.isSelected()&&i.push(t.getValue())}),i},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 n=this,e=this.options;!1===e.itemsCreator&&(e.prev=!1,e.next=!1),!1!==e.prev&&(this.prev=BI.createWidget(BI.extend({type:"bi.loading_bar"},e.prev)),this.prev.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&n._prevLoad()})),this.button_group=BI.createWidget(e.el,{type:"bi.button_group",chooseType:0,items:e.items,behaviors:{},layouts:[{type:"bi.vertical"}],value:e.value}),this.button_group.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.Loader.EVENT_CHANGE,i)}),!1!==e.next&&(this.next=BI.createWidget(BI.extend({type:"bi.loading_bar"},e.next)),this.next.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&n._nextLoad()})),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(e.direction),BI.extend({scrolly:!0},e.logic,{items:BI.LogicFactory.createLogicItemsByDirection(e.direction,this.prev,this.button_group,this.next)})))),e.isDefaultInit&&BI.isEmpty(e.items)&&BI.nextTick(BI.bind(function(){e.isDefaultInit&&BI.isEmpty(e.items)&&this._populate()},this)),BI.isNotEmptyArray(e.items)&&this._populate(e.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,i=this.options;return 0===arguments.length&&BI.isFunction(i.itemsCreator)?(i.itemsCreator.apply(this,[{times:1},function(){if(0===arguments.length)throw new Error("arguments can not be null!!!");t.populate.apply(t,arguments),i.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 i=this,n=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(n.direction),BI.extend({},n.logic,{items:BI.LogicFactory.createLogicItemsByDirection(n.direction,this.tab,this.layout)})))),new BI.ShowListener({eventObj:this.tab,cardLayout:this.layout,cardNameCreator:function(e){return i.showIndex+e},cardCreator:function(e){var t=n.cardCreator(e);return i.cardMap[e]=t},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(i){var n=this;!0===this.options.single&&BI.each(this.cardMap,function(e,t){e!==i+""&&(n.layout.deleteCardByName(e),delete n.cardMap[e])})},afterCardCreated:function(e){var n=this;this.cardMap[e].on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.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){var t;this.layout.isCardExisted(e)||(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 t=this,e=this.options;this.editor=BI.createWidget(e.el,{type:"bi.search_editor"}),BI.createWidget({type:"bi.vertical",element:this,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,vgap:e.vgap,hgap:e.hgap,items:[this.editor]}),e.isDefaultInit&&this._assertPopupView();var i=BI.debounce(BI.bind(this._search,this),BI.EVENT_RESPONSE_TIME,{leading:!0,trailing:!1});this.editor.on(BI.Controller.EVENT_CHANGE,function(e){switch(e){case BI.Events.STARTEDIT:t._startSearch();break;case BI.Events.EMPTY:t._stopSearch();break;case BI.Events.CHANGE:i();break;case BI.Events.PAUSE:BI.endWith(this.getValue(),BI.BlankSplitChar)&&t._pauseSearch()}})},_assertPopupView:function(){var r=this,a=this.options;(a.masker&&!BI.Maskers.has(this.getName())||!1===a.masker&&!this.popupView)&&(this.popupView=BI.createWidget(a.popup,{type:"bi.searcher_view",chooseType:a.chooseType}),this.popupView.on(BI.Controller.EVENT_CHANGE,function(e,t,i){if(r.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK){if(a.isAutoSync){var n=a.adapter&&a.adapter.getValue();switch(a.chooseType){case BI.ButtonGroup.CHOOSE_TYPE_SINGLE:a.adapter&&a.adapter.setValue([i.getValue()]);break;case BI.ButtonGroup.CHOOSE_TYPE_MULTI:i.isSelected()||a.adapter&&a.adapter.setValue(BI.deepWithout(n,i.getValue())),n.push(i.getValue()),a.adapter&&a.adapter.setValue(n)}}r.fireEvent(BI.Searcher.EVENT_CHANGE,t,i)}}),BI.nextTick(function(){r.fireEvent(BI.Searcher.EVENT_AFTER_INIT)})),a.masker&&!BI.Maskers.has(this.getName())&&BI.Maskers.create(this.getName(),a.adapter,BI.extend({container:this,render:this.popupView},a.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 n=this,r=this.options,a=this.editor.getValue();if(""!==a&&!this._stop){if(r.isAutoSearch){var e=r.adapter&&(r.adapter.getItems&&r.adapter.getItems()||r.adapter.attr("items"))||[],t=BI.Func.getSearchResult(e,a),i=t.match,o=t.find;return this.popupView.populate(o,i,a),r.isAutoSync&&r.adapter&&r.adapter.getValue&&this.popupView.setValue(r.adapter.getValue()),void n.fireEvent(BI.Searcher.EVENT_SEARCHING)}this.popupView.loading&&this.popupView.loading(),r.onSearch({times:1,keyword:a,selectedValues:r.adapter&&r.adapter.getValue()},function(e,t){var i;n._stop||(0<(i=[].slice.call(arguments)).length&&i.push(a),BI.Maskers.show(n.getName()),n.popupView.populate.apply(n.popupView,i),r.isAutoSync&&r.adapter&&r.adapter.getValue&&n.popupView.setValue(r.adapter.getValue()),n.popupView.loaded&&n.popupView.loaded(),n.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,i){var n=this.options;this._assertPopupView(),this.popupView.populate.apply(this.popupView,arguments),n.isAutoSync&&n.adapter&&n.adapter.getValue&&this.popupView.setValue(n.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 n=this,e=this.options;this._initSwitcher(),this._initPullDownAction(),this.switcher.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.isEnabled()&&n.isValid()&&(e===BI.Events.EXPAND&&n._popupView(),e===BI.Events.COLLAPSE&&n._hideView(),e===BI.Events.EXPAND&&(n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),n.fireEvent(BI.Switcher.EVENT_EXPAND)),e===BI.Events.COLLAPSE&&(n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),n.isViewVisible()&&n.fireEvent(BI.Switcher.EVENT_COLLAPSE)),e===BI.Events.CLICK&&n.fireEvent(BI.Switcher.EVENT_TRIGGER_CHANGE,t,i))}),this.element.hover(function(){n.isEnabled()&&n.switcher.isEnabled()&&n.element.addClass(e.hoverClass)},function(){n.isEnabled()&&n.switcher.isEnabled()&&n.element.removeClass(e.hoverClass)}),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[{el:this.switcher}]}),e.isDefaultInit&&this._assertPopupView()},_toggle:function(){this._assertPopupView(),this.isExpanded()?this._hideView():this.isEnabled()&&this._popupView()},_initPullDownAction:function(){var i=this,n=this.options,e=this.options.trigger.split(",");BI.each(e,function(e,t){switch(t){case"hover":i.element[t](function(e){i.isEnabled()&&i.switcher.isEnabled()&&(i._popupView(),i.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",i.switcher),i.fireEvent(BI.Switcher.EVENT_EXPAND))},function(){i.isEnabled()&&i.switcher.isEnabled()&&n.toggle&&(i._hideView(),i.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.COLLAPSE,"",i.switcher),i.fireEvent(BI.Switcher.EVENT_COLLAPSE))});break;default:t&&i.element.off(t+"."+i.getName()).on(t+"."+i.getName(),BI.debounce(function(e){i.switcher.element.__isMouseInBounds__(e)&&i.isEnabled()&&i.switcher.isEnabled()&&(n.toggle?i._toggle():i._popupView(),i.isExpanded()?(i.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.EXPAND,"",i.switcher),i.fireEvent(BI.Switcher.EVENT_EXPAND)):(i.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.COLLAPSE,"",i.switcher),i.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 n=this,e=this.options;this._created||(this.popupView=BI.createWidget(e.popup,{type:"bi.button_group",element:e.adapter&&BI.Maskers.create(this.getName(),e.adapter,BI.extend({container:this},e.masker)),cls:"switcher-popup",layouts:[{type:"bi.vertical",hgap:0,vgap:0}],value:e.value},this),this.popupView.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.Switcher.EVENT_CHANGE,t,i)}),e.direction===BI.Direction.Custom||e.adapter||BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[{el:this.popupView}]}),this._created=!0,BI.nextTick(function(){n.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 t=this,i=this.options;this._assertPopupView(),this.fireEvent(BI.Switcher.EVENT_BEFORE_POPUPVIEW),i.adapter?BI.Maskers.show(this.getName()):t.popupView.setVisible(!0),BI.nextTick(function(e){i.adapter?BI.Maskers.show(e):t.popupView.setVisible(!0),t.element.addClass(i.switcherClass),t.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 n=this,i=this.options;BI.isObject(i.tab)&&(this.tab=BI.createWidget(this.options.tab,{type:"bi.button_group"}),this.tab.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.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(i.direction),BI.extend({},i.logic,{items:BI.LogicFactory.createLogicItemsByDirection(i.direction,this.tab,this.layout)})))),new BI.ShowListener({eventObj:this.tab,cardLayout:this.layout,cardCreator:function(e){var t=i.cardCreator.apply(n,arguments);return n.cardMap[e]=t},afterCardShow:function(e){n._deleteOtherCards(e),n.curr=e}}).on(BI.ShowListener.EVENT_CHANGE,function(e){n.fireEvent(BI.Tab.EVENT_CHANGE,e,n)})},_deleteOtherCards:function(i){var n=this;!0===this.options.single&&BI.each(this.cardMap,function(e,t){e!==i+""&&(n.layout.deleteCardByName(e),delete n.cardMap[e])})},_assertCard:function(e){var t;this.layout.isCardExisted(e)||(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,i){this.tab&&this.tab.setValue(e),this._assertCard(e),this.layout.showCardByName(e,t,i),this._deleteOtherCards(e),this.curr!==e&&(this.curr=e)},removeTab:function(i){var n=this;this.options;BI.any(this.cardMap,function(e,t){if(BI.isEqual(e,i+""))return n.layout.deleteCardByName(e),delete n.cardMap[e],!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(i){i=BI.isArray(i)?i:[i],BI.each(this.buttons,function(e,t){BI.isFunction(t.setSelected)?BI.deepContains(i,t.getValue())?t.setSelected(!1):t.setSelected(!0):t.setNotSelectedValue(i)})},setEnabledValue:function(i){i=BI.isArray(i)?i:[i],BI.each(this.buttons,function(e,t){BI.isFunction(t.setEnabledValue)?t.setEnabledValue(i):BI.deepContains(i,t.getValue())?t.setEnable(!0):t.setEnable(!1)})},setValue:function(i){i=BI.isArray(i)?i:[i],BI.each(this.buttons,function(e,t){BI.isFunction(t.setSelected)?BI.deepContains(i,t.getValue())?t.setSelected(!0):t.setSelected(!1):t.setValue(i)})},getNotSelectedValue:function(){var i=[];return BI.each(this.buttons,function(e,t){!t.isEnabled()||BI.isFunction(t.setSelected)?t.isEnabled()&&t.isSelected&&!t.isSelected()&&i.push(t.getValue()):i=BI.concat(i,t.getNotSelectedValue())}),i},getValue:function(){var i=[];return BI.each(this.buttons,function(e,t){!t.isEnabled()||BI.isFunction(t.setSelected)?t.isEnabled()&&t.isSelected&&t.isSelected()&&i.push(t.getValue()):i=BI.concat(i,t.getValue())}),i},getSelectedButtons:function(){var i=[];return BI.each(this.buttons,function(e,t){!t.isEnabled()||BI.isFunction(t.setSelected)?t.isSelected&&t.isSelected()&&i.push(t):i=i.concat(t.getSelectedButtons())}),i},getNotSelectedButtons:function(){var i=[];return BI.each(this.buttons,function(e,t){!t.isEnabled()||BI.isFunction(t.setSelected)?t.isSelected&&!t.isSelected()&&i.push(t):i=i.concat(t.getNotSelectedButtons())}),i},getAllLeaves:function(){var i=[];return BI.each(this.buttons,function(e,t){!t.isEnabled()||BI.isFunction(t.setSelected)?t.isEnabled()&&i.push(t):i=i.concat(t.getAllLeaves())}),i},getIndexByValue:function(n){var r=-1;return BI.any(this.buttons,function(e,t){var i=t.getValue();if(t.isEnabled()&&(i===n||BI.contains(i,n)))return r=e,!0}),r},getNodeById:function(i){var n;return BI.any(this.buttons,function(e,t){if(t.isEnabled()){if(t.attr("id")===i)return n=t,!0;if(BI.isFunction(t.getNodeById)&&(n=t.getNodeById(i)))return!0}}),n},getNodeByValue:function(i){var n;return BI.any(this.buttons,function(e,t){if(t.isEnabled())if(BI.isFunction(t.getNodeByValue)){if(n=t.getNodeByValue(i))return!0}else if(t.attr("value")===i)return n=t,!0}),n}}),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 s,l,u,c;BI.Msg=(u=[],c=[],{alert:function(e,t,i){this._show(!1,e,t,i)},confirm:function(e,t,i){this._show(!0,e,t,i)},prompt:function(e,t,i,n,r){},toast:function(e,t,i){t=t||{},i=i||BI.Widget._renderEngine.createElement("body");var n=t.level||"common",r=!!BI.isNull(t.autoClose)||t.autoClose,a=BI.isFunction(t.callback)?t.callback:BI.emptyFn,o=BI.createWidget({type:"bi.toast",cls:"bi-message-animate bi-message-leave",level:n,autoClose:r,text:e,listeners:[{eventName:BI.Toast.EVENT_DESTORY,action:function(){BI.remove(c,o.element);var i=10;BI.each(c,function(e,t){t.css({top:i}),i+=t.outerHeight()+10}),a()}}]}),s=10;BI.each(c,function(e,t){s+=t.outerHeight()+10}),BI.createWidget({type:"bi.absolute",element:i,items:[{el:o,left:"50%",top:s}]}),c.push(o.element),o.element.css({"margin-left":-1*o.element.outerWidth()/2}),o.element.removeClass("bi-message-leave").addClass("bi-message-enter"),r&&BI.delay(function(){o.element.removeClass("bi-message-enter").addClass("bi-message-leave"),o.destroy()},5e3)},_show:function(e,t,i,n){BI.isNull(s)&&(s=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")),l=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 r=function(){u[u.length-1].destroy(),u.pop(),0===u.length&&(s.remove(),s=null)},a=[];!0===e&&a.push({el:{type:"bi.button",text:BI.i18nText("BI-Basic_Cancel"),level:"ignore",handler:function(){r(),BI.isFunction(n)&&n.apply(null,[!1])}}}),a.push({el:{type:"bi.button",text:BI.i18nText("BI-Basic_OK"),handler:function(){r(),BI.isFunction(n)&&n.apply(null,[!0])}}});var o={element:l,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(){r(),BI.isFunction(n)&&n.apply(null,[!1])}},width:60}}},height:40},center:{el:{type:"bi.label",vgap:10,hgap:20,whiteSpace:"normal",text:i}},south:{el:{type:"bi.absolute",items:[{el:{type:"bi.right_vertical_adapt",lgap:10,items:a},top:0,left:20,right:20,bottom:0}]},height:44}},width:450,height:200}]};u[u.length]=BI.createWidget(o)}})},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]}),0<t.items.length&&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,i,n){return{overscanStartIndex:Math.max(0,i-t),overscanStopIndex:Math.min(e-1,n+t)}},_calculateChildrenToRender:function(){var i=this,e=this.options,t=e.width,n=e.height,r=BI.clamp(e.scrollLeft,0,this._getMaxScrollLeft()),a=BI.clamp(e.scrollTop,0,this._getMaxScrollTop()),o=e.overscanColumnCount,s=e.overscanRowCount;if(0<n&&0<t){var l=this._columnSizeAndPositionManager.getVisibleCellRange(t,r),u=this._rowSizeAndPositionManager.getVisibleCellRange(n,a);if(BI.isEmpty(l)||BI.isEmpty(u))return;var c=this._columnSizeAndPositionManager.getOffsetAdjustment(t,r),h=this._rowSizeAndPositionManager.getOffsetAdjustment(n,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),E=this._columnSizeAndPositionManager.getSizeAndPositionOfCell(f),_=this._rowSizeAndPositionManager.getSizeAndPositionOfCell(I),b=this._columnSizeAndPositionManager.getSizeAndPositionOfCell(g),y=B.offset+h,v=E.offset+c,T=_.offset+h+_.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 P=this._rowSizeAndPositionManager.getSizeAndPositionOfCell(D),M=f;M<=g;M++){var R,H=D+"-"+M,O=this._columnSizeAndPositionManager.getSizeAndPositionOfCell(M),F=this.renderedKeys[H]&&this.renderedKeys[H][2];0<=F?(O.size!==this.renderedCells[F]._width&&(this.renderedCells[F]._width=O.size,this.renderedCells[F].el.setWidth(O.size)),P.size!==this.renderedCells[F]._height&&(this.renderedCells[F]._height=P.size,this.renderedCells[F].el.setHeight(P.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!==P.offset+h&&this.renderedCells[F].el.element.css("top",(P.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:P.size},e.items[D][M],{cls:(e.items[D][M].cls||"")+" grid-cell"+(0===D?" first-row":"")+(0===M?" first-col":""),_rowIndex:D,_columnIndex:M,_left:O.offset+c,_top:P.offset+h}),this),N.push({el:R,left:O.offset+c,top:P.offset+h,_left:O.offset+c,_top:P.offset+h,_width:O.size,_height:P.size})),x=Math.min(x,O.offset+c),A=Math.max(A,O.offset+c+O.size),w=Math.min(w,P.offset+h),L=Math.max(L,P.offset+h+P.size),V[H]=[D,M,k],S[k]=R,k++}var Y={},W={},G=[];BI.each(V,function(e,t){i.renderedKeys[e]?Y[e]=t:W[e]=t}),BI.each(this.renderedKeys,function(e,t){Y[e]||W[e]||G.push(t[2])}),BI.each(G,function(e,t){i.renderedCells[t].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 t=this.options,i=0;return BI.count(0,this.columnCount,function(e){i+=t.columnWidthGetter(e)}),Math.max(0,i-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:0<t.items.length&&(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(i){}},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 r=this,e=this.options,t=this._constant;this.startX=0,this.startY=0;var i=this._calculateSize();this.tracker=new BI.MouseMoveTracker(function(e,t){var i=BI.Widget._renderEngine.createElement("body").width(),n=BI.Widget._renderEngine.createElement("body").height();r.startX+=e,r.startY+=t,r.element.css({left:BI.clamp(r.startX,0,i-r.element.width())+"px",top:BI.clamp(r.startY,0,n-r.element.height())+"px"}),BI.Resizers._resize({target:r.element[0]})},function(){r.tracker.releaseMouseMoves()},_global);var n=[{el:{type:"bi.htape",cls:"bi-message-title bi-header-background",ref:function(e){r.dragger=e},items:[{type:"bi.absolute",items:[{el:BI.isPlainObject(e.header)?BI.extend({},e.header,{extraCls:"bi-font-bold"}):{type:"bi.label",cls:"bi-font-bold",height:e.headerHeight,text:e.header,title:e.header,textAlign:"left"},left:20,top:0,right:0,bottom:0}]},{el:e.closable?{type:"bi.icon_button",cls:"bi-message-close close-font",height:e.headerHeight,handler:function(){r.close()}}:{type:"bi.layout"},width:56}],height:e.headerHeight},height:e.headerHeight},e.logic.dynamic?{el:{type:"bi.vertical",scrolly:!0,cls:"popover-body",ref:function(){r.body=this},css:{"max-height":this._getSuitableBodyHeight(t.MAX_HEIGHT-e.headerHeight-(e.footer?e.footerHeight:0)-e.bodyTgap),"min-height":this._getSuitableBodyHeight(i.height-e.headerHeight-(e.footer?e.footerHeight:0)-e.bodyTgap)},items:[{el:e.body}]},hgap:e.bodyHgap,tgap:e.bodyTgap}:{el:{type:"bi.absolute",items:[{el:e.body,left:e.bodyHgap,top:e.bodyTgap,right:e.bodyHgap,bottom:0}]}}];return e.footer&&n.push({el:{type:"bi.absolute",items:[{el:e.footer,left:20,top:0,right:20,bottom:0}],height:e.footerHeight},height:e.footerHeight}),BI.extend({type:e.logic.dynamic?"bi.vertical":"bi.vtape",items:n,width:this._getSuitableWidth(i.width)},e.logic.dynamic?{type:"bi.vertical",scrolly:!1}:{type:"bi.vtape",height:this._getSuitableHeight(i.height)})},mounted:function(){var i=this;this.options;this.dragger.element.mousedown(function(e){var t=i.element.offset();i.startX=t.left,i.startY=t.top,i.tracker.captureMouseMoves(e)})},_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 t=this,e=this.options;e.footer||(e.footer={type:"bi.right_vertical_adapt",lgap:10,items:[{type:"bi.button",text:this.options.btns[1],value:1,level:"ignore",handler:function(e){t.fireEvent(BI.Popover.EVENT_CANCEL,e),t.close(e)}},{type:"bi.button",text:this.options.btns[0],warningTitle:e.warningTitle,value:0,handler:function(e){t.fireEvent(BI.Popover.EVENT_CONFIRM,e),t.close(e)}}]})}}),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 t=this,e=this.options,i=function(e){e.stopPropagation()},n=function(e){return e.stopEvent(),!1};this.element.css({"z-index":BI.zIndex_popup,"min-width":BI.isNumeric(e.minWidth)?e.minWidth/BI.pixRatio+BI.pixUnit:e.minWidth,"max-width":BI.isNumeric(e.maxWidth)?e.maxWidth/BI.pixRatio+BI.pixUnit:e.maxWidth}).bind({click:i}),this.element.bind("mousewheel",i),e.stopPropagation&&this.element.bind({mousedown:i,mouseup:i,mouseover:i}),e.stopEvent&&this.element.bind({mousedown:n,mouseup:n,mouseover:n}),this.tool=this._createTool(),this.tab=this._createTab(),this.view=this._createView(),this.toolbar=this._createToolBar(),this.view.on(BI.Controller.EVENT_CHANGE,function(e){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&t.fireEvent(BI.PopupView.EVENT_CHANGE)}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(e.direction),BI.extend({},e.logic,{scrolly:!1,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,vgap:e.vgap,hgap:e.hgap,items:BI.LogicFactory.createLogicItemsByDirection(e.direction,BI.extend({cls:"list-view-outer bi-card list-view-shadow"},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(e.direction),BI.extend({},e.logic,{items:BI.LogicFactory.createLogicItemsByDirection(e.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 n=this,e=this.options;this.matcher=BI.createWidget(e.matcher,{type:"bi.button_group",chooseType:e.chooseType,behaviors:{redmark:function(){return!0}},layouts:[{type:"bi.vertical"}],value:e.value}),this.matcher.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.SearcherView.EVENT_CHANGE,t,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(e.searcher,{type:"bi.button_group",chooseType:e.chooseType,behaviors:{redmark:function(){return!0}},layouts:[{type:"bi.vertical"}],value:e.value}),this.searcher.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.SearcherView.EVENT_CHANGE,t,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,i){e=e||[],t=t||[],this.setTipVisible(e.length+t.length===0),this.spliter.setVisible(BI.isNotEmptyArray(t)&&BI.isNotEmptyArray(e)),this.matcher.populate(t,i),this.searcher.populate(e,i)},empty:function(){this.searcher.empty(),this.matcher.empty()},hasMatched:function(){return 0<this.matcher.getAllButtons().length}}),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 i=this,t=this.options;this._populate(),this.element.scroll(function(e){t.scrollTop=i.element.scrollTop(),i._calculateBlocksToRender()});var n=this.element.width(),r=this.element.height();BI.ResizeDetector.addResizeListener(this,function(){var e=i.element.width(),t=i.element.height();e===n&&t===r||(n=e,r=t,i._calculateBlocksToRender())})},_renderMoreIf:function(){for(var e,t=this,i=this.options,n=this.element.height(),r=i.scrollTop+n+i.overscanHeight,a=this.cache[this.renderedIndex]&&this.cache[this.renderedIndex].index+i.blockSize||0,o=this.renderedIndex+1,s=function(){return t.container.element.height()};(e=s())<r&&a<i.items.length;){var l=i.items.slice(a,a+i.blockSize);this.container.addItems(l,this);var u=s()-e;this.cache[o]={index:a,scrollTop:e,height:u},this.renderedIndex=o,o++,a+=i.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 t=this,i=this.options;this._populate(),this.element.scroll(function(e){i.scrollTop=t.element.scrollTop(),t._calculateBlocksToRender()}),BI.ResizeDetector.addResizeListener(this,function(){t._calculateBlocksToRender()})},_renderMoreIf:function(){for(var e,t=this,i=this.options,n=this.element.height(),r=i.scrollTop+n+i.overscanHeight,a=this.cache[this.renderedIndex]&&this.cache[this.renderedIndex].index+i.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<i.items.length;){var l=i.items.slice(a,a+i.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+=i.blockSize}},_calculateBlocksToRender:function(){var e=this.options;this._renderMoreIf();for(var t=this.element.height(),i=e.scrollTop-e.overscanHeight,n=e.scrollTop+t+e.overscanHeight,r=this.tree.greatestLowerBound(i),a=this.tree.leastUpperBound(n),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}}for(var c=BI.Widget._renderEngine.createFragment(),h=BI.Widget._renderEngine.createFragment(),p=c,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(i){}},_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 r=this,a=this.options,e=[],t={};this.empty();var i,o=BI.result(a,"pages"),n=BI.result(this,"currPage"),s=BI.result(a,"groups"),l=BI.result(a,"first"),u=BI.result(a,"last"),c=BI.result(a,"prev"),h=BI.result(a,"next");!1===o?(s=0,u=l=!1):o<s&&(s=o),t.index=Math.ceil((n+(1<s&&s!==o?1:0))/(0===s?1:s)),(!a.dynamicShow&&!a.dynamicShowPrevNext||1<n)&&!1!==c&&(BI.isKey(c)?e.push({text:c,value:"prev",disabled:!1===o?!1===a.hasPrev(n):!(1<n&&!1!==c)}):e.push(BI.extend({disabled:!1===o?!1===a.hasPrev(n):!(1<n&&!1!==c)},c))),(!a.dynamicShow&&!a.dynamicShowFirstLast||1<t.index&&0!==s)&&l&&(e.push({text:l,value:"first",disabled:!(1<t.index&&0!==s)}),1<t.index&&0!==s&&e.push({type:"bi.label",cls:"page-ellipsis",text:"…"})),t.poor=Math.floor((s-1)/2),t.start=1<t.index?n-t.poor:1,t.end=1<t.index?(i=n+(s-t.poor-1),o<i?o:i):s,t.end-t.start<s-1&&(t.start=t.end-s+1);var p=t.start,d=t.end;for(l&&u&&1<t.index&&0!==s&&s<o&&t.end<o&&0!==s&&(p++,d--);p<=d;p++)p===n?e.push({text:p,value:p,selected:!0}):e.push({text:p,value:p});(!a.dynamicShow&&!a.dynamicShowFirstLast||s<o&&t.end<o&&0!==s)&&u&&(s<o&&t.end<o&&0!==s&&e.push({type:"bi.label",cls:"page-ellipsis",text:"…"}),e.push({text:u,value:"last",disabled:!(s<o&&t.end<o&&0!==s)})),t.flow=!c&&0===s,(!a.dynamicShow&&!a.dynamicShowPrevNext&&h||n!==o&&h||t.flow)&&e.push(BI.isKey(h)?!1===o?{text:h,value:"next",disabled:!1===a.hasNext(n)}:t.flow&&n===o?{text:h,value:"next",disabled:!0}:{text:h,value:"next",disabled:!(n!==o&&h||t.flow)}:BI.extend({disabled:!1===o?!1===a.hasNext(n):!(n!==o&&h||t.flow)},h)),this.button_group=BI.createWidget({type:"bi.button_group",element:this,items:BI.createItems(e,{cls:"bi-list-item-select bi-border-radius",height:23,hgap:10,stopPropagation:!0}),behaviors:a.behaviors,layouts:a.layouts}),this.button_group.on(BI.Controller.EVENT_CHANGE,function(e,t,i){if(e===BI.Events.CLICK){var n=r.button_group.getValue()[0];switch(n){case"first":r.currPage=1;break;case"last":r.currPage=o;break;case"prev":r.currPage--;break;case"next":r.currPage++;break;default:r.currPage=n}a.jump.apply(r,[{pages:o,curr:r.currPage}]),r._populate(),r.fireEvent(BI.Pager.EVENT_CHANGE,i)}r.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):1<e},hasNext:function(e){e=e||1;var t=this.options,i=this.options.pages;return!1===i?t.hasNext(e):e<i},setValue:function(e){var t,i,n=this.options;e=(e=e||0)<1?1:e,!1===n.pages?(t=BI.result(n,"lastPage"),i=1,this.currPage=t<e?t:e<(i=BI.result(n,"firstPage"))?i:e):(e=e>n.pages?n.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 i=this.options,n=this.getTipType()||(this.isEnabled()?"success":"warning"),r="success"!==n&&this.getWarningTitle()||this.getTitle();BI.isKey(r)&&(BI.Tooltips.show(e,this.getName(),r,n,this,t),i.action&&BI.Actions.runAction(i.action,"hover",i,this),BI.Actions.runGlobalAction("hover",i,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(t){t=t||{};var i=this;this._hoverBinded||(this.element.on("mouseenter.title"+this.getName(),function(e){i._e=e,"warning"===i.getTipType()||BI.isKey(i.getWarningTitle())&&!i.isEnabled()?i.showTimeout=BI.delay(function(){BI.isNotNull(i.showTimeout)&&i._showToolTip(i._e||e,t)},200):"success"!==i.getTipType()&&!i.isEnabled()||(i.showTimeout=BI.delay(function(){BI.isNotNull(i.showTimeout)&&i._showToolTip(i._e||e,t)},500))}),this.element.on("mousemove.title"+this.getName(),function(e){i._e=e,BI.isNotNull(i.showTimeout)&&(clearTimeout(i.showTimeout),i.showTimeout=null),BI.isNull(i.hideTimeout)&&(i.hideTimeout=BI.delay(function(){BI.isNotNull(i.hideTimeout)&&i._hideTooltip()},500)),i.showTimeout=BI.delay(function(){BI.isNotNull(i.showTimeout)&&(BI.isNotNull(i.hideTimeout)&&(clearTimeout(i.hideTimeout),i.hideTimeout=null),i.element.__isMouseInBounds__(i._e||e)&&i._showToolTip(i._e||e,t))},500)}),this.element.on("mouseleave.title"+this.getName(),function(e){i._e=null,i._clearTimeOut(),i._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;0<t.hgap+t.lgap&&this.element.css({"padding-left":(t.hgap+t.lgap)/BI.pixRatio+BI.pixUnit}),0<t.hgap+t.rgap&&this.element.css({"padding-right":(t.hgap+t.rgap)/BI.pixRatio+BI.pixUnit}),0<t.vgap+t.tgap&&this.element.css({"padding-top":(t.vgap+t.tgap)/BI.pixRatio+BI.pixUnit}),0<t.vgap+t.bgap&&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(){t.handler(e.getValue())}),BI.createWidget({type:"bi.default",element:this,items:[this.text]})):this.text=this;var i=this._getShowText();BI.isUndefined(i)?BI.isKey(t.value)&&this.setText(t.value):this.setText(i),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=BI.isNotNull(e)?e:"",this._doRedMark(this.options.keyword)}});var n=[];BI.Text.addTextFormatter=function(e){n.push(e)},BI.Text.formatText=function(e){if(0<n.length)for(var t=0,i=n.length;t<i;t++)e=n[t](e);return e},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 t=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(e){t.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 e=BI.createWidget({type:"bi.center_adapt",items:[this.loaded]}),i=BI.createWidget({type:"bi.center_adapt",items:[this.loading]});this.cardLayout=BI.createWidget({type:"bi.card",element:this,items:[{el:e,cardName:"loaded"},{el:i,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 t=this,i=this.options,n=function(){t.$mask||(t.$mask=BI.createWidget(BI.isObject(i.shadow)?i.shadow:{},{type:"bi.layout",cls:"bi-button-mask"}),t.$mask.invisible(),BI.createWidget({type:"bi.absolute",element:t,items:[{el:t.$mask,left:0,right:0,top:0,bottom:0}]}))};this.element.mouseup(function(){t._hover||i.isShadowShowingOnSelected||(n(),t.$mask.invisible())}),this.element.on("mouseenter."+this.getName(),function(e){t.element.__isMouseInBounds__(e)&&(!t.isEnabled()||t._hover||!i.isShadowShowingOnSelected&&t.isSelected()||(n(),t.$mask.visible()))}),this.element.on("mousemove."+this.getName(),function(e){t.element.__isMouseInBounds__(e)||t.isEnabled()&&!t._hover&&(n(),t.$mask.invisible())}),this.element.on("mouseleave."+this.getName(),function(){t.isEnabled()&&!t._hover&&(n(),t.$mask.invisible())})},bindEvent:function(){var e,i,a=this,o=this.options,s=this.handle();function l(e){o.stopEvent&&e.stopEvent(),o.stopPropagation&&e.stopPropagation()}function u(e){if(l(e),!(!a.isEnabled()||a.isOnce()&&a.isSelected())){var t;if(BI.isKey(o.bubble)||BI.isFunction(o.bubble))return BI.isNull(a.combo)&&BI.createWidget({type:"bi.absolute",element:a,items:[{el:{type:"bi.bubble_combo",trigger:"",destroyWhenHide:!0,ref:function(){a.combo=this},el:{type:"bi.layout",height:"100%"},popup:{type:"bi.text_bubble_bar_popup_view",text:n(),ref:function(){t=this},listeners:[{eventName:BI.BubblePopupBarView.EVENT_CLICK_TOOLBAR_BUTTON,action:function(e){a.combo.hideView(),e&&i.apply(a,arguments)}}]},listeners:[{eventName:BI.BubbleCombo.EVENT_BEFORE_POPUPVIEW,action:function(){t.populate(n())}}]},left:0,right:0,bottom:0,top:0}]}),void(a.combo.isViewVisible()?a.combo.hideView():a.combo.showView());i.apply(a,arguments)}}function n(){var e=a.options.bubble;return BI.isFunction(e)?e():e}s&&(s=s.element,e=(o.trigger||"").split(","),BI.each(e,function(e,t){switch(t){case"mouseup":var i=!1;s.mousedown(function(){i=!0}),s.mouseup(function(e){!0===i&&u(e),i=!1,l(e)});break;case"mousedown":var i=!1,n=!1;s.mousedown(function(e){BI.Widget._renderEngine.createElement(document).bind("mouseup."+a.getName(),function(e){!BI.DOM.isExist(a)||s.__isMouseInBounds__(e)||!0!==i||n||a._trigger(),i=!1,BI.Widget._renderEngine.createElement(document).unbind("mouseup."+a.getName())}),!0!==i&&(a.isSelected()?n=!0:u(e),i=!0,l(e))}),s.mouseup(function(e){BI.DOM.isExist(a)&&!0===i&&!0===n&&u(e),n=i=!1,BI.Widget._renderEngine.createElement(document).unbind("mouseup."+a.getName())});break;case"dblclick":s.dblclick(u);break;case"lclick":var r,i=!1;s.mousedown(function(e){BI.Widget._renderEngine.createElement(document).bind("mouseup."+a.getName(),function(e){r&&clearInterval(r),r=null,i=!1,BI.Widget._renderEngine.createElement(document).unbind("mouseup."+a.getName())}),!0!==i&&(!a.isEnabled()||a.isOnce()&&a.isSelected()||(r=setInterval(function(){a.isEnabled()&&a.doClick()},180),i=!0,l(e)))});break;default:(o.stopEvent||o.stopPropagation)&&s.mousedown(function(e){l(e)}),s.click(u)}}),i=BI.debounce(this._doClick,BI.EVENT_RESPONSE_TIME,{leading:!0,trailing:!1}))},_trigger:function(e){var t,i=this.options;this.isEnabled()&&(this.isDisableSelected()||(this.isForceSelected()?this.setSelected(!0):this.isForceNotSelected()?this.setSelected(!1):this.setSelected(!this.isSelected())),this.isValid()&&(t=this.getValue(),i.handler.call(this,t,this,e),this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.CLICK,t,this,e),this.fireEvent(BI.BasicButton.EVENT_CHANGE,t,this),i.action&&BI.Actions.runAction(i.action,"click",i,this),BI.Actions.runGlobalAction("click",i,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)?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)&&0<e.height&&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"),0<e.minWidth&&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}),i=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,i)}))))},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}),i=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,i)}))))},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 t=this,e=this.options,i=e.autocomplete?" autocomplete="+e.autocomplete:"";this.editor=this.addWidget(BI.createWidget({type:"bi.input",element:"<input type='"+e.inputType+"'"+i+" />",root:!0,value:e.value,watermark:e.watermark,validationChecker:e.validationChecker,quitChecker:e.quitChecker,allowBlank:e.allowBlank})),this.editor.element.css({width:"100%",height:"100%",border:"none",outline:"none",padding:"0",margin:"0"});var n=[{el:{type:"bi.absolute",ref:function(e){t.contentWrapper=e},items:[{el:this.editor,left:0,right:0,top:0,bottom:0}]},left:e.hgap+e.lgap,right:e.hgap+e.rgap,top:e.vgap+e.tgap,bottom:e.vgap+e.bgap}];BI.createWidget({type:"bi.absolute",element:this,items:n}),this.setWaterMark(this.options.watermark),this.editor.on(BI.Controller.EVENT_CHANGE,function(){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.editor.on(BI.Input.EVENT_FOCUS,function(){t._checkError(),t.element.addClass("bi-editor-focus"),t.fireEvent(BI.Editor.EVENT_FOCUS,arguments)}),this.editor.on(BI.Input.EVENT_BLUR,function(){t._setErrorVisible(!1),t.element.removeClass("bi-editor-focus"),t.fireEvent(BI.Editor.EVENT_BLUR,arguments)}),this.editor.on(BI.Input.EVENT_CLICK,function(){t.fireEvent(BI.Editor.EVENT_CLICK,arguments)}),this.editor.on(BI.Input.EVENT_CHANGE,function(){t.fireEvent(BI.Editor.EVENT_CHANGE,arguments)}),this.editor.on(BI.Input.EVENT_KEY_DOWN,function(e){t.fireEvent(BI.Editor.EVENT_KEY_DOWN,arguments)}),this.editor.on(BI.Input.EVENT_QUICK_DOWN,function(e){e.keyCode!==BI.KeyCode.TAB&&t.watermark&&t.watermark.invisible()}),this.editor.on(BI.Input.EVENT_VALID,function(){t._checkWaterMark(),t._setErrorVisible(!1),t.fireEvent(BI.Editor.EVENT_VALID,arguments)}),this.editor.on(BI.Input.EVENT_ERROR,function(){t._checkWaterMark(),t.fireEvent(BI.Editor.EVENT_ERROR,arguments),t._setErrorVisible(t.isEditing())}),this.editor.on(BI.Input.EVENT_RESTRICT,function(){t._checkWaterMark();var e=t._setErrorVisible(!0);e&&e.element.fadeOut(100,function(){e.element.fadeIn(100)}),t.fireEvent(BI.Editor.EVENT_RESTRICT,arguments)}),this.editor.on(BI.Input.EVENT_EMPTY,function(){t._checkWaterMark(),t.fireEvent(BI.Editor.EVENT_EMPTY,arguments)}),this.editor.on(BI.Input.EVENT_ENTER,function(){t.fireEvent(BI.Editor.EVENT_ENTER,arguments)}),this.editor.on(BI.Input.EVENT_SPACE,function(){t.fireEvent(BI.Editor.EVENT_SPACE,arguments)}),this.editor.on(BI.Input.EVENT_BACKSPACE,function(){t.fireEvent(BI.Editor.EVENT_BACKSPACE,arguments)}),this.editor.on(BI.Input.EVENT_REMOVE,function(){t.fireEvent(BI.Editor.EVENT_REMOVE,arguments)}),this.editor.on(BI.Input.EVENT_START,function(){t.fireEvent(BI.Editor.EVENT_START,arguments)}),this.editor.on(BI.Input.EVENT_PAUSE,function(){t.fireEvent(BI.Editor.EVENT_PAUSE,arguments)}),this.editor.on(BI.Input.EVENT_STOP,function(){t.fireEvent(BI.Editor.EVENT_STOP,arguments)}),this.editor.on(BI.Input.EVENT_CONFIRM,function(){t.fireEvent(BI.Editor.EVENT_CONFIRM,arguments)}),this.editor.on(BI.Input.EVENT_CHANGE_CONFIRM,function(){t.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()},_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 t=this,e=this.options;BI.isNull(this.watermark)&&(this.watermark=BI.createWidget({type:"bi.label",cls:"bi-water-mark",text:this.options.watermark,height:e.height-2*e.vgap-e.tgap,hgap:2,whiteSpace:"nowrap",textAlign:"left"}),this.watermark.element.bind({mousedown:function(e){t.isEnabled()?t.editor.isEditing()||t.editor.focus():t.editor.isEditing()&&t.editor.blur(),e.stopEvent()}}),this.watermark.element.bind("click",function(e){t.isEnabled()?t.editor.isEditing()||t.editor.focus():t.editor.isEditing()&&t.editor.blur(),e.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 t=this,e=this.options,i=this.getValue();BI.isNotEmptyString(i)?(this.watermark&&this.watermark.destroy(),this.watermark=null):BI.isNotEmptyString(e.watermark)&&(this.watermark?(this.watermark.setText(e.watermark),this.watermark.setValid(!e.invalid),this.watermark.setEnable(!e.disabled)):(this.watermark=BI.createWidget({type:"bi.label",cls:"bi-water-mark textarea-watermark",textAlign:"left",whiteSpace:e.scrolly?"normal":"nowrap",title:e.watermark,text:e.watermark,invalid:e.invalid,disabled:e.disabled,hgap:6,vgap:24<e.height?4:2,height:24<e.height?"":e.height}),this.watermark.element.bind({mousedown:function(e){t.isEnabled()?t.focus():t.blur(),e.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,i=t.errorText;if(BI.isFunction(i)&&(i=i(BI.trim(this.getValue()))),!this.disabledError&&BI.isKey(i))return BI.Bubbles[e?"show":"hide"](this.getName(),i,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;0<t.hgap+t.lgap&&this.element.css({"padding-left":(t.hgap+t.lgap)/BI.pixRatio+BI.pixUnit}),0<t.hgap+t.rgap&&this.element.css({"padding-right":(t.hgap+t.rgap)/BI.pixRatio+BI.pixUnit}),0<t.vgap+t.tgap&&this.element.css({"padding-top":(t.vgap+t.tgap)/BI.pixRatio+BI.pixUnit}),0<t.vgap+t.bgap&&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 t=this,e=this.options;return{type:"bi.center_adapt",items:[{type:"bi.default",ref:function(e){t.checkbox=e},cls:"checkbox-content",width:e.iconWidth-2,height:e.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 i=this,t=!1,n=null,r=!1,a=BI.debounce(function(e){i.onKeyDown(e,t),i._keydown_=!1},300),o=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(e){r=!1,t=e.ctrlKey||e.metaKey,n=e.keyCode,i.fireEvent(BI.Input.EVENT_QUICK_DOWN,arguments)}).keyup(function(e){n=null,r&&e.keyCode===BI.KeyCode.ENTER||(i._keydown_=!0,a(e.keyCode))}).on("input propertychange",function(e){var t=e.originalEvent;!BI.isNull(t.propertyName)&&"value"!==t.propertyName||(r=!0,i._keydown_=!0,a(n),n=null)}).click(function(e){e.stopPropagation(),o()}).mousedown(function(e){i.element.val(i.element.val())}).focus(function(e){i._focusDebounce()}).blur(function(e){i._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 t=this;function e(){var e;t.isValid()||!1===t.options.quitChecker.apply(t,[BI.trim(t.getValue())])||(t.element.val(t._lastValidValue?t._lastValidValue:""),t._checkValidationOnValueChange(),t._defaultState()),t.element.removeClass("bi-input-focus"),t._isEditing=!1,t._start=!1,t.isValid()&&(e=t._lastValidValue,t._lastValidValue=t.getValue(),t.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.CONFIRM,t.getValue(),t),t.fireEvent(BI.Input.EVENT_CONFIRM),t._lastValidValue!==e&&t.fireEvent(BI.Input.EVENT_CHANGE_CONFIRM)),t.fireEvent(BI.Input.EVENT_BLUR)}!0===t._keydown_?BI.delay(e,300):e()},_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 i=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===i||""===BI.trim(i)||(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 t=this,e=this.options;return{type:"bi.center_adapt",element:this.element,items:[{type:"bi.layout",cls:"radio-content",ref:function(e){t.radio=e},width:e.iconWidth,height:e.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)&&0<e.width?BI.isNumber(e.textWidth)&&0<e.textWidth?(t.maxWidth=e.textWidth,BI.isNumber(e.height)&&0<e.height?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)&&0<e.height?(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)&&0<e.textWidth?(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)&&0<e.height?(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",i=this._createJson();return BI.isNumber(e.width)&&0<e.width?BI.isNumber(e.textWidth)&&0<e.textWidth?(i.width=e.textWidth,BI.isNumber(e.height)&&0<e.height?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(i)}]}):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(i)}]})):BI.isNumber(e.height)&&0<e.height?(this.text=BI.createWidget(BI.extend(i,{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}))):(i.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(i)}]})):BI.isNumber(e.textWidth)&&0<e.textWidth?(i.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(i)}]})):BI.isNumber(e.height)&&0<e.height?("normal"!==e.whiteSpace&&this.element.css({"line-height":(e.height-2*e.vgap)/BI.pixRatio+BI.pixUnit}),void(this.text=BI.createWidget(BI.extend(i,{element:this,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap})))):(BI.extend(i,{hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap}),this.text=BI.createWidget(BI.extend(i,{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)&&0<e.height&&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,t=BI.isKey(t)?t:e.value;return 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 i=function(e){return e.stopPropagation(),e.stopEvent(),!1};this.element.bind({click:i,mousedown:i,mouseup:i,mouseover:i,mouseenter:i,mouseleave:i,mousemove:i});var n="close-font";switch(t.level){case"success":n="toast-success-font";break;case"error":n="toast-error-font";break;case"warning":n="toast-warning-font";break;case"normal":default:n="toast-message-font"}var r=[{type:"bi.icon_label",cls:n+" 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 t=this.options;this.element.addClass("tooltip-"+t.level);var e=function(e){t.stopPropagation&&e.stopPropagation(),t.stopEvent&&e.stopEvent()};this.element.bind({click:e,mousedown:e,mouseup:e,mouseover:e,mouseenter:e,mouseleave:e,mousemove:e});var i=(t.text+"").split("\n");1<i.length?BI.createWidget({type:"bi.vertical",element:this,hgap:this._const.hgap,items:BI.map(i,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:t.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 r=this,a=this.options;e=BI.Tree.transformToTreeFormat(e);var o=[];return BI.each(e,function(e,i){var t,n;BI.isNotEmptyArray(i.children)||!0===i.isParent?(t=BI.extend({type:"bi.expander",el:{value:i.value},popup:{type:"bi.custom_tree"}},BI.deepClone(a.expander),{id:i.id,pId:i.pId}),n=BI.stripEL(i),BI.isWidget(n)?t.el=n:(delete(n=BI.clone(n)).children,BI.extend(t.el,n)),t.popup.expander=BI.deepClone(a.expander),t.items=t.popup.items=i.children,t.itemsCreator=t.popup.itemsCreator=function(e){if(BI.isNotNull(e.node))return a.itemsCreator.apply(r,arguments);var t=Array.prototype.slice.call(arguments,0);return t[0].node=i,a.itemsCreator.apply(r,t)},BI.isNull(t.popup.el)&&(t.popup.el=BI.deepClone(a.el)),o.push(t)):o.push(i)}),o},initTree:function(e){var n=this,t=this.options;this.tree=BI.createWidget(t.el,{element:this,items:this._formatItems(e),itemsCreator:function(e,i){t.itemsCreator.apply(this,[e,function(e){var t=Array.prototype.slice.call(arguments,0);t[0]=n._formatItems(e),i.apply(null,t)}])},value:t.value}),this.tree.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.CustomTree.EVENT_CHANGE,t,i)})},stroke:function(e){this.populate.apply(this,arguments)},populate:function(e){var t=Array.prototype.slice.call(arguments,0);0<arguments.length&&(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 t=this,e=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:e.height,height:e.height,hgap:e.hgap,rgap:e.rgap,lgap:e.textLgap,text:e.text,keyword:e.keyword,value:e.value,py:e.py}),this.checkbox.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&t.setSelected(t.isSelected())}),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.checkbox],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.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 t=this,e=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:e.height,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword}),this.checkbox.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&t.setSelected(t.isSelected()),t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)});var i=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),n=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:e.iconWrapperWidth,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(i,BI.extend(e.logic,{items:n}))))},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 t=this,e=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:e.height,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword}),this.checkbox.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&(this.isSelected()?t.triggerExpand():t.triggerCollapse())});var i=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),n=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(i,BI.extend(e.logic,{items:n}))))},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 t=this,e=this.options;this.checkbox=BI.createWidget({type:"bi.arrow_group_node_checkbox",width:24,stopPropagation:!0});var i=BI.createWidget({type:"bi.icon_label",width:24,cls:e.iconCls,iconWidth:e.iconWidth,iconHeight: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}),this.checkbox.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&(this.isSelected()?t.triggerExpand():t.triggerCollapse())});var n=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),r=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:e.iconWrapperWidth,el:this.checkbox},{width:16,el:i},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(n,BI.extend(e.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 t=this,e=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:e.height,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword}),this.checkbox.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&(this.isSelected()?t.triggerExpand():t.triggerCollapse())});var i=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),n=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(i,BI.extend(e.logic,{items:n}))))},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 t=this,e=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:e.height,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword}),this.checkbox.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&(this.isSelected()?t.triggerExpand():t.triggerCollapse())});var i=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),n=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(i,BI.extend(e.logic,{items:n}))))},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 t=this,e=this.options;this.node=BI.createWidget({type:"bi.icon_arrow_node",iconCls:e.iconCls,cls:"bi-list-item-none",id:e.id,pId:e.pId,open:e.open,height:e.height,iconHeight:e.iconHeight,iconWidth:e.iconWidth,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword}),this.node.on(BI.Controller.EVENT_CHANGE,function(e){t.setSelected(t.isSelected()),t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)});var i=[];BI.count(0,e.layer,function(){i.push({type:"bi.layout",width:15,height:e.height})}),i.push(this.node),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(e.layer,15),items:i})},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 t=this,e=this.options;this.checkbox=BI.createWidget({type:"bi.tree_node_checkbox"}),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,keyword:e.keyword,py:e.py}),this.checkbox.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&t.setSelected(t.isSelected()),t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)});var i=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),n=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(i,BI.extend(e.logic,{items:n}))))},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),i=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:i}))))},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 i=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),n=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:16,el:t},{el:this.text});BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(i,BI.extend(e.logic,{items:n,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),i=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:i}))))},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),i=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:i}))))},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 t=this,e=this.options;this.item=BI.createWidget({type:"bi.icon_tree_leaf_item",cls:"bi-list-item-none",iconCls:e.iconCls,id:e.id,pId:e.pId,isFront:!0,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword,iconWidth:e.iconWidth,iconHeight:e.iconHeight}),this.item.on(BI.Controller.EVENT_CHANGE,function(e){e!==BI.Events.CLICK&&t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)});var i=[];BI.count(0,e.layer,function(){i.push({type:"bi.layout",width:15,height:e.height})}),i.push(this.item),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(e.layer,15),items:i})},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 t=this,e=this.options,i={type:"bi.label",ref:function(e){t.text=e},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},n=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),r=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:{type:"bi.layout",width:24,height:e.height}},{el:i});return BI.LogicFactory.createLogic(n,BI.extend(e.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,i){var n=this.options,a={},r=BI.getDate(),o=n.min.match(/\d+/g),s=n.max.match(/\d+/g);r.setFullYear(e,t,i),a.ymd=[r.getFullYear(),r.getMonth(),r.getDate()];var l=BI.Date._MD.slice(0);l[1]=BI.isLeapYear(a.ymd[0])?29:28,r.setFullYear(a.ymd[0],a.ymd[1],1),a.FDay=r.getDay();var u=(7-BI.StartOfWeek+a.FDay)%7;a.PDay=l[0===t?11:t-1]-u+1,a.NDay=1;var c=[];return BI.each(BI.range(42),function(e){var t,i={},n=a.ymd[0],r=a.ymd[1]+1;e<u?(i.lastMonth=!0,t=e+a.PDay,1===r&&--n,r=1===r?12:r-1):u<=e&&e<u+l[a.ymd[1]]?(t=e-u+1)===a.ymd[2]&&(i.currentDay=!0):(i.nextMonth=!0,t=a.NDay++,12===r&&(n+=1),r=12===r?1:r+1),BI.checkDateVoid(n,r,t,o,s)[0]&&(i.disabled=!0),i.text=t,c.push(i)}),c},_init:function(){BI.Calendar.superclass._init.apply(this,arguments);var e=this,t=this.options,i=BI.map(this._getWeekLabel(),function(e,t){return{type:"bi.label",height:24,text:t}}),n=BI.createWidget({type:"bi.button_group",height:44,items:i,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:24,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",n,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),i=e.month,n=BI.getDate(),r=n.getDay();t|=0,n.setFullYear(t,i,1);var a=BI.getOffsetDate(n,-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),i=e.month,n=BI.getDate(),r=n.getDay();t|=0,n.setFullYear(t,i,1);var a=BI.getOffsetDate(n,42-r);return!!BI.checkDateVoid(a.getFullYear(),a.getMonth(),a.getDate(),e.min,e.max)[0]},_getItems:function(){var n=this.options,e=this._dateCreator(n.year,n.month-1,n.day),t=[];return t.push(e.slice(0,7)),t.push(e.slice(7,14)),t.push(e.slice(14,21)),t.push(e.slice(21,28)),t.push(e.slice(28,35)),t.push(e.slice(35,42)),BI.map(t,function(e,t){return BI.map(t,function(e,t){var i=t.lastMonth?n.month-1:t.nextMonth?n.month+1:n.month;return BI.extend(t,{type:"bi.calendar_date_item",textAlign:"center",whiteSpace:"normal",once:!1,forceSelected:!0,height:24,value:n.year+"-"+i+"-"+t.text,disabled:t.lastMonth||t.nextMonth||t.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(),i=BI.getDate().getMonth(),n=12*(e.year-t);return n+=e.month-1-i},getDateJSONByPage:function(e){var t=e;t+=BI.getDate().getMonth();var i=BI.parseInt(t/12);t<0&&t%12!=0&&i--;var n=0<=t?t%12:(12+t%12)%12;return{year:BI.getDate().getFullYear()+i,month:1+n}}}),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 i=BI.YearCalendar.getStartYear(e),n=[],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(i+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=i+e,n.push(t)}),n},_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:24})),{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,i=this._yearCreator(e.year||this.currentYear),t=i.length,n=BI.makeArray(t,""),r=[0,6,1,7,2,8,3,9,4,10,5,11];BI.each(i,function(e,t){n[e]=i[r[e]]});var a=[];return a.push(n.slice(0,2)),a.push(n.slice(2,4)),a.push(n.slice(4,6)),a.push(n.slice(6,8)),a.push(n.slice(8,10)),a.push(n.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:24,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 t=this,e=this.options;BI.ColorChooser.superclass._init.apply(this,arguments),e.value=e.value||"",this.combo=BI.createWidget({type:"bi.combo",element:this,container:e.container,adjustLength:1,isNeedAdjustWidth:!1,isNeedAdjustHeight:!1,el:BI.extend({type:e.width<=24?"bi.color_chooser_trigger":"bi.long_color_chooser_trigger",ref:function(e){t.trigger=e},width:e.el.type?e.width:e.width-2,height:e.el.type?e.height:e.height-2},e.el),popup:{el:BI.extend({type:"bi.hex_color_chooser_popup",ref:function(e){t.colorPicker=e},listeners:[{eventName:BI.ColorChooserPopup.EVENT_VALUE_CHANGE,action:function(){i(),t._isRGBColor(t.colorPicker.getValue())||t.combo.hideView()}},{eventName:BI.ColorChooserPopup.EVENT_CHANGE,action:function(){i(),t.combo.hideView()}}]},e.popup),value:e.value,width:292},value:e.value});var i=function(){var e=t.colorPicker.getValue();t.trigger.setValue(e)};this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,function(){t.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 i=this,e=this.options;return{type:"bi.absolute",items:[{el:{type:"bi.vtape",items:[{el:BI.extend({type:e.simple?"bi.simple_hex_color_picker_editor":"bi.hex_color_picker_editor",value:e.value,height:30,listeners:[{eventName:BI.ColorPickerEditor.EVENT_CHANGE,action:function(){i.setValue(this.getValue()),i._dealStoreColors(),i.fireEvent(BI.ColorChooserPopup.EVENT_VALUE_CHANGE,arguments)}}],ref:function(e){i.colorEditor=e}},e.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:e.value,listeners:[{eventName:BI.ColorPicker.EVENT_CHANGE,action:function(){i.setValue(this.getValue()[0]),i._dealStoreColors(),i.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE,arguments)}}],ref:function(e){i.storeColors=e}},left:10,right:10,top:5}]},height:38},{el:{type:"bi.absolute",items:[{el:{type:"bi.color_picker",value:e.value,listeners:[{eventName:BI.ColorPicker.EVENT_CHANGE,action:function(){i.setValue(this.getValue()[0]),i._dealStoreColors(),i.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE,arguments)}}],ref:function(e){i.colorPicker=e}},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:e.editor,ref:function(e){i.customColorChooser=e}},stopPropagation:!1,bgap:-1,rgap:1,lgap:1,minWidth:227,listeners:[{eventName:BI.PopupPanel.EVENT_CLICK_TOOLBAR_BUTTON,action:function(e){switch(e){case 0:i.more.hideView();break;case 1:var t=i.customColorChooser.getValue();BI.isNotEmptyString(t)&&(i.setValue(t),i._dealStoreColors()),i.more.hideView(),i.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE,arguments)}}}]},listeners:[{eventName:BI.Combo.EVENT_AFTER_POPUPVIEW,action:function(){i.customColorChooser.setValue(i.getValue())}}],ref:function(e){i.more=e}},height:24}]},left:0,right:0,top:0,bottom:0},{el:{type:"bi.layout",cls:"disable-mask",invisible:!e.disabled,ref:function(){i.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(),i=new BI.Queue(8);i.fromArray(t),i.remove(e),i.unshift(e);var n=i.toArray();BI.Cache.setItem("colors",BI.array2String(n)),this.setStoreColors(n)},_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 i=this,n=this.options,e=BI.string2Array(BI.Cache.getItem("colors")||"");return BI.filter(e,function(e,t){return!n.simple||i._isRGBColor(t)})},_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 t=this;return{type:"bi.hex_color_chooser_popup",value:this.options.value,simple:!0,listeners:[{eventName:BI.ColorChooserPopup.EVENT_CHANGE,action:function(){t.fireEvent(BI.SimpleColorChooserPopup.EVENT_CHANGE,arguments)}},{eventName:BI.ColorChooserPopup.EVENT_VALUE_CHANGE,action:function(){t.fireEvent(BI.SimpleColorChooserPopup.EVENT_VALUE_CHANGE,arguments)}}],ref:function(e){t.popup=e}}},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 t=this,e=this.options;this.colorEditor=BI.createWidget(e.editor,{type:e.simple?"bi.simple_color_picker_editor":"bi.color_picker_editor",value:e.value,cls:"bi-header-background bi-border-bottom",height:30}),this.colorEditor.on(BI.ColorPickerEditor.EVENT_CHANGE,function(){t.setValue(this.getValue()),t._dealStoreColors(),t.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:e.value}),this.storeColors.on(BI.ColorPicker.EVENT_CHANGE,function(){t.setValue(this.getValue()[0]),t._dealStoreColors(),t.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE,arguments)}),this.colorPicker=BI.createWidget({type:"bi.color_picker",width:210,height:50,value:e.value}),this.colorPicker.on(BI.ColorPicker.EVENT_CHANGE,function(){t.setValue(this.getValue()[0]),t._dealStoreColors(),t.fireEvent(BI.ColorChooserPopup.EVENT_CHANGE,arguments)}),this.customColorChooser=BI.createWidget({type:"bi.custom_color_chooser",editor:e.editor});var i=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:i}),this.more.on(BI.Combo.EVENT_AFTER_POPUPVIEW,function(){t.customColorChooser.setValue(t.getValue())}),i.on(BI.PopupPanel.EVENT_CLICK_TOOLBAR_BUTTON,function(e){switch(e){case 0:t.more.hideView();break;case 1:t.setValue(t.customColorChooser.getValue()),t._dealStoreColors(),t.more.hideView(),t.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:!e.disabled,ref:function(){t.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(),i=new BI.Queue(8);i.fromArray(t),i.remove(e),i.unshift(e);var n=i.toArray();BI.Cache.setItem("colors",BI.array2String(n)),this.setStoreColors(n)},_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 i=this,n=this.options,e=BI.string2Array(BI.Cache.getItem("colors")||"");return BI.filter(e,function(e,t){return!n.simple||i._isRGBColor(t)})},_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 t=this;this.options;this.colorContainer=BI.createWidget({type:"bi.htape",cls:"color-chooser-trigger-content",items:[{type:"bi.icon_change_button",ref:function(e){t.changeIcon=e},disableSelected:!0,iconCls:"auto-color-icon",width:24,iconWidth:16,iconHeight:16},{el:{type:"bi.label",ref:function(e){t.label=e},textAlign:"left",hgap:5,height:18,text:BI.i18nText("BI-Basic_Auto")}}]});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: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,t=this,i=this.options;i.value&&(this.element.css("background-color",i.value),e=this.getName(),this.element.hover(function(){t._createMask(),t.isEnabled()&&BI.Maskers.show(e)},function(){t.isSelected()||BI.Maskers.hide(e)}))},_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 t=this,e=(this.options,this.constants);this.storeValue={};var i=BI.createItems([{text:"R"},{text:"G"},{text:"B"}],{type:"bi.label",cls:"color-picker-editor-label",height:20}),n=function(e){return BI.isNumeric(e)&&0<=(0|e)&&(0|e)<=255},r=BI.map(BI.range(0,3),function(){return{type:"bi.small_text_editor",cls:"color-picker-editor-input",validationChecker:n,errorText:BI.i18nText("BI-Color_Picker_Error_Text"),allowBlank:!0,value:255,width:e.RGB_WIDTH,height:20,listeners:[{eventName:BI.TextEditor.EVENT_CHANGE,action:function(){t._checkEditors(),n(t.storeValue.r)&&n(t.storeValue.g)&&n(t.storeValue.b)&&(t.colorShow.element.css("background-color",t.getValue()),t.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(e){t.colorShow=e}},width:16},{type:"bi.label",text:"#",width:10},{type:"bi.small_text_editor",ref:function(e){t.hexEditor=e},cls:"color-picker-editor-input",validationChecker:this._hexChecker,allowBlank:!0,errorText:BI.i18nText("BI-Color_Picker_Error_Text_Hex"),width:e.HEX_WIDTH,height:20,listeners:[{eventName:"EVENT_CHANGE",action:function(){t._checkHexEditor(),n(t.storeValue.r)&&n(t.storeValue.g)&&n(t.storeValue.b)&&(t.colorShow.element.css("background-color",t.getValue()),t.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE))}}]},{el:BI.extend(r[0],{ref:function(e){t.R=e}}),width:e.RGB_WIDTH},{el:BI.extend(r[1],{ref:function(e){t.G=e}}),width:e.RGB_WIDTH},{el:BI.extend(r[2],{ref:function(e){t.B=e}}),width:e.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()?(t.lastColor=t.getValue(),t.setValue("transparent")):("transparent"===t.lastColor&&(t.lastColor=""),t.setValue(t.lastColor||"#ffffff")),(t.R.isValid()&&t.G.isValid()&&t.B.isValid()||t._isEmptyRGB())&&(t.colorShow.element.css("background-color",t.getValue()),t.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE))}}],ref:function(e){t.transparent=e}},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()?(t.lastColor=t.getValue(),t.setValue("")):t.setValue(t.lastColor||"#ffffff"),(t.R.isValid()&&t.G.isValid()&&t.B.isValid()||t._isEmptyRGB())&&(t.colorShow.element.css("background-color",t.getValue()),t.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE))}}],ref:function(e){t.none=e}},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:i[0].el,lgap:44},{el:i[1].el,lgap:28},{el:i[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 t=this,e=(this.options,this.constants),i=BI.createItems([{text:"R"},{text:"G"},{text:"B"}],{type:"bi.label",cls:"color-picker-editor-label",height:20}),n=function(e){return BI.isNumeric(e)&&0<=(0|e)&&(0|e)<=255},r=BI.map(BI.range(0,3),function(){return{type:"bi.small_text_editor",cls:"color-picker-editor-input",validationChecker:n,errorText:BI.i18nText("BI-Color_Picker_Error_Text"),allowBlank:!0,value:255,width:e.RGB_WIDTH,height:20,listeners:[{eventName:BI.TextEditor.EVENT_CHANGE,action:function(){t._checkEditors(),t.R.isValid()&&t.G.isValid()&&t.B.isValid()&&(t.colorShow.element.css("background-color",t.getValue()),t.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(e){t.colorShow=e}},width:16,lgap:10,rgap:5},{type:"bi.label",text:"#",width:10},{type:"bi.small_text_editor",ref:function(e){t.hexEditor=e},cls:"color-picker-editor-input",validationChecker:this._hexChecker,allowBlank:!0,errorText:BI.i18nText("BI-Color_Picker_Error_Text_Hex"),width:e.HEX_WIDTH,height:20,listeners:[{eventName:"EVENT_CHANGE",action:function(){t._checkHexEditor(),n(t.storeValue.r)&&n(t.storeValue.g)&&n(t.storeValue.b)&&(t.colorShow.element.css("background-color",t.getValue()),t.fireEvent(BI.ColorPickerEditor.EVENT_CHANGE))}}]},{el:BI.extend(r[0],{ref:function(e){t.R=e}}),width:e.RGB_WIDTH},{el:BI.extend(r[1],{ref:function(e){t.G=e}}),width:e.RGB_WIDTH},{el:BI.extend(r[2],{ref:function(e){t.B=e}}),width:e.RGB_WIDTH}]},{type:"bi.vertical_adapt",items:[{el:{type:"bi.label",cls:"color-picker-editor-label",height:20,text:"HEX"},lgap:86},{el:i[0].el,lgap:50},{el:i[1].el,lgap:40},{el:i[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 i=this,e=(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 t=BI.createWidgets(BI.createItems([{text:"R"},{text:"G"},{text:"B"}],{type:"bi.label",cls:"color-picker-editor-label",width:20,height:20})),n=function(e){return BI.isNumeric(e)&&0<=(0|e)&&(0|e)<=255},r=BI.createWidgets([{},{},{}],{type:"bi.small_text_editor",cls:"color-picker-editor-input",validationChecker:n,errorText:BI.i18nText("BI-Color_Picker_Error_Text"),allowBlank:!0,value:255,width:e.RGB_WIDTH,height:20});BI.each(r,function(e,t){t.on(BI.TextEditor.EVENT_CHANGE,function(){i._checkEditors(),n(i.storeValue.r)&&n(i.storeValue.g)&&n(i.storeValue.b)&&(i.colorShow.element.css("background-color",i.getValue()),i.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()?(i.lastColor=i.getValue(),i.setValue("")):i.setValue(i.lastColor||"#ffffff"),(i.R.isValid()&&i.G.isValid()&&i.B.isValid()||i._isEmptyRGB())&&(i.colorShow.element.css("background-color",i.getValue()),i.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()?(i.lastColor=i.getValue(),i.setValue("transparent")):("transparent"===i.lastColor&&(i.lastColor=""),i.setValue(i.lastColor||"#ffffff")),(i.R.isValid()&&i.G.isValid()&&i.B.isValid()||i._isEmptyRGB())&&(i.colorShow.element.css("background-color",i.getValue()),i.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:t[0],width:20},{el:this.R,width:e.RGB_WIDTH},{el:t[1],width:20},{el:this.G,width:e.RGB_WIDTH},{el:t[2],width:20},{el:this.B,width:e.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 i=this,e=(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 t=BI.createWidgets(BI.createItems([{text:"R"},{text:"G"},{text:"B"}],{type:"bi.label",cls:"color-picker-editor-label",width:20,height:20})),n=BI.createWidgets([{},{},{}],{type:"bi.small_text_editor",cls:"color-picker-editor-input",validationChecker:function(e){return BI.isNumeric(e)&&0<=(0|e)&&(0|e)<=255},errorText:BI.i18nText("BI-Color_Picker_Error_Text"),allowBlank:!0,value:255,width:e.RGB_WIDTH,height:20});BI.each(n,function(e,t){t.on(BI.TextEditor.EVENT_CHANGE,function(){i._checkEditors(),i.R.isValid()&&i.G.isValid()&&i.B.isValid()&&(i.colorShow.element.css("background-color",i.getValue()),i.fireEvent(BI.SimpleColorPickerEditor.EVENT_CHANGE))})}),this.R=n[0],this.G=n[1],this.B=n[2],BI.createWidget({type:"bi.vertical_adapt",element:this,items:[{el:this.colorShow,width:16,lgap:20,rgap:15},{el:t[0],width:20},{el:this.R,width:e.RGB_WIDTH},{el:t[1],width:20},{el:this.G,width:e.RGB_WIDTH},{el:t[2],width:20},{el:this.B,width:e.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 t=this;return{type:"bi.absolute",items:[{el:{type:"bi.layout",cls:"",ref:function(e){t.colorWrapper=e}},top:47,left:47,width:101,height:101},{el:{type:"bi.layout",cls:"wheel",ref:function(e){t.wheel=e}},left:0,right:0,top:0,bottom:0},{el:{type:"bi.layout",cls:"overlay",ref:function(e){t.overlay=e}},top:47,left:47,width:101,height:101},{el:{type:"bi.layout",cls:"marker",ref:function(e){t.hMarker=e},scrollable:!1,width:17,height:17}},{el:{type:"bi.layout",cls:"marker",ref:function(e){t.slMarker=e},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]),i=Math.round(255*e[1]),n=Math.round(255*e[2]);return"#"+(t<16?"0":"")+t.toString(16)+(i<16?"0":"")+i.toString(16)+(n<16?"0":"")+n.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=e[0],i=e[1],n=e[2],r=n<=.5?n*(i+1):n+i-n*i,a=2*n-r;return[this._hueToRGB(a,r,t+.33333),this._hueToRGB(a,r,t),this._hueToRGB(a,r,t-.33333)]},_hueToRGB:function(e,t,i){return 6*(i=i<0?i+1:1<i?i-1:i)<1?e+(t-e)*i*6:2*i<1?t:3*i<2?e+(t-e)*(.66666-i)*6:e},_RGBToHSL:function(e){var t=e[0],i=e[1],n=e[2],r=Math.min(t,Math.min(i,n)),a=Math.max(t,Math.max(i,n)),o=a-r,s=(r+a)/2,l=0;return 0<o&&(a==t&&a!=i&&(l+=(i-n)/o),a==i&&a!=n&&(l+=2+(n-t)/o),a==n&&a!=t&&(l+=4+(t-i)/o),l/=6),[l,0<s&&s<1?o/(s<.5?2*s:2-2*s):0,s]},_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,i={x:e.offsetLeft,y:e.offsetTop};return e.offsetParent&&(t=this._absolutePosition(e.offsetParent),i.x+=t.x,i.y+=t.y),i},_widgetCoords:function(e){var t=e.target||e.srcElement,i=this.wheel.element[0];if("undefined"!=typeof e.offsetX){for(var n={x:e.offsetX,y:e.offsetY},r=t;r;)r.mouseX=n.x,r.mouseY=n.y,n.x+=r.offsetLeft,n.y+=r.offsetTop,r=r.offsetParent;for(var r=i,a={x:0,y:0};r;){if("undefined"!=typeof r.mouseX){o=r.mouseX-a.x,s=r.mouseY-a.y;break}a.x+=r.offsetLeft,a.y+=r.offsetTop,r=r.offsetParent}for(r=t;r;)r.mouseX=undefined,r.mouseY=undefined,r=r.offsetParent}else var n=this._absolutePosition(i),o=(e.pageX||0)-n.x,s=(e.pageY||0)-n.y;return{x:o-this.constants.WIDTH/2,y:s-this.constants.WIDTH/2}},_doMouseMove:function(e){var t,i,n,r=this._widgetCoords(e);this.circleDrag?((t=Math.atan2(r.x,-r.y)/6.28)<0&&(t+=1),this._setHSL([t,this.hsl[1],this.hsl[2]])):(i=Math.max(0,Math.min(1,.5-r.x/this.constants.SQUARE)),n=Math.max(0,Math.min(1,.5-r.y/this.constants.SQUARE)),this._setHSL([this.hsl[0],i,n])),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={},i={},n=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-n-this._const.TRIANGLE_LENGTH},i={width:this._const.TRIANGLE_LENGTH};break;case"right":t={top:s,height:this.element.outerHeight(),left:o+n},i={width:this._const.TRIANGLE_LENGTH};break;case"top":t={left:a,width:this.element.outerWidth(),top:s-n-this._const.TRIANGLE_LENGTH},i={height:this._const.TRIANGLE_LENGTH};break;case"bottom":t={left:a,width:this.element.outerWidth(),top:l+n},i={height:this._const.TRIANGLE_LENGTH}}this.triangle&&this.triangle.destroy(),this.triangle=BI.createWidget(i,{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,i=this,n=[];return BI.each(e.buttons,function(e,t){BI.isWidget(t)?n.push(t):n.push(BI.extend({type:"bi.button",height:24,handler:function(e){i.fireEvent(BI.BubblePopupBarView.EVENT_CLICK_TOOLBAR_BUTTON,e)}},t))}),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 i=this,e=this.options,t=BI.map(e.buttons,function(e,t){return BI.isWidget(t)?t:BI.extend({type:"bi.button",height:24,handler:function(e){i.fireEvent(BI.TextBubblePopupBarView.EVENT_CHANGE,e)}},t)});return{type:"bi.bubble_bar_popup_view",minWidth:e.minWidth,maxWidth:e.maxWidth,minHeight:e.minHeight,ref:function(){i.popup=this},el:{type:"bi.label",text:e.text,whiteSpace:"normal",textAlign:"left",ref:function(){i.text=this}},buttons:t}},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,n=this;this.popup=BI.createWidget({type:"bi.button_group",items:BI.createItems(e.items,{type:"bi.single_select_icon_text_item",height:24}),chooseType:e.chooseType,layouts:[{type:"bi.vertical"}],value:e.value}),this.popup.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.IconComboPopup.EVENT_CHANGE,t,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:24}),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(i,e){var n="";return i=BI.isArray(i)?i[0]:i,BI.any(e,function(e,t){if(i===t.value)return n=t.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,i=this._digest(e,this.options.items);e=BI.isArray(e)?e[0]:e,BI.isNotEmptyString(i)?(this.button.setIcon(i),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(i){var e;BI.isNull(i)||BI.isEmptyArray(i)||BI.isEmptyString(i)?(this.trigger.options.tipType="success",this.element.removeClass("combo-error")):(i=BI.isArray(i)?i:[i],e=BI.find(this.options.items,function(e,t){return BI.contains(i,t.value)}),BI.isNull(e)?(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,n=this;this.popup=BI.createWidget({type:"bi.button_group",items:BI.createItems(e.items,{type:"bi.single_select_icon_text_item",height:24,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,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.IconTextValueComboPopup.EVENT_CHANGE,t,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 i=this.options;e=BI.createItems(e,{type:"bi.single_select_icon_text_item",height:24,iconWrapperWidth:i.iconWrapperWidth,iconHeight:i.iconHeight,iconWidth:i.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 t=this,e=this.options;return{type:"bi.absolute",items:[{el:{type:"bi.combo",cls:"bi-border bi-focus-shadow",container:e.container,adjustLength:2,toggle:!1,ref:function(){t.combo=this},el:{type:"bi.search_text_value_trigger",cls:"search-text-value-trigger",watermark:e.watermark,ref:function(){t.trigger=this},items:e.items,height:e.height-2,text:e.text,value:e.value,tipType:e.tipType,warningTitle:e.warningTitle,title:e.title,listeners:[{eventName:BI.SearchTextValueTrigger.EVENT_CHANGE,action:function(){t.setValue(this.getValue()),t.combo.hideView(),t.fireEvent(BI.SearchTextValueCombo.EVENT_CHANGE)}}]},popup:{el:{type:"bi.text_value_combo_popup",chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,value:e.value,items:e.items,ref:function(){t.popup=this,t.trigger.getSearcher().setAdapter(t.popup)},listeners:[{eventName:BI.TextValueComboPopup.EVENT_CHANGE,action:function(){t.setValue(this.getValue()),t.combo.hideView(),t.fireEvent(BI.SearchTextValueCombo.EVENT_CHANGE)}}]},value:e.value,maxHeight:252,minHeight:25},listeners:[{eventName:BI.Combo.EVENT_AFTER_HIDEVIEW,action:function(){t.trigger.stopEditing()}},{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){t.fireEvent(BI.SearchTextValueCombo.EVENT_BEFORE_POPUPVIEW)}}],hideChecker:function(e){return 0===t.triggerBtn.element.find(e.target).length}},left:0,right:0,bottom:0,top:0},{el:{type:"bi.trigger_icon_button",cls:"trigger-icon-button",ref:function(){t.triggerBtn=this},width:e.height,height:e.height,handler:function(){t.combo.isViewVisible()?t.combo.hideView():t.combo.showView()}},right:0,bottom:0,top:0}]}},created:function(){var e=this.options;BI.isKey(e.value)&&this._checkError(e.value)},_checkError:function(i){var e;BI.isNull(i)||BI.isEmptyArray(i)||BI.isEmptyString(i)?(this.trigger.options.tipType="success",this.element.removeClass("combo-error")):(i=BI.isArray(i)?i:[i],e=BI.find(this.options.items,function(e,t){return BI.contains(i,t.value)}),BI.isNull(e)?(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 n=this,e=this.options;return{type:"bi.vertical",vgap:5,items:[{type:"bi.button_group",ref:function(){n.popup=this},items:BI.createItems(e.items,{type:"bi.single_select_item",textAlign:e.textAlign,height:24}),chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,layouts:[{type:"bi.vertical"}],behaviors:{redmark:function(){return!0}},value:e.value,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.SearchTextValueComboPopup.EVENT_CHANGE,t,i)}}]}]}},mounted:function(){this.check()},populate:function(e,t,i){var n=BI.concat(e,t);BI.SearchTextValueComboPopup.superclass.populate.apply(this,n),n=BI.createItems(n,{type:"bi.single_select_item",height:24}),this.popup.populate(n,i)},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,r=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:r.watermark,defaultText:r.text,text:this._digest(r.value,r.items),value:r.value,height:r.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,t){var i=e.keyword,n=BI.Func.getSearchResult(r.items,i);t(n.match,n.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(i,e){var t=this.options;i=BI.isArray(i)?i:[i];var n=[],r=BI.Tree.transformToArrayFormat(e);return BI.each(r,function(e,t){BI.deepContains(i,t.value)&&!BI.contains(n,t.text||t.value)&&n.push(t.text||t.value)}),0<n.length?n.join(","):BI.isFunction(t.text)?t.text():t.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,n=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,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.TextValueCheckComboPopup.EVENT_CHANGE,t,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(i){var e;BI.isNull(i)||BI.isEmptyArray(i)||BI.isEmptyString(i)?(this.trigger.options.tipType="success",this.element.removeClass("combo-error")):(i=BI.isArray(i)?i:[i],e=BI.find(this.options.items,function(e,t){return BI.contains(i,t.value)}),BI.isNull(e)?(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,n=this;this.popup=BI.createWidget({type:"bi.button_group",items:BI.createItems(e.items,{type:"bi.single_select_item",textAlign:e.textAlign,height:24}),chooseType:e.chooseType,layouts:[{type:"bi.vertical"}],value:e.value}),this.popup.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.TextValueComboPopup.EVENT_CHANGE,t,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:24}),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 t=this,e=this.options;this.editor=BI.createWidget({type:"bi.editor",height:e.height,watermark:e.watermark,allowBlank:!0,errorText:e.errorText,validationChecker:e.validationChecker,quitChecker:e.quitChecker,value:e.value}),this.clear=BI.createWidget({type:"bi.icon_button",stopEvent:!0,cls:"search-close-h-font"}),this.clear.on(BI.IconButton.EVENT_CHANGE,function(){t.setValue(""),t.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.STOPEDIT),t.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(){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.editor.on(BI.Editor.EVENT_FOCUS,function(){t.fireEvent(BI.ClearEditor.EVENT_FOCUS)}),this.editor.on(BI.Editor.EVENT_BLUR,function(){t.fireEvent(BI.ClearEditor.EVENT_BLUR)}),this.editor.on(BI.Editor.EVENT_CLICK,function(){t.fireEvent(BI.ClearEditor.EVENT_CLICK)}),this.editor.on(BI.Editor.EVENT_CHANGE,function(){t._checkClear(),t.fireEvent(BI.ClearEditor.EVENT_CHANGE)}),this.editor.on(BI.Editor.EVENT_KEY_DOWN,function(e){t.fireEvent(BI.ClearEditor.EVENT_KEY_DOWN,e)}),this.editor.on(BI.Editor.EVENT_SPACE,function(){t.fireEvent(BI.ClearEditor.EVENT_SPACE)}),this.editor.on(BI.Editor.EVENT_BACKSPACE,function(){t.fireEvent(BI.ClearEditor.EVENT_BACKSPACE)}),this.editor.on(BI.Editor.EVENT_VALID,function(){t.fireEvent(BI.ClearEditor.EVENT_VALID)}),this.editor.on(BI.Editor.EVENT_ERROR,function(){t.fireEvent(BI.ClearEditor.EVENT_ERROR)}),this.editor.on(BI.Editor.EVENT_ENTER,function(){t.fireEvent(BI.ClearEditor.EVENT_ENTER)}),this.editor.on(BI.Editor.EVENT_RESTRICT,function(){t.fireEvent(BI.ClearEditor.EVENT_RESTRICT)}),this.editor.on(BI.Editor.EVENT_EMPTY,function(){t._checkClear(),t.fireEvent(BI.ClearEditor.EVENT_EMPTY)}),this.editor.on(BI.Editor.EVENT_REMOVE,function(){t.fireEvent(BI.ClearEditor.EVENT_REMOVE)}),this.editor.on(BI.Editor.EVENT_CONFIRM,function(){t.fireEvent(BI.ClearEditor.EVENT_CONFIRM)}),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,function(){t.fireEvent(BI.ClearEditor.EVENT_CHANGE_CONFIRM)}),this.editor.on(BI.Editor.EVENT_START,function(){t.fireEvent(BI.ClearEditor.EVENT_START)}),this.editor.on(BI.Editor.EVENT_PAUSE,function(){t.fireEvent(BI.ClearEditor.EVENT_PAUSE)}),this.editor.on(BI.Editor.EVENT_STOP,function(){t.fireEvent(BI.ClearEditor.EVENT_STOP)}),BI.isKey(e.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 t=this,e=this.options;this.editor=BI.createWidget({type:"bi.editor",height:e.height,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,value:e.value,validationChecker:e.validationChecker,quitChecker:e.quitChecker,allowBlank:e.allowBlank,watermark:e.watermark,errorText:e.errorText}),this.text=BI.createWidget({type:"bi.text_button",cls:"shelter-editor-text",title:e.title,warningTitle:e.warningTitle,tipType:e.tipType,textAlign:e.textAlign,height:e.height,hgap:e.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]=t).fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.text.on(BI.TextButton.EVENT_CHANGE,function(){t.fireEvent(BI.ShelterEditor.EVENT_CLICK_LABEL)}),this.editor.on(BI.Controller.EVENT_CHANGE,function(){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.editor.on(BI.Editor.EVENT_FOCUS,function(){t.fireEvent(BI.ShelterEditor.EVENT_FOCUS,arguments)}),this.editor.on(BI.Editor.EVENT_BLUR,function(){t.fireEvent(BI.ShelterEditor.EVENT_BLUR,arguments)}),this.editor.on(BI.Editor.EVENT_CLICK,function(){t.fireEvent(BI.ShelterEditor.EVENT_CLICK,arguments)}),this.editor.on(BI.Editor.EVENT_CHANGE,function(){t.fireEvent(BI.ShelterEditor.EVENT_CHANGE,arguments)}),this.editor.on(BI.Editor.EVENT_KEY_DOWN,function(e){t.fireEvent(BI.ShelterEditor.EVENT_KEY_DOWN,arguments)}),this.editor.on(BI.Editor.EVENT_VALID,function(){t.fireEvent(BI.ShelterEditor.EVENT_VALID,arguments)}),this.editor.on(BI.Editor.EVENT_CONFIRM,function(){t._showHint(),t._checkText(),t.fireEvent(BI.ShelterEditor.EVENT_CONFIRM,arguments)}),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,function(){t._showHint(),t._checkText(),t.fireEvent(BI.ShelterEditor.EVENT_CHANGE_CONFIRM,arguments)}),this.editor.on(BI.Editor.EVENT_START,function(){t.fireEvent(BI.ShelterEditor.EVENT_START,arguments)}),this.editor.on(BI.Editor.EVENT_PAUSE,function(){t.fireEvent(BI.ShelterEditor.EVENT_PAUSE,arguments)}),this.editor.on(BI.Editor.EVENT_STOP,function(){t.fireEvent(BI.ShelterEditor.EVENT_STOP,arguments)}),this.editor.on(BI.Editor.EVENT_SPACE,function(){t.fireEvent(BI.ShelterEditor.EVENT_SPACE,arguments)}),this.editor.on(BI.Editor.EVENT_ERROR,function(){t._checkText(),t.fireEvent(BI.ShelterEditor.EVENT_ERROR,arguments)}),this.editor.on(BI.Editor.EVENT_ENTER,function(){t.fireEvent(BI.ShelterEditor.EVENT_ENTER,arguments)}),this.editor.on(BI.Editor.EVENT_RESTRICT,function(){t.fireEvent(BI.ShelterEditor.EVENT_RESTRICT,arguments)}),this.editor.on(BI.Editor.EVENT_EMPTY,function(){t.fireEvent(BI.ShelterEditor.EVENT_EMPTY,arguments)}),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[this.editor]}),this._showHint(),t._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 t=this,e=this.options;this.editor=BI.createWidget({type:"bi.editor",height:e.height,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,value:e.value,validationChecker:e.validationChecker,quitChecker:e.quitChecker,allowBlank:e.allowBlank,watermark:e.watermark,errorText:e.errorText}),this.text=BI.createWidget({type:"bi.text_button",cls:"sign-editor-text",title:e.title,warningTitle:e.warningTitle,tipType:e.tipType,textAlign:e.textAlign,height:e.height,hgap:e.hgap+2,handler:function(){t._showInput(),t.editor.focus(),t.editor.selectAll()}}),this.text.on(BI.TextButton.EVENT_CHANGE,function(){BI.nextTick(function(){t.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(){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.editor.on(BI.Editor.EVENT_FOCUS,function(){t.fireEvent(BI.SignEditor.EVENT_FOCUS,arguments)}),this.editor.on(BI.Editor.EVENT_BLUR,function(){t.fireEvent(BI.SignEditor.EVENT_BLUR,arguments)}),this.editor.on(BI.Editor.EVENT_CLICK,function(){t.fireEvent(BI.SignEditor.EVENT_CLICK,arguments)}),this.editor.on(BI.Editor.EVENT_CHANGE,function(){t.fireEvent(BI.SignEditor.EVENT_CHANGE,arguments)}),this.editor.on(BI.Editor.EVENT_KEY_DOWN,function(e){t.fireEvent(BI.SignEditor.EVENT_KEY_DOWN,arguments)}),this.editor.on(BI.Editor.EVENT_VALID,function(){t.fireEvent(BI.SignEditor.EVENT_VALID,arguments)}),this.editor.on(BI.Editor.EVENT_CONFIRM,function(){t._showHint(),t._checkText(),t.fireEvent(BI.SignEditor.EVENT_CONFIRM,arguments)}),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,function(){t._showHint(),t._checkText(),t.fireEvent(BI.SignEditor.EVENT_CHANGE_CONFIRM,arguments)}),this.editor.on(BI.Editor.EVENT_START,function(){t.fireEvent(BI.SignEditor.EVENT_START,arguments)}),this.editor.on(BI.Editor.EVENT_PAUSE,function(){t.fireEvent(BI.SignEditor.EVENT_PAUSE,arguments)}),this.editor.on(BI.Editor.EVENT_STOP,function(){t.fireEvent(BI.SignEditor.EVENT_STOP,arguments)}),this.editor.on(BI.Editor.EVENT_SPACE,function(){t.fireEvent(BI.SignEditor.EVENT_SPACE,arguments)}),this.editor.on(BI.Editor.EVENT_ERROR,function(){t._checkText(),t.fireEvent(BI.SignEditor.EVENT_ERROR,arguments)}),this.editor.on(BI.Editor.EVENT_ENTER,function(){t.fireEvent(BI.SignEditor.EVENT_ENTER,arguments)}),this.editor.on(BI.Editor.EVENT_RESTRICT,function(){t.fireEvent(BI.SignEditor.EVENT_RESTRICT,arguments)}),this.editor.on(BI.Editor.EVENT_EMPTY,function(){t.fireEvent(BI.SignEditor.EVENT_EMPTY,arguments)}),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[this.editor]}),this._showHint(),t._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 t=this,e=this.options;this.editor=BI.createWidget(e.el,{type:"bi.editor",height:e.height,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,value:e.value,validationChecker:e.validationChecker,quitChecker:e.quitChecker,allowBlank:e.allowBlank,watermark:e.watermark,errorText:e.errorText}),this.text=BI.createWidget({type:"bi.text_button",cls:"bi-water-mark tip-text-style",textAlign:"left",height:e.height,text:e.text,hgap:e.hgap+2,handler:function(){t._showInput(),t.editor.focus(),t.editor.setValue("")},title:BI.isNotNull(e.tipText)?e.tipText:function(){var e="";return BI.isString(t.stateValue)&&(e=t.stateValue),BI.isArray(t.stateValue)&&1===t.stateValue.length&&(e=t.stateValue[0]),e},warningTitle:e.warningTitle,tipType:e.tipType}),this.text.on(BI.TextButton.EVENT_CHANGE,function(){BI.nextTick(function(){t.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(){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.editor.on(BI.Editor.EVENT_FOCUS,function(){t.fireEvent(BI.StateEditor.EVENT_FOCUS,arguments)}),this.editor.on(BI.Editor.EVENT_BLUR,function(){t.fireEvent(BI.StateEditor.EVENT_BLUR,arguments)}),this.editor.on(BI.Editor.EVENT_CLICK,function(){t.fireEvent(BI.StateEditor.EVENT_CLICK,arguments)}),this.editor.on(BI.Editor.EVENT_CHANGE,function(){t.fireEvent(BI.StateEditor.EVENT_CHANGE,arguments)}),this.editor.on(BI.Editor.EVENT_KEY_DOWN,function(e){t.fireEvent(BI.StateEditor.EVENT_KEY_DOWN,arguments)}),this.editor.on(BI.Editor.EVENT_VALID,function(){t.fireEvent(BI.StateEditor.EVENT_VALID,arguments)}),this.editor.on(BI.Editor.EVENT_CONFIRM,function(){t._showHint(),t.fireEvent(BI.StateEditor.EVENT_CONFIRM,arguments)}),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,function(){t._showHint(),t.fireEvent(BI.StateEditor.EVENT_CHANGE_CONFIRM,arguments)}),this.editor.on(BI.Editor.EVENT_START,function(){t.fireEvent(BI.StateEditor.EVENT_START,arguments)}),this.editor.on(BI.Editor.EVENT_PAUSE,function(){t.fireEvent(BI.StateEditor.EVENT_PAUSE,arguments)}),this.editor.on(BI.Editor.EVENT_STOP,function(){t.fireEvent(BI.StateEditor.EVENT_STOP,arguments)}),this.editor.on(BI.Editor.EVENT_SPACE,function(){t.fireEvent(BI.StateEditor.EVENT_SPACE,arguments)}),this.editor.on(BI.Editor.EVENT_ERROR,function(){t.fireEvent(BI.StateEditor.EVENT_ERROR,arguments)}),this.editor.on(BI.Editor.EVENT_ENTER,function(){t.fireEvent(BI.StateEditor.EVENT_ENTER,arguments)}),this.editor.on(BI.Editor.EVENT_RESTRICT,function(){t.fireEvent(BI.StateEditor.EVENT_RESTRICT,arguments)}),this.editor.on(BI.Editor.EVENT_EMPTY,function(){t.fireEvent(BI.StateEditor.EVENT_EMPTY,arguments)}),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[this.editor]}),this._showHint(),BI.isNotNull(e.text)&&this.setState(e.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,i=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(i)&&i===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(i)?i:t.text),BI.isKey(i)?this.text.element.addClass("bi-water-mark"):this.text.element.removeClass("bi-water-mark")):(1===e.length?this._setText(e[0]):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(i)?i:t.text),BI.isKey(i)?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 t=this,e=this.options;this.editor=BI.createWidget({type:"bi.editor",height:e.height,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,value:e.value,validationChecker:e.validationChecker,quitChecker:e.quitChecker,allowBlank:e.allowBlank,watermark:e.watermark,errorText:e.errorText}),this.text=BI.createWidget({type:"bi.text_button",cls:"bi-water-mark",textAlign:"left",text:e.text,height:e.height,hgap:e.hgap+2,handler:function(){t._showInput(),t.editor.focus(),t.editor.setValue("")}}),this.text.on(BI.TextButton.EVENT_CHANGE,function(){BI.nextTick(function(){t.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(){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.editor.on(BI.Editor.EVENT_FOCUS,function(){t.fireEvent(BI.SimpleStateEditor.EVENT_FOCUS,arguments)}),this.editor.on(BI.Editor.EVENT_BLUR,function(){t.fireEvent(BI.SimpleStateEditor.EVENT_BLUR,arguments)}),this.editor.on(BI.Editor.EVENT_CLICK,function(){t.fireEvent(BI.SimpleStateEditor.EVENT_CLICK,arguments)}),this.editor.on(BI.Editor.EVENT_CHANGE,function(){t.fireEvent(BI.SimpleStateEditor.EVENT_CHANGE,arguments)}),this.editor.on(BI.Editor.EVENT_KEY_DOWN,function(e){t.fireEvent(BI.SimpleStateEditor.EVENT_KEY_DOWN,arguments)}),this.editor.on(BI.Editor.EVENT_VALID,function(){t.fireEvent(BI.SimpleStateEditor.EVENT_VALID,arguments)}),this.editor.on(BI.Editor.EVENT_CONFIRM,function(){t._showHint(),t.fireEvent(BI.SimpleStateEditor.EVENT_CONFIRM,arguments)}),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,function(){t._showHint(),t.fireEvent(BI.SimpleStateEditor.EVENT_CHANGE_CONFIRM,arguments)}),this.editor.on(BI.Editor.EVENT_START,function(){t.fireEvent(BI.SimpleStateEditor.EVENT_START,arguments)}),this.editor.on(BI.Editor.EVENT_PAUSE,function(){t.fireEvent(BI.SimpleStateEditor.EVENT_PAUSE,arguments)}),this.editor.on(BI.Editor.EVENT_STOP,function(){t.fireEvent(BI.SimpleStateEditor.EVENT_STOP,arguments)}),this.editor.on(BI.Editor.EVENT_SPACE,function(){t.fireEvent(BI.SimpleStateEditor.EVENT_SPACE,arguments)}),this.editor.on(BI.Editor.EVENT_ERROR,function(){t.fireEvent(BI.SimpleStateEditor.EVENT_ERROR,arguments)}),this.editor.on(BI.Editor.EVENT_ENTER,function(){t.fireEvent(BI.SimpleStateEditor.EVENT_ENTER,arguments)}),this.editor.on(BI.Editor.EVENT_RESTRICT,function(){t.fireEvent(BI.SimpleStateEditor.EVENT_RESTRICT,arguments)}),this.editor.on(BI.Editor.EVENT_EMPTY,function(){t.fireEvent(BI.SimpleStateEditor.EVENT_EMPTY,arguments)}),BI.createWidget({type:"bi.vertical",scrolly:!1,element:this,items:[this.editor]}),this._showHint(),BI.isNotNull(e.text)&&this.setState(e.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,i=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:24,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,t){i.fireEvent(BI.MultiPopupView.EVENT_CLICK_TOOLBAR_BUTTON,e,t)}),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,i=BI.createWidget({type:"bi.icon_button",cls:"close-h-font",width:25,height:25});return i.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:i,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 n=this,i=this.options;this.button_group=BI.createWidget(i.el,{type:"bi.button_group",chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,behaviors:{},items:i.items,itemsCreator:function(e,t){1===e.times&&(n.empty(),BI.nextTick(function(){n.loading()})),i.itemsCreator(e,function(){t.apply(n,arguments),1===e.times&&BI.nextTick(function(){n.loaded(),n.check()})})},hasNext:i.hasNext,layouts:[{type:"bi.vertical"}]}),this.button_group.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.ListPane.EVENT_CHANGE,t,i)}),this.check(),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Top),BI.extend({scrolly:!0,lgap:i.lgap,rgap:i.rgap,tgap:i.tgap,bgap:i.bgap,vgap:i.vgap,hgap:i.hgap},i.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=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 i=this,e=this.options;return this.text=BI.createWidget({type:"bi.label",cls:"panel-title-text",text:e.title,height:30}),this.button_group=BI.createWidget({type:"bi.button_group",items:e.titleButtons,layouts:[{type:"bi.center_adapt",lgap:10}]}),this.button_group.on(BI.Controller.EVENT_CHANGE,function(){i.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.button_group.on(BI.ButtonGroup.EVENT_CHANGE,function(e,t){i.fireEvent(BI.Panel.EVENT_CHANGE,e,t)}),{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 n=this,e=this.options;this.toolbar=BI.createWidget(e.toolbar),this.allSelected=!1,this.toolbar.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.allSelected=this.isSelected(),e===BI.Events.CLICK&&(n.setAllSelected(n.allSelected),n.fireEvent(BI.SelectList.EVENT_CHANGE,t,i)),n.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.list=BI.createWidget(e.el,{type:"bi.list_pane",items:e.items,itemsCreator:function(t,i){1===t.times&&n.toolbar.setVisible(!1),e.itemsCreator(t,function(e){i.apply(n,arguments),1===t.times&&(n.toolbar.setVisible(e&&0<e.length),n.toolbar.setEnable(n.isEnabled()&&e&&0<e.length)),n._checkAllSelected()})},onLoaded:e.onLoaded,hasNext:e.hasNext}),this.list.on(BI.Controller.EVENT_CHANGE,function(e,t,i){e===BI.Events.CLICK&&(n._checkAllSelected(),n.fireEvent(BI.SelectList.EVENT_CHANGE,t,i)),n.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(e.direction),BI.extend({scrolly:!0},e.logic,{items:BI.LogicFactory.createLogicItemsByDirection(e.direction,this.toolbar,this.list)})))),e.items.length<=0&&(this.toolbar.setVisible(!1),this.toolbar.setEnable(!1)),BI.isNotNull(e.value)&&this.setValue(e.value)},_checkAllSelected:function(){var e=this.list.getValue().length,t=this.getAllLeaves().length-e,i=this.list.hasNext(),n=this.toolbar.isSelected(),r=(r=0<e&&(0<t||!n&&i))||0<t&&i&&n;this.toolbar.setHalfSelected(r),r||this.toolbar.setSelected(0<e&&t<=0&&(!i||n))},setAllSelected:function(i){BI.each(this.getAllButtons(),function(e,t){(t.setSelected||t.setAllSelected).apply(t,[i])}),this.allSelected=!!i,this.toolbar.setSelected(i),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 i=this,e=this.options;BI.LazyLoader.superclass._init.apply(this,arguments);var t=e.items.length;this.loader=BI.createWidget({type:"bi.loader",element:this,el:e.el,itemsCreator:function(e,t){t(i._getNextItems(e))},hasNext:function(e){return e.count<t}}),this.loader.on(BI.Loader.EVENT_CHANGE,function(e){i.fireEvent(BI.LazyLoader.EVENT_CHANGE,e)})},_getNextItems:function(e){var t=this.options,i=t.items.length-this._const.PAGE*(e.times-1),n=BI.takeRight(t.items,i);return BI.take(n,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 n=this,e=this.options;!1===e.itemsCreator&&(e.next=!1),this.button_group=BI.createWidget(e.el,{type:"bi.button_group",element:this,chooseType:0,items:e.items,behaviors:{},layouts:[{type:"bi.vertical"}]}),this.button_group.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.ListLoader.EVENT_CHANGE,i)}),!1!==e.next&&(this.next=BI.createWidget(BI.extend({type:"bi.loading_bar"},e.next)),this.next.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&n._nextLoad()})),BI.createWidget({type:"bi.vertical",element:this,items:[this.next]}),e.isDefaultInit&&BI.isEmpty(e.items)&&BI.nextTick(BI.bind(function(){this.populate()},this)),BI.isNotEmptyArray(e.items)&&this.populate(e.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,i=this.options;0===arguments.length&&BI.isFunction(i.itemsCreator)?i.itemsCreator.apply(this,[{times:1},function(){if(0===arguments.length)throw new Error("参数不能为空");t.populate.apply(t,arguments),i.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 n=this,i=this.options;this.loader=BI.createWidget({type:"bi.list_loader",element:this,isDefaultInit:i.isDefaultInit,el:i.el,items:this._formatItems(i.items),itemsCreator:function(e,t){i.itemsCreator(e,function(e){t(n._formatItems(e))})},onLoaded:i.onLoaded,count:i.count,next:i.next,hasNext:i.hasNext}),this.loader.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.SortList.EVENT_CHANGE,t,i)}),this.loader.element.sortable({containment:i.containment||this.element,connectWith:i.connectWith||".bi-sort-list",items:".sort-item",cursor:i.cursor||"drag",tolerance:i.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(e,t){n.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(){BI.Pane.superclass._mount.apply(this,arguments)&&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})},_init:function(){BI.AllCountPager.superclass._init.apply(this,arguments);var e=this,t=this.options,i=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 "+i.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 "+i.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.left_right_vertical_adapt",element:this,items:{left:[this._getRowCountObject()],right:[this.editor,this.allPages,this.pager]}}:{type:"bi.vertical_adapt",element:this,items:[this.editor,this.allPages,this.pager]})},alwaysShowPager:!0,_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 t=this,e=this.options;return{type:"bi.left",height:e.height,scrollable:!1,ref:function(e){t.rowCountObject=e},items:[{type:"bi.label",height:e.height,text:BI.i18nText("BI-Basic_Total"),ref:function(e){t.prevText=e}},{type:"bi.label",ref:function(e){t.rowCount=e},cls:"row-count",height:e.height,hgap:5,text:e.count,title:e.count},{type:"bi.label",height:e.height,text:BI.i18nText("BI-Tiao_Data"),width:40,textAlign:"left"},BI.isNotEmptyObject(e.rowInfoObject)?e.rowInfoObject:null]}},setAllPages:function(e){this.allPages.setText("/"+e),this.allPages.setTitle(e),this.options.pages=e,this.pager.setAllPages(e),this.editor.setEnable(1<=e),this.setPagerVisible(1<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()},setPagerVisible:function(e){this.editor.setVisible(e),this.allPages.setVisible(e),this.pager.setVisible(e)},setRowCountVisible:function(e){this.rowCountObject.setVisible(e)},populate:function(){this.pager.populate(),this.setPagerVisible(1<this.options.pages)}}),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 i=[86,110,0,24],n=this.layout.attr("items");!0===e&&!0===t?(n[0].right=i[0],n[1].right=i[1],n[2].right=i[2],n[3].right=i[3]):!0===e?(n[0].right=i[2],n[1].right=i[3]):!0===t&&(n[2].right=i[2],n[3].right=i[3]),this.layout.attr("items",n),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 r=this,a=this.options,e=[],t={};this.empty();var i,o=BI.result(a,"pages"),n=BI.result(this,"currPage"),s=BI.result(a,"groups"),l=BI.result(a,"first"),u=BI.result(a,"last"),c=BI.result(a,"prev"),h=BI.result(a,"next");!1===o?(s=0,u=l=!1):o<s&&(s=o),t.index=Math.ceil((n+(1<s&&s!==o?1:0))/(0===s?1:s)),(!a.dynamicShow&&!a.dynamicShowPrevNext||1<n)&&!1!==c&&(BI.isKey(c)?e.push({text:c,value:"prev",disabled:!1===o?!1===a.hasPrev(n):!(1<n&&!1!==c)}):e.push(BI.extend({disabled:!1===o?!1===a.hasPrev(n):!(1<n&&!1!==c)},c))),(!a.dynamicShow&&!a.dynamicShowFirstLast||1<t.index&&0!==s)&&l&&(e.push({text:l,value:"first",disabled:!(1<t.index&&0!==s)}),1<t.index&&0!==s&&e.push({type:"bi.label",cls:"page-ellipsis",text:"…"})),t.poor=Math.floor((s-1)/2),t.start=1<t.index?n-t.poor:1,t.end=1<t.index?(i=n+(s-t.poor-1),o<i?o:i):s,t.end-t.start<s-1&&(t.start=t.end-s+1);var p=t.start,d=t.end;for(l&&u&&1<t.index&&0!==s&&s<o&&t.end<o&&0!==s&&(p++,d--);p<=d;p++)p===n?e.push({text:p,value:p,selected:!0}):e.push({text:p,value:p});(!a.dynamicShow&&!a.dynamicShowFirstLast||s<o&&t.end<o&&0!==s)&&u&&(s<o&&t.end<o&&0!==s&&e.push({type:"bi.label",cls:"page-ellipsis",text:"…"}),e.push({text:u,value:"last",disabled:!(s<o&&t.end<o&&0!==s)})),t.flow=!c&&0===s,(!a.dynamicShow&&!a.dynamicShowPrevNext&&h||n!==o&&h||t.flow)&&e.push(BI.isKey(h)?!1===o?{text:h,value:"next",disabled:!1===a.hasNext(n)}:t.flow&&n===o?{text:h,value:"next",disabled:!0}:{text:h,value:"next",disabled:!(n!==o&&h||t.flow)}:BI.extend({disabled:!1===o?!1===a.hasNext(n):!(n!==o&&h||t.flow)},h)),this.button_group=BI.createWidget({type:"bi.button_group",element:this,items:BI.createItems(e,{cls:"page-item bi-border bi-list-item-active",height:23,hgap:10}),behaviors:a.behaviors,layouts:a.layouts}),this.button_group.on(BI.Controller.EVENT_CHANGE,function(e,t,i){if(!0!==r._lock){if(r._lock=!0,r._debouce(),e===BI.Events.CLICK){var n=r.button_group.getValue()[0];switch(n){case"first":r.currPage=1;break;case"last":r.currPage=o;break;case"prev":r.currPage--;break;case"next":r.currPage++;break;default:r.currPage=n}a.jump.apply(r,[{pages:o,curr:r.currPage}]),r._populate(),r.fireEvent(BI.DetailPager.EVENT_CHANGE,i)}r.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):1<e},hasNext:function(e){e=e||1;var t=this.options,i=this.options.pages;return!1===i?t.hasNext(e):e<i},setValue:function(e){var t,i,n=this.options;e=(e=e||0)<1?1:e,!1===n.pages?(t=BI.result(n,"lastPage"),i=1,this.currPage=t<e?t:e<(i=BI.result(n,"firstPage"))?i:e):(e=e>n.pages?n.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 i=this,e=this.options;this.buttonGroup=BI.createWidget({element:this,type:"bi.button_group",value:e.value,items:BI.createItems(e.items,{type:"bi.segment_button",height:e.height-2,whiteSpace:e.whiteSpace}),layout:[{type:"bi.center"}]}),this.buttonGroup.on(BI.Controller.EVENT_CHANGE,function(){i.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.buttonGroup.on(BI.ButtonGroup.EVENT_CHANGE,function(e,t){i.fireEvent(BI.Segment.EVENT_CHANGE,e,t)})},_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 0<e.length},halfSelected:!1,iconWrapperWidth:26,iconWidth:16,iconHeight:16})},_init:function(){BI.MultiSelectBar.superclass._init.apply(this,arguments);var e=this,t=this.options,i=!0===t.selected,n=!t.selected&&t.halfSelected;this.checkbox=BI.createWidget({type:"bi.checkbox",stopPropagation:!0,handler:function(){e.setSelected(e.isSelected())},selected:i,invisible:n,iconWidth:t.iconWidth,iconHeight:t.iconHeight}),this.half=BI.createWidget({type:"bi.half_icon_button",stopPropagation:!0,handler:function(){e.setSelected(!0)},invisible:i||!n,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(n,r,a){var o=this;return BI.each(n,function(e,t){var i={layer:r};BI.isKey(t.id)||(t.id=BI.UUID()),i.pNode=a,!0===t.isParent||!0===t.parent||BI.isNotEmptyArray(t.children)?(i.type="bi.mid_plus_group_node",e===n.length-1&&(i.type="bi.last_plus_group_node",i.isLastNode=!0),0!==e||a||(i.type="bi.first_plus_group_node"),0===e&&e===n.length-1&&(i.type="bi.plus_group_node"),BI.defaults(t,i),o._formatItems(t.children,r+1,t)):(i.type="bi.mid_tree_leaf_item",0!==e||a||(i.type="bi.first_tree_leaf_item"),e===n.length-1&&(i.type="bi.last_tree_leaf_item"),BI.defaults(t,i))}),n},_assertId:function(e){BI.each(e,function(e,t){BI.isKey(t.id)||(t.id=BI.UUID())})},initTree:function(e){var n=this,t=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"}},t.expander),items:this._formatItems(BI.Tree.transformToTreeFormat(e),0),value:t.value,el:BI.extend({type:"bi.button_tree",chooseType:0,layouts:[{type:"bi.vertical"}]},t.el)}),this.tree.on(BI.Controller.EVENT_CHANGE,function(e,t,i){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&n.fireEvent(BI.LevelTree.EVENT_CHANGE,t,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 i;i=BI.inherit(BI.Widget,{props:{baseCls:"bi-tree-expander",layer:0,isLastNode:!1,isFirstNode:!1,selectable:!1},render:function(){var t=this,i=this.options;return this.trigger=BI.createWidget(i.el,{forceNotSelected:!i.selectable}),this.trigger.on(BI.Controller.EVENT_CHANGE,function(e){i.selectable&&t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),{type:"bi.expander",ref:function(e){t.expander=e},trigger:i.selectable?"":"click",el:this.trigger,isDefaultInit:i.isDefaultInit,popup:{type:"bi.tree_expander.popup",layer:i.layer||i.el.layer,isLastNode:i.isLastNode||i.el.isLastNode,isFirstNode:i.isFirstNode||i.el.isFirstNode,el:i.popup},value:i.value,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(e){t.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",i)},function(e,t){var i;i=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",i)},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 t=this,e=this.options;this._const;this.text=BI.createWidget({type:"bi.label",cls:"select-text-label"+(BI.isKey(e.textCls)?" "+e.textCls:""),textAlign:"left",height:e.height,text:e.text}),this.trigerButton=BI.createWidget({type:"bi.trigger_icon_button",width:e.triggerWidth||e.height}),BI.createWidget({element:this,type:"bi.htape",ref:function(e){t.wrapper=e},items:[{el:{type:"bi.icon_change_button",cls:"icon-combo-trigger-icon",iconCls:e.iconCls,ref:function(e){t.icon=e},iconHeight:e.iconHeight,iconWidth:e.iconWidth,disableSelected:!0},width:BI.isEmptyString(e.iconCls)?0:e.iconWrapperWidth||e.height},{el:this.text,lgap:BI.isEmptyString(e.iconCls)?5:0},{el:this.trigerButton,width:e.triggerWidth||e.height}]})},setValue:function(e){this.text.setValue(e)},setIcon:function(e){var t=this.options;this.icon.setIcon(e);var i=this.wrapper.attr("items")[0],n=this.wrapper.attr("items")[1];BI.isNull(e)||BI.isEmptyString(e)?0!==i.width&&(i.width=0,n.lgap=5,this.wrapper.resize()):i.width!==(t.iconWrapperWidth||t.height)&&(i.width=t.iconWrapperWidth||t.height,n.lgap=0,this.wrapper.resize())},setTextCls:function(e){var t=this.options,i=t.textCls;t.textCls=e,this.text.element.removeClass(i).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(i,e){var n,t=this.options;i=BI.isArray(i)?i:[i];var r=BI.Tree.transformToArrayFormat(e);return BI.any(r,function(e,t){if(BI.deepContains(i,t.value))return n={text:t.text||t.value,iconCls:t.iconCls},!0}),BI.isNotNull(n)?{text:n.text,textCls:"",iconCls:n.iconCls}:{text:BI.isFunction(t.text)?t.text():t.text,textCls:"bi-water-mark",iconCls:t.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,i=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:i.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}]})},setTextCls:function(e){var t=this.options,i=t.textCls;t.textCls=e,this.text.element.removeClass(i).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(i,e){var t=this.options;i=BI.isArray(i)?i:[i];var n=[],r=BI.Tree.transformToArrayFormat(e);return BI.each(r,function(e,t){BI.deepContains(i,t.value)&&!BI.contains(n,t.text||t.value)&&n.push(t.text||t.value)}),0<n.length?{textCls:"",text:n.join(",")}:{textCls:"bi-water-mark",text:BI.isFunction(t.text)?t.text():t.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)},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-2,text:t.text,cls:t.cls})},_digest:function(i,e){var t=this.options;i=BI.isArray(i)?i:[i];var n=[],r=BI.Tree.transformToArrayFormat(e);return BI.each(r,function(e,t){BI.deepContains(i,t.value)&&!BI.contains(n,t.text||t.value)&&n.push(t.text||t.value)}),0<n.length?{cls:"",text:n.join(",")}:{cls:"bi-water-mark",text:t.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 i=this._getAllowMonths();return BI.contains(i,t)||(t=e||i[0]),this.month.setValue(t),t},_getAllowMonths:function(){var i=this._getCheckMinMaxDate(),n=this.year.getValue()||this._year;return BI.filter(BI.range(1,13),function(e,t){return!BI.checkDateVoid(n,t,1,i.min,i.max)[0]})},_checkLeftValid:function(){var e=this._getCheckMinMaxDate(),t=1===this._month?this._year-1:this._year,i=1===this._month?12:this._month-1,n=BI.isNull(BI.checkDateVoid(t,i,1,e.min,e.max)[0]);return this.left.setEnable(n),n},_checkRightValid:function(){var e=this._getCheckMinMaxDate(),t=12===this._month?this._year+1:this._year,i=12===this._month?1:this._month+1,n=BI.isNull(BI.checkDateVoid(t,i,1,e.min,e.max)[0]);return this.right.setEnable(n),n},_getCheckMinMaxDate:function(){var e=this.options,t=BI.parseDateTime(e.min,"%Y-%X-%d"),i=BI.parseDateTime(e.max,"%Y-%X-%d");return t.setDate(1),i.setDate(1),{min:BI.print(t,"%Y-%X-%d"),max:BI.print(i,"%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 i=this.options;BI.each(this.calendar.getAllCard(),function(e,t){t.setMinDate(i.min)})},_checkMax:function(){var i=this.options;BI.each(this.calendar.getAllCard(),function(e,t){t.setMaxDate(i.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 i=this,e=this.options;this.selectedMonth=BI.getDate().getMonth()+1,this.month=BI.createWidget({type:"bi.button_group",element:this,behaviors:e.behaviors,items:BI.createItems(this._getItems(e.allowMonths),{}),layouts:[BI.LogicFactory.createLogic("table",BI.extend({dynamic:!0},{columns:2,rows:6,columnSize:[.5,.5],rowSize:25})),{type:"bi.center_adapt",vgap:1,hgap:2}],value:e.value}),this.month.on(BI.Controller.EVENT_CHANGE,function(e,t){i.selectedMonth=t,i.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&i.fireEvent(BI.MonthPopup.EVENT_CHANGE)})},_getItems:function(i){var e=[1,7,2,8,3,9,4,10,5,11,6,12],t=[];return t.push(e.slice(0,2)),t.push(e.slice(2,4)),t.push(e.slice(4,6)),t.push(e.slice(6,8)),t.push(e.slice(8,10)),t.push(e.slice(10,12)),t=BI.map(t,function(e,t){return BI.map(t,function(e,t){return{type:"bi.text_item",cls:"bi-list-item-select",textAlign:"center",whiteSpace:"nowrap",once:!1,forceSelected:!0,height:23,width:38,value:t,text:t,disabled:!BI.contains(i,t)}})})},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,i=this._year,n=BI.createWidget({type:"bi.year_calendar",behaviors:t.behaviors,min:t.min,max:t.max,logic:{dynamic:!0},year:i+12*e});return n.setValue(this._year),n},_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 n=this,e=this.options;this.today=BI.getDate(),this._year=this.today.getFullYear(),this._month=this.today.getMonth()+1,this.selectedTime=e.selectedTime||{year:this._year,month:this._month},this.datePicker=BI.createWidget({type:"bi.date_picker",behaviors:e.behaviors,min:e.min,max:e.max}),this.datePicker.on(BI.DatePicker.EVENT_CHANGE,function(){var e=n.datePicker.getValue(),t=BI.getMonthDays(BI.getDate(e.year,e.month-1,1)),i=n.selectedTime.day||0;t<i&&(i=t),n.selectedTime={year:e.year,month:e.month},0!==i&&(n.selectedTime.day=i),n.calendar.setSelect(BI.Calendar.getPageByDateJSON(n.selectedTime)),n.calendar.setValue(n.selectedTime),0!==i&&n.fireEvent(BI.DateCalendarPopup.EVENT_CHANGE)}),this.datePicker.on(BI.DatePicker.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,function(){n.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(){n.selectedTime=n.calendar.getValue(),n.calendar.empty(),n.setValue(n.selectedTime),n.fireEvent(BI.DateCalendarPopup.EVENT_CHANGE)}),this.setValue(e.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 i=this.options;BI.each(this.calendar.getAllCard(),function(e,t){t.setMinDate(i.min)})},_checkMax:function(){var i=this.options;BI.each(this.calendar.getAllCard(),function(e,t){t.setMaxDate(i.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 i=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 e=this.getValue()[0];switch(i.dateTab.setSelect(e),e){case BI.DynamicDatePane.Static:var t=BI.DynamicDateHelper.getCalculation(i.dynamicPane.getValue());i.ymd.setValue({year:t.getFullYear(),month:t.getMonth()+1,day:t.getDate()});break;case BI.DynamicDatePane.Dynamic:i.dynamicPane.setValue({year:0})}i.fireEvent(BI.DynamicDatePane.EVENT_CHANGE)}}],ref:function(){i.switcher=this}},height:t.supportDynamic?30:0},{type:"bi.tab",ref:function(){i.dateTab=this},showIndex:BI.DynamicDatePane.Static,cardCreator:function(e){switch(e){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(){i.fireEvent(BI.DynamicDatePane.EVENT_CHANGE)}},{eventName:"EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",action:function(){i.fireEvent(BI.DynamicDatePane.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}],ref:function(){i.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(){i.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(){i.setValue(),i.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(){i.dateTab.getSelect()===BI.DynamicDateCombo.Dynamic?i.dynamicPane.checkValidation(!0)&&i.fireEvent(BI.DynamicDatePopup.EVENT_CHANGE):i.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,i=(e=e||{}).type||BI.DynamicDateCombo.Static,n=e.value||e;switch(this.switcher.setValue(i),this.dateTab.setSelect(i),i){case BI.DynamicDateCombo.Dynamic:this.dynamicPane.setValue(n);break;case BI.DynamicDateCombo.Static:default:this._checkValueValid(n)?(t=BI.getDate(),this.ymd.setValue({year:t.getFullYear(),month:t.getMonth()+1})):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,i=BI.getDate();this.storeValue=BI.isNotNull(t.value)?t.value:{year:i.getFullYear(),month:i.getMonth()+1,day:i.getDate(),hour:i.getHours(),minute:i.getMinutes(),second:i.getSeconds()},this.trigger=BI.createWidget({type:"bi.date_time_trigger",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===n.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 n=BI.createWidget({type:"bi.icon_button",cls:"bi-trigger-icon-button date-font",width:24,height:24});n.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:n,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 t=this,e=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(){t.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(){t.fireEvent(BI.DateTimePopup.BUTTON_OK_EVENT_CHANGE)}),this.dateCombo=BI.createWidget({type:"bi.date_calendar_popup",behaviors:e.behaviors,min:t.options.min,max:t.options.max}),t.dateCombo.on(BI.DateCalendarPopup.EVENT_CHANGE,function(){t.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(e){t.timeSelect=e}}]},height:50},{el:this.dateButton,height:30}]}),this.setValue(e.value)},setValue:function(e){var t,i=e;BI.isNull(i)?(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:i.year,month:i.month,day:i.day}),this.timeSelect.setValue({hour:i.hour,minute:i.minute,second:i.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,i,n=e;i=BI.isNull(n)?(n=BI.getDate(),BI.print(n,"%Y-%X-%d %H:%M:%S")):(t=BI.getDate(n.year,n.month-1,n.day,n.hour,n.minute,n.second),BI.print(t,"%Y-%X-%d %H:%M:%S")),this.text.setText(i),this.text.setTitle(i)}}),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 n=this,e=this.options;this.today=BI.getDate(),this._year=this.today.getFullYear(),this._month=this.today.getMonth()+1,this.selectedTime=e.selectedTime||{year:this._year,month:this._month},this.datePicker=BI.createWidget({type:"bi.date_picker",behaviors:e.behaviors,min:e.min,max:e.max}),this.datePicker.on(BI.DatePicker.EVENT_CHANGE,function(){var e=n.datePicker.getValue(),t=BI.getMonthDays(BI.getDate(e.year,e.month-1,1)),i=n.selectedTime.day||0;t<i&&(i=t),n.selectedTime=BI.extend(n.selectedTime,{year:e.year,month:e.month}),0!==i&&(n.selectedTime.day=i),n.calendar.setSelect(BI.Calendar.getPageByDateJSON(n.selectedTime)),n.calendar.setValue(n.selectedTime),0!==i&&n.fireEvent(BI.DateCalendarPopup.EVENT_CHANGE)}),this.datePicker.on(BI.DatePicker.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,function(){n.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(){n.selectedTime=BI.extend(n.calendar.getValue(),n.timeSelect.getValue()),n.calendar.empty(),n.setValue(n.selectedTime),n.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(){n.timeSelect=this},listeners:[{eventName:BI.DynamicDateTimeSelect.EVENT_CONFIRM,action:function(){n.selectedTime=BI.extend(n.calendar.getValue(),n.timeSelect.getValue()),n.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(e.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 i=this.options;BI.each(this.calendar.getAllCard(),function(e,t){t.setMinDate(i.min)})},_checkMax:function(){var i=this.options;BI.each(this.calendar.getAllCard(),function(e,t){t.setMaxDate(i.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 i=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 e=this.getValue()[0];switch(i.dateTab.setSelect(e),e){case BI.DynamicDateTimePane.Static:var t=BI.DynamicDateHelper.getCalculation(i.dynamicPane.getValue());i.ymd.setValue({year:t.getFullYear(),month:t.getMonth()+1,day:t.getDate()});break;case BI.DynamicDateTimePane.Dynamic:i.dynamicPane.setValue({year:0})}i.fireEvent(BI.DynamicDateTimePane.EVENT_CHANGE)}}],ref:function(){i.switcher=this}},height:t.supportDynamic?30:0},{type:"bi.tab",ref:function(){i.dateTab=this},showIndex:BI.DynamicDateTimePane.Static,cardCreator:function(e){switch(e){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(){i.fireEvent(BI.DynamicDateTimePane.EVENT_CHANGE)}},{eventName:"EVENT_BEFORE_YEAR_MONTH_POPUPVIEW",action:function(){i.fireEvent(BI.DynamicDateTimePane.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}],ref:function(){i.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(){i.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(){i.setValue(),i.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(){i.dateTab.getSelect()===BI.DynamicDateCombo.Dynamic&&!i.dynamicPane.checkValidation(!0)||i.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,i=(e=e||{}).type||BI.DynamicDateTimePane.Static,n=e.value||e;switch(this.switcher.setValue(i),this.dateTab.setSelect(i),i){case BI.DynamicDateTimePane.Dynamic:this.dynamicPane.setValue(n);break;case BI.DynamicDateTimePane.Static:default:this._checkValueValid(n)?(t=BI.getDate(),this.ymd.setValue({year:t.getFullYear(),month:t.getMonth()+1})):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 i=this,e=this.options;this.popupview=BI.createWidget({type:"bi.down_list_popup",items:e.items,chooseType:e.chooseType,value:e.value}),this.popupview.on(BI.DownListPopup.EVENT_CHANGE,function(e){i.fireEvent(BI.DownListCombo.EVENT_CHANGE,e),i.downlistcombo.hideView()}),this.popupview.on(BI.DownListPopup.EVENT_SON_VALUE_CHANGE,function(e,t){i.fireEvent(BI.DownListCombo.EVENT_SON_VALUE_CHANGE,e,t),i.downlistcombo.hideView()}),this.downlistcombo=BI.createWidget({element:this,type:"bi.combo",trigger:e.trigger,isNeedAdjustWidth:!1,container:e.container,adjustLength:e.adjustLength,direction:e.direction,belowMouse:e.belowMouse,stopPropagation:e.stopPropagation,el:BI.createWidget(e.el,{type:"bi.icon_trigger",extraCls:e.iconCls,width:e.width,height:e.height}),popup:{el:this.popupview,stopPropagation:e.stopPropagation,maxHeight:e.maxHeight,minWidth:e.minWidth}}),this.downlistcombo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){i.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:24,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 i=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,i)})))),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("_").length:0},_digest:function(e){var i=this.options;e=BI.isArray(e)?e:[e];var n=this._getLevel();return BI.any(e,function(e,t){return BI.contains(i.childValues,(t+"").split("_").slice(0,n).join("_"))})},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 a=this,e=this.options,t=this._createChildren(this.items);this.popup=BI.createWidget({type:"bi.button_tree",items:BI.createItems(t,{},{adjustLength:-2}),layouts:[{type:"bi.vertical",hgap:this.constants.hgap,vgap:this.constants.vgap}],value:this._digest(e.value),chooseType:e.chooseType}),this.popup.on(BI.ButtonTree.EVENT_CHANGE,function(e,t){var i,n,r=e;BI.isNotNull(a.childValueMap[e])?(r=a.childValueMap[e],a.fireEvent(BI.DownListPopup.EVENT_SON_VALUE_CHANGE,r,a.fatherValueMap[e])):a.fireEvent(BI.DownListPopup.EVENT_CHANGE,r,t),BI.contains(a.singleValues,r)||(i=a.getValue(),n=[],BI.each(i,function(e,t){t.value!=r&&n.push(t)}),a.setValue(n))}),BI.createWidget({type:"bi.vertical",element:this,items:[this.popup],vgap:5})},_createChildren:function(r){var a=this,o=[];return BI.each(r,function(e,t){var i,n={type:"bi.down_list_group",items:[]};BI.each(t,function(e,r){BI.isNotEmptyArray(r.children)&&!BI.isEmpty(r.el)?(r.type="bi.combo_group",r.isDefaultInit=!0,r.cls="down-list-group",r.trigger="hover",r.isNeedAdjustWidth=!1,r.el.title=r.el.title||r.el.text,r.el.type="bi.down_list_group_item",r.el.logic={dynamic:!0},r.el.height=r.el.height||a.constants.height,r.el.iconCls2=a.constants.nextIcon,r.popup={lgap:1,el:{type:"bi.button_tree",chooseType:0,layouts:[{type:"bi.vertical"}]},innerVGap:5,maxHeight:378},r.el.childValues=[],BI.each(r.children,function(e,t){var i=BI.deepClone(r.el.value),n=BI.deepClone(t.value);a.singleValues.push(t.value),t.type=t.type||"bi.down_list_item",t.extraCls=" child-down-list-item",t.title=t.title||t.text,t.textRgap=10,t.isNeedAdjustWidth=!1,t.logic={dynamic:!0},t.father=i,a.fatherValueMap[a._createChildValue(i,n)]=i,a.childValueMap[a._createChildValue(i,n)]=n,t.value=a._createChildValue(i,n),r.el.childValues.push(t.value)})):(r.type=r.type||"bi.down_list_item",r.title=r.title||r.text,r.textRgap=10,r.isNeedAdjustWidth=!1,r.logic={dynamic:!0});var t={};t.el=r,n.items.push(t)}),a._isGroup(n.items)&&BI.each(n.items,function(e,t){a.singleValues.push(t.el.value)}),o.push(n),a._needSpliter(e,r.length)&&(i=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}),o.push(i))}),o},_isGroup:function(e){return 1<e.length},_needSpliter:function(e,t){return e<t-1},_createChildValue:function(e,t){return e+"_"+t},_digest:function(e){var n=this,r=[];return BI.each(e,function(e,t){var i=BI.isNotNull(t.childValue)?n._createChildValue(t.value,t.childValue):t.value;r.push(i)}),r},_checkValues:function(l){var u=[];return BI.each(this.items,function(s,e){BI.each(e,function(e,t){var i,n,r,a,o;BI.isNotNull(t.children)?(i=BI.map(t.children,"value"),r=i,a=l[s],o="",BI.some(r,function(e,i){return BI.some(a,function(e,t){if(i===t)return o=i,!0})}),n=o,BI.isNotEmptyString(n)&&u.push(n)):t.value===l[s][0]&&u.push(l[s][0])})}),u},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),i=BI.createItems(t,{},{adjustLength:-2});this.popup.populate(i)},setValue:function(e){this.popup.setValue(this._digest(e))},_getValue:function(){var i=[];return BI.each(this.popup.getAllButtons(),function(e,t){e%2==0&&i.push(t.getValue())}),i},getValue:function(){var r=this,a=[],e=this._checkValues(this._getValue());return BI.each(e,function(e,t){var i,n={};BI.isNotNull(r.childValueMap[t])?(i=r.fatherValueMap[t],n.childValue=r.childValueMap[t],n.value=i):n.value=t,a.push(n)}),a}}),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)},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 i=Math.abs(t.workDay),n=0;n<i;n++)e=BI.getOffsetDate(e,t.workDay<0?-1:1),BI.isNotNull(BI.holidays[BI.print(e,"%Y-%X-%d")])&&n--;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 n={};BI.each(e.resultPane.getAllButtons(),function(e,t){var i=t.getValue();BI.isNotNull(i.dateType)&&(n[i.dateType]={value:i.value,offset:i.offset})}),e.resultPane.populate(e._getParamJson(BI.map(e.checkgroup.getValue(),function(e,t){var i={dateType:t};return BI.has(n,t)&&(i.value=n[t].value,i.offset=n[t].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 i,n=this,r=(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}}));return 1===e.length&&e[0].dateType===BI.DynamicDateCard.TYPE.DAY?((i=this._getText(BI.DynamicDateCard.TYPE.MONTH))[0].text=BI.i18nText("BI-Basic_Empty"),r.push({type:"bi.text_value_combo",height:24,items:i,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")}}]})):0!==e.length&&BI.last(e).dateType!==BI.DynamicDateCard.TYPE.DAY&&BI.last(e).dateType!==BI.DynamicDateCard.TYPE.WORK_DAY&&r.push({type:"bi.text_value_combo",height:24,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")}}]}),r},_checkDate:function(e){var t=this.options,i=BI.DynamicDateHelper.getCalculation(BI.extend(this._getValue(),this._digestDateTypeValue(e)));return!BI.checkDateVoid(i.getFullYear(),i.getMonth()+1,i.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:0<t?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=[],i=[];BI.isNotNull(e.year)&&(t.push(BI.DynamicDateCard.TYPE.YEAR),i.push(this._createValue(BI.DynamicDateCard.TYPE.YEAR,e.year))),BI.isNotNull(e.quarter)&&(t.push(BI.DynamicDateCard.TYPE.QUARTER),i.push(this._createValue(BI.DynamicDateCard.TYPE.QUARTER,e.quarter))),BI.isNotNull(e.month)&&(t.push(BI.DynamicDateCard.TYPE.MONTH),i.push(this._createValue(BI.DynamicDateCard.TYPE.MONTH,e.month))),BI.isNotNull(e.week)&&(t.push(BI.DynamicDateCard.TYPE.WEEK),i.push(this._createValue(BI.DynamicDateCard.TYPE.WEEK,e.week))),BI.isNotNull(e.day)&&(t.push(BI.DynamicDateCard.TYPE.DAY),i.push(this._createValue(BI.DynamicDateCard.TYPE.DAY,e.day))),BI.isNotNull(e.workDay)&&(t.push(BI.DynamicDateCard.TYPE.WORK_DAY),i.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(i,e.position))},_getValue:function(){var e,n=this,r={},t=this.checkgroup.getValue(),i=this.resultPane.getAllButtons();return 0!==t.length&&BI.each(i,function(e,t){var i=t.getValue();BI.extend(r,n._digestDateTypeValue(i))}),this.workDayBox.isSelected()&&(e=i[0].getValue(),r.workDay=0===e.offset?-e.value:+e.value),r},_getErrorText:function(){var e=this.options,t=BI.parseDateTime(e.min,"%Y-%X-%d"),i=BI.parseDateTime(e.max,"%Y-%X-%d");return BI.i18nText("BI-Basic_Date_Range_Error",t.getFullYear(),t.getMonth()+1,t.getDate(),i.getFullYear(),i.getMonth()+1,i.getDate())},getValue:function(){return this.checkValidation()?this._getValue():{}},getInputValue:function(){return this._getValue()},checkValidation:function(e){var t=this.resultPane.getAllButtons(),i=BI.any(t,function(e,t){return t.checkValidation&&!t.checkValidation()}),n=i?BI.i18nText("BI-Please_Input_Natural_Number"):(i=!this._checkDate(this._getValue()),this._getErrorText());return i&&e&&BI.Bubbles.show("dynamic-date-error",n,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(){this.options.height-=2,BI.DynamicDateCombo.superclass._init.apply(this,arguments)},render:function(){var i=this,e=this.options;this.storeTriggerValue="";var t=BI.getDate();return this.storeValue=e.value,{type:"bi.htape",items:[{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button date-change-h-font",width:e.height,height:e.height,ref:function(){i.changeIcon=this}},width:e.height},{type:"bi.absolute",items:[{el:{type:"bi.combo",container:e.container,ref:function(){i.combo=this},toggle:!1,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,destroyWhenHide:!0,el:{type:"bi.dynamic_date_trigger",min:e.minDate,max:e.maxDate,format:e.format,allowEdit:e.allowEdit,watermark:e.watermark,height:e.height,value:e.value,ref:function(){i.trigger=this},listeners:[{eventName:BI.DynamicDateTrigger.EVENT_KEY_DOWN,action:function(){i.combo.isViewVisible()&&i.combo.hideView(),i.fireEvent(BI.DynamicDateCombo.EVENT_KEY_DOWN,arguments)}},{eventName:BI.DynamicDateTrigger.EVENT_STOP,action:function(){i.combo.isViewVisible()||i.combo.showView()}},{eventName:BI.DynamicDateTrigger.EVENT_FOCUS,action:function(){i.storeTriggerValue=i.trigger.getKey(),i.combo.isViewVisible()||i.combo.showView(),i.fireEvent(BI.DynamicDateCombo.EVENT_FOCUS)}},{eventName:BI.DynamicDateTrigger.EVENT_BLUR,action:function(){i.fireEvent(BI.DynamicDateCombo.EVENT_BLUR)}},{eventName:BI.DynamicDateTrigger.EVENT_ERROR,action:function(){i.storeValue={type:BI.DynamicDateCombo.Static,value:{year:t.getFullYear(),month:t.getMonth()+1}},i.fireEvent(BI.DynamicDateCombo.EVENT_ERROR)}},{eventName:BI.DynamicDateTrigger.EVENT_VALID,action:function(){i.fireEvent(BI.DynamicDateCombo.EVENT_VALID)}},{eventName:BI.DynamicDateTrigger.EVENT_CHANGE,action:function(){i.fireEvent(BI.DynamicDateCombo.EVENT_CHANGE)}},{eventName:BI.DynamicDateTrigger.EVENT_CONFIRM,action:function(){var e=i.storeTriggerValue,t=i.trigger.getKey();i.combo.isViewVisible()||BI.isEqual(t,e)||(BI.isNotEmptyString(t)&&!BI.isEqual(t,e)?(i.storeValue=i.trigger.getValue(),i.setValue(i.trigger.getValue())):BI.isEmptyString(t)&&(i.storeValue=null,i.trigger.setValue()),i._checkDynamicValue(i.storeValue),i.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM))}}]},adjustLength:this.constants.comboAdjustHeight,popup:{el:{type:"bi.dynamic_date_popup",supportDynamic:e.supportDynamic,behaviors:e.behaviors,min:e.minDate,max:e.maxDate,ref:function(){i.popup=this},listeners:[{eventName:BI.DynamicDatePopup.BUTTON_CLEAR_EVENT_CHANGE,action:function(){i.setValue(),i.combo.hideView(),i.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDatePopup.BUTTON_lABEL_EVENT_CHANGE,action:function(){var e=BI.getDate();i.setValue({type:BI.DynamicDateCombo.Static,value:{year:e.getFullYear(),month:e.getMonth()+1,day:e.getDate()}}),i.combo.hideView(),i.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDatePopup.BUTTON_OK_EVENT_CHANGE,action:function(){var e=i.popup.getValue();i._checkValue(e)&&i.setValue(e),i.combo.hideView(),i.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDatePopup.EVENT_CHANGE,action:function(){i.setValue(i.popup.getValue()),i.combo.hideView(),i.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDatePopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,action:function(){i.fireEvent(BI.DynamicDateCombo.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}]},stopPropagation:!1},hideChecker:function(e){return 0===i.triggerBtn.element.find(e.target).length},listeners:[{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){i.popup.setMinDate(e.minDate),i.popup.setMaxDate(e.maxDate),i.popup.setValue(i.storeValue),i.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:e.height,height:e.height,listeners:[{eventName:BI.IconButton.EVENT_CHANGE,action:function(){i.combo.isViewVisible()||i.combo.showView()}}],ref:function(){i.triggerBtn=this}},top:0,right:0}]}],ref:function(e){i.comboWrapper=e}}},created:function(){this._checkDynamicValue(this.storeValue)},_checkDynamicValue:function(e){var t=this.options,i=null;switch(BI.isNotNull(e)&&(i=e.type),i){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 i=e.value||{};return!BI.checkDateVoid(i.year,i.month,i.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:{baseCls:"bi-dynamic-date-param-item",dateType:BI.DynamicDateCard.TYPE.YEAR,validationChecker:function(){return!0},value:0,offset:0,height:24},render:function(){var e=this,t=this.options;return{type:"bi.htape",items:[{el:{type:"bi.sign_editor",cls:"bi-border",height:22,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:24,text:this._getText()},width:t.dateType===BI.DynamicDateCard.TYPE.WORK_DAY?60:20},{type:"bi.text_value_combo",height:24,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,buttonHeight:24},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,i=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:i.buttonHeight-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:i.buttonHeight-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:i.buttonHeight-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)}}]}]],height:24}}]}),this.setValue(t.value)},_getTabJson:function(){var t=this,i=this.options;return{type:"bi.tab",logic:{dynamic:!0},ref:function(){t.dateTab=this},tab:{type:"bi.linear_segment",invisible:!i.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(e){switch(e){case BI.DynamicDateCombo.Dynamic:return{type:"bi.dynamic_date_card",cls:"dynamic-date-pane",listeners:[{eventName:"EVENT_CHANGE",action:function(){t._setInnerValue(t.year,e)}}],min:t.options.min,max:t.options.max,ref:function(){t.dynamicPane=this}};case BI.DynamicDateCombo.Static:default:return{type:"bi.date_calendar_popup",behaviors:i.behaviors,min:t.options.min,max:t.options.max,listeners:[{eventName:BI.DateCalendarPopup.EVENT_CHANGE,action:function(){t.fireEvent(BI.DynamicDatePopup.EVENT_CHANGE)}},{eventName:BI.DateCalendarPopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,action:function(){t.fireEvent(BI.DynamicDatePopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}],ref:function(){t.ymd=this}}}},listeners:[{eventName:BI.Tab.EVENT_CHANGE,action:function(){switch(t.dateTab.getSelect()){case BI.DynamicDateCombo.Static:var e=BI.DynamicDateHelper.getCalculation(t.dynamicPane.getValue());t.ymd.setValue({year:e.getFullYear(),month:e.getMonth()+1,day:e.getDate()}),t._setInnerValue();break;case BI.DynamicDateCombo.Dynamic:default:t.storeValue&&t.storeValue.type===BI.DynamicDateCombo.Dynamic?t.dynamicPane.setValue(t.storeValue.value):t.dynamicPane.setValue({year:0}),t._setInnerValue()}}}]}},_setInnerValue:function(){var e;this.dateTab.getSelect()===BI.DynamicDateCombo.Static?(this.todayButton.setValue(BI.i18nText("BI-Multi_Date_Today")),this.todayButton.setEnable(!this._checkTodayValid())):(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,i=(e=e||{}).type||BI.DynamicDateCombo.Static,n=e.value||e;switch(this.dateTab.setSelect(i),i){case BI.DynamicDateCombo.Dynamic:this.dynamicPane.setValue(n),this._setInnerValue();break;case BI.DynamicDateCombo.Static:default:this._checkValueValid(n)?(t=BI.getDate(),this.ymd.setValue({year:t.getFullYear(),month:t.getMonth()+1,day:t.getDate()})):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 n=this,r=this.options,e=this._const;this.storeTriggerValue="",this.editor=BI.createWidget({type:"bi.sign_editor",height:r.height,validationChecker:function(e){var t=n._getStandardDateStr(e),i=t.match(/\d+/g);return BI.isKey(r.format)||n._autoAppend(e,i),n._dateCheck(t)&&BI.checkDateLegal(t)&&n._checkVoid({year:0|i[0],month:0|i[1],day:0|i[2]})},quitChecker:function(){return!1},hgap:e.hgap,vgap:e.vgap,allowBlank:!0,watermark:BI.isKey(r.watermark)?r.watermark:BI.i18nText("BI-Basic_Unrestricted"),errorText:function(){var e="";return BI.isKey(r.format)||(e=n.editor.isEditing()?BI.i18nText("BI-Date_Trigger_Error_Text"):BI.i18nText("BI-Year_Trigger_Invalid_Text")),e},title:BI.bind(this._getTitle,this)}),this.editor.on(BI.SignEditor.EVENT_KEY_DOWN,function(){n.fireEvent(BI.DynamicDateTrigger.EVENT_KEY_DOWN,arguments)}),this.editor.on(BI.SignEditor.EVENT_FOCUS,function(){n.storeTriggerValue=n.getKey(),n.fireEvent(BI.DynamicDateTrigger.EVENT_FOCUS)}),this.editor.on(BI.SignEditor.EVENT_BLUR,function(){n.fireEvent(BI.DynamicDateTrigger.EVENT_BLUR)}),this.editor.on(BI.SignEditor.EVENT_STOP,function(){n.fireEvent(BI.DynamicDateTrigger.EVENT_STOP)}),this.editor.on(BI.SignEditor.EVENT_VALID,function(){n.fireEvent(BI.DynamicDateTrigger.EVENT_VALID)}),this.editor.on(BI.SignEditor.EVENT_ERROR,function(){n.fireEvent(BI.DynamicDateTrigger.EVENT_ERROR)}),this.editor.on(BI.SignEditor.EVENT_CONFIRM,function(){var e,t=n.editor.getValue();BI.isNotNull(t)&&n.editor.setState(t),BI.isNotEmptyString(t)&&!BI.isEqual(n.storeTriggerValue,n.getKey())&&(e=n._getStandardDateStr(t).match(/\d+/g),n.storeValue={type:BI.DynamicDateCombo.Static,value:{year:0|e[0],month:0|e[1],day:0|e[2]}}),n.fireEvent(BI.DynamicDateTrigger.EVENT_CONFIRM)}),this.editor.on(BI.SignEditor.EVENT_SPACE,function(){n.editor.isValid()&&n.editor.blur()}),this.editor.on(BI.SignEditor.EVENT_START,function(){n.fireEvent(BI.DynamicDateTrigger.EVENT_START)}),this.editor.on(BI.SignEditor.EVENT_CHANGE,function(){n.fireEvent(BI.DynamicDateTrigger.EVENT_CHANGE)}),BI.createWidget({type:"bi.htape",element:this,items:[{el:this.editor},{el:BI.createWidget(),width:24}]}),r.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(r.value)},_getTitle:function(){var e=this.storeValue||{},t=e.type||BI.DynamicDateCombo.Static,i=e.value;switch(t){case BI.DynamicDateCombo.Dynamic:var n=this._getText(i),r=BI.getDate(),r=BI.DynamicDateHelper.getCalculation(i),a=BI.print(r,this._getFormatString());return BI.isEmptyString(n)?a:n+":"+a;case BI.DynamicDateCombo.Static:default:return BI.isNull(i)||BI.isNull(i.day)?"":BI.print(BI.getDate(i.year,i.month-1,i.day),this._getFormatString())}},_getStandardDateStr:function(e){var t=this._const,i=[0,1,2],n=this._getFormatString().match(/%./g);BI.each(n,function(e,t){switch(t){case"%Y":case"%y":i[0]=e;break;case"%X":case"%x":i[1]=e;break;case"%d":case"%e":default:i[2]=e}});var r=BI.parseDateTime(e,this._getFormatString());BI.print(r,this._getFormatString())===e&&(e=BI.print(r,t.compareFormat),i=[0,1,2]);var a=e.match(/\d+/g),o=[];return BI.each(a,function(e){o[e]=a[i[e]]}),o.length===i.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 i=e.split("-")[1];(BI.isNotNull(i)&&2===i.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()),i=BI.print(t,this._const.compareFormat);return 0<=t.getMonth()&&(BI.print(BI.parseDateTime(e,"%Y-%X"),"%Y-%X")===e||BI.print(BI.parseDateTime(e,"%Y-%x"),"%Y-%x")===e)&&i>=this.options.min&&i<=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="",i="";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"))),i=n(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"))),i=n(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"))),i=n(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"))),i=n(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"))),i=1===BI.size(e)?n(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+i;function n(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")}}},setValue:function(e){var t,i,n,r=BI.getDate();switch(this.storeValue=e,BI.isNotNull(e)&&(t=e.type||BI.DynamicDateCombo.Static,i=e.value||e),t){case BI.DynamicDateCombo.Dynamic:var a=this._getText(i),r=BI.DynamicDateHelper.getCalculation(i);this._setInnerValue(r,a);break;case BI.DynamicDateCombo.Static:default:BI.isNull(i)||BI.isNull(i.day)?(this.editor.setState(""),this.editor.setValue("")):(n=BI.print(BI.getDate(i.year,i.month-1,i.day),this._getFormatString()),this.editor.setState(n),this.editor.setValue(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)},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(){this.options.height-=2,BI.DynamicDateTimeCombo.superclass._init.apply(this,arguments)},render:function(){var i=this,e=this.options;this.storeTriggerValue="";var t=BI.getDate();return this.storeValue=e.value,{type:"bi.htape",items:[{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button date-change-h-font",width:e.height,height:e.height,ref:function(){i.changeIcon=this}},width:e.height},{type:"bi.absolute",items:[{el:{type:"bi.combo",destroyWhenHide:!0,container:e.container,ref:function(){i.combo=this},toggle:!1,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,el:{type:"bi.dynamic_date_time_trigger",min:e.minDate,max:e.maxDate,allowEdit:e.allowEdit,watermark:e.watermark,format:e.format,height:e.height,value:e.value,ref:function(){i.trigger=this},listeners:[{eventName:BI.DynamicDateTimeTrigger.EVENT_KEY_DOWN,action:function(){i.combo.isViewVisible()&&i.combo.hideView(),i.fireEvent(BI.DynamicDateTimeCombo.EVENT_KEY_DOWN,arguments)}},{eventName:BI.DynamicDateTimeTrigger.EVENT_STOP,action:function(){i.combo.isViewVisible()||i.combo.showView()}},{eventName:BI.DynamicDateTimeTrigger.EVENT_TRIGGER_CLICK,action:function(){i.combo.toggle()}},{eventName:BI.DynamicDateTimeTrigger.EVENT_FOCUS,action:function(){i.storeTriggerValue=i.trigger.getKey(),i.combo.isViewVisible()||i.combo.showView(),i.fireEvent(BI.DynamicDateTimeCombo.EVENT_FOCUS)}},{eventName:BI.DynamicDateTimeTrigger.EVENT_BLUR,action:function(){i.fireEvent(BI.DynamicDateTimeCombo.EVENT_BLUR)}},{eventName:BI.DynamicDateTimeTrigger.EVENT_ERROR,action:function(){i.storeValue={type:BI.DynamicDateTimeCombo.Static,value:{year:t.getFullYear(),month:t.getMonth()+1}},i.fireEvent(BI.DynamicDateTimeCombo.EVENT_ERROR)}},{eventName:BI.DynamicDateTimeTrigger.EVENT_VALID,action:function(){i.fireEvent(BI.DynamicDateTimeCombo.EVENT_VALID)}},{eventName:BI.DynamicDateTimeTrigger.EVENT_CHANGE,action:function(){i.fireEvent(BI.DynamicDateTimeCombo.EVENT_CHANGE)}},{eventName:BI.DynamicDateTimeTrigger.EVENT_CONFIRM,action:function(){var e=i.storeTriggerValue,t=i.trigger.getKey();i.combo.isViewVisible()||BI.isEqual(t,e)||(BI.isNotEmptyString(t)&&!BI.isEqual(t,e)?(i.storeValue=i.trigger.getValue(),i.setValue(i.trigger.getValue())):BI.isEmptyString(t)&&(i.storeValue=null,i.trigger.setValue()),i._checkDynamicValue(i.storeValue),i.fireEvent(BI.DynamicDateTimeCombo.EVENT_CONFIRM))}}]},adjustLength:this.constants.comboAdjustHeight,popup:{el:{type:"bi.dynamic_date_time_popup",supportDynamic:e.supportDynamic,behaviors:e.behaviors,min:e.minDate,max:e.maxDate,ref:function(){i.popup=this},listeners:[{eventName:BI.DynamicDateTimePopup.BUTTON_CLEAR_EVENT_CHANGE,action:function(){i.setValue(),i.combo.hideView(),i.fireEvent(BI.DynamicDateTimeCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDateTimePopup.BUTTON_lABEL_EVENT_CHANGE,action:function(){var e=BI.getDate();i.setValue({type:BI.DynamicDateTimeCombo.Static,value:{year:e.getFullYear(),month:e.getMonth()+1,day:e.getDate(),hour:0,minute:0,second:0}}),i.combo.hideView(),i.fireEvent(BI.DynamicDateTimeCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDateTimePopup.BUTTON_OK_EVENT_CHANGE,action:function(){var e=i.popup.getValue();i._checkValue(e)&&i.setValue(e),i.combo.hideView(),i.fireEvent(BI.DynamicDateTimeCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDateTimePopup.EVENT_CHANGE,action:function(){i.setValue(i.popup.getValue()),i.combo.hideView(),i.fireEvent(BI.DynamicDateTimeCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicDateTimePopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,action:function(){i.fireEvent(BI.DynamicDateTimeCombo.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}]},stopPropagation:!1},listeners:[{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){i.popup.setMinDate(e.minDate),i.popup.setMaxDate(e.maxDate),i.popup.setValue(i.storeValue),i.fireEvent(BI.DynamicDateTimeCombo.EVENT_BEFORE_POPUPVIEW)}}],hideChecker:function(e){return 0===i.triggerBtn.element.find(e.target).length}},top:0,left:0,right:0,bottom:0},{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button date-font",width:e.height,height:e.height,listeners:[{eventName:BI.IconButton.EVENT_CHANGE,action:function(){i.combo.isViewVisible()||i.combo.showView()}}],ref:function(){i.triggerBtn=this}},top:0,right:0}]}],ref:function(e){i.comboWrapper=e}}},created:function(){this._checkDynamicValue(this.storeValue)},_checkDynamicValue:function(e){var t=this.options,i=null;switch(BI.isNotNull(e)&&(i=e.type),i){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 i=e.value||{};return!BI.checkDateVoid(i.year,i.month,i.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,i=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:i.buttonHeight-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:i.buttonHeight-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:i.buttonHeight-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:24}}]}),this.setValue(t.value)},_getTabJson:function(){var t=this,i=this.options;return{type:"bi.tab",logic:{dynamic:!0},ref:function(){t.dateTab=this},tab:{type:"bi.linear_segment",invisible:!i.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(e){switch(e){case BI.DynamicDateCombo.Dynamic:return{type:"bi.dynamic_date_card",cls:"dynamic-date-pane",listeners:[{eventName:"EVENT_CHANGE",action:function(){t._setInnerValue(t.year,e)}}],ref:function(){t.dynamicPane=this},min:t.options.min,max:t.options.max};case BI.DynamicDateCombo.Static:default:return{type:"bi.vertical",items:[{type:"bi.date_calendar_popup",behaviors:i.behaviors,min:t.options.min,max:t.options.max,ref:function(){t.ymd=this},listeners:[{eventName:BI.DateCalendarPopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,action:function(){t.fireEvent(BI.DynamicDateTimePopup.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}]},{el:{type:"bi.dynamic_date_time_select",cls:"bi-split-top",ref:function(){t.timeSelect=this},height:40}}]}}},listeners:[{eventName:BI.Tab.EVENT_CHANGE,action:function(){switch(t.dateTab.getSelect()){case BI.DynamicDateCombo.Static:var e=BI.DynamicDateHelper.getCalculation(t.dynamicPane.getValue());t.ymd.setValue({year:e.getFullYear(),month:e.getMonth()+1,day:e.getDate()}),t.timeSelect.setValue(),t._setInnerValue();break;case BI.DynamicDateCombo.Dynamic:default:t.storeValue&&t.storeValue.type===BI.DynamicDateCombo.Dynamic?t.dynamicPane.setValue(t.storeValue.value):t.dynamicPane.setValue({year:0}),t._setInnerValue()}}}]}},_setInnerValue:function(){var e;this.dateTab.getSelect()===BI.DynamicDateCombo.Static?(this.todayButton.setValue(BI.i18nText("BI-Multi_Date_Today")),this.todayButton.setEnable(!this._checkTodayValid())):(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,i=(e=e||{}).type||BI.DynamicDateCombo.Static,n=e.value||e;switch(this.dateTab.setSelect(i),i){case BI.DynamicDateCombo.Dynamic:this.dynamicPane.setValue(n),this._setInnerValue();break;case BI.DynamicDateCombo.Static:default:this._checkValueValid(n)?(t=BI.getDate(),this.ymd.setValue({year:t.getFullYear(),month:t.getMonth()+1,day:t.getDate()}),this.timeSelect.setValue()):(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 t=this;return{type:"bi.center_adapt",items:[{type:"bi.vertical_adapt",items:[{el:{type:"bi.number_editor",ref:function(){t.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 e=this.getValue();t._checkHour(e),this.setValue(t._formatValueToDoubleDigit(e)),t.fireEvent(BI.DynamicDateTimeSelect.EVENT_CONFIRM)}},{eventName:BI.SignEditor.EVENT_CHANGE,action:function(){var e=t._autoSwitch(this.getValue(),BI.DynamicDateTimeSelect.HOUR);this.setValue(e)}}],width:60,height:24}},{type:"bi.label",text:":",width:20},{type:"bi.number_editor",ref:function(){t.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 e=this.getValue();t._checkMinute(e),this.setValue(t._formatValueToDoubleDigit(e),BI.DynamicDateTimeSelect.MINUTE),t.fireEvent(BI.DynamicDateTimeSelect.EVENT_CONFIRM)}},{eventName:BI.SignEditor.EVENT_CHANGE,action:function(){var e=t._autoSwitch(this.getValue(),BI.DynamicDateTimeSelect.MINUTE);this.setValue(e)}}],width:60,height:24},{type:"bi.label",text:":",width:20},{type:"bi.number_editor",ref:function(){t.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 e=this.getValue();t._checkSecond(e),this.setValue(t._formatValueToDoubleDigit(e)),t.fireEvent(BI.DynamicDateTimeSelect.EVENT_CONFIRM)}}],width:60,height:24}]}]}},_checkBorder:function(e){e=e||{},this._checkHour(e.hour),this._checkMinute(e.minute),this._checkSecond(e.second)},_checkHour:function(e){this.hour.setDownEnable(0<BI.parseInt(e)),this.hour.setUpEnable(BI.parseInt(e)<23)},_checkMinute:function(e){this.minute.setDownEnable(0<BI.parseInt(e)),this.minute.setUpEnable(BI.parseInt(e)<59)},_checkSecond:function(e){this.second.setDownEnable(0<BI.parseInt(e)),this.second.setUpEnable(BI.parseInt(e)<59)},_autoSwitch:function(e,t){var i=0,n=e+"";switch(t){case BI.DynamicDateTimeSelect.HOUR:i=2;break;case BI.DynamicDateTimeSelect.MINUTE:i=5}if(1===n.length&&BI.parseInt(n)>i&&(n="0"+n),2===n.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 n},_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 n=this,r=this.options,e=this._const;this.storeTriggerValue="",this.editor=BI.createWidget({type:"bi.sign_editor",height:r.height,validationChecker:function(e){var t=n._getStandardDateStr(e),i=t.match(/\d+/g);return BI.isKey(r.format)||n._autoAppend(e,i),n._dateCheck(t)&&BI.checkDateLegal(t)&&n._checkVoid({year:0|i[0],month:0|i[1],day:0|i[2]})},quitChecker:function(){return!1},hgap:e.hgap,vgap:e.vgap,allowBlank:!0,watermark:BI.isKey(r.watermark)?r.watermark:BI.i18nText("BI-Basic_Unrestricted"),errorText:function(){var e="";return BI.isKey(r.format)||(e=n.editor.isEditing()?BI.i18nText("BI-Basic_Date_Time_Error_Text"):BI.i18nText("BI-Year_Trigger_Invalid_Text")),e},title:BI.bind(this._getTitle,this)}),this.editor.on(BI.SignEditor.EVENT_KEY_DOWN,function(){n.fireEvent(BI.DynamicDateTimeTrigger.EVENT_KEY_DOWN,arguments)}),this.editor.on(BI.SignEditor.EVENT_FOCUS,function(){n.storeTriggerValue=n.getKey(),n.fireEvent(BI.DynamicDateTimeTrigger.EVENT_FOCUS)}),this.editor.on(BI.SignEditor.EVENT_BLUR,function(){n.fireEvent(BI.DynamicDateTimeTrigger.EVENT_BLUR)}),this.editor.on(BI.SignEditor.EVENT_STOP,function(){n.fireEvent(BI.DynamicDateTimeTrigger.EVENT_STOP)}),this.editor.on(BI.SignEditor.EVENT_VALID,function(){n.fireEvent(BI.DynamicDateTimeTrigger.EVENT_VALID)}),this.editor.on(BI.SignEditor.EVENT_ERROR,function(){n.fireEvent(BI.DynamicDateTimeTrigger.EVENT_ERROR)}),this.editor.on(BI.SignEditor.EVENT_CONFIRM,function(){var e,t=n.editor.getValue();BI.isNotNull(t)&&n.editor.setState(t),BI.isNotEmptyString(t)&&!BI.isEqual(n.storeTriggerValue,n.getKey())&&(e=n._getStandardDateStr(t).match(/\d+/g),n.storeValue={type:BI.DynamicDateCombo.Static,value:{year:0|e[0],month:0|e[1],day:0|e[2],hour:0|e[3],minute:0|e[4],second:0|e[5]}}),n.fireEvent(BI.DynamicDateTimeTrigger.EVENT_CONFIRM)}),this.editor.on(BI.SignEditor.EVENT_START,function(){n.fireEvent(BI.DynamicDateTimeTrigger.EVENT_START)}),this.editor.on(BI.SignEditor.EVENT_CHANGE,function(){n.fireEvent(BI.DynamicDateTimeTrigger.EVENT_CHANGE)}),BI.createWidget({type:"bi.htape",element:this,items:[{el:this.editor},{el:BI.createWidget(),width:24}]}),r.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(r.value)},_getTitle:function(){var e=this.storeValue||{},t=e.type||BI.DynamicDateCombo.Static,i=e.value;switch(t){case BI.DynamicDateCombo.Dynamic:var n=this._getText(i),r=BI.DynamicDateHelper.getCalculation(i),a=BI.print(r,this._getFormatString());return BI.isEmptyString(n)?a:n+":"+a;case BI.DynamicDateCombo.Static:default:return BI.isNull(i)||BI.isNull(i.day)?"":BI.print(BI.getDate(i.year,i.month-1,i.day,i.hour||0,i.minute||0,i.second||0),this._getFormatString())}},_getStandardDateStr:function(e){var t=this._const,i=[],n=!1,r=this._getFormatString().match(/%./g);BI.each(r,function(e,t){switch(t){case"%Y":case"%y":i[0]=e;break;case"%X":case"%x":i[1]=e;break;case"%d":case"%e":i[2]=e;break;case"%S":n=!0}});var a=BI.parseDateTime(e,this._getFormatString());BI.print(a,this._getFormatString())===e&&(e=BI.print(a,t.compareFormat),i=[0,1,2]);var o=e.match(/\d+/g)||[],s=[];BI.each(o.slice(0,3),function(e){s[e]=o[i[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||n||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 i=e.split("-")[1];(BI.isNotNull(i)&&2===i.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"),i=BI.print(t,"%Y-%X-%d");return 0<t.getMonth()&&(BI.print(BI.parseDateTime(e,"%Y-%X"),"%Y-%X")===e||BI.print(BI.parseDateTime(e,"%Y-%x"),"%Y-%x")===e)&&i>=this.options.min&&i<=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="",i="";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"))),i=n(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"))),i=n(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"))),i=n(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"))),i=n(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"))),i=1===BI.size(e)?n(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+i;function n(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,i,n,r=BI.getDate();switch(this.storeValue=e,BI.isNotNull(e)&&(t=e.type||BI.DynamicDateCombo.Static,i=e.value||e),t){case BI.DynamicDateCombo.Dynamic:var a=this._getText(i),r=BI.DynamicDateHelper.getCalculation(i);this._setInnerValue(r,a);break;case BI.DynamicDateCombo.Static:default:BI.isNull(i)||BI.isNull(i.day)?(this.editor.setState(""),this.editor.setValue("")):(n=BI.print(BI.getDate(i.year,i.month-1,i.day,i.hour||0,i.minute||0,i.second||0),this._getFormatString()),this.editor.setState(n),this.editor.setValue(n))}},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 t=this,e=this.options;this.editor=BI.createWidget(e.el,{type:"bi.editor",height:e.height,watermark:e.watermark,allowBlank:!0,hgap:1,errorText:e.errorText,validationChecker:e.validationChecker,quitChecker:e.quitChecker,value:e.value}),this.clear=BI.createWidget({type:"bi.icon_button",stopEvent:!0,cls:"close-font"}),this.clear.on(BI.IconButton.EVENT_CHANGE,function(){t.setValue(""),t.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.STOPEDIT,t.getValue()),t.fireEvent(BI.SearchEditor.EVENT_CHANGE),t.fireEvent(BI.SearchEditor.EVENT_CLEAR)}),BI.createWidget({element:this,type:"bi.htape",items:[{el:{type:"bi.icon_label",cls:"search-font"},width:24},{el:t.editor},{el:this.clear,width:24}]}),this.editor.on(BI.Controller.EVENT_CHANGE,function(){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.editor.on(BI.Editor.EVENT_FOCUS,function(){t.fireEvent(BI.SearchEditor.EVENT_FOCUS)}),this.editor.on(BI.Editor.EVENT_BLUR,function(){t.fireEvent(BI.SearchEditor.EVENT_BLUR)}),this.editor.on(BI.Editor.EVENT_CLICK,function(){t.fireEvent(BI.SearchEditor.EVENT_CLICK)}),this.editor.on(BI.Editor.EVENT_CHANGE,function(){t._checkClear(),t.fireEvent(BI.SearchEditor.EVENT_CHANGE)}),this.editor.on(BI.Editor.EVENT_KEY_DOWN,function(e){t.fireEvent(BI.SearchEditor.EVENT_KEY_DOWN,e)}),this.editor.on(BI.Editor.EVENT_SPACE,function(){t.fireEvent(BI.SearchEditor.EVENT_SPACE)}),this.editor.on(BI.Editor.EVENT_BACKSPACE,function(){t.fireEvent(BI.SearchEditor.EVENT_BACKSPACE)}),this.editor.on(BI.Editor.EVENT_VALID,function(){t.fireEvent(BI.SearchEditor.EVENT_VALID)}),this.editor.on(BI.Editor.EVENT_ERROR,function(){t.fireEvent(BI.SearchEditor.EVENT_ERROR)}),this.editor.on(BI.Editor.EVENT_ENTER,function(){t.fireEvent(BI.SearchEditor.EVENT_ENTER)}),this.editor.on(BI.Editor.EVENT_RESTRICT,function(){t.fireEvent(BI.SearchEditor.EVENT_RESTRICT)}),this.editor.on(BI.Editor.EVENT_EMPTY,function(){t._checkClear(),t.fireEvent(BI.SearchEditor.EVENT_EMPTY)}),this.editor.on(BI.Editor.EVENT_REMOVE,function(){t.fireEvent(BI.SearchEditor.EVENT_REMOVE)}),this.editor.on(BI.Editor.EVENT_CONFIRM,function(){t.fireEvent(BI.SearchEditor.EVENT_CONFIRM)}),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,function(){t.fireEvent(BI.SearchEditor.EVENT_CHANGE_CONFIRM)}),this.editor.on(BI.Editor.EVENT_START,function(){t.fireEvent(BI.SearchEditor.EVENT_START)}),this.editor.on(BI.Editor.EVENT_PAUSE,function(){t.fireEvent(BI.SearchEditor.EVENT_PAUSE)}),this.editor.on(BI.Editor.EVENT_STOP,function(){t.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 t=this,e=this.options;BI.isNumber(e.height)&&this.element.css({height:e.height-2}),BI.isNumber(e.width)&&this.element.css({width:e.width-2}),this.editor=BI.createWidget({type:"bi.editor",height:e.height-2,hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,value:e.value,title:e.title,tipType:e.tipType,validationChecker:e.validationChecker,quitChecker:e.quitChecker,allowBlank:e.allowBlank,watermark:e.watermark,errorText:e.errorText}),this.editor.on(BI.Controller.EVENT_CHANGE,function(){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.editor.on(BI.Editor.EVENT_FOCUS,function(){t.fireEvent(BI.TextEditor.EVENT_FOCUS)}),this.editor.on(BI.Editor.EVENT_BLUR,function(){t.fireEvent(BI.TextEditor.EVENT_BLUR)}),this.editor.on(BI.Editor.EVENT_CLICK,function(){t.fireEvent(BI.TextEditor.EVENT_CLICK)}),this.editor.on(BI.Editor.EVENT_CHANGE,function(){t.fireEvent(BI.TextEditor.EVENT_CHANGE)}),this.editor.on(BI.Editor.EVENT_KEY_DOWN,function(e){t.fireEvent(BI.TextEditor.EVENT_KEY_DOWN)}),this.editor.on(BI.Editor.EVENT_SPACE,function(e){t.fireEvent(BI.TextEditor.EVENT_SPACE)}),this.editor.on(BI.Editor.EVENT_BACKSPACE,function(e){t.fireEvent(BI.TextEditor.EVENT_BACKSPACE)}),this.editor.on(BI.Editor.EVENT_VALID,function(){t.fireEvent(BI.TextEditor.EVENT_VALID)}),this.editor.on(BI.Editor.EVENT_CONFIRM,function(){t.fireEvent(BI.TextEditor.EVENT_CONFIRM)}),this.editor.on(BI.Editor.EVENT_CHANGE_CONFIRM,function(){t.fireEvent(BI.TextEditor.EVENT_CHANGE_CONFIRM)}),this.editor.on(BI.Editor.EVENT_REMOVE,function(e){t.fireEvent(BI.TextEditor.EVENT_REMOVE)}),this.editor.on(BI.Editor.EVENT_START,function(){t.fireEvent(BI.TextEditor.EVENT_START)}),this.editor.on(BI.Editor.EVENT_PAUSE,function(){t.fireEvent(BI.TextEditor.EVENT_PAUSE)}),this.editor.on(BI.Editor.EVENT_STOP,function(){t.fireEvent(BI.TextEditor.EVENT_STOP)}),this.editor.on(BI.Editor.EVENT_ERROR,function(){t.fireEvent(BI.TextEditor.EVENT_ERROR,arguments)}),this.editor.on(BI.Editor.EVENT_ENTER,function(){t.fireEvent(BI.TextEditor.EVENT_ENTER)}),this.editor.on(BI.Editor.EVENT_RESTRICT,function(){t.fireEvent(BI.TextEditor.EVENT_RESTRICT)}),this.editor.on(BI.Editor.EVENT_EMPTY,function(){t.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 r=this,e=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:e.EDITOR_WIDTH,validationChecker:function(e){return r._checkValidation(e)}}),this.labelOne.element.hover(function(){r.labelOne.element.removeClass("bi-border").addClass("bi-border")},function(){r.labelOne.element.removeClass("bi-border")}),this.labelOne.on(BI.Editor.EVENT_CONFIRM,function(){var e=r.valueOne,t=BI.parseFloat(this.getValue());r.valueOne=t;var i=r._getPercentByValue(t),n=BI.parseFloat(i.toFixed(1));r._setSliderOnePosition(n),r._setBlueTrack(),r._checkLabelPosition(e,r.valueTwo,r.valueOne,r.valueTwo),r.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:e.EDITOR_WIDTH,validationChecker:function(e){return r._checkValidation(e)}}),this.labelTwo.element.hover(function(){r.labelTwo.element.removeClass("bi-border").addClass("bi-border")},function(){r.labelTwo.element.removeClass("bi-border")}),this.labelTwo.on(BI.Editor.EVENT_CONFIRM,function(){var e=r.valueTwo,t=BI.parseFloat(this.getValue());r.valueTwo=t;var i=r._getPercentByValue(t),n=BI.parseFloat(i.toFixed(1));r._setSliderTwoPosition(n),r._setBlueTrack(),r._checkLabelPosition(r.valueOne,e,r.valueOne,r.valueTwo),r.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:e.TRACK_HEIGHT}]}],hgap:7,height:e.TRACK_HEIGHT},top:23,left:0,width:"100%"},this._createLabelWrapper(),this._createSliderWrapper()]}},_rePosBySizeAfterMove:function(e,t){var i=this.options,n=100*e/this._getGrayTrackLength(),r=BI.parseFloat(n.toFixed(1)),a=this._getValueByPercent(r),a=this._assertValue(a);a=!1===i.digit?a:a.toFixed(i.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 i=100*e/this._getGrayTrackLength(),n=BI.parseFloat(i.toFixed(1));t?this._setSliderOnePosition(n):this._setSliderTwoPosition(n)},_draggable:function(t,i){var n=this,r=(this.options,!1),a=0,o=0,s=0,l=new BI.MouseMoveTracker(function(e){l.isDragging()&&(r=!0,a=u(s+(o+=e)),t.element.addClass("dragging"),n._rePosBySizeAfterMove(a,i))},function(){!0===r&&(a=u(a),n._rePosBySizeAfterStop(a,i),o=a=0,s=a,r=!1),t.element.removeClass("dragging"),l.releaseMouseMoves(),n.fireEvent(BI.IntervalSlider.EVENT_CHANGE)},window);function u(e){return BI.clamp(e,0,n._getGrayTrackLength())}t.element.on("mousedown",function(e){t.isEnabled()&&(u(s=this.offsetLeft),l.captureMouseMoves(e))})},_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,i=!1,n=(e+"").split(".")[1];return BI.isEmptyString(n)||BI.isNumeric(e)&&!(BI.isNull(e)||e<this.min||e>this.max)&&(i=!(!1!==t.digit&&!BI.isInteger(e))||(n||"").length===t.digit),i},_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,i,n,r){var a;e=BI.parseFloat(e),t=BI.parseFloat(t),i=BI.parseFloat(i),n=BI.parseFloat(n),(e<=t&&n<i||t<=e&&i<n)&&(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),i=this.calculation.accurateMultiplication(t,e),n=this.calculation.accurateDivisionTenExponent(i,2);if(this.precision<0){var r=BI.parseFloat(this.calculation.accurateAddition(n,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(n,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=[];if(-1<e.indexOf("e")){t=e.split("e");return BI.size(t[0].split(".")[1])-BI.parseInt(t[1].substring(1))}return 1<(t=e.split(".")).length?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),i=BI.parseFloat(e.max);!isNaN(t)&&!isNaN(i)&&t<=i&&(this.min=t,this.max=i,this.valueOne=t,this.valueTwo=i,this.precision=this._getPrecision(),this.setEnable(!0)),i===t&&this.setEnable(!1)},setValue:function(e){var t=this.options,i=BI.parseFloat(e.min),n=BI.parseFloat(e.max),i=!1===t.digit?i:BI.parseFloat(i.toFixed(t.digit)),n=!1===t.digit?n:BI.parseFloat(n.toFixed(t.digit));isNaN(i)||isNaN(n)||(this._checkValidation(i)&&(this.valueOne=this.valueOne<=this.valueTwo?i:n),this._checkValidation(n)&&(this.valueTwo=this.valueOne<=this.valueTwo?n:i),i<this.min&&(this.valueOne=this.min),n>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",i=0;i<e;i++)t+="0";return BI.parseInt(t)},_formatDecimal:function(e,t){if(e.numDecimalLength!==t.numDecimalLength){var i,n=e.numDecimalLength-t.numDecimalLength;0<n?i=t:(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,i,n=e.toString().split("."),r=n[0];return i=1===n.length?(t="0",0):(t=n[1],n[1].length),{numInteger:r,numDecimal:t,numDecimalLength:i}},_accurateSubtraction:function(e,t){var i=this._stringNumberFactory(e),n=this._stringNumberFactory(t),r=BI.parseInt(i.numInteger)-BI.parseInt(n.numInteger);this._formatDecimal(i,n);var a,o=function(e,t){if(e.numDecimal.length>=t.numDecimal.length)return e.numDecimal.length;return t.numDecimal.length}(i,n);a=BI.parseInt(i.numDecimal)>=BI.parseInt(n.numDecimal)?l((BI.parseInt(i.numDecimal)-BI.parseInt(n.numDecimal)).toString(),o):(r--,l((this._getMagnitude(o)+BI.parseInt(i.numDecimal)-BI.parseInt(n.numDecimal)).toString(),o));var s=r+"."+a;return BI.parseFloat(s);function l(e,t){for(var i=t-e.length,n=0;n<i;n++)e="0"+e;return e}},_accurateAddition:function(e,t){var i=this._stringNumberFactory(e),n=this._stringNumberFactory(t),r=BI.parseInt(i.numInteger)+BI.parseInt(n.numInteger);this._formatDecimal(i,n);var a=(BI.parseInt(i.numDecimal)+BI.parseInt(n.numDecimal)).toString();"0"!==a&&(a=a.length<=i.numDecimal.length?function(e,t){for(var i=t-e.length,n=0;n<i;n++)e="0"+e;return e}(a,i.numDecimal.length):(r++,a.slice(1)));var o=r+"."+a;return BI.parseFloat(o)},_accurateMultiplication:function(e,t){var i=this._stringNumberFactory(e),n=this._stringNumberFactory(t),r=BI.parseInt(i.numInteger)*BI.parseInt(n.numInteger),a=this._accurateDivisionTenExponent(BI.parseInt(i.numDecimal)*BI.parseInt(n.numInteger),i.numDecimalLength),o=this._accurateDivisionTenExponent(BI.parseInt(i.numInteger)*BI.parseInt(n.numDecimal),n.numDecimalLength),s=this._accurateDivisionTenExponent(BI.parseInt(i.numDecimal)*BI.parseInt(n.numDecimal),i.numDecimalLength+n.numDecimalLength);return this._accurateAddition(this._accurateAddition(this._accurateAddition(r,a),o),s)},_accurateDivisionTenExponent:function(e,t){var i,n,r=this._stringNumberFactory(e);n=r.numInteger.length>t?(i=r.numInteger.slice(0,r.numInteger.length-t),r.numInteger.slice(-t)):(i="0",function(e,t){for(var i=t-e.length,n=0;n<i;n++)e="0"+e;return e}(r.numInteger,t));var a=i+"."+n+r.numDecimal;return BI.parseFloat(a)},accurateSubtraction:function(e,t){return 0<=e&&0<=t?t<=e?this._accurateSubtraction(e,t):-this._accurateSubtraction(t,e):0<=e&&t<0?this._accurateAddition(e,-t):e<0&&0<=t?-this._accurateAddition(-e,t):e<0&&t<0?t<=e?this._accurateSubtraction(-t,-e):this._accurateSubtraction(-e,-t):void 0},accurateAddition:function(e,t){return 0<=e&&0<=t?this._accurateAddition(e,t):0<=e&&t<0?this.accurateSubtraction(e,-t):e<0&&0<=t?this.accurateSubtraction(t,-e):e<0&&t<0?-this._accurateAddition(-e,-t):void 0},accurateMultiplication:function(e,t){return 0<=e&&0<=t?this._accurateMultiplication(e,t):0<=e&&t<0?-this._accurateMultiplication(e,-t):e<0&&0<=t?-this._accurateMultiplication(-e,t):e<0&&t<0?this._accurateMultiplication(-e,-t):void 0},accurateDivisionTenExponent:function(e,t){return 0<=e?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 i=this,e=this.options;this.popupview=BI.createWidget({type:"bi.multi_layer_down_list_popup",items:e.items,chooseType:e.chooseType,value:e.value}),this.popupview.on(BI.MultiLayerDownListPopup.EVENT_CHANGE,function(e){i.fireEvent(BI.MultiLayerDownListCombo.EVENT_CHANGE,e),i.downlistcombo.hideView()}),this.popupview.on(BI.MultiLayerDownListPopup.EVENT_SON_VALUE_CHANGE,function(e,t){i.fireEvent(BI.MultiLayerDownListCombo.EVENT_SON_VALUE_CHANGE,e,t),i.downlistcombo.hideView()}),this.downlistcombo=BI.createWidget({element:this,type:"bi.combo",trigger:e.trigger,isNeedAdjustWidth:!1,container:e.container,adjustLength:e.adjustLength,direction:e.direction,stopPropagation:e.stopPropagation,el:BI.createWidget(e.el,{type:"bi.icon_trigger",extraCls:e.iconCls?e.iconCls:"pull-down-font",width:e.width,height:e.height}),popup:{el:this.popupview,stopPropagation:e.stopPropagation,maxHeight:1e3}}),this.downlistcombo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){i.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 s=this,e=this.options,t=this._createPopupItems(e.items);this.popup=BI.createWidget({type:"bi.button_tree",items:BI.createItems(t,{},{adjustLength:-2}),layouts:[{type:"bi.vertical",hgap:this.constants.hgap,vgap:this.constants.vgap}],value:this._digest(e.value),chooseType:e.chooseType}),this.popup.on(BI.ButtonTree.EVENT_CHANGE,function(e,t){var i,n,r,a,o=e;BI.isNotNull(s.childValueMap[e])?(o=s.childValueMap[e],n=((i=s.fatherValueMap[e])+"").split("_"),s.fireEvent(BI.MultiLayerDownListPopup.EVENT_SON_VALUE_CHANGE,o,1<n.length?n:i)):s.fireEvent(BI.MultiLayerDownListPopup.EVENT_CHANGE,o,t),BI.contains(s.singleValues,o)||(r=s.getValue(),a=[],BI.each(r,function(e,t){t.value!=o&&a.push(t)}),s.setValue(a))}),BI.createWidget({type:"bi.vertical",element:this,items:[this.popup],vgap:5})},_createPopupItems:function(r){var a=this,o=[];return BI.each(r,function(e,t){var i,n={type:"bi.down_list_group",items:[]};BI.each(t,function(e,t){BI.isNotEmptyArray(t.children)&&!BI.isEmpty(t.el)?(t.type="bi.combo_group",t.cls="down-list-group",t.trigger="hover",t.isNeedAdjustWidth=!1,t.el.title=t.el.title||t.el.text,t.el.type="bi.down_list_group_item",t.el.logic={dynamic:!0},t.el.height=a.constants.height,t.el.iconCls2=a.constants.nextIcon,t.popup={lgap:1,el:{type:"bi.button_tree",chooseType:0,layouts:[{type:"bi.vertical"}]},innerVGap:5},a._createChildren(t)):(t.type=t.type||"bi.down_list_item",t.title=t.title||t.text,t.textRgap=10,t.isNeedAdjustWidth=!1,t.logic={dynamic:!0});var i={};i.el=t,n.items.push(i)}),a._isGroup(n.items)&&BI.each(n.items,function(e,t){a.singleValues.push(t.el.value)}),o.push(n),a._needSpliter(e,r.length)&&(i=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}),o.push(i))}),o},_createChildren:function(r){var a=this;this._formatEL(r).el.childValues=[],BI.each(r.children,function(e,t){t=t.el?BI.extend(t.el,{children:t.children}):t;var i=BI.deepClone(a._formatEL(r).el.value),n=BI.deepClone(t.value);a.singleValues.push(t.value),t.type=t.type||"bi.down_list_item",t.extraCls=" child-down-list-item",t.title=t.title||t.text,t.textRgap=10,t.isNeedAdjustWidth=!1,t.logic={dynamic:!0},t.father=i,a.fatherValueMap[a._createChildValue(i,n)]=i,a.childValueMap[a._createChildValue(i,n)]=n,t.value=a._createChildValue(i,n),a._formatEL(r).el.childValues.push(t.value),BI.isNotEmptyArray(t.children)&&(t.type="bi.down_list_group_item",t.iconCls2=a.constants.nextIcon,t.height=a.constants.height,a._createChildren(t))})},_formatEL:function(e){return e&&e.el?e:{el:e}},_isGroup:function(e){return 1<e.length},_needSpliter:function(e,t){return e<t-1},_createChildValue:function(e,t){var i=e;return BI.isArray(e)&&(i=e.join("_")),i+"_"+t},_digest:function(e){var n=this,r=[];return BI.each(e,function(e,t){var i=BI.isNotNull(t.childValue)?n._createChildValue(t.value,t.childValue):t.value;r.push(i)}),r},_checkValues:function(u){var e=this.options,c=[];return BI.each(e.items,function(l,e){BI.each(e,function(e,t){var i,n,r,a,o;BI.isNotNull(t.children)?(i=function s(e){var i=[];BI.isNotNull(e.children)?BI.each(e.children,function(e,t){i=BI.concat(i,s(t))}):i.push(e.value);return i}(t),r=i,a=u[l],o="",BI.some(r,function(e,i){return BI.some(a,function(e,t){if(i===t)return o=i,!0})}),n=o,BI.isNotEmptyString(n)&&c.push(n)):t.value===u[l][0]&&c.push(u[l][0])})}),c},populate:function(e){BI.MultiLayerDownListPopup.superclass.populate.apply(this,arguments);this.childValueMap={},this.fatherValueMap={},this.singleValues=[];var t=this._createPopupItems(e),i=BI.createItems(t,{},{adjustLength:-2});this.popup.populate(i)},setValue:function(e){this.popup.setValue(this._digest(e))},_getValue:function(){var i=[];return BI.each(this.popup.getAllButtons(),function(e,t){e%2==0&&i.push(t.getValue())}),i},getValue:function(){var a=this,o=[],e=this._checkValues(this._getValue());return BI.each(e,function(e,t){var i,n,r={};BI.isNotNull(a.childValueMap[t])?(i=a.fatherValueMap[t],r.childValue=a.childValueMap[t],n=(i+"").split("_"),r.value=1<n.length?n:i):r.value=t,o.push(r)}),o}}),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 t=this,e=this.options,i=e.itemsCreator===BI.emptyFn?this._getSyncConfig():this._getAsyncConfig();return this._shouldWrapper()?i:{type:"bi.absolute",items:[{el:i,left:0,right:0,top:0,bottom:0},{el:{type:"bi.trigger_icon_button",cls:"trigger-icon-button",ref:function(e){t.triggerBtn=e},width:e.height,height:e.height,handler:function(){t.combo.isViewVisible()?t.combo.hideView():t.combo.showView()}},right:0,bottom:0,top:0}]}},_shouldWrapper:function(){var e=this.options;return!e.allowEdit&&e.itemsCreator===BI.emptyFn},_getBaseConfig:function(){var t=this,e=this.options;return{type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",container:e.container,destroyWhenHide:e.destroyWhenHide,adjustLength:2,ref:function(e){t.combo=e},popup:{el:{type:"bi.multilayer_select_tree_popup",isDefaultInit:e.isDefaultInit,itemsCreator:e.itemsCreator,items:e.items,ref:function(e){t.trigger&&t.trigger.getSearcher().setAdapter(e)},listeners:[{eventName:BI.MultiLayerSelectTreePopup.EVENT_CHANGE,action:function(){t.setValue(this.getValue()),t.combo.hideView(),t.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_CHANGE)}}],onLoaded:function(){BI.nextTick(function(){t.combo.adjustWidth(),t.combo.adjustHeight()})}},value:e.value,maxHeight:400,maxWidth:e.isNeedAdjustWidth?"auto":500,minHeight:240},isNeedAdjustWidth:e.isNeedAdjustWidth,listeners:[{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){t.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_BEFORE_POPUPVIEW)}}]}},_getSearchConfig:function(){var t=this,i=this.options;return{el:{type:"bi.multilayer_select_tree_trigger",container:i.container,allowInsertValue:i.allowInsertValue,allowSearchValue:i.allowSearchValue,allowEdit:i.allowEdit,cls:"multilayer-select-tree-trigger",ref:function(e){t.trigger=e},items:i.items,itemsCreator:i.itemsCreator,valueFormatter:i.valueFormatter,watermark:i.watermark,height:i.height-2,text:i.text,value:i.value,tipType:i.tipType,warningTitle:i.warningTitle,title:i.title,listeners:[{eventName:BI.MultiLayerSelectTreeTrigger.EVENT_CHANGE,action:function(){t.setValue(this.getValue()),t.combo.hideView(),t.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_CHANGE)}},{eventName:BI.MultiLayerSelectTreeTrigger.EVENT_FOCUS,action:function(){t.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_FOCUS)}},{eventName:BI.MultiLayerSelectTreeTrigger.EVENT_BLUR,action:function(){t.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_BLUR)}},{eventName:BI.MultiLayerSelectTreeTrigger.EVENT_SEARCHING,action:function(){t.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_SEARCHING)}},{eventName:BI.MultiLayerSelectTreeTrigger.EVENT_ADD_ITEM,action:function(){var e=t.trigger.getSearcher().getKeyword();t.combo.setValue([e]),t.combo.hideView()}}]},toggle:!i.allowEdit,hideChecker:function(e){return!(i.container&&t.trigger.getSearcher().isSearching()&&0<t.trigger.getSearcher().getView().element.find(e.target).length)&&0===t.triggerBtn.element.find(e.target).length},listeners:[{eventName:BI.Combo.EVENT_AFTER_HIDEVIEW,action:function(){t.trigger.stopEditing()}},{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){t.fireEvent(BI.MultiLayerSelectTreeCombo.EVENT_BEFORE_POPUPVIEW)}}]}},_getSyncConfig:function(){var e=this.options,t=this._getBaseConfig();return BI.extend(t,e.allowEdit?this._getSearchConfig():{el:{type:"bi.single_tree_trigger",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()},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 i=this,n=this.options;return this.tree=BI.createWidget({type:"bi.multilayer_select_level_tree",isDefaultInit:n.isDefaultInit,items:n.items,itemsCreator:n.itemsCreator===BI.emptyFn?BI.emptyFn:function(e,t){n.itemsCreator(e,function(e){t(e),i.setKeyword(n.keywordGetter())})},keywordGetter:n.keywordGetter,value:n.value,scrollable:null,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(){i.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}},{eventName:BI.MultiLayerSelectLevelTree.EVENT_CHANGE,action:function(){i.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(e){i.addNotMatchTip=e},handler:function(){i.fireEvent(BI.MultiLayerSelectTreeInsertSearchPane.EVENT_ADD_ITEM,n.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(n,r,a){var o=this,s=this.options.keywordGetter();return BI.each(n,function(e,t){var i={isFirstNode:0===e,isLastNode:e===n.length-1};t.layer=r,BI.isKey(t.id)||(t.id=BI.UUID()),t.keyword=t.keyword||s,i.pNode=a,!0===t.isParent||!0===t.parent||BI.isNotEmptyArray(t.children)?(0===r&&i.isFirstNode&&i.isLastNode?i.type="bi.multilayer_select_tree_plus_group_node":0===r&&i.isFirstNode?i.type="bi.multilayer_select_tree_first_plus_group_node":i.isLastNode?i.type="bi.multilayer_select_tree_last_plus_group_node":i.type="bi.multilayer_select_tree_mid_plus_group_node",BI.defaults(t,i),o._formatItems(t.children,r+1,t)):(0===r&&i.isFirstNode&&i.isLastNode?i.type="bi.root_tree_leaf_item":0===r&&i.isFirstNode?i.type="bi.multilayer_single_tree_first_tree_leaf_item":i.isLastNode?i.type="bi.multilayer_single_tree_last_tree_leaf_item":i.type="bi.multilayer_single_tree_mid_tree_leaf_item",BI.defaults(t,i))}),n},_assertId:function(e){BI.each(e,function(e,t){t.id=t.id||BI.UUID()})},initTree:function(e){var n=this,r=this.options,a=!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:r.isDefaultInit,el:{},popup:{type:"bi.custom_tree"}},items:this._formatItems(BI.Tree.transformToTreeFormat(e),0),itemsCreator:function(t,i){1!==t.times||t.node||BI.nextTick(function(){n.loading()}),r.itemsCreator(t,function(e){a=e.hasNext,1!==t.times||t.node||n._populate(e.items),i(n._formatItems(BI.Tree.transformToTreeFormat(e.items),t.node?t.node.layer+1:0,t.node)),n.setValue(n.storeValue),1!==t.times||t.node||BI.nextTick(function(){n.loaded()})})},value:r.value,el:{type:"bi.loader",isDefaultInit:r.itemsCreator!==BI.emptyFn,el:{type:"bi.button_tree",chooseType:r.chooseType===BI.Selection.None?BI.Selection.None:BI.Selection.Default,behaviors:r.behaviors,layouts:[{type:"bi.vertical"}]},hasNext:function(){return a}}}),this.tree.on(BI.Controller.EVENT_CHANGE,function(e,t){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&(n.setValue(t),n.fireEvent(BI.MultiLayerSelectLevelTree.EVENT_CHANGE,arguments))}),BI.createWidget({type:"bi.adaptive",element:this,scrollable:r.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 n=this,r=this.options;r.itemsCreator===BI.emptyFn&&this._initData();var e={type:"bi.htape",items:[{el:{type:"bi.searcher",ref:function(){n.searcher=this},masker:BI.isNotNull(r.container)?{offset:{},container:r.container}:{offset:{}},isAutoSearch:!1,el:{type:"bi.state_editor",ref:function(){n.editor=this},defaultText:r.text,text:this._digest(r.value),value:r.value,height:r.height,tipText:"",watermark:r.watermark,listeners:[{eventName:BI.StateEditor.EVENT_FOCUS,action:function(){n.fireEvent(BI.MultiLayerSelectTreeTrigger.EVENT_FOCUS)}},{eventName:BI.StateEditor.EVENT_BLUR,action:function(){n.fireEvent(BI.MultiLayerSelectTreeTrigger.EVENT_BLUR)}},{eventName:BI.StateEditor.EVENT_CHANGE,action:function(){n.fireEvent(BI.MultiLayerSelectTreeTrigger.EVENT_SEARCHING)}}]},popup:{type:r.allowInsertValue?"bi.multilayer_select_tree_insert_search_pane":"bi.multilayer_select_tree_popup",itemsCreator:r.itemsCreator===BI.emptyFn?BI.emptyFn:function(e,t){e.keyword=n.editor.getValue(),r.itemsCreator(e,t)},keywordGetter:function(){return n.editor.getValue()},cls:"bi-card",listeners:[{eventName:BI.MultiLayerSelectTreeInsertSearchPane.EVENT_ADD_ITEM,action:function(){n.options.text=n.getSearcher().getKeyword(),n.fireEvent(BI.MultiLayerSelectTreeTrigger.EVENT_ADD_ITEM)}}],ref:function(e){n.popup=e}},onSearch:function(e,t){var i=e.keyword;r.itemsCreator===BI.emptyFn?(t(n._getSearchItems(i)),r.allowInsertValue&&n.popup.setKeyword(i)):t()},listeners:[{eventName:BI.Searcher.EVENT_CHANGE,action:function(){n.fireEvent(BI.MultiLayerSelectTreeTrigger.EVENT_CHANGE)}}]}},{el:{type:"bi.layout",width:24},width:24}]};return r.allowEdit?e:{type:"bi.absolute",items:[{el:e,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(i){var n=this,r=this.options,a=[];return this.tree.traverse(function(e){var t=BI.Func.getSearchResult(n.tree.isRoot(e)?[]:BI.concat([e.text],r.allowSearchValue?[e.value]:[]),i);if(0<t.find.length||0<t.match.length)return a.push(e),!0}),this._fillTreeStructure4Search(a,"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 n=this;e.children=e.children||[];var r=[];return BI.each(e.children,function(e,t){var i=n._getChildren(t);r=r.concat(i)}),e.children.concat(r)},_fillTreeStructure4Search:function(e){var i=this,n=[],r=[];for(BI.each(e,function(e,t){r.push({pId:t.pId}),n.push(t),n=n.concat(i._getChildren(t))});BI.isNotEmptyArray(r);){var t=r.pop(),a=this.tree.search(this.tree.getRoot(),t.pId,"id");null!=a&&(a.open=!0,r.push({pId:a.pId}),n.push(a))}return BI.uniqBy(BI.map(n,function(e,t){return i._createJson(t,t.open)}),"id")},_digest:function(i){var e=this.options;if(BI.isFunction(e.valueFormatter))return e.valueFormatter(i);if(e.itemsCreator!==BI.emptyFn)return i;var t=BI.find(e.items,function(e,t){return t.value===i});return BI.isNotNull(t)?t.text:e.text},_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 t=this,e=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:e.id,pId:e.pId,keyword:e.keyword,open:e.open,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py}),this.node.on(BI.Controller.EVENT_CHANGE,function(e){t.setSelected(t.isSelected()),t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)});var i=[];i.push({el:this.node,lgap:12*e.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(e.layer,12),items:i})},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 t=this,e=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:e.id,pId:e.pId,keyword:e.keyword,open:e.open,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py}),this.node.on(BI.Controller.EVENT_CHANGE,function(e){t.setSelected(t.isSelected()),t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)});var i=[];i.push({el:this.node,lgap:12*e.layer}),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)},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 t=this,e=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:e.id,pId:e.pId,keyword:e.keyword,open:e.open,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py}),this.node.on(BI.Controller.EVENT_CHANGE,function(e){t.setSelected(t.isSelected()),t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)});var i=[];i.push({el:this.node,lgap:12*e.layer}),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)},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 t=this,e=this.options;this.node=BI.createWidget({type:"bi.select_tree_plus_group_node",cls:"bi-list-item-none",stopPropagation:!0,logic:{dynamic:!0},id:e.id,pId:e.pId,keyword:e.keyword,open:e.open,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py}),this.node.on(BI.Controller.EVENT_CHANGE,function(e){t.setSelected(t.isSelected()),t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)});var i=[];i.push({el:this.node,lgap:12*e.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(e.layer,12),items:i})},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 t=this,e=this.options,i=e.itemsCreator===BI.emptyFn?this._getSyncConfig():this._getAsyncConfig();return this._shouldWrapper()?i:{type:"bi.absolute",height:e.height-2,items:[{el:i,left:0,right:0,top:0,bottom:0},{el:{type:"bi.trigger_icon_button",cls:"trigger-icon-button",ref:function(e){t.triggerBtn=e},width:e.height,height:e.height,handler:function(){t.combo.isViewVisible()?t.combo.hideView():t.combo.showView()}},right:0,bottom:0,top:0}]}},_shouldWrapper:function(){var e=this.options;return!e.allowEdit&&e.itemsCreator===BI.emptyFn},_getBaseConfig:function(){var t=this,e=this.options;return{type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",container:e.container,destroyWhenHide:e.destroyWhenHide,adjustLength:2,ref:function(e){t.combo=e},popup:{el:{type:"bi.multilayer_single_tree_popup",isDefaultInit:e.isDefaultInit,itemsCreator:e.itemsCreator,items:e.items,ref:function(e){t.trigger&&t.trigger.getSearcher().setAdapter(e)},listeners:[{eventName:BI.MultiLayerSingleTreePopup.EVENT_CHANGE,action:function(){t.setValue(this.getValue()),t.combo.hideView(),t.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_CHANGE)}}],onLoaded:function(){BI.nextTick(function(){t.combo.adjustWidth(),t.combo.adjustHeight()})}},value:e.value,maxHeight:400,maxWidth:e.isNeedAdjustWidth?"auto":500,minHeight:240},isNeedAdjustWidth:e.isNeedAdjustWidth,listeners:[{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){t.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_BEFORE_POPUPVIEW)}}]}},_getSearchConfig:function(){var t=this,i=this.options;return{el:{type:"bi.multilayer_single_tree_trigger",container:i.container,allowInsertValue:i.allowInsertValue,allowSearchValue:i.allowSearchValue,allowEdit:i.allowEdit,cls:"multilayer-single-tree-trigger",ref:function(e){t.trigger=e},watermark:i.watermark,items:i.items,itemsCreator:i.itemsCreator,valueFormatter:i.valueFormatter,height:i.height-2,text:i.text,value:i.value,tipType:i.tipType,warningTitle:i.warningTitle,title:i.title,listeners:[{eventName:BI.MultiLayerSingleTreeTrigger.EVENT_CHANGE,action:function(){t.setValue(this.getValue()),t.combo.hideView(),t.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_CHANGE)}},{eventName:BI.MultiLayerSingleTreeTrigger.EVENT_FOCUS,action:function(){t.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_FOCUS)}},{eventName:BI.MultiLayerSingleTreeTrigger.EVENT_BLUR,action:function(){t.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_BLUR)}},{eventName:BI.MultiLayerSingleTreeTrigger.EVENT_SEARCHING,action:function(){t.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_SEARCHING)}},{eventName:BI.MultiLayerSingleTreeTrigger.EVENT_ADD_ITEM,action:function(){var e=t.trigger.getSearcher().getKeyword();t.combo.setValue([e]),t.combo.hideView()}}]},toggle:!i.allowEdit,hideChecker:function(e){return!(i.container&&t.trigger.getSearcher().isSearching()&&0<t.trigger.getSearcher().getView().element.find(e.target).length)&&0===t.triggerBtn.element.find(e.target).length},listeners:[{eventName:BI.Combo.EVENT_AFTER_HIDEVIEW,action:function(){t.trigger.stopEditing()}},{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){t.fireEvent(BI.MultiLayerSingleTreeCombo.EVENT_BEFORE_POPUPVIEW)}}]}},_getSyncConfig:function(){var e=this.options,t=this._getBaseConfig();return BI.extend(t,e.allowEdit?this._getSearchConfig():{el:{type:"bi.single_tree_trigger",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()},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 i=this,n=this.options;return this.tree=BI.createWidget({type:"bi.multilayer_single_level_tree",isDefaultInit:n.isDefaultInit,items:n.items,itemsCreator:n.itemsCreator===BI.emptyFn?BI.emptyFn:function(e,t){n.itemsCreator(e,function(e){t(e),i.setKeyword(n.keywordGetter())})},keywordGetter:n.keywordGetter,value:n.value,scrollable:null,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(){i.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}},{eventName:BI.MultiLayerSelectLevelTree.EVENT_CHANGE,action:function(){i.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(e){i.addNotMatchTip=e},handler:function(){i.fireEvent(BI.MultiLayerSingleTreeInsertSearchPane.EVENT_ADD_ITEM,n.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(n,r,a){var o=this,s=this.options.keywordGetter();return BI.each(n,function(e,t){var i={isFirstNode:0===e,isLastNode:e===n.length-1};t.layer=r,BI.isKey(t.id)||(t.id=BI.UUID()),t.keyword=t.keyword||s,i.pNode=a,!0===t.isParent||!0===t.parent||BI.isNotEmptyArray(t.children)?(0===r&&i.isFirstNode&&i.isLastNode?i.type="bi.multilayer_single_tree_plus_group_node":0===r&&i.isFirstNode?i.type="bi.multilayer_single_tree_first_plus_group_node":i.isLastNode?i.type="bi.multilayer_single_tree_last_plus_group_node":i.type="bi.multilayer_single_tree_mid_plus_group_node",BI.defaults(t,i),o._formatItems(t.children,r+1,t)):(0===r&&i.isFirstNode&&i.isLastNode?i.type="bi.root_tree_leaf_item":0===r&&i.isFirstNode?i.type="bi.multilayer_single_tree_first_tree_leaf_item":i.isLastNode?i.type="bi.multilayer_single_tree_last_tree_leaf_item":i.type="bi.multilayer_single_tree_mid_tree_leaf_item",BI.defaults(t,i))}),n},_assertId:function(e){BI.each(e,function(e,t){t.id=t.id||BI.UUID()})},initTree:function(e){var n=this,r=this.options,a=!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:r.isDefaultInit,el:{},popup:{type:"bi.custom_tree"}},items:this._formatItems(BI.Tree.transformToTreeFormat(e),0),value:r.value,itemsCreator:function(t,i){1!==t.times||t.node||BI.nextTick(function(){n.loading()}),r.itemsCreator(t,function(e){a=e.hasNext,1!==t.times||t.node||n._populate(e.items),i(n._formatItems(BI.Tree.transformToTreeFormat(e.items),t.node?t.node.layer+1:0,t.node)),n.setValue(n.storeValue),1!==t.times||t.node||BI.nextTick(function(){n.loaded()})})},el:{type:"bi.loader",isDefaultInit:r.itemsCreator!==BI.emptyFn,el:{type:"bi.button_tree",chooseType:r.chooseType===BI.Selection.None?BI.Selection.None:BI.Selection.Default,behaviors:r.behaviors,layouts:[{type:"bi.vertical"}]},hasNext:function(){return a}}}),this.tree.on(BI.Controller.EVENT_CHANGE,function(e,t){n.fireEvent(BI.Controller.EVENT_CHANGE,arguments),e===BI.Events.CLICK&&(n.setValue(t),n.fireEvent(BI.MultiLayerSingleLevelTree.EVENT_CHANGE,t))}),BI.createWidget({type:"bi.adaptive",element:this,scrollable:r.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 n=this,r=this.options;r.itemsCreator===BI.emptyFn&&this._initData();var e={type:"bi.htape",items:[{el:{type:"bi.searcher",ref:function(){n.searcher=this},masker:BI.isNotNull(r.container)?{offset:{},container:r.container}:{offset:{}},isAutoSearch:!1,el:{type:"bi.state_editor",ref:function(){n.editor=this},defaultText:r.text,text:this._digest(r.value),value:r.value,height:r.height,tipText:"",watermark:r.watermark,listeners:[{eventName:BI.StateEditor.EVENT_FOCUS,action:function(){n.fireEvent(BI.MultiLayerSingleTreeTrigger.EVENT_FOCUS)}},{eventName:BI.StateEditor.EVENT_BLUR,action:function(){n.fireEvent(BI.MultiLayerSingleTreeTrigger.EVENT_BLUR)}},{eventName:BI.StateEditor.EVENT_CHANGE,action:function(){n.fireEvent(BI.MultiLayerSingleTreeTrigger.EVENT_SEARCHING)}}]},popup:{type:r.allowInsertValue?"bi.multilayer_single_tree_insert_search_pane":"bi.multilayer_single_tree_popup",itemsCreator:r.itemsCreator===BI.emptyFn?BI.emptyFn:function(e,t){e.keyword=n.editor.getValue(),r.itemsCreator(e,t)},keywordGetter:function(){return n.editor.getValue()},cls:"bi-card",listeners:[{eventName:BI.MultiLayerSingleTreeInsertSearchPane.EVENT_ADD_ITEM,action:function(){n.options.text=n.getSearcher().getKeyword(),n.fireEvent(BI.MultiLayerSingleTreeTrigger.EVENT_ADD_ITEM)}}],ref:function(e){n.popup=e}},onSearch:function(e,t){var i=e.keyword;r.itemsCreator===BI.emptyFn?(t(n._getSearchItems(i)),r.allowInsertValue&&n.popup.setKeyword(i)):t()},listeners:[{eventName:BI.Searcher.EVENT_CHANGE,action:function(){n.fireEvent(BI.MultiLayerSingleTreeTrigger.EVENT_CHANGE)}}]}},{el:{type:"bi.layout",width:24},width:24}]};return r.allowEdit?e:{type:"bi.absolute",items:[{el:e,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(i){var n=this,r=this.options,a=[];return this.tree.traverse(function(e){var t=BI.Func.getSearchResult(n.tree.isRoot(e)?[]:BI.concat([e.text],r.allowSearchValue?[e.value]:[]),i);if(0<t.find.length||0<t.match.length)return a.push(e),!0}),this._fillTreeStructure4Search(a,"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 n=this;e.children=e.children||[];var r=[];return BI.each(e.children,function(e,t){var i=n._getChildren(t);r=r.concat(i)}),e.children.concat(r)},_fillTreeStructure4Search:function(e){var i=this,n=[],r=[];for(BI.each(e,function(e,t){r.push({pId:t.pId}),n.push(t),n=n.concat(i._getChildren(t))});BI.isNotEmptyArray(r);){var t=r.pop(),a=this.tree.search(this.tree.getRoot(),t.pId,"id");null!=a&&(a.open=!0,r.push({pId:a.pId}),n.push(a))}return BI.uniqBy(BI.map(n,function(e,t){return i._createJson(t,t.open)}),"id")},_digest:function(i){var e=this.options;if(BI.isFunction(e.valueFormatter))return e.valueFormatter(i);if(e.itemsCreator!==BI.emptyFn)return i;var t=BI.find(e.items,function(e,t){return t.value===i});return BI.isNotNull(t)?t.text:e.text},_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 t=this,e=this.options;return BI.createWidget({type:"bi.first_plus_group_node",cls:"bi-list-item-none",logic:{dynamic:!0},id:e.id,pId:e.pId,open:e.open,isLastNode:e.isLastNode,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(e){e!==BI.Events.CLICK&&t.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 t=this,e=this.options;return BI.createWidget({type:"bi.last_plus_group_node",cls:"bi-list-item-none",logic:{dynamic:!0},id:e.id,pId:e.pId,open:e.open,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(e){e!==BI.Events.CLICK&&t.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 t=this,e=this.options;return BI.createWidget({type:"bi.mid_plus_group_node",cls:"bi-list-item-none",logic:{dynamic:!0},id:e.id,pId:e.pId,open:e.open,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(e){e!==BI.Events.CLICK&&t.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 t=this.options;this.node=this._createNode();for(var i=[],e=t.pNode;e;)e.isLastNode&&i.push(e.layer),e=e.pNode;var n=[];BI.count(0,t.layer,function(e){n.push({type:"bi.layout",cls:BI.contains(i,e)?"":"base-line-conn-background",width:12,height:t.height})}),n.push(this.node),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)},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 t=this,e=this.options;return BI.createWidget({type:"bi.plus_group_node",cls:"bi-list-item-none",logic:{dynamic:!0},id:e.id,pId:e.pId,open:e.open,isLastNode:e.isLastNode,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(e){e!==BI.Events.CLICK&&t.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 t=this,e=this.options;this.item=BI.createWidget({type:"bi.first_tree_leaf_item",cls:"bi-list-item-none",logic:{dynamic:!0},id:e.id,pId:e.pId,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword}),this.item.on(BI.Controller.EVENT_CHANGE,function(e){e!==BI.Events.CLICK&&t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)});var i=[];i.push({el:this.item,lgap:12*e.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(e.layer,12),items:i})},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 t=this,e=this.options;this.item=BI.createWidget({type:"bi.last_tree_leaf_item",cls:"bi-list-item-none",logic:{dynamic:!0},id:e.id,pId:e.pId,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword}),this.item.on(BI.Controller.EVENT_CHANGE,function(e){e!==BI.Events.CLICK&&t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)});var i=[];i.push({el:this.item,lgap:12*e.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(e.layer,12),items:i})},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 t=this,e=this.options;this.item=BI.createWidget({type:"bi.mid_tree_leaf_item",cls:"bi-list-item-none",logic:{dynamic:!0},id:e.id,pId:e.pId,height:e.height,hgap:e.hgap,text:e.text,value:e.value,py:e.py,keyword:e.keyword}),this.item.on(BI.Controller.EVENT_CHANGE,function(e){e!==BI.Events.CLICK&&t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)});var i=[];i.push({el:this.item,lgap:12*e.layer}),BI.createWidget({type:"bi.horizontal_adapt",element:this,columnSize:BI.makeArray(e.layer,12),items:i})},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 i=this,n=this.options;this.storeValue=n.value||{},this.display=BI.createWidget({type:"bi.display_selected_list",items:n.items,itemsCreator:function(e,t){e=BI.extend(e||{},{selectedValues:i.storeValue.value}),i.storeValue.type!==BI.Selection.Multi?n.itemsCreator(e,t):t({items:BI.map(i.storeValue.value,function(e,t){var i=n.valueFormatter(t)||t;return{text:i,value:t,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(){n.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 i=this,n=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(n.items),chooseType:BI.ButtonGroup.CHOOSE_TYPE_MULTI,layouts:[{type:"bi.vertical",lgap:10}]},itemsCreator:function(e,t){n.itemsCreator(e,function(e){i.hasNext=!!e.hasNext,t(i._createItems(e.items))})},hasNext:function(){return i.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:24,height:24,allowEdit:!0})},_init:function(){var i=this,e=this.options;BI.MultiSelectCombo.superclass._init.apply(this,arguments);var n=function(){BI.isKey(i._startValue)&&(i.storeValue.type===BI.Selection.All?(BI.remove(i.storeValue.value,i._startValue),i.storeValue.assist=i.storeValue.assist||[],i.storeValue.assist.pushDistinct(i._startValue)):(BI.pushDistinct(i.storeValue.value,i._startValue),BI.remove(i.storeValue.assist,i._startValue))),i.trigger.getSearcher().setState(i.storeValue),i.numberCounter.setButtonChecked(i.storeValue)};this.storeValue=e.value||{},this._assertValue(this.storeValue),this.requesting=!1,this.trigger=BI.createWidget({type:"bi.multi_select_trigger",allowEdit:e.allowEdit,height:e.height-2,text:e.text,masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:e.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),itemHeight:e.itemHeight,value:this.storeValue}),this.trigger.on(BI.MultiSelectTrigger.EVENT_FOCUS,function(){i.fireEvent(BI.MultiSelectCombo.EVENT_FOCUS)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_BLUR,function(){i.fireEvent(BI.MultiSelectCombo.EVENT_BLUR)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_START,function(){i._setStartValue(""),this.getSearcher().setValue(i.storeValue)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_STOP,function(){i._setStartValue(""),i.fireEvent(BI.MultiSelectCombo.EVENT_STOP)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_SEARCHING,function(e){var t=BI.last(e);0<(e=BI.initial(e||[])).length&&i._joinKeywords(e,function(){BI.endWith(t,BI.BlankSplitChar)?(i.combo.setValue(i.storeValue),n(),i.combo.populate(),i._setStartValue("")):(i.combo.setValue(i.storeValue),n()),i._dataChange=!0}),i.fireEvent(BI.MultiSelectCombo.EVENT_SEARCHING)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_CHANGE,function(e,t){t instanceof BI.MultiSelectBar?i._joinAll(this.getValue(),function(){n()}):i._join(this.getValue(),function(){n()}),i._dataChange=!0,i.fireEvent(BI.MultiSelectCombo.EVENT_CLICK_ITEM)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW,function(){i.numberCounter.updateSelectedValue(i.storeValue)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_COUNTER_CLICK,function(){i.combo.isViewVisible()||i.combo.showView()}),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!e.allowEdit,container:e.container,el:this.trigger,adjustLength:1,popup:{type:"bi.multi_select_popup_view",ref:function(){i.popup=this,i.trigger.setAdapter(this),i.numberCounter.setAdapter(this)},listeners:[{eventName:BI.MultiSelectPopupView.EVENT_CHANGE,action:function(){i._dataChange=!0,i.storeValue=this.getValue(),i._adjust(function(){n()}),i.fireEvent(BI.MultiSelectCombo.EVENT_CLICK_ITEM)}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CONFIRM,action:function(){i._defaultState()}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CLEAR,action:function(){i._dataChange=!0,i.setValue(),i._defaultState()}}],itemsCreator:e.itemsCreator,itemsHeight:e.itemsHeight,valueFormatter:e.valueFormatter,onLoaded:function(){BI.nextTick(function(){i.combo.adjustWidth(),i.combo.adjustHeight(),i.numberCounter.adjustView(),i.trigger.getSearcher().adjustView()})}},value:e.value,hideChecker:function(e){return 0===t.element.find(e.target).length&&0===i.numberCounter.element.find(e.target).length}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){this.isViewVisible()||(i._dataChange=!1),this.setValue(i.storeValue),BI.nextTick(function(){i._populate()})}),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,function(){i._stopEditing(),!0===i.requesting?i.wants2Quit=!0:i._dataChange&&i.fireEvent(BI.MultiSelectCombo.EVENT_CONFIRM)});var t=BI.createWidget({type:"bi.trigger_icon_button",width:e.height,height:e.height,cls:"multi-select-trigger-icon-button"});t.on(BI.TriggerIconButton.EVENT_CHANGE,function(){i.numberCounter.hideView(),i.combo.isViewVisible()?i.combo.hideView():i.combo.showView()}),this.numberCounter=BI.createWidget({type:"bi.multi_select_check_selected_switcher",masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:e.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),value:this.storeValue}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,function(){i.combo.isViewVisible()||i.combo.showView()}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,function(){this.updateSelectedValue(i.storeValue)}),this.numberCounter.on(BI.Events.VIEW,function(e){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(!0===e?i.numberCounter.element.outerWidth()+8:0)})}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,function(){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(0)})}),this.trigger.element.click(function(e){0<i.trigger.element.find(e.target).length&&i.numberCounter.hideView()}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:t,right:0,top:0,bottom:0},{el:{type:"bi.vertical_adapt",items:[this.numberCounter]},right:e.height,top:0,height:e.height}]})},_itemsCreator4Trigger:function(t,i){var n=this;this.options.itemsCreator(t,function(e){1===t.times&&BI.isNotNull(t.keywords)&&n.trigger.setValue(BI.deepClone(n.getValue())),i.apply(n,arguments)})},_stopEditing:function(){this.trigger.stopEditing(),this.numberCounter.hideView()},_defaultState:function(){this._stopEditing(),this.combo.hideView()},_assertValue:function(e){(e=e||{}).type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(r,a){var o=this,e=this.options;this._assertValue(this.storeValue),this.requesting=!0,e.itemsCreator({type:BI.MultiSelectCombo.REQ_GET_ALL_DATA,keywords:r},function(e){var t,i,n=BI.map(e.items,"value");t=n,i=o._makeMap(t),BI.each(r,function(e,t){BI.isNotNull(i[t])&&(o.storeValue.type===BI.Selection.Multi?BI.pushDistinct(o.storeValue.value,t):BI.remove(o.storeValue.value,t))}),o._adjust(a)})},_joinAll:function(t,l){var u=this,e=this.options;this._assertValue(t),this.requesting=!0,e.itemsCreator({type:BI.MultiSelectCombo.REQ_GET_ALL_DATA,keywords:[this.trigger.getKey()]},function(e){var i=BI.map(e.items,"value");if(u.storeValue.type===t.type){var n=!1,r=u._makeMap(u.storeValue.value);return BI.each(i,function(e,t){BI.isNotNull(r[t])&&(n=!0,u.storeValue.assist&&u.storeValue.assist.push(r[t]),delete r[t])}),n&&(u.storeValue.value=BI.values(r)),void u._adjust(l)}var a=u._makeMap(u.storeValue.value),o=u._makeMap(t.value),s=[];BI.each(i,function(e,t){BI.isNotNull(a[i[e]])&&(u.storeValue.assist&&u.storeValue.assist.push(a[i[e]]),delete a[i[e]]),BI.isNull(o[i[e]])&&(BI.remove(u.storeValue.assist,t),s.push(t))}),u.storeValue.value=s.concat(BI.values(a)),u._adjust(l)})},_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 i=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var n=this._makeMap(this.storeValue.value);BI.each(e.value,function(e,t){n[t]||(i.storeValue.value.push(t),BI.remove(i.storeValue.assist,t),n[t]=t)});var r=!1;return BI.each(e.assist,function(e,t){BI.isNotNull(n[t])&&(r=!0,i.storeValue.assist&&i.storeValue.assist.push(n[t]),delete n[t])}),r&&(this.storeValue.value=BI.values(n)),void i._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:24,height:24})},_init:function(){var i=this,e=this.options;BI.MultiSelectNoBarCombo.superclass._init.apply(this,arguments);var n=function(){BI.isKey(i._startValue)&&(i.storeValue.type===BI.Selection.All?(BI.remove(i.storeValue.value,i._startValue),i.storeValue.assist=i.storeValue.assist||[],i.storeValue.assist.pushDistinct(i._startValue)):(BI.pushDistinct(i.storeValue.value,i._startValue),BI.remove(i.storeValue.assist,i._startValue))),i.trigger.getSearcher().setState(i.storeValue),i.numberCounter.setButtonChecked(i.storeValue)};this.storeValue={type:BI.Selection.Multi,value:e.value||[]},this.requesting=!1,this.trigger=BI.createWidget({type:"bi.multi_select_trigger",height:e.height-2,text:e.text,masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:e.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),itemHeight:e.itemHeight,value:{type:BI.Selection.Multi,value:e.value}}),this.trigger.on(BI.MultiSelectTrigger.EVENT_FOCUS,function(){i.fireEvent(BI.MultiSelectNoBarCombo.EVENT_FOCUS)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_BLUR,function(){i.fireEvent(BI.MultiSelectNoBarCombo.EVENT_BLUR)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_START,function(){i._setStartValue(""),this.getSearcher().setValue(i.storeValue)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_STOP,function(){i._setStartValue(""),i.fireEvent(BI.MultiSelectNoBarCombo.EVENT_STOP)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_SEARCHING,function(e){var t=BI.last(e);0<(e=BI.initial(e||[])).length&&i._joinKeywords(e,function(){BI.endWith(t,BI.BlankSplitChar)?(i.combo.setValue(i.storeValue),n(),i.combo.populate(),i._setStartValue("")):(i.combo.setValue(i.storeValue),n()),i._dataChange=!0})}),this.trigger.on(BI.MultiSelectTrigger.EVENT_CHANGE,function(e,t){t instanceof BI.MultiSelectBar?i._joinAll(this.getValue(),function(){n()}):i._join(this.getValue(),function(){n()}),i._dataChange=!0,i.fireEvent(BI.MultiSelectNoBarCombo.EVENT_CLICK_ITEM)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW,function(){i.numberCounter.updateSelectedValue(i.storeValue)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_COUNTER_CLICK,function(){i.combo.isViewVisible()||i.combo.showView()}),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!1,container:e.container,el:this.trigger,adjustLength:1,popup:{type:"bi.multi_select_no_bar_popup_view",ref:function(){i.popup=this,i.trigger.setAdapter(this),i.numberCounter.setAdapter(this)},listeners:[{eventName:BI.MultiSelectPopupView.EVENT_CHANGE,action:function(){i._dataChange=!0,i.storeValue=this.getValue(),i._adjust(function(){n()}),i.fireEvent(BI.MultiSelectNoBarCombo.EVENT_CLICK_ITEM)}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CONFIRM,action:function(){i._defaultState()}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CLEAR,action:function(){i._dataChange=!0,i.setValue(),i._defaultState()}}],itemsCreator:e.itemsCreator,itemHeight:e.itemHeight,valueFormatter:e.valueFormatter,onLoaded:function(){BI.nextTick(function(){i.combo.adjustWidth(),i.combo.adjustHeight(),i.numberCounter.adjustView(),i.trigger.getSearcher().adjustView()})}},value:{type:BI.Selection.Multi,value:e.value},hideChecker:function(e){return 0===t.element.find(e.target).length&&0===i.numberCounter.element.find(e.target).length}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){this.isViewVisible()||(i._dataChange=!1),this.setValue(i.storeValue),BI.nextTick(function(){i._populate()})}),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,function(){i._stopEditing(),!0===i.requesting?i.wants2Quit=!0:i._dataChange&&i.fireEvent(BI.MultiSelectNoBarCombo.EVENT_CONFIRM)});var t=BI.createWidget({type:"bi.trigger_icon_button",width:e.height,height:e.height,cls:"multi-select-trigger-icon-button"});t.on(BI.TriggerIconButton.EVENT_CHANGE,function(){i.numberCounter.hideView(),i.combo.isViewVisible()?i.combo.hideView():i.combo.showView()}),this.numberCounter=BI.createWidget({type:"bi.multi_select_check_selected_switcher",masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:e.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),value:{type:BI.Selection.Multi,value:e.value}}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,function(){i.combo.isViewVisible()||i.combo.showView()}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,function(){this.updateSelectedValue(i.storeValue)}),this.numberCounter.on(BI.Events.VIEW,function(e){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(!0===e?i.numberCounter.element.outerWidth()+8:0)})}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,function(){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(0)})}),this.trigger.element.click(function(e){0<i.trigger.element.find(e.target).length&&i.numberCounter.hideView()}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:t,right:0,top:0,bottom:0},{el:{type:"bi.vertical_adapt",items:[this.numberCounter]},right:e.height,top:0,height:e.height}]})},_addItem:function(e,t){var i=this,n=this.trigger.getSearcher().getKeyword();this._join({type:BI.Selection.Multi,value:[n]},function(){i.storeValue.type===BI.Selection.Multi&&BI.pushDistinct(i.storeValue.value,n),i.combo.setValue(i.storeValue),i._setStartValue(n),e(),i.populate(),i._setStartValue(""),i._dataChange=!0})},_itemsCreator4Trigger:function(t,i){var n=this;this.options.itemsCreator(t,function(e){1===t.times&&BI.isNotNull(t.keywords)&&n.trigger.setValue(BI.deepClone(n.storeValue)),i.apply(n,arguments)})},_stopEditing:function(){this.trigger.stopEditing(),this.numberCounter.hideView()},_defaultState:function(){this._stopEditing(),this.combo.hideView()},_assertValue:function(e){(e=e||{}).type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(r,a){var o=this,e=this.options;this._assertValue(this.storeValue),this.requesting=!0,e.itemsCreator({type:BI.MultiSelectNoBarCombo.REQ_GET_ALL_DATA,keywords:r},function(e){var t,i,n=BI.map(e.items,"value");t=n,i=o._makeMap(t),BI.each(r,function(e,t){BI.isNotNull(i[t])&&(o.storeValue.type===BI.Selection.Multi?BI.pushDistinct(o.storeValue.value,t):BI.remove(o.storeValue.value,t))}),o._adjust(a)})},_joinAll:function(t,l){var u=this,e=this.options;this._assertValue(t),this.requesting=!0,e.itemsCreator({type:BI.MultiSelectNoBarCombo.REQ_GET_ALL_DATA,keywords:[this.trigger.getKey()]},function(e){var i=BI.map(e.items,"value");if(u.storeValue.type===t.type){var n=!1,r=u._makeMap(u.storeValue.value);return BI.each(i,function(e,t){BI.isNotNull(r[t])&&(n=!0,u.storeValue.assist&&u.storeValue.assist.push(r[t]),delete r[t])}),n&&(u.storeValue.value=BI.values(r)),void u._adjust(l)}var a=u._makeMap(u.storeValue.value),o=u._makeMap(t.value),s=[];BI.each(i,function(e,t){BI.isNotNull(a[i[e]])&&(u.storeValue.assist&&u.storeValue.assist.push(a[i[e]]),delete a[i[e]]),BI.isNull(o[i[e]])&&(BI.remove(u.storeValue.assist,t),s.push(t))}),u.storeValue.value=s.concat(BI.values(a)),u._adjust(l)})},_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 i=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var n=this._makeMap(this.storeValue.value);BI.each(e.value,function(e,t){n[t]||(i.storeValue.value.push(t),BI.remove(i.storeValue.assist,t),n[t]=t)});var r=!1;return BI.each(e.assist,function(e,t){BI.isNotNull(n[t])&&(r=!0,i.storeValue.assist&&i.storeValue.assist.push(n[t]),delete n[t])}),r&&(this.storeValue.value=BI.values(n)),void i._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:24,allowEdit:!0})},_init:function(){var i=this,e=this.options;BI.MultiSelectInsertCombo.superclass._init.apply(this,arguments);var n=function(){BI.isKey(i._startValue)&&(i.storeValue.type===BI.Selection.All?(BI.remove(i.storeValue.value,i._startValue),i.storeValue.assist=i.storeValue.assist||[],i.storeValue.assist.pushDistinct(i._startValue)):(BI.pushDistinct(i.storeValue.value,i._startValue),BI.remove(i.storeValue.assist,i._startValue))),i.trigger.getSearcher().setState(i.storeValue),i.numberCounter.setButtonChecked(i.storeValue)};this.storeValue=e.value||{},this.requesting=!1,this.trigger=BI.createWidget({type:"bi.multi_select_insert_trigger",allowEdit:e.allowEdit,height:e.height-2,text:e.text,watermark:e.watermark,masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:e.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),itemHeight:e.itemHeight,value:e.value}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_FOCUS,function(){i.fireEvent(BI.MultiSelectInsertCombo.EVENT_FOCUS)}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_BLUR,function(){i.fireEvent(BI.MultiSelectInsertCombo.EVENT_BLUR)}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_START,function(){i._setStartValue(""),this.getSearcher().setValue(i.storeValue)}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_STOP,function(){i._setStartValue(""),i.fireEvent(BI.MultiSelectInsertCombo.EVENT_STOP)}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_PAUSE,function(){i._addItem(n,!0)}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_SEARCHING,function(e){var t=BI.last(e);0<(e=BI.initial(e||[])).length&&i._joinKeywords(e,function(){BI.endWith(t,BI.BlankSplitChar)?(i.combo.setValue(i.storeValue),n(),i.combo.populate(),i._setStartValue("")):(i.combo.setValue(i.storeValue),n()),i._dataChange=!0}),i.fireEvent(BI.MultiSelectInsertCombo.EVENT_SEARCHING)}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_CHANGE,function(e,t){t instanceof BI.MultiSelectBar?i._joinAll(this.getValue(),function(){n()}):i._join(this.getValue(),function(){n()}),i._dataChange=!0,i.fireEvent(BI.MultiSelectInsertCombo.EVENT_CLICK_ITEM)}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW,function(){i.numberCounter.updateSelectedValue(i.storeValue)}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_COUNTER_CLICK,function(){i.combo.isViewVisible()||i.combo.showView()}),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!e.allowEdit,el:this.trigger,adjustLength:1,container:e.container,popup:{type:"bi.multi_select_popup_view",ref:function(){i.popup=this,i.trigger.setAdapter(this),i.numberCounter.setAdapter(this)},listeners:[{eventName:BI.MultiSelectPopupView.EVENT_CHANGE,action:function(){i._dataChange=!0,i.storeValue=this.getValue(),i._adjust(function(){n()}),i.fireEvent(BI.MultiSelectInsertCombo.EVENT_CLICK_ITEM)}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CONFIRM,action:function(){i._defaultState()}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CLEAR,action:function(){i._dataChange=!0,i.setValue(),i._defaultState()}}],itemsCreator:e.itemsCreator,valueFormatter:e.valueFormatter,itemHeight:e.itemHeight,onLoaded:function(){BI.nextTick(function(){i.combo.adjustWidth(),i.combo.adjustHeight(),i.numberCounter.adjustView(),i.trigger.getSearcher().adjustView()})}},value:e.value,hideChecker:function(e){return 0===t.element.find(e.target).length&&0===i.numberCounter.element.find(e.target).length}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){this.isViewVisible()||(i._dataChange=!1),this.setValue(i.storeValue),BI.nextTick(function(){i._populate()})}),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,function(){i._stopEditing(),!0===i.requesting?i.wants2Quit=!0:i._dataChange&&i.fireEvent(BI.MultiSelectInsertCombo.EVENT_CONFIRM)});var t=BI.createWidget({type:"bi.trigger_icon_button",width:e.height,height:e.height,cls:"multi-select-trigger-icon-button"});t.on(BI.TriggerIconButton.EVENT_CHANGE,function(){i.numberCounter.hideView(),i.combo.isViewVisible()?i.combo.hideView():i.combo.showView()}),this.numberCounter=BI.createWidget({type:"bi.multi_select_check_selected_switcher",masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:e.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),value:e.value}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,function(){i.combo.isViewVisible()||i.combo.showView()}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,function(){this.updateSelectedValue(i.storeValue)}),this.numberCounter.on(BI.Events.VIEW,function(e){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(!0===e?i.numberCounter.element.outerWidth()+8:0)})}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,function(){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(0)})}),this.trigger.element.click(function(e){0<i.trigger.element.find(e.target).length&&i.numberCounter.hideView()}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:t,right:0,top:0,bottom:0},{el:{type:"bi.vertical_adapt",items:[this.numberCounter]},right:e.height,top:0,height:e.height}]})},_itemsCreator4Trigger:function(t,i){var n=this;this.options.itemsCreator(t,function(e){1===t.times&&BI.isNotNull(t.keywords)&&n.trigger.setValue(BI.deepClone(n.getValue())),i.apply(n,arguments)})},_addItem:function(e){var t=this,i=this.trigger.getSearcher().getKeyword();this._join({type:BI.Selection.Multi,value:[i]},function(){t.storeValue.type===BI.Selection.Multi&&BI.pushDistinct(t.storeValue.value,i),t.combo.setValue(t.storeValue),t._setStartValue(i),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||{}).type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(e,t){var i=this;this.options;this._assertValue(this.storeValue),this.requesting=!0,BI.each(e,function(e,t){i.storeValue.type===BI.Selection.Multi?BI.pushDistinct(i.storeValue.value,t):BI.remove(i.storeValue.value,t)}),i._adjust(t)},_joinAll:function(t,l){var u=this,e=this.options;this._assertValue(t),this.requesting=!0,e.itemsCreator({type:BI.MultiSelectInsertCombo.REQ_GET_ALL_DATA,keywords:[this.trigger.getKey()]},function(e){var i=BI.map(e.items,"value");if(u.storeValue.type===t.type){var n=!1,r=u._makeMap(u.storeValue.value);return BI.each(i,function(e,t){BI.isNotNull(r[t])&&(n=!0,u.storeValue.assist&&u.storeValue.assist.push(r[t]),delete r[t])}),n&&(u.storeValue.value=BI.values(r)),void u._adjust(l)}var a=u._makeMap(u.storeValue.value),o=u._makeMap(t.value),s=[];BI.each(i,function(e,t){BI.isNotNull(a[i[e]])&&(u.storeValue.assist&&u.storeValue.assist.push(a[i[e]]),delete a[i[e]]),BI.isNull(o[i[e]])&&(BI.remove(u.storeValue.assist,t),s.push(t))}),u.storeValue.value=s.concat(BI.values(a)),u._adjust(l)})},_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 i=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var n=this._makeMap(this.storeValue.value);BI.each(e.value,function(e,t){n[t]||(i.storeValue.value.push(t),BI.remove(i.storeValue.assist,t),n[t]=t)});var r=!1;return BI.each(e.assist,function(e,t){BI.isNotNull(n[t])&&(r=!0,i.storeValue.assist&&i.storeValue.assist.push(n[t]),delete n[t])}),r&&(this.storeValue.value=BI.values(n)),void i._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.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,itemsHeight:24,height:24})},_init:function(){var i=this,e=this.options;BI.MultiSelectInsertNoBarCombo.superclass._init.apply(this,arguments);var n=function(){BI.isKey(i._startValue)&&(i.storeValue.type===BI.Selection.All?(BI.remove(i.storeValue.value,i._startValue),i.storeValue.assist=i.storeValue.assist||[],i.storeValue.assist.pushDistinct(i._startValue)):(BI.pushDistinct(i.storeValue.value,i._startValue),BI.remove(i.storeValue.assist,i._startValue))),i.trigger.getSearcher().setState(i.storeValue),i.numberCounter.setButtonChecked(i.storeValue)};this.storeValue={type:BI.Selection.Multi,value:e.value||[]},this.requesting=!1,this.trigger=BI.createWidget({type:"bi.multi_select_insert_trigger",height:e.height-2,text:e.text,masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:e.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),itemHeight:e.itemHeight,value:{type:BI.Selection.Multi,value:e.value}}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_START,function(){i._setStartValue(""),this.getSearcher().setValue(i.storeValue)}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_STOP,function(){i._setStartValue("")}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_PAUSE,function(){i._addItem(n,!0)}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_SEARCHING,function(e){var t=BI.last(e);0<(e=BI.initial(e||[])).length&&i._joinKeywords(e,function(){BI.endWith(t,BI.BlankSplitChar)?(i.combo.setValue(i.storeValue),n(),i.combo.populate(),i._setStartValue("")):(i.combo.setValue(i.storeValue),n()),i._dataChange=!0})}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_CHANGE,function(e,t){t instanceof BI.MultiSelectBar?i._joinAll(this.getValue(),function(){n()}):i._join(this.getValue(),function(){n()}),i._dataChange=!0}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW,function(){i.numberCounter.updateSelectedValue(i.storeValue)}),this.trigger.on(BI.MultiSelectInsertTrigger.EVENT_COUNTER_CLICK,function(){i.combo.isViewVisible()||i.combo.showView()}),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!1,container:e.container,el:this.trigger,adjustLength:1,popup:{type:"bi.multi_select_no_bar_popup_view",ref:function(){i.popup=this,i.trigger.setAdapter(this),i.numberCounter.setAdapter(this)},listeners:[{eventName:BI.MultiSelectPopupView.EVENT_CHANGE,action:function(){i._dataChange=!0,i.storeValue=this.getValue(),i._adjust(function(){n()})}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CONFIRM,action:function(){i._defaultState()}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CLEAR,action:function(){i._dataChange=!0,i.setValue(),i._defaultState()}}],itemsCreator:e.itemsCreator,itemHeight:e.itemHeight,valueFormatter:e.valueFormatter,onLoaded:function(){BI.nextTick(function(){i.combo.adjustWidth(),i.combo.adjustHeight(),i.numberCounter.adjustView(),i.trigger.getSearcher().adjustView()})}},value:{type:BI.Selection.Multi,value:e.value},hideChecker:function(e){return 0===t.element.find(e.target).length&&0===i.numberCounter.element.find(e.target).length}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){this.isViewVisible()||(i._dataChange=!1),this.setValue(i.storeValue),BI.nextTick(function(){i._populate()})}),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,function(){i._stopEditing(),!0===i.requesting?i.wants2Quit=!0:i._dataChange&&i.fireEvent(BI.MultiSelectInsertNoBarCombo.EVENT_CONFIRM)});var t=BI.createWidget({type:"bi.trigger_icon_button",width:e.height,height:e.height,cls:"multi-select-trigger-icon-button"});t.on(BI.TriggerIconButton.EVENT_CHANGE,function(){i.numberCounter.hideView(),i.combo.isViewVisible()?i.combo.hideView():i.combo.showView()}),this.numberCounter=BI.createWidget({type:"bi.multi_select_check_selected_switcher",masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:e.valueFormatter,itemsCreator:BI.bind(this._itemsCreator4Trigger,this),value:{type:BI.Selection.Multi,value:e.value}}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,function(){i.combo.isViewVisible()||i.combo.showView()}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,function(){this.updateSelectedValue(i.storeValue)}),this.numberCounter.on(BI.Events.VIEW,function(e){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(!0===e?i.numberCounter.element.outerWidth()+8:0)})}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,function(){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(0)})}),this.trigger.element.click(function(e){0<i.trigger.element.find(e.target).length&&i.numberCounter.hideView()}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:t,right:0,top:0,bottom:0},{el:{type:"bi.vertical_adapt",items:[this.numberCounter]},right:e.height,top:0,height:e.height}]})},_itemsCreator4Trigger:function(t,i){var n=this;this.options.itemsCreator(t,function(e){1===t.times&&BI.isNotNull(t.keywords)&&n.trigger.setValue(BI.deepClone(n.storeValue)),i.apply(n,arguments)})},_addItem:function(e){var t=this,i=this.trigger.getSearcher().getKeyword();this._join({type:BI.Selection.Multi,value:[i]},function(){t.storeValue.type===BI.Selection.Multi&&BI.pushDistinct(t.storeValue.value,i),t.combo.setValue(t.storeValue),t._setStartValue(i),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||{}).type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(e,t){var i=this;this.options;this._assertValue(this.storeValue),this.requesting=!0,BI.each(e,function(e,t){i.storeValue.type===BI.Selection.Multi?BI.pushDistinct(i.storeValue.value,t):BI.remove(i.storeValue.value,t)}),i._adjust(t)},_joinAll:function(t,l){var u=this,e=this.options;this._assertValue(t),this.requesting=!0,e.itemsCreator({type:BI.MultiSelectInsertNoBarCombo.REQ_GET_ALL_DATA,keywords:[this.trigger.getKey()]},function(e){var i=BI.map(e.items,"value");if(u.storeValue.type===t.type){var n=!1,r=u._makeMap(u.storeValue.value);return BI.each(i,function(e,t){BI.isNotNull(r[t])&&(n=!0,u.storeValue.assist&&u.storeValue.assist.push(r[t]),delete r[t])}),n&&(u.storeValue.value=BI.values(r)),void u._adjust(l)}var a=u._makeMap(u.storeValue.value),o=u._makeMap(t.value),s=[];BI.each(i,function(e,t){BI.isNotNull(a[i[e]])&&(u.storeValue.assist&&u.storeValue.assist.push(a[i[e]]),delete a[i[e]]),BI.isNull(o[i[e]])&&(BI.remove(u.storeValue.assist,t),s.push(t))}),u.storeValue.value=s.concat(BI.values(a)),u._adjust(l)})},_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 i=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var n=this._makeMap(this.storeValue.value);BI.each(e.value,function(e,t){n[t]||(i.storeValue.value.push(t),BI.remove(i.storeValue.assist,t),n[t]=t)});var r=!1;return BI.each(e.assist,function(e,t){BI.isNotNull(n[t])&&(r=!0,i.storeValue.assist&&i.storeValue.assist.push(n[t]),delete n[t])}),r&&(this.storeValue.value=BI.values(n)),void i._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.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:24})},_init:function(){BI.MultiSelectLoader.superclass._init.apply(this,arguments);var s=this,l=this.options,u=!1;this.storeValue=l.value||{},this._assertValue(this.storeValue),this.button_group=BI.createWidget({type:"bi.select_list",logic:l.logic,toolbar:{type:"bi.multi_select_bar",cls:"bi-list-item-active",iconWrapperWidth:36},el:BI.extend({onLoaded:l.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"}]}}},l.el),itemsCreator:function(r,a){var o=s._startValue;s.storeValue&&(r=BI.extend(r||{},{selectedValues:BI.isKey(o)&&s.storeValue.type===BI.Selection.Multi?s.storeValue.value.concat(o):s.storeValue.value})),l.itemsCreator(r,function(e){u=e.hasNext;var t,i,n=[];1===r.times&&s.storeValue&&(t=BI.map(s.storeValue.value,function(e,t){var i=l.valueFormatter(t)||t;return{text:i,value:t,title:i,selected:s.storeValue.type===BI.Selection.Multi}}),BI.isKey(s._startValue)&&!BI.contains(s.storeValue.value,s._startValue)&&(i=l.valueFormatter(o)||o,t.unshift({text:i,value:o,title:i,selected:!0})),n=s._createItems(t)),a(n.concat(s._createItems(e.items)),e.keyword||""),1===r.times&&s.storeValue&&(BI.isKey(o)&&(s.storeValue.type===BI.Selection.All?BI.remove(s.storeValue.value,o):BI.pushDistinct(s.storeValue.value,o)),s.setValue(s.storeValue)),1===r.times&&s._scrollToTop()})},hasNext:function(){return u},value:this.storeValue}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Top),BI.extend({scrolly:!0,vgap:5},l.logic,{items:BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Top,this.button_group)})))),this.button_group.on(BI.Controller.EVENT_CHANGE,function(){s.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.button_group.on(BI.SelectList.EVENT_CHANGE,function(){s.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,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||{}).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){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:24,onLoaded:BI.emptyFn})},_init:function(){BI.MultiSelectNoBarLoader.superclass._init.apply(this,arguments);var s=this,l=this.options,u=!1;this.storeValue=l.value||{},this._assertValue(this.storeValue),this.button_group=BI.createWidget(BI.extend({type:"bi.list_pane",onLoaded:l.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(r,a){var o=s._startValue;s.storeValue&&(r=BI.extend(r||{},{selectedValues:BI.isKey(o)&&s.storeValue.type===BI.Selection.Multi?s.storeValue.value.concat(o):s.storeValue.value})),l.itemsCreator(r,function(e){u=e.hasNext;var t,i,n=[];1===r.times&&s.storeValue&&(t=BI.map(s.storeValue.value,function(e,t){var i=l.valueFormatter(t)||t;return{text:i,value:t,title:i,selected:s.storeValue.type===BI.Selection.Multi}}),BI.isKey(s._startValue)&&!BI.contains(s.storeValue.value,s._startValue)&&(i=l.valueFormatter(o)||o,t.unshift({text:i,value:o,title:i,selected:!0})),n=s._createItems(t)),a(n.concat(s._createItems(e.items)),e.keyword||""),1===r.times&&s.storeValue&&(BI.isKey(o)&&(s.storeValue.type===BI.Selection.All?BI.remove(s.storeValue.value,o):BI.pushDistinct(s.storeValue.value,o)),s.setValue(s.storeValue)),1===r.times&&s._scrollToTop()})},hasNext:function(){return u},value:this.storeValue},l.el)),BI.createWidget({type:"bi.vertical",element:this,items:[this.button_group],vgap:5}),this.button_group.on(BI.Controller.EVENT_CHANGE,function(){s.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.button_group.on(BI.SelectList.EVENT_CHANGE,function(){s.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,iconWrapperWidth:36})},_scrollToTop:function(){var e=this;BI.delay(function(){e.button_group.element.scrollTop(0)},30)},_assertValue:function(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){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:24})},_init:function(){BI.MultiSelectPopupView.superclass._init.apply(this,arguments);var t=this,e=this.options;this.loader=BI.createWidget({type:"bi.multi_select_loader",itemsCreator:e.itemsCreator,itemHeight:e.itemHeight,valueFormatter:e.valueFormatter,onLoaded:e.onLoaded,value:e.value}),this.popupView=BI.createWidget({type:"bi.multi_popup_view",stopPropagation:!1,maxWidth:e.maxWidth,minWidth:e.minWidth,maxHeight:e.maxHeight,element:this,buttons:[BI.i18nText("BI-Basic_Clears"),BI.i18nText("BI-Basic_Sure")],el:this.loader,value:e.value}),this.popupView.on(BI.MultiPopupView.EVENT_CHANGE,function(){t.fireEvent(BI.MultiSelectPopupView.EVENT_CHANGE)}),this.popupView.on(BI.MultiPopupView.EVENT_CLICK_TOOLBAR_BUTTON,function(e){switch(e){case 0:t.fireEvent(BI.MultiSelectPopupView.EVENT_CLICK_CLEAR);break;case 1:t.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:24,onLoaded:BI.emptyFn})},_init:function(){BI.MultiSelectNoBarPopupView.superclass._init.apply(this,arguments);var t=this,e=this.options;this.loader=BI.createWidget({type:"bi.multi_select_no_bar_loader",itemsCreator:e.itemsCreator,itemHeight:e.itemHeight,valueFormatter:e.valueFormatter,onLoaded:e.onLoaded,value:e.value}),this.popupView=BI.createWidget({type:"bi.multi_popup_view",stopPropagation:!1,maxWidth:e.maxWidth,minWidth:e.minWidth,maxHeight:e.maxHeight,element:this,buttons:[BI.i18nText("BI-Basic_Clears"),BI.i18nText("BI-Basic_Sure")],el:this.loader,value:e.value}),this.popupView.on(BI.MultiPopupView.EVENT_CHANGE,function(){t.fireEvent(BI.MultiSelectNoBarPopupView.EVENT_CHANGE)}),this.popupView.on(BI.MultiPopupView.EVENT_CLICK_TOOLBAR_BUTTON,function(e){switch(e){case 0:t.fireEvent(BI.MultiSelectNoBarPopupView.EVENT_CLICK_CLEAR);break;case 1:t.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 i=this,n=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.multi_select_search_loader",keywordGetter:n.keywordGetter,valueFormatter:n.valueFormatter,itemsCreator:function(e,t){n.itemsCreator.apply(i,[e,function(e){t(e),i.setKeyword(n.keywordGetter())}])},itemHeight:n.itemHeight,value:n.value}),this.loader.on(BI.Controller.EVENT_CHANGE,function(){i.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.resizer=BI.createWidget({type:"bi.vtape",element:this,items:[{el:this.addNotMatchTip,height:this.constants.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 o=this,s=this.options,l=!1;this.storeValue=BI.deepClone(s.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:s.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(r,a){o.storeValue&&(r=BI.extend(r||{},{selectedValues:o.storeValue.value})),s.itemsCreator(r,function(e){var t=e.keyword=s.keywordGetter();l=e.hasNext;var i,n=[];1===r.times&&o.storeValue&&(i=o._filterValues(o.storeValue),n=o._createItems(i)),a(n.concat(o._createItems(e.items)),t),1===r.times&&o.storeValue&&o.setValue(o.storeValue)})},hasNext:function(){return l}}),this.button_group.on(BI.Controller.EVENT_CHANGE,function(){o.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.button_group.on(BI.SelectList.EVENT_CHANGE,function(){o.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,selected:this.isAllSelected(),cls:"bi-list-item-active",iconWrapperWidth:36})},isAllSelected:function(){return this.button_group.isAllSelected()},_filterValues:function(i){var e,n=this.options,t=n.keywordGetter(),r=BI.deepClone(i.value)||[],a=BI.map(r,function(e,t){return{text:n.valueFormatter(t)||t,value:t}});return BI.isKey(t)&&(r=(e=BI.Func.getSearchResult(a,t)).match.concat(e.find)),BI.map(r,function(e,t){return{text:t.text,title:t.text,value:t.value,selected:i.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 i=this,n=this.options;this.loader=BI.createWidget({type:"bi.multi_select_search_loader",keywordGetter:n.keywordGetter,valueFormatter:n.valueFormatter,itemsCreator:function(e,t){n.itemsCreator.apply(i,[e,function(e){t(e)}])},itemHeight:n.itemHeight,value:n.value}),this.loader.on(BI.Controller.EVENT_CHANGE,function(){i.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(i){var n=this,e=this.options;i.type!==BI.Selection.All?BI.nextTick(function(){n.numberCounter.setText(i.value.length),n.setVisible(0<i.value.length)}):e.itemsCreator({type:BI.MultiSelectCombo.REQ_GET_DATA_LENGTH},function(e){var t;BI.isNotEmptyString(e.count)?BI.nextTick(function(){n.numberCounter.setText(e.count),n.setVisible(!0)}):(t=e.count-i.value.length,BI.nextTick(function(){n.numberCounter.setText(t),n.setVisible(0<t)}))})},_assertValue:function(e){return(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 i=this,e=this.options,n=BI.debounce(BI.bind(this._dealChange,this),300);return BI.extend({type:"bi.state_editor",ref:function(e){i.editor=e},hgap:e.hgap,vgap:e.vgap,lgap:e.lgap,rgap:e.rgap,tgap:e.tgap,bgap:e.bgap,height:e.height,watermark:e.watermark,allowBlank:!0,value:e.value,defaultText:e.text,text:e.text,tipType:e.tipType,warningTitle:e.warningTitle,el:{type:"bi.textarea_editor",scrolly:!1,validationChecker:function(){return!0},throttle:!0},listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(e,t){BI.contains(t,"\n")?i._dealChange(e,t):n(e,t)}},{eventName:BI.Editor.EVENT_KEY_DOWN,action:function(e){e===BI.KeyCode.ENTER&&i._clearSplitValue()}},{eventName:BI.Editor.EVENT_FOCUS,action:function(){i.fireEvent(BI.SelectPatchEditor.EVENT_FOCUS,arguments)}},{eventName:BI.Editor.EVENT_BLUR,action:function(){i._start=!1,i.fireEvent(BI.SelectPatchEditor.EVENT_BLUR,arguments)}}]},e.el)},_clearSplitValue:function(){this.editor.setValue("")},_dealChange:function(e,t){var i="";t===this.editor.getValue()&&(BI.isKey(t)&&(i=this._formatText(t)),e===BI.Events.CHANGE&&(this._setValue(i),""!==this._trimValue(i)&&(this._start&&BI.isKey(this._lastValue)&&(!0!==this._pause||this._trimValue(this._lastValue)===this._trimValue(i))||(this._start=!0,this._pause=!1,this.fireEvent(BI.Controller.EVENT_CHANGE,BI.Events.STARTEDIT,this.getValue(),this))),this._trimValue(this._lastValue)!==this._trimValue(i)&&this.fireEvent(BI.Controller.EVENT_CHANGE,arguments),BI.endWith(i,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=i)},_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 n=this,r=this.options;this.editor=BI.createWidget(r.el,{type:"bi.multi_select_editor",watermark:r.watermark,height:r.height,text:r.text,listeners:[{eventName:BI.MultiSelectEditor.EVENT_FOCUS,action:function(){n.fireEvent(BI.MultiSelectInsertSearcher.EVENT_FOCUS)}},{eventName:BI.MultiSelectEditor.EVENT_BLUR,action:function(){n.fireEvent(BI.MultiSelectInsertSearcher.EVENT_BLUR)}}]}),this.searcher=BI.createWidget({type:"bi.searcher",element:this,height:r.height,isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t()},el:this.editor,popup:BI.extend({type:"bi.multi_select_search_insert_pane",valueFormatter:r.valueFormatter,keywordGetter:function(){return n.editor.getKeyword()},itemsCreator:function(e,t){var i=n.editor.getKeyword();e.keywords=[i],this.setKeyword(i),r.itemsCreator(e,t)},itemHeight:r.itemHeight,value:r.value},r.popup),adapter:r.adapter,masker:r.masker}),this.searcher.on(BI.Searcher.EVENT_START,function(){n.fireEvent(BI.MultiSelectInsertSearcher.EVENT_START)}),this.searcher.on(BI.Searcher.EVENT_PAUSE,function(){this.hasMatched(),n.fireEvent(BI.MultiSelectInsertSearcher.EVENT_PAUSE)}),this.searcher.on(BI.Searcher.EVENT_STOP,function(){n.fireEvent(BI.MultiSelectInsertSearcher.EVENT_STOP)}),this.searcher.on(BI.Searcher.EVENT_CHANGE,function(){n.fireEvent(BI.MultiSelectInsertSearcher.EVENT_CHANGE,arguments)}),this.searcher.on(BI.Searcher.EVENT_SEARCHING,function(){var e=this.getKeywords();n.fireEvent(BI.MultiSelectInsertSearcher.EVENT_SEARCHING,e)}),BI.isNotNull(r.value)&&this.setState(r.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 i,n=this.options;(e=e||{}).value||(e.value=[]),e.type===BI.Selection.All?0===e.value.length?this.editor.setState(BI.Selection.All):BI.size(e.assist)<=20?(i="",BI.each(e.assist,function(e,t){i+=0===e?""+(n.valueFormatter(t+"")||t):","+(n.valueFormatter(t+"")||t)}),this.editor.setState(i)):this.editor.setState(BI.Selection.Multi):0===e.value.length?this.editor.setState(BI.Selection.None):BI.size(e.value)<=20?(i="",BI.each(e.value,function(e,t){i+=0===e?""+(n.valueFormatter(t+"")||t):","+(n.valueFormatter(t+"")||t)}),this.editor.setState(i)):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 n=this,r=this.options;this.editor=BI.createWidget(r.el,{type:"bi.multi_select_editor",height:r.height,text:r.text,watermark:r.watermark,listeners:[{eventName:BI.MultiSelectEditor.EVENT_FOCUS,action:function(){n.fireEvent(BI.MultiSelectSearcher.EVENT_FOCUS)}},{eventName:BI.MultiSelectEditor.EVENT_BLUR,action:function(){n.fireEvent(BI.MultiSelectSearcher.EVENT_BLUR)}}]}),this.searcher=BI.createWidget({type:"bi.searcher",element:this,height:r.height,isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t()},el:this.editor,popup:BI.extend({type:"bi.multi_select_search_pane",valueFormatter:r.valueFormatter,keywordGetter:function(){return n.editor.getValue()},itemsCreator:function(e,t){var i=n.editor.getValue();e.keywords=[i],r.itemsCreator(e,t)},itemHeight:r.itemHeight,value:r.value},r.popup),adapter:r.adapter,masker:r.masker}),this.searcher.on(BI.Searcher.EVENT_START,function(){n.fireEvent(BI.MultiSelectSearcher.EVENT_START)}),this.searcher.on(BI.Searcher.EVENT_PAUSE,function(){this.hasMatched(),n.fireEvent(BI.MultiSelectSearcher.EVENT_PAUSE)}),this.searcher.on(BI.Searcher.EVENT_STOP,function(){n.fireEvent(BI.MultiSelectSearcher.EVENT_STOP)}),this.searcher.on(BI.Searcher.EVENT_CHANGE,function(){n.fireEvent(BI.MultiSelectSearcher.EVENT_CHANGE,arguments)}),this.searcher.on(BI.Searcher.EVENT_SEARCHING,function(){var e=this.getKeywords();n.fireEvent(BI.MultiSelectSearcher.EVENT_SEARCHING,e)}),BI.isNotNull(r.value)&&this.setState(r.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 i,n=this.options;(e=e||{}).value||(e.value=[]),e.type===BI.Selection.All?0===e.value.length?this.editor.setState(BI.Selection.All):BI.size(e.assist)<=20?(i="",BI.each(e.assist,function(e,t){i+=0===e?""+(n.valueFormatter(t+"")||t):","+(n.valueFormatter(t+"")||t)}),this.editor.setState(i)):this.editor.setState(BI.Selection.Multi):0===e.value.length?this.editor.setState(BI.Selection.None):BI.size(e.value)<=20?(i="",BI.each(e.value,function(e,t){i+=0===e?""+(n.valueFormatter(t+"")||t):","+(n.valueFormatter(t+"")||t)}),this.editor.setState(i)):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 t=this,e=this.options;this.button=BI.createWidget(e.el,{type:"bi.multi_select_check_selected_button",itemsCreator:e.itemsCreator,value:e.value}),this.button.on(BI.Events.VIEW,function(){t.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:e.valueFormatter,itemsCreator:e.itemsCreator,onClickContinueSelect:function(){t.switcher.hideView()},ref:function(e){t.checkPane=e},value:e.value},e.popup),adapter:e.adapter,masker:e.masker}),this.switcher.on(BI.Switcher.EVENT_TRIGGER_CHANGE,function(){t.fireEvent(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE)}),this.switcher.on(BI.Switcher.EVENT_BEFORE_POPUPVIEW,function(){t.fireEvent(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW)}),this.switcher.on(BI.Switcher.EVENT_AFTER_HIDEVIEW,function(){t.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:24,itemHeight:24})},_init:function(){BI.MultiSelectInsertList.superclass._init.apply(this,arguments);var n=this,r=this.options;this.storeValue=this._assertValue(r.value||{});var i=function(){BI.isKey(n._startValue)&&(n.storeValue.type===BI.Selection.All?BI.remove(n.storeValue.value,n._startValue):BI.pushDistinct(n.storeValue.value,n._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:r.itemsCreator,itemHeight:r.itemHeight,valueFormatter:r.valueFormatter,logic:{dynamic:!1},el:{},value:r.value}),this.adapter.on(BI.MultiSelectLoader.EVENT_CHANGE,function(){n.storeValue=this.getValue(),i(),n.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:r.valueFormatter,keywordGetter:function(){return n.trigger.getKeyword()},itemsCreator:function(e,t){var i=n.trigger.getKeyword();BI.isNotEmptyString(i)&&(e.keywords=[i],this.setKeyword(e.keywords[0]),r.itemsCreator(e,t))},itemHeight:r.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(e){n.editor=e},height:r.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(){n._showSearcherPane(),n._setStartValue(""),this.setValue(BI.deepClone(n.storeValue))}},{eventName:BI.Searcher.EVENT_STOP,action:function(){n._showAdapter(),n._setStartValue(""),n.adapter.setValue(n.storeValue),n.adapter.populate()}},{eventName:BI.Searcher.EVENT_PAUSE,action:function(){var e=this.getKeyword();n._join({type:BI.Selection.Multi,value:[e]},function(){n.storeValue.type===BI.Selection.Multi&&BI.pushDistinct(n.storeValue.value,e),n._showAdapter(),n.adapter.setValue(n.storeValue),n._setStartValue(e),i(),n.adapter.populate(),n._setStartValue(""),n.fireEvent(BI.MultiSelectInsertList.EVENT_CHANGE)}),n._showAdapter()}},{eventName:BI.Searcher.EVENT_SEARCHING,action:function(){var e=n._getKeywords(),t=BI.last(e);0<(e=BI.initial(e||[])).length&&n._joinKeywords(e,function(){BI.endWith(t,BI.BlankSplitChar)?(n.adapter.setValue(n.storeValue),i(),n.adapter.populate(),n._setStartValue("")):(n.adapter.setValue(n.storeValue),i()),n.fireEvent(BI.MultiSelectInsertList.EVENT_CHANGE)})}},{eventName:BI.Searcher.EVENT_CHANGE,action:function(e,t){t instanceof BI.MultiSelectBar?n._joinAll(this.getValue(),function(){i(),n.fireEvent(BI.MultiSelectInsertList.EVENT_CHANGE)}):n._join(this.getValue(),function(){i(),n.fireEvent(BI.MultiSelectInsertList.EVENT_CHANGE)})}}],value:r.value}),BI.createWidget({type:"bi.vtape",element:this,items:[{el:this.trigger,height:r.searcherHeight},{el:this.adapter,height:"fill"}]}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.searcherPane,top:r.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){return(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 i=this;this.options;this._assertValue(this.storeValue),BI.each(e,function(e,t){i.storeValue.type===BI.Selection.Multi?BI.pushDistinct(i.storeValue.value,t):BI.remove(i.storeValue.value,t)}),t()},_joinAll:function(t,l){var u=this,e=this.options;this._assertValue(t),e.itemsCreator({type:BI.MultiSelectInsertList.REQ_GET_ALL_DATA,keywords:[u.trigger.getKeyword()]},function(e){var i=BI.map(e.items,"value");if(u.storeValue.type===t.type){var n=!1,r=u._makeMap(u.storeValue.value);return BI.each(i,function(e,t){BI.isNotNull(r[t])&&(n=!0,delete r[t])}),n&&(u.storeValue.value=BI.values(r)),void l()}var a=u._makeMap(u.storeValue.value),o=u._makeMap(t.value),s=[];BI.each(i,function(e,t){BI.isNotNull(a[i[e]])&&delete a[i[e]],BI.isNull(o[i[e]])&&s.push(t)}),u.storeValue.value=s.concat(BI.values(a)),l()})},_join:function(e,t){var i=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var n=this._makeMap(this.storeValue.value);BI.each(e.value,function(e,t){n[t]||(i.storeValue.value.push(t),n[t]=t)});var r=!1;return BI.each(e.assist,function(e,t){BI.isNotNull(n[t])&&(r=!0,delete n[t])}),r&&(this.storeValue.value=BI.values(n)),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:24})},_init:function(){BI.MultiSelectInsertNoBarList.superclass._init.apply(this,arguments);var n=this,r=this.options;this.storeValue={type:BI.Selection.Multi,value:r.value||[]};var i=function(){BI.isKey(n._startValue)&&(n.storeValue.type===BI.Selection.All?BI.remove(n.storeValue.value,n._startValue):BI.pushDistinct(n.storeValue.value,n._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:r.itemsCreator,itemHeight:r.itemHeight,valueFormatter:r.valueFormatter,logic:{dynamic:!1},el:{},value:{type:BI.Selection.Multi,value:r.value||[]}}),this.adapter.on(BI.MultiSelectLoader.EVENT_CHANGE,function(){n.storeValue=this.getValue(),i(),n.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:r.valueFormatter,keywordGetter:function(){return n.trigger.getKeyword()},itemsCreator:function(e,t){var i=n.trigger.getKeyword();BI.isNotEmptyString(i)&&(e.keywords=[i],this.setKeyword(e.keywords[0]),r.itemsCreator(e,t))}}),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(e){n.editor=e},height:r.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(){n._showSearcherPane(),n._setStartValue(""),this.setValue(BI.deepClone(n.storeValue))}},{eventName:BI.Searcher.EVENT_STOP,action:function(){n._showAdapter(),n._setStartValue(""),n.adapter.setValue(n.storeValue),n.adapter.populate()}},{eventName:BI.Searcher.EVENT_PAUSE,action:function(){var e=this.getKeyword();n._join({type:BI.Selection.Multi,value:[e]},function(){n.storeValue.type===BI.Selection.Multi&&BI.pushDistinct(n.storeValue.value,e),n._showAdapter(),n.adapter.setValue(n.storeValue),n._setStartValue(e),i(),n.adapter.populate(),n._setStartValue(""),n.fireEvent(BI.MultiSelectInsertNoBarList.EVENT_CHANGE)})}},{eventName:BI.Searcher.EVENT_SEARCHING,action:function(){var e=n._getKeywords(),t=BI.last(e);0<(e=BI.initial(e||[])).length&&n._joinKeywords(e,function(){BI.endWith(t,BI.BlankSplitChar)?(n.adapter.setValue(n.storeValue),i(),n.adapter.populate(),n._setStartValue("")):(n.adapter.setValue(n.storeValue),i()),n.fireEvent(BI.MultiSelectInsertNoBarList.EVENT_CHANGE)})}},{eventName:BI.Searcher.EVENT_CHANGE,action:function(e,t){t instanceof BI.MultiSelectBar?n._joinAll(this.getValue(),function(){i(),n.fireEvent(BI.MultiSelectInsertNoBarList.EVENT_CHANGE)}):n._join(this.getValue(),function(){i(),n.fireEvent(BI.MultiSelectInsertNoBarList.EVENT_CHANGE)})}}],value:{type:BI.Selection.Multi,value:r.value||[]}}),BI.createWidget({type:"bi.vtape",element:this,items:[{el:this.trigger,height:r.searcherHeight},{el:this.adapter,height:"fill"}]}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.searcherPane,top:r.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||{}).type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(e,t){var i=this;this.options;this._assertValue(this.storeValue),BI.each(e,function(e,t){i.storeValue.type===BI.Selection.Multi?BI.pushDistinct(i.storeValue.value,t):BI.remove(i.storeValue.value,t)}),t()},_joinAll:function(t,l){var u=this,e=this.options;this._assertValue(t),e.itemsCreator({type:BI.MultiSelectInsertNoBarList.REQ_GET_ALL_DATA,keywords:[u.trigger.getKeyword()]},function(e){var i=BI.map(e.items,"value");if(u.storeValue.type===t.type){var n=!1,r=u._makeMap(u.storeValue.value);return BI.each(i,function(e,t){BI.isNotNull(r[t])&&(n=!0,delete r[t])}),n&&(u.storeValue.value=BI.values(r)),void l()}var a=u._makeMap(u.storeValue.value),o=u._makeMap(t.value),s=[];BI.each(i,function(e,t){BI.isNotNull(a[i[e]])&&delete a[i[e]],BI.isNull(o[i[e]])&&s.push(t)}),u.storeValue.value=s.concat(BI.values(a)),l()})},_join:function(e,t){var i=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var n=this._makeMap(this.storeValue.value);BI.each(e.value,function(e,t){n[t]||(i.storeValue.value.push(t),n[t]=t)});var r=!1;return BI.each(e.assist,function(e,t){BI.isNotNull(n[t])&&(r=!0,delete n[t])}),r&&(this.storeValue.value=BI.values(n)),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:24})},_init:function(){BI.MultiSelectList.superclass._init.apply(this,arguments);var n=this,r=this.options;this.storeValue={};var i=function(){BI.isKey(n._startValue)&&(n.storeValue.type===BI.Selection.All?BI.remove(n.storeValue.value,n._startValue):BI.pushDistinct(n.storeValue.value,n._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:r.itemsCreator,valueFormatter:r.valueFormatter,itemHeight:r.itemHeight,logic:{dynamic:!1},el:{}}),this.adapter.on(BI.MultiSelectLoader.EVENT_CHANGE,function(){n.storeValue=this.getValue(),n._adjust(function(){i(),n.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:r.valueFormatter,keywordGetter:function(){return n.trigger.getKeyword()},itemsCreator:function(e,t){var i=n.trigger.getKeyword();BI.isNotEmptyString(i)&&(e.keywords=[i],r.itemsCreator(e,t))},itemHeight:r.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(e){n.editor=e},height:r.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(){n._showSearcherPane(),n._setStartValue(""),this.setValue(BI.deepClone(n.storeValue))}},{eventName:BI.Searcher.EVENT_STOP,action:function(){n._showAdapter(),n._setStartValue(""),n.adapter.setValue(n.storeValue),n.adapter.populate()}},{eventName:BI.Searcher.EVENT_PAUSE,action:function(){n._showAdapter(),n.fireEvent(BI.MultiSelectList.EVENT_CHANGE)}},{eventName:BI.Searcher.EVENT_SEARCHING,action:function(){var e=this.getKeyword(),t=BI.last(e);0<(e=BI.initial(e||[])).length&&n._joinKeywords(e,function(){BI.endWith(t,BI.BlankSplitChar)?(n.adapter.setValue(n.storeValue),i(),n.adapter.populate(),n._setStartValue("")):(n.adapter.setValue(n.storeValue),i()),n.fireEvent(BI.MultiSelectList.EVENT_CHANGE)})}},{eventName:BI.Searcher.EVENT_CHANGE,action:function(e,t){t instanceof BI.MultiSelectBar?n._joinAll(this.getValue(),function(){i(),n.fireEvent(BI.MultiSelectList.EVENT_CHANGE)}):n._join(this.getValue(),function(){i(),n.fireEvent(BI.MultiSelectList.EVENT_CHANGE)})}}]}),BI.createWidget({type:"bi.vtape",element:this,items:[{el:this.trigger,height:r.searcherHeight},{el:this.adapter,height:"fill"}]}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.searcherPane,top:r.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||{}).type||(e.type=BI.Selection.Multi),e.value||(e.value=[])},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(r,a){var o=this,e=this.options;this._assertValue(this.storeValue),e.itemsCreator({type:BI.MultiSelectList.REQ_GET_ALL_DATA,keywords:r},function(e){var t,i,n=BI.map(e.items,"value");t=n,i=o._makeMap(t),BI.each(r,function(e,t){BI.isNotNull(i[t])&&(o.storeValue.type===BI.Selection.Multi?BI.pushDistinct(o.storeValue.value,t):BI.remove(o.storeValue.value,t))}),o._adjust(a)})},_joinAll:function(t,l){var u=this,e=this.options;this._assertValue(t),e.itemsCreator({type:BI.MultiSelectList.REQ_GET_ALL_DATA,keywords:[this.trigger.getKey()]},function(e){var i=BI.map(e.items,"value");if(u.storeValue.type===t.type){var n=!1,r=u._makeMap(u.storeValue.value);return BI.each(i,function(e,t){BI.isNotNull(r[t])&&(n=!0,delete r[t])}),n&&(u.storeValue.value=BI.values(r)),void u._adjust(l)}var a=u._makeMap(u.storeValue.value),o=u._makeMap(t.value),s=[];BI.each(i,function(e,t){BI.isNotNull(a[i[e]])&&delete a[i[e]],BI.isNull(o[i[e]])&&s.push(t)}),u.storeValue.value=s.concat(BI.values(a)),u._adjust(l)})},_adjust:function(t){var i=this,e=this.options;function n(){i.storeValue.type===BI.Selection.All&&i.storeValue.value.length>=i._count?i.storeValue={type:BI.Selection.Multi,value:[]}:i.storeValue.type===BI.Selection.Multi&&i.storeValue.value.length>=i._count&&(i.storeValue={type:BI.Selection.All,value:[]})}this._count?(n(),t()):e.itemsCreator({type:BI.MultiSelectList.REQ_GET_DATA_LENGTH},function(e){i._count=e.count,n(),t()})},_join:function(e,t){var i=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var n=this._makeMap(this.storeValue.value);BI.each(e.value,function(e,t){n[t]||(i.storeValue.value.push(t),n[t]=t)});var r=!1;return BI.each(e.assist,function(e,t){BI.isNotNull(n[t])&&(r=!0,delete n[t])}),r&&(this.storeValue.value=BI.values(n)),void i._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 i=this,n=this.options;this.storeValue={value:{}},this.adapter=BI.createWidget({type:"bi.multi_select_tree_popup",itemsCreator:n.itemsCreator,showLine:n.showLine}),this.adapter.on(BI.MultiSelectTreePopup.EVENT_CHANGE,function(){i.searcher.isSearching()?i.storeValue={value:i.searcherPane.getValue()}:i.storeValue={value:i.adapter.getValue()},i.setSelectedValue(i.storeValue.value),i.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 i.searcher.getKeyword()},itemsCreator:function(e,t){e.keyword=i.searcher.getKeyword(),n.itemsCreator(e,t)}}),this.searcherPane.setVisible(!1),this.searcher=BI.createWidget({type:"bi.searcher",isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t({keyword:i.searcher.getKeyword()})},adapter:this.adapter,popup:this.searcherPane,masker:!1,listeners:[{eventName:BI.Searcher.EVENT_START,action:function(){i._showSearcherPane()}},{eventName:BI.Searcher.EVENT_STOP,action:function(){i._showAdapter(),BI.nextTick(function(){i.adapter.populate()})}},{eventName:BI.Searcher.EVENT_CHANGE,action:function(){i.searcher.isSearching()?i.storeValue={value:i.searcherPane.getValue()}:i.storeValue={value:i.adapter.getValue()},i.setSelectedValue(i.storeValue.value),i.fireEvent(BI.MultiSelectTree.EVENT_CHANGE)}},{eventName:BI.Searcher.EVENT_PAUSE,action:function(){i._showAdapter(),BI.nextTick(function(){i.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,i=this.options;this.selectedValues={};var t=BI.createWidget({type:"bi.text_button",text:BI.i18nText("BI-Continue_Select"),cls:"multi-tree-check-selected"});t.on(BI.TextButton.EVENT_CHANGE,function(){i.onClickContinueSelect(),BI.nextTick(function(){e.empty()})});var n=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:t,lgap:this.constants.lgap,tgap:this.constants.tgap}]});this.display=BI.createWidget(i.el,{type:"bi.display_tree",cls:"bi-multi-tree-display",itemsCreator:function(e,t){e.type=BI.TreeView.REQ_TYPE_GET_SELECTED_DATA,i.itemsCreator(e,t)},value:(i.value||{}).value}),this.display.on(BI.Events.AFTERINIT,function(){e.fireEvent(BI.Events.AFTERINIT)}),this.display.on(BI.TreeView.EVENT_INIT,function(){n.setVisible(!1)}),this.display.on(BI.TreeView.EVENT_AFTERINIT,function(){n.setVisible(!0)}),BI.createWidget({type:"bi.vtape",element:this,items:[{height:this.constants.height,el:n},{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 i=this,e=this.options;BI.MultiTreeCombo.superclass._init.apply(this,arguments);var t=!1,n=!1;this.storeValue={value:e.value||{}},this.trigger=BI.createWidget({type:"bi.multi_select_trigger",allowEdit:e.allowEdit,height:e.height-2,valueFormatter:e.valueFormatter,text:e.text,watermark:e.watermark,masker:{offset:this.constants.offset},searcher:{type:"bi.multi_tree_searcher",itemsCreator:e.itemsCreator},value:{value:e.value||{}}}),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!e.allowEdit,container:e.container,el:this.trigger,adjustLength:1,popup:{type:"bi.multi_tree_popup_view",ref:function(){i.popup=this,i.trigger.setAdapter(this),i.numberCounter.setAdapter(this)},listeners:[{eventName:BI.MultiTreePopup.EVENT_AFTERINIT,action:function(){i.numberCounter.adjustView(),(t=!0)===n&&l()}},{eventName:BI.MultiTreePopup.EVENT_CHANGE,action:function(){r=!0;var e={type:BI.Selection.Multi,value:this.hasChecked()?this.getValue():{}};i.trigger.getSearcher().setState(e),i.numberCounter.setButtonChecked(e),i.fireEvent(BI.MultiTreeCombo.EVENT_CLICK_ITEM,i.combo.getValue())}},{eventName:BI.MultiTreePopup.EVENT_CLICK_CONFIRM,action:function(){i.combo.hideView()}},{eventName:BI.MultiTreePopup.EVENT_CLICK_CLEAR,action:function(){a=!0,i.setValue(),i._defaultState()}}],itemsCreator:e.itemsCreator,onLoaded:function(){BI.nextTick(function(){i.numberCounter.adjustView(),i.trigger.getSearcher().adjustView()})},maxWidth:e.isNeedAdjustWidth?"auto":500},isNeedAdjustWidth:e.isNeedAdjustWidth,value:{value:e.value||{}},hideChecker:function(e){return 0===u.element.find(e.target).length&&0===i.numberCounter.element.find(e.target).length}});var r=!1,a=!1,o=function(){return i.trigger.getSearcher().isSearching()},s=function(){return i.combo.isViewVisible()};function l(){o()?i.storeValue={value:i.trigger.getValue()}:s()&&(i.storeValue={value:i.combo.getValue()}),i.trigger.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue)}this.trigger.on(BI.MultiSelectTrigger.EVENT_FOCUS,function(){i.fireEvent(BI.MultiTreeCombo.EVENT_FOCUS)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_BLUR,function(){i.fireEvent(BI.MultiTreeCombo.EVENT_BLUR)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_START,function(){i.storeValue={value:i.combo.getValue()},this.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_STOP,function(){i.storeValue={value:this.getValue()},i.combo.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue),BI.nextTick(function(){s()&&i.combo.populate()}),i.fireEvent(BI.MultiTreeCombo.EVENT_STOP)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_SEARCHING,function(){i.fireEvent(BI.MultiTreeCombo.EVENT_SEARCHING)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_TRIGGER_CLICK,function(){i.combo.toggle()}),this.trigger.on(BI.MultiSelectTrigger.EVENT_COUNTER_CLICK,function(){i.combo.isViewVisible()||i.combo.showView()}),this.trigger.on(BI.MultiSelectTrigger.EVENT_CHANGE,function(){var e=this.getSearcher().hasChecked(),t={type:BI.Selection.Multi,value:e?{1:1}:{}};this.getSearcher().setState(e?BI.Selection.Multi:BI.Selection.None),i.numberCounter.setButtonChecked(t),i.fireEvent(BI.MultiTreeCombo.EVENT_CLICK_ITEM,i.combo.getValue())}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){o()||(!0===r&&(i.storeValue={value:i.combo.getValue()},r=!1),i.combo.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue),i.populate(),i.fireEvent(BI.MultiTreeCombo.EVENT_BEFORE_POPUPVIEW))}),this.combo.on(BI.Combo.EVENT_BEFORE_HIDEVIEW,function(){o()?(i._stopEditing(),i.fireEvent(BI.MultiTreeCombo.EVENT_CONFIRM)):s()&&(i._stopEditing(),i.storeValue={value:i.combo.getValue()},!0===a&&(i.storeValue={value:{}}),i.fireEvent(BI.MultiTreeCombo.EVENT_CONFIRM)),r=a=!1});var u=BI.createWidget({type:"bi.trigger_icon_button",width:e.height,height:e.height,cls:"multi-select-trigger-icon-button"});u.on(BI.TriggerIconButton.EVENT_CHANGE,function(){i.numberCounter.hideView(),i.combo.isViewVisible()?i.combo.hideView():i.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:e.itemsCreator,valueFormatter:e.valueFormatter,value:{value:e.value||{}}}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,function(){i.combo.isViewVisible()||i.combo.showView()}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,function(){!1===n&&(n=!0),!0===t&&(n=null,l())}),this.numberCounter.on(BI.Events.VIEW,function(e){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(!0===e?i.numberCounter.element.outerWidth()+8:0)})}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,function(){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(0)})}),this.trigger.element.click(function(e){0<i.trigger.element.find(e.target).length&&i.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:e.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||{}})},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 i=this,e=this.options;BI.MultiTreeInsertCombo.superclass._init.apply(this,arguments);var t=!1,n=!1;this.storeValue={value:e.value||{}},this.trigger=BI.createWidget({type:"bi.multi_select_trigger",allowEdit:e.allowEdit,height:e.height-2,valueFormatter:e.valueFormatter,masker:{offset:this.constants.offset},searcher:{type:"bi.multi_tree_searcher",text:e.text,watermark:e.watermark,itemsCreator:e.itemsCreator,popup:{type:"bi.multi_tree_search_insert_pane",listeners:[{eventName:BI.MultiTreeSearchInsertPane.EVENT_ADD_ITEM,action:function(){i.storeValue.value[i.trigger.getSearcher().getKeyword()]={},i._assertShowValue(),i.combo.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue),i._stopEditing()}}]}},value:{value:e.value||{}}}),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!e.allowEdit,container:e.container,el:this.trigger,adjustLength:1,popup:{type:"bi.multi_tree_popup_view",ref:function(){i.popup=this,i.trigger.setAdapter(this),i.numberCounter.setAdapter(this)},listeners:[{eventName:BI.MultiTreePopup.EVENT_AFTERINIT,action:function(){i.numberCounter.adjustView(),(t=!0)===n&&l()}},{eventName:BI.MultiTreePopup.EVENT_CHANGE,action:function(){r=!0;var e={type:BI.Selection.Multi,value:this.hasChecked()?this.getValue():{}};i.trigger.getSearcher().setState(e),i.numberCounter.setButtonChecked(e),i.fireEvent(BI.MultiTreeInsertCombo.EVENT_CLICK_ITEM,i.combo.getValue())}},{eventName:BI.MultiTreePopup.EVENT_CLICK_CONFIRM,action:function(){i.combo.hideView()}},{eventName:BI.MultiTreePopup.EVENT_CLICK_CLEAR,action:function(){a=!0,i.setValue(),i._defaultState()}}],itemsCreator:e.itemsCreator,onLoaded:function(){BI.nextTick(function(){i.numberCounter.adjustView(),i.trigger.getSearcher().adjustView()})},maxWidth:e.isNeedAdjustWidth?"auto":500},isNeedAdjustWidth:e.isNeedAdjustWidth,value:{value:e.value||{}},hideChecker:function(e){return 0===u.element.find(e.target).length&&0===i.numberCounter.element.find(e.target).length}});var r=!1,a=!1,o=function(){return i.trigger.getSearcher().isSearching()},s=function(){return i.combo.isViewVisible()};function l(){o()?i.storeValue={value:i.trigger.getValue()}:s()&&(i.storeValue={value:i.combo.getValue()}),i.trigger.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue)}this.trigger.on(BI.MultiSelectTrigger.EVENT_FOCUS,function(){i.fireEvent(BI.MultiTreeInsertCombo.EVENT_FOCUS)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_BLUR,function(){i.fireEvent(BI.MultiTreeInsertCombo.EVENT_BLUR)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_START,function(){i.storeValue={value:i.combo.getValue()},this.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_STOP,function(){i.storeValue={value:this.getValue()},i.combo.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue),BI.nextTick(function(){s()&&i.combo.populate()}),i.fireEvent(BI.MultiTreeInsertCombo.EVENT_STOP)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_SEARCHING,function(){i.fireEvent(BI.MultiTreeInsertCombo.EVENT_SEARCHING)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_TRIGGER_CLICK,function(){i.combo.toggle()}),this.trigger.on(BI.MultiSelectTrigger.EVENT_CHANGE,function(){var e=this.getSearcher().hasChecked(),t={type:BI.Selection.Multi,value:e?{1:1}:{}};this.getSearcher().setState(e?BI.Selection.Multi:BI.Selection.None),i.numberCounter.setButtonChecked(t),i.fireEvent(BI.MultiTreeInsertCombo.EVENT_CLICK_ITEM,i.combo.getValue())}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){o()||(!0===r&&(i.storeValue={value:i.combo.getValue()},r=!1),i.combo.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue),i.populate(),i.fireEvent(BI.MultiTreeInsertCombo.EVENT_BEFORE_POPUPVIEW))}),this.combo.on(BI.Combo.EVENT_BEFORE_HIDEVIEW,function(){o()?(i._stopEditing(),i.fireEvent(BI.MultiTreeInsertCombo.EVENT_CONFIRM)):s()&&(i._stopEditing(),i.storeValue={value:i.combo.getValue()},!0===a&&(i.storeValue={value:{}}),i.fireEvent(BI.MultiTreeInsertCombo.EVENT_CONFIRM)),r=a=!1});var u=BI.createWidget({type:"bi.trigger_icon_button",width:e.height,height:e.height,cls:"multi-select-trigger-icon-button"});u.on(BI.TriggerIconButton.EVENT_CHANGE,function(){i.numberCounter.hideView(),i.combo.isViewVisible()?i.combo.hideView():i.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:e.itemsCreator,masker:{offset:this.constants.offset},valueFormatter:e.valueFormatter,value:e.value}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,function(){i.combo.isViewVisible()||i.combo.showView()}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,function(){!1===n&&(n=!0),!0===t&&(n=null,l())}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,function(){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(0)})}),this.numberCounter.on(BI.Events.VIEW,function(e){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(!0===e?i.numberCounter.element.outerWidth()+8:0)})}),this.trigger.element.click(function(e){0<i.trigger.element.find(e.target).length&&i.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:e.height,top:0,height:e.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()},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 i=this,e=this.options;BI.MultiTreeListCombo.superclass._init.apply(this,arguments);var t=!1,n=!1;this.storeValue={value:e.value||[]},this.trigger=BI.createWidget({type:"bi.multi_select_trigger",allowEdit:e.allowEdit,text:e.text,watermark:e.watermark,height:e.height-2,valueFormatter:e.valueFormatter,masker:{offset:this.constants.offset},searcher:{type:"bi.multi_list_tree_searcher",itemsCreator:e.itemsCreator,popup:{type:e.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(){i.storeValue.value.unshift([i.trigger.getSearcher().getKeyword()]),i._assertShowValue(),i.combo.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue),i._stopEditing()}}]}},switcher:{el:{type:"bi.multi_tree_check_selected_button"},popup:{type:"bi.multi_tree_check_pane",el:{type:"bi.list_display_tree"},itemsCreator:e.itemsCreator}},value:{value:e.value||{}}}),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!e.allowEdit,container:e.container,el:this.trigger,adjustLength:1,popup:{type:"bi.multi_tree_popup_view",ref:function(){i.popup=this,i.trigger.setAdapter(this),i.numberCounter.setAdapter(this)},el:{type:"bi.list_async_tree"},listeners:[{eventName:BI.MultiTreePopup.EVENT_AFTERINIT,action:function(){i.numberCounter.adjustView(),(t=!0)===n&&l()}},{eventName:BI.MultiTreePopup.EVENT_CHANGE,action:function(){r=!0;var e={type:BI.Selection.Multi,value:this.hasChecked()?this.getValue():[]};i.trigger.getSearcher().setState(e),i.numberCounter.setButtonChecked(e),i.fireEvent(BI.MultiTreeListCombo.EVENT_CLICK_ITEM,i.combo.getValue())}},{eventName:BI.MultiTreePopup.EVENT_CLICK_CONFIRM,action:function(){i.combo.hideView()}},{eventName:BI.MultiTreePopup.EVENT_CLICK_CLEAR,action:function(){a=!0,i.setValue(),i._defaultState()}}],itemsCreator:e.itemsCreator,onLoaded:function(){BI.nextTick(function(){i.numberCounter.adjustView(),i.trigger.getSearcher().adjustView()})},maxWidth:e.isNeedAdjustWidth?"auto":500},isNeedAdjustWidth:e.isNeedAdjustWidth,value:{value:e.value||{}},hideChecker:function(e){return 0===u.element.find(e.target).length&&0===i.numberCounter.element.find(e.target).length}});var r=!1,a=!1,o=function(){return i.trigger.getSearcher().isSearching()},s=function(){return i.combo.isViewVisible()};function l(){o()?i.storeValue={value:i.trigger.getValue()}:s()&&(i.storeValue={value:i.combo.getValue()}),i.trigger.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue)}this.trigger.on(BI.MultiSelectTrigger.EVENT_FOCUS,function(){i.fireEvent(BI.MultiTreeListCombo.EVENT_FOCUS)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_BLUR,function(){i.fireEvent(BI.MultiTreeListCombo.EVENT_BLUR)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_START,function(){i.storeValue={value:i.combo.getValue()},this.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_STOP,function(){i.storeValue={value:this.getValue()},i.combo.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue),BI.nextTick(function(){s()&&i.combo.populate()}),i.fireEvent(BI.MultiTreeListCombo.EVENT_STOP)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_SEARCHING,function(){i.fireEvent(BI.MultiTreeListCombo.EVENT_SEARCHING)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_TRIGGER_CLICK,function(){i.combo.toggle()}),this.trigger.on(BI.MultiSelectTrigger.EVENT_CHANGE,function(){var e=this.getSearcher().hasChecked(),t={type:BI.Selection.Multi,value:e?{1:1}:{}};this.getSearcher().setState(e?BI.Selection.Multi:BI.Selection.None),i.numberCounter.setButtonChecked(t),i.fireEvent(BI.MultiTreeListCombo.EVENT_CLICK_ITEM,i.combo.getValue())}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){o()||(!0===r&&(i.storeValue={value:i.combo.getValue()},r=!1),i.combo.setValue(i.storeValue),i.numberCounter.setValue(i.storeValue),i.populate(),i.fireEvent(BI.MultiTreeListCombo.EVENT_BEFORE_POPUPVIEW))}),this.combo.on(BI.Combo.EVENT_BEFORE_HIDEVIEW,function(){o()?(i.trigger.stopEditing(),i.fireEvent(BI.MultiTreeListCombo.EVENT_CONFIRM)):s()&&(i._stopEditing(),i.storeValue={value:i.combo.getValue()},!0===a&&(i.storeValue={value:[]}),i.fireEvent(BI.MultiTreeListCombo.EVENT_CONFIRM)),r=a=!1});var u=BI.createWidget({type:"bi.trigger_icon_button",width:e.height,height:e.height,cls:"multi-select-trigger-icon-button"});u.on(BI.TriggerIconButton.EVENT_CHANGE,function(){i.numberCounter.hideView(),i.combo.isViewVisible()?i.combo.hideView():i.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:e.itemsCreator,masker:{offset:{left:0,top:0,right:0,bottom:25}},valueFormatter:e.valueFormatter,value:e.value}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,function(){i.combo.isViewVisible()||i.combo.showView()}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,function(){!1===n&&(n=!0),!0===t&&(n=null,l())}),this.numberCounter.on(BI.Events.VIEW,function(e){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(!0===e?i.numberCounter.element.outerWidth()+8:0)})}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_AFTER_HIDEVIEW,function(){BI.nextTick(function(){i.trigger.refreshPlaceHolderWidth(0)})}),this.trigger.element.click(function(e){0<i.trigger.element.find(e.target).length&&i.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:e.height,top:0,height:e.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()},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 t=this,e=this.options,i=e.value;this.selectedValues={},this.tree=BI.createWidget(e.el,{type:"bi.async_tree",showLine:e.showLine,height:400,cls:"popup-view-tree",itemsCreator:e.itemsCreator,onLoaded:e.onLoaded,value:i.value||{}}),this.popupView=BI.createWidget({type:"bi.multi_popup_view",element:this,stopPropagation:!1,maxWidth:e.maxWidth,minWidth:e.minWidth,maxHeight:e.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(e){switch(e){case 0:t.fireEvent(BI.MultiTreePopup.EVENT_CLICK_CLEAR);break;case 1:t.fireEvent(BI.MultiTreePopup.EVENT_CLICK_CONFIRM)}}),this.tree.on(BI.TreeView.EVENT_CHANGE,function(){t.fireEvent(BI.MultiTreePopup.EVENT_CHANGE)}),this.tree.on(BI.TreeView.EVENT_AFTERINIT,function(){t.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=0<BI.size(e.value);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 i=this,n=this.options;return{type:"bi.absolute",items:[{el:{type:"bi.text_button",invisible:!0,ref:function(e){i.addTip=e},text:BI.i18nText("BI-Basic_Click_To_Add_Text",""),height:this.constants.height,cls:"bi-high-light",handler:function(){i.fireEvent(BI.MultiTreeSearchInsertPane.EVENT_ADD_ITEM,n.keywordGetter())}},top:5,left:0,right:0},{el:BI.extend({type:"bi.part_tree",tipText:BI.i18nText("BI-No_Select"),itemsCreator:function(e,t){e.keyword=n.keywordGetter(),n.itemsCreator(e,function(e){t(e),i.setKeyword(n.keywordGetter(),e.items)})},ref:function(e){i.partTree=e},value:n.value,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(){i.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}},{eventName:BI.TreeView.EVENT_CHANGE,action:function(){i.fireEvent(BI.MultiTreeSearchInsertPane.EVENT_CHANGE)}}]},n.el),left:0,top:0,bottom:0,right:0}]}},setKeyword:function(e,t){var i=BI.isEmptyArray(t);this.addTip.setVisible(i),this.partTree.setVisible(!i),i&&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 t=this,i=this.options;return BI.extend({type:"bi.part_tree",element:this,tipText:BI.i18nText("BI-No_Select"),itemsCreator:function(e,t){e.keyword=i.keywordGetter(),i.itemsCreator(e,t)},value:i.value,listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(){t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}},{eventName:BI.TreeView.EVENT_CHANGE,action:function(){t.fireEvent(BI.MultiTreeSearchPane.EVENT_CHANGE)}}],ref:function(e){t.partTree=e}},i.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 i=this,n=this.options;this.editor=BI.createWidget({type:"bi.multi_select_editor",height:n.height,text:n.text,watermark:n.watermark,el:{type:"bi.simple_state_editor",height:n.height}}),this.searcher=BI.createWidget({type:"bi.searcher",element:this,isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t({keyword:i.editor.getValue()})},el:this.editor,popup:BI.extend({type:"bi.multi_tree_search_pane",keywordGetter:function(){return i.editor.getValue()},itemsCreator:function(e,t){e.keyword=i.editor.getValue(),n.itemsCreator(e,t)},value:n.value},n.popup),adapter:n.adapter,masker:n.masker}),this.searcher.on(BI.Searcher.EVENT_START,function(){i.fireEvent(BI.MultiListTreeSearcher.EVENT_START)}),this.searcher.on(BI.Searcher.EVENT_PAUSE,function(){this.hasMatched(),i.fireEvent(BI.MultiListTreeSearcher.EVENT_PAUSE)}),this.searcher.on(BI.Searcher.EVENT_STOP,function(){i.fireEvent(BI.MultiListTreeSearcher.EVENT_STOP)}),this.searcher.on(BI.Searcher.EVENT_CHANGE,function(){i.fireEvent(BI.MultiListTreeSearcher.EVENT_CHANGE,arguments)}),BI.isNotNull(n.value)&&this.setState(n.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 n=this.options;(e=e||{}).value||(e.value=[]);var r,a=0;BI.isNumber(e)?this.editor.setState(e):0===BI.size(e.value)?this.editor.setState(BI.Selection.None):(r="",BI.each(e.value,function(e,t){var i=BI.last(t);r+=(n.valueFormatter(i+"")||i)+"; ",a++}),20<a?this.editor.setState(BI.Selection.Multi):this.editor.setState(r))},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 i=this,n=this.options;this.editor=BI.createWidget({type:"bi.multi_select_editor",watermark:n.watermark,height:n.height,el:{type:"bi.simple_state_editor",text:n.text,height:n.height},listeners:[{eventName:BI.MultiSelectEditor.EVENT_FOCUS,action:function(){i.fireEvent(BI.MultiSelectSearcher.EVENT_FOCUS)}},{eventName:BI.MultiSelectEditor.EVENT_BLUR,action:function(){i.fireEvent(BI.MultiSelectSearcher.EVENT_BLUR)}}]}),this.searcher=BI.createWidget({type:"bi.searcher",element:this,isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t({keyword:i.editor.getValue()})},el:this.editor,popup:BI.extend({type:"bi.multi_tree_search_pane",keywordGetter:function(){return i.editor.getValue()},itemsCreator:function(e,t){e.keyword=i.editor.getValue(),n.itemsCreator(e,t)},value:n.value},n.popup),adapter:n.adapter,masker:n.masker}),this.searcher.on(BI.Searcher.EVENT_START,function(){i.fireEvent(BI.MultiTreeSearcher.EVENT_START)}),this.searcher.on(BI.Searcher.EVENT_PAUSE,function(){i.fireEvent(BI.MultiTreeSearcher.EVENT_PAUSE)}),this.searcher.on(BI.Searcher.EVENT_STOP,function(){i.fireEvent(BI.MultiTreeSearcher.EVENT_STOP)}),this.searcher.on(BI.Searcher.EVENT_CHANGE,function(){i.fireEvent(BI.MultiTreeSearcher.EVENT_CHANGE,arguments)}),this.searcher.on(BI.Searcher.EVENT_SEARCHING,function(){var e=this.getKeywords();i.fireEvent(BI.MultiTreeSearcher.EVENT_SEARCHING,e)}),BI.isNotNull(n.value)&&this.setState(n.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 l=this.options;(e=e||{}).value||(e.value={});var n,r,t,u=0;BI.isNumber(e)?this.editor.setState(e):0===BI.size(e.value)?this.editor.setState(BI.Selection.None):(n="",r=e.value,t=BI.Func.getSortedResult(BI.keys(r)),BI.each(t,function(e,t){var i=function s(n){var r="";var a=0,o=BI.size(n);var e=BI.Func.getSortedResult(BI.keys(n));BI.each(e,function(e,t){a++;var i=s(n[t]);r+=(l.valueFormatter(t+"")||t)+(""===i?"":":"+i)+(a===o?"":","),""===i&&u++});return r}(r[t]);n+=(l.valueFormatter(t+"")||t)+(""===i?"":":"+i)+"; ",""===i&&u++}),20<u?this.editor.setState(BI.Selection.Multi):this.editor.setState(n))},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 t=this,i=this.options;this.editor=BI.createWidget({type:"bi.sign_editor",height:i.height-2,allowBlank:i.allowBlank,value:i.valueFormatter(i.value),validationChecker:function(e){return!(i.validationChecker===BI.emptyFn&&!t._checkValueInRange(e))&&i.validationChecker(e)},errorText:i.errorText}),this.editor.on(BI.TextEditor.EVENT_CHANGE,function(){t.fireEvent(BI.NumberEditor.EVENT_CHANGE)}),this.editor.on(BI.TextEditor.EVENT_ERROR,function(){i.value=BI.parseFloat(this.getLastValidValue()),t._checkAdjustDisabled(i.value)}),this.editor.on(BI.TextEditor.EVENT_VALID,function(){i.value=BI.parseFloat(this.getValue()),t._checkAdjustDisabled(i.value)}),this.editor.on(BI.TextEditor.EVENT_CONFIRM,function(){t.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(){t._finetuning(i.step),t.fireEvent(BI.NumberEditor.EVENT_CHANGE),t.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(){t._finetuning(-i.step),t.fireEvent(BI.NumberEditor.EVENT_CHANGE),t.fireEvent(BI.NumberEditor.EVENT_CONFIRM)}),BI.createWidget({type:"bi.htape",height:i.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 t=this,i=this.constants,e=this.options;BI.NumberInterval.superclass._init.apply(this,arguments),this.smallEditor=BI.createWidget({type:"bi.number_interval_single_editor",height:e.height-2,watermark:e.watermark,allowBlank:e.allowBlank,value:e.min,level:"warning",tipType:"success",title:function(){return t.smallEditor&&t.smallEditor.getValue()},quitChecker:function(){return!1},validationChecker:function(e){return!!BI.isNumeric(e)||(t.smallEditorBubbleType=i.typeError,!1)},cls:"number-interval-small-editor bi-border"}),this.smallTip=BI.createWidget({type:"bi.label",text:e.numTip,height:e.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:e.height-2,watermark:e.watermark,allowBlank:e.allowBlank,value:e.max,title:function(){return t.bigEditor&&t.bigEditor.getValue()},quitChecker:function(){return!1},validationChecker:function(e){return!!BI.isNumeric(e)||(t.bigEditorBubbleType=i.typeError,!1)},cls:"number-interval-big-editor bi-border"}),this.bigTip=BI.createWidget({type:"bi.label",text:e.numTip,height:e.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:e.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===e.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:e.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===e.closeMax?this.bigCombo.setValue(1):this.bigCombo.setValue(0),this.label=BI.createWidget({type:"bi.label",text:BI.i18nText("BI-Basic_Value"),textHeight:e.height-2*i.border,width:i.width-2*i.border,height:e.height-2*i.border,level:"warning",tipType:"warning"}),this.left=BI.createWidget({type:"bi.htape",items:[{el:t.smallEditor},{el:t.smallCombo,width:i.width-i.border}]}),this.right=BI.createWidget({type:"bi.htape",items:[{el:t.bigCombo,width:i.width-i.border},{el:t.bigEditor,lgap:1}]}),BI.createWidget({element:t,type:"bi.center",hgap:15,height:e.height,items:[{type:"bi.absolute",items:[{el:t.left,left:-15,right:0,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:t.right,left:0,right:-15,top:0,bottom:0}]}]}),BI.createWidget({element:t,type:"bi.horizontal_auto",items:[t.label]}),t._setValidEvent(t.bigEditor,i.bigEditor),t._setValidEvent(t.smallEditor,i.smallEditor),t._setErrorEvent(t.bigEditor,i.bigEditor),t._setErrorEvent(t.smallEditor,i.smallEditor),t._setBlurEvent(t.bigEditor),t._setBlurEvent(t.smallEditor),t._setFocusEvent(t.bigEditor),t._setFocusEvent(t.smallEditor),t._setComboValueChangedEvent(t.bigCombo),t._setComboValueChangedEvent(t.smallCombo),t._setEditorValueChangedEvent(t.bigEditor),t._setEditorValueChangedEvent(t.smallEditor),t._checkValidation()},_checkValidation:function(){var e=this,t=this.constants,i=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"),i.validation="invalid",t.typeError;if(BI.isEmptyString(e.smallEditor.getValue())||BI.isEmptyString(e.bigEditor.getValue()))return e.element.removeClass("number-error"),i.validation="valid","";var n=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?r<n?(e.element.addClass("number-error"),i.validation="invalid",t.numberError):(e.element.removeClass("number-error"),i.validation="valid",""):r<n?(e.element.addClass("number-error"),i.validation="invalid",t.numberError):n===r?(e.element.addClass("number-error"),i.validation="invalid",t.signalError):(e.element.removeClass("number-error"),i.validation="valid","")},_setTitle:function(e){this.label.setTitle(e)},_setFocusEvent:function(e){var t=this,i=this.constants;e.on(BI.NumberIntervalSingleEidtor.EVENT_FOCUS,function(){switch(t._setTitle(""),t._checkValidation()){case i.typeError:BI.Bubbles.show(i.typeError,BI.i18nText("BI-Numerical_Interval_Input_Data"),t,{offsetStyle:"left",adjustYOffset:i.adjustYOffset});break;case i.numberError:BI.Bubbles.show(i.numberError,BI.i18nText("BI-Numerical_Interval_Number_Value"),t,{offsetStyle:"left",adjustYOffset:i.adjustYOffset});break;case i.signalError:BI.Bubbles.show(i.signalError,BI.i18nText("BI-Numerical_Interval_Signal_Value"),t,{offsetStyle:"left",adjustYOffset:i.adjustYOffset});break;default:return}})},_setBlurEvent:function(e){var t=this.constants,i=this;e.on(BI.NumberIntervalSingleEidtor.EVENT_BLUR,function(){switch(BI.Bubbles.hide(t.typeError),BI.Bubbles.hide(t.numberError),BI.Bubbles.hide(t.signalError),i._checkValidation()){case t.typeError:i._setTitle(BI.i18nText("BI-Numerical_Interval_Input_Data"));break;case t.numberError:i._setTitle(BI.i18nText("BI-Numerical_Interval_Number_Value"));break;case t.signalError:i._setTitle(BI.i18nText("BI-Numerical_Interval_Signal_Value"));break;default:i._setTitle("")}})},_setErrorEvent:function(e){var t=this.constants,i=this;e.on(BI.NumberIntervalSingleEidtor.EVENT_ERROR,function(){i._checkValidation(),BI.Bubbles.show(t.typeError,BI.i18nText("BI-Numerical_Interval_Input_Data"),i,{offsetStyle:"left",adjustYOffset:t.adjustYOffset}),i.fireEvent(BI.NumberInterval.EVENT_ERROR)})},_setValidEvent:function(e){var t=this,i=this.constants;e.on(BI.NumberIntervalSingleEidtor.EVENT_VALID,function(){switch(t._checkValidation()){case i.numberError:BI.Bubbles.show(i.numberError,BI.i18nText("BI-Numerical_Interval_Number_Value"),t,{offsetStyle:"left",adjustYOffset:i.adjustYOffset}),t.fireEvent(BI.NumberInterval.EVENT_ERROR);break;case i.signalError:BI.Bubbles.show(i.signalError,BI.i18nText("BI-Numerical_Interval_Signal_Value"),t,{offsetStyle:"left",adjustYOffset:i.adjustYOffset}),t.fireEvent(BI.NumberInterval.EVENT_ERROR);break;default:t.fireEvent(BI.NumberInterval.EVENT_VALID)}})},_setEditorValueChangedEvent:function(e){var t=this,i=this.constants;e.on(BI.NumberIntervalSingleEidtor.EVENT_CHANGE,function(){switch(t._checkValidation()){case i.typeError:BI.Bubbles.show(i.typeError,BI.i18nText("BI-Numerical_Interval_Input_Data"),t,{offsetStyle:"left",adjustYOffset:i.adjustYOffset});break;case i.numberError:BI.Bubbles.show(i.numberError,BI.i18nText("BI-Numerical_Interval_Number_Value"),t,{offsetStyle:"left",adjustYOffset:i.adjustYOffset});break;case i.signalError:BI.Bubbles.show(i.signalError,BI.i18nText("BI-Numerical_Interval_Signal_Value"),t,{offsetStyle:"left",adjustYOffset:i.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,i=this.constants;e.on(BI.IconCombo.EVENT_CHANGE,function(){switch(t._checkValidation()){case i.typeError:t._setTitle(BI.i18nText("BI-Numerical_Interval_Input_Data")),t.fireEvent(BI.NumberInterval.EVENT_ERROR);break;case i.numberError:t._setTitle(BI.i18nText("BI-Numerical_Interval_Number_Value")),t.fireEvent(BI.NumberInterval.EVENT_ERROR);break;case i.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;(BI.isNumeric(e.min)||BI.isEmptyString(e.min))&&this.smallEditor.setValue(e.min),BI.isNotNull(e.min)||this.smallEditor.setValue(""),(BI.isNumeric(e.max)||BI.isEmptyString(e.max))&&this.bigEditor.setValue(e.max),BI.isNotNull(e.max)||this.bigEditor.setValue(""),BI.isNull(e.closeMin)||(t=!0===e.closeMin?1:0,this.smallCombo.setValue(t)),BI.isNull(e.closeMax)||(t=!0===e.closeMax?1:0,this.bigCombo.setValue(t)),this._checkValidation()},getValue:function(){var e={},t=this.smallCombo.getValue(),i=this.bigCombo.getValue();return e.min=this.smallEditor.getValue(),e.max=this.bigEditor.getValue(),0===t[0]?e.closeMin=!1:e.closeMin=!0,0===i[0]?e.closeMax=!1:e.closeMax=!0,e},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 t=this,e=this.options;return{type:"bi.vertical",items:[{type:"bi.editor",ref:function(e){t.editor=e},height:e.height,watermark:e.watermark,allowBlank:e.allowBlank,value:e.value,quitChecker:e.quitChecker,validationChecker:e.validationChecker,listeners:[{eventName:BI.Editor.EVENT_ERROR,action:function(){t.fireEvent(BI.NumberIntervalSingleEidtor.EVENT_ERROR,arguments)}},{eventName:BI.Editor.EVENT_FOCUS,action:function(){t.fireEvent(BI.NumberIntervalSingleEidtor.EVENT_FOCUS,arguments)}},{eventName:BI.Editor.EVENT_BLUR,action:function(){t.fireEvent(BI.NumberIntervalSingleEidtor.EVENT_BLUR,arguments)}},{eventName:BI.Editor.EVENT_VALID,action:function(){t.fireEvent(BI.NumberIntervalSingleEidtor.EVENT_VALID,arguments)}},{eventName:BI.Editor.EVENT_CHANGE,action:function(){t.fireEvent(BI.NumberIntervalSingleEidtor.EVENT_CHANGE,arguments)}},{eventName:BI.Editor.EVENT_CONFIRM,action:function(){t.fireEvent(BI.NumberIntervalSingleEidtor.EVENT_CONFIRM,arguments)}},{eventName:BI.Editor.EVENT_CHANGE_CONFIRM,action:function(){t.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 n=this,e=this.options;BI.SearchMultiTextValueCombo.superclass._init.apply(this,arguments);var i=function(){BI.isKey(n._startValue)&&(n.storeValue.type===BI.Selection.All?BI.remove(n.storeValue.value,n._startValue):BI.pushDistinct(n.storeValue.value,n._startValue)),n._updateAllValue(),n._checkError(),n.trigger.getSearcher().setState(n.storeValue),n.trigger.getCounter().setButtonChecked(n.storeValue)};this.storeValue=BI.deepClone(e.value||{}),this._updateAllValue(),this._assertValue(this.storeValue),this._checkError(),this.requesting=!1,this.trigger=BI.createWidget({type:"bi.search_multi_select_trigger",text:e.text,height:e.height-2,masker:{offset:{left:0,top:0,right:0,bottom:25}},allValueGetter:function(){return n.allValue},valueFormatter:e.valueFormatter,itemsCreator:function(t,i){n._itemsCreator(t,function(e){1===t.times&&BI.isNotNull(t.keywords)&&n.trigger.setValue(BI.deepClone(n.getValue())),i.apply(n,arguments)})},value:this.storeValue,warningTitle:e.warningTitle}),this.trigger.on(BI.MultiSelectTrigger.EVENT_START,function(){n._setStartValue(""),this.getSearcher().setValue(n.storeValue)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_STOP,function(){n._setStartValue("")}),this.trigger.on(BI.MultiSelectTrigger.EVENT_SEARCHING,function(e){var t=BI.last(e);0<(e=BI.initial(e||[])).length&&n._joinKeywords(e,function(){BI.endWith(t,BI.BlankSplitChar)?(n.combo.setValue(n.storeValue),i(),n.combo.populate(),n._setStartValue("")):(n.combo.setValue(n.storeValue),i()),n._dataChange=!0})}),this.trigger.on(BI.MultiSelectTrigger.EVENT_CHANGE,function(e,t){t instanceof BI.MultiSelectBar?n._joinAll(this.getValue(),function(){i()}):n._join(this.getValue(),function(){i()}),n._dataChange=!0}),this.trigger.on(BI.MultiSelectTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW,function(){this.getCounter().setValue(n.storeValue)}),this.trigger.on(BI.MultiSelectTrigger.EVENT_COUNTER_CLICK,function(){n.combo.isViewVisible()||n.combo.showView()}),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-focus-shadow bi-border-radius",toggle:!1,container:e.container,el:this.trigger,adjustLength:1,popup:{type:"bi.search_multi_select_popup_view",ref:function(){n.popup=this,n.trigger.setAdapter(this)},listeners:[{eventName:BI.MultiSelectPopupView.EVENT_CHANGE,action:function(){n._dataChange=!0,n.storeValue=this.getValue(),n._adjust(function(){i()})}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CONFIRM,action:function(){n._defaultState()}},{eventName:BI.MultiSelectPopupView.EVENT_CLICK_CLEAR,action:function(){n._dataChange=!0,n.setValue(),n._defaultState()}}],itemsCreator:BI.bind(n._itemsCreator,this),valueFormatter:e.valueFormatter,onLoaded:function(){BI.nextTick(function(){n.combo.adjustWidth(),n.combo.adjustHeight(),n.trigger.getCounter().adjustView(),n.trigger.getSearcher().adjustView()})}},value:e.value,hideChecker:function(e){return 0===t.element.find(e.target).length}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){this.isViewVisible()||(n._dataChange=!1),this.setValue(n.storeValue),BI.nextTick(function(){n._populate()})}),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,function(){n.trigger.stopEditing(),!0===n.requesting?n.wants2Quit=!0:(i(),n._dataChange&&n.fireEvent(BI.SearchMultiTextValueCombo.EVENT_CONFIRM))});var t=BI.createWidget({type:"bi.trigger_icon_button",width:e.height,height:e.height,cls:"multi-select-trigger-icon-button"});t.on(BI.TriggerIconButton.EVENT_CHANGE,function(){n.trigger.getCounter().hideView(),n.combo.isViewVisible()?n.combo.hideView():n.combo.showView()}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:t,right:0,top:0,bottom:0}]}),this._checkError()},_defaultState:function(){this.trigger.stopEditing(),this.combo.hideView()},_assertValue:function(e){var i=this.options;(e=e||{}).type||(e.type=BI.Selection.Multi),e.value||(e.value=[]),BI.remove(e.value,function(e,t){return!BI.contains(BI.map(i.items,"value"),t)})},_makeMap:function(e){return BI.makeObject(e||[])},_joinKeywords:function(r,a){var o=this;this.options;this._assertValue(this.storeValue),this.requesting=!0,this._itemsCreator({type:BI.SearchMultiTextValueCombo.REQ_GET_ALL_DATA,keywords:r},function(e){var t,i,n=BI.map(e.items,"value");t=n,i=o._makeMap(t),BI.each(r,function(e,t){BI.isNotNull(i[t])&&(o.storeValue.type===BI.Selection.Multi?BI.pushDistinct(o.storeValue.value,t):BI.remove(o.storeValue.value,t))}),o._adjust(a)})},_joinAll:function(t,l){var u=this;this.options;this._assertValue(t),this.requesting=!0,this._itemsCreator({type:BI.SearchMultiTextValueCombo.REQ_GET_ALL_DATA,keywords:[this.trigger.getKey()]},function(e){var i=BI.map(e.items,"value");if(u.storeValue.type===t.type){var n=!1,r=u._makeMap(u.storeValue.value);return BI.each(i,function(e,t){BI.isNotNull(r[t])&&(n=!0,u.storeValue.assist&&u.storeValue.assist.push(r[t]),delete r[t])}),n&&(u.storeValue.value=BI.values(r)),void u._adjust(l)}var a=u._makeMap(u.storeValue.value),o=u._makeMap(t.value),s=[];BI.each(i,function(e,t){BI.isNotNull(a[i[e]])&&(u.storeValue.assist&&u.storeValue.assist.push(a[i[e]]),delete a[i[e]]),BI.isNull(o[i[e]])&&(BI.remove(u.storeValue.assist,t),s.push(t))}),u.storeValue.value=s.concat(BI.values(a)),u._adjust(l)})},_adjust:function(t){var i=this;this.options;function n(){i.storeValue.type===BI.Selection.All&&i.storeValue.value.length>=i._count?i.storeValue={type:BI.Selection.Multi,value:[]}:i.storeValue.type===BI.Selection.Multi&&i.storeValue.value.length>=i._count&&(i.storeValue={type:BI.Selection.All,value:[]}),i._updateAllValue(),i._checkError(),!0===i.wants2Quit&&(i.fireEvent(BI.SearchMultiTextValueCombo.EVENT_CONFIRM),i.wants2Quit=!1),i.requesting=!1}this._count?(n(),t()):this._itemsCreator({type:BI.SearchMultiTextValueCombo.REQ_GET_DATA_LENGTH},function(e){i._count=e.count,n(),t()})},_join:function(e,t){var i=this;this.options;if(this._assertValue(e),this._assertValue(this.storeValue),this.storeValue.type===e.type){var n=this._makeMap(this.storeValue.value);BI.each(e.value,function(e,t){n[t]||(i.storeValue.value.push(t),BI.remove(i.storeValue.assist,t),n[t]=t)});var r=!1;return BI.each(e.assist,function(e,t){BI.isNotNull(n[t])&&(r=!0,i.storeValue.assist&&i.storeValue.assist.push(n[t]),delete n[t])}),r&&(this.storeValue.value=BI.values(n)),void i._adjust(t)}this._joinAll(e,t)},_setStartValue:function(e){this._startValue=e,this.popup.setStartValue(e)},_getItemsByTimes:function(e,t){for(var i=[],n=100*(t-1);e[n]&&n<100*t;n++)i.push(e[n]);return i},_hasNextByTimes:function(e,t){return 100*t<e.length},_itemsCreator:function(e,t){var i,n=this.options.items,r=(e.keywords||[]).slice();e.keyword&&r.push(e.keyword),BI.each(r,function(e,t){var i=BI.Func.getSearchResult(n,t);n=i.match.concat(i.find)}),e.selectedValues&&(i=BI.makeObject(e.selectedValues,!0),n=BI.filter(n,function(e,t){return!i[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,i=this.storeValue.value||[];BI.isNotEmptyArray(i)?(i=BI.isArray(i)?i:[i],e=BI.find(this.allValue,function(e,t){return!BI.contains(i,t)}),BI.isNull(e)?(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"))):i.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 t=this,e=this.options;this.searcher=BI.createWidget(e.searcher,{type:"bi.search_multi_select_searcher",height:e.height,itemsCreator:e.itemsCreator,valueFormatter:e.valueFormatter,allValueGetter:e.allValueGetter,popup:{},adapter:e.adapter,masker:e.masker,value:e.value,text:e.text,tipType:e.tipType,warningTitle:e.warningTitle}),this.searcher.on(BI.MultiSelectSearcher.EVENT_START,function(){t.fireEvent(BI.SearchMultiSelectTrigger.EVENT_START)}),this.searcher.on(BI.MultiSelectSearcher.EVENT_PAUSE,function(){t.fireEvent(BI.SearchMultiSelectTrigger.EVENT_PAUSE)}),this.searcher.on(BI.MultiSelectSearcher.EVENT_SEARCHING,function(){t.fireEvent(BI.SearchMultiSelectTrigger.EVENT_SEARCHING,arguments)}),this.searcher.on(BI.MultiSelectSearcher.EVENT_STOP,function(){t.fireEvent(BI.SearchMultiSelectTrigger.EVENT_STOP)}),this.searcher.on(BI.MultiSelectSearcher.EVENT_CHANGE,function(){t.fireEvent(BI.SearchMultiSelectTrigger.EVENT_CHANGE,arguments)}),this.numberCounter=BI.createWidget(e.switcher,{type:"bi.multi_select_check_selected_switcher",valueFormatter:e.valueFormatter,itemsCreator:e.itemsCreator,adapter:e.adapter,masker:e.masker,value:e.value}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_TRIGGER_CHANGE,function(){t.fireEvent(BI.SearchMultiSelectTrigger.EVENT_COUNTER_CLICK)}),this.numberCounter.on(BI.MultiSelectCheckSelectedSwitcher.EVENT_BEFORE_POPUPVIEW,function(){t.fireEvent(BI.SearchMultiSelectTrigger.EVENT_BEFORE_COUNTER_POPUPVIEW)});var i=BI.createWidget({type:"bi.right_vertical_adapt",hgap:4,items:[{el:this.numberCounter}]}),n=BI.createWidget({type:"bi.htape",element:this,items:[{el:this.searcher,width:"fill"},{el:i,width:0},{el:BI.createWidget(),width:24}]});this.numberCounter.on(BI.Events.VIEW,function(e){BI.nextTick(function(){n.attr("items")[1].width=!0===e?t.numberCounter.element.outerWidth()+8:0,n.resize()})}),this.element.click(function(e){0<t.element.find(e.target).length&&t.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 s=this,l=this.options,u=!1;this.storeValue=l.value||{},this._assertValue(this.storeValue),this.button_group=BI.createWidget({type:"bi.select_list",element:this,logic:l.logic,el:BI.extend({onLoaded:l.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"}]}}},l.el),itemsCreator:function(r,a){var o=s._startValue;s.storeValue&&(r=BI.extend(r||{},{selectedValues:BI.isKey(o)&&s.storeValue.type===BI.Selection.Multi?s.storeValue.value.concat(o):s.storeValue.value})),l.itemsCreator(r,function(e){u=e.hasNext;var t,i,n=[];1===r.times&&s.storeValue&&(t=BI.map(s.storeValue.value,function(e,t){var i=l.valueFormatter(t)||t;return{text:i,value:t,title:i,selected:s.storeValue.type===BI.Selection.Multi}}),BI.isKey(s._startValue)&&!BI.contains(s.storeValue.value,s._startValue)&&(i=l.valueFormatter(o)||o,t.unshift({text:i,value:o,title:i,selected:!0})),n=s._createItems(t)),a(n.concat(s._createItems(e.items)),e.keyword||""),1===r.times&&s.storeValue&&(BI.isKey(o)&&(s.storeValue.type===BI.Selection.All?BI.remove(s.storeValue.value,o):BI.pushDistinct(s.storeValue.value,o)),s.setValue(s.storeValue)),1===r.times&&s._scrollToTop()})},hasNext:function(){return u},value:this.storeValue}),this.button_group.on(BI.Controller.EVENT_CHANGE,function(){s.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.button_group.on(BI.SelectList.EVENT_CHANGE,function(){s.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||{}).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){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 t=this,e=this.options;this.loader=BI.createWidget({type:"bi.search_multi_select_loader",itemsCreator:e.itemsCreator,valueFormatter:e.valueFormatter,onLoaded:e.onLoaded,value:e.value}),this.popupView=BI.createWidget({type:"bi.multi_popup_view",stopPropagation:!1,maxWidth:e.maxWidth,minWidth:e.minWidth,maxHeight:e.maxHeight,element:this,buttons:[BI.i18nText("BI-Basic_Clears"),BI.i18nText("BI-Basic_Sure")],el:this.loader,value:e.value}),this.popupView.on(BI.MultiPopupView.EVENT_CHANGE,function(){t.fireEvent(BI.SearchMultiSelectPopupView.EVENT_CHANGE)}),this.popupView.on(BI.MultiPopupView.EVENT_CLICK_TOOLBAR_BUTTON,function(e){switch(e){case 0:t.fireEvent(BI.SearchMultiSelectPopupView.EVENT_CLICK_CLEAR);break;case 1:t.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 n=this,r=this.options;this.editor=BI.createWidget(r.el,{type:"bi.multi_select_editor",height:r.height,text:r.text,tipType:r.tipType,warningTitle:r.warningTitle}),this.searcher=BI.createWidget({type:"bi.searcher",element:this,height:r.height,isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t()},el:this.editor,popup:BI.extend({type:"bi.multi_select_search_pane",valueFormatter:r.valueFormatter,keywordGetter:function(){return n.editor.getValue()},itemsCreator:function(e,t){var i=n.editor.getValue();e.keywords=[i],r.itemsCreator(e,t)},value:r.value},r.popup),adapter:r.adapter,masker:r.masker}),this.searcher.on(BI.Searcher.EVENT_START,function(){n.fireEvent(BI.SearchMultiSelectSearcher.EVENT_START)}),this.searcher.on(BI.Searcher.EVENT_PAUSE,function(){this.hasMatched(),n.fireEvent(BI.SearchMultiSelectSearcher.EVENT_PAUSE)}),this.searcher.on(BI.Searcher.EVENT_STOP,function(){n.fireEvent(BI.SearchMultiSelectSearcher.EVENT_STOP)}),this.searcher.on(BI.Searcher.EVENT_CHANGE,function(){n.fireEvent(BI.SearchMultiSelectSearcher.EVENT_CHANGE,arguments)}),this.searcher.on(BI.Searcher.EVENT_SEARCHING,function(){var e=this.getKeywords();n.fireEvent(BI.SearchMultiSelectSearcher.EVENT_SEARCHING,e)}),BI.isNotNull(r.value)&&this.setState(r.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 i,n=this.options,t={};t.type=e.type,t.value=n.allValueGetter()||[],t.assist=e.assist,t.type===BI.Selection.All?0===t.value.length?this.editor.setState(BI.Selection.All):BI.size(t.assist)<=20?(i="",BI.each(t.assist,function(e,t){i+=0===e?""+(n.valueFormatter(t+"")||t):","+(n.valueFormatter(t+"")||t)}),this.editor.setState(i)):this.editor.setState(BI.Selection.Multi):0===t.value.length?this.editor.setState(BI.Selection.None):BI.size(t.value)<=20?(i="",BI.each(t.value,function(e,t){i+=0===e?""+(n.valueFormatter(t+"")||t):","+(n.valueFormatter(t+"")||t)}),this.editor.setState(i)):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 t=this,e=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:e.height,height:e.height,hgap:e.hgap,text:e.text,value:e.value,keyword:e.keyword,py:e.py}),this.checkbox.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&(this.isSelected()?t.triggerExpand():t.triggerCollapse())});var i=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),n=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(i,BI.extend(e.logic,{items:n}))))},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 t=this,e=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:e.height,height:e.height,hgap:e.hgap,text:e.text,value:e.value,keyword:e.keyword,py:e.py}),this.checkbox.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&(this.isSelected()?t.triggerExpand():t.triggerCollapse())});var i=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),n=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(i,BI.extend(e.logic,{items:n}))))},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 t=this,e=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:e.height,height:e.height,hgap:e.hgap,text:e.text,value:e.value,keyword:e.keyword,py:e.py}),this.checkbox.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&(this.isSelected()?t.triggerExpand():t.triggerCollapse())});var i=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),n=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(i,BI.extend(e.logic,{items:n}))))},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 t=this,e=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:e.height,height:e.height,hgap:e.hgap,text:e.text,value:e.value,keyword:e.keyword,py:e.py}),this.checkbox.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&(this.isSelected()?t.triggerExpand():t.triggerCollapse())});var i=BI.LogicFactory.createLogicTypeByDirection(BI.Direction.Left),n=BI.LogicFactory.createLogicItemsByDirection(BI.Direction.Left,{width:24,el:this.checkbox},this.text);BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(i,BI.extend(e.logic,{items:n}))))},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 t=this,e=this.options;this.trigger=BI.createWidget(e.el),this.trigger.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&this.isSelected()&&t.expander.setValue([]),t.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.expander=BI.createWidget({type:"bi.expander",element:this,trigger:e.trigger,toggle:e.toggle,direction:e.direction,isDefaultInit:e.isDefaultInit,el:this.trigger,popup:e.popup}),this.expander.on(BI.Controller.EVENT_CHANGE,function(e){e===BI.Events.CLICK&&t.trigger.setSelected(!1),t.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(n,r,a){var o=this;return BI.each(n,function(e,t){var i={layer:r};t.id=t.id||BI.UUID(),i.pNode=a,!0===t.isParent||!0===t.parent||BI.isNotEmptyArray(t.children)?(i.type="bi.select_tree_mid_plus_group_node",e===n.length-1&&(i.type="bi.select_tree_last_plus_group_node",i.isLastNode=!0),0!==e||a||(i.type="bi.select_tree_first_plus_group_node"),0===e&&e===n.length-1&&(i.type="bi.select_tree_plus_group_node"),BI.defaults(t,i),o._formatItems(t.children,r+1,t)):(i.type="bi.mid_tree_leaf_item",0!==e||a||(i.type="bi.first_tree_leaf_item"),e===n.length-1&&(i.type="bi.last_tree_leaf_item"),BI.defaults(t,i))}),n},_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 o=this,s=this.options,l=!1;this.button_group=BI.createWidget({type:"bi.single_select_list",allowNoSelect:s.allowNoSelect,element:this,logic:{dynamic:!1},value:s.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(r,a){o.storeValue&&(r=BI.extend(r||{},{selectedValues:[o.storeValue]})),s.itemsCreator(r,function(e){var t=e.keyword=s.keywordGetter();l=e.hasNext;var i,n=[];1===r.times&&BI.isNotNull(o.storeValue)&&(i=o._filterValues(o.storeValue),n=o._createItems(i)),a(n.concat(o._createItems(e.items)),t||""),1===r.times&&o.storeValue&&o.setValue(o.storeValue)})},hasNext:function(){return l}}),this.button_group.on(BI.Controller.EVENT_CHANGE,function(){o.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.button_group.on(BI.SingleSelectList.EVENT_CHANGE,function(){o.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,i=this.options,n=i.keywordGetter(),r=e||[],a=BI.map(BI.isArray(r)?r:[r],function(e,t){return{text:i.valueFormatter(t)||t,value:t}});return BI.isKey(n)&&(r=(t=BI.Func.getSearchResult(a,n)).match.concat(t.find)),BI.map(r,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 i=this,n=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.addNotMatchTip=BI.createWidget({type:"bi.label",invisible:!0,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:n.allowNoSelect,keywordGetter:n.keywordGetter,valueFormatter:n.valueFormatter,itemsCreator:function(e,t){n.itemsCreator.apply(i,[e,function(e){t(e),i.setKeyword(n.keywordGetter())}])},value:n.value}),this.loader.on(BI.Controller.EVENT_CHANGE,function(){i.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.resizer=BI.createWidget({type:"bi.vtape",element:this,items:[{type:"bi.vertical",items:[this.tooltipClick,this.addNotMatchTip],height:this.constants.height},{el:this.loader}]})},setKeyword:function(i){var n=this.options,e=BI.some(this.loader.getAllButtons(),function(e,t){return i===(n.valueFormatter(t.getValue())||t.getValue())}),t=0<this.loader.getAllButtons().length&&e;this.tooltipClick.setVisible(t),this.addNotMatchTip.setVisible(!t),t||this.addNotMatchTip.setText(BI.i18nText("BI-Basic_Click_To_Add_Text",i))},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.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 i=this,n=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:n.allowNoSelect,keywordGetter:n.keywordGetter,valueFormatter:n.valueFormatter,itemsCreator:function(e,t){n.itemsCreator.apply(i,[e,function(e){t(e),i.setKeyword(n.keywordGetter())}])},value:n.value}),this.loader.on(BI.Controller.EVENT_CHANGE,function(){i.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,i=this.options,n=0<this.loader.getAllButtons().length&&(t=this.loader.getAllButtons()[0])&&e===(i.valueFormatter(t.getValue())||t.getValue());n!==this.tooltipClick.isVisible()&&(this.tooltipClick.setVisible(n),this.resizer.attr("items")[0].height=n?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 n=this,e=this.options;BI.SingleSelectCombo.superclass._init.apply(this,arguments);var i=function(){BI.isKey(n._startValue)&&(n.storeValue=n._startValue),n.trigger.getSearcher().setState(n.storeValue)};this.storeValue=e.value,this.requesting=!1,this.trigger=BI.createWidget({type:"bi.single_select_trigger",height:e.height-2,allowNoSelect:e.allowNoSelect,allowEdit:e.allowEdit,valueFormatter:e.valueFormatter,itemsCreator:function(t,i){e.itemsCreator(t,function(e){1===t.times&&BI.isNotNull(t.keywords)&&n.trigger.setValue(n.getValue()),i.apply(n,arguments)})},text:e.text,value:this.storeValue}),this.trigger.on(BI.SingleSelectTrigger.EVENT_FOCUS,function(){n.fireEvent(BI.SingleSelectCombo.EVENT_FOCUS)}),this.trigger.on(BI.SingleSelectTrigger.EVENT_BLUR,function(){n.fireEvent(BI.SingleSelectCombo.EVENT_BLUR)}),this.trigger.on(BI.SingleSelectTrigger.EVENT_START,function(){n._setStartValue(),this.getSearcher().setValue(n.storeValue)}),this.trigger.on(BI.SingleSelectTrigger.EVENT_STOP,function(){n._setStartValue(),n.fireEvent(BI.SingleSelectCombo.EVENT_STOP)}),this.trigger.on(BI.SingleSelectTrigger.EVENT_SEARCHING,function(){n.fireEvent(BI.SingleSelectCombo.EVENT_SEARCHING)}),this.trigger.on(BI.SingleSelectTrigger.EVENT_CHANGE,function(e,t){n.storeValue=this.getValue(),i(),n._defaultState()}),this.trigger.on(BI.SingleSelectTrigger.EVENT_COUNTER_CLICK,function(){n.combo.isViewVisible()||n.combo.showView()}),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-border-radius",container:e.container,toggle:!1,el:this.trigger,adjustLength:1,popup:{type:"bi.single_select_popup_view",allowNoSelect:e.allowNoSelect,ref:function(){n.popup=this,n.trigger.setAdapter(this)},listeners:[{eventName:BI.SingleSelectPopupView.EVENT_CHANGE,action:function(){n.storeValue=this.getValue(),n._adjust(function(){i(),n._defaultState()}),n.fireEvent(BI.SingleSelectCombo.EVENT_CLICK_ITEM)}}],itemsCreator:e.itemsCreator,valueFormatter:e.valueFormatter,onLoaded:function(){BI.nextTick(function(){n.combo.adjustWidth(),n.combo.adjustHeight(),n.trigger.getSearcher().adjustView()})}},hideChecker:function(e){return 0===t.element.find(e.target).length},value:e.value}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){this.setValue(n.storeValue),BI.nextTick(function(){n.populate()})}),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,function(){n.trigger.stopEditing(),!0===n.requesting?n.wants2Quit=!0:n.fireEvent(BI.SingleSelectCombo.EVENT_CONFIRM)});var t=BI.createWidget({type:"bi.trigger_icon_button",width:e.height,height:e.height,cls:"single-select-trigger-icon-button"});t.on(BI.TriggerIconButton.EVENT_CHANGE,function(){n.combo.isViewVisible()?n.combo.hideView():n.combo.showView()}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:t,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(r,a){var o=this,e=this.options;this._assertValue(this.storeValue),this.requesting=!0,e.itemsCreator({type:BI.SingleSelectCombo.REQ_GET_ALL_DATA,keywords:r},function(e){var t,i,n=BI.map(e.items,"value");t=n,i=o._makeMap(t),BI.each(r,function(e,t){BI.isNotNull(i[t])&&BI.remove(o.storeValue.value,t)}),o._adjust(a)})},_adjust:function(t){var i=this,e=this.options;function n(){!0===i.wants2Quit&&(i.fireEvent(BI.SingleSelectCombo.EVENT_CONFIRM),i.wants2Quit=!1),i.requesting=!1}this._count?(n(),t()):e.itemsCreator({type:BI.SingleSelectCombo.REQ_GET_DATA_LENGTH},function(e){i._count=e.count,n(),t()})},_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 n=this,e=this.options;BI.SingleSelectInsertCombo.superclass._init.apply(this,arguments);var i=function(){BI.isKey(n._startValue)&&(n.storeValue=n._startValue),n.trigger.getSearcher().setState(n.storeValue)};this.storeValue=e.value,this.requesting=!1,this.trigger=BI.createWidget({type:"bi.single_select_trigger",watermark:e.watermark,height:e.height-2,allowNoSelect:e.allowNoSelect,allowEdit:e.allowEdit,valueFormatter:e.valueFormatter,itemsCreator:function(t,i){e.itemsCreator(t,function(e){1===t.times&&BI.isNotNull(t.keywords)&&n.trigger.setValue(n.getValue()),i.apply(n,arguments)})},text:e.text,value:this.storeValue,searcher:{popup:{type:"bi.single_select_search_insert_pane"}}}),this.trigger.on(BI.SingleSelectTrigger.EVENT_FOCUS,function(){n.fireEvent(BI.SingleSelectInsertCombo.EVENT_FOCUS)}),this.trigger.on(BI.SingleSelectTrigger.EVENT_BLUR,function(){n.fireEvent(BI.SingleSelectInsertCombo.EVENT_BLUR)}),this.trigger.on(BI.SingleSelectTrigger.EVENT_START,function(){n._setStartValue(),this.getSearcher().setValue(n.storeValue)}),this.trigger.on(BI.SingleSelectTrigger.EVENT_STOP,function(){n._setStartValue(),n.fireEvent(BI.SingleSelectInsertCombo.EVENT_STOP)}),this.trigger.on(BI.SingleSelectTrigger.EVENT_PAUSE,function(){n.storeValue=n.trigger.getSearcher().getKeyword(),i(),n._defaultState()}),this.trigger.on(BI.SingleSelectTrigger.EVENT_SEARCHING,function(){n.fireEvent(BI.SingleSelectInsertCombo.EVENT_SEARCHING)}),this.trigger.on(BI.SingleSelectTrigger.EVENT_CHANGE,function(e,t){n.storeValue=this.getValue(),i(),n._defaultState()}),this.trigger.on(BI.SingleSelectTrigger.EVENT_COUNTER_CLICK,function(){n.combo.isViewVisible()||n.combo.showView()}),this.combo=BI.createWidget({type:"bi.combo",cls:"bi-border bi-border-radius",container:e.container,toggle:!1,el:this.trigger,adjustLength:1,popup:{type:"bi.single_select_popup_view",allowNoSelect:e.allowNoSelect,ref:function(){n.popup=this,n.trigger.setAdapter(this)},listeners:[{eventName:BI.SingleSelectPopupView.EVENT_CHANGE,action:function(){n.storeValue=this.getValue(),n._adjust(function(){i(),n._defaultState()}),n.fireEvent(BI.SingleSelectInsertCombo.EVENT_CLICK_ITEM)}}],itemsCreator:e.itemsCreator,valueFormatter:e.valueFormatter,onLoaded:function(){BI.nextTick(function(){n.combo.adjustWidth(),n.combo.adjustHeight(),n.trigger.getSearcher().adjustView()})}},hideChecker:function(e){return 0===t.element.find(e.target).length},value:e.value}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){this.setValue(n.storeValue),BI.nextTick(function(){n.populate()})}),this.wants2Quit=!1,this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW,function(){n.trigger.stopEditing(),!0===n.requesting?n.wants2Quit=!0:n.fireEvent(BI.SingleSelectInsertCombo.EVENT_CONFIRM)});var t=BI.createWidget({type:"bi.trigger_icon_button",width:e.height,height:e.height,cls:"single-select-trigger-icon-button"});t.on(BI.TriggerIconButton.EVENT_CHANGE,function(){n.combo.isViewVisible()?n.combo.hideView():n.combo.showView()}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:this.combo,left:0,right:0,top:0,bottom:0},{el:t,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 n=this,e=this.options;this.list=BI.createWidget(e.el,{type:"bi.list_pane",items:e.items,itemsCreator:function(t,i){1===t.times&&n.toolbar&&n.toolbar.setVisible(!1),e.itemsCreator(t,function(e){i.apply(n,arguments),1===t.times&&(n.toolbar&&n.toolbar.setVisible(e&&0<e.length),n.toolbar&&n.toolbar.setEnable(e&&0<e.length))})},onLoaded:e.onLoaded,hasNext:e.hasNext,value:e.value}),this.list.on(BI.Controller.EVENT_CHANGE,function(e,t,i){e===BI.Events.CLICK&&n.fireEvent(BI.SingleSelectList.EVENT_CHANGE,t,i),n.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),BI.createWidget(BI.extend({element:this},BI.LogicFactory.createLogic(BI.LogicFactory.createLogicTypeByDirection(e.direction),BI.extend({scrolly:!0},e.logic,{items:e.allowNoSelect?BI.LogicFactory.createLogicItemsByDirection(e.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(e){n.toolbar=e},listeners:[{eventName:BI.Controller.EVENT_CHANGE,action:function(e){e===BI.Events.CLICK&&(n.list.setValue(),n.fireEvent(BI.SingleSelectList.EVENT_CHANGE)),n.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}}]},this.list):BI.LogicFactory.createLogicItemsByDirection(e.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 o=this,s=this.options,l=!1;this.storeValue=s.value,this.button_group=BI.createWidget({type:"bi.single_select_list",allowNoSelect:s.allowNoSelect,logic:s.logic,el:BI.extend({onLoaded:s.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"}]}}},s.el),itemsCreator:function(n,r){var a=o._startValue;BI.isNotNull(o.storeValue)&&(n=BI.extend(n||{},{selectedValues:[o.storeValue]})),s.itemsCreator(n,function(e){l=e.hasNext;var t,i=[];1===n.times&&BI.isNotNull(o.storeValue)&&(t=BI.map([o.storeValue],function(e,t){var i=s.valueFormatter(t)||t;return{text:i,value:t,title:i,selected:!0}}),i=o._createItems(t)),r(i.concat(o._createItems(e.items)),e.keyword||""),1===n.times&&o.storeValue&&(BI.isKey(a)&&(o.storeValue=a),o.setValue(o.storeValue)),1===n.times&&o._scrollToTop()})},hasNext:function(){return l},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(){o.fireEvent(BI.Controller.EVENT_CHANGE,arguments)}),this.button_group.on(BI.SingleSelectList.EVENT_CHANGE,function(){o.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 i=this,n=this.options;this.storeValue=n.value;var t=function(){BI.isKey(i._startValue)&&(i.storeValue=i._startValue)};this.adapter=BI.createWidget({type:"bi.single_select_loader",allowNoSelect:n.allowNoSelect,cls:"popup-single-select-list bi-border-left bi-border-right bi-border-bottom",itemsCreator:n.itemsCreator,valueFormatter:n.valueFormatter,logic:{dynamic:!0},el:{},value:n.value}),this.adapter.on(BI.SingleSelectLoader.EVENT_CHANGE,function(){i.storeValue=this.getValue(),t(),i.fireEvent(BI.SingleSelectInsertList.EVENT_CHANGE)}),this.searcherPane=BI.createWidget({type:"bi.single_select_search_insert_pane",allowNoSelect:n.allowNoSelect,cls:"bi-border-left bi-border-right bi-border-bottom",valueFormatter:n.valueFormatter,keywordGetter:function(){return i.trigger.getKeyword()},itemsCreator:function(e,t){e.keywords=[i.trigger.getKeyword()],this.setKeyword(e.keywords[0]),n.itemsCreator(e,t)}}),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(e){i.editor=e},height:n.searcherHeight},isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t()},adapter:this.adapter,popup:this.searcherPane,height:200,masker:!1,value:n.value,listeners:[{eventName:BI.Searcher.EVENT_START,action:function(){i._showSearcherPane(),i._setStartValue(),this.setValue(BI.deepClone(i.storeValue))}},{eventName:BI.Searcher.EVENT_STOP,action:function(){i._showAdapter(),i._setStartValue(),i.adapter.setValue(i.storeValue),i.adapter.populate()}},{eventName:BI.Searcher.EVENT_PAUSE,action:function(){var e=this.getKeyword();i.storeValue=e,i._showAdapter(),i.adapter.setValue(i.storeValue),i._setStartValue(e),t(),i.adapter.populate(),i._setStartValue(),i.fireEvent(BI.SingleSelectInsertList.EVENT_CHANGE)}},{eventName:BI.Searcher.EVENT_CHANGE,action:function(){i.storeValue=this.getValue(),i.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 n=this,r=this.options;this.editor=BI.createWidget(r.el,{type:"bi.single_select_editor",height:r.height,watermark:r.watermark,text:r.text,listeners:[{eventName:BI.SingleSelectEditor.EVENT_FOCUS,action:function(){n.fireEvent(BI.SingleSelectSearcher.EVENT_FOCUS)}},{eventName:BI.SingleSelectEditor.EVENT_BLUR,action:function(){n.fireEvent(BI.SingleSelectSearcher.EVENT_BLUR)}}]}),this.searcher=BI.createWidget({type:"bi.searcher",element:this,height:r.height,isAutoSearch:!1,isAutoSync:!1,onSearch:function(e,t){t()},el:this.editor,popup:BI.extend({type:"bi.single_select_search_pane",allowNoSelect:r.allowNoSelect,valueFormatter:r.valueFormatter,keywordGetter:function(){return n.editor.getValue()},itemsCreator:function(e,t){var i=n.editor.getValue();e.keywords=[i],this.setKeyword(i),r.itemsCreator(e,t)},value:r.value},r.popup),adapter:r.adapter,masker:r.masker}),this.searcher.on(BI.Searcher.EVENT_START,function(){n.fireEvent(BI.SingleSelectSearcher.EVENT_START)}),this.searcher.on(BI.Searcher.EVENT_PAUSE,function(){this.hasMatched(),n.fireEvent(BI.SingleSelectSearcher.EVENT_PAUSE)}),this.searcher.on(BI.Searcher.EVENT_STOP,function(){n.fireEvent(BI.SingleSelectSearcher.EVENT_STOP)}),this.searcher.on(BI.Searcher.EVENT_CHANGE,function(){n.fireEvent(BI.SingleSelectSearcher.EVENT_CHANGE,arguments)}),this.searcher.on(BI.Searcher.EVENT_SEARCHING,function(){var e=this.getKeywords();n.fireEvent(BI.SingleSelectSearcher.EVENT_SEARCHING,e)}),BI.isNotNull(r.value)&&this.setState(r.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;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 t=this.options;BI.nextTick(BI.bind(function(){var e;""===this.editor.getValue()?(this.text.setValue(t.watermark||""),this.text.element.addClass("bi-water-mark")):(e=this.editor.getValue(),e=BI.isEmpty(e)||e==t.text?t.text:e+t.text,this.text.setValue(e),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 o=this,s=this.options,l=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 u=BI.createWidget({type:"bi.vertical",items:[{type:"bi.absolute",items:[this.slider]}],hgap:l.SLIDER_WIDTH_HALF,height:l.SLIDER_HEIGHT});return u.element.click(function(e){var t,i,n,r,a;o.enable&&o.isEnabled()&&u.element[0]===e.originalEvent.target&&(t=e.clientX-o.element.offset().left-l.SLIDER_WIDTH_HALF,i=o.track.element[0].scrollWidth-l.TRACK_GAP,(n=0)<t&&t<i&&(n=100*t/o._getGrayTrackLength()),i<=t&&(n=100),r=BI.parseFloat(n.toFixed(1)),o._setAllPosition(r),a=o._getValueByPercent(r),a=!1===s.digit?a:a.toFixed(s.digit),o.label.setValue(a),o.value=a,o.fireEvent(BI.SingleSlider.EVENT_CHANGE))}),this.label=BI.createWidget({type:"bi.sign_text_editor",cls:"slider-editor-button",text:s.unit,width:l.EDITOR_WIDTH-2,allowBlank:!1,textAlign:"center",validationChecker:function(e){return o._checkValidation(e)}}),this.label.element.hover(function(){o.label.element.removeClass("bi-border").addClass("bi-border")},function(){o.label.element.removeClass("bi-border")}),this.label.on(BI.SignEditor.EVENT_CONFIRM,function(){var e=BI.parseFloat(this.getValue()),t=o._getPercentByValue(e),i=BI.parseFloat(t.toFixed(1));o._setAllPosition(i),this.setValue(e),o.value=e,o.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:l.TRACK_HEIGHT}]}],hgap:l.TRACK_GAP_HALF,height:l.TRACK_HEIGHT},top:23,left:0,width:"100%"},{el:u,top:20,left:0,width:"100%"},{el:{type:"bi.vertical",items:[{type:"bi.horizontal_auto",items:[this.label]}],height:l.EDITOR_HEIGHT},top:0,left:0,width:"100%"}]}},_draggable:function(r){var a=this,o=this.options,s=!1,l=0,u=0,c=0,h=new BI.MouseMoveTracker(function(e){var t,i,n;h.isDragging()&&(s=!0,l=p(c+(u+=e)),r.element.addClass("dragging"),t=100*l/a._getGrayTrackLength(),i=BI.parseFloat(t.toFixed(1)),a._setBlueTrack(i),a._setLabelPosition(i),a._setSliderPosition(i),n=a._getValueByPercent(i),n=!1===o.digit?n:n.toFixed(o.digit),a.label.setValue(n),a.value=n)},function(){var e,t;!0===s&&(e=100*(l=p(l))/a._getGrayTrackLength(),t=BI.parseFloat(e.toFixed(1)),a._setSliderPosition(t),u=l=0,c=l,s=!1),r.element.removeClass("dragging"),h.releaseMouseMoves(),a.fireEvent(BI.SingleSlider.EVENT_CHANGE)},window);function p(e){return BI.clamp(e,0,a._getGrayTrackLength())}r.element.on("mousedown",function(e){r.isEnabled()&&(p(c=this.offsetLeft),h.captureMouseMoves(e))})},_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,i=!1;return BI.isNumeric(e)&&!(BI.isNull(e)||e<this.min||e>this.max)&&(i=!1===t.digit||((e+"").split(".")[1]||"").length===t.digit),i},_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),i=BI.parseFloat(e.max);!isNaN(t)&&!isNaN(i)&&t<i&&(this.min=t,this.max=i)},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 o=this,s=this.options,l=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 u=BI.createWidget({type:"bi.vertical",items:[{type:"bi.absolute",items:[this.slider]}],hgap:l.SLIDER_WIDTH_HALF,height:l.SLIDER_HEIGHT});u.element.click(function(e){var t,i,n,r,a;o.enable&&o.isEnabled()&&u.element[0]===e.originalEvent.target&&(t=e.clientX-o.element.offset().left-l.SLIDER_WIDTH_HALF,i=o.track.element[0].scrollWidth-l.TRACK_GAP,(n=0)<t&&t<i&&(n=100*t/o._getGrayTrackLength()),i<=t&&(n=100),r=BI.parseFloat(n.toFixed(1)),o._setAllPosition(r),a=o._getValueByPercent(r),a=!1===s.digit?a:a.toFixed(s.digit),o.label.setText(a+s.unit),o.value=a,o.fireEvent(BI.SingleSliderLabel.EVENT_CHANGE))}),this.label=BI.createWidget({type:"bi.label",height:l.HEIGHT,width:l.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:l.TRACK_HEIGHT}]}],hgap:l.TRACK_GAP_HALF,height:l.TRACK_HEIGHT},top:13,left:0,width:"100%"},{el:u,top:10,left:0,width:"100%"},{el:{type:"bi.vertical",items:[{type:"bi.horizontal_auto",items:[this.label]}],height:l.EDITOR_HEIGHT},top:0,left:0,width:"100%"}]})},_draggable:function(r){var a=this,o=this.options,s=!1,l=0,u=0,c=0,h=new BI.MouseMoveTracker(function(e){var t,i,n;h.isDragging()&&(s=!0,l=p(c+(u+=e)),r.element.addClass("dragging"),t=100*l/a._getGrayTrackLength(),i=BI.parseFloat(t.toFixed(1)),a._setBlueTrack(i),a._setLabelPosition(i),a._setSliderPosition(i),n=a._getValueByPercent(i),n=!1===o.digit?n:n.toFixed(o.digit),a.label.setValue(n+o.unit),a.value=n,a.fireEvent(BI.SingleSliderLabel.EVENT_CHANGE))},function(){var e,t;!0===s&&(e=100*(l=p(l))/a._getGrayTrackLength(),t=BI.parseFloat(e.toFixed(1)),a._setSliderPosition(t),u=l=0,c=l,s=!1),r.element.removeClass("dragging"),h.releaseMouseMoves(),a.fireEvent(BI.SingleSliderLabel.EVENT_CHANGE)},window);function p(e){return BI.clamp(e,0,a._getGrayTrackLength())}r.element.on("mousedown",function(e){r.isEnabled()&&(p(c=this.offsetLeft),h.captureMouseMoves(e))})},_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),i=BI.parseFloat(e.max);!isNaN(t)&&!isNaN(i)&&t<i&&(this.min=t,this.max=i)},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 o=this,s=this._constant,e=this._createTrack();this.slider=BI.createWidget({type:"bi.single_slider_button"}),this._draggable(this.slider);var l=BI.createWidget({type:"bi.vertical",items:[{type:"bi.absolute",items:[this.slider]}],hgap:s.SLIDER_WIDTH_HALF,height:s.SLIDER_HEIGHT});return l.element.click(function(e){var t,i,n,r,a;o.enable&&o.isEnabled()&&l.element[0]===e.originalEvent.target&&(t=e.clientX-o.element.offset().left-s.SLIDER_WIDTH_HALF,i=o.track.element[0].scrollWidth-s.TRACK_GAP,(n=0)<t&&t<i&&(n=100*t/o._getGrayTrackLength()),i<=t&&(n=100),r=BI.parseFloat(n.toFixed(1)),o._setAllPosition(r),a=o._getValueByPercent(r),o.value=a,o.fireEvent(BI.SingleSlider.EVENT_CHANGE))}),{type:"bi.absolute",element:this,items:[{el:{type:"bi.vertical",items:[{type:"bi.absolute",items:[{el:e,width:"100%",height:s.TRACK_HEIGHT}]}],hgap:s.TRACK_GAP_HALF,height:s.TRACK_HEIGHT},top:3,left:0,width:"100%"},{el:l,top:0,left:0,width:"100%"}]}},_draggable:function(r){var a=this,o=this.options,s=!1,l=0,u=0,c=0,h=new BI.MouseMoveTracker(function(e){var t,i,n;h.isDragging()&&(s=!0,l=p(c+(u+=e)),r.element.addClass("dragging"),t=100*l/a._getGrayTrackLength(),i=BI.parseFloat(t.toFixed(1)),a._setBlueTrack(i),a._setSliderPosition(i),n=a._getValueByPercent(i),n=!1===o.digit?n:n.toFixed(o.digit),a.value=n,a.fireEvent(BI.SingleSliderNormal.EVENT_DRAG,n))},function(){var e,t;!0===s&&(e=100*(l=p(l))/a._getGrayTrackLength(),t=BI.parseFloat(e.toFixed(1)),a._setSliderPosition(t),u=l=0,c=l,s=!1),r.element.removeClass("dragging"),h.releaseMouseMoves(),a.fireEvent(BI.SingleSlider.EVENT_CHANGE)},window);function p(e){return BI.clamp(e,0,a._getGrayTrackLength())}r.element.on("mousedown",function(e){r.isEnabled()&&(p(c=this.offsetLeft),h.captureMouseMoves(e))})},_createTrack:function(){var t=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(e){t.track=e}}},_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),i=BI.parseFloat(e.max);!isNaN(t)&&!isNaN(i)&&t<i&&(this.min=t,this.max=i)},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 i=this,n=this.getValue();BI.any(this.options.items,function(e,t){if(BI.contains(n,t.value))return i.trigger.setTitle(t.text||t.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||[]},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,i=this.options;i.height-=2,BI.isNumeric(i.width)&&(i.width-=2),BI.TextValueDownListCombo.superclass._init.apply(this,arguments),this._createValueMap(),BI.isNotNull(i.value)&&(e=this._digest(i.value)),this.trigger=BI.createWidget({type:"bi.down_list_select_text_trigger",cls:"text-value-down-list-trigger",height:i.height,items:i.items,text:i.text,value:e}),this.combo=BI.createWidget({type:"bi.down_list_combo",element:this,chooseType:BI.Selection.Single,adjustLength:2,height:i.height,el:this.trigger,value:BI.isNull(e)?[]:[e],items:BI.deepClone(i.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 n=this;this.valueMap={},BI.each(BI.flatten(this.options.items),function(e,i){BI.has(i,"el")?BI.each(i.children,function(e,t){n.valueMap[t.value]={value:i.el.value,childValue:t.value}}):n.valueMap[i.value]={value:i.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,i){BI.has(i,"el")?(BI.each(i.children,function(e,t){t.text=i.el.text+"("+t.text+")"}),t=BI.concat(t,i.children)):t.push(i)}),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 t=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(e){t.timeSelect=e}}]},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(){t.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(){t.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(){t.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 i=this,e=this.options;this.storeTriggerValue="",this.storeValue=e.value;var t={type:"bi.time_popup",value:e.value,listeners:[{eventName:BI.TimePopup.BUTTON_CLEAR_EVENT_CHANGE,action:function(){i.setValue(),i.hidePopupView(),i.fireEvent(BI.TimeCombo.EVENT_CONFIRM)}},{eventName:BI.TimePopup.BUTTON_OK_EVENT_CHANGE,action:function(){i.setValue(i.popup.getValue()),i.hidePopupView(),i.fireEvent(BI.TimeCombo.EVENT_CONFIRM)}},{eventName:BI.TimePopup.BUTTON_NOW_EVENT_CHANGE,action:function(){i._setNowTime()}}],ref:function(e){i.popup=e}};return{type:"bi.htape",items:[{type:"bi.absolute",items:[{el:{type:"bi.combo",cls:"bi-border bi-border-radius bi-focus-shadow",container:e.container,toggle:!1,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,el:{type:"bi.time_trigger",height:e.height,allowEdit:e.allowEdit,watermark:e.watermark,format:e.format,value:e.value,ref:function(e){i.trigger=e},listeners:[{eventName:"EVENT_KEY_DOWN",action:function(){i.combo.isViewVisible()&&i.combo.hideView(),i.fireEvent(BI.TimeCombo.EVENT_KEY_DOWN,arguments)}},{eventName:"EVENT_STOP",action:function(){i.combo.isViewVisible()||i.combo.showView()}},{eventName:"EVENT_FOCUS",action:function(){i.storeTriggerValue=i.trigger.getKey(),i.combo.isViewVisible()||i.combo.showView(),i.fireEvent("EVENT_FOCUS")}},{eventName:"EVENT_BLUR",action:function(){i.fireEvent("EVENT_BLUR")}},{eventName:"EVENT_ERROR",action:function(){var e=BI.getDate();i.storeValue={hour:e.getHours(),minute:e.getMinutes(),second:e.getSeconds()},i.fireEvent("EVENT_ERROR")}},{eventName:"EVENT_VALID",action:function(){i.fireEvent("EVENT_VALID")}},{eventName:"EVENT_CHANGE",action:function(){i.fireEvent("EVENT_CHANGE")}},{eventName:"EVENT_CONFIRM",action:function(){var e,t;i.combo.isViewVisible()||(e=i.storeTriggerValue,t=i.trigger.getKey(),BI.isNotEmptyString(t)&&!BI.isEqual(t,e)?(i.storeValue=i.trigger.getValue(),i.setValue(i.trigger.getValue())):BI.isEmptyString(t)&&(i.storeValue=null,i.trigger.setValue()),i.fireEvent("EVENT_CONFIRM"))}}]},adjustLength:this.constants.comboAdjustHeight,popup:{el:t,width:this.constants.popupWidth,stopPropagation:!1},hideChecker:function(e){return 0===i.triggerBtn.element.find(e.target).length},listeners:[{eventName:BI.Combo.EVENT_BEFORE_POPUPVIEW,action:function(){i.popup.setValue(i.storeValue),i.fireEvent(BI.TimeCombo.EVENT_BEFORE_POPUPVIEW)}}],ref:function(e){i.combo=e}},top:0,left:0,right:0,bottom:0},{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button time-font icon-size-16",width:e.height,height:e.height,listeners:[{eventName:BI.IconButton.EVENT_CHANGE,action:function(){i.combo.isViewVisible()||i.combo.showView()}}],ref:function(e){i.triggerBtn=e}},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 i=this,e=this.options;return this.storeTriggerValue="",this.storeValue=e.value,{type:"bi.absolute",items:[{el:{type:"bi.sign_editor",height:e.height,validationChecker:function(e){return i._dateCheck(e)},quitChecker:function(){return!1},ref:function(e){i.editor=e},value:this._formatValue(e.value),hgap:4,allowBlank:!0,watermark:BI.isKey(e.watermark)?e.watermark:BI.i18nText("BI-Basic_Unrestricted"),title:BI.bind(this._getTitle,this),listeners:[{eventName:"EVENT_KEY_DOWN",action:function(){i.fireEvent("EVENT_KEY_DOWN",arguments)}},{eventName:"EVENT_FOCUS",action:function(){i.storeTriggerValue=i.getKey(),i.fireEvent("EVENT_FOCUS")}},{eventName:"EVENT_BLUR",action:function(){i.fireEvent("EVENT_BLUR")}},{eventName:"EVENT_STOP",action:function(){i.fireEvent("EVENT_STOP")}},{eventName:"EVENT_VALID",action:function(){i.fireEvent("EVENT_VALID")}},{eventName:"EVENT_ERROR",action:function(){i.fireEvent("EVENT_ERROR")}},{eventName:"EVENT_CONFIRM",action:function(){var e,t=i.editor.getValue();BI.isNotNull(t)&&i.editor.setState(t),BI.isNotEmptyString(t)&&!BI.isEqual(i.storeTriggerValue,i.getKey())&&(e=t.match(/\d+/g),i.storeValue={hour:0|e[0],minute:0|e[1],second:0|e[2]}),i.fireEvent("EVENT_CONFIRM")}},{eventName:"EVENT_START",action:function(){i.fireEvent("EVENT_START")}},{eventName:"EVENT_CHANGE",action:function(){i.fireEvent("EVENT_CHANGE")}}]},left:0,right:0,top:0,bottom:0},{el:{type:"bi.text",invisible:e.allowEdit,cls:"show-text",title:BI.bind(this._getTitle,this),hgap:4},left:0,right:0,top:0,bottom:0}]}},_dateCheck:function(i){var n=this._const,r=this;return BI.any(n.FORMAT_ARRAY,function(e,t){return BI.print(BI.parseDateTime(n.DEFAULT_DATE_STRING+" "+r._getCompleteHMS(i,t),n.COMPLETE_COMPARE_FORMAT),t)===i})},_getCompleteHMS:function(e,t){var i=this._const;switch(t){case"%M:%S":e=i.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.options;BI.DateInterval.superclass._init.apply(this,arguments),e.value=e.value||{},this.left=this._createCombo(e.value.start),this.right=this._createCombo(e.value.end),this.label=BI.createWidget({type:"bi.label",height:e.height,width:this.constants.width,text:"-"}),BI.createWidget({element:this,type:"bi.center",height:e.height,items:[{type:"bi.absolute",items:[{el:this.left,left:this.constants.offset,right:this.constants.width/2,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:this.right,left:this.constants.width/2,right:this.constants.offset,top:0,bottom:0}]}]}),BI.createWidget({type:"bi.horizontal_auto",element:this,items:[this.label]})},_createCombo:function(e){var i=this,t=this.options,n=BI.createWidget({type:"bi.dynamic_date_combo",supportDynamic:t.supportDynamic,minDate:t.minDate,maxDate:t.maxDate,behaviors:t.behaviors,value:e,height:t.height,listeners:[{eventName:BI.DynamicDateCombo.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW,action:function(){i.fireEvent(BI.DateInterval.EVENT_BEFORE_YEAR_MONTH_POPUPVIEW)}}]});return n.on(BI.DynamicDateCombo.EVENT_ERROR,function(){i._clearTitle(),BI.Bubbles.hide("error"),i.element.removeClass(i.constants.timeErrorCls),i.fireEvent(BI.DateInterval.EVENT_ERROR)}),n.on(BI.DynamicDateCombo.EVENT_VALID,function(){BI.Bubbles.hide("error");var e=i.left.getKey(),t=i.right.getKey();i._check(e,t)&&i._compare(e,t)?(i._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),i.element.addClass(i.constants.timeErrorCls),BI.Bubbles.show("error",BI.i18nText("BI-Time_Interval_Error_Text"),i,{offsetStyle:"center"}),i.fireEvent(BI.DateInterval.EVENT_ERROR)):(i._clearTitle(),i.element.removeClass(i.constants.timeErrorCls))}),n.on(BI.DynamicDateCombo.EVENT_FOCUS,function(){BI.Bubbles.hide("error");var e=i.left.getKey(),t=i.right.getKey();i._check(e,t)&&i._compare(e,t)?(i._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),i.element.addClass(i.constants.timeErrorCls),BI.Bubbles.show("error",BI.i18nText("BI-Time_Interval_Error_Text"),i,{offsetStyle:"center"}),i.fireEvent(BI.DateInterval.EVENT_ERROR)):(i._clearTitle(),i.element.removeClass(i.constants.timeErrorCls))}),n.on(BI.DynamicDateCombo.EVENT_CONFIRM,function(){BI.Bubbles.hide("error");var e=i.left.getKey(),t=i.right.getKey();i._check(e,t)&&i._compare(e,t)?(i._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),i.element.addClass(i.constants.timeErrorCls),i.fireEvent(BI.DateInterval.EVENT_ERROR)):(i._clearTitle(),i.element.removeClass(i.constants.timeErrorCls),i.fireEvent(BI.DateInterval.EVENT_CHANGE))}),n},_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 i=e.match(/\d+/g),n=t.match(/\d+/g);return this._dateCheck(e)&&BI.checkDateLegal(e)&&this._checkVoid({year:i[0],month:i[1],day:i[2]})&&this._dateCheck(t)&&BI.checkDateLegal(t)&&this._checkVoid({year:n[0],month:n[1],day:n[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)&&t<e},_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.options;BI.TimeInterval.superclass._init.apply(this,arguments),e.value=e.value||{},this.left=this._createCombo(e.value.start),this.right=this._createCombo(e.value.end),this.label=BI.createWidget({type:"bi.label",height:e.height,width:this.constants.width,text:"-"}),BI.createWidget({element:this,type:"bi.center",height:e.height,items:[{type:"bi.absolute",items:[{el:this.left,left:this.constants.offset,right:this.constants.width/2,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:this.right,left:this.constants.width/2,right:this.constants.offset,top:0,bottom:0}]}]}),BI.createWidget({type:"bi.horizontal_auto",element:this,items:[this.label]})},_createCombo:function(e){var i=this,t=this.options,n=BI.createWidget({type:"bi.dynamic_date_time_combo",supportDynamic:t.supportDynamic,minDate:t.minDate,maxDate:t.maxDate,behaviors:t.behaviors,value:e,height:t.height});return n.on(BI.DynamicDateTimeCombo.EVENT_ERROR,function(){i._clearTitle(),BI.Bubbles.hide("error"),i.element.removeClass(i.constants.timeErrorCls),i.fireEvent(BI.TimeInterval.EVENT_ERROR)}),n.on(BI.DynamicDateTimeCombo.EVENT_VALID,function(){BI.Bubbles.hide("error");var e=i.left.getKey(),t=i.right.getKey();i.left.isValid()&&i.right.isValid()&&i._check(e,t)&&i._compare(e,t)?(i._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),i.element.addClass(i.constants.timeErrorCls),BI.Bubbles.show("error",BI.i18nText("BI-Time_Interval_Error_Text"),i,{offsetStyle:"center"}),i.fireEvent(BI.TimeInterval.EVENT_ERROR)):(i._clearTitle(),i.element.removeClass(i.constants.timeErrorCls))}),n.on(BI.DynamicDateTimeCombo.EVENT_FOCUS,function(){BI.Bubbles.hide("error");var e=i.left.getKey(),t=i.right.getKey();i.left.isValid()&&i.right.isValid()&&i._check(e,t)&&i._compare(e,t)?(i._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),i.element.addClass(i.constants.timeErrorCls),BI.Bubbles.show("error",BI.i18nText("BI-Time_Interval_Error_Text"),i,{offsetStyle:"center"}),i.fireEvent(BI.TimeInterval.EVENT_ERROR)):(i._clearTitle(),i.element.removeClass(i.constants.timeErrorCls))}),n.on(BI.DynamicDateTimeCombo.EVENT_CONFIRM,function(){BI.Bubbles.hide("error");var e=i.left.getKey(),t=i.right.getKey();i.left.isValid()&&i.right.isValid()&&i._check(e,t)&&i._compare(e,t)?(i._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),i.element.addClass(i.constants.timeErrorCls),i.fireEvent(BI.TimeInterval.EVENT_ERROR)):(i._clearTitle(),i.element.removeClass(i.constants.timeErrorCls),i.fireEvent(BI.TimeInterval.EVENT_CHANGE))}),n},_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 i=e.match(/\d+/g),n=t.match(/\d+/g);return this._dateCheck(e)&&BI.checkDateLegal(e)&&this._checkVoid({year:i[0],month:i[1],day:i[2]})&&this._dateCheck(t)&&BI.checkDateLegal(t)&&this._checkVoid({year:n[0],month:n[1],day:n[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)&&t<e},_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 t=this,e=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(e){t.label=e}}]},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(e){t.left=e}},this._createCombo(e.value.start)),left:this.constants.offset,right:0,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:BI.extend({ref:function(e){t.right=e}},this._createCombo(e.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 t=this;this.options;return{type:"bi.vertical",ref:function(e){t.wrapper=e},items:[{type:"bi.label",text:BI.i18nText("BI-Multi_Date_Relative_Current_Time"),textAlign:"left",height:24},{type:"bi.dynamic_date_param_item",ref:function(){t.item=this},listeners:[{eventName:"EVENT_CHANGE",action:function(){t.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,i=BI.DynamicDateHelper.getCalculation(this._getValue());return!BI.checkDateVoid(i.getFullYear(),i.getMonth()+1,i.getDate(),t.min,t.max)[0]},_createValue:function(e,t){return{dateType:e,value:Math.abs(t),offset:0<t?1:0}},_getErrorText:function(){var e=this.options,t=BI.parseDateTime(e.min,"%Y-%X-%d"),i=BI.parseDateTime(e.max,"%Y-%X-%d");return BI.i18nText("BI-Basic_Year_Range_Error",t.getFullYear(),i.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=!this.item.checkValidation(),i=t?BI.i18nText("BI-Please_Input_Natural_Number"):(t=!this._checkDate(this._getValue()),this._getErrorText());return t&&e&&BI.Bubbles.show("dynamic-year-error",i,this.item),!t}}),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,i=this._year,n=BI.createWidget({type:"bi.year_calendar",behaviors:t.behaviors,min:t.min,max:t.max,logic:{dynamic:!0},year:i+12*e});return n.setValue(this._year),n},_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(!0),!0},_checkRightValid:function(){this.options;return this.preBtn.setEnable(!0),!0},_checkMin:function(){var i=this.options;BI.each(this.navigation.getAllCard(),function(e,t){t.setMinDate(i.min)})},_checkMax:function(){var i=this.options;BI.each(this.navigation.getAllCard(),function(e,t){t.setMaxDate(i.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,i=(e=e||{}).year;BI.checkDateVoid(i,1,1,t.min,t.max)[0]?(i=BI.getDate().getFullYear(),this.selectedYear="",this.navigation.setSelect(BI.YearCalendar.getPageByYear(i)),this.navigation.setValue("")):(this.selectedYear=BI.parseInt(i),this.navigation.setSelect(BI.YearCalendar.getPageByYear(i)),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 t=this,e=this.options;e.height-=2,BI.isNumeric(e.width)&&(e.width-=2),BI.DynamicYearCombo.superclass._init.apply(this,arguments),this.storeValue=e.value,this.trigger=BI.createWidget({type:"bi.dynamic_year_trigger",min:e.minDate,max:e.maxDate,height:e.height,value:e.value||""}),this.trigger.on(BI.DynamicYearTrigger.EVENT_KEY_DOWN,function(){t.combo.isViewVisible()&&t.combo.hideView()}),this.trigger.on(BI.DynamicYearTrigger.EVENT_FOCUS,function(){t.storeTriggerValue=this.getKey(),t.fireEvent(BI.DynamicYearCombo.EVENT_FOCUS)}),this.trigger.on(BI.DynamicYearTrigger.EVENT_START,function(){t.combo.isViewVisible()&&t.combo.hideView()}),this.trigger.on(BI.DynamicYearTrigger.EVENT_STOP,function(){t.combo.showView()}),this.trigger.on(BI.DynamicYearTrigger.EVENT_ERROR,function(){t.combo.isViewVisible()&&t.combo.hideView(),t.fireEvent(BI.DynamicYearCombo.EVENT_ERROR)}),this.trigger.on(BI.DynamicYearTrigger.EVENT_VALID,function(){t.fireEvent(BI.DynamicYearCombo.EVENT_VALID)}),this.trigger.on(BI.DynamicYearTrigger.EVENT_CONFIRM,function(){t.combo.isViewVisible()||(this.getKey()&&this.getKey()!==t.storeTriggerValue?(t.storeValue=t.trigger.getValue(),t.setValue(t.storeValue)):this.getKey()||(t.storeValue=null,t.setValue()),t._checkDynamicValue(t.storeValue),t.fireEvent(BI.DynamicYearCombo.EVENT_CONFIRM))}),this.combo=BI.createWidget({type:"bi.combo",container:e.container,isNeedAdjustHeight:!1,isNeedAdjustWidth:!1,el:this.trigger,destroyWhenHide:!0,adjustLength:1,popup:{minWidth:85,stopPropagation:!1,el:{type:"bi.dynamic_year_popup",supportDynamic:e.supportDynamic,ref:function(){t.popup=this},listeners:[{eventName:BI.DynamicYearPopup.EVENT_CHANGE,action:function(){t.setValue(t.popup.getValue()),t.combo.hideView(),t.fireEvent(BI.DynamicYearCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearPopup.BUTTON_CLEAR_EVENT_CHANGE,action:function(){t.setValue(),t.combo.hideView(),t.fireEvent(BI.DynamicYearCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearPopup.BUTTON_lABEL_EVENT_CHANGE,action:function(){var e=BI.getDate();t.setValue({type:BI.DynamicYearCombo.Static,value:{year:e.getFullYear()}}),t.combo.hideView(),t.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearPopup.BUTTON_OK_EVENT_CHANGE,action:function(){t.setValue(t.popup.getValue()),t.combo.hideView(),t.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}}],behaviors:e.behaviors,min:e.minDate,max:e.maxDate},value:e.value||""}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){t.popup.setMinDate(e.minDate),t.popup.setMaxDate(e.maxDate),t.popup.setValue(t.storeValue),t.fireEvent(BI.DynamicYearCombo.EVENT_BEFORE_POPUPVIEW)}),BI.createWidget({type:"bi.htape",element:this,ref:function(){t.comboWrapper=this},items:[{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button date-change-h-font",width:24,height:24,ref:function(){t.changeIcon=this}},width:24},this.combo]}),this._checkDynamicValue(e.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,buttonHeight:24},props:{baseCls:"bi-year-popup",behaviors:{},min:"1900-01-01",max:"2099-12-31",width:180,supportDynamic:!0},render:function(){var e=this,t=(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:t.buttonHeight-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:t.buttonHeight-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:t.buttonHeight-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:24}}]}},_setInnerValue:function(){var e;this.dateTab.getSelect()===BI.DynamicDateCombo.Static?(this.yearButton.setValue(BI.i18nText("BI-Basic_Current_Year")),this.yearButton.setEnable(!this._checkYearValid())):(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 t=this,i=this.options;return{type:"bi.tab",logic:{dynamic:!0},ref:function(){t.dateTab=this},tab:{type:"bi.linear_segment",invisible:!i.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(e){switch(e){case BI.DynamicYearCombo.Dynamic:return{type:"bi.dynamic_year_card",cls:"dynamic-year-pane",min:t.options.min,max:t.options.max,listeners:[{eventName:"EVENT_CHANGE",action:function(){t._setInnerValue(t.year,e)}}],ref:function(){t.dynamicPane=this}};case BI.DynamicYearCombo.Static:default:return{type:"bi.static_year_card",behaviors:i.behaviors,min:t.options.min,max:t.options.max,listeners:[{eventName:BI.StaticYearCard.EVENT_CHANGE,action:function(){t.fireEvent(BI.DynamicYearPopup.EVENT_CHANGE)}}],ref:function(){t.year=this}}}},listeners:[{eventName:BI.Tab.EVENT_CHANGE,action:function(){switch(t.dateTab.getSelect()){case BI.DynamicYearCombo.Static:var e=BI.DynamicDateHelper.getCalculation(t.dynamicPane.getValue());t.year.setValue({year:e.getFullYear()}),t._setInnerValue();break;case BI.DynamicYearCombo.Dynamic:default:t.storeValue&&t.storeValue.type===BI.DynamicYearCombo.Dynamic?t.dynamicPane.setValue(t.storeValue.value):t.dynamicPane.setValue({year:0}),t._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=(e=e||{}).type||BI.DynamicDateCombo.Static,i=e.value||e;switch(this.dateTab.setSelect(t),t){case BI.DynamicDateCombo.Dynamic:this.dynamicPane.setValue(i),this._setInnerValue();break;case BI.DynamicDateCombo.Static:default:this.year.setValue(i),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 t=this,i=this.options,e=this._const;this.editor=BI.createWidget({type:"bi.sign_editor",height:i.height,validationChecker:function(e){return""===e||BI.isPositiveInteger(e)&&!BI.checkDateVoid(e,1,1,i.min,i.max)[0]},quitChecker:function(e){return!1},hgap:e.hgap,vgap:e.vgap,watermark:BI.i18nText("BI-Basic_Unrestricted"),allowBlank:!0,errorText:function(){return BI.i18nText("BI-Year_Trigger_Invalid_Text")}}),this.editor.on(BI.SignEditor.EVENT_KEY_DOWN,function(){t.fireEvent(BI.DynamicYearTrigger.EVENT_KEY_DOWN,arguments)}),this.editor.on(BI.SignEditor.EVENT_FOCUS,function(){t.fireEvent(BI.DynamicYearTrigger.EVENT_FOCUS)}),this.editor.on(BI.SignEditor.EVENT_STOP,function(){t.fireEvent(BI.DynamicYearTrigger.EVENT_STOP)}),this.editor.on(BI.SignEditor.EVENT_CONFIRM,function(){var e=t.editor.getValue();BI.isNotNull(e)&&t.editor.setValue(e),BI.isNotEmptyString(e)&&(t.storeValue={type:BI.DynamicDateCombo.Static,value:{year:e}}),t.fireEvent(BI.DynamicYearTrigger.EVENT_CONFIRM)}),this.editor.on(BI.SignEditor.EVENT_SPACE,function(){t.editor.isValid()&&t.editor.blur()}),this.editor.on(BI.SignEditor.EVENT_START,function(){t.fireEvent(BI.DynamicYearTrigger.EVENT_START)}),this.editor.on(BI.SignEditor.EVENT_ERROR,function(){t.fireEvent(BI.DynamicYearTrigger.EVENT_ERROR)}),this.editor.on(BI.SignEditor.EVENT_VALID,function(){t.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:i.height},width:i.height},{el:{type:"bi.trigger_icon_button",width:i.height},width:i.height}]}),this.setValue(i.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 i=BI.print(e,"%Y");this.editor.setState(i),this.editor.setValue(i)},_titleCreator:function(){var e=this.storeValue||{},t=e.type||BI.DynamicDateCombo.Static,i=e.value;if(!this.editor.isValid())return"";switch(t){case BI.DynamicDateCombo.Dynamic:var n=this._getText(i),r=BI.getDate(),r=BI.DynamicDateHelper.getCalculation(i),a=BI.print(r,"%Y");return BI.isEmptyString(n)?a:n+":"+a;case BI.DynamicDateCombo.Static:default:return(i=i||{}).year}},setValue:function(e){var t,i,n=BI.getDate();switch(this.storeValue=e,BI.isNotNull(e)&&(t=e.type||BI.DynamicDateCombo.Static,i=e.value||e),t){case BI.DynamicDateCombo.Dynamic:var r=this._getText(i),n=BI.DynamicDateHelper.getCalculation(i);this._setInnerValue(n,r);break;case BI.DynamicDateCombo.Static:default:i=i||{},this.editor.setState(i.year),this.editor.setValue(i.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 t=this,e=this.options;return e.value=e.value||{},this.left=this._createCombo(e.value.start),this.right=this._createCombo(e.value.end),[{type:"bi.center",hgap:15,height:this.constants.height,items:[{type:"bi.absolute",items:[{el:t.left,left:this.constants.offset,right:0,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:t.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(e){t.label=e}}]}]},_createCombo:function(e){var i=this,t=this.options,n=BI.createWidget({type:"bi.dynamic_year_combo",supportDynamic:t.supportDynamic,minDate:t.minDate,maxDate:t.maxDate,behaviors:t.behaviors,value:e,listeners:[{eventName:BI.DynamicYearCombo.EVENT_BEFORE_POPUPVIEW,action:function(){i.fireEvent(BI.YearInterval.EVENT_BEFORE_POPUPVIEW)}}]});return n.on(BI.DynamicYearCombo.EVENT_ERROR,function(){i._clearTitle(),BI.Bubbles.hide("error"),i.element.removeClass(i.constants.timeErrorCls),i.fireEvent(BI.YearInterval.EVENT_ERROR)}),n.on(BI.DynamicYearCombo.EVENT_VALID,function(){i._checkValid()}),n.on(BI.DynamicYearCombo.EVENT_FOCUS,function(){i._checkValid()}),n.on(BI.DynamicYearCombo.EVENT_CONFIRM,function(){BI.Bubbles.hide("error");var e=i.left.getKey(),t=i.right.getKey();i.left.isStateValid()&&i.right.isStateValid()&&i._check(e,t)&&i._compare(e,t)?(i._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),i.element.addClass(i.constants.timeErrorCls),i.fireEvent(BI.YearInterval.EVENT_ERROR)):(i._clearTitle(),i.element.removeClass(i.constants.timeErrorCls),i.fireEvent(BI.YearInterval.EVENT_CHANGE))}),n},_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 i=e.match(/\d+/g),n=t.match(/\d+/g),r="";BI.isNotNull(i)&&(r=i[0]||"");var a="";return BI.isNotNull(n)&&(a=n[0]||""),this._dateCheck(r)&&BI.checkDateLegal(r)&&this._checkVoid({year:i[0],month:1,day:1})&&this._dateCheck(a)&&BI.checkDateLegal(a)&&this._checkVoid({year:n[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)&&t<e},_setTitle:function(e){this.setTitle(e)},_clearTitle:function(){this.setTitle("")},_checkValid:function(){var e=this;BI.Bubbles.hide("error");var t=e.left.getKey(),i=e.right.getKey();e.left.isValid()&&e.right.isValid()&&e._check(t,i)&&e._compare(t,i)?(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 t=this;return{type:"bi.vertical",items:[{type:"bi.label",text:BI.i18nText("BI-Multi_Date_Relative_Current_Time"),textAlign:"left",height:24},{type:"bi.vertical",ref:function(e){t.wrapper=e},items:[{el:{type:"bi.dynamic_date_param_item",validationChecker:BI.bind(t._checkDate,t),ref:function(){t.year=this},listeners:[{eventName:"EVENT_CHANGE",action:function(){t.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(){t.month=this},listeners:[{eventName:"EVENT_CHANGE",action:function(){t.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"),i=BI.parseDateTime(e.max,"%Y-%X-%d");return BI.i18nText("BI-Basic_Year_Month_Range_Error",t.getFullYear(),t.getMonth()+1,i.getFullYear(),i.getMonth()+1)},_checkDate:function(e){var t=this.options,i=BI.DynamicDateHelper.getCalculation(BI.extend(this._getValue(),this._digestDateTypeValue(e)));return!BI.checkDateVoid(i.getFullYear(),i.getMonth()+1,i.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:0<t?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=!this.year.checkValidation(),i=!this.month.checkValidation(),n=t||i,r=n?BI.i18nText("BI-Please_Input_Natural_Number"):(n=!this._checkDate(this._getValue()),this._getErrorText());return n&&e&&BI.Bubbles.show("dynamic-year-month-error",r,this.wrapper),!n}}),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 n=this,e=[1,7,2,8,3,9,4,10,5,11,6,12],t=[];return t.push(e.slice(0,2)),t.push(e.slice(2,4)),t.push(e.slice(4,6)),t.push(e.slice(6,8)),t.push(e.slice(8,10)),t.push(e.slice(10,12)),BI.map(t,function(i,e){return BI.map(e,function(t,e){return{type:"bi.text_item",cls:"bi-list-item-select",textAlign:"center",whiteSpace:"nowrap",once:!1,forceSelected:!0,height:23,width:38,value:e,text:e,ref:function(e){n.monthMap[0===t?i:i+6]=e}}})})},render:function(){var t=this,e=this.options;return this.monthMap={},{type:"bi.vertical",items:[{type:"bi.year_picker",cls:"bi-split-bottom",min:e.min,max:e.max,ref:function(){t.yearPicker=this},behaviors:e.behaviors,height:30,listeners:[{eventName:BI.YearPicker.EVENT_CHANGE,action:function(){var e=this.getValue();t._checkMonthStatus(e),t.setValue({year:e,month:t.selectedMonth})}}]},{el:{type:"bi.button_group",behaviors:e.behaviors,ref:function(){t.month=this},items:this._createMonths(),layouts:[BI.LogicFactory.createLogic("table",BI.extend({dynamic:!0},{columns:2,rows:6,columnSize:[.5,.5],rowSize:25})),{type:"bi.center_adapt",vgap:1,hgap:2}],value:e.value,listeners:[{eventName:BI.ButtonGroup.EVENT_CHANGE,action:function(){t.selectedYear=t.yearPicker.getValue(),t.selectedMonth=this.getValue()[0],t.fireEvent(BI.StaticYearMonthCard.EVENT_CHANGE)}}]},vgap:5}]}},created:function(){this._checkMonthStatus(this.selectedYear)},_checkMonthStatus:function(e){var t=this.options,i=BI.parseDateTime(t.min,"%Y-%X-%d"),n=BI.parseDateTime(t.max,"%Y-%X-%d"),r=i.getFullYear(),a=n.getFullYear(),o=0,s=11;r===e&&(o=i.getMonth()),a===e&&(s=n.getMonth());var l=e<r||a<e;BI.each(this.monthMap,function(e,t){var i=e<o||s<e;t.setEnable(!l&&!i)})},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,i=this.options,n={};n.year=e.year||0,n.month=e.month||0,0===n.year||0===n.month||BI.checkDateVoid(n.year,n.month,1,i.min,i.max)[0]?(t=n.year||BI.getDate().getFullYear(),this.selectedYear=t,this.selectedMonth="",this.yearPicker.setValue(t),this.month.setValue()):(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 i=this,e=this.options;e.height-=2,BI.isNumeric(e.width)&&(e.width-=2),BI.DynamicYearMonthCombo.superclass._init.apply(this,arguments),this.storeValue=e.value,this.storeTriggerValue="",this.trigger=BI.createWidget({type:"bi.dynamic_year_month_trigger",min:e.minDate,max:e.maxDate,height:e.height,value:e.value||""}),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_KEY_DOWN,function(){i.combo.isViewVisible()&&i.combo.hideView()}),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_START,function(){i.combo.isViewVisible()&&i.combo.hideView()}),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_STOP,function(){i.combo.showView()}),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_ERROR,function(){i.combo.isViewVisible()&&i.combo.hideView(),i.fireEvent(BI.DynamicYearMonthCombo.EVENT_ERROR)}),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_VALID,function(){i.fireEvent(BI.DynamicYearMonthCombo.EVENT_VALID)}),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_CONFIRM,function(){var e=i.storeTriggerValue,t=i.trigger.getKey();BI.isEqual(t,e)||(BI.isNotEmptyString(t)&&!BI.isEqual(t,e)&&(i.storeValue=i.trigger.getValue(),i.setValue(i.trigger.getValue())),i._checkDynamicValue(i.storeValue),i.fireEvent(BI.DynamicYearMonthCombo.EVENT_CONFIRM))}),this.trigger.on(BI.DynamicYearMonthTrigger.EVENT_FOCUS,function(){i.storeTriggerValue=i.trigger.getKey(),i.fireEvent(BI.DynamicYearMonthCombo.EVENT_FOCUS)}),this.combo=BI.createWidget({type:"bi.combo",container:e.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:e.supportDynamic,ref:function(){i.popup=this},listeners:[{eventName:BI.DynamicYearMonthPopup.EVENT_CHANGE,action:function(){i.setValue(i.popup.getValue()),i.combo.hideView(),i.fireEvent(BI.DynamicYearMonthCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearMonthPopup.BUTTON_CLEAR_EVENT_CHANGE,action:function(){i.setValue(),i.combo.hideView(),i.fireEvent(BI.DynamicYearMonthCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearMonthPopup.BUTTON_lABEL_EVENT_CHANGE,action:function(){var e=BI.getDate();i.setValue({type:BI.DynamicYearMonthCombo.Static,value:{year:e.getFullYear(),month:e.getMonth()+1}}),i.combo.hideView(),i.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearMonthPopup.BUTTON_OK_EVENT_CHANGE,action:function(){var e=i.popup.getValue();i._checkValue(e)&&i.setValue(e),i.combo.hideView(),i.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}}],behaviors:e.behaviors,min:e.minDate,max:e.maxDate},value:e.value||""}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){i.popup.setMinDate(e.minDate),i.popup.setMaxDate(e.maxDate),i.popup.setValue(i.storeValue),i.fireEvent(BI.DynamicYearMonthCombo.EVENT_BEFORE_POPUPVIEW)}),BI.createWidget({type:"bi.htape",element:this,ref:function(){i.comboWrapper=this},items:[{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button date-change-h-font",width:24,height:24,ref:function(){i.changeIcon=this}},width:24},this.combo]}),this._checkDynamicValue(e.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 i=e.value||{};return!BI.checkDateVoid(i.year,i.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,buttonHeight:24},props:{baseCls:"bi-year-month-popup",behaviors:{},min:"1900-01-01",max:"2099-12-31",width:180,supportDynamic:!0},render:function(){var e=this,t=(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:t.buttonHeight-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:t.buttonHeight-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:t.buttonHeight-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)}}]}]],height:24}}]}},_setInnerValue:function(){var e;this.dateTab.getSelect()===BI.DynamicDateCombo.Static?(this.textButton.setValue(BI.i18nText("BI-Basic_Current_Month")),this.textButton.setEnable(!this._checkTodayValid())):(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 t=this,i=this.options;return{type:"bi.tab",logic:{dynamic:!0},ref:function(){t.dateTab=this},tab:{type:"bi.linear_segment",cls:"bi-split-bottom",invisible:!i.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(e){switch(e){case BI.DynamicYearCombo.Dynamic:return{type:"bi.dynamic_year_month_card",cls:"dynamic-year-month-pane",min:t.options.min,max:t.options.max,listeners:[{eventName:"EVENT_CHANGE",action:function(){t._setInnerValue(t.year,e)}}],ref:function(){t.dynamicPane=this}};case BI.DynamicYearCombo.Static:default:return{type:"bi.static_year_month_card",behaviors:i.behaviors,min:t.options.min,max:t.options.max,listeners:[{eventName:BI.StaticYearMonthCard.EVENT_CHANGE,action:function(){t.fireEvent(BI.DynamicYearMonthPopup.EVENT_CHANGE)}}],ref:function(){t.year=this}}}},listeners:[{eventName:BI.Tab.EVENT_CHANGE,action:function(){switch(t.dateTab.getSelect()){case BI.DynamicYearCombo.Static:var e=BI.DynamicDateHelper.getCalculation(t.dynamicPane.getValue());t.year.setValue({year:e.getFullYear(),month:e.getMonth()+1}),t._setInnerValue();break;case BI.DynamicYearCombo.Dynamic:default:t.storeValue&&t.storeValue.type===BI.DynamicYearCombo.Dynamic?t.dynamicPane.setValue(t.storeValue.value):t.dynamicPane.setValue({year:0}),t._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=(e=e||{}).type||BI.DynamicDateCombo.Static,i=e.value||e;switch(this.dateTab.setSelect(t),t){case BI.DynamicDateCombo.Dynamic:this.dynamicPane.setValue(i),this._setInnerValue();break;case BI.DynamicDateCombo.Static:default:this.year.setValue(i),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(i){var n=this,r=this.options,e=this._const,t=BI.createWidget({type:"bi.sign_editor",height:r.height,validationChecker:function(e){if(i)return""===e||BI.isPositiveInteger(e)&&!BI.checkDateVoid(e,parseInt(e,10)===BI.parseDateTime(r.min,"%Y-%X-%d").getFullYear()?BI.parseDateTime(r.min,"%Y-%X-%d").getMonth()+1:1,1,r.min,r.max)[0];var t=n.yearEditor.getValue();return""===e||BI.isPositiveInteger(e)&&1<=e&&e<=12&&(!!BI.isEmptyString(t)||!BI.checkDateVoid(n.yearEditor.getValue(),e,1,r.min,r.max)[0])},quitChecker:function(){return!1},watermark:BI.i18nText("BI-Basic_Unrestricted"),errorText:function(e){return BI.i18nText("BI-Year_Trigger_Invalid_Text")},hgap:e.hgap,vgap:e.vgap,allowBlank:!0});return t.on(BI.SignEditor.EVENT_KEY_DOWN,function(){n.fireEvent(BI.DynamicYearMonthTrigger.EVENT_KEY_DOWN)}),t.on(BI.SignEditor.EVENT_FOCUS,function(){n.fireEvent(BI.DynamicYearMonthTrigger.EVENT_FOCUS)}),t.on(BI.SignEditor.EVENT_STOP,function(){n.fireEvent(BI.DynamicYearMonthTrigger.EVENT_STOP)}),t.on(BI.SignEditor.EVENT_CONFIRM,function(){n._doEditorConfirm(t),n.fireEvent(BI.DynamicYearMonthTrigger.EVENT_CONFIRM)}),t.on(BI.SignEditor.EVENT_SPACE,function(){t.isValid()&&t.blur()}),t.on(BI.SignEditor.EVENT_START,function(){n.fireEvent(BI.DynamicYearMonthTrigger.EVENT_START)}),t.on(BI.SignEditor.EVENT_ERROR,function(){n.fireEvent(BI.DynamicYearMonthTrigger.EVENT_ERROR)}),t.on(BI.SignEditor.EVENT_VALID,function(){var e=n.yearEditor.getValue(),t=n.monthEditor.getValue();BI.isNotEmptyString(e)&&BI.isNotEmptyString(t)&&BI.isPositiveInteger(e)&&1<=t&&t<=12&&!BI.checkDateVoid(e,t,1,r.min,r.max)[0]&&n.fireEvent(BI.DynamicYearMonthTrigger.EVENT_VALID)}),t.on(BI.SignEditor.EVENT_CHANGE,function(){i&&n._autoSwitch(t)}),t},_titleCreator:function(){var e=this.storeValue||{},t=e.type||BI.DynamicDateCombo.Static,i=e.value;if(!this.monthEditor.isValid()||!this.yearEditor.isValid())return"";switch(t){case BI.DynamicDateCombo.Dynamic:var n=this._getText(i),r=BI.getDate(),r=BI.DynamicDateHelper.getCalculation(i),a=BI.print(r,"%Y-%x");return BI.isEmptyString(n)?a:n+":"+a;case BI.DynamicDateCombo.Static:default:return i=i||{},this._getStaticTitle(i)}},_doEditorConfirm:function(e){var t=e.getValue();BI.isNotNull(t)&&e.setValue(t);var i=this.monthEditor.getValue();this.storeValue={type:BI.DynamicDateCombo.Static,value:{year:this.yearEditor.getValue(),month:BI.isEmptyString(this.monthEditor.getValue())?"":i}}},_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,i,n=BI.getDate();switch(this.storeValue=e,BI.isNotNull(e)&&(t=e.type||BI.DynamicDateCombo.Static,i=e.value||e),t){case BI.DynamicDateCombo.Dynamic:var r=this._getText(i),n=BI.DynamicDateHelper.getCalculation(i);this._setInnerValue(n,r);break;case BI.DynamicDateCombo.Static:default:i=i||{};var a=BI.isNull(i.month)?null:i.month;this.yearEditor.setValue(i.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.options;BI.YearMonthInterval.superclass._init.apply(this,arguments),e.value=e.value||{},this.left=this._createCombo(e.value.start),this.right=this._createCombo(e.value.end),this.label=BI.createWidget({type:"bi.label",height:this.constants.height,width:this.constants.width,text:"-"}),BI.createWidget({element:this,type:"bi.center",hgap:15,height:this.constants.height,items:[{type:"bi.absolute",items:[{el:this.left,left:this.constants.offset,right:0,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:this.right,left:0,right:this.constants.offset,top:0,bottom:0}]}]}),BI.createWidget({type:"bi.horizontal_auto",element:this,items:[this.label]})},_createCombo:function(e){var i=this,t=this.options,n=BI.createWidget({type:"bi.dynamic_year_month_combo",supportDynamic:t.supportDynamic,minDate:t.minDate,maxDate:t.maxDate,behaviors:t.behaviors,value:e,listeners:[{eventName:BI.DynamicYearMonthCombo.EVENT_BEFORE_POPUPVIEW,action:function(){i.fireEvent(BI.YearMonthInterval.EVENT_BEFORE_POPUPVIEW)}}]});return n.on(BI.DynamicYearMonthCombo.EVENT_ERROR,function(){i._clearTitle(),BI.Bubbles.hide("error"),i.element.removeClass(i.constants.timeErrorCls),i.fireEvent(BI.YearMonthInterval.EVENT_ERROR)}),n.on(BI.DynamicYearMonthCombo.EVENT_VALID,function(){i._checkValid()}),n.on(BI.DynamicYearMonthCombo.EVENT_FOCUS,function(){i._checkValid()}),n.on(BI.DynamicYearMonthCombo.EVENT_CONFIRM,function(){BI.Bubbles.hide("error");var e=i.left.getKey(),t=i.right.getKey();i.left.isStateValid()&&i.right.isStateValid()&&i._check(e,t)&&i._compare(e,t)?(i._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),i.element.addClass(i.constants.timeErrorCls),i.fireEvent(BI.YearMonthInterval.EVENT_ERROR)):(i._clearTitle(),i.element.removeClass(i.constants.timeErrorCls),i.fireEvent(BI.YearMonthInterval.EVENT_CHANGE))}),n},_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 i=e.match(/\d+/g),n=t.match(/\d+/g),r="";BI.isNotNull(i)&&(r=(i[0]||"")+"-"+(i[1]||1));var a="";return BI.isNotNull(n)&&(a=(n[0]||"")+"-"+(n[1]||1)),this._dateCheck(r)&&BI.checkDateLegal(r)&&this._checkVoid({year:i[0],month:i[1]||1,day:1})&&this._dateCheck(a)&&BI.checkDateLegal(a)&&this._checkVoid({year:n[0],month:n[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)&&t<e},_setTitle:function(e){this.setTitle(e)},_clearTitle:function(){this.setTitle("")},_checkValid:function(){var e=this;BI.Bubbles.hide("error");var t=e.left.getKey(),i=e.right.getKey();e.left.isValid()&&e.right.isValid()&&e._check(t,i)&&e._compare(t,i)?(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 t=this;return{type:"bi.vertical",items:[{type:"bi.label",text:BI.i18nText("BI-Multi_Date_Relative_Current_Time"),textAlign:"left",height:24},{type:"bi.vertical",ref:function(e){t.wrapper=e},items:[{el:{type:"bi.dynamic_date_param_item",validationChecker:BI.bind(t._checkDate,t),ref:function(){t.year=this},listeners:[{eventName:"EVENT_CHANGE",action:function(){t.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(){t.quarter=this},listeners:[{eventName:"EVENT_CHANGE",action:function(){t.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"),i=BI.parseDateTime(e.max,"%Y-%X-%d");return BI.i18nText("BI-Basic_Year_Quarter_Range_Error",t.getFullYear(),BI.getQuarter(t),i.getFullYear(),BI.getQuarter(i))},_checkDate:function(e){var t=this.options,i=BI.DynamicDateHelper.getCalculation(BI.extend(this._getValue(),this._digestDateTypeValue(e)));return!BI.checkDateVoid(i.getFullYear(),i.getMonth()+1,i.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:0<t?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=!this.year.checkValidation(),i=!this.quarter.checkValidation(),n=t||i,r=n?BI.i18nText("BI-Please_Input_Natural_Number"):(n=!this._checkDate(this._getValue()),this._getErrorText());return n&&e&&BI.Bubbles.show("dynamic-year-quarter-error",r,this.wrapper),!n}}),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 i=this,e=[{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(e,function(t,e){return BI.extend(e,{type:"bi.text_item",cls:"bi-list-item-select",textAlign:"center",whiteSpace:"nowrap",once:!1,forceSelected:!0,height:24,ref:function(e){i.quarterMap[t+1]=e}})})},render:function(){var t=this,e=this.options;return this.quarterMap={},{type:"bi.vertical",items:[{type:"bi.year_picker",cls:"bi-split-bottom",ref:function(){t.yearPicker=this},min:e.min,max:e.max,behaviors:e.behaviors,height:30,listeners:[{eventName:BI.YearPicker.EVENT_CHANGE,action:function(){var e=this.getValue();t._checkQuarterStatus(e),t.setValue({year:e,quarter:t.selectedQuarter})}}]},{el:{type:"bi.button_group",behaviors:e.behaviors,ref:function(){t.quarter=this},items:this._createQuarter(),layouts:[{type:"bi.vertical",vgap:10}],value:e.value,listeners:[{eventName:BI.ButtonGroup.EVENT_CHANGE,action:function(){t.selectedYear=t.yearPicker.getValue(),t.selectedQuarter=this.getValue()[0],t.fireEvent(BI.StaticYearQuarterCard.EVENT_CHANGE)}}]},vgap:5}]}},_checkQuarterStatus:function(e){var t=this.options,i=BI.parseDateTime(t.min,"%Y-%X-%d"),n=BI.parseDateTime(t.max,"%Y-%X-%d"),r=i.getFullYear(),a=n.getFullYear(),o=1,s=4;r===e&&(o=BI.parseInt(BI.getQuarter(i))),a===e&&(s=BI.parseInt(BI.getQuarter(n)));var l=e<r||a<e;BI.each(this.quarterMap,function(e,t){var i=e<o||s<e;t.setEnable(!l&&!i)})},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,i=this.options,n={};n.year=e.year||0,n.quarter=e.quarter||0,0===n.quarter||0===n.year||BI.checkDateVoid(n.year,n.quarter,1,i.min,i.max)[0]?(t=n.year||BI.getDate().getFullYear(),this.selectedYear=t,this.selectedQuarter="",this.yearPicker.setValue(t),this.quarter.setValue()):(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 i=this,e=this.options;e.height-=2,BI.isNumeric(e.width)&&(e.width-=2),BI.DynamicYearQuarterCombo.superclass._init.apply(this,arguments),this.storeValue=e.value,i.storeTriggerValue="",this.trigger=BI.createWidget({type:"bi.dynamic_year_quarter_trigger",min:e.minDate,max:e.maxDate,height:e.height,value:e.value||""}),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_KEY_DOWN,function(){i.combo.isViewVisible()&&i.combo.hideView()}),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_START,function(){i.combo.isViewVisible()&&i.combo.hideView()}),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_STOP,function(){i.combo.showView()}),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_ERROR,function(){i.combo.isViewVisible()&&i.combo.hideView(),i.fireEvent(BI.DynamicYearQuarterCombo.EVENT_ERROR)}),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_VALID,function(){i.fireEvent(BI.DynamicYearMonthCombo.EVENT_VALID)}),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_CONFIRM,function(){var e=i.storeTriggerValue,t=i.trigger.getKey();BI.isEqual(t,e)||(BI.isNotEmptyString(t)&&!BI.isEqual(t,e)&&(i.storeValue=i.trigger.getValue(),i.setValue(i.trigger.getValue())),i._checkDynamicValue(i.storeValue),i.fireEvent(BI.DynamicYearQuarterCombo.EVENT_CONFIRM))}),this.trigger.on(BI.DynamicYearQuarterTrigger.EVENT_FOCUS,function(){i.storeTriggerValue=i.trigger.getKey(),i.fireEvent(BI.DynamicYearQuarterCombo.EVENT_FOCUS)}),this.combo=BI.createWidget({type:"bi.combo",container:e.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:e.supportDynamic,ref:function(){i.popup=this},listeners:[{eventName:BI.DynamicYearQuarterPopup.EVENT_CHANGE,action:function(){i.setValue(i.popup.getValue()),i.combo.hideView(),i.fireEvent(BI.DynamicYearQuarterCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearQuarterPopup.BUTTON_CLEAR_EVENT_CHANGE,action:function(){i.setValue(),i.combo.hideView(),i.fireEvent(BI.DynamicYearQuarterCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearQuarterPopup.BUTTON_lABEL_EVENT_CHANGE,action:function(){var e=BI.getDate();i.setValue({type:BI.DynamicYearMonthCombo.Static,value:{year:e.getFullYear(),quarter:BI.getQuarter(e)}}),i.combo.hideView(),i.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}},{eventName:BI.DynamicYearQuarterPopup.BUTTON_OK_EVENT_CHANGE,action:function(){var e=i.popup.getValue();i._checkValue(e)&&i.setValue(e),i.combo.hideView(),i.fireEvent(BI.DynamicDateCombo.EVENT_CONFIRM)}}],behaviors:e.behaviors,min:e.minDate,max:e.maxDate},value:e.value||""}}),this.combo.on(BI.Combo.EVENT_BEFORE_POPUPVIEW,function(){i.popup.setMinDate(e.minDate),i.popup.setMaxDate(e.maxDate),i.popup.setValue(i.storeValue),i.fireEvent(BI.DynamicYearQuarterCombo.EVENT_BEFORE_POPUPVIEW)}),BI.createWidget({type:"bi.htape",element:this,ref:function(){i.comboWrapper=this},items:[{el:{type:"bi.icon_button",cls:"bi-trigger-icon-button date-change-h-font",width:24,height:24,ref:function(){i.changeIcon=this}},width:24},this.combo]}),this._checkDynamicValue(e.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 i=e.value||{};return!BI.checkDateVoid(i.year,3*(i.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,t=(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:t.buttonHeight-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:t.buttonHeight-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:t.buttonHeight-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:24}}]}},_setInnerValue:function(){var e;this.dateTab.getSelect()===BI.DynamicYearQuarterCombo.Static?(this.textButton.setValue(BI.i18nText("BI-Basic_Current_Quarter")),this.textButton.setEnable(!this._checkTodayValid())):(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 t=this,i=this.options;return{type:"bi.tab",logic:{dynamic:!0},ref:function(){t.dateTab=this},tab:{type:"bi.linear_segment",cls:"bi-split-bottom",invisible:!i.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(e){switch(e){case BI.DynamicYearQuarterCombo.Dynamic:return{type:"bi.dynamic_year_quarter_card",cls:"dynamic-year-quarter-pane",min:t.options.min,max:t.options.max,listeners:[{eventName:"EVENT_CHANGE",action:function(){t._setInnerValue(t.year,e)}}],ref:function(){t.dynamicPane=this}};case BI.DynamicYearQuarterCombo.Static:default:return{type:"bi.static_year_quarter_card",behaviors:i.behaviors,min:t.options.min,max:t.options.max,listeners:[{eventName:BI.DynamicYearCard.EVENT_CHANGE,action:function(){t.fireEvent(BI.DynamicYearQuarterPopup.EVENT_CHANGE)}}],ref:function(){t.year=this}}}},listeners:[{eventName:BI.Tab.EVENT_CHANGE,action:function(){switch(t.dateTab.getSelect()){case BI.DynamicYearQuarterCombo.Static:var e=BI.DynamicDateHelper.getCalculation(t.dynamicPane.getValue());t.year.setValue({year:e.getFullYear(),quarter:BI.getQuarter(e)}),t._setInnerValue();break;case BI.DynamicYearQuarterCombo.Dynamic:default:t.storeValue&&t.storeValue.type===BI.DynamicYearQuarterCombo.Dynamic?t.dynamicPane.setValue(t.storeValue.value):t.dynamicPane.setValue({year:0}),t._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=(e=e||{}).type||BI.DynamicDateCombo.Static,i=e.value||e;switch(this.dateTab.setSelect(t),t){case BI.DynamicDateCombo.Dynamic:this.dynamicPane.setValue(i),this._setInnerValue();break;case BI.DynamicDateCombo.Static:default:this.year.setValue(i),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(i){var n=this,r=this.options,e=this._const,t=BI.createWidget({type:"bi.sign_editor",height:r.height,validationChecker:function(e){if(i)return""===e||BI.isPositiveInteger(e)&&!BI.checkDateVoid(e,parseInt(e,10)===BI.parseDateTime(r.min,"%Y-%X-%d").getFullYear()?BI.parseDateTime(r.min,"%Y-%X-%d").getMonth()+1:1,1,r.min,r.max)[0];var t=n.yearEditor.getValue();return""===e||BI.isPositiveInteger(e)&&1<=e&&e<=4&&(!!BI.isEmptyString(t)||!BI.checkDateVoid(n.yearEditor.getValue(),3*(e-1)+1,1,r.min,r.max)[0])},quitChecker:function(){return!1},errorText:function(e){return BI.i18nText("BI-Year_Trigger_Invalid_Text")},watermark:BI.i18nText("BI-Basic_Unrestricted"),hgap:e.hgap,vgap:e.vgap,title:"",allowBlank:!0});return t.on(BI.SignEditor.EVENT_KEY_DOWN,function(){n.fireEvent(BI.DynamicYearQuarterTrigger.EVENT_KEY_DOWN)}),t.on(BI.SignEditor.EVENT_FOCUS,function(){n.fireEvent(BI.DynamicYearQuarterTrigger.EVENT_FOCUS)}),t.on(BI.SignEditor.EVENT_STOP,function(){n.fireEvent(BI.DynamicYearQuarterTrigger.EVENT_STOP)}),t.on(BI.SignEditor.EVENT_CONFIRM,function(){n._doEditorConfirm(t),n.fireEvent(BI.DynamicYearQuarterTrigger.EVENT_CONFIRM)}),t.on(BI.SignEditor.EVENT_SPACE,function(){t.isValid()&&t.blur()}),t.on(BI.SignEditor.EVENT_START,function(){n.fireEvent(BI.DynamicYearQuarterTrigger.EVENT_START)}),t.on(BI.SignEditor.EVENT_ERROR,function(){n.fireEvent(BI.DynamicYearQuarterTrigger.EVENT_ERROR)}),t.on(BI.SignEditor.EVENT_VALID,function(){var e=n.yearEditor.getValue(),t=n.quarterEditor.getValue();BI.isNotEmptyString(e)&&BI.isNotEmptyString(t)&&BI.isPositiveInteger(e)&&1<=t&&t<=4&&!BI.checkDateVoid(e,3*(t-1)+1,1,r.min,r.max)[0]&&n.fireEvent(BI.DynamicYearMonthTrigger.EVENT_VALID)}),t.on(BI.SignEditor.EVENT_CHANGE,function(){i&&n._autoSwitch(t)}),t},_doEditorConfirm:function(e){var t=e.getValue();BI.isNotNull(t)&&e.setValue(t);var i=this.quarterEditor.getValue();this.storeValue={type:BI.DynamicYearQuarterCombo.Static,value:{year:this.yearEditor.getValue(),quarter:BI.isEmptyString(this.quarterEditor.getValue())?"":i}},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 i=BI.print(e,"%Y-%Q");this.yearEditor.setValue(e.getFullYear()),this.quarterEditor.setValue(BI.getQuarter(e)),this.setTitle(BI.isEmptyString(t)?i:t+":"+i)},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,i,n=BI.getDate();switch(this.storeValue=e,BI.isNotNull(e)&&(t=e.type||BI.DynamicYearQuarterCombo.Static,i=e.value||e),t){case BI.DynamicYearQuarterCombo.Dynamic:var r=this._getText(i),n=BI.DynamicDateHelper.getCalculation(i);this._setInnerValue(n,r);break;case BI.DynamicYearQuarterCombo.Static:default:i=i||{};var a=BI.isNull(i.quarter)?null:i.quarter;this.yearEditor.setValue(i.year),this.yearEditor.setTitle(i.year),this.quarterEditor.setValue(a),this.quarterEditor.setTitle(a),this.setTitle(this._getStaticTitle(i))}},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 t=this,e=this.options;return e.value=e.value||{},this.left=this._createCombo(e.value.start),this.right=this._createCombo(e.value.end),[{type:"bi.center",hgap:15,height:this.constants.height,items:[{type:"bi.absolute",items:[{el:t.left,left:this.constants.offset,right:0,top:0,bottom:0}]},{type:"bi.absolute",items:[{el:t.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(e){t.label=e}}]}]},_createCombo:function(e){var i=this,t=this.options,n=BI.createWidget({type:"bi.dynamic_year_quarter_combo",supportDynamic:t.supportDynamic,minDate:t.minDate,maxDate:t.maxDate,behaviors:t.behaviors,value:e,listeners:[{eventName:BI.DynamicYearQuarterCombo.EVENT_BEFORE_POPUPVIEW,action:function(){i.fireEvent(BI.YearQuarterInterval.EVENT_BEFORE_POPUPVIEW)}}]});return n.on(BI.DynamicYearQuarterCombo.EVENT_ERROR,function(){i._clearTitle(),BI.Bubbles.hide("error"),i.element.removeClass(i.constants.timeErrorCls),i.fireEvent(BI.YearQuarterInterval.EVENT_ERROR)}),n.on(BI.DynamicYearQuarterCombo.EVENT_VALID,function(){i._checkValid()}),n.on(BI.DynamicYearQuarterCombo.EVENT_FOCUS,function(){i._checkValid()}),n.on(BI.DynamicYearQuarterCombo.EVENT_CONFIRM,function(){BI.Bubbles.hide("error");var e=i.left.getKey(),t=i.right.getKey();i.left.isStateValid()&&i.right.isStateValid()&&i._check(e,t)&&i._compare(e,t)?(i._setTitle(BI.i18nText("BI-Time_Interval_Error_Text")),i.element.addClass(i.constants.timeErrorCls),i.fireEvent(BI.YearQuarterInterval.EVENT_ERROR)):(i._clearTitle(),i.element.removeClass(i.constants.timeErrorCls),i.fireEvent(BI.YearQuarterInterval.EVENT_CHANGE))}),n},_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 i=e.match(/\d+/g),n=t.match(/\d+/g),r="";BI.isNotNull(i)&&(r=(i[0]||"")+"-"+(i[1]||1));var a="";return BI.isNotNull(n)&&(a=(n[0]||"")+"-"+(n[1]||1)),this._dateCheck(r)&&BI.checkDateLegal(r)&&this._checkVoid({year:i[0],quarter:i[1]||1})&&this._dateCheck(a)&&BI.checkDateLegal(a)&&this._checkVoid({year:n[0],quarter:n[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)&&t<e},_setTitle:function(e){this.setTitle(e)},_clearTitle:function(){this.setTitle("")},_checkValid:function(){var e=this;BI.Bubbles.hide("error");var t=e.left.getKey(),i=e.right.getKey();e.left.isValid()&&e.right.isValid()&&e._check(t,i)&&e._compare(t,i)?(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(i){var n=i;return BI.isNotNull(this.items)&&BI.some(this.items,function(e,t){if(t.value===i||t.value+""===i)return n=t.text,!0}),n},_itemsCreator:function(t,a){var i=this,e=this.options;function n(n){var e=(t.keywords||[]).slice();t.keyword&&e.push(t.keyword);var i,r=n;BI.isNotEmptyArray(e)&&(r=[],BI.each(e,function(e,t){var i=BI.Func.getSearchResult(n,t);r=r.concat(i.match).concat(i.find)}),r=BI.uniq(r)),t.selectedValues&&(i=BI.makeObject(t.selectedValues,!0),r=BI.filter(r,function(e,t){return!i[t.value]})),t.type!==BI.MultiSelectCombo.REQ_GET_ALL_DATA?t.type!==BI.MultiSelectCombo.REQ_GET_DATA_LENGTH?a({items:r,hasNext:!1}):a({count:r.length}):a({items:r})}e.cache&&this.items?n(this.items):e.itemsCreator({},function(e){n(i.items=e)})},_assertValue:function(e){var t=e=e||{};return BI.isNotNull(this.items)&&0===BI.difference(BI.map(this.items,"value"),e.value).length&&(t={type:BI.Selection.All,value:[]}),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,i=this._digestValue(t.value);return{type:"bi.search_multi_text_value_combo",text:t.text,height:t.height,items:t.items,value:i,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 i=this.combo.getValue()||{};if(i.value=i.value||[],i.type!==BI.Selection.All)return i.value||[];var n=[];return BI.each(this.options.items,function(e,t){BI.contains(i.value,t.value)||n.push(t.value)}),n},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(i){var n=i;return BI.isNotNull(this.items)&&BI.some(this.items,function(e,t){if(t.value===i||t.value+""===i)return n=t.text,!0}),n},_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 i=this,n=this.options;function r(){switch(e.type){case BI.TreeView.REQ_TYPE_INIT_DATA:i._reqInitTreeNode(e,t);break;case BI.TreeView.REQ_TYPE_ADJUST_DATA:i._reqAdjustTreeNode(e,t);break;case BI.TreeView.REQ_TYPE_SELECT_DATA:i._reqSelectedTreeNode(e,t);break;case BI.TreeView.REQ_TYPE_GET_SELECTED_DATA:i._reqDisplayTreeNode(e,t);break;default:i._reqTreeNode(e,t)}}this.items?r():n.itemsCreator({},function(e){i._initData(e),r()})},_reqDisplayTreeNode:function(e,t){var o=this,n=[],i=e.selectedValues;function s(e,t){return null==e?0:BI.isEmpty(e)?o._getChildCount(t):BI.size(e)}function l(e,t,i){n.push({id:e.id,pId:t,text:e.text+(0<i?"("+BI.i18nText("BI-Basic_Altogether")+i+BI.i18nText("BI-Basic_Count")+")":""),value:e.value,open:!0})}null==i||BI.isEmpty(i)?t({}):(function u(r,a,n){if(null==n||BI.isEmpty(n))return void BI.each(a.getChildren(),function(e,t){var i=BI.clone(r);i.push(t.value);var n=o._getChildCount(i);l(t,a.id,n),u(i,t,{})});BI.each(n,function(e){var t,i=o._getTreeNode(r,e);BI.isNull(i)?l({id:BI.UUID(),text:e,value:e},BI.UUID(),0):((t=BI.clone(r)).push(i.value),l(i,i.parent&&i.parent.id,s(n[e],t)),u(t,i,n[e]))})}([],this.tree.getRoot(),i),t({items:n}))},_reqSelectedTreeNode:function(e,t){var p=this,i=BI.deepClone(e.selectedValues),a=e.notSelectedValue||{},l=e.keyword||"",o=e.parentValues||[];function s(o,s,l){var u=o,c=[],h=[];BI.some(s,function(i,e){var t=u[e];if(null==t){if(0===i)return!0;if(!BI.isEmpty(u))return!0;var n=s.slice(0,i),r=p._getChildren(n);if(h.push(n),c.push(r.length),i===s.length-1&&1===r.length&&r[0].value===l)for(var a=c.length-1;0<=a&&1===c[a];a--)p._deleteNode(o,h[a]);else BI.each(r,function(e,t){return i===s.length-1&&t.value===l||void(u[t.value]={})});u=u[e]}else u=t})}function u(e,t,n,i){var r=BI.clone(e);if(r.push(t),p._isMatch(e,t,l))return i&&i.push(r),!0;var a=p._getChildren(r),o=[],s=!1;return BI.each(a,function(e,t){u(r,t.value,n,i)?s=!0:o.push(t.value)}),!0===s&&BI.each(o,function(e,t){var i=BI.clone(r);i.push(t),n.push(i)}),s}function c(e){for(var t=0,i=e.length;t<i;t++)if(p._isMatch(e.slice(0,t),e[t],l))return 1}null==i||BI.isEmpty(i)?t({}):(function(i){var e=o.concat(a);{var t;!function(e,t){for(var i=e,n=0;n<t.length;n++){var r=t[n];if(null==(i=i[r]))return!1}return!0}(i,e)||(c(e)?p._deleteNode(i,e):(r=u(o,a,[],t=[]))&&BI.isNotEmptyArray(t)&&BI.each(t,function(e,t){p._getNode(i,t)?p._deleteNode(i,t):s(i,t,BI.last(t))}))}{var n,r;!function(e,t){for(var i=e,n=0;n<t.length;n++){var r=t[n];if(!BI.has(i,r))return!1;if(i=i[r],BI.isEmpty(i))return!0}return!1}(i,e)||(r=!(n=[]),c(e)?r=!0:(r=u(o,a,n),e=o),!0===r&&(s(i,e,a),0<n.length&&BI.each(n,function(e,t){p._buildTree(i,t)})))}}(i),t(i))},_reqAdjustTreeNode:function(e,t){var i,n=this,o=[],r=e.selectedValues;null==r||BI.isEmpty(r)?t({}):(BI.each(r,function(e,t){o.push([e])}),function s(i,r){if(null==i||BI.isEmpty(i))return!0;var a=!0;BI.each(i,function(e,t){var n=BI.clone(r);n.push(e),s(i[e],n)||(BI.each(i[e],function(e,t){var i=BI.clone(n);i.push(e),o.push(i)}),a=!1)});return a&&(e=i,t=r,BI.isEmpty(e)||n._getChildCount(t)===BI.size(e));var e,t}(r,[]),i={},BI.each(o,function(e,t){n._buildTree(i,t)}),t(i))},_reqInitTreeNode:function(l,e){var f=this,u=[],g=l.keyword||"",c=l.selectedValues,h=l.lastSearchValue||"",t=function(){var e=f._getChildren([]),t=e.length;if(""!==h){for(var i=0,n=t;i<n;i++)if(e[i].value===h){t=i+1;break}}else t=0;for(var r=[],a=t,n=e.length;a<n;a++){var o;if(r.length<f._const.perPage?o=m(1,[],e[a].value,!1,u):r.length===f._const.perPage&&(o=m(1,[],e[a].value,!1,[])),!0===o[0]&&r.push(e[a].value),r.length>f._const.perPage)break}{var s;1===l.times&&(s=f._getAddedValueNode([],c),u=BI.concat(BI.filter(s,function(e,t){var i=BI.Func.getSearchResult([t.text||t.value],g);return 0<i.find.length||0<i.match.length}),u))}return r}();function m(n,e,t,i,r){var a,o;if(f._isMatch(e,t,g))return I(e,t,!1,p=i||B(e,t),!i&&(a=t,null!=(o=E(e))?BI.any(o,function(e,t){if(e===a&&null!=t&&!BI.isEmpty(t))return!0}):null),!0,r),[!0,p];var s=BI.clone(e);s.push(t);var l,u,c=f._getChildren(s),h=!1,p=!1,d=i||(l=t,null!=(u=E(e))?BI.any(u,function(e,t){if(e===l&&null!=t&&BI.isEmpty(t))return!0}):null);return BI.each(c,function(e,t){var i=m(n+1,s,t.value,d,r);!0===i[1]&&(p=!0),!0===i[0]&&(h=!0)}),!0===h&&I(e,t,!0,p=d||B(e,t)&&p,!1,!1,r),[h,p]}function I(e,t,i,n,r,a,o){var s=f._getTreeNode(e,t);o.push({id:s.id,pId:s.pId,text:s.text,value:s.value,title:s.title,isParent:0<s.getChildrenLength(),open:i,checked:n,halfCheck:r,flag:a})}function B(e,t){var i=E(e);return null!=i&&BI.any(i,function(e){if(e===t)return!0})}function E(e){var i=c;return null==i?null:(BI.every(e,function(e,t){return null!=(i=i[t])}),i)}BI.nextTick(function(){e({hasNext:t.length>f._const.perPage,items:u,lastSearchValue:BI.last(t)})})},_reqTreeNode:function(e,t){for(var i,c=this,n=this.options,o=[],r=e.times,a=e.checkState||{},s=e.parentValues||[],l=e.selectedValues||{},u=f(s,l),h=this._getChildren(s),p=(r-1)*this._const.perPage;h[p]&&p<r*this._const.perPage;p++){var d=g(h[p].value,s,u,a);o.push({id:h[p].id,pId:h[p].pId,value:h[p].value,text:h[p].text,times:1,isParent:0<h[p].getChildrenLength(),checked:d[0],halfCheck:d[1],open:n.open})}function f(e,i){var n={},a=(e||[]).slice(0);return BI.each(e,function(e,t){a.push(t),i=i[t]||{}}),BI.each(i,function(e,t){var i,r=BI.concat(a,e);BI.isNull(t)?n[e]=[0,0]:BI.isEmpty(t)?n[e]=[2,0]:(i={},BI.each(t,function(e,t){(BI.isNull(t)||BI.isEmpty(t)||function n(t,i){if(BI.isEmpty(t))return!0;if(c._getChildCount(i)!==BI.size(t))return!1;return BI.every(t,function(e){return n(t[e],BI.concat(i,e))})}(t,BI.concat(r,[e])))&&(i[e]=!0)}),n[e]=[1,BI.size(i)])}),n}function g(e,t,i,n){var r,a,o=n.checked,s=n.half,l=!1,u=!1;return BI.has(i,e)&&(1===i[e][0]?((r=BI.clone(t)).push(e),0<(a=c._getChildCount(r))&&a!==i[e][1]&&(u=!0)):2===i[e][0]&&(l=!0)),[(o||u||l)&&(l||o)&&!s||BI.has(i,e),u]}n.open&&(i=[],BI.each(h,function(e,t){i=BI.concat(i,c._getAllChildren(s.concat([t.value])))}),BI.each(i,function(e,i){var t=f(i.parentValues,l),n={},r=BI.find(o,function(e,t){return t.id===i.pId});r&&(n.checked=!r.halfCheck&&r.checked,n.half=r.halfCheck);var a=g(i.value,i.parentValues,t,n);o.push({id:i.id,pId:i.pId,value:i.value,text:i.text,times:1,isParent:0<i.getChildrenLength(),checked:a[0],halfCheck:a[1],open:c.options.open})})),0===s.length&&1===r&&(o=BI.concat(c._getAddedValueNode(s,l),o)),BI.nextTick(function(){t({items:o,hasNext:h.length>r*c._const.perPage})})},_getAddedValueNode:function(e,t){var i=this._getChildren(e);return BI.map(BI.difference(BI.keys(t),BI.map(i,"value")),function(e,t){return{id:BI.UUID(),pId:0<i.length?i[0].pId:BI.UUID(),value:t,text:t,times:1,isParent:!1,checked:!0,halfCheck:!1}})},_getNode:function(e,t){for(var i=e,n=0,r=t.length;n<r;n++){if(null==i)return null;i=i[t[n]]}return i},_deleteNode:function(e,t){var i=t[t.length-1],n=t.slice(0,t.length-1),r=this._getNode(e,n);if(null!=r&&r[i])for(delete r[i];0<n.length&&BI.isEmpty(r);)i=n[n.length-1],n=n.slice(0,n.length-1),null!=(r=this._getNode(e,n))&&delete r[i]},_buildTree:function(e,t){var i=e;BI.each(t,function(e,t){BI.has(i,t)||(i[t]={}),i=i[t]})},_isMatch:function(e,t,i){var n=this.options,r=this._getTreeNode(e,t);if(!r)return!1;var a=BI.Func.getSearchResult([r.text||r.value],i);if(n.allowSearchValue&&r.value){var o=BI.Func.getSearchResult([r.value],i);return 0<o.find.length||0<o.match.length||0<a.find.length||0<a.match.length}return 0<a.find.length||0<a.match.length},_getTreeNode:function(t,i){var n,r=this,a=0,o=this.tree.getRoot();return this.tree.traverse(function(e){if(!r.tree.isRoot(e)){if(a>t.length)return!1;if(a!==t.length||e.value!==i)return e.value!==t[a]||e.getParent()!==o||(a++,void(o=e));if(e.getParent()!==o)return;return n=e,!1}}),n},_getChildren:function(e){var t,i;return(i=0<e.length?(t=BI.last(e),this._getTreeNode(e.slice(0,e.length-1),t)):this.tree.getRoot())?i.getChildren():[]},_getAllChildren:function(i){var e=this._getChildren(i),t=[].concat(e);BI.each(t,function(e,t){t.parentValues=i});for(var n=BI.map(e,function(e,t){return{parentValues:i,value:t.value}});BI.isNotEmptyArray(n);){var r=n.shift(),a=r.parentValues.concat(r.value),o=this._getChildren(a);BI.each(o,function(e,t){t.parentValues=a}),n=n.concat(o),t=t.concat(o)}return t},_getChildCount:function(e){return this._getChildren(e).length},buildCompleteTree:function(e){var o=this,t={};return null===e||BI.isEmpty(e)||function s(n,e,r,a){if(null===r||BI.isEmpty(r))return void BI.each(e.getChildren(),function(e,t){var i=BI.clone(n);i.push(t.value),a[t.value]={},s(i,t,null,a[t.value])});BI.each(r,function(e){var t=o._getTreeNode(n,e),i=BI.clone(n);i.push(t.value),a[e]={},s(i,t,r[e],a[e])})}([],this.tree.getRoot(),e,t),t}})},function(e,t){BI.AbstractListTreeValueChooser=BI.inherit(BI.AbstractTreeValueChooser,{_reqDisplayTreeNode:function(e,t){var i,a=this,o={},n=e.selectedValues;function s(e,t){o[e.id]={id:e.id,pId:t,text:e.text,value:e.value,open:!0,isLeaf:e.isLeaf}}null==n||BI.isEmpty(n)?t({}):(this.tree.getRoot(),i=n,BI.each(i,function(e,r){BI.each(r,function(e,t){var i=t,n=a._getTreeNode(r.slice(0,e),i);BI.isNull(n)?s({id:BI.UUID(),text:i,value:i,isLeaf:!0},BI.UUID()):(BI.has(o,n.id)||s(n,n.parent&&n.parent.id),!0!==o[n.id].isLeaf&&(o[n.id].isLeaf=e===r.length-1))})}),t({items:BI.values(o)}))},_reqInitTreeNode:function(l,e){var u=this,c=[],h=l.keyword||"",p=l.selectedValues,d=l.lastSearchValue||"",t=function(){var e=u._getChildren([]),t=e.length;if(""!==d){for(var i=0,n=t;i<n;i++)if(e[i].value===d){t=i+1;break}}else t=0;for(var r=[],a=t,n=e.length;a<n;a++){var o;if(r.length<u._const.perPage?o=f(1,[],e[a].value,c):r.length===u._const.perPage&&(o=f(1,[],e[a].value,[])),!0===o[0]&&r.push(e[a].value),r.length>u._const.perPage)break}{var s;1===l.times&&(s=u._getAddedValueNode([],p),c=BI.concat(BI.filter(s,function(e,t){var i=BI.Func.getSearchResult([t.text||t.value],h);return 0<i.find.length||0<i.match.length}),c))}return r}();function f(n,e,t,r){if(u._isMatch(e,t,h))return g(e,t,!1,s=m(e,t),!0,r),[!0,s];var a=BI.clone(e);a.push(t);var i=u._getChildren(a),o=!1,s=!1;return BI.each(i,function(e,t){var i=f(n+1,a,t.value,r);!0===i[1]&&(s=!0),!0===i[0]&&(o=!0)}),!0===o&&g(e,t,!0,s=m(e,t),!1,r),[o,s]}function g(e,t,i,n,r,a){var o=u._getTreeNode(e,t);a.push({id:o.id,pId:o.pId,text:o.text,value:o.value,title:o.title,isParent:0<o.getChildrenLength(),open:i,checked:n,halfCheck:!1,flag:r})}function m(i,n){return BI.any(p,function(e,t){return BI.isEqual(i,t.slice(0,i.length))&&BI.last(t)===n})}BI.nextTick(function(){e({hasNext:t.length>u._const.perPage,items:c,lastSearchValue:BI.last(t)})})},_reqTreeNode:function(e,t){for(var i,n=this,r=this.options,a=[],o=e.times,s=e.parentValues||[],l=e.selectedValues||[],u=d(s,l),c=this._getChildren(s),h=(o-1)*this._const.perPage;c[h]&&h<o*this._const.perPage;h++){var p=BI.has(u,c[h].value);a.push({id:c[h].id,pId:c[h].pId,value:c[h].value,text:c[h].text,times:1,isParent:0<c[h].getChildrenLength(),checked:p,halfCheck:!1,open:r.open})}function d(i,e){var n={};return BI.each(e,function(e,t){BI.isEqual(i,t.slice(0,i.length))&&(n[BI.last(t)]=[2,0])}),n}r.open&&(i=[],BI.each(c,function(e,t){i=BI.concat(i,n._getAllChildren(s.concat([t.value])))}),BI.each(i,function(e,t){var i=d(t.parentValues,l),n=BI.has(i,t.value);a.push({id:t.id,pId:t.pId,value:t.value,text:t.text,times:1,isParent:0<t.getChildrenLength(),checked:n,halfCheck:!1,open:r.open})})),0===s.length&&1===o&&(a=BI.concat(n._getAddedValueNode(s,l),a)),BI.nextTick(function(){t({items:a,hasNext:c.length>o*n._const.perPage})})},_getAddedValueNode:function(e,t){var i=this._getChildren(e),n=BI.flatten(BI.filter(t,function(e,t){return 1===t.length}));return BI.map(BI.difference(n,BI.map(i,"value")),function(e,t){return{id:BI.UUID(),pId:0<i.length?i[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 t=this,e=this.options;BI.isNotNull(e.items)&&this._initData(e.items),this.combo=BI.createWidget({type:"bi.multi_tree_list_combo",isNeedAdjustWidth:e.isNeedAdjustWidth,element:this,text:e.text,value:e.value,watermark:e.watermark,allowInsertValue:e.allowInsertValue,allowEdit:e.allowEdit,itemsCreator:BI.bind(this._itemsCreator,this),valueFormatter:BI.bind(this._valueFormatter,this),width:e.width,height:e.height,listeners:[{eventName:BI.MultiTreeListCombo.EVENT_FOCUS,action:function(){t.fireEvent(BI.ListTreeValueChooserInsertCombo.EVENT_FOCUS)}},{eventName:BI.MultiTreeListCombo.EVENT_BLUR,action:function(){t.fireEvent(BI.ListTreeValueChooserInsertCombo.EVENT_BLUR)}},{eventName:BI.MultiTreeListCombo.EVENT_STOP,action:function(){t.fireEvent(BI.ListTreeValueChooserInsertCombo.EVENT_STOP)}},{eventName:BI.MultiTreeListCombo.EVENT_CLICK_ITEM,action:function(e){t.fireEvent(BI.ListTreeValueChooserInsertCombo.EVENT_CLICK_ITEM,e)}},{eventName:BI.MultiTreeListCombo.EVENT_SEARCHING,action:function(){t.fireEvent(BI.ListTreeValueChooserInsertCombo.EVENT_SEARCHING)}},{eventName:BI.MultiTreeListCombo.EVENT_CONFIRM,action:function(){t.fireEvent(BI.ListTreeValueChooserInsertCombo.EVENT_CONFIRM)}},{eventName:BI.MultiTreeCombo.EVENT_BEFORE_POPUPVIEW,action:function(){t.fireEvent(BI.TreeValueChooserInsertCombo.EVENT_BEFORE_POPUPVIEW)}}]})},showView:function(){this.combo.showView()},hideView:function(){this.combo.hideView()},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 t=this,e=this.options;BI.isNotNull(e.items)&&this._initData(e.items),this.combo=BI.createWidget({type:"bi.multi_tree_insert_combo",isNeedAdjustWidth:e.isNeedAdjustWidth,allowEdit:e.allowEdit,text:e.text,value:e.value,watermark:e.watermark,element:this,itemsCreator:BI.bind(this._itemsCreator,this),valueFormatter:BI.bind(this._valueFormatter,this),width:e.width,height:e.height,listeners:[{eventName:BI.MultiTreeInsertCombo.EVENT_FOCUS,action:function(){t.fireEvent(BI.TreeValueChooserCombo.EVENT_FOCUS)}},{eventName:BI.MultiTreeInsertCombo.EVENT_BLUR,action:function(){t.fireEvent(BI.TreeValueChooserCombo.EVENT_BLUR)}},{eventName:BI.MultiTreeInsertCombo.EVENT_STOP,action:function(){t.fireEvent(BI.TreeValueChooserInsertCombo.EVENT_STOP)}},{eventName:BI.MultiTreeInsertCombo.EVENT_CLICK_ITEM,action:function(e){t.fireEvent(BI.TreeValueChooserInsertCombo.EVENT_CLICK_ITEM,e)}},{eventName:BI.MultiTreeInsertCombo.EVENT_SEARCHING,action:function(){t.fireEvent(BI.TreeValueChooserInsertCombo.EVENT_SEARCHING)}},{eventName:BI.MultiTreeInsertCombo.EVENT_CONFIRM,action:function(){t.fireEvent(BI.TreeValueChooserInsertCombo.EVENT_CONFIRM)}},{eventName:BI.MultiTreeCombo.EVENT_BEFORE_POPUPVIEW,action:function(){t.fireEvent(BI.TreeValueChooserInsertCombo.EVENT_BEFORE_POPUPVIEW)}}]})},showView:function(){this.combo.showView()},hideView:function(){this.combo.hideView()},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 t=this,e=this.options;BI.isNotNull(e.items)&&this._initData(e.items),this.combo=BI.createWidget({type:"bi.multi_tree_combo",text:e.text,allowEdit:e.allowEdit,value:e.value,watermark:e.watermark,element:this,itemsCreator:BI.bind(this._itemsCreator,this),valueFormatter:BI.bind(this._valueFormatter,this),width:e.width,height:e.height,isNeedAdjustWidth:e.isNeedAdjustWidth,listeners:[{eventName:BI.MultiTreeCombo.EVENT_FOCUS,action:function(){t.fireEvent(BI.TreeValueChooserCombo.EVENT_FOCUS)}},{eventName:BI.MultiTreeCombo.EVENT_BLUR,action:function(){t.fireEvent(BI.TreeValueChooserCombo.EVENT_BLUR)}},{eventName:BI.MultiTreeCombo.EVENT_STOP,action:function(){t.fireEvent(BI.TreeValueChooserCombo.EVENT_STOP)}},{eventName:BI.MultiTreeCombo.EVENT_CLICK_ITEM,action:function(e){t.fireEvent(BI.TreeValueChooserCombo.EVENT_CLICK_ITEM,e)}},{eventName:BI.MultiTreeCombo.EVENT_SEARCHING,action:function(){t.fireEvent(BI.TreeValueChooserCombo.EVENT_SEARCHING)}},{eventName:BI.MultiTreeCombo.EVENT_CONFIRM,action:function(){t.fireEvent(BI.TreeValueChooserCombo.EVENT_CONFIRM)}},{eventName:BI.MultiTreeCombo.EVENT_BEFORE_POPUPVIEW,action:function(){t.fireEvent(BI.TreeValueChooserCombo.EVENT_BEFORE_POPUPVIEW)}}]})},showView:function(){this.combo.showView()},hideView:function(){this.combo.hideView()},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(i){var n=i;return BI.isNotNull(this.items)&&BI.some(this.items,function(e,t){if(t.value===i||t.value+""===i)return n=t.text,!0}),n},_getItemsByTimes:function(e,t){for(var i=[],n=(t-1)*this._const.perPage;e[n]&&n<t*this._const.perPage;n++)i.push(e[n]);return i},_hasNextByTimes:function(e,t){return t*this._const.perPage<e.length},_itemsCreator:function(t,a){var o=this,e=this.options;function i(n){var i,e=(t.keywords||[]).slice(),r=n;BI.isNotEmptyArray(e)&&(r=[],BI.each(e,function(e,t){var i=BI.Func.getSearchResult(n,t);r=r.concat(i.match).concat(i.find)}),r=BI.uniq(r)),t.selectedValues&&(i=BI.makeObject(t.selectedValues,!0),r=BI.filter(r,function(e,t){return!i[t.value]})),t.type!==BI.MultiSelectCombo.REQ_GET_ALL_DATA?t.type!==BI.MultiSelectCombo.REQ_GET_DATA_LENGTH?a({items:o._getItemsByTimes(r,t.times),hasNext:o._hasNextByTimes(r,t.times)}):a({count:r.length}):a({items:r})}e.cache&&this.items?i(this.items):e.itemsCreator({},function(e){i(o.items=e)})},_assertValue:function(e){var t=e=e||{};return 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:[]}),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 t=this,e=this.options;return BI.isNotNull(e.items)&&(this.items=e.items),{type:"bi.multi_select_no_bar_combo",allowEdit:e.allowEdit,text:e.text,value:this._assertValue(e.value),itemsCreator:BI.bind(this._itemsCreator,this),valueFormatter:BI.bind(this._valueFormatter,this),width:e.width,height:e.height,ref:function(e){t.combo=e},listeners:[{eventName:BI.MultiSelectCombo.EVENT_FOCUS,action:function(){t.fireEvent(BI.ValueChooserNoBarCombo.EVENT_FOCUS)}},{eventName:BI.MultiSelectCombo.EVENT_BLUR,action:function(){t.fireEvent(BI.ValueChooserNoBarCombo.EVENT_BLUR)}},{eventName:BI.MultiSelectCombo.EVENT_STOP,action:function(){t.fireEvent(BI.ValueChooserNoBarCombo.EVENT_STOP)}},{eventName:BI.MultiSelectCombo.EVENT_CLICK_ITEM,action:function(){t.fireEvent(BI.ValueChooserNoBarCombo.EVENT_CLICK_ITEM)}},{eventName:BI.MultiSelectCombo.EVENT_SEARCHING,action:function(){t.fireEvent(BI.ValueChooserNoBarCombo.EVENT_SEARCHING)}},{eventName:BI.MultiSelectCombo.EVENT_CONFIRM,action:function(){t.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,i){"use strict";var n,r=(n=i(705))&&n.__esModule?n:{"default":n};BI.extend(BI,r["default"])},function(e,t,i){"use strict";function o(e){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function o(t){return typeof t}:function o(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},o(e)}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"Combo",{enumerable:!0,get:function(){return n.Combo}}),Object.defineProperty(t,"ButtonGroup",{enumerable:!0,get:function(){return r.ButtonGroup}}),Object.defineProperty(t,"Tab",{enumerable:!0,get:function(){return a.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 E.Single}}),Object.defineProperty(t,"Text",{enumerable:!0,get:function(){return _.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 P.ShowAction}}),Object.defineProperty(t,"Behavior",{enumerable:!0,get:function(){return M.Behavior}}),Object.defineProperty(t,"BehaviorFactory",{enumerable:!0,get:function(){return M.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 ie.TextEditor}}),Object.defineProperty(t,"IconLabel",{enumerable:!0,get:function(){return ne.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 Ee.VerticalAdaptLayout}}),Object.defineProperty(t,"MultiSelectInsertCombo",{enumerable:!0,get:function(){return _e.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 Pe.TextAreaEditor}}),Object.defineProperty(t,"SingleSelectItem",{enumerable:!0,get:function(){return Me.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,"TreeView",{enumerable:!0,get:function(){return ze.TreeView}}),Object.defineProperty(t,"MultiTreePopup",{enumerable:!0,get:function(){return Qe.MultiTreePopup}}),Object.defineProperty(t,"SingleSelectRadioItem",{enumerable:!0,get:function(){return qe.SingleSelectRadioItem}}),Object.defineProperty(t,"SingleSelectInsertCombo",{enumerable:!0,get:function(){return $e.SingleSelectInsertCombo}}),Object.defineProperty(t,"SingleSelectCombo",{enumerable:!0,get:function(){return et.SingleSelectCombo}}),Object.defineProperty(t,"CardLayout",{enumerable:!0,get:function(){return tt.CardLayout}}),Object.defineProperty(t,"DynamicYearMonthCombo",{enumerable:!0,get:function(){return it.DynamicYearMonthCombo}}),Object.defineProperty(t,"TimeCombo",{enumerable:!0,get:function(){return nt.TimeCombo}}),Object.defineProperty(t,"ListTreeView",{enumerable:!0,get:function(){return rt.ListTreeView}}),Object.defineProperty(t,"ListAsyncTree",{enumerable:!0,get:function(){return at.ListAsyncTree}}),Object.defineProperty(t,"AsyncTree",{enumerable:!0,get:function(){return ot.AsyncTree}}),Object.defineProperty(t,"MultiLayerSingleTreeCombo",{enumerable:!0,get:function(){return st.MultiLayerSingleTreeCombo}}),Object.defineProperty(t,"MultiLayerSelectTreeCombo",{enumerable:!0,get:function(){return lt.MultiLayerSelectTreeCombo}}),Object.defineProperty(t,"MultiTreeListCombo",{enumerable:!0,get:function(){return ut.MultiTreeListCombo}}),Object.defineProperty(t,"MultiTreeInsertCombo",{enumerable:!0,get:function(){return ct.MultiTreeInsertCombo}}),Object.defineProperty(t,"TextValueDownListCombo",{enumerable:!0,get:function(){return ht.TextValueDownListCombo}}),Object.defineProperty(t,"Switch",{enumerable:!0,get:function(){return pt.Switch}}),Object.defineProperty(t,"HorizontalLayout",{enumerable:!0,get:function(){return dt.HorizontalLayout}}),Object.defineProperty(t,"ShelterEditor",{enumerable:!0,get:function(){return ft.ShelterEditor}}),Object.defineProperty(t,"TextTrigger",{enumerable:!0,get:function(){return gt.TextTrigger}}),Object.defineProperty(t,"SelectTextTrigger",{enumerable:!0,get:function(){return mt.SelectTextTrigger}}),Object.defineProperty(t,"DateInterval",{enumerable:!0,get:function(){return It.DateInterval}}),Object.defineProperty(t,"DynamicDatePane",{enumerable:!0,get:function(){return Bt.DynamicDatePane}}),Object.defineProperty(t,"AllCountPager",{enumerable:!0,get:function(){return Et.AllCountPager}}),Object.defineProperty(t,"PopupView",{enumerable:!0,get:function(){return _t.PopupView}}),Object.defineProperty(t,"BubblePopupView",{enumerable:!0,get:function(){return bt.BubblePopupView}}),Object.defineProperty(t,"BubblePopupBarView",{enumerable:!0,get:function(){return bt.BubblePopupBarView}}),Object.defineProperty(t,"TextBubblePopupBarView",{enumerable:!0,get:function(){return bt.TextBubblePopupBarView}}),Object.defineProperty(t,"ArrowTreeGroupNodeCheckbox",{enumerable:!0,get:function(){return yt.ArrowTreeGroupNodeCheckbox}}),Object.defineProperty(t,"NumberInterval",{enumerable:!0,get:function(){return vt.NumberInterval}}),Object.defineProperty(t,"DynamicYearQuarterCombo",{enumerable:!0,get:function(){return Tt.DynamicYearQuarterCombo}}),Object.defineProperty(t,"DynamicYearCombo",{enumerable:!0,get:function(){return Ct.DynamicYearCombo}}),Object.defineProperty(t,"IntervalSlider",{enumerable:!0,get:function(){return Nt.IntervalSlider}}),Object.defineProperty(t,"MultiSelectInsertList",{enumerable:!0,get:function(){return Vt.MultiSelectInsertList}}),Object.defineProperty(t,"YearMonthInterval",{enumerable:!0,get:function(){return St.YearMonthInterval}}),Object.defineProperty(t,"NumberEditor",{enumerable:!0,get:function(){return xt.NumberEditor}}),Object.defineProperty(t,"TextValueCheckCombo",{enumerable:!0,get:function(){return wt.TextValueCheckCombo}}),Object.defineProperty(t,"LinearSegment",{enumerable:!0,get:function(){return At.LinearSegment}}),Object.defineProperty(t,"Img",{enumerable:!0,get:function(){return Lt.Img}}),Object.defineProperty(t,"EditorIconCheckCombo",{enumerable:!0,get:function(){return kt.EditorIconCheckCombo}}),Object.defineProperty(t,"IconTextValueCombo",{enumerable:!0,get:function(){return Dt.IconTextValueCombo}}),Object.defineProperty(t,"ListView",{enumerable:!0,get:function(){return Pt.ListView}}),Object.defineProperty(t,"FloatCenterLayout",{enumerable:!0,get:function(){return Mt.FloatCenterLayout}}),Object.defineProperty(t,"DynamicYearMonthPopup",{enumerable:!0,get:function(){return Rt.DynamicYearMonthPopup}}),Object.defineProperty(t,"Controller",{enumerable:!0,get:function(){return Ht.Controller}}),Object.defineProperty(t,"LayerController",{enumerable:!0,get:function(){return Ot.LayerController}}),Object.defineProperty(t,"DateCalendarPopup",{enumerable:!0,get:function(){return Ft.DateCalendarPopup}}),Object.defineProperty(t,"Tree",{enumerable:!0,get:function(){return Yt.Tree}}),Object.defineProperty(t,"Node",{enumerable:!0,get:function(){return Yt.Node}}),Object.defineProperty(t,"TextNode",{enumerable:!0,get:function(){return Wt.TextNode}}),Object.defineProperty(t,"TextValueCheckComboPopup",{enumerable:!0,get:function(){return Gt.TextValueCheckComboPopup}}),Object.defineProperty(t,"ImageButton",{enumerable:!0,get:function(){return jt.ImageButton}}),Object.defineProperty(t,"History",{enumerable:!0,get:function(){return Zt.History}}),Object.defineProperty(t,"Router",{enumerable:!0,get:function(){return Zt.Router}}),Object.defineProperty(t,"DateTimeCombo",{enumerable:!0,get:function(){return Xt.DateTimeCombo}}),Object.defineProperty(t,"FloatHorizontalLayout",{enumerable:!0,get:function(){return Ut.FloatHorizontalLayout}}),Object.defineProperty(t,"AdaptiveLayout",{enumerable:!0,get:function(){return Jt.AdaptiveLayout}}),Object.defineProperty(t,"HexColorChooserPopup",{enumerable:!0,get:function(){return Kt.HexColorChooserPopup}}),Object.defineProperty(t,"BlankIconTextItem",{enumerable:!0,get:function(){return zt.BlankIconTextItem}}),Object.defineProperty(t,"BroadcastController",{enumerable:!0,get:function(){return Qt.BroadcastController}}),Object.defineProperty(t,"Pager",{enumerable:!0,get:function(){return qt.Pager}}),Object.defineProperty(t,"TimeInterval",{enumerable:!0,get:function(){return $t.TimeInterval}}),Object.defineProperty(t,"DynamicDateTimePane",{enumerable:!0,get:function(){return ei.DynamicDateTimePane}}),Object.defineProperty(t,"SingleSelectInsertList",{enumerable:!0,get:function(){return ti.SingleSelectInsertList}}),Object.defineProperty(t,"MultiSelectTree",{enumerable:!0,get:function(){return ii.MultiSelectTree}}),Object.defineProperty(t,"HtmlLabel",{enumerable:!0,get:function(){return ni.HtmlLabel}}),t["default"]=void 0;var n=i(706),r=i(68),a=i(707),s=i(16),l=i(4),u=i(46),c=i(708),h=i(709),p=i(710),d=i(711),f=i(712),g=i(713),m=i(714),I=i(47),B=i(715),E=i(2),_=i(69),b=i(48),y=i(716),v=i(717),T=i(718),C=i(719),N=i(720),V=i(721),S=i(722),x=i(723),w=i(724),A=i(725),L=i(33),k=i(70),D=i(71),P=i(726),M=i(49),R=i(727),H=i(728),O=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==o(e)&&"function"!=typeof e)return{"default":e};var t=ri();if(t&&t.has(e))return t.get(e);var i={},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e){var a;Object.prototype.hasOwnProperty.call(e,r)&&((a=n?Object.getOwnPropertyDescriptor(e,r):null)&&(a.get||a.set)?Object.defineProperty(i,r,a):i[r]=e[r])}i["default"]=e,t&&t.set(e,i);return i}(i(729)),F=i(29),Y=i(1),W=i(3),G=i(730),j=i(731),Z=i(732),X=i(733),U=i(734),J=i(735),K=i(736),z=i(737),Q=i(738),q=i(739),$=i(740),ee=i(741),te=i(50),ie=i(72),ne=i(742),re=i(743),ae=i(744),oe=i(745),se=i(746),le=i(747),ue=i(748),ce=i(749),he=i(750),pe=i(751),de=i(752),fe=i(753),ge=i(754),me=i(755),Ie=i(756),Be=i(757),Ee=i(758),_e=i(759),be=i(760),ye=i(761),ve=i(762),Te=i(763),Ce=i(764),Ne=i(765),Ve=i(766),Se=i(767),xe=i(768),we=i(769),Ae=i(770),Le=i(771),ke=i(73),De=i(772),Pe=i(773),Me=i(774),Re=i(775),He=i(776),Oe=i(777),Fe=i(778),Ye=i(779),We=i(780),Ge=i(781),je=i(782),Ze=i(783),Xe=i(784),Ue=i(785),Je=i(786),Ke=i(787),ze=i(52),Qe=i(788),qe=i(789),$e=i(790),et=i(791),tt=i(792),it=i(793),nt=i(794),rt=i(74),at=i(795),ot=i(796),st=i(797),lt=i(798),ut=i(799),ct=i(800),ht=i(801),pt=i(802),dt=i(803),ft=i(804),gt=i(805),mt=i(806),It=i(807),Bt=i(808),Et=i(809),_t=i(51),bt=i(810),yt=i(811),vt=i(812),Tt=i(813),Ct=i(814),Nt=i(815),Vt=i(816),St=i(817),xt=i(818),wt=i(819),At=i(820),Lt=i(821),kt=i(822),Dt=i(823),Pt=i(824),Mt=i(825),Rt=i(826),Ht=i(53),Ot=i(827),Ft=i(828),Yt=i(829),Wt=i(830),Gt=i(831),jt=i(832),Zt=i(833),Xt=i(834),Ut=i(835),Jt=i(836),Kt=i(837),zt=i(838),Qt=i(839),qt=i(840),$t=i(841),ei=i(842),ti=i(843),ii=i(844),ni=i(845);function ri(){if("function"!=typeof WeakMap)return null;var t=new WeakMap;return ri=function ri(){return t},t}var ai={Decorators:O};t["default"]=ai},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(47)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(16)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(71)},function(e,t,i){"use strict";i(49)},function(e,t,i){"use strict";i(49)},function(e,t,i){"use strict";function o(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function s(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function l(e,t){e.prototype=Object.create(t.prototype),function(e,t){for(var i=Object.getOwnPropertyNames(t),n=0;n<i.length;n++){var r=i[n],a=Object.getOwnPropertyDescriptor(t,r);a&&a.configurable&&e[r]===undefined&&Object.defineProperty(e,r,a)}}(e.prototype.constructor=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(i){var n=1<arguments.length&&arguments[1]!==undefined?arguments[1]:{};return function(e){return function(e){function t(){return e.apply(this,arguments)||this}return l(t,e),t.prototype._store=function(){var e=n.props?n.props.apply(this):undefined;return BI.Models.getModel(i.xtype,e)},t}(e)}},t.mixin=function(){return function(t){var i={};Object.getOwnPropertyNames(t.prototype).forEach(function(e){"constructor"!==e&&(i[e]=t.prototype[e])}),Fix.mixin(t.xtype,i)}},t.mixins=function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];return function(e){var a=[];return t.forEach(function(e){e.xtype&&a.push(e.xtype)}),function(r){function e(){for(var e,t=arguments.length,i=new Array(t),n=0;n<t;n++)i[n]=arguments[n];return s(o(e=r.call.apply(r,[this].concat(i))||this),"mixins",a),e}return l(e,r),e}(e)}},t.Model=void 0;var n=function(r){function e(){for(var e,t=arguments.length,i=new Array(t),n=0;n<t;n++)i[n]=arguments[n];return s(o(e=r.call.apply(r,[this].concat(i))||this),"model",void 0),s(o(e),"store",void 0),s(o(e),"context",void 0),s(o(e),"actions",void 0),s(o(e),"childContext",void 0),s(o(e),"TYPE",void 0),s(o(e),"computed",void 0),e}return l(e,r),e.prototype.state=function(){return{}},e}(Fix.Model);t.Model=n},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(68)},function(e,t,i){"use strict";i(46)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(72)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(16)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(69)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(16)},function(e,t,i){"use strict";i(51)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(73)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(50)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(70)},function(e,t,i){"use strict";i(33)},function(e,t,i){"use strict";i(33)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(16)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(74)},function(e,t,i){"use strict";i(52)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(48)},function(e,t,i){"use strict";i(48)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(51),i(1)},function(e,t,i){"use strict";i(50)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(53)},function(e,t,i){"use strict";i(1)},function(e,t,i){},function(e,t,i){"use strict";i(46)},function(e,t,i){"use strict";i(16)},function(e,t,i){"use strict";i(4)},function(e,t,i){},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(3)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(4)},function(e,t,i){"use strict";i(53)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(1)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(2)},function(e,t,i){"use strict";i(47)},function(e,t,i){e.exports=i(60)},function(e,t,i){},function(e,t,i){},function(e,t){BI.prepares.push(function(){var e,r=function(){return null==e&&(e=!(!BI.isSupportCss3||!BI.isSupportCss3("flex"))),e};BI.Plugin.configWidget("bi.horizontal",function(e){return r()?BI.extend({},e,{type:"bi.flex_horizontal"}):BI.extend({scrollx:!0},e,{type:"bi.inline"})}),BI.Plugin.configWidget("bi.center_adapt",function(e){var t=r();e.items&&e.items.length;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){var t=r();e.items&&e.items.length;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 t=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)&&t)return BI.extend({},e,{type:"bi.horizontal_auto"});var n=r();return!i&&n?BI.extend({horizontalAlign:BI.HorizontalAlign.Center},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 r()?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 r()?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)&&(0<e.hgap||0<e.rgap))return BI.extend({},e,{type:"bi.flex_scrollable_horizontal"})}),BI.Plugin.configWidget("bi.flex_vertical",function(e){if((!0===e.scrollable||!0===e.scrollx)&&(0<e.hgap||0<e.rgap))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 t,i,a=_global.document&&_global.document.attachEvent,o=!1;if(_global.document&&!a){var e=(i=_global.requestAnimationFrame||_global.mozRequestAnimationFrame||_global.webkitRequestAnimationFrame||function(e){return _global.setTimeout(e,20)},function(e){return i(e)}),n=(t=_global.cancelAnimationFrame||_global.mozCancelAnimationFrame||_global.webkitCancelAnimationFrame||_global.clearTimeout,function(e){return t(e)}),s=function(e){var t=e.__resizeTriggers__,i=t.firstElementChild,n=t.lastElementChild,r=i.firstElementChild;n.scrollLeft=n.scrollWidth,n.scrollTop=n.scrollHeight,r.style.width=i.offsetWidth+1+"px",r.style.height=i.offsetHeight+1+"px",i.scrollLeft=i.scrollWidth,i.scrollTop=i.scrollHeight},l=function(t){var i=this;s(this),this.__resizeRAF__&&n(this.__resizeRAF__),this.__resizeRAF__=e(function(){var e;(e=i).offsetWidth===e.__resizeLast__.width&&e.offsetHeight===e.__resizeLast__.height||(i.__resizeLast__.width=i.offsetWidth,i.__resizeLast__.height=i.offsetHeight,i.__resizeListeners__.forEach(function(e){e.call(i,t)}))})},r=!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&&(r=!0),!1===r)for(var g=0;g<h.length;g++)if(f.style[h[g]+"AnimationName"]!==undefined){d=h[g],u="-"+d.toLowerCase()+"-",c=p[g],r=!0;break}var m="resizeanim",I="@"+u+"keyframes "+m+" { from { opacity: 0; } to { opacity: 0; } } ",B=u+"animation: 1ms "+m+"; "}var E=function(t,e){var i,n,r;a?(t.attachEvent("onresize",e),BI.nextTick(e)):(t.__resizeTriggers__||("static"===getComputedStyle(t).position&&(t.style.position="relative"),o||(i=(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%; }',n=document.head||document.getElementsByTagName("head")[0],(r=document.createElement("style")).type="text/css",r.styleSheet?r.styleSheet.cssText=i:r.appendChild(document.createTextNode(i)),n.appendChild(r),o=!0),t.__resizeLast__={},t.__resizeListeners__=[],(t.__resizeTriggers__=document.createElement("div")).className="resize-triggers",t.__resizeTriggers__.innerHTML='<div class="expand-trigger"><div></div></div><div class="contract-trigger"></div>',t.appendChild(t.__resizeTriggers__),s(t),t.addEventListener("scroll",l,!0),c&&t.__resizeTriggers__.addEventListener(c,function(e){e.animationName===m&&s(t)})),t.__resizeListeners__.push(e))},_=function(e,t){a?e.detachEvent("onresize",t):(e.__resizeListeners__.splice(e.__resizeListeners__.indexOf(t),1),e.__resizeListeners__.length||(e.removeEventListener("scroll",l),e.__resizeTriggers__=!e.removeChild(e.__resizeTriggers__)))};BI.ResizeDetector={addResizeListener:function(e,t){return E(e.element[0],t),function(){_(e.element[0],t)}},removeResizeListener:function(e,t){_(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,n){var t=BI.jQuery._data(e[0]).events;BI.each(t,function(i,e){BI.each(e,function(e,t){n.on(i+(t.namespace?"."+t.namespace:""),t)})});var i=e.children(),r=n.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,t){t.element=n})},hang:function(e){if(!BI.isEmpty(e)){var i=BI.Widget._renderEngine.createFragment();return BI.each(e,function(e,t){t instanceof BI.Widget&&(t=t.element),t instanceof BI.$&&t[0]&&i.appendChild(t[0])}),i}},isExist:function(e){return 0<BI.Widget._renderEngine.createElement("body").find(e.element).length},preloadImages:function(e,t){var i=0,n=[];function r(){++i>=e.length&&t()}BI.each(e,function(e,t){n[e]=new Image,n[e].src=t,n[e].onload=function(){r()},n[e].onerror=function(){r()}})},getTextSizeWidth:function(e,t){var i=BI.Widget._renderEngine.createElement("<span></span>").addClass("text-width-span").appendTo("body");null==t&&(t=12),t+="px",i.css("font-size",t).text(e);var n=i.width();return i.remove(),n},getTextSizeHeight:function(e,t){var i=BI.Widget._renderEngine.createElement("<span></span>").addClass("text-width-span").appendTo("body");null==t&&(t=12),t+="px",i.css("font-size",t).text(e);var n=i.height();return i.remove(),n},getScrollWidth:function(){var e;return!BI.isNull(this._scrollWidth)&&0!==this._scrollWidth||(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()),this._scrollWidth},getImage:function(e,t,i){var n=document.createElement("canvas");BI.Widget._renderEngine.createElement("body").append(n);var r=n.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;n.width=2*a,n.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(n).destroy();var o=i||"rgba(54, 133, 242, 0.1)";return{width:a,height:16,src:n.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),i=BI.parseInt(t[0]),n=BI.parseInt(t[1]),r=BI.parseInt(t[2]);return"#"+this.int2hex(i)+this.int2hex(n)+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,i="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))]),i+=t[0]+",",i+=t[1]+",",i+=t[2]+")"},rgba2rgb:function(e,t){if(BI.isNull(t)&&(t=1),"rgba"!=e.substr(0,4))return"";var i=e.match(/\d+(\.\d+)?/g);if(i.length<4)return"";var n=BI.parseFloat(i[0]),r=BI.parseFloat(i[1]),a=BI.parseFloat(i[2]),o=BI.parseFloat(i[3]);return"rgb("+Math.floor(t*(1-o)*255+n*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,i){return{left:e.element.offset().left-t.element.outerWidth()-(i||0)}},getInnerLeftPosition:function(e,t,i){return{left:e.element.offset().left+(i||0)}},getRightPosition:function(e,t,i){var n=e.element;return{left:n.offset().left+n.outerWidth()+(i||0)}},getInnerRightPosition:function(e,t,i){var n=e.element,r=t.element.bounds();return{left:n.offset().left+n.outerWidth()-r.width-(i||0)}},getTopPosition:function(e,t,i){return{top:e.element.offset().top-t.element.outerHeight()-(i||0)}},getBottomPosition:function(e,t,i){var n=e.element;return{top:n.offset().top+n.outerHeight()+(i||0)}},isLeftSpaceEnough:function(e,t,i){return 0<=BI.DOM.getLeftPosition(e,t,i).left},isInnerLeftSpaceEnough:function(e,t,i){var n=t.element.bounds(),r=BI.Widget._renderEngine.createElement("body").bounds();return BI.DOM.getInnerLeftPosition(e,t,i).left+n.width<=r.width},isRightSpaceEnough:function(e,t,i){var n=t.element.bounds(),r=BI.Widget._renderEngine.createElement("body").bounds();return BI.DOM.getRightPosition(e,t,i).left+n.width<=r.width},isInnerRightSpaceEnough:function(e,t,i){return 0<=BI.DOM.getInnerRightPosition(e,t,i).left},isTopSpaceEnough:function(e,t,i){return 0<=BI.DOM.getTopPosition(e,t,i).top},isBottomSpaceEnough:function(e,t,i){var n=t.element.bounds(),r=BI.Widget._renderEngine.createElement("body").bounds();return BI.DOM.getBottomPosition(e,t,i).top+n.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,i){var n=t.element.bounds(),r=BI.Widget._renderEngine.createElement("body").bounds(),a=e.element.offset().left+i;return a+n.width>r.width&&(a=r.width-n.width),a},getLeftAlignPosition:function(e,t,i){var n=this._getLeftAlignPosition(e,t,i),r="";return n<0&&(n=this._getRightAlignPosition(e,t,i),r="left"),n<0&&(n=0),{left:n,dir:r||"right"}},getLeftAdaptPosition:function(e,t,i){return BI.DOM.isLeftSpaceEnough(e,t,i)?BI.DOM.getLeftPosition(e,t,i):{left:0}},_getRightAlignPosition:function(e,t,i){var n=e.element.bounds(),r=t.element.bounds();return e.element.offset().left+n.width-r.width-i},getRightAlignPosition:function(e,t,i){var n=this._getRightAlignPosition(e,t,i),r="";return n<0&&(n=this._getLeftAlignPosition(e,t,i),r="right"),n<0&&(n=0),{left:n,dir:r||"left"}},getRightAdaptPosition:function(e,t,i){return BI.DOM.isRightSpaceEnough(e,t,i)?BI.DOM.getRightPosition(e,t,i):{left:BI.Widget._renderEngine.createElement("body").bounds().width-t.element.bounds().width}},getTopAlignPosition:function(e,t,i,n){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+i)?r=s.top+i:n?(r=s.top+i,a=c.height-r):BI.DOM.isTopSpaceEnough(e,t,-1*l.height+i)?(r=s.top+l.height-u.height-i,o="top"):(r=c.height-u.height)<i&&(a=c.height-i),r<i&&(r=i),a?{top:r,adaptHeight:a,dir:o||"bottom"}:{top:r,dir:o||"bottom"}},getTopAdaptPosition:function(e,t,i,n){var r=t.element.bounds(),a=BI.Widget._renderEngine.createElement("body").bounds();return BI.DOM.isTopSpaceEnough(e,t,i)?BI.DOM.getTopPosition(e,t,i):n?{top:0,adaptHeight:e.element.offset().top-i}:r.height+i>a.height?{top:0,adaptHeight:a.height-i}:{top:0}},getBottomAlignPosition:function(e,t,i,n){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+i)?r=s.top+l.height-u.height-i:n?(r=0,a=s.top+l.height-i):BI.DOM.isBottomSpaceEnough(e,t,-1*l.height+i)?(r=s.top+i,o="bottom"):(r=0,u.height+i>c.height&&(a=c.height-i)),r<0&&(r=0),a?{top:r,adaptHeight:a,dir:o||"top"}:{top:r,dir:o||"top"}},getBottomAdaptPosition:function(e,t,i,n){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,i)?BI.DOM.getBottomPosition(e,t,i):n?{top:r.top+a.height+i,adaptHeight:s.height-r.top-a.height-i}:o.height+i>s.height?{top:i,adaptHeight:s.height-i}:{top:s.height-o.height-i}},getCenterAdaptPosition:function(e,t){var i=e.element.offset(),n=e.element.bounds(),r=t.element.bounds(),a=BI.Widget._renderEngine.createElement("body").bounds(),o=i.left+n.width/2+r.width/2>a.width?a.width-r.width:i.left+n.width/2-r.width/2;return o<0&&(o=0),{left:o}},getMiddleAdaptPosition:function(e,t){var i=e.element.offset(),n=e.element.bounds(),r=t.element.bounds(),a=BI.Widget._renderEngine.createElement("body").bounds(),o=i.top+n.height/2+r.height/2>a.height?a.height-r.height:i.top+n.height/2-r.height/2;return o<0&&(o=0),{top:o}},getComboPositionByDirections:function(e,t,i,n,r,a){var o;i=i||0,n=n||0;for(var s,l,u,c=[],h=[],p=[],d=!1,f=!1,g=!1,m=a[0],I=0;I<a.length;I++)switch(o=a[I]){case"left":case"right":c.push(o);break;case"top":case"bottom":h.push(o);break;case"innerLeft":case"innerRight":p.push(o)}for(I=0;I<a.length;I++)switch(o=a[I]){case"left":if(!d){var B=f?n:i,E=f?0:n;if(BI.DOM.isLeftSpaceEnough(e,t,B))return s=BI.DOM.getLeftPosition(e,t,B).left,(u="bottom"===h[0]?BI.DOM.getTopAlignPosition(e,t,E,r):BI.DOM.getBottomAlignPosition(e,t,E,r)).dir="left,"+u.dir,f&&(u.change="left"),u.left=s,u}g=!0;break;case"right":if(!d){B=f?n:i,E=f?i:n;if(BI.DOM.isRightSpaceEnough(e,t,B))return s=BI.DOM.getRightPosition(e,t,B).left,(u="bottom"===h[0]?BI.DOM.getTopAlignPosition(e,t,E,r):BI.DOM.getBottomAlignPosition(e,t,E,r)).dir="right,"+u.dir,f&&(u.change="right"),u.left=s,u}g=!0;break;case"top":B=g?n:i,E=g?i:n;if(BI.DOM.isTopSpaceEnough(e,t,E))return l=BI.DOM.getTopPosition(e,t,E).top,(u="right"===c[0]?BI.DOM.getLeftAlignPosition(e,t,B,r):BI.DOM.getRightAlignPosition(e,t,B)).dir="top,"+u.dir,g&&(u.change="top"),u.top=l,u;r&&(d=!0),f=!0;break;case"bottom":B=g?n:i,E=g?i:n;if(BI.DOM.isBottomSpaceEnough(e,t,E))return l=BI.DOM.getBottomPosition(e,t,E).top,(u="right"===c[0]?BI.DOM.getLeftAlignPosition(e,t,B,r):BI.DOM.getRightAlignPosition(e,t,B)).dir="bottom,"+u.dir,g&&(u.change="bottom"),u.top=l,u;r&&(d=!0),f=!0;break;case"innerLeft":if(!d){B=f?n:i,E=f?0:n;if(BI.DOM.isInnerLeftSpaceEnough(e,t,B))return s=BI.DOM.getInnerLeftPosition(e,t,B).left,(u="bottom"===h[0]?BI.DOM.getTopAlignPosition(e,t,E,r):BI.DOM.getBottomAlignPosition(e,t,E,r)).dir="innerLeft,"+u.dir,f&&(u.change="innerLeft"),u.left=s,u}g=!0;break;case"innerRight":if(!d){B=f?n:i,E=f?i:n;if(BI.DOM.isInnerRightSpaceEnough(e,t,B))return s=BI.DOM.getInnerRightPosition(e,t,B).left,(u="bottom"===h[0]?BI.DOM.getTopAlignPosition(e,t,E,r):BI.DOM.getBottomAlignPosition(e,t,E,r)).dir="innerLeft,"+u.dir,f&&(u.change="innerRight"),u.left=s,u}}switch(a[0]){case"left":case"right":return(m=BI.DOM.isRightSpaceLarger(e)?(s=BI.DOM.getRightAdaptPosition(e,t,i).left,"right"):(s=BI.DOM.getLeftAdaptPosition(e,t,i).left,"left"),"bottom"===h[0])?((u=BI.DOM.getTopAlignPosition(e,t,n,r)).left=s,u.dir=m+","+u.dir,u):((u=BI.DOM.getBottomAlignPosition(e,t,n,r)).left=s,u.dir=m+","+u.dir,u);default:return(m=BI.DOM.isBottomSpaceLarger(e)?(u=BI.DOM.getBottomAdaptPosition(e,t,n,r),"bottom"):(u=BI.DOM.getTopAdaptPosition(e,t,n,r),"top"),"right"===c[0])?(s=BI.DOM.getLeftAlignPosition(e,t,i,r).left,u.left=s,u.dir=m+","+u.dir,u):(s=BI.DOM.getRightAlignPosition(e,t,i).left,u.left=s,u.dir=m+","+u.dir,u)}},getComboPosition:function(e,t,i,n,r,a,o){i=i||0,n=n||0;var s=BI.Widget._renderEngine.createElement("body").bounds().height-n,l=Math.min(t.attr("maxHeight")||s,s);t.resetHeight&&t.resetHeight(l);var u,c=BI.DOM.getComboPositionByDirections(e,t,i,n,r,a||["bottom","top","right","left"]);switch(o){case"center":c.change?(u=BI.DOM.getMiddleAdaptPosition(e,t),c.top=u.top):(u=BI.DOM.getCenterAdaptPosition(e,t),c.left=u.left);break;case"middle":c.change?(u=BI.DOM.getCenterAdaptPosition(e,t),c.left=u.left):(u=BI.DOM.getMiddleAdaptPosition(e,t),c.top=u.top)}return!0===r&&t.resetHeight&&t.resetHeight(Math.min(s-c.top,l)),c}})},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(),i=t.match(/(?:msie\s([\w.]+))/),n=t.match(/(?:trident.*rv:([\w.]+))/),e=i&&n&&i[1]&&n[1]?Math.max(+i[1],+n[1]):i&&i[1]?+i[1]:n&&n[1]?+n[1]:0;return 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;for(var t,i=["webkit","Moz","ms","o"],n=[],r=document.documentElement.style,a=function(e){return BI.isString(e)?e.replace(/-(\w)/g,function(e,t){return t.toUpperCase()}):""},o=0;o<i.length;o++)n.push(a(i[o]+"-"+e));for(n.push(a(e)),o=0,t=n.length;o<t;o++)if(n[o]in r)return!0;return!1}})},function(bi,yi,e){var vi,t,i;t="undefined"!=typeof window?window:this,i=function(v,e){var h=[],g=v.document,c=h.slice,m=h.concat,s=h.push,r=h.indexOf,i={},t=i.toString,I=i.hasOwnProperty,B={},T=function(e,t){return new T.fn.init(e,t)},n=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,a=/^-ms-/,o=/-([\da-z])/gi,l=function(e,t){return t.toUpperCase()};function u(e){var t=!!e&&"length"in e&&e.length,i=T.type(e);return"function"!==i&&!T.isWindow(e)&&("array"===i||0===t||"number"==typeof t&&0<t&&t-1 in e)}T.fn=T.prototype={jquery:"1.12.4",constructor:T,selector:"",length:0,toArray:function(){return c.call(this)},get:function(e){return null!=e?e<0?this[e+this.length]:this[e]:c.call(this)},pushStack:function(e){var t=T.merge(this.constructor(),e);return t.prevObject=this,t.context=this.context,t},each:function(e){if(1<arguments.length)throw new Error("调用兼容出错");return T.each(this,e)},map:function(i){return this.pushStack(T.map(this,function(e,t){return i.call(e,t,e)}))},slice:function(){return this.pushStack(c.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,i=+e+(e<0?t:0);return this.pushStack(0<=i&&i<t?[this[i]]:[])},end:function(){return this.prevObject||this.constructor()},push:s,sort:h.sort,splice:h.splice},T.extend=T.fn.extend=function(){var e,t,i,n,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||T.isFunction(o)||(o={}),s===l&&(o=this,s--);s<l;s++)if(null!=(r=arguments[s]))for(n in r)e=o[n],i=r[n],"__proto__"!==n&&o!==i&&(u&&i&&(T.isPlainObject(i)||(t=T.isArray(i)))?(a=t?(t=!1,e&&T.isArray(e)?e:[]):e&&T.isPlainObject(e)?e:{},o[n]=T.extend(u,a,i)):i!==undefined&&(o[n]=i));return o},T.extend({expando:"jQuery"+("1.12.4"+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isFunction:function(e){return"function"===T.type(e)},isArray:Array.isArray||function(e){return"array"===T.type(e)},isWindow:function(e){return null!=e&&e==e.window},isNumeric:function(e){var t=e&&e.toString();return!T.isArray(e)&&0<=t-parseFloat(t)+1},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},isPlainObject:function(e){var t;if(!e||"object"!==T.type(e)||e.nodeType||T.isWindow(e))return!1;try{if(e.constructor&&!I.call(e,"constructor")&&!I.call(e.constructor.prototype,"isPrototypeOf"))return!1}catch(i){return!1}if(!B.ownFirst)for(t in e)return I.call(e,t);for(t in e);return t===undefined||I.call(e,t)},type:function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?i[t.call(e)]||"object":typeof e},globalEval:function(e){e&&T.trim(e)&&(v.execScript||function(e){v.eval.call(v,e)})(e)},camelCase:function(e){return e.replace(a,"ms-").replace(o,l)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,t){var i,n=0;if(u(e))for(i=e.length;n<i&&!1!==t.call(e[n],n,e[n]);n++);else for(n in e)if(!1===t.call(e[n],n,e[n]))break;return e},trim:function(e){return null==e?"":(e+"").replace(n,"")},makeArray:function(e,t){var i=t||[];return null!=e&&(u(Object(e))?T.merge(i,"string"==typeof e?[e]:e):s.call(i,e)),i},inArray:function(e,t,i){var n;if(t){if(r)return r.call(t,e,i);for(n=t.length,i=i?i<0?Math.max(0,n+i):i:0;i<n;i++)if(i in t&&t[i]===e)return i}return-1},merge:function(e,t){for(var i=+t.length,n=0,r=e.length;n<i;)e[r++]=t[n++];if(i!=i)for(;t[n]!==undefined;)e[r++]=t[n++];return e.length=r,e},grep:function(e,t,i){for(var n=[],r=0,a=e.length,o=!i;r<a;r++)!t(e[r],r)!=o&&n.push(e[r]);return n},map:function(e,t,i){var n,r,a=0,o=[];if(u(e))for(n=e.length;a<n;a++)null!=(r=t(e[a],a,i))&&o.push(r);else for(a in e)null!=(r=t(e[a],a,i))&&o.push(r);return m.apply([],o)},guid:1,proxy:function(e,t){var i,n,r;return"string"==typeof t&&(r=e[t],t=e,e=r),T.isFunction(e)?(i=c.call(arguments,2),(n=function(){return e.apply(t||this,i.concat(c.call(arguments)))}).guid=e.guid=e.guid||T.guid++,n):undefined},now:function(){return+new Date},support:B}),"function"==typeof Symbol&&(T.fn[Symbol.iterator]=h[Symbol.iterator]),T.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){i["[object "+t+"]"]=t.toLowerCase()});var p=function(i){var e,g,_,a,r,b,h,m,y,l,u,v,T,o,C,I,s,c,B,N="sizzle"+ +new Date,E=i.document,V=0,n=0,p=re(),d=re(),S=re(),f=function(e,t){return e===t&&(u=!0),0},x={}.hasOwnProperty,t=[],w=t.pop,A=t.push,L=t.push,k=t.slice,D=function(e,t){for(var i=0,n=e.length;i<n;i++)if(e[i]===t)return i;return-1},P="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",M="[\\x20\\t\\r\\n\\f]",R="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",H="\\["+M+"*("+R+")(?:"+M+"*([*^$|!~]?=)"+M+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+R+"))|)"+M+"*\\]",O=":("+R+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+H+")*)|.*)\\)|)",F=new RegExp(M+"+","g"),Y=new RegExp("^"+M+"+|((?:^|[^\\\\])(?:\\\\.)*)"+M+"+$","g"),W=new RegExp("^"+M+"*,"+M+"*"),G=new RegExp("^"+M+"*([>+~]|"+M+")"+M+"*"),j=new RegExp("="+M+"*([^\\]'\"]*?)"+M+"*\\]","g"),Z=new RegExp(O),X=new RegExp("^"+R+"$"),U={ID:new RegExp("^#("+R+")"),CLASS:new RegExp("^\\.("+R+")"),TAG:new RegExp("^("+R+"|[*])"),ATTR:new RegExp("^"+H),PSEUDO:new RegExp("^"+O),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+P+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},J=/^(?:input|select|textarea|button)$/i,K=/^h\d$/i,z=/^[^{]+\{\s*\[native \w/,Q=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,q=/[+~]/,$=/'|\\/g,ee=new RegExp("\\\\([\\da-f]{1,6}"+M+"?|("+M+")|.)","ig"),te=function(e,t,i){var n="0x"+t-65536;return n!=n||i?t:n<0?String.fromCharCode(65536+n):String.fromCharCode(n>>10|55296,1023&n|56320)},ie=function(){v()};try{L.apply(t=k.call(E.childNodes),E.childNodes),t[E.childNodes.length].nodeType}catch(Ie){L={apply:t.length?function(e,t){A.apply(e,k.call(t))}:function(e,t){for(var i=e.length,n=0;e[i++]=t[n++];);e.length=i-1}}}function ne(e,t,i,n){var r,a,o,s,l,u,c,h,p=t&&t.ownerDocument,d=t?t.nodeType:9;if(i=i||[],"string"!=typeof e||!e||1!==d&&9!==d&&11!==d)return i;if(!n&&((t?t.ownerDocument||t:E)!==T&&v(t),t=t||T,C)){if(11!==d&&(u=Q.exec(e)))if(r=u[1]){if(9===d){if(!(o=t.getElementById(r)))return i;if(o.id===r)return i.push(o),i}else if(p&&(o=p.getElementById(r))&&B(t,o)&&o.id===r)return i.push(o),i}else{if(u[2])return L.apply(i,t.getElementsByTagName(e)),i;if((r=u[3])&&g.getElementsByClassName&&t.getElementsByClassName)return L.apply(i,t.getElementsByClassName(r)),i}if(g.qsa&&!S[e+" "]&&(!I||!I.test(e))){if(1!==d)p=t,h=e;else if("object"!==t.nodeName.toLowerCase()){for((s=t.getAttribute("id"))?s=s.replace($,"\\$&"):t.setAttribute("id",s=N),a=(c=b(e)).length,l=X.test(s)?"#"+s:"[id='"+s+"']";a--;)c[a]=l+" "+pe(c[a]);h=c.join(","),p=q.test(e)&&ce(t.parentNode)||t}if(h)try{return L.apply(i,p.querySelectorAll(h)),i}catch(f){}finally{s===N&&t.removeAttribute("id")}}}return m(e.replace(Y,"$1"),t,i,n)}function re(){var i=[];function n(e,t){return i.push(e+" ")>_.cacheLength&&delete n[i.shift()],n[e+" "]=t}return n}function ae(e){return e[N]=!0,e}function oe(e){var t=T.createElement("div");try{return!!e(t)}catch(Ie){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function se(e,t){for(var i=e.split("|"),n=i.length;n--;)_.attrHandle[i[n]]=t}function le(e,t){var i=t&&e,n=i&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||1<<31)-(~e.sourceIndex||1<<31);if(n)return n;if(i)for(;i=i.nextSibling;)if(i===t)return-1;return e?1:-1}function ue(o){return ae(function(a){return a=+a,ae(function(e,t){for(var i,n=o([],e.length,a),r=n.length;r--;)e[i=n[r]]&&(e[i]=!(t[i]=e[i]))})})}function ce(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in g=ne.support={},r=ne.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return!!t&&"HTML"!==t.nodeName},v=ne.setDocument=function(e){var t,i,n=e?e.ownerDocument||e:E;return n!==T&&9===n.nodeType&&n.documentElement&&(o=(T=n).documentElement,C=!r(T),(i=T.defaultView)&&i.top!==i&&(i.addEventListener?i.addEventListener("unload",ie,!1):i.attachEvent&&i.attachEvent("onunload",ie)),g.attributes=oe(function(e){return e.className="i",!e.getAttribute("className")}),g.getElementsByTagName=oe(function(e){return e.appendChild(T.createComment("")),!e.getElementsByTagName("*").length}),g.getElementsByClassName=z.test(T.getElementsByClassName),g.getById=oe(function(e){return o.appendChild(e).id=N,!T.getElementsByName||!T.getElementsByName(N).length}),g.getById?(_.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&C){var i=t.getElementById(e);return i?[i]:[]}},_.filter.ID=function(e){var t=e.replace(ee,te);return function(e){return e.getAttribute("id")===t}}):(delete _.find.ID,_.filter.ID=function(e){var i=e.replace(ee,te);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===i}}),_.find.TAG=g.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):g.qsa?t.querySelectorAll(e):void 0}:function(e,t){var i,n=[],r=0,a=t.getElementsByTagName(e);if("*"!==e)return a;for(;i=a[r++];)1===i.nodeType&&n.push(i);return n},_.find.CLASS=g.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&C)return t.getElementsByClassName(e)},s=[],I=[],(g.qsa=z.test(T.querySelectorAll))&&(oe(function(e){o.appendChild(e).innerHTML="<a id='"+N+"'></a><select id='"+N+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&I.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||I.push("\\["+M+"*(?:value|"+P+")"),e.querySelectorAll("[id~="+N+"-]").length||I.push("~="),e.querySelectorAll(":checked").length||I.push(":checked"),e.querySelectorAll("a#"+N+"+*").length||I.push(".#.+[+~]")}),oe(function(e){var t=T.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&I.push("name"+M+"*[*^$|!~]?="),e.querySelectorAll(":enabled").length||I.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),I.push(",.*:")})),(g.matchesSelector=z.test(c=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&oe(function(e){g.disconnectedMatch=c.call(e,"div"),c.call(e,"[s!='']:x"),s.push("!=",O)}),I=I.length&&new RegExp(I.join("|")),s=s.length&&new RegExp(s.join("|")),t=z.test(o.compareDocumentPosition),B=t||z.test(o.contains)?function(e,t){var i=9===e.nodeType?e.documentElement:e,n=t&&t.parentNode;return e===n||!(!n||1!==n.nodeType||!(i.contains?i.contains(n):e.compareDocumentPosition&&16&e.compareDocumentPosition(n)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},f=t?function(e,t){if(e===t)return u=!0,0;var i=!e.compareDocumentPosition-!t.compareDocumentPosition;return i||(1&(i=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!g.sortDetached&&t.compareDocumentPosition(e)===i?e===T||e.ownerDocument===E&&B(E,e)?-1:t===T||t.ownerDocument===E&&B(E,t)?1:l?D(l,e)-D(l,t):0:4&i?-1:1)}:function(e,t){if(e===t)return u=!0,0;var i,n=0,r=e.parentNode,a=t.parentNode,o=[e],s=[t];if(!r||!a)return e===T?-1:t===T?1:r?-1:a?1:l?D(l,e)-D(l,t):0;if(r===a)return le(e,t);for(i=e;i=i.parentNode;)o.unshift(i);for(i=t;i=i.parentNode;)s.unshift(i);for(;o[n]===s[n];)n++;return n?le(o[n],s[n]):o[n]===E?-1:s[n]===E?1:0}),T},ne.matches=function(e,t){return ne(e,null,null,t)},ne.matchesSelector=function(e,t){if((e.ownerDocument||e)!==T&&v(e),t=t.replace(j,"='$1']"),g.matchesSelector&&C&&!S[t+" "]&&(!s||!s.test(t))&&(!I||!I.test(t)))try{var i=c.call(e,t);if(i||g.disconnectedMatch||e.document&&11!==e.document.nodeType)return i}catch(Ie){}return 0<ne(t,T,null,[e]).length},ne.contains=function(e,t){return(e.ownerDocument||e)!==T&&v(e),B(e,t)},ne.attr=function(e,t){(e.ownerDocument||e)!==T&&v(e);var i=_.attrHandle[t.toLowerCase()],n=i&&x.call(_.attrHandle,t.toLowerCase())?i(e,t,!C):undefined;return n!==undefined?n:g.attributes||!C?e.getAttribute(t):(n=e.getAttributeNode(t))&&n.specified?n.value:null},ne.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},ne.uniqueSort=function(e){var t,i=[],n=0,r=0;if(u=!g.detectDuplicates,l=!g.sortStable&&e.slice(0),e.sort(f),u){for(;t=e[r++];)t===e[r]&&(n=i.push(r));for(;n--;)e.splice(i[n],1)}return l=null,e},a=ne.getText=function(e){var t,i="",n=0,r=e.nodeType;if(r){if(1===r||9===r||11===r){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)i+=a(e)}else if(3===r||4===r)return e.nodeValue}else for(;t=e[n++];)i+=a(t);return i},(_=ne.selectors={cacheLength:50,createPseudo:ae,match:U,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(ee,te),e[3]=(e[3]||e[4]||e[5]||"").replace(ee,te),"~="===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]||ne.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]&&ne.error(e[0]),e},PSEUDO:function(e){var t,i=!e[6]&&e[2];return U.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":i&&Z.test(i)&&(t=b(i,!0))&&(t=i.indexOf(")",i.length-t)-i.length)&&(e[0]=e[0].slice(0,t),e[2]=i.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(ee,te).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=p[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&p(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(i,n,r){return function(e){var t=ne.attr(e,i);return null==t?"!="===n:!n||(t+="","="===n?t===r:"!="===n?t!==r:"^="===n?r&&0===t.indexOf(r):"*="===n?r&&-1<t.indexOf(r):"$="===n?r&&t.slice(-r.length)===r:"~="===n?-1<(" "+t.replace(F," ")+" ").indexOf(r):"|="===n&&(t===r||t.slice(0,r.length+1)===r+"-"))}},CHILD:function(f,e,t,g,m){var I="nth"!==f.slice(0,3),B="last"!==f.slice(-4),E="of-type"===e;return 1===g&&0===m?function(e){return!!e.parentNode}:function(e,t,i){var n,r,a,o,s,l,u=I!=B?"nextSibling":"previousSibling",c=e.parentNode,h=E&&e.nodeName.toLowerCase(),p=!i&&!E,d=!1;if(c){if(I){for(;u;){for(o=e;o=o[u];)if(E?o.nodeName.toLowerCase()===h:1===o.nodeType)return!1;l=u="only"===f&&!l&&"nextSibling"}return!0}if(l=[B?c.firstChild:c.lastChild],B&&p){for(d=(s=(n=(r=(a=(o=c)[N]||(o[N]={}))[o.uniqueID]||(a[o.uniqueID]={}))[f]||[])[0]===V&&n[1])&&n[2],o=s&&c.childNodes[s];o=++s&&o&&o[u]||(d=s=0)||l.pop();)if(1===o.nodeType&&++d&&o===e){r[f]=[V,s,d];break}}else if(p&&(d=s=(n=(r=(a=(o=e)[N]||(o[N]={}))[o.uniqueID]||(a[o.uniqueID]={}))[f]||[])[0]===V&&n[1]),!1===d)for(;(o=++s&&o&&o[u]||(d=s=0)||l.pop())&&((E?o.nodeName.toLowerCase()!==h:1!==o.nodeType)||!++d||(p&&((r=(a=o[N]||(o[N]={}))[o.uniqueID]||(a[o.uniqueID]={}))[f]=[V,d]),o!==e)););return(d-=m)===g||d%g==0&&0<=d/g}}},PSEUDO:function(e,a){var t,o=_.pseudos[e]||_.setFilters[e.toLowerCase()]||ne.error("unsupported pseudo: "+e);return o[N]?o(a):1<o.length?(t=[e,e,"",a],_.setFilters.hasOwnProperty(e.toLowerCase())?ae(function(e,t){for(var i,n=o(e,a),r=n.length;r--;)e[i=D(e,n[r])]=!(t[i]=n[r])}):function(e){return o(e,0,t)}):o}},pseudos:{not:ae(function(e){var n=[],r=[],s=h(e.replace(Y,"$1"));return s[N]?ae(function(e,t,i,n){for(var r,a=s(e,null,n,[]),o=e.length;o--;)(r=a[o])&&(e[o]=!(t[o]=r))}):function(e,t,i){return n[0]=e,s(n,null,i,r),n[0]=null,!r.pop()}}),has:ae(function(t){return function(e){return 0<ne(t,e).length}}),contains:ae(function(t){return t=t.replace(ee,te),function(e){return-1<(e.textContent||e.innerText||a(e)).indexOf(t)}}),lang:ae(function(i){return X.test(i||"")||ne.error("unsupported lang: "+i),i=i.replace(ee,te).toLowerCase(),function(e){var t;do{if(t=C?e.lang:e.getAttribute("xml:lang")||e.getAttribute("lang"))return(t=t.toLowerCase())===i||0===t.indexOf(i+"-")}while((e=e.parentNode)&&1===e.nodeType);return!1}}),target:function(e){var t=i.location&&i.location.hash;return t&&t.slice(1)===e.id},root:function(e){return e===o},focus:function(e){return e===T.activeElement&&(!T.hasFocus||T.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!_.pseudos.empty(e)},header:function(e){return K.test(e.nodeName)},input:function(e){return J.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:ue(function(){return[0]}),last:ue(function(e,t){return[t-1]}),eq:ue(function(e,t,i){return[i<0?i+t:i]}),even:ue(function(e,t){for(var i=0;i<t;i+=2)e.push(i);return e}),odd:ue(function(e,t){for(var i=1;i<t;i+=2)e.push(i);return e}),lt:ue(function(e,t,i){for(var n=i<0?i+t:i;0<=--n;)e.push(n);return e}),gt:ue(function(e,t,i){for(var n=i<0?i+t:i;++n<t;)e.push(n);return e})}}).pseudos.nth=_.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})_.pseudos[e]=function(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}(e);for(e in{submit:!0,reset:!0})_.pseudos[e]=function(i){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===i}}(e);function he(){}function pe(e){for(var t=0,i=e.length,n="";t<i;t++)n+=e[t].value;return n}function de(s,e,t){var l=e.dir,u=t&&"parentNode"===l,c=n++;return e.first?function(e,t,i){for(;e=e[l];)if(1===e.nodeType||u)return s(e,t,i)}:function(e,t,i){var n,r,a,o=[V,c];if(i){for(;e=e[l];)if((1===e.nodeType||u)&&s(e,t,i))return!0}else for(;e=e[l];)if(1===e.nodeType||u){if((n=(r=(a=e[N]||(e[N]={}))[e.uniqueID]||(a[e.uniqueID]={}))[l])&&n[0]===V&&n[1]===c)return o[2]=n[2];if((r[l]=o)[2]=s(e,t,i))return!0}}}function fe(r){return 1<r.length?function(e,t,i){for(var n=r.length;n--;)if(!r[n](e,t,i))return!1;return!0}:r[0]}function ge(e,t,i,n,r){for(var a,o=[],s=0,l=e.length,u=null!=t;s<l;s++)(a=e[s])&&(i&&!i(a,n,r)||(o.push(a),u&&t.push(s)));return o}function me(d,f,g,m,I,e){return m&&!m[N]&&(m=me(m)),I&&!I[N]&&(I=me(I,e)),ae(function(e,t,i,n){var r,a,o,s=[],l=[],u=t.length,c=e||function(e,t,i){for(var n=0,r=t.length;n<r;n++)ne(e,t[n],i);return i}(f||"*",i.nodeType?[i]:i,[]),h=!d||!e&&f?c:ge(c,s,d,i,n),p=g?I||(e?d:u||m)?[]:t:h;if(g&&g(h,p,i,n),m)for(r=ge(p,l),m(r,[],i,n),a=r.length;a--;)(o=r[a])&&(p[l[a]]=!(h[l[a]]=o));if(e){if(I||d){if(I){for(r=[],a=p.length;a--;)(o=p[a])&&r.push(h[a]=o);I(null,p=[],r,n)}for(a=p.length;a--;)(o=p[a])&&-1<(r=I?D(e,o):s[a])&&(e[r]=!(t[r]=o))}}else p=ge(p===t?p.splice(u,p.length):p),I?I(null,t,p,n):L.apply(t,p)})}return he.prototype=_.filters=_.pseudos,_.setFilters=new he,b=ne.tokenize=function(e,t){var i,n,r,a,o,s,l,u=d[e+" "];if(u)return t?0:u.slice(0);for(o=e,s=[],l=_.preFilter;o;){for(a in i&&!(n=W.exec(o))||(n&&(o=o.slice(n[0].length)||o),s.push(r=[])),i=!1,(n=G.exec(o))&&(i=n.shift(),r.push({value:i,type:n[0].replace(Y," ")}),o=o.slice(i.length)),_.filter)!(n=U[a].exec(o))||l[a]&&!(n=l[a](n))||(i=n.shift(),r.push({value:i,type:a,matches:n}),o=o.slice(i.length));if(!i)break}return t?o.length:o?ne.error(e):d(e,s).slice(0)},h=ne.compile=function(e,t){var i,m,I,B,E,n,r=[],a=[],o=S[e+" "];if(!o){for(i=(t=t||b(e)).length;i--;)(o=function h(e){for(var r,t,i,n=e.length,a=_.relative[e[0].type],o=a||_.relative[" "],s=a?1:0,l=de(function(e){return e===r},o,!0),u=de(function(e){return-1<D(r,e)},o,!0),c=[function(e,t,i){var n=!a&&(i||t!==y)||((r=t).nodeType?l:u)(e,t,i);return r=null,n}];s<n;s++)if(t=_.relative[e[s].type])c=[de(fe(c),t)];else{if((t=_.filter[e[s].type].apply(null,e[s].matches))[N]){for(i=++s;i<n&&!_.relative[e[i].type];i++);return me(1<s&&fe(c),1<s&&pe(e.slice(0,s-1).concat({value:" "===e[s-2].type?"*":""})).replace(Y,"$1"),t,s<i&&h(e.slice(s,i)),i<n&&h(e=e.slice(i)),i<n&&pe(e))}c.push(t)}return fe(c)}(t[i]))[N]?r.push(o):a.push(o);(o=S(e,(m=a,B=0<(I=r).length,E=0<m.length,n=function(e,t,i,n,r){var a,o,s,l=0,u="0",c=e&&[],h=[],p=y,d=e||E&&_.find.TAG("*",r),f=V+=null==p?1:Math.random()||.1,g=d.length;for(r&&(y=t===T||t||r);u!==g&&null!=(a=d[u]);u++){if(E&&a){for(o=0,t||a.ownerDocument===T||(v(a),i=!C);s=m[o++];)if(s(a,t||T,i)){n.push(a);break}r&&(V=f)}B&&((a=!s&&a)&&l--,e&&c.push(a))}if(l+=u,B&&u!==l){for(o=0;s=I[o++];)s(c,h,t,i);if(e){if(0<l)for(;u--;)c[u]||h[u]||(h[u]=w.call(n));h=ge(h)}L.apply(n,h),r&&!e&&0<h.length&&1<l+I.length&&ne.uniqueSort(n)}return r&&(V=f,y=p),c},B?ae(n):n))).selector=e}return o},m=ne.select=function(e,t,i,n){var r,a,o,s,l,u="function"==typeof e&&e,c=!n&&b(e=u.selector||e);if(i=i||[],1===c.length){if(2<(a=c[0]=c[0].slice(0)).length&&"ID"===(o=a[0]).type&&g.getById&&9===t.nodeType&&C&&_.relative[a[1].type]){if(!(t=(_.find.ID(o.matches[0].replace(ee,te),t)||[])[0]))return i;u&&(t=t.parentNode),e=e.slice(a.shift().value.length)}for(r=U.needsContext.test(e)?0:a.length;r--&&(o=a[r],!_.relative[s=o.type]);)if((l=_.find[s])&&(n=l(o.matches[0].replace(ee,te),q.test(a[0].type)&&ce(t.parentNode)||t))){if(a.splice(r,1),!(e=n.length&&pe(a)))return L.apply(i,n),i;break}}return(u||h(e,c))(n,t,!C,i,!t||q.test(e)&&ce(t.parentNode)||t),i},g.sortStable=N.split("").sort(f).join("")===N,g.detectDuplicates=!!u,v(),g.sortDetached=oe(function(e){return 1&e.compareDocumentPosition(T.createElement("div"))}),oe(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||se("type|href|height|width",function(e,t,i){if(!i)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),g.attributes&&oe(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||se("value",function(e,t,i){if(!i&&"input"===e.nodeName.toLowerCase())return e.defaultValue}),oe(function(e){return null==e.getAttribute("disabled")})||se(P,function(e,t,i){var n;if(!i)return!0===e[t]?t.toLowerCase():(n=e.getAttributeNode(t))&&n.specified?n.value:null}),ne}(v);T.find=p,T.expr=p.selectors,T.expr[":"]=T.expr.pseudos,T.uniqueSort=T.unique=p.uniqueSort,T.text=p.getText,T.isXMLDoc=p.isXML,T.contains=p.contains;var d=function(e,t,i){for(var n=[],r=i!==undefined;(e=e[t])&&9!==e.nodeType;)if(1===e.nodeType){if(r&&T(e).is(i))break;n.push(e)}return n},f=function(e,t){for(var i=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&i.push(e);return i},E=T.expr.match.needsContext,b=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,y=/^.[^:#\[\.,]*$/;function C(e,i,n){if(T.isFunction(i))return T.grep(e,function(e,t){return!!i.call(e,t,e)!==n});if(i.nodeType)return T.grep(e,function(e){return e===i!==n});if("string"==typeof i){if(y.test(i))return T.filter(i,e,n);i=T.filter(i,e)}return T.grep(e,function(e){return-1<T.inArray(e,i)!==n})}T.filter=function(e,t,i){var n=t[0];return i&&(e=":not("+e+")"),1===t.length&&1===n.nodeType?T.find.matchesSelector(n,e)?[n]:[]:T.find.matches(e,T.grep(t,function(e){return 1===e.nodeType}))},T.fn.extend({find:function(e){var t,i=[],n=this,r=n.length;if("string"!=typeof e)return this.pushStack(T(e).filter(function(){for(t=0;t<r;t++)if(T.contains(n[t],this))return!0}));for(t=0;t<r;t++)T.find(e,n[t],i);return(i=this.pushStack(1<r?T.unique(i):i)).selector=this.selector?this.selector+" "+e:e,i},filter:function(e){return this.pushStack(C(this,e||[],!1))},not:function(e){return this.pushStack(C(this,e||[],!0))},is:function(e){return!!C(this,"string"==typeof e&&E.test(e)?T(e):e||[],!1).length}});var N,V=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/;(T.fn.init=function(e,t,i){var n,r;if(!e)return this;if(i=i||N,"string"!=typeof e)return e.nodeType?(this.context=this[0]=e,this.length=1,this):T.isFunction(e)?"undefined"!=typeof i.ready?i.ready(e):e(T):(e.selector!==undefined&&(this.selector=e.selector,this.context=e.context),T.makeArray(e,this));if(!(n="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&3<=e.length?[null,e,null]:V.exec(e))||!n[1]&&t)return!t||t.jquery?(t||i).find(e):this.constructor(t).find(e);if(n[1]){if(t=t instanceof T?t[0]:t,T.merge(this,T.parseHTML(n[1],t&&t.nodeType?t.ownerDocument||t:g,!0)),b.test(n[1])&&T.isPlainObject(t))for(n in t)T.isFunction(this[n])?this[n](t[n]):this.attr(n,t[n]);return this}if((r=g.getElementById(n[2]))&&r.parentNode){if(r.id!==n[2])return N.find(e);this.length=1,this[0]=r}return this.context=g,this.selector=e,this}).prototype=T.fn,N=T(g);var S=/^(?:parents|prev(?:Until|All))/,x={children:!0,contents:!0,next:!0,prev:!0};function w(e,t){for(;(e=e[t])&&1!==e.nodeType;);return e}T.fn.extend({has:function(e){var t,i=T(e,this),n=i.length;return this.filter(function(){for(t=0;t<n;t++)if(T.contains(this,i[t]))return!0})},closest:function(e,t){for(var i,n=0,r=this.length,a=[],o=E.test(e)||"string"!=typeof e?T(e,t||this.context):0;n<r;n++)for(i=this[n];i&&i!==t;i=i.parentNode)if(i.nodeType<11&&(o?-1<o.index(i):1===i.nodeType&&T.find.matchesSelector(i,e))){a.push(i);break}return this.pushStack(1<a.length?T.uniqueSort(a):a)},index:function(e){return e?"string"==typeof e?T.inArray(this[0],T(e)):T.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(T.uniqueSort(T.merge(this.get(),T(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),T.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return d(e,"parentNode")},parentsUntil:function(e,t,i){return d(e,"parentNode",i)},next:function(e){return w(e,"nextSibling")},prev:function(e){return w(e,"previousSibling")},nextAll:function(e){return d(e,"nextSibling")},prevAll:function(e){return d(e,"previousSibling")},nextUntil:function(e,t,i){return d(e,"nextSibling",i)},prevUntil:function(e,t,i){return d(e,"previousSibling",i)},siblings:function(e){return f((e.parentNode||{}).firstChild,e)},children:function(e){return f(e.firstChild)},contents:function(e){return T.nodeName(e,"iframe")?e.contentDocument||e.contentWindow.document:T.merge([],e.childNodes)}},function(n,r){T.fn[n]=function(e,t){var i=T.map(this,r,e);return"Until"!==n.slice(-5)&&(t=e),t&&"string"==typeof t&&(i=T.filter(t,i)),1<this.length&&(x[n]||(i=T.uniqueSort(i)),S.test(n)&&(i=i.reverse())),this.pushStack(i)}});var A,L,k=/\S+/g;function D(){g.addEventListener?(g.removeEventListener("DOMContentLoaded",P),v.removeEventListener("load",P)):(g.detachEvent("onreadystatechange",P),v.detachEvent("onload",P))}function P(){!g.addEventListener&&"load"!==v.event.type&&"complete"!==g.readyState||(D(),T.ready())}for(L in T.Callbacks=function(n){var e,i;n="string"==typeof n?(e=n,i={},T.each(e.match(k)||[],function(e,t){i[t]=!0}),i):T.extend({},n);var r,t,a,o,s=[],l=[],u=-1,c=function(){for(o=n.once,a=r=!0;l.length;u=-1)for(t=l.shift();++u<s.length;)!1===s[u].apply(t[0],t[1])&&n.stopOnFalse&&(u=s.length,t=!1);n.memory||(t=!1),r=!1,o&&(s=t?[]:"")},h={add:function(){return s&&(t&&!r&&(u=s.length-1,l.push(t)),function i(e){T.each(e,function(e,t){T.isFunction(t)?n.unique&&h.has(t)||s.push(t):t&&t.length&&"string"!==T.type(t)&&i(t)})}(arguments),t&&!r&&c()),this},remove:function(){return T.each(arguments,function(e,t){for(var i;-1<(i=T.inArray(t,s,i));)s.splice(i,1),i<=u&&u--}),this},has:function(e){return e?-1<T.inArray(e,s):0<s.length},empty:function(){return s=s&&[],this},disable:function(){return o=l=[],s=t="",this},disabled:function(){return!s},lock:function(){return o=!0,t||h.disable(),this},locked:function(){return!!o},fireWith:function(e,t){return o||(t=[e,(t=t||[]).slice?t.slice():t],l.push(t),r||c()),this},fire:function(){return h.fireWith(this,arguments),this},fired:function(){return!!a}};return h},T.extend({Deferred:function(e){var a=[["resolve","done",T.Callbacks("once memory"),"resolved"],["reject","fail",T.Callbacks("once memory"),"rejected"],["notify","progress",T.Callbacks("memory")]],r="pending",o={state:function(){return r},always:function(){return s.done(arguments).fail(arguments),this},then:function(){var r=arguments;return T.Deferred(function(n){T.each(a,function(e,t){var i=T.isFunction(r[e])&&r[e];s[t[1]](function(){var e=i&&i.apply(this,arguments);e&&T.isFunction(e.promise)?e.promise().progress(n.notify).done(n.resolve).fail(n.reject):n[t[0]+"With"](this===o?n.promise():this,i?[e]:arguments)})}),r=null}).promise()},promise:function(e){return null!=e?T.extend(e,o):o}},s={};return o.pipe=o.then,T.each(a,function(e,t){var i=t[2],n=t[3];o[t[1]]=i.add,n&&i.add(function(){r=n},a[1^e][2].disable,a[2][2].lock),s[t[0]]=function(){return s[t[0]+"With"](this===s?o:this,arguments),this},s[t[0]+"With"]=i.fireWith}),o.promise(s),e&&e.call(s,s),s},when:function(e){var r,t,i,n=0,a=c.call(arguments),o=a.length,s=1!==o||e&&T.isFunction(e.promise)?o:0,l=1===s?e:T.Deferred(),u=function(t,i,n){return function(e){i[t]=this,n[t]=1<arguments.length?c.call(arguments):e,n===r?l.notifyWith(i,n):--s||l.resolveWith(i,n)}};if(1<o)for(r=new Array(o),t=new Array(o),i=new Array(o);n<o;n++)a[n]&&T.isFunction(a[n].promise)?a[n].promise().progress(u(n,t,r)).done(u(n,i,a)).fail(l.reject):--s;return s||l.resolveWith(i,a),l.promise()}}),T.fn.ready=function(e){return T.ready.promise().done(e),this},T.extend({isReady:!1,readyWait:1,holdReady:function(e){e?T.readyWait++:T.ready(!0)},ready:function(e){(!0===e?--T.readyWait:T.isReady)||(T.isReady=!0)!==e&&0<--T.readyWait||(A.resolveWith(g,[T]),T.fn.triggerHandler&&(T(g).triggerHandler("ready"),T(g).off("ready")))}}),T.ready.promise=function(e){if(!A)if(A=T.Deferred(),"complete"===g.readyState||"loading"!==g.readyState&&!g.documentElement.doScroll)v.setTimeout(T.ready);else if(g.addEventListener)g.addEventListener("DOMContentLoaded",P),v.addEventListener("load",P);else{g.attachEvent("onreadystatechange",P),v.attachEvent("onload",P);var t=!1;try{t=null==v.frameElement&&g.documentElement}catch(i){}t&&t.doScroll&&!function n(){if(!T.isReady){try{t.doScroll("left")}catch(i){return v.setTimeout(n,50)}D(),T.ready()}}()}return A.promise(e)},T.ready.promise(),T(B))break;B.ownFirst="0"===L,B.inlineBlockNeedsLayout=!1,T(function(){var e,t,i,n=g.getElementsByTagName("body")[0];n&&n.style&&(t=g.createElement("div"),(i=g.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",B.inlineBlockNeedsLayout=e=3===t.offsetWidth,e&&(n.style.zoom=1)),n.removeChild(i))}),function(){var e=g.createElement("div");B.deleteExpando=!0;try{delete e.test}catch(t){B.deleteExpando=!1}e=null}();var M,R=function(e){var t=T.noData[(e.nodeName+" ").toLowerCase()],i=+e.nodeType||1;return(1===i||9===i)&&(!t||!0!==t&&e.getAttribute("classid")===t)},H=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,O=/([A-Z])/g;function F(e,t,i){if(i===undefined&&1===e.nodeType){var n="data-"+t.replace(O,"-$1").toLowerCase();if("string"==typeof(i=e.getAttribute(n))){try{i="true"===i||"false"!==i&&("null"===i?null:+i+""===i?+i:H.test(i)?T.parseJSON(i):i)}catch(r){}T.data(e,t,i)}else i=undefined}return i}function Y(e){var t;for(t in e)if(("data"!==t||!T.isEmptyObject(e[t]))&&"toJSON"!==t)return;return 1}function W(e,t,i,n){if(R(e)){var r,a,o=T.expando,s=e.nodeType,l=s?T.cache:e,u=s?e[o]:e[o]&&o;if(u&&l[u]&&(n||l[u].data)||i!==undefined||"string"!=typeof t)return l[u=u||(s?e[o]=h.pop()||T.guid++:o)]||(l[u]=s?{}:{toJSON:T.noop}),"object"!=typeof t&&"function"!=typeof t||(n?l[u]=T.extend(l[u],t):l[u].data=T.extend(l[u].data,t)),a=l[u],n||(a.data||(a.data={}),a=a.data),i!==undefined&&(a[T.camelCase(t)]=i),"string"==typeof t?null==(r=a[t])&&(r=a[T.camelCase(t)]):r=a,r}}function G(e,t,i){if(R(e)){var n,r,a=e.nodeType,o=a?T.cache:e,s=a?e[T.expando]:T.expando;if(o[s]){if(t&&(n=i?o[s]:o[s].data)){r=(t=T.isArray(t)?t.concat(T.map(t,T.camelCase)):t in n||(t=T.camelCase(t))in n?[t]:t.split(" ")).length;for(;r--;)delete n[t[r]];if(i?!Y(n):!T.isEmptyObject(n))return}(i||(delete o[s].data,Y(o[s])))&&(a?T.cleanData([e],!0):B.deleteExpando||o!=o.window?delete o[s]:o[s]=undefined)}}}T.extend({cache:{},noData:{"applet ":!0,"embed ":!0,"object ":"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(e){return!!(e=e.nodeType?T.cache[e[T.expando]]:e[T.expando])&&!Y(e)},data:function(e,t,i){return W(e,t,i)},removeData:function(e,t){return G(e,t)},_data:function(e,t,i){return W(e,t,i,!0)},_removeData:function(e,t){return G(e,t,!0)}}),T.fn.extend({data:function(e,t){var i,n,r,a=this[0],o=a&&a.attributes;if(e!==undefined)return"object"==typeof e?this.each(function(){T.data(this,e)}):1<arguments.length?this.each(function(){T.data(this,e,t)}):a?F(a,e,T.data(a,e)):undefined;if(this.length&&(r=T.data(a),1===a.nodeType&&!T._data(a,"parsedAttrs"))){for(i=o.length;i--;)o[i]&&0===(n=o[i].name).indexOf("data-")&&F(a,n=T.camelCase(n.slice(5)),r[n]);T._data(a,"parsedAttrs",!0)}return r},removeData:function(e){return this.each(function(){T.removeData(this,e)})}}),T.extend({queue:function(e,t,i){var n;if(e)return t=(t||"fx")+"queue",n=T._data(e,t),i&&(!n||T.isArray(i)?n=T._data(e,t,T.makeArray(i)):n.push(i)),n||[]},dequeue:function(e,t){t=t||"fx";var i=T.queue(e,t),n=i.length,r=i.shift(),a=T._queueHooks(e,t);"inprogress"===r&&(r=i.shift(),n--),r&&("fx"===t&&i.unshift("inprogress"),delete a.stop,r.call(e,function(){T.dequeue(e,t)},a)),!n&&a&&a.empty.fire()},_queueHooks:function(e,t){var i=t+"queueHooks";return T._data(e,i)||T._data(e,i,{empty:T.Callbacks("once memory").add(function(){T._removeData(e,t+"queue"),T._removeData(e,i)})})}}),T.fn.extend({queue:function(t,i){var e=2;return"string"!=typeof t&&(i=t,t="fx",e--),arguments.length<e?T.queue(this[0],t):i===undefined?this:this.each(function(){var e=T.queue(this,t,i);T._queueHooks(this,t),"fx"===t&&"inprogress"!==e[0]&&T.dequeue(this,t)})},dequeue:function(e){return this.each(function(){T.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var i,n=1,r=T.Deferred(),a=this,o=this.length,s=function(){--n||r.resolveWith(a,[a])};for("string"!=typeof e&&(t=e,e=undefined),e=e||"fx";o--;)(i=T._data(a[o],e+"queueHooks"))&&i.empty&&(n++,i.empty.add(s));return s(),r.promise(t)}}),B.shrinkWrapBlocks=function(){return null!=M?M:(M=!1,(t=g.getElementsByTagName("body")[0])&&t.style?(e=g.createElement("div"),(i=g.createElement("div")).style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",t.appendChild(i).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(g.createElement("div")).style.width="5px",M=3!==e.offsetWidth),t.removeChild(i),M):void 0);var e,t,i};var j=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,Z=new RegExp("^(?:([+-])=|)("+j+")([a-z%]*)$","i"),X=["Top","Right","Bottom","Left"],U=function(e,t){return e=t||e,"none"===T.css(e,"display")||!T.contains(e.ownerDocument,e)};function J(e,t,i,n){var r,a=1,o=20,s=n?function(){return n.cur()}:function(){return T.css(e,t,"")},l=s(),u=i&&i[3]||(T.cssNumber[t]?"":"px"),c=(T.cssNumber[t]||"px"!==u&&+l)&&Z.exec(T.css(e,t));if(c&&c[3]!==u)for(u=u||c[3],i=i||[],c=+l||1;c/=a=a||".5",T.style(e,t,c+u),a!==(a=s()/l)&&1!==a&&--o;);return i&&(c=+c||+l||0,r=i[1]?c+(i[1]+1)*i[2]:+i[2],n&&(n.unit=u,n.start=c,n.end=r)),r}var K,z,Q,q=function(e,t,i,n,r,a,o){var s=0,l=e.length,u=null==i;if("object"===T.type(i))for(s in r=!0,i)q(e,t,s,i[s],!0,a,o);else if(n!==undefined&&(r=!0,T.isFunction(n)||(o=!0),u&&(t=o?(t.call(e,n),null):(u=t,function(e,t,i){return u.call(T(e),i)})),t))for(;s<l;s++)t(e[s],i,o?n:n.call(e[s],s,t(e[s],i)));return r?e:u?t.call(e):l?t(e[0],i):a},$=/^(?:checkbox|radio)$/i,ee=/<([\w:-]+)/,te=/^$|\/(?:java|ecma)script/i,ie=/^\s+/,ne="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 re(e){var t=ne.split("|"),i=e.createDocumentFragment();if(i.createElement)for(;t.length;)i.createElement(t.pop());return i}K=g.createElement("div"),z=g.createDocumentFragment(),Q=g.createElement("input"),K.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",B.leadingWhitespace=3===K.firstChild.nodeType,B.tbody=!K.getElementsByTagName("tbody").length,B.htmlSerialize=!!K.getElementsByTagName("link").length,B.html5Clone="<:nav></:nav>"!==g.createElement("nav").cloneNode(!0).outerHTML,Q.type="checkbox",Q.checked=!0,z.appendChild(Q),B.appendChecked=Q.checked,K.innerHTML="<textarea>x</textarea>",B.noCloneChecked=!!K.cloneNode(!0).lastChild.defaultValue,z.appendChild(K),(Q=g.createElement("input")).setAttribute("type","radio"),Q.setAttribute("checked","checked"),Q.setAttribute("name","t"),K.appendChild(Q),B.checkClone=K.cloneNode(!0).cloneNode(!0).lastChild.checked,B.noCloneEvent=!!K.addEventListener,K[T.expando]=1,B.attributes=!K.getAttribute(T.expando),K.innerHTML="<option></option>",B.option=!!K.lastChild;var ae={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:B.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]};function oe(e,t){var i,n,r=0,a="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):undefined;if(!a)for(a=[],i=e.childNodes||e;null!=(n=i[r]);r++)!t||T.nodeName(n,t)?a.push(n):T.merge(a,oe(n,t));return t===undefined||t&&T.nodeName(e,t)?T.merge([e],a):a}function se(e,t){for(var i,n=0;null!=(i=e[n]);n++)T._data(i,"globalEval",!t||T._data(t[n],"globalEval"))}ae.tbody=ae.tfoot=ae.colgroup=ae.caption=ae.thead,ae.th=ae.td,B.option||(ae.optgroup=ae.option=[1,"<select multiple='multiple'>","</select>"]);var le=/<|&#?\w+;/,ue=/<tbody/i;function ce(e){$.test(e.type)&&(e.defaultChecked=e.checked)}function he(e,t,i,n,r){for(var a,o,s,l,u,c,h,p=e.length,d=re(t),f=[],g=0;g<p;g++)if((o=e[g])||0===o)if("object"===T.type(o))T.merge(f,o.nodeType?[o]:o);else if(le.test(o)){for(l=l||d.appendChild(t.createElement("div")),u=(ee.exec(o)||["",""])[1].toLowerCase(),h=ae[u]||ae._default,l.innerHTML=h[1]+T.htmlPrefilter(o)+h[2],a=h[0];a--;)l=l.lastChild;if(!B.leadingWhitespace&&ie.test(o)&&f.push(t.createTextNode(ie.exec(o)[0])),!B.tbody)for(a=(o="table"!==u||ue.test(o)?"<table>"!==h[1]||ue.test(o)?0:l:l.firstChild)&&o.childNodes.length;a--;)T.nodeName(c=o.childNodes[a],"tbody")&&!c.childNodes.length&&o.removeChild(c);for(T.merge(f,l.childNodes),l.textContent="";l.firstChild;)l.removeChild(l.firstChild);l=d.lastChild}else f.push(t.createTextNode(o));for(l&&d.removeChild(l),B.appendChecked||T.grep(oe(f,"input"),ce),g=0;o=f[g++];)if(n&&-1<T.inArray(o,n))r&&r.push(o);else if(s=T.contains(o.ownerDocument,o),l=oe(d.appendChild(o),"script"),s&&se(l),i)for(a=0;o=l[a++];)te.test(o.type||"")&&i.push(o);return l=null,d}!function(){var e,t,i=g.createElement("div");for(e in{submit:!0,change:!0,focusin:!0})t="on"+e,(B[e]=t in v)||(i.setAttribute(t,"t"),B[e]=!1===i.attributes[t].expando);i=null}();var pe=/^(?:input|select|textarea)$/i,de=/^key/,fe=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,ge=/^(?:focusinfocus|focusoutblur)$/,me=/^([^.]*)(?:\.(.+)|)/;function Ie(){return!0}function Be(){return!1}function Ee(){try{return g.activeElement}catch(e){}}function _e(e,t,i,n,r,a){var o,s;if("object"==typeof t){for(s in"string"!=typeof i&&(n=n||i,i=undefined),t)_e(e,s,i,n,t[s],a);return e}if(null==n&&null==r?(r=i,n=i=undefined):null==r&&("string"==typeof i?(r=n,n=undefined):(r=n,n=i,i=undefined)),!1===r)r=Be;else if(!r)return e;return 1===a&&(o=r,(r=function(e){return T().off(e),o.apply(this,arguments)}).guid=o.guid||(o.guid=T.guid++)),e.each(function(){T.event.add(this,t,r,n,i)})}T.event={global:{},add:function(e,t,i,n,r){var a,o,s,l,u,c,h,p,d,f,g,m=T._data(e);if(m){for(i.handler&&(i=(l=i).handler,r=l.selector),i.guid||(i.guid=T.guid++),(o=m.events)||(o=m.events={}),(c=m.handle)||((c=m.handle=function(e){return void 0===T||e&&T.event.triggered===e.type?undefined:T.event.dispatch.apply(c.elem,arguments)}).elem=e),s=(t=(t||"").match(k)||[""]).length;s--;)d=g=(a=me.exec(t[s])||[])[1],f=(a[2]||"").split(".").sort(),d&&(u=T.event.special[d]||{},d=(r?u.delegateType:u.bindType)||d,u=T.event.special[d]||{},h=T.extend({type:d,origType:g,data:n,handler:i,guid:i.guid,selector:r,needsContext:r&&T.expr.match.needsContext.test(r),namespace:f.join(".")},l),(p=o[d])||((p=o[d]=[]).delegateCount=0,u.setup&&!1!==u.setup.call(e,n,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=i.guid)),r?p.splice(p.delegateCount++,0,h):p.push(h),T.event.global[d]=!0);e=null}},remove:function(e,t,i,n,r){var a,o,s,l,u,c,h,p,d,f,g,m=T.hasData(e)&&T._data(e);if(m&&(c=m.events)){for(u=(t=(t||"").match(k)||[""]).length;u--;)if(d=g=(s=me.exec(t[u])||[])[1],f=(s[2]||"").split(".").sort(),d){for(h=T.event.special[d]||{},p=c[d=(n?h.delegateType:h.bindType)||d]||[],s=s[2]&&new RegExp("(^|\\.)"+f.join("\\.(?:.*\\.|)")+"(\\.|$)"),l=a=p.length;a--;)o=p[a],!r&&g!==o.origType||i&&i.guid!==o.guid||s&&!s.test(o.namespace)||n&&n!==o.selector&&("**"!==n||!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,m.handle)||T.removeEvent(e,d,m.handle),delete c[d])}else for(d in c)T.event.remove(e,d+t[u],i,n,!0);T.isEmptyObject(c)&&(delete m.handle,T._removeData(e,"events"))}},trigger:function(e,t,i,n){var r,a,o,s,l,u,c=[i||g],h=I.call(e,"type")?e.type:e,p=I.call(e,"namespace")?e.namespace.split("."):[],d=l=i=i||g;if(3!==i.nodeType&&8!==i.nodeType&&!ge.test(h+T.event.triggered)&&(-1<h.indexOf(".")&&(h=(p=h.split(".")).shift(),p.sort()),a=h.indexOf(":")<0&&"on"+h,(e=e[T.expando]?e:new T.Event(h,"object"==typeof e&&e)).isTrigger=n?2:3,e.namespace=p.join("."),e.rnamespace=e.namespace?new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,e.result=undefined,e.target||(e.target=i),t=null==t?[e]:T.makeArray(t,[e]),s=T.event.special[h]||{},n||!s.trigger||!1!==s.trigger.apply(i,t))){if(!n&&!s.noBubble&&!T.isWindow(i)){for(o=s.delegateType||h,ge.test(o+h)||(d=d.parentNode);d;d=d.parentNode)c.push(d),l=d;l===(i.ownerDocument||g)&&c.push(l.defaultView||l.parentWindow||v)}for(u=0;(d=c[u++])&&!e.isPropagationStopped();)e.type=1<u?o:s.bindType||h,(r=(T._data(d,"events")||{})[e.type]&&T._data(d,"handle"))&&r.apply(d,t),(r=a&&d[a])&&r.apply&&R(d)&&(e.result=r.apply(d,t),!1===e.result&&e.preventDefault());if(e.type=h,!n&&!e.isDefaultPrevented()&&(!s._default||!1===s._default.apply(c.pop(),t))&&R(i)&&a&&i[h]&&!T.isWindow(i)){(l=i[a])&&(i[a]=null),T.event.triggered=h;try{i[h]()}catch(f){}T.event.triggered=undefined,l&&(i[a]=l)}return e.result}},dispatch:function(e){e=T.event.fix(e);var t,i,n,r,a,o,s=c.call(arguments),l=(T._data(this,"events")||{})[e.type]||[],u=T.event.special[e.type]||{};if((s[0]=e).delegateTarget=this,!u.preDispatch||!1!==u.preDispatch.call(this,e)){for(o=T.event.handlers.call(this,e,l),t=0;(r=o[t++])&&!e.isPropagationStopped();)for(e.currentTarget=r.elem,i=0;(a=r.handlers[i++])&&!e.isImmediatePropagationStopped();)e.rnamespace&&!e.rnamespace.test(a.namespace)||(e.handleObj=a,e.data=a.data,(n=((T.event.special[a.origType]||{}).handle||a.handler).apply(r.elem,s))!==undefined&&!1===(e.result=n)&&(e.preventDefault(),e.stopPropagation()));return u.postDispatch&&u.postDispatch.call(this,e),e.result}},handlers:function(e,t){var i,n,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(n=[],i=0;i<s;i++)n[r=(a=t[i]).selector+" "]===undefined&&(n[r]=a.needsContext?-1<T(r,this).index(l):T.find(r,this,null,[l]).length),n[r]&&n.push(a);n.length&&o.push({elem:l,handlers:n})}return s<t.length&&o.push({elem:this,handlers:t.slice(s)}),o},fix:function(e){if(e[T.expando])return e;var t,i,n,r=e.type,a=e,o=this.fixHooks[r];for(o||(this.fixHooks[r]=o=fe.test(r)?this.mouseHooks:de.test(r)?this.keyHooks:{}),n=o.props?this.props.concat(o.props):this.props,e=new T.Event(a),t=n.length;t--;)e[i=n[t]]=a[i];return e.target||(e.target=a.srcElement||g),3===e.target.nodeType&&(e.target=e.target.parentNode),e.metaKey=!!e.metaKey,o.filter?o.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 i,n,r,a=t.button,o=t.fromElement;return null==e.pageX&&null!=t.clientX&&(r=(n=e.target.ownerDocument||g).documentElement,i=n.body,e.pageX=t.clientX+(r&&r.scrollLeft||i&&i.scrollLeft||0)-(r&&r.clientLeft||i&&i.clientLeft||0),e.pageY=t.clientY+(r&&r.scrollTop||i&&i.scrollTop||0)-(r&&r.clientTop||i&&i.clientTop||0)),!e.relatedTarget&&o&&(e.relatedTarget=o===e.target?t.toElement:o),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!==Ee()&&this.focus)try{return this.focus(),!1}catch(e){}},delegateType:"focusin"},blur:{trigger:function(){if(this===Ee()&&this.blur)return this.blur(),!1},delegateType:"focusout"},click:{trigger:function(){if(T.nodeName(this,"input")&&"checkbox"===this.type&&this.click)return this.click(),!1},_default:function(e){return T.nodeName(e.target,"a")}},beforeunload:{postDispatch:function(e){e.result!==undefined&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}},simulate:function(e,t,i){var n=T.extend(new T.Event,i,{type:e,isSimulated:!0});T.event.trigger(n,null,t),n.isDefaultPrevented()&&i.preventDefault()}},T.removeEvent=g.removeEventListener?function(e,t,i){e.removeEventListener&&e.removeEventListener(t,i)}:function(e,t,i){var n="on"+t;e.detachEvent&&("undefined"==typeof e[n]&&(e[n]=null),e.detachEvent(n,i))},T.Event=function(e,t){if(!(this instanceof T.Event))return new T.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||e.defaultPrevented===undefined&&!1===e.returnValue?Ie:Be):this.type=e,t&&T.extend(this,t),this.timeStamp=e&&e.timeStamp||T.now(),this[T.expando]=!0},T.Event.prototype={constructor:T.Event,isDefaultPrevented:Be,isPropagationStopped:Be,isImmediatePropagationStopped:Be,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=Ie,e&&(e.preventDefault?e.preventDefault():e.returnValue=!1)},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=Ie,e&&!this.isSimulated&&(e.stopPropagation&&e.stopPropagation(),e.cancelBubble=!0)},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=Ie,e&&e.stopImmediatePropagation&&e.stopImmediatePropagation(),this.stopPropagation()}},T.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,r){T.event.special[e]={delegateType:r,bindType:r,handle:function(e){var t,i=e.relatedTarget,n=e.handleObj;return i&&(i===this||T.contains(this,i))||(e.type=n.origType,t=n.handler.apply(this,arguments),e.type=r),t}}}),B.submit||(T.event.special.submit={setup:function(){if(T.nodeName(this,"form"))return!1;T.event.add(this,"click._submit keypress._submit",function(e){var t=e.target,i=T.nodeName(t,"input")||T.nodeName(t,"button")?T.prop(t,"form"):undefined;i&&!T._data(i,"submit")&&(T.event.add(i,"submit._submit",function(e){e._submitBubble=!0}),T._data(i,"submit",!0))})},postDispatch:function(e){e._submitBubble&&(delete e._submitBubble,this.parentNode&&!e.isTrigger&&T.event.simulate("submit",this.parentNode,e))},teardown:function(){if(T.nodeName(this,"form"))return!1;T.event.remove(this,"._submit")}}),B.change||(T.event.special.change={setup:function(){if(pe.test(this.nodeName))return"checkbox"!==this.type&&"radio"!==this.type||(T.event.add(this,"propertychange._change",function(e){"checked"===e.originalEvent.propertyName&&(this._justChanged=!0)}),T.event.add(this,"click._change",function(e){this._justChanged&&!e.isTrigger&&(this._justChanged=!1),T.event.simulate("change",this,e)})),!1;T.event.add(this,"beforeactivate._change",function(e){var t=e.target;pe.test(t.nodeName)&&!T._data(t,"change")&&(T.event.add(t,"change._change",function(e){!this.parentNode||e.isSimulated||e.isTrigger||T.event.simulate("change",this.parentNode,e)}),T._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 T.event.remove(this,"._change"),!pe.test(this.nodeName)}}),B.focusin||T.each({focus:"focusin",blur:"focusout"},function(i,n){var r=function(e){T.event.simulate(n,e.target,T.event.fix(e))};T.event.special[n]={setup:function(){var e=this.ownerDocument||this,t=T._data(e,n);t||e.addEventListener(i,r,!0),T._data(e,n,(t||0)+1)},teardown:function(){var e=this.ownerDocument||this,t=T._data(e,n)-1;t?T._data(e,n,t):(e.removeEventListener(i,r,!0),T._removeData(e,n))}}}),T.fn.extend({on:function(e,t,i,n){return _e(this,e,t,i,n)},one:function(e,t,i,n){return _e(this,e,t,i,n,1)},off:function(e,t,i){var n,r;if(e&&e.preventDefault&&e.handleObj)return n=e.handleObj,T(e.delegateTarget).off(n.namespace?n.origType+"."+n.namespace:n.origType,n.selector,n.handler),this;if("object"!=typeof e)return!1!==t&&"function"!=typeof t||(i=t,t=undefined),!1===i&&(i=Be),this.each(function(){T.event.remove(this,e,i,t)});for(r in e)this.off(r,t,e[r]);return this},trigger:function(e,t){return this.each(function(){T.event.trigger(e,t,this)})},triggerHandler:function(e,t){var i=this[0];if(i)return T.event.trigger(e,t,i,!0)}});var be=/ jQuery\d+="(?:null|\d+)"/g,ye=new RegExp("<(?:"+ne+")[\\s/>]","i"),ve=/<script|<style|<link/i,Te=/checked\s*(?:[^=]|=\s*.checked.)/i,Ce=/^true\/(.*)/,Ne=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,Ve=re(g).appendChild(g.createElement("div"));function Se(e,t){return T.nodeName(e,"table")&&T.nodeName(11!==t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function xe(e){return e.type=(null!==T.find.attr(e,"type"))+"/"+e.type,e}function we(e){var t=Ce.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function Ae(e,t){if(1===t.nodeType&&T.hasData(e)){var i,n,r,a=T._data(e),o=T._data(t,a),s=a.events;if(s)for(i in delete o.handle,o.events={},s)for(n=0,r=s[i].length;n<r;n++)T.event.add(t,i,s[i][n]);o.data&&(o.data=T.extend({},o.data))}}function Le(i,n,r,a){n=m.apply([],n);var e,t,o,s,l,u,c=0,h=i.length,p=h-1,d=n[0],f=T.isFunction(d);if(f||1<h&&"string"==typeof d&&!B.checkClone&&Te.test(d))return i.each(function(e){var t=i.eq(e);f&&(n[0]=d.call(this,e,t.html())),Le(t,n,r,a)});if(h&&(e=(u=he(n,i[0].ownerDocument,!1,i,a)).firstChild,1===u.childNodes.length&&(u=e),e||a)){for(o=(s=T.map(oe(u,"script"),xe)).length;c<h;c++)t=u,c!==p&&(t=T.clone(t,!0,!0),o&&T.merge(s,oe(t,"script"))),r.call(i[c],t,c);if(o)for(l=s[s.length-1].ownerDocument,T.map(s,we),c=0;c<o;c++)t=s[c],te.test(t.type||"")&&!T._data(t,"globalEval")&&T.contains(l,t)&&(t.src?T._evalUrl&&T._evalUrl(t.src):T.globalEval((t.text||t.textContent||t.innerHTML||"").replace(Ne,"")));u=e=null}return i}function ke(e,t,i){for(var n,r=t?T.filter(t,e):e,a=0;null!=(n=r[a]);a++)i||1!==n.nodeType||T.cleanData(oe(n)),n.parentNode&&(i&&T.contains(n.ownerDocument,n)&&se(oe(n,"script")),n.parentNode.removeChild(n));return e}T.extend({htmlPrefilter:function(e){return e},clone:function(e,t,i){var n,r,a,o,s,l=T.contains(e.ownerDocument,e);if(B.html5Clone||T.isXMLDoc(e)||!ye.test("<"+e.nodeName+">")?a=e.cloneNode(!0):(Ve.innerHTML=e.outerHTML,Ve.removeChild(a=Ve.firstChild)),!(B.noCloneEvent&&B.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||T.isXMLDoc(e)))for(n=oe(a),s=oe(e),o=0;null!=(r=s[o]);++o)n[o]&&function(e,t){var i,n,r;if(1===t.nodeType){if(i=t.nodeName.toLowerCase(),!B.noCloneEvent&&t[T.expando]){for(n in(r=T._data(t)).events)T.removeEvent(t,n,r.handle);t.removeAttribute(T.expando)}"script"===i&&t.text!==e.text?(xe(t).text=e.text,we(t)):"object"===i?(t.parentNode&&(t.outerHTML=e.outerHTML),B.html5Clone&&e.innerHTML&&!T.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):"input"===i&&$.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):"option"===i?t.defaultSelected=t.selected=e.defaultSelected:"input"!==i&&"textarea"!==i||(t.defaultValue=e.defaultValue)}}(r,n[o]);if(t)if(i)for(s=s||oe(e),n=n||oe(a),o=0;null!=(r=s[o]);o++)Ae(r,n[o]);else Ae(e,a);return 0<(n=oe(a,"script")).length&&se(n,!l&&oe(e,"script")),n=s=r=null,a},cleanData:function(e,t){for(var i,n,r,a,o=0,s=T.expando,l=T.cache,u=B.attributes,c=T.event.special;null!=(i=e[o]);o++)if((t||R(i))&&(a=(r=i[s])&&l[r])){if(a.events)for(n in a.events)c[n]?T.event.remove(i,n):T.removeEvent(i,n,a.handle);l[r]&&(delete l[r],u||"undefined"==typeof i.removeAttribute?i[s]=undefined:i.removeAttribute(s),h.push(r))}}}),T.fn.extend({domManip:Le,detach:function(e){return ke(this,e,!0)},remove:function(e){return ke(this,e)},text:function(e){return q(this,function(e){return e===undefined?T.text(this):this.empty().append((this[0]&&this[0].ownerDocument||g).createTextNode(e))},null,e,arguments.length)},append:function(){return Le(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||Se(this,e).appendChild(e)})},prepend:function(){return Le(this,arguments,function(e){var t;1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(t=Se(this,e)).insertBefore(e,t.firstChild)})},before:function(){return Le(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return Le(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&&T.cleanData(oe(e,!1));e.firstChild;)e.removeChild(e.firstChild);e.options&&T.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 T.clone(this,e,t)})},html:function(e){return q(this,function(e){var t=this[0]||{},i=0,n=this.length;if(e===undefined)return 1===t.nodeType?t.innerHTML.replace(be,""):undefined;if("string"==typeof e&&!ve.test(e)&&(B.htmlSerialize||!ye.test(e))&&(B.leadingWhitespace||!ie.test(e))&&!ae[(ee.exec(e)||["",""])[1].toLowerCase()]){e=T.htmlPrefilter(e);try{for(;i<n;i++)1===(t=this[i]||{}).nodeType&&(T.cleanData(oe(t,!1)),t.innerHTML=e);t=0}catch(r){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var i=[];return Le(this,arguments,function(e){var t=this.parentNode;T.inArray(this,i)<0&&(T.cleanData(oe(this)),t&&t.replaceChild(e,this))},i)}}),T.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,o){T.fn[e]=function(e){for(var t,i=0,n=[],r=T(e),a=r.length-1;i<=a;i++)t=i===a?this:this.clone(!0),T(r[i])[o](t),s.apply(n,t.get());return this.pushStack(n)}});var De,Pe={HTML:"block",BODY:"block"};function Me(e,t){var i=T(t.createElement(e)).appendTo(t.body),n=T.css(i[0],"display");return i.detach(),n}function Re(e){var t=g,i=Pe[e];return i||("none"!==(i=Me(e,t))&&i||((t=((De=(De||T("<iframe frameborder='0' width='0' height='0'/>")).appendTo(t.documentElement))[0].contentWindow||De[0].contentDocument).document).write(),t.close(),i=Me(e,t),De.detach()),Pe[e]=i),i}var He,Oe,Fe,Ye,We,Ge,je,Ze,Xe=/^margin/,Ue=new RegExp("^("+j+")(?!px)[a-z%]+$","i"),Je=function(e,t,i,n){var r,a,o={};for(a in t)o[a]=e.style[a],e.style[a]=t[a];for(a in r=i.apply(e,n||[]),t)e.style[a]=o[a];return r},Ke=g.documentElement;function ze(){var e,t,i=g.documentElement;i.appendChild(je),Ze.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%",He=Fe=Ge=!1,Oe=We=!0,v.getComputedStyle&&(t=v.getComputedStyle(Ze),He="1%"!==(t||{}).top,Ge="2px"===(t||{}).marginLeft,Fe="4px"===(t||{width:"4px"}).width,Ze.style.marginRight="50%",Oe="4px"===(t||{marginRight:"4px"}).marginRight,(e=Ze.appendChild(g.createElement("div"))).style.cssText=Ze.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",e.style.marginRight=e.style.width="0",Ze.style.width="1px",We=!parseFloat((v.getComputedStyle(e)||{}).marginRight),Ze.removeChild(e)),Ze.style.display="none",(Ye=0===Ze.getClientRects().length)&&(Ze.style.display="",Ze.innerHTML="<table><tr><td></td><td>t</td></tr></table>",Ze.childNodes[0].style.borderCollapse="separate",(e=Ze.getElementsByTagName("td"))[0].style.cssText="margin:0;border:0;padding:0;display:none",(Ye=0===e[0].offsetHeight)&&(e[0].style.display="",e[1].style.display="none",Ye=0===e[0].offsetHeight)),i.removeChild(je)}je=g.createElement("div"),(Ze=g.createElement("div")).style&&(Ze.style.cssText="float:left;opacity:.5",B.opacity="0.5"===Ze.style.opacity,B.cssFloat=!!Ze.style.cssFloat,Ze.style.backgroundClip="content-box",Ze.cloneNode(!0).style.backgroundClip="",B.clearCloneStyle="content-box"===Ze.style.backgroundClip,(je=g.createElement("div")).style.cssText="border:0;width:8px;height:0;top:0;left:-9999px;padding:0;margin-top:1px;position:absolute",Ze.innerHTML="",je.appendChild(Ze),B.boxSizing=""===Ze.style.boxSizing||""===Ze.style.MozBoxSizing||""===Ze.style.WebkitBoxSizing,T.extend(B,{reliableHiddenOffsets:function(){return null==He&&ze(),Ye},boxSizingReliable:function(){return null==He&&ze(),Fe},pixelMarginRight:function(){return null==He&&ze(),Oe},pixelPosition:function(){return null==He&&ze(),He},reliableMarginRight:function(){return null==He&&ze(),We},reliableMarginLeft:function(){return null==He&&ze(),Ge}}));var Qe,qe,$e=/^(top|right|bottom|left)$/;function et(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}v.getComputedStyle?(Qe=function(e){var t=e.ownerDocument.defaultView;return t&&t.opener||(t=v),t.getComputedStyle(e)},qe=function(e,t,i){var n,r,a,o,s=e.style;return""!==(o=(i=i||Qe(e))?i.getPropertyValue(t)||i[t]:undefined)&&o!==undefined||T.contains(e.ownerDocument,e)||(o=T.style(e,t)),i&&!B.pixelMarginRight()&&Ue.test(o)&&Xe.test(t)&&(n=s.width,r=s.minWidth,a=s.maxWidth,s.minWidth=s.maxWidth=s.width=o,o=i.width,s.width=n,s.minWidth=r,s.maxWidth=a),o===undefined?o:o+""}):Ke.currentStyle&&(Qe=function(e){return e.currentStyle},qe=function(e,t,i){var n,r,a,o,s=e.style;return null==(o=(i=i||Qe(e))?i[t]:undefined)&&s&&s[t]&&(o=s[t]),Ue.test(o)&&!$e.test(t)&&(n=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=n,a&&(r.left=a)),o===undefined?o:o+""||"auto"});var tt=/alpha\([^)]*\)/i,it=/opacity\s*=\s*([^)]*)/i,nt=/^(none|table(?!-c[ea]).+)/,rt=new RegExp("^("+j+")(.*)$","i"),at={position:"absolute",visibility:"hidden",display:"block"},ot={letterSpacing:"0",fontWeight:"400"},st=["Webkit","O","Moz","ms"],lt=g.createElement("div").style;function ut(e){if(e in lt)return e;for(var t=e.charAt(0).toUpperCase()+e.slice(1),i=st.length;i--;)if((e=st[i]+t)in lt)return e}function ct(e,t){for(var i,n,r,a=[],o=0,s=e.length;o<s;o++)(n=e[o]).style&&(a[o]=T._data(n,"olddisplay"),i=n.style.display,t?(a[o]||"none"!==i||(n.style.display=""),""===n.style.display&&U(n)&&(a[o]=T._data(n,"olddisplay",Re(n.nodeName)))):(r=U(n),(i&&"none"!==i||!r)&&T._data(n,"olddisplay",r?i:T.css(n,"display"))));for(o=0;o<s;o++)(n=e[o]).style&&(t&&"none"!==n.style.display&&""!==n.style.display||(n.style.display=t?a[o]||"":"none"));return e}function ht(e,t,i){var n=rt.exec(t);return n?Math.max(0,n[1]-(i||0))+(n[2]||"px"):t}function pt(e,t,i,n,r){for(var a=i===(n?"border":"content")?4:"width"===t?1:0,o=0;a<4;a+=2)"margin"===i&&(o+=T.css(e,i+X[a],!0,r)),n?("content"===i&&(o-=T.css(e,"padding"+X[a],!0,r)),"margin"!==i&&(o-=T.css(e,"border"+X[a]+"Width",!0,r))):(o+=T.css(e,"padding"+X[a],!0,r),"padding"!==i&&(o+=T.css(e,"border"+X[a]+"Width",!0,r)));return o}function dt(e,t,i){var n=!0,r="width"===t?e.offsetWidth:e.offsetHeight,a=Qe(e),o=B.boxSizing&&"border-box"===T.css(e,"boxSizing",!1,a);if(r<=0||null==r){if(((r=qe(e,t,a))<0||null==r)&&(r=e.style[t]),Ue.test(r))return r;n=o&&(B.boxSizingReliable()||r===e.style[t]),r=parseFloat(r)||0}return r+pt(e,t,i||(o?"border":"content"),n,a)+"px"}function ft(e,t,i,n,r){return new ft.prototype.init(e,t,i,n,r)}T.extend({cssHooks:{opacity:{get:function(e,t){if(t){var i=qe(e,"opacity");return""===i?"1":i}}}},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":B.cssFloat?"cssFloat":"styleFloat"},style:function(e,t,i,n){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var r,a,o,s=T.camelCase(t),l=e.style;if(t=T.cssProps[s]||(T.cssProps[s]=ut(s)||s),o=T.cssHooks[t]||T.cssHooks[s],i===undefined)return o&&"get"in o&&(r=o.get(e,!1,n))!==undefined?r:l[t];if("string"===(a=typeof i)&&(r=Z.exec(i))&&r[1]&&(i=J(e,t,r),a="number"),null!=i&&i==i&&("number"===a&&(i+=r&&r[3]||(T.cssNumber[s]?"":"px")),B.clearCloneStyle||""!==i||0!==t.indexOf("background")||(l[t]="inherit"),!(o&&"set"in o&&(i=o.set(e,i,n))===undefined)))try{l[t]=i}catch(u){}}},css:function(e,t,i,n){var r,a,o,s=T.camelCase(t);return t=T.cssProps[s]||(T.cssProps[s]=ut(s)||s),(o=T.cssHooks[t]||T.cssHooks[s])&&"get"in o&&(a=o.get(e,!0,i)),a===undefined&&(a=qe(e,t,n)),"normal"===a&&t in ot&&(a=ot[t]),""===i||i?(r=parseFloat(a),!0===i||isFinite(r)?r||0:a):a}}),T.each(["height","width"],function(e,r){T.cssHooks[r]={get:function(e,t,i){if(t)return nt.test(T.css(e,"display"))&&0===e.offsetWidth?Je(e,at,function(){return dt(e,r,i)}):dt(e,r,i)},set:function(e,t,i){var n=i&&Qe(e);return ht(0,t,i?pt(e,r,i,B.boxSizing&&"border-box"===T.css(e,"boxSizing",!1,n),n):0)}}}),B.opacity||(T.cssHooks.opacity={get:function(e,t){return it.test((t&&e.currentStyle?e.currentStyle.filter:e.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":t?"1":""},set:function(e,t){var i=e.style,n=e.currentStyle,r=T.isNumeric(t)?"alpha(opacity="+100*t+")":"",a=n&&n.filter||i.filter||"";((i.zoom=1)<=t||""===t)&&""===T.trim(a.replace(tt,""))&&i.removeAttribute&&(i.removeAttribute("filter"),""===t||n&&!n.filter)||(i.filter=tt.test(a)?a.replace(tt,r):a+" "+r)}}),T.cssHooks.marginRight=et(B.reliableMarginRight,function(e,t){if(t)return Je(e,{display:"inline-block"},qe,[e,"marginRight"])}),T.cssHooks.marginLeft=et(B.reliableMarginLeft,function(e,t){if(t)return(parseFloat(qe(e,"marginLeft"))||(T.contains(e.ownerDocument,e)?e.getBoundingClientRect().left-Je(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}):0))+"px"}),T.each({margin:"",padding:"",border:"Width"},function(r,a){T.cssHooks[r+a]={expand:function(e){for(var t=0,i={},n="string"==typeof e?e.split(" "):[e];t<4;t++)i[r+X[t]+a]=n[t]||n[t-2]||n[0];return i}},Xe.test(r)||(T.cssHooks[r+a].set=ht)}),T.fn.extend({css:function(e,t){return q(this,function(e,t,i){var n,r,a={},o=0;if(T.isArray(t)){for(n=Qe(e),r=t.length;o<r;o++)a[t[o]]=T.css(e,t[o],!1,n);return a}return i!==undefined?T.style(e,t,i):T.css(e,t)},e,t,1<arguments.length)},show:function(){return ct(this,!0)},hide:function(){return ct(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){U(this)?T(this).show():T(this).hide()})}}),(T.Tween=ft).prototype={constructor:ft,init:function(e,t,i,n,r,a){this.elem=e,this.prop=i,this.easing=r||T.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=n,this.unit=a||(T.cssNumber[i]?"":"px")},cur:function(){var e=ft.propHooks[this.prop];return e&&e.get?e.get(this):ft.propHooks._default.get(this)},run:function(e){var t,i=ft.propHooks[this.prop];return this.options.duration?this.pos=t=T.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),i&&i.set?i.set(this):ft.propHooks._default.set(this),this}},ft.prototype.init.prototype=ft.prototype,ft.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=T.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){T.fx.step[e.prop]?T.fx.step[e.prop](e):1!==e.elem.nodeType||null==e.elem.style[T.cssProps[e.prop]]&&!T.cssHooks[e.prop]?e.elem[e.prop]=e.now:T.style(e.elem,e.prop,e.now+e.unit)}}},ft.propHooks.scrollTop=ft.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},T.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},T.fx=ft.prototype.init,T.fx.step={};var gt,mt,It,Bt,Et,_t,bt,yt=/^(?:toggle|show|hide)$/,vt=/queueHooks$/;function Tt(){return v.setTimeout(function(){gt=undefined}),gt=T.now()}function Ct(e,t){var i,n={height:e},r=0;for(t=t?1:0;r<4;r+=2-t)n["margin"+(i=X[r])]=n["padding"+i]=e;return t&&(n.opacity=n.width=e),n}function Nt(e,t,i){for(var n,r=(Vt.tweeners[t]||[]).concat(Vt.tweeners["*"]),a=0,o=r.length;a<o;a++)if(n=r[a].call(i,t,e))return n}function Vt(a,e,t){var i,o,n=0,r=Vt.prefilters.length,s=T.Deferred().always(function(){delete l.elem}),l=function(){if(o)return!1;for(var e=gt||Tt(),t=Math.max(0,u.startTime+u.duration-e),i=1-(t/u.duration||0),n=0,r=u.tweens.length;n<r;n++)u.tweens[n].run(i);return s.notifyWith(a,[u,i,t]),i<1&&r?t:(s.resolveWith(a,[u]),!1)},u=s.promise({elem:a,props:T.extend({},e),opts:T.extend(!0,{specialEasing:{},easing:T.easing._default},t),originalProperties:e,originalOptions:t,startTime:gt||Tt(),duration:t.duration,tweens:[],createTween:function(e,t){var i=T.Tween(a,u.opts,e,t,u.opts.specialEasing[e]||u.opts.easing);return u.tweens.push(i),i},stop:function(e){var t=0,i=e?u.tweens.length:0;if(o)return this;for(o=!0;t<i;t++)u.tweens[t].run(1);return e?(s.notifyWith(a,[u,1,0]),s.resolveWith(a,[u,e])):s.rejectWith(a,[u,e]),this}}),c=u.props;for(!function(e,t){var i,n,r,a,o;for(i in e)if(r=t[n=T.camelCase(i)],a=e[i],T.isArray(a)&&(r=a[1],a=e[i]=a[0]),i!==n&&(e[n]=a,delete e[i]),(o=T.cssHooks[n])&&"expand"in o)for(i in a=o.expand(a),delete e[n],a)i in e||(e[i]=a[i],t[i]=r);else t[n]=r}(c,u.opts.specialEasing);n<r;n++)if(i=Vt.prefilters[n].call(u,a,c,u.opts))return T.isFunction(i.stop)&&(T._queueHooks(u.elem,u.opts.queue).stop=T.proxy(i.stop,i)),i;return T.map(c,Nt,u),T.isFunction(u.opts.start)&&u.opts.start.call(a,u),T.fx.timer(T.extend(l,{elem:a,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)}T.Animation=T.extend(Vt,{tweeners:{"*":[function(e,t){var i=this.createTween(e,t);return J(i.elem,e,Z.exec(t),i),i}]},tweener:function(e,t){for(var i,n=0,r=(e=T.isFunction(e)?(t=e,["*"]):e.match(k)).length;n<r;n++)i=e[n],Vt.tweeners[i]=Vt.tweeners[i]||[],Vt.tweeners[i].unshift(t)},prefilters:[function(t,e,i){var n,r,a,o,s,l,u,c=this,h={},p=t.style,d=t.nodeType&&U(t),f=T._data(t,"fxshow");for(n in i.queue||(null==(s=T._queueHooks(t,"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--,T.queue(t,"fx").length||s.empty.fire()})})),1===t.nodeType&&("height"in e||"width"in e)&&(i.overflow=[p.overflow,p.overflowX,p.overflowY],"inline"===("none"===(u=T.css(t,"display"))?T._data(t,"olddisplay")||Re(t.nodeName):u)&&"none"===T.css(t,"float")&&(B.inlineBlockNeedsLayout&&"inline"!==Re(t.nodeName)?p.zoom=1:p.display="inline-block")),i.overflow&&(p.overflow="hidden",B.shrinkWrapBlocks()||c.always(function(){p.overflow=i.overflow[0],p.overflowX=i.overflow[1],p.overflowY=i.overflow[2]})),e)if(r=e[n],yt.exec(r)){if(delete e[n],a=a||"toggle"===r,r===(d?"hide":"show")){if("show"!==r||!f||f[n]===undefined)continue;d=!0}h[n]=f&&f[n]||T.style(t,n)}else u=undefined;if(T.isEmptyObject(h))"inline"===("none"===u?Re(t.nodeName):u)&&(p.display=u);else for(n in f?"hidden"in f&&(d=f.hidden):f=T._data(t,"fxshow",{}),a&&(f.hidden=!d),d?T(t).show():c.done(function(){T(t).hide()}),c.done(function(){var e;for(e in T._removeData(t,"fxshow"),h)T.style(t,e,h[e])}),h)o=Nt(d?f[n]:0,n,c),n in f||(f[n]=o.start,d&&(o.end=o.start,o.start="width"===n||"height"===n?1:0))}],prefilter:function(e,t){t?Vt.prefilters.unshift(e):Vt.prefilters.push(e)}}),T.speed=function(e,t,i){var n=e&&"object"==typeof e?T.extend({},e):{complete:i||!i&&t||T.isFunction(e)&&e,duration:e,easing:i&&t||t&&!T.isFunction(t)&&t};return n.duration=T.fx.off?0:"number"==typeof n.duration?n.duration:n.duration in T.fx.speeds?T.fx.speeds[n.duration]:T.fx.speeds._default,null!=n.queue&&!0!==n.queue||(n.queue="fx"),n.old=n.complete,n.complete=function(){T.isFunction(n.old)&&n.old.call(this),n.queue&&T.dequeue(this,n.queue)},n},T.fn.extend({fadeTo:function(e,t,i,n){return this.filter(U).css("opacity",0).show().end().animate({opacity:t},e,i,n)},animate:function(t,e,i,n){var r=T.isEmptyObject(t),a=T.speed(e,i,n),o=function(){var e=Vt(this,T.extend({},t),a);(r||T._data(this,"finish"))&&e.stop(!0)};return o.finish=o,r||!1===a.queue?this.each(o):this.queue(a.queue,o)},stop:function(r,e,a){var o=function(e){var t=e.stop;delete e.stop,t(a)};return"string"!=typeof r&&(a=e,e=r,r=undefined),e&&!1!==r&&this.queue(r||"fx",[]),this.each(function(){var e=!0,t=null!=r&&r+"queueHooks",i=T.timers,n=T._data(this);if(t)n[t]&&n[t].stop&&o(n[t]);else for(t in n)n[t]&&n[t].stop&&vt.test(t)&&o(n[t]);for(t=i.length;t--;)i[t].elem!==this||null!=r&&i[t].queue!==r||(i[t].anim.stop(a),e=!1,i.splice(t,1));!e&&a||T.dequeue(this,r)})},finish:function(o){return!1!==o&&(o=o||"fx"),this.each(function(){var e,t=T._data(this),i=t[o+"queue"],n=t[o+"queueHooks"],r=T.timers,a=i?i.length:0;for(t.finish=!0,T.queue(this,o,[]),n&&n.stop&&n.stop.call(this,!0),e=r.length;e--;)r[e].elem===this&&r[e].queue===o&&(r[e].anim.stop(!0),r.splice(e,1));for(e=0;e<a;e++)i[e]&&i[e].finish&&i[e].finish.call(this);delete t.finish})}}),T.each(["toggle","show","hide"],function(e,n){var r=T.fn[n];T.fn[n]=function(e,t,i){return null==e||"boolean"==typeof e?r.apply(this,arguments):this.animate(Ct(n,!0),e,t,i)}}),T.each({slideDown:Ct("show"),slideUp:Ct("hide"),slideToggle:Ct("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,n){T.fn[e]=function(e,t,i){return this.animate(n,e,t,i)}}),T.timers=[],T.fx.tick=function(){var e,t=T.timers,i=0;for(gt=T.now();i<t.length;i++)(e=t[i])()||t[i]!==e||t.splice(i--,1);t.length||T.fx.stop(),gt=undefined},T.fx.timer=function(e){T.timers.push(e),e()?T.fx.start():T.timers.pop()},T.fx.interval=13,T.fx.start=function(){mt=mt||v.setInterval(T.fx.tick,T.fx.interval)},T.fx.stop=function(){v.clearInterval(mt),mt=null},T.fx.speeds={slow:600,fast:200,_default:400},T.fn.delay=function(n,e){return n=T.fx&&T.fx.speeds[n]||n,e=e||"fx",this.queue(e,function(e,t){var i=v.setTimeout(e,n);t.stop=function(){v.clearTimeout(i)}})},Bt=g.createElement("input"),Et=g.createElement("div"),_t=g.createElement("select"),bt=_t.appendChild(g.createElement("option")),(Et=g.createElement("div")).setAttribute("className","t"),Et.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",It=Et.getElementsByTagName("a")[0],Bt.setAttribute("type","checkbox"),Et.appendChild(Bt),(It=Et.getElementsByTagName("a")[0]).style.cssText="top:1px",B.getSetAttribute="t"!==Et.className,B.style=/top/.test(It.getAttribute("style")),B.hrefNormalized="/a"===It.getAttribute("href"),B.checkOn=!!Bt.value,B.optSelected=bt.selected,B.enctype=!!g.createElement("form").enctype,_t.disabled=!0,B.optDisabled=!bt.disabled,(Bt=g.createElement("input")).setAttribute("value",""),B.input=""===Bt.getAttribute("value"),Bt.value="t",Bt.setAttribute("type","radio"),B.radioValue="t"===Bt.value;var St=/\r/g,xt=/[\x20\t\r\n\f]+/g;T.fn.extend({val:function(i){var n,e,r,t=this[0];return arguments.length?(r=T.isFunction(i),this.each(function(e){var t;1===this.nodeType&&(null==(t=r?i.call(this,e,T(this).val()):i)?t="":"number"==typeof t?t+="":T.isArray(t)&&(t=T.map(t,function(e){return null==e?"":e+""})),(n=T.valHooks[this.type]||T.valHooks[this.nodeName.toLowerCase()])&&"set"in n&&n.set(this,t,"value")!==undefined||(this.value=t))})):t?(n=T.valHooks[t.type]||T.valHooks[t.nodeName.toLowerCase()])&&"get"in n&&(e=n.get(t,"value"))!==undefined?e:"string"==typeof(e=t.value)?e.replace(St,""):null==e?"":e:void 0}}),T.extend({valHooks:{option:{get:function(e){var t=T.find.attr(e,"value");return null!=t?t:T.trim(T.text(e)).replace(xt," ")}},select:{get:function(e){for(var t,i,n=e.options,r=e.selectedIndex,a="select-one"===e.type||r<0,o=a?null:[],s=a?r+1:n.length,l=r<0?s:a?r:0;l<s;l++)if(((i=n[l]).selected||l===r)&&(B.optDisabled?!i.disabled:null===i.getAttribute("disabled"))&&(!i.parentNode.disabled||!T.nodeName(i.parentNode,"optgroup"))){if(t=T(i).val(),a)return t;o.push(t)}return o},set:function(e,t){for(var i,n,r=e.options,a=T.makeArray(t),o=r.length;o--;)if(n=r[o],-1<T.inArray(T.valHooks.option.get(n),a))try{n.selected=i=!0}catch(_){n.scrollHeight}else n.selected=!1;return i||(e.selectedIndex=-1),r}}}}),T.each(["radio","checkbox"],function(){T.valHooks[this]={set:function(e,t){if(T.isArray(t))return e.checked=-1<T.inArray(T(e).val(),t)}},B.checkOn||(T.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})});var wt,At,Lt=T.expr.attrHandle,kt=/^(?:checked|selected)$/i,Dt=B.getSetAttribute,Pt=B.input;T.fn.extend({attr:function(e,t){return q(this,T.attr,e,t,1<arguments.length)},removeAttr:function(e){return this.each(function(){T.removeAttr(this,e)})}}),T.extend({attr:function(e,t,i){var n,r,a=e.nodeType;if(3!==a&&8!==a&&2!==a)return"undefined"==typeof e.getAttribute?T.prop(e,t,i):(1===a&&T.isXMLDoc(e)||(t=t.toLowerCase(),r=T.attrHooks[t]||(T.expr.match.bool.test(t)?At:wt)),i!==undefined?null===i?void T.removeAttr(e,t):r&&"set"in r&&(n=r.set(e,i,t))!==undefined?n:(e.setAttribute(t,i+""),i):!(r&&"get"in r&&null!==(n=r.get(e,t)))&&null==(n=T.find.attr(e,t))?undefined:n)},attrHooks:{type:{set:function(e,t){if(!B.radioValue&&"radio"===t&&T.nodeName(e,"input")){var i=e.value;return e.setAttribute("type",t),i&&(e.value=i),t}}}},removeAttr:function(e,t){var i,n,r=0,a=t&&t.match(k);if(a&&1===e.nodeType)for(;i=a[r++];)n=T.propFix[i]||i,T.expr.match.bool.test(i)?Pt&&Dt||!kt.test(i)?e[n]=!1:e[T.camelCase("default-"+i)]=e[n]=!1:T.attr(e,i,""),e.removeAttribute(Dt?i:n)}}),At={set:function(e,t,i){return!1===t?T.removeAttr(e,i):Pt&&Dt||!kt.test(i)?e.setAttribute(!Dt&&T.propFix[i]||i,i):e[T.camelCase("default-"+i)]=e[i]=!0,i}},T.each(T.expr.match.bool.source.match(/\w+/g),function(e,t){var a=Lt[t]||T.find.attr;Pt&&Dt||!kt.test(t)?Lt[t]=function(e,t,i){var n,r;return i||(r=Lt[t],Lt[t]=n,n=null!=a(e,t,i)?t.toLowerCase():null,Lt[t]=r),n}:Lt[t]=function(e,t,i){if(!i)return e[T.camelCase("default-"+t)]?t.toLowerCase():null}}),Pt&&Dt||(T.attrHooks.value={set:function(e,t,i){if(!T.nodeName(e,"input"))return wt&&wt.set(e,t,i);e.defaultValue=t}}),Dt||(wt={set:function(e,t,i){var n=e.getAttributeNode(i);if(n||e.setAttributeNode(n=e.ownerDocument.createAttribute(i)),n.value=t+="","value"===i||t===e.getAttribute(i))return t}},Lt.id=Lt.name=Lt.coords=function(e,t,i){var n;if(!i)return(n=e.getAttributeNode(t))&&""!==n.value?n.value:null},T.valHooks.button={get:function(e,t){var i=e.getAttributeNode(t);if(i&&i.specified)return i.value},set:wt.set},T.attrHooks.contenteditable={set:function(e,t,i){wt.set(e,""!==t&&t,i)}},T.each(["width","height"],function(e,i){T.attrHooks[i]={set:function(e,t){if(""===t)return e.setAttribute(i,"auto"),t}}})),B.style||(T.attrHooks.style={get:function(e){return e.style.cssText||undefined},set:function(e,t){return e.style.cssText=t+""}});var Mt=/^(?:input|select|textarea|button|object)$/i,Rt=/^(?:a|area)$/i;T.fn.extend({prop:function(e,t){return q(this,T.prop,e,t,1<arguments.length)},removeProp:function(t){return t=T.propFix[t]||t,this.each(function(){try{this[t]=undefined,delete this[t]}catch(e){}})}}),T.extend({prop:function(e,t,i){var n,r,a=e.nodeType;if(3!==a&&8!==a&&2!==a)return 1===a&&T.isXMLDoc(e)||(t=T.propFix[t]||t,r=T.propHooks[t]),i!==undefined?r&&"set"in r&&(n=r.set(e,i,t))!==undefined?n:e[t]=i:r&&"get"in r&&null!==(n=r.get(e,t))?n:e[t]},propHooks:{tabIndex:{get:function(e){var t=T.find.attr(e,"tabindex");return t?parseInt(t,10):Mt.test(e.nodeName)||Rt.test(e.nodeName)&&e.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),B.hrefNormalized||T.each(["href","src"],function(e,t){T.propHooks[t]={get:function(e){return e.getAttribute(t,4)}}}),B.optSelected||(T.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)}}),T.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){T.propFix[this.toLowerCase()]=this}),B.enctype||(T.propFix.enctype="encoding");var Ht=/[\t\r\n\f]/g;function Ot(e){return T.attr(e,"class")||""}T.fn.extend({addClass:function(t){var e,i,n,r,a,o,s,l=0;if(T.isFunction(t))return this.each(function(e){T(this).addClass(t.call(this,e,Ot(this)))});if("string"==typeof t&&t)for(e=t.match(k)||[];i=this[l++];)if(r=Ot(i),n=1===i.nodeType&&(" "+r+" ").replace(Ht," ")){for(o=0;a=e[o++];)n.indexOf(" "+a+" ")<0&&(n+=a+" ");r!==(s=T.trim(n))&&T.attr(i,"class",s)}return this},removeClass:function(t){var e,i,n,r,a,o,s,l=0;if(T.isFunction(t))return this.each(function(e){T(this).removeClass(t.call(this,e,Ot(this)))});if(!arguments.length)return this.attr("class","");if("string"==typeof t&&t)for(e=t.match(k)||[];i=this[l++];)if(r=Ot(i),n=1===i.nodeType&&(" "+r+" ").replace(Ht," ")){for(o=0;a=e[o++];)for(;-1<n.indexOf(" "+a+" ");)n=n.replace(" "+a+" "," ");r!==(s=T.trim(n))&&T.attr(i,"class",s)}return this},toggleClass:function(r,t){var a=typeof r;return"boolean"==typeof t&&"string"==a?t?this.addClass(r):this.removeClass(r):T.isFunction(r)?this.each(function(e){T(this).toggleClass(r.call(this,e,Ot(this),t),t)}):this.each(function(){var e,t,i,n;if("string"==a)for(t=0,i=T(this),n=r.match(k)||[];e=n[t++];)i.hasClass(e)?i.removeClass(e):i.addClass(e);else r!==undefined&&"boolean"!=a||((e=Ot(this))&&T._data(this,"__className__",e),T.attr(this,"class",!e&&!1!==r&&T._data(this,"__className__")||""))})},hasClass:function(e){for(var t,i=0,n=" "+e+" ";t=this[i++];)if(1===t.nodeType&&-1<(" "+Ot(t)+" ").replace(Ht," ").indexOf(n))return!0;return!1}}),T.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,i){T.fn[i]=function(e,t){return 0<arguments.length?this.on(i,null,e,t):this.trigger(i)}}),T.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}});var Ft=v.location,Yt=T.now(),Wt=/\?/,Gt=/(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;T.parseJSON=function(e){if(v.JSON&&v.JSON.parse)return v.JSON.parse(e+"");var r,a=null,t=T.trim(e+"");return t&&!T.trim(t.replace(Gt,function(e,t,i,n){return r&&t&&(a=0),0===a?e:(r=i||t,a+=!n-!i,"")}))?Function("return "+t)():T.error("Invalid JSON: "+e)},T.parseXML=function(e){var t;if(!e||"string"!=typeof e)return null;try{v.DOMParser?t=(new v.DOMParser).parseFromString(e,"text/xml"):((t=new v.ActiveXObject("Microsoft.XMLDOM")).async="false",t.loadXML(e))}catch(i){t=undefined}return t&&t.documentElement&&!t.getElementsByTagName("parsererror").length||T.error("Invalid XML: "+e),t};var jt=/#.*$/,Zt=/([?&])_=[^&]*/,Xt=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Ut=/^(?:GET|HEAD)$/,Jt=/^\/\//,Kt=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,zt={},Qt={},qt="*/".concat("*"),$t=Ft.href,ei=Kt.exec($t.toLowerCase())||[];function ti(a){return function(e,t){"string"!=typeof e&&(t=e,e="*");var i,n=0,r=e.toLowerCase().match(k)||[];if(T.isFunction(t))for(;i=r[n++];)"+"===i.charAt(0)?(i=i.slice(1)||"*",(a[i]=a[i]||[]).unshift(t)):(a[i]=a[i]||[]).push(t)}}function ii(t,r,a,o){var s={},l=t===Qt;function u(e){var n;return s[e]=!0,T.each(t[e]||[],function(e,t){var i=t(r,a,o);return"string"!=typeof i||l||s[i]?l?!(n=i):void 0:(r.dataTypes.unshift(i),u(i),!1)}),n}return u(r.dataTypes[0])||!s["*"]&&u("*")}function ni(e,t){var i,n,r=T.ajaxSettings.flatOptions||{};for(n in t)t[n]!==undefined&&((r[n]?e:i=i||{})[n]=t[n]);return i&&T.extend(!0,e,i),e}function ri(e){if(!T.contains(e.ownerDocument||g,e))return!0;for(;e&&1===e.nodeType;){if("none"===((t=e).style&&t.style.display||T.css(t,"display"))||"hidden"===e.type)return!0;e=e.parentNode}var t;return!1}T.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:$t,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(ei[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":qt,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":T.parseJSON,"text xml":T.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?ni(ni(e,T.ajaxSettings),t):ni(T.ajaxSettings,e)},ajaxPrefilter:ti(zt),ajaxTransport:ti(Qt),ajax:function(e,t){"object"==typeof e&&(t=e,e=undefined),t=t||{};var i,n,c,h,p,d,f,r,g=T.ajaxSetup({},t),m=g.context||g,I=g.context&&(m.nodeType||m.jquery)?T(m):T.event,B=T.Deferred(),E=T.Callbacks("once memory"),_=g.statusCode||{},a={},o={},b=0,s="canceled",y={readyState:0,getResponseHeader:function(e){var t;if(2===b){if(!r)for(r={};t=Xt.exec(h);)r[t[1].toLowerCase()]=t[2];t=r[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return 2===b?h:null},setRequestHeader:function(e,t){var i=e.toLowerCase();return b||(e=o[i]=o[i]||e,a[e]=t),this},overrideMimeType:function(e){return b||(g.mimeType=e),this},statusCode:function(e){var t;if(e)if(b<2)for(t in e)_[t]=[_[t],e[t]];else y.always(e[y.status]);return this},abort:function(e){var t=e||s;return f&&f.abort(t),l(0,t),this}};if(B.promise(y).complete=E.add,y.success=y.done,y.error=y.fail,g.url=((e||g.url||$t)+"").replace(jt,"").replace(Jt,ei[1]+"//"),g.type=t.method||t.type||g.method||g.type,g.dataTypes=T.trim(g.dataType||"*").toLowerCase().match(k)||[""],null==g.crossDomain&&(i=Kt.exec(g.url.toLowerCase()),g.crossDomain=!(!i||i[1]===ei[1]&&i[2]===ei[2]&&(i[3]||("http:"===i[1]?"80":"443"))===(ei[3]||("http:"===ei[1]?"80":"443")))),g.data&&g.processData&&"string"!=typeof g.data&&(g.data=T.param(g.data,g.traditional)),ii(zt,g,t,y),2===b)return y;for(n in(d=T.event&&g.global)&&0==T.active++&&T.event.trigger("ajaxStart"),g.type=g.type.toUpperCase(),g.hasContent=!Ut.test(g.type),c=g.url,g.hasContent||(g.data&&(c=g.url+=(Wt.test(c)?"&":"?")+g.data,delete g.data),!1===g.cache&&(g.url=Zt.test(c)?c.replace(Zt,"$1_="+Yt++):c+(Wt.test(c)?"&":"?")+"_="+Yt++)),g.ifModified&&(T.lastModified[c]&&y.setRequestHeader("If-Modified-Since",T.lastModified[c]),T.etag[c]&&y.setRequestHeader("If-None-Match",T.etag[c])),(g.data&&g.hasContent&&!1!==g.contentType||t.contentType)&&y.setRequestHeader("Content-Type",g.contentType),y.setRequestHeader("Accept",g.dataTypes[0]&&g.accepts[g.dataTypes[0]]?g.accepts[g.dataTypes[0]]+("*"!==g.dataTypes[0]?", "+qt+"; q=0.01":""):g.accepts["*"]),g.headers)y.setRequestHeader(n,g.headers[n]);if(g.beforeSend&&(!1===g.beforeSend.call(m,y,g)||2===b))return y.abort();for(n in s="abort",{success:1,error:1,complete:1})y[n](g[n]);if(f=ii(Qt,g,t,y)){if(y.readyState=1,d&&I.trigger("ajaxSend",[y,g]),2===b)return y;g.async&&0<g.timeout&&(p=v.setTimeout(function(){y.abort("timeout")},g.timeout));try{b=1,f.send(a,l)}catch(u){if(!(b<2))throw u;l(-1,u)}}else l(-1,"No Transport");function l(e,t,i,n){var r,a,o,s,l,u=t;2!==b&&(b=2,p&&v.clearTimeout(p),f=undefined,h=n||"",y.readyState=0<e?4:0,r=200<=e&&e<300||304===e,i&&(s=function(e,t,i){for(var n,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 i)a=l[0];else{for(o in i){if(!l[0]||e.converters[o+" "+l[0]]){a=o;break}n=n||o}a=a||n}if(a)return a!==l[0]&&l.unshift(a),i[a]}(g,y,i)),s=function(e,t,i,n){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]&&(i[e.responseFields[a]]=t),!l&&n&&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(h){return{state:"parsererror",error:o?h:"No conversion from "+l+" to "+a}}}return{state:"success",data:t}}(g,s,y,r),r?(g.ifModified&&((l=y.getResponseHeader("Last-Modified"))&&(T.lastModified[c]=l),(l=y.getResponseHeader("etag"))&&(T.etag[c]=l)),204===e||"HEAD"===g.type?u="nocontent":304===e?u="notmodified":(u=s.state,a=s.data,r=!(o=s.error))):(o=u,!e&&u||(u="error",e<0&&(e=0))),y.status=e,y.statusText=(t||u)+"",r?B.resolveWith(m,[a,u,y]):B.rejectWith(m,[y,u,o]),y.statusCode(_),_=undefined,d&&I.trigger(r?"ajaxSuccess":"ajaxError",[y,g,r?a:o]),E.fireWith(m,[y,u]),d&&(I.trigger("ajaxComplete",[y,g]),--T.active||T.event.trigger("ajaxStop")))}return y},getJSON:function(e,t,i){return T.get(e,t,i,"json")},getScript:function(e,t){return T.get(e,undefined,t,"script")}}),T.each(["get","post"],function(e,r){T[r]=function(e,t,i,n){return T.isFunction(t)&&(n=n||i,i=t,t=undefined),T.ajax(T.extend({url:e,type:r,dataType:n,data:t,success:i},T.isPlainObject(e)&&e))}}),T._evalUrl=function(e){return T.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,"throws":!0})},T.fn.extend({wrapAll:function(t){return T.isFunction(t)?this.each(function(e){T(this).wrapAll(t.call(this,e))}):(this[0]&&(e=T(t,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&e.insertBefore(this[0]),e.map(function(){for(var e=this;e.firstChild&&1===e.firstChild.nodeType;)e=e.firstChild;return e}).append(this)),this);var e},wrapInner:function(i){return T.isFunction(i)?this.each(function(e){T(this).wrapInner(i.call(this,e))}):this.each(function(){var e=T(this),t=e.contents();t.length?t.wrapAll(i):e.append(i)})},wrap:function(t){var i=T.isFunction(t);return this.each(function(e){T(this).wrapAll(i?t.call(this,e):t)})},unwrap:function(){return this.parent().each(function(){T.nodeName(this,"body")||T(this).replaceWith(this.childNodes)}).end()}}),T.expr.filters.hidden=function(e){return B.reliableHiddenOffsets()?e.offsetWidth<=0&&e.offsetHeight<=0&&!e.getClientRects().length:ri(e)},T.expr.filters.visible=function(e){return!T.expr.filters.hidden(e)};var ai=/%20/g,oi=/\[\]$/,si=/\r?\n/g,li=/^(?:submit|button|image|reset|file)$/i,ui=/^(?:input|select|textarea|keygen)/i;T.param=function(e,t){var i,n=[],r=function(e,t){t=T.isFunction(t)?t():null==t?"":t,n[n.length]=encodeURIComponent(e)+"="+encodeURIComponent(t)};if(t===undefined&&(t=T.ajaxSettings&&T.ajaxSettings.traditional),T.isArray(e)||e.jquery&&!T.isPlainObject(e))T.each(e,function(){r(this.name,this.value)});else for(i in e)!function a(i,e,n,r){var t;if(T.isArray(e))T.each(e,function(e,t){n||oi.test(i)?r(i,t):a(i+"["+("object"==typeof t&&null!=t?e:"")+"]",t,n,r)});else if(n||"object"!==T.type(e))r(i,e);else for(t in e)a(i+"["+t+"]",e[t],n,r)}(i,e[i],t,r);return n.join("&").replace(ai,"+")},T.fn.extend({serialize:function(){return T.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=T.prop(this,"elements");return e?T.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!T(this).is(":disabled")&&ui.test(this.nodeName)&&!li.test(e)&&(this.checked||!$.test(e))}).map(function(e,t){var i=T(this).val();return null==i?null:T.isArray(i)?T.map(i,function(e){return{name:t.name,value:e.replace(si,"\r\n")}}):{name:t.name,value:i.replace(si,"\r\n")}}).get()}}),T.ajaxSettings.xhr=v.ActiveXObject!==undefined?function(){return this.isLocal?fi():8<g.documentMode?di():/^(get|post|head|put|delete|options)$/i.test(this.type)&&di()||fi()}:di;var ci=0,hi={},pi=T.ajaxSettings.xhr();function di(){try{return new v.XMLHttpRequest}catch(e){}}function fi(){try{return new v.ActiveXObject("Microsoft.XMLHTTP")}catch(e){}}v.attachEvent&&v.attachEvent("onunload",function(){for(var e in hi)hi[e](undefined,!0)}),B.cors=!!pi&&"withCredentials"in pi,(pi=B.ajax=!!pi)&&T.ajaxTransport(function(u){var c;if(!u.crossDomain||B.cors)return{send:function(e,o){var t,s=u.xhr(),l=++ci;if(s.open(u.type,u.url,u.async,u.username,u.password),u.xhrFields)for(t in u.xhrFields)s[t]=u.xhrFields[t];for(t in u.mimeType&&s.overrideMimeType&&s.overrideMimeType(u.mimeType),u.crossDomain||e["X-Requested-With"]||(e["X-Requested-With"]="XMLHttpRequest"),e)e[t]!==undefined&&s.setRequestHeader(t,e[t]+"");s.send(u.hasContent&&u.data||null),c=function(e,t){var i,n,r;if(c&&(t||4===s.readyState))if(delete hi[l],c=undefined,s.onreadystatechange=T.noop,t)4!==s.readyState&&s.abort();else{r={},i=s.status,"string"==typeof s.responseText&&(r.text=s.responseText);try{n=s.statusText}catch(a){n=""}i||!u.isLocal||u.crossDomain?1223===i&&(i=204):i=r.text?200:404}r&&o(i,n,r,s.getAllResponseHeaders())},u.async?4===s.readyState?v.setTimeout(c):s.onreadystatechange=hi[l]=c:c()},abort:function(){c&&c(undefined,!0)}}}),T.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 T.globalEval(e),e}}}),T.ajaxPrefilter("script",function(e){e.cache===undefined&&(e.cache=!1),e.crossDomain&&(e.type="GET",e.global=!1)}),T.ajaxTransport("script",function(t){if(t.crossDomain){var n,r=g.head||T("head")[0]||g.documentElement;return{send:function(e,i){(n=g.createElement("script")).async=!0,t.scriptCharset&&(n.charset=t.scriptCharset),n.src=t.url,n.onload=n.onreadystatechange=function(e,t){!t&&n.readyState&&!/loaded|complete/.test(n.readyState)||(n.onload=n.onreadystatechange=null,n.parentNode&&n.parentNode.removeChild(n),n=null,t||i(200,"success"))},r.insertBefore(n,r.firstChild)},abort:function(){n&&n.onload(undefined,!0)}}}});var gi=[],mi=/(=)\?(?=&|$)|\?\?/;T.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=gi.pop()||T.expando+"_"+Yt++;return this[e]=!0,e}}),T.ajaxPrefilter("json jsonp",function(e,t,i){var n,r,a,o=!1!==e.jsonp&&(mi.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&mi.test(e.data)&&"data");if(o||"jsonp"===e.dataTypes[0])return n=e.jsonpCallback=T.isFunction(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,o?e[o]=e[o].replace(mi,"$1"+n):!1!==e.jsonp&&(e.url+=(Wt.test(e.url)?"&":"?")+e.jsonp+"="+n),e.converters["script json"]=function(){return a||T.error(n+" was not called"),a[0]},e.dataTypes[0]="json",r=v[n],v[n]=function(){a=arguments},i.always(function(){r===undefined?T(v).removeProp(n):v[n]=r,e[n]&&(e.jsonpCallback=t.jsonpCallback,gi.push(n)),a&&T.isFunction(r)&&r(a[0]),a=r=undefined}),"script"}),T.parseHTML=function(e,t,i){if(!e||"string"!=typeof e)return null;"boolean"==typeof t&&(i=t,t=!1),t=t||g;var n=b.exec(e),r=!i&&[];return n?[t.createElement(n[1])]:(n=he([e],t,r),r&&r.length&&T(r).remove(),T.merge([],n.childNodes))};var Ii=T.fn.load;function Bi(e){return T.isWindow(e)?e:9===e.nodeType&&(e.defaultView||e.parentWindow)}T.fn.load=function(e,t,i){if("string"!=typeof e&&Ii)return Ii.apply(this,arguments);var n,r,a,o=this,s=e.indexOf(" ");return-1<s&&(n=T.trim(e.slice(s,e.length)),e=e.slice(0,s)),T.isFunction(t)?(i=t,t=undefined):t&&"object"==typeof t&&(r="POST"),0<o.length&&T.ajax({url:e,type:r||"GET",dataType:"html",data:t}).done(function(e){a=arguments,o.html(n?T("<div>").append(T.parseHTML(e)).find(n):e)}).always(i&&function(e,t){o.each(function(){i.apply(this,a||[e.responseText,t,e])})}),this},T.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){T.fn[t]=function(e){return this.on(t,e)}}),T.expr.filters.animated=function(t){return T.grep(T.timers,function(e){return t===e.elem}).length},T.offset={setOffset:function(e,t,i){var n,r,a,o,s,l,u=T.css(e,"position"),c=T(e),h={};"static"===u&&(e.style.position="relative"),s=c.offset(),a=T.css(e,"top"),l=T.css(e,"left"),r=("absolute"===u||"fixed"===u)&&-1<T.inArray("auto",[a,l])?(o=(n=c.position()).top,n.left):(o=parseFloat(a)||0,parseFloat(l)||0),T.isFunction(t)&&(t=t.call(e,i,T.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)}},T.fn.extend({offset:function(t){if(arguments.length)return t===undefined?this:this.each(function(e){T.offset.setOffset(this,t,e)});var e,i,n={top:0,left:0},r=this[0],a=r&&r.ownerDocument;return a?(e=a.documentElement,T.contains(e,r)?("undefined"!=typeof r.getBoundingClientRect&&(n=r.getBoundingClientRect()),i=Bi(a),{top:n.top+(i.pageYOffset||e.scrollTop)-(e.clientTop||0),left:n.left+(i.pageXOffset||e.scrollLeft)-(e.clientLeft||0)}):n):void 0},position:function(){if(this[0]){var e,t,i={top:0,left:0},n=this[0];return"fixed"===T.css(n,"position")?t=n.getBoundingClientRect():(e=this.offsetParent(),t=this.offset(),T.nodeName(e[0],"html")||(i=e.offset()),i.top+=T.css(e[0],"borderTopWidth",!0),i.left+=T.css(e[0],"borderLeftWidth",!0)),{top:t.top-i.top-T.css(n,"marginTop",!0),left:t.left-i.left-T.css(n,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var e=this.offsetParent;e&&!T.nodeName(e,"html")&&"static"===T.css(e,"position");)e=e.offsetParent;return e||Ke})}}),T.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,r){var a=/Y/.test(r);T.fn[t]=function(e){return q(this,function(e,t,i){var n=Bi(e);if(i===undefined)return n?r in n?n[r]:n.document.documentElement[t]:e[t];n?n.scrollTo(a?T(n).scrollLeft():i,a?i:T(n).scrollTop()):e[t]=i},t,e,arguments.length,null)}}),T.each(["top","left"],function(e,i){T.cssHooks[i]=et(B.pixelPosition,function(e,t){if(t)return t=qe(e,i),Ue.test(t)?T(e).position()[i]+"px":t})}),T.each({Height:"height",Width:"width"},function(a,o){T.each({padding:"inner"+a,content:o,"":"outer"+a},function(n,e){T.fn[e]=function(e,t){var i=arguments.length&&(n||"boolean"!=typeof e),r=n||(!0===e||!0===t?"margin":"border");return q(this,function(e,t,i){var n;return T.isWindow(e)?e.document.documentElement["client"+a]:9===e.nodeType?(n=e.documentElement,Math.max(e.body["scroll"+a],n["scroll"+a],e.body["offset"+a],n["offset"+a],n["client"+a])):i===undefined?T.css(e,t,r):T.style(e,t,i,r)},o,i?e:undefined,i,null)}})}),T.fn.extend({bind:function(e,t,i){return this.on(e,null,t,i)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,i,n){return this.on(t,e,i,n)},undelegate:function(e,t,i){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",i)}}),T.fn.size=function(){return this.length},T.fn.andSelf=T.fn.addBack,(vi=function(){return T}.apply(yi,[]))===undefined||(bi.exports=vi);var Ei=v.jQuery,_i=v.$;return T.noConflict=function(e){return v.$===T&&(v.$=_i),e&&v.jQuery===T&&(v.jQuery=Ei),T},v.$||v.jQuery||(v.jQuery=v.$=T),BI.jQuery=BI.$=T},"object"==typeof bi.exports?bi.exports=t.document?i(t):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return i(e)}:i(t)},function(e,t){BI.$.extend(BI.$.Event.prototype,{stopEvent:function(){this.stopPropagation(),this.preventDefault()}})},function(e,t){var i;BI.jQuery&&((i=BI.jQuery).fn.insets||(i.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}}),i.fn.bounds||(i.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=0<=t.width?t.width:e.width),null!=e.height&&(t.height=e.height-(this.outerHeight(!0)-this.height()),t.height=0<=t.height?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,i,t){if(!BI.isKey(i)||100<(e+"").length)return BI.isIE9Below()?this.html(BI.htmlEncode(e)):(this[0].textContent=e,this);i+="",i=BI.toUpperCase(i);var n=(e||"")+"";for(t=(t||BI.makeFirstPY(e,{splitChar:""}))+"",t=BI.toUpperCase(t),this.empty();0<t.length&&0<n.length;){var r=BI.toUpperCase(n).indexOf(i),a=t.indexOf(i);if(0<=a&&(a=(a-Math.floor(a/(n.length+1)))%n.length),0<=r&&(r<a||-1===a))this.append(BI.htmlEncode(n.substr(0,r))),this.append(BI.$("<span>").addClass("bi-keyword-red-mark").html(BI.htmlEncode(n.substr(r,i.length)))),n=n.substr(r+i.length),BI.isNotEmptyString(t)&&(t=BI.map(t.split(""),function(e,t){return t.slice(r+i.length)}).join(""));else{if(!(0<=a)){this.append(BI.htmlEncode(n));break}this.append(BI.htmlEncode(n.substr(0,a))),this.append(BI.$("<span>").addClass("bi-keyword-red-mark").html(BI.htmlEncode(n.substr(a,i.length)))),BI.isNotEmptyString(t)&&(t=BI.map(t.split(""),function(e,t){return t.slice(a+i.length)}).join("")),n=n.substr(a+i.length)}}return this},getDomHeight:function(e){var t=BI.$(this).clone();t.appendTo(BI.$(e||"body"));var i=t.height();return t.remove(),i},hasVerticalScroll:function(){return 0<this.height()&&this[0].clientWidth<this[0].offsetWidth},hasHorizonScroll:function(){return 0<this.width()&&this[0].clientHeight<this[0].offsetHeight},getStyle:function(e){var t=this[0],i=void 0;if(_global.getComputedStyle&&(i=_global.getComputedStyle(t,null)))return i.getPropertyValue(BI.hyphenate(e));if(document.defaultView&&document.defaultView.getComputedStyle){if(i=document.defaultView.getComputedStyle(t,null))return i.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(),i=t.width||this.outerWidth(),n=t.height||this.outerHeight();return!(e.pageX<Math.floor(t.left)||e.pageX>t.left+i||e.pageY<Math.floor(t.top)||e.pageY>t.top+n)},__hasZIndexMask__:function(e){return e&&null!=this.zIndexMask[e]},__buildZIndexMask__:function(e,t){this.zIndexMask=this.zIndexMask||{},this.indexMask=this.indexMask||[];var i=BI.createWidget({type:"bi.center_adapt",cls:"bi-z-index-mask",items:t});return i.element.css({"z-index":e}),BI.createWidget({type:"bi.absolute",element:this,items:[{el:i,left:0,right:0,top:0,bottom:0}]}),this.indexMask.push(i),e&&(this.zIndexMask[e]=i),i.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(p){var e=["wheel","mousewheel","DOMMouseScroll","MozMousePixelScroll"],t="onwheel"in document||document.documentMode>=9?["wheel"]:["mousewheel","DomMouseScroll","MozMousePixelScroll"],d=Array.prototype.slice,f,g;if(p.event.fixHooks){for(var i=e.length;i;){p.event.fixHooks[e[--i]]=p.event.mouseHooks}}var m=p.event.special.mousewheel={version:"3.1.12",setup:function(){if(this.addEventListener){for(var e=t.length;e;){this.addEventListener(t[--e],n,false)}}else{this.onmousewheel=n}},teardown:function(){if(this.removeEventListener){for(var e=t.length;e;){this.removeEventListener(t[--e],n,false)}}else{this.onmousewheel=null}},settings:{adjustOldDeltas:true,normalizeOffset:true}};function n(e){var t=e||_global.event,i=d.call(arguments,1),n=0,r=0,a=0,o=0,s=0,l=0;e=p.event.fix(t);e.type="mousewheel";if("detail"in t){a=t.detail*-1}if("wheelDelta"in t){a=t.wheelDelta}if("wheelDeltaY"in t){a=t.wheelDeltaY}if("wheelDeltaX"in t){r=t.wheelDeltaX*-1}if("axis"in t&&t.axis===t.HORIZONTAL_AXIS){r=a*-1;a=0}n=a===0?r:a;if("deltaY"in t){a=t.deltaY*-1;n=a}if("deltaX"in t){r=t.deltaX;if(a===0){n=r*-1}}if(a===0&&r===0){return}if(t.deltaMode===1){var u=40;n*=u;a*=u;r*=u}else if(t.deltaMode===2){var c=800;n*=c;a*=c;r*=c}o=Math.max(Math.abs(a),Math.abs(r));if(!g||o<g){g=o;if(B(t,o)){g/=40}}if(B(t,o)){n/=40;r/=40;a/=40}n=Math[n>=1?"floor":"ceil"](n/g);r=Math[r>=1?"floor":"ceil"](r/g);a=Math[a>=1?"floor":"ceil"](a/g);if(m.settings.normalizeOffset&&this.getBoundingClientRect){var h=this.getBoundingClientRect();s=e.clientX-h.left;l=e.clientY-h.top}e.deltaX=r;e.deltaY=a;e.deltaFactor=g;e.offsetX=s;e.offsetY=l;e.deltaMode=0;i.unshift(e,n,r,a);if(f){clearTimeout(f)}f=setTimeout(I,200);return(p.event.dispatch||p.event.handle).apply(this,i)}function I(){g=null}function B(e,t){return m.settings.adjustOldDeltas&&e.type==="mousewheel"&&t%120===0}p.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 r;_.extend(BI,{$import:(r={},function(i,e,t){var n;!function(i,n){var e=BI.$("head script, body script");BI.$.each(e,function(e,t){-1!=t.src.indexOf(i)&&(r[i]=!0)});var t=BI.$("head link");BI.$.each(t,function(e,t){-1!=t.href.indexOf(i)&&n&&(r[i]=!1,BI.$(t).remove())})}(i,t),!0!==r[i]&&("css"===e?((n=document.createElement("link")).rel="stylesheet",n.type="text/css",n.href=i,document.getElementsByTagName("head")[0].appendChild(n),r[i]=!0):BI.$.ajax({url:i,dataType:"script",async:!1,cache:!0,complete:function(e,t){"success"==t&&(r[i]=!0)}}))})})},function(e,t){!function(){var e={on:function(e,t,i){return h(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},once:function(e,t,i){if(!h(this,"once",e,[t,i])||!t)return this;var n=this,r=_.once(function(){n.off(e,r),t.apply(this,arguments)});return r._callback=t,this.on(e,r,i)},off:function(e,t,i){if(!this._events||!h(this,"off",e,[t,i]))return this;if(!e&&!t&&!i)return this._events=void 0,this;for(var n=e?[e]:_.keys(this._events),r=0,a=n.length;r<a;r++){e=n[r];var o=this._events[e];if(o)if(t||i){for(var s=[],l=0,u=o.length;l<u;l++){var c=o[l];(t&&t!==c.callback&&t!==c.callback._callback||i&&i!==c.context)&&s.push(c)}s.length?this._events[e]=s: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(!h(this,"trigger",e,t))return this;var i=this._events[e],n=this._events.all;return i&&r(i,t),n&&r(n,arguments),this},fireEvent:function(){this.trigger.apply(this,arguments)},listenTo:function(e,t,i){var n=this._listeningTo||(this._listeningTo={});return i||"object"!=typeof t||(i=this),(n[e._listenId||(e._listenId=_.uniqueId("l"))]=e).on(t,i,this),this},listenToOnce:function(e,t,i){if("object"==typeof t){for(var n in t)this.listenToOnce(e,n,t[n]);return this}if(l.test(t)){for(var r=t.split(l),a=0,o=r.length;a<o;a++)this.listenToOnce(e,r[a],i);return this}if(!i)return this;var s=_.once(function(){this.stopListening(e,t,s),i.apply(this,arguments)});return s._callback=i,this.listenTo(e,t,s)},stopListening:function(e,t,i){var n=this._listeningTo;if(!n)return this;var r=!t&&!i;for(var a in i||"object"!=typeof t||(i=this),e&&((n={})[e._listenId]=e),n)(e=n[a]).off(t,i,this),(r||_.isEmpty(e._events))&&delete this._listeningTo[a];return this}},l=/\s+/,h=function(e,t,i,n){if(!i)return!0;if("object"==typeof i){for(var r in i)e[t].apply(e,[r,i[r]].concat(n));return!1}if(l.test(i)){for(var a=i.split(l),o=0,s=a.length;o<s;o++)e[t].apply(e,[a[o]].concat(n));return!1}return!0},r=function(e,t){var i,n=-1,r=e.length,a=t[0],o=t[1],s=t[2];switch(t.length){case 0:for(;++n<r;)(i=e[n]).callback.call(i.ctx);return;case 1:for(;++n<r;)(i=e[n]).callback.call(i.ctx,a);return;case 2:for(;++n<r;)(i=e[n]).callback.call(i.ctx,a,o);return;case 3:for(;++n<r;)(i=e[n]).callback.call(i.ctx,a,o,s);return;default:for(;++n<r;)(i=e[n]).callback.apply(i.ctx,t);return}},i=BI.Router=function(e){(e=e||{}).routes&&(this.routes=e.routes),this._bindRoutes(),this._init.apply(this,arguments)},t=/\((.*?)\)/g,n=/(\(\?)?:\w+/g,a=/\*\w+/g,o=/[\-{}\[\]+?.,\\\^$|#\s]/g;_.extend(i.prototype,e,{_init:function(){},route:function(i,n,r){_.isRegExp(i)||(i=this._routeToRegExp(i)),_.isFunction(n)&&(r=n,n=""),r=r||this[n];var a=this;return BI.history.route(i,function(e){var t=a._extractParameters(i,e);!1!==a.execute(r,t,n)&&(a.trigger.apply(a,["route:"+n].concat(t)),a.trigger("route",n,t),BI.history.trigger("route",a,n,t))}),this},execute:function(e,t,i){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(o,"\\$&").replace(t,"(?:$1)?").replace(n,function(e,t){return t?e:"([^/?]+)"}).replace(a,"([^?]*?)"),new RegExp("^"+e+"(?:\\?([\\s\\S]*))?$")},_extractParameters:function(e,t){var r=e.exec(t).slice(1);return _.map(r,function(e,t){if(t===r.length-1)return e||null;var i=null;if(e)try{i=decodeURIComponent(e)}catch(n){i=e}return i})}});var s=function(){this.handlers=[],this.checkUrl=_.bind(this.checkUrl,this),"undefined"!=typeof window&&(this.location=_global.location,this.history=_global.history)},u=/^[#\/]|\s+$/g,c=/^\/+|\/+$/g,p=/#.*$/;s.started=!1,_.extend(s.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(i){}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(u,"")},start:function(e){if(s.started)throw new Error("BI.history has already been started");if(s.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(c,"/"),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})}var i,n;this._hasHashChange||!this._wantsHashChange||this._wantsPushState&&this._hasPushState||((i=document.createElement("iframe")).src="javascript:0",i.style.display="none",i.tabIndex=-1,n=document.body,this.iframe=n.insertBefore(i,n.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),s.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()===i.prototype._routeToRegExp(e).toString())return this.handlers[t];return null},unRoute:function(t){var e=_.findIndex(this.handlers,function(e){return e.route.test(t)});-1<e&&this.handlers.splice(e,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(t){return t=this.fragment=this.getFragment(t),_.some(this.handlers,function(e){if(e.route.test(t))return e.callback(t),!0})},navigate:function(e,t){if(!s.started)return!1;t&&!0!==t||(t={trigger:!!t}),e=this.getFragment(e||"");var i=this.root;""!==e&&"?"!==e.charAt(0)||(i=i.slice(0,-1)||"/");var n=i+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,n);else{if(!this._wantsHashChange)return this.location.assign(n);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,i){var n;i?(n=e.href.replace(/(javascript:|#).*$/,""),e.replace(n+"#"+t)):e.hash="#"+t}}),BI.history=new s}()},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=(x1c=function(e){return this[e]},function(e){var t=e.files||[e];return t.item||(t.item=x1c),t}),x1c,event={add:document.addEventListener?function(e,t,i){return e.addEventListener(t,i,!1),this}:function(e,t,i){return e.attachEvent("on"+t,i),this},del:document.removeEventListener?function(e,t,i){return e.removeEventListener(t,i,!1),this}:function(e,t,i){return e.detachEvent("on"+t,i),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,i){return"--".concat(e,CRLF,'Content-Disposition: form-data; name="',t,'"; filename="',_global.encodeURIComponent(i.fileName),'"',CRLF,"Content-Type: application/octet-stream",CRLF,CRLF,i.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,sendFile=xhr.upload||xhr.sendAsBinary?function(i,e,t,n){var r=i.current;if(!(-1<e&&e<i.file.fileSize)){for(var a,o=new XMLHttpRequest,s=o.upload||{addEventListener:function(e,t){this["on"+e]=t}},l=0;l<length;l++)s.addEventListener(split[l].substring(2),function(t){return function(e){isFunction(i[t])&&i[t](e,o)}}(split[l]),!1);s.addEventListener("load",function(e){!1===i.onreadystatechange?isFunction(i.onload)&&i.onload(e,o):setTimeout(function(){4===o.readyState?isFunction(i.onload)&&i.onload(e,o):setTimeout(arguments.callee,15)},15)},!1),o.open("post",BI.appendQuery(i.url,{filename:_global.encodeURIComponent(i.file.fileName)}),!0),o.upload?(o.onreadystatechange=function(){switch(o.readyState){case 4:var e=BI.jsonDecode(o.responseText);-1!=i.file.type.indexOf("image")&&(e.attach_type="image"),e.filename=i.file.fileName,1==i.maxLength?i.attach_array[0]=e:i.attach_array[r]=e}},isFunction(s.onloadstart)&&s.onloadstart()):((a={loaded:0,total:i.file.fileSize||i.file.size,simulation:!0}).interval=setInterval(function(){a.loaded+=256,a.total<=a.loaded&&(a.loaded=a.total),s.onprogress(a)},100),o.onabort=function(){s.onabort({})},o.onerror=function(){s.onerror({})},o.onreadystatechange=function(){switch(o.readyState){case 2:case 3:a.total<=a.loaded&&(a.loaded=a.total),s.onprogress(a);break;case 4:var e;clearInterval(a.interval),a.interval=0,a.loaded=a.total,s.onprogress(a),199<o.status&&o.status<400?(s.onload({}),(e=BI.jsonDecode(o.responseText)).filename=i.file.fileName,-1!=i.file.type.indexOf("image")&&(e.attach_type="image"),i.attach_array[r]=e):s.onerror({})}},s.onloadstart(a));var u,c="AjaxUploadBoundary"+(new Date).getTime();return o.setRequestHeader("Content-Type","multipart/form-data; boundary="+c),i.file.getAsBinary?o[o.sendAsBinary?"sendAsBinary":"send"](multipart(c,i.name,i.file)):(o.setRequestHeader("Content-Type","multipart/form-data"),(u=new FormData).append("FileData",i.file),o.send(u)),i}isFunction(i.onerror)&&i.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(i){t.filename=handler.file.fileName}1==handler.maxLength?handler.attach_array[0]=t:handler.attach_array[current]=t}catch(i){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;return sendFile}(Object.prototype.toString),sendFiles=function(n,r,a,o){var s=n.files.length,l=n.onload,u=n.onloadstart;for(n.current=0,n.total=0,n.sent=0;n.current<s;)n.total+=n.files[n.current].fileSize||n.files[n.current].size,n.current++;return n.current=0,s&&-1!==n.files[0].fileSize?(n.file=n.files[n.current],sendFile(n,r,a,o).onload=function(e,t){n.onloadstart=null,n.sent+=n.files[n.current].fileSize||n.files[n.current].size,++n.current<s?(n.file=n.files[n.current],sendFile(n,r,a,o).onload=arguments.callee):l&&(n.onloadstart=u,n.onload=l,n.onload(e,t))}):s&&(n.total=100*s,n.file=n.files[n.current],sendFile(n,r,a,o).onload=function(e,t){var i=arguments.callee;n.onloadstart=null,n.sent+=100,++n.current<s?(/\b(chrome|safari)\b/i.test(navigator.userAgent)&&(n.iframe.parentNode.removeChild(n.iframe),n.iframe=null),setTimeout(function(){n.file=n.files[n.current],sendFile(n,r,a,o).onload=i},15)):l&&setTimeout(function(){n.iframe.parentNode.removeChild(n.iframe),n.iframe=null,n.onloadstart=u,n.onload=l,n.onload(e,t)},15)}),n},r1=/\.([^.]+)$/,r2=/\/([^/]+)$/,fileTypeValidate=function(n,e){if(!e)return!0;var t=e.split(",");return t[0]===e&&(t=(e+"").split(";")),BI.some(t,function(e,t){var i;return(i=t.match(r1))?-1<n.toLowerCase().indexOf(i[1]):(i=t.match(r2))?"*"===i[1]||-1<n.toLowerCase().indexOf(i[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 n=this,e=this.options,r=this.wrap=this._wrap(this.element[0],e.maxSize);r.onloadstart=function(e,t){n.fireEvent(BI.File.EVENT_UPLOADSTART,arguments)},r.onprogress=function(e,t){-1!==this.file.fileSize&&e.simulation,n.fireEvent(BI.File.EVENT_PROGRESS,{file:this.file,total:e.total,loaded:e.loaded,simulation:e.simulation})},r.onerror=function(){n.fireEvent(BI.File.EVENT_ERROR)},r.onload=function(e,t){var i=this;setTimeout(function(){return i.clean(),i.hide(),t.status<200||399<t.status?(BI.Msg.toast(BI.i18nText("BI-Upload_File_Error"),{level:"error"}),void n.fireEvent(BI.File.EVENT_ERROR)):void(BI.some(r.attach_array,function(e,t){if(t.errorCode)return BI.Msg.toast(BI.i18nText(t.errorMsg),{level:"error"}),n.fireEvent(BI.File.EVENT_ERROR,t),!0})||n.fireEvent(BI.File.EVENT_UPLOADED))},1e3)},r.url=e.url,r.fileType=e.accept,r.attach_array=[],r.attach_names=[],r.attachNum=0},_events:function(s){var l=this,u=this.options;return event.add(s.dom.input,"change",function(){event.del(s.dom.input,"change",arguments.callee);var e=s.dom.input.cloneNode(!0),t=F(s.dom.input);if(-1!==u.maxLength&&u.maxLength<t.length)l.fireEvent(BI.File.EVENT_ERROR,{errorType:2});else for(var i=0;i<t.length;i++){var n=t.item(i),r=n.value||n.name,a=n.fileName||(n.fileName=r.split("\\").pop()),o=(-1!==a.indexOf(".")&&a.split(".").pop().toLowerCase(),n.fileSize||n.size);fileTypeValidate(a,s.fileType)?-1!==s.maxSize&&o&&s.maxSize<o?(BI.Msg.toast(BI.i18nText("BI-Upload_File_Size_Error"),{level:"error"}),l.fireEvent(BI.File.EVENT_ERROR,{errorType:1,file:n})):s.files.unshift(n):(BI.Msg.toast(BI.i18nText("BI-Upload_File_Type_Error"),{level:"error"}),l.fireEvent(BI.File.EVENT_ERROR,{errorType:0,file:n}))}0<s.files.length&&l.fireEvent(BI.File.EVENT_CHANGE,{files:s.files}),e.value="",s.dom.input.parentNode.replaceChild(e,s.dom.input),s.dom.input=e,event.add(s.dom.input,"change",arguments.callee)}),s},_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,i,n){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,o=this,t=this.options,i={async:{enable:!0,url:function(e,t){var i=o._getParentValues(t);return t.times=t.times||1,"&id="+t.id+"&times="+t.times+++"&parentValues= "+_global.encodeURIComponent(BI.jsonEncode(i))+"&checkState="+_global.encodeURIComponent(BI.jsonEncode(t.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:t.showLine},callback:{beforeExpand:function(e,t){if(t.isAjaxing)return BI.Msg.toast("Please Wait。","warning"),!1;t.children||(t.times=1,l(t,"refresh"));return!0},onAsyncSuccess:function(e,t,i,n){if(i.halfCheck=!1,!n||0===n.length||/^<html>[\s,\S]*<\/html>$/gi.test(n)||o._stop)return;var r=o.nodes,a=i.count||0;i.children.length>a?(i.count=i.children.length,BI.delay(function(){l(i)},s)):(r.updateNode(i),r.selectNode(i.children[0]))},onAsyncError:function(e,t,i,n,r,a){o.nodes;BI.Msg.toast("Error!","warning")},beforeCheck:function(e,t){var i=t.getCheckStatus();{var n;!(t.halfCheck=!1)===t.checked&&(function r(e){BI.each(e,function(e,t){!0===t.halfCheck&&(t.halfCheck=!1,r(t.children))})}(t.children),n=o.nodes.getSelectedNodes(),BI.$.each(n,function(e,t){t.halfCheck=!1}))}!0===i.half&&!0===i.checked&&(t.checked=!1)},onCheck:function(e,t,i){o._selectTreeNode(t,i)},onExpand:function(e,t,i){i.halfCheck=!1},onCollapse:function(e,t,i){},onClick:function(e,t,i){var n=i.checked,r=i.getCheckStatus();!0===r.half&&!0===r.checked&&(n=!1);o.nodes.checkNode(i,!n,!0,!0)}}},s=100;function l(e,t){var i=o.nodes;"refresh"==t&&i.updateNode(e),i.reAsyncChildNodes(e,t,!0)}return i},_getParentValues:function(e){if(!e.getParentNode())return[];var t=e.getParentNode();return this._getParentValues(t).concat([this._getNodeValue(t)])},_getNodeValue:function(e){return null==e.value?BI.replaceAll(e.text.replace(/<[^>]+>/g,""),"&nbsp;"," "):e.value},_getHalfSelectedValues:function(i,e){var t,n,r,a,o,s=this,l=e.getCheckStatus();!1===l.checked&&!1===l.half||(BI.isNotEmptyArray(e.children)&&!0===l.half?(t=e.children,BI.each(t,function(e,t){s._getHalfSelectedValues(i,t)})):(r=(n=e.parentValues||s._getParentValues(e)).concat(this._getNodeValue(e)),BI.isNotEmptyArray(e.children)||!1===l.half?this._buildTree(i,r):(a=BI.deepClone(this.options.paras.selectedValues),o=this._getTree(a,r),this._addTreeNode(i,n,this._getNodeValue(e),o))))},_getTree:function(e,t){var i=e;return BI.any(t,function(e,t){return null==i[t]||void(i=i[t])}),i},_addTreeNode:function(e,t,i,n){var r=e;BI.each(t,function(e,t){null==r[t]&&(r[t]={}),r=r[t]}),r[i]=n},_buildTree:function(e,t){var i=e;BI.each(t,function(e,t){null==i[t]&&(i[t]={}),i=i[t]})},_getSelectedValues:function(){var e,r=this,a={},t=this.nodes.getNodes();return e=t,BI.each(e,function(e,t){var i,n=t.getCheckStatus();!0!==n.checked&&!0!==n.half||(!0===n.half?r._getHalfSelectedValues(a,t):(i=(t.parentValues||r._getParentValues(t)).concat([r._getNodeValue(t)]),r._buildTree(a,i)))}),a},_dealWidthNodes:function(e){var i=this.options,t=BI.Tree.arrayFormat(e);return BI.each(t,function(e,t){t.title=t.title||t.text||t.value,t.isParent=t.isParent||t.parent,t.value=BI.isUndefined(t.value)?t.text:t.value,BI.isKey(i.paras.keyword)?t.text=BI.$("<div>").__textKeywordMarked__(BI.Text.formatText(t.text+""),i.paras.keyword,t.py).html():t.text=BI.htmlEncode(BI.Text.formatText(t.text+""))}),e},_loadMore:function(){var n=this,e=this.options;this.tip.setLoading();var t=BI.extend({},e.paras,{times:++this.times});e.itemsCreator(t,function(e){var t,i;!0!==n._stop&&(t=!!e.hasNext,i=e.items||[],t?n.tip.setLoaded():n.tip.setEnd(),0<i.length&&n.nodes.addNodes(null,n._dealWidthNodes(i)))})},_initTree:function(r){var a=this,e=this.options;a.fireEvent(BI.Events.INIT),this.times=1;var o=this.tree;o.empty(),this.loading(),this.tip.setVisible(!1);var s=BI.extend({},e.paras,{times:1});e.itemsCreator(s,function(e){var t,i,n;!0!==a._stop&&(t=!!e.hasNext,0<(i=e.items||[]).length&&(n=a._dealWidthNodes(i),!0!==a._stop&&(a.nodes=BI.$.fn.zTree.init(o.element,r,n))),a.setTipVisible(i.length<=0),a.loaded(),t?a.tip.setLoaded():a.tip.invisible(),1===s.times&&a.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 0<this.nodes.getCheckedNodes(!0).length},checkAll:function(e){this.nodes&&(BI.each(this.nodes.getNodes(),function(e,t){t.halfCheck=!1,function i(e){BI.each(e,function(e,t){t.halfCheck=!1,i(t.children)})}(t.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,n){var r;this.nodes&&(n=n||"value",r=this.nodes,BI.each(e,function(e,i){var t=r.getNodesByParam(n,e,null);BI.each(t,function(e,t){BI.extend(t,{checked:!0},i),r.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 t=this;this.service=new BI.TreeRenderPageService({subNodeListGetter:function(e){return BI.$("#"+t.id+" #"+e+"_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 i=t.getCheckStatus();{var n;!(t.halfCheck=!1)===t.checked&&(function r(e){BI.each(e,function(e,t){t.halfCheck=!1,r(t.children)})}(t.children),n=BI.$.fn.zTree.getZTreeObj(e).getSelectedNodes(),BI.each(n,function(e,t){t.halfCheck=!1}))}!0===i.half&&!0===i.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,i){i.halfCheck=!1},onCollapse:function(e,t,i){i.halfCheck=!1},onClick:function(e,t,i){var n=BI.$.fn.zTree.getZTreeObj(t),r=i.checked,a=i.getCheckStatus();!0===a.half&&!0===a.checked&&(r=!1);n.checkNode(i,!r,!0,!0)}}}},_selectTreeNode:function(e,t){this.options;var i=BI.deepClone(t.parentValues||this._getParentValues(t)),n=this._getNodeValue(t);if(!0===t.checked)this._addTreeNode(this.options.paras.selectedValues,i,n,{});else{var r=t,a=this._getTree(this.options.paras.selectedValues,i);for(BI.isNotNull(a[n])&&delete a[n];null!=r&&BI.isEmpty(a);)i=i.slice(0,i.length-1),null!=(r=r.getParentNode())&&delete(a=this._getTree(this.options.paras.selectedValues,i))[n=this._getNodeValue(r)];this.options.paras.selectedValues=this._getJoinValue()}BI.AsyncTree.superclass._selectTreeNode.apply(this,arguments)},_beforeExpandNode:function(e,r){var a=this,n=this.options,o=function(e){var t,i,n=e.items||[];0<n.length&&(t=a._dealWidthNodes(n),i=!!e.hasNext,a.nodes.addNodes(r,t),i?a.service.pushNodeList(r.tId,s):a.service.removeNodeList(r.tId))};function s(e){e=e||{};var t=r.parentValues||a._getParentValues(r),i=BI.extend({},n.paras,{id:r.id,times:e.times,parentValues:t.concat(a._getNodeValue(r)),checkState:r.getCheckStatus()},e);n.itemsCreator(i,o)}var t=r.getCheckStatus();r.children||setTimeout(function(){s({times:1,checkState:t})},17)},_join:function(e,t){var a=this,o={};function s(i,n,r){BI.each(n,function(e,t){BI.isNull(r[e])||BI.isEmpty(r[e])?a._addTreeNode(o,i,e,t):s(i.concat([e]),n[e],r[e])})}return s([],e,t),s([],t,e),o},hasChecked:function(){return!BI.isEmpty(this.options.paras.selectedValues)||BI.AsyncTree.superclass.hasChecked.apply(this,arguments)},_getJoinValue: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._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(o){var e=o.treeObj,t=consts.event;e.bind(t.NODECREATED,function(e,t,i){tools.apply(o.callback.onNodeCreated,[e,t,i])}),e.bind(t.CLICK,function(e,t,i,n,r){tools.apply(o.callback.onClick,[t,i,n,r])}),e.bind(t.EXPAND,function(e,t,i){tools.apply(o.callback.onExpand,[e,t,i])}),e.bind(t.COLLAPSE,function(e,t,i){tools.apply(o.callback.onCollapse,[e,t,i])}),e.bind(t.ASYNC_SUCCESS,function(e,t,i,n){tools.apply(o.callback.onAsyncSuccess,[e,t,i,n])}),e.bind(t.ASYNC_ERROR,function(e,t,i,n,r,a){tools.apply(o.callback.onAsyncError,[e,t,i,n,r,a])}),e.bind(t.REMOVE,function(e,t,i){tools.apply(o.callback.onRemove,[e,t,i])}),e.bind(t.SELECTED,function(e,t,i,n){tools.apply(o.callback.onSelected,[t,i,n])}),e.bind(t.UNSELECTED,function(e,t,i,n){tools.apply(o.callback.onUnSelected,[t,i,n])})},_unbindEvent=function(e){var t=e.treeObj,i=consts.event;t.unbind(i.NODECREATED).unbind(i.CLICK).unbind(i.EXPAND).unbind(i.COLLAPSE).unbind(i.ASYNC_SUCCESS).unbind(i.ASYNC_ERROR).unbind(i.REMOVE).unbind(i.SELECTED).unbind(i.UNSELECTED)},_eventProxy=function(e){var t=e.target,i=data.getSetting(e.data.treeId),n="",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)?(n=tools.getNodeMainDom(t).id,a="switchNode"):(u=tools.getMDom(i,t,[{tagName:"a",attrName:"treeNode"+consts.id.A}]))&&(n=tools.getNodeMainDom(u).id,a="clickNode"):tools.eqs(e.type,"dblclick")&&(o="dblclick",(u=tools.getMDom(i,t,[{tagName:"a",attrName:"treeNode"+consts.id.A}]))&&(n=tools.getNodeMainDom(u).id,a="switchNode")),0<o.length&&0==n.length&&(u=tools.getMDom(i,t,[{tagName:"a",attrName:"treeNode"+consts.id.A}]))&&(n=tools.getNodeMainDom(u).id),0<n.length)switch(r=data.getNodeCache(i,n),a){case"switchNode":r.isParent&&(tools.eqs(e.type,"click")||tools.eqs(e.type,"dblclick")&&tools.apply(i.view.dblClickExpand,[i.treeId,r],i.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,i,n,r,a,o){var s,l;i&&(s=data.getRoot(e),l=e.data.key.children,i.level=t,i.tId=e.treeId+"_"+ ++s.zId,i.parentTId=n?n.tId:null,i.open="string"==typeof i.open?tools.eqs(i.open,"true"):!!i.open,i[l]&&0<i[l].length?(i.isParent=!0,i.zAsync=!0):(i.isParent="string"==typeof i.isParent?tools.eqs(i.isParent,"true"):!!i.isParent,i.open=!(!i.isParent||e.async.enable)&&i.open,i.zAsync=!i.isParent),i.isFirstNode=r,i.isLastNode=a,i.getParentNode=function(){return data.getNodeCache(e,i.parentTId)},i.getPreNode=function(){return data.getPreNode(e,i)},i.getNextNode=function(){return data.getNextNode(e,i)},i.isAjaxing=!1,data.fixPIdKeyValue(e,i))},_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,i){var n=e.data.key.children;t[n]||(t[n]=[]),0<t[n].length&&(t[n][t[n].length-1].isLastNode=!1,view.setNodeLineIcos(e,t[n][t[n].length-1])),t.isParent=!0,t[n]=t[n].concat(i)},addSelectedNode:function(e,t){var i=data.getRoot(e);data.isSelectedNode(e,t)||i.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,i){for(var n=0,r=_init.afterA.length;n<r;n++)_init.afterA[n].apply(this,arguments)},getBeforeA:function(e,t,i){for(var n=0,r=_init.beforeA.length;n<r;n++)_init.beforeA[n].apply(this,arguments)},getInnerAfterA:function(e,t,i){for(var n=0,r=_init.innerAfterA.length;n<r;n++)_init.innerAfterA[n].apply(this,arguments)},getInnerBeforeA:function(e,t,i){for(var n=0,r=_init.innerBeforeA.length;n<r;n++)_init.innerBeforeA[n].apply(this,arguments)},getCache:function(e){return caches[e.treeId]},getNextNode:function(e,t){if(!t)return null;for(var i=e.data.key.children,n=t.parentTId?t.getParentNode():data.getRoot(e),r=0,a=n[i].length-1;r<=a;r++)if(n[i][r]===t)return r==a?null:n[i][r+1];return null},getNodeByParam:function(e,t,i,n){if(!t||!i)return null;for(var r=e.data.key.children,a=0,o=t.length;a<o;a++){if(t[a][i]==n)return t[a];var s=data.getNodeByParam(e,t[a][r],i,n);if(s)return s}return null},getNodeCache:function(e,t){if(!t)return null;var i=caches[e.treeId].nodes[data.getNodeCacheId(t)];return i||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,i,n){if(!t||!i)return[];for(var r=e.data.key.children,a=[],o=0,s=t.length;o<s;o++)t[o][i]==n&&a.push(t[o]),a=a.concat(data.getNodesByParam(e,t[o][r],i,n));return a},getNodesByParamFuzzy:function(e,t,i,n){if(!t||!i)return[];var r=e.data.key.children,a=[];n=n.toLowerCase();for(var o=0,s=t.length;o<s;o++)"string"==typeof t[o][i]&&-1<t[o][i].toLowerCase().indexOf(n)&&a.push(t[o]),a=a.concat(data.getNodesByParamFuzzy(e,t[o][r],i,n));return a},getNodesByFilter:function(e,t,i,n,r){if(!t)return n?null:[];for(var a=e.data.key.children,o=n?null:[],s=0,l=t.length;s<l;s++){if(tools.apply(i,[t[s],r],!1)){if(n)return t[s];o.push(t[s])}var u=data.getNodesByFilter(e,t[s][a],i,n,r);if(n&&u)return u;o=n?u:o.concat(u)}return o},getPreNode:function(e,t){if(!t)return null;for(var i=e.data.key.children,n=t.parentTId?t.getParentNode():data.getRoot(e),r=0,a=n[i].length;r<a;r++)if(n[i][r]===t)return 0==r?null:n[i][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,i=_init.caches.length;t<i;t++)_init.caches[t].apply(this,arguments)},initNode:function(e,t,i,n,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,i=_init.roots.length;t<i;t++)_init.roots[t].apply(this,arguments)},isSelectedNode:function(e,t){for(var i=data.getRoot(e),n=0,r=i.curSelectedList.length;n<r;n++)if(t===i.curSelectedList[n])return!0;return!1},removeNodeCache:function(e,t){var i=e.data.key.children;if(t[i])for(var n=0,r=t[i].length;n<r;n++)arguments.callee(e,t[i][n]);data.getCache(e).nodes[data.getNodeCacheId(t.tId)]=null},removeSelectedNode:function(e,t){for(var i=data.getRoot(e),n=0,r=i.curSelectedList.length;n<r;n++)t!==i.curSelectedList[n]&&data.getNodeCache(e,i.curSelectedList[n].tId)||(i.curSelectedList.splice(n,1),n--,r--)},setCache:function(e,t){caches[e.treeId]=t},setRoot:function(e,t){roots[e.treeId]=t},setZTreeTools:function(e,t){for(var i=0,n=_init.zTreeTools.length;i<n;i++)_init.zTreeTools[i].apply(this,arguments)},transformToArrayFormat:function(e,t){if(!t)return[];var i=e.data.key.children,n=[];if(tools.isArray(t))for(var r=0,a=t.length;r<a;r++)n.push(t[r]),t[r][i]&&(n=n.concat(data.transformToArrayFormat(e,t[r][i])));else n.push(t),t[i]&&(n=n.concat(data.transformToArrayFormat(e,t[i])));return n},transformTozTreeFormat:function(e,t){var i=e.data.simpleData.idKey,n=e.data.simpleData.pIdKey,r=e.data.key.children;if(!i||""==i||!t)return[];if(tools.isArray(t)){for(var a=[],o={},s=0,l=t.length;s<l;s++)o[t[s][i]]=t[s];for(s=0,l=t.length;s<l;s++)o[t[s][n]]&&t[s][i]!=t[s][n]?(o[t[s][n]][r]||(o[t[s][n]][r]=[]),o[t[s][n]][r].push(t[s])):a.push(t[s]);return a}return[t]}},event={bindEvent:function(e){for(var t=0,i=_init.bind.length;t<i;t++)_init.bind[t].apply(this,arguments)},unbindEvent:function(e){for(var t=0,i=_init.unbind.length;t<i;t++)_init.unbind[t].apply(this,arguments)},bindTree:function(e){var t={treeId:e.treeId},i=e.treeObj;e.view.txtSelectedEnable||i.bind("selectstart",function(e){var t=e.originalEvent.srcElement.nodeName.toLowerCase();return"input"===t||"textarea"===t}).css({"-moz-user-select":"-moz-none"}),i.bind("click",t,event.proxy),i.bind("dblclick",t,event.proxy),i.bind("mouseover",t,event.proxy),i.bind("mouseout",t,event.proxy),i.bind("mousedown",t,event.proxy),i.bind("mouseup",t,event.proxy),i.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=[],i=0,n=_init.proxys.length;i<n;i++){var r=_init.proxys[i].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 i=event.doProxy(e),n=!0,r=0,a=i.length;r<a;r++){var o=i[r];o.nodeEventCallback&&(n=o.nodeEventCallback.apply(o,[e,o.node])&&n),o.treeEventCallback&&(n=o.treeEventCallback.apply(o,[e,o.node])&&n)}return n}},handler={onSwitchNode:function(e,t){var i=data.getSetting(e.data.treeId);if(t.open){if(0==tools.apply(i.callback.beforeCollapse,[i.treeId,t],!0))return!0;data.getRoot(i).expandTriggerFlag=!0,view.switchNode(i,t)}else{if(0==tools.apply(i.callback.beforeExpand,[i.treeId,t],!0))return!0;data.getRoot(i).expandTriggerFlag=!0,view.switchNode(i,t)}return!0},onClickNode:function(e,t){var i=data.getSetting(e.data.treeId),n=i.view.autoCancelSelected&&(e.ctrlKey||e.metaKey)&&data.isSelectedNode(i,t)?0:i.view.autoCancelSelected&&(e.ctrlKey||e.metaKey)&&i.view.selectedMulti?2:1;return 0==tools.apply(i.callback.beforeClick,[i.treeId,t,n],!0)||(0==n?view.cancelPreSelectedNode(i,t):view.selectNode(i,t,2==n),i.treeObj.trigger(consts.event.CLICK,[e,i.treeId,t,n])),!0},onZTreeMousedown:function(e,t){var i=data.getSetting(e.data.treeId);return tools.apply(i.callback.beforeMouseDown,[i.treeId,t],!0)&&tools.apply(i.callback.onMouseDown,[e,i.treeId,t]),!0},onZTreeMouseup:function(e,t){var i=data.getSetting(e.data.treeId);return tools.apply(i.callback.beforeMouseUp,[i.treeId,t],!0)&&tools.apply(i.callback.onMouseUp,[e,i.treeId,t]),!0},onZTreeDblclick:function(e,t){var i=data.getSetting(e.data.treeId);return tools.apply(i.callback.beforeDblClick,[i.treeId,t],!0)&&tools.apply(i.callback.onDblClick,[e,i.treeId,t]),!0},onZTreeContextmenu:function(e,t){var i=data.getSetting(e.data.treeId);return tools.apply(i.callback.beforeRightClick,[i.treeId,t],!0)&&tools.apply(i.callback.onRightClick,[e,i.treeId,t]),"function"!=typeof i.callback.onRightClick}},tools={apply:function(e,t,i){return"function"==typeof e?e.apply(zt,t||[]):i},canAsync:function(e,t){var i=e.data.key.children;return e.async.enable&&t&&t.isParent&&!(t.zAsync||t[i]&&0<t[i].length)},clone:function(e){if(null===e)return null;var t=tools.isArray(e)?[]:{};for(var i in e)t[i]=e[i]instanceof Date?new Date(e[i].getTime()):"object"==typeof e[i]?arguments.callee(e[i]):e[i];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,i){return t&&"string"!=typeof t&&(i=t,t=""),"string"==typeof e?$(e,i?i.treeObj.get(0).ownerDocument:null):$("#"+e.tId+t,i?i.treeObj:null)},getMDom:function(e,t,i){if(!t)return null;for(;t&&t.id!==e.treeId;){for(var n=0,r=i.length;t.tagName&&n<r;n++)if(tools.eqs(t.tagName,i[n].tagName)&&null!==t.getAttribute(i[n].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 0<$(e).closest("#"+t).length},uCanDo:function(e,t){return!0}},view={addNodes:function(e,t,i,n){var r,a,o;e.data.keep.leaf&&t&&!t.isParent||(tools.isArray(i)||(i=[i]),e.data.simpleData.enable&&(i=data.transformTozTreeFormat(e,i)),t?(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,i),view.createNodes(e,t.level+1,i,t),n||view.expandCollapseParentNode(e,t,!0)):(data.addNodesData(e,data.getRoot(e),i),view.createNodes(e,0,i,null)))},appendNodes:function(e,t,i,n,r,a){if(!i)return[];for(var o=[],s=e.data.key.children,l=0,u=i.length;l<u;l++){var c,h,p=i[l];r&&(c=(n||data.getRoot(e))[s].length==i.length&&0==l,h=l==i.length-1,data.initNode(e,t,p,n,c,h,a),data.addNodeCache(e,p));var d=[];p[s]&&0<p[s].length&&(d=view.appendNodes(e,t+1,p[s],p,r,a&&p.open)),a&&(view.makeDOMNodeMainBefore(o,e,p),view.makeDOMNodeLine(o,e,p),data.getBeforeA(e,p,o),view.makeDOMNodeNameBefore(o,e,p),data.getInnerBeforeA(e,p,o),view.makeDOMNodeIcon(o,e,p),data.getInnerAfterA(e,p,o),view.makeDOMNodeNameAfter(o,e,p),data.getAfterA(e,p,o),p.isParent&&p.open&&view.makeUlHtml(e,p,o,d.join("")),view.makeDOMNodeMainAfter(o,e,p),data.addCreatedNode(e,p))}return o},appendParentULDom:function(e,t){var i=[],n=$$(t,e);!n.get(0)&&t.parentTId&&(view.appendParentULDom(e,t.getParentNode()),n=$$(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,i,o.join("")),n.append(i.join(""))},asyncNode:function(setting,node,isSilent,callback){var i,l,icoObj;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;node&&(node.isAjaxing=!0,icoObj=$$(node,consts.id.ICON,setting),icoObj.attr({style:"","class":consts.className.BUTTON+" "+consts.className.ICO_LOADING}));for(var tmpParam={},i=0,l=setting.async.autoParam.length;node&&i<l;i++){var pKey=setting.async.autoParam[i].split("="),spKey=pKey;1<pKey.length&&(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,i){_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,i]))}}),!0},cancelPreSelectedNode:function(e,t,i){for(var n,r=data.getRoot(e).curSelectedList,a=r.length-1;0<=a;a--)if(t===(n=r[a])||!t&&(!i||i!==n)){if($$(n,consts.id.A,e).removeClass(consts.node.CURSELECTED),t){data.removeSelectedNode(e,t),e.treeObj.trigger(consts.event.UNSELECTED,[event,e.treeId,n]);break}r.splice(a,1),e.treeObj.trigger(consts.event.UNSELECTED,[event,e.treeId,n])}},createNodeCallback:function(e){if(e.callback.onNodeCreated||e.view.addDiyDom)for(var t=data.getRoot(e);0<t.createdNodes.length;){var i=t.createdNodes.shift();tools.apply(e.view.addDiyDom,[e.treeId,i]),e.callback.onNodeCreated&&e.treeObj.trigger(consts.event.NODECREATED,[e.treeId,i])}},createNodes:function(e,t,i,n){var r,a,o,s,l;i&&0!=i.length&&(r=data.getRoot(e),a=e.data.key.children,o=!n||n.open||!!$$(n[a][0],e).get(0),r.createdNodes=[],s=view.appendNodes(e,t,i,n,!0,o),n?(l=$$(n,consts.id.UL,e)).get(0)&&l.append(s.join("")):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,i,n,r){var a,o,s,l,u=data.getRoot(e),c=e.data.key.children;t?(u.expandTriggerFlag&&(a=r,r=function(){a&&a(),t.open?e.treeObj.trigger(consts.event.EXPAND,[e.treeId,t]):e.treeObj.trigger(consts.event.COLLAPSE,[e.treeId,t])},u.expandTriggerFlag=!1),!t.open&&t.isParent&&(!$$(t,consts.id.UL,e).get(0)||t[c]&&0<t[c].length&&!$$(t[c][0],e).get(0))&&(view.appendParentULDom(e,t),view.createNodeCallback(e)),t.open!=i?(o=$$(t,consts.id.UL,e),s=$$(t,consts.id.SWITCH,e),l=$$(t,consts.id.ICON,e),t.isParent?(t.open=!t.open,t.iconOpen&&t.iconClose&&l.attr("style",view.makeNodeIcoStyle(e,t)),t.open?(view.replaceSwitchClass(t,s,consts.folder.OPEN),view.replaceIcoClass(t,l,consts.folder.OPEN),0!=n&&""!=e.view.expandSpeed&&t[c]&&0<t[c].length?o.slideDown(e.view.expandSpeed,r):(o.show(),tools.apply(r,[]))):(view.replaceSwitchClass(t,s,consts.folder.CLOSE),view.replaceIcoClass(t,l,consts.folder.CLOSE),0!=n&&""!=e.view.expandSpeed&&t[c]&&0<t[c].length?o.slideUp(e.view.expandSpeed,r):(o.hide(),tools.apply(r,[])))):tools.apply(r,[])):tools.apply(r,[])):tools.apply(r,[])},expandCollapseParentNode:function(e,t,i,n,r){t&&(t.parentTId?(view.expandCollapseNode(e,t,i,n),t.parentTId&&view.expandCollapseParentNode(e,t.getParentNode(),i,n,r)):view.expandCollapseNode(e,t,i,n,r))},expandCollapseSonNode:function(e,t,i,n,r){var a=data.getRoot(e),o=e.data.key.children,s=t?t[o]:a[o],l=!t&&n,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],i,l);data.getRoot(e).expandTriggerFlag=u,view.expandCollapseNode(e,t,i,n,r)},isSelectedNode:function(e,t){if(!t)return!1;for(var i=data.getRoot(e).curSelectedList,n=i.length-1;0<=n;n--)if(t===i[n])return!0;return!1},makeDOMNodeIcon:function(e,t,i){var n=data.getNodeName(t,i),r=t.view.nameIsHTML?n:n.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;");e.push("<span id='",i.tId,consts.id.ICON,"' title='' treeNode",consts.id.ICON," class='",view.makeNodeIcoClass(t,i),"' style='",view.makeNodeIcoStyle(t,i),"'></span><span id='",i.tId,consts.id.SPAN,"'>",r,"</span>")},makeDOMNodeLine:function(e,t,i){e.push("<span id='",i.tId,consts.id.SWITCH,"' title='' class='",view.makeNodeLineClass(t,i),"' treeNode",consts.id.SWITCH,"></span>")},makeDOMNodeMainAfter:function(e,t,i){e.push("</li>")},makeDOMNodeMainBefore:function(e,t,i){e.push("<li id='",i.tId,"' class='",consts.className.LEVEL,i.level,"' tabindex='0' hidefocus='true' treenode>")},makeDOMNodeNameAfter:function(e,t,i){e.push("</a>")},makeDOMNodeNameBefore:function(e,t,i){var n=data.getNodeTitle(t,i),r=view.makeNodeUrl(t,i),a=view.makeNodeFontCss(t,i),o=[];for(var s in a)o.push(s,":",a[s],";");e.push("<a id='",i.tId,consts.id.A,"' class='",consts.className.LEVEL,i.level,"' treeNode",consts.id.A,' onclick="',i.click||"",'" ',null!=r&&0<r.length?"href='"+r+"'":""," target='",view.makeNodeTarget(i),"' style='",o.join(""),"'"),tools.apply(t.view.showTitle,[t.treeId,i],t.view.showTitle)&&n&&e.push("title='",n.replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;"),"'"),e.push(">")},makeNodeFontCss:function(e,t){var i=tools.apply(e.view.fontCss,[e.treeId,t],e.view.fontCss);return i&&"function"!=typeof i?i:{}},makeNodeIcoClass:function(e,t){var i=["ico"];return t.isAjaxing||(i[0]=(t.iconSkin?t.iconSkin+"_":"")+i[0],t.isParent?i.push(t.open?consts.folder.OPEN:consts.folder.CLOSE):i.push(consts.folder.DOCU)),consts.className.BUTTON+" "+i.join("_")},makeNodeIcoStyle:function(e,t){var i,n=[];return t.isAjaxing||((i=t.isParent&&t.iconOpen&&t.iconClose?t.open?t.iconOpen:t.iconClose:t.icon)&&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;")),n.join("")},makeNodeLineClass:function(e,t){var i=[];return e.view.showLine?0==t.level&&t.isFirstNode&&t.isLastNode?i.push(consts.line.ROOT):0==t.level&&t.isFirstNode?i.push(consts.line.ROOTS):t.isLastNode?i.push(consts.line.BOTTOM):i.push(consts.line.CENTER):i.push(consts.line.NOLINE),t.isParent?i.push(t.open?consts.folder.OPEN:consts.folder.CLOSE):i.push(consts.folder.DOCU),view.makeNodeLineClassEx(t)+i.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 i=e.data.key.url;return t[i]?t[i]:null},makeUlHtml:function(e,t,i,n){i.push("<ul id='",t.tId,consts.id.UL,"' class='",consts.className.LEVEL,t.level," ",view.makeUlLineClass(e,t),"' style='display:",t.open?"block":"none","'>"),i.push(n),i.push("</ul>")},makeUlLineClass:function(e,t){return e.view.showLine&&!t.isLastNode?consts.line.LINE:""},removeChildNodes:function(e,t){if(t){var i=e.data.key.children,n=t[i];if(n){for(var r,a,o=0,s=n.length;o<s;o++)data.removeNodeCache(e,n[o]);data.removeSelectedNode(e),delete t[i],e.data.keep.parent?$$(t,consts.id.UL,e).empty():(t.isParent=!1,t.open=!1,r=$$(t,consts.id.SWITCH,e),a=$$(t,consts.id.ICON,e),view.replaceSwitchClass(t,r,consts.folder.DOCU),view.replaceIcoClass(t,a,consts.folder.DOCU),$$(t,consts.id.UL,e).remove())}}},setFirstNode:function(e,t){var i=e.data.key.children;0<t[i].length&&(t[i][0].isFirstNode=!0)},setLastNode:function(e,t){var i=e.data.key.children,n=t[i].length;0<n&&(t[i][n-1].isLastNode=!0)},removeNode:function(e,t){var i=data.getRoot(e),n=e.data.key.children,r=t.parentTId?t.getParentNode():i;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[n].length;a<o;a++)if(r[n][a].tId==t.tId){r[n].splice(a,1);break}view.setFirstNode(e,r),view.setLastNode(e,r);var s,l,u,c,h,p=r[n].length;e.data.keep.parent||0!=p?e.view.showLine&&0<p&&(s=r[n][p-1],u=$$(s,consts.id.UL,e),c=$$(s,consts.id.SWITCH,e),h=$$(s,consts.id.ICON,e),r==i?1==r[n].length?view.replaceSwitchClass(s,c,consts.line.ROOT):(l=$$(r[n][0],consts.id.SWITCH,e),view.replaceSwitchClass(r[n][0],l,consts.line.ROOTS),view.replaceSwitchClass(s,c,consts.line.BOTTOM)):view.replaceSwitchClass(s,c,consts.line.BOTTOM),u.removeClass(consts.line.LINE)):(r.isParent=!1,r.open=!1,u=$$(r,consts.id.UL,e),c=$$(r,consts.id.SWITCH,e),h=$$(r,consts.id.ICON,e),view.replaceSwitchClass(r,c,consts.folder.DOCU),view.replaceIcoClass(r,h,consts.folder.DOCU),u.css("display","none"))}},replaceIcoClass:function(e,t,i){if(t&&!e.isAjaxing){var n=t.attr("class");if(n!=undefined){var r=n.split("_");switch(i){case consts.folder.OPEN:case consts.folder.CLOSE:case consts.folder.DOCU:r[r.length-1]=i}t.attr("class",r.join("_"))}}},replaceSwitchClass:function(e,t,i){if(t){var n=t.attr("class");if(n!=undefined){var r=n.split("_");switch(i){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)+i;break;case consts.folder.OPEN:case consts.folder.CLOSE:case consts.folder.DOCU:r[1]=i}t.attr("class",r.join("_")),i!==consts.folder.DOCU?t.removeAttr("disabled"):t.attr("disabled","disabled")}}},selectNode:function(e,t,i){i||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 i=$$(t,consts.id.A,e),n=view.makeNodeFontCss(e,t);n&&i.css(n)},setNodeLineIcos:function(e,t){var i,n,r,a;t&&(i=$$(t,consts.id.SWITCH,e),n=$$(t,consts.id.UL,e),r=$$(t,consts.id.ICON,e),0==(a=view.makeUlLineClass(e,t)).length?n.removeClass(consts.line.LINE):n.addClass(a),i.attr("class",view.makeNodeLineClass(e,t)),t.isParent?i.removeAttr("disabled"):i.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 i=data.getNodeTitle(e,t),n=$$(t,consts.id.SPAN,e);n.empty(),e.view.nameIsHTML?n.html(data.getNodeName(e,t)):n.text(data.getNodeName(e,t)),tools.apply(e.view.showTitle,[e.treeId,t],e.view.showTitle)&&$$(t,consts.id.A,e).attr("title",i||"")},setNodeTarget:function(e,t){$$(t,consts.id.A,e).attr("target",view.makeNodeTarget(t))},setNodeUrl:function(e,t){var i=$$(t,consts.id.A,e),n=view.makeNodeUrl(e,t);null==n||0==n.length?i.removeAttr("href"):i.attr("href",n)},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&&0<e.length)view.destroy(data.getSetting(e));else for(var t in settings)view.destroy(settings[t])},init:function(e,t,i){var s=tools.clone(_setting);$.extend(!0,s,t),s.treeId=e.attr("id"),s.treeObj=e,s.treeObj.empty(),settings[s.treeId]=s,"undefined"==typeof document.body.style.maxHeight&&(s.view.expandSpeed=""),data.initRoot(s);var n=data.getRoot(s),r=s.data.key.children;i=i?tools.clone(tools.isArray(i)?i:[i]):[],s.data.simpleData.enable?n[r]=data.transformTozTreeFormat(s,i):n[r]=i,data.initCache(s),event.unbindTree(s),event.bindTree(s),event.unbindEvent(s),event.bindEvent(s);var a={setting:s,addNodes:function(e,t,i){if(!t)return null;if((e=e||null)&&!e.isParent&&s.data.keep.leaf)return null;var n=tools.clone(tools.isArray(t)?t:[t]);function r(){view.addNodes(s,e,n,1==i)}return tools.canAsync(s,e)?view.asyncNode(s,e,i,r):r(),n},cancelSelectedNode:function(e){view.cancelPreSelectedNode(s,e)},destroy:function(){view.destroy(s)},expandAll:function(e){return e=!!e,view.expandCollapseSonNode(s,null,e,!0),e},expandNode:function(t,e,i,n,r){if(!t||!t.isParent)return null;if(!0!==e&&!1!==e&&(e=!t.open),(r=!!r)&&e&&0==tools.apply(s.callback.beforeExpand,[s.treeId,t],!0))return null;if(r&&!e&&0==tools.apply(s.callback.beforeCollapse,[s.treeId,t],!0))return null;if(e&&t.parentTId&&view.expandCollapseParentNode(s,t.getParentNode(),e,!1),e===t.open&&!i)return null;if(data.getRoot(s).expandTriggerFlag=r,!tools.canAsync(s,t)&&i)view.expandCollapseSonNode(s,t,e,!0,function(){if(!1!==n)try{$$(t,s).focus().blur()}catch(e){}});else if(t.open=!e,view.switchNode(this.setting,t),!1!==n)try{$$(t,s).focus().blur()}catch(a){}return e},getNodes:function(){return data.getNodes(s)},getNodeByParam:function(e,t,i){return e?data.getNodeByParam(s,i?i[s.data.key.children]:data.getNodes(s),e,t):null},getNodeByTId:function(e){return data.getNodeCache(s,e)},getNodesByParam:function(e,t,i){return e?data.getNodesByParam(s,i?i[s.data.key.children]:data.getNodes(s),e,t):null},getNodesByParamFuzzy:function(e,t,i){return e?data.getNodesByParamFuzzy(s,i?i[s.data.key.children]:data.getNodes(s),e,t):null},getNodesByFilter:function(e,t,i,n){return t=!!t,e&&"function"==typeof e?data.getNodesByFilter(s,i?i[s.data.key.children]:data.getNodes(s),e,t,n):t?null:[]},getNodeIndex:function(e){if(!e)return null;for(var t=s.data.key.children,i=e.parentTId?e.getParentNode():data.getRoot(s),n=0,r=i[t].length;n<r;n++)if(i[t][n]==e)return n;return-1},getSelectedNodes:function(){for(var e=[],t=data.getRoot(s).curSelectedList,i=0,n=t.length;i<n;i++)e.push(t[i]);return e},isSelectedNode:function(e){return data.isSelectedNode(s,e)},reAsyncChildNodes:function(e,t,i){if(this.setting.async.enable){var n=!e;if(n&&(e=data.getRoot(s)),"refresh"==t){for(var r=this.setting.data.key.children,a=0,o=e[r]?e[r].length:0;a<o;a++)data.removeNodeCache(s,e[r][a]);data.removeSelectedNode(s),e[r]=[],n?this.setting.treeObj.empty():$$(e,consts.id.UL,s).empty()}view.asyncNode(this.setting,n?null:e,!!i)}},refresh:function(){this.setting.treeObj.empty();var e=data.getRoot(s),t=e[s.data.key.children];data.initRoot(s),e[s.data.key.children]=t,data.initCache(s),view.createNodes(s,0,e[s.data.key.children])},removeChildNodes:function(e){if(!e)return null;var t=e[s.data.key.children];return view.removeChildNodes(s,e),t||null},removeNode:function(e,t){e&&((t=!!t)&&0==tools.apply(s.callback.beforeRemove,[s.treeId,e],!0)||(view.removeNode(s,e),t&&this.setting.treeObj.trigger(consts.event.REMOVE,[s.treeId,e])))},selectNode:function(t,e){if(t&&tools.uCanDo(s)){if(e=s.view.selectedMulti&&e,t.parentTId)view.expandCollapseParentNode(s,t.getParentNode(),!0,!1,function(){try{$$(t,s).focus().blur()}catch(e){}});else try{$$(t,s).focus().blur()}catch(i){}view.selectNode(s,t,e)}},transformTozTreeNodes:function(e){return data.transformTozTreeFormat(s,e)},transformToArray:function(e){return data.transformToArrayFormat(s,e)},updateNode:function(e,t){e&&$$(e,s).get(0)&&tools.uCanDo(s)&&(view.setNodeName(s,e),view.setNodeTarget(s,e),view.setNodeUrl(s,e),view.setNodeLineIcos(s,e),view.setNodeFontCss(s,e))}};return n.treeTools=a,data.setZTreeTools(s,a),n[r]&&0<n[r].length?view.createNodes(s,0,n[r]):s.async.enable&&s.async.url&&""!==s.async.url&&view.asyncNode(s),a}};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"}},i={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}},s={onCheckNode:function(e,t){if(!0===t.chkDisabled)return!1;var i=d.getSetting(e.data.treeId),n=i.data.key.checked;if(0==l.apply(i.callback.beforeCheck,[i.treeId,t],!0))return!0;t[n]=!t[n],p.checkNodeRelation(i,t);var r=f(t,h.id.CHECK,i);return p.setChkClass(i,r,t),p.repairParentChkClassWithSelf(i,t),i.treeObj.trigger(h.event.CHECK,[e,i.treeId,t]),!0},onMouseoverCheck:function(e,t){if(!0===t.chkDisabled)return!1;var i=d.getSetting(e.data.treeId),n=f(t,h.id.CHECK,i);return t.check_Focus=!0,p.setChkClass(i,n,t),!0},onMouseoutCheck:function(e,t){if(!0===t.chkDisabled)return!1;var i=d.getSetting(e.data.treeId),n=f(t,h.id.CHECK,i);return t.check_Focus=!1,p.setChkClass(i,n,t),!0}},n={tools:{},view:{checkNodeRelation:function(e,t){var i,n=e.data.key.children,r=e.data.key.checked,a=h.radio;if(e.check.chkStyle==a.STYLE){var o=d.getRadioCheckedList(e);if(t[r])if(e.check.radioType==a.TYPE_ALL){for(l=o.length-1;0<=l;l--)(i=o[l])[r]&&i!=t&&(i[r]=!1,o.splice(l,1),p.setChkClass(e,f(i,h.id.CHECK,e),i),i.parentTId!=t.parentTId&&p.repairParentChkClassWithSelf(e,i));o.push(t)}else for(var s=t.parentTId?t.getParentNode():d.getRoot(e),l=0,u=s[n].length;l<u;l++)(i=s[n][l])[r]&&i!=t&&(i[r]=!1,p.setChkClass(e,f(i,h.id.CHECK,e),i));else if(e.check.radioType==a.TYPE_ALL)for(l=0,u=o.length;l<u;l++)if(t==o[l]){o.splice(l,1);break}}else t[r]&&(!t[n]||0==t[n].length||-1<e.check.chkboxType.Y.indexOf("s"))&&p.setSonNodeCheckBox(e,t,!0),t[r]||t[n]&&0!=t[n].length&&!(-1<e.check.chkboxType.N.indexOf("s"))||p.setSonNodeCheckBox(e,t,!1),t[r]&&-1<e.check.chkboxType.Y.indexOf("p")&&p.setParentNodeCheckBox(e,t,!0),!t[r]&&-1<e.check.chkboxType.N.indexOf("p")&&p.setParentNodeCheckBox(e,t,!1)},makeChkClass:function(e,t){var i=e.data.key.checked,n=h.checkbox,r=h.radio,a=e.check.chkboxType,o=""===a.Y&&""===a.N;fullStyle="",fullStyle=!0===t.chkDisabled?n.DISABLED:t.halfCheck?n.PART:e.check.chkStyle==r.STYLE?t.check_Child_State<1?n.FULL:n.PART:t[i]?2===t.check_Child_State||-1===t.check_Child_State||o?n.FULL:n.PART:t.check_Child_State<1||o?n.FULL:n.PART;var s=e.check.chkStyle+"_"+(t[i]?n.TRUE:n.FALSE)+"_"+fullStyle,s=t.check_Focus&&!0!==t.chkDisabled?s+"_"+n.FOCUS:s;return h.className.BUTTON+" "+n.DEFAULT+" "+s},repairAllChk:function(e,t){if(e.check.enable&&e.check.chkStyle===h.checkbox.STYLE)for(var i=e.data.key.checked,n=e.data.key.children,r=d.getRoot(e),a=0,o=r[n].length;a<o;a++){var s=r[n][a];!0!==s.nocheck&&!0!==s.chkDisabled&&(s[i]=t),p.setSonNodeCheckBox(e,s,t)}},repairChkClass:function(e,t){var i;t&&(d.makeChkFlag(e,t),!0!==t.nocheck&&(i=f(t,h.id.CHECK,e),p.setChkClass(e,i,t)))},repairParentChkClass:function(e,t){var i;t&&t.parentTId&&(i=t.getParentNode(),p.repairChkClass(e,i),p.repairParentChkClass(e,i))},repairParentChkClassWithSelf:function(e,t){var i;t&&(t[i=e.data.key.children]&&0<t[i].length?p.repairParentChkClass(e,t[i][0]):p.repairParentChkClass(e,t))},repairSonChkDisabled:function(e,t,i,n){if(t){var r=e.data.key.children;if(t.chkDisabled!=i&&(t.chkDisabled=i),p.repairChkClass(e,t),t[r]&&n)for(var a=0,o=t[r].length;a<o;a++){var s=t[r][a];p.repairSonChkDisabled(e,s,i,n)}}},repairParentChkDisabled:function(e,t,i,n){t&&(t.chkDisabled!=i&&n&&(t.chkDisabled=i),p.repairChkClass(e,t),p.repairParentChkDisabled(e,t.getParentNode(),i,n))},setChkClass:function(e,t,i){t&&(!0===i.nocheck?t.hide():t.show(),t.attr("class",p.makeChkClass(e,i)))},setParentNodeCheckBox:function(e,t,i,n){var r=e.data.key.children,a=e.data.key.checked,o=f(t,h.id.CHECK,e);if(n=n||t,d.makeChkFlag(e,t),!0!==t.nocheck&&!0!==t.chkDisabled&&(t[a]=i,p.setChkClass(e,o,t),e.check.autoCheckTrigger&&t!=n&&e.treeObj.trigger(h.event.CHECK,[null,e.treeId,t])),t.parentTId){var s=!0;if(!i)for(var l=t.getParentNode()[r],u=0,c=l.length;u<c;u++)if(!0!==l[u].nocheck&&!0!==l[u].chkDisabled&&l[u][a]||(!0===l[u].nocheck||!0===l[u].chkDisabled)&&0<l[u].check_Child_State){s=!1;break}s&&p.setParentNodeCheckBox(e,t.getParentNode(),i,n)}},setSonNodeCheckBox:function(e,t,i,n){if(t){var r=e.data.key.children,a=e.data.key.checked,o=f(t,h.id.CHECK,e);n=n||t;var s=!1;if(t[r])for(var l=0,u=t[r].length;l<u&&!0!==t.chkDisabled;l++){var c=t[r][l];p.setSonNodeCheckBox(e,c,i,n),!0===c.chkDisabled&&(s=!0)}t!=d.getRoot(e)&&!0!==t.chkDisabled&&(s&&!0!==t.nocheck&&d.makeChkFlag(e,t),!0!==t.nocheck&&!0!==t.chkDisabled?(t[a]=i,s||(t.check_Child_State=t[r]&&0<t[r].length?i?2:0:-1)):t.check_Child_State=-1,p.setChkClass(e,o,t),e.check.autoCheckTrigger&&t!=n&&!0!==t.nocheck&&!0!==t.chkDisabled&&e.treeObj.trigger(h.event.CHECK,[null,e.treeId,t]))}}},event:{},data:{getRadioCheckedList:function(e){for(var t=d.getRoot(e).radioCheckedList,i=0,n=t.length;i<n;i++)d.getNodeCache(e,t[i].tId)||(t.splice(i,1),i--,n--);return t},getCheckStatus:function(e,t){if(!e.check.enable||t.nocheck||t.chkDisabled)return null;var i=e.data.key.checked;return{checked:t[i],half:t.halfCheck?t.halfCheck:e.check.chkStyle==h.radio.STYLE?2===t.check_Child_State:t[i]?-1<t.check_Child_State&&t.check_Child_State<2:0<t.check_Child_State}},getTreeCheckedNodes:function(e,t,i,n){if(!t)return[];var r=e.data.key.children,a=e.data.key.checked,o=i&&e.check.chkStyle==h.radio.STYLE&&e.check.radioType==h.radio.TYPE_ALL;n=n||[];for(var s=0,l=t.length;s<l&&(!0===t[s].nocheck||!0===t[s].chkDisabled||t[s][a]!=i||(n.push(t[s]),!o))&&(d.getTreeCheckedNodes(e,t[s][r],i,n),!(o&&0<n.length));s++);return n},getTreeChangeCheckedNodes:function(e,t,i){if(!t)return[];var n=e.data.key.children,r=e.data.key.checked;i=i||[];for(var a=0,o=t.length;a<o;a++)!0!==t[a].nocheck&&!0!==t[a].chkDisabled&&t[a][r]!=t[a].checkedOld&&i.push(t[a]),d.getTreeChangeCheckedNodes(e,t[a][n],i);return i},makeChkFlag:function(e,t){if(t){var i=e.data.key.children,n=e.data.key.checked,r=-1;if(t[i])for(var a=0,o=t[i].length;a<o;a++){var s=t[i][a],l=-1;if(e.check.chkStyle==h.radio.STYLE){if(2==(l=!0===s.nocheck||!0===s.chkDisabled?s.check_Child_State:!0===s.halfCheck||s[n]||0<s.check_Child_State?2:0)){r=2;break}0==l&&(r=0)}else if(e.check.chkStyle==h.checkbox.STYLE){if(1===(l=!0===s.nocheck||!0===s.chkDisabled?s.check_Child_State:!0===s.halfCheck?1:s[n]?-1===s.check_Child_State||2===s.check_Child_State?2:1:0<s.check_Child_State?1:0)){r=1;break}if(2===l&&-1<r&&0<a&&l!==r){r=1;break}if(2===r&&-1<l&&l<2){r=1;break}-1<l&&(r=l)}}t.check_Child_State=r}}}};e.extend(!0,e.fn.zTree.consts,t),e.extend(!0,e.fn.zTree._z,n);var r=e.fn.zTree,l=r._z.tools,h=r.consts,p=r._z.view,d=r._z.data,f=(r._z.event,l.$);d.exSetting(i),d.addInitBind(function(r){var e=r.treeObj,t=h.event;e.bind(t.CHECK,function(e,t,i,n){e.srcEvent=t,l.apply(r.callback.onCheck,[e,i,n])})}),d.addInitUnBind(function(e){var t=e.treeObj,i=h.event;t.unbind(i.CHECK)}),d.addInitCache(function(e){}),d.addInitNode(function(e,t,i,n,r,a,o){var s;i&&(s=e.data.key.checked,"string"==typeof i[s]&&(i[s]=l.eqs(i[s],"true")),i[s]=!!i[s],i.checkedOld=i[s],"string"==typeof i.nocheck&&(i.nocheck=l.eqs(i.nocheck,"true")),i.nocheck=!!i.nocheck||e.check.nocheckInherit&&n&&!!n.nocheck,"string"==typeof i.chkDisabled&&(i.chkDisabled=l.eqs(i.chkDisabled,"true")),i.chkDisabled=!!i.chkDisabled||e.check.chkDisabledInherit&&n&&!!n.chkDisabled,"string"==typeof i.halfCheck&&(i.halfCheck=l.eqs(i.halfCheck,"true")),i.halfCheck=!!i.halfCheck,i.check_Child_State=-1,i.check_Focus=!1,i.getCheckStatus=function(){return d.getCheckStatus(e,i)},e.check.chkStyle==h.radio.STYLE&&e.check.radioType==h.radio.TYPE_ALL&&i[s]&&d.getRoot(e).radioCheckedList.push(i))}),d.addInitProxy(function(e){var t=e.target,i=d.getSetting(e.data.treeId),n="",r=null,a="",o=null;if(l.eqs(e.type,"mouseover")?i.check.enable&&l.eqs(t.tagName,"span")&&null!==t.getAttribute("treeNode"+h.id.CHECK)&&(n=l.getNodeMainDom(t).id,a="mouseoverCheck"):l.eqs(e.type,"mouseout")?i.check.enable&&l.eqs(t.tagName,"span")&&null!==t.getAttribute("treeNode"+h.id.CHECK)&&(n=l.getNodeMainDom(t).id,a="mouseoutCheck"):l.eqs(e.type,"click")&&i.check.enable&&l.eqs(t.tagName,"span")&&null!==t.getAttribute("treeNode"+h.id.CHECK)&&(n=l.getNodeMainDom(t).id,a="checkNode"),0<n.length)switch(r=d.getNodeCache(i,n),a){case"checkNode":o=s.onCheckNode;break;case"mouseoverCheck":o=s.onMouseoverCheck;break;case"mouseoutCheck":o=s.onMouseoutCheck}return{stop:"checkNode"===a,node:r,nodeEventType:a,nodeEventCallback:o,treeEventType:"",treeEventCallback:null}},!0),d.addInitRoot(function(e){d.getRoot(e).radioCheckedList=[]}),d.addBeforeA(function(e,t,i){e.data.key.checked;e.check.enable&&(d.makeChkFlag(e,t),i.push("<span ID='",t.tId,h.id.CHECK,"' class='",p.makeChkClass(e,t),"' treeNode",h.id.CHECK,!0===t.nocheck?" style='display:none;'":"","></span>"))}),d.addZTreeTools(function(e,n){n.checkNode=function(e,t,i,n){var r,a=this.setting.data.key.checked;!0!==e.chkDisabled&&(!0!==t&&!1!==t&&(t=!e[a]),n=!!n,e[a]===t&&!i||n&&0==l.apply(this.setting.callback.beforeCheck,[this.setting.treeId,e],!0)||l.uCanDo(this.setting)&&this.setting.check.enable&&!0!==e.nocheck&&(e[a]=t,r=f(e,h.id.CHECK,this.setting),!i&&this.setting.check.chkStyle!==h.radio.STYLE||p.checkNodeRelation(this.setting,e),p.setChkClass(this.setting,r,e),p.repairParentChkClassWithSelf(this.setting,e),n&&this.setting.treeObj.trigger(h.event.CHECK,[null,this.setting.treeId,e])))},n.checkAllNodes=function(e){p.repairAllChk(this.setting,!!e)},n.getCheckedNodes=function(e){var t=this.setting.data.key.children;return e=!1!==e,d.getTreeCheckedNodes(this.setting,d.getRoot(this.setting)[t],e)},n.getChangeCheckedNodes=function(){var e=this.setting.data.key.children;return d.getTreeChangeCheckedNodes(this.setting,d.getRoot(this.setting)[e])},n.setChkDisabled=function(e,t,i,n){t=!!t,i=!!i,n=!!n,p.repairSonChkDisabled(this.setting,e,t,n),p.repairParentChkDisabled(this.setting,e.getParentNode(),t,i)};var r=n.updateNode;n.updateNode=function(e,t){var i;r&&r.apply(n,arguments),e&&this.setting.check.enable&&f(e,this.setting).get(0)&&l.uCanDo(this.setting)&&(i=f(e,h.id.CHECK,this.setting),1!=t&&this.setting.check.chkStyle!==h.radio.STYLE||p.checkNodeRelation(this.setting,e),p.setChkClass(this.setting,i,e),p.repairParentChkClassWithSelf(this.setting,e))}});var a=p.createNodes;p.createNodes=function(e,t,i,n){a&&a.apply(p,arguments),i&&p.repairParentChkClassWithSelf(e,n)};var o=p.removeNode;p.removeNode=function(e,t){var i=t.getParentNode();o&&o.apply(p,arguments),t&&i&&(p.repairChkClass(e,i),p.repairParentChkClass(e,i))};var u=p.appendNodes;p.appendNodes=function(e,t,i,n,r,a){var o="";return u&&(o=u.apply(p,arguments)),n&&d.makeChkFlag(e,n),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 a=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(e,t,i){a._selectTreeNode(t,i)},onClick:function(e,t,i){var n=BI.$.fn.zTree.getZTreeObj(t),r=i.checked;a._checkValue(i,!r),n.checkNode(i,!r,!0,!0)}}}},_selectTreeNode:function(e,t){this._checkValue(t,t.checked),BI.ListTreeView.superclass._selectTreeNode.apply(this,arguments)},_transArrayToMap:function(e){var n=this,r={};return BI.each(e,function(e,t){var i=t.join(n._constants.SPLIT);r[i]=!0}),r},_transMapToArray:function(e){var i=this,n=[];return BI.each(e,function(e){var t=e.split(i._constants.SPLIT);n.push(t)}),n},_checkValue:function(e,t){var i=BI.concat(this._getParentValues(e),this._getNodeValue(e)).join(this._constants.SPLIT);t?this.storeValue[i]=!0:delete this.storeValue[i]},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,a=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,t,i){a._selectTreeNode(t,i)},beforeExpand:function(e,t){a._beforeExpandNode(e,t)},beforeCheck:function(e,t){t.half=!1},onClick:function(e,t,i){var n=BI.$.fn.zTree.getZTreeObj(t),r=i.checked;a._checkValue(i,!r),n.checkNode(i,!r,!0,!0)}}}},_beforeExpandNode:function(e,r){var a=this,o=this.options,t=r.parentValues||a._getParentValues(r),s=BI.extend({},o.paras,{id:r.id,times:1,parentValues:t.concat(this._getNodeValue(r))}),l=function(e){var t,i,n=e.items||[];0<n.length&&(t=a._dealWidthNodes(n),i=!!e.hasNext,a.nodes.addNodes(r,t),!0===i&&BI.delay(function(){u++,s.times=u,o.itemsCreator(s,l)},100))},u=1;r.children||setTimeout(function(){o.itemsCreator(s,l)},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 n=this,r=this.options,e=BI.extend({},r.paras,{type:BI.TreeView.REQ_TYPE_INIT_DATA,times:++this.times});this.tip.setLoading(),r.itemsCreator(e,function(e){var t=!!e.hasNext,i=e.items||[];r.paras.lastSearchValue=e.lastSearchValue,!0!==n._stop&&(t?n.tip.setLoaded():n.tip.setEnd(),0<i.length&&n.nodes.addNodes(null,n._dealWidthNodes(i)))})},_initTree:function(n,r){var a=this,o=this.options;this.times=1;var s=this.tree;s.empty(),a.tip.setVisible(!1),this.loading();var e=BI.extend({},o.paras,{type:BI.TreeView.REQ_TYPE_INIT_DATA,times:this.times}),t=function(e){var t,i;!0!==a._stop&&r==o.paras.keyword&&(t=!!e.hasNext,i=e.items||[],o.paras.lastSearchValue=e.lastSearchValue,function(e){if(!0===a._stop)return;a.nodes=BI.$.fn.zTree.init(s.element,n,e)}(0<i.length?a._dealWidthNodes(i):[]),a.setTipVisible(i.length<=0),a.loaded(),t?a.tip.setLoaded():a.tip.invisible(),a.fireEvent(BI.Events.AFTERINIT))};BI.delay(function(){o.itemsCreator(e,t)},100)},stroke:function(e){var t=this.options;delete t.paras.keyword,BI.extend(t.paras,e),delete t.paras.lastSearchValue;var i=this._configSetting();this._initTree(i,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 n=this,r=this.options,e=BI.extend({},r.paras,{type:BI.TreeView.REQ_TYPE_INIT_DATA,times:++this.times});this.tip.setLoading(),r.itemsCreator(e,function(e){var t=!!e.hasNext,i=e.items||[];r.paras.lastSearchValue=e.lastSearchValue,!0!==n._stop&&(t?n.tip.setLoaded():n.tip.setEnd(),0<i.length&&n.nodes.addNodes(null,n._dealWidthNodes(i)))})},_selectTreeNode:function(e,t){var i=this,n=this.options,r=BI.deepClone(t.parentValues||i._getParentValues(t)),a=this._getNodeValue(t);if(!0===t.checked)this.options.paras.selectedValues=this._getUnionValue(),n.itemsCreator(BI.extend({},n.paras,{type:BI.TreeView.REQ_TYPE_ADJUST_DATA,curSelectedValue:a,parentValues:r}),function(e){i.options.paras.selectedValues=e,BI.AsyncTree.superclass._selectTreeNode.apply(i,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}n.itemsCreator(BI.extend({},n.paras,{type:BI.TreeView.REQ_TYPE_SELECT_DATA,notSelectedValue:a,parentValues:r}),function(e){i.options.paras.selectedValues=e,BI.AsyncTree.superclass._selectTreeNode.apply(i,arguments)})}},_getSelectedValues:function(){var a=this,o={};return function s(e){BI.each(e,function(e,t){var i=t.getCheckStatus();if(!1===i.checked)return!0;var n=t.parentValues||a._getParentValues(t),r=n.concat([a._getNodeValue(t)]);if(a._buildTree(o,r),BI.isNotEmptyArray(t.children))return s(t.children),!0;!0===i.half&&a._getHalfSelectedValues(o,t)})}(this.nodes.getNodes()),o},_initTree:function(n,r){var a=this,o=this.options;this.times=1;var s=this.tree;s.empty(),a.tip.setVisible(!1),this.loading();var e=BI.extend({},o.paras,{type:BI.TreeView.REQ_TYPE_INIT_DATA,times:this.times}),t=function(e){var t,i;!0!==a._stop&&r==o.paras.keyword&&(t=!!e.hasNext,i=e.items||[],o.paras.lastSearchValue=e.lastSearchValue,function(e){if(!0===a._stop)return;a.nodes=BI.$.fn.zTree.init(s.element,n,e)}(0<i.length?a._dealWidthNodes(i):[]),a.setTipVisible(i.length<=0),a.loaded(),t?a.tip.setLoaded():a.tip.invisible(),a.fireEvent(BI.Events.AFTERINIT))};BI.delay(function(){o.itemsCreator(e,t)},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 a=this,o={};function s(i,n,r){BI.each(n,function(e,t){BI.isNull(r[e])?a._addTreeNode(o,i,e,t):BI.isEmpty(r[e])?a._addTreeNode(o,i,e,{}):s(i.concat([e]),n[e],r[e])})}return s([],e,t),s([],t,e),o},stroke:function(e){var t=this.options;delete t.paras.keyword,BI.extend(t.paras,e),delete t.paras.lastSearchValue;var i=this._configSetting();this._initTree(i,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&&0<t.count&&(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&&0<t.count&&(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 n=this,r=this.options;this.structure=new BI.Tree,this.tree=BI.createWidget({type:"bi.tree_view",element:this,itemsCreator:function(e,t){var i=function(e){t({items:e}),n.structure.initTree(BI.Tree.transformToTreeFormat(e))};BI.isNotNull(r.items)?i(r.items):r.itemsCreator(e,i)}}),this.tree.on(BI.TreeView.EVENT_CHANGE,function(){n.fireEvent(BI.SimpleTreeView.EVENT_CHANGE,arguments)}),BI.isNotEmptyArray(r.items)&&this.populate(),BI.isNotNull(r.value)&&this.setValue(r.value)},populate:function(e,t){e&&(this.options.items=e),this.tree.stroke({keyword:t})},_digest:function(e){e=e||[];var r=this,a={},o=[];return BI.each(e,function(e,t){var i=r.structure.search(t,"value");if(i){var n=i;for((n=n.getParent())&&(a[n.value]||(a[n.value]=0),a[n.value]++);n&&n.getChildrenLength()<=a[n.value];)o.push(n.value),(n=n.getParent())&&(a[n.value]||(a[n.value]=0),a[n.value]++)}}),BI.makeObject(e.concat(o))},setValue:function(e){this.tree.setValue(this._digest(e))},_getValue:function(){var i=[],e=this.tree.getValue(),n=function(e){BI.each(e,function(e,t){BI.isEmpty(t)?i.push(e):n(t)})};return n(e),i},empty:function(){this.tree.empty()},getValue:function(){var n=this,r=[],e=this._getValue();return BI.each(e,function(e,t){var i=n.structure.search(t,"value");i&&n.structure._traverse(i,function(e){e.isLeaf()&&r.push(e.value)})}),r}}),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),i=this._getTreeContainerBounds(e);return t.top+t.height<i.top+i.height},_isNodeInVisible:function(e){var t=this.options.subNodeListGetter(e);return 0===t.length||"none"===t.css("display")},pushNodeList:function(e,t){var i=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(){i.refreshAllNodes()},30)))},refreshAllNodes:function(){var t=this;BI.each(this.nodeLists,function(e){t._isNodeInVisible(e)||t.refreshNodes(e)})},refreshNodes:function(e){var t;this._canNodePopulate(e)&&((t=this.nodeLists[e]).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 t=this;BI.each(this.nodeLists,function(e){t.removeNodeList(e)}),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,i=BI.createWidget({type:"bi.loading_bar",height:25,handler:function(){t.refreshNodes(e)}});return i.setLoaded(),i},pushNodeList:function(e,t){var i=this.options,n=this._getLoadingBar(e);BI.has(this.nodeLists,e)?(this.nodeLists[e].loadWidget.destroy(),this.nodeLists[e].loadWidget=n):this.nodeLists[e]={populate:BI.debounce(t,0),options:{times:1},loadWidget:n},BI.createWidget({type:"bi.vertical",element:i.subNodeListGetter(e),items:[n]})},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 t=this;BI.each(this.nodeLists,function(e){t.removeNodeList(e)}),this.nodeLists={}}})},function(e,t){function a(e,t,i,n){return BI.isPlainObject(i)&&(i=(n=i).handler),n=n||{},Fix.watch(e.model,t,_.bind(i,e),BI.extend(n,{store:e.store}))}var r,o;o={},BI.useWorker=function(e){r=e;var t=BI.Widget.prototype._init;BI.Widget.prototype._init=function(){this.$destroyWorker=function(){var e;if(this._worker){var i=this.getName(),n=this._worker();if(BI.isArray(n)&&(e=n[1],n=n[0]),r){o[i]=this,r.postMessage({type:n,name:i,eventType:"create",options:e,watches:BI.map(this.watch,function(e){return e})});return this.store=new Proxy({},{get:function(e,t){return function(){r.postMessage({type:n,name:i,eventType:"action",action:t,args:[].slice.call(arguments)})}},set:function(e,t,i){return Reflect.set(e,t,i)}}),function(){delete o[i],r.postMessage({type:n,name:i,eventType:"destroy"})}}return this.store=BI.Models.getModel(n,e),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 i in e._watchers||(e._watchers=[]),t){var n=t[i];if(BI.isArray(n))for(var r=0;r<n.length;r++)e._watchers.push(a(e,i,n[r]));else e._watchers.push(a(e,i,n))}}(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)}}}.call(this);try{t.apply(this,arguments)}catch(e){console.error(e)}};var i=BI.Widget.prototype._initRender;BI.Widget.prototype._initRender=function(){r&&this._worker?(this.__asking=!0,this.__async=!0):i.apply(this,arguments)};var n=BI.Widget.prototype.__d;BI.Widget.prototype.__d=function(){this.$destroyWorker&&this.$destroyWorker();try{n.apply(this,arguments)}catch(e){console.error(e)}},r&&r.addEventListener("message",function(e){var t=e.data;(function(e){switch(e.eventType){case"create":this.model=e.msg,i.call(this);break;case"watch":var t=e.args;this.watch[e.currentWatchType].apply(this,t)}}).apply(o[t.name],[t])},!1)}},function(e,t,i){var s=i(60),n=i(1123),l=i(281),u=i(280),c=i(1148),r=i(1159),a=i(917),o=a.get,h=a.enforce,p=String(r).split("toString");n("inspectSource",function(e){return r.call(e)}),(e.exports=function(e,t,i,n){var r=!!n&&!!n.unsafe,a=!!n&&!!n.enumerable,o=!!n&&!!n.noTargetGet;"function"==typeof i&&("string"!=typeof t||u(i,"name")||l(i,"name",t),h(i).source=p.join("string"==typeof t?t:"")),e!==s?(r?!o&&e[t]&&(a=!0):delete e[t],a?e[t]=i:l(e,t,i)):a?e[t]=i:c(t,i)})(Function.prototype,"toString",function(){return"function"==typeof this&&o(this).source||r.call(this)})},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t){Array.prototype.indexOf||(Array.prototype.indexOf=function(e,t){var i;if(null==this)throw new TypeError('"this" is null or not defined');var n=Object(this),r=n.length>>>0;if(0==r)return-1;var a=0|t;if(r<=a)return-1;for(i=Math.max(0<=a?a:r-Math.abs(a),0);i<r;){if(i in n&&n[i]===e)return i;i++}return-1}),Array.prototype.lastIndexOf||(Array.prototype.lastIndexOf=function(e){"use strict";if(null==this)throw new TypeError;var t,i,n=Object(this),r=n.length>>>0;if(0==r)return-1;for(t=r-1,1<arguments.length&&((t=Number(arguments[1]))!=t?t=0:0!=t&&t!=1/0&&t!=-1/0&&(t=(0<t||-1)*Math.floor(Math.abs(t)))),i=0<=t?Math.min(t,r-1):r-Math.abs(t);0<=i;i--)if(i in n&&n[i]===e)return i;return-1})},function(e,t){var i;_global.console=_global.console||((i={}).log=i.warn=i.debug=i.info=i.error=i.time=i.dir=i.profile=i.clear=i.exception=i.trace=i.assert=function(){},i)},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,i,n={__ob__:t,$accessors:t,$vbthis:t,$vbsetter:t},r=[];for(i in e)i in n||Object.prototype.hasOwnProperty.call(e,i)&&r.push(i);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){var o,i;i=window.navigator.userAgent.toLowerCase(),/msie/.test(i)&&(o=Array.prototype.sort,Array.prototype.sort=function(e){if(e&&"function"==typeof e){if(this.length<2)return this;for(var t,i,n=0,r=n+1,a=this.length;n<a;n++)for(r=n+1;r<a;r++)!0==0<("number"==typeof(i=e.call(this,this[n],this[r]))?i:i?1:0)&&(t=this[n],this[n]=this[r],this[r]=t);return this}return o.call(this)})},function(e,t){var i={}.toString;e.exports=function(e){return i.call(e).slice(8,-1)}},function(e,t,i){var n,r,a,o,s,l,u,c,h=i(1195),p=i(60),d=i(89),f=i(281),g=i(280),m=i(1136),I=i(1124),B=p.WeakMap;u=h?(n=new B,r=n.get,a=n.has,o=n.set,s=function(e,t){return o.call(n,e,t),t},l=function(e){return r.call(n,e)||{}},function(e){return a.call(n,e)}):(I[c=m("state")]=!0,s=function(e,t){return f(e,c,t),t},l=function(e){return g(e,c)?e[c]:{}},function(e){return g(e,c)}),e.exports={set:s,get:l,has:u,enforce:function(e){return u(e)?l(e):s(e,{})},getterFor:function(i){return function(e){var t;if(!d(e)||(t=l(e)).type!==i)throw TypeError("Incompatible receiver, "+i+" required");return t}}}},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(String(e)+" is not a function");return e}},,,,function(e,t,i){var n=i(1145),r=i(1135);e.exports=function(e){return n(r(e))}},function(e,t){e.exports=!1},function(e,t,i){var n=i(846),r=i(60),a=function(e){return"function"==typeof e?e:undefined};e.exports=function(e,t){return arguments.length<2?a(n[e])||a(r[e]):n[e]&&n[e][t]||r[e]&&r[e][t]}},function(e,t,i){var n=i(90),r=i(1202),a=i(1150),o=i(1124),s=i(1162),l=i(1147),u=i(1136)("IE_PROTO"),c="prototype",h=function(){},p=function(){var e,t=l("iframe"),i=a.length;for(t.style.display="none",s.appendChild(t),t.src=String("javascript:"),(e=t.contentWindow.document).open(),e.write("<script>document.F=Object<\/script>"),e.close(),p=e.F;i--;)delete p[c][a[i]];return p()};e.exports=Object.create||function(e,t){var i;return null!==e?(h[c]=n(e),i=new h,h[c]=null,i[u]=e):i=p(),t===undefined?i:r(i,t)},o[u]=!0},function(e,t,i){var n=i(1135);e.exports=function(e){return Object(n(e))}},function(e,t,i){var d=i(90),f=i(1236),g=i(1138),m=i(1126),I=i(1237),B=i(1238),E=function(e,t){this.stopped=e,this.result=t};(e.exports=function(e,t,i,n,r){var a,o,s,l,u,c,h,p=m(t,i,n?2:1);if(r)a=e;else{if("function"!=typeof(o=I(e)))throw TypeError("Target is not iterable");if(f(o)){for(s=0,l=g(e.length);s<l;s++)if((u=n?p(d(h=e[s])[0],h[1]):p(e[s]))&&u instanceof E)return u;return new E(!1)}a=o.call(e)}for(c=a.next;!(h=c.call(a)).done;)if("object"==typeof(u=B(a,p,h.value,n))&&u&&u instanceof E)return u;return new E(!1)}).stop=function(e){return new E(!0,e)}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t){},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t,i){var n=i(923),r=i(1194);(e.exports=function(e,t){return r[e]||(r[e]=t!==undefined?t:{})})("versions",[]).push({version:"3.3.2",mode:n?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},function(e,t){e.exports={}},function(e,t,i){var n=i(282).f,r=i(280),a=i(66)("toStringTag");e.exports=function(e,t,i){e&&!r(e=i?e:e.prototype,a)&&n(e,a,{configurable:!0,value:t})}},function(e,t,i){var a=i(918);e.exports=function(n,r,e){if(a(n),r===undefined)return n;switch(e){case 0:return function(){return n.call(r)};case 1:return function(e){return n.call(r,e)};case 2:return function(e,t){return n.call(r,e,t)};case 3:return function(e,t,i){return n.call(r,e,t,i)}}return function(){return n.apply(r,arguments)}}},function(e,t){e.exports={}},function(e,t,i){"use strict";var r=i(918),n=function(e){var i,n;this.promise=new e(function(e,t){if(i!==undefined||n!==undefined)throw TypeError("Bad Promise constructor");i=e,n=t}),this.resolve=r(i),this.reject=r(n)};e.exports.f=function(e){return new n(e)}},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){},function(e,t,i){var n=i(173),r=i(1144),a=i(1122),o=i(922),s=i(1146),l=i(280),u=i(1158),c=Object.getOwnPropertyDescriptor;t.f=n?c:function(e,t){if(e=o(e),t=s(t,!0),u)try{return c(e,t)}catch(i){}if(l(e,t))return a(!r.f.call(e,t),e[t])}},function(e,t){e.exports=function(e){if(e==undefined)throw TypeError("Can't call method on "+e);return e}},function(e,t,i){var n=i(1123),r=i(1137),a=n("keys");e.exports=function(e){return a[e]||(a[e]=r(e))}},function(e,t){var i=0,n=Math.random();e.exports=function(e){return"Symbol("+String(e===undefined?"":e)+")_"+(++i+n).toString(36)}},function(e,t,i){var n=i(1139),r=Math.min;e.exports=function(e){return 0<e?r(n(e),9007199254740991):0}},function(e,t){var i=Math.ceil,n=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(0<e?n:i)(e)}},function(e,t,i){var n=i(280),r=i(926),a=i(1136),o=i(1167),s=a("IE_PROTO"),l=Object.prototype;e.exports=o?Object.getPrototypeOf:function(e){return e=r(e),n(e,s)?e[s]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?l:null}},function(e,t,i){var n=i(60),r=i(1126),a=Function.call;e.exports=function(e,t,i){return r(a,n[e].prototype[t],i)}},function(e,t){e.exports=function(e){try{return{error:!1,value:e()}}catch(t){return{error:!0,value:t}}}},,function(e,t,i){"use strict";var n={}.propertyIsEnumerable,r=Object.getOwnPropertyDescriptor,a=r&&!n.call({1:2},1);t.f=a?function(e){var t=r(this,e);return!!t&&t.enumerable}:n},function(e,t,i){var n=i(88),r=i(916),a="".split;e.exports=n(function(){return!Object("z").propertyIsEnumerable(0)})?function(e){return"String"==r(e)?a.call(e,""):Object(e)}:Object},function(e,t,i){var r=i(89);e.exports=function(e,t){if(!r(e))return e;var i,n;if(t&&"function"==typeof(i=e.toString)&&!r(n=i.call(e)))return n;if("function"==typeof(i=e.valueOf)&&!r(n=i.call(e)))return n;if(!t&&"function"==typeof(i=e.toString)&&!r(n=i.call(e)))return n;throw TypeError("Can't convert object to primitive value")}},function(e,t,i){var n=i(60),r=i(89),a=n.document,o=r(a)&&r(a.createElement);e.exports=function(e){return o?a.createElement(e):{}}},function(e,t,i){var n=i(60),r=i(281);e.exports=function(e,t){try{r(n,e,t)}catch(i){n[e]=t}return t}},function(e,t,i){var n=i(1160),r=i(1150).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return n(e,r)}},function(e,t){e.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,i){var n=i(88),r=/#|\.prototype\./,a=function(e,t){var i=s[o(e)];return i==u||i!=l&&("function"==typeof t?n(t):!!t)},o=a.normalize=function(e){return String(e).replace(r,".").toLowerCase()},s=a.data={},l=a.NATIVE="N",u=a.POLYFILL="P";e.exports=a},function(e,t,i){var n=i(1160),r=i(1150);e.exports=Object.keys||function(e){return n(e,r)}},function(e,t,i){"use strict";var I=i(67),B=i(1230),E=i(1140),_=i(1155),b=i(1125),y=i(281),v=i(875),n=i(66),T=i(923),C=i(1127),r=i(1173),N=r.IteratorPrototype,V=r.BUGGY_SAFARI_ITERATORS,S=n("iterator"),x="values",w=function(){return this};e.exports=function(e,t,i,n,r,a,o){B(i,t,n);var s,l,u,c=function(e){if(e===r&&g)return g;if(!V&&e in d)return d[e];switch(e){case"keys":case x:case"entries":return function(){return new i(this,e)}}return function(){return new i(this)}},h=t+" Iterator",p=!1,d=e.prototype,f=d[S]||d["@@iterator"]||r&&d[r],g=!V&&f||c(r),m="Array"==t&&d.entries||f;if(m&&(s=E(m.call(new e)),N!==Object.prototype&&s.next&&(T||E(s)===N||(_?_(s,N):"function"!=typeof s[S]&&y(s,S,w)),b(s,h,!0,!0),T&&(C[h]=w))),r==x&&f&&f.name!==x&&(p=!0,g=function(){return f.call(this)}),T&&!o||d[S]===g||y(d,S,g),C[t]=g,r)if(l={values:c(x),keys:a?g:c("keys"),entries:c("entries")},o)for(u in l)!V&&!p&&u in d||v(d,u,l[u]);else I({target:t,proto:!0,forced:V||p},l);return l}},function(e,t,i){var r=i(90),a=i(1231);e.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var i,n=!1,e={};try{(i=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set).call(e,[]),n=e instanceof Array}catch(t){}return function(e,t){return r(e),a(t),n?i.call(e,t):e.__proto__=t,e}}():undefined)},function(e,t){e.exports=function(e,t,i){if(!(e instanceof t))throw TypeError("Incorrect "+(i?i+" ":"")+"invocation");return e}},function(e,t,i){var n=i(924);e.exports=n("navigator","userAgent")||""},function(e,t,i){var n=i(173),r=i(88),a=i(1147);e.exports=!n&&!r(function(){return 7!=Object.defineProperty(a("div"),"a",{get:function(){return 7}}).a})},function(e,t,i){var n=i(1123);e.exports=n("native-function-to-string",Function.toString)},function(e,t,i){var o=i(280),s=i(922),l=i(1161).indexOf,u=i(1124);e.exports=function(e,t){var i,n=s(e),r=0,a=[];for(i in n)!o(u,i)&&o(n,i)&&a.push(i);for(;t.length>r;)o(n,i=t[r++])&&(~l(a,i)||a.push(i));return a}},function(e,t,i){var l=i(922),u=i(1138),c=i(1198),n=function(s){return function(e,t,i){var n,r=l(e),a=u(r.length),o=c(i,a);if(s&&t!=t){for(;o<a;)if((n=r[o++])!=n)return!0}else for(;o<a;o++)if((s||o in r)&&r[o]===t)return s||o||0;return!s&&-1}};e.exports={includes:n(!0),indexOf:n(!1)}},function(e,t,i){var n=i(924);e.exports=n("document","documentElement")},function(e,t,i){var n=i(88);e.exports=!!Object.getOwnPropertySymbols&&!n(function(){return!String(Symbol())})},function(e,t,i){var n=i(916);e.exports=Array.isArray||function(e){return"Array"==n(e)}},function(e,t,i){t.f=i(66)},function(e,t,i){var _=i(1126),b=i(1145),y=i(926),v=i(1138),T=i(1212),C=[].push,n=function(d){var f=1==d,g=2==d,m=3==d,I=4==d,B=6==d,E=5==d||B;return function(e,t,i,n){for(var r,a,o=y(e),s=b(o),l=_(t,i,3),u=v(s.length),c=0,h=n||T,p=f?h(e,u):g?h(e,0):undefined;c<u;c++)if((E||c in s)&&(a=l(r=s[c],c,o),d))if(f)p[c]=a;else if(a)switch(d){case 3:return!0;case 5:return r;case 6:return c;case 2:C.call(p,r)}else if(I)return!1;return B?-1:m||I?I:p}};e.exports={forEach:n(0),map:n(1),filter:n(2),some:n(3),every:n(4),find:n(5),findIndex:n(6)}},function(e,t,i){var n=i(88);e.exports=!n(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype})},function(e,t,i){"use strict";var n=i(88);e.exports=function(e,t){var i=[][e];return!i||!n(function(){i.call(null,t||function(){throw 1},1)})}},function(e,t,i){var n=i(875),r=i(1229),a=Object.prototype;r!==a.toString&&n(a,"toString",r,{unsafe:!0})},function(e,t,i){var r=i(916),a=i(66)("toStringTag"),o="Arguments"==r(function(){return arguments}());e.exports=function(e){var t,i,n;return e===undefined?"Undefined":null===e?"Null":"string"==typeof(i=function(e,t){try{return e[t]}catch(i){}}(t=Object(e),a))?i:o?r(t):"Object"==(n=r(t))&&"function"==typeof t.callee?"Arguments":n}},function(e,t,i){"use strict";var r=i(1172).charAt,n=i(917),a=i(1154),o="String Iterator",s=n.set,l=n.getterFor(o);a(String,"String",function(e){s(this,{type:o,string:String(e),index:0})},function(){var e,t=l(this),i=t.string,n=t.index;return n>=i.length?{value:undefined,done:!0}:(e=r(i,n),t.index+=e.length,{value:e,done:!1})})},function(e,t,i){var l=i(1139),u=i(1135),n=function(s){return function(e,t){var i,n,r=String(u(e)),a=l(t),o=r.length;return a<0||o<=a?s?"":undefined:(i=r.charCodeAt(a))<55296||56319<i||a+1===o||(n=r.charCodeAt(a+1))<56320||57343<n?s?r.charAt(a):i:s?r.slice(a,a+2):n-56320+(i-55296<<10)+65536}};e.exports={codeAt:n(!1),charAt:n(!0)}},function(e,t,i){"use strict";var n,r,a,o=i(1140),s=i(281),l=i(280),u=i(66),c=i(923),h=u("iterator"),p=!1;[].keys&&("next"in(a=[].keys())?(r=o(o(a)))!==Object.prototype&&(n=r):p=!0),n==undefined&&(n={}),c||l(n,h)||s(n,h,function(){return this}),e.exports={IteratorPrototype:n,BUGGY_SAFARI_ITERATORS:p}},function(e,t,i){var n=i(60),r=i(1232),a=i(1233),o=i(281),s=i(66),l=s("iterator"),u=s("toStringTag"),c=a.values;for(var h in r){var p=n[h],d=p&&p.prototype;if(d){if(d[l]!==c)try{o(d,l,c)}catch(g){d[l]=c}if(d[u]||o(d,u,h),r[h])for(var f in a)if(d[f]!==a[f])try{o(d,f,a[f])}catch(g){d[f]=a[f]}}}},function(e,t,i){var n=i(60);e.exports=n.Promise},function(e,t,i){var r=i(875);e.exports=function(e,t,i){for(var n in t)r(e,n,t[n],i);return e}},function(e,t,i){"use strict";var n=i(924),r=i(282),a=i(66),o=i(173),s=a("species");e.exports=function(e){var t=n(e),i=r.f;o&&t&&!t[s]&&i(t,s,{configurable:!0,get:function(){return this}})}},function(e,t,i){var r=i(66)("iterator"),a=!1;try{var n=0,o={next:function(){return{done:!!n++}},"return":function(){a=!0}};o[r]=function(){return this},Array.from(o,function(){throw 2})}catch(s){}e.exports=function(e,t){if(!t&&!a)return!1;var i=!1;try{var n={};n[r]=function(){return{next:function(){return{done:i=!0}}}},e(n)}catch(s){}return i}},function(e,t,i){var r=i(90),a=i(918),o=i(66)("species");e.exports=function(e,t){var i,n=r(e).constructor;return n===undefined||(i=r(n)[o])==undefined?t:a(i)}},function(e,t,i){var n,r,a,o=i(60),s=i(88),l=i(916),u=i(1126),c=i(1162),h=i(1147),p=i(1157),d=o.location,f=o.setImmediate,g=o.clearImmediate,m=o.process,I=o.MessageChannel,B=o.Dispatch,E=0,_={},b="onreadystatechange",y=function(e){var t;_.hasOwnProperty(e)&&(t=_[e],delete _[e],t())},v=function(e){return function(){y(e)}},T=function(e){y(e.data)},C=function(e){o.postMessage(e+"",d.protocol+"//"+d.host)};f&&g||(f=function(e){for(var t=[],i=1;i<arguments.length;)t.push(arguments[i++]);return _[++E]=function(){("function"==typeof e?e:Function(e)).apply(undefined,t)},n(E),E},g=function(e){delete _[e]},"process"==l(m)?n=function(e){m.nextTick(v(e))}:B&&B.now?n=function(e){B.now(v(e))}:I&&!/(iphone|ipod|ipad).*applewebkit/i.test(p)?(a=(r=new I).port2,r.port1.onmessage=T,n=u(a.postMessage,a,1)):!o.addEventListener||"function"!=typeof postMessage||o.importScripts||s(C)?n=b in h("script")?function(e){c.appendChild(h("script"))[b]=function(){c.removeChild(this),y(e)}}:function(e){setTimeout(v(e),0)}:(n=C,o.addEventListener("message",T,!1))),e.exports={set:f,clear:g}},function(e,t,i){var n=i(90),r=i(89),a=i(1128);e.exports=function(e,t){if(n(e),r(t)&&t.constructor===e)return t;var i=a.f(e);return(0,i.resolve)(t),i.promise}},function(e,t,i){"use strict";var n=i(67),u=i(918),r=i(1128),a=i(1142),c=i(927);n({target:"Promise",stat:!0},{allSettled:function(e){var s=this,t=r.f(s),l=t.resolve,i=t.reject,n=a(function(){var n=u(s.resolve),r=[],a=0,o=1;c(e,function(e){var t=a++,i=!1;r.push(undefined),o++,n.call(s,e).then(function(e){i||(i=!0,r[t]={status:"fulfilled",value:e},--o||l(r))},function(e){i||(i=!0,r[t]={status:"rejected",reason:e},--o||l(r))})}),--o||l(r)});return n.error&&i(n.value),t.promise}})},function(e,t,i){"use strict";var n,r,a=i(1250),o=RegExp.prototype.exec,s=String.prototype.replace,l=o,u=(n=/a/,r=/b*/g,o.call(n,"a"),o.call(r,"a"),0!==n.lastIndex||0!==r.lastIndex),c=/()??/.exec("")[1]!==undefined;(u||c)&&(l=function(e){var t,i,n,r;return c&&(i=new RegExp("^"+this.source+"$(?!\\s)",a.call(this))),u&&(t=this.lastIndex),n=o.call(this,e),u&&n&&(this.lastIndex=this.global?n.index+n[0].length:t),c&&n&&1<n.length&&s.call(n[0],i,function(){for(r=1;r<arguments.length-2;r++)arguments[r]===undefined&&(n[r]=undefined)}),n}),e.exports=l},function(e,t,i){var n=i(1124),r=i(89),a=i(280),o=i(282).f,s=i(1137),l=i(1256),u=s("meta"),c=0,h=Object.isExtensible||function(){return!0},p=function(e){o(e,u,{value:{objectID:"O"+ ++c,weakData:{}}})},d=e.exports={REQUIRED:!1,fastKey:function(e,t){if(!r(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!a(e,u)){if(!h(e))return"F";if(!t)return"E";p(e)}return e[u].objectID},getWeakData:function(e,t){if(!a(e,u)){if(!h(e))return!0;if(!t)return!1;p(e)}return e[u].weakData},onFreeze:function(e){return l&&d.REQUIRED&&h(e)&&!a(e,u)&&p(e),e}};n[u]=!0},function(e,t){e.exports=_},,,,,,function(e,t,i){e.exports=i(1192)},function(e,t,i){i(1193);var n=i(846).Object,r=e.exports=function r(e,t,i){return n.defineProperty(e,t,i)};n.defineProperty.sham&&(r.sham=!0)},function(e,t,i){var n=i(67),r=i(173);n({target:"Object",stat:!0,forced:!r,sham:!r},{defineProperty:i(282).f})},function(e,t,i){var n=i(60),r=i(1148),a="__core-js_shared__",o=n[a]||r(a,{});e.exports=o},function(e,t,i){var n=i(60),r=i(1159),a=n.WeakMap;e.exports="function"==typeof a&&/native code/.test(r.call(a))},function(e,t,i){var s=i(280),l=i(1197),u=i(1134),c=i(282);e.exports=function(e,t){for(var i=l(t),n=c.f,r=u.f,a=0;a<i.length;a++){var o=i[a];s(e,o)||n(e,o,r(t,o))}}},function(e,t,i){var n=i(924),r=i(1149),a=i(1151),o=i(90);e.exports=n("Reflect","ownKeys")||function(e){var t=r.f(o(e)),i=a.f;return i?t.concat(i(e)):t}},function(e,t,i){var n=i(1139),r=Math.max,a=Math.min;e.exports=function(e,t){var i=n(e);return i<0?r(i+t,0):a(i,t)}},function(e,t,i){e.exports=i(1200)},function(e,t,i){i(1201);var n=i(846).Object;e.exports=function(e,t){return n.create(e,t)}},function(e,t,i){i(67)({target:"Object",stat:!0,sham:!i(173)},{create:i(925)})},function(e,t,i){var n=i(173),o=i(282),s=i(90),l=i(1153);e.exports=n?Object.defineProperties:function(e,t){s(e);for(var i,n=l(t),r=n.length,a=0;a<r;)o.f(e,i=n[a++],t[i]);return e}},function(e,t,i){e.exports=i(1204)},function(e,t,i){i(1205);var n=i(846);e.exports=n.Object.assign},function(e,t,i){var n=i(67),r=i(1206);n({target:"Object",stat:!0,forced:Object.assign!==r},{assign:r})},function(e,t,i){"use strict";var p=i(173),n=i(88),d=i(1153),f=i(1151),g=i(1144),m=i(926),I=i(1145),r=Object.assign;e.exports=!r||n(function(){var e={},t={},i=Symbol(),n="abcdefghijklmnopqrst";return e[i]=7,n.split("").forEach(function(e){t[e]=e}),7!=r({},e)[i]||d(r({},t)).join("")!=n})?function(e,t){for(var i=m(e),n=arguments.length,r=1,a=f.f,o=g.f;r<n;)for(var s,l=I(arguments[r++]),u=a?d(l).concat(a(l)):d(l),c=u.length,h=0;h<c;)s=u[h++],p&&!o.call(l,s)||(i[s]=l[s]);return i}:r},function(e,t,i){e.exports=i(1208)},function(e,t,i){i(1209);var n=i(846);e.exports=n.Object.getOwnPropertySymbols},function(e,t,i){"use strict";var n=i(67),r=i(60),a=i(923),o=i(173),s=i(1163),l=i(88),u=i(280),c=i(1164),h=i(89),p=i(90),d=i(926),f=i(922),g=i(1146),m=i(1122),I=i(925),B=i(1153),E=i(1149),_=i(1210),b=i(1151),y=i(1134),v=i(282),T=i(1144),C=i(281),N=i(875),V=i(1123),S=i(1136),x=i(1124),w=i(1137),A=i(66),L=i(1165),k=i(1211),D=i(1125),P=i(917),M=i(1166).forEach,R=S("hidden"),H="Symbol",O="prototype",F=A("toPrimitive"),Y=P.set,W=P.getterFor(H),G=Object[O],j=r.Symbol,Z=r.JSON,X=Z&&Z.stringify,U=y.f,J=v.f,K=_.f,z=T.f,Q=V("symbols"),q=V("op-symbols"),$=V("string-to-symbol-registry"),ee=V("symbol-to-string-registry"),te=V("wks"),ie=r.QObject,ne=!ie||!ie[O]||!ie[O].findChild,re=o&&l(function(){return 7!=I(J({},"a",{get:function(){return J(this,"a",{value:7}).a}})).a})?function(e,t,i){var n=U(G,t);n&&delete G[t],J(e,t,i),n&&e!==G&&J(G,t,n)}:J,ae=function(e,t){var i=Q[e]=I(j[O]);return Y(i,{type:H,tag:e,description:t}),o||(i.description=t),i},oe=s&&"symbol"==typeof j.iterator?function(e){return"symbol"==typeof e}:function(e){return Object(e)instanceof j},se=function(e,t,i){e===G&&se(q,t,i),p(e);var n=g(t,!0);return p(i),u(Q,n)?(i.enumerable?(u(e,R)&&e[R][n]&&(e[R][n]=!1),i=I(i,{enumerable:m(0,!1)})):(u(e,R)||J(e,R,m(1,{})),e[R][n]=!0),re(e,n,i)):J(e,n,i)},le=function(t,e){p(t);var i=f(e),n=B(i).concat(pe(i));return M(n,function(e){o&&!ue.call(i,e)||se(t,e,i[e])}),t},ue=function(e){var t=g(e,!0),i=z.call(this,t);return!(this===G&&u(Q,t)&&!u(q,t))&&(!(i||!u(this,t)||!u(Q,t)||u(this,R)&&this[R][t])||i)},ce=function(e,t){var i=f(e),n=g(t,!0);if(i!==G||!u(Q,n)||u(q,n)){var r=U(i,n);return!r||!u(Q,n)||u(i,R)&&i[R][n]||(r.enumerable=!0),r}},he=function(e){var t=K(f(e)),i=[];return M(t,function(e){u(Q,e)||u(x,e)||i.push(e)}),i},pe=function(e){var t=e===G,i=K(t?q:f(e)),n=[];return M(i,function(e){!u(Q,e)||t&&!u(G,e)||n.push(Q[e])}),n};s||(N((j=function Symbol(){if(this instanceof j)throw TypeError("Symbol is not a constructor");var t=arguments.length&&arguments[0]!==undefined?String(arguments[0]):undefined,i=w(t),n=function(e){this===G&&n.call(q,e),u(this,R)&&u(this[R],i)&&(this[R][i]=!1),re(this,i,m(1,e))};return o&&ne&&re(G,i,{configurable:!0,set:n}),ae(i,t)})[O],"toString",function(){return W(this).tag}),T.f=ue,v.f=se,y.f=ce,E.f=_.f=he,b.f=pe,o&&(J(j[O],"description",{configurable:!0,get:function(){return W(this).description}}),a||N(G,"propertyIsEnumerable",ue,{unsafe:!0})),L.f=function(e){return ae(A(e),e)}),n({global:!0,wrap:!0,forced:!s,sham:!s},{Symbol:j}),M(B(te),function(e){k(e)}),n({target:H,stat:!0,forced:!s},{"for":function(e){var t=String(e);if(u($,t))return $[t];var i=j(t);return $[t]=i,ee[i]=t,i},keyFor:function(e){if(!oe(e))throw TypeError(e+" is not a symbol");if(u(ee,e))return ee[e]},useSetter:function(){ne=!0},useSimple:function(){ne=!1}}),n({target:"Object",stat:!0,forced:!s,sham:!o},{create:function(e,t){return t===undefined?I(e):le(I(e),t)},defineProperty:se,defineProperties:le,getOwnPropertyDescriptor:ce}),n({target:"Object",stat:!0,forced:!s},{getOwnPropertyNames:he,getOwnPropertySymbols:pe}),n({target:"Object",stat:!0,forced:l(function(){b.f(1)})},{getOwnPropertySymbols:function(e){return b.f(d(e))}}),Z&&n({target:"JSON",stat:!0,forced:!s||l(function(){var e=j();return"[null]"!=X([e])||"{}"!=X({a:e})||"{}"!=X(Object(e))})},{stringify:function(e){for(var t,i,n=[e],r=1;r<arguments.length;)n.push(arguments[r++]);if(i=t=n[1],(h(t)||e!==undefined)&&!oe(e))return c(t)||(t=function(e,t){if("function"==typeof i&&(t=i.call(this,e,t)),!oe(t))return t}),n[1]=t,X.apply(Z,n)}}),j[O][F]||C(j[O],F,j[O].valueOf),D(j,H),x[R]=!0},function(e,t,i){var n=i(922),r=i(1149).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(n(e))}},function(e,t,i){var n=i(846),r=i(280),a=i(1165),o=i(282).f;e.exports=function(e){var t=n.Symbol||(n.Symbol={});r(t,e)||o(t,e,{value:a.f(e)})}},function(e,t,i){var n=i(89),r=i(1164),a=i(66)("species");e.exports=function(e,t){var i;return r(e)&&("function"==typeof(i=e.constructor)&&(i===Array||r(i.prototype))||n(i)&&null===(i=i[a]))&&(i=undefined),new(i===undefined?Array:i)(0===t?0:t)}},function(e,t,i){e.exports=i(1214)},function(e,t,i){i(1215);var n=i(846);e.exports=n.Object.getPrototypeOf},function(e,t,i){var n=i(67),r=i(88),a=i(926),o=i(1140),s=i(1167);n({target:"Object",stat:!0,forced:r(function(){o(1)}),sham:!s},{getPrototypeOf:function(e){return o(a(e))}})},function(e,t,i){e.exports=i(1217)},function(e,t,i){i(1218);var n=i(1141);e.exports=n("Array","forEach")},function(e,t,i){"use strict";var n=i(67),r=i(1219);n({target:"Array",proto:!0,forced:[].forEach!=r},{forEach:r})},function(e,t,i){"use strict";var n=i(1166).forEach,r=i(1168);e.exports=r("forEach")?function(e){return n(this,e,1<arguments.length?arguments[1]:undefined)}:[].forEach},function(e,t,i){e.exports=i(1221)},function(e,t,i){i(1222);var n=i(1141);e.exports=n("Array","indexOf")},function(e,t,i){"use strict";var n=i(67),r=i(1161).indexOf,a=i(1168),o=[].indexOf,s=!!o&&1/[1].indexOf(1,-0)<0,l=a("indexOf");n({target:"Array",proto:!0,forced:s||l},{indexOf:function(e){return s?o.apply(this,arguments)||0:r(this,e,1<arguments.length?arguments[1]:undefined)}})},function(e,t,i){e.exports=i(1224)},function(e,t,i){i(1225);var n=i(1141);e.exports=n("Function","bind")},function(e,t,i){i(67)({target:"Function",proto:!0},{bind:i(1226)})},function(e,t,i){"use strict";var a=i(918),o=i(89),s=[].slice,l={};e.exports=Function.bind||function(t){var i=a(this),n=s.call(arguments,1),r=function(){var e=n.concat(s.call(arguments));return this instanceof r?function(e,t,i){if(!(t in l)){for(var n=[],r=0;r<t;r++)n[r]="a["+r+"]";l[t]=Function("C,a","return new C("+n.join(",")+")")}return l[t](e,i)}(i,e.length,e):i.apply(t,e)};return o(i.prototype)&&(r.prototype=i.prototype),r}},function(e,t,i){e.exports=i(1228),i(1242),i(1243),i(1244),i(1245)},function(e,t,i){i(1169),i(1171),i(1174),i(1235),i(1182),i(1241);var n=i(846);e.exports=n.Promise},function(e,t,i){"use strict";var n=i(1170),r={};r[i(66)("toStringTag")]="z",e.exports="[object z]"!==String(r)?function(){return"[object "+n(this)+"]"}:r.toString},function(e,t,i){"use strict";var r=i(1173).IteratorPrototype,a=i(925),o=i(1122),s=i(1125),l=i(1127),u=function(){return this};e.exports=function(e,t,i){var n=t+" Iterator";return e.prototype=a(r,{next:o(1,i)}),s(e,n,!1,!0),l[n]=u,e}},function(e,t,i){var n=i(89);e.exports=function(e){if(!n(e)&&null!==e)throw TypeError("Can't set "+String(e)+" as a prototype");return e}},function(e,t){e.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},function(e,t,i){"use strict";var n=i(922),r=i(1234),a=i(1127),o=i(917),s=i(1154),l="Array Iterator",u=o.set,c=o.getterFor(l);e.exports=s(Array,"Array",function(e,t){u(this,{type:l,target:n(e),index:0,kind:t})},function(){var e=c(this),t=e.target,i=e.kind,n=e.index++;return!t||n>=t.length?(e.target=undefined,{value:undefined,done:!0}):"keys"==i?{value:n,done:!1}:"values"==i?{value:t[n],done:!1}:{value:[n,t[n]],done:!1}},"values"),a.Arguments=a.Array,r("keys"),r("values"),r("entries")},function(e,t,i){var n=i(66),r=i(925),a=i(281),o=n("unscopables"),s=Array.prototype;s[o]==undefined&&a(s,o,r(null)),e.exports=function(e){s[o][e]=!0}},function(e,t,i){"use strict";var r,n,a,o,s=i(67),l=i(923),u=i(60),c=i(846),h=i(1175),p=i(875),d=i(1176),f=i(1125),g=i(1177),m=i(89),I=i(918),B=i(1156),E=i(916),_=i(927),b=i(1178),y=i(1179),v=i(1180).set,T=i(1239),C=i(1181),N=i(1240),V=i(1128),S=i(1142),x=i(1157),w=i(917),A=i(1152),L=i(66)("species"),k="Promise",D=w.get,P=w.set,M=w.getterFor(k),R=h,H=u.TypeError,O=u.document,F=u.process,Y=u.fetch,W=F&&F.versions,G=W&&W.v8||"",j=V.f,Z=j,X="process"==E(F),U=!!(O&&O.createEvent&&u.dispatchEvent),J="unhandledrejection",K=A(k,function(){var e=R.resolve(1),t=function(){},i=(e.constructor={})[L]=function(e){e(t,t)};return!((X||"function"==typeof PromiseRejectionEvent)&&(!l||e["finally"])&&e.then(t)instanceof i&&0!==G.indexOf("6.6")&&-1===x.indexOf("Chrome/66"))}),z=K||!b(function(e){R.all(e)["catch"](function(){})}),Q=function(e){var t;return!(!m(e)||"function"!=typeof(t=e.then))&&t},q=function(p,d,f){var g;d.notified||(d.notified=!0,g=d.reactions,T(function(){for(var e=d.value,t=1==d.state,i=0;g.length>i;){var n,r,a,o=g[i++],s=t?o.ok:o.fail,l=o.resolve,u=o.reject,c=o.domain;try{s?(t||(2===d.rejection&&ie(p,d),d.rejection=1),!0===s?n=e:(c&&c.enter(),n=s(e),c&&(c.exit(),a=!0)),n===o.promise?u(H("Promise-chain cycle")):(r=Q(n))?r.call(n,l,u):l(n)):u(e)}catch(h){c&&!a&&c.exit(),u(h)}}d.reactions=[],d.notified=!1,f&&!d.rejection&&ee(p,d)}))},$=function(e,t,i){var n,r;U?((n=O.createEvent("Event")).promise=t,n.reason=i,n.initEvent(e,!1,!0),u.dispatchEvent(n)):n={promise:t,reason:i},(r=u["on"+e])?r(n):e===J&&N("Unhandled promise rejection",i)},ee=function(i,n){v.call(u,function(){var e,t=n.value;if(te(n)&&(e=S(function(){X?F.emit("unhandledRejection",t,i):$(J,i,t)}),n.rejection=X||te(n)?2:1,e.error))throw e.value})},te=function(e){return 1!==e.rejection&&!e.parent},ie=function(e,t){v.call(u,function(){X?F.emit("rejectionHandled",e):$("rejectionhandled",e,t.value)})},ne=function(t,i,n,r){return function(e){t(i,n,e,r)}},re=function(e,t,i,n){t.done||(t.done=!0,n&&(t=n),t.value=i,t.state=2,q(e,t,!0))},ae=function(i,n,r,e){if(!n.done){n.done=!0,e&&(n=e);try{if(i===r)throw H("Promise can't be resolved itself");var a=Q(r);a?T(function(){var e={done:!1};try{a.call(r,ne(ae,i,e,n),ne(re,i,e,n))}catch(t){re(i,e,t,n)}}):(n.value=r,n.state=1,q(i,n,!1))}catch(t){re(i,{done:!1},t,n)}}};K&&(R=function Promise(t){B(this,R,k),I(t),r.call(this);var i=D(this);try{t(ne(ae,this,i),ne(re,this,i))}catch(n){re(this,i,n)}},(r=function Promise(t){P(this,{type:k,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:undefined})}).prototype=d(R.prototype,{then:function(e,t){var i=M(this),n=j(y(this,R));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=X?F.domain:undefined,i.parent=!0,i.reactions.push(n),0!=i.state&&q(this,i,!1),n.promise},"catch":function(e){return this.then(undefined,e)}}),n=function(){var e=new r,t=D(e);this.promise=e,this.resolve=ne(ae,e,t),this.reject=ne(re,e,t)},V.f=j=function(e){return e===R||e===a?new n:Z(e)},l||"function"!=typeof h||(o=h.prototype.then,p(h.prototype,"then",function(e,t){var i=this;return new R(function(e,t){o.call(i,e,t)}).then(e,t)},{unsafe:!0}),"function"==typeof Y&&s({global:!0,enumerable:!0,forced:!0},{fetch:function(e){return C(R,Y.apply(u,arguments))}}))),s({global:!0,wrap:!0,forced:K},{Promise:R}),f(R,k,!1,!0),g(k),a=c[k],s({target:k,stat:!0,forced:K},{reject:function(e){var t=j(this);return t.reject.call(undefined,e),t.promise}}),s({target:k,stat:!0,forced:l||K},{resolve:function(e){return C(l&&this===a?R:this,e)}}),s({target:k,stat:!0,forced:z},{all:function(e){var s=this,t=j(s),l=t.resolve,u=t.reject,i=S(function(){var n=I(s.resolve),r=[],a=0,o=1;_(e,function(e){var t=a++,i=!1;r.push(undefined),o++,n.call(s,e).then(function(e){i||(i=!0,r[t]=e,--o||l(r))},u)}),--o||l(r)});return i.error&&u(i.value),t.promise},race:function(e){var i=this,n=j(i),r=n.reject,t=S(function(){var t=I(i.resolve);_(e,function(e){t.call(i,e).then(n.resolve,r)})});return t.error&&r(t.value),n.promise}})},function(e,t,i){var n=i(66),r=i(1127),a=n("iterator"),o=Array.prototype;e.exports=function(e){return e!==undefined&&(r.Array===e||o[a]===e)}},function(e,t,i){var n=i(1170),r=i(1127),a=i(66)("iterator");e.exports=function(e){if(e!=undefined)return e[a]||e["@@iterator"]||r[n(e)]}},function(e,t,i){var o=i(90);e.exports=function(e,t,i,n){try{return n?t(o(i)[0],i[1]):t(i)}catch(a){var r=e["return"];throw r!==undefined&&o(r.call(e)),a}}},function(e,t,i){var n,r,a,o,s,l,u,c,h=i(60),p=i(1134).f,d=i(916),f=i(1180).set,g=i(1157),m=h.MutationObserver||h.WebKitMutationObserver,I=h.process,B=h.Promise,E="process"==d(I),_=p(h,"queueMicrotask"),b=_&&_.value;b||(n=function(){var e,t;for(E&&(e=I.domain)&&e.exit();r;){t=r.fn,r=r.next;try{t()}catch(i){throw r?o():a=undefined,i}}a=undefined,e&&e.enter()},o=E?function(){I.nextTick(n)}:m&&!/(iphone|ipod|ipad).*applewebkit/i.test(g)?(s=!0,l=document.createTextNode(""),new m(n).observe(l,{characterData:!0}),function(){l.data=s=!s}):B&&B.resolve?(u=B.resolve(undefined),c=u.then,function(){c.call(u,n)}):function(){f.call(h,n)}),e.exports=b||function(e){var t={fn:e,next:undefined};a&&(a.next=t),r||(r=t,o()),a=t}},function(e,t,i){var n=i(60);e.exports=function(e,t){var i=n.console;i&&i.error&&(1===arguments.length?i.error(e):i.error(e,t))}},function(e,t,i){"use strict";var n=i(67),r=i(923),a=i(1175),o=i(924),s=i(1179),l=i(1181),u=i(875);n({target:"Promise",proto:!0,real:!0},{"finally":function(t){var i=s(this,o("Promise")),e="function"==typeof t;return this.then(e?function(e){return l(i,t()).then(function(){return e})}:t,e?function(e){return l(i,t()).then(function(){throw e})}:t)}}),r||"function"!=typeof a||a.prototype["finally"]||u(a.prototype,"finally",o("Promise").prototype["finally"])},function(e,t,i){"use strict";var n=i(67),r=i(173),a=i(1140),o=i(1155),s=i(925),l=i(282),u=i(1122),c=i(927),h=i(281),p=i(90),d=i(917),f=d.set,g=d.getterFor("AggregateError"),m=function(e,t){var i=this;if(!(i instanceof m))return new m(e,t);o&&(i=o(new Error(t),a(i)));var n=[];return c(e,n.push,n),r?f(i,{errors:n,type:"AggregateError"}):i.errors=n,t!==undefined&&h(i,"message",String(t)),i};m.prototype=s(Error.prototype,{constructor:u(5,m),message:u(5,""),name:u(5,"AggregateError"),toString:u(5,function(){var e=(e=p(this).name)===undefined?"AggregateError":String(e),t=this.message;return e+": "+(t=t===undefined?"":String(t))})}),r&&l.f(m.prototype,"errors",{get:function(){return g(this).errors},configurable:!0}),n({global:!0},{AggregateError:m})},function(e,t,i){i(1182)},function(e,t,i){"use strict";var n=i(67),r=i(1128),a=i(1142);n({target:"Promise",stat:!0},{"try":function(e){var t=r.f(this),i=a(e);return(i.error?t.reject:t.resolve)(i.value),t.promise}})},function(e,t,i){"use strict";var n=i(67),h=i(918),p=i(924),r=i(1128),a=i(1142),d=i(927),f="No one promise resolved";n({target:"Promise",stat:!0},{any:function(e){var l=this,t=r.f(l),u=t.resolve,c=t.reject,i=a(function(){var n=h(l.resolve),r=[],a=0,o=1,s=!1;d(e,function(e){var t=a++,i=!1;r.push(undefined),o++,n.call(l,e).then(function(e){i||s||(s=!0,u(e))},function(e){i||s||(i=!0,r[t]=e,--o||c(new(p("AggregateError"))(r,f)))})}),--o||c(new(p("AggregateError"))(r,f))});return i.error&&c(i.value),t.promise}})},function(e,t,i){e.exports=i(1247)},function(e,t,i){i(1248);var n=i(1141);e.exports=n("String","replace")},function(e,t,i){"use strict";var n=i(1249),v=i(90),T=i(926),C=i(1138),N=i(1139),a=i(1135),V=i(1251),S=i(1252),x=Math.max,w=Math.min,A=Math.floor,L=/\$([$&'`]|\d\d?|<[^>]*>)/g,k=/\$([$&'`]|\d\d?)/g;n("replace",2,function(r,b,y){return[function(e,t){var i=a(this),n=e==undefined?undefined:e[r];return n!==undefined?n.call(e,i,t):b.call(String(i),e,t)},function(e,t){var i=y(b,e,this,t);if(i.done)return i.value;var n=v(e),r=String(this),a="function"==typeof t;a||(t=String(t));var o,s=n.global;s&&(o=n.unicode,n.lastIndex=0);for(var l=[];;){var u=S(n,r);if(null===u)break;if(l.push(u),!s)break;""===String(u[0])&&(n.lastIndex=V(r,C(n.lastIndex),o))}for(var c,h="",p=0,d=0;d<l.length;d++){u=l[d];for(var f=String(u[0]),g=x(w(N(u.index),r.length),0),m=[],I=1;I<u.length;I++)m.push((c=u[I])===undefined?c:String(c));var B,E=u.groups,_=a?(B=[f].concat(m,g,r),E!==undefined&&B.push(E),String(t.apply(undefined,B))):function(a,o,s,l,u,e){var c=s+a.length,h=l.length,t=k;u!==undefined&&(u=T(u),t=L);return b.call(e,t,function(e,t){var i;switch(t.charAt(0)){case"$":return"$";case"&":return a;case"`":return o.slice(0,s);case"'":return o.slice(c);case"<":i=u[t.slice(1,-1)];break;default:var n=+t;if(0==n)return e;if(h<n){var r=A(n/10);return 0===r?e:r<=h?l[r-1]===undefined?t.charAt(1):l[r-1]+t.charAt(1):e}i=l[n-1]}return i===undefined?"":i})}(f,r,g,m,E,t);p<=g&&(h+=r.slice(p,g)+_,p=g+f.length)}return h+r.slice(p)}]})},function(e,t,i){"use strict";var h=i(281),p=i(875),d=i(88),f=i(66),g=i(1183),m=f("species"),I=!d(function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$<a>")}),B=!d(function(){var e=/(?:)/,t=e.exec;e.exec=function(){return t.apply(this,arguments)};var i="ab".split(e);return 2!==i.length||"a"!==i[0]||"b"!==i[1]});e.exports=function(i,e,t,n){var a,r,o,s,l=f(i),u=!d(function(){var e={};return e[l]=function(){return 7},7!=""[i](e)}),c=u&&!d(function(){var e=!1,t=/a/;return t.exec=function(){return e=!0,null},"split"===i&&(t.constructor={},t.constructor[m]=function(){return t}),t[l](""),!e});u&&c&&("replace"!==i||I)&&("split"!==i||B)||(a=/./[l],o=(r=t(l,""[i],function(e,t,i,n,r){return t.exec===g?u&&!r?{done:!0,value:a.call(t,i,n)}:{done:!0,value:e.call(i,t,n)}:{done:!1}}))[0],s=r[1],p(String.prototype,i,o),p(RegExp.prototype,l,2==e?function(e,t){return s.call(e,this,t)}:function(e){return s.call(e,this)}),n&&h(RegExp.prototype[l],"sham",!0))}},function(e,t,i){"use strict";var n=i(90);e.exports=function(){var e=n(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.dotAll&&(t+="s"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},function(e,t,i){"use strict";var n=i(1172).charAt;e.exports=function(e,t,i){return t+(i?n(e,t).length:1)}},function(e,t,i){var r=i(916),a=i(1183);e.exports=function(e,t){var i=e.exec;if("function"==typeof i){var n=i.call(e,t);if("object"!=typeof n)throw TypeError("RegExp exec method returned something other than an Object or null");return n}if("RegExp"!==r(e))throw TypeError("RegExp#exec called on incompatible receiver");return a.call(e,t)}},function(e,t,i){i(1254),i(1169),i(1171),i(1174);var n=i(846);e.exports=n.Map},function(e,t,i){"use strict";var n=i(1255),r=i(1258);e.exports=n("Map",function(e){return function(){return e(this,arguments.length?arguments[0]:undefined)}},r,!0)},function(e,t,i){"use strict";var m=i(67),I=i(60),B=i(1152),E=i(875),_=i(1184),b=i(927),y=i(1156),v=i(89),T=i(88),C=i(1178),N=i(1125),V=i(1257);e.exports=function(n,e,t,r,a){var i,o,s,l,u,c=I[n],h=c&&c.prototype,p=c,d=r?"set":"add",f={},g=function(e){var i=h[e];E(h,e,"add"==e?function(e){return i.call(this,0===e?0:e),this}:"delete"==e?function(e){return!(a&&!v(e))&&i.call(this,0===e?0:e)}:"get"==e?function(e){return a&&!v(e)?undefined:i.call(this,0===e?0:e)}:"has"==e?function(e){return!(a&&!v(e))&&i.call(this,0===e?0:e)}:function(e,t){return i.call(this,0===e?0:e,t),this})};return B(n,"function"!=typeof c||!(a||h.forEach&&!T(function(){(new c).entries().next()})))?(p=t.getConstructor(e,n,r,d),_.REQUIRED=!0):B(n,!0)&&(o=(i=new p)[d](a?{}:-0,1)!=i,s=T(function(){i.has(1)}),l=C(function(e){new c(e)}),u=!a&&T(function(){for(var e=new c,t=5;t--;)e[d](t,t);return!e.has(-0)}),l||(((p=e(function(e,t){y(e,p,n);var i=V(new c,e,p);return t!=undefined&&b(t,i[d],i,r),i})).prototype=h).constructor=p),(s||u)&&(g("delete"),g("has"),r&&g("get")),(u||o)&&g(d),a&&h.clear&&delete h.clear),f[n]=p,m({global:!0,forced:p!=c},f),N(p,n),a||t.setStrong(p,n,r),p}},function(e,t,i){var n=i(88);e.exports=!n(function(){return Object.isExtensible(Object.preventExtensions({}))})},function(e,t,i){var a=i(89),o=i(1155);e.exports=function(e,t,i){var n,r;return o&&"function"==typeof(n=t.constructor)&&n!==i&&a(r=n.prototype)&&r!==i.prototype&&o(e,r),e}},function(e,t,i){"use strict";var u=i(282).f,c=i(925),h=i(1176),p=i(1126),d=i(1156),f=i(927),o=i(1154),s=i(1177),g=i(173),m=i(1184).fastKey,n=i(917),I=n.set,B=n.getterFor;e.exports={getConstructor:function(e,i,n,r){var a=e(function(e,t){d(e,a,i),I(e,{type:i,index:c(null),first:undefined,last:undefined,size:0}),g||(e.size=0),t!=undefined&&f(t,e[r],e,n)}),s=B(i),o=function(e,t,i){var n,r,a=s(e),o=l(e,t);return o?o.value=i:(a.last=o={index:r=m(t,!0),key:t,value:i,previous:n=a.last,next:undefined,removed:!1},a.first||(a.first=o),n&&(n.next=o),g?a.size++:e.size++,"F"!==r&&(a.index[r]=o)),e},l=function(e,t){var i,n=s(e),r=m(t);if("F"!==r)return n.index[r];for(i=n.first;i;i=i.next)if(i.key==t)return i};return h(a.prototype,{clear:function(){for(var e=s(this),t=e.index,i=e.first;i;)i.removed=!0,i.previous&&(i.previous=i.previous.next=undefined),delete t[i.index],i=i.next;e.first=e.last=undefined,g?e.size=0:this.size=0},"delete":function(e){var t,i,n=s(this),r=l(this,e);return r&&(t=r.next,i=r.previous,delete n.index[r.index],r.removed=!0,i&&(i.next=t),t&&(t.previous=i),n.first==r&&(n.first=t),n.last==r&&(n.last=i),g?n.size--:this.size--),!!r},forEach:function(e){for(var t,i=s(this),n=p(e,1<arguments.length?arguments[1]:undefined,3);t=t?t.next:i.first;)for(n(t.value,t.key,this);t&&t.removed;)t=t.previous},has:function(e){return!!l(this,e)}}),h(a.prototype,n?{get:function(e){var t=l(this,e);return t&&t.value},set:function(e,t){return o(this,0===e?0:e,t)}}:{add:function(e){return o(this,e=0===e?0:e,e)}}),g&&u(a.prototype,"size",{get:function(){return s(this).size}}),a},setStrong:function(e,t,i){var n=t+" Iterator",r=B(t),a=B(n);o(e,t,function(e,t){I(this,{type:n,target:e,state:r(e),kind:t,last:undefined})},function(){for(var e=a(this),t=e.kind,i=e.last;i&&i.removed;)i=i.previous;return e.target&&(e.last=i=i?i.next:e.state.first)?"keys"==t?{value:i.key,done:!1}:"values"==t?{value:i.value,done:!1}:{value:[i.key,i.value],done:!1}:(e.target=undefined,{value:undefined,done:!0})},i?"entries":"values",!i,!0),s(t)}}},function(t,e,i){(function(e){t.exports=e.Fix=i(1260)}).call(this,i(14))},function(e,t,i){(function(Z){function X(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(function(e,d){"use strict";d="default"in d?d["default"]:d;var t=void 0,f={$accessors:t,$vbthis:t,$vbsetter:t,$vm:t},p=["$accessors","$vbthis","$vbsetter","$vm"],n=[];function s(e,t,i){}function i(e){return"function"==typeof e&&/native code/.test(e.toString())}d.each(["slice","splice"],function(e){n[e]=Array.prototype[e]}),Array.prototype.splice=function(){this.__ref__=l();for(var e=arguments.length,t=Array(e),i=0;i<e;i++)t[i]=arguments[i];return n.splice.apply(this,t)};var r=/\d\.\d{4}/;function l(e){var t=0<arguments.length&&e!==undefined?e:"bi";return String(Math.random()+Math.random()).replace(r,t)}"undefined"!=typeof navigator&&/(msie|trident)/i.test(navigator.userAgent.toLowerCase())&&function(){if("undefined"==typeof navigator)return;var e=navigator.userAgent.toLowerCase(),t=e.match(/(?:msie\s([\w.]+))/),i=e.match(/(?:trident.*rv:([\w.]+))/);t&&i&&t[1]&&i[1]?Math.max(+t[1],+i[1]):t&&t[1]?t[1]:i&&i[1]&&i[1]}();var a=Object.prototype.toString;function g(e){return"[object Object]"===a.call(e)}var o=/[^\w.$]/;function u(e){var t=void 0;if(d.isArray(e)){t=[];for(var i=0,n=e.length;i<n;i++)t[i]=u(e[i])}else if(e&&g(e))for(var r in t={},e)-1===p.indexOf(r)&&(t[r]=u(e[r]));else t=e;return t}function c(e){if(null===e)return null;if(Array.isArray(e)){var t=[].concat(e);return e.__ref__!==undefined&&(t.__ref__=e.__ref__),t}return u(e)}var h,m,I,B,E,b,y=(E=!(B=[]),b=void 0,b=void 0!==Z&&i(Z)?function b(){Z(v)}:"undefined"==typeof MessageChannel||!i(MessageChannel)&&"[object MessageChannelConstructor]"!==MessageChannel.toString()?"undefined"!=typeof Promise&&i(Promise)?(h=Promise.resolve(),function b(){h.then(v)}):function b(){setTimeout(v,0)}:(m=new MessageChannel,I=m.port2,m.port1.onmessage=v,function b(){I.postMessage(1)}),function(t,i){var n=void 0;if(B.push(function(){if(t)try{t.call(i)}catch(e){console.error(e)}else n&&n(i)}),E||(E=!0,b()),!t&&"undefined"!=typeof Promise)return new Promise(function(e,t){n=e})});function v(){E=!1;for(var e=B.slice(0),t=B.length=0;t<e.length;t++)e[t]()}function T(e,t,i){"object"==typeof t&&(i=t,t=e,e=function(){return t.apply(this,arguments)});var n=function n(){},r=t.prototype;return n.prototype=r,e.prototype=new n,e.superclass=r,d.extend(e.prototype,i,{superclass:t}),e}Object.prototype.toString,function O$d(t,i,n,r){t instanceof d&&t._wrapped,i instanceof d&&i._wrapped;var a=N$d.call(t);if(a!==N$d.call(i))return!1;switch(a){case"[object RegExp]":case"[object String]":return""+t==""+i;case"[object Number]":return+t!=+t?+i!=+i:0==+t?1/t==1/i:+t==+i;case"[object Date]":case"[object Boolean]":return+t==+i;case"[object Symbol]":return L$d.valueOf.call(t)===L$d.valueOf.call(i)}var o="[object Array]"===a;if(!o){if("object"!=typeof t||"object"!=typeof i)return!1;var s=t.constructor,l=i.constructor;if(s!==l&&!(d.isFunction(s)&&s instanceof s&&d.isFunction(l)&&l instanceof l)&&"constructor"in t&&"constructor"in i)return!1}0;for(var u=(n||[]).length;u--;)if(n[u]===t)return r[u]===i;if(n.push(t),r.push(i),o){if(t.length!==i.length)return!1;for(;u--;)if(!P$d(t[u],i[u],n,r))return!1}else{var c,h=d.keys(t),u=h.length;if(d.keys(i).length!==u)return!1;for(;u--;){if(h[u],-1!==p.indexOf(c))return!0;if(-1===Object.keys(i).indexOf(c)||!P$d(t[c],i[c],n,r))return!1}}return n.pop(),r.pop(),!0},function P$d(t,i,n,r){if(t===i)return 0!==t||1/t==1/i;if(null==t||null==i)return!1;if(t!=t)return i!=i;var a=typeof t;return("function"==a||"object"==a||"object"==typeof i)&&("function"==a||O$d(t,i,n,r))};function C(e,t){if(e===t)return 1;if(e&&t&&"object"==typeof e&&"object"==typeof t){if(e.constructor!==t.constructor)return;var i,n,r=void 0,a=void 0;if(Array.isArray(e)){if((r=e.length)!==t.length)return;for(a=r;0!=a--;)if(!C(e[a],t[a]))return;return 1}if(e.constructor===RegExp)return 1;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();if((r=(n=Object.keys(e)).length)!==Object.keys(t).length)return;for(a=r;0!=a--;)if(!Object.prototype.hasOwnProperty.call(t,n[a]))return;for(a=r;0!=a--;)if(i=n[a],-1===p.indexOf(i)&&!C(e[i],t[i]))return;return 1}return"function"==typeof e||e!=e&&t!=t}var N={};var V=void 0,S={"||":V,"&&":V,"(":V,")":V};function x(r,e,a){var s=3<arguments.length&&arguments[3]!==undefined?arguments[3]:{},l=r;!l.$watch&&l.$vm&&(l=l.$vm),g(a)&&(a=(s=a).handler),"string"==typeof a&&(a=l[a]),(s=s||{}).user=!0;var o=void 0;if(d.isFunction(e)||!(o=e.match(/[a-zA-Z0-9_.*]+|[|][|]|[&][&]|[(]|[)]/g))||1===o.length&&!/\*/.test(e))return l.$watch(e,a,s),[];var u=o.slice(),c=!1,h=!1,p=function p(e,t,i,n){!0!==c&&(u[e]=!0,function(e){for(var t="",i=0,n=e.length;i<n;i++)d.isBoolean(e[i])||d.has(S,e[i])?t+=e[i]:t+="false";return new Function("return "+t)()}(u)&&(c=!0,a.call(r,t,i,n)),s&&s.sync?(h=c=!1,u=o.slice()):h||(h=!0,y(function(){h=c=!1,u=o.slice()})))};return d.each(o,function(e,n){if(!d.has(S,e))if(/^[1-9a-zA-Z.]+(\*\*$|\*$)/.test(e)||"**"===e){var t=/\*\*$/.test(e);e=t?e.replace(".**",""):e.replace(".*","");var i=t?e:function(){var i={};return d.each(l.model,function(e,t){t in f||(i[t]=e)}),i};l.$watch(i,function(e,t,i){p(n,e,t,d.extend({index:n},i))},d.extend(s,{deep:t}))}else{if(/\*\*$|\*$/.test(e))throw new Error("not support");var a,o;/\*/.test(e)?(a=e.split("."),o=function o(){for(var t={root:l.model},r=function r(e,i){var n={};"*"===a[i]?d.each(t,function(e,i){d.each(e,function(e,t){i+t in f||(n[i+t]=e)})}):d.each(t,function(e,t){t+a[i]in f||(n[t+a[i]]=e[a[i]])}),t=n},e=0,i=a.length;e<i;e++)r(i,e);return t},l.$watch(o,function(e,t,i){p(n,e,t,d.extend({index:n},i))},s)):l.$watch(e,function(e,t,i){p(n,e,t,d.extend({index:n},i))},s)}}),[]}var w={},A={},L=function L(){},k=(D.prototype.getInstance=function(){return this},D);function D(e){var t=e.get,i=e.last,n=e.listener,r=e.sync,a=(e.deep,e.id);return X(this,D),this.id=a,this.get=t,this.last=c(i),this.listener=n||L,this.sync=r||!1,{id:this.id,get:this.get,last:this.last,listener:this.listener}}function P(e,t,i,n){var r=3<arguments.length&&n!==undefined?n:{};g(i)&&(i=(r=i).handler),"string"==typeof i&&(i=e[i]);var a=d.isFunction(t)?d.bind(t,e):d.bind(function(){return function(e){if(!o.test(e)){var i=e.split(".");return function(e){for(var t=0;t<i.length;t++){if(!e)return;e=e[i[t]]}return e}}}("model."+t)(e)},e);return new k({get:a,listener:d.bind(i,e),last:a(),sync:r.sync,deep:r.deep,id:r.id})}function M(t,i){return function(){var e=t.apply(i,[].concat(Array.prototype.slice.call(arguments)));return i.$digest(),e}}function R(n,e){var t=1<arguments.length&&e!==undefined?e:[];d.each(t.reverse(),function(e){var t=N[e];for(var i in t)"function"==typeof t[i]&&(d.has(n,i)||(n[i]=M(t[i],n)))})}function H(r,e){var n=r._contextWatchers={};d.each(e,function(t){var i=function(n){for(var e=r._parent;e;){if(e.childContext&&-1<e.childContext.indexOf(n))return e.$watch(n,function(e,t,i){r._contextWatchers[n]&&(r.model[n]=e,r._contextWatchers[n].last=c(e),r.$digest())},{id:r._modelHashId+"-"+n}),{p:e,value:e.model[n]};e=e._parent}}(t);i&&(r.model[t]=i.p?i.p.model[t]:undefined,n[t]=new k({id:i.p._modelHashId+"-"+t,get:function(){return r.model[t]},last:r.model[t],listener:d.bind(function(e){i.p.model[t]=e,i.p.$digest()},i.p)}))})}function O(e){for(var t=!0,i=!0,n=!0,r=10;t&&0<r;r--)t=function(n){var r=!1;return d.each(n._stateWatchers,function(e,t){var i=e.get();C(i,e.last)||(n.model[t]=i,r=!0,e.last=c(i))}),r}(e);for(var a=10;i&&0<a;a--)i=function(a){var o=!1;return d.each(a._contextWatchers,function(e,t){var i,n=e.get(),r=e.last;C(n,r)||(i={id:e.id,cb:d.bind(e.listener,a,n,r,a)},a.contextListeners.push(i),a.model[t]=n,o=!0,e.last=c(n))}),o}(e);for(var o=10;n&&0<o;o--)n=function(r){var a=!1,o=[],s=[];return d.each(r._computedOrder,function(e){var t=r._computedWatchers[e];try{var i=t.get();C(i,t.last)?s.push(e):(r.model[e]=i,a=!0,o.push(e),t.last=c(i))}catch(n){a=!0,o.push(e)}}),r._computedOrder=[].concat(s,o),a}(e)}var F,Y=(F={},function(e,t){var i=e.id,n=e.cb;i&&F[i]||(y(function(){n(),F[i]=!1},t),F[i]=!0)});var W=(G.prototype._constructor=function(e){this.alive=!0,this.options=e||{},this.model={$vm:this},this._modelHashId=l("model"),this.syncListeners=[],this.asyncListeners=[],this.contextListeners=[],this._parent=G.target;var t=d.isFunction(this.state)?this.state():this.state,i=this.computed,n=this.context,r=(this.childContext,this.watch),a=this.actions,o=this.mixins;n&&H(this,n),R(this,o),this.init(),function(i,n){var r=i._stateWatchers={};for(var e in n)i.model[e]=n[e];var a=function a(e){var t=n[e];r[e]=new k({id:i._modelHashId+"-"+e,get:function(){return i.model[e]},last:t,listener:i.options.defaultCallback||L})};for(var t in n)a(t)}(this,t),function(e,t){var i=e._computedWatchers={},n=e._computedOrder=[];for(var r in t){var a=t[r],o=e;n.push(r),i[r]=new k({id:e._modelHashId+"-"+r,get:d.bind(a,o),last:undefined,listener:L})}}(this,i),O(this),function(e,t){for(var i in e._watchers||(e._watchers=[]),t){var n=t[i];if(d.isArray(n))for(var r=0;r<n.length;r++)x(e,i,n[r]);else x(e,i,n)}}(this,r),function(e,t){for(var i in t)e[i]=null==t[i]?s:M(t[i],e)}(this,a),this.created&&this.created(),w[this._modelHashId]=this},G.prototype._init=function(){},G.prototype.init=function(){this._init()},G.prototype.destroy=function(){this.alive=!1,w[this._modelHashId]=null,this._watchers&&(this._watchers=[]),this._computedWatchers&&(this._computedWatchers=[]),this._stateWatchers&&(this._stateWatchers=[]),this._contextWatchers&&(this._contextWatchers=[]),this.destroyed&&this.destroyed()},G.prototype.$watch=function(e,t,i){var n=P(this,e,t,i);this._watchers.push(n)},G.prototype.$digest=function(){O(this),function(r){var a=[].concat(r.syncListeners||[]),o=[].concat(r.asyncListeners||[]),e=[].concat(r.contextListeners||[]);r.asyncListeners=[],r.syncListeners=[];var t=[].concat(r._watchers);d.each(t,function(e){var t,i,n;e&&(C(t=e.get(),i=e.last)||(n={id:e.id,cb:d.bind(e.listener,r,t,i,r)},!0===e.sync?a.push(n):o.push(n),e.last=c(t)))}),d.each(a,function(e){e.cb()}),0===e.length&&0===o.length||y(function(){d.each(BI.uniqBy(e.reverse(),"id").reverse(),function(e){e.cb()}),d.each(o,function(e){e.cb()})})}(this),this.options.define||d.each(A,function(e){e&&e.$digest&&e.$digest()})},G.prototype.getModelID=function(){return this._modelHashId},G);function G(){X(this,G)}function j(){return w}e.version="2.0",e.$$skipArray=f,e.mixin=function(e,t){N[e]=_.cloneDeep(t)},e.toJSON=u,e.nextListener=Y,e.Model=W,e.getAllModelInstances=j,e.refreshAll=function(){d.each(w,function(e){e&&e.$digest&&e.$digest()})},e.define=function(e){var t=new(T(W,{state:function(){return e}}));return t._constructor({define:!0}),(A[t.getModelID()]=t).model},e.inherit=T,e.watch=x,e.__esModule=!0})(t,(i(1185),i(1185)))}).call(this,i(61).setImmediate)},function(e,t){!function(){function s(e,t,i,n){return BI.isPlainObject(i)&&(i=(n=i).handler),n=n||{},Fix.watch(e.model,t,_.bind(i,e),BI.extend(n,{store:e.store}))}var i=null,t=[];function r(e){i&&t.push(i),Fix.Model.target=i=e}function a(){Fix.Model.target=i=t.pop()}var o=Fix.watch;function n(){var e,t=!1;return _global.Fix&&this._store&&((e=function(e){if(null!=i)return i;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))&&(r(e),t=!0),this.store=this._store(),this.store&&(this.store._widget=this),t&&a(),t=!1,r(this.store),this.store instanceof Fix.Model?this.model=this.store.model:this.model=this.store,t=!0),t}Fix.watch=function(e,t,i,n){return BI.isPlainObject(i)&&(i=(n=i).handler),"string"==typeof i&&(i=e[i]),o.call(this,e,t,function(){n&&n.store&&r(n.store);var e=i.apply(this,arguments);return n&&n.store&&a(),e},n)},_.each(["populate","addItems","prependItems"],function(e){var t=BI.Loader.prototype[e];BI.Loader.prototype[e]=function(){BI.Widget.pushContext(this);var e=t.apply(this,arguments);return BI.Widget.popContext(),e}}),BI.Widget.prototype._initRender=function(){this.beforeInit?(this.__asking=!0,this.beforeInit(BI.bind(function(){this.model&&this.model.$vm&&this.model.$vm.$digest(),this._render()},this)),!0===this.__asking&&(this.__async=!0)):this._render()};var l=BI.Widget.prototype._init;BI.Widget.prototype._init=function(){var e=n.call(this);l.apply(this,arguments),e&&a()};var u=BI.Widget.prototype._render;BI.Widget.prototype._render=function(){var e=!1;_global.Fix&&this._store&&(e=!0,r(this.store),function(o,e){for(var t in o._watchers||(o._watchers=[]),e){var i=e[t];if(BI.isArray(i))for(var n=0;n<i.length;n++)o._watchers.push(s(o,t,i[n]));else o._watchers.push(s(o,t,i))}BI.each(o.$watchDelayCallbacks,function(e,t){var i=t[0],n=t[1];for(var r in BI.isKey(i)&&(r=i,(i={})[r]=n),i){var a=i[r];if(BI.isArray(a))for(e=0;e<a.length;e++)o._watchers.push(s(o,r,a[e]));else o._watchers.push(s(o,r,a))}})}(this,this.watch)),u.apply(this,arguments),e&&a()};var e=BI.Widget.prototype.__d;BI.Widget.prototype.__d=function(){e.apply(this,arguments),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 i=BI.Widget.prototype[e];i&&(BI.Widget.prototype[e]=function(){this.store&&r(this.store);try{var e=i.apply(this,arguments)}catch(t){console.error(t)}return this.store&&a(),e})});var c,h,p,d=function(){BI.nextTick(function(){Fix&&Fix.refreshAll&&Fix.refreshAll()})};$(document).ajaxComplete(d),BI.history&&(c=BI.history.navigate,BI.history.navigate=function(){c.apply(this,arguments),BI.defer(function(){d()},200)},h=window.history.back,window.history.back=function(){h.apply(this,arguments),BI.defer(function(){d()},200)}),BI.Router&&(p=BI.Router.prototype.execute,BI.Router.prototype.execute=function(){p.apply(this,arguments),d()}),_.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 n=BI[e];BI[e]=function(e,i,t){return"function"==typeof i?n(e,function(e,t){if(!(e in Fix.$$skipArray))return i.apply(this,arguments)},t):n.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),i=[],n=0;n<t.length;n++)t[n]in Fix.$$skipArray||i.push(t[n]);return i},BI.values=function(e){for(var t=BI.keys(obj),i=t.length,n=[],r=0;r<i;r++)n[r]=obj[t[r]];return n},BI.extend=function(){var e=Array.prototype.slice.call(arguments);if(e.length<1)return{};for(var i=e[0],t=1;t<e.length;)BI.each(e[t],function(e,t){i[e]=t}),t++;return i},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)},Fix.set=function(e,t,i){try{e&&(e[t]=i)}catch(n){}finally{return _.cloneDeep(e)}},Fix.del=function(e,t){try{delete e[t]}catch(i){}finally{return _.cloneDeep(e)}}}()},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,i){i(91),i(910),i(911),i(912),i(913),i(914),i(915),i(1191),i(1199),i(1203),i(1207),i(1213),i(1216),i(1220),i(1223),i(1227),i(1246),i(1253),i(847),i(848),i(202),i(203),i(204),i(205),i(206),i(207),i(208),i(209),i(210),i(211),i(212),i(213),i(214),i(215),i(216),i(217),i(218),i(219),i(220),i(221),i(92),i(95),i(97),i(283),i(284),i(98),i(285),i(286),i(287),i(288),i(289),i(290),i(99),i(100),i(101),i(291),i(292),i(293),i(294),i(295),i(296),i(297),i(298),i(102),i(103),i(104),i(105),i(106),i(107),i(299),i(300),i(301),i(302),i(303),i(849),i(850),i(851),i(852),i(853),i(854),i(855),i(856),i(857),i(304),i(305),i(306),i(307),i(308),i(309),i(310),i(311),i(312),i(313),i(314),i(315),i(316),i(317),i(108),i(318),i(319),i(320),i(109),i(321),i(322),i(323),i(324),i(325),i(326),i(327),i(328),i(329),i(330),i(331),i(332),i(333),i(334),i(335),i(336),i(337),i(338),i(339),i(340),i(341),i(342),i(343),i(344),i(345),i(346),i(347),i(348),i(349),i(350),i(351),i(352),i(353),i(354),i(355),i(356),i(357),i(358),i(359),i(360),i(361),i(362),i(363),i(364),i(365),i(366),i(367),i(110),i(111),i(112),i(1259),i(222),i(223),i(224),i(225),i(226),i(227),i(228),i(229),i(230),i(231),i(232),i(233),i(234),i(235),i(236),i(237),i(238),i(239),i(240),i(241),i(242),i(243),i(244),i(245),i(246),i(247),i(248),i(249),i(250),i(251),i(252),i(253),i(254),i(255),i(256),i(257),i(258),i(259),i(260),i(261),i(262),i(263),i(264),i(265),i(266),i(267),i(268),i(269),i(270),i(271),i(272),i(273),i(274),i(275),i(276),i(277),i(278),i(279),i(859),i(368),i(369),i(370),i(371),i(372),i(373),i(374),i(375),i(376),i(377),i(378),i(379),i(380),i(381),i(382),i(383),i(384),i(385),i(386),i(387),i(388),i(389),i(390),i(391),i(392),i(393),i(394),i(395),i(396),i(397),i(398),i(399),i(400),i(401),i(402),i(403),i(404),i(405),i(406),i(407),i(408),i(409),i(410),i(411),i(412),i(413),i(414),i(415),i(416),i(417),i(418),i(419),i(420),i(860),i(421),i(422),i(423),i(424),i(425),i(426),i(427),i(428),i(429),i(430),i(431),i(432),i(433),i(434),i(435),i(436),i(437),i(438),i(439),i(440),i(441),i(442),i(443),i(444),i(445),i(446),i(447),i(448),i(449),i(450),i(451),i(452),i(453),i(454),i(455),i(456),i(457),i(458),i(459),i(460),i(461),i(462),i(463),i(464),i(465),i(466),i(467),i(468),i(469),i(470),i(471),i(472),i(473),i(474),i(475),i(476),i(477),i(478),i(479),i(480),i(481),i(482),i(483),i(484),i(485),i(486),i(487),i(488),i(489),i(490),i(491),i(492),i(493),i(494),i(495),i(496),i(497),i(498),i(499),i(500),i(501),i(502),i(503),i(504),i(505),i(506),i(507),i(508),i(509),i(510),i(511),i(512),i(513),i(514),i(515),i(516),i(517),i(518),i(519),i(520),i(521),i(522),i(523),i(524),i(525),i(526),i(527),i(528),i(529),i(530),i(531),i(532),i(861),i(862),i(863),i(864),i(865),i(866),i(867),i(868),i(869),i(870),i(871),i(872),i(873),i(113),i(114),i(115),i(116),i(117),i(118),i(119),i(120),i(121),i(122),i(123),i(124),i(125),i(126),i(127),i(128),i(129),i(130),i(131),i(132),i(133),i(134),i(135),i(136),i(137),i(138),i(139),i(140),i(141),i(142),i(143),i(144),i(145),i(146),i(147),i(148),i(149),i(150),i(151),i(152),i(153),i(154),i(155),i(156),i(157),i(158),i(159),i(160),i(161),i(162),i(163),i(164),i(165),i(166),i(167),i(168),i(169),i(170),i(171),i(172),i(533),i(534),i(535),i(536),i(537),i(538),i(539),i(540),i(541),i(542),i(543),i(544),i(545),i(546),i(547),i(548),i(549),i(550),i(551),i(552),i(553),i(554),i(555),i(556),i(557),i(558),i(559),i(560),i(561),i(562),i(563),i(564),i(565),i(566),i(567),i(568),i(569),i(570),i(571),i(572),i(573),i(574),i(575),i(576),i(577),i(578),i(579),i(580),i(581),i(582),i(583),i(584),i(585),i(586),i(587),i(588),i(589),i(590),i(591),i(592),i(593),i(594),i(595),i(596),i(597),i(598),i(599),i(600),i(601),i(602),i(603),i(604),i(605),i(606),i(607),i(608),i(609),i(610),i(611),i(612),i(613),i(614),i(615),i(616),i(617),i(618),i(619),i(620),i(621),i(622),i(623),i(624),i(625),i(626),i(627),i(628),i(629),i(630),i(631),i(632),i(633),i(634),i(635),i(636),i(637),i(638),i(639),i(640),i(641),i(642),i(643),i(644),i(645),i(646),i(647),i(648),i(649),i(650),i(651),i(652),i(653),i(654),i(655),i(656),i(657),i(658),i(659),i(660),i(661),i(662),i(663),i(664),i(665),i(666),i(667),i(668),i(669),i(670),i(671),i(672),i(673),i(674),i(675),i(676),i(677),i(678),i(679),i(680),i(681),i(682),i(683),i(684),i(685),i(686),i(687),i(688),i(689),i(690),i(691),i(692),i(693),i(694),i(695),i(696),i(697),i(698),i(699),i(700),i(701),i(702),i(703),i(858),i(1261),i(874),i(1129),i(1130),i(1131),i(1132),i(1133),i(1121),e.exports=i(704)}]);