Files
fast/public/assets/libs/bootstrap-table/dist/extensions/i18n-enhance/bootstrap-table-i18n-enhance.js
xiadc c6a4e1f5f6 init
- 框架初始化
 - 安装插件
 - 修复PHP8.4报错
2025-04-19 17:21:20 +08:00

34 lines
759 B
JavaScript

/**
* @author: Jewway
* @version: v1.0.0
*/
!function ($) {
'use strict';
var BootstrapTable = $.fn.bootstrapTable.Constructor;
BootstrapTable.prototype.changeTitle = function (locale) {
$.each(this.options.columns, function (idx, columnList) {
$.each(columnList, function (idx, column) {
if (column.field) {
column.title = locale[column.field];
}
});
});
this.initHeader();
this.initBody();
this.initToolbar();
};
BootstrapTable.prototype.changeLocale = function (localeId) {
this.options.locale = localeId;
this.initLocale();
this.initPagination();
};
$.fn.bootstrapTable.methods.push('changeTitle');
$.fn.bootstrapTable.methods.push('changeLocale');
}(jQuery);