In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/03 Report--
This article mainly shows you "bootstrap-table how to achieve data refresh to stay on the current page", the content is easy to understand, clear, hope to help you solve your doubts, the following let the editor lead you to study and learn "bootstrap-table how to achieve data refresh to stay on the current page" this article.
Get the current page
To stay on the current page, we first need to get the current page. Bootstrap-table defines that getOptions can get a lot of table information, including the current page.
$table.bootstrapTable ('getOptions')
Re-request data
After we modify the data, we need to request the data again. We can use refresh or initialize the call again, which I use here to make the initialization call again. By passing the current page as a parameter.
Refresh data init (pageIndex) by calling initialization function Function init (pageIndex) {$('# table') .bootstrapTable ({method:'get', url:'/ admin/student/getAllStudent', striped:true, cache:false, uniqueId:'id', clickToSelect: true, pagination:true, / / set the paging pageNumber:pageIndex | | 1 Zero / initialize load the first page Default first page queryParams: the parameters passed by queryParams,// when requesting the server, number of sidePagination:'server', pageSize:10,// records per page, pageList: [10rec 20rep 30je 40], / / paging progress value columns: [{/ / column parameters field: 'sid', title:' sid',}, {field: 'name'] Title: 'name'}, {field:' grade', title: 'grade'}, {field:' password', title: 'password'}, {field:' Button', title: 'operation', events: operateEvents Add button to formatter:AddFunctionAlty// table},]}) } these are all the contents of the article "how to refresh the data in bootstrap-table and stay on the current page". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.