Been searching for the forums for an answer to how I can click a button and deselect all checkboxes in a table.
I have a table with a checkbox in the first cell of each row. When the checkbox is checked/unchecked by clicking on it, the data in the row is added/removed from a datastore. When the datastore contains items I’m displaying a context menu where you can empty the datastore by clicking clear all
. when clear all is clicked, I also need to uncheck all the checkboxes.
I’ve tried placing the checkbox inside a form group, and inside a checkbox group and using reset as was suggested in this thread. Remove Check from Checkbox but no joy.
I’ve also tried setting select(false)
on the dmx click event as was suggested here How to clear a single checkbox with button click? and here How Can I Deselect a Checkbox on-click?
dmx-on:click="datastore_sel_candidates.clear();inp_select.select(false)"
inp_select being the checkbox.
Wondering if this is to do with the checkbox being inside of a tabl? as suggested by @jellederijke here How to clear a single checkbox with button click? and not finding a solution to the same problem.