Parent / child editing: dependent child table buttons
Parent / child editing: dependent child table buttons

Hello!
I made a parent / child solution based on this example:
https://editor.datatables.net/examples/advanced/parentChild.html
Are there any way to make the child table buttons dependent?
I mean hide the buttons until I select one row in parent table.
Thank You and best regards:
Endre, Szak
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
One option is to use
buttons().container()
chained with jQuery hide() and jQuery show() to hide/show the buttons container.You can use the
select
event for the parent table. In the event check for selected rows. If none the use the above to hide or show if one or more rows are selected. See this example to learn how to check for selected rows.Kevin
Dear Kevin,
Thank you, it finally works.