This question is a little hard to explain, so please bear with me.
I am trying to find a way to integrate Beaver Builder with WP Toolset Types and Views in order to generate BB Layout Templates that replace the single pages of a custom post type called “Products.”
My “Products” custom post type contains several custom fields that I would like to display using custom modules and a Layout Template that gets applied to all of my Products. I have already made some custom BB modules that display the post title and custom fields for this post type. I have also created a BB Layout Template called “Product Single Layout” and placed my custom modules within it.
In order to apply this Layout Template to all of my Products without having to go into each single page, open Page Builder, and manually select it, I have looked into rendering BB Layout Templates using shortcodes. Since the Toolset plugin contains a Content Template feature that overrides the default single.php layout for my custom post type, I have placed the following shortcode inside of a Content Template called “Products Single.”
[fl_builder_insert_layout slug=“product-single-layout” type=“fl-builder-template”]
So far, this works well in that it renders the Layout Template for all of my products without needing to go into each one and select it. The problem is that my custom modules are not working in relation to each Product. Instead the single product pages still display the title and fields of the Layout Template itself and do not update to reflect the title and fields of the Product it is getting applied to. However, when I open Page Builder for a single product, then the modules suddenly start to work well and render the correct content.
My question is, is there any way to create a Layout Template with custom modules that render post fields and have this content get rendered for each of my posts without having to go into PageBuilder and publish each individual post?
This is a tough one to explain, so I am happy to fill in some details or provide access to my site if needed.