Need to add info rows
Need to add info rows
When the table first opens in default order, I want to insert some info rows that span all columns, like in the beige rows in the folowing screenshot.
Then if the user enters something into the search box so that it reorders the rows, these info rows shoud disappear. They should only display when rows are in default order.
But when I add any rows to the table using "colspan" it breaks the functionality completely, no search box appears, no sorting, etc.
Is there a version of the datatables that has the ability to do this? Or will I have to hack the code to make it work?
Any info is greatly appreciated, thank you.
Answers
Please post the errors you see on the console. Please also post a test case, link to a page showing the issue or - if that's not possible - post your code.
Datatables doesn't support
colspan
in thetbody
. See the HTML requirements for more info.The data, like
Graded Single
, where does it come from?The RowGroup extension might handle this nicely for you. You can enable or disable the RowGroup using an API
rowGroup().enable()
orrowGroup().disable()
. In the-even order
event you can determine the current order and enable or disable as appropriate.Kevin