Skip Navigation

[Resolved] Repeater Field Group displaying extra results when using Divi for layout

This support ticket is created 5 years, 3 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 -
- 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 -

Supporter timezone: Europe/London (GMT+00:00)

This topic contains 10 replies, has 2 voices.

Last updated by Nigel 5 years, 3 months ago.

Assisted by: Nigel.

Author
Posts
#1346771

I am trying to: create a layout for a Repeating Field Group and display the results in a View using the Divi builder for the layout

Page URL: hidden link

I expected to see: The two results displayed at the top

Instead, I got: The two expected results, then 20+ extra empty results!

Video of the problem: hidden link

Additionally, I am using the Grid Table layout with 3 rows, but I need a way to change the number of rows for mobile devices. do you know how I can do this?

Thank you!!

#1346869

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

Hi Luigi

At the very start of the video (I didn't watch it all) it shows that the Content Selection of the View is for both Events *and* the Event Attachment repeatable field group.

And there don't appear to be any Query Filters set.

So the View would get all of the event posts and all event attachment groups of repeatable fields (each group of fields is stored as a post of a hidden post type) and then iterate over all of these posts when generating the output.

So it doesn't surprise me that you are getting unexpected results.

You need to set up the query to actually get the results—and only the results—that you intend.

I am guessing that if you are displaying a single event post then you want to display the event attachment repeatable field groups that belong to that particular event.

So update the Content Selection so that it is only querying the repeatable field group, and not the Event post type.

Then add a relationship Query Filter to set the post the repeatable field group belongs to (i.e. set by the post where this View is shown).

#1347283

Thank you Nigel!
That was exactly the issue.

Now I'm just stuck on making the Table Grid mobile responsive and adding a filter on the front-end so the visitor can view the Repeatable Field Groups by Date. Can you advise on the best way to proceed? I have added a Date field to the Repeatable Field Group.

The desired filter options can be seen on this page: hidden link

#1347351

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

When I visit that link the results already appear to be displayed in a responsive grid (on smaller screens they display in 2 columns, and on the smallest size stack to a single column), so it appears you resolved this already.

Regarding adding front-end filters, unfortunately we have a current issue where it is not possible to create front-end filters for Views querying repeatable field groups. (There should be an erratum, but it hasn't been prepared yet, I'm asking for that now.)

I'll nudge the developers at the meeting in the morning to see whether this is something we can expect a fix for soon, and I'll let you know what they say.

#1347359

Thank you!
And I apologize for the confusion, the link provided was for an example of how it should work (with the date filter and mobile responsiveness), the site I am working on with Toolset is: hidden link

#1347381

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

OK, it looks like on that page for the output format of the View you have use a table format, which is not responsive.

You need to use a Bootstrap grid instead, which is responsive.

Except the problem is you are using Divi, right? And Divi is not compatible with Bootstrap, meaning you are advised to disable Bootstrap when using Divi.

That means you'll need to take a hands-on approach with the CSS required for such a responsive grid.

I think the simplest solution is probably to create your own, with CSS grid or flexbox it really is quite simple. You just need to modify the Loop Editor to generate the required markup, remembering that whatever is inside the wpv-loop tags is the part that repeats for each result.

Here's a simple example you could adapt: hidden link

#1348131

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

Minor update to say that the erratum has been published: https://toolset.com/errata/views-has-issues-when-creating-repeatable-fields-groups-fields-filters-and-when-displaying-the-view/

I'll update you here when there is some progress from the developers.

#1349461

Thank you Nigel!
Your support has been excellent.

Could you please let me know when there is an estimated date the front-end filters will be fixed?
My client is waiting for us to be able to filter the results by date before we publish the site.

#1349797

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

The developer actually proposed a fix for this already, and it's undergoing testing.

If that goes well, then it will be incorporated in the next Views hotfix.

I've asked if they can make a patch available for you before then, so it should be soon, if not today then early next week.

#1350405

That's wonderful news!! Thank you for all your help.

If you could take a look, there is one more issue we are having on this site that's keeping us from being able to go live.
I've made a ticket which can be seen here: https://toolset.com/forums/topic/map-missing-results/#post-1350403

The In Action CPT has ACF custom fields that were imported with the posts, but some of the results are not displaying on the map. The strange thing is that if I have all the results load on the page as HTML, they are all there! The rest of the details are in the support ticket above.

If you have time, could you take a look as well? I've been stuck on this one for a few days now.
Thanks Nigel!

#1352425

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

Hi Luigi

Sorry for the delay, I was waiting on the fix from the developer.

You can download a replacement version of Views here: hidden link

On the plugins page of your site delete the current Views installation, the upload the zip file I just shared with you on the Add New plugins page.

That contains the fix to be able to set up custom searches with repeatable field groups.

Before you do this, of course, make sure you have a current backup.

(I notice Beda has been updating you in the other ticket.)