Page 1 of 1

Populating and mapping to the select menu component

Posted: Thu May 07, 2015 5:03 pm
by Mac Strait

I would like to populate the Select UI component using the REST LIST database service to give the user a list of items to choose from. Mapping $ to the UI component name displays all the items from the database. I am using an click event to trigger the mapping. The first click displays the drop down list retrieved from the database, but when the user selects an item, it is always one particular item that is shown as selected. On the second click the list disappears.

Basically I am trying to achieve a drop down menu where the user is able to select an item and the selected item is shown in the display. Note that I do not know the number of items that will appear in the drop down ahead of time. Image


Populating and mapping to the select menu component

Posted: Fri May 08, 2015 3:13 pm
by Serhii Kulibaba

Hello,

Please change event of action "invoke service" from "click" to "page show".

Could you check are there any errors in console? This: http://devcenter.appery.io/documentat... should help.


Populating and mapping to the select menu component

Posted: Fri May 08, 2015 4:09 pm
by Mac Strait

Hi,

Thanks for the swift response. Changing the invoke service to be associated with the page rather than the select component and setting the event to be page show worked perfectly!

So I take it to update the database with the users selection, I should use the click or selected service on the select component along with the appropriate REST service?


Populating and mapping to the select menu component

Posted: Sat May 09, 2015 5:49 pm
by Alena Prykhodko

Invoke service on page show event.