Skip to content
Advertisement

Bootstrap-Table: Expand rows that are not hidden

I have filters set up that will hide certain rows of my bootstrap-table. I have also implemented the “expandAllRows” method to display all detail-views; however, this method will expand ALL rows including those that are hidden by my filters.

How would I modify bootstrap-table.min.js in order to only show the detail-views of the rows that are visible?

I believe I need to modify the line from bootstrap-table.min.js but not sure how:

JavaScript

I am using the bootstrap-table buttons method to add the custom buttons for expanding and collapsing the rows. See below:

JavaScript

Advertisement

Answer

Rather than modify bootstraps’ functions, maybe you could just circumvent them by renaming the attribute when you filter them. Something like this

JavaScript
User contributions licensed under: CC BY-SA
2 People found this is helpful
Advertisement