Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
wenzhixin committed Mar 26, 2024
2 parents 3c31535 + d88ba2e commit b215cde
Show file tree
Hide file tree
Showing 12 changed files with 67 additions and 13 deletions.
2 changes: 1 addition & 1 deletion assets/js/template.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
window._config = {
isDebug: location.hash.slice(1) === 'is-debug' ||
['localhost', '127.0.0.1', 'dev.bootstrap-table.com'].indexOf(location.hostname) > -1,
cdnUrl: 'https://cdn.jsdelivr.net/npm/[email protected].3/dist/',
cdnUrl: 'https://cdn.jsdelivr.net/npm/[email protected].4/dist/',
localUrl: '../bootstrap-table/src/',
testUrl: '/src/'
}
Expand Down
4 changes: 2 additions & 2 deletions crud/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<meta charset="utf-8">
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.6.3/css/all.css">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected].3/dist/bootstrap-table.min.css">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected].4/dist/bootstrap-table.min.css">
<style>
.mr10 { margin-right: 10px; }
.alert {
Expand All @@ -17,7 +17,7 @@
<script src="https://cdn.jsdelivr.net/npm/jquery/dist/jquery.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/umd/popper.min.js"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected].3/dist/bootstrap-table.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected].4/dist/bootstrap-table.min.js"></script>
</head>
<body>
<div class="container">
Expand Down
6 changes: 4 additions & 2 deletions extensions/print.html
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<tr>
<th data-field="id">ID</th>
<th data-field="name">Item Name</th>
<th data-field="price">Item Price</th>
<th data-field="price"><i class="fa fa-print"></i> Item Price</th>
</tr>
</thead>
</table>
Expand All @@ -28,6 +28,8 @@
var $table = $('#table')

function mounted() {
$table.bootstrapTable()
$table.bootstrapTable({
printStyles: ['https://cdn.jsdelivr.net/npm/@fortawesome/[email protected]/css/all.min.css']
})
}
</script>
1 change: 1 addition & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,7 @@
<li><a href="#options/table-pagination.html">Pagination</a></li>
<li><a href="#options/pagination-h-align.html">Pagination H Align</a></li>
<li><a href="#options/pagination-index-number.html">Pagination Index Number</a></li>
<li><a href="#options/pagination-load-more.html">Pagination Load More</a></li>
<li><a href="#options/pagination-loop.html">Pagination Loop</a></li>
<li><a href="#options/pagination-parts.html">Pagination Parts</a></li>
<li><a href="#options/pagination-text.html">Pagination Text</a></li>
Expand Down
2 changes: 1 addition & 1 deletion options/multiple-select-row.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script>
init({
title: 'Multiple Select Row',
desc: 'Use `multipleSelectRow` to select the multiple selection row. Can use the ctrl+click to select one row or use shift+click to select a range of rows.',
desc: 'Use `multipleSelectRow` to select the multiple selection row. You can use the ctrl+click to select one row or shift+click to select a range of rows.',
links: ['bootstrap-table.min.css'],
scripts: ['bootstrap-table.min.js']
})
Expand Down
46 changes: 46 additions & 0 deletions options/pagination-load-more.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<script>
init({
title: 'Pagination Load More',
desc: 'Use `paginationLoadMore` option to enable loading more data through pagination.',
links: [
'bootstrap-table.min.css'
],
scripts: [
'bootstrap-table.min.js'
]
})
</script>

<table
id="table"
data-show-columns="true"
data-pagination="true"
data-search="true"
data-url="https://examples.wenzhixin.net.cn/examples/bootstrap_table/data">
<thead>
<tr>
<th data-field="id" data-sortable="true">ID</th>
<th data-field="name" data-sortable="true">Item Name</th>
<th data-field="price" data-sortable="true">Item Price</th>
</tr>
</thead>
</table>

<script>
var rows = []

function mounted() {
$('#table').bootstrapTable({
paginationLoadMore: true,
queryParams (params) {
params.limit = 100
params.offset = rows.length
return params
},
responseHandler (res) {
rows = rows.concat(res.rows)
return rows
}
})
}
</script>
9 changes: 7 additions & 2 deletions options/table-locale.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
links: ['bootstrap-table.min.css'],
scripts: [
'bootstrap-table.min.js',
'https://cdn.jsdelivr.net/npm/[email protected].3/dist/bootstrap-table-locale-all.min.js'
'https://cdn.jsdelivr.net/npm/[email protected].4/dist/bootstrap-table-locale-all.min.js'
]
})
</script>
Expand Down Expand Up @@ -77,6 +77,7 @@
data-show-refresh="true"
data-show-toggle="true"
data-show-columns="true"
data-show-button-text="true"
data-show-export="true"
data-pagination="true"
data-url="json/data1.json">
Expand All @@ -93,7 +94,11 @@
var $table = $('#table')

function mounted() {
$table.bootstrapTable()
$table.bootstrapTable({
formatRefresh: function () {
return ''
}
})

$('#locale').change(function () {
$table.bootstrapTable('refreshOptions', {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "bootstrap-table-examples",
"version": "1.22.3",
"version": "1.22.4",
"description": "bootstrap-table-examples",
"repository": {
"type": "git",
Expand Down
2 changes: 1 addition & 1 deletion vue-starter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
},
"dependencies": {
"bootstrap": "^4.5.0",
"bootstrap-table": "^1.22.3",
"bootstrap-table": "^1.22.4",
"bootstrap-vue": "^2.15.0",
"core-js": "^3.6.5",
"jquery": "^3.5.1",
Expand Down
2 changes: 1 addition & 1 deletion webpack-starter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
},
"dependencies": {
"bootstrap": "^4.5.0",
"bootstrap-table": "^1.22.3",
"bootstrap-table": "^1.22.4",
"jquery": "^3.5.1",
"popper.js": "^1.16.1"
},
Expand Down
2 changes: 1 addition & 1 deletion welcome.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
scripts: [
'https://cdn.jsdelivr.net/npm/[email protected]/tableExport.min.js',
'bootstrap-table.min.js',
'https://cdn.jsdelivr.net/npm/[email protected].3/dist/bootstrap-table-locale-all.min.js',
'https://cdn.jsdelivr.net/npm/[email protected].4/dist/bootstrap-table-locale-all.min.js',
'extensions/export/bootstrap-table-export.min.js'
]
})
Expand Down
2 changes: 1 addition & 1 deletion welcomes/vue-component.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
scripts: [
'https://cdn.jsdelivr.net/npm/[email protected]/dist/vue.min.js',
'bootstrap-table.min.js',
'https://cdn.jsdelivr.net/npm/[email protected].3/dist/bootstrap-table-vue.min.js'
'https://cdn.jsdelivr.net/npm/[email protected].4/dist/bootstrap-table-vue.min.js'
]
})
</script>
Expand Down

0 comments on commit b215cde

Please sign in to comment.