nps/web/static/js/bootstrap-table.min.js

10 lines
66 KiB
Go
Raw Normal View History

/**
* bootstrap-table - An extended Bootstrap table with radio, checkbox, sort, pagination, and other added features. (supports twitter bootstrap v2 and v3).
*
* @version v1.13.5
* @homepage https://bootstrap-table.com
* @author wenzhixin <wenzhixin2010@gmail.com> (http://wenzhixin.net.cn/)
* @license MIT
*/
(function(e,t){if('function'==typeof define&&define.amd)define([],t);else if('undefined'!=typeof exports)t();else{t(),e.bootstrapTable={exports:{}}.exports}})(this,function(){'use strict';function e(e,t){if(!(e instanceof t))throw new TypeError('Cannot call a class as a function')}function t(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);t<e.length;t++)o[t]=e[t];return o}return Array.from(e)}var o=function(){function e(e,t){for(var o,a=0;a<t.length;a++)o=t[a],o.enumerable=o.enumerable||!1,o.configurable=!0,'value'in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}return function(t,o,i){return o&&e(t.prototype,o),i&&e(t,i),t}}(),i=function(){function e(e,t){var o=[],i=!0,a=!1,n=void 0;try{for(var s,l=e[Symbol.iterator]();!(i=(s=l.next()).done)&&(o.push(s.value),!(t&&o.length===t));i=!0);}catch(e){a=!0,n=e}finally{try{!i&&l['return']&&l['return']()}finally{if(a)throw n}}return o}return function(t,o){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,o);throw new TypeError('Invalid attempt to destructure non-iterable instance')}}(),a='function'==typeof Symbol&&'symbol'==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&'function'==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?'symbol':typeof e};(function(n){var s=3;try{var g=n.fn.dropdown.Constructor.VERSION;g!==void 0&&(s=parseInt(g,10))}catch(t){}var l={3:{iconsPrefix:'glyphicon',icons:{paginationSwitchDown:'glyphicon-collapse-down icon-chevron-down',paginationSwitchUp:'glyphicon-collapse-up icon-chevron-up',refresh:'glyphicon-refresh icon-refresh',toggleOff:'glyphicon-list-alt icon-list-alt',toggleOn:'glyphicon-list-alt icon-list-alt',columns:'glyphicon-th icon-th',detailOpen:'glyphicon-plus icon-plus',detailClose:'glyphicon-minus icon-minus',fullscreen:'glyphicon-fullscreen'},classes:{buttons:'default',pull:'pull'},html:{toobarDropdow:['<ul class="dropdown-menu" role="menu">','</ul>'],toobarDropdowItem:'<li role="menuitem"><label>%s</label></li>',pageDropdown:['<ul class="dropdown-menu" role="menu">','</ul>'],pageDropdownItem:'<li role="menuitem" class="%s"><a href="#">%s</a></li>'}},4:{iconsPrefix:'fa',icons:{paginationSwitchDown:'fa-caret-square-down',paginationSwitchUp:'fa-caret-square-up',refresh:'fa-sync',toggleOff:'fa-toggle-off',toggleOn:'fa-toggle-on',columns:'fa-th-list',detailOpen:'fa-plus',detailClose:'fa-minus',fullscreen:'fa-arrows-alt'},classes:{buttons:'secondary',pull:'float'},html:{toobarDropdow:['<div class="dropdown-menu dropdown-menu-right">','</div>'],toobarDropdowItem:'<label class="dropdown-item">%s</label>',pageDropdown:['<div class="dropdown-menu">','</div>'],pageDropdownItem:'<a class="dropdown-item %s" href="#">%s</a>'}}}[s],r={bootstrapVersion:s,sprintf:function(e){for(var t=arguments.length,o=Array(1<t?t-1:0),a=1;a<t;a++)o[a-1]=arguments[a];var n=!0,s=0,i=e.replace(/%s/g,function(){var e=o[s++];return'undefined'==typeof e?(n=!1,''):e});return n?i:''},getFieldTitle:function(e,t){for(var o=e,i=Array.isArray(o),a=0,_iterator=i?o:o[Symbol.iterator]();;){var n;if(i){if(a>=o.length)break;n=o[a++]}else{if(a=o.next(),a.done)break;n=a.value}var s=n;if(s.field===t)return s.title}return''},setFieldIndex:function(e){for(var t=0,o=[],a=e[0],n=Array.isArray(a),s=0,_iterator2=n?a:a[Symbol.iterator]();;){var l;if(n){if(s>=a.length)break;l=a[s++]}else{if(s=a.next(),s.done)break;l=s.value}var d=l;t+=d.colspan||1}for(var m=0;m<e.length;m++){o[m]=[];for(var i=0;i<t;i++)o[m][i]=!1}for(var y=0;y<e.length;y++)for(var p=e[y],c=Array.isArray(p),h=0,_iterator3=c?p:p[Symbol.iterator]();;){var g;if(c){if(h>=p.length)break;g=p[h++]}else{if(h=p.next(),h.done)break;g=h.value}var u=g,r=u.rowspan||1,f=u.colspan||1,b=o[y].indexOf(!1);1===f&&(u.fieldIndex=b,'undefined'==typeof u.field&&(u.field=b));for(var w=0;w<r;w++)o[y+w][b]=!0;for(var k=0;k<f;k++)o[y][b+k]=!0}},getScrollBarWidth:function(){if(this.cachedWidth===void 0){var e=n('<div/>').addClass('fixed-table-scroll-inner'),t=n('<div/>').addClass('fixed-table-scroll-outer');t.append(e),n('body').append(t);var o=e[0].offsetWidth;t.css('overflow','scroll'