Prerequisites
Describe the bug and add attachments
Hello,
The documentation (https://devdocs.prestashop-project.org/9/development/components/form/types-reference/material-choice-table/#body-inner) says that we can use multiple option "to enable multiple checkboxes selection or not".
But in fact, using the "multiple => false" option generate a fatal error in MaterialChoiceTableType
count(): Argument #1 ($value) must be of type Countable|array, string given
I have succeded to fix it with a small change in MaterialChoiceTableType but I don't think we should.
If we don't want multiple option, we must use ChoiceType : better UI, no "Select All", radios instead of checkboxes.
I think we should remove this option, PrestaShop never use it.
What do you think about it ? :)
Thank you
Expected behavior
We should have a checklist where we can only select one checkbox
Steps to reproduce
- Update
CustomerType
- Add
'multiple' => false for the MaterialChoiceTableType group_ids
- Edit a customer
PrestaShop version(s) where the bug happened
8.2.1 (and probably before), 9.0.0
How you installed PrestaShop
git clone
PHP version(s) where the bug happened
8.1
If your bug is related to a module, specify its name and its version
No response
Your company or customer's name goes here (if applicable).
Mademoiselle bio
Prerequisites
Describe the bug and add attachments
Hello,
The documentation (https://devdocs.prestashop-project.org/9/development/components/form/types-reference/material-choice-table/#body-inner) says that we can use
multipleoption "to enable multiple checkboxes selection or not".But in fact, using the
"multiple => false"option generate a fatal error inMaterialChoiceTableTypeI have succeded to fix it with a small change in
MaterialChoiceTableTypebut I don't think we should.If we don't want multiple option, we must use
ChoiceType: better UI, no "Select All", radios instead of checkboxes.I think we should remove this option, PrestaShop never use it.
What do you think about it ? :)
Thank you
Expected behavior
We should have a checklist where we can only select one checkbox
Steps to reproduce
CustomerType'multiple' => falsefor theMaterialChoiceTableTypegroup_idsPrestaShop version(s) where the bug happened
8.2.1 (and probably before), 9.0.0
How you installed PrestaShop
git clone
PHP version(s) where the bug happened
8.1
If your bug is related to a module, specify its name and its version
No response
Your company or customer's name goes here (if applicable).
Mademoiselle bio