Radio Button styling

Hello,

is it possible to change the basic layout of radio buttons? I would like to have 2 of them in each row of a repeating group. But I can’t find an option to freely move each radio button element in order to align with the layout.

Ok, styling is not a big issue as one can create custom radio buttons.

Unfortunately I don’t know how to attach/append a value to each entry in a list of things. For example: if I have a list of things (apple, banana, lemon) in cell „my fruits“ of „current user“, I would like to append a „0“ or „1“ to each fruit according to the radio button selection.
(At least that is the way it should be done in my understanding of things)

Can someone give me a hint on this?

Hi mirko,

  1. if you have fruits in your database as a data type you can add a field yes/no. You could make the default value of this field yes or no.
  2. show one icon if current fruit’s field is yes and show the other icon if current fruit’s field is no.
  3. And if you click the icon you can have a workflow that makes changes to the current cells fruit: current cell’s fruit yes/no field to yes or no.

Is this what you mean/helpful?

hope this helps
Julius.

Hey Julius,

thanks for this tip. I am not sure if I understand you correctly. This is what I have at the moment:

If I add another field next to „Fruits“ I would need to keep care of the correct assignment of a fruit <—>choice value. Therefore my thought was to append the choice to the actual fruit itself. Something like „apple:1“ , „banana:0“ , „lemon:1“ etc…

But maybe you meant this and I didn’t understand you correctly?

Ah ok so each user can select fruits from the same list of fruits and has a list of fruits, but peter may have 1 banana and 2 apples whereas John may have 3 bananas and 5 apples. Is that what you want?

  1. In this case, I would create another data type called Basket. Which has a field list of items.
  2. For the above you need a new data type called Item. Each item has the field: amount and a fruit, type fruit. Also a yes/no field, as you seem to need this.
  3. Whenever Peter starts selecting fruits, he creates a new basket, saved with the user underneath peter’s current basket (or list of baskets) a new field. You could also create the basket and add it to Peter just after sign up or when a button is pressed.
  4. Then whenever he selects a fruit a new item is created with the fruit= the fruit selected (e.g current cell’s fruit) and the amount, the amount selected. Or a yes/no field for each item.
  5. You could then have a group called current user’s basket (type basket). This basket can have a repeating group inside: list of items. In each cell of that group you can then have current cell’s items fruit and current cell’s items amount. This allows every user to have their own items and amounts for each fruit.

Hope that makes sense. Otherwise just pm me.

regards Julius

For free tip & step by step lists on Bubble & more check https://www.tiplister.com/

Hey Julius,

thanks for this guide. I am not sure if I understood what you described in you last posting. I feel still very new to this whole bubble stuff. But maybe things are a litte bit easier in my case anyways as there is no need for a “basket”.
What I want to achieve is more something like a food rating thing.

Here is an example:

And here the editor:

Every user can search for some fruits which he likes to rate (bad/good). The result should be stored in his/her profile (current_user -> “fruit_rating”).

Ok I think I understand.

Option A - quick fix.
You add a datafield to type fruit called list of numbers or list of yes/nos. You change that datafield whenever a fruit is rated. For each fruit you can then count the number of entries and sum them to get an average. Using current cell’s fruits list of numbers: count or :sum
However, this means that you cannot see which user said yes/no to which fruit or rated which fruit how, you can just get the average.

Option B - more functionality
You create one new data type called fruit reviews. Each fruit review has a yes/no field (or number field) as well as a fruit it is associated with (type fruit)
When you add a fruit to a user, you also create a new thing: type fruit review that has the fruit selected added to it and the review rating (yes/no or number) set.
That way you can have a cell say current cell’s fruits’ list of fruit reviews’ sum/average or creator etc.

hope this helps, otherwise pm me

regards
Julius

This topic was automatically closed after 70 days. New replies are no longer allowed.