I have a drop down menu that I’m trying to dynamically populate. The data is actually stored in two data types – Menu and Menu_Taxonomy). In the “Menu” data type I have the values (“Name”) that I want to display in the menu, but I need to only show a specific type of menu, so I need to first look in the Menu_Taxonomy to get unique IDs that relate to the right taxonomyand then search in the Menu data type with the Unique ID.
The “Menu” data type’s unique ID is stored in the related record on the “Menu_taxonomy”.
How can I create a drop down that essentially joins the two data types together to get the data needed?
UPDATE: This didn’t work after further review. It was adding all the menu items in the Term data type. For some reason it ignored step 6 where I tried to filter based on a value in the Term_taxonomy data type
I figured it out. Using the Choices Source option I was able to do the following in the drop down menu
Select Type = Term
Create Constraint
Enter Unique ID = [Do a search for]
Select Term_Taxonomy
This open another window
Create Constraint
Enter taxonomy = nav_menu
It’s a little difficult to understand the flow because it’s not presented in a readable way in the Choices Source field once you’ve created it, but at least it works.
Yes, a taxonomy will have multiple terms. A term can only have one taxonomy.
The Term data type holds the name of the term – this could be for a navigational menu location, a category name, or some other type of data in the future. The other fields may be useful at a later date.
What I’m currently trying to accomplish is building a page that will allow me to create nav menus. These menus will be containers for menu items. For example: the “Left Sidebar” nav menu will hold menu items to specific pages. I hope to be able to then create a group that will dynamically display the menu items that I add to the “Left Sidebar” nav menu.
In this screenshot I have the field and button to create the nav menu
In this screenshot I have a drop down that should display the nav menus that were created.
The next part is yet to be built, but once a nav menu is selected then a user will be able to add related menu items to the nav menu in the white space shown below.