bootstrap-table-pipeline.js 41 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206
  1. (function (global, factory) {
  2. typeof exports === 'object' && typeof module !== 'undefined' ? factory(require('jquery')) :
  3. typeof define === 'function' && define.amd ? define(['jquery'], factory) :
  4. (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.jQuery));
  5. }(this, (function ($) { 'use strict';
  6. function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
  7. var $__default = /*#__PURE__*/_interopDefaultLegacy($);
  8. var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
  9. function createCommonjsModule(fn, module) {
  10. return module = { exports: {} }, fn(module, module.exports), module.exports;
  11. }
  12. var check = function (it) {
  13. return it && it.Math == Math && it;
  14. };
  15. // https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
  16. var global_1 =
  17. // eslint-disable-next-line es/no-global-this -- safe
  18. check(typeof globalThis == 'object' && globalThis) ||
  19. check(typeof window == 'object' && window) ||
  20. // eslint-disable-next-line no-restricted-globals -- safe
  21. check(typeof self == 'object' && self) ||
  22. check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
  23. // eslint-disable-next-line no-new-func -- fallback
  24. (function () { return this; })() || Function('return this')();
  25. var fails = function (exec) {
  26. try {
  27. return !!exec();
  28. } catch (error) {
  29. return true;
  30. }
  31. };
  32. // Detect IE8's incomplete defineProperty implementation
  33. var descriptors = !fails(function () {
  34. // eslint-disable-next-line es/no-object-defineproperty -- required for testing
  35. return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] != 7;
  36. });
  37. var $propertyIsEnumerable = {}.propertyIsEnumerable;
  38. // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
  39. var getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
  40. // Nashorn ~ JDK8 bug
  41. var NASHORN_BUG = getOwnPropertyDescriptor$1 && !$propertyIsEnumerable.call({ 1: 2 }, 1);
  42. // `Object.prototype.propertyIsEnumerable` method implementation
  43. // https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable
  44. var f$4 = NASHORN_BUG ? function propertyIsEnumerable(V) {
  45. var descriptor = getOwnPropertyDescriptor$1(this, V);
  46. return !!descriptor && descriptor.enumerable;
  47. } : $propertyIsEnumerable;
  48. var objectPropertyIsEnumerable = {
  49. f: f$4
  50. };
  51. var createPropertyDescriptor = function (bitmap, value) {
  52. return {
  53. enumerable: !(bitmap & 1),
  54. configurable: !(bitmap & 2),
  55. writable: !(bitmap & 4),
  56. value: value
  57. };
  58. };
  59. var toString = {}.toString;
  60. var classofRaw = function (it) {
  61. return toString.call(it).slice(8, -1);
  62. };
  63. var split = ''.split;
  64. // fallback for non-array-like ES3 and non-enumerable old V8 strings
  65. var indexedObject = fails(function () {
  66. // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
  67. // eslint-disable-next-line no-prototype-builtins -- safe
  68. return !Object('z').propertyIsEnumerable(0);
  69. }) ? function (it) {
  70. return classofRaw(it) == 'String' ? split.call(it, '') : Object(it);
  71. } : Object;
  72. // `RequireObjectCoercible` abstract operation
  73. // https://tc39.es/ecma262/#sec-requireobjectcoercible
  74. var requireObjectCoercible = function (it) {
  75. if (it == undefined) throw TypeError("Can't call method on " + it);
  76. return it;
  77. };
  78. // toObject with fallback for non-array-like ES3 strings
  79. var toIndexedObject = function (it) {
  80. return indexedObject(requireObjectCoercible(it));
  81. };
  82. var isObject = function (it) {
  83. return typeof it === 'object' ? it !== null : typeof it === 'function';
  84. };
  85. // `ToPrimitive` abstract operation
  86. // https://tc39.es/ecma262/#sec-toprimitive
  87. // instead of the ES6 spec version, we didn't implement @@toPrimitive case
  88. // and the second argument - flag - preferred type is a string
  89. var toPrimitive = function (input, PREFERRED_STRING) {
  90. if (!isObject(input)) return input;
  91. var fn, val;
  92. if (PREFERRED_STRING && typeof (fn = input.toString) == 'function' && !isObject(val = fn.call(input))) return val;
  93. if (typeof (fn = input.valueOf) == 'function' && !isObject(val = fn.call(input))) return val;
  94. if (!PREFERRED_STRING && typeof (fn = input.toString) == 'function' && !isObject(val = fn.call(input))) return val;
  95. throw TypeError("Can't convert object to primitive value");
  96. };
  97. var hasOwnProperty = {}.hasOwnProperty;
  98. var has$1 = function (it, key) {
  99. return hasOwnProperty.call(it, key);
  100. };
  101. var document = global_1.document;
  102. // typeof document.createElement is 'object' in old IE
  103. var EXISTS = isObject(document) && isObject(document.createElement);
  104. var documentCreateElement = function (it) {
  105. return EXISTS ? document.createElement(it) : {};
  106. };
  107. // Thank's IE8 for his funny defineProperty
  108. var ie8DomDefine = !descriptors && !fails(function () {
  109. // eslint-disable-next-line es/no-object-defineproperty -- requied for testing
  110. return Object.defineProperty(documentCreateElement('div'), 'a', {
  111. get: function () { return 7; }
  112. }).a != 7;
  113. });
  114. // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
  115. var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
  116. // `Object.getOwnPropertyDescriptor` method
  117. // https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
  118. var f$3 = descriptors ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {
  119. O = toIndexedObject(O);
  120. P = toPrimitive(P, true);
  121. if (ie8DomDefine) try {
  122. return $getOwnPropertyDescriptor(O, P);
  123. } catch (error) { /* empty */ }
  124. if (has$1(O, P)) return createPropertyDescriptor(!objectPropertyIsEnumerable.f.call(O, P), O[P]);
  125. };
  126. var objectGetOwnPropertyDescriptor = {
  127. f: f$3
  128. };
  129. var anObject = function (it) {
  130. if (!isObject(it)) {
  131. throw TypeError(String(it) + ' is not an object');
  132. } return it;
  133. };
  134. // eslint-disable-next-line es/no-object-defineproperty -- safe
  135. var $defineProperty = Object.defineProperty;
  136. // `Object.defineProperty` method
  137. // https://tc39.es/ecma262/#sec-object.defineproperty
  138. var f$2 = descriptors ? $defineProperty : function defineProperty(O, P, Attributes) {
  139. anObject(O);
  140. P = toPrimitive(P, true);
  141. anObject(Attributes);
  142. if (ie8DomDefine) try {
  143. return $defineProperty(O, P, Attributes);
  144. } catch (error) { /* empty */ }
  145. if ('get' in Attributes || 'set' in Attributes) throw TypeError('Accessors not supported');
  146. if ('value' in Attributes) O[P] = Attributes.value;
  147. return O;
  148. };
  149. var objectDefineProperty = {
  150. f: f$2
  151. };
  152. var createNonEnumerableProperty = descriptors ? function (object, key, value) {
  153. return objectDefineProperty.f(object, key, createPropertyDescriptor(1, value));
  154. } : function (object, key, value) {
  155. object[key] = value;
  156. return object;
  157. };
  158. var setGlobal = function (key, value) {
  159. try {
  160. createNonEnumerableProperty(global_1, key, value);
  161. } catch (error) {
  162. global_1[key] = value;
  163. } return value;
  164. };
  165. var SHARED = '__core-js_shared__';
  166. var store$1 = global_1[SHARED] || setGlobal(SHARED, {});
  167. var sharedStore = store$1;
  168. var functionToString = Function.toString;
  169. // this helper broken in `3.4.1-3.4.4`, so we can't use `shared` helper
  170. if (typeof sharedStore.inspectSource != 'function') {
  171. sharedStore.inspectSource = function (it) {
  172. return functionToString.call(it);
  173. };
  174. }
  175. var inspectSource = sharedStore.inspectSource;
  176. var WeakMap$1 = global_1.WeakMap;
  177. var nativeWeakMap = typeof WeakMap$1 === 'function' && /native code/.test(inspectSource(WeakMap$1));
  178. var shared = createCommonjsModule(function (module) {
  179. (module.exports = function (key, value) {
  180. return sharedStore[key] || (sharedStore[key] = value !== undefined ? value : {});
  181. })('versions', []).push({
  182. version: '3.10.1',
  183. mode: 'global',
  184. copyright: '© 2021 Denis Pushkarev (zloirock.ru)'
  185. });
  186. });
  187. var id = 0;
  188. var postfix = Math.random();
  189. var uid = function (key) {
  190. return 'Symbol(' + String(key === undefined ? '' : key) + ')_' + (++id + postfix).toString(36);
  191. };
  192. var keys = shared('keys');
  193. var sharedKey = function (key) {
  194. return keys[key] || (keys[key] = uid(key));
  195. };
  196. var hiddenKeys$1 = {};
  197. var WeakMap = global_1.WeakMap;
  198. var set, get, has;
  199. var enforce = function (it) {
  200. return has(it) ? get(it) : set(it, {});
  201. };
  202. var getterFor = function (TYPE) {
  203. return function (it) {
  204. var state;
  205. if (!isObject(it) || (state = get(it)).type !== TYPE) {
  206. throw TypeError('Incompatible receiver, ' + TYPE + ' required');
  207. } return state;
  208. };
  209. };
  210. if (nativeWeakMap) {
  211. var store = sharedStore.state || (sharedStore.state = new WeakMap());
  212. var wmget = store.get;
  213. var wmhas = store.has;
  214. var wmset = store.set;
  215. set = function (it, metadata) {
  216. metadata.facade = it;
  217. wmset.call(store, it, metadata);
  218. return metadata;
  219. };
  220. get = function (it) {
  221. return wmget.call(store, it) || {};
  222. };
  223. has = function (it) {
  224. return wmhas.call(store, it);
  225. };
  226. } else {
  227. var STATE = sharedKey('state');
  228. hiddenKeys$1[STATE] = true;
  229. set = function (it, metadata) {
  230. metadata.facade = it;
  231. createNonEnumerableProperty(it, STATE, metadata);
  232. return metadata;
  233. };
  234. get = function (it) {
  235. return has$1(it, STATE) ? it[STATE] : {};
  236. };
  237. has = function (it) {
  238. return has$1(it, STATE);
  239. };
  240. }
  241. var internalState = {
  242. set: set,
  243. get: get,
  244. has: has,
  245. enforce: enforce,
  246. getterFor: getterFor
  247. };
  248. var redefine = createCommonjsModule(function (module) {
  249. var getInternalState = internalState.get;
  250. var enforceInternalState = internalState.enforce;
  251. var TEMPLATE = String(String).split('String');
  252. (module.exports = function (O, key, value, options) {
  253. var unsafe = options ? !!options.unsafe : false;
  254. var simple = options ? !!options.enumerable : false;
  255. var noTargetGet = options ? !!options.noTargetGet : false;
  256. var state;
  257. if (typeof value == 'function') {
  258. if (typeof key == 'string' && !has$1(value, 'name')) {
  259. createNonEnumerableProperty(value, 'name', key);
  260. }
  261. state = enforceInternalState(value);
  262. if (!state.source) {
  263. state.source = TEMPLATE.join(typeof key == 'string' ? key : '');
  264. }
  265. }
  266. if (O === global_1) {
  267. if (simple) O[key] = value;
  268. else setGlobal(key, value);
  269. return;
  270. } else if (!unsafe) {
  271. delete O[key];
  272. } else if (!noTargetGet && O[key]) {
  273. simple = true;
  274. }
  275. if (simple) O[key] = value;
  276. else createNonEnumerableProperty(O, key, value);
  277. // add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
  278. })(Function.prototype, 'toString', function toString() {
  279. return typeof this == 'function' && getInternalState(this).source || inspectSource(this);
  280. });
  281. });
  282. var path = global_1;
  283. var aFunction$1 = function (variable) {
  284. return typeof variable == 'function' ? variable : undefined;
  285. };
  286. var getBuiltIn = function (namespace, method) {
  287. return arguments.length < 2 ? aFunction$1(path[namespace]) || aFunction$1(global_1[namespace])
  288. : path[namespace] && path[namespace][method] || global_1[namespace] && global_1[namespace][method];
  289. };
  290. var ceil = Math.ceil;
  291. var floor = Math.floor;
  292. // `ToInteger` abstract operation
  293. // https://tc39.es/ecma262/#sec-tointeger
  294. var toInteger = function (argument) {
  295. return isNaN(argument = +argument) ? 0 : (argument > 0 ? floor : ceil)(argument);
  296. };
  297. var min$1 = Math.min;
  298. // `ToLength` abstract operation
  299. // https://tc39.es/ecma262/#sec-tolength
  300. var toLength = function (argument) {
  301. return argument > 0 ? min$1(toInteger(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991
  302. };
  303. var max$1 = Math.max;
  304. var min = Math.min;
  305. // Helper for a popular repeating case of the spec:
  306. // Let integer be ? ToInteger(index).
  307. // If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).
  308. var toAbsoluteIndex = function (index, length) {
  309. var integer = toInteger(index);
  310. return integer < 0 ? max$1(integer + length, 0) : min(integer, length);
  311. };
  312. // `Array.prototype.{ indexOf, includes }` methods implementation
  313. var createMethod$2 = function (IS_INCLUDES) {
  314. return function ($this, el, fromIndex) {
  315. var O = toIndexedObject($this);
  316. var length = toLength(O.length);
  317. var index = toAbsoluteIndex(fromIndex, length);
  318. var value;
  319. // Array#includes uses SameValueZero equality algorithm
  320. // eslint-disable-next-line no-self-compare -- NaN check
  321. if (IS_INCLUDES && el != el) while (length > index) {
  322. value = O[index++];
  323. // eslint-disable-next-line no-self-compare -- NaN check
  324. if (value != value) return true;
  325. // Array#indexOf ignores holes, Array#includes - not
  326. } else for (;length > index; index++) {
  327. if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;
  328. } return !IS_INCLUDES && -1;
  329. };
  330. };
  331. var arrayIncludes = {
  332. // `Array.prototype.includes` method
  333. // https://tc39.es/ecma262/#sec-array.prototype.includes
  334. includes: createMethod$2(true),
  335. // `Array.prototype.indexOf` method
  336. // https://tc39.es/ecma262/#sec-array.prototype.indexof
  337. indexOf: createMethod$2(false)
  338. };
  339. var indexOf = arrayIncludes.indexOf;
  340. var objectKeysInternal = function (object, names) {
  341. var O = toIndexedObject(object);
  342. var i = 0;
  343. var result = [];
  344. var key;
  345. for (key in O) !has$1(hiddenKeys$1, key) && has$1(O, key) && result.push(key);
  346. // Don't enum bug & hidden keys
  347. while (names.length > i) if (has$1(O, key = names[i++])) {
  348. ~indexOf(result, key) || result.push(key);
  349. }
  350. return result;
  351. };
  352. // IE8- don't enum bug keys
  353. var enumBugKeys = [
  354. 'constructor',
  355. 'hasOwnProperty',
  356. 'isPrototypeOf',
  357. 'propertyIsEnumerable',
  358. 'toLocaleString',
  359. 'toString',
  360. 'valueOf'
  361. ];
  362. var hiddenKeys = enumBugKeys.concat('length', 'prototype');
  363. // `Object.getOwnPropertyNames` method
  364. // https://tc39.es/ecma262/#sec-object.getownpropertynames
  365. // eslint-disable-next-line es/no-object-getownpropertynames -- safe
  366. var f$1 = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
  367. return objectKeysInternal(O, hiddenKeys);
  368. };
  369. var objectGetOwnPropertyNames = {
  370. f: f$1
  371. };
  372. // eslint-disable-next-line es/no-object-getownpropertysymbols -- safe
  373. var f = Object.getOwnPropertySymbols;
  374. var objectGetOwnPropertySymbols = {
  375. f: f
  376. };
  377. // all object keys, includes non-enumerable and symbols
  378. var ownKeys = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) {
  379. var keys = objectGetOwnPropertyNames.f(anObject(it));
  380. var getOwnPropertySymbols = objectGetOwnPropertySymbols.f;
  381. return getOwnPropertySymbols ? keys.concat(getOwnPropertySymbols(it)) : keys;
  382. };
  383. var copyConstructorProperties = function (target, source) {
  384. var keys = ownKeys(source);
  385. var defineProperty = objectDefineProperty.f;
  386. var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
  387. for (var i = 0; i < keys.length; i++) {
  388. var key = keys[i];
  389. if (!has$1(target, key)) defineProperty(target, key, getOwnPropertyDescriptor(source, key));
  390. }
  391. };
  392. var replacement = /#|\.prototype\./;
  393. var isForced = function (feature, detection) {
  394. var value = data[normalize(feature)];
  395. return value == POLYFILL ? true
  396. : value == NATIVE ? false
  397. : typeof detection == 'function' ? fails(detection)
  398. : !!detection;
  399. };
  400. var normalize = isForced.normalize = function (string) {
  401. return String(string).replace(replacement, '.').toLowerCase();
  402. };
  403. var data = isForced.data = {};
  404. var NATIVE = isForced.NATIVE = 'N';
  405. var POLYFILL = isForced.POLYFILL = 'P';
  406. var isForced_1 = isForced;
  407. var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
  408. /*
  409. options.target - name of the target object
  410. options.global - target is the global object
  411. options.stat - export as static methods of target
  412. options.proto - export as prototype methods of target
  413. options.real - real prototype method for the `pure` version
  414. options.forced - export even if the native feature is available
  415. options.bind - bind methods to the target, required for the `pure` version
  416. options.wrap - wrap constructors to preventing global pollution, required for the `pure` version
  417. options.unsafe - use the simple assignment of property instead of delete + defineProperty
  418. options.sham - add a flag to not completely full polyfills
  419. options.enumerable - export as enumerable property
  420. options.noTargetGet - prevent calling a getter on target
  421. */
  422. var _export = function (options, source) {
  423. var TARGET = options.target;
  424. var GLOBAL = options.global;
  425. var STATIC = options.stat;
  426. var FORCED, target, key, targetProperty, sourceProperty, descriptor;
  427. if (GLOBAL) {
  428. target = global_1;
  429. } else if (STATIC) {
  430. target = global_1[TARGET] || setGlobal(TARGET, {});
  431. } else {
  432. target = (global_1[TARGET] || {}).prototype;
  433. }
  434. if (target) for (key in source) {
  435. sourceProperty = source[key];
  436. if (options.noTargetGet) {
  437. descriptor = getOwnPropertyDescriptor(target, key);
  438. targetProperty = descriptor && descriptor.value;
  439. } else targetProperty = target[key];
  440. FORCED = isForced_1(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
  441. // contained in target
  442. if (!FORCED && targetProperty !== undefined) {
  443. if (typeof sourceProperty === typeof targetProperty) continue;
  444. copyConstructorProperties(sourceProperty, targetProperty);
  445. }
  446. // add a flag to not completely full polyfills
  447. if (options.sham || (targetProperty && targetProperty.sham)) {
  448. createNonEnumerableProperty(sourceProperty, 'sham', true);
  449. }
  450. // extend global
  451. redefine(target, key, sourceProperty, options);
  452. }
  453. };
  454. // `IsArray` abstract operation
  455. // https://tc39.es/ecma262/#sec-isarray
  456. // eslint-disable-next-line es/no-array-isarray -- safe
  457. var isArray = Array.isArray || function isArray(arg) {
  458. return classofRaw(arg) == 'Array';
  459. };
  460. var createProperty = function (object, key, value) {
  461. var propertyKey = toPrimitive(key);
  462. if (propertyKey in object) objectDefineProperty.f(object, propertyKey, createPropertyDescriptor(0, value));
  463. else object[propertyKey] = value;
  464. };
  465. var engineIsNode = classofRaw(global_1.process) == 'process';
  466. var engineUserAgent = getBuiltIn('navigator', 'userAgent') || '';
  467. var process = global_1.process;
  468. var versions = process && process.versions;
  469. var v8 = versions && versions.v8;
  470. var match, version;
  471. if (v8) {
  472. match = v8.split('.');
  473. version = match[0] + match[1];
  474. } else if (engineUserAgent) {
  475. match = engineUserAgent.match(/Edge\/(\d+)/);
  476. if (!match || match[1] >= 74) {
  477. match = engineUserAgent.match(/Chrome\/(\d+)/);
  478. if (match) version = match[1];
  479. }
  480. }
  481. var engineV8Version = version && +version;
  482. // eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
  483. var nativeSymbol = !!Object.getOwnPropertySymbols && !fails(function () {
  484. // eslint-disable-next-line es/no-symbol -- required for testing
  485. return !Symbol.sham &&
  486. // Chrome 38 Symbol has incorrect toString conversion
  487. // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances
  488. (engineIsNode ? engineV8Version === 38 : engineV8Version > 37 && engineV8Version < 41);
  489. });
  490. /* eslint-disable es/no-symbol -- required for testing */
  491. var useSymbolAsUid = nativeSymbol
  492. && !Symbol.sham
  493. && typeof Symbol.iterator == 'symbol';
  494. var WellKnownSymbolsStore = shared('wks');
  495. var Symbol$1 = global_1.Symbol;
  496. var createWellKnownSymbol = useSymbolAsUid ? Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid;
  497. var wellKnownSymbol = function (name) {
  498. if (!has$1(WellKnownSymbolsStore, name) || !(nativeSymbol || typeof WellKnownSymbolsStore[name] == 'string')) {
  499. if (nativeSymbol && has$1(Symbol$1, name)) {
  500. WellKnownSymbolsStore[name] = Symbol$1[name];
  501. } else {
  502. WellKnownSymbolsStore[name] = createWellKnownSymbol('Symbol.' + name);
  503. }
  504. } return WellKnownSymbolsStore[name];
  505. };
  506. var SPECIES$2 = wellKnownSymbol('species');
  507. var arrayMethodHasSpeciesSupport = function (METHOD_NAME) {
  508. // We can't use this feature detection in V8 since it causes
  509. // deoptimization and serious performance degradation
  510. // https://github.com/zloirock/core-js/issues/677
  511. return engineV8Version >= 51 || !fails(function () {
  512. var array = [];
  513. var constructor = array.constructor = {};
  514. constructor[SPECIES$2] = function () {
  515. return { foo: 1 };
  516. };
  517. return array[METHOD_NAME](Boolean).foo !== 1;
  518. });
  519. };
  520. var HAS_SPECIES_SUPPORT$1 = arrayMethodHasSpeciesSupport('slice');
  521. var SPECIES$1 = wellKnownSymbol('species');
  522. var nativeSlice = [].slice;
  523. var max = Math.max;
  524. // `Array.prototype.slice` method
  525. // https://tc39.es/ecma262/#sec-array.prototype.slice
  526. // fallback for not array-like ES3 strings and DOM objects
  527. _export({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT$1 }, {
  528. slice: function slice(start, end) {
  529. var O = toIndexedObject(this);
  530. var length = toLength(O.length);
  531. var k = toAbsoluteIndex(start, length);
  532. var fin = toAbsoluteIndex(end === undefined ? length : end, length);
  533. // inline `ArraySpeciesCreate` for usage native `Array#slice` where it's possible
  534. var Constructor, result, n;
  535. if (isArray(O)) {
  536. Constructor = O.constructor;
  537. // cross-realm fallback
  538. if (typeof Constructor == 'function' && (Constructor === Array || isArray(Constructor.prototype))) {
  539. Constructor = undefined;
  540. } else if (isObject(Constructor)) {
  541. Constructor = Constructor[SPECIES$1];
  542. if (Constructor === null) Constructor = undefined;
  543. }
  544. if (Constructor === Array || Constructor === undefined) {
  545. return nativeSlice.call(O, k, fin);
  546. }
  547. }
  548. result = new (Constructor === undefined ? Array : Constructor)(max(fin - k, 0));
  549. for (n = 0; k < fin; k++, n++) if (k in O) createProperty(result, n, O[k]);
  550. result.length = n;
  551. return result;
  552. }
  553. });
  554. // a string of all valid unicode whitespaces
  555. var whitespaces = '\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u2000\u2001\u2002' +
  556. '\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF';
  557. var whitespace = '[' + whitespaces + ']';
  558. var ltrim = RegExp('^' + whitespace + whitespace + '*');
  559. var rtrim = RegExp(whitespace + whitespace + '*$');
  560. // `String.prototype.{ trim, trimStart, trimEnd, trimLeft, trimRight }` methods implementation
  561. var createMethod$1 = function (TYPE) {
  562. return function ($this) {
  563. var string = String(requireObjectCoercible($this));
  564. if (TYPE & 1) string = string.replace(ltrim, '');
  565. if (TYPE & 2) string = string.replace(rtrim, '');
  566. return string;
  567. };
  568. };
  569. var stringTrim = {
  570. // `String.prototype.{ trimLeft, trimStart }` methods
  571. // https://tc39.es/ecma262/#sec-string.prototype.trimstart
  572. start: createMethod$1(1),
  573. // `String.prototype.{ trimRight, trimEnd }` methods
  574. // https://tc39.es/ecma262/#sec-string.prototype.trimend
  575. end: createMethod$1(2),
  576. // `String.prototype.trim` method
  577. // https://tc39.es/ecma262/#sec-string.prototype.trim
  578. trim: createMethod$1(3)
  579. };
  580. var trim = stringTrim.trim;
  581. var $parseInt = global_1.parseInt;
  582. var hex = /^[+-]?0[Xx]/;
  583. var FORCED = $parseInt(whitespaces + '08') !== 8 || $parseInt(whitespaces + '0x16') !== 22;
  584. // `parseInt` method
  585. // https://tc39.es/ecma262/#sec-parseint-string-radix
  586. var numberParseInt = FORCED ? function parseInt(string, radix) {
  587. var S = trim(String(string));
  588. return $parseInt(S, (radix >>> 0) || (hex.test(S) ? 16 : 10));
  589. } : $parseInt;
  590. // `parseInt` method
  591. // https://tc39.es/ecma262/#sec-parseint-string-radix
  592. _export({ global: true, forced: parseInt != numberParseInt }, {
  593. parseInt: numberParseInt
  594. });
  595. var arrayMethodIsStrict = function (METHOD_NAME, argument) {
  596. var method = [][METHOD_NAME];
  597. return !!method && fails(function () {
  598. // eslint-disable-next-line no-useless-call,no-throw-literal -- required for testing
  599. method.call(null, argument || function () { throw 1; }, 1);
  600. });
  601. };
  602. /* eslint-disable es/no-array-prototype-indexof -- required for testing */
  603. var $indexOf = arrayIncludes.indexOf;
  604. var nativeIndexOf = [].indexOf;
  605. var NEGATIVE_ZERO = !!nativeIndexOf && 1 / [1].indexOf(1, -0) < 0;
  606. var STRICT_METHOD = arrayMethodIsStrict('indexOf');
  607. // `Array.prototype.indexOf` method
  608. // https://tc39.es/ecma262/#sec-array.prototype.indexof
  609. _export({ target: 'Array', proto: true, forced: NEGATIVE_ZERO || !STRICT_METHOD }, {
  610. indexOf: function indexOf(searchElement /* , fromIndex = 0 */) {
  611. return NEGATIVE_ZERO
  612. // convert -0 to +0
  613. ? nativeIndexOf.apply(this, arguments) || 0
  614. : $indexOf(this, searchElement, arguments.length > 1 ? arguments[1] : undefined);
  615. }
  616. });
  617. var aFunction = function (it) {
  618. if (typeof it != 'function') {
  619. throw TypeError(String(it) + ' is not a function');
  620. } return it;
  621. };
  622. // optional / simple context binding
  623. var functionBindContext = function (fn, that, length) {
  624. aFunction(fn);
  625. if (that === undefined) return fn;
  626. switch (length) {
  627. case 0: return function () {
  628. return fn.call(that);
  629. };
  630. case 1: return function (a) {
  631. return fn.call(that, a);
  632. };
  633. case 2: return function (a, b) {
  634. return fn.call(that, a, b);
  635. };
  636. case 3: return function (a, b, c) {
  637. return fn.call(that, a, b, c);
  638. };
  639. }
  640. return function (/* ...args */) {
  641. return fn.apply(that, arguments);
  642. };
  643. };
  644. // `ToObject` abstract operation
  645. // https://tc39.es/ecma262/#sec-toobject
  646. var toObject = function (argument) {
  647. return Object(requireObjectCoercible(argument));
  648. };
  649. var SPECIES = wellKnownSymbol('species');
  650. // `ArraySpeciesCreate` abstract operation
  651. // https://tc39.es/ecma262/#sec-arrayspeciescreate
  652. var arraySpeciesCreate = function (originalArray, length) {
  653. var C;
  654. if (isArray(originalArray)) {
  655. C = originalArray.constructor;
  656. // cross-realm fallback
  657. if (typeof C == 'function' && (C === Array || isArray(C.prototype))) C = undefined;
  658. else if (isObject(C)) {
  659. C = C[SPECIES];
  660. if (C === null) C = undefined;
  661. }
  662. } return new (C === undefined ? Array : C)(length === 0 ? 0 : length);
  663. };
  664. var push = [].push;
  665. // `Array.prototype.{ forEach, map, filter, some, every, find, findIndex, filterOut }` methods implementation
  666. var createMethod = function (TYPE) {
  667. var IS_MAP = TYPE == 1;
  668. var IS_FILTER = TYPE == 2;
  669. var IS_SOME = TYPE == 3;
  670. var IS_EVERY = TYPE == 4;
  671. var IS_FIND_INDEX = TYPE == 6;
  672. var IS_FILTER_OUT = TYPE == 7;
  673. var NO_HOLES = TYPE == 5 || IS_FIND_INDEX;
  674. return function ($this, callbackfn, that, specificCreate) {
  675. var O = toObject($this);
  676. var self = indexedObject(O);
  677. var boundFunction = functionBindContext(callbackfn, that, 3);
  678. var length = toLength(self.length);
  679. var index = 0;
  680. var create = specificCreate || arraySpeciesCreate;
  681. var target = IS_MAP ? create($this, length) : IS_FILTER || IS_FILTER_OUT ? create($this, 0) : undefined;
  682. var value, result;
  683. for (;length > index; index++) if (NO_HOLES || index in self) {
  684. value = self[index];
  685. result = boundFunction(value, index, O);
  686. if (TYPE) {
  687. if (IS_MAP) target[index] = result; // map
  688. else if (result) switch (TYPE) {
  689. case 3: return true; // some
  690. case 5: return value; // find
  691. case 6: return index; // findIndex
  692. case 2: push.call(target, value); // filter
  693. } else switch (TYPE) {
  694. case 4: return false; // every
  695. case 7: push.call(target, value); // filterOut
  696. }
  697. }
  698. }
  699. return IS_FIND_INDEX ? -1 : IS_SOME || IS_EVERY ? IS_EVERY : target;
  700. };
  701. };
  702. var arrayIteration = {
  703. // `Array.prototype.forEach` method
  704. // https://tc39.es/ecma262/#sec-array.prototype.foreach
  705. forEach: createMethod(0),
  706. // `Array.prototype.map` method
  707. // https://tc39.es/ecma262/#sec-array.prototype.map
  708. map: createMethod(1),
  709. // `Array.prototype.filter` method
  710. // https://tc39.es/ecma262/#sec-array.prototype.filter
  711. filter: createMethod(2),
  712. // `Array.prototype.some` method
  713. // https://tc39.es/ecma262/#sec-array.prototype.some
  714. some: createMethod(3),
  715. // `Array.prototype.every` method
  716. // https://tc39.es/ecma262/#sec-array.prototype.every
  717. every: createMethod(4),
  718. // `Array.prototype.find` method
  719. // https://tc39.es/ecma262/#sec-array.prototype.find
  720. find: createMethod(5),
  721. // `Array.prototype.findIndex` method
  722. // https://tc39.es/ecma262/#sec-array.prototype.findIndex
  723. findIndex: createMethod(6),
  724. // `Array.prototype.filterOut` method
  725. // https://github.com/tc39/proposal-array-filtering
  726. filterOut: createMethod(7)
  727. };
  728. var $filter = arrayIteration.filter;
  729. var HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('filter');
  730. // `Array.prototype.filter` method
  731. // https://tc39.es/ecma262/#sec-array.prototype.filter
  732. // with adding support of @@species
  733. _export({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT }, {
  734. filter: function filter(callbackfn /* , thisArg */) {
  735. return $filter(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);
  736. }
  737. });
  738. /**
  739. * @author doug-the-guy
  740. * @version v1.0.0
  741. *
  742. * Bootstrap Table Pipeline
  743. * -----------------------
  744. *
  745. * This plugin enables client side data caching for server side requests which will
  746. * eliminate the need to issue a new request every page change. This will allow
  747. * for a performance balance for a large data set between returning all data at once
  748. * (client side paging) and a new server side request (server side paging).
  749. *
  750. * There are two new options:
  751. * - usePipeline: enables this feature
  752. * - pipelineSize: the size of each cache window
  753. *
  754. * The size of the pipeline must be evenly divisible by the current page size. This is
  755. * assured by rounding up to the nearest evenly divisible value. For example, if
  756. * the pipeline size is 4990 and the current page size is 25, then pipeline size will
  757. * be dynamically set to 5000.
  758. *
  759. * The cache windows are computed based on the pipeline size and the total number of rows
  760. * returned by the server side query. For example, with pipeline size 500 and total rows
  761. * 1300, the cache windows will be:
  762. *
  763. * [{'lower': 0, 'upper': 499}, {'lower': 500, 'upper': 999}, {'lower': 1000, 'upper': 1499}]
  764. *
  765. * Using the limit (i.e. the pipelineSize) and offset parameters, the server side request
  766. * **MUST** return only the data in the requested cache window **AND** the total number of rows.
  767. * To wit, the server side code must use the offset and limit parameters to prepare the response
  768. * data.
  769. *
  770. * On a page change, the new offset is checked if it is within the current cache window. If so,
  771. * the requested page data is returned from the cached data set. Otherwise, a new server side
  772. * request will be issued for the new cache window.
  773. *
  774. * The current cached data is only invalidated on these events:
  775. * * sorting
  776. * * searching
  777. * * page size change
  778. * * page change moves into a new cache window
  779. *
  780. * There are two new events:
  781. * - cached-data-hit.bs.table: issued when cached data is used on a page change
  782. * - cached-data-reset.bs.table: issued when the cached data is invalidated and a
  783. * new server side request is issued
  784. *
  785. **/
  786. var Utils = $__default['default'].fn.bootstrapTable.utils;
  787. $__default['default'].extend($__default['default'].fn.bootstrapTable.defaults, {
  788. usePipeline: false,
  789. pipelineSize: 1000,
  790. // eslint-disable-next-line no-unused-vars
  791. onCachedDataHit: function onCachedDataHit(data) {
  792. return false;
  793. },
  794. // eslint-disable-next-line no-unused-vars
  795. onCachedDataReset: function onCachedDataReset(data) {
  796. return false;
  797. }
  798. });
  799. $__default['default'].extend($__default['default'].fn.bootstrapTable.Constructor.EVENTS, {
  800. 'cached-data-hit.bs.table': 'onCachedDataHit',
  801. 'cached-data-reset.bs.table': 'onCachedDataReset'
  802. });
  803. var BootstrapTable = $__default['default'].fn.bootstrapTable.Constructor;
  804. var _init = BootstrapTable.prototype.init;
  805. var _onSearch = BootstrapTable.prototype.onSearch;
  806. var _onSort = BootstrapTable.prototype.onSort;
  807. var _onPageListChange = BootstrapTable.prototype.onPageListChange;
  808. BootstrapTable.prototype.init = function () {
  809. // needs to be called before initServer()
  810. this.initPipeline();
  811. for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
  812. args[_key] = arguments[_key];
  813. }
  814. _init.apply(this, Array.prototype.slice.apply(args));
  815. };
  816. BootstrapTable.prototype.initPipeline = function () {
  817. this.cacheRequestJSON = {};
  818. this.cacheWindows = [];
  819. this.currWindow = 0;
  820. this.resetCache = true;
  821. };
  822. BootstrapTable.prototype.onSearch = function () {
  823. /* force a cache reset on search */
  824. if (this.options.usePipeline) {
  825. this.resetCache = true;
  826. }
  827. _onSearch.apply(this, Array.prototype.slice.apply(arguments));
  828. };
  829. BootstrapTable.prototype.onSort = function () {
  830. /* force a cache reset on sort */
  831. if (this.options.usePipeline) {
  832. this.resetCache = true;
  833. }
  834. _onSort.apply(this, Array.prototype.slice.apply(arguments));
  835. };
  836. BootstrapTable.prototype.onPageListChange = function (event) {
  837. /* rebuild cache window on page size change */
  838. var target = $__default['default'](event.currentTarget);
  839. var newPageSize = parseInt(target.text(), 10);
  840. this.options.pipelineSize = this.calculatePipelineSize(this.options.pipelineSize, newPageSize);
  841. this.resetCache = true;
  842. _onPageListChange.apply(this, Array.prototype.slice.apply(arguments));
  843. };
  844. BootstrapTable.prototype.calculatePipelineSize = function (pipelineSize, pageSize) {
  845. /* calculate pipeline size by rounding up to the nearest value evenly divisible
  846. * by the pageSize */
  847. if (pageSize === 0) return 0;
  848. return Math.ceil(pipelineSize / pageSize) * pageSize;
  849. };
  850. BootstrapTable.prototype.setCacheWindows = function () {
  851. /* set cache windows based on the total number of rows returned by server side
  852. * request and the pipelineSize */
  853. this.cacheWindows = [];
  854. var numWindows = this.options.totalRows / this.options.pipelineSize;
  855. for (var i = 0; i <= numWindows; i++) {
  856. var b = i * this.options.pipelineSize;
  857. this.cacheWindows[i] = {
  858. lower: b,
  859. upper: b + this.options.pipelineSize - 1
  860. };
  861. }
  862. };
  863. BootstrapTable.prototype.setCurrWindow = function (offset) {
  864. /* set the current cache window index, based on where the current offset falls */
  865. this.currWindow = 0;
  866. for (var i = 0; i < this.cacheWindows.length; i++) {
  867. if (this.cacheWindows[i].lower <= offset && offset <= this.cacheWindows[i].upper) {
  868. this.currWindow = i;
  869. break;
  870. }
  871. }
  872. };
  873. BootstrapTable.prototype.drawFromCache = function (offset, limit) {
  874. /* draw rows from the cache using offset and limit */
  875. var res = $__default['default'].extend(true, {}, this.cacheRequestJSON);
  876. var drawStart = offset - this.cacheWindows[this.currWindow].lower;
  877. var drawEnd = drawStart + limit;
  878. res.rows = res.rows.slice(drawStart, drawEnd);
  879. return res;
  880. };
  881. BootstrapTable.prototype.initServer = function (silent, query, url) {
  882. /* determine if requested data is in cache (on paging) or if
  883. * a new ajax request needs to be issued (sorting, searching, paging
  884. * moving outside of cached data, page size change)
  885. * initial version of this extension will entirely override base initServer
  886. **/
  887. var data = {};
  888. var index = this.header.fields.indexOf(this.options.sortName);
  889. var params = {
  890. searchText: this.searchText,
  891. sortName: this.options.sortName,
  892. sortOrder: this.options.sortOrder
  893. };
  894. var request = null;
  895. if (this.header.sortNames[index]) {
  896. params.sortName = this.header.sortNames[index];
  897. }
  898. if (this.options.pagination && this.options.sidePagination === 'server') {
  899. params.pageSize = this.options.pageSize === this.options.formatAllRows() ? this.options.totalRows : this.options.pageSize;
  900. params.pageNumber = this.options.pageNumber;
  901. }
  902. if (!(url || this.options.url) && !this.options.ajax) {
  903. return;
  904. }
  905. var useAjax = true;
  906. if (this.options.queryParamsType === 'limit') {
  907. params = {
  908. searchText: params.searchText,
  909. sortName: params.sortName,
  910. sortOrder: params.sortOrder
  911. };
  912. if (this.options.pagination && this.options.sidePagination === 'server') {
  913. params.limit = this.options.pageSize === this.options.formatAllRows() ? this.options.totalRows : this.options.pageSize;
  914. params.offset = (this.options.pageSize === this.options.formatAllRows() ? this.options.totalRows : this.options.pageSize) * (this.options.pageNumber - 1);
  915. if (this.options.usePipeline) {
  916. // if cacheWindows is empty, this is the initial request
  917. if (!this.cacheWindows.length) {
  918. useAjax = true;
  919. params.drawOffset = params.offset; // cache exists: determine if the page request is entirely within the current cached window
  920. } else {
  921. var w = this.cacheWindows[this.currWindow]; // case 1: reset cache but stay within current window (e.g. column sort)
  922. // case 2: move outside of the current window (e.g. search or paging)
  923. // since each cache window is aligned with the current page size
  924. // checking if params.offset is outside the current window is sufficient.
  925. // need to requery for preceding or succeeding cache window
  926. // also handle case
  927. if (this.resetCache || params.offset < w.lower || params.offset > w.upper) {
  928. useAjax = true;
  929. this.setCurrWindow(params.offset); // store the relative offset for drawing the page data afterwards
  930. params.drawOffset = params.offset; // now set params.offset to the lower bound of the new cache window
  931. // the server will return that whole cache window
  932. params.offset = this.cacheWindows[this.currWindow].lower; // within current cache window
  933. } else {
  934. useAjax = false;
  935. }
  936. }
  937. } else if (params.limit === 0) {
  938. delete params.limit;
  939. }
  940. }
  941. } // force an ajax call - this is on search, sort or page size change
  942. if (this.resetCache) {
  943. useAjax = true;
  944. this.resetCache = false;
  945. }
  946. if (this.options.usePipeline && useAjax) {
  947. /* in this scenario limit is used on the server to get the cache window
  948. * and drawLimit is used to get the page data afterwards */
  949. params.drawLimit = params.limit;
  950. params.limit = this.options.pipelineSize;
  951. } // cached results can be used
  952. if (!useAjax) {
  953. var res = this.drawFromCache(params.offset, params.limit);
  954. this.load(res);
  955. this.trigger('load-success', res);
  956. this.trigger('cached-data-hit', res);
  957. return;
  958. } // cached results can't be used
  959. // continue base initServer code
  960. if (!$__default['default'].isEmptyObject(this.filterColumnsPartial)) {
  961. params.filter = JSON.stringify(this.filterColumnsPartial, null);
  962. }
  963. data = Utils.calculateObjectValue(this.options, this.options.queryParams, [params], data);
  964. $__default['default'].extend(data, query || {}); // false to stop request
  965. if (data === false) {
  966. return;
  967. }
  968. if (!silent) {
  969. this.$tableLoading.show();
  970. }
  971. var self = this;
  972. request = $__default['default'].extend({}, Utils.calculateObjectValue(null, this.options.ajaxOptions), {
  973. type: this.options.method,
  974. url: url || this.options.url,
  975. data: this.options.contentType === 'application/json' && this.options.method === 'post' ? JSON.stringify(data) : data,
  976. cache: this.options.cache,
  977. contentType: this.options.contentType,
  978. dataType: this.options.dataType,
  979. success: function success(res) {
  980. res = Utils.calculateObjectValue(self.options, self.options.responseHandler, [res], res); // cache results if using pipelining
  981. if (self.options.usePipeline) {
  982. // store entire request in cache
  983. self.cacheRequestJSON = $__default['default'].extend(true, {}, res); // this gets set in load() also but needs to be set before
  984. // setting cacheWindows
  985. self.options.totalRows = res[self.options.totalField]; // if this is a search, potentially less results will be returned
  986. // so cache windows need to be rebuilt. Otherwise it
  987. // will come out the same
  988. self.setCacheWindows();
  989. self.setCurrWindow(params.drawOffset); // just load data for the page
  990. res = self.drawFromCache(params.drawOffset, params.drawLimit);
  991. self.trigger('cached-data-reset', res);
  992. }
  993. self.load(res);
  994. self.trigger('load-success', res);
  995. if (!silent) self.$tableLoading.hide();
  996. },
  997. error: function error(res) {
  998. var data = [];
  999. if (self.options.sidePagination === 'server') {
  1000. data = {};
  1001. data[self.options.totalField] = 0;
  1002. data[self.options.dataField] = [];
  1003. }
  1004. self.load(data);
  1005. self.trigger('load-error', res.status, res);
  1006. if (!silent) self.$tableLoading.hide();
  1007. }
  1008. });
  1009. if (this.options.ajax) {
  1010. Utils.calculateObjectValue(this, this.options.ajax, [request], null);
  1011. } else {
  1012. if (this._xhr && this._xhr.readyState !== 4) {
  1013. this._xhr.abort();
  1014. }
  1015. this._xhr = $__default['default'].ajax(request);
  1016. }
  1017. };
  1018. })));