I am struggling to combine 2 different data types, “Store” and “Task”, in the same repeating group.
Data type “Store” has a field called StoreName - text and a field called “StoreRegion” - text
Data type “Task” has a field called TaskDone? - yes/no and a field called ForStore - Store
The repeating group lists the names of stores for which a specific task needs to be done. I want to be able to filter this list by the store region. So when I choose a region from the dropdown element, I want the repeating group to only show the stores from that region. I cannot get the dropdown to apply to the repeating group.
Hi, thanks for taking the time to check out my problem. When I change the RG to Store, Bubble says I should change it back to Task if I do a search for Task:
I agree the challenge lies in accessing a data type field that belongs to Store while the repeating group’s type of content is set to Task. I chose Task for the repeating group’s type of content and also for the cell (data source is Current Cell’s Task) so that I can show the open tasks for each store (Parent group’s Task’s ForStore’s Store).
Now, I also want to restrain this store list by region, depending on the region selected in the dropdown. Is there a way to configure the data source of the repeating group to search the Store date type for region while the RG’s type of content is Task? The Task data type has a field ForStore - Store and I tried the following but do not know how to complete the expression or if this is correct in general.
There is no problem in the Type of content be a “Store” and you start your Data Source with Search for tasks.
The RESULT of this sentence must be a list of stores (as this is the Type of content of your repeating group). So, at this point, Bubble will tell you that something is wrong, because your sentence is resulting in a list of tasks, correct?
So, to correct this nehavior, we need to END this sentence with a list of stores.
We know that every task has its own store. So, what you need to do is load these stores after your Search for tasks.
In the image above, keep scrolling down until you see something like Each item Store. This will load the store of each task instead of load the task itself. And this is what we want.
Search for task’s Each item Store :Unique elements
The :unique elements in the end is just to prevent duplicate stores in the results.
hi @rpetribu Thanks so much for clarifying. I managed to input the expression, but when I preview the repeating group it now appears empty. I am not sure what I am missing?