I have created a many to many relationship for 2 post types, Package Deals and Products.
I have tried to follow the instructions for creating a view for Package Deals that shows information from both the Package Deals and Products post types.
When I try and create the view it does not show the indented related post products under the Package Deals post type (see attached image).
I know I am doing something incorrectly, however, have no idea what it is.
Thanks for any assistance you can offer.
Kirk
Hi Kirk,
Thank you for contacting us and I'd be happy to assist.
To suggest the best way to achieve this, I'll need to fully understand exactly where and how you're planning to show this view.
Can you please share temporary admin login details, along with the example page where this view can be seen?
Note: Your next reply will be private and please make a complete backup copy, before sharing the access details.
regards,
Waqar
Thank you for sharing these details.
To achieve this, you'll need nested views, which are not currently supported through the views created using the new Blocks editor.
First, you'll enable the classic/legacy views editor by selecting the option "Show both the legacy and Blocks interface and let me choose which to use for each item I build" for the editing experience.
( at WP Admin -> Toolset -> Settings -> General )
This will enable the views management section at WP Admin -> Toolset -> Views, from where the classic/legacy views can be added/edited.
The first parent view will be set to show the "Package Deal" posts and inside its loop, you can show any field data from this post type.
The second child view will be nested inside the loop of the first view and will be set to show the "Products" posts, which are related to the current post in the loop. In the loop of this second view, you can show any information that you need from the related product.
Here is a guide on using the nested views:
https://toolset.com/documentation/user-guides/views/using-a-child-view-in-a-taxonomy-view-layout/
I hope this helps and please let me know if you need any further assistance around this.
My issue is resolved now. Thank you!