This probably belongs on the Crocoblock forum but since it also pertains to the Bricks Query Loop (I think?), I thought I’d try my luck here with fellow JetEngine users.
I have two CPTs (Author and Book) and a many-to-many Relations linking the two (Author → Book). I would like to have a dropdown Author filter modifying the loop that displays a grid of Books.
Has anyone successfully implemented something like this using JetEngine Relations and JetSmartFilters?
Update: a small progress, but no closer to solving this.
I was able to obtain some details of Books using JetEngine’s Query Builder and display it using a Bricks Query Loop, and the Author ID dropdown filter I created previously is able to modify the grid.
However, the JetEngine Query (using SQL Inner Join) does not have the usual data required to display the Books nicely on the front-end (e.g. missing feature image, url link) - and the Author is also in the form of its numeric post id.
So yes, the Books grid is now filterable. But no, its not usable by the the end user
Here’s the JetEngine Query, for explanation and posterity:
Query Type = SQL/AI Query
From table = posts
Use Join enabled
Join Tables
** Join Type = Inner Join
** Join Table = jet_rel_default
** When current table column = child_object_id
** Is equal to other table column = ID
Update: Solution turns out to be a lot simpler, thanks to Crocoblock’s support pointing me to this knowledgebase. Essentially, JetSmartFilters has built-in ability to create filters based on JetEngine’s Relations - and it works on the frontend using Bricks.