array checkbox in editor show as separate labels

array checkbox in editor show as separate labels

mfmf Posts: 41Questions: 11Answers: 0

Deal all,

I am using this example: https://editor.datatables.net/examples/advanced/joinArray.html

And I would like to change the appreance of the following:

                "label": "Permissions:",
                "name": "permission[].id",
                "type": "checkbox"

and I would like to have just one checkbox per label (if that makes sense) like this:

            }, {
                "label": "Accounts:",
                "name": "permission[].id['0']",
                "type": "checkbox"
           }, {
                "label": "Desktop:",
                "name": "permission[].id['1']",
                "type": "checkbox"
            }

But permission[].id['0'] is not returning anything and I tried all sort of ways also dotted but what is the correct way to display only one value from the array?

Thanks!

This question has an accepted answers - jump to answer

Answers

  • allanallan Posts: 61,446Questions: 1Answers: 10,054 Site admin
    Answer ✓

    I'm afraid that isn't something that Editor can do at the moment. The field's value in this case is an array, so it needs to be a single field. Multiple fields can't currently be combined to form a single value I'm afraid.

    Allan

  • mfmf Posts: 41Questions: 11Answers: 0

    ok, thanks for answering!

This discussion has been closed.