I have RG displaying a list of services. There is an Ionic_checkbox in the corner, by checking this the user can add the item to the cart, and this is working fine.
Is there a way to make those checkboxes act like a radio button within the RG?
I need your help/advice to set up a rule where only one checkbox can be checked in the RG.
I would probably add a field in the database (probably in the Services data type but it depends on your set up) called ‘Item Added’ and then whenever a checkbox is checked, I’d set that new field to yes.
Then I’d have a conditional on each checkbox when Item Added’ is yes this checkbox is disabled.
Note: this could alternatively be done by setting a state on the page, but if you want this setting to persist when the user comes back another day, using the database often makes more sense.
Thanks for your reply. At this stage I dont really want to create a DB entry. At the bottom of the page there is a button to finalize the booking. Clicking on that is when it is saved to the DB.
I still believe it can be solved with custom states. Just don’t know how.
This is what I am doing:
Created the custom state:
When the checkbox value is changed and it is checked I set the state like this:
And this is the condition to uncheck the other check boxes:
What am I doing wrong?
I’m wondering if the conditional won’t change the checkbox status on the fly (only on page load), so maybe you need to run a custom workflow with an action that unchecks all boxes and then another action that just checks the box you want to check?
Looking at the workflow element actions, but I just can’t find any that would change a checkbox.
OK, I was able to solve this issue with replacing the checkboxes for two icons.
Unchecked one (blue) is visible on all cards until the custom state’s Title is = to current cell’s Title. Than the green checked one is displayed.
But I am still wondering why the checkboxes doesn’t “behave” the way I want.
Anyway, it is solved now with the workaround using the icons.
This topic was automatically closed after 70 days. New replies are no longer allowed.