DataTables Editor formOptions: main: submit: 'changed' always includes checkboxes
DataTables Editor formOptions: main: submit: 'changed' always includes checkboxes
klyde
Posts: 2Questions: 1Answers: 1
I have a DataTable Editor initialized with the following fields:
{
label: "Test Text Box",
name: "test_text",
},
{
label: "Test",
name: "test_check",
type: "checkbox",
separator: "",
unselectedValue: 0,
options: [
{ label: '', value: 1 }
],
},
The form options are set as:
formOptions: {
main: {
submit: 'changed',
},
},
When I submit the form, the submit: 'changed'
property works correctly for the text field, but the checkbox field is always submitted, regardless of whether its value was changed.
Thanks for any help.
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
The solution is as follows:
The
separator
value must be set to" "
instead of""
(one space).Thanks for posting back - great to hear you've got it working.
Allan