Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
wenzhixin committed May 15, 2024
2 parents 4063f11 + d5cf8cc commit 0dfedc6
Show file tree
Hide file tree
Showing 10 changed files with 44 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/bootstrap-table@1.22.5/dist/',
cdnUrl: 'https://cdn.jsdelivr.net/npm/bootstrap-table@1.22.6/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://cdn.jsdelivr.net/npm/bootstrap@4.6.2/dist/css/bootstrap.min.css">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@6.5.2/css/all.min.css">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-table@1.22.5/dist/bootstrap-table.min.css">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-table@1.22.6/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/popper.js@1.16.1/dist/umd/popper.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@4.6.2/dist/js/bootstrap.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap-table@1.22.5/dist/bootstrap-table.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap-table@1.22.6/dist/bootstrap-table.min.js"></script>
</head>
<body>
<div class="container">
Expand Down
31 changes: 29 additions & 2 deletions extensions/cookie.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,35 @@
],
scripts: [
'bootstrap-table.min.js',
'extensions/cookie/bootstrap-table-cookie.min.js'
'extensions/cookie/bootstrap-table-cookie.min.js',
'https://cdn.jsdelivr.net/npm/bootstrap-table@1.22.5/dist/bootstrap-table-locale-all.min.js'
]
})
</script>

<style>
select.form-control {
width: 200px;
}
</style>

<div class="toolbar">
<select class="form-control" id="locale">
<option value="en-US">en-US</option>
<option value="zh-CN" selected>zh-CN</option>
</select>
</div>

<table
id="table"
data-toolbar=".toolbar"
data-show-columns="true"
data-cookie="true"
data-cookie-id-table="saveId"
data-page-list="10,25,50,100,all"
data-pagination="true"
data-search="true"
data-height="460"
data-url="https://examples.wenzhixin.net.cn/examples/bootstrap_table/data"
data-side-pagination="server">
<thead>
Expand All @@ -32,6 +49,16 @@

<script>
function mounted() {
$('#table').bootstrapTable()
var $table = $('#table')

$table.bootstrapTable({
cookieStorage: 'localStorage'
})

$('#locale').change(function () {
$table.bootstrapTable('refreshOptions', {
locale: $(this).val()
})
})
}
</script>
8 changes: 6 additions & 2 deletions extensions/toolbar.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,18 @@
id="table"
data-pagination="true"
data-search="true"
data-show-columns="true"
data-advanced-search="true"
data-id-table="advancedTable"
data-url="json/data1.json">
data-side-pagination="server"
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>
<th data-field="price" data-sortable="true">
<i class="fa fa-star"></i> Item Price
</th>
</tr>
</thead>
</table>
Expand Down
2 changes: 1 addition & 1 deletion 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/bootstrap-table@1.22.5/dist/bootstrap-table-locale-all.min.js'
'https://cdn.jsdelivr.net/npm/bootstrap-table@1.22.6/dist/bootstrap-table-locale-all.min.js'
]
})
</script>
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.5",
"version": "1.22.6",
"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.5",
"bootstrap-table": "^1.22.6",
"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.5",
"bootstrap-table": "^1.22.6",
"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/tableexport.jquery.plugin@1.29.0/tableExport.min.js',
'bootstrap-table.min.js',
'https://cdn.jsdelivr.net/npm/bootstrap-table@1.22.5/dist/bootstrap-table-locale-all.min.js',
'https://cdn.jsdelivr.net/npm/bootstrap-table@1.22.6/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/vue@2.7.16/dist/vue.min.js',
'bootstrap-table.min.js',
'https://cdn.jsdelivr.net/npm/bootstrap-table@1.22.5/dist/bootstrap-table-vue.min.js'
'https://cdn.jsdelivr.net/npm/bootstrap-table@1.22.6/dist/bootstrap-table-vue.min.js'
]
})
</script>
Expand Down

0 comments on commit 0dfedc6

Please sign in to comment.