src/KopSoftWms/wwwroot/js/bootstrap.table.min.js

(完整代码) 94KB

/*!
 * Bootstrap v3.3.7 (http://getbootstrap.com)
 * Copyright 2011-2016 Twitter, Inc.
 * Licensed under the MIT license
 */
if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");+function(n){"use strict";var t=n.fn.jquery.split(" ")[0].split(".");if(t[0]<2&&t[1]<9||1==t[0]&&9==t[1]&&t[2]<1||t[0]>3)throw new Error("Bootstrap's JavaScript requires jQuery version 1.9.1 or higher, but lower than version 4");}(jQuery);+function(n){"use strict";function t(){var i=document.createElement("bootstrap"),n={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var t in n)if(void 0!==i.style[t])return{end:n[t]};return!1}n.fn.emulateTransitionEnd=function(t){var i=!1,u=this,r;n(this).one("bsTransitionEnd",function(){i=!0});return r=function(){i||n(u).trigger(n.support.transition.end)},setTimeout(r,t),this};n(function(){n.support.transition=t();n.support.transition&&(n.event.special.bsTransitionEnd={bindType:n.support.transition.end,delegateType:n.support.transition.end,handle:function(t){if(n(t.target).is(this))return t.handleObj.handler.apply(this,arguments)}})})}(jQuery);+function(n){"use strict";function u(i){return this.each(function(){var r=n(this),u=r.data("bs.alert");u||r.data("bs.alert",u=new t(this));"string"==typeof i&&u[i].call(r)})}var i='[data-dismiss="alert"]',t=function(t){n(t).on("click",i,this.close)},r;t.VERSION="3.3.7";t.TRANSITION_DURATION=150;t.prototype.close=function(i){function e(){r.detach().trigger("closed.bs.alert").remove()}var f=n(this),u=f.attr("data-target"),r;u||(u=f.attr("href"),u=u&&u.replace(/.*(?=#[^\s]*$)/,""));r=n("#"===u?[]:u);i&&i.preventDefault();r.length||(r=f.closest(".alert"));r.trigger(i=n.Event("close.bs.alert"));i.isDefaultPrevented()||(r.removeClass("in"),n.support.transition&&r.hasClass("fade")?r.one("bsTransitionEnd",e).emulateTransitionEnd(t.TRANSITION_DURATION):e())};r=n.fn.alert;n.fn.alert=u;n.fn.alert.Constructor=t;n.fn.alert.noConflict=function(){return n.fn.alert=r,this};n(document).on("click.bs.alert.data-api",i,t.prototype.close)}(jQuery);+function(n){"use strict";function i(i){return this.each(function(){var u=n(this),r=u.data("bs.button"),f="object"==typeof i&&i;r||u.data("bs.button",r=new t(this,f));"toggle"==i?r.toggle():i&&r.setState(i)})}var t=function(i,r){this.$element=n(i);this.options=n.extend({},t.DEFAULTS,r);this.isLoading=!1},r;t.VERSION="3.3.7";t.DEFAULTS={loadingText:"loading..."};t.prototype.setState=function(t){var i="disabled",r=this.$element,f=r.is("input")?"val":"html",u=r.data();t+="Text";null==u.resetText&&r.data("resetText",r[f]());setTimeout(n.proxy(function(){r[f](null==u[t]?this.options[t]:u[t]);"loadingText"==t?(this.isLoading=!0,r.addClass(i).attr(i,i).prop(i,!0)):this.isLoading&&(this.isLoading=!1,r.removeClass(i).removeAttr(i).prop(i,!1))},this),0)};t.prototype.toggle=function(){var t=!0,i=this.$element.closest('[data-toggle="buttons"]'),n;i.length?(n=this.$element.find("input"),"radio"==n.prop("type")?(n.prop("checked")&&(t=!1),i.find(".active").removeClass("active"),this.$element.addClass("active")):"checkbox"==n.prop("type")&&(n.prop("checked")!==this.$element.hasClass("active")&&(t=!1),this.$element.toggleClass("active")),n.prop("checked",this.$element.hasClass("active")),t&&n.trigger("change")):(this.$element.attr("aria-pressed",!this.$element.hasClass("active")),this.$element.toggleClass("active"))};r=n.fn.button;n.fn.button=i;n.fn.button.Constructor=t;n.fn.button.noConflict=function(){return n.fn.button=r,this};n(document).on("click.bs.button.data-api",'[data-toggle^="button"]',function(t){var r=n(t.target).closest(".btn");i.call(r,"toggle");n(t.target).is('input[type="radio"], input[type="checkbox"]')||(t.preventDefault(),r.is("input,button")?r.trigger("focus"):r.find("input:visible,button:visible").first().trigger("focus"))}).on("focus.bs.button.data-api blur.bs.button.data-api",'[data-toggle^="button"]',function(t){n(t.target).closest(".btn").toggleClass("focus",/^focus(in)?$/.test(t.type))})}(jQuery);+function(n){"use strict";function i(i){return this.each(function(){var u=n(this),r=u.data("bs.carousel"),f=n.extend({},t.DEFAULTS,u.data(),"object"==typeof i&&i),e="string"==typeof i?i:f.slide;r||u.data("bs.carousel",r=new t(this,f));"number"==typeof i?r.to(i):e?r[e]():f.interval&&r.pause().cycle()})}var t=function(t,i){this.$element=n(t);this.$indicators=this.$element.find(".carousel-indicators");this.options=i;this.paused=null;this.sliding=null;this.interval=null;this.$active=null;this.$items=null;this.options.keyboard&&this.$element.on("keydown.bs.carousel",n.proxy(this.keydown,this));"hover"==this.options.pause&&!("ontouchstart"in document.documentElement)&&this.$element.on("mouseenter.bs.carousel",n.proxy(this.pause,this)).on("mouseleave.bs.carousel",n.proxy(this.cycle,this))},u,r;t.VERSION="3.3.7";t.TRANSITION_DURATION=600;t.DEFAULTS={interval:5e3,pause:"hover",wrap:!0,keyboard:!0};t.prototype.keydown=function(n){if(!/input|textarea/i.test(n.target.tagName)){switch(n.which){case 37:this.prev();break;case 39:this.next();break;default:return}n.preventDefault()}};t.prototype.cycle=function(t){return t||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(n.proxy(this.next,this),this.options.interval)),this};t.prototype.getItemIndex=function(n){return this.$items=n.parent().children(".item"),this.$items.index(n||this.$active)};t.prototype.getItemForDirection=function(n,t){var i=this.getItemIndex(t),f="prev"==n&&0===i||"next"==n&&i==this.$items.length-1,r,u;return f&&!this.options.wrap?t:(r="prev"==n?-1:1,u=(i+r)%this.$items.length,this.$items.eq(u))};t.prototype.to=function(n){var i=this,t=this.getItemIndex(this.$active=this.$element.find(".item.active"));if(!(n>this.$items.length-1||n<0))return this.sliding?this.$element.one("slid.bs.carousel",function(){i.to(n)}):t==n?this.pause().cycle():this.slide(n>t?"next":"prev",this.$items.eq(n))};t.prototype.pause=function(t){return t||(this.paused=!0),this.$element.find(".next, .prev").length&&n.support.transition&&(this.$element.trigger(n.support.transition.end),this.cycle(!0)),this.interval=clearInterval(this.interval),this};t.prototype.next=function(){if(!this.sliding)return this.slide("next")};t.prototype.prev=function(){if(!this.sliding)return this.slide("prev")};t.prototype.slide=function(i,r){var e=this.$element.find(".item.active"),u=r||this.getItemForDirection(i,e),l=this.interval,f="next"==i?"left":"right",a=this,o,s,h,c;return u.hasClass("active")?this.sliding=!1:(o=u[0],s=n.Event("slide.bs.carousel",{relatedTarget:o,direction:f}),(this.$element.trigger(s),!s.isDefaultPrevented())?((this.sliding=!0,l&&this.pause(),this.$indicators.length)&&(this.$indicators.find(".active").removeClass("active"),h=n(this.$indicators.children()[this.getItemIndex(u)]),h&&h.addClass("active")),c=n.Event("slid.bs.carousel",{relatedTarget:o,direction:f}),n.support.transition&&this.$element.hasClass("slide")?(u.addClass(i),u[0].offsetWidth,e.addClass(f),u.addClass(f),e.one("bsTransitionEnd",function(){u.removeClass([i,f].join(" ")).addClass("active");e.removeClass(["active",f].join(" "));a.sliding=!1;setTimeout(function(){a.$element.trigger(c)},0)}).emulateTransitionEnd(t.TRANSITION_DURATION)):(e.removeClass("active"),u.addClass("active"),this.sliding=!1,this.$element.trigger(c)),l&&this.cycle(),this):void 0)};u=n.fn.carousel;n.fn.carousel=i;n.fn.carousel.Constructor=t;n.fn.carousel.noConflict=function(){return n.fn.carousel=u,this};r=function(t){var o,r=n(this),u=n(r.attr("data-target")||(o=r.attr("href"))&&o.replace(/.*(?=#[^\s]+$)/,"")),e,f;u.hasClass("carousel")&&(e=n.extend({},u.data(),r.data()),f=r.attr("data-slide-to"),f&&(e.interval=!1),i.call(u,e),f&&u.data("bs.carousel").to(f),t.preventDefault())};n(document).on("click.bs.carousel.data-api","[data-slide]",r).on("click.bs.carousel.data-api","[data-slide-to]",r);n(window).on("load",function(){n('[data-ride="carousel"]').each(function(){var t=n(this);i.call(t,t.data())})})}(jQuery);+function(n){"use strict";function r(t){var i,r=t.attr("data-target")||(i=t.attr("href"))&&i.replace(/.*(?=#[^\s]+$)/,"");return n(r)}function i(i){return this.each(function(){var u=n(this),r=u.data("bs.collapse"),f=n.extend({},t.DEFAULTS,u.data(),"object"==typeof i&&i);!r&&f.toggle&&/show|hide/.test(i)&&(f.toggle=!1);r||u.data("bs.collapse",r=new t(this,f));"string"==typeof i&&r[i]()})}var t=function(i,r){this.$element=n(i);this.options=n.extend({},t.DEFAULTS,r);this.$trigger=n('[data-toggle="collapse"][href="#'+i.id+'"],[data-toggle="collapse"][data-target="#'+i.id+'"]');this.transitioning=null;this.options.parent?this.$parent=this.getParent():this.addAriaAndCollapsedClass(this.$element,this.$trigger);this.options.toggle&&this.toggle()},u;t.VERSION="3.3.7";t.TRANSITION_DURATION=350;t.DEFAULTS={toggle:!0};t.prototype.dimension=function(){var n=this.$element.hasClass("width");return n?"width":"height"};t.prototype.show=function(){var f,r,e,u,o,s;if(!this.transitioning&&!this.$element.hasClass("in")&&(r=this.$parent&&this.$parent.children(".panel").children(".in, .collapsing"),!(r&&r.length&&(f=r.data("bs.collapse"),f&&f.transitioning))&&(e=n.Event("show.bs.collapse"),this.$element.trigger(e),!e.isDefaultPrevented()))){if(r&&r.length&&(i.call(r,"hide"),f||r.data("bs.collapse",null)),u=this.dimension(),this.$element.removeClass("collapse").addClass("collapsing")[u](0).attr("aria-expanded",!0),this.$trigger.removeClass("collapsed").attr("aria-expanded",!0),this.transitioning=1,o=function(){this.$element.removeClass("collapsing").addClass("collapse in")[u]("");this.transitioning=0;this.$element.trigger("shown.bs.collapse")},!n.support.transition)return o.call(this);s=n.camelCase(["scroll",u].join("-"));this.$element.one("bsTransitionEnd",n.proxy(o,this)).emulateTransitionEnd(t.TRANSITION_DURATION)[u](this.$element[0][s])}};t.prototype.hide=function(){var r,i,u;if(!this.transitioning&&this.$element.hasClass("in")&&(r=n.Event("hide.bs.collapse"),this.$element.trigger(r),!r.isDefaultPrevented()))return i=this.dimension(),this.$element[i](this.$element[i]())[0].offsetHeight,this.$element.addClass("collapsing").removeClass("collapse in").attr("aria-expanded",!1),this.$trigger.addClass("collapsed").attr("aria-expanded",!1),this.transitioning=1,u=function(){this.transitioning=0;this.$element.removeClass("collapsing").addClass("collapse").trigger("hidden.bs.collapse")},n.support.transition?void this.$element[i](0).one("bsTransitionEnd",n.proxy(u,this)).emulateTransitionEnd(t.TRANSITION_DURATION):u.call(this)};t.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()};t.prototype.getParent=function(){return n(this.options.parent).find('[data-toggle="collapse"][data-parent="'+this.options.parent+'"]').each(n.proxy(function(t,i){var u=n(i);this.addAriaAndCollapsedClass(r(u),u)},this)).end()};t.prototype.addAriaAndCollapsedClass=function(n,t){var i=n.hasClass("in");n.attr("aria-expanded",i);t.toggleClass("collapsed",!i).attr("aria-expanded",i)};u=n.fn.collapse;n.fn.collapse=i;n.fn.collapse.Constructor=t;n.fn.collapse.noConflict=function(){return n.fn.collapse=u,this};n(document).on("click.bs.collapse.data-api",'[data-toggle="collapse"]',function(t){var u=n(this);u.attr("data-target")||t.preventDefault();var f=r(u),e=f.data("bs.collapse"),o=e?"toggle":u.data();i.call(f,o)})}(jQuery);+function(n){"use strict";function r(t){var i=t.attr("data-target"),r;return i||(i=t.attr("href"),i=i&&/#[A-Za-z]/.test(i)&&i.replace(/.*(?=#[^\s]*$)/,"")),r=i&&n(i),r&&r.length?r:t.parent()}function u(t){t&&3===t.which||(n(o).remove(),n(i).each(function(){var u=n(this),i=r(u),f={relatedTarget:this};i.hasClass("open")&&(t&&"click"==t.type&&/input|textarea/i.test(t.target.tagName)&&n.contains(i[0],t.target)||(i.trigger(t=n.Event("hide.bs.dropdown",f)),t.isDefaultPrevented()||(u.attr("aria-expanded","false"),i.removeClass("open").trigger(n.Event("hidden.bs.dropdown",f)))))}))}function e(i){return this.each(function(){var r=n(this),u=r.data("bs.dropdown");u||r.data("bs.dropdown",u=new t(this));"string"==typeof i&&u[i].call(r)})}var o=".dropdown-backdrop",i='[data-toggle="dropdown"]',t=function(t){n(t).on("click.bs.dropdown",this.toggle)},f;t.VERSION="3.3.7";t.prototype.toggle=function(t){var f=n(this),i,o,e;if(!f.is(".disabled, :disabled")){if(i=r(f),o=i.hasClass("open"),u(),!o){if("ontouchstart"in document.documentElement&&!i.closest(".navbar-nav").length&&n(document.createElement("div")).addClass("dropdown-backdrop").insertAfter(n(this)).on("click",u),e={relatedTarget:this},i.trigger(t=n.Event("show.bs.dropdown",e)),t.isDefaultPrevented())return;f.trigger("focus").attr("aria-expanded","true");i.toggleClass("open").trigger(n.Event("shown.bs.dropdown",e))}return!1}};t.prototype.keydown=function(t){var e,o,s,h,f,u;if(/(38|40|27|32)/.test(t.which)&&!/input|textarea/i.test(t.target.tagName)&&(e=n(this),t.preventDefault(),t.stopPropagation(),!e.is(".disabled, :disabled"))){if(o=r(e),s=o.hasClass("open"),!s&&27!=t.which||s&&27==t.which)return 27==t.which&&o.find(i).trigger("focus"),e.trigger("click");h=" li:not(.disabled):visible a";f=o.find(".dropdown-menu"+h);f.length&&(u=f.index(t.target),38==t.which&&u>0&&u--,40==t.which&&u<f.length-1&&u++,~u||(u=0),f.eq(u).trigger("focus"))}};f=n.fn.dropdown;n.fn.dropdown=e;n.fn.dropdown.Constructor=t;n.fn.dropdown.noConflict=function(){return n.fn.dropdown=f,this};n(document).on("click.bs.dropdown.data-api",u).on("click.bs.dropdown.data-api",".dropdown form",function(n){n.stopPropagation()}).on("click.bs.dropdown.data-api",i,t.prototype.toggle).on("keydown.bs.dropdown.data-api",i,t.prototype.keydown).on("keydown.bs.dropdown.data-api",".dropdown-menu",t.prototype.keydown)}(jQuery);+function(n){"use strict";function i(i,r){return this.each(function(){var f=n(this),u=f.data("bs.modal"),e=n.extend({},t.DEFAULTS,f.data(),"object"==typeof i&&i);u||f.data("bs.modal",u=new t(this,e));"string"==typeof i?u[i](r):e.show&&u.show(r)})}var t=function(t,i){this.options=i;this.$body=n(document.body);this.$element=n(t);this.$dialog=this.$element.find(".modal-dialog");this.$backdrop=null;this.isShown=null;this.originalBodyPad=null;this.scrollbarWidth=0;this.ignoreBackdropClick=!1;this.options.remote&&this.$element.find(".modal-content").load(this.options.remote,n.proxy(function(){this.$element.trigger("loaded.bs.modal")},this))},r;t.VERSION="3.3.7";t.TRANSITION_DURATION=300;t.BACKDROP_TRANSITION_DURATION=150;t.DEFAULTS={backdrop:!0,keyboard:!0,show:!0};t.prototype.toggle=function(n){return this.isShown?this.hide():this.show(n)};t.prototype.show=function(i){var r=this,u=n.Event("show.bs.modal",{relatedTarget:i});this.$element.trigger(u);this.isShown||u.isDefaultPrevented()||(this.isShown=!0,this.checkScrollbar(),this.setScrollbar(),this.$body.addClass("modal-open"),this.escape(),this.resize(),this.$element.on("click.dismiss.bs.modal",'[data-dismiss="modal"]',n.proxy(this.hide,this)),this.$dialog.on("mousedown.dismiss.bs.modal",function(){r.$element.one("mouseup.dismiss.bs.modal",function(t){n(t.target).is(r.$element)&&(r.ignoreBackdropClick=!0)})}),this.backdrop(function(){var f=n.support.transition&&r.$element.hasClass("fade"),u;r.$element.parent().length||r.$element.appendTo(r.$body);r.$element.show().scrollTop(0);r.adjustDialog();f&&r.$element[0].offsetWidth;r.$element.addClass("in");r.enforceFocus();u=n.Event("shown.bs.modal",{relatedTarget:i});f?r.$dialog.one("bsTransitionEnd",function(){r.$element.trigger("focus").trigger(u)}).emulateTransitionEnd(t.TRANSITION_DURATION):r.$element.trigger("focus").trigger(u)}))};t.prototype.hide=function(i){i&&i.preventDefault();i=n.Event("hide.bs.modal");this.$element.trigger(i);this.isShown&&!i.isDefaultPrevented()&&(this.isShown=!1,this.escape(),this.resize(),n(document).off("focusin.bs.modal"),this.$element.removeClass("in").off("click.dismiss.bs.modal").off("mouseup.dismiss.bs.modal"),this.$dialog.off("mousedown.dismiss.bs.modal"),n.support.transition&&this.$element.hasClass("fade")?this.$element.one("bsTransitionEnd",n.proxy(this.hideModal,this)).emulateTransitionEnd(t.TRANSITION_DURATION):this.hideModal())};t.prototype.enforceFocus=function(){n(document).off("focusin.bs.modal").on("focusin.bs.modal",n.proxy(function(n){document===n.target||this.$element[0]===n.target||this.$element.has(n.target).length||this.$element.trigger("focus")},this))};t.prototype.escape=function(){this.isShown&&this.options.keyboard?this.$element.on("keydown.dismiss.bs.modal",n.proxy(function(n){27==n.which&&this.hide()},this)):this.isShown||this.$element.off("keydown.dismiss.bs.modal")};t.prototype.resize=function(){this.isShown?n(window).on("resize.bs.modal",n.proxy(this.handleUpdate,this)):n(window).off("resize.bs.modal")};t.prototype.hideModal=function(){var n=this;this.$element.hide();this.backdrop(function(){n.$body.removeClass("modal-open");n.resetAdjustments();n.resetScrollbar();n.$element.trigger("hidden.bs.modal")})};t.prototype.removeBackdrop=function(){this.$backdrop&&this.$backdrop.remove();this.$backdrop=null};t.prototype.backdrop=function(i){var e=this,f=this.$element.hasClass("fade")?"fade":"",r,u;if(this.isShown&&this.options.backdrop){if(r=n.support.transition&&f,this.$backdrop=n(document.createElement("div")).addClass("modal-backdrop "+f).appendTo(this.$body),this.$element.on("click.dismiss.bs.modal",n.proxy(function(n){return this.ignoreBackdropClick?void(this.ignoreBackdropClick=!1):void(n.target===n.currentTarget&&("static"==this.options.backdrop?this.$element[0].focus():this.hide()))},this)),r&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in"),!i)return;r?this.$backdrop.one("bsTransitionEnd",i).emulateTransitionEnd(t.BACKDROP_TRANSITION_DURATION):i()}else!this.isShown&&this.$backdrop?(this.$backdrop.removeClass("in"),u=function(){e.removeBackdrop();i&&i()},n.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one("bsTransitionEnd",u).emulateTransitionEnd(t.BACKDROP_TRANSITION_DURATION):u()):i&&i()};t.prototype.handleUpdate=function(){this.adjustDialog()};t.prototype.adjustDialog=function(){var n=this.$element[0].scrollHeight>document.documentElement.clientHeight;this.$element.css({paddingLeft:!this.bodyIsOverflowing&&n?this.scrollbarWidth:"",paddingRight:this.bodyIsOverflowing&&!n?this.scrollbarWidth:""})};t.prototype.resetAdjustments=function(){this.$element.css({paddingLeft:"",paddingRight:""})};t.prototype.checkScrollbar=function(){var n=window.innerWidth,t;n||(t=document.documentElement.getBoundingClientRect(),n=t.right-Math.abs(t.left));this.bodyIsOverflowing=document.body.clientWidth<n;this.scrollbarWidth=this.measureScrollbar()};t.prototype.setScrollbar=function(){var n=parseInt(this.$body.css("padding-right")||0,10);this.originalBodyPad=document.body.style.paddingRight||"";this.bodyIsOverflowing&&this.$body.css("padding-right",n+this.scrollbarWidth)};t.prototype.resetScrollbar=function(){this.$body.css("padding-right",this.originalBodyPad)};t.prototype.measureScrollbar=function(){var n=document.createElement("div"),t;return n.className="modal-scrollbar-measure",this.$body.append(n),t=n.offsetWidth-n.clientWidth,this.$body[0].removeChild(n),t};r=n.fn.modal;n.fn.modal=i;n.fn.modal.Constructor=t;n.fn.modal.noConflict=function(){return n.fn.modal=r,this};n(document).on("click.bs.modal.data-api",'[data-toggle="modal"]',function(t){var r=n(this),f=r.attr("href"),u=n(r.attr("data-target")||f&&f.replace(/.*(?=#[^\s]+$)/,"")),e=u.data("bs.modal")?"toggle":n.extend({remote:!/#/.test(f)&&f},u.data(),r.data());r.is("a")&&t.preventDefault();u.one("show.bs.modal",function(n){n.isDefaultPrevented()||u.one("hidden.bs.modal",function(){r.is(":visible")&&r.trigger("focus")})});i.call(u,e,this)})}(jQuery);+function(n){"use strict";function r(i){return this.each(function(){var u=n(this),r=u.data("bs.tooltip"),f="object"==typeof i&&i;!r&&/destroy|hide/.test(i)||(r||u.data("bs.tooltip",r=new t(this,f)),"string"==typeof i&&r[i]())})}var t=function(n,t){this.type=null;this.options=null;this.enabled=null;this.timeout=null;this.hoverState=null;this.$element=null;this.inState=null;this.init("tooltip",n,t)},i;t.VERSION="3.3.7";t.TRANSITION_DURATION=150;t.DEFAULTS={animation:!0,placement:"top",selector:!1,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"><\/div><div class="tooltip-inner"><\/div><\/div>',trigger:"hover focus",title:"",delay:0,html:!1,container:!1,viewport:{selector:"body",padding:0}};t.prototype.init=function(t,i,r){var f,e,u,o,s;if(this.enabled=!0,this.type=t,this.$element=n(i),this.options=this.getOptions(r),this.$viewport=this.options.viewport&&n(n.isFunction(this.options.viewport)?this.options.viewport.call(this,this.$element):this.options.viewport.selector||this.options.viewport),this.inState={click:!1,hover:!1,focus:!1},this.$element[0]instanceof document.constructor&&!this.options.selector)throw new Error("`selector` option must be specified when initializing "+this.type+" on the window.document object!");for(f=this.options.trigger.split(" "),e=f.length;e--;)if(u=f[e],"click"==u)this.$element.on("click."+this.type,this.options.selector,n.proxy(this.toggle,this));else"manual"!=u&&(o="hover"==u?"mouseenter":"focusin",s="hover"==u?"mouseleave":"focusout",this.$element.on(o+"."+this.type,this.options.selector,n.proxy(this.enter,this)),this.$element.on(s+"."+this.type,this.options.selector,n.proxy(this.leave,this)));this.options.selector?this._options=n.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()};t.prototype.getDefaults=function(){return t.DEFAULTS};t.prototype.getOptions=function(t){return t=n.extend({},this.getDefaults(),this.$element.data(),t),t.delay&&"number"==typeof t.delay&&(t.delay={show:t.delay,hide:t.delay}),t};t.prototype.getDelegateOptions=function(){var t={},i=this.getDefaults();return this._options&&n.each(this._options,function(n,r){i[n]!=r&&(t[n]=r)}),t};t.prototype.enter=function(t){var i=t instanceof this.constructor?t:n(t.currentTarget).data("bs."+this.type);return i||(i=new this.constructor(t.currentTarget,this.getDelegateOptions()),n(t.currentTarget).data("bs."+this.type,i)),t instanceof n.Event&&(i.inState["focusin"==t.type?"focus":"hover"]=!0),i.tip().hasClass("in")||"in"==i.hoverState?void(i.hoverState="in"):(clearTimeout(i.timeout),i.hoverState="in",i.options.delay&&i.options.delay.show?void(i.timeout=setTimeout(function(){"in"==i.hoverState&&i.show()},i.options.delay.show)):i.show())};t.prototype.isInStateTrue=function(){for(var n in this.inState)if(this.inState[n])return!0;return!1};t.prototype.leave=function(t){var i=t instanceof this.constructor?t:n(t.currentTarget).data("bs."+this.type);if(i||(i=new this.constructor(t.currentTarget,this.getDelegateOptions()),n(t.currentTarget).data("bs."+this.type,i)),t instanceof n.Event&&(i.inState["focusout"==t.type?"focus":"hover"]=!1),!i.isInStateTrue())return clearTimeout(i.timeout),i.hoverState="out",i.options.delay&&i.options.delay.hide?void(i.timeout=setTimeout(function(){"out"==i.hoverState&&i.hide()},i.options.delay.hide)):i.hide()};t.prototype.show=function(){var c=n.Event("show.bs."+this.type),l,p,e,w,h;if(this.hasContent()&&this.enabled){if(this.$element.trigger(c),l=n.contains(this.$element[0].ownerDocument.documentElement,this.$element[0]),c.isDefaultPrevented()||!l)return;var u=this,r=this.tip(),a=this.getUID(this.type);this.setContent();r.attr("id",a);this.$element.attr("aria-describedby",a);this.options.animation&&r.addClass("fade");var i="function"==typeof this.options.placement?this.options.placement.call(this,r[0],this.$element[0]):this.options.placement,v=/\s?auto?\s?/i,y=v.test(i);y&&(i=i.replace(v,"")||"top");r.detach().css({top:0,left:0,display:"block"}).addClass(i).data("bs."+this.type,this);this.options.container?r.appendTo(this.options.container):r.insertAfter(this.$element);this.$element.trigger("inserted.bs."+this.type);var f=this.getPosition(),o=r[0].offsetWidth,s=r[0].offsetHeight;y&&(p=i,e=this.getPosition(this.$viewport),i="bottom"==i&&f.bottom+s>e.bottom?"top":"top"==i&&f.top-s<e.top?"bottom":"right"==i&&f.right+o>e.width?"left":"left"==i&&f.left-o<e.left?"right":i,r.removeClass(p).addClass(i));w=this.getCalculatedOffset(i,f,o,s);this.applyPlacement(w,i);h=function(){var n=u.hoverState;u.$element.trigger("shown.bs."+u.type);u.hoverState=null;"out"==n&&u.leave(u)};n.support.transition&&this.$tip.hasClass("fade")?r.one("bsTransitionEnd",h).emulateTransitionEnd(t.TRANSITION_DURATION):h()}};t.prototype.applyPlacement=function(t,i){var r=this.tip(),l=r[0].offsetWidth,e=r[0].offsetHeight,o=parseInt(r.css("margin-top"),10),s=parseInt(r.css("margin-left"),10),h,f,u;isNaN(o)&&(o=0);isNaN(s)&&(s=0);t.top+=o;t.left+=s;n.offset.setOffset(r[0],n.extend({using:function(n){r.css({top:Math.round(n.top),left:Math.round(n.left)})}},t),0);r.addClass("in");h=r[0].offsetWidth;f=r[0].offsetHeight;"top"==i&&f!=e&&(t.top=t.top+e-f);u=this.getViewportAdjustedDelta(i,t,h,f);u.left?t.left+=u.left:t.top+=u.top;var c=/top|bottom/.test(i),a=c?2*u.left-l+h:2*u.top-e+f,v=c?"offsetWidth":"offsetHeight";r.offset(t);this.replaceArrow(a,r[0][v],c)};t.prototype.replaceArrow=function(n,t,i){this.arrow().css(i?"left":"top",50*(1-n/t)+"%").css(i?"top":"left","")};t.prototype.setContent=function(){var n=this.tip(),t=this.getTitle();n.find(".tooltip-inner")[this.options.html?"html":"text"](t);n.removeClass("fade in top bottom left right")};t.prototype.hide=function(i){function f(){"in"!=r.hoverState&&u.detach();r.$element&&r.$element.removeAttr("aria-describedby").trigger("hidden.bs."+r.type);i&&i()}var r=this,u=n(this.$tip),e=n.Event("hide.bs."+this.type);if(this.$element.trigger(e),!e.isDefaultPrevented())return u.removeClass("in"),n.support.transition&&u.hasClass("fade")?u.one("bsTransitionEnd",f).emulateTransitionEnd(t.TRANSITION_DURATION):f(),this.hoverState=null,this};t.prototype.fixTitle=function(){var n=this.$element;(n.attr("title")||"string"!=typeof n.attr("data-original-title"))&&n.attr("data-original-title",n.attr("title")||"").attr("title","")};t.prototype.hasContent=function(){return this.getTitle()};t.prototype.getPosition=function(t){t=t||this.$element;var r=t[0],u="BODY"==r.tagName,i=r.getBoundingClientRect();null==i.width&&(i=n.extend({},i,{width:i.right-i.left,height:i.bottom-i.top}));var f=window.SVGElement&&r instanceof window.SVGElement,e=u?{top:0,left:0}:f?null:t.offset(),o={scroll:u?document.documentElement.scrollTop||document.body.scrollTop:t.scrollTop()},s=u?{width:n(window).width(),height:n(window).height()}:null;return n.extend({},i,o,s,e)};t.prototype.getCalculatedOffset=function(n,t,i,r){return"bottom"==n?{top:t.top+t.height,left:t.left+t.width/2-i/2}:"top"==n?{top:t.top-r,left:t.left+t.width/2-i/2}:"left"==n?{top:t.top+t.height/2-r/2,left:t.left-i}:{top:t.top+t.height/2-r/2,left:t.left+t.width}};t.prototype.getViewportAdjustedDelta=function(n,t,i,r){var f={top:0,left:0},e,u,o,s,h,c;return this.$viewport?(e=this.options.viewport&&this.options.viewport.padding||0,u=this.getPosition(this.$viewport),/right|left/.test(n)?(o=t.top-e-u.scroll,s=t.top+e-u.scroll+r,o<u.top?f.top=u.top-o:s>u.top+u.height&&(f.top=u.top+u.height-s)):(h=t.left-e,c=t.left+e+i,h<u.left?f.left=u.left-h:c>u.right&&(f.left=u.left+u.width-c)),f):f};t.prototype.getTitle=function(){var t=this.$element,n=this.options;return t.attr("data-original-title")||("function"==typeof n.title?n.title.call(t[0]):n.title)};t.prototype.getUID=function(n){do n+=~~(1e6*Math.random());while(document.getElementById(n));return n};t.prototype.tip=function(){if(!this.$tip&&(this.$tip=n(this.options.template),1!=this.$tip.length))throw new Error(this.type+" `template` option must consist of exactly 1 top-level element!");return this.$tip};t.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")};t.prototype.enable=function(){this.enabled=!0};t.prototype.disable=function(){this.enabled=!1};t.prototype.toggleEnabled=function(){this.enabled=!this.enabled};t.prototype.toggle=function(t){var i=this;t&&(i=n(t.currentTarget).data("bs."+this.type),i||(i=new this.constructor(t.currentTarget,this.getDelegateOptions()),n(t.currentTarget).data("bs."+this.type,i)));t?(i.inState.click=!i.inState.click,i.isInStateTrue()?i.enter(i):i.leave(i)):i.tip().hasClass("in")?i.leave(i):i.enter(i)};t.prototype.destroy=function(){var n=this;clearTimeout(this.timeout);this.hide(function(){n.$element.off("."+n.type).removeData("bs."+n.type);n.$tip&&n.$tip.detach();n.$tip=null;n.$arrow=null;n.$viewport=null;n.$element=null})};i=n.fn.tooltip;n.fn.tooltip=r;n.fn.tooltip.Constructor=t;n.fn.tooltip.noConflict=function(){return n.fn.tooltip=i,this}}(jQuery);+function(n){"use strict";function r(i){return this.each(function(){var u=n(this),r=u.data("bs.popover"),f="object"==typeof i&&i;!r&&/destroy|hide/.test(i)||(r||u.data("bs.popover",r=new t(this,f)),"string"==typeof i&&r[i]())})}var t=function(n,t){this.init("popover",n,t)},i;if(!n.fn.tooltip)throw new Error("Popover requires tooltip.js");t.VERSION="3.3.7";t.DEFAULTS=n.extend({},n.fn.tooltip.Constructor.DEFAULTS,{placement:"right",trigger:"click",content:"",template:'<div class="popover" role="tooltip"><div class="arrow"><\/div><h3 class="popover-title"><\/h3><div class="popover-content"><\/div><\/div>'});t.prototype=n.extend({},n.fn.tooltip.Constructor.prototype);t.prototype.constructor=t;t.prototype.getDefaults=function(){return t.DEFAULTS};t.prototype.setContent=function(){var n=this.tip(),i=this.getTitle(),t=this.getContent();n.find(".popover-title")[this.options.html?"html":"text"](i);n.find(".popover-content").children().detach().end()[this.options.html?"string"==typeof t?"html":"append":"text"](t);n.removeClass("fade top bottom left right in");n.find(".popover-title").html()||n.find(".popover-title").hide()};t.prototype.hasContent=function(){return this.getTitle()||this.getContent()};t.prototype.getContent=function(){var t=this.$element,n=this.options;return t.attr("data-content")||("function"==typeof n.content?n.content.call(t[0]):n.content)};t.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")};i=n.fn.popover;n.fn.popover=r;n.fn.popover.Constructor=t;n.fn.popover.noConflict=function(){return n.fn.popover=i,this}}(jQuery);+function(n){"use strict";function t(i,r){this.$body=n(document.body);this.$scrollElement=n(n(i).is(document.body)?window:i);this.options=n.extend({},t.DEFAULTS,r);this.selector=(this.options.target||"")+" .nav li > a";this.offsets=[];this.targets=[];this.activeTarget=null;this.scrollHeight=0;this.$scrollElement.on("scroll.bs.scrollspy",n.proxy(this.process,this));this.refresh();this.process()}function i(i){return this.each(function(){var u=n(this),r=u.data("bs.scrollspy"),f="object"==typeof i&&i;r||u.data("bs.scrollspy",r=new t(this,f));"string"==typeof i&&r[i]()})}t.VERSION="3.3.7";t.DEFAULTS={offset:10};t.prototype.getScrollHeight=function(){return this.$scrollElement[0].scrollHeight||Math.max(this.$body[0].scrollHeight,document.documentElement.scrollHeight)};t.prototype.refresh=function(){var t=this,i="offset",r=0;this.offsets=[];this.targets=[];this.scrollHeight=this.getScrollHeight();n.isWindow(this.$scrollElement[0])||(i="position",r=this.$scrollElement.scrollTop());this.$body.find(this.selector).map(function(){var f=n(this),u=f.data("target")||f.attr("href"),t=/^#./.test(u)&&n(u);return t&&t.length&&t.is(":visible")&&[[t[i]().top+r,u]]||null}).sort(function(n,t){return n[0]-t[0]}).each(function(){t.offsets.push(this[0]);t.targets.push(this[1])})};t.prototype.process=function(){var n,i=this.$scrollElement.scrollTop()+this.options.offset,f=this.getScrollHeight(),e=this.options.offset+f-this.$scrollElement.height(),t=this.offsets,r=this.targets,u=this.activeTarget;if(this.scrollHeight!=f&&this.refresh(),i>=e)return u!=(n=r[r.length-1])&&this.activate(n);if(u&&i<t[0])return this.activeTarget=null,this.clear();for(n=t.length;n--;)u!=r[n]&&i>=t[n]&&(void 0===t[n+1]||i<t[n+1])&&this.activate(r[n])};t.prototype.activate=function(t){this.activeTarget=t;this.clear();var r=this.selector+'[data-target="'+t+'"],'+this.selector+'[href="'+t+'"]',i=n(r).parents("li").addClass("active");i.parent(".dropdown-menu").length&&(i=i.closest("li.dropdown").addClass("active"));i.trigger("activate.bs.scrollspy")};t.prototype.clear=function(){n(this.selector).parentsUntil(this.options.target,".active").removeClass("active")};var r=n.fn.scrollspy;n.fn.scrollspy=i;n.fn.scrollspy.Constructor=t;n.fn.scrollspy.noConflict=function(){return n.fn.scrollspy=r,this};n(window).on("load.bs.scrollspy.data-api",function(){n('[data-spy="scroll"]').each(function(){var t=n(this);i.call(t,t.data())})})}(jQuery);+function(n){"use strict";function r(i){return this.each(function(){var u=n(this),r=u.data("bs.tab");r||u.data("bs.tab",r=new t(this));"string"==typeof i&&r[i]()})}var t=function(t){this.element=n(t)},u,i;t.VERSION="3.3.7";t.TRANSITION_DURATION=150;t.prototype.show=function(){var t=this.element,f=t.closest("ul:not(.dropdown-menu)"),i=t.data("target"),u;if(i||(i=t.attr("href"),i=i&&i.replace(/.*(?=#[^\s]*$)/,"")),!t.parent("li").hasClass("active")){var r=f.find(".active:last a"),e=n.Event("hide.bs.tab",{relatedTarget:t[0]}),o=n.Event("show.bs.tab",{relatedTarget:r[0]});(r.trigger(e),t.trigger(o),o.isDefaultPrevented()||e.isDefaultPrevented())||(u=n(i),this.activate(t.closest("li"),f),this.activate(u,u.parent(),function(){r.trigger({type:"hidden.bs.tab",relatedTarget:t[0]});t.trigger({type:"shown.bs.tab",relatedTarget:r[0]})}))}};t.prototype.activate=function(i,r,u){function e(){f.removeClass("active").find("> .dropdown-menu > .active").removeClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!1);i.addClass("active").find('[data-toggle="tab"]').attr("aria-expanded",!0);o?(i[0].offsetWidth,i.addClass("in")):i.removeClass("fade");i.parent(".dropdown-menu").length&&i.closest("li.dropdown").addClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!0);u&&u()}var f=r.find("> .active"),o=u&&n.support.transition&&(f.length&&f.hasClass("fade")||!!r.find("> .fade").length);f.length&&o?f.one("bsTransitionEnd",e).emulateTransitionEnd(t.TRANSITION_DURATION):e();f.removeClass("in")};u=n.fn.tab;n.fn.tab=r;n.fn.tab.Constructor=t;n.fn.tab.noConflict=function(){return n.fn.tab=u,this};i=function(t){t.preventDefault();r.call(n(this),"show")};n(document).on("click.bs.tab.data-api",'[data-toggle="tab"]',i).on("click.bs.tab.data-api",'[data-toggle="pill"]',i)}(jQuery);+function(n){"use strict";function i(i){return this.each(function(){var u=n(this),r=u.data("bs.affix"),f="object"==typeof i&&i;r||u.data("bs.affix",r=new t(this,f));"string"==typeof i&&r[i]()})}var t=function(i,r){this.options=n.extend({},t.DEFAULTS,r);this.$target=n(this.options.target).on("scroll.bs.affix.data-api",n.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",n.proxy(this.checkPositionWithEventLoop,this));this.$element=n(i);this.affixed=null;this.unpin=null;this.pinnedOffset=null;this.checkPosition()},r;t.VERSION="3.3.7";t.RESET="affix affix-top affix-bottom";t.DEFAULTS={offset:0,target:window};t.prototype.getState=function(n,t,i,r){var u=this.$target.scrollTop(),f=this.$element.offset(),e=this.$target.height();if(null!=i&&"top"==this.affixed)return u<i&&"top";if("bottom"==this.affixed)return null!=i?!(u+this.unpin<=f.top)&&"bottom":!(u+e<=n-r)&&"bottom";var o=null==this.affixed,s=o?u:f.top,h=o?e:t;return null!=i&&u<=i?"top":null!=r&&s+h>=n-r&&"bottom"};t.prototype.getPinnedOffset=function(){if(this.pinnedOffset)return this.pinnedOffset;this.$element.removeClass(t.RESET).addClass("affix");var n=this.$target.scrollTop(),i=this.$element.offset();return this.pinnedOffset=i.top-n};t.prototype.checkPositionWithEventLoop=function(){setTimeout(n.proxy(this.checkPosition,this),1)};t.prototype.checkPosition=function(){var i,e,o;if(this.$element.is(":visible")){var s=this.$element.height(),r=this.options.offset,f=r.top,u=r.bottom,h=Math.max(n(document).height(),n(document.body).height());if("object"!=typeof r&&(u=f=r),"function"==typeof f&&(f=r.top(this.$element)),"function"==typeof u&&(u=r.bottom(this.$element)),i=this.getState(h,s,f,u),this.affixed!=i){if(null!=this.unpin&&this.$element.css("top",""),e="affix"+(i?"-"+i:""),o=n.Event(e+".bs.affix"),this.$element.trigger(o),o.isDefaultPrevented())return;this.affixed=i;this.unpin="bottom"==i?this.getPinnedOffset():null;this.$element.removeClass(t.RESET).addClass(e).trigger(e.replace("affix","affixed")+".bs.affix")}"bottom"==i&&this.$element.offset({top:h-s-u})}};r=n.fn.affix;n.fn.affix=i;n.fn.affix.Constructor=t;n.fn.affix.noConflict=function(){return n.fn.affix=r,this};n(window).on("load",function(){n('[data-spy="affix"]').each(function(){var r=n(this),t=r.data();t.offset=t.offset||{};null!=t.offsetBottom&&(t.offset.bottom=t.offsetBottom);null!=t.offsetTop&&(t.offset.top=t.offsetTop);i.call(r,t)})})}(jQuery);!function(n){"use strict";var o=3,h;try{o=parseInt(n.fn.dropdown.Constructor.VERSION,10)}catch(b){}var u={3:{buttonsClass:"default",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"},pullClass:"pull",toobarDropdowHtml:['<ul class="dropdown-menu" role="menu">',"<\/ul>"],toobarDropdowItemHtml:'<li role="menuitem"><label>%s<\/label><\/li>',pageDropdownHtml:['<ul class="dropdown-menu" role="menu">',"<\/ul>"],pageDropdownItemHtml:'<li role="menuitem" class="%s"><a href="#">%s<\/a><\/li>'},4:{buttonsClass:"secondary",iconsPrefix:"fa",icons:{paginationSwitchDown:"fa-toggle-down",paginationSwitchUp:"fa-toggle-up",refresh:"fa-refresh",toggleOff:"fa-toggle-off",toggleOn:"fa-toggle-on",columns:"fa-th-list",detailOpen:"fa-plus",detailClose:"fa-minus",fullscreen:"fa-arrows-alt"},pullClass:"float",toobarDropdowHtml:['<div class="dropdown-menu dropdown-menu-right">',"<\/div>"],toobarDropdowItemHtml:'<label class="dropdown-item">%s<\/label>',pageDropdownHtml:['<div class="dropdown-menu">',"<\/div>"],pageDropdownItemHtml:'<a class="dropdown-item %s" href="#">%s<\/a>'}}[o],s=null,i=function(n){var i=arguments,t=!0,r=1;return n=n.replace(/%s/g,function(){var n=i[r++];return"undefined"==typeof n?(t=!1,""):n}),t?n:""},y=function(t,i,r,u){var f="";return n.each(t,function(n,t){return t[i]===u?(f=t[r],!1):!0}),f},p=function(t){for(var r,u,s=0,f=[],i=0;i<t[0].length;i++)s+=t[0][i].colspan||1;for(i=0;i<t.length;i++)for(f[i]=[],r=0;s>r;r++)f[i][r]=!1;for(i=0;i<t.length;i++)for(r=0;r<t[i].length;r++){var e=t[i][r],c=e.rowspan||1,h=e.colspan||1,o=n.inArray(!1,f[i]);for(1===h&&(e.fieldIndex=o,"undefined"==typeof e.field&&(e.field=o)),u=0;c>u;u++)f[i+u][o]=!0;for(u=0;h>u;u++)f[i][o+u]=!0}},c=function(){if(null===s){var r,i,u=n("<p/>").addClass("fixed-table-scroll-inner"),t=n("<div/>").addClass("fixed-table-scroll-outer");t.append(u);n("body").append(t);r=u[0].offsetWidth;t.css("overflow","scroll");i=u[0].offsetWidth;r===i&&(i=t[0].clientWidth);t.remove();s=r-i}return s},r=function(t,r,u,f){var e=r,o;return"string"==typeof r&&(o=r.split("."),o.length>1?(e=window,n.each(o,function(n,t){e=e[t]})):e=window[r]),"object"==typeof e?e:"function"==typeof e?e.apply(t,u||[]):!e&&"string"==typeof r&&i.apply(this,[r].concat(u))?i.apply(this,[r].concat(u)):f},l=function(t,i,r){var o=Object.getOwnPropertyNames||function(n){var t=[];for(var i in n)n.hasOwnProperty(i)&&t.push(i);return t},e=o(t),s=o(i),u="",f;if(r&&e.length!==s.length)return!1;for(f=0;f<e.length;f++)if(u=e[f],n.inArray(u,s)>-1&&t[u]!==i[u])return!1;return!0},f=function(n){return"string"==typeof n?n.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#039;").replace(/`/g,"&#x60;"):n},a=function(n){var t,i;for(t in n)i=t.split(/(?=[A-Z])/).join("-").toLowerCase(),i!==t&&(n[i]=n[t],delete n[t]);return n},e=function(n,t,i){var r=n,u,e;if("string"!=typeof t||n.hasOwnProperty(t))return i?f(n[t]):n[t];u=t.split(".");for(e in u)u.hasOwnProperty(e)&&(r=r&&r[u[e]]);return i?f(r):r},v=function(){return!!(navigator.userAgent.indexOf("MSIE ")>0||navigator.userAgent.match(/Trident.*rv\:11\./))},w=function(){Object.keys||(Object.keys=function(){var t=Object.prototype.hasOwnProperty,i=!{toString:null}.propertyIsEnumerable("toString"),n=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],r=n.length;return function(u){if("object"!=typeof u&&("function"!=typeof u||null===u))throw new TypeError("Object.keys called on non-object");var e,f,o=[];for(e in u)t.call(u,e)&&o.push(e);if(i)for(f=0;r>f;f++)t.call(u,n[f])&&o.push(n[f]);return o}}())},t=function(t,i){this.options=i;this.$el=n(t);this.$el_=this.$el.clone();this.timeoutId_=0;this.timeoutFooter_=0;this.init()};t.DEFAULTS={classes:"table table-hover",sortClass:void 0,locale:void 0,height:void 0,undefinedText:"-",sortName:void 0,sortOrder:"asc",sortStable:!1,rememberOrder:!1,striped:!1,columns:[[]],data:[],totalField:"total",dataField:"rows",method:"get",url:void 0,ajax:void 0,cache:!0,contentType:"application/json",dataType:"json",ajaxOptions:{},queryParams:function(n){return n},queryParamsType:"limit",responseHandler:function(n){return n},pagination:!1,onlyInfoPagination:!1,paginationLoop:!0,sidePagination:"client",totalRows:0,pageNumber:1,pageSize:10,pageList:[10,25,50,100],paginationHAlign:"right",paginationVAlign:"bottom",paginationDetailHAlign:"left",paginationPreText:"&lsaquo;",paginationNextText:"&rsaquo;",search:!1,searchOnEnterKey:!1,strictSearch:!1,searchAlign:"right",selectItemName:"btSelectItem",showHeader:!0,showFooter:!1,showColumns:!1,showPaginationSwitch:!1,showRefresh:!1,showToggle:!1,showFullscreen:!1,smartDisplay:!0,escape:!1,minimumCountColumns:1,idField:void 0,uniqueId:void 0,cardView:!1,detailView:!1,detailFormatter:function(){return""},detailFilter:function(){return!0},trimOnSearch:!0,clickToSelect:!1,singleSelect:!1,toolbar:void 0,toolbarAlign:"left",buttonsToolbar:void 0,buttonsAlign:"right",checkboxHeader:!0,sortable:!0,silentSort:!0,maintainSelected:!1,searchTimeOut:500,searchText:"",iconSize:void 0,buttonsClass:u.buttonsClass,iconsPrefix:u.iconsPrefix,icons:u.icons,customSearch:n.noop,customSort:n.noop,ignoreClickToSelectOn:function(t){return n.inArray(t.tagName,["A","BUTTON"])},rowStyle:function(){return{}},rowAttributes:function(){return{}},footerStyle:function(){return{}},onAll:function(){return!1},onClickCell:function(){return!1},onDblClickCell:function(){return!1},onClickRow:function(){return!1},onDblClickRow:function(){return!1},onSort:function(){return!1},onCheck:function(){return!1},onUncheck:function(){return!1},onCheckAll:function(){return!1},onUncheckAll:function(){return!1},onCheckSome:function(){return!1},onUncheckSome:function(){return!1},onLoadSuccess:function(){return!1},onLoadError:function(){return!1},onColumnSwitch:function(){return!1},onPageChange:function(){return!1},onSearch:function(){return!1},onToggle:function(){return!1},onPreBody:function(){return!1},onPostBody:function(){return!1},onPostHeader:function(){return!1},onExpandRow:function(){return!1},onCollapseRow:function(){return!1},onRefreshOptions:function(){return!1},onRefresh:function(){return!1},onResetView:function(){return!1},onScrollBody:function(){return!1}};t.LOCALES={};t.LOCALES["en-US"]=t.LOCALES.en={formatLoadingMessage:function(){return"Loading, please wait..."},formatRecordsPerPage:function(n){return i("%s rows per page",n)},formatShowingRows:function(n,t,r){return i("Showing %s to %s of %s rows",n,t,r)},formatDetailPagination:function(n){return i("Showing %s rows",n)},formatSearch:function(){return"Search"},formatNoMatches:function(){return"No matching records found"},formatPaginationSwitch:function(){return"Hide/Show pagination"},formatRefresh:function(){return"Refresh"},formatToggle:function(){return"Toggle"},formatFullscreen:function(){return"Fullscreen"},formatColumns:function(){return"Columns"},formatAllRows:function(){return"All"}};n.extend(t.DEFAULTS,t.LOCALES["en-US"]);t.COLUMN_DEFAULTS={radio:!1,checkbox:!1,checkboxEnabled:!0,field:void 0,title:void 0,titleTooltip:void 0,"class":void 0,align:void 0,halign:void 0,falign:void 0,valign:void 0,width:void 0,sortable:!1,order:"asc",visible:!0,switchable:!0,clickToSelect:!0,formatter:void 0,footerFormatter:void 0,events:void 0,sorter:void 0,sortName:void 0,cellStyle:void 0,searchable:!0,searchFormatter:!0,cardVisible:!0,escape:!1,showSelectTitle:!1};t.EVENTS={"all.bs.table":"onAll","click-cell.bs.table":"onClickCell","dbl-click-cell.bs.table":"onDblClickCell","click-row.bs.table":"onClickRow","dbl-click-row.bs.table":"onDblClickRow","sort.bs.table":"onSort","check.bs.table":"onCheck","uncheck.bs.table":"onUncheck","check-all.bs.table":"onCheckAll","uncheck-all.bs.table":"onUncheckAll","check-some.bs.table":"onCheckSome","uncheck-some.bs.table":"onUncheckSome","load-success.bs.table":"onLoadSuccess","load-error.bs.table":"onLoadError","column-switch.bs.table":"onColumnSwitch","page-change.bs.table":"onPageChange","search.bs.table":"onSearch","toggle.bs.table":"onToggle","pre-body.bs.table":"onPreBody","post-body.bs.table":"onPostBody","post-header.bs.table":"onPostHeader","expand-row.bs.table":"onExpandRow","collapse-row.bs.table":"onCollapseRow","refresh-options.bs.table":"onRefreshOptions","reset-view.bs.table":"onResetView","refresh.bs.table":"onRefresh","scroll-body.bs.table":"onScrollBody"};t.prototype.init=function(){this.initLocale();this.initContainer();this.initTable();this.initHeader();this.initData();this.initHiddenRows();this.initFooter();this.initToolbar();this.initPagination();this.initBody();this.initSearchText();this.initServer()};t.prototype.initLocale=function(){if(this.options.locale){var t=this.options.locale.split(/-|_/);t[0].toLowerCase();t[1]&&t[1].toUpperCase();n.fn.bootstrapTable.locales[this.options.locale]?n.extend(this.options,n.fn.bootstrapTable.locales[this.options.locale]):n.fn.bootstrapTable.locales[t.join("-")]?n.extend(this.options,n.fn.bootstrapTable.locales[t.join("-")]):n.fn.bootstrapTable.locales[t[0]]&&n.extend(this.options,n.fn.bootstrapTable.locales[t[0]])}};t.prototype.initContainer=function(){this.$container=n(['<div class="bootstrap-table">','<div class="fixed-table-toolbar"><\/div>',"top"===this.options.paginationVAlign||"both"===this.options.paginationVAlign?'<div class="fixed-table-pagination" style="clear: both;"><\/div>':"",'<div class="fixed-table-container">','<div class="fixed-table-header"><table><\/table><\/div>','<div class="fixed-table-body">','<div class="fixed-table-loading">',this.options.formatLoadingMessage(),"<\/div>","<\/div>",'<div class="fixed-table-footer"><table><tr><\/tr><\/table><\/div>',"<\/div>","bottom"===this.options.paginationVAlign||"both"===this.options.paginationVAlign?'<div class="fixed-table-pagination"><\/div>':"","<\/div>"].join(""));this.$container.insertAfter(this.$el);this.$tableContainer=this.$container.find(".fixed-table-container");this.$tableHeader=this.$container.find(".fixed-table-header");this.$tableBody=this.$container.find(".fixed-table-body");this.$tableLoading=this.$container.find(".fixed-table-loading");this.$tableFooter=this.$container.find(".fixed-table-footer");this.$toolbar=this.options.buttonsToolbar?n("body").find(this.options.buttonsToolbar):this.$container.find(".fixed-table-toolbar");this.$pagination=this.$container.find(".fixed-table-pagination");this.$tableBody.append(this.$el);this.$container.after('<div class="clearfix"><\/div>');this.$el.addClass(this.options.classes);this.options.striped&&this.$el.addClass("table-striped");-1!==n.inArray("table-no-bordered",this.options.classes.split(" "))&&this.$tableContainer.addClass("table-no-bordered")};t.prototype.initTable=function(){var r=this,f=[],u=[],i;(this.$header=this.$el.find(">thead"),this.$header.length||(this.$header=n("<thead><\/thead>").appendTo(this.$el)),this.$header.find("tr").each(function(){var t=[];n(this).find("th").each(function(){"undefined"!=typeof n(this).data("field")&&n(this).data("field",n(this).data("field")+"");t.push(n.extend({},{title:n(this).html(),"class":n(this).attr("class"),titleTooltip:n(this).attr("title"),rowspan:n(this).attr("rowspan")?+n(this).attr("rowspan"):void 0,colspan:n(this).attr("colspan")?+n(this).attr("colspan"):void 0},n(this).data()))});f.push(t)}),n.isArray(this.options.columns[0])||(this.options.columns=[this.options.columns]),this.options.columns=n.extend(!0,[],f,this.options.columns),this.columns=[],this.fieldsColumnsIndex=[],p(this.options.columns),n.each(this.options.columns,function(i,u){n.each(u,function(u,f){f=n.extend({},t.COLUMN_DEFAULTS,f);"undefined"!=typeof f.fieldIndex&&(r.columns[f.fieldIndex]=f,r.fieldsColumnsIndex[f.field]=f.fieldIndex);r.options.columns[i][u]=f})}),this.options.data.length)||(i=[],this.$el.find(">tbody>tr").each(function(t){var f={};f._id=n(this).attr("id");f._class=n(this).attr("class");f._data=a(n(this).data());n(this).find(">td").each(function(u){for(var e,s,o,h=n(this),c=+h.attr("colspan")||1,l=+h.attr("rowspan")||1;i[t]&&i[t][u];u++);for(s=u;u+c>s;s++)for(o=t;t+l>o;o++)i[o]||(i[o]=[]),i[o][s]=!0;e=r.columns[u].field;f[e]=n(this).html();f["_"+e+"_id"]=n(this).attr("id");f["_"+e+"_class"]=n(this).attr("class");f["_"+e+"_rowspan"]=n(this).attr("rowspan");f["_"+e+"_colspan"]=n(this).attr("colspan");f["_"+e+"_title"]=n(this).attr("title");f["_"+e+"_data"]=a(n(this).data())});u.push(f)}),this.options.data=u,u.length&&(this.fromHtml=!0))};t.prototype.initHeader=function(){var t=this,u={},r=[];this.header={fields:[],styles:[],classes:[],formatters:[],events:[],sorters:[],sortNames:[],cellStyles:[],searchables:[]};n.each(this.options.columns,function(e,o){r.push("<tr>");0===e&&!t.options.cardView&&t.options.detailView&&r.push(i('<th class="detail" rowspan="%s"><div class="fht-cell"><\/div><\/th>',t.options.columns.length));n.each(o,function(n,e){var o="",c="",l="",s="",a=i(' class="%s"',e["class"]),v=(t.options.sortOrder||e.order,"px"),h=e.width,y;if(void 0===e.width||t.options.cardView||"string"==typeof e.width&&-1!==e.width.indexOf("%")&&(v="%"),e.width&&"string"==typeof e.width&&(h=e.width.replace("%","").replace("px","")),c=i("text-align: %s; ",e.halign?e.halign:e.align),l=i("text-align: %s; ",e.align),s=i("vertical-align: %s; ",e.valign),s+=i("width: %s; ",!e.checkbox&&!e.radio||h?h?h+v:void 0:e.showSelectTitle?void 0:"36px"),"undefined"!=typeof e.fieldIndex){if(t.header.fields[e.fieldIndex]=e.field,t.header.styles[e.fieldIndex]=l+s,t.header.classes[e.fieldIndex]=a,t.header.formatters[e.fieldIndex]=e.formatter,t.header.events[e.fieldIndex]=e.events,t.header.sorters[e.fieldIndex]=e.sorter,t.header.sortNames[e.fieldIndex]=e.sortName,t.header.cellStyles[e.fieldIndex]=e.cellStyle,t.header.searchables[e.fieldIndex]=e.searchable,!e.visible)return;if(t.options.cardView&&!e.cardVisible)return;u[e.field]=e}r.push("<th"+i(' title="%s"',e.titleTooltip),e.checkbox||e.radio?i(' class="bs-checkbox %s"',e["class"]||""):a,i(' style="%s"',c+s),i(' rowspan="%s"',e.rowspan),i(' colspan="%s"',e.colspan),i(' data-field="%s"',e.field),0===n&&e.fieldIndex?" data-not-first-th":"",">");r.push(i('<div class="th-inner %s">',t.options.sortable&&e.sortable?"sortable both":""));o=t.options.escape?f(e.title):e.title;y=o;e.checkbox&&(o="",!t.options.singleSelect&&t.options.checkboxHeader&&(o='<input name="btSelectAll" type="checkbox" />'),t.header.stateField=e.field);e.radio&&(o="",t.header.stateField=e.field,t.options.singleSelect=!0);!o&&e.showSelectTitle&&(o+=y);r.push(o);r.push("<\/div>");r.push('<div class="fht-cell"><\/div>');r.push("<\/div>");r.push("<\/th>")});r.push("<\/tr>")});this.$header.html(r.join(""));this.$header.find("th[data-field]").each(function(){n(this).data(u[n(this).data("field")])});this.$container.off("click",".th-inner").on("click",".th-inner",function(i){var r=n(this);return t.options.detailView&&!r.parent().hasClass("bs-checkbox")&&r.closest(".bootstrap-table")[0]!==t.$container[0]?!1:void(t.options.sortable&&r.parent().data().sortable&&t.onSort(i))});this.$header.children().children().off("keypress").on("keypress",function(i){if(t.options.sortable&&n(this).data().sortable){var r=i.keyCode||i.which;13==r&&t.onSort(i)}});n(window).off("resize.bootstrap-table");!this.options.showHeader||this.options.cardView?(this.$header.hide(),this.$tableHeader.hide(),this.$tableLoading.css("top",0)):(this.$header.show(),this.$tableHeader.show(),this.$tableLoading.css("top",this.$header.outerHeight()+1),this.getCaret(),n(window).on("resize.bootstrap-table",n.proxy(this.resetWidth,this)));this.$selectAll=this.$header.find('[name="btSelectAll"]');this.$selectAll.off("click").on("click",function(){var i=n(this).prop("checked");t[i?"checkAll":"uncheckAll"]();t.updateSelected()})};t.prototype.initFooter=function(){!this.options.showFooter||this.options.cardView?this.$tableFooter.hide():this.$tableFooter.show()};t.prototype.initData=function(n,t){this.options.data="append"===t?this.options.data.concat(n):"prepend"===t?[].concat(n).concat(this.options.data):n||this.options.data;this.data=this.options.data;"server"!==this.options.sidePagination&&this.initSort()};t.prototype.initSort=function(){var t=this,o=this.options.sortName,u="desc"===this.options.sortOrder?-1:1,f=n.inArray(this.options.sortName,this.header.fields),s=0;return this.options.customSort!==n.noop?void this.options.customSort.apply(this,[this.options.sortName,this.options.sortOrder]):void(-1!==f&&(this.options.sortStable&&n.each(this.data,function(n,t){t._position=n}),this.data.sort(function(i,s){t.header.sortNames[f]&&(o=t.header.sortNames[f]);var h=e(i,o,t.options.escape),c=e(s,o,t.options.escape),l=r(t.header,t.header.sorters[f],[h,c,i,s]);return void 0!==l?t.options.sortStable&&0===l?i._position-s._position:u*l:((void 0===h||null===h)&&(h=""),(void 0===c||null===c)&&(c=""),t.options.sortStable&&h===c?(h=i._position,c=s._position,i._position-s._position):n.isNumeric(h)&&n.isNumeric(c)?(h=parseFloat(h),c=parseFloat(c),c>h?-1*u:u):h===c?0:("string"!=typeof h&&(h=h.toString()),-1===h.localeCompare(c)?-1*u:u))}),void 0!==this.options.sortClass&&(clearTimeout(s),s=setTimeout(function(){t.$el.removeClass(t.options.sortClass);var n=t.$header.find(i('[data-field="%s"]',t.options.sortName).index()+1);t.$el.find(i("tr td:nth-child(%s)",n)).addClass(t.options.sortClass)},250))))};t.prototype.onSort=function(t){var i="keypress"===t.type?n(t.currentTarget):n(t.currentTarget).parent(),r=this.$header.find("th").eq(i.index());return this.$header.add(this.$header_).find("span.order").remove(),this.options.sortName===i.data("field")?this.options.sortOrder="asc"===this.options.sortOrder?"desc":"asc":(this.options.sortName=i.data("field"),this.options.sortOrder=this.options.rememberOrder?"asc"===i.data("order")?"desc":"asc":this.columns[this.fieldsColumnsIndex[i.data("field")]].order),this.trigger("sort",this.options.sortName,this.options.sortOrder),i.add(r).data("order",this.options.sortOrder),this.getCaret(),"server"===this.options.sidePagination?void this.initServer(this.options.silentSort):(this.initSort(),void this.initBody())};t.prototype.initToolbar=function(){var e,s,f=this,t=[],o=0,h=0;this.$toolbar.find(".bs-bars").children().length&&n("body").append(n(this.options.toolbar));this.$toolbar.html("");("string"==typeof this.options.toolbar||"object"==typeof this.options.toolbar)&&n(i('<div class="bs-bars %s-%s"><\/div>',u.pullClass,this.options.toolbarAlign)).appendTo(this.$toolbar).append(n(this.options.toolbar));t=[i('<div class="columns columns-%s btn-group %s-%s">',this.options.buttonsAlign,u.pullClass,this.options.buttonsAlign)];"string"==typeof this.options.icons&&(this.options.icons=r(null,this.options.icons));this.options.showPaginationSwitch&&t.push(i('<button class="btn'+i(" btn-%s",this.options.buttonsClass)+i(" btn-%s",this.options.iconSize)+'" type="button" name="paginationSwitch" aria-label="pagination Switch" title="%s">',this.options.formatPaginationSwitch()),i('<i class="%s %s"><\/i>',this.options.iconsPrefix,this.options.icons.paginationSwitchDown),"<\/button>");this.options.showFullscreen&&this.$toolbar.find('button[name="fullscreen"]').off("click").on("click",n.proxy(this.toggleFullscreen,this));this.options.showRefresh&&t.push(i('<button class="btn'+i(" btn-%s",this.options.buttonsClass)+i(" btn-%s",this.options.iconSize)+'" type="button" name="refresh" aria-label="refresh" title="%s">',this.options.formatRefresh()),i('<i class="%s %s"><\/i>',this.options.iconsPrefix,this.options.icons.refresh),"<\/button>");this.options.showToggle&&t.push(i('<button class="btn'+i(" btn-%s",this.options.buttonsClass)+i(" btn-%s",this.options.iconSize)+'" type="button" name="toggle" aria-label="toggle" title="%s">',this.options.formatToggle()),i('<i class="%s %s"><\/i>',this.options.iconsPrefix,this.options.icons.toggleOn),"<\/button>");this.options.showFullscreen&&t.push(i('<button class="btn'+i(" btn-%s",this.options.buttonsClass)+i(" btn-%s",this.options.iconSize)+'" type="button" name="fullscreen" aria-label="fullscreen" title="%s">',this.options.formatFullscreen()),i('<i class="%s %s"><\/i>',this.options.iconsPrefix,this.options.icons.fullscreen),"<\/button>");this.options.showColumns&&(t.push(i('<div class="keep-open btn-group" title="%s">',this.options.formatColumns()),'<button type="button" aria-label="columns" class="btn'+i(" btn-%s",this.options.buttonsClass)+i(" btn-%s",this.options.iconSize)+' dropdown-toggle" data-toggle="dropdown">',i('<i class="%s %s"><\/i>',this.options.iconsPrefix,this.options.icons.columns),' <span class="caret"><\/span>',"<\/button>",u.toobarDropdowHtml[0]),n.each(this.columns,function(n,r){if(!(r.radio||r.checkbox||f.options.cardView&&!r.cardVisible)){var e=r.visible?' checked="checked"':"";r.switchable&&(t.push(i(u.toobarDropdowItemHtml,i('<input type="checkbox" data-field="%s" value="%s"%s> %s',r.field,n,e,r.title))),h++)}}),t.push(u.toobarDropdowHtml[1],"<\/div>"));t.push("<\/div>");(this.showToolbar||t.length>2)&&this.$toolbar.append(t.join(""));this.options.showPaginationSwitch&&this.$toolbar.find('button[name="paginationSwitch"]').off("click").on("click",n.proxy(this.togglePagination,this));this.options.showRefresh&&this.$toolbar.find('button[name="refresh"]').off("click").on("click",n.proxy(this.refresh,this));this.options.showToggle&&this.$toolbar.find('button[name="toggle"]').off("click").on("click",function(){f.toggleView()});this.options.showColumns&&(e=this.$toolbar.find(".keep-open"),h<=this.options.minimumCountColumns&&e.find("input").prop("disabled",!0),e.find("li").off("click").on("click",function(n){n.stopImmediatePropagation()}),e.find("input").off("click").on("click",function(){var t=n(this);f.toggleColumn(n(this).val(),t.prop("checked"),!1);f.trigger("column-switch",n(this).data("field"),t.prop("checked"))}));this.options.search&&(t=[],t.push(i('<div class="%s-%s search">',u.pullClass,this.options.searchAlign),i('<input class="form-control'+i(" input-%s",this.options.iconSize)+'" type="text" placeholder="%s">',this.options.formatSearch()),"<\/div>"),this.$toolbar.append(t.join("")),s=this.$toolbar.find(".search input"),s.off("keyup drop blur").on("keyup drop blur",function(t){f.options.searchOnEnterKey&&13!==t.keyCode||n.inArray(t.keyCode,[37,38,39,40])>-1||(clearTimeout(o),o=setTimeout(function(){f.onSearch(t)},f.options.searchTimeOut))}),v()&&s.off("mouseup").on("mouseup",function(n){clearTimeout(o);o=setTimeout(function(){f.onSearch(n)},f.options.searchTimeOut)}))};t.prototype.onSearch=function(t){var i=n.trim(n(t.currentTarget).val());this.options.trimOnSearch&&n(t.currentTarget).val()!==i&&n(t.currentTarget).val(i);i!==this.searchText&&(this.searchText=i,this.options.searchText=i,this.options.pageNumber=1,this.initSearch(),t.firedByInitSearchText?"client"===this.options.sidePagination&&this.updatePagination():this.updatePagination(),this.trigger("search",i))};t.prototype.initSearch=function(){var t=this,u,i;if("server"!==this.options.sidePagination){if(this.options.customSearch!==n.noop)return void window[this.options.customSearch].apply(this,[this.searchText]);u=this.searchText&&(this.options.escape?f(this.searchText):this.searchText).toLowerCase();i=n.isEmptyObject(this.filterColumns)?null:this.filterColumns;this.data=i?n.grep(this.options.data,function(t){for(var r in i)if(n.isArray(i[r])&&-1===n.inArray(t[r],i[r])||!n.isArray(i[r])&&t[r]!==i[r])return!1;return!0}):this.options.data;this.data=u?n.grep(this.data,function(i,f){for(var e,s,c,l,h,o=0;o<t.header.fields.length;o++)if(t.header.searchables[o]){if(s=n.isNumeric(t.header.fields[o])?parseInt(t.header.fields[o],10):t.header.fields[o],c=t.columns[t.fieldsColumnsIndex[s]],"string"==typeof s){for(e=i,l=s.split("."),h=0;h<l.length;h++)null!=e[l[h]]&&(e=e[l[h]]);c&&c.searchFormatter&&(e=r(c,t.header.formatters[o],[e,i,f],e))}else e=i[s];if("string"==typeof e||"number"==typeof e)if(t.options.strictSearch){if((e+"").toLowerCase()===u)return!0}else if(-1!==(e+"").toLowerCase().indexOf(u))return!0}return!1}):this.data}};t.prototype.initPagination=function(){var p,c,w;if(!this.options.pagination)return void this.$pagination.hide();this.$pagination.show();var s,r,f,v,l,a,y,e=this,t=[],h=!1,b=this.getData(),o=this.options.pageList;if(("server"!==this.options.sidePagination&&(this.options.totalRows=b.length),this.totalPages=0,this.options.totalRows)&&(this.options.pageSize===this.options.formatAllRows()?(this.options.pageSize=this.options.totalRows,h=!0):this.options.pageSize===this.options.totalRows&&(p="string"==typeof this.options.pageList?this.options.pageList.replace("[","").replace("]","").replace(/ /g,"").toLowerCase().split(","):this.options.pageList,n.inArray(this.options.formatAllRows().toLowerCase(),p)>-1&&(h=!0)),this.totalPages=~~((this.options.totalRows-1)/this.options.pageSize)+1,this.options.totalPages=this.totalPages),this.totalPages>0&&this.options.pageNumber>this.totalPages&&(this.options.pageNumber=this.totalPages),this.pageFrom=(this.options.pageNumber-1)*this.options.pageSize+1,this.pageTo=this.options.pageNumber*this.options.pageSize,this.pageTo>this.options.totalRows&&(this.pageTo=this.options.totalRows),t.push(i('<div class="%s-%s pagination-detail">',u.pullClass,this.options.paginationDetailHAlign),'<span class="pagination-info">',this.options.onlyInfoPagination?this.options.formatDetailPagination(this.options.totalRows):this.options.formatShowingRows(this.pageFrom,this.pageTo,this.options.totalRows),"<\/span>"),!this.options.onlyInfoPagination){for(t.push('<span class="page-list">'),c=[i('<span class="btn-group %s">',"top"===this.options.paginationVAlign||"both"===this.options.paginationVAlign?"dropdown":"dropup"),'<button type="button" class="btn'+i(" btn-%s",this.options.buttonsClass)+i(" btn-%s",this.options.iconSize)+' dropdown-toggle" data-toggle="dropdown">','<span class="page-size">',h?this.options.formatAllRows():this.options.pageSize,"<\/span>",' <span class="caret"><\/span>',"<\/button>",u.pageDropdownHtml[0]],"string"==typeof this.options.pageList&&(w=this.options.pageList.replace("[","").replace("]","").replace(/ /g,"").split(","),o=[],n.each(w,function(n,t){o.push(t.toUpperCase()===e.options.formatAllRows().toUpperCase()||"UNLIMITED"===t.toUpperCase()?e.options.formatAllRows():+t)})),n.each(o,function(n,t){if(!e.options.smartDisplay||0===n||o[n-1]<e.options.totalRows){var r;r=h?t===e.options.formatAllRows()?"active":"":t===e.options.pageSize?"active":"";c.push(i(u.pageDropdownItemHtml,r,t))}}),c.push(u.pageDropdownHtml[1]+"<\/span>"),t.push(this.options.formatRecordsPerPage(c.join(""))),t.push("<\/span>"),t.push("<\/div>",i('<div class="%s-%s pagination">',u.pullClass,this.options.paginationHAlign),'<ul class="pagination'+i(" pagination-%s",this.options.iconSize)+'">',i('<li class="page-item page-pre"><a class="page-link" href="#">%s<\/a><\/li>',this.options.paginationPreText)),this.totalPages<5?(r=1,f=this.totalPages):(r=this.options.pageNumber-2,f=r+4,1>r&&(r=1,f=5),f>this.totalPages&&(f=this.totalPages,r=f-4)),this.totalPages>=6&&(this.options.pageNumber>=3&&(t.push(i('<li class="page-item page-first%s">',1===this.options.pageNumber?" active":""),'<a class="page-link" href="#">',1,"<\/a>","<\/li>"),r++),this.options.pageNumber>=4&&(4==this.options.pageNumber||6==this.totalPages||7==this.totalPages?r--:t.push('<li class="page-item page-first-separator disabled">','<a class="page-link" href="#">...<\/a>',"<\/li>"),f--)),this.totalPages>=7&&this.options.pageNumber>=this.totalPages-2&&r--,6==this.totalPages?this.options.pageNumber>=this.totalPages-2&&f++:this.totalPages>=7&&(7==this.totalPages||this.options.pageNumber>=this.totalPages-3)&&f++,s=r;f>=s;s++)t.push(i('<li class="page-item%s">',s===this.options.pageNumber?" active":""),'<a class="page-link" href="#">',s,"<\/a>","<\/li>");this.totalPages>=8&&this.options.pageNumber<=this.totalPages-4&&t.push('<li class="page-item page-last-separator disabled">','<a class="page-link" href="#">...<\/a>',"<\/li>");this.totalPages>=6&&this.options.pageNumber<=this.totalPages-3&&t.push(i('<li class="page-item page-last%s">',this.totalPages===this.options.pageNumber?" active":""),'<a class="page-link" href="#">',this.totalPages,"<\/a>","<\/li>");t.push(i('<li class="page-item page-next"><a class="page-link" href="#">%s<\/a><\/li>',this.options.paginationNextText),"<\/ul>","<\/div>")}this.$pagination.html(t.join(""));this.options.onlyInfoPagination||(v=this.$pagination.find(".page-list a"),l=this.$pagination.find(".page-pre"),a=this.$pagination.find(".page-next"),y=this.$pagination.find(".page-item").not(".page-next, .page-pre"),this.options.smartDisplay&&(this.totalPages<=1&&this.$pagination.find("div.pagination").hide(),(o.length<2||this.options.totalRows<=o[0])&&this.$pagination.find("span.page-list").hide(),this.$pagination[this.getData().length?"show":"hide"]()),this.options.paginationLoop||(1===this.options.pageNumber&&l.addClass("disabled"),this.options.pageNumber===this.totalPages&&a.addClass("disabled")),h&&(this.options.pageSize=this.options.formatAllRows()),v.off("click").on("click",n.proxy(this.onPageListChange,this)),l.off("click").on("click",n.proxy(this.onPagePre,this)),a.off("click").on("click",n.proxy(this.onPageNext,this)),y.off("click").on("click",n.proxy(this.onPageNumber,this)))};t.prototype.updatePagination=function(t){t&&n(t.currentTarget).hasClass("disabled")||(this.options.maintainSelected||this.resetRows(),this.initPagination(),"server"===this.options.sidePagination?this.initServer():this.initBody(),this.trigger("page-change",this.options.pageNumber,this.options.pageSize))};t.prototype.onPageListChange=function(t){t.preventDefault();var i=n(t.currentTarget);return i.parent().addClass("active").siblings().removeClass("active"),this.options.pageSize=i.text().toUpperCase()===this.options.formatAllRows().toUpperCase()?this.options.formatAllRows():+i.text(),this.$toolbar.find(".page-size").text(this.options.pageSize),this.updatePagination(t),!1};t.prototype.onPagePre=function(n){return n.preventDefault(),this.options.pageNumber-1==0?this.options.pageNumber=this.options.totalPages:this.options.pageNumber--,this.updatePagination(n),!1};t.prototype.onPageNext=function(n){return n.preventDefault(),this.options.pageNumber+1>this.options.totalPages?this.options.pageNumber=1:this.options.pageNumber++,this.updatePagination(n),!1};t.prototype.onPageNumber=function(t){return t.preventDefault(),this.options.pageNumber!==+n(t.currentTarget).text()?(this.options.pageNumber=+n(t.currentTarget).text(),this.updatePagination(t),!1):void 0};t.prototype.initRow=function(t,u){var c,o=this,h=[],s={},a=[],v="",l={},p=[];if(!(n.inArray(t,this.hiddenRows)>-1)){if(s=r(this.options,this.options.rowStyle,[t,u],s),s&&s.css)for(c in s.css)a.push(c+": "+s.css[c]);if(l=r(this.options,this.options.rowAttributes,[t,u],l))for(c in l)p.push(i('%s="%s"',c,f(l[c])));return t._data&&!n.isEmptyObject(t._data)&&n.each(t._data,function(n,t){"index"!==n&&(v+=i(' data-%s="%s"',n,t))}),h.push("<tr",i(" %s",p.join(" ")),i(' id="%s"',n.isArray(t)?void 0:t._id),i(' class="%s"',s.classes||(n.isArray(t)?void 0:t._class)),i(' data-index="%s"',u),i(' data-uniqueid="%s"',t[this.options.uniqueId]),i("%s",v),">"),this.options.cardView&&h.push(i('<td colspan="%s"><div class="card-views">',this.header.fields.length)),!this.options.cardView&&this.options.detailView&&(h.push("<td>"),r(null,this.options.detailFilter,[u,t])&&h.push('<a class="detail-icon" href="#">',i('<i class="%s %s"><\/i>',this.options.iconsPrefix,this.options.icons.detailOpen),"<\/a>"),h.push("<\/td>")),n.each(this.header.fields,function(c,l){var d="",w=e(t,l,o.options.escape),v="",k="",b={},it="",g=o.header.classes[c],rt="",ut="",ft="",et="",p=o.columns[c],nt,tt;if((!o.fromHtml||"undefined"!=typeof w||p.checkbox||p.radio)&&p.visible&&(!o.options.cardView||p.cardVisible)){if(p.escape&&(w=f(w)),s=i('style="%s"',a.concat(o.header.styles[c]).join("; ")),t["_"+l+"_id"]&&(it=i(' id="%s"',t["_"+l+"_id"])),t["_"+l+"_class"]&&(g=i(' class="%s"',t["_"+l+"_class"])),t["_"+l+"_rowspan"]&&(ut=i(' rowspan="%s"',t["_"+l+"_rowspan"])),t["_"+l+"_colspan"]&&(ft=i(' colspan="%s"',t["_"+l+"_colspan"])),t["_"+l+"_title"]&&(et=i(' title="%s"',t["_"+l+"_title"])),b=r(o.header,o.header.cellStyles[c],[w,t,u,l],b),b.classes&&(g=i(' class="%s"',b.classes)),b.css){nt=[];for(tt in b.css)nt.push(tt+": "+b.css[tt]);s=i('style="%s"',nt.concat(o.header.styles[c]).join("; "))}v=r(p,o.header.formatters[c],[w,t,u,l],w);t["_"+l+"_data"]&&!n.isEmptyObject(t["_"+l+"_data"])&&n.each(t["_"+l+"_data"],function(n,t){"index"!==n&&(rt+=i(' data-%s="%s"',n,t))});p.checkbox||p.radio?(k=p.checkbox?"checkbox":k,k=p.radio?"radio":k,d=[i(o.options.cardView?'<div class="card-view %s">':'<td class="bs-checkbox %s">',p["class"]||""),"<input"+i(' data-index="%s"',u)+i(' name="%s"',o.options.selectItemName)+i(' type="%s"',k)+i(' value="%s"',t[o.options.idField])+i(' checked="%s"',v===!0||w||v&&v.checked?"checked":void 0)+i(' disabled="%s"',!p.checkboxEnabled||v&&v.disabled?"disabled":void 0)+" />",o.header.formatters[c]&&"string"==typeof v?v:"",o.options.cardView?"<\/div>":"<\/td>"].join(""),t[o.header.stateField]=v===!0||!!w||v&&v.checked):(v="undefined"==typeof v||null===v?o.options.undefinedText:v,d=o.options.cardView?['<div class="card-view">',o.options.showHeader?i('<span class="title" %s>%s<\/span>',s,y(o.columns,"field","title",l)):"",i('<span class="value">%s<\/span>',v),"<\/div>"].join(""):[i("<td%s %s %s %s %s %s %s>",it,g,s,rt,ut,ft,et),v,"<\/td>"].join(""),o.options.cardView&&o.options.smartDisplay&&""===v&&(d='<div class="card-view"><\/div>'));h.push(d)}}),this.options.cardView&&h.push("<\/div><\/td>"),h.push("<\/tr>"),h.join(" ")}};t.prototype.initBody=function(t){var u=this,f=this.getData(),c,o,s,l,h;for(this.trigger("pre-body",f),this.$body=this.$el.find(">tbody"),this.$body.length||(this.$body=n("<tbody><\/tbody>").appendTo(this.$el)),this.options.pagination&&"server"!==this.options.sidePagination||(this.pageFrom=1,this.pageTo=f.length),o=n(document.createDocumentFragment()),s=this.pageFrom-1;s<this.pageTo;s++)l=f[s],h=this.initRow(l,s,f,o),c=c||!!h,h&&h!==!0&&o.append(h);c||o.append('<tr class="no-records-found">'+i('<td colspan="%s">%s<\/td>',this.$header.find("th").length,this.options.formatNoMatches())+"<\/tr>");this.$body.html(o);t||this.scrollTo(0);this.$body.find("> tr[data-index] > td").off("click dblclick").on("click dblclick",function(t){var r=n(this),o=r.parent(),s=u.data[o.data("index")],c=r[0].cellIndex,l=u.getVisibleFields(),f=l[u.options.detailView&&!u.options.cardView?c-1:c],a=u.columns[u.fieldsColumnsIndex[f]],v=e(s,f,u.options.escape),h;!r.find(".detail-icon").length&&(u.trigger("click"===t.type?"click-cell":"dbl-click-cell",f,v,s,r),u.trigger("click"===t.type?"click-row":"dbl-click-row",s,o,f),"click"===t.type&&u.options.clickToSelect&&a.clickToSelect&&u.options.ignoreClickToSelectOn(t.target))&&(h=o.find(i('[name="%s"]',u.options.selectItemName)),h.length&&h[0].click())});this.$body.find("> tr[data-index] > td > .detail-icon").off("click").on("click",function(t){var o,l;t.preventDefault();var h=n(this),e=h.parent().parent(),s=e.data("index"),c=f[s];return e.next().is("tr.detail-view")?(h.find("i").attr("class",i("%s %s",u.options.iconsPrefix,u.options.icons.detailOpen)),u.trigger("collapse-row",s,c,e.next()),e.next().remove()):(h.find("i").attr("class",i("%s %s",u.options.iconsPrefix,u.options.icons.detailClose)),e.after(i('<tr class="detail-view"><td colspan="%s"><\/td><\/tr>',e.find("td").length)),o=e.next().find("td"),l=r(u.options,u.options.detailFormatter,[s,c,o],""),1===o.length&&o.append(l),u.trigger("expand-row",s,c,o)),u.resetView(),!1});this.$selectItem=this.$body.find(i('[name="%s"]',this.options.selectItemName));this.$selectItem.off("click").on("click",function(t){t.stopImmediatePropagation();var i=n(this),r=i.prop("checked"),f=u.data[i.data("index")];(n(this).is(":radio")||u.options.singleSelect)&&n.each(u.options.data,function(n,t){t[u.header.stateField]=!1});f[u.header.stateField]=r;u.options.singleSelect&&(u.$selectItem.not(this).each(function(){u.data[n(this).data("index")][u.header.stateField]=!1}),u.$selectItem.filter(":checked").not(this).prop("checked",!1));u.updateSelected();u.trigger(r?"check":"uncheck",f,i)});n.each(this.header.events,function(t,i){var o,e,f;if(i&&("string"==typeof i&&(i=r(null,i)),o=u.header.fields[t],e=n.inArray(o,u.getVisibleFields()),-1!==e)){u.options.detailView&&!u.options.cardView&&(e+=1);for(f in i)u.$body.find(">tr:not(.no-records-found)").each(function(){var t=n(this),h=t.find(u.options.cardView?".card-view":"td").eq(e),r=f.indexOf(" "),s=f.substring(0,r),c=f.substring(r+1),l=i[f];h.find(c).off(s).on(s,function(n){var i=t.data("index"),r=u.data[i],f=r[o];l.apply(this,[n,f,r,i])})})}});this.updateSelected();this.resetView();this.trigger("post-body",f)};t.prototype.initServer=function(t,i,u){var s,e=this,o={},h=n.inArray(this.options.sortName,this.header.fields),f={searchText:this.searchText,sortName:this.options.sortName,sortOrder:this.options.sortOrder};this.header.sortNames[h]&&(f.sortName=this.header.sortNames[h]);this.options.pagination&&"server"===this.options.sidePagination&&(f.pageSize=this.options.pageSize===this.options.formatAllRows()?this.options.totalRows:this.options.pageSize,f.pageNumber=this.options.pageNumber);(u||this.options.url||this.options.ajax)&&("limit"===this.options.queryParamsType&&(f={search:f.searchText,sort:f.sortName,order:f.sortOrder},this.options.pagination&&"server"===this.options.sidePagination&&(f.offset=this.options.pageSize===this.options.formatAllRows()?0:this.options.pageSize*(this.options.pageNumber-1),f.limit=this.options.pageSize===this.options.formatAllRows()?this.options.totalRows:this.options.pageSize,0===f.limit&&delete f.limit)),n.isEmptyObject(this.filterColumnsPartial)||(f.filter=JSON.stringify(this.filterColumnsPartial,null)),o=r(this.options,this.options.queryParams,[f],o),n.extend(o,i||{}),o!==!1&&(t||this.$tableLoading.show(),s=n.extend({},r(null,this.options.ajaxOptions),{type:this.options.method,url:u||this.options.url,data:"application/json"===this.options.contentType&&"post"===this.options.method?JSON.stringify(o):o,cache:this.options.cache,contentType:this.options.contentType,dataType:this.options.dataType,success:function(n){n=r(e.options,e.options.responseHandler,[n],n);e.load(n);e.trigger("load-success",n);t||e.$tableLoading.hide()},error:function(n){var i=[];"server"===e.options.sidePagination&&(i={},i[e.options.totalField]=0,i[e.options.dataField]=[]);e.load(i);e.trigger("load-error",n.status,n);t||e.$tableLoading.hide()}}),this.options.ajax?r(this,this.options.ajax,[s],null):(this._xhr&&4!==this._xhr.readyState&&this._xhr.abort(),this._xhr=n.ajax(s))))};t.prototype.initSearchText=function(){if(this.options.search&&(this.searchText="",""!==this.options.searchText)){var n=this.$toolbar.find(".search input");n.val(this.options.searchText);this.onSearch({currentTarget:n,firedByInitSearchText:!0})}};t.prototype.getCaret=function(){var t=this;n.each(this.$header.find("th"),function(i,r){n(r).find(".sortable").removeClass("desc asc").addClass(n(r).data("field")===t.options.sortName?t.options.sortOrder:"both")})};t.prototype.updateSelected=function(){var t=this.$selectItem.filter(":enabled").length&&this.$selectItem.filter(":enabled").length===this.$selectItem.filter(":enabled").filter(":checked").length;this.$selectAll.add(this.$selectAll_).prop("checked",t);this.$selectItem.each(function(){n(this).closest("tr")[n(this).prop("checked")?"addClass":"removeClass"]("selected")})};t.prototype.updateRows=function(){var t=this;this.$selectItem.each(function(){t.data[n(this).data("index")][t.header.stateField]=n(this).prop("checked")})};t.prototype.resetRows=function(){var t=this;n.each(this.data,function(n,i){t.$selectAll.prop("checked",!1);t.$selectItem.prop("checked",!1);t.header.stateField&&(i[t.header.stateField]=!1)});this.initHiddenRows()};t.prototype.trigger=function(i){var r=Array.prototype.slice.call(arguments,1);i+=".bs.table";this.options[t.EVENTS[i]].apply(this.options,r);this.$el.trigger(n.Event(i),r);this.options.onAll(i,r);this.$el.trigger(n.Event("all.bs.table"),[i,r])};t.prototype.resetHeader=function(){clearTimeout(this.timeoutId_);this.timeoutId_=setTimeout(n.proxy(this.fitHeader,this),this.$el.is(":hidden")?100:0)};t.prototype.fitHeader=function(){var r,h,u,f,t=this,e,o,s,l,a;if(t.$el.is(":hidden"))return void(t.timeoutId_=setTimeout(n.proxy(t.fitHeader,t),100));(r=this.$tableBody.get(0),h=r.scrollWidth>r.clientWidth&&r.scrollHeight>r.clientHeight+this.$header.outerHeight()?c():0,this.$el.css("margin-top",-this.$header.outerHeight()),u=n(":focus"),u.length>0)&&(e=u.parents("th"),e.length>0&&(o=e.attr("data-field"),void 0!==o&&(s=this.$header.find("[data-field='"+o+"']"),s.length>0&&s.find(":input").addClass("focus-temp"))));this.$header_=this.$header.clone(!0,!0);this.$selectAll_=this.$header_.find('[name="btSelectAll"]');this.$tableHeader.css({"margin-right":h}).find("table").css("width",this.$el.outerWidth()).html("").attr("class",this.$el.attr("class")).append(this.$header_);f=n(".focus-temp:visible:eq(0)");f.length>0&&(f.focus(),this.$header.find(".focus-temp").removeClass("focus-temp"));this.$header.find("th[data-field]").each(function(){t.$header_.find(i('th[data-field="%s"]',n(this).data("field"))).data(n(this).data())});l=this.getVisibleFields();a=this.$header_.find("th");this.$body.find(">tr:first-child:not(.no-records-found) > *").each(function(r){var f=n(this),e=r,u,o;(t.options.detailView&&!t.options.cardView&&(0===r&&t.$header_.find("th.detail").find(".fht-cell").width(f.innerWidth()),e=r-1),-1!==e)&&(u=t.$header_.find(i('th[data-field="%s"]',l[e])),u.length>1&&(u=n(a[f[0].cellIndex])),o=u.width()-u.find(".fht-cell").width(),u.find(".fht-cell").width(f.innerWidth()-o))});this.horizontalScroll();this.trigger("post-header")};t.prototype.resetFooter=function(){var u=this,f=u.getData(),t=[];this.options.showFooter&&!this.options.cardView&&(!this.options.cardView&&this.options.detailView&&t.push('<td><div class="th-inner">&nbsp;<\/div><div class="fht-cell"><\/div><\/td>'),n.each(this.columns,function(n,e){var s,h="",c="",l=[],o={},a=i(' class="%s"',e["class"]);if(e.visible&&(!u.options.cardView||e.cardVisible)){if(h=i("text-align: %s; ",e.falign?e.falign:e.align),c=i("vertical-align: %s; ",e.valign),o=r(null,u.options.footerStyle),o&&o.css)for(s in o.css)l.push(s+": "+o.css[s]);t.push("<td",a,i(' style="%s"',h+c+l.concat().join("; ")),">");t.push('<div class="th-inner">');t.push(r(e,e.footerFormatter,[f],"&nbsp;")||"&nbsp;");t.push("<\/div>");t.push('<div class="fht-cell"><\/div>');t.push("<\/div>");t.push("<\/td>")}}),this.$tableFooter.find("tr").html(t.join("")),this.$tableFooter.show(),clearTimeout(this.timeoutFooter_),this.timeoutFooter_=setTimeout(n.proxy(this.fitFooter,this),this.$el.is(":hidden")?100:0))};t.prototype.fitFooter=function(){var i,t,r;return clearTimeout(this.timeoutFooter_),this.$el.is(":hidden")?void(this.timeoutFooter_=setTimeout(n.proxy(this.fitFooter,this),100)):(t=this.$el.css("width"),r=t>this.$tableBody.width()?c():0,this.$tableFooter.css({"margin-right":r}).find("table").css("width",t).attr("class",this.$el.attr("class")),i=this.$tableFooter.find("td"),this.$body.find(">tr:first-child:not(.no-records-found) > *").each(function(t){var r=n(this);i.eq(t).find(".fht-cell").width(r.innerWidth())}),void this.horizontalScroll())};t.prototype.horizontalScroll=function(){var t=this;t.trigger("scroll-body");this.$tableBody.off("scroll").on("scroll",function(){t.options.showHeader&&t.options.height&&t.$tableHeader.scrollLeft(n(this).scrollLeft());t.options.showFooter&&!t.options.cardView&&t.$tableFooter.scrollLeft(n(this).scrollLeft())})};t.prototype.toggleColumn=function(n,t,r){if(-1!==n&&(this.columns[n].visible=t,this.initHeader(),this.initSearch(),this.initPagination(),this.initBody(),this.options.showColumns)){var u=this.$toolbar.find(".keep-open input").prop("disabled",!1);r&&u.filter(i('[value="%s"]',n)).prop("checked",t);u.filter(":checked").length<=this.options.minimumCountColumns&&u.filter(":checked").prop("disabled",!0)}};t.prototype.getVisibleFields=function(){var t=this,i=[];return n.each(this.header.fields,function(n,r){var u=t.columns[t.fieldsColumnsIndex[r]];u.visible&&i.push(r)}),i};t.prototype.resetView=function(n){var t=0;if(n&&n.height&&(this.options.height=n.height),this.$selectAll.prop("checked",this.$selectItem.length>0&&this.$selectItem.length===this.$selectItem.filter(":checked").length),this.options.height){var i=this.$toolbar.outerHeight(!0),r=this.$pagination.outerHeight(!0),u=this.options.height-i-r;this.$tableContainer.css("height",u+"px")}return this.options.cardView?(this.$el.css("margin-top","0"),this.$tableContainer.css("padding-bottom","0"),void this.$tableFooter.hide()):(this.options.showHeader&&this.options.height?(this.$tableHeader.show(),this.resetHeader(),t+=this.$header.outerHeight()):(this.$tableHeader.hide(),this.trigger("post-header")),this.options.showFooter&&(this.resetFooter(),this.options.height&&(t+=this.$tableFooter.outerHeight()+1)),this.getCaret(),this.$tableContainer.css("padding-bottom",t+"px"),void this.trigger("reset-view"))};t.prototype.getData=function(t){var i=this.options.data;return(this.searchText||this.options.sortName||!n.isEmptyObject(this.filterColumns)||!n.isEmptyObject(this.filterColumnsPartial))&&(i=this.data),t?i.slice(this.pageFrom-1,this.pageTo):i};t.prototype.load=function(t){var i=!1;this.options.pagination&&"server"===this.options.sidePagination?(this.options.totalRows=t[this.options.totalField],i=t.fixedScroll,t=t[this.options.dataField]):n.isArray(t)||(i=t.fixedScroll,t=t.data);this.initData(t);this.initSearch();this.initPagination();this.initBody(i)};t.prototype.append=function(n){this.initData(n,"append");this.initSearch();this.initPagination();this.initSort();this.initBody(!0)};t.prototype.prepend=function(n){this.initData(n,"prepend");this.initSearch();this.initPagination();this.initSort();this.initBody(!0)};t.prototype.remove=function(t){var i,r,u=this.options.data.length;if(t.hasOwnProperty("field")&&t.hasOwnProperty("values")){for(i=u-1;i>=0;i--)r=this.options.data[i],r.hasOwnProperty(t.field)&&-1!==n.inArray(r[t.field],t.values)&&(this.options.data.splice(i,1),"server"===this.options.sidePagination&&(this.options.totalRows-=1));u!==this.options.data.length&&(this.initSearch(),this.initPagination(),this.initSort(),this.initBody(!0))}};t.prototype.removeAll=function(){this.options.data.length>0&&(this.options.data.splice(0,this.options.data.length),this.initSearch(),this.initPagination(),this.initBody(!0))};t.prototype.getRowByUniqueId=function(n){for(var i,t,u=this.options.uniqueId,e=this.options.data.length,f=null,r=e-1;r>=0;r--){if(i=this.options.data[r],i.hasOwnProperty(u))t=i[u];else{if(!i._data.hasOwnProperty(u))continue;t=i._data[u]}if("string"==typeof t?n=n.toString():"number"==typeof t&&(Number(t)===t&&t%1==0?n=parseInt(n):t===Number(t)&&0!==t&&(n=parseFloat(n))),t===n){f=i;break}}return f};t.prototype.removeByUniqueId=function(n){var i=this.options.data.length,t=this.getRowByUniqueId(n);t&&this.options.data.splice(this.options.data.indexOf(t),1);i!==this.options.data.length&&(this.initSearch(),this.initPagination(),this.initBody(!0))};t.prototype.updateByUniqueId=function(t){var i=this,r=n.isArray(t)?t:[t];n.each(r,function(t,r){var u;r.hasOwnProperty("id")&&r.hasOwnProperty("row")&&(u=n.inArray(i.getRowByUniqueId(r.id),i.options.data),-1!==u&&n.extend(i.options.data[u],r.row))});this.initSearch();this.initPagination();this.initSort();this.initBody(!0)};t.prototype.refreshColumnTitle=function(t){if(t.hasOwnProperty("field")&&t.hasOwnProperty("title")&&(this.columns[this.fieldsColumnsIndex[t.field]].title=this.options.escape?f(t.title):t.title,this.columns[this.fieldsColumnsIndex[t.field]].visible)){var i=void 0!==this.options.height?this.$tableHeader:this.$header;i.find("th[data-field]").each(function(){if(n(this).data("field")===t.field)return(n(n(this).find(".th-inner")[0]).text(t.title),!1)})}};t.prototype.insertRow=function(n){n.hasOwnProperty("index")&&n.hasOwnProperty("row")&&(this.options.data.splice(n.index,0,n.row),this.initSearch(),this.initPagination(),this.initSort(),this.initBody(!0))};t.prototype.updateRow=function(t){var i=this,r=n.isArray(t)?t:[t];n.each(r,function(t,r){r.hasOwnProperty("index")&&r.hasOwnProperty("row")&&n.extend(i.options.data[r.index],r.row)});this.initSearch();this.initPagination();this.initSort();this.initBody(!0)};t.prototype.initHiddenRows=function(){this.hiddenRows=[]};t.prototype.showRow=function(n){this.toggleRow(n,!0)};t.prototype.hideRow=function(n){this.toggleRow(n,!1)};t.prototype.toggleRow=function(t,i){var r,u;t.hasOwnProperty("index")?r=this.getData()[t.index]:t.hasOwnProperty("uniqueId")&&(r=this.getRowByUniqueId(t.uniqueId));r&&(u=n.inArray(r,this.hiddenRows),i||-1!==u?i&&u>-1&&this.hiddenRows.splice(u,1):this.hiddenRows.push(r),this.initBody(!0))};t.prototype.getHiddenRows=function(){var i=this,r=this.getData(),t=[];return n.each(r,function(r,u){n.inArray(u,i.hiddenRows)>-1&&t.push(u)}),this.hiddenRows=t,t};t.prototype.mergeCells=function(t){var u,f,e,i=t.index,r=n.inArray(t.field,this.getVisibleFields()),o=t.rowspan||1,s=t.colspan||1,h=this.$body.find(">tr");if(this.options.detailView&&!this.options.cardView&&(r+=1),e=h.eq(i).find(">td").eq(r),!(0>i||0>r||i>=this.data.length)){for(u=i;i+o>u;u++)for(f=r;r+s>f;f++)h.eq(u).find(">td").eq(f).hide();e.attr("rowspan",o).attr("colspan",s).show()}};t.prototype.updateCell=function(n){n.hasOwnProperty("index")&&n.hasOwnProperty("field")&&n.hasOwnProperty("value")&&(this.data[n.index][n.field]=n.value,n.reinit!==!1&&(this.initSort(),this.initBody(!0)))};t.prototype.updateCellById=function(t){var i=this,r;t.hasOwnProperty("id")&&t.hasOwnProperty("field")&&t.hasOwnProperty("value")&&(r=n.isArray(t)?t:[t],n.each(r,function(t,r){var u;u=n.inArray(i.getRowByUniqueId(r.id),i.options.data);-1!==u&&(i.data[u][r.field]=r.value)}),t.reinit!==!1&&(this.initSort(),this.initBody(!0)))};t.prototype.getOptions=function(){return n.extend(!0,{},this.options)};t.prototype.getSelections=function(){var t=this;return n.grep(this.options.data,function(n){return n[t.header.stateField]===!0})};t.prototype.getAllSelections=function(){var t=this;return n.grep(this.options.data,function(n){return n[t.header.stateField]})};t.prototype.checkAll=function(){this.checkAll_(!0)};t.prototype.uncheckAll=function(){this.checkAll_(!1)};t.prototype.checkInvert=function(){var t=this,r=t.$selectItem.filter(":enabled"),i=r.filter(":checked");r.each(function(){n(this).prop("checked",!n(this).prop("checked"))});t.updateRows();t.updateSelected();t.trigger("uncheck-some",i);i=t.getSelections();t.trigger("check-some",i)};t.prototype.checkAll_=function(n){var t;n||(t=this.getSelections());this.$selectAll.add(this.$selectAll_).prop("checked",n);this.$selectItem.filter(":enabled").prop("checked",n);this.updateRows();n&&(t=this.getSelections());this.trigger(n?"check-all":"uncheck-all",t)};t.prototype.check=function(n){this.check_(!0,n)};t.prototype.uncheck=function(n){this.check_(!1,n)};t.prototype.check_=function(n,t){var r=this.$selectItem.filter(i('[data-index="%s"]',t)).prop("checked",n);this.data[t][this.header.stateField]=n;this.updateSelected();this.trigger(n?"check":"uncheck",this.data[t],r)};t.prototype.checkBy=function(n){this.checkBy_(!0,n)};t.prototype.uncheckBy=function(n){this.checkBy_(!1,n)};t.prototype.checkBy_=function(t,r){if(r.hasOwnProperty("field")&&r.hasOwnProperty("values")){var u=this,f=[];n.each(this.options.data,function(e,o){if(!o.hasOwnProperty(r.field))return!1;if(-1!==n.inArray(o[r.field],r.values)){var s=u.$selectItem.filter(":enabled").filter(i('[data-index="%s"]',e)).prop("checked",t);o[u.header.stateField]=t;f.push(o);u.trigger(t?"check":"uncheck",o,s)}});this.updateSelected();this.trigger(t?"check-some":"uncheck-some",f)}};t.prototype.destroy=function(){this.$el.insertBefore(this.$container);n(this.options.toolbar).insertBefore(this.$el);this.$container.next().remove();this.$container.remove();this.$el.html(this.$el_.html()).css("margin-top","0").attr("class",this.$el_.attr("class")||"")};t.prototype.showLoading=function(){this.$tableLoading.show()};t.prototype.hideLoading=function(){this.$tableLoading.hide()};t.prototype.togglePagination=function(){this.options.pagination=!this.options.pagination;var n=this.$toolbar.find('button[name="paginationSwitch"] i');this.options.pagination?n.attr("class",this.options.iconsPrefix+" "+this.options.icons.paginationSwitchDown):n.attr("class",this.options.iconsPrefix+" "+this.options.icons.paginationSwitchUp);this.updatePagination()};t.prototype.toggleFullscreen=function(){this.$el.closest(".bootstrap-table").toggleClass("fullscreen")};t.prototype.refresh=function(n){n&&n.url&&(this.options.url=n.url);n&&n.pageNumber&&(this.options.pageNumber=n.pageNumber);n&&n.pageSize&&(this.options.pageSize=n.pageSize);this.initServer(n&&n.silent,n&&n.query,n&&n.url);this.trigger("refresh",n)};t.prototype.resetWidth=function(){this.options.showHeader&&this.options.height&&this.fitHeader();this.options.showFooter&&!this.options.cardView&&this.fitFooter()};t.prototype.showColumn=function(n){this.toggleColumn(this.fieldsColumnsIndex[n],!0,!0)};t.prototype.hideColumn=function(n){this.toggleColumn(this.fieldsColumnsIndex[n],!1,!0)};t.prototype.getHiddenColumns=function(){return n.grep(this.columns,function(n){return!n.visible})};t.prototype.getVisibleColumns=function(){return n.grep(this.columns,function(n){return n.visible})};t.prototype.toggleAllColumns=function(t){var r=this,i;(n.each(this.columns,function(n){r.columns[n].visible=t}),this.initHeader(),this.initSearch(),this.initPagination(),this.initBody(),this.options.showColumns)&&(i=this.$toolbar.find(".keep-open input").prop("disabled",!1),i.filter(":checked").length<=this.options.minimumCountColumns&&i.filter(":checked").prop("disabled",!0))};t.prototype.showAllColumns=function(){this.toggleAllColumns(!0)};t.prototype.hideAllColumns=function(){this.toggleAllColumns(!1)};t.prototype.filterBy=function(t){this.filterColumns=n.isEmptyObject(t)?{}:t;this.options.pageNumber=1;this.initSearch();this.updatePagination()};t.prototype.scrollTo=function(n){return"string"==typeof n&&(n="bottom"===n?this.$tableBody[0].scrollHeight:0),"number"==typeof n&&this.$tableBody.scrollTop(n),"undefined"==typeof n?this.$tableBody.scrollTop():void 0};t.prototype.getScrollPosition=function(){return this.scrollTo()};t.prototype.selectPage=function(n){n>0&&n<=this.options.totalPages&&(this.options.pageNumber=n,this.updatePagination())};t.prototype.prevPage=function(){this.options.pageNumber>1&&(this.options.pageNumber--,this.updatePagination())};t.prototype.nextPage=function(){this.options.pageNumber<this.options.totalPages&&(this.options.pageNumber++,this.updatePagination())};t.prototype.toggleView=function(){this.options.cardView=!this.options.cardView;this.initHeader();var n=this.$toolbar.find('button[name="toggle"] i');this.options.cardView?(n.removeClass(this.options.icons.toggleOff),n.addClass(this.options.icons.toggleOn)):(n.removeClass(this.options.icons.toggleOn),n.addClass(this.options.icons.toggleOff));this.initBody();this.trigger("toggle",this.options.cardView)};t.prototype.refreshOptions=function(t){l(this.options,t,!0)||(this.options=n.extend(this.options,t),this.trigger("refresh-options",this.options),this.destroy(),this.init())};t.prototype.resetSearch=function(n){var t=this.$toolbar.find(".search input");t.val(n||"");this.onSearch({currentTarget:t})};t.prototype.expandRow_=function(n,t){var r=this.$body.find(i('> tr[data-index="%s"]',t));r.next().is("tr.detail-view")===(n?!1:!0)&&r.find("> td > .detail-icon").click()};t.prototype.expandRow=function(n){this.expandRow_(!0,n)};t.prototype.collapseRow=function(n){this.expandRow_(!1,n)};t.prototype.expandAllRows=function(t){var s,u;if(t){var r=this.$body.find(i('> tr[data-index="%s"]',0)),h=this,f=null,e=!1,o=-1;if(r.next().is("tr.detail-view")?r.next().next().is("tr.detail-view")||(r.next().find(".detail-icon").click(),e=!0):(r.find("> td > .detail-icon").click(),e=!0),e)try{o=setInterval(function(){f=h.$body.find("tr.detail-view").last().find(".detail-icon");f.length>0?f.click():clearInterval(o)},1)}catch(c){clearInterval(o)}}else for(s=this.$body.children(),u=0;u<s.length;u++)this.expandRow_(!0,n(s[u]).data("index"))};t.prototype.collapseAllRows=function(t){if(t)this.expandRow_(!1,0);else for(var r=this.$body.children(),i=0;i<r.length;i++)this.expandRow_(!1,n(r[i]).data("index"))};t.prototype.updateFormatText=function(n,t){this.options[i("format%s",n)]&&("string"==typeof t?this.options[i("format%s",n)]=function(){return t}:"function"==typeof t&&(this.options[i("format%s",n)]=t));this.initToolbar();this.initPagination();this.initBody()};h=["getOptions","getSelections","getAllSelections","getData","load","append","prepend","remove","removeAll","insertRow","updateRow","updateCell","updateByUniqueId","removeByUniqueId","getRowByUniqueId","showRow","hideRow","getHiddenRows","mergeCells","refreshColumnTitle","checkAll","uncheckAll","checkInvert","check","uncheck","checkBy","uncheckBy","refresh","resetView","resetWidth","destroy","showLoading","hideLoading","showColumn","hideColumn","getHiddenColumns","getVisibleColumns","showAllColumns","hideAllColumns","filterBy","scrollTo","getScrollPosition","selectPage","prevPage","nextPage","togglePagination","toggleView","refreshOptions","resetSearch","expandRow","collapseRow","expandAllRows","collapseAllRows","updateFormatText","updateCellById"];n.fn.bootstrapTable=function(i){var r,u=Array.prototype.slice.call(arguments,1);return this.each(function(){var e=n(this),f=e.data("bootstrap.table"),o=n.extend({},t.DEFAULTS,e.data(),"object"==typeof i&&i);if("string"==typeof i){if(n.inArray(i,h)<0)throw new Error("Unknown method: "+i);if(!f)return;r=f[i].apply(f,u);"destroy"===i&&e.removeData("bootstrap.table")}f||e.data("bootstrap.table",f=new t(this,o))}),"undefined"==typeof r?this:r};n.fn.bootstrapTable.Constructor=t;n.fn.bootstrapTable.defaults=t.DEFAULTS;n.fn.bootstrapTable.columnDefaults=t.COLUMN_DEFAULTS;n.fn.bootstrapTable.locales=t.LOCALES;n.fn.bootstrapTable.methods=h;n.fn.bootstrapTable.utils={bootstrapVersion:o,sprintf:i,compareObjects:l,calculateObjectValue:r,getItemField:e,objectKeys:w,isIEBrowser:v};n(function(){n('[data-toggle="table"]').bootstrapTable()})}(jQuery);!function(n){"use strict";n.fn.bootstrapTable.locales["zh-CN"]={formatLoadingMessage:function(){return"正在努力地加载数据中,请稍候……"},formatRecordsPerPage:function(n){return"每页显示 "+n+" 条记录"},formatShowingRows:function(n,t,i){return"显示第 "+n+" 到第 "+t+" 条记录,总共 "+i+" 条记录"},formatSearch:function(){return"搜索"},formatNoMatches:function(){return"没有找到匹配的记录"},formatPaginationSwitch:function(){return"隐藏/显示分页"},formatRefresh:function(){return"刷新"},formatToggle:function(){return"切换"},formatColumns:function(){return"列"},formatExport:function(){return"导出数据"},formatClearFilters:function(){return"清空过滤"}};n.extend(n.fn.bootstrapTable.defaults,n.fn.bootstrapTable.locales["zh-CN"])}(jQuery);

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。