Forum Academy Marketplace Showcase Pricing Features

Filtering Repeating Group of Profiles

Hi,

I am using three filters (specialty, state, payment) for a repeating group on my explore page. The filters work properly, however I need help with three things.

(1) Before a user selects the applicable filters, I would like all of the profiles in the repeating group to show. Right now, no profiles show until the user selects the applicable filters.

(2) I would like the repeating group to update when at least one filter is selected by the user. Right now, no profiles are visible unless the user selects an entry from each of the three filters.

(3) If the user selects the applicable filters and no profiles come up, I would like certain text to show. I think I need to use a conditional to show the element, but I’m not sure how I should write the conditional.

Any help would be appreciated.


Hi @antonia.hyman.

Simply use this as data source do a search for dietitian to show all dietitian if no filters have been used.

The reason why no dietitian is showing when none of the filters have been activated is because you structured your search in way that is dependent to the filters. Notice how you would need to get the dropdowns’ value first?

For starters, you could change the data source of the repeating group every time a filter is applied. However, I HIGHLY suggest you do not go through that route since not only is it a headache to manage, it is also unscalable especially when you reach thousands of records.

You might want to check out the “daisy chain filtering method” I can explain this by detail on how it works but it would be better if you check this video instead

kudos again to Andrew Vernon for making this.

  1. The conditional of the text could be simply “when repeating group’s list of dietitian first item is empty” then set the property to this element is visible :white_check_mark:

Hope this helps!

Best,
Nino

Thanks so much for taking the time to right this helpful response Nino. I just implemented #3. Now I’m working on #1 and then will check out the video you suggested for #2.

For #1, it sounds like the conditional needs to go on the repeating group element. Do you mind writing out the condition using Bubble’s language? I understand what you’re saying in theory, just not sure how I write it. Thank you.

It is not a condition but rather a data source for the repeating group. You can use it here like you how you usually do it
image

Simply search for dietitian without any constraints

Okay that makes sense, but then I can’t do an advanced search using filters like I have it set up now correct? Right now I’m using the advanced search to filter the data by those three criteria.

yes you would not need to do that anymore especially since you should be doing what I suggested at #2 for optimal performance

But if you were to not do #2, you could still achieve that by again, search for all of the dietitian at first but now, you could have a “do when” workflows where if the inputs are changed , change the source of the RG

Okay thank you. I’m working through the video now. Sorry if this question is dense, but it looks like when he sets up the data source he used a few constraints. Do I need to have these constraints to start with? Would it be sufficient to just have the data source as “Search for Dietitian Profile”. I’m not sure what the constraints he added are doing.

1

I went ahead and tried daisy chain filtering as it was explained in the video. In the first image you can see that when one of the three dropdown values are changed, the custom filters are triggered. This seems to be working correctly.

Where I’m running into trouble is with the results that are shown. I’m trying to set it up, so that a user can do this search “Specialty X OR Specialty Y” & “State A or State B” & “Payment A or Payment B”. Right now the individual searches for the different parameters work, but not the “ands” combining the filters. I’m guessing the issue is with my filters in the custom events. Any chance you can help me figure out how to write this? Each of these filters is a multidropdown.