|
@@ -155,9 +155,8 @@
|
|
|
pageSize: 10,
|
|
pageSize: 10,
|
|
|
pageList: [10, 25, 50, 100],
|
|
pageList: [10, 25, 50, 100],
|
|
|
paginationHAlign: 'right', //right, left
|
|
paginationHAlign: 'right', //right, left
|
|
|
- paginationVAlign: 'bottom', //bottom, top
|
|
|
|
|
|
|
+ paginationVAlign: 'bottom', //bottom, top, both
|
|
|
paginationDetailHAlign: 'left', //right, left
|
|
paginationDetailHAlign: 'left', //right, left
|
|
|
- paginationDetailVAlign: 'bottom', //bottom, top
|
|
|
|
|
search: false,
|
|
search: false,
|
|
|
searchAlign: 'right',
|
|
searchAlign: 'right',
|
|
|
selectItemName: 'btSelectItem',
|
|
selectItemName: 'btSelectItem',
|
|
@@ -356,6 +355,9 @@
|
|
|
this.$container = $([
|
|
this.$container = $([
|
|
|
'<div class="bootstrap-table">',
|
|
'<div class="bootstrap-table">',
|
|
|
'<div class="fixed-table-toolbar"></div>',
|
|
'<div class="fixed-table-toolbar"></div>',
|
|
|
|
|
+ this.options.paginationVAlign === 'top' || this.options.paginationVAlign === 'both' ?
|
|
|
|
|
+ '<div class="fixed-table-pagination" style="clear: both;"></div>' :
|
|
|
|
|
+ '',
|
|
|
'<div class="fixed-table-container">',
|
|
'<div class="fixed-table-container">',
|
|
|
'<div class="fixed-table-header"><table></table></div>',
|
|
'<div class="fixed-table-header"><table></table></div>',
|
|
|
'<div class="fixed-table-body">',
|
|
'<div class="fixed-table-body">',
|
|
@@ -364,7 +366,9 @@
|
|
|
'</div>',
|
|
'</div>',
|
|
|
'</div>',
|
|
'</div>',
|
|
|
'<div class="fixed-table-footer"><table><tr></tr></table></div>',
|
|
'<div class="fixed-table-footer"><table><tr></tr></table></div>',
|
|
|
- '<div class="fixed-table-pagination"></div>',
|
|
|
|
|
|
|
+ this.options.paginationVAlign === 'bottom' || this.options.paginationVAlign === 'both' ?
|
|
|
|
|
+ '<div class="fixed-table-pagination"></div>' :
|
|
|
|
|
+ '',
|
|
|
'</div>',
|
|
'</div>',
|
|
|
'</div>'].join(''));
|
|
'</div>'].join(''));
|
|
|
|
|
|
|
@@ -805,11 +809,7 @@
|
|
|
if (this.options.showToggle) {
|
|
if (this.options.showToggle) {
|
|
|
this.$toolbar.find('button[name="toggle"]')
|
|
this.$toolbar.find('button[name="toggle"]')
|
|
|
.off('click').on('click', function () {
|
|
.off('click').on('click', function () {
|
|
|
- that.options.cardView = !that.options.cardView;
|
|
|
|
|
- that.initHeader();
|
|
|
|
|
- // Fixed remove toolbar when click cardView button.
|
|
|
|
|
- //that.initToolbar();
|
|
|
|
|
- that.initBody();
|
|
|
|
|
|
|
+ that.toggleView();
|
|
|
});
|
|
});
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -1017,7 +1017,8 @@
|
|
|
html.push('<span class="page-list">');
|
|
html.push('<span class="page-list">');
|
|
|
|
|
|
|
|
var pageNumber = [
|
|
var pageNumber = [
|
|
|
- '<span class="btn-group dropup">',
|
|
|
|
|
|
|
+ sprintf('<span class="btn-group %s">', this.options.paginationVAlign === 'top' || this.options.paginationVAlign === 'both' ?
|
|
|
|
|
+ 'dropdown' : 'dropup'),
|
|
|
'<button type="button" class="btn btn-default ' + (this.options.iconSize === undefined ? '' : ' btn-' + this.options.iconSize) + ' dropdown-toggle" data-toggle="dropdown">',
|
|
'<button type="button" class="btn btn-default ' + (this.options.iconSize === undefined ? '' : ' btn-' + this.options.iconSize) + ' dropdown-toggle" data-toggle="dropdown">',
|
|
|
'<span class="page-size">',
|
|
'<span class="page-size">',
|
|
|
$allSelected ? this.options.formatAllRows() : this.options.pageSize,
|
|
$allSelected ? this.options.formatAllRows() : this.options.pageSize,
|
|
@@ -2122,7 +2123,8 @@
|
|
|
BootstrapTable.prototype.toggleView = function () {
|
|
BootstrapTable.prototype.toggleView = function () {
|
|
|
this.options.cardView = !this.options.cardView;
|
|
this.options.cardView = !this.options.cardView;
|
|
|
this.initHeader();
|
|
this.initHeader();
|
|
|
- this.initToolbar();
|
|
|
|
|
|
|
+ // Fixed remove toolbar when click cardView button.
|
|
|
|
|
+ //that.initToolbar();
|
|
|
this.initBody();
|
|
this.initBody();
|
|
|
};
|
|
};
|
|
|
|
|
|