Page 1 of 1
Mapping to Select Menu
Posted: Mon Jun 11, 2012 11:55 pm
by imperial.mack
I'm creating a dropdown of different restaurants by type
I tried to drag "Class" to "selectmenuitem1 label" like shown here http://help.gotiggr.com/documentation... but it wouldnt let me. It only works if I drag "$" to "selectmenuitem1" first but then I cant populate the name, address, and phone fields for the restaurants. Im using Kinvey as the backend.
Mapping to Select Menu
Posted: Tue Jun 12, 2012 12:18 am
by maxkatz
Just to make sure I understand, you want to map the same collection to the menu and grid?
Mapping to Select Menu
Posted: Tue Jun 12, 2012 1:18 am
by imperial.mack
Correct. and using kinvey I just thought I'd add a "Class" column to each restaurant and put in the type of restaurant in the cell.
I just want the dropdown to be dynamic and load restaurants depending on the cruisine type selected
Mapping to Select Menu
Posted: Tue Jun 12, 2012 3:04 am
by maxkatz
Here is what you can do.
Open the service editor, Response Parameters panel. Then manually add another response collection and the data you want to map. For example, you will end up with something like this:
$
__Name
__Class
__....
$
__Name
__Class
this way you can map one of them to the menu and one to the grid.
Do insert at least one static element into the menu, otherwise it won't work (it's a known bug).
Mapping to Select Menu
Posted: Tue Jun 12, 2012 3:57 am
by imperial.mack
Works!!! but is there some way to remove duplicate entries in the dropdown?
Mapping to Select Menu
Posted: Tue Jun 12, 2012 3:59 am
by maxkatz
Unless that's the actual data, you shouldn't get any duplicates. How does your mapping look?
Mapping to Select Menu
Posted: Tue Jun 12, 2012 1:20 pm
by imperial.mack
yes I see duplicates for each restaurant, 25 "American", and one "African", but problem also is when i select "African" is just refreshes the page and doesnt show the one African restaurant I have in there.
Mapping to Select Menu
Posted: Tue Jun 12, 2012 4:04 pm
by maxkatz
Where exactly do you see duplicates..?
The list won't automatically refresh (two separate components), you need to filter the list based on the value selected form the menu.
Mapping to Select Menu
Posted: Sat Jun 16, 2012 3:17 pm
by imperial.mack
How would I go about filtering the list based on the value selected from the menu?
Mapping to Select Menu
Posted: Sat Jun 16, 2012 4:03 pm
by maxkatz
Read the selected value, make a request to Kinvey (check their API - what filtering options they have), get the result and display it.